Skip to content

Commit a168cb5

Browse files
fix(ui): Ensure UI bundle svgr config is using plugins (#7821)
1 parent 14ca5e4 commit a168cb5

2 files changed

Lines changed: 12 additions & 1 deletion

File tree

.changeset/every-results-help.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@clerk/ui': patch
3+
---
4+
5+
Fix issue where SVG elements had unexpected width/height attributes

packages/ui/tsdown.config.mts

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,13 @@ export default defineConfig(({ watch }) => {
1414
external: ['react', 'react-dom', '@clerk/localizations', '@clerk/shared'],
1515
format: ['esm'], // ESM only
1616
minify: false,
17-
plugins: [svgr()],
17+
plugins: [
18+
svgr({
19+
svgoConfig: {
20+
plugins: ['preset-default', 'removeDimensions', 'removeStyleElement'],
21+
},
22+
}),
23+
],
1824
define: {
1925
PACKAGE_NAME: `"${uiPackage.name}"`,
2026
PACKAGE_VERSION: `"${uiPackage.version}"`,

0 commit comments

Comments
 (0)