@entur/form 5.1.4 → 5.2.2
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 +28 -0
- package/dist/Checkbox.d.ts +1 -1
- package/dist/RadioPanel.d.ts +1 -1
- package/dist/Switch.d.ts +11 -3
- package/dist/TextArea.d.ts +1 -1
- package/dist/TextField.d.ts +2 -2
- package/dist/TravelSwitch.d.ts +5 -1
- package/dist/form.cjs.development.js +201 -143
- 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 +94 -56
- package/dist/form.esm.js.map +1 -1
- package/dist/segmented-control/SegmentedChoice.d.ts +1 -1
- package/dist/styles.css +192 -169
- package/dist/utils.d.ts +1 -1
- package/package.json +11 -11
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,34 @@
|
|
|
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.2.2](https://bitbucket.org/enturas/design-system/compare/@entur/form@5.2.1...@entur/form@5.2.2) (2022-02-09)
|
|
7
|
+
|
|
8
|
+
**Note:** Version bump only for package @entur/form
|
|
9
|
+
|
|
10
|
+
## [5.2.1](https://bitbucket.org/enturas/design-system/compare/@entur/form@5.2.0...@entur/form@5.2.1) (2022-01-21)
|
|
11
|
+
|
|
12
|
+
### Bug Fixes
|
|
13
|
+
|
|
14
|
+
- **textarea:** fix label position bug in textarea ([cbc07cd](https://bitbucket.org/enturas/design-system/commits/cbc07cdbc8201f89bfc455e7965ecaee80d00a2a))
|
|
15
|
+
- **textfield:** fix label position bug on textfield ([76a2cdf](https://bitbucket.org/enturas/design-system/commits/76a2cdf7878f32bd1c5a9c7f4f8d8918b8e09344))
|
|
16
|
+
|
|
17
|
+
# [5.2.0](https://bitbucket.org/enturas/design-system/compare/@entur/form@5.1.5...@entur/form@5.2.0) (2022-01-05)
|
|
18
|
+
|
|
19
|
+
### Bug Fixes
|
|
20
|
+
|
|
21
|
+
- **form:** added space between label and segmented control ([dea5a1a](https://bitbucket.org/enturas/design-system/commits/dea5a1ac5e18d118d546d35f4195293cf1e395f0))
|
|
22
|
+
|
|
23
|
+
### Features
|
|
24
|
+
|
|
25
|
+
- **switch:** add 'labelPlacement' prop with 'right' or 'bottom' choice to Switch ([97d8933](https://bitbucket.org/enturas/design-system/commits/97d8933e8644a633ef5c48471bc04a5392bdd2ba))
|
|
26
|
+
- **travel switch:** update TravelSwitch to use new 'labelPlacement' prop in 'Switch' ([5676ef8](https://bitbucket.org/enturas/design-system/commits/5676ef89dbc25e73a227224f7d0738fce4d3cc2c))
|
|
27
|
+
|
|
28
|
+
## [5.1.5](https://bitbucket.org/enturas/design-system/compare/@entur/form@5.1.4...@entur/form@5.1.5) (2021-12-10)
|
|
29
|
+
|
|
30
|
+
### Bug Fixes
|
|
31
|
+
|
|
32
|
+
- **textfield:** consistent rendering of clearbutton if clearable ([87a42ba](https://bitbucket.org/enturas/design-system/commits/87a42baadebfffbc07c8636db26aa2be6203d523))
|
|
33
|
+
|
|
6
34
|
## [5.1.4](https://bitbucket.org/enturas/design-system/compare/@entur/form@5.1.3...@entur/form@5.1.4) (2021-11-17)
|
|
7
35
|
|
|
8
36
|
### 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
|
@@ -3,8 +3,12 @@ import './Switch.scss';
|
|
|
3
3
|
export declare type SwitchProps = {
|
|
4
4
|
/** Ekstra klassenavn */
|
|
5
5
|
className?: string;
|
|
6
|
-
/** Label for
|
|
6
|
+
/** Label for Switch-en. */
|
|
7
7
|
children?: React.ReactNode;
|
|
8
|
+
/** Posisjonen til label for Switch-en.
|
|
9
|
+
* @default "right"
|
|
10
|
+
*/
|
|
11
|
+
labelPlacement?: 'right' | 'bottom';
|
|
8
12
|
/** Om switchen er checked eller ikke */
|
|
9
13
|
checked?: boolean;
|
|
10
14
|
/** Ikonet som skal stå inne i sirkelen på Switchen */
|
|
@@ -25,8 +29,12 @@ export declare type SwitchProps = {
|
|
|
25
29
|
export declare const Switch: React.ForwardRefExoticComponent<{
|
|
26
30
|
/** Ekstra klassenavn */
|
|
27
31
|
className?: string | undefined;
|
|
28
|
-
/** Label for
|
|
32
|
+
/** Label for Switch-en. */
|
|
29
33
|
children?: React.ReactNode;
|
|
34
|
+
/** Posisjonen til label for Switch-en.
|
|
35
|
+
* @default "right"
|
|
36
|
+
*/
|
|
37
|
+
labelPlacement?: "right" | "bottom" | undefined;
|
|
30
38
|
/** Om switchen er checked eller ikke */
|
|
31
39
|
checked?: boolean | undefined;
|
|
32
40
|
/** Ikonet som skal stå inne i sirkelen på Switchen */
|
|
@@ -43,4 +51,4 @@ export declare const Switch: React.ForwardRefExoticComponent<{
|
|
|
43
51
|
size?: "medium" | "large" | undefined;
|
|
44
52
|
/** Callback for når verdien endres */
|
|
45
53
|
onChange?: ((e: React.ChangeEvent<HTMLInputElement>) => void) | undefined;
|
|
46
|
-
} &
|
|
54
|
+
} & 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>>;
|
package/dist/TravelSwitch.d.ts
CHANGED
|
@@ -5,8 +5,12 @@ export declare type TravelSwitchProps = {
|
|
|
5
5
|
className?: string;
|
|
6
6
|
/** Om switchen er checked eller ikke */
|
|
7
7
|
checked?: boolean;
|
|
8
|
-
/** Label for
|
|
8
|
+
/** Label for TravelSwitch-en. */
|
|
9
9
|
children?: React.ReactNode;
|
|
10
|
+
/** Posisjonen til label for TravelSwitch-en.
|
|
11
|
+
* @default "right"
|
|
12
|
+
*/
|
|
13
|
+
labelPlacement?: 'right' | 'bottom';
|
|
10
14
|
/** Hvilken type reise som skal vises rikig ikon og farge for */
|
|
11
15
|
transport: 'bus' | 'metro' | 'air' | 'tram' | 'rail' | 'water' | 'bike' | 'airportLinkBus' | 'airportLinkRail' | 'scooter';
|
|
12
16
|
/** Callback for når verdien endres */
|