Skip to content

Commit

Permalink
ref: change randomId lengths
Browse files Browse the repository at this point in the history
  • Loading branch information
Sv443 committed Nov 8, 2024
1 parent 23ebc23 commit 273e1ae
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/components/toggleInput.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ export interface ToggleInputProps {
export async function createToggleInput({
onChange,
initialValue = false,
id = randomId(8, 26),
id = randomId(6, 36),
labelPos = "left",
}: ToggleInputProps) {
const wrapperEl = document.createElement("div");
Expand Down
2 changes: 1 addition & 1 deletion src/utils/dom.ts
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ export async function addStyle(css: string, ref?: string, transform: (css: strin
if(!domLoaded)
throw new Error("DOM has not finished loading yet");
const elem = addGlobalStyle(await transform(css));
elem.id = `bytm-style-${ref ?? randomId(5, 36)}`;
elem.id = `bytm-style-${ref ?? randomId(6, 36)}`;
return elem;
}

Expand Down

0 comments on commit 273e1ae

Please sign in to comment.