@uncinc/uncinc-react-kitchen-sink 2.6.1 → 2.6.4
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/dist/Context/ViewportContext.d.ts +23 -0
- package/dist/components/AbbreviationAnnotation/index.d.ts +24 -0
- package/dist/components/Accordion/AccordionItem/index.d.ts +17 -0
- package/dist/components/Accordion/AccordionItem/index.js +8 -8
- package/dist/components/Accordion/AccordionItemVariant/index.d.ts +23 -0
- package/dist/components/Accordion/index.d.ts +3 -0
- package/dist/components/Accordion/index.js +3 -3
- package/dist/components/ApiAutocomplete/index.d.ts +19 -0
- package/dist/components/Button/index.d.ts +1 -1
- package/dist/components/Cookie/Checkbox/index.d.ts +12 -0
- package/dist/components/Cookie/index.d.ts +72 -0
- package/dist/components/Dialog/DialogHelpersStory/index.d.ts +3 -0
- package/dist/components/Dialog/DialogHookStory/index.d.ts +3 -0
- package/dist/components/Dialog/DialogHookStory/index.js +15 -23
- package/dist/components/Dialog/DialogOverrideStory/index.d.ts +3 -0
- package/dist/components/Dialog/index.d.ts +5 -5
- package/dist/components/Download/index.js +1 -1
- package/dist/components/FontSizeSwitcher/index.d.ts +11 -0
- package/dist/components/Form/Checkbox/index.d.ts +9 -0
- package/dist/components/Form/Checkbox/index.js +2 -1
- package/dist/components/Form/Checkboxes/index.d.ts +3 -0
- package/dist/components/Form/Date/index.d.ts +3 -0
- package/dist/components/Form/DatePicker/index.d.ts +3 -0
- package/dist/components/Form/DateSelect/index.d.ts +17 -0
- package/dist/components/Form/Email/index.d.ts +3 -0
- package/dist/components/Form/FormikWrapper/index.d.ts +3 -0
- package/dist/components/Form/GenericFormElement/index.d.ts +3 -0
- package/dist/components/Form/Number/index.d.ts +3 -0
- package/dist/components/Form/RadioButtons/index.d.ts +3 -0
- package/dist/components/Form/SearchField/index.d.ts +3 -0
- package/dist/components/Form/Select/Input/index.d.ts +3 -0
- package/dist/components/Form/Select/index.d.ts +3 -0
- package/dist/components/Form/TextField/index.d.ts +4 -0
- package/dist/components/Form/TextField/index.js +2 -1
- package/dist/components/Form/Textarea/index.d.ts +3 -0
- package/dist/components/Form/commonTests.d.ts +6 -0
- package/dist/components/Form/{TextField/index.test.js → commonTests.js} +65 -94
- package/dist/components/Hamburger/index.d.ts +14 -0
- package/dist/components/Header/index.d.ts +10 -0
- package/dist/components/Image/Background/index.d.ts +8 -0
- package/dist/components/Image/Picture/index.d.ts +2 -2
- package/dist/components/InlineMenu/index.d.ts +44 -0
- package/dist/components/InlineMenu/index.js +156 -40
- package/dist/components/Layout/Container/index.d.ts +22 -0
- package/dist/components/Layout/Container/index.js +14 -12
- package/dist/components/Layout/QuickLayout/Auto/index.d.ts +14 -0
- package/dist/components/Layout/QuickLayout/Center/index.d.ts +6 -0
- package/dist/components/Layout/QuickLayout/Clamp/index.d.ts +16 -0
- package/dist/components/Layout/QuickLayout/Sidebar/index.d.ts +14 -0
- package/dist/components/Layout/QuickLayout/SpaceBetween/index.d.ts +14 -0
- package/dist/components/Layout/QuickLayout/Stack/index.d.ts +7 -0
- package/dist/components/Layout/QuickLayout/Wrap/index.d.ts +14 -0
- package/dist/components/Layout/QuickLayout/index.d.ts +12 -0
- package/dist/components/Lottie/LottieAnimation/index.d.ts +3 -0
- package/dist/components/Lottie/LottieAnimationWithMousePosition.d.ts +6 -0
- package/dist/components/Lottie/index.d.ts +3 -0
- package/dist/components/MagicLine/index.d.ts +6 -0
- package/dist/components/MediaPlayer/index.js +6 -5
- package/dist/components/NavigationScroll/index.d.ts +10 -0
- package/dist/components/Pagination/index.d.ts +57 -0
- package/dist/components/SearchKit/Facets/ChipFacet/index.d.ts +8 -0
- package/dist/components/SearchKit/Facets/ListFacet/index.d.ts +8 -0
- package/dist/components/SearchKit/Facets/SelectFacet/index.d.ts +8 -0
- package/dist/components/SearchKit/Query/index.d.ts +7 -0
- package/dist/components/SearchKit/SearchFacets/index.d.ts +14 -0
- package/dist/components/SearchKit/SearchField/index.d.ts +16 -0
- package/dist/components/SearchKit/SearchLoadMore/index.d.ts +7 -0
- package/dist/components/SearchKit/SearchPage/index.d.ts +14 -0
- package/dist/components/SearchKit/SearchPagination/index.d.ts +5 -0
- package/dist/components/SearchKit/SearchReset/index.d.ts +7 -0
- package/dist/components/SearchKit/SearchResults/index.d.ts +33 -0
- package/dist/components/SearchKit/SearchSelectedFilters/Filters/CustomValue/index.d.ts +5 -0
- package/dist/components/SearchKit/SearchSelectedFilters/Filters/DateRange/index.d.ts +6 -0
- package/dist/components/SearchKit/SearchSelectedFilters/Filters/NumericRange/index.d.ts +6 -0
- package/dist/components/SearchKit/SearchSelectedFilters/Filters/Value/index.d.ts +6 -0
- package/dist/components/SearchKit/SearchSelectedFilters/index.d.ts +6 -0
- package/dist/components/SearchKit/SearchSorting/index.d.ts +6 -0
- package/dist/components/SearchKit/index.d.ts +37 -0
- package/dist/components/Share/index.d.ts +18 -0
- package/dist/components/Sliders/SliderRelated/index.d.ts +21 -0
- package/dist/components/TableRender/index.d.ts +10 -0
- package/dist/components/TableRender/index.js +66 -0
- package/dist/components/TableRender/style.scss +106 -0
- package/dist/components/TitleWithText/index.d.ts +3 -1
- package/dist/components/TitleWithText/index.js +8 -5
- package/dist/components/WysiwygField/index.d.ts +1 -1
- package/dist/components/WysiwygField/index.js +2 -1
- package/dist/components/index.d.ts +16 -0
- package/dist/config/constants.d.ts +1 -1
- package/dist/config/i18next/index.d.ts +2 -0
- package/dist/helpers/date.d.ts +3 -0
- package/dist/helpers/gtm.d.ts +1 -1
- package/dist/helpers/index.d.ts +14 -0
- package/dist/helpers/index.js +31 -0
- package/dist/helpers/useValueForCurrentViewPort.d.ts +1 -0
- package/dist/hooks/useClickOutside.js +1 -1
- package/dist/hooks/useDialog.d.ts +1 -4
- package/dist/hooks/useDialogHelpers.d.ts +1 -1
- package/dist/hooks/useOnScreen.d.ts +2 -0
- package/dist/hooks/useOnScreen.js +6 -6
- package/dist/hooks/usePrevious.d.ts +1 -0
- package/dist/hooks/usePrevious.js +1 -7
- package/dist/hooks/useScrollPosition.d.ts +2 -0
- package/dist/hooks/useScrollPosition.js +1 -1
- package/dist/hooks/useWindowDimensions.d.ts +4 -0
- package/dist/index.d.ts +73 -0
- package/dist/index.js +14 -0
- package/dist/organisms/Downloads/index.js +4 -2
- package/dist/organisms/ImageGrid/index.d.ts +25 -0
- package/dist/organisms/ImageGrid/index.js +30 -0
- package/dist/organisms/ImageGrid/style.scss +53 -0
- package/dist/organisms/Text/index.d.ts +2 -0
- package/dist/organisms/Text/index.js +5 -1
- package/dist/setupTests.d.ts +1 -0
- package/dist/styles/assets/_variables.scss +5 -1
- package/package.json +10 -8
- package/dist/components/AbbreviationAnnotation/stories.js +0 -38
- package/dist/components/AbbreviationAnnotation/stories.scss +0 -39
- package/dist/components/Accordion/stories.js +0 -40
- package/dist/components/ApiAutocomplete/stories.js +0 -29
- package/dist/components/Button/stories.js +0 -36
- package/dist/components/Button/stories.scss +0 -45
- package/dist/components/CallToAction/stories.d.ts +0 -8
- package/dist/components/CallToAction/stories.js +0 -37
- package/dist/components/Cookie/stories.js +0 -91
- package/dist/components/Cookie/stories.scss +0 -70
- package/dist/components/Dialog/stories.js +0 -21
- package/dist/components/Download/stories.d.ts +0 -8
- package/dist/components/Download/stories.js +0 -28
- package/dist/components/Download/stories.scss +0 -67
- package/dist/components/FontSizeSwitcher/stories.js +0 -25
- package/dist/components/Form/Checkbox/stories.js +0 -37
- package/dist/components/Form/Checkboxes/index.test.js +0 -155
- package/dist/components/Form/Checkboxes/stories.js +0 -49
- package/dist/components/Form/Date/stories.js +0 -31
- package/dist/components/Form/DatePicker/stories.js +0 -31
- package/dist/components/Form/DateSelect/stories.js +0 -54
- package/dist/components/Form/Email/stories.js +0 -31
- package/dist/components/Form/Number/stories.js +0 -34
- package/dist/components/Form/RadioButtons/index.test.js +0 -146
- package/dist/components/Form/RadioButtons/stories.js +0 -54
- package/dist/components/Form/Select/stories.js +0 -70
- package/dist/components/Form/TextField/stories.js +0 -40
- package/dist/components/Form/Textarea/stories.js +0 -31
- package/dist/components/Hamburger/stories.js +0 -50
- package/dist/components/Header/stories.js +0 -50
- package/dist/components/Header/stories.scss +0 -11
- package/dist/components/Image/stories.js +0 -89
- package/dist/components/Image/stories.scss +0 -20
- package/dist/components/InlineMenu/stories.js +0 -68
- package/dist/components/InlineMenu/stories.scss +0 -10
- package/dist/components/Layout/Container/stories.js +0 -95
- package/dist/components/Layout/Container/stories.scss +0 -21
- package/dist/components/Layout/QuickLayout/stories.js +0 -104
- package/dist/components/Lottie/stories.js +0 -66
- package/dist/components/MagicLine/stories.js +0 -63
- package/dist/components/MagicLine/stories.scss +0 -38
- package/dist/components/MediaPlayer/stories.d.ts +0 -12
- package/dist/components/MediaPlayer/stories.js +0 -146
- package/dist/components/NavigationScroll/stories.js +0 -21
- package/dist/components/NavigationScroll/stories.scss +0 -17
- package/dist/components/Pagination/stories.js +0 -103
- package/dist/components/Pagination/stories.scss +0 -31
- package/dist/components/SearchKit/stories.js +0 -205
- package/dist/components/Share/stories.js +0 -18
- package/dist/components/Share/stories.scss +0 -63
- package/dist/components/Sliders/SliderRelated/stories.js +0 -91
- package/dist/components/TitleWithText/stories.d.ts +0 -8
- package/dist/components/TitleWithText/stories.js +0 -24
- package/dist/components/TitleWithText/stories.scss +0 -0
- package/dist/components/WysiwygField/stories.js +0 -43
- package/dist/organisms/Downloads/stories.d.ts +0 -8
- package/dist/organisms/Downloads/stories.js +0 -43
- package/dist/organisms/Downloads/stories.scss +0 -67
- package/dist/organisms/Quote/stories.d.ts +0 -8
- package/dist/organisms/Quote/stories.js +0 -39
- package/dist/organisms/Quote/stories.scss +0 -48
- package/dist/organisms/Text/stories.d.ts +0 -8
- package/dist/organisms/Text/stories.js +0 -30
- package/dist/organisms/Text/stories.scss +0 -29
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
export const SCREEN_MOBILE: "SCREEN_MOBILE";
|
|
2
|
+
export const SCREEN_TABLET: "SCREEN_TABLET";
|
|
3
|
+
export const SCREEN_NORMAL: "SCREEN_NORMAL";
|
|
4
|
+
export const SCREEN_WIDE: "SCREEN_WIDE";
|
|
5
|
+
export const SCREEN_HUGE: "SCREEN_HUGE";
|
|
6
|
+
export default ViewportContext;
|
|
7
|
+
declare const ViewportContext: React.Context<{
|
|
8
|
+
screenSizes: {
|
|
9
|
+
SCREEN_MOBILE: number;
|
|
10
|
+
SCREEN_TABLET: number;
|
|
11
|
+
SCREEN_NORMAL: number;
|
|
12
|
+
SCREEN_WIDE: number;
|
|
13
|
+
SCREEN_HUGE: number;
|
|
14
|
+
};
|
|
15
|
+
imageStyles: {
|
|
16
|
+
SCREEN_MOBILE: string;
|
|
17
|
+
SCREEN_TABLET: string;
|
|
18
|
+
SCREEN_NORMAL: string;
|
|
19
|
+
SCREEN_WIDE: string;
|
|
20
|
+
SCREEN_HUGE: string;
|
|
21
|
+
};
|
|
22
|
+
}>;
|
|
23
|
+
import React from 'react';
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
export default AbbreviationAnnotation;
|
|
2
|
+
declare function AbbreviationAnnotation({ title, children, abbreviationTitle, abbreviationContent, ...props }: {
|
|
3
|
+
[x: string]: any;
|
|
4
|
+
title: any;
|
|
5
|
+
children: any;
|
|
6
|
+
abbreviationTitle: any;
|
|
7
|
+
abbreviationContent: any;
|
|
8
|
+
}): React.JSX.Element;
|
|
9
|
+
declare namespace AbbreviationAnnotation {
|
|
10
|
+
namespace propTypes {
|
|
11
|
+
let title: PropTypes.Validator<string>;
|
|
12
|
+
let children: PropTypes.Validator<PropTypes.ReactElementLike>;
|
|
13
|
+
let abbreviationTitle: PropTypes.Requireable<(...args: any[]) => any>;
|
|
14
|
+
let abbreviationContent: PropTypes.Requireable<(...args: any[]) => any>;
|
|
15
|
+
}
|
|
16
|
+
namespace defaultProps {
|
|
17
|
+
export function abbreviationTitle_1(html: any): React.JSX.Element;
|
|
18
|
+
export { abbreviationTitle_1 as abbreviationTitle };
|
|
19
|
+
export function abbreviationContent_1(html: any): React.JSX.Element;
|
|
20
|
+
export { abbreviationContent_1 as abbreviationContent };
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
import React from 'react';
|
|
24
|
+
import PropTypes from 'prop-types';
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
export default AccordionItem;
|
|
2
|
+
declare function AccordionItem(props: any): React.JSX.Element;
|
|
3
|
+
declare namespace AccordionItem {
|
|
4
|
+
namespace defaultProps {
|
|
5
|
+
export let title: string;
|
|
6
|
+
export let content: string;
|
|
7
|
+
export let iconClassName: string;
|
|
8
|
+
export let duration: number;
|
|
9
|
+
export let easing: string;
|
|
10
|
+
export { AccordeonTitle as titleComponent };
|
|
11
|
+
}
|
|
12
|
+
}
|
|
13
|
+
import React from 'react';
|
|
14
|
+
declare function AccordeonTitle({ className, children }: {
|
|
15
|
+
className: any;
|
|
16
|
+
children: any;
|
|
17
|
+
}): React.JSX.Element;
|
|
@@ -34,14 +34,14 @@ var AccordeonTitle = function AccordeonTitle(_ref2) {
|
|
|
34
34
|
className: className
|
|
35
35
|
}, children);
|
|
36
36
|
};
|
|
37
|
-
var AccordionItem = function AccordionItem(
|
|
38
|
-
var title =
|
|
39
|
-
content =
|
|
40
|
-
iconClassName =
|
|
41
|
-
duration =
|
|
42
|
-
easing =
|
|
43
|
-
titleComponent =
|
|
44
|
-
className =
|
|
37
|
+
var AccordionItem = function AccordionItem(props) {
|
|
38
|
+
var title = props.title,
|
|
39
|
+
content = props.content,
|
|
40
|
+
iconClassName = props.iconClassName,
|
|
41
|
+
duration = props.duration,
|
|
42
|
+
easing = props.easing,
|
|
43
|
+
titleComponent = props.titleComponent,
|
|
44
|
+
className = props.className;
|
|
45
45
|
var _useState = (0, _react.useState)(true),
|
|
46
46
|
_useState2 = _slicedToArray(_useState, 2),
|
|
47
47
|
collapsed = _useState2[0],
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
export default AccordionItemVariant;
|
|
2
|
+
declare function AccordionItemVariant({ title, children, className, buttonOpened, buttonClosed, duration, easing, onClick }: {
|
|
3
|
+
title: any;
|
|
4
|
+
children: any;
|
|
5
|
+
className: any;
|
|
6
|
+
buttonOpened: any;
|
|
7
|
+
buttonClosed: any;
|
|
8
|
+
duration: any;
|
|
9
|
+
easing: any;
|
|
10
|
+
onClick: any;
|
|
11
|
+
}): React.JSX.Element;
|
|
12
|
+
declare namespace AccordionItemVariant {
|
|
13
|
+
namespace defaultProps {
|
|
14
|
+
let title: string;
|
|
15
|
+
let className: string;
|
|
16
|
+
let children: React.JSX.Element;
|
|
17
|
+
let buttonOpened: React.JSX.Element;
|
|
18
|
+
let buttonClosed: React.JSX.Element;
|
|
19
|
+
let duration: number;
|
|
20
|
+
let easing: string;
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
import React from 'react';
|
|
@@ -8,9 +8,9 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
8
8
|
var _classnames = _interopRequireDefault(require("classnames"));
|
|
9
9
|
require("./style.scss");
|
|
10
10
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
11
|
-
var Accordion = function Accordion(
|
|
12
|
-
var className =
|
|
13
|
-
children =
|
|
11
|
+
var Accordion = function Accordion(props) {
|
|
12
|
+
var className = props.className,
|
|
13
|
+
children = props.children;
|
|
14
14
|
var classes = (0, _classnames.default)('Accordion', className);
|
|
15
15
|
return /*#__PURE__*/_react.default.createElement("div", {
|
|
16
16
|
className: classes
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
export default ApiAutocomplete;
|
|
2
|
+
declare function ApiAutocomplete({ endpoint, placeholder, renderItem, defaultValue, onSelectItem, queryParameter, getSuggestionValue, requestOptions, ...props }: {
|
|
3
|
+
[x: string]: any;
|
|
4
|
+
endpoint: any;
|
|
5
|
+
placeholder: any;
|
|
6
|
+
renderItem: any;
|
|
7
|
+
defaultValue: any;
|
|
8
|
+
onSelectItem: any;
|
|
9
|
+
queryParameter?: string | undefined;
|
|
10
|
+
getSuggestionValue: any;
|
|
11
|
+
requestOptions: any;
|
|
12
|
+
}): React.JSX.Element;
|
|
13
|
+
declare namespace ApiAutocomplete {
|
|
14
|
+
namespace defaultProps {
|
|
15
|
+
function getSuggestionValue(item: any): any;
|
|
16
|
+
let requestOptions: {};
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
import React from 'react';
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export default CheckboxAndRadio;
|
|
2
|
+
declare function CheckboxAndRadio({ name, id, value, label, checked, onChange, disabled, type }: {
|
|
3
|
+
name: any;
|
|
4
|
+
id: any;
|
|
5
|
+
value: any;
|
|
6
|
+
label: any;
|
|
7
|
+
checked: any;
|
|
8
|
+
onChange: any;
|
|
9
|
+
disabled: any;
|
|
10
|
+
type: any;
|
|
11
|
+
}): React.JSX.Element;
|
|
12
|
+
import React from 'react';
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
export default CookieCompliancePopup;
|
|
2
|
+
declare function CookieCompliancePopup(props: any): React.JSX.Element | null;
|
|
3
|
+
declare namespace CookieCompliancePopup {
|
|
4
|
+
namespace defaultProps {
|
|
5
|
+
let agreeText: string;
|
|
6
|
+
let disagreeText: string;
|
|
7
|
+
let manualText: string;
|
|
8
|
+
function manualHeader(): void;
|
|
9
|
+
function onAgree(): void;
|
|
10
|
+
function onDisagree(): void;
|
|
11
|
+
let showDisagree: boolean;
|
|
12
|
+
let manualButtonClassname: string;
|
|
13
|
+
let cookieLevels: {
|
|
14
|
+
value: string;
|
|
15
|
+
label: string;
|
|
16
|
+
description: string;
|
|
17
|
+
disabled: boolean;
|
|
18
|
+
}[];
|
|
19
|
+
namespace defaultValues {
|
|
20
|
+
let necessary: boolean;
|
|
21
|
+
let voorkeuren: boolean;
|
|
22
|
+
let statistieken: boolean;
|
|
23
|
+
let marketing: boolean;
|
|
24
|
+
}
|
|
25
|
+
let cookieDomain: null;
|
|
26
|
+
namespace cookieOptions {
|
|
27
|
+
let days: number;
|
|
28
|
+
let path: string;
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
namespace propTypes {
|
|
32
|
+
let agreeText_1: PropTypes.Requireable<string>;
|
|
33
|
+
export { agreeText_1 as agreeText };
|
|
34
|
+
let disagreeText_1: PropTypes.Requireable<string>;
|
|
35
|
+
export { disagreeText_1 as disagreeText };
|
|
36
|
+
let manualText_1: PropTypes.Requireable<string>;
|
|
37
|
+
export { manualText_1 as manualText };
|
|
38
|
+
let manualHeader_1: PropTypes.Requireable<(...args: any[]) => any>;
|
|
39
|
+
export { manualHeader_1 as manualHeader };
|
|
40
|
+
let manualButtonClassname_1: PropTypes.Requireable<string>;
|
|
41
|
+
export { manualButtonClassname_1 as manualButtonClassname };
|
|
42
|
+
let onAgree_1: PropTypes.Requireable<(...args: any[]) => any>;
|
|
43
|
+
export { onAgree_1 as onAgree };
|
|
44
|
+
let onDisagree_1: PropTypes.Requireable<(...args: any[]) => any>;
|
|
45
|
+
export { onDisagree_1 as onDisagree };
|
|
46
|
+
let showDisagree_1: PropTypes.Requireable<boolean>;
|
|
47
|
+
export { showDisagree_1 as showDisagree };
|
|
48
|
+
let cookieLevels_1: PropTypes.Requireable<(PropTypes.InferProps<{
|
|
49
|
+
value: PropTypes.Requireable<string>;
|
|
50
|
+
label: PropTypes.Requireable<string>;
|
|
51
|
+
description: PropTypes.Requireable<string>;
|
|
52
|
+
disabled: PropTypes.Requireable<boolean>;
|
|
53
|
+
}> | null | undefined)[]>;
|
|
54
|
+
export { cookieLevels_1 as cookieLevels };
|
|
55
|
+
let cookieOptions_1: PropTypes.Requireable<PropTypes.InferProps<{
|
|
56
|
+
days: PropTypes.Requireable<number>;
|
|
57
|
+
path: PropTypes.Requireable<string>;
|
|
58
|
+
}>>;
|
|
59
|
+
export { cookieOptions_1 as cookieOptions };
|
|
60
|
+
let cookieDomain_1: PropTypes.Requireable<string>;
|
|
61
|
+
export { cookieDomain_1 as cookieDomain };
|
|
62
|
+
let defaultValues_1: PropTypes.Requireable<PropTypes.InferProps<{
|
|
63
|
+
necessary: PropTypes.Requireable<boolean>;
|
|
64
|
+
voorkeuren: PropTypes.Requireable<boolean>;
|
|
65
|
+
statistieken: PropTypes.Requireable<boolean>;
|
|
66
|
+
marketing: PropTypes.Requireable<boolean>;
|
|
67
|
+
}>>;
|
|
68
|
+
export { defaultValues_1 as defaultValues };
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
import React from 'react';
|
|
72
|
+
import PropTypes from 'prop-types';
|
|
@@ -9,36 +9,28 @@ var _uuid = require("uuid");
|
|
|
9
9
|
var _useDialog2 = _interopRequireDefault(require("../../../hooks/useDialog"));
|
|
10
10
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
11
11
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
12
|
-
function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }
|
|
13
|
-
function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
14
|
-
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
15
|
-
function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
|
16
|
-
function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
|
|
17
|
-
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
18
12
|
var DialogHookStory = function DialogHookStory(args) {
|
|
13
|
+
var _useDialog = (0, _useDialog2.default)(),
|
|
14
|
+
openDialog = _useDialog.openDialog,
|
|
15
|
+
DialogComponent = _useDialog.DialogComponent;
|
|
16
|
+
var uuid = (0, _uuid.v4)();
|
|
19
17
|
var Content = function Content() {
|
|
20
18
|
return /*#__PURE__*/_react.default.createElement("div", null, /*#__PURE__*/_react.default.createElement("p", null, "I've been created using the ", /*#__PURE__*/_react.default.createElement("code", null, "useDialog"), " hook.", /*#__PURE__*/_react.default.createElement("br", null), /*#__PURE__*/_react.default.createElement("br", null), "This hook provides you with:", /*#__PURE__*/_react.default.createElement("ul", null, /*#__PURE__*/_react.default.createElement("li", null, /*#__PURE__*/_react.default.createElement("code", null, "DialogComponent"), " - the Dialog component"), /*#__PURE__*/_react.default.createElement("li", null, /*#__PURE__*/_react.default.createElement("code", null, "dialogIsOpen"), " - a const which tells you if the dialog is open or closed"), /*#__PURE__*/_react.default.createElement("li", null, /*#__PURE__*/_react.default.createElement("code", null, "openDialog"), " - a function to open the dialog"), /*#__PURE__*/_react.default.createElement("li", null, /*#__PURE__*/_react.default.createElement("code", null, "closeDialog"), " - a function to close the dialog")), "The ", /*#__PURE__*/_react.default.createElement("code", null, "DialogComponent"), " has several arguments:", /*#__PURE__*/_react.default.createElement("ul", null, /*#__PURE__*/_react.default.createElement("li", null, /*#__PURE__*/_react.default.createElement("code", null, "id"), " - a unique identifier (optional)"), /*#__PURE__*/_react.default.createElement("li", null, /*#__PURE__*/_react.default.createElement("code", null, "title"), " - a header element, or any element, really (optional)"), /*#__PURE__*/_react.default.createElement("li", null, /*#__PURE__*/_react.default.createElement("code", null, "children"), " - the dialog's content. Wrapped within the dialog."), /*#__PURE__*/_react.default.createElement("li", null, /*#__PURE__*/_react.default.createElement("code", null, "showCloseButton"), " - render a close button? (optional)"), /*#__PURE__*/_react.default.createElement("li", null, /*#__PURE__*/_react.default.createElement("code", null, "showCloseIcon"), " - render a close icon? (optional)"), /*#__PURE__*/_react.default.createElement("li", null, /*#__PURE__*/_react.default.createElement("code", null, "closeButtonText"), " - text for the close button (optional)"), /*#__PURE__*/_react.default.createElement("li", null, /*#__PURE__*/_react.default.createElement("code", null, "closeIcon"), " - what icon to use. Default 'icon-cross' (optional)"), /*#__PURE__*/_react.default.createElement("li", null, /*#__PURE__*/_react.default.createElement("code", null, "dialogLabel"), " - a label for a11y - default 'dialog' (optional)")), "Depending on where the dialog is being used, you might need to add a z-index.", /*#__PURE__*/_react.default.createElement("br", null), /*#__PURE__*/_react.default.createElement("br", null), "This Dialog handles several things for you: Taking focus and keeping it inside and it allows you to close the Dialog by either pressing Escape or clicking outside of it. This is done by several different hooks.", /*#__PURE__*/_react.default.createElement("br", null), /*#__PURE__*/_react.default.createElement("br", null), "Alternatively, if you need a more custom approach, you can opt to use the ", /*#__PURE__*/_react.default.createElement("code", null, "useDialogHelpers"), " hook instead."));
|
|
21
19
|
};
|
|
22
20
|
var title = function title() {
|
|
23
21
|
return /*#__PURE__*/_react.default.createElement("h2", null, "I'm a Dialog!");
|
|
24
22
|
};
|
|
25
|
-
return /*#__PURE__*/_react.default.createElement("div", null,
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
showCloseButton: true,
|
|
37
|
-
closeButtonText: "Click here to close me.",
|
|
38
|
-
showCloseIcon: true,
|
|
39
|
-
closeIcon: "icon-cross"
|
|
40
|
-
}, args), /*#__PURE__*/_react.default.createElement(Content, null)));
|
|
41
|
-
}));
|
|
23
|
+
return /*#__PURE__*/_react.default.createElement("div", null, /*#__PURE__*/_react.default.createElement("div", null, /*#__PURE__*/_react.default.createElement("button", {
|
|
24
|
+
type: "button",
|
|
25
|
+
onClick: openDialog
|
|
26
|
+
}, "Open a dialog"), /*#__PURE__*/_react.default.createElement(DialogComponent, _extends({
|
|
27
|
+
id: uuid,
|
|
28
|
+
title: title,
|
|
29
|
+
showCloseButton: true,
|
|
30
|
+
closeButtonText: "Click here to close me.",
|
|
31
|
+
showCloseIcon: true,
|
|
32
|
+
closeIcon: "icon-cross"
|
|
33
|
+
}, args), /*#__PURE__*/_react.default.createElement(Content, null))));
|
|
42
34
|
};
|
|
43
35
|
exports.DialogHookStory = DialogHookStory;
|
|
44
36
|
var _default = DialogHookStory;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export default Dialog;
|
|
2
|
-
declare function Dialog(props: any): React.ReactPortal;
|
|
2
|
+
declare function Dialog(props: any): React.ReactPortal | null;
|
|
3
3
|
declare namespace Dialog {
|
|
4
4
|
namespace propTypes {
|
|
5
5
|
let id: PropTypes.Requireable<string>;
|
|
@@ -16,9 +16,9 @@ declare namespace Dialog {
|
|
|
16
16
|
let disableClosers: PropTypes.Requireable<boolean>;
|
|
17
17
|
}
|
|
18
18
|
namespace defaultProps {
|
|
19
|
-
let id_1:
|
|
19
|
+
let id_1: string;
|
|
20
20
|
export { id_1 as id };
|
|
21
|
-
let title_1:
|
|
21
|
+
let title_1: null;
|
|
22
22
|
export { title_1 as title };
|
|
23
23
|
let showCloseButton_1: boolean;
|
|
24
24
|
export { showCloseButton_1 as showCloseButton };
|
|
@@ -32,9 +32,9 @@ declare namespace Dialog {
|
|
|
32
32
|
export { dialogLabel_1 as dialogLabel };
|
|
33
33
|
let isOpen_1: boolean;
|
|
34
34
|
export { isOpen_1 as isOpen };
|
|
35
|
-
let closeFunction_1:
|
|
35
|
+
let closeFunction_1: null;
|
|
36
36
|
export { closeFunction_1 as closeFunction };
|
|
37
|
-
let portalTarget_1: HTMLElement;
|
|
37
|
+
let portalTarget_1: HTMLElement | null;
|
|
38
38
|
export { portalTarget_1 as portalTarget };
|
|
39
39
|
let disableClosers_1: boolean;
|
|
40
40
|
export { disableClosers_1 as disableClosers };
|
|
@@ -50,7 +50,7 @@ var Download = function Download(_ref) {
|
|
|
50
50
|
className: "Download__attributes"
|
|
51
51
|
}, extension && /*#__PURE__*/_react.default.createElement("span", {
|
|
52
52
|
className: "Download__extension"
|
|
53
|
-
}, extension[0]
|
|
53
|
+
}, extension[0]), filesize && /*#__PURE__*/_react.default.createElement("span", {
|
|
54
54
|
className: "Download__filesize"
|
|
55
55
|
}, "(", (0, _prettyBytes.default)(filesize), ")")));
|
|
56
56
|
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export default FontSizeSwitcher;
|
|
2
|
+
declare function FontSizeSwitcher({ defaultSize, incrementMode }: {
|
|
3
|
+
defaultSize: any;
|
|
4
|
+
incrementMode?: boolean | undefined;
|
|
5
|
+
}): React.JSX.Element;
|
|
6
|
+
declare namespace FontSizeSwitcher {
|
|
7
|
+
namespace defaultProps {
|
|
8
|
+
let defaultSize: number;
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
import React from 'react';
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export function Checkbox(props: any): React.JSX.Element;
|
|
2
|
+
export namespace Checkbox {
|
|
3
|
+
namespace defaultProps {
|
|
4
|
+
function onChange(): void;
|
|
5
|
+
}
|
|
6
|
+
}
|
|
7
|
+
declare const _default: (props: any) => React.JSX.Element;
|
|
8
|
+
export default _default;
|
|
9
|
+
import React from 'react';
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.default = void 0;
|
|
6
|
+
exports.default = exports.Checkbox = void 0;
|
|
7
7
|
var _react = _interopRequireDefault(require("react"));
|
|
8
8
|
var _formik = require("formik");
|
|
9
9
|
var _classnames = _interopRequireDefault(require("classnames"));
|
|
@@ -66,6 +66,7 @@ var Checkbox = function Checkbox(props) {
|
|
|
66
66
|
})), title);
|
|
67
67
|
}));
|
|
68
68
|
};
|
|
69
|
+
exports.Checkbox = Checkbox;
|
|
69
70
|
Checkbox.defaultProps = {
|
|
70
71
|
onChange: function onChange() {}
|
|
71
72
|
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
export default DateSelect;
|
|
2
|
+
declare function DateSelect(props: any): React.JSX.Element;
|
|
3
|
+
declare namespace DateSelect {
|
|
4
|
+
namespace defaultProps {
|
|
5
|
+
let title: string;
|
|
6
|
+
let fieldName: string;
|
|
7
|
+
let yearMin: number;
|
|
8
|
+
let yearMax: number;
|
|
9
|
+
let hideYear: boolean;
|
|
10
|
+
let requiredError: string;
|
|
11
|
+
let notValidError: string;
|
|
12
|
+
let dayPlaceholder: string;
|
|
13
|
+
let monthPlaceholder: string;
|
|
14
|
+
let yearPlaceholder: string;
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
import React from 'react';
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.default = void 0;
|
|
6
|
+
exports.default = exports.TextField = void 0;
|
|
7
7
|
var _react = _interopRequireDefault(require("react"));
|
|
8
8
|
var _formik = require("formik");
|
|
9
9
|
var _classnames = _interopRequireDefault(require("classnames"));
|
|
@@ -65,5 +65,6 @@ var TextField = function TextField(props) {
|
|
|
65
65
|
disabled: disabled
|
|
66
66
|
})));
|
|
67
67
|
};
|
|
68
|
+
exports.TextField = TextField;
|
|
68
69
|
var _default = (0, _withMapping.default)(TextField);
|
|
69
70
|
exports.default = _default;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
export function testElementExists(element: any, label: any, render: any): void;
|
|
2
|
+
export function testRenderDescription(description: any, render: any): void;
|
|
3
|
+
export function testOnChange(label: any, expectedValue: any, render: any): void;
|
|
4
|
+
export function testRequiredIndicator(render: any): void;
|
|
5
|
+
export function testRequiredErrorMessage(errorClassName: any, errorMessage: any, render: any): void;
|
|
6
|
+
export function testRenderDisabled(element: any, label: any, render: any): void;
|