mirror of
https://github.com/primefaces/primevue.git
synced 2025-05-09 00:42:36 +00:00
Refactor #5176 - invalid property added
This commit is contained in:
parent
b42c9eb7ee
commit
a9a254915c
54 changed files with 198 additions and 12 deletions
|
@ -18,6 +18,10 @@ export default {
|
|||
type: null,
|
||||
default: false
|
||||
},
|
||||
invalid: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
disabled: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
|
|
5
components/lib/inputswitch/InputSwitch.d.ts
vendored
5
components/lib/inputswitch/InputSwitch.d.ts
vendored
|
@ -105,6 +105,11 @@ export interface InputSwitchProps {
|
|||
* @defaultValue false
|
||||
*/
|
||||
falseValue?: any;
|
||||
/**
|
||||
* When present, it specifies that the component should have invalid state style.
|
||||
* @defaultValue false
|
||||
*/
|
||||
invalid?: boolean | undefined;
|
||||
/**
|
||||
* When present, it specifies that the component should be disabled.
|
||||
* @defaultValue false
|
||||
|
|
|
@ -37,7 +37,8 @@ const classes = {
|
|||
'p-inputswitch p-component',
|
||||
{
|
||||
'p-highlight': instance.checked,
|
||||
'p-disabled': props.disabled
|
||||
'p-disabled': props.disabled,
|
||||
'p-invalid': props.invalid
|
||||
}
|
||||
],
|
||||
input: 'p-inputswitch-input',
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue