mirror of
https://github.com/ful1e5/apple_cursor.git
synced 2025-05-14 07:04:47 -04:00
⚡ Frames padding added
This commit is contained in:
parent
2360da1472
commit
ff6772e41e
1 changed files with 6 additions and 2 deletions
|
@ -8,7 +8,11 @@ export const frameNumber = (index: number, endIndex: number) => {
|
||||||
return result;
|
return result;
|
||||||
};
|
};
|
||||||
|
|
||||||
export const getFrameName = (index: number, fileName: string) => {
|
export const getFrameName = (
|
||||||
const frame = frameNumber(index, 2);
|
index: number,
|
||||||
|
fileName: string,
|
||||||
|
padding: number = 2
|
||||||
|
) => {
|
||||||
|
const frame = frameNumber(index, padding);
|
||||||
return `${path.basename(fileName, ".svg")}-${frame}.png`;
|
return `${path.basename(fileName, ".svg")}-${frame}.png`;
|
||||||
};
|
};
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue