From e5ae8cbb1c0e288d7c87840819739febf30cfbb6 Mon Sep 17 00:00:00 2001 From: Paul Vilalta Date: Tue, 3 Jan 2023 16:34:54 +0100 Subject: [PATCH 1/3] first draw --- .../BIMDataMenu/BIMDataMenu.vue | 34 +++++++++++++++-- .../BIMDataMenu/_BIMDataMenu.scss | 3 ++ src/web/views/Components/Menu/BasicMenu.vue | 37 ++++++++++++++++++- 3 files changed, 70 insertions(+), 4 deletions(-) diff --git a/src/BIMDataComponents/BIMDataMenu/BIMDataMenu.vue b/src/BIMDataComponents/BIMDataMenu/BIMDataMenu.vue index 357d595f..24f5c593 100644 --- a/src/BIMDataComponents/BIMDataMenu/BIMDataMenu.vue +++ b/src/BIMDataComponents/BIMDataMenu/BIMDataMenu.vue @@ -8,6 +8,7 @@ :class="[ item.divider ? 'bimdata-menu__item--divider' : '', { hover: isItemHover && currentItemText === item.text }, + hasNoChildren(item) ? 'bimdata-menu__item--no-children' : '', ]" @click.stop="onClick(item)" @mouseover="onMouseOver(item)" @@ -26,14 +27,32 @@ :style="{ 'background-color': isItemHover && currentItemText === item.text ? item.background : '', + display: 'flex', }" > - + @@ -97,6 +121,10 @@ export default { type: Boolean, default: true, }, + childrenLeft: { + type: Boolean, + default: false, + }, }, emits: ["item-click"], data() { diff --git a/src/BIMDataComponents/BIMDataMenu/_BIMDataMenu.scss b/src/BIMDataComponents/BIMDataMenu/_BIMDataMenu.scss index 2e390615..f50bf515 100644 --- a/src/BIMDataComponents/BIMDataMenu/_BIMDataMenu.scss +++ b/src/BIMDataComponents/BIMDataMenu/_BIMDataMenu.scss @@ -48,6 +48,9 @@ background-color: transparent; } } + &--no-children { + color: var(--color-silver-dark); + } &__children { overflow: auto; padding: calc(var(--spacing-unit) / 2) 0; diff --git a/src/web/views/Components/Menu/BasicMenu.vue b/src/web/views/Components/Menu/BasicMenu.vue index 7b5075b9..6fc9ae13 100644 --- a/src/web/views/Components/Menu/BasicMenu.vue +++ b/src/web/views/Components/Menu/BasicMenu.vue @@ -10,15 +10,31 @@ >