@spectrum-web-components/icons-ui 0.42.2 → 0.42.3

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/bin/build.js CHANGED
@@ -141,20 +141,22 @@ icons.forEach((i) => {
141
141
  }
142
142
  `;
143
143
 
144
- const icon = prettier.format(iconLiteral, {
145
- printWidth: 100,
146
- tabWidth: 2,
147
- useTabs: false,
148
- semi: true,
149
- singleQuote: true,
150
- trailingComma: 'all',
151
- bracketSpacing: true,
152
- jsxBracketSameLine: false,
153
- arrowParens: 'avoid',
154
- parser: 'typescript',
155
- });
156
-
157
- fs.writeFileSync(location, icon, 'utf-8');
144
+ prettier
145
+ .format(iconLiteral, {
146
+ printWidth: 100,
147
+ tabWidth: 2,
148
+ useTabs: false,
149
+ semi: true,
150
+ singleQuote: true,
151
+ trailingComma: 'all',
152
+ bracketSpacing: true,
153
+ jsxBracketSameLine: false,
154
+ arrowParens: 'avoid',
155
+ parser: 'typescript',
156
+ })
157
+ .then((icon) => {
158
+ fs.writeFileSync(location, icon, 'utf-8');
159
+ });
158
160
 
159
161
  const exportString = `export {${ComponentName}Icon} from './icons/${id}.js';\r\n`;
160
162
  fs.appendFileSync(
@@ -192,31 +194,33 @@ icons.forEach((i) => {
192
194
  }
193
195
  }
194
196
  `;
195
- const iconElementFile = prettier.format(iconElement, {
196
- printWidth: 100,
197
- tabWidth: 2,
198
- useTabs: false,
199
- semi: true,
200
- singleQuote: true,
201
- trailingComma: 'all',
202
- bracketSpacing: true,
203
- jsxBracketSameLine: false,
204
- arrowParens: 'avoid',
205
- parser: 'typescript',
206
- });
207
-
208
- fs.writeFileSync(
209
- path.join(
210
- rootDir,
211
- 'packages',
212
- 'icons-ui',
213
- 'src',
214
- 'elements',
215
- `Icon${id}.ts`
216
- ),
217
- iconElementFile,
218
- 'utf-8'
219
- );
197
+ prettier
198
+ .format(iconElement, {
199
+ printWidth: 100,
200
+ tabWidth: 2,
201
+ useTabs: false,
202
+ semi: true,
203
+ singleQuote: true,
204
+ trailingComma: 'all',
205
+ bracketSpacing: true,
206
+ jsxBracketSameLine: false,
207
+ arrowParens: 'avoid',
208
+ parser: 'typescript',
209
+ })
210
+ .then((iconElementFile) => {
211
+ fs.writeFileSync(
212
+ path.join(
213
+ rootDir,
214
+ 'packages',
215
+ 'icons-ui',
216
+ 'src',
217
+ 'elements',
218
+ `Icon${id}.ts`
219
+ ),
220
+ iconElementFile,
221
+ 'utf-8'
222
+ );
223
+ });
220
224
 
221
225
  const iconRegistration = `
222
226
  ${disclaimer}
@@ -232,30 +236,32 @@ icons.forEach((i) => {
232
236
  }
233
237
  }
234
238
  `;
235
- const iconRegistrationFile = prettier.format(iconRegistration, {
236
- printWidth: 100,
237
- tabWidth: 2,
238
- useTabs: false,
239
- semi: true,
240
- singleQuote: true,
241
- trailingComma: 'all',
242
- bracketSpacing: true,
243
- jsxBracketSameLine: false,
244
- arrowParens: 'avoid',
245
- parser: 'typescript',
246
- });
247
-
248
- fs.writeFileSync(
249
- path.join(
250
- rootDir,
251
- 'packages',
252
- 'icons-ui',
253
- 'icons',
254
- `${iconElementName}.ts`
255
- ),
256
- iconRegistrationFile,
257
- 'utf-8'
258
- );
239
+ prettier
240
+ .format(iconRegistration, {
241
+ printWidth: 100,
242
+ tabWidth: 2,
243
+ useTabs: false,
244
+ semi: true,
245
+ singleQuote: true,
246
+ trailingComma: 'all',
247
+ bracketSpacing: true,
248
+ jsxBracketSameLine: false,
249
+ arrowParens: 'avoid',
250
+ parser: 'typescript',
251
+ })
252
+ .then((iconRegistrationFile) => {
253
+ fs.writeFileSync(
254
+ path.join(
255
+ rootDir,
256
+ 'packages',
257
+ 'icons-ui',
258
+ 'icons',
259
+ `${iconElementName}.ts`
260
+ ),
261
+ iconRegistrationFile,
262
+ 'utf-8'
263
+ );
264
+ });
259
265
  const importStatement = `\r\nimport '@spectrum-web-components/icons-ui/icons/${iconElementName}.js';`;
260
266
  const metadata = `{name: '${Case.sentence(
261
267
  ComponentName
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@spectrum-web-components/icons-ui",
3
- "version": "0.42.2",
3
+ "version": "0.42.3",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -44,9 +44,9 @@
44
44
  "lit-html"
45
45
  ],
46
46
  "dependencies": {
47
- "@spectrum-web-components/base": "^0.42.2",
48
- "@spectrum-web-components/icon": "^0.42.2",
49
- "@spectrum-web-components/iconset": "^0.42.2"
47
+ "@spectrum-web-components/base": "^0.42.3",
48
+ "@spectrum-web-components/icon": "^0.42.3",
49
+ "@spectrum-web-components/iconset": "^0.42.3"
50
50
  },
51
51
  "devDependencies": {
52
52
  "@spectrum-css/ui-icons": "^1.1.2",
@@ -55,7 +55,7 @@
55
55
  "fast-glob": "^3.2.12",
56
56
  "fs": "^0.0.1-security",
57
57
  "path": "^0.12.7",
58
- "prettier": "^2.7.1"
58
+ "prettier": "^3.0.0"
59
59
  },
60
60
  "types": "./src/index.d.ts",
61
61
  "customElements": "custom-elements.json",
@@ -63,5 +63,5 @@
63
63
  "./src/index.js",
64
64
  "./icons/*"
65
65
  ],
66
- "gitHead": "e19af30387032608baaa88c6a17c2ee50103a7c5"
66
+ "gitHead": "a03edce4f21f232f1705d8eb222e6e5436cad4c3"
67
67
  }
@@ -1,6 +1,6 @@
1
1
  import { html, TemplateResult } from '@spectrum-web-components/base';
2
2
  export type { TemplateResult };
3
- export declare type GenericTemplateLiteralTagType = (strings: TemplateStringsArray, ...values: unknown[]) => string;
4
- declare type TemplateLiteralTagType = GenericTemplateLiteralTagType | typeof html;
3
+ export type GenericTemplateLiteralTagType = (strings: TemplateStringsArray, ...values: unknown[]) => string;
4
+ type TemplateLiteralTagType = GenericTemplateLiteralTagType | typeof html;
5
5
  export declare const tag: (strings: TemplateStringsArray, ...values: unknown[]) => string | TemplateResult;
6
6
  export declare const setCustomTemplateLiteralTag: (tag: TemplateLiteralTagType) => void;