chore: update code structure and remove redundant changes

This commit is contained in:
sHa
2025-06-18 00:30:47 +03:00
parent ca97046961
commit d87e79f44d
10 changed files with 6437 additions and 1959 deletions

View File

@@ -794,36 +794,6 @@
/>
</Router>
<Header
{displayLogos}
allLogos={logos}
{theme}
{setTheme}
{viewMode}
{setGridView}
{setListView}
{setCompactView}
{searchQuery}
{setSearchQuery}
{allTags}
{selectedTags}
{selectedBrands}
{selectedVariants}
{tagDropdownOpen}
{toggleDropdown}
{addTag}
{removeTag}
{addBrand}
{removeBrand}
{addVariant}
{removeVariant}
{getTagObj}
{compactMode}
{setCompactMode}
{collection}
{setCollection}
{collections}
/>
<style>
</style>

View File

@@ -121,6 +121,12 @@
},
};
}
// Capitalize first letter of a string
function capitalizeFirst(str) {
if (!str) return "";
return str.charAt(0).toUpperCase() + str.slice(1);
}
</script>
<div
@@ -174,6 +180,15 @@
{/if}
<p><strong>Format:</strong> <span>{logo.format}</span></p>
<p><strong>Path:</strong> {logo.path}</p>
{#if logo.meta}
<div class="logo-meta">
{#each Object.entries(logo.meta) as [key, value]}
<p>
<strong>{capitalizeFirst(key)}:</strong> <span>{value}</span>
</p>
{/each}
</div>
{/if}
{#if logo.tags && logo.tags.length}
<div class="logo-tags">
{#each logo.tags as tagObj}
@@ -186,11 +201,11 @@
</div>
{/if}
{#if logo.variants && logo.variants.length}
<div class="variants-list">
{#each logo.variants as variant}
<span class="logo-variant">{variant}</span>
{/each}
</div>
<div class="variants-list">
{#each logo.variants as variant}
<span class="logo-variant">{variant}</span>
{/each}
</div>
{/if}
</div>
@@ -295,7 +310,7 @@
border-radius: 12px;
padding: 1.5rem;
box-shadow: 0 2px 16px 4px rgba(0, 0, 0, 0.18);
overflow-y: auto;
overflow-y: scroll;
}
.logo-tags {
display: flex;