feat: Add chat file name in top bar

This commit is contained in:
Petr Mironychev
2025-01-24 00:52:10 +01:00
parent bf63ae5714
commit 258053d826
4 changed files with 34 additions and 4 deletions

View File

@ -72,6 +72,9 @@ ChatRootView {
tokensBadge {
text: qsTr("tokens:%1/%2").arg(root.inputTokensCount).arg(root.chatModel.tokensThreshold)
}
recentPath {
text: qsTr("Latest chat file name: %1").arg(root.chatFileName.length > 0 ? root.chatFileName : "Unsaved")
}
}
ListView {

View File

@ -28,6 +28,7 @@ Rectangle {
property alias loadButton: loadButtonId
property alias clearButton: clearButtonId
property alias tokensBadge: tokensBadgeId
property alias recentPath: recentPathId
color: palette.window.hslLightness > 0.5 ?
Qt.darker(palette.window, 1.1) :
@ -62,6 +63,14 @@ Rectangle {
text: qsTr("Clear")
}
Text {
id: recentPathId
Layout.fillWidth: true
elide: Text.ElideMiddle
color: palette.text
}
Item {
Layout.fillWidth: true
}