Reverts equipment accordion link styling (#1436)

Fix problem where accordion items caused issue in the events handling, preventing promoted widgets from working (e.g. oh-toggle).

Add styling to present equipment as accordion as activable items (pointer, hover and active states), in a similar fashion as regular link list items.

Signed-off-by: Gautier Taravella <tarag@mailbox.org>
pull/1540/head
Gautier 2022-11-08 14:51:59 +01:00 committed by GitHub
parent 531dabfa83
commit 4d1a94ac48
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 15 additions and 1 deletions

View File

@ -5,7 +5,7 @@
:media-item="context.parent.component.config.mediaList && !config.divider"
:badge="(config.divider) ? 'Divider' : (config.listButton) ? 'List button' : config.badge"
:accordion-item="isRegularAccordion && !config.divider && !context.editmode"
:link="(config.action !== undefined && config.action !== '' && !context.editmode) || isEquipmentAccordion ? true : undefined"
:link="(config.action !== undefined && config.action !== '' && !context.editmode) ? true : undefined"
@click.stop="openAccordionOrPerformAction"
:class="{ 'oh-equipment-accordion-item' : isEquipmentAccordion}"
ref="f7AccordionContent">
@ -32,6 +32,12 @@
.item-link .item-inner:after
transition-duration 300ms
> .item-content
cursor pointer
&:active
background var(--f7-list-link-pressed-bg-color)
.list,
.block
margin-top 0
@ -96,6 +102,14 @@
&.accordion-item-opened > .item-content > .item-inner > .item-title-row:before
content var(--f7-accordion-chevron-icon-up)
.aurora
.oh-equipment-accordion-item
> .item-content
&:hover
background var(--f7-list-link-hover-bg-color)
&:active
background var(--f7-list-link-pressed-bg-color)
.item-divider > span
flex-shrink 1
overflow hidden