Skip to content

Commit

Permalink
Merge pull request #365 from db-ui/fix-placeholder-fallback
Browse files Browse the repository at this point in the history
fix: issue with placeholder fallback
  • Loading branch information
nmerget authored Dec 10, 2024
2 parents 63efdc3 + 718f6df commit 86307f8
Showing 1 changed file with 0 additions and 12 deletions.
12 changes: 0 additions & 12 deletions src/generate-icon-fonts/gather-icons.ts
Original file line number Diff line number Diff line change
Expand Up @@ -194,8 +194,6 @@ const gatherIcons = (
const sizeFilePath = `${temporaryDirectory}/${allTemporaryDir}/${generalPrefix}${fileName}${sizeFileEnding}.svg`;
const fallbackFilePath = `${temporaryDirectory}/${allTemporaryDir}/${generalPrefix}${iconFileName}.svg`;
const fallbackSizeFilePath = `${temporaryDirectory}/${allTemporaryDir}/${generalPrefix}${iconFileName}${sizeFileEnding}.svg`;
const placeholderFilePath = `${temporaryDirectory}/${allTemporaryDir}/${generalPrefix}x_placeholder.svg`;
const placeholderSizeFilePath = `${temporaryDirectory}/${allTemporaryDir}/${generalPrefix}x_placeholder${sizeFileEnding}.svg`;

if (!FSE.existsSync(`${temporaryDirectory}/${directory}`)) {
FSE.mkdirSync(`${temporaryDirectory}/${directory}`, {
Expand All @@ -213,16 +211,6 @@ const gatherIcons = (
defaultFilePath,
`${temporaryDirectory}/${directory}/${generalPrefix}${iconFileName}.svg`,
);
} else if (FSE.existsSync(placeholderSizeFilePath)) {
FSE.copyFileSync(
placeholderSizeFilePath,
`${temporaryDirectory}/${directory}/${generalPrefix}${iconFileName}.svg`,
);
} else if (FSE.existsSync(placeholderFilePath)) {
FSE.copyFileSync(
placeholderFilePath,
`${temporaryDirectory}/${directory}/${generalPrefix}${iconFileName}.svg`,
);
} else if (FSE.existsSync(fallbackSizeFilePath)) {
FSE.copyFileSync(
fallbackSizeFilePath,
Expand Down

0 comments on commit 86307f8

Please sign in to comment.