@govtechsg/sgds-web-component 3.0.4 → 3.0.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Masthead/index.js +11 -2
- package/components/Card/index.umd.js +2 -2
- package/components/Card/index.umd.js.map +1 -1
- package/components/Card/sgds-card.d.ts +1 -1
- package/components/Card/sgds-card.js +2 -2
- package/components/Card/sgds-card.js.map +1 -1
- package/components/Datepicker/index.umd.js +1 -10
- package/components/Datepicker/index.umd.js.map +1 -1
- package/components/Input/index.umd.js +1 -10
- package/components/Input/index.umd.js.map +1 -1
- package/components/Input/sgds-input.d.ts +0 -2
- package/components/Input/sgds-input.js +1 -10
- package/components/Input/sgds-input.js.map +1 -1
- package/components/Masthead/index.umd.js +11 -2
- package/components/Masthead/index.umd.js.map +1 -1
- package/components/Masthead/masthead.js +1 -1
- package/components/Masthead/sgds-masthead.d.ts +2 -0
- package/components/Masthead/sgds-masthead.js +10 -1
- package/components/Masthead/sgds-masthead.js.map +1 -1
- package/components/QuantityToggle/index.umd.js +1 -10
- package/components/QuantityToggle/index.umd.js.map +1 -1
- package/components/index.umd.js +14 -14
- package/components/index.umd.js.map +1 -1
- package/css/grid.css +55 -16
- package/index.umd.js +14 -14
- package/index.umd.js.map +1 -1
- package/package.json +1 -4
- package/react/components/Card/sgds-card.cjs.js +2 -2
- package/react/components/Card/sgds-card.cjs.js.map +1 -1
- package/react/components/Card/sgds-card.js +2 -2
- package/react/components/Card/sgds-card.js.map +1 -1
- package/react/components/Input/sgds-input.cjs.js +1 -10
- package/react/components/Input/sgds-input.cjs.js.map +1 -1
- package/react/components/Input/sgds-input.js +1 -10
- package/react/components/Input/sgds-input.js.map +1 -1
- package/react/components/Masthead/masthead.cjs.js +1 -1
- package/react/components/Masthead/masthead.js +1 -1
- package/react/components/Masthead/sgds-masthead.cjs.js +10 -1
- package/react/components/Masthead/sgds-masthead.cjs.js.map +1 -1
- package/react/components/Masthead/sgds-masthead.js +10 -1
- package/react/components/Masthead/sgds-masthead.js.map +1 -1
- package/themes/root.css +17 -6
|
@@ -5144,16 +5144,6 @@
|
|
|
5144
5144
|
blur() {
|
|
5145
5145
|
this.input.blur();
|
|
5146
5146
|
}
|
|
5147
|
-
/** Programatically sets the invalid state of the input. Pass in boolean value in the argument */
|
|
5148
|
-
setInvalid(bool) {
|
|
5149
|
-
this.invalid = bool;
|
|
5150
|
-
if (bool) {
|
|
5151
|
-
this.emit("sgds-invalid");
|
|
5152
|
-
}
|
|
5153
|
-
else {
|
|
5154
|
-
this.emit("sgds-valid");
|
|
5155
|
-
}
|
|
5156
|
-
}
|
|
5157
5147
|
/**
|
|
5158
5148
|
* Checks for validity. Under the hood, HTMLFormElement's reportValidity method calls this method to check for component's validity state
|
|
5159
5149
|
* Note that the native error popup is prevented for SGDS form components by default. Instead the validation message shows up in the feedback container of SgdsInput
|
|
@@ -5190,6 +5180,7 @@
|
|
|
5190
5180
|
}
|
|
5191
5181
|
_handleBlur() {
|
|
5192
5182
|
const sgdsBlur = this.emit("sgds-blur", { cancelable: true });
|
|
5183
|
+
this.setInvalid(!this._mixinCheckValidity());
|
|
5193
5184
|
if (sgdsBlur.defaultPrevented)
|
|
5194
5185
|
return;
|
|
5195
5186
|
this._isTouched = true;
|