PTViewer added to panel components

pull/6416/head
tugcekucukoglu 2024-09-16 16:04:45 +03:00
parent 274b9b43a0
commit 75b6473550
28 changed files with 376 additions and 104 deletions

View File

@ -1,8 +0,0 @@
<template>
<DocSectionText v-bind="$attrs">
<p>{{ $attrs.description }}</p>
</DocSectionText>
<div class="card">
<img class="w-full" src="https://primefaces.org/cdn/primevue/images/pt/accordion.jpg" />
</div>
</template>

View File

@ -0,0 +1,63 @@
<template>
<DocSectionText v-bind="$attrs" />
<DocPTViewer :docs="docs">
<Accordion value="0">
<AccordionPanel value="0">
<AccordionHeader>Header I</AccordionHeader>
<AccordionContent>
<p class="m-0">
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo
consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
</p>
</AccordionContent>
</AccordionPanel>
<AccordionPanel value="1">
<AccordionHeader>Header II</AccordionHeader>
<AccordionContent>
<p class="m-0">
Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Nemo enim
ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt. Consectetur, adipisci velit, sed quia non numquam eius modi.
</p>
</AccordionContent>
</AccordionPanel>
<AccordionPanel value="2">
<AccordionHeader>Header III</AccordionHeader>
<AccordionContent>
<p class="m-0">
At vero eos et accusamus et iusto odio dignissimos ducimus qui blanditiis praesentium voluptatum deleniti atque corrupti quos dolores et quas molestias excepturi sint occaecati cupiditate non provident, similique sunt in culpa
qui officia deserunt mollitia animi, id est laborum et dolorum fuga. Et harum quidem rerum facilis est et expedita distinctio. Nam libero tempore, cum soluta nobis est eligendi optio cumque nihil impedit quo minus.
</p>
</AccordionContent>
</AccordionPanel>
</Accordion>
</DocPTViewer>
</template>
<script>
import { getPTOptions } from '@/components/doc/helpers';
export default {
data() {
return {
docs: [
{
data: getPTOptions('Accordion'),
key: 'Accordion'
},
{
data: getPTOptions('AccordionPanel'),
key: 'AccordionPanel'
},
{
data: getPTOptions('AccordionHeader'),
key: 'AccordionHeader'
},
{
data: getPTOptions('AccordionContent'),
key: 'AccordionContent'
}
]
};
}
};
</script>

View File

@ -11,16 +11,16 @@
<script> <script>
import DocApiTable from '@/components/doc/DocApiTable.vue'; import DocApiTable from '@/components/doc/DocApiTable.vue';
import { getPTOptions } from '@/components/doc/helpers'; import { getPTOptions } from '@/components/doc/helpers';
import PTImage from './PTImage.vue'; import PTViewer from './PTViewer.vue';
export default { export default {
data() { data() {
return { return {
docs: [ docs: [
{ {
id: 'pt.image', id: 'pt.viewer',
label: 'Wireframe', label: 'Viewer',
component: PTImage component: PTViewer
}, },
{ {
id: 'pt.doc.accordion', id: 'pt.doc.accordion',

View File

@ -1,8 +0,0 @@
<template>
<DocSectionText v-bind="$attrs">
<p>{{ $attrs.description }}</p>
</DocSectionText>
<div class="card">
<img class="w-full" src="https://primefaces.org/cdn/primevue/images/pt/card.jpg" />
</div>
</template>

View File

@ -0,0 +1,38 @@
<template>
<DocSectionText v-bind="$attrs" />
<DocPTViewer :docs="docs">
<Card style="width: 25rem">
<template #title>Advanced Card</template>
<template #subtitle>Card subtitle</template>
<template #content>
<p class="m-0">
Lorem ipsum dolor sit amet, consectetur adipisicing elit. Inventore sed consequuntur error repudiandae numquam deserunt quisquam repellat libero asperiores earum nam nobis, culpa ratione quam perferendis esse, cupiditate neque
quas!
</p>
</template>
<template #footer>
<div class="flex gap-4 mt-1">
<Button label="Cancel" severity="secondary" outlined class="w-full" />
<Button label="Save" class="w-full" />
</div>
</template>
</Card>
</DocPTViewer>
</template>
<script>
import { getPTOptions } from '@/components/doc/helpers';
export default {
data() {
return {
docs: [
{
data: getPTOptions('Card'),
key: 'Card'
}
]
};
}
};
</script>

View File

@ -11,16 +11,16 @@
<script> <script>
import DocApiTable from '@/components/doc/DocApiTable.vue'; import DocApiTable from '@/components/doc/DocApiTable.vue';
import { getPTOptions } from '@/components/doc/helpers'; import { getPTOptions } from '@/components/doc/helpers';
import PTImage from './PTImage.vue'; import PTViewer from './PTViewer.vue';
export default { export default {
data() { data() {
return { return {
docs: [ docs: [
{ {
id: 'pt.image', id: 'pt.viewer',
label: 'Wireframe', label: 'Viewer',
component: PTImage component: PTViewer
}, },
{ {
id: 'pt.doc.card', id: 'pt.doc.card',

View File

@ -1,8 +0,0 @@
<template>
<DocSectionText v-bind="$attrs">
<p>{{ $attrs.description }}</p>
</DocSectionText>
<div class="card">
<img class="w-full" src="https://primefaces.org/cdn/primevue/images/pt/deferred.jpg" />
</div>
</template>

View File

@ -0,0 +1,25 @@
<template>
<DocSectionText v-bind="$attrs" />
<DocPTViewer :docs="docs">
<DeferredContent>
<img src="https://primefaces.org/cdn/primevue/images/nature/nature4.jpg" alt="Nature" />
</DeferredContent>
</DocPTViewer>
</template>
<script>
import { getPTOptions } from '@/components/doc/helpers';
export default {
data() {
return {
docs: [
{
data: getPTOptions('DeferredContent'),
key: 'DeferredContent'
}
]
};
}
};
</script>

View File

@ -11,16 +11,16 @@
<script> <script>
import DocApiTable from '@/components/doc/DocApiTable.vue'; import DocApiTable from '@/components/doc/DocApiTable.vue';
import { getPTOptions } from '@/components/doc/helpers'; import { getPTOptions } from '@/components/doc/helpers';
import PTImage from './PTImage.vue'; import PTViewer from './PTViewer.vue';
export default { export default {
data() { data() {
return { return {
docs: [ docs: [
{ {
id: 'pt.image', id: 'pt.viewer',
label: 'Wireframe', label: 'Viewer',
component: PTImage component: PTViewer
}, },
{ {
id: 'pt.doc.deferredcontent', id: 'pt.doc.deferredcontent',

View File

@ -1,8 +0,0 @@
<template>
<DocSectionText v-bind="$attrs">
<p>{{ $attrs.description }}</p>
</DocSectionText>
<div class="card">
<img class="w-full" src="https://primefaces.org/cdn/primevue/images/pt/fieldset.jpg" />
</div>
</template>

View File

@ -0,0 +1,28 @@
<template>
<DocSectionText v-bind="$attrs" />
<DocPTViewer :docs="docs">
<Fieldset legend="Header" toggleable>
<p class="m-0">
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
</p>
</Fieldset>
</DocPTViewer>
</template>
<script>
import { getPTOptions } from '@/components/doc/helpers';
export default {
data() {
return {
docs: [
{
data: getPTOptions('Fieldset'),
key: 'Fieldset'
}
]
};
}
};
</script>

View File

@ -11,16 +11,16 @@
<script> <script>
import DocApiTable from '@/components/doc/DocApiTable.vue'; import DocApiTable from '@/components/doc/DocApiTable.vue';
import { getPTOptions } from '@/components/doc/helpers'; import { getPTOptions } from '@/components/doc/helpers';
import PTImage from './PTImage.vue'; import PTViewer from './PTViewer.vue';
export default { export default {
data() { data() {
return { return {
docs: [ docs: [
{ {
id: 'pt.image', id: 'pt.viewer',
label: 'Wireframe', label: 'Viewer',
component: PTImage component: PTViewer
}, },
{ {
id: 'pt.doc.fieldset', id: 'pt.doc.fieldset',

View File

@ -11,16 +11,16 @@
<script> <script>
import DocApiTable from '@/components/doc/DocApiTable.vue'; import DocApiTable from '@/components/doc/DocApiTable.vue';
import { getPTOptions } from '@/components/doc/helpers'; import { getPTOptions } from '@/components/doc/helpers';
import PTImage from './PTImage.vue'; import PTViewer from './PTViewer.vue';
export default { export default {
data() { data() {
return { return {
docs: [ docs: [
{ {
id: 'pt.image', id: 'pt.viewer',
label: 'Wireframe', label: 'Viewer',
component: PTImage component: PTViewer
}, },
{ {
id: 'pt.doc.panel', id: 'pt.doc.panel',

View File

@ -1,8 +0,0 @@
<template>
<DocSectionText v-bind="$attrs">
<p>{{ $attrs.description }}</p>
</DocSectionText>
<div class="card">
<img class="w-full" src="https://primefaces.org/cdn/primevue/images/pt/scrollpanel.jpg" />
</div>
</template>

View File

@ -0,0 +1,40 @@
<template>
<DocSectionText v-bind="$attrs" />
<DocPTViewer :docs="docs">
<ScrollPanel style="width: 100%; height: 200px" pt:bary="!visible !opacity-100">
<p>
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
</p>
<p>
Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Nemo enim ipsam
voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt. Consectetur, adipisci velit, sed quia non numquam eius modi.
</p>
<p>
At vero eos et accusamus et iusto odio dignissimos ducimus qui blanditiis praesentium voluptatum deleniti atque corrupti quos dolores et quas molestias excepturi sint occaecati cupiditate non provident, similique sunt in culpa qui
officia deserunt mollitia animi, id est laborum et dolorum fuga. Et harum quidem rerum facilis est et expedita distinctio. Nam libero tempore, cum soluta nobis est eligendi optio cumque nihil impedit quo minus.
</p>
<p class="m-0">
Quod maxime placeat facere possimus, omnis voluptas assumenda est, omnis dolor repellendus. Temporibus autem quibusdam et aut officiis debitis aut rerum necessitatibus saepe eveniet ut et voluptates repudiandae sint et molestiae non
recusandae. Itaque earum rerum hic tenetur a sapiente delectus, ut aut reiciendis voluptatibus maiores alias consequatur aut perferendis doloribus asperiores repellat
</p>
</ScrollPanel>
</DocPTViewer>
</template>
<script>
import { getPTOptions } from '@/components/doc/helpers';
export default {
data() {
return {
docs: [
{
data: getPTOptions('ScrollPanel'),
key: 'ScrollPanel'
}
]
};
}
};
</script>

View File

@ -11,16 +11,16 @@
<script> <script>
import DocApiTable from '@/components/doc/DocApiTable.vue'; import DocApiTable from '@/components/doc/DocApiTable.vue';
import { getPTOptions } from '@/components/doc/helpers'; import { getPTOptions } from '@/components/doc/helpers';
import PTImage from './PTImage.vue'; import PTViewer from './PTViewer.vue';
export default { export default {
data() { data() {
return { return {
docs: [ docs: [
{ {
id: 'pt.image', id: 'pt.viewer',
label: 'Wireframe', label: 'Viewer',
component: PTImage component: PTViewer
}, },
{ {
id: 'pt.doc.scrollpanel', id: 'pt.doc.scrollpanel',

View File

@ -1,8 +0,0 @@
<template>
<DocSectionText v-bind="$attrs">
<p>{{ $attrs.description }}</p>
</DocSectionText>
<div class="card">
<img class="w-full" src="https://primefaces.org/cdn/primevue/images/pt/splitter.jpg" />
</div>
</template>

View File

@ -0,0 +1,30 @@
<template>
<DocSectionText v-bind="$attrs" />
<DocPTViewer :docs="docs">
<Splitter style="height: 300px" class="w-full">
<SplitterPanel class="flex items-center justify-center"> Panel 1 </SplitterPanel>
<SplitterPanel class="flex items-center justify-center"> Panel 2 </SplitterPanel>
</Splitter>
</DocPTViewer>
</template>
<script>
import { getPTOptions } from '@/components/doc/helpers';
export default {
data() {
return {
docs: [
{
data: getPTOptions('Splitter'),
key: 'Splitter'
},
{
data: getPTOptions('SplitterPanel'),
key: 'SplitterPanel'
}
]
};
}
};
</script>

View File

@ -11,16 +11,16 @@
<script> <script>
import DocApiTable from '@/components/doc/DocApiTable.vue'; import DocApiTable from '@/components/doc/DocApiTable.vue';
import { getPTOptions } from '@/components/doc/helpers'; import { getPTOptions } from '@/components/doc/helpers';
import PTImage from './PTImage.vue'; import PTViewer from './PTViewer.vue';
export default { export default {
data() { data() {
return { return {
docs: [ docs: [
{ {
id: 'pt.image', id: 'pt.viewer',
label: 'Wireframe', label: 'Viewer',
component: PTImage component: PTViewer
}, },
{ {
id: 'pt.doc.splitter', id: 'pt.doc.splitter',

View File

@ -1,8 +0,0 @@
<template>
<DocSectionText v-bind="$attrs">
<p>{{ $attrs.description }}</p>
</DocSectionText>
<div class="card">
<img class="w-full" src="https://primefaces.org/cdn/primevue/images/pt/wireframe-placeholder.jpg" />
</div>
</template>

View File

@ -0,0 +1,72 @@
<template>
<DocSectionText v-bind="$attrs" />
<DocPTViewer :docs="docs">
<Stepper value="1" class="basis-[50rem]" linear>
<StepList :style="{ overflowX: 'unset' }">
<Step value="1">Header I</Step>
<Step value="2">Header II</Step>
<Step value="3">Header III</Step>
</StepList>
<StepPanels>
<StepPanel value="1">
<div class="flex flex-col h-48">
<div class="border-2 border-dashed border-surface-200 dark:border-surface-700 rounded bg-surface-50 dark:bg-surface-950 flex-auto flex justify-center items-center font-medium">Content I</div>
</div>
<div class="flex pt-6 justify-end">
<Button label="Next" icon="pi pi-arrow-right" iconPos="right" />
</div>
</StepPanel>
<StepPanel value="2">
<div class="flex flex-col h-48">
<div class="border-2 border-dashed border-surface-200 dark:border-surface-700 rounded bg-surface-50 dark:bg-surface-950 flex-auto flex justify-center items-center font-medium">Content II</div>
</div>
<div class="flex pt-6 justify-between">
<Button label="Back" severity="secondary" icon="pi pi-arrow-left" />
<Button label="Next" icon="pi pi-arrow-right" iconPos="right" />
</div>
</StepPanel>
<StepPanel value="3">
<div class="flex flex-col h-48">
<div class="border-2 border-dashed border-surface-200 dark:border-surface-700 rounded bg-surface-50 dark:bg-surface-950 flex-auto flex justify-center items-center font-medium">Content III</div>
</div>
<div class="pt-6">
<Button label="Back" severity="secondary" icon="pi pi-arrow-left" />
</div>
</StepPanel>
</StepPanels>
</Stepper>
</DocPTViewer>
</template>
<script>
import { getPTOptions } from '@/components/doc/helpers';
export default {
data() {
return {
docs: [
{
data: getPTOptions('Stepper'),
key: 'Stepper'
},
{
data: getPTOptions('StepList'),
key: 'StepList'
},
{
data: getPTOptions('Step'),
key: 'Step'
},
{
data: getPTOptions('StepPanels'),
key: 'StepPanels'
},
{
data: getPTOptions('StepPanel'),
key: 'StepPanel'
}
]
};
}
};
</script>

View File

@ -11,16 +11,16 @@
<script> <script>
import DocApiTable from '@/components/doc/DocApiTable.vue'; import DocApiTable from '@/components/doc/DocApiTable.vue';
import { getPTOptions } from '@/components/doc/helpers'; import { getPTOptions } from '@/components/doc/helpers';
import PTImage from './PTImage.vue'; import PTViewer from './PTViewer.vue';
export default { export default {
data() { data() {
return { return {
docs: [ docs: [
{ {
id: 'pt.image', id: 'pt.viewer',
label: 'Wireframe', label: 'Viewer',
component: PTImage component: PTViewer
}, },
{ {
id: 'pt.doc.stepper', id: 'pt.doc.stepper',

View File

@ -11,16 +11,16 @@
<script> <script>
import DocApiTable from '@/components/doc/DocApiTable.vue'; import DocApiTable from '@/components/doc/DocApiTable.vue';
import { getPTOptions } from '@/components/doc/helpers'; import { getPTOptions } from '@/components/doc/helpers';
import PTImage from './PTImage.vue'; import PTViewer from './PTViewer.vue';
export default { export default {
data() { data() {
return { return {
docs: [ docs: [
{ {
id: 'pt.image', id: 'pt.viewer',
label: 'Wireframe', label: 'Viewer',
component: PTImage component: PTViewer
}, },
{ {
id: 'pt.doc.tabs', id: 'pt.doc.tabs',

View File

@ -1,8 +0,0 @@
<template>
<DocSectionText v-bind="$attrs">
<p>{{ $attrs.description }}</p>
</DocSectionText>
<div class="card">
<img class="w-full" src="https://primefaces.org/cdn/primevue/images/pt/toolbar.jpg" />
</div>
</template>

View File

@ -0,0 +1,40 @@
<template>
<DocSectionText v-bind="$attrs" />
<DocPTViewer :docs="docs">
<Toolbar class="w-full">
<template #start>
<Button icon="pi pi-plus" class="mr-2" severity="secondary" text />
<Button icon="pi pi-print" class="mr-2" severity="secondary" text />
<Button icon="pi pi-upload" severity="secondary" text />
</template>
<template #center>
<IconField>
<InputIcon>
<i class="pi pi-search" />
</InputIcon>
<InputText placeholder="Search" />
</IconField>
</template>
<template #end> <Button label="Save"></Button></template>
</Toolbar>
</DocPTViewer>
</template>
<script>
import { getPTOptions } from '@/components/doc/helpers';
export default {
data() {
return {
docs: [
{
data: getPTOptions('Toolbar'),
key: 'Toolbar'
}
]
};
}
};
</script>

View File

@ -11,16 +11,16 @@
<script> <script>
import DocApiTable from '@/components/doc/DocApiTable.vue'; import DocApiTable from '@/components/doc/DocApiTable.vue';
import { getPTOptions } from '@/components/doc/helpers'; import { getPTOptions } from '@/components/doc/helpers';
import PTImage from './PTImage.vue'; import PTViewer from './PTViewer.vue';
export default { export default {
data() { data() {
return { return {
docs: [ docs: [
{ {
id: 'pt.image', id: 'pt.viewer',
label: 'Wireframe', label: 'Viewer',
component: PTImage component: PTViewer
}, },
{ {
id: 'pt.doc.toolbar', id: 'pt.doc.toolbar',