mirror of
https://github.com/Nheko-Reborn/nheko.git
synced 2024-11-26 04:58:49 +03:00
Make Text element a sibling of the Rectangle to avoid the text from depending on the rectangle's opacity property. Switch to Nheko theme colors
This commit is contained in:
parent
e3c6656613
commit
e1c4f7d516
1 changed files with 14 additions and 14 deletions
|
@ -46,25 +46,25 @@ Item {
|
|||
|
||||
Rectangle {
|
||||
id: container
|
||||
|
||||
width: parent.width
|
||||
implicitHeight: imgcaption.implicitHeight
|
||||
anchors.bottom: overlay.bottom
|
||||
color: "black"
|
||||
color: colors.window
|
||||
opacity: 0.75
|
||||
}
|
||||
|
||||
Text {
|
||||
id: imgcaption
|
||||
Text {
|
||||
id: imgcaption
|
||||
|
||||
anchors.fill: parent
|
||||
elide: Text.ElideMiddle
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
verticalAlignment: Text.AlignVCenter
|
||||
// See this MSC: https://github.com/matrix-org/matrix-doc/pull/2530
|
||||
text: model.data.filename ? model.data.filename : model.data.body
|
||||
color: "white"
|
||||
}
|
||||
anchors.fill: container
|
||||
elide: Text.ElideMiddle
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
verticalAlignment: Text.AlignVCenter
|
||||
// See this MSC: https://github.com/matrix-org/matrix-doc/pull/2530
|
||||
text: model.data.filename ? model.data.filename : model.data.body
|
||||
color: colors.text
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue