2021-08-27 21:35:30 +00:00
|
|
|
accessing
|
2021-08-22 01:52:32 +00:00
|
|
|
asCardElement
|
2022-01-03 00:01:09 +00:00
|
|
|
| aModeLook anEditor textInfoPane buttonsPane webpageButton |
|
2021-08-27 21:35:30 +00:00
|
|
|
|
|
|
|
aModeLook := BrEditorModeAptitude new
|
|
|
|
editableFocused: [ :aWidget | aWidget border: (BlBorder paint: BrGlamorousColors focusedEditorBorderColor width: 1) ];
|
|
|
|
editableUnfocused: [ :aWidget | aWidget border: (BlBorder paint: BrGlamorousColors editorBorderColor width: 1) ];
|
|
|
|
readOnly: [ :aWidget | aWidget border: BlBorder empty ].
|
|
|
|
|
|
|
|
anEditor := BrEditor new
|
|
|
|
aptitude: BrGlamorousRegularEditorAptitude new + aModeLook;
|
|
|
|
text: self description;
|
|
|
|
vFitContent.
|
2022-01-03 00:01:09 +00:00
|
|
|
|
|
|
|
webpageButton := BrButton new
|
|
|
|
aptitude: BrGlamorousButtonWithLabelAptitude new;
|
2022-03-31 21:09:15 +00:00
|
|
|
label: self guiLinkLabel;
|
2022-01-03 00:01:09 +00:00
|
|
|
action: [ WebBrowser openOn: self url asString ].
|
2021-08-27 21:35:30 +00:00
|
|
|
|
|
|
|
textInfoPane := BrVerticalPane new
|
|
|
|
hMatchParent;
|
|
|
|
vFitContent;
|
|
|
|
margin: (BlInsets left: 20);
|
|
|
|
addChild: (BrLabel new
|
|
|
|
aptitude: BrGlamorousLabelAptitude;
|
|
|
|
text: '@' , self userName ;
|
|
|
|
beHugeSize);
|
|
|
|
addChild: (BrLabel new
|
|
|
|
aptitude: BrGlamorousLabelAptitude;
|
|
|
|
text: self name;
|
|
|
|
beLargeSize);
|
|
|
|
addChild: (BrLabel new
|
|
|
|
aptitude: BrGlamorousLabelAptitude;
|
2022-01-03 00:01:09 +00:00
|
|
|
text: 'Joined: ' , self createdAtShorted ).
|
|
|
|
self url ifNotNil: [textInfoPane addChild: webpageButton].
|
|
|
|
textInfoPane addChild: anEditor.
|
2021-08-27 22:32:28 +00:00
|
|
|
buttonsPane := BrHorizontalPane new
|
|
|
|
fitContent;
|
|
|
|
cellSpacing: 5;
|
|
|
|
addChildren: {
|
|
|
|
BrButton new
|
|
|
|
aptitude: BrGlamorousButtonWithLabelAptitude new;
|
|
|
|
label: 'Tweets';
|
2022-04-01 01:49:30 +00:00
|
|
|
action: [ :e | e phlow spawnObject: self getMessages ].
|
2021-08-27 22:32:28 +00:00
|
|
|
BrButton new
|
|
|
|
aptitude: BrGlamorousButtonWithLabelAptitude new;
|
|
|
|
label: 'Web view';
|
|
|
|
action: [ self webView ].
|
|
|
|
}.
|
2021-08-27 21:35:30 +00:00
|
|
|
|
|
|
|
^ BrHorizontalPane new
|
|
|
|
padding: (BlInsets all: 15);
|
|
|
|
margin: (BlInsets all: 10);
|
|
|
|
cellSpacing: 5;
|
|
|
|
hMatchParent;
|
2021-08-22 01:52:32 +00:00
|
|
|
vFitContent;
|
2021-08-27 21:35:30 +00:00
|
|
|
addChildren: {
|
|
|
|
(self profileImage asElement asScalableElement size: 124 @ 124).
|
|
|
|
BrVerticalPane new
|
|
|
|
cellSpacing: 5;
|
|
|
|
hMatchParent;
|
|
|
|
vFitContent;
|
|
|
|
addChildren: {
|
2021-08-27 22:32:28 +00:00
|
|
|
buttonsPane.
|
2021-08-27 21:35:30 +00:00
|
|
|
textInfoPane.
|
|
|
|
}
|
|
|
|
}
|