Skip to content

Commit

Permalink
Update embed button color variable (#131)
Browse files Browse the repository at this point in the history
Signed-off-by: mohin7 <[email protected]>
  • Loading branch information
mohin7 authored Feb 19, 2024
1 parent 21aedf8 commit bfc1d8e
Showing 1 changed file with 10 additions and 8 deletions.
18 changes: 10 additions & 8 deletions layouts/_default/embed_console.html
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,9 @@
width: calc(100% - 64px);
&:hover {
background-color: var(--ac-primary, #1c1c1c);
color: #ffffff;
color: var(--ac-text, #ffffff);
.tag{
background-color: #ffffff;
background-color: var(--ac-text, #ffffff);
color: var(--ac-primary, #1c1c1c);
}
}
Expand All @@ -48,7 +48,7 @@
border-radius: 4px;
margin-left: 4px;
background-color: var(--ac-primary, #1c1c1c);
color: #ffffff;
color: var(--ac-text, #ffffff);
transition: 0.3s ease-in-out;
font-size: 12px;
&.is-hidden {
Expand Down Expand Up @@ -77,13 +77,11 @@
border-right: 4px solid rgba(255, 255, 255, 0.0);
animation: spinner .6s linear infinite;
}
}


@keyframes spinner {
to {transform: rotate(360deg);}
}
@keyframes spinner {
to {transform: rotate(360deg);}
}


</style>
</head>
Expand All @@ -99,9 +97,13 @@

const urlParams = new URLSearchParams(window.location.search);
const color = urlParams.get('color');
const text = urlParams.get('text');
if (color) {
acSignInButton.style.setProperty('--ac-primary', "#"+color);
}
if (text) {
acSignInButton.style.setProperty('--ac-text',"#"+text);
}

// function to get cookie
function getCookie(cname) {
Expand Down

0 comments on commit bfc1d8e

Please sign in to comment.