feat(StatusLetterIdenticon): Expose the text component
Aliased the text compoenent so that its color, text value can be set from outside
This commit is contained in:
parent
ea3408012f
commit
d16719adda
|
@ -5,6 +5,7 @@ import StatusQ.Core.Theme 0.1
|
||||||
Rectangle {
|
Rectangle {
|
||||||
id: statusLetterIdenticon
|
id: statusLetterIdenticon
|
||||||
|
|
||||||
|
property alias identiconText: identiconText
|
||||||
property string name
|
property string name
|
||||||
property int letterSize: 21
|
property int letterSize: 21
|
||||||
|
|
||||||
|
@ -14,6 +15,7 @@ Rectangle {
|
||||||
radius: width / 2
|
radius: width / 2
|
||||||
|
|
||||||
StatusBaseText {
|
StatusBaseText {
|
||||||
|
id: identiconText
|
||||||
text: ((statusLetterIdenticon.name.charAt(0) === "#")
|
text: ((statusLetterIdenticon.name.charAt(0) === "#")
|
||||||
|| (statusLetterIdenticon.name.charAt(0) === "@") ?
|
|| (statusLetterIdenticon.name.charAt(0) === "@") ?
|
||||||
statusLetterIdenticon.name.charAt(1) : statusLetterIdenticon.name.charAt(0)).toUpperCase()
|
statusLetterIdenticon.name.charAt(1) : statusLetterIdenticon.name.charAt(0)).toUpperCase()
|
||||||
|
|
Loading…
Reference in New Issue