Add brand information to logos and display in LogoModal component

This commit is contained in:
sHa
2025-04-30 16:17:17 +03:00
parent f3051bd3dd
commit c28037e1a7
3 changed files with 40 additions and 2 deletions

View File

@@ -3,6 +3,7 @@
"name": "Adidas", "name": "Adidas",
"path": "logos/adidas.svg", "path": "logos/adidas.svg",
"format": "SVG", "format": "SVG",
"brand": "Adidas",
"disable": false, "disable": false,
"tags": [ "tags": [
"clothing", "clothing",
@@ -30,6 +31,7 @@
"path": "logos/amazon.svg", "path": "logos/amazon.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "Amazon",
"tags": [ "tags": [
"retail" "retail"
], ],
@@ -54,6 +56,7 @@
"path": "logos/apple.svg", "path": "logos/apple.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "Apple",
"tags": [ "tags": [
{ {
"text": "tech", "text": "tech",
@@ -83,6 +86,7 @@
"path": "logos/atb.svg", "path": "logos/atb.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "ATB",
"tags": [ "tags": [
"retail" "retail"
] ]
@@ -113,6 +117,7 @@
"path": "logos/disney.svg", "path": "logos/disney.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "Disney",
"tags": [ "tags": [
"entertainment", "entertainment",
"streaming" "streaming"
@@ -138,6 +143,7 @@
"path": "logos/dodge.svg", "path": "logos/dodge.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "Dodge",
"tags": [ "tags": [
"automobile", "automobile",
"transport" "transport"
@@ -167,6 +173,7 @@
"path": "logos/google.svg", "path": "logos/google.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "Google",
"tags": [ "tags": [
{ {
"text": "tech", "text": "tech",
@@ -198,6 +205,7 @@
"path": "logos/jeep.svg", "path": "logos/jeep.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "Jeep",
"tags": [ "tags": [
"automobile", "automobile",
"transport" "transport"
@@ -227,6 +235,7 @@
"path": "logos/kyivstar.svg", "path": "logos/kyivstar.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "Kyivstar",
"tags": [ "tags": [
"telecom", "telecom",
"mobile" "mobile"
@@ -237,6 +246,7 @@
"path": "logos/lifecell.svg", "path": "logos/lifecell.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "Lifecell",
"tags": [ "tags": [
"telecom", "telecom",
"mobile" "mobile"
@@ -262,6 +272,7 @@
"path": "logos/mono_black.svg", "path": "logos/mono_black.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "Monobank",
"tags": [ "tags": [
"bank", "bank",
"finance" "finance"
@@ -272,6 +283,7 @@
"path": "logos/mono_white.svg", "path": "logos/mono_white.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "Monobank",
"tags": [ "tags": [
"bank", "bank",
"finance" "finance"
@@ -282,6 +294,7 @@
"path": "logos/mono_yellow.svg", "path": "logos/mono_yellow.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "Monobank",
"tags": [ "tags": [
"bank", "bank",
"finance" "finance"
@@ -292,6 +305,7 @@
"path": "logos/monobank_paw.svg", "path": "logos/monobank_paw.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "Monobank",
"tags": [ "tags": [
"bank", "bank",
"finance" "finance"
@@ -302,6 +316,7 @@
"path": "logos/monobank_text.svg", "path": "logos/monobank_text.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "Monobank",
"tags": [ "tags": [
"bank", "bank",
"finance" "finance"
@@ -337,6 +352,7 @@
"path": "logos/neocom.svg", "path": "logos/neocom.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "Neocom",
"tags": [ "tags": [
"telecom", "telecom",
"provider" "provider"
@@ -347,6 +363,7 @@
"path": "logos/netflix.svg", "path": "logos/netflix.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "Netflix",
"tags": [ "tags": [
"streaming", "streaming",
"entertainment" "entertainment"
@@ -376,6 +393,7 @@
"path": "logos/privat24.svg", "path": "logos/privat24.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "PrivatBank",
"tags": [ "tags": [
"bank", "bank",
"finance" "finance"
@@ -386,6 +404,7 @@
"path": "logos/privat24bussiness.svg", "path": "logos/privat24bussiness.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "PrivatBank",
"tags": [ "tags": [
"bank", "bank",
"finance" "finance"
@@ -396,6 +415,7 @@
"path": "logos/privatbank.svg", "path": "logos/privatbank.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "PrivatBank",
"tags": [ "tags": [
"bank", "bank",
"finance" "finance"
@@ -406,6 +426,7 @@
"path": "logos/privatbank_logo.svg", "path": "logos/privatbank_logo.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "PrivatBank",
"tags": [ "tags": [
"bank", "bank",
"finance" "finance"
@@ -416,6 +437,7 @@
"path": "logos/pumb.svg", "path": "logos/pumb.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "PUMB",
"tags": [ "tags": [
"bank", "bank",
"finance" "finance"
@@ -426,6 +448,7 @@
"path": "logos/reebok.svg", "path": "logos/reebok.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "Reebok",
"tags": [ "tags": [
"clothing", "clothing",
"sports", "sports",
@@ -452,6 +475,7 @@
"path": "logos/revolut.svg", "path": "logos/revolut.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "Revolut",
"tags": [ "tags": [
"bank", "bank",
"finance", "finance",
@@ -510,6 +534,7 @@
"path": "logos/sendpulse.svg", "path": "logos/sendpulse.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "Sendpulse",
"tags": [ "tags": [
"marketing", "marketing",
"email" "email"
@@ -520,6 +545,7 @@
"path": "logos/sendpulse_logo.svg", "path": "logos/sendpulse_logo.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "Sendpulse",
"tags": [ "tags": [
"marketing", "marketing",
"email" "email"
@@ -530,6 +556,7 @@
"path": "logos/shadoll.svg", "path": "logos/shadoll.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "shadoll",
"tags": [], "tags": [],
"colors": [ "colors": [
{ {
@@ -552,6 +579,7 @@
"path": "logos/shkafnik.svg", "path": "logos/shkafnik.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "Shkafnik",
"tags": [ "tags": [
"furniture" "furniture"
] ]
@@ -561,6 +589,7 @@
"path": "logos/shkafnik_logo.svg", "path": "logos/shkafnik_logo.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "Shkafnik",
"tags": [ "tags": [
"furniture" "furniture"
] ]
@@ -570,6 +599,7 @@
"path": "logos/silpo.svg", "path": "logos/silpo.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "Silpo",
"tags": [ "tags": [
"retail", "retail",
"grocery" "grocery"
@@ -580,6 +610,7 @@
"path": "logos/viber.svg", "path": "logos/viber.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "Viber",
"tags": [ "tags": [
"messaging", "messaging",
"communication" "communication"
@@ -590,6 +621,7 @@
"path": "logos/vodafone.svg", "path": "logos/vodafone.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "Vodafone",
"tags": [ "tags": [
"telecom", "telecom",
"mobile" "mobile"
@@ -600,6 +632,7 @@
"path": "logos/wise.svg", "path": "logos/wise.svg",
"format": "SVG", "format": "SVG",
"disable": false, "disable": false,
"brand": "Wise",
"tags": [ "tags": [
"finance", "finance",
"transfer" "transfer"

View File

@@ -131,7 +131,8 @@ function scanLogos() {
...existingItem, ...existingItem,
path: logoPath, path: logoPath,
format: format, format: format,
disable: typeof existingItem.disable === 'boolean' ? existingItem.disable : false disable: typeof existingItem.disable === 'boolean' ? existingItem.disable : false,
brand: existingItem.brand || existingItem.name || formatName(file)
}; };
} else { } else {
// New logo // New logo
@@ -139,7 +140,8 @@ function scanLogos() {
name: formatName(file), name: formatName(file),
path: logoPath, path: logoPath,
format: format, format: format,
disable: false disable: false,
brand: formatName(file)
}; };
} }
// Ensure tags field exists and is an array // Ensure tags field exists and is an array

View File

@@ -91,6 +91,9 @@ $: getLogoThemeColor = logo => getDefaultLogoColor(logo.colors, theme);
{/each} {/each}
</div> </div>
{/if} {/if}
{#if logo.brand}
<p><strong>Brand:</strong> <span>{logo.brand}</span></p>
{/if}
<p><strong>Format:</strong> <span>{logo.format}</span></p> <p><strong>Format:</strong> <span>{logo.format}</span></p>
<p><strong>Path:</strong> {logo.path}</p> <p><strong>Path:</strong> {logo.path}</p>
{#if logo.tags && logo.tags.length} {#if logo.tags && logo.tags.length}