Compare commits

..

1 Commits

Author SHA1 Message Date
4645b21f91 add dark mode in baseListItem 2023-03-23 17:57:40 +05:30
2 changed files with 6 additions and 6 deletions

View File

@ -15,12 +15,12 @@
v-if="label"
:for="id"
:class="`font-medium ${
disabled ? 'text-gray-400 cursor-not-allowed' : 'text-gray-600 dark:text-white'
disabled ? 'text-gray-400 cursor-not-allowed' : 'text-gray-600'
} cursor-pointer `"
>
{{ label }}
</label>
<p v-if="description" class="text-gray-500 dark:text-gray-400">{{ description }}</p>
<p v-if="description" class="text-gray-500">{{ description }}</p>
</div>
</div>
</template>
@ -51,7 +51,7 @@ const props = defineProps({
},
checkboxClass: {
type: String,
default: 'w-4 h-4 border-gray-300 rounded cursor-pointer dark:bg-gray-600 dark:border-gray-500',
default: 'w-4 h-4 border-gray-300 rounded cursor-pointer',
},
setInitialValue: {
type: Boolean,

View File

@ -28,13 +28,13 @@ export default {
},
},
setup(props, { slots }) {
const defaultClass = `cursor-pointer pb-2 pr-0 text-sm font-medium leading-5 flex items-center`
const defaultClass = `cursor-pointer pb-2 pr-0 text-sm font-medium leading-5 flex items-center`
let hasIconSlot = computed(() => {
return !!slots.icon
})
let containerClass = computed(() => {
if (props.active) return `${defaultClass} text-primary-500`
else return `${defaultClass} text-gray-500`
if (props.active) return `${defaultClass} text-primary-500 dark:text-primary-400`
else return `${defaultClass} text-gray-500 dark:text-gray-300`
})
return {
hasIconSlot,