tiny-vue/examples/sites/demos/pc/app/currency/size-composition-api.vue

35 lines
937 B
Vue
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<template>
<div class="demo-currency-class">
<tiny-currency v-model="value" size="medium" placeholder="请选择" @change="change"></tiny-currency>
<br /><br />
<tiny-currency v-model="value" placeholder="请选择" @change="change"></tiny-currency>
<br /><br />
<tiny-currency v-model="value" size="small" placeholder="请选择" @change="change"></tiny-currency>
<br /><br />
<tiny-currency v-model="value" size="mini" placeholder="请选择" @change="change"></tiny-currency>
<p>当前选中值{{ value }}</p>
</div>
</template>
<script setup>
import { ref } from 'vue'
import { TinyCurrency, TinyModal } from '@opentiny/vue'
const value = ref('VUV')
function change(value) {
TinyModal.message({ message: `当前值为 ${value}`, status: 'info' })
}
</script>
<style scoped>
.demo-currency-class {
width: 280px;
}
p {
font-size: 14px;
line-height: 1.5;
padding: 16px 0;
}
</style>