Password pt demo added

pull/3938/head
Tuğçe Küçükoğlu 2023-05-05 18:01:38 +03:00
parent fe219d631a
commit 26cbc4dc4c
4 changed files with 110 additions and 3 deletions

56
doc/password/pt/PTDoc.vue Normal file
View File

@ -0,0 +1,56 @@
<template>
<DocSectionText v-bind="$attrs">
<p>Strength meter is displayed as a popup while a value is being entered.</p>
</DocSectionText>
<div class="card flex justify-content-center">
<Password
v-model="value"
:pt="{
info: { class: 'font-bold' }
}"
/>
</div>
<DocSectionCode :code="code" />
</template>
<script>
export default {
data() {
return {
value: null,
code: {
basic: `
<Password v-model="value" />`,
options: `
<template>
<div class="card flex justify-content-center">
<Password v-model="value" />
</div>
</template>
<script>
export default {
data() {
return {
value: null
}
}
};
<\/script>`,
composition: `
<template>
<div class="card flex justify-content-center">
<Password v-model="value" />
</div>
</template>
<script setup>
import { ref } from 'vue';
const value = ref(null);
<\/script>`
}
};
}
};
</script>

View File

@ -0,0 +1,8 @@
<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>

41
doc/password/pt/index.vue Normal file
View File

@ -0,0 +1,41 @@
<template>
<div class="doc-main">
<div class="doc-intro">
<h1>Password Pass Through</h1>
</div>
<DocSections :docs="docs" />
</div>
<DocSectionNav :docs="docs" />
</template>
<script>
import DocApiTable from '@/components/doc/DocApiTable.vue';
import { getPTOption } from '@/components/doc/helpers/PTHelper.js';
import PtDoc from './PTDoc.vue';
import PTImage from './PTImage.vue';
export default {
data() {
return {
docs: [
{
id: 'pt.image',
label: 'Wireframe',
component: PTImage
},
{
id: 'pt.doc.password',
label: 'Password PT Options',
component: DocApiTable,
data: getPTOption('Password')
},
{
id: 'pt.demo',
label: 'Demo',
component: PtDoc
}
]
};
}
};
</script>

View File

@ -1,5 +1,5 @@
<template>
<DocComponent title="Vue Password Component" header="Password" description="Password displays strength indicator for password fields." :componentDocs="docs" :apiDocs="['Password']" />
<DocComponent title="Vue Password Component" header="Password" description="Password displays strength indicator for password fields." :componentDocs="docs" :apiDocs="['Password']" :ptTabComponent="ptComponent" />
</template>
<script>
@ -7,7 +7,6 @@ import AccessibilityDoc from '@/doc/password/AccessibilityDoc.vue';
import BasicDoc from '@/doc/password/BasicDoc.vue';
import DisabledDoc from '@/doc/password/DisabledDoc.vue';
import FloatLabelDoc from '@/doc/password/FloatLabelDoc.vue';
import VeeValidateDoc from '@/doc/password/form/VeeValidateDoc.vue';
import ImportDoc from '@/doc/password/ImportDoc.vue';
import InvalidDoc from '@/doc/password/InvalidDoc.vue';
import LocaleDoc from '@/doc/password/LocaleDoc.vue';
@ -15,6 +14,8 @@ import MeterDoc from '@/doc/password/MeterDoc.vue';
import StyleDoc from '@/doc/password/StyleDoc.vue';
import TemplateDoc from '@/doc/password/TemplateDoc.vue';
import ToggleMaskDoc from '@/doc/password/ToggleMaskDoc.vue';
import VeeValidateDoc from '@/doc/password/form/VeeValidateDoc.vue';
import PTComponent from '@/doc/password/pt/index.vue';
export default {
data() {
@ -87,7 +88,8 @@ export default {
label: 'Accessibility',
component: AccessibilityDoc
}
]
],
ptComponent: PTComponent
};
}
};