refactor: #7090 for Stepper
parent
4a3306b97e
commit
60c596db96
|
@ -7,7 +7,6 @@
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { UniqueComponentId } from '@primevue/core/utils';
|
|
||||||
import BaseStepper from './BaseStepper.vue';
|
import BaseStepper from './BaseStepper.vue';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
@ -17,21 +16,14 @@ export default {
|
||||||
emits: ['update:value'],
|
emits: ['update:value'],
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
id: this.$attrs.id,
|
|
||||||
d_value: this.value
|
d_value: this.value
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
'$attrs.id'(newValue) {
|
|
||||||
this.id = newValue || UniqueComponentId();
|
|
||||||
},
|
|
||||||
value(newValue) {
|
value(newValue) {
|
||||||
this.d_value = newValue;
|
this.d_value = newValue;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
|
||||||
this.id = this.id || UniqueComponentId();
|
|
||||||
},
|
|
||||||
methods: {
|
methods: {
|
||||||
updateValue(newValue) {
|
updateValue(newValue) {
|
||||||
if (this.d_value !== newValue) {
|
if (this.d_value !== newValue) {
|
||||||
|
|
Loading…
Reference in New Issue