mirror of
https://github.com/primefaces/primevue.git
synced 2025-05-10 09:22:34 +00:00
MeterGroup demo updates
This commit is contained in:
parent
8274c1c936
commit
2f7ef11751
6 changed files with 99 additions and 36 deletions
66
doc/metergroup/MultipleDoc.vue
Normal file
66
doc/metergroup/MultipleDoc.vue
Normal file
|
@ -0,0 +1,66 @@
|
|||
<template>
|
||||
<DocSectionText v-bind="$attrs">
|
||||
<p>MeterGroup is used with the <i>value</i> property.</p>
|
||||
</DocSectionText>
|
||||
<div class="card">
|
||||
<MeterGroup :value="value" />
|
||||
</div>
|
||||
<DocSectionCode :code="code" />
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
value: [
|
||||
{ color: '#239EF0', label: 'Mortgage', value: 25 },
|
||||
{ color: '#FAA419', label: 'Loan', value: 15 },
|
||||
{ color: '#EE5879', label: 'Credit Card', value: 20 }
|
||||
],
|
||||
code: {
|
||||
basic: `
|
||||
<MeterGroup :value="value" />
|
||||
`,
|
||||
options: `
|
||||
<template>
|
||||
<div class="card">
|
||||
<MeterGroup :value="value" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
value: [
|
||||
{ color: '#239EF0', label: 'Mortgage', value: 25 },
|
||||
{ color: '#FAA419', label: 'Loan', value: 15 },
|
||||
{ color: '#EE5879', label: 'Credit Card', value: 20 }
|
||||
]
|
||||
};
|
||||
}
|
||||
};
|
||||
<\/script>
|
||||
`,
|
||||
composition: `
|
||||
<template>
|
||||
<div class="card">
|
||||
<MeterGroup :value="value" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { ref } from "vue";
|
||||
|
||||
const value = ref([
|
||||
{ color: '#239EF0', label: 'Mortgage', value: 25 },
|
||||
{ color: '#FAA419', label: 'Loan', value: 15 },
|
||||
{ color: '#EE5879', label: 'Credit Card', value: 20 }
|
||||
]);
|
||||
<\/script>
|
||||
`
|
||||
}
|
||||
};
|
||||
}
|
||||
};
|
||||
</script>
|
Loading…
Add table
Add a link
Reference in a new issue