mirror of
https://github.com/pheralb/svgl.git
synced 2025-12-29 08:01:36 +08:00
Merge branch 'main' into main
This commit is contained in:
@@ -28,6 +28,7 @@
|
||||
|
||||
// Props:
|
||||
export let svgInfo: iSVG;
|
||||
export let searchTerm: string;
|
||||
|
||||
let isInFigma = false;
|
||||
onMount(() => {
|
||||
@@ -37,6 +38,11 @@
|
||||
|
||||
// Wordmark SVG:
|
||||
let wordmarkSvg = false;
|
||||
$: {
|
||||
if (searchTerm) {
|
||||
wordmarkSvg = false;
|
||||
}
|
||||
}
|
||||
|
||||
const insertSVG = async (url?: string) => {
|
||||
const content = (await getSvgContent(url)) as string;
|
||||
@@ -59,7 +65,7 @@
|
||||
class="group flex flex-col items-center justify-center rounded-md border border-neutral-200 p-4 transition-colors duration-100 hover:bg-neutral-100/80 dark:border-neutral-800 dark:hover:bg-neutral-800/20"
|
||||
>
|
||||
<!-- Image -->
|
||||
{#if wordmarkSvg == true}
|
||||
{#if wordmarkSvg == true && svgInfo.wordmark !== undefined}
|
||||
<img
|
||||
class={cn('hidden dark:block', globalImageStyles)}
|
||||
src={typeof svgInfo.wordmark !== 'string'
|
||||
@@ -175,7 +181,7 @@
|
||||
</button>
|
||||
{/if}
|
||||
|
||||
{#if wordmarkSvg}
|
||||
{#if wordmarkSvg && svgInfo.wordmark !== undefined}
|
||||
<CopySvg {iconSize} {iconStroke} {svgInfo} isInFigma={false} isWordmarkSvg={true} />
|
||||
{:else}
|
||||
<CopySvg {iconSize} {iconStroke} {svgInfo} isInFigma={false} isWordmarkSvg={false} />
|
||||
|
||||
+44
-18
@@ -2220,6 +2220,16 @@ export const svgs: iSVG[] = [
|
||||
},
|
||||
url: 'https://raycast.com/'
|
||||
},
|
||||
{
|
||||
title: 'Hack The Box',
|
||||
category: 'Cybersecurity',
|
||||
route: '/library/hack-the-box.svg',
|
||||
wordmark: {
|
||||
light: '/library/hack-the-box-wordmark-light.svg',
|
||||
dark: '/library/hack-the-box-wordmark-dark.svg'
|
||||
},
|
||||
url: 'https://www.hackthebox.com/'
|
||||
},
|
||||
{
|
||||
title: 'Procure',
|
||||
category: 'Marketplace',
|
||||
@@ -2262,12 +2272,6 @@ export const svgs: iSVG[] = [
|
||||
route: '/library/sourcegraph.svg',
|
||||
url: 'https://about.sourcegraph.com/'
|
||||
},
|
||||
{
|
||||
title: 'Claude AI',
|
||||
category: 'AI',
|
||||
route: '/library/claude-ai.svg',
|
||||
url: 'https://claude.ai/'
|
||||
},
|
||||
{
|
||||
title: 'Perplexity AI',
|
||||
category: 'AI',
|
||||
@@ -2952,16 +2956,6 @@ export const svgs: iSVG[] = [
|
||||
route: '/library/manzdev.svg',
|
||||
url: 'https://manz.dev/'
|
||||
},
|
||||
{
|
||||
title: 'MediaWiki',
|
||||
category: ['Software', 'CMS'],
|
||||
"route": "/library/mediawiki.svg",
|
||||
"wordmark": {
|
||||
"light": "/library/mediawiki-wordmark-light.svg",
|
||||
"dark": "/library/mediawiki-wordmark-dark.svg"
|
||||
},
|
||||
"url": "https://www.mediawiki.org/"
|
||||
},
|
||||
{
|
||||
title: 'Afordin',
|
||||
category: ['Community'],
|
||||
@@ -2969,6 +2963,38 @@ export const svgs: iSVG[] = [
|
||||
light: '/library/afordin-light.svg',
|
||||
dark: '/library/afordin-dark.svg'
|
||||
},
|
||||
url: 'https://github.com/Afordin'
|
||||
}
|
||||
url: 'https://github.com/Afordin'
|
||||
},
|
||||
{
|
||||
title: 'MediaWiki',
|
||||
category: ['Software', 'CMS'],
|
||||
route: '/library/mediawiki.svg',
|
||||
wordmark: {
|
||||
light: '/library/mediawiki-wordmark-light.svg',
|
||||
dark: '/library/mediawiki-wordmark-dark.svg'
|
||||
},
|
||||
url: "https://www.mediawiki.org/"
|
||||
},
|
||||
{
|
||||
title: 'Carrd',
|
||||
category: ['Social'],
|
||||
route: '/library/carrd.svg',
|
||||
url: 'https://carrd.co/'
|
||||
},
|
||||
{
|
||||
title: 'Claude AI',
|
||||
category: 'AI',
|
||||
route: '/library/claude-ai-icon.svg',
|
||||
wordmark: {
|
||||
light: '/library/claude-ai-wordmark-icon_light.svg',
|
||||
dark: '/library/claude-ai-wordmark-icon_dark.svg'
|
||||
},
|
||||
url: 'https://claude.ai/'
|
||||
},
|
||||
{
|
||||
title: 'UnoCSS',
|
||||
category: 'Devtool',
|
||||
route: '/library/unocss.svg',
|
||||
url: 'https://unocss.dev/'
|
||||
}
|
||||
];
|
||||
|
||||
@@ -134,7 +134,7 @@
|
||||
</div>
|
||||
<Grid>
|
||||
{#each filteredSvgs.slice(0, showAll ? undefined : 30) as svg}
|
||||
<SvgCard svgInfo={svg} />
|
||||
<SvgCard svgInfo={svg} searchTerm={searchTerm} />
|
||||
{/each}
|
||||
</Grid>
|
||||
{#if filteredSvgs.length > 30 && !showAll}
|
||||
|
||||
@@ -12,6 +12,7 @@ export type tCategory =
|
||||
| 'Database'
|
||||
| 'Compiler'
|
||||
| 'Crypto'
|
||||
| 'Cybersecurity'
|
||||
| 'Social'
|
||||
| 'Entertainment'
|
||||
| 'Browser'
|
||||
|
||||
Reference in New Issue
Block a user