Fonts + Only Pointers in sync.Maps

This commit is contained in:
Simon Martens
2024-12-20 01:10:39 +01:00
parent 9012fdcb17
commit 3ef30ef7c7
17 changed files with 323 additions and 255 deletions

View File

@@ -0,0 +1,71 @@
@font-face {
font-family: "Rancho";
font-style: normal;
font-weight: 500;
font-display: swap;
src: url(/assets/fonts/Rancho-Regular.ttf) format("truetype");
}
@font-face {
font-family: "Merriweather";
font-style: normal;
font-weight: 500;
font-display: swap;
src: url(/assets/fonts/Merriweather-Regular.ttf) format("truetype");
}
@font-face {
font-family: "Merriweather";
font-style: italic;
font-weight: 500;
font-display: swap;
src: url(/assets/fonts/Merriweather-Italic.ttf) format("truetype");
}
@font-face {
font-family: "Merriweather";
font-style: normal;
font-weight: bold;
font-display: swap;
src: url(/assets/fonts/Merriweather-Bold.ttf) format("truetype");
}
@font-face {
font-family: "Merriweather";
font-style: italic;
font-weight: bold;
font-display: swap;
src: url(/assets/fonts/SourceSans3-BoldItalic.ttf) format("truetype");
}
@font-face {
font-family: "Source Sans 3";
font-style: normal;
font-weight: 500;
font-display: swap;
src: url(/assets/fonts/SourceSans3-Medium.ttf) format("truetype");
}
@font-face {
font-family: "Source Sans 3";
font-style: italic;
font-weight: 500;
font-display: swap;
src: url(/assets/fonts/SourceSans3-MediumItalic.ttf) format("truetype");
}
@font-face {
font-family: "Source Sans 3";
font-style: normal;
font-weight: bold;
font-display: swap;
src: url(/assets/fonts/SourceSans3-Bold.ttf) format("truetype");
}
@font-face {
font-family: "Source Sans 3";
font-style: italic;
font-weight: bold;
font-display: swap;
src: url(/assets/fonts/SourceSans3-BoldItalic.ttf) format("truetype");
}

View File

@@ -1,31 +1,22 @@
function setup() {
let templates = document.querySelectorAll("template[simple]");
templates.forEach((template) => {
let templateId = template.getAttribute("id");
let templateContent = template.content;
customElements.define(templateId, class extends HTMLElement {
function a() {
document.querySelectorAll("template[simple]").forEach((l) => {
let s = l.getAttribute("id"), n = l.content;
customElements.define(s, class extends HTMLElement {
constructor() {
super();
this.appendChild(templateContent.cloneNode(true));
this.slots = this.querySelectorAll("slot");
super(), this.appendChild(n.cloneNode(!0)), this.slots = this.querySelectorAll("slot");
}
connectedCallback() {
let toremove = [];
this.slots.forEach((tslot) => {
let slotName = tslot.getAttribute("name");
let slotContent = this.querySelector(`[slot="${slotName}"]`);
if (slotContent) {
tslot.replaceWith(slotContent.cloneNode(true));
toremove.push(slotContent);
}
});
toremove.forEach((element) => {
element.remove();
let o = [];
this.slots.forEach((e) => {
let r = e.getAttribute("name"), t = this.querySelector(`[slot="${r}"]`);
t && (e.replaceWith(t.cloneNode(!0)), o.push(t));
}), o.forEach((e) => {
e.remove();
});
}
});
});
}
export {
setup
a as setup
};

View File

@@ -554,114 +554,6 @@ video {
display: none;
}
@font-face {
font-family: "Rancho";
font-style: normal;
font-weight: 500;
font-display: swap;
src: url(/publi/public/fonts/Rancho-Regular.ttf) format("truetype");
}
@font-face {
font-family: "Merriweather";
font-style: normal;
font-weight: 500;
font-display: swap;
src: url(/public/fonts/Merriweather-Regular.ttf) format("truetype");
}
@font-face {
font-family: "Merriweather";
font-style: italic;
font-weight: 500;
font-display: swap;
src: url(/public/fonts/Merriweather-Italic.ttf) format("truetype");
}
@font-face {
font-family: "Merriweather";
font-style: normal;
font-weight: bold;
font-display: swap;
src: url(/public/fonts/Merriweather-Bold.ttf) format("truetype");
}
@font-face {
font-family: "Merriweather";
font-style: italic;
font-weight: bold;
font-display: swap;
src: url(/public/fonts/SourceSans3-BoldItalic.ttf) format("truetype");
}
@font-face {
font-family: "Source Sans 3";
font-style: normal;
font-weight: 500;
font-display: swap;
src: url(/public/fonts/SourceSans3-Medium.ttf) format("truetype");
}
@font-face {
font-family: "Source Sans 3";
font-style: italic;
font-weight: 500;
font-display: swap;
src: url(/public/fonts/SourceSans3-MediumItalic.ttf) format("truetype");
}
@font-face {
font-family: "Source Sans 3";
font-style: normal;
font-weight: bold;
font-display: swap;
src: url(/public/fonts/SourceSans3-Bold.ttf) format("truetype");
}
@font-face {
font-family: "Source Sans 3";
font-style: italic;
font-weight: bold;
font-display: swap;
src: url(/public/fonts/SourceSans3-BoldItalic.ttf) format("truetype");
}
html {
font-size: 15.5px;
}