@dfds-ui/forms 2.0.29 → 2.2.0-alpha.32eece3d
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/assistive-text/AssistiveText.d.ts +1 -1
- package/asterisk/Asterisk.d.ts +2 -2
- package/asterisk/Asterisk.js +2 -2
- package/checkbox/Checkbox.js +3 -3
- package/checkbox/CheckboxContext.d.ts +1 -0
- package/checkbox/CheckboxGroup.d.ts +2 -2
- package/checkbox/CheckboxGroup.js +3 -3
- package/cjs/assistive-text/AssistiveText.d.ts +1 -1
- package/cjs/assistive-text/AssistiveText.js +1 -1
- package/cjs/asterisk/Asterisk.d.ts +2 -2
- package/cjs/asterisk/Asterisk.js +5 -5
- package/cjs/checkbox/Checkbox.js +19 -24
- package/cjs/checkbox/CheckboxContext.d.ts +1 -0
- package/cjs/checkbox/CheckboxContext.js +1 -2
- package/cjs/checkbox/CheckboxGroup.d.ts +2 -2
- package/cjs/checkbox/CheckboxGroup.js +16 -21
- package/cjs/checkbox/index.js +2 -2
- package/cjs/counter/Counter.js +32 -46
- package/cjs/counter/index.js +1 -1
- package/cjs/enhanced/EnhancedField.d.ts +1 -1
- package/cjs/enhanced/EnhancedField.js +14 -15
- package/cjs/enhanced/index.js +1 -1
- package/cjs/error-text/ErrorText.d.ts +1 -1
- package/cjs/error-text/ErrorText.js +1 -1
- package/cjs/field-wrap/FieldWrap.d.ts +2 -2
- package/cjs/field-wrap/FieldWrap.js +2 -2
- package/cjs/field-wrap/index.js +1 -1
- package/cjs/help-icon/HelpIcon.d.ts +2 -2
- package/cjs/help-icon/HelpIcon.js +1 -1
- package/cjs/index.js +19 -19
- package/cjs/label/Label.d.ts +1 -1
- package/cjs/label/Label.js +11 -17
- package/cjs/password-field/PasswordField.js +4 -14
- package/cjs/radio/Radio.js +17 -21
- package/cjs/radio/RadioContext.d.ts +1 -0
- package/cjs/radio/RadioContext.js +1 -2
- package/cjs/radio/RadioGroup.d.ts +2 -2
- package/cjs/radio/RadioGroup.js +1 -1
- package/cjs/radio/index.js +2 -2
- package/cjs/rating/Rating.d.ts +1 -1
- package/cjs/rating/Rating.js +5 -15
- package/cjs/rating/index.js +1 -1
- package/cjs/select-field/AsyncSelectField.d.ts +88 -80
- package/cjs/select-field/AsyncSelectField.js +21 -26
- package/cjs/select-field/CreatableSelectField.d.ts +89 -81
- package/cjs/select-field/CreatableSelectField.js +56 -63
- package/cjs/select-field/NativeSelectField.d.ts +1 -1
- package/cjs/select-field/NativeSelectField.js +18 -23
- package/cjs/select-field/SelectField.d.ts +4 -4
- package/cjs/select-field/SelectField.js +57 -66
- package/cjs/switch/Switch.d.ts +1 -1
- package/cjs/switch/Switch.js +26 -31
- package/cjs/switch/SwitchContext.d.ts +1 -0
- package/cjs/switch/SwitchContext.js +1 -2
- package/cjs/switch/SwitchGroup.d.ts +2 -2
- package/cjs/switch/SwitchGroup.js +1 -1
- package/cjs/switch/index.js +2 -2
- package/cjs/tel-field/TelField.js +32 -55
- package/cjs/text-field/TextField.d.ts +2 -2
- package/cjs/text-field/TextField.js +34 -41
- package/cjs/textarea-field/TextareaField.js +23 -39
- package/cjs/types/index.js +2 -2
- package/counter/Counter.js +7 -7
- package/enhanced/EnhancedField.d.ts +1 -1
- package/enhanced/EnhancedField.js +3 -3
- package/error-text/ErrorText.d.ts +1 -1
- package/field-wrap/FieldWrap.d.ts +2 -2
- package/field-wrap/FieldWrap.js +1 -1
- package/help-icon/HelpIcon.d.ts +2 -2
- package/label/Label.d.ts +1 -1
- package/label/Label.js +3 -3
- package/package.json +9 -9
- package/password-field/PasswordField.js +5 -5
- package/radio/Radio.js +4 -4
- package/radio/RadioContext.d.ts +1 -0
- package/radio/RadioGroup.d.ts +2 -2
- package/rating/Rating.d.ts +1 -1
- package/rating/Rating.js +8 -8
- package/select-field/AsyncSelectField.d.ts +88 -80
- package/select-field/AsyncSelectField.js +4 -4
- package/select-field/CreatableSelectField.d.ts +89 -81
- package/select-field/CreatableSelectField.js +6 -6
- package/select-field/NativeSelectField.d.ts +1 -1
- package/select-field/NativeSelectField.js +3 -3
- package/select-field/SelectField.d.ts +4 -4
- package/select-field/SelectField.js +6 -6
- package/switch/Switch.d.ts +1 -1
- package/switch/Switch.js +20 -20
- package/switch/SwitchContext.d.ts +1 -0
- package/switch/SwitchGroup.d.ts +2 -2
- package/tel-field/TelField.js +8 -8
- package/text-field/TextField.d.ts +2 -2
- package/text-field/TextField.js +3 -3
- package/textarea-field/TextareaField.js +7 -7
|
@@ -41,88 +41,96 @@ export declare type CreatableSelectFieldProps<Option, IsMulti extends boolean, G
|
|
|
41
41
|
value?: SingleValue<Option> | MultiValue<Option>;
|
|
42
42
|
visualSize?: Size;
|
|
43
43
|
};
|
|
44
|
-
declare const CreatableSelectFieldInner: <Option, IsMulti extends boolean, Group extends GroupBase<Option>>({ assistiveText, components, defaultValue, disabled, errorMessage, filterConfig, help, helpPlacement, hideAsterisk, isClearable, isMulti, isSearchable, label, name, onBlur, onChange, onSelect, options, placeholder, required, styles, value, visualSize, ...rest }: CreatableSelectFieldProps<Option, IsMulti, Group>, ref: React.ForwardedRef<any>) => JSX.Element;
|
|
45
|
-
export declare const CreatableSelectField: <Option, IsMulti extends boolean, Group extends GroupBase<Option>>(props: BaseFieldProps & Omit<Pick<import("react-select/dist/declarations/src/Select").Props<Option, IsMulti, Group>, "id" | "
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
44
|
+
declare const CreatableSelectFieldInner: <Option, IsMulti extends boolean, Group extends GroupBase<Option>>({ assistiveText, components, defaultValue, disabled, errorMessage, filterConfig, help, helpPlacement, hideAsterisk, isClearable, isMulti, isSearchable, label, name, onBlur, onChange, onSelect, options, placeholder, required, styles, value, visualSize, ...rest }: CreatableSelectFieldProps<Option, IsMulti, Group>, ref: React.ForwardedRef<any>) => React.JSX.Element;
|
|
45
|
+
export declare const CreatableSelectField: <Option, IsMulti extends boolean, Group extends GroupBase<Option>>(props: BaseFieldProps & Omit<Pick<import("react-select/dist/declarations/src/Select").Props<Option, IsMulti, Group>, "id" | "className" | "value" | "form" | "autoFocus" | "aria-errormessage" | "aria-invalid" | "aria-label" | "aria-labelledby" | "onFocus" | "onBlur" | "onChange" | "onKeyDown" | "theme" | "name" | "ariaLiveMessages" | "classNamePrefix" | "delimiter" | "formatOptionLabel" | "hideSelectedOptions" | "inputValue" | "inputId" | "instanceId" | "isClearable" | "isOptionSelected" | "menuPortalTarget" | "onInputChange" | "onMenuOpen" | "onMenuClose" | "onMenuScrollToTop" | "onMenuScrollToBottom"> & {
|
|
46
|
+
tabIndex?: number | undefined;
|
|
47
|
+
'aria-live'?: "off" | "assertive" | "polite" | undefined;
|
|
48
|
+
placeholder?: React.ReactNode;
|
|
49
|
+
backspaceRemovesValue?: boolean | undefined;
|
|
50
|
+
blurInputOnSelect?: boolean | undefined;
|
|
51
|
+
captureMenuScroll?: boolean | undefined;
|
|
52
|
+
closeMenuOnSelect?: boolean | undefined;
|
|
53
|
+
closeMenuOnScroll?: boolean | ((event: Event) => boolean) | undefined;
|
|
54
|
+
components?: Partial<import("react-select/dist/declarations/src/components").SelectComponents<Option, IsMulti, Group>> | undefined;
|
|
55
|
+
controlShouldRenderValue?: boolean | undefined;
|
|
56
|
+
escapeClearsValue?: boolean | undefined;
|
|
57
|
+
filterOption?: ((option: import("react-select/dist/declarations/src/filters").FilterOptionOption<Option>, inputValue: string) => boolean) | null | undefined;
|
|
58
|
+
formatGroupLabel?: ((group: Group) => React.ReactNode) | undefined;
|
|
59
|
+
getOptionLabel?: import("react-select").GetOptionLabel<Option> | undefined;
|
|
60
|
+
getOptionValue?: import("react-select").GetOptionValue<Option> | undefined;
|
|
61
|
+
isDisabled?: boolean | undefined;
|
|
62
|
+
isLoading?: boolean | undefined;
|
|
63
|
+
isOptionDisabled?: ((option: Option, selectValue: import("react-select").Options<Option>) => boolean) | undefined;
|
|
64
|
+
isMulti?: IsMulti | undefined;
|
|
65
|
+
isRtl?: boolean | undefined;
|
|
66
|
+
isSearchable?: boolean | undefined;
|
|
67
|
+
loadingMessage?: ((obj: {
|
|
68
|
+
inputValue: string;
|
|
69
|
+
}) => React.ReactNode) | undefined;
|
|
70
|
+
minMenuHeight?: number | undefined;
|
|
71
|
+
maxMenuHeight?: number | undefined;
|
|
72
|
+
menuIsOpen?: boolean | undefined;
|
|
73
|
+
menuPlacement?: import("react-select").MenuPlacement | undefined;
|
|
74
|
+
menuPosition?: import("react-select").MenuPosition | undefined;
|
|
75
|
+
menuShouldBlockScroll?: boolean | undefined;
|
|
76
|
+
menuShouldScrollIntoView?: boolean | undefined;
|
|
77
|
+
noOptionsMessage?: ((obj: {
|
|
78
|
+
inputValue: string;
|
|
79
|
+
}) => React.ReactNode) | undefined;
|
|
80
|
+
openMenuOnFocus?: boolean | undefined;
|
|
81
|
+
openMenuOnClick?: boolean | undefined;
|
|
82
|
+
options?: OptionsOrGroups<Option, Group> | undefined;
|
|
83
|
+
pageSize?: number | undefined;
|
|
84
|
+
screenReaderStatus?: ((obj: {
|
|
80
85
|
count: number;
|
|
81
|
-
}) => string;
|
|
82
|
-
styles
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
'aria-live'
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
86
|
+
}) => string) | undefined;
|
|
87
|
+
styles?: import("react-select").StylesConfig<Option, IsMulti, Group> | undefined;
|
|
88
|
+
tabSelectsValue?: boolean | undefined;
|
|
89
|
+
} & {}, "value" | "onChange" | "inputValue" | "menuIsOpen" | "onInputChange" | "onMenuOpen" | "onMenuClose"> & Partial<Pick<import("react-select/dist/declarations/src/Select").Props<Option, IsMulti, Group>, "id" | "className" | "value" | "form" | "autoFocus" | "aria-errormessage" | "aria-invalid" | "aria-label" | "aria-labelledby" | "onFocus" | "onBlur" | "onChange" | "onKeyDown" | "theme" | "name" | "ariaLiveMessages" | "classNamePrefix" | "delimiter" | "formatOptionLabel" | "hideSelectedOptions" | "inputValue" | "inputId" | "instanceId" | "isClearable" | "isOptionSelected" | "menuPortalTarget" | "onInputChange" | "onMenuOpen" | "onMenuClose" | "onMenuScrollToTop" | "onMenuScrollToBottom"> & {
|
|
90
|
+
tabIndex?: number | undefined;
|
|
91
|
+
'aria-live'?: "off" | "assertive" | "polite" | undefined;
|
|
92
|
+
placeholder?: React.ReactNode;
|
|
93
|
+
backspaceRemovesValue?: boolean | undefined;
|
|
94
|
+
blurInputOnSelect?: boolean | undefined;
|
|
95
|
+
captureMenuScroll?: boolean | undefined;
|
|
96
|
+
closeMenuOnSelect?: boolean | undefined;
|
|
97
|
+
closeMenuOnScroll?: boolean | ((event: Event) => boolean) | undefined;
|
|
98
|
+
components?: Partial<import("react-select/dist/declarations/src/components").SelectComponents<Option, IsMulti, Group>> | undefined;
|
|
99
|
+
controlShouldRenderValue?: boolean | undefined;
|
|
100
|
+
escapeClearsValue?: boolean | undefined;
|
|
101
|
+
filterOption?: ((option: import("react-select/dist/declarations/src/filters").FilterOptionOption<Option>, inputValue: string) => boolean) | null | undefined;
|
|
102
|
+
formatGroupLabel?: ((group: Group) => React.ReactNode) | undefined;
|
|
103
|
+
getOptionLabel?: import("react-select").GetOptionLabel<Option> | undefined;
|
|
104
|
+
getOptionValue?: import("react-select").GetOptionValue<Option> | undefined;
|
|
105
|
+
isDisabled?: boolean | undefined;
|
|
106
|
+
isLoading?: boolean | undefined;
|
|
107
|
+
isOptionDisabled?: ((option: Option, selectValue: import("react-select").Options<Option>) => boolean) | undefined;
|
|
108
|
+
isMulti?: IsMulti | undefined;
|
|
109
|
+
isRtl?: boolean | undefined;
|
|
110
|
+
isSearchable?: boolean | undefined;
|
|
111
|
+
loadingMessage?: ((obj: {
|
|
112
|
+
inputValue: string;
|
|
113
|
+
}) => React.ReactNode) | undefined;
|
|
114
|
+
minMenuHeight?: number | undefined;
|
|
115
|
+
maxMenuHeight?: number | undefined;
|
|
116
|
+
menuIsOpen?: boolean | undefined;
|
|
117
|
+
menuPlacement?: import("react-select").MenuPlacement | undefined;
|
|
118
|
+
menuPosition?: import("react-select").MenuPosition | undefined;
|
|
119
|
+
menuShouldBlockScroll?: boolean | undefined;
|
|
120
|
+
menuShouldScrollIntoView?: boolean | undefined;
|
|
121
|
+
noOptionsMessage?: ((obj: {
|
|
122
|
+
inputValue: string;
|
|
123
|
+
}) => React.ReactNode) | undefined;
|
|
124
|
+
openMenuOnFocus?: boolean | undefined;
|
|
125
|
+
openMenuOnClick?: boolean | undefined;
|
|
126
|
+
options?: OptionsOrGroups<Option, Group> | undefined;
|
|
127
|
+
pageSize?: number | undefined;
|
|
128
|
+
screenReaderStatus?: ((obj: {
|
|
120
129
|
count: number;
|
|
121
|
-
}) => string;
|
|
122
|
-
styles
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
}, never>>> & import("react-select/dist/declarations/src/useStateManager").StateManagerAdditionalProps<Option> & import("react-select/dist/declarations/src/useCreatable").CreatableAdditionalProps<Option, Group> & {
|
|
130
|
+
}) => string) | undefined;
|
|
131
|
+
styles?: import("react-select").StylesConfig<Option, IsMulti, Group> | undefined;
|
|
132
|
+
tabSelectsValue?: boolean | undefined;
|
|
133
|
+
} & {}> & import("react-select/dist/declarations/src/useStateManager").StateManagerAdditionalProps<Option> & import("react-select/dist/declarations/src/useCreatable").CreatableAdditionalProps<Option, Group> & {
|
|
126
134
|
assistiveText?: string | undefined;
|
|
127
135
|
autoFocus?: boolean | undefined;
|
|
128
136
|
className?: string | undefined;
|
|
@@ -148,7 +156,7 @@ export declare const CreatableSelectField: <Option, IsMulti extends boolean, Gro
|
|
|
148
156
|
isMulti?: boolean | undefined;
|
|
149
157
|
isSearchable?: boolean | undefined;
|
|
150
158
|
menuIsOpen?: boolean | undefined;
|
|
151
|
-
menuPlacement?: "
|
|
159
|
+
menuPlacement?: "top" | "bottom" | "auto" | undefined;
|
|
152
160
|
onBlur?: ((value: any) => void) | undefined;
|
|
153
161
|
onChange?: ((newValue: MultiValue<Option> | SingleValue<Option>, actionMeta: ActionMeta<Option>) => void) | undefined;
|
|
154
162
|
onSelect?: ((value: MultiValue<Option> | SingleValue<Option>) => void) | undefined;
|
|
@@ -5,14 +5,14 @@ var _excluded = ["assistiveText", "components", "defaultValue", "disabled", "err
|
|
|
5
5
|
var _templateObject;
|
|
6
6
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
7
7
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
8
|
-
function _defineProperty(
|
|
8
|
+
function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
|
|
9
9
|
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
|
|
10
10
|
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
11
|
-
function _objectDestructuringEmpty(
|
|
12
|
-
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (
|
|
13
|
-
function _objectWithoutProperties(
|
|
14
|
-
function _objectWithoutPropertiesLoose(
|
|
15
|
-
function _taggedTemplateLiteral(
|
|
11
|
+
function _objectDestructuringEmpty(t) { if (null == t) throw new TypeError("Cannot destructure " + t); }
|
|
12
|
+
function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) { ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } } return n; }, _extends.apply(null, arguments); }
|
|
13
|
+
function _objectWithoutProperties(e, t) { if (null == e) return {}; var o, r, i = _objectWithoutPropertiesLoose(e, t); if (Object.getOwnPropertySymbols) { var n = Object.getOwnPropertySymbols(e); for (r = 0; r < n.length; r++) { o = n[r], -1 === t.indexOf(o) && {}.propertyIsEnumerable.call(e, o) && (i[o] = e[o]); } } return i; }
|
|
14
|
+
function _objectWithoutPropertiesLoose(r, e) { if (null == r) return {}; var t = {}; for (var n in r) { if ({}.hasOwnProperty.call(r, n)) { if (-1 !== e.indexOf(n)) continue; t[n] = r[n]; } } return t; }
|
|
15
|
+
function _taggedTemplateLiteral(e, t) { return t || (t = e.slice(0)), Object.freeze(Object.defineProperties(e, { raw: { value: Object.freeze(t) } })); }
|
|
16
16
|
function _EMOTION_STRINGIFIED_CSS_ERROR__() { return "You have tried to stringify object returned from `css` function. It isn't supposed to be used directly (e.g. as value of the `className` prop), but rather handed to emotion so it can handle it (e.g. as value of `css` prop)."; }
|
|
17
17
|
import React from 'react';
|
|
18
18
|
import { css } from '@emotion/react';
|
|
@@ -4,5 +4,5 @@ export declare type NativeSelectFieldProps = BaseFieldProps & React.ComponentPro
|
|
|
4
4
|
className?: string;
|
|
5
5
|
visualSize?: Size;
|
|
6
6
|
};
|
|
7
|
-
export declare const NativeSelectField: React.ForwardRefExoticComponent<
|
|
7
|
+
export declare const NativeSelectField: React.ForwardRefExoticComponent<Omit<NativeSelectFieldProps, "ref"> & React.RefAttributes<HTMLSelectElement>>;
|
|
8
8
|
export default NativeSelectField;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
var _excluded = ["name", "label", "defaultValue", "className", "help", "children", "helpPlacement", "assistiveText", "errorMessage", "disabled", "required", "hideAsterisk", "visualSize"];
|
|
2
|
-
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (
|
|
3
|
-
function _objectWithoutProperties(
|
|
4
|
-
function _objectWithoutPropertiesLoose(
|
|
2
|
+
function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) { ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } } return n; }, _extends.apply(null, arguments); }
|
|
3
|
+
function _objectWithoutProperties(e, t) { if (null == e) return {}; var o, r, i = _objectWithoutPropertiesLoose(e, t); if (Object.getOwnPropertySymbols) { var n = Object.getOwnPropertySymbols(e); for (r = 0; r < n.length; r++) { o = n[r], -1 === t.indexOf(o) && {}.propertyIsEnumerable.call(e, o) && (i[o] = e[o]); } } return i; }
|
|
4
|
+
function _objectWithoutPropertiesLoose(r, e) { if (null == r) return {}; var t = {}; for (var n in r) { if ({}.hasOwnProperty.call(r, n)) { if (-1 !== e.indexOf(n)) continue; t[n] = r[n]; } } return t; }
|
|
5
5
|
import React, { forwardRef } from 'react';
|
|
6
6
|
import { css } from '@emotion/react';
|
|
7
7
|
import { ChevronDown } from '@dfds-ui/icons/system/';
|
|
@@ -5,14 +5,14 @@ export declare type BaseReactSelectProps = Omit<React.PropsWithRef<Select>, 'siz
|
|
|
5
5
|
export declare type Size = 'small' | 'medium' | 'large';
|
|
6
6
|
export declare const ReactSelectWrapper: import("@emotion/styled").StyledComponent<{
|
|
7
7
|
theme?: import("@emotion/react").Theme | undefined;
|
|
8
|
-
as?: React.ElementType<any> | undefined;
|
|
8
|
+
as?: React.ElementType<any, keyof React.JSX.IntrinsicElements> | undefined;
|
|
9
9
|
} & {
|
|
10
10
|
error?: boolean | undefined;
|
|
11
11
|
size?: string | undefined;
|
|
12
12
|
arrow?: boolean | undefined;
|
|
13
13
|
selected?: boolean | undefined;
|
|
14
14
|
}, React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
15
|
-
export declare const Menu: (props: any) => JSX.Element;
|
|
15
|
+
export declare const Menu: (props: any) => React.JSX.Element;
|
|
16
16
|
export declare type SelectFieldProps<T = string> = BaseFieldProps & {
|
|
17
17
|
assistiveText?: string;
|
|
18
18
|
autoFocus?: boolean;
|
|
@@ -51,7 +51,7 @@ export declare type SelectFieldProps<T = string> = BaseFieldProps & {
|
|
|
51
51
|
value?: SingleValue<T> | MultiValue<T>;
|
|
52
52
|
visualSize?: Size;
|
|
53
53
|
};
|
|
54
|
-
declare function SelectFieldInner<T>({ assistiveText, components, defaultValue, disabled, errorMessage, filterConfig, help, helpPlacement, hideAsterisk, isClearable, isMulti, isSearchable, label, name, onBlur, onChange, onSelect, options, placeholder, required, styles, value, visualSize, ...rest }: SelectFieldProps<T>, ref: React.ForwardedRef<any>): JSX.Element;
|
|
54
|
+
declare function SelectFieldInner<T>({ assistiveText, components, defaultValue, disabled, errorMessage, filterConfig, help, helpPlacement, hideAsterisk, isClearable, isMulti, isSearchable, label, name, onBlur, onChange, onSelect, options, placeholder, required, styles, value, visualSize, ...rest }: SelectFieldProps<T>, ref: React.ForwardedRef<any>): React.JSX.Element;
|
|
55
55
|
export declare const SelectField: <T>(props: BaseFieldProps & {
|
|
56
56
|
assistiveText?: string | undefined;
|
|
57
57
|
autoFocus?: boolean | undefined;
|
|
@@ -78,7 +78,7 @@ export declare const SelectField: <T>(props: BaseFieldProps & {
|
|
|
78
78
|
isMulti?: boolean | undefined;
|
|
79
79
|
isSearchable?: boolean | undefined;
|
|
80
80
|
menuIsOpen?: boolean | undefined;
|
|
81
|
-
menuPlacement?: "
|
|
81
|
+
menuPlacement?: "top" | "bottom" | "auto" | undefined;
|
|
82
82
|
onBlur?: ((value: any) => void) | undefined;
|
|
83
83
|
onChange?: ((newValue: SingleValue<T> | MultiValue<T>, actionMeta: ActionMeta<T>) => void) | undefined;
|
|
84
84
|
onSelect?: ((value: SingleValue<T> | MultiValue<T>) => void) | undefined;
|
|
@@ -5,14 +5,14 @@ var _excluded = ["assistiveText", "components", "defaultValue", "disabled", "err
|
|
|
5
5
|
var _templateObject;
|
|
6
6
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
7
7
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
8
|
-
function _defineProperty(
|
|
8
|
+
function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
|
|
9
9
|
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
|
|
10
10
|
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
11
|
-
function _objectDestructuringEmpty(
|
|
12
|
-
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (
|
|
13
|
-
function _objectWithoutProperties(
|
|
14
|
-
function _objectWithoutPropertiesLoose(
|
|
15
|
-
function _taggedTemplateLiteral(
|
|
11
|
+
function _objectDestructuringEmpty(t) { if (null == t) throw new TypeError("Cannot destructure " + t); }
|
|
12
|
+
function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) { ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } } return n; }, _extends.apply(null, arguments); }
|
|
13
|
+
function _objectWithoutProperties(e, t) { if (null == e) return {}; var o, r, i = _objectWithoutPropertiesLoose(e, t); if (Object.getOwnPropertySymbols) { var n = Object.getOwnPropertySymbols(e); for (r = 0; r < n.length; r++) { o = n[r], -1 === t.indexOf(o) && {}.propertyIsEnumerable.call(e, o) && (i[o] = e[o]); } } return i; }
|
|
14
|
+
function _objectWithoutPropertiesLoose(r, e) { if (null == r) return {}; var t = {}; for (var n in r) { if ({}.hasOwnProperty.call(r, n)) { if (-1 !== e.indexOf(n)) continue; t[n] = r[n]; } } return t; }
|
|
15
|
+
function _taggedTemplateLiteral(e, t) { return t || (t = e.slice(0)), Object.freeze(Object.defineProperties(e, { raw: { value: Object.freeze(t) } })); }
|
|
16
16
|
function _EMOTION_STRINGIFIED_CSS_ERROR__() { return "You have tried to stringify object returned from `css` function. It isn't supposed to be used directly (e.g. as value of the `className` prop), but rather handed to emotion so it can handle it (e.g. as value of `css` prop)."; }
|
|
17
17
|
import React from 'react';
|
|
18
18
|
import { css } from '@emotion/react';
|
package/switch/Switch.d.ts
CHANGED
|
@@ -28,5 +28,5 @@ export declare type SwitchProps = React.PropsWithRef<JSX.IntrinsicElements['labe
|
|
|
28
28
|
size?: Size;
|
|
29
29
|
error?: boolean;
|
|
30
30
|
};
|
|
31
|
-
export declare const Switch: React.ForwardRefExoticComponent<
|
|
31
|
+
export declare const Switch: React.ForwardRefExoticComponent<Omit<SwitchProps, "ref"> & React.RefAttributes<HTMLInputElement>>;
|
|
32
32
|
export {};
|