@momentum-design/components 0.41.7 → 0.43.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 +110 -102
- package/dist/browser/index.js.map +4 -4
- package/dist/components/brandvisual/brandvisual.component.d.ts +44 -0
- package/dist/components/brandvisual/brandvisual.component.js +106 -0
- package/dist/components/brandvisual/brandvisual.constants.d.ts +5 -0
- package/dist/components/brandvisual/brandvisual.constants.js +6 -0
- package/dist/components/brandvisual/brandvisual.styles.d.ts +2 -0
- package/dist/components/brandvisual/brandvisual.styles.js +11 -0
- package/dist/components/brandvisual/brandvisual.types.d.ts +2 -0
- package/dist/components/brandvisual/brandvisual.types.js +1 -0
- package/dist/components/brandvisual/index.d.ts +7 -0
- package/dist/components/brandvisual/index.js +4 -0
- package/dist/custom-elements.json +357 -251
- package/dist/index.d.ts +2 -1
- package/dist/index.js +2 -1
- package/dist/react/brandvisual/index.d.ts +23 -0
- package/dist/react/brandvisual/index.js +32 -0
- package/dist/react/index.d.ts +2 -1
- package/dist/react/index.js +2 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
@@ -34,10 +34,11 @@ import Progressbar from './components/progressbar';
|
|
34
34
|
import Option from './components/option';
|
35
35
|
import OptGroup from './components/optgroup';
|
36
36
|
import Textarea from './components/textarea';
|
37
|
+
import Brandvisual from './components/brandvisual';
|
37
38
|
// Constants / Utils Imports
|
38
39
|
import { BUTTON_COLORS, BUTTON_VARIANTS, ICON_BUTTON_SIZES, PILL_BUTTON_SIZES, } from './components/button/button.constants';
|
39
40
|
import { inMemoryCache, webAPIIconsCache } from './utils/icon-cache';
|
40
41
|
// Components Exports
|
41
|
-
export { AlertChip, Avatar, AvatarButton, Badge, Bullet, Button, Checkbox, Chip, Coachmark, Divider, FilterChip, FormfieldGroup, Icon, IconProvider, Input, InputChip, Link, List, ListItem, Marker, Popover, Presence, Radio, RadioGroup, Spinner, Tab, Text, ThemeProvider, Toggle, VirtualizedList, Option, OptGroup, Progressbar, Textarea, Tooltip, };
|
42
|
+
export { AlertChip, Avatar, AvatarButton, Badge, Bullet, Button, Checkbox, Chip, Coachmark, Divider, FilterChip, FormfieldGroup, Icon, IconProvider, Input, InputChip, Link, List, ListItem, Marker, Popover, Presence, Radio, RadioGroup, Spinner, Tab, Text, ThemeProvider, Toggle, VirtualizedList, Option, OptGroup, Progressbar, Textarea, Tooltip, Brandvisual, };
|
42
43
|
// Constants / Utils Exports
|
43
44
|
export { inMemoryCache, webAPIIconsCache, BUTTON_COLORS, BUTTON_VARIANTS, ICON_BUTTON_SIZES, PILL_BUTTON_SIZES };
|
@@ -0,0 +1,23 @@
|
|
1
|
+
import Component from '../../components/brandvisual';
|
2
|
+
/**
|
3
|
+
* The `mdc-brandvisual` component is responsible for rendering logos dynamically & ensures they are
|
4
|
+
* displayed correctly within applications.
|
5
|
+
*
|
6
|
+
* Features:
|
7
|
+
* - Dynamically loads brandvisuals based on the `name` attribute.
|
8
|
+
* - Emits a `load` event when the brandvisual is successfully fetched.
|
9
|
+
* - Emits an `error` event when the brandvisual import fails.
|
10
|
+
* - Supports accessibility best practices.
|
11
|
+
* - Used for brand representation within the design system.
|
12
|
+
*
|
13
|
+
* @tagname mdc-brandvisual
|
14
|
+
*
|
15
|
+
* @event load - (React: onLoad) This event is dispatched when the brandvisual has been successfully loaded.
|
16
|
+
* @event error - (React: onError) This event is dispatched when the brandvisual fetching has failed.
|
17
|
+
*
|
18
|
+
*/
|
19
|
+
declare const reactWrapper: import("@lit/react").ReactWebComponent<Component, {
|
20
|
+
onLoad: string;
|
21
|
+
onError: string;
|
22
|
+
}>;
|
23
|
+
export default reactWrapper;
|
@@ -0,0 +1,32 @@
|
|
1
|
+
import * as React from 'react';
|
2
|
+
import { createComponent } from '@lit/react';
|
3
|
+
import Component from '../../components/brandvisual';
|
4
|
+
import { TAG_NAME } from '../../components/brandvisual/brandvisual.constants';
|
5
|
+
/**
|
6
|
+
* The `mdc-brandvisual` component is responsible for rendering logos dynamically & ensures they are
|
7
|
+
* displayed correctly within applications.
|
8
|
+
*
|
9
|
+
* Features:
|
10
|
+
* - Dynamically loads brandvisuals based on the `name` attribute.
|
11
|
+
* - Emits a `load` event when the brandvisual is successfully fetched.
|
12
|
+
* - Emits an `error` event when the brandvisual import fails.
|
13
|
+
* - Supports accessibility best practices.
|
14
|
+
* - Used for brand representation within the design system.
|
15
|
+
*
|
16
|
+
* @tagname mdc-brandvisual
|
17
|
+
*
|
18
|
+
* @event load - (React: onLoad) This event is dispatched when the brandvisual has been successfully loaded.
|
19
|
+
* @event error - (React: onError) This event is dispatched when the brandvisual fetching has failed.
|
20
|
+
*
|
21
|
+
*/
|
22
|
+
const reactWrapper = createComponent({
|
23
|
+
tagName: TAG_NAME,
|
24
|
+
elementClass: Component,
|
25
|
+
react: React,
|
26
|
+
events: {
|
27
|
+
onLoad: 'load',
|
28
|
+
onError: 'error',
|
29
|
+
},
|
30
|
+
displayName: 'Brandvisual',
|
31
|
+
});
|
32
|
+
export default reactWrapper;
|
package/dist/react/index.d.ts
CHANGED
@@ -1,7 +1,8 @@
|
|
1
1
|
export { default as AlertChip } from './alertchip';
|
2
|
-
export { default as Avatar } from './avatar';
|
3
2
|
export { default as AvatarButton } from './avatarbutton';
|
3
|
+
export { default as Avatar } from './avatar';
|
4
4
|
export { default as Badge } from './badge';
|
5
|
+
export { default as Brandvisual } from './brandvisual';
|
5
6
|
export { default as Bullet } from './bullet';
|
6
7
|
export { default as Button } from './button';
|
7
8
|
export { default as Buttonsimple } from './buttonsimple';
|
package/dist/react/index.js
CHANGED
@@ -1,7 +1,8 @@
|
|
1
1
|
export { default as AlertChip } from './alertchip';
|
2
|
-
export { default as Avatar } from './avatar';
|
3
2
|
export { default as AvatarButton } from './avatarbutton';
|
3
|
+
export { default as Avatar } from './avatar';
|
4
4
|
export { default as Badge } from './badge';
|
5
|
+
export { default as Brandvisual } from './brandvisual';
|
5
6
|
export { default as Bullet } from './bullet';
|
6
7
|
export { default as Button } from './button';
|
7
8
|
export { default as Buttonsimple } from './buttonsimple';
|
package/package.json
CHANGED