primevue-mirror/doc/inputnumber/pt/PTDoc.vue

105 lines
2.5 KiB
Vue
Raw Normal View History

2023-05-05 12:57:15 +00:00
<template>
<DocSectionText v-bind="$attrs"></DocSectionText>
<div class="card flex justify-content-center">
<InputNumber
v-model="value"
showButtons
buttonLayout="horizontal"
:step="0.25"
incrementButtonIcon="pi pi-plus"
decrementButtonIcon="pi pi-minus"
mode="currency"
currency="EUR"
:pt="{
incrementButton: { class: 'bg-teal-500 border-teal-500' },
decrementButton: { class: 'bg-orange-500 border-orange-500' }
}"
/>
</div>
<DocSectionCode :code="code" />
</template>
<script>
export default {
data() {
return {
value: 20,
code: {
2023-09-22 12:54:14 +00:00
basic: `
<InputNumber
2023-05-05 12:57:15 +00:00
v-model="value"
showButtons
buttonLayout="horizontal"
:step="0.25"
incrementButtonIcon="pi pi-plus"
decrementButtonIcon="pi pi-minus"
mode="currency"
currency="EUR"
:pt="{
incrementButton: { class: 'bg-teal-500 border-teal-500' },
decrementButton: { class: 'bg-orange-500 border-orange-500' }
}"
2023-10-15 09:38:39 +00:00
/>
`,
2023-09-22 12:54:14 +00:00
options: `
<template>
2023-05-05 12:57:15 +00:00
<div class="card flex justify-content-center">
<InputNumber
v-model="value"
showButtons
buttonLayout="horizontal"
:step="0.25"
incrementButtonIcon="pi pi-plus"
decrementButtonIcon="pi pi-minus"
mode="currency"
currency="EUR"
:pt="{
incrementButton: { class: 'bg-teal-500 border-teal-500' },
decrementButton: { class: 'bg-orange-500 border-orange-500' }
}"
/>
</div>
</template>
<script>
export default {
data() {
return {
value: 20
};
}
};
2023-10-15 09:38:39 +00:00
<\/script>
`,
2023-09-22 12:54:14 +00:00
composition: `
<template>
2023-05-05 12:57:15 +00:00
<div class="card flex justify-content-center">
<InputNumber
v-model="value"
showButtons
buttonLayout="horizontal"
:step="0.25"
incrementButtonIcon="pi pi-plus"
decrementButtonIcon="pi pi-minus"
mode="currency"
currency="EUR"
:pt="{
incrementButton: { class: 'bg-teal-500 border-teal-500' },
decrementButton: { class: 'bg-orange-500 border-orange-500' }
}"
/>
</div>
</template>
<script setup>
import { ref } from "vue";
const value = ref(20);
2023-10-15 09:38:39 +00:00
<\/script>
`
2023-05-05 12:57:15 +00:00
}
};
}
};
</script>