@danske/sapphire-react-lab 0.99.2 → 0.100.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/build/cjs/index.js +649 -458
- package/build/cjs/index.js.map +1 -1
- package/build/esm/FileDropzone/i18n/da-DK.js +1 -0
- package/build/esm/FileDropzone/i18n/da-DK.js.map +1 -1
- package/build/esm/FileDropzone/i18n/de-DE.js +1 -0
- package/build/esm/FileDropzone/i18n/de-DE.js.map +1 -1
- package/build/esm/FileDropzone/i18n/en-US.js +1 -0
- package/build/esm/FileDropzone/i18n/en-US.js.map +1 -1
- package/build/esm/FileDropzone/i18n/fi-FI.js +1 -0
- package/build/esm/FileDropzone/i18n/fi-FI.js.map +1 -1
- package/build/esm/FileDropzone/i18n/nb-NO.js +1 -0
- package/build/esm/FileDropzone/i18n/nb-NO.js.map +1 -1
- package/build/esm/FileDropzone/i18n/pl-PL.js +1 -0
- package/build/esm/FileDropzone/i18n/pl-PL.js.map +1 -1
- package/build/esm/FileDropzone/i18n/sv-SE.js +1 -0
- package/build/esm/FileDropzone/i18n/sv-SE.js.map +1 -1
- package/build/esm/FileDropzone/src/FileDropzone.js +1 -1
- package/build/esm/FileDropzone/src/FileDropzone.js.map +1 -1
- package/build/esm/Filtering/src/FilterDropdown.js +3 -2
- package/build/esm/Filtering/src/FilterDropdown.js.map +1 -1
- package/build/esm/Filtering/src/SearchableSelectFilter.js +1 -0
- package/build/esm/Filtering/src/SearchableSelectFilter.js.map +1 -1
- package/build/esm/TimeField/i18n/da-DK.js +7 -0
- package/build/esm/TimeField/i18n/da-DK.js.map +1 -0
- package/build/esm/TimeField/i18n/de-DE.js +7 -0
- package/build/esm/TimeField/i18n/de-DE.js.map +1 -0
- package/build/esm/TimeField/i18n/en-US.js +7 -0
- package/build/esm/TimeField/i18n/en-US.js.map +1 -0
- package/build/esm/TimeField/i18n/fi-FI.js +7 -0
- package/build/esm/TimeField/i18n/fi-FI.js.map +1 -0
- package/build/esm/TimeField/i18n/index.js +20 -0
- package/build/esm/TimeField/i18n/index.js.map +1 -0
- package/build/esm/TimeField/i18n/nb-NO.js +7 -0
- package/build/esm/TimeField/i18n/nb-NO.js.map +1 -0
- package/build/esm/TimeField/i18n/pl-PL.js +7 -0
- package/build/esm/TimeField/i18n/pl-PL.js.map +1 -0
- package/build/esm/TimeField/i18n/sv-SE.js +7 -0
- package/build/esm/TimeField/i18n/sv-SE.js.map +1 -0
- package/build/esm/TimeField/src/TimeField.js +106 -0
- package/build/esm/TimeField/src/TimeField.js.map +1 -0
- package/build/esm/TimeField/src/TimeFieldSegment.js +48 -0
- package/build/esm/TimeField/src/TimeFieldSegment.js.map +1 -0
- package/build/esm/index.js +1 -0
- package/build/esm/index.js.map +1 -1
- package/build/index.d.ts +92 -2
- package/package.json +30 -28
package/build/index.d.ts
CHANGED
|
@@ -6,7 +6,8 @@ import { CollectionBase, DOMProps, Expandable, ItemProps, AriaLabelingProps, Foc
|
|
|
6
6
|
import { HoverProps } from '@react-aria/interactions';
|
|
7
7
|
import { DropOptions } from '@react-aria/dnd';
|
|
8
8
|
import { AriaNumberFieldProps } from '@react-aria/numberfield';
|
|
9
|
-
import { SliderProps as SliderProps$1, SliderThumbProps, BreadcrumbProps, BreadcrumbsProps as BreadcrumbsProps$1 } from 'react-aria-components';
|
|
9
|
+
import { SliderProps as SliderProps$1, SliderThumbProps, BreadcrumbProps, BreadcrumbsProps as BreadcrumbsProps$1, TimeValue } from 'react-aria-components';
|
|
10
|
+
import { AriaTimeFieldProps } from '@react-aria/datepicker';
|
|
10
11
|
export { useLocale } from '@react-aria/i18n';
|
|
11
12
|
|
|
12
13
|
interface FilterDropdownProps extends SapphireStyleProps, Pick<PopoverTriggerProps, 'defaultOpen' | 'isOpen' | 'onOpenChange' | 'noMaxWidth'> {
|
|
@@ -448,4 +449,93 @@ interface SapphireAlertProps extends SapphireStyleProps {
|
|
|
448
449
|
}
|
|
449
450
|
declare function Alert({ children, title, variant, ...props }: SapphireAlertProps): React__default.JSX.Element;
|
|
450
451
|
|
|
451
|
-
|
|
452
|
+
declare type TimeFieldProps<T extends TimeValue> = Pick<AriaTimeFieldProps<T>, 'isDisabled' | 'isRequired' | 'isReadOnly' | 'label' | 'value' | 'defaultValue' | 'onChange' | 'onFocus' | 'onBlur' | 'shouldForceLeadingZeros'> & SapphireStyleProps & {
|
|
453
|
+
/**
|
|
454
|
+
* @default 'lg'
|
|
455
|
+
*/
|
|
456
|
+
size?: 'lg' | 'md';
|
|
457
|
+
/**
|
|
458
|
+
* To visually indicate if this field is required or optional.
|
|
459
|
+
* @default false
|
|
460
|
+
*/
|
|
461
|
+
necessityIndicator?: boolean;
|
|
462
|
+
/**
|
|
463
|
+
* Places the label either above (default) or on the side of the control.
|
|
464
|
+
* @default 'above'
|
|
465
|
+
*/
|
|
466
|
+
labelPlacement?: 'side' | 'above';
|
|
467
|
+
/**
|
|
468
|
+
* If it should hide the "clear" button when input is not empty.
|
|
469
|
+
*
|
|
470
|
+
* @default false
|
|
471
|
+
*/
|
|
472
|
+
noClearButton?: boolean;
|
|
473
|
+
/**
|
|
474
|
+
* Whether the input should render as having an error and an error message.
|
|
475
|
+
* This also sets the appropriate `aria` attributes on the input.
|
|
476
|
+
*
|
|
477
|
+
* A `boolean` sets the error state. Can be paired with the "note" prop with Field.Note variant="error"
|
|
478
|
+
* A `ReactNode` sets the error state with an additional error message.
|
|
479
|
+
*
|
|
480
|
+
* **An error message is strongly recommended because an error should
|
|
481
|
+
* always have an explanation about how to fix it.**
|
|
482
|
+
*/
|
|
483
|
+
error?: boolean | ReactNode;
|
|
484
|
+
/**
|
|
485
|
+
* A note to show below the input.
|
|
486
|
+
* If the input has an error message, this note will be replaced by that.
|
|
487
|
+
* Use {@Link Field.Note} to render the note.
|
|
488
|
+
*/
|
|
489
|
+
note?: ReactNode;
|
|
490
|
+
/**
|
|
491
|
+
* A HelpButton to render next to the label.
|
|
492
|
+
*/
|
|
493
|
+
contextualHelp?: ReactNode;
|
|
494
|
+
};
|
|
495
|
+
declare const TimeField: <T extends TimeValue>(props: Pick<AriaTimeFieldProps<T>, "label" | "value" | "isDisabled" | "onFocus" | "onBlur" | "onChange" | "defaultValue" | "isReadOnly" | "isRequired" | "shouldForceLeadingZeros"> & SapphireStyleProps & {
|
|
496
|
+
/**
|
|
497
|
+
* @default 'lg'
|
|
498
|
+
*/
|
|
499
|
+
size?: "md" | "lg" | undefined;
|
|
500
|
+
/**
|
|
501
|
+
* To visually indicate if this field is required or optional.
|
|
502
|
+
* @default false
|
|
503
|
+
*/
|
|
504
|
+
necessityIndicator?: boolean | undefined;
|
|
505
|
+
/**
|
|
506
|
+
* Places the label either above (default) or on the side of the control.
|
|
507
|
+
* @default 'above'
|
|
508
|
+
*/
|
|
509
|
+
labelPlacement?: "above" | "side" | undefined;
|
|
510
|
+
/**
|
|
511
|
+
* If it should hide the "clear" button when input is not empty.
|
|
512
|
+
*
|
|
513
|
+
* @default false
|
|
514
|
+
*/
|
|
515
|
+
noClearButton?: boolean | undefined;
|
|
516
|
+
/**
|
|
517
|
+
* Whether the input should render as having an error and an error message.
|
|
518
|
+
* This also sets the appropriate `aria` attributes on the input.
|
|
519
|
+
*
|
|
520
|
+
* A `boolean` sets the error state. Can be paired with the "note" prop with Field.Note variant="error"
|
|
521
|
+
* A `ReactNode` sets the error state with an additional error message.
|
|
522
|
+
*
|
|
523
|
+
* **An error message is strongly recommended because an error should
|
|
524
|
+
* always have an explanation about how to fix it.**
|
|
525
|
+
*/
|
|
526
|
+
error?: boolean | ReactNode;
|
|
527
|
+
/**
|
|
528
|
+
* A note to show below the input.
|
|
529
|
+
* If the input has an error message, this note will be replaced by that.
|
|
530
|
+
* Use {@Link Field.Note} to render the note.
|
|
531
|
+
*/
|
|
532
|
+
note?: ReactNode;
|
|
533
|
+
/**
|
|
534
|
+
* A HelpButton to render next to the label.
|
|
535
|
+
*/
|
|
536
|
+
contextualHelp?: ReactNode;
|
|
537
|
+
} & {
|
|
538
|
+
ref?: React__default.RefObject<HTMLDivElement> | undefined;
|
|
539
|
+
}) => React__default.ReactElement;
|
|
540
|
+
|
|
541
|
+
export { _Accordion as Accordion, AccordionContext, AccordionHeadingProps, AccordionItemProps, AccordionProps, Alert, BreadcrumbItem, BreadcrumbItemLink, BreadcrumbItemLinkProps, BreadcrumbItemProps, Breadcrumbs, BreadcrumbsProps, FileDropzone, FileDropzoneProps, FileTrigger, FileTriggerProps, FilterDropdown, FilterDropdownProps, Flag, FlagProps, LabeledValue, NumberField, NumberFieldProps, NumberFieldRef, ProgressIndicator, ProgressIndicatorProps, SapphireAlertProps, SearchableSelectFilter, SearchableSelectFilterProps, _Slider as Slider, SliderProps, TagGroup, TagGroupProps, TagItem, TimeField, TimeFieldProps };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@danske/sapphire-react-lab",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.100.0",
|
|
4
4
|
"license": "SEE LICENSE IN LICENSE",
|
|
5
5
|
"description": "Experimental React components of the Sapphire Design System from Danske Bank A/S",
|
|
6
6
|
"exports": {
|
|
@@ -25,48 +25,50 @@
|
|
|
25
25
|
},
|
|
26
26
|
"peerDependencies": {
|
|
27
27
|
"@danske/sapphire-icons": "^3.1.0",
|
|
28
|
-
"@danske/sapphire-react": "^5.6.
|
|
28
|
+
"@danske/sapphire-react": "^5.6.2",
|
|
29
29
|
"react": ">=16.8.0",
|
|
30
30
|
"react-dom": ">=16.8.0"
|
|
31
31
|
},
|
|
32
32
|
"devDependencies": {
|
|
33
33
|
"@danske/sapphire-icons": "^3.1.0",
|
|
34
|
-
"@danske/sapphire-react": "^5.6.
|
|
34
|
+
"@danske/sapphire-react": "^5.6.2",
|
|
35
35
|
"@types/react-transition-group": "^4.4.5",
|
|
36
36
|
"cross-env": "^7.0.3"
|
|
37
37
|
},
|
|
38
38
|
"dependencies": {
|
|
39
39
|
"@danske/sapphire-css": "^44.0.0",
|
|
40
|
-
"@internationalized/date": "^3.
|
|
40
|
+
"@internationalized/date": "^3.10.0",
|
|
41
41
|
"@internationalized/string": "^3.2.7",
|
|
42
42
|
"@react-aria/accordion": "3.0.0-alpha.37",
|
|
43
|
-
"@react-aria/button": "^3.14.
|
|
44
|
-
"@react-aria/combobox": "^3.
|
|
45
|
-
"@react-aria/
|
|
46
|
-
"@react-aria/
|
|
47
|
-
"@react-aria/
|
|
48
|
-
"@react-aria/
|
|
49
|
-
"@react-aria/
|
|
50
|
-
"@react-aria/
|
|
51
|
-
"@react-aria/
|
|
52
|
-
"@react-aria/
|
|
53
|
-
"@react-aria/
|
|
54
|
-
"@react-aria/
|
|
55
|
-
"@react-aria/
|
|
56
|
-
"@react-aria/
|
|
43
|
+
"@react-aria/button": "^3.14.2",
|
|
44
|
+
"@react-aria/combobox": "^3.14.0",
|
|
45
|
+
"@react-aria/datepicker": "^3.15.2",
|
|
46
|
+
"@react-aria/dialog": "^3.5.31",
|
|
47
|
+
"@react-aria/dnd": "^3.11.3",
|
|
48
|
+
"@react-aria/focus": "^3.21.2",
|
|
49
|
+
"@react-aria/i18n": "^3.12.13",
|
|
50
|
+
"@react-aria/interactions": "^3.25.6",
|
|
51
|
+
"@react-aria/label": "^3.7.22",
|
|
52
|
+
"@react-aria/numberfield": "^3.12.2",
|
|
53
|
+
"@react-aria/overlays": "^3.30.0",
|
|
54
|
+
"@react-aria/progress": "^3.4.27",
|
|
55
|
+
"@react-aria/tag": "^3.7.2",
|
|
56
|
+
"@react-aria/utils": "^3.31.0",
|
|
57
|
+
"@react-aria/visually-hidden": "^3.8.28",
|
|
57
58
|
"@react-spectrum/utils": "^3.12.5",
|
|
58
|
-
"@react-stately/collections": "^3.12.
|
|
59
|
-
"@react-stately/combobox": "^3.
|
|
60
|
-
"@react-stately/
|
|
61
|
-
"@react-stately/
|
|
62
|
-
"@react-stately/
|
|
63
|
-
"@react-stately/
|
|
59
|
+
"@react-stately/collections": "^3.12.8",
|
|
60
|
+
"@react-stately/combobox": "^3.12.0",
|
|
61
|
+
"@react-stately/datepicker": "^3.15.2",
|
|
62
|
+
"@react-stately/list": "^3.13.1",
|
|
63
|
+
"@react-stately/numberfield": "^3.10.2",
|
|
64
|
+
"@react-stately/toggle": "^3.9.2",
|
|
65
|
+
"@react-stately/tree": "^3.9.3",
|
|
64
66
|
"@react-stately/utils": "^3.10.8",
|
|
65
|
-
"@react-types/dialog": "^3.5.
|
|
66
|
-
"@react-types/shared": "^3.32.
|
|
67
|
+
"@react-types/dialog": "^3.5.22",
|
|
68
|
+
"@react-types/shared": "^3.32.1",
|
|
67
69
|
"clsx": "^1.1.1",
|
|
68
|
-
"react-aria-components": "^1.
|
|
70
|
+
"react-aria-components": "^1.13.0",
|
|
69
71
|
"react-transition-group": "^4.4.5"
|
|
70
72
|
},
|
|
71
|
-
"gitHead": "
|
|
73
|
+
"gitHead": "9f90f2527ecc5fdd374638c518ab372b71f88709"
|
|
72
74
|
}
|