@redvars/peacock 3.0.1 → 3.1.1

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.
Files changed (115) hide show
  1. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/avatar/avatar.css.js +3 -3
  2. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/avatar/avatar.css.js.map +1 -1
  3. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/avatar/avatar.d.ts +0 -6
  4. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/avatar/avatar.js +0 -6
  5. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/avatar/avatar.js.map +1 -1
  6. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/avatar/p-avatar.d.ts +10 -0
  7. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/avatar/p-avatar.js +17 -0
  8. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/avatar/p-avatar.js.map +1 -0
  9. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/badge/badge.css.d.ts +1 -0
  10. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/badge/badge.css.js +33 -0
  11. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/badge/badge.css.js.map +1 -0
  12. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/badge/badge.d.ts +9 -0
  13. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/badge/badge.js +37 -0
  14. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/badge/badge.js.map +1 -0
  15. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/badge/index.d.ts +1 -0
  16. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/badge/index.js +2 -0
  17. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/badge/index.js.map +1 -0
  18. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/badge/p-badge.d.ts +8 -0
  19. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/badge/p-badge.js +15 -0
  20. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/badge/p-badge.js.map +1 -0
  21. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/icon/icon.d.ts +0 -6
  22. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/icon/icon.js +0 -7
  23. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/icon/icon.js.map +1 -1
  24. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/icon/p-icon.d.ts +8 -1
  25. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/icon/p-icon.js +11 -4
  26. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/icon/p-icon.js.map +1 -1
  27. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/index.d.ts +3 -2
  28. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/index.js +3 -2
  29. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/index.js.map +1 -1
  30. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/link/index.d.ts +1 -0
  31. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/link/index.js +2 -0
  32. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/link/index.js.map +1 -0
  33. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/link/link.css.d.ts +2 -0
  34. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/link/link.css.js +36 -0
  35. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/link/link.css.js.map +1 -0
  36. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/link/link.d.ts +12 -0
  37. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/link/link.js +18 -0
  38. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/link/link.js.map +1 -0
  39. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/peacock-loader.js +31 -2
  40. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/peacock-loader.js.map +1 -1
  41. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/styleMixins.css.d.ts +9 -0
  42. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/styleMixins.css.js +46 -0
  43. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/styleMixins.css.js.map +1 -0
  44. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/text/text.css.d.ts +2 -0
  45. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/text/text.css.js +70 -0
  46. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/text/text.css.js.map +1 -0
  47. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/utils.d.ts +0 -1
  48. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/utils.js +0 -7
  49. package/.rollup.cache/E/git/redvars/peacock/components/dist/src/utils.js.map +1 -1
  50. package/.rollup.cache/E/git/redvars/peacock/components/dist/tsconfig.tsbuildinfo +1 -1
  51. package/{demo → assets}/tokens.css +60 -48
  52. package/copyDesignFiles.js +11 -0
  53. package/custom-elements-manifest.config.mjs +10 -22
  54. package/custom-elements.md +61 -137
  55. package/demo/index.html +21 -8
  56. package/demo/int.html +1 -1
  57. package/dist/assets/styles/tokens.css +522 -0
  58. package/dist/{icon-1wpxQtrZ.js → avatar-GQwWRGRw.js} +94 -17
  59. package/dist/avatar-GQwWRGRw.js.map +1 -0
  60. package/dist/avatar-jfcIDB8G.js +424 -0
  61. package/dist/avatar-jfcIDB8G.js.map +1 -0
  62. package/dist/component/avatar.js +12 -8
  63. package/dist/component/avatar.js.map +1 -1
  64. package/dist/component/{Icon.js → icon.js} +96 -9
  65. package/dist/component/icon.js.map +1 -0
  66. package/dist/directive-CKEA2P55.js +70 -0
  67. package/dist/directive-CKEA2P55.js.map +1 -0
  68. package/dist/index.js +40 -61
  69. package/dist/index.js.map +1 -1
  70. package/dist/peacock-loader.js +132 -3
  71. package/dist/peacock-loader.js.map +1 -1
  72. package/dist/src/avatar/avatar.d.ts +0 -6
  73. package/dist/src/avatar/p-avatar.d.ts +10 -0
  74. package/dist/src/badge/badge.css.d.ts +1 -0
  75. package/dist/src/badge/badge.d.ts +9 -0
  76. package/dist/src/badge/index.d.ts +1 -0
  77. package/dist/src/badge/p-badge.d.ts +8 -0
  78. package/dist/src/icon/icon.d.ts +0 -6
  79. package/dist/src/icon/p-icon.d.ts +8 -1
  80. package/dist/src/index.d.ts +3 -2
  81. package/dist/src/link/link.css.d.ts +2 -0
  82. package/dist/src/styleMixins.css.d.ts +9 -0
  83. package/dist/src/text/text.css.d.ts +2 -0
  84. package/dist/src/utils.d.ts +0 -1
  85. package/dist/tsconfig.tsbuildinfo +1 -1
  86. package/dist/web-types.json +78 -0
  87. package/package.json +19 -7
  88. package/readme-gen.mjs +15 -2
  89. package/readme.md +190 -0
  90. package/rollup.config.js +14 -1
  91. package/src/avatar/avatar.css.ts +2 -2
  92. package/src/avatar/avatar.ts +0 -6
  93. package/src/avatar/demo/index.html +2 -2
  94. package/src/avatar/p-avatar.ts +12 -0
  95. package/src/badge/badge.css.ts +33 -0
  96. package/src/badge/badge.ts +29 -0
  97. package/src/badge/demo/index.html +54 -0
  98. package/src/badge/index.ts +1 -0
  99. package/src/badge/p-badge.ts +10 -0
  100. package/src/icon/demo/index.html +4 -4
  101. package/src/icon/icon.ts +1 -7
  102. package/src/icon/p-icon.ts +8 -1
  103. package/src/index.ts +3 -2
  104. package/src/link/link.css.ts +36 -0
  105. package/src/peacock-loader.ts +40 -2
  106. package/src/styleMixins.css.ts +55 -0
  107. package/src/styles.d.ts +11 -0
  108. package/src/text/text.css.ts +76 -0
  109. package/src/utils.ts +0 -8
  110. package/tsconfig.json +1 -1
  111. package/README.md +0 -46
  112. package/dist/component/Icon.js.map +0 -1
  113. package/dist/icon-1wpxQtrZ.js.map +0 -1
  114. package/dist/src/peacock-loader.js +0 -16
  115. package/dist/src/peacock-loader.js.map +0 -1
@@ -3,7 +3,6 @@
3
3
  * ------------------------------------------- */
4
4
 
5
5
  :root {
6
- --color-background: #fffbff;
7
6
  --color-black: #000000;
8
7
  --color-blue: #305cde;
9
8
  --color-blue-0: #000000;
@@ -33,7 +32,7 @@
33
32
  --color-error-95: var(--color-red-95);
34
33
  --color-error-98: var(--color-red-98);
35
34
  --color-error-100: var(--color-red-100);
36
- --color-error-container: #ffdad6;
35
+ --color-error-container: var(--color-error-90);
37
36
  --color-green: #2e6f40;
38
37
  --color-green-0: #000000;
39
38
  --color-green-10: #00210b;
@@ -48,9 +47,12 @@
48
47
  --color-green-95: #c4ffcb;
49
48
  --color-green-98: #eaffe9;
50
49
  --color-green-100: #ffffff;
51
- --color-inverse-on-surface: #fbeeec;
52
- --color-inverse-primary: #aec6ff;
53
- --color-inverse-surface: #362f2e;
50
+ --color-inverse-error: var(--color-error-80);
51
+ --color-inverse-on-surface: var(--color-neutral-95);
52
+ --color-inverse-primary: var(--color-primary-80);
53
+ --color-inverse-secondary: var(--color-secondary-80);
54
+ --color-inverse-surface: var(--color-neutral-20);
55
+ --color-inverse-tertiary: var(--color-tertiary-80);
54
56
  --color-neutral: #747878;
55
57
  --color-neutral-0: #000000;
56
58
  --color-neutral-4: #0b0f0f;
@@ -99,17 +101,16 @@
99
101
  --color-neutral-variant-98: #f2fbfd;
100
102
  --color-neutral-variant-99: #f6feff;
101
103
  --color-neutral-variant-100: #ffffff;
102
- --color-on-background: #201a19;
103
- --color-on-error: #ffffff;
104
- --color-on-error-container: #410002;
105
- --color-on-primary: #ffffff;
106
- --color-on-primary-container: #001a42;
107
- --color-on-secondary: #ffffff;
108
- --color-on-secondary-container: #141b2c;
104
+ --color-on-error: var(--color-error-100);
105
+ --color-on-error-container: var(--color-error-10);
106
+ --color-on-primary: var(--color-primary-100);
107
+ --color-on-primary-container: var(--color-primary-10);
108
+ --color-on-secondary: var(--color-secondary-100);
109
+ --color-on-secondary-container: var(--color-secondary-10);
109
110
  --color-on-surface: var(--color-neutral-10);
110
- --color-on-surface-variant: var(--color-neutral-30);
111
- --color-on-tertiary: #ffffff;
112
- --color-on-tertiary-container: #29132d;
111
+ --color-on-surface-variant: var(--color-neutral-variant-30);
112
+ --color-on-tertiary: var(--color-tertiary-100);
113
+ --color-on-tertiary-container: var(--color-tertiary-10);
113
114
  --color-orange: #ff7518;
114
115
  --color-orange-0: #000000;
115
116
  --color-orange-10: #341100;
@@ -126,7 +127,7 @@
126
127
  --color-orange-100: #ffffff;
127
128
  --color-outline: var(--color-neutral-variant-50);
128
129
  --color-outline-variant: var(--color-neutral-variant-80);
129
- --color-primary: #4589ff;
130
+ --color-primary: var(--color-primary-40);
130
131
  --color-primary-0: #000000;
131
132
  --color-primary-10: #001a42;
132
133
  --color-primary-20: #002e6b;
@@ -140,7 +141,7 @@
140
141
  --color-primary-95: #edf0ff;
141
142
  --color-primary-98: #faf9ff;
142
143
  --color-primary-100: #ffffff;
143
- --color-primary-container: #d8e2ff;
144
+ --color-primary-container: var(--color-primary-90);
144
145
  --color-purple: #e40078;
145
146
  --color-purple-0: #000000;
146
147
  --color-purple-10: #3f001c;
@@ -169,8 +170,8 @@
169
170
  --color-red-95: #ffedea;
170
171
  --color-red-98: #fff8f6;
171
172
  --color-red-100: #ffffff;
172
- --color-scrim: #000000;
173
- --color-secondary: #6f778b;
173
+ --color-scrim: var(--color-neutral-0);
174
+ --color-secondary: var(--color-secondary-40);
174
175
  --color-secondary-0: #000000;
175
176
  --color-secondary-10: #141b2c;
176
177
  --color-secondary-20: #293041;
@@ -184,8 +185,8 @@
184
185
  --color-secondary-95: #edf0ff;
185
186
  --color-secondary-98: #faf9ff;
186
187
  --color-secondary-100: #ffffff;
187
- --color-secondary-container: #dbe2f9;
188
- --color-shadow: #000000;
188
+ --color-secondary-container: var(--color-secondary-90);
189
+ --color-shadow: var(--color-neutral-0);
189
190
  --color-success: var(--color-green);
190
191
  --color-success-0: var(--color-green-0);
191
192
  --color-success-10: var(--color-green-10);
@@ -200,15 +201,15 @@
200
201
  --color-success-95: var(--color-green-95);
201
202
  --color-success-98: var(--color-green-98);
202
203
  --color-success-100: var(--color-green-100);
203
- --color-surface: var(--color-neutral-98);
204
+ --color-surface: var(--color-neutral-99);
204
205
  --color-surface-container: var(--color-neutral-94);
205
206
  --color-surface-container-high: var(--color-neutral-92);
206
207
  --color-surface-container-highest: var(--color-neutral-90);
207
208
  --color-surface-container-low: var(--color-neutral-96);
208
209
  --color-surface-container-lowest: var(--color-neutral-100);
209
210
  --color-surface-dim: var(--color-neutral-87);
210
- --color-surface-variant: var(--color-neutral-90);
211
- --color-tertiary: #8b6d8d;
211
+ --color-surface-variant: var(--color-neutral-variant-90);
212
+ --color-tertiary: var(--color-tertiary-40);
212
213
  --color-tertiary-0: #000000;
213
214
  --color-tertiary-10: #29132d;
214
215
  --color-tertiary-20: #402843;
@@ -222,7 +223,7 @@
222
223
  --color-tertiary-95: #ffebfc;
223
224
  --color-tertiary-98: #fff7fa;
224
225
  --color-tertiary-100: #ffffff;
225
- --color-tertiary-container: #fcd7fb;
226
+ --color-tertiary-container: var(--color-tertiary-90);
226
227
  --color-warning: var(--color-yellow);
227
228
  --color-warning-0: var(--color-yellow-0);
228
229
  --color-warning-10: var(--color-yellow-10);
@@ -274,7 +275,13 @@
274
275
  --font-weight-medium: 500; /* Slightly heavier than regular weight. 500 weight. */
275
276
  --font-weight-regular: 400; /* Standard weight for regular text. 400 weight. */
276
277
  --font-weight-semi-bold: 600; /* Heavier than medium weight. 600 weight. */
278
+ --global-avatar-border-radius: var(--shape-corner-full);
277
279
  --global-badge-color: var(--color-error-40);
280
+ --shape-corner-full: 9999px;
281
+ --shape-corner-large: 12px;
282
+ --shape-corner-medium: 8px;
283
+ --shape-corner-none: 0;
284
+ --shape-corner-small: 4px;
278
285
  --spacing-000: 0; /* No spacing (base × 0). */
279
286
  --spacing-025: 0.125rem; /* 2px - Smallest increment (base × 0.125). */
280
287
  --spacing-050: 0.25rem; /* 4px - Extra small spacing (base × 0.25). */
@@ -474,37 +481,42 @@
474
481
  }
475
482
 
476
483
  [data-theme='dark'] {
477
- --color-background: #201a19;
478
- --color-error-container: #93000a;
479
- --color-inverse-on-surface: #362f2e;
480
- --color-inverse-primary: #005ac4;
481
- --color-inverse-surface: #ede0dd;
482
- --color-on-background: #ede0dd;
483
- --color-on-error: #690005;
484
- --color-on-error-container: #ffb4ab;
485
- --color-on-primary: #002e6b;
486
- --color-on-primary-container: #d8e2ff;
487
- --color-on-secondary: #293041;
488
- --color-on-secondary-container: #dbe2f9;
489
- --color-on-surface: #ede0dd;
490
- --color-on-surface-variant: #d8c2be;
491
- --color-on-tertiary: #402843;
492
- --color-on-tertiary-container: #fcd7fb;
484
+ --color-error: var(--color-error-80);
485
+ --color-error-container: var(--color-error-30);
486
+ --color-inverse-error: var(--color-error-40);
487
+ --color-inverse-on-surface: var(--color-neutral-20);
488
+ --color-inverse-primary: var(--color-primary-40);
489
+ --color-inverse-secondary: var(--color-secondary-40);
490
+ --color-inverse-surface: var(--color-neutral-90);
491
+ --color-inverse-tertiary: var(--color-tertiary-40);
492
+ --color-on-error: var(--color-error-20);
493
+ --color-on-error-container: var(--color-error-90);
494
+ --color-on-primary: var(--color-primary-20);
495
+ --color-on-primary-container: var(--color-primary-90);
496
+ --color-on-secondary: var(--color-secondary-20);
497
+ --color-on-secondary-container: var(--color-secondary-90);
498
+ --color-on-surface: var(--color-neutral-90);
499
+ --color-on-surface-variant: var(--color-neutral-variant-80);
500
+ --color-on-tertiary: var(--color-tertiary-20);
501
+ --color-on-tertiary-container: var(--color-tertiary-90);
493
502
  --color-outline: var(--color-neutral-variant-60);
494
503
  --color-outline-variant: var(--color-neutral-variant-30);
495
- --color-primary-container: #004396;
496
- --color-scrim: #000000;
497
- --color-secondary-container: #3f4759;
498
- --color-shadow: #000000;
499
- --color-surface: #201a19;
504
+ --color-primary: var(--color-primary-80);
505
+ --color-primary-container: var(--color-primary-30);
506
+ --color-scrim: var(--color-neutral-0);
507
+ --color-secondary: var(--color-secondary-80);
508
+ --color-secondary-container: var(--color-secondary-30);
509
+ --color-shadow: var(--color-neutral-0);
510
+ --color-surface: var(--color-neutral-10);
500
511
  --color-surface-container: var(--color-neutral-12);
501
512
  --color-surface-container-high: var(--color-neutral-17);
502
513
  --color-surface-container-highest: var(--color-neutral-22);
503
514
  --color-surface-container-low: var(--color-neutral-10);
504
515
  --color-surface-container-lowest: var(--color-neutral-4);
505
516
  --color-surface-dim: var(--color-neutral-6);
506
- --color-surface-variant: #534341;
507
- --color-tertiary-container: #583e5a;
517
+ --color-surface-variant: var(--color-neutral-variant-30);
518
+ --color-tertiary: var(--color-tertiary-80);
519
+ --color-tertiary-container: var(--color-tertiary-30);
508
520
  --global-badge-color: var(--color-error-80);
509
521
  }
510
522
 
@@ -0,0 +1,11 @@
1
+ import fs from 'fs';
2
+
3
+ fs.cpSync('../design-tokens/dist/', './assets', {
4
+ recursive: true,
5
+ force: true,
6
+ });
7
+
8
+ fs.cpSync('../design-tokens/dist/', './dist/assets/styles/', {
9
+ recursive: true,
10
+ force: true,
11
+ });
@@ -1,16 +1,4 @@
1
- import { lazyLoaderPlugin } from '@wc-toolkit/lazy-loader';
2
-
3
- const formatComponentName = str => {
4
- return (
5
- str
6
- // 1. Remove the word "Component" if it exists at the end
7
- .replace(/Component$/, '')
8
- // 2. Find uppercase letters and replace with "-lowercase"
9
- .replace(/([a-z0-9])([A-Z])/g, '$1-$2')
10
- // 3. Convert the whole string to lowercase
11
- .toLowerCase()
12
- );
13
- };
1
+ import { customElementJetBrainsPlugin } from 'custom-element-jet-brains-integration';
14
2
 
15
3
  export default {
16
4
  /** Globs to analyze */
@@ -21,14 +9,14 @@ export default {
21
9
  /** Enable special handling for litelement */
22
10
  litelement: true,
23
11
 
24
- /*plugins: [
25
- lazyLoaderPlugin({
26
- importPathTemplate: (name, tagName) => {
27
- console.log(`./src/${formatComponentName(name)}/${tagName}.js`);
28
- return `./src/${formatComponentName(name)}/${tagName}.js`;
29
- },
30
- outdir: 'dist',
31
- eagerLoad: ['p-icon'],
12
+ packageJson: true,
13
+
14
+ plugins: [
15
+ customElementJetBrainsPlugin({
16
+ // Optional configuration options
17
+ outdir: 'dist', // Output directory for web-types.json
18
+ fileName: 'web-types.json', // Output file name
19
+ packageJson: true, // Automatically update the "web-types" property in package.json
32
20
  }),
33
- ],*/
21
+ ],
34
22
  };
@@ -1,88 +1,3 @@
1
- # `src/index.ts`:
2
-
3
- ## Exports
4
-
5
- | Kind | Name | Declaration | Module | Package |
6
- | ---- | -------- | ----------- | ------------------ | ------- |
7
- | `js` | `Icon` | Icon | ./icon/icon.js | |
8
- | `js` | `Avatar` | Avatar | ./avatar/avatar.js | |
9
-
10
- # `src/LoaderUtils.ts`:
11
-
12
- ## class: `LoaderUtils`
13
-
14
- ### Static Methods
15
-
16
- | Name | Privacy | Description | Parameters | Return | Inherited From |
17
- | ------------------- | ------- | ----------- | ------------------------------------------ | ------ | -------------- |
18
- | `registerComponent` | | | `tagName: string, CustomElementClass: any` | | |
19
-
20
- ### Methods
21
-
22
- | Name | Privacy | Description | Parameters | Return | Inherited From |
23
- | --------------------- | ------- | ----------- | --------------------------- | --------------- | -------------- |
24
- | `start` | | | | | |
25
- | `eagerLoadComponents` | | | | | |
26
- | `getFullTagName` | | | `name: string` | | |
27
- | `registerAsync` | | | `tagName: string` | `Promise<void>` | |
28
- | `load` | | | `root: Element \| Document` | `Promise<void>` | |
29
- | `lazyLoadComponents` | | | `root: any` | | |
30
-
31
- <hr/>
32
-
33
- ## Variables
34
-
35
- | Name | Description | Type |
36
- | -------------------- | ----------- | ---- |
37
- | `CustomElementClass` | | |
38
-
39
- <hr/>
40
-
41
- ## Exports
42
-
43
- | Kind | Name | Declaration | Module | Package |
44
- | --------------------------- | -------------- | ------------------ | ------------------ | ------- |
45
- | `js` | `LoaderConfig` | LoaderConfig | src/LoaderUtils.ts | |
46
- | `js` | `LoaderUtils` | LoaderUtils | src/LoaderUtils.ts | |
47
- | `custom-element-definition` | `tagName` | CustomElementClass | src/LoaderUtils.ts | |
48
- | `custom-element-definition` | `tagName` | CustomElementClass | src/LoaderUtils.ts | |
49
-
50
- # `src/utils.ts`:
51
-
52
- ## Functions
53
-
54
- | Name | Description | Parameters | Return |
55
- | ------------------ | ----------- | ---------------- | ------ |
56
- | `createCacheFetch` | | `name: string` | |
57
- | `sanitizeSvg` | | `rawSvg: string` | |
58
- | `getTypography` | | `name: string` | |
59
-
60
- <hr/>
61
-
62
- ## Exports
63
-
64
- | Kind | Name | Declaration | Module | Package |
65
- | ---- | ------------------ | ---------------- | ------------ | ------- |
66
- | `js` | `createCacheFetch` | createCacheFetch | src/utils.ts | |
67
- | `js` | `sanitizeSvg` | sanitizeSvg | src/utils.ts | |
68
- | `js` | `getTypography` | getTypography | src/utils.ts | |
69
-
70
- # `src/avatar/avatar.css.ts`:
71
-
72
- ## Variables
73
-
74
- | Name | Description | Type |
75
- | -------- | ----------- | ---- |
76
- | `styles` | | |
77
-
78
- <hr/>
79
-
80
- ## Exports
81
-
82
- | Kind | Name | Declaration | Module | Package |
83
- | ---- | -------- | ----------- | ------------------------ | ------- |
84
- | `js` | `styles` | styles | src/avatar/avatar.css.ts | |
85
-
86
1
  # `src/avatar/avatar.ts`:
87
2
 
88
3
  ## class: `Avatar`
@@ -107,13 +22,6 @@
107
22
  | `name` | name | |
108
23
  | `src` | src | |
109
24
 
110
- ### CSS Properties
111
-
112
- | Name | Default | Description |
113
- | -------------- | ------- | ------------------------------- |
114
- | `--icon-color` | | Controls the color of the icon. |
115
- | `--icon-size` | | Controls the size of the icon. |
116
-
117
25
  <hr/>
118
26
 
119
27
  ## Exports
@@ -122,47 +30,78 @@
122
30
  | ---- | -------- | ----------- | -------------------- | ------- |
123
31
  | `js` | `Avatar` | Avatar | src/avatar/avatar.ts | |
124
32
 
125
- # `src/avatar/index.ts`:
33
+ # `src/avatar/p-avatar.ts`:
126
34
 
127
- ## Exports
35
+ ## class: `PAvatar`, `p-avatar`
128
36
 
129
- | Kind | Name | Declaration | Module | Package |
130
- | ---- | -------- | ----------- | ----------- | ------- |
131
- | `js` | `Avatar` | Avatar | ./avatar.js | |
37
+ ### Superclass
132
38
 
133
- # `src/icon/datasource.ts`:
39
+ | Name | Module | Package |
40
+ | -------- | --------------------- | ------- |
41
+ | `Avatar` | /src/avatar/avatar.js | |
134
42
 
135
- ## Functions
43
+ ### Fields
44
+
45
+ | Name | Privacy | Type | Default | Description | Inherited From |
46
+ | ------ | ------- | --------------------- | ------- | ----------- | -------------- |
47
+ | `name` | | `string` | `''` | | Avatar |
48
+ | `src` | | `string \| undefined` | | | Avatar |
49
+
50
+ ### Attributes
51
+
52
+ | Name | Field | Inherited From |
53
+ | ------ | ----- | -------------- |
54
+ | `name` | name | Avatar |
55
+ | `src` | src | Avatar |
56
+
57
+ ### CSS Properties
136
58
 
137
- | Name | Description | Parameters | Return |
138
- | ----------- | ----------- | -------------------------------- | ------ |
139
- | `fetchSVG` | | `url: string` | |
140
- | `fetchIcon` | | `name: string, provider: string` | |
59
+ | Name | Default | Description |
60
+ | --------------------------- | ------- | --------------------------------- |
61
+ | `--avatar-background-color` | | Controls the color of the avatar. |
62
+ | `--avatar-size` | | Controls the size of the avatar. |
141
63
 
142
64
  <hr/>
143
65
 
144
66
  ## Exports
145
67
 
146
- | Kind | Name | Declaration | Module | Package |
147
- | ---- | ----------- | ----------- | ---------------------- | ------- |
148
- | `js` | `fetchSVG` | fetchSVG | src/icon/datasource.ts | |
149
- | `js` | `fetchIcon` | fetchIcon | src/icon/datasource.ts | |
68
+ | Kind | Name | Declaration | Module | Package |
69
+ | --------------------------- | ---------- | ----------- | ---------------------- | ------- |
70
+ | `js` | `PAvatar` | PAvatar | src/avatar/p-avatar.ts | |
71
+ | `custom-element-definition` | `p-avatar` | PAvatar | src/avatar/p-avatar.ts | |
72
+
73
+ # `src/badge/badge.ts`:
74
+
75
+ ## class: `Badge`
76
+
77
+ ### Superclass
150
78
 
151
- # `src/icon/icon.css.ts`:
79
+ | Name | Module | Package |
80
+ | ------------ | ------ | ------- |
81
+ | `LitElement` | | lit |
152
82
 
153
- ## Variables
83
+ ### Fields
154
84
 
155
- | Name | Description | Type |
156
- | -------- | ----------- | ---- |
157
- | `styles` | | |
85
+ | Name | Privacy | Type | Default | Description | Inherited From |
86
+ | ---------------- | ------- | --------------------- | ------- | ----------- | -------------- |
87
+ | `name` | | `string` | `''` | | |
88
+ | `src` | | `string \| undefined` | | | |
89
+ | `slotHasContent` | | `boolean` | `false` | | |
90
+
91
+ ### Attributes
92
+
93
+ | Name | Field | Inherited From |
94
+ | ------ | ----- | -------------- |
95
+ | `name` | name | |
96
+ | `src` | src | |
158
97
 
159
98
  <hr/>
160
99
 
161
100
  ## Exports
162
101
 
163
- | Kind | Name | Declaration | Module | Package |
164
- | ---- | -------- | ----------- | -------------------- | ------- |
165
- | `js` | `styles` | styles | src/icon/icon.css.ts | |
102
+ | Kind | Name | Declaration | Module | Package |
103
+ | ---- | ------- | ----------- | ------------------ | ------- |
104
+ | `js` | `Badge` | Badge | src/badge/badge.ts | |
166
105
 
167
106
  # `src/icon/icon.ts`:
168
107
 
@@ -178,7 +117,7 @@
178
117
 
179
118
  | Name | Privacy | Type | Default | Description | Inherited From |
180
119
  | ---------- | ------- | --------------------------------------------- | -------------------- | ----------- | -------------- |
181
- | `name` | | `string \| undefined` | `'home'` | | |
120
+ | `name` | | `string \| undefined` | | | |
182
121
  | `src` | | `string \| undefined` | | | |
183
122
  | `provider` | | `'material-symbols' \| 'carbon' \| undefined` | `'material-symbols'` | | |
184
123
 
@@ -196,13 +135,6 @@
196
135
  | `src` | src | |
197
136
  | `provider` | provider | |
198
137
 
199
- ### CSS Properties
200
-
201
- | Name | Default | Description |
202
- | -------------- | ------- | ------------------------------------------------- |
203
- | `--icon-color` | | Controls the color of the icon. |
204
- | `--icon-size` | `1rem` | Controls the size of the icon. Defaults to "1rem" |
205
-
206
138
  <hr/>
207
139
 
208
140
  ## Exports
@@ -211,17 +143,9 @@
211
143
  | ---- | ------ | ----------- | ---------------- | ------- |
212
144
  | `js` | `Icon` | Icon | src/icon/icon.ts | |
213
145
 
214
- # `src/icon/index.ts`:
215
-
216
- ## Exports
217
-
218
- | Kind | Name | Declaration | Module | Package |
219
- | ---- | ------ | ----------- | --------- | ------- |
220
- | `js` | `Icon` | Icon | ./icon.js | |
221
-
222
146
  # `src/icon/p-icon.ts`:
223
147
 
224
- ## class: `IconComponent`, `p-icon`
148
+ ## class: `PIcon`, `p-icon`
225
149
 
226
150
  ### Superclass
227
151
 
@@ -233,7 +157,7 @@
233
157
 
234
158
  | Name | Privacy | Type | Default | Description | Inherited From |
235
159
  | ---------- | ------- | --------------------------------------------- | -------------------- | ----------- | -------------- |
236
- | `name` | | `string \| undefined` | `'home'` | | Icon |
160
+ | `name` | | `string \| undefined` | | | Icon |
237
161
  | `src` | | `string \| undefined` | | | Icon |
238
162
  | `provider` | | `'material-symbols' \| 'carbon' \| undefined` | `'material-symbols'` | | Icon |
239
163
 
@@ -262,7 +186,7 @@
262
186
 
263
187
  ## Exports
264
188
 
265
- | Kind | Name | Declaration | Module | Package |
266
- | --------------------------- | --------------- | ------------- | ------------------ | ------- |
267
- | `js` | `IconComponent` | IconComponent | src/icon/p-icon.ts | |
268
- | `custom-element-definition` | `p-icon` | IconComponent | src/icon/p-icon.ts | |
189
+ | Kind | Name | Declaration | Module | Package |
190
+ | --------------------------- | -------- | ----------- | ------------------ | ------- |
191
+ | `js` | `PIcon` | PIcon | src/icon/p-icon.ts | |
192
+ | `custom-element-definition` | `p-icon` | PIcon | src/icon/p-icon.ts | |
package/demo/index.html CHANGED
@@ -3,7 +3,13 @@
3
3
  <head>
4
4
  <meta charset='utf-8'>
5
5
  <meta name='viewport' content='width=device-width, initial-scale=1.0, viewport-fit=cover' />
6
- <link rel='stylesheet' href='/demo/tokens.css' />
6
+
7
+ <!-- Default font : Noto Sans and Noto Sans Mono -->
8
+ <link rel="preconnect" href="https://fonts.googleapis.com">
9
+ <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
10
+ <link href="https://fonts.googleapis.com/css2?family=Noto+Sans+Mono:wght@100..900&family=Noto+Sans:ital,wght@0,100..900;1,100..900&display=swap" rel="stylesheet">
11
+
12
+
7
13
  <style>
8
14
  body {
9
15
  background: #fafafa;
@@ -13,17 +19,24 @@
13
19
  </head>
14
20
  <body>
15
21
 
16
- <a href='/src/icon/demo/index.html'>icon</a>
17
-
18
- <p-icon provider='carbon' name='logo--github'></p-icon>
22
+ <div id='tags'></div>
19
23
 
20
- <br/>
21
24
 
22
- <a href='/src/avatar/demo/index.html'>avatar</a>
23
- <p-avatar name='Test'></p-avatar>
25
+ <script type="module">
26
+ const res = await fetch('/dist/custom-elements.json');
27
+ const customElements = await res.json();
28
+ console.log(customElements)
29
+ const customTags = customElements.modules.filter(module =>
30
+ module.declarations.find(d => d.tagName),
31
+ );
24
32
 
33
+ console.log(customTags);
25
34
 
35
+ const $tags = document.querySelector('#tags');
36
+ customTags.forEach((tag) => {
37
+ $tags.innerHTML += `<p><a href='/src/${tag.declarations[0].tagName.split('-')[1]}/demo/index.html'>${tag.declarations[0].tagName}</p></a>`;
38
+ })
26
39
 
27
- <script type='module' src='/dist/src/peacock-loader.js'></script>
40
+ </script>
28
41
  </body>
29
42
  </html>
package/demo/int.html CHANGED
@@ -3,7 +3,7 @@
3
3
  <head>
4
4
  <meta charset='utf-8'>
5
5
  <meta name='viewport' content='width=device-width, initial-scale=1.0, viewport-fit=cover' />
6
- <link rel='stylesheet' href='/demo/tokens.css' />
6
+ <link rel='stylesheet' href='/dist/assets/styles/tokens.css' />
7
7
  <style>
8
8
  body {
9
9
  background: #fafafa;