Hi All
I am trying to use an accordion list to display a list of items - however I also need to be able to set the font sizes, color and the justification.
I have managed to get most of the layout working - however the first line of the list is still right justified and no matter what I try I cannot get it right:
My YAML is:
component: oh-list-card
config:
title: Test Layout
accordionList: true
slots:
default:
- component: oh-list-item
slots:
after:
- component: Label
config:
text: Line 1
style:
color: red
font-size: 13px
class:
- display-flex
- justify-content-left
- align-items-left
accordion:
- component: oh-list
config:
style:
color: black
slots:
default:
- component: oh-list-item
config:
class:
- display-flex
- justify-content-left
- align-items-left
slots:
after:
- component: Label
config:
text: Line 2
style:
color: red
font-size: 13px
- component: oh-list-item
config:
class:
- display-flex
- justify-content-left
- align-items-left
slots:
after:
- component: Label
config:
text: Line 3
style:
color: red
font-size: 13px
My only other option seems to be to use the First List Item as a Label/Title, but then the Card doe snto look like the others on the page…
EDIT:
My other attempt - which seems to affect all the later components
component: oh-list-card
config:
title: Test Layout
accordionList: true
slots:
default:
- component: oh-list-item
config:
class:
- display-flex
- justify-content-left
- align-items-left
slots:
after:
- component: Label
config:
text: Line 1
style:
color: red
font-size: 13px
accordion:
- component: oh-list
config:
style:
color: black
slots:
default:
- component: oh-list-item
config:
class:
- display-flex
- justify-content-left
- align-items-left
slots:
after:
- component: Label
config:
text: Line 2
style:
color: red
font-size: 13px
- component: oh-list-item
config:
class:
- display-flex
- justify-content-left
- align-items-left
slots:
after:
- component: Label
config:
text: Line 3
style:
color: red
font-size: 13px
EDIT:
The result seems to be affected by the length on the text in line 2 ??? All I did was add abcdefgh
to line 2:
Any suggestions
Thanks
Mark