21 lines
658 B
JavaScript
21 lines
658 B
JavaScript
const toolbarConfig = {
|
|
size: 25,
|
|
gap: 10,
|
|
radius: 7,
|
|
paddingY: 6,
|
|
iconPadding: 5,
|
|
iconSize: 13,
|
|
};
|
|
|
|
const applyToolbarVars = () => {
|
|
const root = document.documentElement;
|
|
root.style.setProperty("--tb-size", `${toolbarConfig.size}px`);
|
|
root.style.setProperty("--tb-gap", `${toolbarConfig.gap}px`);
|
|
root.style.setProperty("--tb-radius", `${toolbarConfig.radius}px`);
|
|
root.style.setProperty("--tb-pad-y", `${toolbarConfig.paddingY}px`);
|
|
root.style.setProperty("--tb-icon-pad", `${toolbarConfig.iconPadding}px`);
|
|
root.style.setProperty("--tb-icon-size", `${toolbarConfig.iconSize}px`);
|
|
};
|
|
|
|
export { toolbarConfig, applyToolbarVars };
|