Add config menu framework
Options don't do anything as of now, but they are saved and loaded
This commit is contained in:
parent
6bca12c934
commit
fc4ce8e69e
3 changed files with 127 additions and 2 deletions
|
@ -105,4 +105,11 @@ export function imgSrcToIDs(imgSrc: string | null): { fileID: string; syncID: st
|
|||
|
||||
return assetPathToIDs(imgSrc);
|
||||
|
||||
}
|
||||
|
||||
export function validateColor(hex: string) {
|
||||
hex = hex.replace('#', '');
|
||||
return typeof hex === 'string'
|
||||
&& hex.length === 6
|
||||
&& !isNaN(Number('0x' + hex))
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue