Skip to content

Commit

Permalink
add DisabledDoc for Card
Browse files Browse the repository at this point in the history
  • Loading branch information
nightswinger committed May 2, 2024
1 parent e8b99e9 commit ba24a18
Show file tree
Hide file tree
Showing 2 changed files with 57 additions and 0 deletions.
50 changes: 50 additions & 0 deletions docs/src/components/views/Card/DisabledDoc.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
<template>
<DocSection label="Disabled" :code="code">
<template #description>
A card may show its content is disabled
</template>
<template #example>
<Card disabled>
<CardContent header="Kristy">
<template #meta>
<span class="date">Joined in 2013</span>
</template>
<template #description>
Kristy is an art director living in New York.
</template>
</CardContent>
<CardContent extra>
<Icon name="user" />
22 Friends
</CardContent>
</Card>
</template>
</DocSection>
</template>

<script setup lang="ts">
import DocSection from '@/components/doc/DocSection.vue'
import {
Card,
CardContent,
Icon,
} from 'vue-fomantic-ui'
const code = `<template>
<Card disabled>
<CardContent header="Kristy">
<template #meta>
<span class="date">Joined in 2013</span>
</template>
<template #description>
Kristy is an art director living in New York.
</template>
</CardContent>
<CardContent extra>
<Icon name="user" />
22 Friends
</CardContent>
</Card>
<\/template>`
</script>
7 changes: 7 additions & 0 deletions docs/src/pages/views/Card.vue
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ import DescriptionDoc from '@/components/views/Card/DescriptionDoc.vue'
import ExtraContentDoc from '@/components/views/Card/ExtraContentDoc.vue'
// States
import DisabledDoc from '@/components/views/Card/DisabledDoc.vue'
// Variations
import FluidCardDoc from '@/components/views/Card/FluidCardDoc.vue'
Expand Down Expand Up @@ -93,6 +94,12 @@ const docs = [
category: 'Content',
component: ExtraContentDoc,
},
{
id: 'disabled',
label: 'Disabled',
category: 'States',
component: DisabledDoc,
},
{
id: 'fluid-card',
label: 'Fluid Card',
Expand Down

0 comments on commit ba24a18

Please sign in to comment.