@telia-ace/widget-ui 1.0.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/LICENSE.txt +6 -0
- package/README.md +3 -0
- package/lib/components/anchor-link.d.ts +4 -0
- package/lib/components/anchor-link.js +7 -0
- package/lib/components/button.d.ts +4 -0
- package/lib/components/button.js +64 -0
- package/lib/components/checkbox.d.ts +7 -0
- package/lib/components/checkbox.js +39 -0
- package/lib/components/drawer/drawer.d.ts +21 -0
- package/lib/components/drawer/drawer.js +150 -0
- package/lib/components/drawer/index.d.ts +3 -0
- package/lib/components/drawer/index.js +29 -0
- package/lib/components/dropdown/dropdown.d.ts +9 -0
- package/lib/components/dropdown/dropdown.js +155 -0
- package/lib/components/dropdown/index.d.ts +4 -0
- package/lib/components/dropdown/index.js +10 -0
- package/lib/components/dropdown/use-position.d.ts +5 -0
- package/lib/components/dropdown/use-position.js +57 -0
- package/lib/components/empty.d.ts +4 -0
- package/lib/components/empty.js +40 -0
- package/lib/components/grid.d.ts +7 -0
- package/lib/components/grid.js +64 -0
- package/lib/components/html.d.ts +12 -0
- package/lib/components/html.js +78 -0
- package/lib/components/icon.d.ts +7 -0
- package/lib/components/icon.js +35 -0
- package/lib/components/index.d.ts +58 -0
- package/lib/components/index.js +69 -0
- package/lib/components/input.d.ts +10 -0
- package/lib/components/input.js +94 -0
- package/lib/components/item-list.d.ts +10 -0
- package/lib/components/item-list.js +62 -0
- package/lib/components/item-tree.d.ts +13 -0
- package/lib/components/item-tree.js +55 -0
- package/lib/components/lightbox.d.ts +6 -0
- package/lib/components/lightbox.js +92 -0
- package/lib/components/link.d.ts +11 -0
- package/lib/components/link.js +99 -0
- package/lib/components/list.d.ts +9 -0
- package/lib/components/list.js +56 -0
- package/lib/components/modal/confirm.d.ts +12 -0
- package/lib/components/modal/confirm.js +61 -0
- package/lib/components/modal/index.d.ts +4 -0
- package/lib/components/modal/index.js +10 -0
- package/lib/components/modal/modal.d.ts +10 -0
- package/lib/components/modal/modal.js +127 -0
- package/lib/components/not-found.d.ts +9 -0
- package/lib/components/not-found.js +55 -0
- package/lib/components/overlay.d.ts +8 -0
- package/lib/components/overlay.js +73 -0
- package/lib/components/paragraph.d.ts +11 -0
- package/lib/components/paragraph.js +66 -0
- package/lib/components/portal.d.ts +7 -0
- package/lib/components/portal.js +61 -0
- package/lib/components/route-link.d.ts +11 -0
- package/lib/components/route-link.js +115 -0
- package/lib/components/symbol-badge.d.ts +15 -0
- package/lib/components/symbol-badge.js +197 -0
- package/lib/components/tab-stop.d.ts +18 -0
- package/lib/components/tab-stop.js +100 -0
- package/lib/components/text-link.d.ts +8 -0
- package/lib/components/text-link.js +62 -0
- package/lib/components/text.d.ts +4 -0
- package/lib/components/text.js +35 -0
- package/lib/components/timestamp.d.ts +13 -0
- package/lib/components/timestamp.js +39 -0
- package/lib/components/tooltip.d.ts +8 -0
- package/lib/components/tooltip.js +127 -0
- package/lib/components/transition-component.d.ts +30 -0
- package/lib/components/transition-component.js +77 -0
- package/lib/components/typography.d.ts +9 -0
- package/lib/components/typography.js +43 -0
- package/lib/components/widget-link.d.ts +10 -0
- package/lib/components/widget-link.js +116 -0
- package/lib/contexts/index.d.ts +9 -0
- package/lib/contexts/index.js +15 -0
- package/lib/create-react-component.d.ts +11 -0
- package/lib/create-react-component.js +18 -0
- package/lib/hooks/index.d.ts +27 -0
- package/lib/hooks/index.js +58 -0
- package/lib/hooks/use-action.d.ts +4 -0
- package/lib/hooks/use-action.js +21 -0
- package/lib/hooks/use-children.d.ts +4 -0
- package/lib/hooks/use-children.js +70 -0
- package/lib/hooks/use-columns.d.ts +2 -0
- package/lib/hooks/use-columns.js +6 -0
- package/lib/hooks/use-component-descriptor.d.ts +2 -0
- package/lib/hooks/use-component-descriptor.js +6 -0
- package/lib/hooks/use-component-node.d.ts +6 -0
- package/lib/hooks/use-component-node.js +37 -0
- package/lib/hooks/use-component-platform.d.ts +4 -0
- package/lib/hooks/use-component-platform.js +39 -0
- package/lib/hooks/use-component.d.ts +3 -0
- package/lib/hooks/use-component.js +57 -0
- package/lib/hooks/use-container.d.ts +2 -0
- package/lib/hooks/use-container.js +6 -0
- package/lib/hooks/use-context.d.ts +3 -0
- package/lib/hooks/use-context.js +50 -0
- package/lib/hooks/use-dispatch.d.ts +3 -0
- package/lib/hooks/use-dispatch.js +64 -0
- package/lib/hooks/use-event-listener.d.ts +2 -0
- package/lib/hooks/use-event-listener.js +21 -0
- package/lib/hooks/use-events.d.ts +3 -0
- package/lib/hooks/use-events.js +12 -0
- package/lib/hooks/use-is-mounted.d.ts +3 -0
- package/lib/hooks/use-is-mounted.js +14 -0
- package/lib/hooks/use-key-press.d.ts +2 -0
- package/lib/hooks/use-key-press.js +46 -0
- package/lib/hooks/use-layout.d.ts +3 -0
- package/lib/hooks/use-layout.js +50 -0
- package/lib/hooks/use-previous.d.ts +2 -0
- package/lib/hooks/use-previous.js +11 -0
- package/lib/hooks/use-properties.d.ts +6 -0
- package/lib/hooks/use-properties.js +9 -0
- package/lib/hooks/use-render-state.d.ts +4 -0
- package/lib/hooks/use-render-state.js +66 -0
- package/lib/hooks/use-route-data.d.ts +4 -0
- package/lib/hooks/use-route-data.js +54 -0
- package/lib/hooks/use-router.d.ts +3 -0
- package/lib/hooks/use-router.js +9 -0
- package/lib/hooks/use-scroll.d.ts +2 -0
- package/lib/hooks/use-scroll.js +71 -0
- package/lib/hooks/use-settings.d.ts +3 -0
- package/lib/hooks/use-settings.js +38 -0
- package/lib/hooks/use-toggle.d.ts +2 -0
- package/lib/hooks/use-toggle.js +28 -0
- package/lib/hooks/use-transition-end.d.ts +2 -0
- package/lib/hooks/use-transition-end.js +62 -0
- package/lib/hooks/use-unique-menu.d.ts +2 -0
- package/lib/hooks/use-unique-menu.js +15 -0
- package/lib/hooks/use-widget-event.d.ts +3 -0
- package/lib/hooks/use-widget-event.js +21 -0
- package/lib/index.d.ts +9 -0
- package/lib/index.js +92 -0
- package/lib/styles.d.ts +19 -0
- package/lib/styles.js +53 -0
- package/lib/utils/animations.d.ts +18 -0
- package/lib/utils/animations.js +104 -0
- package/lib/utils/browser.d.ts +12 -0
- package/lib/utils/browser.js +54 -0
- package/lib/utils/convert-to-string-attributes.d.ts +2 -0
- package/lib/utils/convert-to-string-attributes.js +23 -0
- package/lib/utils/create-empty-component.d.ts +4 -0
- package/lib/utils/create-empty-component.js +25 -0
- package/lib/utils/embedded-link-mapper.d.ts +4 -0
- package/lib/utils/embedded-link-mapper.js +62 -0
- package/lib/utils/filter-css-props.d.ts +8 -0
- package/lib/utils/filter-css-props.js +28 -0
- package/lib/utils/generic-hash-link.d.ts +8 -0
- package/lib/utils/generic-hash-link.js +70 -0
- package/lib/utils/heading-styles.d.ts +1 -0
- package/lib/utils/heading-styles.js +48 -0
- package/lib/utils/index.d.ts +12 -0
- package/lib/utils/index.js +28 -0
- package/lib/utils/process-html-string.d.ts +4 -0
- package/lib/utils/process-html-string.js +16 -0
- package/lib/utils/render-instructions.d.ts +8 -0
- package/lib/utils/render-instructions.js +19 -0
- package/lib-esm/components/anchor-link.d.ts +4 -0
- package/lib-esm/components/anchor-link.js +5 -0
- package/lib-esm/components/button.d.ts +4 -0
- package/lib-esm/components/button.js +36 -0
- package/lib-esm/components/checkbox.d.ts +7 -0
- package/lib-esm/components/checkbox.js +34 -0
- package/lib-esm/components/drawer/drawer.d.ts +21 -0
- package/lib-esm/components/drawer/drawer.js +121 -0
- package/lib-esm/components/drawer/index.d.ts +3 -0
- package/lib-esm/components/drawer/index.js +3 -0
- package/lib-esm/components/dropdown/dropdown.d.ts +9 -0
- package/lib-esm/components/dropdown/dropdown.js +127 -0
- package/lib-esm/components/dropdown/index.d.ts +4 -0
- package/lib-esm/components/dropdown/index.js +3 -0
- package/lib-esm/components/dropdown/use-position.d.ts +5 -0
- package/lib-esm/components/dropdown/use-position.js +53 -0
- package/lib-esm/components/empty.d.ts +4 -0
- package/lib-esm/components/empty.js +35 -0
- package/lib-esm/components/grid.d.ts +7 -0
- package/lib-esm/components/grid.js +36 -0
- package/lib-esm/components/html.d.ts +12 -0
- package/lib-esm/components/html.js +53 -0
- package/lib-esm/components/icon.d.ts +7 -0
- package/lib-esm/components/icon.js +30 -0
- package/lib-esm/components/index.d.ts +58 -0
- package/lib-esm/components/index.js +30 -0
- package/lib-esm/components/input.d.ts +10 -0
- package/lib-esm/components/input.js +69 -0
- package/lib-esm/components/item-list.d.ts +10 -0
- package/lib-esm/components/item-list.js +34 -0
- package/lib-esm/components/item-tree.d.ts +13 -0
- package/lib-esm/components/item-tree.js +50 -0
- package/lib-esm/components/lightbox.d.ts +6 -0
- package/lib-esm/components/lightbox.js +64 -0
- package/lib-esm/components/link.d.ts +11 -0
- package/lib-esm/components/link.js +71 -0
- package/lib-esm/components/list.d.ts +9 -0
- package/lib-esm/components/list.js +31 -0
- package/lib-esm/components/modal/confirm.d.ts +12 -0
- package/lib-esm/components/modal/confirm.js +33 -0
- package/lib-esm/components/modal/index.d.ts +4 -0
- package/lib-esm/components/modal/index.js +3 -0
- package/lib-esm/components/modal/modal.d.ts +10 -0
- package/lib-esm/components/modal/modal.js +99 -0
- package/lib-esm/components/not-found.d.ts +9 -0
- package/lib-esm/components/not-found.js +27 -0
- package/lib-esm/components/overlay.d.ts +8 -0
- package/lib-esm/components/overlay.js +45 -0
- package/lib-esm/components/paragraph.d.ts +11 -0
- package/lib-esm/components/paragraph.js +38 -0
- package/lib-esm/components/portal.d.ts +7 -0
- package/lib-esm/components/portal.js +36 -0
- package/lib-esm/components/route-link.d.ts +11 -0
- package/lib-esm/components/route-link.js +90 -0
- package/lib-esm/components/symbol-badge.d.ts +15 -0
- package/lib-esm/components/symbol-badge.js +192 -0
- package/lib-esm/components/tab-stop.d.ts +18 -0
- package/lib-esm/components/tab-stop.js +75 -0
- package/lib-esm/components/text-link.d.ts +8 -0
- package/lib-esm/components/text-link.js +34 -0
- package/lib-esm/components/text.d.ts +4 -0
- package/lib-esm/components/text.js +30 -0
- package/lib-esm/components/timestamp.d.ts +13 -0
- package/lib-esm/components/timestamp.js +33 -0
- package/lib-esm/components/tooltip.d.ts +8 -0
- package/lib-esm/components/tooltip.js +99 -0
- package/lib-esm/components/transition-component.d.ts +30 -0
- package/lib-esm/components/transition-component.js +72 -0
- package/lib-esm/components/typography.d.ts +9 -0
- package/lib-esm/components/typography.js +38 -0
- package/lib-esm/components/widget-link.d.ts +10 -0
- package/lib-esm/components/widget-link.js +88 -0
- package/lib-esm/contexts/index.d.ts +9 -0
- package/lib-esm/contexts/index.js +12 -0
- package/lib-esm/create-react-component.d.ts +11 -0
- package/lib-esm/create-react-component.js +16 -0
- package/lib-esm/hooks/index.d.ts +27 -0
- package/lib-esm/hooks/index.js +26 -0
- package/lib-esm/hooks/use-action.d.ts +4 -0
- package/lib-esm/hooks/use-action.js +14 -0
- package/lib-esm/hooks/use-children.d.ts +4 -0
- package/lib-esm/hooks/use-children.js +65 -0
- package/lib-esm/hooks/use-columns.d.ts +2 -0
- package/lib-esm/hooks/use-columns.js +4 -0
- package/lib-esm/hooks/use-component-descriptor.d.ts +2 -0
- package/lib-esm/hooks/use-component-descriptor.js +4 -0
- package/lib-esm/hooks/use-component-node.d.ts +6 -0
- package/lib-esm/hooks/use-component-node.js +35 -0
- package/lib-esm/hooks/use-component-platform.d.ts +4 -0
- package/lib-esm/hooks/use-component-platform.js +34 -0
- package/lib-esm/hooks/use-component.d.ts +3 -0
- package/lib-esm/hooks/use-component.js +52 -0
- package/lib-esm/hooks/use-container.d.ts +2 -0
- package/lib-esm/hooks/use-container.js +4 -0
- package/lib-esm/hooks/use-context.d.ts +3 -0
- package/lib-esm/hooks/use-context.js +45 -0
- package/lib-esm/hooks/use-dispatch.d.ts +3 -0
- package/lib-esm/hooks/use-dispatch.js +59 -0
- package/lib-esm/hooks/use-event-listener.d.ts +2 -0
- package/lib-esm/hooks/use-event-listener.js +19 -0
- package/lib-esm/hooks/use-events.d.ts +3 -0
- package/lib-esm/hooks/use-events.js +7 -0
- package/lib-esm/hooks/use-is-mounted.d.ts +3 -0
- package/lib-esm/hooks/use-is-mounted.js +12 -0
- package/lib-esm/hooks/use-key-press.d.ts +2 -0
- package/lib-esm/hooks/use-key-press.js +41 -0
- package/lib-esm/hooks/use-layout.d.ts +3 -0
- package/lib-esm/hooks/use-layout.js +45 -0
- package/lib-esm/hooks/use-previous.d.ts +2 -0
- package/lib-esm/hooks/use-previous.js +9 -0
- package/lib-esm/hooks/use-properties.d.ts +6 -0
- package/lib-esm/hooks/use-properties.js +7 -0
- package/lib-esm/hooks/use-render-state.d.ts +4 -0
- package/lib-esm/hooks/use-render-state.js +61 -0
- package/lib-esm/hooks/use-route-data.d.ts +4 -0
- package/lib-esm/hooks/use-route-data.js +49 -0
- package/lib-esm/hooks/use-router.d.ts +3 -0
- package/lib-esm/hooks/use-router.js +7 -0
- package/lib-esm/hooks/use-scroll.d.ts +2 -0
- package/lib-esm/hooks/use-scroll.js +66 -0
- package/lib-esm/hooks/use-settings.d.ts +3 -0
- package/lib-esm/hooks/use-settings.js +33 -0
- package/lib-esm/hooks/use-toggle.d.ts +2 -0
- package/lib-esm/hooks/use-toggle.js +26 -0
- package/lib-esm/hooks/use-transition-end.d.ts +2 -0
- package/lib-esm/hooks/use-transition-end.js +60 -0
- package/lib-esm/hooks/use-unique-menu.d.ts +2 -0
- package/lib-esm/hooks/use-unique-menu.js +10 -0
- package/lib-esm/hooks/use-widget-event.d.ts +3 -0
- package/lib-esm/hooks/use-widget-event.js +16 -0
- package/lib-esm/index.d.ts +9 -0
- package/lib-esm/index.js +7 -0
- package/lib-esm/styles.d.ts +19 -0
- package/lib-esm/styles.js +26 -0
- package/lib-esm/utils/animations.d.ts +18 -0
- package/lib-esm/utils/animations.js +101 -0
- package/lib-esm/utils/browser.d.ts +12 -0
- package/lib-esm/utils/browser.js +51 -0
- package/lib-esm/utils/convert-to-string-attributes.d.ts +2 -0
- package/lib-esm/utils/convert-to-string-attributes.js +21 -0
- package/lib-esm/utils/create-empty-component.d.ts +4 -0
- package/lib-esm/utils/create-empty-component.js +20 -0
- package/lib-esm/utils/embedded-link-mapper.d.ts +4 -0
- package/lib-esm/utils/embedded-link-mapper.js +57 -0
- package/lib-esm/utils/filter-css-props.d.ts +8 -0
- package/lib-esm/utils/filter-css-props.js +25 -0
- package/lib-esm/utils/generic-hash-link.d.ts +8 -0
- package/lib-esm/utils/generic-hash-link.js +63 -0
- package/lib-esm/utils/heading-styles.d.ts +1 -0
- package/lib-esm/utils/heading-styles.js +44 -0
- package/lib-esm/utils/index.d.ts +12 -0
- package/lib-esm/utils/index.js +10 -0
- package/lib-esm/utils/process-html-string.d.ts +4 -0
- package/lib-esm/utils/process-html-string.js +10 -0
- package/lib-esm/utils/render-instructions.d.ts +8 -0
- package/lib-esm/utils/render-instructions.js +12 -0
- package/package.json +47 -0
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
var __read = (this && this.__read) || function (o, n) {
|
|
2
|
+
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
3
|
+
if (!m) return o;
|
|
4
|
+
var i = m.call(o), r, ar = [], e;
|
|
5
|
+
try {
|
|
6
|
+
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
|
|
7
|
+
}
|
|
8
|
+
catch (error) { e = { error: error }; }
|
|
9
|
+
finally {
|
|
10
|
+
try {
|
|
11
|
+
if (r && !r.done && (m = i["return"])) m.call(i);
|
|
12
|
+
}
|
|
13
|
+
finally { if (e) throw e.error; }
|
|
14
|
+
}
|
|
15
|
+
return ar;
|
|
16
|
+
};
|
|
17
|
+
import { ComponentQuery } from '@telia-ace/widget-core';
|
|
18
|
+
import { uuid } from '@telia-ace/widget-utilities';
|
|
19
|
+
import { useEffect, useState } from 'react';
|
|
20
|
+
import useComponentDescriptor from './use-component-descriptor';
|
|
21
|
+
import useComponentPlatform from './use-component-platform';
|
|
22
|
+
var useDispatch = function () {
|
|
23
|
+
var components = useComponentPlatform();
|
|
24
|
+
var descriptor = useComponentDescriptor();
|
|
25
|
+
var _a = __read(useState([]), 2), queue = _a[0], setQueue = _a[1];
|
|
26
|
+
var _b = __read(useState(), 2), actions = _b[0], setActions = _b[1];
|
|
27
|
+
useEffect(function () {
|
|
28
|
+
if (components && descriptor) {
|
|
29
|
+
var component = new ComponentQuery(components).withId(descriptor.id);
|
|
30
|
+
var actions_1 = components.actions(component, descriptor.type || uuid());
|
|
31
|
+
setActions(actions_1);
|
|
32
|
+
// process the queue and set it to null
|
|
33
|
+
if (queue !== null) {
|
|
34
|
+
queue.forEach(function (item) {
|
|
35
|
+
actions_1
|
|
36
|
+
.dispatch(item.key, item.data)
|
|
37
|
+
.then(function (value) { return item.resolve(value); })
|
|
38
|
+
.catch(function (reason) { return item.reject(reason); });
|
|
39
|
+
});
|
|
40
|
+
setQueue(null);
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
}, [components, descriptor.id]);
|
|
44
|
+
return function (key, data) {
|
|
45
|
+
if (queue !== null) {
|
|
46
|
+
// if queue is available the actions controller is not yet created
|
|
47
|
+
return new Promise(function (resolve, reject) {
|
|
48
|
+
queue.push({
|
|
49
|
+
key: key,
|
|
50
|
+
data: data,
|
|
51
|
+
resolve: resolve,
|
|
52
|
+
reject: reject,
|
|
53
|
+
});
|
|
54
|
+
});
|
|
55
|
+
}
|
|
56
|
+
return actions.dispatch(key, data);
|
|
57
|
+
};
|
|
58
|
+
};
|
|
59
|
+
export default useDispatch;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { useEffect, useRef } from 'react';
|
|
2
|
+
export default (function (eventName, handler, element, condition) {
|
|
3
|
+
if (element === void 0) { element = window; }
|
|
4
|
+
if (condition === void 0) { condition = function () { return true; }; }
|
|
5
|
+
var savedHandler = useRef(function () { });
|
|
6
|
+
useEffect(function () {
|
|
7
|
+
savedHandler.current = handler;
|
|
8
|
+
}, [handler]);
|
|
9
|
+
useEffect(function () {
|
|
10
|
+
var isSupported = element && condition();
|
|
11
|
+
if (!isSupported)
|
|
12
|
+
return;
|
|
13
|
+
var eventListener = function (event) { return savedHandler.current(event); };
|
|
14
|
+
element.addEventListener(eventName, eventListener);
|
|
15
|
+
return function () {
|
|
16
|
+
element.removeEventListener(eventName, eventListener);
|
|
17
|
+
};
|
|
18
|
+
}, [eventName, element]);
|
|
19
|
+
});
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { useEffect, useRef } from 'react';
|
|
2
|
+
var useIsMounted = function () {
|
|
3
|
+
var isMounted = useRef(false);
|
|
4
|
+
useEffect(function () {
|
|
5
|
+
isMounted.current = true;
|
|
6
|
+
return function () {
|
|
7
|
+
isMounted.current = false;
|
|
8
|
+
};
|
|
9
|
+
}, []);
|
|
10
|
+
return isMounted;
|
|
11
|
+
};
|
|
12
|
+
export default useIsMounted;
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
var __read = (this && this.__read) || function (o, n) {
|
|
2
|
+
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
3
|
+
if (!m) return o;
|
|
4
|
+
var i = m.call(o), r, ar = [], e;
|
|
5
|
+
try {
|
|
6
|
+
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
|
|
7
|
+
}
|
|
8
|
+
catch (error) { e = { error: error }; }
|
|
9
|
+
finally {
|
|
10
|
+
try {
|
|
11
|
+
if (r && !r.done && (m = i["return"])) m.call(i);
|
|
12
|
+
}
|
|
13
|
+
finally { if (e) throw e.error; }
|
|
14
|
+
}
|
|
15
|
+
return ar;
|
|
16
|
+
};
|
|
17
|
+
import { useCallback, useState } from 'react';
|
|
18
|
+
import useEventListener from './use-event-listener';
|
|
19
|
+
var useKeyPress = function (targetKey, action) {
|
|
20
|
+
// State for keeping track of whether key is pressed
|
|
21
|
+
var _a = __read(useState(false), 2), keyPressed = _a[0], setKeyPressed = _a[1];
|
|
22
|
+
var onKeyDown = useCallback(function (event) {
|
|
23
|
+
var key = event.key;
|
|
24
|
+
if (key === targetKey) {
|
|
25
|
+
setKeyPressed(true);
|
|
26
|
+
if (action) {
|
|
27
|
+
action(event);
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
}, [setKeyPressed, action]);
|
|
31
|
+
var onKeyUp = useCallback(function (_a) {
|
|
32
|
+
var key = _a.key;
|
|
33
|
+
if (key === targetKey) {
|
|
34
|
+
setKeyPressed(false);
|
|
35
|
+
}
|
|
36
|
+
}, [setKeyPressed]);
|
|
37
|
+
useEventListener('keydown', onKeyDown, window);
|
|
38
|
+
useEventListener('keyup', onKeyUp, window);
|
|
39
|
+
return keyPressed;
|
|
40
|
+
};
|
|
41
|
+
export default useKeyPress;
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
var __read = (this && this.__read) || function (o, n) {
|
|
2
|
+
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
3
|
+
if (!m) return o;
|
|
4
|
+
var i = m.call(o), r, ar = [], e;
|
|
5
|
+
try {
|
|
6
|
+
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
|
|
7
|
+
}
|
|
8
|
+
catch (error) { e = { error: error }; }
|
|
9
|
+
finally {
|
|
10
|
+
try {
|
|
11
|
+
if (r && !r.done && (m = i["return"])) m.call(i);
|
|
12
|
+
}
|
|
13
|
+
finally { if (e) throw e.error; }
|
|
14
|
+
}
|
|
15
|
+
return ar;
|
|
16
|
+
};
|
|
17
|
+
import { useEffect, useState } from 'react';
|
|
18
|
+
import useComponentNode from './use-component-node';
|
|
19
|
+
import useComponentPlatform from './use-component-platform';
|
|
20
|
+
import useIsMounted from './use-is-mounted';
|
|
21
|
+
var useLayout = function (id) {
|
|
22
|
+
var node = useComponentNode(id);
|
|
23
|
+
var components = useComponentPlatform();
|
|
24
|
+
var _a = __read(useState({}), 2), layout = _a[0], setLayout = _a[1];
|
|
25
|
+
var isMounted = useIsMounted();
|
|
26
|
+
useEffect(function () {
|
|
27
|
+
if (node && isMounted.current) {
|
|
28
|
+
setLayout(node.attributes.layout);
|
|
29
|
+
}
|
|
30
|
+
}, [node, isMounted]);
|
|
31
|
+
useEffect(function () {
|
|
32
|
+
if (components) {
|
|
33
|
+
var unsubscribe_1 = components.events.subscribe('components:layout-changed', function (event, data) {
|
|
34
|
+
if (node === data.node && isMounted.current) {
|
|
35
|
+
setLayout(data.node.attributes.layout);
|
|
36
|
+
}
|
|
37
|
+
});
|
|
38
|
+
return function () {
|
|
39
|
+
unsubscribe_1();
|
|
40
|
+
};
|
|
41
|
+
}
|
|
42
|
+
}, [components, isMounted]);
|
|
43
|
+
return layout;
|
|
44
|
+
};
|
|
45
|
+
export default useLayout;
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
var __read = (this && this.__read) || function (o, n) {
|
|
2
|
+
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
3
|
+
if (!m) return o;
|
|
4
|
+
var i = m.call(o), r, ar = [], e;
|
|
5
|
+
try {
|
|
6
|
+
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
|
|
7
|
+
}
|
|
8
|
+
catch (error) { e = { error: error }; }
|
|
9
|
+
finally {
|
|
10
|
+
try {
|
|
11
|
+
if (r && !r.done && (m = i["return"])) m.call(i);
|
|
12
|
+
}
|
|
13
|
+
finally { if (e) throw e.error; }
|
|
14
|
+
}
|
|
15
|
+
return ar;
|
|
16
|
+
};
|
|
17
|
+
import { WidgetRenderState } from '@telia-ace/widget-core';
|
|
18
|
+
import { useEffect, useState } from 'react';
|
|
19
|
+
import useContainer from './use-container';
|
|
20
|
+
import useIsMounted from './use-is-mounted';
|
|
21
|
+
var useRenderState = function (passedContainer) {
|
|
22
|
+
var _a = __read(useState(), 2), renderState = _a[0], setRenderState = _a[1];
|
|
23
|
+
var container = useContainer();
|
|
24
|
+
var isMounted = useIsMounted();
|
|
25
|
+
useEffect(function () {
|
|
26
|
+
var unsubscribe;
|
|
27
|
+
var _a = (passedContainer || container).get('$widget'), name = _a.name, invoke = _a.invoke;
|
|
28
|
+
invoke('renderState').then(function (renderState) {
|
|
29
|
+
if (isMounted.current) {
|
|
30
|
+
setRenderState(renderState);
|
|
31
|
+
}
|
|
32
|
+
});
|
|
33
|
+
(passedContainer || container)
|
|
34
|
+
.getAsync('actionResolver')
|
|
35
|
+
.then(function (actionResolver) {
|
|
36
|
+
unsubscribe = actionResolver.subscribe(name, function (origin, action) {
|
|
37
|
+
switch (action) {
|
|
38
|
+
case 'close':
|
|
39
|
+
case 'open':
|
|
40
|
+
if (isMounted.current) {
|
|
41
|
+
setRenderState(action === 'open'
|
|
42
|
+
? WidgetRenderState.open
|
|
43
|
+
: WidgetRenderState.closed);
|
|
44
|
+
}
|
|
45
|
+
break;
|
|
46
|
+
case 'hide':
|
|
47
|
+
if (isMounted.current) {
|
|
48
|
+
setRenderState(WidgetRenderState.hidden);
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
});
|
|
52
|
+
});
|
|
53
|
+
return function () {
|
|
54
|
+
if (unsubscribe) {
|
|
55
|
+
unsubscribe();
|
|
56
|
+
}
|
|
57
|
+
};
|
|
58
|
+
}, [isMounted]);
|
|
59
|
+
return renderState;
|
|
60
|
+
};
|
|
61
|
+
export default useRenderState;
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
var __read = (this && this.__read) || function (o, n) {
|
|
2
|
+
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
3
|
+
if (!m) return o;
|
|
4
|
+
var i = m.call(o), r, ar = [], e;
|
|
5
|
+
try {
|
|
6
|
+
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
|
|
7
|
+
}
|
|
8
|
+
catch (error) { e = { error: error }; }
|
|
9
|
+
finally {
|
|
10
|
+
try {
|
|
11
|
+
if (r && !r.done && (m = i["return"])) m.call(i);
|
|
12
|
+
}
|
|
13
|
+
finally { if (e) throw e.error; }
|
|
14
|
+
}
|
|
15
|
+
return ar;
|
|
16
|
+
};
|
|
17
|
+
import { removeNullAndUndefinedValues } from '@telia-ace/widget-utilities';
|
|
18
|
+
import { useEffect, useState } from 'react';
|
|
19
|
+
import useContainer from './use-container';
|
|
20
|
+
import useIsMounted from './use-is-mounted';
|
|
21
|
+
import useRouter from './use-router';
|
|
22
|
+
var useRouteData = function (passedContainer) {
|
|
23
|
+
var container = useContainer();
|
|
24
|
+
var router = useRouter();
|
|
25
|
+
var _a = __read(useState({ name: '', params: {} }), 2), routeData = _a[0], setRouteData = _a[1];
|
|
26
|
+
var isMounted = useIsMounted();
|
|
27
|
+
useEffect(function () {
|
|
28
|
+
var events = (passedContainer || container).get('$widget').events;
|
|
29
|
+
var unsubscribe = events.subscribe('router:change', function (e, _a) {
|
|
30
|
+
var routeData = _a.next.routeData;
|
|
31
|
+
if (isMounted.current) {
|
|
32
|
+
var name_1 = routeData.name, params = routeData.params;
|
|
33
|
+
removeNullAndUndefinedValues(params);
|
|
34
|
+
setRouteData({ name: name_1, params: params });
|
|
35
|
+
}
|
|
36
|
+
});
|
|
37
|
+
return unsubscribe;
|
|
38
|
+
}, [isMounted]);
|
|
39
|
+
useEffect(function () {
|
|
40
|
+
if (router && router.history && isMounted.current) {
|
|
41
|
+
var routeData_1 = router.getRouteData();
|
|
42
|
+
var name_2 = routeData_1.name, params = routeData_1.params;
|
|
43
|
+
removeNullAndUndefinedValues(params);
|
|
44
|
+
setRouteData({ name: name_2, params: params });
|
|
45
|
+
}
|
|
46
|
+
}, [router, isMounted]);
|
|
47
|
+
return routeData;
|
|
48
|
+
};
|
|
49
|
+
export default useRouteData;
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
import { useCallback, useRef } from 'react';
|
|
2
|
+
import { browser, Browsers } from '../utils';
|
|
3
|
+
import useEventListener from './use-event-listener';
|
|
4
|
+
export default (function (scrollable) {
|
|
5
|
+
var elem = useRef();
|
|
6
|
+
var previousY = useRef(0);
|
|
7
|
+
var timeoutId;
|
|
8
|
+
var onScroll = useCallback(function () {
|
|
9
|
+
var _a;
|
|
10
|
+
(_a = elem.current) === null || _a === void 0 ? void 0 : _a.classList.add('humany-scrolling');
|
|
11
|
+
clearTimeout(timeoutId);
|
|
12
|
+
timeoutId = setTimeout(function () {
|
|
13
|
+
var _a;
|
|
14
|
+
(_a = elem.current) === null || _a === void 0 ? void 0 : _a.classList.remove('humany-scrolling');
|
|
15
|
+
}, 500);
|
|
16
|
+
}, [elem]);
|
|
17
|
+
var onTouchStart = useCallback(function (event) {
|
|
18
|
+
previousY.current = event.touches[0].clientY;
|
|
19
|
+
}, [elem]);
|
|
20
|
+
var traverseScrollable = function (element) {
|
|
21
|
+
if (isScrollable(element)) {
|
|
22
|
+
if (element === elem.current) {
|
|
23
|
+
return element;
|
|
24
|
+
}
|
|
25
|
+
return null;
|
|
26
|
+
}
|
|
27
|
+
if (element.parentElement) {
|
|
28
|
+
return traverseScrollable(element.parentElement);
|
|
29
|
+
}
|
|
30
|
+
return null;
|
|
31
|
+
};
|
|
32
|
+
var isScrollable = function (element) {
|
|
33
|
+
return (element.scrollWidth > element.clientWidth || element.scrollHeight > element.clientHeight);
|
|
34
|
+
};
|
|
35
|
+
var onTouchMove = useCallback(function (event) {
|
|
36
|
+
if (!event.cancelable) {
|
|
37
|
+
return;
|
|
38
|
+
}
|
|
39
|
+
var top = event.touches[0].clientY;
|
|
40
|
+
var firstScrollable = traverseScrollable(event.target);
|
|
41
|
+
if (!firstScrollable) {
|
|
42
|
+
return;
|
|
43
|
+
}
|
|
44
|
+
var scrollTop = firstScrollable.scrollTop;
|
|
45
|
+
var direction = previousY.current - top < 0 ? 'up' : 'down';
|
|
46
|
+
var isAtTop = scrollTop <= 0 && direction === 'up';
|
|
47
|
+
var isAtBottom = scrollTop >= firstScrollable.scrollHeight - firstScrollable.offsetHeight &&
|
|
48
|
+
direction === 'down';
|
|
49
|
+
if (isAtTop || isAtBottom) {
|
|
50
|
+
// Don't scroll up if already at top,
|
|
51
|
+
// and don't scroll down if bottom has been reached
|
|
52
|
+
event.preventDefault();
|
|
53
|
+
}
|
|
54
|
+
previousY.current = top;
|
|
55
|
+
}, [elem, previousY]);
|
|
56
|
+
useEventListener('scroll', onScroll, elem.current, function () { return elem.current && scrollable; });
|
|
57
|
+
// This will prevent scrolling causing browser
|
|
58
|
+
// to freeze on Safari / Chrome on iOS
|
|
59
|
+
useEventListener('touchstart', onTouchStart, elem.current, function () { return elem.current && scrollable; });
|
|
60
|
+
useEventListener('touchmove', onTouchMove, elem.current, function () { return elem.current && scrollable; });
|
|
61
|
+
if (!scrollable) {
|
|
62
|
+
return ['', elem];
|
|
63
|
+
}
|
|
64
|
+
return [styling, elem];
|
|
65
|
+
});
|
|
66
|
+
var styling = "\n overflow-y: ".concat(browser() === Browsers.Chrome || browser() === Browsers.EdgeChromium ? 'overlay' : 'auto', ";\n overflow-x: hidden;\n -ms-overflow-style: none; /* IE 10+ */\n scrollbar-width: thin; /* Firefox */\n scrollbar-color: transparent transparent; /* Firefox */\n\n ::-webkit-scrollbar {\n width: 3px !important;\n background-color: transparent;\n border-left: none;\n }\n ::-webkit-scrollbar-thumb {\n background-color: transparent;\n }\n ::-webkit-scrollbar-track {\n -webkit-box-shadow: none !important;\n background-color: transparent;\n }\n &.humany-scrolling {\n scrollbar-color: #7F7F7F transparent;\n scrollbar-width: thin; /* Firefox */\n -ms-overflow-style: none; /* IE 10+ */\n\n ::-webkit-scrollbar-thumb {\n background-color: #7F7F7F;\n }\n }\n");
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
var __read = (this && this.__read) || function (o, n) {
|
|
2
|
+
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
3
|
+
if (!m) return o;
|
|
4
|
+
var i = m.call(o), r, ar = [], e;
|
|
5
|
+
try {
|
|
6
|
+
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
|
|
7
|
+
}
|
|
8
|
+
catch (error) { e = { error: error }; }
|
|
9
|
+
finally {
|
|
10
|
+
try {
|
|
11
|
+
if (r && !r.done && (m = i["return"])) m.call(i);
|
|
12
|
+
}
|
|
13
|
+
finally { if (e) throw e.error; }
|
|
14
|
+
}
|
|
15
|
+
return ar;
|
|
16
|
+
};
|
|
17
|
+
import { useEffect, useState } from 'react';
|
|
18
|
+
import useContainer from './use-container';
|
|
19
|
+
import useIsMounted from './use-is-mounted';
|
|
20
|
+
var useSettings = function () {
|
|
21
|
+
var _a = __read(useState(null), 2), settings = _a[0], setSettings = _a[1];
|
|
22
|
+
var container = useContainer();
|
|
23
|
+
var isMounted = useIsMounted();
|
|
24
|
+
useEffect(function () {
|
|
25
|
+
container.get('settings').then(function (settings) {
|
|
26
|
+
if (isMounted.current) {
|
|
27
|
+
setSettings(settings);
|
|
28
|
+
}
|
|
29
|
+
});
|
|
30
|
+
}, [isMounted]);
|
|
31
|
+
return settings;
|
|
32
|
+
};
|
|
33
|
+
export default useSettings;
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
var __read = (this && this.__read) || function (o, n) {
|
|
2
|
+
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
3
|
+
if (!m) return o;
|
|
4
|
+
var i = m.call(o), r, ar = [], e;
|
|
5
|
+
try {
|
|
6
|
+
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
|
|
7
|
+
}
|
|
8
|
+
catch (error) { e = { error: error }; }
|
|
9
|
+
finally {
|
|
10
|
+
try {
|
|
11
|
+
if (r && !r.done && (m = i["return"])) m.call(i);
|
|
12
|
+
}
|
|
13
|
+
finally { if (e) throw e.error; }
|
|
14
|
+
}
|
|
15
|
+
return ar;
|
|
16
|
+
};
|
|
17
|
+
import { useCallback, useState } from 'react';
|
|
18
|
+
var useToggle = function (initialValue) {
|
|
19
|
+
if (initialValue === void 0) { initialValue = false; }
|
|
20
|
+
var _a = __read(useState(initialValue), 2), value = _a[0], setValue = _a[1];
|
|
21
|
+
var toggle = useCallback(function (forced) {
|
|
22
|
+
setValue(typeof forced === 'boolean' ? forced : function (v) { return !v; });
|
|
23
|
+
}, []);
|
|
24
|
+
return [value, toggle];
|
|
25
|
+
};
|
|
26
|
+
export default useToggle;
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
var __read = (this && this.__read) || function (o, n) {
|
|
2
|
+
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
3
|
+
if (!m) return o;
|
|
4
|
+
var i = m.call(o), r, ar = [], e;
|
|
5
|
+
try {
|
|
6
|
+
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
|
|
7
|
+
}
|
|
8
|
+
catch (error) { e = { error: error }; }
|
|
9
|
+
finally {
|
|
10
|
+
try {
|
|
11
|
+
if (r && !r.done && (m = i["return"])) m.call(i);
|
|
12
|
+
}
|
|
13
|
+
finally { if (e) throw e.error; }
|
|
14
|
+
}
|
|
15
|
+
return ar;
|
|
16
|
+
};
|
|
17
|
+
import { useCallback, useEffect, useState } from 'react';
|
|
18
|
+
import { useComponentPlatform, useContainer, useEventListener, useIsMounted } from '.';
|
|
19
|
+
export default (function (handler) {
|
|
20
|
+
var container = useContainer();
|
|
21
|
+
var components = useComponentPlatform();
|
|
22
|
+
var widgetDOMElement = container.get('widgetDOMElement');
|
|
23
|
+
var _a = __read(useState(null), 2), viewDOMElement = _a[0], setViewDOMElement = _a[1];
|
|
24
|
+
var _b = __read(useState(null), 2), rootDOMElement = _b[0], setRootDOMElement = _b[1];
|
|
25
|
+
var isMounted = useIsMounted();
|
|
26
|
+
useEffect(function () {
|
|
27
|
+
if (components && isMounted.current) {
|
|
28
|
+
var rootArea = components.nodes.all.find(function (n) { return n.name === 'root-area'; });
|
|
29
|
+
var view = components.nodes.all.find(function (n) { return n.type === 'view'; });
|
|
30
|
+
if (!(view === null || view === void 0 ? void 0 : view.attributes.properties.animation) &&
|
|
31
|
+
!(rootArea === null || rootArea === void 0 ? void 0 : rootArea.attributes.properties.animation)) {
|
|
32
|
+
// if view and root does not use animations, call handler on render
|
|
33
|
+
handler();
|
|
34
|
+
}
|
|
35
|
+
else {
|
|
36
|
+
// else add elements to state for transitionend-event handling
|
|
37
|
+
var getElement = function (id) {
|
|
38
|
+
if (id === void 0) { id = ''; }
|
|
39
|
+
return widgetDOMElement === null || widgetDOMElement === void 0 ? void 0 : widgetDOMElement.querySelector("[data-node-id=\"".concat(id, "\"]"));
|
|
40
|
+
};
|
|
41
|
+
var viewDOMElement_1 = getElement(view === null || view === void 0 ? void 0 : view.id);
|
|
42
|
+
if (viewDOMElement_1) {
|
|
43
|
+
setViewDOMElement(viewDOMElement_1);
|
|
44
|
+
}
|
|
45
|
+
var rootDOMElement_1 = getElement(rootArea === null || rootArea === void 0 ? void 0 : rootArea.id);
|
|
46
|
+
if (rootDOMElement_1) {
|
|
47
|
+
setRootDOMElement(rootDOMElement_1);
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
}, [components, container, isMounted]);
|
|
52
|
+
var eventListener = useCallback(function (event) {
|
|
53
|
+
if (isMounted.current &&
|
|
54
|
+
(event.target === viewDOMElement || event.target === rootDOMElement)) {
|
|
55
|
+
handler();
|
|
56
|
+
}
|
|
57
|
+
}, [handler, isMounted, viewDOMElement, rootDOMElement]);
|
|
58
|
+
useEventListener('transitionend', eventListener, viewDOMElement);
|
|
59
|
+
useEventListener('transitionend', eventListener, rootDOMElement);
|
|
60
|
+
});
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import useWidgetEvent from './use-widget-event';
|
|
2
|
+
var useUniqueMenu = function (id, callback) {
|
|
3
|
+
var dispatch = useWidgetEvent('widget:menu-toggled', function (_, triggeredId) {
|
|
4
|
+
if (triggeredId !== id) {
|
|
5
|
+
callback();
|
|
6
|
+
}
|
|
7
|
+
});
|
|
8
|
+
return function () { return dispatch(id); };
|
|
9
|
+
};
|
|
10
|
+
export default useUniqueMenu;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { useEffect } from 'react';
|
|
2
|
+
import useEvents from './use-events';
|
|
3
|
+
var useWidgetEvent = function (event, callback, dependencies, passedContainer) {
|
|
4
|
+
if (dependencies === void 0) { dependencies = []; }
|
|
5
|
+
var events = useEvents(passedContainer);
|
|
6
|
+
useEffect(function () {
|
|
7
|
+
if (events) {
|
|
8
|
+
var unsubscribe_1 = events.subscribe(event, callback);
|
|
9
|
+
return function () {
|
|
10
|
+
unsubscribe_1();
|
|
11
|
+
};
|
|
12
|
+
}
|
|
13
|
+
}, [events].concat(dependencies));
|
|
14
|
+
return function (data) { return events === null || events === void 0 ? void 0 : events.dispatch(event, data); };
|
|
15
|
+
};
|
|
16
|
+
export default useWidgetEvent;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { AnchorLink, Button, ButtonProps, Checkbox, CheckboxProps, Confirm, DateFormats, Drawer, DrawerAnimationType, Dropdown, DropdownProps, Empty, EmptyProps, Grid, GridProps, Html, HtmlIconProps, HtmlParseInstruction, HtmlProps, Icon, IconProps, Input, InputProps, ItemList, ItemListProps, ItemRenderer, ItemTree, ItemTreeProps, Lightbox, LightboxProps, Link, LinkProps, List, ListProps, Modal, ModalProps, NotFound, NotFoundProps, Overlay, OverlayProps, Paragraph, ParagraphProps, Portal, PortalProps, RouteLink, RouteLinkProps, Symbol, SymbolBadge, SymbolBadgeProps, TabStop, TabStopProps, Text, TextLink, TextLinkProps, TextProps, Timestamp, TimestampProps, Tooltip, TooltipProps, TransitionComponent, TransitionComponentProps, Typography, TypographyProps, WidgetLink, WidgetLinkProps } from './components';
|
|
2
|
+
import { ColumnContext, ComponentNodeContext, ComponentPropertyContext, ContainerContext, RoutingContext } from './contexts';
|
|
3
|
+
import { default as createReactComponent } from './create-react-component';
|
|
4
|
+
import { DispatchAction, useAction, useChildren, useColumns, useComponent, useComponentDescriptor, useComponentNode, useComponentPlatform, useContainer, useContext, useDispatch, useEventListener, useEvents, useIsMounted, useKeyPress, useLayout, usePrevious, useProperties, useRenderState, useRouteData, useRouter, useScroll, useSettings, useToggle, useTransitionEnd, useUniqueMenu, useWidgetEvent } from './hooks';
|
|
5
|
+
import { borderTabStyle, buttonCss, contentBox, invertedHoverButton, itemList, linkTabStyle, list, paddedBorderTabStyle, StyledText } from './styles';
|
|
6
|
+
import { createEmptyComponent, filterCssProps, filterCssPropsStyle, headingElement, transitionComposer } from './utils';
|
|
7
|
+
export { AnchorLink, borderTabStyle, Button, buttonCss, Checkbox, ColumnContext, ComponentNodeContext, ComponentPropertyContext, Confirm, ContainerContext, contentBox, createEmptyComponent, createReactComponent, DateFormats, Drawer, DrawerAnimationType, Dropdown, filterCssProps, filterCssPropsStyle, Grid, headingElement, Html, Icon, Input, invertedHoverButton, ItemList, ItemTree, Lightbox, Link, linkTabStyle, List, paddedBorderTabStyle, RoutingContext, SymbolBadge, Text, TextLink, TransitionComponent, transitionComposer, Typography, useChildren, useColumns, useComponent, useComponentDescriptor, useComponentNode, useComponentPlatform, useContainer, useContext, useDispatch, useIsMounted, useLayout, useProperties, useRenderState, useRouteData, useRouter, useScroll, useTransitionEnd, useAction, useEventListener, useEvents, useKeyPress, usePrevious, useSettings, useToggle, useUniqueMenu, useWidgetEvent, Empty, Modal, NotFound, Overlay, Paragraph, Portal, RouteLink, TabStop, Timestamp, Tooltip, WidgetLink, itemList, list, StyledText, };
|
|
8
|
+
export type { ButtonProps, CheckboxProps, DropdownProps, EmptyProps, GridProps, HtmlIconProps, HtmlParseInstruction, HtmlProps, IconProps, InputProps, ItemListProps, ItemRenderer, ItemTreeProps, LightboxProps, LinkProps, ListProps, ModalProps, NotFoundProps, OverlayProps, ParagraphProps, PortalProps, RouteLinkProps, Symbol, SymbolBadgeProps, TabStopProps, TextLinkProps, TextProps, TimestampProps, TooltipProps, TransitionComponentProps, TypographyProps, WidgetLinkProps, };
|
|
9
|
+
export type { DispatchAction };
|