gpt4all

Форк
0
/
ThumbsDownDialog.qml 
77 строк · 2.0 Кб
1
import QtCore
2
import QtQuick
3
import QtQuick.Controls
4
import QtQuick.Controls.Basic
5
import QtQuick.Layouts
6
import download
7
import network
8
import llm
9

10
MyDialog {
11
    id: thumbsDownDialog
12
    modal: true
13
    padding: 20
14

15
    Theme {
16
        id: theme
17
    }
18

19
    property alias response: thumbsDownNewResponse.text
20

21
    Column {
22
        anchors.fill: parent
23
        spacing: 20
24
        Item {
25
            width: childrenRect.width
26
            height: childrenRect.height
27
            Image {
28
                id: img
29
                anchors.top: parent.top
30
                anchors.left: parent.left
31
                width: 60
32
                height: 60
33
                source: "qrc:/gpt4all/icons/thumbs_down.svg"
34
            }
35
            Text {
36
                anchors.left: img.right
37
                anchors.leftMargin: 30
38
                anchors.verticalCenter: img.verticalCenter
39
                text: qsTr("Please edit the text below to provide a better response. (optional)")
40
                color: theme.textColor
41
                font.pixelSize: theme.fontSizeLarge
42
            }
43
        }
44

45
        ScrollView {
46
            clip: true
47
            height: 300
48
            width: parent.width
49
            ScrollBar.vertical.policy: ScrollBar.AlwaysOn
50
            ScrollBar.horizontal.policy: ScrollBar.AlwaysOff
51

52
            MyTextArea {
53
                id: thumbsDownNewResponse
54
                placeholderText: qsTr("Please provide a better response...")
55
            }
56
        }
57
    }
58

59
    footer: DialogButtonBox {
60
        padding: 20
61
        alignment: Qt.AlignRight
62
        spacing: 10
63
        MySettingsButton {
64
            text: qsTr("Submit")
65
            Accessible.description: qsTr("Submits the user's response")
66
            DialogButtonBox.buttonRole: DialogButtonBox.AcceptRole
67
        }
68
        MySettingsButton {
69
            text: qsTr("Cancel")
70
            Accessible.description: qsTr("Closes the response dialog")
71
            DialogButtonBox.buttonRole: DialogButtonBox.RejectRole
72
        }
73
        background: Rectangle {
74
            color: "transparent"
75
        }
76
    }
77
}
78

Использование cookies

Мы используем файлы cookie в соответствии с Политикой конфиденциальности и Политикой использования cookies.

Нажимая кнопку «Принимаю», Вы даете АО «СберТех» согласие на обработку Ваших персональных данных в целях совершенствования нашего веб-сайта и Сервиса GitVerse, а также повышения удобства их использования.

Запретить использование cookies Вы можете самостоятельно в настройках Вашего браузера.