🎨 Improved file titles

This commit is contained in:
Miguel Avila 2021-08-14 11:49:20 -05:00
parent 93bfc062f1
commit 591fa0176a
4 changed files with 14 additions and 12 deletions

View File

@ -2,7 +2,6 @@
// │ ├─┤├┬┘ ││└─┐ // │ ├─┤├┬┘ ││└─┐
// └─┘┴ ┴┴└──┴┘└─┘ // └─┘┴ ┴┴└──┴┘└─┘
const printCards = () => { const printCards = () => {
for (const card of CONFIG.cards) { for (const card of CONFIG.cards) {
console.log(card.id); console.log(card.id);
@ -10,18 +9,14 @@ const printCards = () => {
let item = ` let item = `
<a <a
href="${card.link}" href="${card.link}"
target="${CONFIG.openInNewTab ? "_blank" : ""}" target="${CONFIG.openInNewTab ? '_blank' : ''}"
class="buttonLink__link card buttonLink__link-${ class="buttonLink__link card buttonLink__link-${card.id}"
card.id
}"
> >
<i class="buttonLink__icon" data-feather="${ <i class="buttonLink__icon" data-feather="${card.icon}"></i>
card.icon
}"></i>
</a> </a>
`; `;
const position = "beforeend"; const position = 'beforeend';
buttonsContainer.insertAdjacentHTML(position, item); buttonsContainer.insertAdjacentHTML(position, item);
} }

View File

@ -1,3 +1,7 @@
// ┌─┐┬─┐┌─┐┌─┐┌┬┐┬┌┐┌┌─┐┌─┐
// │ ┬├┬┘├┤ ├┤ │ │││││ ┬└─┐
// └─┘┴└─└─┘└─┘ ┴ ┴┘└┘└─┘└─┘
// Get the hour // Get the hour
const today = new Date(); const today = new Date();
const hour = today.getHours(); const hour = today.getHours();

View File

@ -1,3 +1,7 @@
// ┌┬┐┬ ┬┌─┐┌┬┐┌─┐
// │ ├─┤├┤ │││├┤
// ┴ ┴ ┴└─┘┴ ┴└─┘
// Store the theme // Store the theme
let darkTheme = localStorage.getItem('darkTheme'); let darkTheme = localStorage.getItem('darkTheme');
const themeToggle = document.querySelector('#themeButton'); const themeToggle = document.querySelector('#themeButton');
@ -35,6 +39,6 @@ themeToggle.addEventListener('click', () => {
} }
}); });
if(CONFIG.imageBackground) { if (CONFIG.imageBackground) {
document.body.classList.add('withImageBackground'); document.body.classList.add('withImageBackground');
} }

View File

@ -29,7 +29,6 @@ const CONFIG = {
weatherLatitude: '37.774929', weatherLatitude: '37.774929',
weatherLongitude: '-122.419418', weatherLongitude: '-122.419418',
// ┌─┐┌─┐┬─┐┌┬┐┌─┐ // ┌─┐┌─┐┬─┐┌┬┐┌─┐
// │ ├─┤├┬┘ ││└─┐ // │ ├─┤├┬┘ ││└─┐
// └─┘┴ ┴┴└──┴┘└─┘ // └─┘┴ ┴┴└──┴┘└─┘