Skip to content

Commit

Permalink
Showing 4 changed files with 8 additions and 1 deletion.
1 change: 1 addition & 0 deletions ui-icons/package.json
Original file line number Diff line number Diff line change
@@ -3,6 +3,7 @@
"version": "0.1.0",
"type": "module",
"module": "dist/index.esm.js",
"types": "dist/index.d.ts",
"scripts": {
"svgo": "svgo icons --config svgo.config.cjs",
"build-components": "node ./scripts/build.js",
1 change: 1 addition & 0 deletions ui-icons/rollup.config.js
Original file line number Diff line number Diff line change
@@ -23,6 +23,7 @@ export default {
babelHelpers: 'bundled'
}),
typescript(),
terser()
],
output: formats.map(format => ({
file: `dist/index.${format}.js`,
2 changes: 1 addition & 1 deletion ui-icons/scripts/build.js
Original file line number Diff line number Diff line change
@@ -136,7 +136,7 @@ for (const [name, currentData] of Object.entries(representation)) {

return [
`IconReplaceName${variant}Props`,
`interface IconReplaceName${variant}Props {size?: ${sizeStr}, variant?: '${variant}', title?: string, color?: string}`
`interface IconReplaceName${variant}Props {size?: ${sizeStr}, variant?: '${variant}', title?: string}`
]
})
const iconPropsContent = definitions.map(([name, content]) => `${content}\n`).join('\n')
5 changes: 5 additions & 0 deletions ui-icons/src/types/osrd-generic-icon-type.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
export type OSRDGenericIconType = {
variant?: string;
size?: string;
title?: string;
};

0 comments on commit 9920d48

Please sign in to comment.