diff --git a/src/components/NeBadgeV2.vue b/src/components/NeBadgeV2.vue new file mode 100644 index 0000000..560a4f9 --- /dev/null +++ b/src/components/NeBadgeV2.vue @@ -0,0 +1,120 @@ + + + + + diff --git a/src/components/NeDropdownFilter.vue b/src/components/NeDropdownFilter.vue index e55c249..9e63677 100644 --- a/src/components/NeDropdownFilter.vue +++ b/src/components/NeDropdownFilter.vue @@ -51,12 +51,14 @@ export interface Props { size?: ButtonSize disabled?: boolean id?: string + clearSearchLabel: string } const props = withDefaults(defineProps(), { showClearFilter: true, showSelectionCount: true, showOptionsFilter: false, + clearSearchLabel: 'Clear', optionsFilterPlaceholder: '', maxOptionsShown: 25, alignToRight: false, @@ -220,6 +222,7 @@ function maybeFocusOptionsFilter() { ref="optionsFilterRef" v-model="optionsFilter" :placeholder="optionsFilterPlaceholder" + :clear-search-label="clearSearchLabel" is-search @keydown.stop /> diff --git a/src/components/NeListbox.vue b/src/components/NeListbox.vue index 00618f0..905c9f2 100644 --- a/src/components/NeListbox.vue +++ b/src/components/NeListbox.vue @@ -69,6 +69,7 @@ const showOptions = ref(false) const listboxRef = ref(null) const top = ref(0) const left = ref(0) +const width = ref(0) const buttonRef = ref | null>(null) const inputValidStyle = @@ -137,6 +138,7 @@ watch( function calculatePosition() { top.value = buttonRef.value?.$el.getBoundingClientRect().bottom + window.scrollY left.value = buttonRef.value?.$el.getBoundingClientRect().left - window.scrollX + width.value = buttonRef.value?.$el.getBoundingClientRect().width || 0 } function onClickOutsideListbox() { @@ -246,7 +248,7 @@ onClickOutside(listboxRef, () => onClickOutsideListbox()) props.isShown, + () => { + if (props.isShown) { + emit('show') + } + } +) onMounted(() => { window.addEventListener('keydown', onKeyUp) diff --git a/src/components/NeTableRow.vue b/src/components/NeTableRow.vue index 3c0f94c..cf7f3db 100644 --- a/src/components/NeTableRow.vue +++ b/src/components/NeTableRow.vue @@ -18,7 +18,7 @@ const trCardStyle: Record = { } diff --git a/src/components/NeToastNotification.vue b/src/components/NeToastNotification.vue index 84cbf43..2cd9919 100644 --- a/src/components/NeToastNotification.vue +++ b/src/components/NeToastNotification.vue @@ -89,7 +89,9 @@ library.add(fasXmark) class="text-gray-500 dark:text-gray-400" >