qml: make TextAreas more visible
This commit is contained in:
@@ -45,20 +45,26 @@ ElDialog {
|
||||
Layout.rightMargin: constants.paddingLarge
|
||||
|
||||
Label {
|
||||
text: Daemon.currentWallet.isWatchOnly
|
||||
? qsTr('Import additional addresses')
|
||||
: qsTr('Import additional keys')
|
||||
Layout.fillWidth: true
|
||||
wrapMode: Text.Wrap
|
||||
text: (Daemon.currentWallet.isWatchOnly
|
||||
? qsTr('Enter, paste or scan additional addresses')
|
||||
: qsTr('Enter, paste or scan additional private keys')) +
|
||||
'. ' + qsTr('You can add multiple, each on a separate line.')
|
||||
}
|
||||
|
||||
RowLayout {
|
||||
TextArea {
|
||||
ElTextArea {
|
||||
id: import_ta
|
||||
Layout.fillWidth: true
|
||||
Layout.minimumHeight: 80
|
||||
focus: true
|
||||
Layout.fillHeight: true
|
||||
font.family: FixedFont
|
||||
wrapMode: TextEdit.WrapAnywhere
|
||||
onTextChanged: valid = verify(text)
|
||||
inputMethodHints: Qt.ImhSensitiveData | Qt.ImhNoPredictiveText
|
||||
inputMethodHints: Qt.ImhSensitiveData | Qt.ImhNoPredictiveText | Qt.ImhNoAutoUppercase
|
||||
background: PaneInsetBackground {
|
||||
baseColor: constants.darkerDialogBackground
|
||||
}
|
||||
}
|
||||
ColumnLayout {
|
||||
Layout.alignment: Qt.AlignTop
|
||||
|
||||
@@ -36,6 +36,14 @@ ElDialog {
|
||||
Layout.rightMargin: constants.paddingLarge
|
||||
Layout.bottomMargin: constants.paddingLarge
|
||||
|
||||
InfoTextArea {
|
||||
Layout.columnSpan: 2
|
||||
Layout.fillWidth: true
|
||||
compact: true
|
||||
visible: invoiceParser.lnurlData['min_sendable_sat'] != invoiceParser.lnurlData['max_sendable_sat']
|
||||
text: qsTr('Amount must be between %1 and %2 %3').arg(Config.formatSats(invoiceParser.lnurlData['min_sendable_sat'])).arg(Config.formatSats(invoiceParser.lnurlData['max_sendable_sat'])).arg(Config.baseUnit)
|
||||
}
|
||||
|
||||
Label {
|
||||
text: qsTr('Provider')
|
||||
color: Material.accentColor
|
||||
@@ -93,26 +101,17 @@ ElDialog {
|
||||
}
|
||||
}
|
||||
|
||||
InfoTextArea {
|
||||
Layout.columnSpan: 2
|
||||
Layout.fillWidth: true
|
||||
compact: true
|
||||
visible: invoiceParser.lnurlData['min_sendable_sat'] != invoiceParser.lnurlData['max_sendable_sat']
|
||||
text: qsTr('Amount must be between %1 and %2 %3').arg(Config.formatSats(invoiceParser.lnurlData['min_sendable_sat'])).arg(Config.formatSats(invoiceParser.lnurlData['max_sendable_sat'])).arg(Config.baseUnit)
|
||||
}
|
||||
|
||||
Label {
|
||||
Layout.columnSpan: 2
|
||||
visible: invoiceParser.lnurlData['comment_allowed'] > 0
|
||||
text: qsTr('Message')
|
||||
color: Material.accentColor
|
||||
}
|
||||
TextArea {
|
||||
ElTextArea {
|
||||
id: comment
|
||||
Layout.columnSpan: 2
|
||||
Layout.fillWidth: true
|
||||
Layout.leftMargin: constants.paddingLarge
|
||||
Layout.minimumHeight: 80
|
||||
Layout.minimumHeight: 160
|
||||
visible: invoiceParser.lnurlData['comment_allowed'] > 0
|
||||
wrapMode: TextEdit.Wrap
|
||||
placeholderText: qsTr('Enter an (optional) message for the receiver')
|
||||
|
||||
@@ -101,6 +101,18 @@ ElDialog {
|
||||
plaintext.text = AppController.clipboardToText()
|
||||
}
|
||||
}
|
||||
ToolButton {
|
||||
icon.source: '../../icons/share.png'
|
||||
icon.color: enabled ? 'transparent' : Material.iconDisabledColor
|
||||
enabled: plaintext.text
|
||||
onClicked: {
|
||||
var dialog = app.genericShareDialog.createObject(app, {
|
||||
title: qsTr('Message'),
|
||||
text_qr: plaintext.text
|
||||
})
|
||||
dialog.open()
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import QtQuick 2.15
|
||||
import QtQuick.Layouts 1.0
|
||||
import QtQuick.Controls 2.14
|
||||
import QtQuick.Controls.Material 2.0
|
||||
import QtQuick
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Controls
|
||||
import QtQuick.Controls.Material
|
||||
|
||||
import org.electrum 1.0
|
||||
|
||||
@@ -16,6 +16,9 @@ Flickable {
|
||||
property alias wrapMode: edit.wrapMode
|
||||
property alias background: rootpane.background
|
||||
property alias font: edit.font
|
||||
property alias inputMethodHints: edit.inputMethodHints
|
||||
property alias placeholderText: edit.placeholderText
|
||||
property alias color: edit.color
|
||||
|
||||
contentWidth: rootpane.width
|
||||
contentHeight: rootpane.height
|
||||
|
||||
@@ -122,10 +122,10 @@ WizardComponent {
|
||||
}
|
||||
|
||||
RowLayout {
|
||||
TextArea {
|
||||
ElTextArea {
|
||||
id: masterkey_ta
|
||||
Layout.fillWidth: true
|
||||
Layout.minimumHeight: 80
|
||||
Layout.minimumHeight: 160
|
||||
font.family: FixedFont
|
||||
wrapMode: TextEdit.WrapAnywhere
|
||||
onTextChanged: {
|
||||
@@ -133,8 +133,12 @@ WizardComponent {
|
||||
verifyMasterKey(text)
|
||||
}
|
||||
inputMethodHints: Qt.ImhSensitiveData | Qt.ImhNoPredictiveText | Qt.ImhNoAutoUppercase
|
||||
background: PaneInsetBackground {
|
||||
baseColor: constants.darkerDialogBackground
|
||||
}
|
||||
}
|
||||
ColumnLayout {
|
||||
Layout.alignment: Qt.AlignTop
|
||||
ToolButton {
|
||||
icon.source: '../../../icons/paste.png'
|
||||
icon.height: constants.iconSizeMedium
|
||||
|
||||
@@ -26,7 +26,7 @@ WizardComponent {
|
||||
|
||||
ColumnLayout {
|
||||
width: parent.width
|
||||
|
||||
height: parent.height
|
||||
InfoTextArea {
|
||||
Layout.preferredWidth: parent.width
|
||||
text: qsTr('Enter a list of Bitcoin addresses (this will create a watching-only wallet), or a list of private keys.')
|
||||
@@ -34,15 +34,21 @@ WizardComponent {
|
||||
|
||||
RowLayout {
|
||||
Layout.topMargin: constants.paddingMedium
|
||||
TextArea {
|
||||
Layout.fillHeight: true
|
||||
|
||||
ElTextArea {
|
||||
id: import_ta
|
||||
Layout.fillWidth: true
|
||||
Layout.minimumHeight: 80
|
||||
focus: true
|
||||
Layout.fillHeight: true
|
||||
font.family: FixedFont
|
||||
wrapMode: TextEdit.WrapAnywhere
|
||||
onTextChanged: valid = verify(text)
|
||||
inputMethodHints: Qt.ImhSensitiveData | Qt.ImhNoPredictiveText | Qt.ImhNoAutoUppercase
|
||||
background: PaneInsetBackground {
|
||||
baseColor: constants.darkerDialogBackground
|
||||
}
|
||||
}
|
||||
|
||||
ColumnLayout {
|
||||
Layout.alignment: Qt.AlignTop
|
||||
ToolButton {
|
||||
|
||||
Reference in New Issue
Block a user