You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
1 line
992 B
1 line
992 B
import{i as e}from"./competitionBranding-DKFkcrfF.js";var t=`#052d62`;function n(e){let t=e.trim().replace(`#`,``);return/^[0-9a-f]{6}$/i.test(t)?`${parseInt(t.slice(0,2),16)}, ${parseInt(t.slice(2,4),16)}, ${parseInt(t.slice(4,6),16)}`:null}function r(r){if(typeof document>`u`)return;let i=r?.trim()??``,a=e(i)?/^(?:#|rgb|hsl)/i.test(i)?i:`#${i.replace(/^#/,``)}`:t;if(document.body.style.setProperty(`--primary`,a),document.body.style.setProperty(`--bs-primary`,a),a.startsWith(`#`)){document.body.style.setProperty(`--primary-soft`,`${a}14`);let e=n(a);e&&document.body.style.setProperty(`--bs-primary-rgb`,e)}else document.body.style.removeProperty(`--primary-soft`),document.body.style.removeProperty(`--bs-primary-rgb`)}function i(){typeof document>`u`||(document.body.style.removeProperty(`--primary`),document.body.style.removeProperty(`--primary-soft`),document.body.style.removeProperty(`--bs-primary`),document.body.style.removeProperty(`--bs-primary-rgb`))}export{i as n,r as t}; |