@entur/form 5.2.1 → 5.3.0
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/CHANGELOG.md +14 -0
- package/dist/Checkbox.d.ts +1 -1
- package/dist/RadioPanel.d.ts +1 -1
- package/dist/Switch.d.ts +19 -11
- package/dist/TextArea.d.ts +1 -1
- package/dist/TextField.d.ts +2 -2
- package/dist/form.cjs.development.js +187 -138
- package/dist/form.cjs.development.js.map +1 -1
- package/dist/form.cjs.production.min.js +1 -1
- package/dist/form.cjs.production.min.js.map +1 -1
- package/dist/form.esm.js +75 -46
- package/dist/form.esm.js.map +1 -1
- package/dist/segmented-control/SegmentedChoice.d.ts +1 -1
- package/dist/styles.css +199 -199
- package/dist/utils.d.ts +1 -1
- package/package.json +11 -11
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,20 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
# [5.3.0](https://bitbucket.org/enturas/design-system/compare/@entur/form@5.2.3...@entur/form@5.3.0) (2022-03-14)
|
|
7
|
+
|
|
8
|
+
### Features
|
|
9
|
+
|
|
10
|
+
- **switch:** add state icon to switch by default. Hide using hideIcon or change using icon prop ([a785c76](https://bitbucket.org/enturas/design-system/commits/a785c760bfd7b3f7aa45887a08b97c83656eb69e))
|
|
11
|
+
|
|
12
|
+
## [5.2.3](https://bitbucket.org/enturas/design-system/compare/@entur/form@5.2.2...@entur/form@5.2.3) (2022-03-01)
|
|
13
|
+
|
|
14
|
+
**Note:** Version bump only for package @entur/form
|
|
15
|
+
|
|
16
|
+
## [5.2.2](https://bitbucket.org/enturas/design-system/compare/@entur/form@5.2.1...@entur/form@5.2.2) (2022-02-09)
|
|
17
|
+
|
|
18
|
+
**Note:** Version bump only for package @entur/form
|
|
19
|
+
|
|
6
20
|
## [5.2.1](https://bitbucket.org/enturas/design-system/compare/@entur/form@5.2.0...@entur/form@5.2.1) (2022-01-21)
|
|
7
21
|
|
|
8
22
|
### Bug Fixes
|
package/dist/Checkbox.d.ts
CHANGED
|
@@ -39,4 +39,4 @@ export declare const Checkbox: React.ForwardRefExoticComponent<{
|
|
|
39
39
|
* @default false
|
|
40
40
|
*/
|
|
41
41
|
reduceClickArea?: boolean | undefined;
|
|
42
|
-
} &
|
|
42
|
+
} & Omit<React.InputHTMLAttributes<HTMLInputElement>, "checked"> & React.RefAttributes<HTMLInputElement>>;
|
package/dist/RadioPanel.d.ts
CHANGED
|
@@ -26,4 +26,4 @@ export declare type RadioPanelProps = {
|
|
|
26
26
|
/** */
|
|
27
27
|
style?: React.CSSProperties;
|
|
28
28
|
} & Omit<React.DetailedHTMLProps<React.InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, 'title' | 'size'>;
|
|
29
|
-
export declare const RadioPanel: React.ForwardRefExoticComponent<Pick<RadioPanelProps, "
|
|
29
|
+
export declare const RadioPanel: React.ForwardRefExoticComponent<Pick<RadioPanelProps, "accept" | "alt" | "autoComplete" | "autoFocus" | "capture" | "checked" | "crossOrigin" | "disabled" | "form" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget" | "height" | "list" | "max" | "maxLength" | "min" | "minLength" | "multiple" | "name" | "pattern" | "title" | "size" | "key" | "placeholder" | "readOnly" | "required" | "src" | "step" | "type" | "value" | "width" | "onChange" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "id" | "lang" | "slot" | "spellCheck" | "style" | "tabIndex" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "children" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "secondaryLabel" | "hideCheckbox"> & React.RefAttributes<HTMLInputElement>>;
|
package/dist/Switch.d.ts
CHANGED
|
@@ -9,17 +9,21 @@ export declare type SwitchProps = {
|
|
|
9
9
|
* @default "right"
|
|
10
10
|
*/
|
|
11
11
|
labelPlacement?: 'right' | 'bottom';
|
|
12
|
-
/** Om
|
|
12
|
+
/** Om switch-en er checked eller ikke */
|
|
13
13
|
checked?: boolean;
|
|
14
|
-
/** Ikonet som skal stå inne i sirkelen på
|
|
14
|
+
/** Ikonet som skal stå inne i sirkelen på Switch-en */
|
|
15
15
|
icon?: React.ReactNode;
|
|
16
|
-
/**
|
|
16
|
+
/** Skjul ikonet inne i sikrelen på Switch-en
|
|
17
|
+
* @default false
|
|
18
|
+
*/
|
|
19
|
+
hideIcon?: boolean;
|
|
20
|
+
/** Farge som settes på ikon og bakgrunnen når Switch-en er "checked". Default er mint-contrast
|
|
17
21
|
* @default colors.validation .mintContrast
|
|
18
22
|
*/
|
|
19
23
|
color?: string;
|
|
20
|
-
/** Lik som color, men når
|
|
24
|
+
/** Lik som color, men når Switch-en står i en kontrast seksjon. Default er samme farge som color. */
|
|
21
25
|
contrastColor?: string;
|
|
22
|
-
/** Størrelsen på
|
|
26
|
+
/** Størrelsen på Switch-en
|
|
23
27
|
* @default "medium"
|
|
24
28
|
*/
|
|
25
29
|
size?: 'medium' | 'large';
|
|
@@ -35,20 +39,24 @@ export declare const Switch: React.ForwardRefExoticComponent<{
|
|
|
35
39
|
* @default "right"
|
|
36
40
|
*/
|
|
37
41
|
labelPlacement?: "right" | "bottom" | undefined;
|
|
38
|
-
/** Om
|
|
42
|
+
/** Om switch-en er checked eller ikke */
|
|
39
43
|
checked?: boolean | undefined;
|
|
40
|
-
/** Ikonet som skal stå inne i sirkelen på
|
|
44
|
+
/** Ikonet som skal stå inne i sirkelen på Switch-en */
|
|
41
45
|
icon?: React.ReactNode;
|
|
42
|
-
/**
|
|
46
|
+
/** Skjul ikonet inne i sikrelen på Switch-en
|
|
47
|
+
* @default false
|
|
48
|
+
*/
|
|
49
|
+
hideIcon?: boolean | undefined;
|
|
50
|
+
/** Farge som settes på ikon og bakgrunnen når Switch-en er "checked". Default er mint-contrast
|
|
43
51
|
* @default colors.validation .mintContrast
|
|
44
52
|
*/
|
|
45
53
|
color?: string | undefined;
|
|
46
|
-
/** Lik som color, men når
|
|
54
|
+
/** Lik som color, men når Switch-en står i en kontrast seksjon. Default er samme farge som color. */
|
|
47
55
|
contrastColor?: string | undefined;
|
|
48
|
-
/** Størrelsen på
|
|
56
|
+
/** Størrelsen på Switch-en
|
|
49
57
|
* @default "medium"
|
|
50
58
|
*/
|
|
51
59
|
size?: "medium" | "large" | undefined;
|
|
52
60
|
/** Callback for når verdien endres */
|
|
53
61
|
onChange?: ((e: React.ChangeEvent<HTMLInputElement>) => void) | undefined;
|
|
54
|
-
} &
|
|
62
|
+
} & Omit<React.InputHTMLAttributes<HTMLInputElement>, "size"> & React.RefAttributes<HTMLInputElement>>;
|
package/dist/TextArea.d.ts
CHANGED
|
@@ -25,7 +25,7 @@ export declare const TextArea: React.ForwardRefExoticComponent<{
|
|
|
25
25
|
/** Ekstra klassenavn */
|
|
26
26
|
className?: string | undefined;
|
|
27
27
|
/** Valideringsvariant */
|
|
28
|
-
variant?:
|
|
28
|
+
variant?: VariantType | undefined;
|
|
29
29
|
/** Deaktiverer tekstområdet */
|
|
30
30
|
disabled?: boolean | undefined;
|
|
31
31
|
/** Setter tekstområdet i read-only modus */
|
package/dist/TextField.d.ts
CHANGED
|
@@ -51,7 +51,7 @@ export declare const TextField: React.ForwardRefExoticComponent<{
|
|
|
51
51
|
/** Varselmelding, som vil komme under TextField */
|
|
52
52
|
feedback?: string | undefined;
|
|
53
53
|
/** Hvilken valideringsfarge som vises */
|
|
54
|
-
variant?:
|
|
54
|
+
variant?: VariantType | undefined;
|
|
55
55
|
/** Deaktiver inputfeltet */
|
|
56
56
|
disabled?: boolean | undefined;
|
|
57
57
|
/** Setter inputfeltet i read-only modus */
|
|
@@ -72,4 +72,4 @@ export declare const TextField: React.ForwardRefExoticComponent<{
|
|
|
72
72
|
clearable?: boolean | undefined;
|
|
73
73
|
/** Callback for clearable */
|
|
74
74
|
onClear?: (() => void) | undefined;
|
|
75
|
-
} &
|
|
75
|
+
} & Omit<React.InputHTMLAttributes<HTMLInputElement>, "size" | "label"> & React.RefAttributes<HTMLInputElement>>;
|