From 9d1cdccf28a96c5f6b7462a8967488fab2661409 Mon Sep 17 00:00:00 2001 From: Scott Motte Date: Mon, 13 Jan 2025 09:56:40 -0800 Subject: [PATCH 1/9] =?UTF-8?q?add=20`dotenvx`=20=E2=AC=9B=EF=B8=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/data/svgs.ts | 6 ++++++ src/types/categories.ts | 3 ++- static/library/dotenvx.svg | 1 + 3 files changed, 9 insertions(+), 1 deletion(-) create mode 100644 static/library/dotenvx.svg diff --git a/src/data/svgs.ts b/src/data/svgs.ts index a19ec67..c513b88 100644 --- a/src/data/svgs.ts +++ b/src/data/svgs.ts @@ -3199,5 +3199,11 @@ export const svgs: iSVG[] = [ category: ['Config', 'Library', 'Devtool'], route: '/library/dotenv.svg', url: 'https://github.com/motdotla/dotenv' + }, + { + title: 'dotenvx', + category: ['Secrets', 'Config', 'Devtool'], + route: '/library/dotenvx.svg', + url: 'https://dotenvx.com' } ]; diff --git a/src/types/categories.ts b/src/types/categories.ts index 257cc57..3a92a49 100644 --- a/src/types/categories.ts +++ b/src/types/categories.ts @@ -29,4 +29,5 @@ export type tCategory = | 'Authentication' | 'IoT' | 'Home Automation' - | 'Config'; + | 'Config' + | 'Secrets'; diff --git a/static/library/dotenvx.svg b/static/library/dotenvx.svg new file mode 100644 index 0000000..390d470 --- /dev/null +++ b/static/library/dotenvx.svg @@ -0,0 +1 @@ +dotenvx From 225f97783bc3cfc56d02e8c13f9a9fa87c140aa8 Mon Sep 17 00:00:00 2001 From: Scott Motte Date: Mon, 13 Jan 2025 13:49:34 -0800 Subject: [PATCH 2/9] retrigger ci From 3b2dc0b79dbed64cf2c49a8e6e09e548cd885b27 Mon Sep 17 00:00:00 2001 From: pheralb Date: Wed, 15 Jan 2025 11:40:10 +0000 Subject: [PATCH 3/9] =?UTF-8?q?=E2=9C=8D=EF=B8=8F=20Update=20warning=20mes?= =?UTF-8?q?sage=20+=20add=20message=20to=20copy=20svg=20component?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/copySvg.svelte | 8 ++++++++ src/components/warning.svelte | 12 ++++++------ src/ui/popover/popover-content.svelte | 2 +- 3 files changed, 15 insertions(+), 7 deletions(-) diff --git a/src/components/copySvg.svelte b/src/components/copySvg.svelte index 4f3ecaa..526319d 100644 --- a/src/components/copySvg.svelte +++ b/src/components/copySvg.svelte @@ -309,5 +309,13 @@ +
+

+ Remember to request permission from the creators for the use of the SVG. Modification is not + allowed. +

+
diff --git a/src/components/warning.svelte b/src/components/warning.svelte index 8a7b9a3..dd3e224 100644 --- a/src/components/warning.svelte +++ b/src/components/warning.svelte @@ -5,28 +5,28 @@ import { cn } from '@/utils/cn'; let warning = false; - let warningName = 'svgl_warning_message'; + let warningName = 'svgl_warn_message'; const initialValue = browser ? window.localStorage.getItem(warningName) : true; {#if !warning && !initialValue}

All SVGs include links to the respective products or companies that own them. Please contact the owner directly if you intend to use their logo.Please contact the owner directly if you need to use their logo. - If you are the owner of an SVG and prefer it not to be displayed here, + If you are the owner of an SVG and would like it removed, create an issue on GitHub.

diff --git a/src/ui/popover/popover-content.svelte b/src/ui/popover/popover-content.svelte index d6e3f76..796ce56 100644 --- a/src/ui/popover/popover-content.svelte +++ b/src/ui/popover/popover-content.svelte @@ -21,7 +21,7 @@ {sideOffset} {...$$restProps} class={cn( - 'z-50 w-auto rounded-md border border-neutral-200 bg-white p-3 shadow-md outline-none dark:border-neutral-800 dark:bg-neutral-900', + 'z-50 w-auto max-w-96 rounded-md border border-neutral-200 bg-white p-3 shadow-md outline-none dark:border-neutral-800 dark:bg-neutral-900', className )} > From a043abcefd0120e5f0aeee87a8e364dad291806a Mon Sep 17 00:00:00 2001 From: pheralb Date: Wed, 15 Jan 2025 11:54:53 +0000 Subject: [PATCH 4/9] =?UTF-8?q?=F0=9F=93=9D=20Add=20brand=20guidelines=20s?= =?UTF-8?q?ection=20+=20fixed=20``Request=20Logo``=20url?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 7485fdb..3dd28ed 100644 --- a/README.md +++ b/README.md @@ -10,7 +10,7 @@ Discover  ✦  - + Request logo  ✦  @@ -138,6 +138,19 @@ pnpm install } ``` +- **Add brand guidelines**: + +```json +{ + "title": "Title", + "category": "Category", + "route": "/library/your_logo.svg", + "wordmark": "/library/your_logo_wordmark.svg", + "brandUrl": "https://assets.website.com/brand-guidelines", + "url": "Website" +} +``` + > [!NOTE] > > - The list of categories is here: [`src/types/categories.ts`](https://github.com/pheralb/svgl/blob/main/src/types/categories.ts). You can add a new category if you need it. From d6a333c3160dd2c0157d3797bb7a76e16506435a Mon Sep 17 00:00:00 2001 From: pheralb Date: Wed, 15 Jan 2025 11:55:10 +0000 Subject: [PATCH 5/9] =?UTF-8?q?=F0=9F=93=9D=20Create=20custom=20pull=20req?= =?UTF-8?q?uest=20template?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/PULL_REQUEST_TEMPLATE.md | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 .github/PULL_REQUEST_TEMPLATE.md diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md new file mode 100644 index 0000000..21ec51d --- /dev/null +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -0,0 +1,16 @@ +## 📝 About your SVG: + +- **Title**: +- **Category**: +- **Website URL**: +- **Description**: + +## 📷 Screenshots: + +✨ Add screenshots of the logo. + +## ✅ Checklist + +- [ ] I have permission to use this logo. +- [ ] The .svg URL I have provided is optimized for web use. +- [ ] The .svg size is less than **20kb**. From 4bceb2137c40e33fc5c6d782eabfdd3381399fd5 Mon Sep 17 00:00:00 2001 From: pheralb Date: Wed, 15 Jan 2025 11:56:00 +0000 Subject: [PATCH 6/9] =?UTF-8?q?=E2=9C=A8=20Add=20support=20for=20product?= =?UTF-8?q?=20brand=20guidelines?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/svgCard.svelte | 24 +++++++++++++++++++----- src/data/svgs.ts | 1 + src/types/svg.ts | 1 + 3 files changed, 21 insertions(+), 5 deletions(-) diff --git a/src/components/svgCard.svelte b/src/components/svgCard.svelte index 078370b..09cc8ab 100644 --- a/src/components/svgCard.svelte +++ b/src/components/svgCard.svelte @@ -13,7 +13,8 @@ Sparkles, EllipsisIcon, TagIcon, - XIcon + XIcon, + PaletteIcon } from 'lucide-svelte'; // Components & styles: @@ -57,8 +58,10 @@ let maxVisibleCategories = 1; let moreTagsOptions = false; - // Global Images Styles: + // Global Styles: const globalImageStyles = 'mb-4 mt-2 h-10 select-none pointer-events-none'; + const btnStyles = + 'flex items-center space-x-2 rounded-md p-2 duration-100 hover:bg-neutral-200 dark:hover:bg-neutral-700/40';
@@ -200,7 +203,7 @@ title="Website" target="_blank" rel="noopener noreferrer" - class="flex items-center space-x-2 rounded-md p-2 duration-100 hover:bg-neutral-200 dark:hover:bg-neutral-700/40" + class={btnStyles} > @@ -210,7 +213,7 @@ on:click={() => { wordmarkSvg = !wordmarkSvg; }} - class="flex items-center space-x-2 rounded-md p-2 duration-100 hover:bg-neutral-200 dark:hover:bg-neutral-700/40" + class={btnStyles} > {#if wordmarkSvg} @@ -219,5 +222,16 @@ {/if} {/if} + {#if svgInfo.brandUrl !== undefined} + + + + {/if}
diff --git a/src/data/svgs.ts b/src/data/svgs.ts index c513b88..94389b9 100644 --- a/src/data/svgs.ts +++ b/src/data/svgs.ts @@ -2667,6 +2667,7 @@ export const svgs: iSVG[] = [ light: '/library/vercel_wordmark.svg', dark: '/library/vercel_wordmark_dark.svg' }, + brandUrl: 'https://vercel.com/geist/brands', url: 'https://vercel.com/' }, { diff --git a/src/types/svg.ts b/src/types/svg.ts index 6d568e3..6402e5b 100644 --- a/src/types/svg.ts +++ b/src/types/svg.ts @@ -11,5 +11,6 @@ export interface iSVG { category: tCategory | tCategory[]; route: string | ThemeOptions; wordmark?: string | ThemeOptions; + brandUrl?: string; url: string; } From b29dfd8332f002c096c7b82d5401c4fd52c03e8d Mon Sep 17 00:00:00 2001 From: pheralb Date: Wed, 15 Jan 2025 16:05:41 +0000 Subject: [PATCH 7/9] =?UTF-8?q?=F0=9F=8E=A8=20New=20light/dark=20theme=20f?= =?UTF-8?q?or=20Shiki?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/app.css | 9 +++++++++ svelte.config.js | 12 ++++++++++-- 2 files changed, 19 insertions(+), 2 deletions(-) diff --git a/src/app.css b/src/app.css index f85c976..0f54e63 100644 --- a/src/app.css +++ b/src/app.css @@ -72,3 +72,12 @@ src: url('/fonts/GeistMonoVariableVF.woff2') format('woff2'); font-display: swap; } + +html.dark .shiki, +html.dark .shiki span { + color: var(--shiki-dark) !important; + background-color: transparent !important; + font-style: var(--shiki-dark-font-style) !important; + font-weight: var(--shiki-dark-font-weight) !important; + text-decoration: var(--shiki-dark-text-decoration) !important; +} diff --git a/svelte.config.js b/svelte.config.js index aaa6f5c..4d22dda 100644 --- a/svelte.config.js +++ b/svelte.config.js @@ -36,11 +36,19 @@ const mdsvexOptions = { highlight: { highlighter: async (code, lang = 'text') => { const highlighter = await getHighlighter({ - themes: ['vesper'], + themes: ['github-light', 'github-dark'], langs: ['javascript', 'typescript', 'bash', 'json'] }); await highlighter.loadLanguage('javascript', 'typescript', 'bash'); - const html = escapeSvelte(highlighter.codeToHtml(code, { lang, theme: 'vesper' })); + const html = escapeSvelte( + highlighter.codeToHtml(code, { + lang, + themes: { + light: 'github-light', + dark: 'github-dark' + } + }) + ); return `{@html \`${html}\` }`; } } From a03589d795560745bf675d0adbecbbd783b33631 Mon Sep 17 00:00:00 2001 From: pheralb Date: Wed, 15 Jan 2025 16:05:54 +0000 Subject: [PATCH 8/9] =?UTF-8?q?=E2=9A=99=EF=B8=8F=20Upgrade=20API=20types?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/docs/api.md | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/docs/api.md b/src/docs/api.md index 76dc803..fd8e41f 100644 --- a/src/docs/api.md +++ b/src/docs/api.md @@ -39,17 +39,18 @@ export interface Category { - For SVGs: ```ts -type ThemeOptions = { - light: string; +export type ThemeOptions = { dark: string; + light: string; }; export interface iSVG { - id: number; + id?: number; title: string; - category: string | string[]; + category: tCategory | tCategory[]; route: string | ThemeOptions; wordmark?: string | ThemeOptions; + brandUrl?: string; url: string; } ``` From ba51ec699bfc98e18930cd8384ba8661c93210b2 Mon Sep 17 00:00:00 2001 From: pheralb Date: Wed, 15 Jan 2025 16:06:08 +0000 Subject: [PATCH 9/9] =?UTF-8?q?=F0=9F=8E=A8=20Update=20codeblocks?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/routes/api/+page.svelte | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/routes/api/+page.svelte b/src/routes/api/+page.svelte index b6d4ae5..323430c 100644 --- a/src/routes/api/+page.svelte +++ b/src/routes/api/+page.svelte @@ -42,7 +42,7 @@ 'prose dark:prose-invert', 'mx-auto max-w-3xl px-4 py-10', 'prose-h2:font-medium prose-h2:tracking-tight prose-h2:underline prose-h2:decoration-neutral-300 prose-h2:underline-offset-[6px] prose-h2:transition-opacity hover:prose-h2:opacity-70 dark:prose-h2:decoration-neutral-700/65', - 'prose-pre:m-0 prose-pre:border-neutral-200 dark:prose-pre:border dark:prose-pre:border-neutral-800/65' + 'prose-pre:m-0 prose-pre:border prose-pre:border-neutral-200 dark:prose-pre:border dark:prose-pre:border-neutral-800/65' )} >