Refactor on Base* structure
parent
8f49edbe14
commit
5b1d3f89c3
|
@ -21,7 +21,7 @@ export default {
|
||||||
},
|
},
|
||||||
invalid: {
|
invalid: {
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
default: false
|
default: undefined
|
||||||
},
|
},
|
||||||
disabled: {
|
disabled: {
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
|
@ -80,7 +80,7 @@ export default {
|
||||||
return isNotEmpty(this.d_value);
|
return isNotEmpty(this.d_value);
|
||||||
},
|
},
|
||||||
$invalid() {
|
$invalid() {
|
||||||
return this.invalid || this.$pcForm?.states?.[this.$formName]?.invalid;
|
return this.invalid ?? this.$pcForm?.states?.[this.$formName]?.invalid;
|
||||||
},
|
},
|
||||||
$formName() {
|
$formName() {
|
||||||
return this.formControl?.name || this.name || this.$attrs.name;
|
return this.formControl?.name || this.name || this.$attrs.name;
|
||||||
|
|
|
@ -28,7 +28,7 @@ export default {
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
$variant() {
|
$variant() {
|
||||||
return this.variant || this.$primevue.config.inputStyle || this.$primevue.config.inputVariant;
|
return this.variant ?? (this.$primevue.config.inputStyle || this.$primevue.config.inputVariant);
|
||||||
},
|
},
|
||||||
$fluid() {
|
$fluid() {
|
||||||
return this.fluid ?? !!this.$pcFluid;
|
return this.fluid ?? !!this.$pcFluid;
|
||||||
|
|
Loading…
Reference in New Issue