fix: Avoid styles getting purged on prod build (#7086)
This commit is contained in:
@@ -28,8 +28,12 @@ body {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.heading {
|
.heading {
|
||||||
|
.permalink {
|
||||||
|
visibility: hidden;
|
||||||
|
}
|
||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
a {
|
.permalink {
|
||||||
visibility: visible;
|
visibility: visible;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ export const getHeadingsfromTheArticle = () => {
|
|||||||
const slug = slugifyWithCounter(element.innerText);
|
const slug = slugifyWithCounter(element.innerText);
|
||||||
element.id = slug;
|
element.id = slug;
|
||||||
element.className = 'scroll-mt-24 heading';
|
element.className = 'scroll-mt-24 heading';
|
||||||
element.innerHTML += `<a class="invisible text-slate-600 ml-3" href="#${slug}" title="${element.innerText}" data-turbolinks="false">#</a>`;
|
element.innerHTML += `<a class="permalink text-slate-600 ml-3" href="#${slug}" title="${element.innerText}" data-turbolinks="false">#</a>`;
|
||||||
rows.push({
|
rows.push({
|
||||||
slug,
|
slug,
|
||||||
title: element.innerText,
|
title: element.innerText,
|
||||||
|
|||||||
Reference in New Issue
Block a user