@momentum-design/components 0.4.14 → 0.4.16

Sign up to get free protection for your applications and to get access to all the features.
Files changed (55) hide show
  1. package/dist/components/avatar/avatar.component.js +38 -32
  2. package/dist/components/avatar/avatar.constants.js +3 -9
  3. package/dist/components/avatar/avatar.styles.js +3 -5
  4. package/dist/components/avatar/avatar.types.js +1 -2
  5. package/dist/components/avatar/index.js +4 -7
  6. package/dist/components/badge/badge.component.js +65 -59
  7. package/dist/components/badge/badge.constants.js +3 -12
  8. package/dist/components/badge/badge.styles.js +5 -7
  9. package/dist/components/badge/index.js +6 -9
  10. package/dist/components/icon/icon.component.js +46 -40
  11. package/dist/components/icon/icon.constants.js +3 -8
  12. package/dist/components/icon/icon.styles.js +5 -7
  13. package/dist/components/icon/icon.utils.js +1 -4
  14. package/dist/components/icon/index.js +4 -7
  15. package/dist/components/iconprovider/iconprovider.component.js +39 -33
  16. package/dist/components/iconprovider/iconprovider.constants.js +3 -10
  17. package/dist/components/iconprovider/iconprovider.context.js +4 -6
  18. package/dist/components/iconprovider/index.js +4 -7
  19. package/dist/components/text/fonts.styles.js +2 -5
  20. package/dist/components/text/index.js +4 -7
  21. package/dist/components/text/text.component.js +35 -29
  22. package/dist/components/text/text.constants.js +3 -9
  23. package/dist/components/text/text.styles.js +5 -7
  24. package/dist/components/text/text.types.js +1 -2
  25. package/dist/components/themeprovider/index.js +4 -7
  26. package/dist/components/themeprovider/themeprovider.component.js +27 -21
  27. package/dist/components/themeprovider/themeprovider.constants.js +3 -8
  28. package/dist/components/themeprovider/themeprovider.context.js +4 -6
  29. package/dist/components/themeprovider/themeprovider.styles.js +3 -5
  30. package/dist/custom-elements.json +172 -172
  31. package/dist/index.js +7 -16
  32. package/dist/models/component/component.component.js +5 -8
  33. package/dist/models/component/component.styles.js +2 -4
  34. package/dist/models/component/component.types.js +1 -2
  35. package/dist/models/component/index.js +2 -5
  36. package/dist/models/index.js +3 -8
  37. package/dist/models/provider/index.js +2 -5
  38. package/dist/models/provider/provider.component.js +9 -12
  39. package/dist/models/provider/provider.styles.js +3 -5
  40. package/dist/react/avatar/index.js +8 -11
  41. package/dist/react/badge/index.js +8 -11
  42. package/dist/react/icon/index.js +8 -11
  43. package/dist/react/iconprovider/index.js +8 -11
  44. package/dist/react/index.d.ts +1 -1
  45. package/dist/react/index.js +6 -18
  46. package/dist/react/text/index.js +8 -11
  47. package/dist/react/themeprovider/index.js +8 -11
  48. package/dist/utils/mixins/DisabledMixin.js +14 -10
  49. package/dist/utils/mixins/TabIndexMixin.js +14 -10
  50. package/dist/utils/provider/index.js +3 -5
  51. package/dist/utils/styles/index.js +4 -8
  52. package/dist/utils/tag-name/constants.js +1 -3
  53. package/dist/utils/tag-name/index.js +3 -6
  54. package/dist/utils/types.js +1 -2
  55. package/package.json +1 -1
@@ -114,6 +114,178 @@
114
114
  }
115
115
  ]
116
116
  },
117
+ {
118
+ "kind": "javascript-module",
119
+ "path": "components/icon/icon.component.js",
120
+ "declarations": [
121
+ {
122
+ "kind": "class",
123
+ "description": "Icon component that dynamically displays SVG icons based on a valid name.\n\nThis component must be mounted within an `IconProvider` component.\n\nThe `IconProvider` defines the source URL from which icons are consumed.\nThe `Icon` component accepts a `name` attribute, which corresponds to\nthe file name of the icon to be loaded from the specified URL.\n\nOnce fetched, the icon will be rendered. If the fetching process is unsuccessful,\nno icon will be displayed.\n\nThe `size` attribute allows for dynamic sizing of the icon based on the provided\n`length-unit` attribute. This unit can either come from the `IconProvider`\nor can be overridden for each individual icon. For example:\nif `size = 1` and `length-unit = 'em'`, the dimensions of the icon will be\n`width: 1em; height: 1em`.\n\nRegarding accessibility, there are two types of icons: decorative and informative.\n\n### Decorative Icons\n- Decorative icons do not convey any essential information to the content of a page.\n- They should be hidden from screen readers (SR) to prevent confusion for users.\n- For decorative icons, an `aria-label` is not required, and the `role` will be set to null.\n\n### Informative Icons\n- Informative icons convey important information that is not adequately represented\n by surrounding text or components.\n- They provide valuable context and must be announced by assistive technologies.\n- For informative icons, an `aria-label` is required, and the `role` will be set to \"img\".\n- If an `aria-label` is provided, the role will be set to 'img'; if it is absent,\n the role will be unset.",
124
+ "name": "Icon",
125
+ "cssProperties": [
126
+ {
127
+ "description": "Allows customization of the default fill color.",
128
+ "name": "--mdc-icon-fill-color"
129
+ }
130
+ ],
131
+ "members": [
132
+ {
133
+ "kind": "field",
134
+ "name": "iconData",
135
+ "type": {
136
+ "text": "HTMLElement | undefined"
137
+ },
138
+ "privacy": "private"
139
+ },
140
+ {
141
+ "kind": "field",
142
+ "name": "lengthUnitFromContext",
143
+ "type": {
144
+ "text": "string | undefined"
145
+ },
146
+ "privacy": "private"
147
+ },
148
+ {
149
+ "kind": "field",
150
+ "name": "sizeFromContext",
151
+ "type": {
152
+ "text": "number | undefined"
153
+ },
154
+ "privacy": "private"
155
+ },
156
+ {
157
+ "kind": "field",
158
+ "name": "name",
159
+ "type": {
160
+ "text": "string | undefined"
161
+ },
162
+ "description": "Name of the icon (= filename)",
163
+ "attribute": "name",
164
+ "reflects": true
165
+ },
166
+ {
167
+ "kind": "field",
168
+ "name": "size",
169
+ "type": {
170
+ "text": "number | undefined"
171
+ },
172
+ "description": "Size of the icon (works in combination with length unit)",
173
+ "attribute": "size"
174
+ },
175
+ {
176
+ "kind": "field",
177
+ "name": "lengthUnit",
178
+ "type": {
179
+ "text": "string | undefined"
180
+ },
181
+ "description": "Length unit attribute for overriding length-unit from `IconProvider`",
182
+ "attribute": "length-unit"
183
+ },
184
+ {
185
+ "kind": "field",
186
+ "name": "ariaLabel",
187
+ "type": {
188
+ "text": "string | null"
189
+ },
190
+ "default": "null",
191
+ "description": "Aria-label attribute to be set for accessibility",
192
+ "attribute": "aria-label"
193
+ },
194
+ {
195
+ "kind": "field",
196
+ "name": "iconProviderContext",
197
+ "privacy": "private",
198
+ "readonly": true
199
+ },
200
+ {
201
+ "kind": "method",
202
+ "name": "getIconData",
203
+ "privacy": "private",
204
+ "description": "Get Icon Data function which will fetch the icon (currently only svg)\nand sets state and attributes once fetched successfully"
205
+ },
206
+ {
207
+ "kind": "method",
208
+ "name": "updateSize",
209
+ "privacy": "private",
210
+ "description": "Updates the size by setting the width and height"
211
+ },
212
+ {
213
+ "kind": "method",
214
+ "name": "setRoleOnIcon",
215
+ "privacy": "private"
216
+ },
217
+ {
218
+ "kind": "method",
219
+ "name": "setAriaHiddenOnIcon",
220
+ "privacy": "private"
221
+ },
222
+ {
223
+ "kind": "method",
224
+ "name": "setAriaLabelOnIcon",
225
+ "privacy": "private"
226
+ },
227
+ {
228
+ "kind": "field",
229
+ "name": "computedIconSize",
230
+ "privacy": "private",
231
+ "readonly": true
232
+ }
233
+ ],
234
+ "attributes": [
235
+ {
236
+ "name": "name",
237
+ "type": {
238
+ "text": "string | undefined"
239
+ },
240
+ "description": "Name of the icon (= filename)",
241
+ "fieldName": "name"
242
+ },
243
+ {
244
+ "name": "size",
245
+ "type": {
246
+ "text": "number | undefined"
247
+ },
248
+ "description": "Size of the icon (works in combination with length unit)",
249
+ "fieldName": "size"
250
+ },
251
+ {
252
+ "name": "length-unit",
253
+ "type": {
254
+ "text": "string | undefined"
255
+ },
256
+ "description": "Length unit attribute for overriding length-unit from `IconProvider`",
257
+ "fieldName": "lengthUnit"
258
+ },
259
+ {
260
+ "name": "aria-label",
261
+ "type": {
262
+ "text": "string | null"
263
+ },
264
+ "default": "null",
265
+ "description": "Aria-label attribute to be set for accessibility",
266
+ "fieldName": "ariaLabel"
267
+ }
268
+ ],
269
+ "superclass": {
270
+ "name": "Component",
271
+ "module": "/src/models"
272
+ },
273
+ "tagName": "mdc-icon",
274
+ "jsDoc": "/**\n * Icon component that dynamically displays SVG icons based on a valid name.\n *\n * This component must be mounted within an `IconProvider` component.\n *\n * The `IconProvider` defines the source URL from which icons are consumed.\n * The `Icon` component accepts a `name` attribute, which corresponds to\n * the file name of the icon to be loaded from the specified URL.\n *\n * Once fetched, the icon will be rendered. If the fetching process is unsuccessful,\n * no icon will be displayed.\n *\n * The `size` attribute allows for dynamic sizing of the icon based on the provided\n * `length-unit` attribute. This unit can either come from the `IconProvider`\n * or can be overridden for each individual icon. For example:\n * if `size = 1` and `length-unit = 'em'`, the dimensions of the icon will be\n * `width: 1em; height: 1em`.\n *\n * Regarding accessibility, there are two types of icons: decorative and informative.\n *\n * ### Decorative Icons\n * - Decorative icons do not convey any essential information to the content of a page.\n * - They should be hidden from screen readers (SR) to prevent confusion for users.\n * - For decorative icons, an `aria-label` is not required, and the `role` will be set to null.\n *\n * ### Informative Icons\n * - Informative icons convey important information that is not adequately represented\n * by surrounding text or components.\n * - They provide valuable context and must be announced by assistive technologies.\n * - For informative icons, an `aria-label` is required, and the `role` will be set to \"img\".\n * - If an `aria-label` is provided, the role will be set to 'img'; if it is absent,\n * the role will be unset.\n *\n * @tagname mdc-icon\n *\n * @cssproperty --mdc-icon-fill-color - Allows customization of the default fill color.\n */",
275
+ "customElement": true
276
+ }
277
+ ],
278
+ "exports": [
279
+ {
280
+ "kind": "js",
281
+ "name": "default",
282
+ "declaration": {
283
+ "name": "Icon",
284
+ "module": "components/icon/icon.component.js"
285
+ }
286
+ }
287
+ ]
288
+ },
117
289
  {
118
290
  "kind": "javascript-module",
119
291
  "path": "components/badge/badge.component.js",
@@ -435,178 +607,6 @@
435
607
  }
436
608
  ]
437
609
  },
438
- {
439
- "kind": "javascript-module",
440
- "path": "components/icon/icon.component.js",
441
- "declarations": [
442
- {
443
- "kind": "class",
444
- "description": "Icon component that dynamically displays SVG icons based on a valid name.\n\nThis component must be mounted within an `IconProvider` component.\n\nThe `IconProvider` defines the source URL from which icons are consumed.\nThe `Icon` component accepts a `name` attribute, which corresponds to\nthe file name of the icon to be loaded from the specified URL.\n\nOnce fetched, the icon will be rendered. If the fetching process is unsuccessful,\nno icon will be displayed.\n\nThe `size` attribute allows for dynamic sizing of the icon based on the provided\n`length-unit` attribute. This unit can either come from the `IconProvider`\nor can be overridden for each individual icon. For example:\nif `size = 1` and `length-unit = 'em'`, the dimensions of the icon will be\n`width: 1em; height: 1em`.\n\nRegarding accessibility, there are two types of icons: decorative and informative.\n\n### Decorative Icons\n- Decorative icons do not convey any essential information to the content of a page.\n- They should be hidden from screen readers (SR) to prevent confusion for users.\n- For decorative icons, an `aria-label` is not required, and the `role` will be set to null.\n\n### Informative Icons\n- Informative icons convey important information that is not adequately represented\n by surrounding text or components.\n- They provide valuable context and must be announced by assistive technologies.\n- For informative icons, an `aria-label` is required, and the `role` will be set to \"img\".\n- If an `aria-label` is provided, the role will be set to 'img'; if it is absent,\n the role will be unset.",
445
- "name": "Icon",
446
- "cssProperties": [
447
- {
448
- "description": "Allows customization of the default fill color.",
449
- "name": "--mdc-icon-fill-color"
450
- }
451
- ],
452
- "members": [
453
- {
454
- "kind": "field",
455
- "name": "iconData",
456
- "type": {
457
- "text": "HTMLElement | undefined"
458
- },
459
- "privacy": "private"
460
- },
461
- {
462
- "kind": "field",
463
- "name": "lengthUnitFromContext",
464
- "type": {
465
- "text": "string | undefined"
466
- },
467
- "privacy": "private"
468
- },
469
- {
470
- "kind": "field",
471
- "name": "sizeFromContext",
472
- "type": {
473
- "text": "number | undefined"
474
- },
475
- "privacy": "private"
476
- },
477
- {
478
- "kind": "field",
479
- "name": "name",
480
- "type": {
481
- "text": "string | undefined"
482
- },
483
- "description": "Name of the icon (= filename)",
484
- "attribute": "name",
485
- "reflects": true
486
- },
487
- {
488
- "kind": "field",
489
- "name": "size",
490
- "type": {
491
- "text": "number | undefined"
492
- },
493
- "description": "Size of the icon (works in combination with length unit)",
494
- "attribute": "size"
495
- },
496
- {
497
- "kind": "field",
498
- "name": "lengthUnit",
499
- "type": {
500
- "text": "string | undefined"
501
- },
502
- "description": "Length unit attribute for overriding length-unit from `IconProvider`",
503
- "attribute": "length-unit"
504
- },
505
- {
506
- "kind": "field",
507
- "name": "ariaLabel",
508
- "type": {
509
- "text": "string | null"
510
- },
511
- "default": "null",
512
- "description": "Aria-label attribute to be set for accessibility",
513
- "attribute": "aria-label"
514
- },
515
- {
516
- "kind": "field",
517
- "name": "iconProviderContext",
518
- "privacy": "private",
519
- "readonly": true
520
- },
521
- {
522
- "kind": "method",
523
- "name": "getIconData",
524
- "privacy": "private",
525
- "description": "Get Icon Data function which will fetch the icon (currently only svg)\nand sets state and attributes once fetched successfully"
526
- },
527
- {
528
- "kind": "method",
529
- "name": "updateSize",
530
- "privacy": "private",
531
- "description": "Updates the size by setting the width and height"
532
- },
533
- {
534
- "kind": "method",
535
- "name": "setRoleOnIcon",
536
- "privacy": "private"
537
- },
538
- {
539
- "kind": "method",
540
- "name": "setAriaHiddenOnIcon",
541
- "privacy": "private"
542
- },
543
- {
544
- "kind": "method",
545
- "name": "setAriaLabelOnIcon",
546
- "privacy": "private"
547
- },
548
- {
549
- "kind": "field",
550
- "name": "computedIconSize",
551
- "privacy": "private",
552
- "readonly": true
553
- }
554
- ],
555
- "attributes": [
556
- {
557
- "name": "name",
558
- "type": {
559
- "text": "string | undefined"
560
- },
561
- "description": "Name of the icon (= filename)",
562
- "fieldName": "name"
563
- },
564
- {
565
- "name": "size",
566
- "type": {
567
- "text": "number | undefined"
568
- },
569
- "description": "Size of the icon (works in combination with length unit)",
570
- "fieldName": "size"
571
- },
572
- {
573
- "name": "length-unit",
574
- "type": {
575
- "text": "string | undefined"
576
- },
577
- "description": "Length unit attribute for overriding length-unit from `IconProvider`",
578
- "fieldName": "lengthUnit"
579
- },
580
- {
581
- "name": "aria-label",
582
- "type": {
583
- "text": "string | null"
584
- },
585
- "default": "null",
586
- "description": "Aria-label attribute to be set for accessibility",
587
- "fieldName": "ariaLabel"
588
- }
589
- ],
590
- "superclass": {
591
- "name": "Component",
592
- "module": "/src/models"
593
- },
594
- "tagName": "mdc-icon",
595
- "jsDoc": "/**\n * Icon component that dynamically displays SVG icons based on a valid name.\n *\n * This component must be mounted within an `IconProvider` component.\n *\n * The `IconProvider` defines the source URL from which icons are consumed.\n * The `Icon` component accepts a `name` attribute, which corresponds to\n * the file name of the icon to be loaded from the specified URL.\n *\n * Once fetched, the icon will be rendered. If the fetching process is unsuccessful,\n * no icon will be displayed.\n *\n * The `size` attribute allows for dynamic sizing of the icon based on the provided\n * `length-unit` attribute. This unit can either come from the `IconProvider`\n * or can be overridden for each individual icon. For example:\n * if `size = 1` and `length-unit = 'em'`, the dimensions of the icon will be\n * `width: 1em; height: 1em`.\n *\n * Regarding accessibility, there are two types of icons: decorative and informative.\n *\n * ### Decorative Icons\n * - Decorative icons do not convey any essential information to the content of a page.\n * - They should be hidden from screen readers (SR) to prevent confusion for users.\n * - For decorative icons, an `aria-label` is not required, and the `role` will be set to null.\n *\n * ### Informative Icons\n * - Informative icons convey important information that is not adequately represented\n * by surrounding text or components.\n * - They provide valuable context and must be announced by assistive technologies.\n * - For informative icons, an `aria-label` is required, and the `role` will be set to \"img\".\n * - If an `aria-label` is provided, the role will be set to 'img'; if it is absent,\n * the role will be unset.\n *\n * @tagname mdc-icon\n *\n * @cssproperty --mdc-icon-fill-color - Allows customization of the default fill color.\n */",
596
- "customElement": true
597
- }
598
- ],
599
- "exports": [
600
- {
601
- "kind": "js",
602
- "name": "default",
603
- "declaration": {
604
- "name": "Icon",
605
- "module": "components/icon/icon.component.js"
606
- }
607
- }
608
- ]
609
- },
610
610
  {
611
611
  "kind": "javascript-module",
612
612
  "path": "components/iconprovider/iconprovider.component.js",
package/dist/index.js CHANGED
@@ -1,16 +1,7 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.Text = exports.Badge = exports.Avatar = exports.IconProvider = exports.Icon = exports.ThemeProvider = void 0;
4
- const tslib_1 = require("tslib");
5
- const themeprovider_1 = tslib_1.__importDefault(require("./components/themeprovider"));
6
- exports.ThemeProvider = themeprovider_1.default;
7
- const icon_1 = tslib_1.__importDefault(require("./components/icon"));
8
- exports.Icon = icon_1.default;
9
- const iconprovider_1 = tslib_1.__importDefault(require("./components/iconprovider"));
10
- exports.IconProvider = iconprovider_1.default;
11
- const avatar_1 = tslib_1.__importDefault(require("./components/avatar"));
12
- exports.Avatar = avatar_1.default;
13
- const badge_1 = tslib_1.__importDefault(require("./components/badge"));
14
- exports.Badge = badge_1.default;
15
- const text_1 = tslib_1.__importDefault(require("./components/text"));
16
- exports.Text = text_1.default;
1
+ import ThemeProvider from './components/themeprovider';
2
+ import Icon from './components/icon';
3
+ import IconProvider from './components/iconprovider';
4
+ import Avatar from './components/avatar';
5
+ import Badge from './components/badge';
6
+ import Text from './components/text';
7
+ export { ThemeProvider, Icon, IconProvider, Avatar, Badge, Text, };
@@ -1,8 +1,5 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const tslib_1 = require("tslib");
4
- const lit_1 = require("lit");
5
- const component_styles_1 = tslib_1.__importDefault(require("./component.styles"));
1
+ import { LitElement } from 'lit';
2
+ import styles from './component.styles';
6
3
  /**
7
4
  * Core Component class to ultimately be inherited by all Web Components within
8
5
  * this package.
@@ -12,7 +9,7 @@ const component_styles_1 = tslib_1.__importDefault(require("./component.styles")
12
9
  *
13
10
  * @public
14
11
  */
15
- class Component extends lit_1.LitElement {
12
+ class Component extends LitElement {
16
13
  /**
17
14
  * Register `this` extended `Component` Class as a custom element within the
18
15
  * DOM's custom elements registry.
@@ -50,5 +47,5 @@ class Component extends lit_1.LitElement {
50
47
  /**
51
48
  * Styles associated with the Base Component.
52
49
  */
53
- Component.styles = [component_styles_1.default];
54
- exports.default = Component;
50
+ Component.styles = [styles];
51
+ export default Component;
@@ -1,7 +1,5 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const lit_1 = require("lit");
4
- exports.default = (0, lit_1.css) `
1
+ import { css } from 'lit';
2
+ export default css `
5
3
  :host {
6
4
  box-sizing: border-box;
7
5
  }
@@ -1,2 +1 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
1
+ export {};
@@ -1,5 +1,2 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const tslib_1 = require("tslib");
4
- const component_component_1 = tslib_1.__importDefault(require("./component.component"));
5
- exports.default = component_component_1.default;
1
+ import Component from './component.component';
2
+ export default Component;
@@ -1,8 +1,3 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.Provider = exports.Component = void 0;
4
- const tslib_1 = require("tslib");
5
- const component_1 = tslib_1.__importDefault(require("./component"));
6
- exports.Component = component_1.default;
7
- const provider_1 = tslib_1.__importDefault(require("./provider"));
8
- exports.Provider = provider_1.default;
1
+ import Component from './component';
2
+ import Provider from './provider';
3
+ export { Component, Provider, };
@@ -1,5 +1,2 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const tslib_1 = require("tslib");
4
- const provider_component_1 = tslib_1.__importDefault(require("./provider.component"));
5
- exports.default = provider_component_1.default;
1
+ import Provider from './provider.component';
2
+ export default Provider;
@@ -1,17 +1,14 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const tslib_1 = require("tslib");
4
- const context_1 = require("@lit/context");
5
- const lit_1 = require("lit");
6
- const component_1 = tslib_1.__importDefault(require("../component"));
7
- const provider_styles_1 = tslib_1.__importDefault(require("./provider.styles"));
1
+ import { ContextProvider } from '@lit/context';
2
+ import { html } from 'lit';
3
+ import Component from '../component';
4
+ import styles from './provider.styles';
8
5
  /**
9
6
  * Provider Component class to ultimately be inherited by all Provider-type Web
10
7
  * Components within this package.
11
8
  *
12
9
  * @public
13
10
  */
14
- class Provider extends component_1.default {
11
+ class Provider extends Component {
15
12
  /**
16
13
  * Constructor of the Provider.
17
14
  *
@@ -29,7 +26,7 @@ class Provider extends component_1.default {
29
26
  */
30
27
  constructor({ context, initialValue }) {
31
28
  super();
32
- this.context = new context_1.ContextProvider(this, {
29
+ this.context = new ContextProvider(this, {
33
30
  context,
34
31
  initialValue,
35
32
  });
@@ -46,11 +43,11 @@ class Provider extends component_1.default {
46
43
  */
47
44
  render() {
48
45
  this.updateContext();
49
- return (0, lit_1.html) `<slot></slot>`;
46
+ return html `<slot></slot>`;
50
47
  }
51
48
  }
52
49
  /**
53
50
  * Styles associated with this Provider Component.
54
51
  */
55
- Provider.styles = [...component_1.default.styles, provider_styles_1.default];
56
- exports.default = Provider;
52
+ Provider.styles = [...Component.styles, styles];
53
+ export default Provider;
@@ -1,9 +1,7 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const lit_1 = require("lit");
4
- const styles = (0, lit_1.css) `
1
+ import { css } from 'lit';
2
+ const styles = css `
5
3
  :host {
6
4
  display: contents;
7
5
  }
8
6
  `;
9
- exports.default = styles;
7
+ export default styles;
@@ -1,10 +1,7 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const tslib_1 = require("tslib");
4
- const React = tslib_1.__importStar(require("react"));
5
- const react_1 = require("@lit/react");
6
- const avatar_1 = tslib_1.__importDefault(require("../../components/avatar"));
7
- const avatar_constants_1 = require("../../components/avatar/avatar.constants");
1
+ import * as React from 'react';
2
+ import { createComponent } from '@lit/react';
3
+ import Component from '../../components/avatar';
4
+ import { TAG_NAME } from '../../components/avatar/avatar.constants';
8
5
  /**
9
6
  * @slot - This is a default/unnamed slot
10
7
  *
@@ -12,11 +9,11 @@ const avatar_constants_1 = require("../../components/avatar/avatar.constants");
12
9
  *
13
10
  * @tagname mdc-avatar
14
11
  */
15
- const reactWrapper = (0, react_1.createComponent)({
16
- tagName: avatar_constants_1.TAG_NAME,
17
- elementClass: avatar_1.default,
12
+ const reactWrapper = createComponent({
13
+ tagName: TAG_NAME,
14
+ elementClass: Component,
18
15
  react: React,
19
16
  events: {},
20
17
  displayName: 'Avatar',
21
18
  });
22
- exports.default = reactWrapper;
19
+ export default reactWrapper;
@@ -1,10 +1,7 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const tslib_1 = require("tslib");
4
- const React = tslib_1.__importStar(require("react"));
5
- const react_1 = require("@lit/react");
6
- const badge_1 = tslib_1.__importDefault(require("../../components/badge"));
7
- const badge_constants_1 = require("../../components/badge/badge.constants");
1
+ import * as React from 'react';
2
+ import { createComponent } from '@lit/react';
3
+ import Component from '../../components/badge';
4
+ import { TAG_NAME } from '../../components/badge/badge.constants';
8
5
  /**
9
6
  * A badge is a small, visually distinct element that provides additional information
10
7
  * or highlights the status of an item.
@@ -15,11 +12,11 @@ const badge_constants_1 = require("../../components/badge/badge.constants");
15
12
  *
16
13
  * @tagname mdc-badge
17
14
  */
18
- const reactWrapper = (0, react_1.createComponent)({
19
- tagName: badge_constants_1.TAG_NAME,
20
- elementClass: badge_1.default,
15
+ const reactWrapper = createComponent({
16
+ tagName: TAG_NAME,
17
+ elementClass: Component,
21
18
  react: React,
22
19
  events: {},
23
20
  displayName: 'Badge',
24
21
  });
25
- exports.default = reactWrapper;
22
+ export default reactWrapper;
@@ -1,10 +1,7 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const tslib_1 = require("tslib");
4
- const React = tslib_1.__importStar(require("react"));
5
- const react_1 = require("@lit/react");
6
- const icon_1 = tslib_1.__importDefault(require("../../components/icon"));
7
- const icon_constants_1 = require("../../components/icon/icon.constants");
1
+ import * as React from 'react';
2
+ import { createComponent } from '@lit/react';
3
+ import Component from '../../components/icon';
4
+ import { TAG_NAME } from '../../components/icon/icon.constants';
8
5
  /**
9
6
  * Icon component that dynamically displays SVG icons based on a valid name.
10
7
  *
@@ -42,11 +39,11 @@ const icon_constants_1 = require("../../components/icon/icon.constants");
42
39
  *
43
40
  * @cssproperty --mdc-icon-fill-color - Allows customization of the default fill color.
44
41
  */
45
- const reactWrapper = (0, react_1.createComponent)({
46
- tagName: icon_constants_1.TAG_NAME,
47
- elementClass: icon_1.default,
42
+ const reactWrapper = createComponent({
43
+ tagName: TAG_NAME,
44
+ elementClass: Component,
48
45
  react: React,
49
46
  events: {},
50
47
  displayName: 'Icon',
51
48
  });
52
- exports.default = reactWrapper;
49
+ export default reactWrapper;
@@ -1,10 +1,7 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const tslib_1 = require("tslib");
4
- const React = tslib_1.__importStar(require("react"));
5
- const react_1 = require("@lit/react");
6
- const iconprovider_1 = tslib_1.__importDefault(require("../../components/iconprovider"));
7
- const iconprovider_constants_1 = require("../../components/iconprovider/iconprovider.constants");
1
+ import * as React from 'react';
2
+ import { createComponent } from '@lit/react';
3
+ import Component from '../../components/iconprovider';
4
+ import { TAG_NAME } from '../../components/iconprovider/iconprovider.constants';
8
5
  /**
9
6
  * IconProvider component, which allows to be consumed from sub components
10
7
  * (see `providerUtils.consume` for how to consume)
@@ -17,11 +14,11 @@ const iconprovider_constants_1 = require("../../components/iconprovider/iconprov
17
14
  *
18
15
  * @slot - children
19
16
  */
20
- const reactWrapper = (0, react_1.createComponent)({
21
- tagName: iconprovider_constants_1.TAG_NAME,
22
- elementClass: iconprovider_1.default,
17
+ const reactWrapper = createComponent({
18
+ tagName: TAG_NAME,
19
+ elementClass: Component,
23
20
  react: React,
24
21
  events: {},
25
22
  displayName: 'IconProvider',
26
23
  });
27
- exports.default = reactWrapper;
24
+ export default reactWrapper;