Chips, ColorPicker, Dropdown unstyled demo updates

pull/4224/head
Tuğçe Küçükoğlu 2023-07-26 16:38:10 +03:00
parent 6657f09035
commit a3f5a4fb6f
12 changed files with 226 additions and 27 deletions

View File

@ -1,5 +1,5 @@
<template>
<DocSectionText id="style" label="Style" v-bind="$attrs">
<DocSectionText v-bind="$attrs">
<p>List of class names used in the styled mode.</p>
</DocSectionText>

View File

@ -0,0 +1,30 @@
<template>
<DocSectionText v-bind="$attrs">
<p>Theming is implemented with the pass through properties in unstyled mode. Example below demonstrates the built-in Tailwind theme.</p>
</DocSectionText>
<DocSectionCode :code="code" embedded />
</template>
<script>
export default {
data() {
return {
value: null,
code: {
composition: `
<template>
<div class="card">
<Chips v-model="value" />
</div>
</template>
<script setup>
import { ref } from "vue";
const value = ref();
<\/script>`
}
};
}
};
</script>

View File

@ -0,0 +1,33 @@
<template>
<div class="doc-main">
<div class="doc-intro">
<h1>Chips Theming</h1>
</div>
<DocSections :docs="docs" />
</div>
<DocSectionNav :docs="docs" />
</template>
<script>
import StyledDoc from './StyledDoc.vue';
import UnstyledDoc from './UnstyledDoc.vue';
export default {
data() {
return {
docs: [
{
id: 'styled',
label: 'Styled',
component: StyledDoc
},
{
id: 'unstyled',
label: 'Unstyled',
component: UnstyledDoc
}
]
};
}
};
</script>

View File

@ -1,5 +1,5 @@
<template>
<DocSectionText id="style" label="Style" v-bind="$attrs">
<DocSectionText v-bind="$attrs">
<p>List of class names used in the styled mode.</p>
</DocSectionText>

View File

@ -0,0 +1,30 @@
<template>
<DocSectionText v-bind="$attrs">
<p>Theming is implemented with the pass through properties in unstyled mode. Example below demonstrates the built-in Tailwind theme.</p>
</DocSectionText>
<DocSectionCode :code="code" embedded />
</template>
<script>
export default {
data() {
return {
color: null,
code: {
composition: `
<template>
<div class="card flex justify-center">
<ColorPicker v-model="color" />
</div>
</template>
<script setup>
import { ref } from "vue";
const color = ref();
<\/script>`
}
};
}
};
</script>

View File

@ -0,0 +1,33 @@
<template>
<div class="doc-main">
<div class="doc-intro">
<h1>ColorPicker Theming</h1>
</div>
<DocSections :docs="docs" />
</div>
<DocSectionNav :docs="docs" />
</template>
<script>
import StyledDoc from './StyledDoc.vue';
import UnstyledDoc from './UnstyledDoc.vue';
export default {
data() {
return {
docs: [
{
id: 'styled',
label: 'Styled',
component: StyledDoc
},
{
id: 'unstyled',
label: 'Unstyled',
component: UnstyledDoc
}
]
};
}
};
</script>

View File

@ -1,5 +1,5 @@
<template>
<DocSectionText id="style" label="Style" v-bind="$attrs">
<DocSectionText v-bind="$attrs">
<p>List of class names used in the styled mode.</p>
</DocSectionText>
<div class="doc-tablewrapper">

View File

@ -0,0 +1,44 @@
<template>
<DocSectionText v-bind="$attrs">
<p>Theming is implemented with the pass through properties in unstyled mode. Example below demonstrates the built-in Tailwind theme.</p>
</DocSectionText>
<DocSectionCode :code="code" embedded />
</template>
<script>
export default {
data() {
return {
selectedCity: null,
cities: [
{ name: 'New York', code: 'NY' },
{ name: 'Rome', code: 'RM' },
{ name: 'London', code: 'LDN' },
{ name: 'Istanbul', code: 'IST' },
{ name: 'Paris', code: 'PRS' }
],
code: {
composition: `
<template>
<div class="card flex justify-center">
<Dropdown v-model="selectedCity" :options="cities" optionLabel="name" placeholder="Select a City" class="w-full md:w-14rem" />
</div>
</template>
<script setup>
import { ref } from "vue";
const selectedCity = ref();
const cities = ref([
{ name: 'New York', code: 'NY' },
{ name: 'Rome', code: 'RM' },
{ name: 'London', code: 'LDN' },
{ name: 'Istanbul', code: 'IST' },
{ name: 'Paris', code: 'PRS' }
]);
<\/script>`
}
};
}
};
</script>

View File

@ -0,0 +1,33 @@
<template>
<div class="doc-main">
<div class="doc-intro">
<h1>Dropdown Theming</h1>
</div>
<DocSections :docs="docs" />
</div>
<DocSectionNav :docs="docs" />
</template>
<script>
import StyledDoc from './StyledDoc.vue';
import UnstyledDoc from './UnstyledDoc.vue';
export default {
data() {
return {
docs: [
{
id: 'styled',
label: 'Styled',
component: StyledDoc
},
{
id: 'unstyled',
label: 'Unstyled',
component: UnstyledDoc
}
]
};
}
};
</script>

View File

@ -1,5 +1,5 @@
<template>
<DocComponent title="Vue Chips Component" header="Chips" description="Chips is used to enter multiple values on an input field." :componentDocs="docs" :apiDocs="['Chips']" :ptTabComponent="ptComponent" />
<DocComponent title="Vue Chips Component" header="Chips" description="Chips is used to enter multiple values on an input field." :componentDocs="docs" :apiDocs="['Chips']" :ptTabComponent="ptComponent" :themingDocs="themingDoc" />
</template>
<script>
@ -10,10 +10,10 @@ import FloatLabelDoc from '@/doc/chips/FloatLabelDoc';
import ImportDoc from '@/doc/chips/ImportDoc';
import InvalidDoc from '@/doc/chips/InvalidDoc';
import SeparatorDoc from '@/doc/chips/SeparatorDoc';
import StyleDoc from '@/doc/chips/StyleDoc';
import TemplateDoc from '@/doc/chips/TemplateDoc';
import VeeValidateDoc from '@/doc/chips/form/VeeValidateDoc';
import PTComponent from '@/doc/chips/pt/index.vue';
import ThemingDoc from '@/doc/chips/theming/index.vue';
export default {
data() {
@ -66,18 +66,14 @@ export default {
}
]
},
{
id: 'style',
label: 'Style',
component: StyleDoc
},
{
id: 'accessibility',
label: 'Accessibility',
component: AccessibilityDoc
}
],
ptComponent: PTComponent
ptComponent: PTComponent,
themingDoc: ThemingDoc
};
}
};

View File

@ -1,5 +1,5 @@
<template>
<DocComponent title="Vue ColorPicker Component" header="ColorPicker" description="ColorPicker is an input component to select a color." :componentDocs="docs" :apiDocs="['ColorPicker']" :ptTabComponent="ptComponent" />
<DocComponent title="Vue ColorPicker Component" header="ColorPicker" description="ColorPicker is an input component to select a color." :componentDocs="docs" :apiDocs="['ColorPicker']" :ptTabComponent="ptComponent" :themingDocs="themingDoc" />
</template>
<script>
@ -9,9 +9,9 @@ import DisabledDoc from '@/doc/colorpicker/DisabledDoc';
import FormatDoc from '@/doc/colorpicker/FormatDoc';
import ImportDoc from '@/doc/colorpicker/ImportDoc';
import InlineDoc from '@/doc/colorpicker/InlineDoc';
import StyleDoc from '@/doc/colorpicker/StyleDoc';
import VeeValidateDoc from '@/doc/colorpicker/form/VeeValidateDoc';
import PTComponent from '@/doc/colorpicker/pt/index.vue';
import ThemingDoc from '@/doc/colorpicker/theming/index.vue';
export default {
data() {
@ -54,18 +54,14 @@ export default {
}
]
},
{
id: 'style',
label: 'Style',
component: StyleDoc
},
{
id: 'accessibility',
label: 'Accessibility',
component: AccessibilityDoc
}
],
ptComponent: PTComponent
ptComponent: PTComponent,
themingDoc: ThemingDoc
};
}
};

View File

@ -1,5 +1,13 @@
<template>
<DocComponent title="Vue Select Component" header="Dropdown" description="Dropdown also known as Select, is used to choose an item from a collection of options." :componentDocs="docs" :apiDocs="['Dropdown']" :ptTabComponent="ptComponent" />
<DocComponent
title="Vue Select Component"
header="Dropdown"
description="Dropdown also known as Select, is used to choose an item from a collection of options."
:componentDocs="docs"
:apiDocs="['Dropdown']"
:ptTabComponent="ptComponent"
:themingDocs="themingDoc"
/>
</template>
<script>
@ -15,11 +23,11 @@ import ImportDoc from '@/doc/dropdown/ImportDoc';
import InvalidDoc from '@/doc/dropdown/InvalidDoc';
import LazyVirtualScrollDoc from '@/doc/dropdown/LazyVirtualScrollDoc';
import LoadingStateDoc from '@/doc/dropdown/LoadingStateDoc';
import StyleDoc from '@/doc/dropdown/StyleDoc';
import TemplateDoc from '@/doc/dropdown/TemplateDoc';
import VirtualScrollDoc from '@/doc/dropdown/VirtualScrollDoc';
import VeeValidateDoc from '@/doc/dropdown/form/VeeValidateDoc';
import PTComponent from '@/doc/dropdown/pt/index.vue';
import ThemingDoc from '@/doc/dropdown/theming/index.vue';
export default {
data() {
@ -102,18 +110,14 @@ export default {
}
]
},
{
id: 'style',
label: 'Style',
component: StyleDoc
},
{
id: 'accessibility',
label: 'Accessibility',
component: AccessibilityDoc
}
],
ptComponent: PTComponent
ptComponent: PTComponent,
themingDoc: ThemingDoc
};
}
};