Chatwoot/app/javascript/shared/components/ui/dropdown/DropdownItem.vue
2021-05-20 13:51:46 +05:30

49 lines
803 B
Vue

<template>
<li
class="dropdown-menu__item"
:class="{
'is-disabled': disabled,
}"
:tabindex="disabled ? null : -1"
:aria-disabled="disabled"
>
<slot></slot>
</li>
</template>
<script>
export default {
name: 'WootDropdownItem',
componentName: 'WootDropdownMenu',
props: {
disabled: {
type: Boolean,
default: false,
},
className: {
type: String,
default: '',
},
},
};
</script>
<style lang="scss" scoped>
.dropdown-menu__item {
list-style: none;
::v-deep {
a,
.button {
width: 100%;
text-align: left;
white-space: nowrap;
display: inline-flex;
border-radius: var(--border-radius-normal);
&:hover {
background: var(--color-background);
}
}
}
}
</style>