@momentum-design/components 0.116.1 → 0.117.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/dist/browser/index.js +315 -307
- package/dist/browser/index.js.map +4 -4
- package/dist/components/icon/icon.utils.d.ts +1 -1
- package/dist/components/icon/icon.utils.js +2 -2
- package/dist/components/iconprovider/iconprovider.component.d.ts +3 -1
- package/dist/components/iconprovider/iconprovider.component.js +1 -1
- package/dist/components/iconprovider/iconprovider.constants.d.ts +0 -1
- package/dist/components/iconprovider/iconprovider.constants.js +0 -1
- package/dist/components/illustration/illustration.component.d.ts +91 -0
- package/dist/components/illustration/illustration.component.js +220 -0
- package/dist/components/illustration/illustration.constants.d.ts +5 -0
- package/dist/components/illustration/illustration.constants.js +6 -0
- package/dist/components/illustration/illustration.styles.d.ts +2 -0
- package/dist/components/illustration/illustration.styles.js +15 -0
- package/dist/components/illustration/illustration.types.d.ts +2 -0
- package/dist/components/illustration/illustration.types.js +1 -0
- package/dist/components/illustration/illustration.utils.d.ts +32 -0
- package/dist/components/illustration/illustration.utils.js +79 -0
- package/dist/components/illustration/index.d.ts +7 -0
- package/dist/components/illustration/index.js +4 -0
- package/dist/components/illustrationprovider/illustrationprovider.component.d.ts +97 -0
- package/dist/components/illustrationprovider/illustrationprovider.component.js +123 -0
- package/dist/components/illustrationprovider/illustrationprovider.constants.d.ts +7 -0
- package/dist/components/illustrationprovider/illustrationprovider.constants.js +8 -0
- package/dist/components/illustrationprovider/illustrationprovider.context.d.ts +12 -0
- package/dist/components/illustrationprovider/illustrationprovider.context.js +7 -0
- package/dist/components/illustrationprovider/illustrationprovider.types.d.ts +3 -0
- package/dist/components/illustrationprovider/illustrationprovider.types.js +1 -0
- package/dist/components/illustrationprovider/index.d.ts +7 -0
- package/dist/components/illustrationprovider/index.js +4 -0
- package/dist/custom-elements.json +2076 -1742
- package/dist/index.d.ts +5 -3
- package/dist/index.js +5 -3
- package/dist/react/iconprovider/index.d.ts +1 -1
- package/dist/react/iconprovider/index.js +1 -1
- package/dist/react/illustration/index.d.ts +40 -0
- package/dist/react/illustration/index.js +49 -0
- package/dist/react/illustrationprovider/index.d.ts +31 -0
- package/dist/react/illustrationprovider/index.js +40 -0
- package/dist/react/index.d.ts +4 -2
- package/dist/react/index.js +4 -2
- package/dist/utils/{icon-cache → assets-cache}/index.d.ts +2 -2
- package/dist/utils/{icon-cache → assets-cache}/index.js +3 -3
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
@@ -25,6 +25,8 @@ import FilterChip from './components/filterchip';
|
|
25
25
|
import FormfieldGroup from './components/formfieldgroup';
|
26
26
|
import Icon from './components/icon';
|
27
27
|
import IconProvider from './components/iconprovider';
|
28
|
+
import Illustration from './components/illustration';
|
29
|
+
import IllustrationProvider from './components/illustrationprovider';
|
28
30
|
import Input from './components/input';
|
29
31
|
import InputChip from './components/inputchip';
|
30
32
|
import Link from './components/link';
|
@@ -93,7 +95,7 @@ import type { InputInputEvent, InputChangeEvent, InputFocusEvent, InputBlurEvent
|
|
93
95
|
import type { VirtualizedListScrollEvent } from './components/virtualizedlist/virtualizedlist.types';
|
94
96
|
import { BUTTON_COLORS, BUTTON_VARIANTS, ICON_BUTTON_SIZES, PILL_BUTTON_SIZES } from './components/button/button.constants';
|
95
97
|
import { SKELETON_VARIANTS } from './components/skeleton/skeleton.constants';
|
96
|
-
import { inMemoryCache,
|
97
|
-
export { Accordion, AccordionButton, AccordionGroup, AlertChip, Animation, Appheader, Avatar, AvatarButton, Badge, Brandvisual, Bullet, Button, ButtonGroup, ButtonLink, Card, CardButton, CardCheckbox, CardRadio, Checkbox, Chip, Coachmark, Dialog, Divider, FilterChip, FormfieldGroup, Icon, IconProvider, Input, InputChip, Link, LinkButton, Linksimple, List, Listheader, ListItem, Marker, MenuBar, MenuItem, MenuItemCheckbox, MenuItemRadio, MenuPopover, MenuSection, NavMenuItem, OptGroup, Option, Password, Popover, Presence, Progressbar, Progressspinner, Radio, RadioGroup, ScreenreaderAnnouncer, Searchfield, Select, SelectListbox, SideNavigation, Skeleton, Spinner, StaticChip, StaticCheckbox, StaticRadio, StaticToggle, Stepper, StepperConnector, StepperItem, Tab, TabList, Text, Textarea, ThemeProvider, Toast, Toggle, Typewriter, ToggleTip, Tooltip, VirtualizedList, Combobox, Slider, ListBox, Banner };
|
98
|
+
import { inMemoryCache, webAPIAssetsCache } from './utils/assets-cache';
|
99
|
+
export { Accordion, AccordionButton, AccordionGroup, AlertChip, Animation, Appheader, Avatar, AvatarButton, Badge, Brandvisual, Bullet, Button, ButtonGroup, ButtonLink, Card, CardButton, CardCheckbox, CardRadio, Checkbox, Chip, Coachmark, Dialog, Divider, FilterChip, FormfieldGroup, Icon, IconProvider, Illustration, IllustrationProvider, Input, InputChip, Link, LinkButton, Linksimple, List, Listheader, ListItem, Marker, MenuBar, MenuItem, MenuItemCheckbox, MenuItemRadio, MenuPopover, MenuSection, NavMenuItem, OptGroup, Option, Password, Popover, Presence, Progressbar, Progressspinner, Radio, RadioGroup, ScreenreaderAnnouncer, Searchfield, Select, SelectListbox, SideNavigation, Skeleton, Spinner, StaticChip, StaticCheckbox, StaticRadio, StaticToggle, Stepper, StepperConnector, StepperItem, Tab, TabList, Text, Textarea, ThemeProvider, Toast, Toggle, Typewriter, ToggleTip, Tooltip, VirtualizedList, Combobox, Slider, ListBox, Banner, };
|
98
100
|
export type { BadgeType, ButtonColor, ButtonVariant, IconButtonSize, MenuPopoverActionEvent, MenuPopoverChangeEvent, MenuSectionChangeEvent, PillButtonSize, PopoverPlacement, SkeletonVariant, SelectChangeEvent, SelectInputEvent, SpinnerSize, SpinnerVariant, TextType, TypewriterType, InputInputEvent, InputChangeEvent, InputFocusEvent, InputBlurEvent, InputClearEvent, VirtualizedListScrollEvent, };
|
99
|
-
export { BUTTON_COLORS, BUTTON_VARIANTS, ICON_BUTTON_SIZES, inMemoryCache, PILL_BUTTON_SIZES, SKELETON_VARIANTS,
|
101
|
+
export { BUTTON_COLORS, BUTTON_VARIANTS, ICON_BUTTON_SIZES, inMemoryCache, PILL_BUTTON_SIZES, SKELETON_VARIANTS, webAPIAssetsCache, };
|
package/dist/index.js
CHANGED
@@ -27,6 +27,8 @@ import FilterChip from './components/filterchip';
|
|
27
27
|
import FormfieldGroup from './components/formfieldgroup';
|
28
28
|
import Icon from './components/icon';
|
29
29
|
import IconProvider from './components/iconprovider';
|
30
|
+
import Illustration from './components/illustration';
|
31
|
+
import IllustrationProvider from './components/illustrationprovider';
|
30
32
|
import Input from './components/input';
|
31
33
|
import InputChip from './components/inputchip';
|
32
34
|
import Link from './components/link';
|
@@ -84,8 +86,8 @@ import Banner from './components/banner';
|
|
84
86
|
// Constants / Utils Imports
|
85
87
|
import { BUTTON_COLORS, BUTTON_VARIANTS, ICON_BUTTON_SIZES, PILL_BUTTON_SIZES, } from './components/button/button.constants';
|
86
88
|
import { SKELETON_VARIANTS } from './components/skeleton/skeleton.constants';
|
87
|
-
import { inMemoryCache,
|
89
|
+
import { inMemoryCache, webAPIAssetsCache } from './utils/assets-cache';
|
88
90
|
// Components Exports
|
89
|
-
export { Accordion, AccordionButton, AccordionGroup, AlertChip, Animation, Appheader, Avatar, AvatarButton, Badge, Brandvisual, Bullet, Button, ButtonGroup, ButtonLink, Card, CardButton, CardCheckbox, CardRadio, Checkbox, Chip, Coachmark, Dialog, Divider, FilterChip, FormfieldGroup, Icon, IconProvider, Input, InputChip, Link, LinkButton, Linksimple, List, Listheader, ListItem, Marker, MenuBar, MenuItem, MenuItemCheckbox, MenuItemRadio, MenuPopover, MenuSection, NavMenuItem, OptGroup, Option, Password, Popover, Presence, Progressbar, Progressspinner, Radio, RadioGroup, ScreenreaderAnnouncer, Searchfield, Select, SelectListbox, SideNavigation, Skeleton, Spinner, StaticChip, StaticCheckbox, StaticRadio, StaticToggle, Stepper, StepperConnector, StepperItem, Tab, TabList, Text, Textarea, ThemeProvider, Toast, Toggle, Typewriter, ToggleTip, Tooltip, VirtualizedList, Combobox, Slider, ListBox, Banner };
|
91
|
+
export { Accordion, AccordionButton, AccordionGroup, AlertChip, Animation, Appheader, Avatar, AvatarButton, Badge, Brandvisual, Bullet, Button, ButtonGroup, ButtonLink, Card, CardButton, CardCheckbox, CardRadio, Checkbox, Chip, Coachmark, Dialog, Divider, FilterChip, FormfieldGroup, Icon, IconProvider, Illustration, IllustrationProvider, Input, InputChip, Link, LinkButton, Linksimple, List, Listheader, ListItem, Marker, MenuBar, MenuItem, MenuItemCheckbox, MenuItemRadio, MenuPopover, MenuSection, NavMenuItem, OptGroup, Option, Password, Popover, Presence, Progressbar, Progressspinner, Radio, RadioGroup, ScreenreaderAnnouncer, Searchfield, Select, SelectListbox, SideNavigation, Skeleton, Spinner, StaticChip, StaticCheckbox, StaticRadio, StaticToggle, Stepper, StepperConnector, StepperItem, Tab, TabList, Text, Textarea, ThemeProvider, Toast, Toggle, Typewriter, ToggleTip, Tooltip, VirtualizedList, Combobox, Slider, ListBox, Banner, };
|
90
92
|
// Constants / Utils Exports
|
91
|
-
export { BUTTON_COLORS, BUTTON_VARIANTS, ICON_BUTTON_SIZES, inMemoryCache, PILL_BUTTON_SIZES, SKELETON_VARIANTS,
|
93
|
+
export { BUTTON_COLORS, BUTTON_VARIANTS, ICON_BUTTON_SIZES, inMemoryCache, PILL_BUTTON_SIZES, SKELETON_VARIANTS, webAPIAssetsCache, };
|
@@ -6,7 +6,7 @@ import Component from '../../components/iconprovider';
|
|
6
6
|
* Attribute `iconSet` can be set to either `momentum-icons` or `custom-icons`.
|
7
7
|
* If `momentum-icons` is selected, the icons will be fetched from the
|
8
8
|
* Momentum Design System icon set per a dynamic JS Import (no need to provide a URL).
|
9
|
-
* This requires the consumer to have the `@momentum-
|
9
|
+
* This requires the consumer to have the `@momentum-design/icons` package installed and the
|
10
10
|
* build tooling needs to support dynamic imports.
|
11
11
|
*
|
12
12
|
* If `custom-icons` is selected, the icons will be fetched from the provided URL.
|
@@ -9,7 +9,7 @@ import { TAG_NAME } from '../../components/iconprovider/iconprovider.constants';
|
|
9
9
|
* Attribute `iconSet` can be set to either `momentum-icons` or `custom-icons`.
|
10
10
|
* If `momentum-icons` is selected, the icons will be fetched from the
|
11
11
|
* Momentum Design System icon set per a dynamic JS Import (no need to provide a URL).
|
12
|
-
* This requires the consumer to have the `@momentum-
|
12
|
+
* This requires the consumer to have the `@momentum-design/icons` package installed and the
|
13
13
|
* build tooling needs to support dynamic imports.
|
14
14
|
*
|
15
15
|
* If `custom-icons` is selected, the icons will be fetched from the provided URL.
|
@@ -0,0 +1,40 @@
|
|
1
|
+
import Component from '../../components/illustration';
|
2
|
+
/**
|
3
|
+
* Illustration component that dynamically displays SVG illustrations based on a valid name.
|
4
|
+
*
|
5
|
+
* This component must be mounted within an `IllustrationProvider` component.
|
6
|
+
*
|
7
|
+
* The `IllustrationProvider` defines the source URL from which illustrations are consumed.
|
8
|
+
* The `Illustration` component accepts a `name` attribute, which corresponds to
|
9
|
+
* the file name of the illustration to be loaded from the specified URL.
|
10
|
+
*
|
11
|
+
* Once fetched, the illustration will be rendered. If the fetching process is unsuccessful,
|
12
|
+
* no illustration will be displayed.
|
13
|
+
*
|
14
|
+
* Default sizing of the illustration is controlled by choosing a different illustration name, can be overridden with the `--mdc-illustration-size` CSS property.
|
15
|
+
* Coloring of the illustration is currently baked into the svg, meaning that the illustration name determines
|
16
|
+
* the coloring.
|
17
|
+
*
|
18
|
+
* Regarding accessibility, there are two types of illustrations: decorative and informative.
|
19
|
+
*
|
20
|
+
* ### Decorative Illustrations
|
21
|
+
* - Decorative illustrations do not convey any essential information to the content of a page.
|
22
|
+
* - They should be hidden from screen readers (SR) to prevent confusion for users.
|
23
|
+
* - For decorative illustrations, an `aria-label` is not required, and the `role` will be set to null.
|
24
|
+
*
|
25
|
+
* ### Informative Illustrations
|
26
|
+
* - Informative illustrations convey important information that is not adequately represented
|
27
|
+
* by surrounding text or components.
|
28
|
+
* - They provide valuable context and must be announced by assistive technologies.
|
29
|
+
* - For informative illustrations, an `aria-label` is required, and the `role` will be set to "img" automatically.
|
30
|
+
* - If an `aria-label` is provided, the role will be set to 'img'; if it is absent,
|
31
|
+
* the role will be unset.
|
32
|
+
*
|
33
|
+
* @tagname mdc-illustration
|
34
|
+
*
|
35
|
+
* @cssproperty --mdc-illustration-size - Allows customization of the illustration size.
|
36
|
+
*
|
37
|
+
* @csspart illustration - The svg inside the illustration element.
|
38
|
+
*/
|
39
|
+
declare const reactWrapper: import("@lit/react").ReactWebComponent<Component, {}>;
|
40
|
+
export default reactWrapper;
|
@@ -0,0 +1,49 @@
|
|
1
|
+
import * as React from 'react';
|
2
|
+
import { createComponent } from '@lit/react';
|
3
|
+
import Component from '../../components/illustration';
|
4
|
+
import { TAG_NAME } from '../../components/illustration/illustration.constants';
|
5
|
+
/**
|
6
|
+
* Illustration component that dynamically displays SVG illustrations based on a valid name.
|
7
|
+
*
|
8
|
+
* This component must be mounted within an `IllustrationProvider` component.
|
9
|
+
*
|
10
|
+
* The `IllustrationProvider` defines the source URL from which illustrations are consumed.
|
11
|
+
* The `Illustration` component accepts a `name` attribute, which corresponds to
|
12
|
+
* the file name of the illustration to be loaded from the specified URL.
|
13
|
+
*
|
14
|
+
* Once fetched, the illustration will be rendered. If the fetching process is unsuccessful,
|
15
|
+
* no illustration will be displayed.
|
16
|
+
*
|
17
|
+
* Default sizing of the illustration is controlled by choosing a different illustration name, can be overridden with the `--mdc-illustration-size` CSS property.
|
18
|
+
* Coloring of the illustration is currently baked into the svg, meaning that the illustration name determines
|
19
|
+
* the coloring.
|
20
|
+
*
|
21
|
+
* Regarding accessibility, there are two types of illustrations: decorative and informative.
|
22
|
+
*
|
23
|
+
* ### Decorative Illustrations
|
24
|
+
* - Decorative illustrations do not convey any essential information to the content of a page.
|
25
|
+
* - They should be hidden from screen readers (SR) to prevent confusion for users.
|
26
|
+
* - For decorative illustrations, an `aria-label` is not required, and the `role` will be set to null.
|
27
|
+
*
|
28
|
+
* ### Informative Illustrations
|
29
|
+
* - Informative illustrations convey important information that is not adequately represented
|
30
|
+
* by surrounding text or components.
|
31
|
+
* - They provide valuable context and must be announced by assistive technologies.
|
32
|
+
* - For informative illustrations, an `aria-label` is required, and the `role` will be set to "img" automatically.
|
33
|
+
* - If an `aria-label` is provided, the role will be set to 'img'; if it is absent,
|
34
|
+
* the role will be unset.
|
35
|
+
*
|
36
|
+
* @tagname mdc-illustration
|
37
|
+
*
|
38
|
+
* @cssproperty --mdc-illustration-size - Allows customization of the illustration size.
|
39
|
+
*
|
40
|
+
* @csspart illustration - The svg inside the illustration element.
|
41
|
+
*/
|
42
|
+
const reactWrapper = createComponent({
|
43
|
+
tagName: TAG_NAME,
|
44
|
+
elementClass: Component,
|
45
|
+
react: React,
|
46
|
+
events: {},
|
47
|
+
displayName: 'Illustration',
|
48
|
+
});
|
49
|
+
export default reactWrapper;
|
@@ -0,0 +1,31 @@
|
|
1
|
+
import Component from '../../components/illustrationprovider';
|
2
|
+
/**
|
3
|
+
* IllustrationProvider component, which allows to be consumed from sub components
|
4
|
+
* (see `providerUtils.consume` for how to consume)
|
5
|
+
*
|
6
|
+
* Attribute `illustrationSet` can be set to either `momentum-illustrations` or `custom-illustrations`.
|
7
|
+
* If `momentum-illustrations` is selected, the illustrations will be fetched from the
|
8
|
+
* Momentum Design System illustration set per a dynamic JS Import (no need to provide a URL).
|
9
|
+
* This requires the consumer to have the `@momentum-design/illustrations` package installed and the
|
10
|
+
* build tooling needs to support dynamic imports.
|
11
|
+
*
|
12
|
+
* If `custom-illustrations` is selected, the illustrations will be fetched from the provided URL.
|
13
|
+
* This requires the consumer to provide a URL from which the illustrations will be fetched and
|
14
|
+
* the consumer needs to make sure to bundle the illustrations in the application.
|
15
|
+
*
|
16
|
+
* If `cacheStrategy` is provided (only works with illustrationSet = `custom-illustrations`), the
|
17
|
+
* IllustrationProvider will cache the illustrations in the selected cache (either web-api-cache or in-memory-cache),
|
18
|
+
* to avoid fetching the same illustration multiple times over the network.
|
19
|
+
* This is useful when the same illustration is used multiple times in the application.
|
20
|
+
* To consider:
|
21
|
+
* - The `in-memory-cache` is not persisted and will be lost when the
|
22
|
+
* IllustrationProvider is removed from the DOM.
|
23
|
+
* - The `web-api-cache` is persisted, but only works in https environments
|
24
|
+
* (https://developer.mozilla.org/en-US/docs/Web/API/Cache).
|
25
|
+
*
|
26
|
+
* @tagname mdc-illustrationprovider
|
27
|
+
*
|
28
|
+
* @slot - children
|
29
|
+
*/
|
30
|
+
declare const reactWrapper: import("@lit/react").ReactWebComponent<Component, {}>;
|
31
|
+
export default reactWrapper;
|
@@ -0,0 +1,40 @@
|
|
1
|
+
import * as React from 'react';
|
2
|
+
import { createComponent } from '@lit/react';
|
3
|
+
import Component from '../../components/illustrationprovider';
|
4
|
+
import { TAG_NAME } from '../../components/illustrationprovider/illustrationprovider.constants';
|
5
|
+
/**
|
6
|
+
* IllustrationProvider component, which allows to be consumed from sub components
|
7
|
+
* (see `providerUtils.consume` for how to consume)
|
8
|
+
*
|
9
|
+
* Attribute `illustrationSet` can be set to either `momentum-illustrations` or `custom-illustrations`.
|
10
|
+
* If `momentum-illustrations` is selected, the illustrations will be fetched from the
|
11
|
+
* Momentum Design System illustration set per a dynamic JS Import (no need to provide a URL).
|
12
|
+
* This requires the consumer to have the `@momentum-design/illustrations` package installed and the
|
13
|
+
* build tooling needs to support dynamic imports.
|
14
|
+
*
|
15
|
+
* If `custom-illustrations` is selected, the illustrations will be fetched from the provided URL.
|
16
|
+
* This requires the consumer to provide a URL from which the illustrations will be fetched and
|
17
|
+
* the consumer needs to make sure to bundle the illustrations in the application.
|
18
|
+
*
|
19
|
+
* If `cacheStrategy` is provided (only works with illustrationSet = `custom-illustrations`), the
|
20
|
+
* IllustrationProvider will cache the illustrations in the selected cache (either web-api-cache or in-memory-cache),
|
21
|
+
* to avoid fetching the same illustration multiple times over the network.
|
22
|
+
* This is useful when the same illustration is used multiple times in the application.
|
23
|
+
* To consider:
|
24
|
+
* - The `in-memory-cache` is not persisted and will be lost when the
|
25
|
+
* IllustrationProvider is removed from the DOM.
|
26
|
+
* - The `web-api-cache` is persisted, but only works in https environments
|
27
|
+
* (https://developer.mozilla.org/en-US/docs/Web/API/Cache).
|
28
|
+
*
|
29
|
+
* @tagname mdc-illustrationprovider
|
30
|
+
*
|
31
|
+
* @slot - children
|
32
|
+
*/
|
33
|
+
const reactWrapper = createComponent({
|
34
|
+
tagName: TAG_NAME,
|
35
|
+
elementClass: Component,
|
36
|
+
react: React,
|
37
|
+
events: {},
|
38
|
+
displayName: 'IllustrationProvider',
|
39
|
+
});
|
40
|
+
export default reactWrapper;
|
package/dist/react/index.d.ts
CHANGED
@@ -1,6 +1,6 @@
|
|
1
|
-
export { default as Accordion } from './accordion';
|
2
1
|
export { default as AccordionButton } from './accordionbutton';
|
3
2
|
export { default as AccordionGroup } from './accordiongroup';
|
3
|
+
export { default as Accordion } from './accordion';
|
4
4
|
export { default as AlertChip } from './alertchip';
|
5
5
|
export { default as Animation } from './animation';
|
6
6
|
export { default as Appheader } from './appheader';
|
@@ -29,6 +29,8 @@ export { default as FormfieldGroup } from './formfieldgroup';
|
|
29
29
|
export { default as FormfieldWrapper } from './formfieldwrapper';
|
30
30
|
export { default as Icon } from './icon';
|
31
31
|
export { default as IconProvider } from './iconprovider';
|
32
|
+
export { default as Illustration } from './illustration';
|
33
|
+
export { default as IllustrationProvider } from './illustrationprovider';
|
32
34
|
export { default as Input } from './input';
|
33
35
|
export { default as InputChip } from './inputchip';
|
34
36
|
export { default as Link } from './link';
|
@@ -56,8 +58,8 @@ export { default as Progressspinner } from './progressspinner';
|
|
56
58
|
export { default as Radio } from './radio';
|
57
59
|
export { default as RadioGroup } from './radiogroup';
|
58
60
|
export { default as ScreenreaderAnnouncer } from './screenreaderannouncer';
|
59
|
-
export { default as Select } from './select';
|
60
61
|
export { default as Searchfield } from './searchfield';
|
62
|
+
export { default as Select } from './select';
|
61
63
|
export { default as Selectlistbox } from './selectlistbox';
|
62
64
|
export { default as SideNavigation } from './sidenavigation';
|
63
65
|
export { default as Skeleton } from './skeleton';
|
package/dist/react/index.js
CHANGED
@@ -1,6 +1,6 @@
|
|
1
|
-
export { default as Accordion } from './accordion';
|
2
1
|
export { default as AccordionButton } from './accordionbutton';
|
3
2
|
export { default as AccordionGroup } from './accordiongroup';
|
3
|
+
export { default as Accordion } from './accordion';
|
4
4
|
export { default as AlertChip } from './alertchip';
|
5
5
|
export { default as Animation } from './animation';
|
6
6
|
export { default as Appheader } from './appheader';
|
@@ -29,6 +29,8 @@ export { default as FormfieldGroup } from './formfieldgroup';
|
|
29
29
|
export { default as FormfieldWrapper } from './formfieldwrapper';
|
30
30
|
export { default as Icon } from './icon';
|
31
31
|
export { default as IconProvider } from './iconprovider';
|
32
|
+
export { default as Illustration } from './illustration';
|
33
|
+
export { default as IllustrationProvider } from './illustrationprovider';
|
32
34
|
export { default as Input } from './input';
|
33
35
|
export { default as InputChip } from './inputchip';
|
34
36
|
export { default as Link } from './link';
|
@@ -56,8 +58,8 @@ export { default as Progressspinner } from './progressspinner';
|
|
56
58
|
export { default as Radio } from './radio';
|
57
59
|
export { default as RadioGroup } from './radiogroup';
|
58
60
|
export { default as ScreenreaderAnnouncer } from './screenreaderannouncer';
|
59
|
-
export { default as Select } from './select';
|
60
61
|
export { default as Searchfield } from './searchfield';
|
62
|
+
export { default as Select } from './select';
|
61
63
|
export { default as Selectlistbox } from './selectlistbox';
|
62
64
|
export { default as SideNavigation } from './sidenavigation';
|
63
65
|
export { default as Skeleton } from './skeleton';
|
@@ -14,7 +14,7 @@ export declare const inMemoryCache: (name: string) => Promise<{
|
|
14
14
|
* @param name - name of the cache (used as an identifier)
|
15
15
|
* @returns Object with set, get and delete methods
|
16
16
|
*/
|
17
|
-
export declare const
|
17
|
+
export declare const webAPIAssetsCache: (name: string) => Promise<{
|
18
18
|
set: (request: Request, response: Response) => Promise<void>;
|
19
19
|
get: (request: Request) => Promise<string | undefined>;
|
20
20
|
delete: (request: Request) => Promise<void>;
|
@@ -25,7 +25,7 @@ export declare const webAPIIconsCache: (name: string) => Promise<{
|
|
25
25
|
* @param cacheStrategy - strategy to be used for caching
|
26
26
|
* @returns the cache based on the strategy
|
27
27
|
*/
|
28
|
-
export declare const
|
28
|
+
export declare const assetsCache: (cacheName: string, cacheStrategy: CacheStrategy) => Promise<{
|
29
29
|
set(request: Request, response: Response): Promise<void>;
|
30
30
|
get(request: Request): Promise<string | undefined>;
|
31
31
|
delete(request: Request): Promise<void>;
|
@@ -25,7 +25,7 @@ export const inMemoryCache = async (name) => {
|
|
25
25
|
* @param name - name of the cache (used as an identifier)
|
26
26
|
* @returns Object with set, get and delete methods
|
27
27
|
*/
|
28
|
-
export const
|
28
|
+
export const webAPIAssetsCache = async (name) => {
|
29
29
|
const cache = await caches.open(name);
|
30
30
|
return {
|
31
31
|
set: async (request, response) => {
|
@@ -46,9 +46,9 @@ export const webAPIIconsCache = async (name) => {
|
|
46
46
|
* @param cacheStrategy - strategy to be used for caching
|
47
47
|
* @returns the cache based on the strategy
|
48
48
|
*/
|
49
|
-
export const
|
49
|
+
export const assetsCache = async (cacheName, cacheStrategy) => {
|
50
50
|
if (cacheStrategy === 'in-memory-cache') {
|
51
51
|
return inMemoryCache(cacheName);
|
52
52
|
}
|
53
|
-
return
|
53
|
+
return webAPIAssetsCache(cacheName);
|
54
54
|
};
|