Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: remove all Assets-static.js modules #8526

Merged
merged 1 commit into from
Mar 25, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 0 additions & 6 deletions packages/fiori/src/Assets-static.ts

This file was deleted.

Empty file.
2 changes: 1 addition & 1 deletion packages/icons-business-suite/src/json-imports/Icons.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const loadIconsBundle = async (collection: string): Promise<CollectionData> => {
}

if (typeof iconData === "string" && (iconData as string).endsWith(".json")) {
throw new Error("[icons-business-suite] Invalid bundling detected - dynamic JSON imports bundled as URLs. Switch to inlining JSON files from the build or use `import \"@ui5/webcomponents-icons-business-suite/dist/Assets-static.js\". Check the \"Assets\" documentation for more information.");
throw new Error("[icons-business-suite] Invalid bundling detected - dynamic JSON imports bundled as URLs. Switch to inlining JSON files from the build. Check the \"Assets\" documentation for more information.");
}
return iconData;
}
Expand Down
Empty file.
2 changes: 1 addition & 1 deletion packages/icons-tnt/src/json-imports/Icons.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const loadIconsBundle = async (collection: string): Promise<CollectionData> => {
}

if (typeof iconData === "string" && (iconData as string).endsWith(".json")) {
throw new Error("[icons-tnt] Invalid bundling detected - dynamic JSON imports bundled as URLs. Switch to inlining JSON files from the build or use `import \"@ui5/webcomponents-icons-tnt/dist/Assets-static.js\". Check the \"Assets\" documentation for more information.");
throw new Error("[icons-tnt] Invalid bundling detected - dynamic JSON imports bundled as URLs. Switch to inlining JSON files from the build. Check the \"Assets\" documentation for more information.");
}
return iconData;
}
Expand Down
1 change: 0 additions & 1 deletion packages/icons/src/Assets-static.ts

This file was deleted.

2 changes: 1 addition & 1 deletion packages/icons/src/json-imports/Icons.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const loadIconsBundle = async (collection: string): Promise<CollectionData> => {
}

if (typeof iconData === "string" && (iconData as string).endsWith(".json")) {
throw new Error("[icons] Invalid bundling detected - dynamic JSON imports bundled as URLs. Switch to inlining JSON files from the build or use `import \"@ui5/webcomponents-icons/dist/Assets-static.js\". Check the \"Assets\" documentation for more information.");
throw new Error("[icons] Invalid bundling detected - dynamic JSON imports bundled as URLs. Switch to inlining JSON files from the build. Check the \"Assets\" documentation for more information.");
}
return iconData;
}
Expand Down
2 changes: 1 addition & 1 deletion packages/localization/lib/generate-json-imports/cldr.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ ${caseImports}
const importAndCheck = async (localeId) => {
const data = await importCldrJson(localeId);
if (typeof data === "string" && data.endsWith(".json")) {
throw new Error(\`[LocaleData] Invalid bundling detected - dynamic JSON imports bundled as URLs. Switch to inlining JSON files from the build or use 'import ".../Assets-static.js"'. Check the \"Assets\" documentation for more information.\`);
throw new Error(\`[LocaleData] Invalid bundling detected - dynamic JSON imports bundled as URLs. Switch to inlining JSON files from the build. Check the \"Assets\" documentation for more information.\`);
}
return data;
}
Expand Down
2 changes: 0 additions & 2 deletions packages/localization/src/Assets-static.ts

This file was deleted.

6 changes: 0 additions & 6 deletions packages/main/src/Assets-static.ts

This file was deleted.

2 changes: 0 additions & 2 deletions packages/theming/src/Assets-static.ts

This file was deleted.

2 changes: 1 addition & 1 deletion packages/tools/lib/generate-json-imports/i18n.js
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ import { registerI18nLoader } from "@ui5/webcomponents-base/dist/asset-registrie
const importAndCheck = async (localeId) => {
const data = await importMessageBundle(localeId);
if (typeof data === "string" && data.endsWith(".json")) {
throw new Error(\`[i18n] Invalid bundling detected - dynamic JSON imports bundled as URLs. Switch to inlining JSON files from the build or use 'import ".../Assets-static.js"'. Check the \"Assets\" documentation for more information.\`);
throw new Error(\`[i18n] Invalid bundling detected - dynamic JSON imports bundled as URLs. Switch to inlining JSON files from the build. Check the \"Assets\" documentation for more information.\`);
}
return data;
}
Expand Down
2 changes: 1 addition & 1 deletion packages/tools/lib/generate-json-imports/themes.js
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ ${dynamicImportLines}
const loadAndCheck = async (themeName) => {
const data = await loadThemeProperties(themeName);
if (typeof data === "string" && data.endsWith(".json")) {
throw new Error(\`[themes] Invalid bundling detected - dynamic JSON imports bundled as URLs. Switch to inlining JSON files from the build or use 'import ".../Assets-static.js"'. Check the \"Assets\" documentation for more information.\`);
throw new Error(\`[themes] Invalid bundling detected - dynamic JSON imports bundled as URLs. Switch to inlining JSON files from the build. Check the \"Assets\" documentation for more information.\`);
}
return data;
};
Expand Down