From 0313d091fc11c65294c2002294f312a4f4fda9af Mon Sep 17 00:00:00 2001 From: sHa Date: Thu, 1 May 2025 01:51:14 +0300 Subject: [PATCH 1/2] Add new logos --- public/data/logos.json | 38 +++++++++++++++++++++++-------- public/logos/dalnoboy-service.svg | 2 +- public/logos/okko.svg | 7 ++++++ public/logos/wog.svg | 12 ++++++++++ 4 files changed, 49 insertions(+), 10 deletions(-) create mode 100644 public/logos/okko.svg create mode 100644 public/logos/wog.svg diff --git a/public/data/logos.json b/public/data/logos.json index cdfefa0..e4f450e 100644 --- a/public/data/logos.json +++ b/public/data/logos.json @@ -28,10 +28,7 @@ "disable": false, "brand": "Apple", "tags": [ - { - "text": "tech", - "color": "silver" - } + "tech" ], "colors": [ { @@ -74,7 +71,13 @@ "transport", "garage" ], - "brand": "Dalnoboy Service" + "brand": "Dalnoboy Service", + "colors": [ + { + "label": "Orange", + "value": "#ee7800" + } + ] }, { "name": "Disney", @@ -130,10 +133,7 @@ "disable": false, "brand": "Google", "tags": [ - { - "text": "tech", - "color": "silver" - } + "tech" ] }, { @@ -367,6 +367,16 @@ "tags": [], "brand": "Nvidia" }, + { + "name": "Okko", + "path": "logos/okko.svg", + "format": "SVG", + "disable": false, + "tags": [ + "fuel" + ], + "brand": "Okko" + }, { "name": "Privat24", "path": "logos/privat24.svg", @@ -581,5 +591,15 @@ "finance", "transfer" ] + }, + { + "name": "WOG", + "path": "logos/wog.svg", + "format": "SVG", + "disable": false, + "tags": [ + "fuel" + ], + "brand": "WOG" } ] \ No newline at end of file diff --git a/public/logos/dalnoboy-service.svg b/public/logos/dalnoboy-service.svg index 8b18adf..568574d 100644 --- a/public/logos/dalnoboy-service.svg +++ b/public/logos/dalnoboy-service.svg @@ -1,5 +1,5 @@ + fill="currentColor" /> diff --git a/public/logos/okko.svg b/public/logos/okko.svg new file mode 100644 index 0000000..05712cb --- /dev/null +++ b/public/logos/okko.svg @@ -0,0 +1,7 @@ + + + + + + diff --git a/public/logos/wog.svg b/public/logos/wog.svg new file mode 100644 index 0000000..65361e3 --- /dev/null +++ b/public/logos/wog.svg @@ -0,0 +1,12 @@ + From c62d453946cefdc35ebd898b8d1b17a30b645089 Mon Sep 17 00:00:00 2001 From: sHa Date: Thu, 1 May 2025 11:57:23 +0300 Subject: [PATCH 2/2] Refactor logo management components: remove LogoModal, add Actions and Grid components, enhance List and Preview components with improved theme handling and SVG support. --- src/App.svelte | 8 ++-- .../{LogoActions.svelte => Actions.svelte} | 0 .../{LogoGrid.svelte => Grid.svelte} | 8 ++-- src/components/InlineSvg.svelte | 41 ++++++++++--------- .../{LogoList.svelte => List.svelte} | 21 +++++----- .../{LogoModal.svelte => Preview.svelte} | 0 6 files changed, 40 insertions(+), 38 deletions(-) rename src/components/{LogoActions.svelte => Actions.svelte} (100%) rename src/components/{LogoGrid.svelte => Grid.svelte} (96%) rename src/components/{LogoList.svelte => List.svelte} (91%) rename src/components/{LogoModal.svelte => Preview.svelte} (100%) diff --git a/src/App.svelte b/src/App.svelte index 643b308..9db057a 100644 --- a/src/App.svelte +++ b/src/App.svelte @@ -1,7 +1,7 @@ - +
{#each logos as logo} @@ -115,7 +115,7 @@ $: getLogoThemeColor = logo => getDefaultLogoColor(logo.colors, theme); {/if}
- +
diff --git a/src/components/InlineSvg.svelte b/src/components/InlineSvg.svelte index 73b5428..1f77c23 100644 --- a/src/components/InlineSvg.svelte +++ b/src/components/InlineSvg.svelte @@ -1,11 +1,11 @@ - +
{#each logos as logo} @@ -77,13 +77,12 @@ on:keydown={(e) => (e.key === 'Enter' || e.key === ' ') && openPreview(logo)} style="cursor:pointer;" > - {#if isSvgLogo(logo)} - + {#if isSvgLogo(logo)} {:else} {logo.name} {/if} @@ -125,7 +124,7 @@ {/if}
- +
{:else} diff --git a/src/components/LogoModal.svelte b/src/components/Preview.svelte similarity index 100% rename from src/components/LogoModal.svelte rename to src/components/Preview.svelte