mirror of
https://github.com/BradNut/personal-website-sveltekit
synced 2025-09-08 23:20:18 +00:00
Fixing most svelte check issues.
This commit is contained in:
parent
9a1b2ed293
commit
d18f6b0a9f
8 changed files with 17 additions and 24 deletions
|
|
@ -35,7 +35,7 @@
|
||||||
{textData?.text}
|
{textData?.text}
|
||||||
{/if}
|
{/if}
|
||||||
{#if textData?.showIcon}
|
{#if textData?.showIcon}
|
||||||
{@render linkIcon?.(iconData ?? {})}
|
{@render linkIcon(iconData ?? {})}
|
||||||
{/if}
|
{/if}
|
||||||
{#if textData?.location === "bottom" || (textData?.location === "right" && textData?.text)}
|
{#if textData?.location === "bottom" || (textData?.location === "right" && textData?.text)}
|
||||||
{textData?.text}
|
{textData?.text}
|
||||||
|
|
@ -44,7 +44,7 @@
|
||||||
{/snippet}
|
{/snippet}
|
||||||
|
|
||||||
{#snippet linkIcon({ type, icon, iconClass }: LinkIconType)}
|
{#snippet linkIcon({ type, icon, iconClass }: LinkIconType)}
|
||||||
{#if type === "svg" && icon}
|
{#if type === "svg" && icon && typeof icon === 'function' && icon.length !== undefined}
|
||||||
<svg
|
<svg
|
||||||
style="width: 2.5rem; height: 2.5rem;"
|
style="width: 2.5rem; height: 2.5rem;"
|
||||||
class={iconClass ?? ""}
|
class={iconClass ?? ""}
|
||||||
|
|
@ -52,7 +52,7 @@
|
||||||
viewBox="0 0 24 24"
|
viewBox="0 0 24 24"
|
||||||
xmlns="http://www.w3.org/2000/svg"
|
xmlns="http://www.w3.org/2000/svg"
|
||||||
>
|
>
|
||||||
{@render icon?.()}
|
{@render (icon as any)()}
|
||||||
</svg>
|
</svg>
|
||||||
{:else if type === "icon" && icon}
|
{:else if type === "icon" && icon}
|
||||||
{@const Icon = icon}
|
{@const Icon = icon}
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
<script lang="ts">
|
<script lang="ts">
|
||||||
import type { Snippet } from 'svelte';
|
import type { Snippet } from 'svelte';
|
||||||
import type { Picture } from 'vite-imagetools';
|
import type { Picture } from 'vite-imagetools';
|
||||||
import { ExternalLinkType } from '../types/externalLinkType';
|
import type { ExternalLinkType } from '../types/externalLinkType';
|
||||||
|
|
||||||
const {
|
const {
|
||||||
links,
|
links,
|
||||||
|
|
@ -15,8 +15,8 @@ const {
|
||||||
fetchpriority = 'auto',
|
fetchpriority = 'auto',
|
||||||
loading = 'lazy',
|
loading = 'lazy',
|
||||||
}: {
|
}: {
|
||||||
links: Snippet<ExternalLinkType[]>;
|
links: Snippet<[ExternalLinkType[]]>;
|
||||||
details: Snippet<string>;
|
details: Snippet<[]>;
|
||||||
portfolioDetails: string;
|
portfolioDetails: string;
|
||||||
externalLinks: ExternalLinkType[];
|
externalLinks: ExternalLinkType[];
|
||||||
name: string;
|
name: string;
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
<script module>
|
<script module lang="ts">
|
||||||
export { blueSkyIcon, dockerIcon, drizzleIcon, honoIcon, gitHubIcon, linkedInIcon, lucideIcon, nextDotJsIcon, reactIcon, svelteIcon, typescriptIcon, xIcon };
|
export { blueSkyIcon, dockerIcon, drizzleIcon, honoIcon, gitHubIcon, linkedInIcon, lucideIcon, nextDotJsIcon, reactIcon, svelteIcon, typescriptIcon, xIcon };
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
@ -46,7 +46,7 @@
|
||||||
<path fill="currentColor" d="M18.665 21.978C16.758 23.255 14.465 24 12 24 5.377 24 0 18.623 0 12S5.377 0 12 0s12 5.377 12 12c0 3.583-1.574 6.801-4.067 9.001L9.219 7.2H7.2v9.596h1.615V9.251l9.85 12.727Zm-3.332-8.533 1.6 2.061V7.2h-1.6v6.245Z"/>
|
<path fill="currentColor" d="M18.665 21.978C16.758 23.255 14.465 24 12 24 5.377 24 0 18.623 0 12S5.377 0 12 0s12 5.377 12 12c0 3.583-1.574 6.801-4.067 9.001L9.219 7.2H7.2v9.596h1.615V9.251l9.85 12.727Zm-3.332-8.533 1.6 2.061V7.2h-1.6v6.245Z"/>
|
||||||
{/snippet}
|
{/snippet}
|
||||||
|
|
||||||
{#snippet lucideIcon(icon)}
|
{#snippet lucideIcon(icon: any)}
|
||||||
{@const Icon = icon}
|
{@const Icon = icon}
|
||||||
<Icon />
|
<Icon />
|
||||||
{/snippet}
|
{/snippet}
|
||||||
|
|
|
||||||
|
|
@ -17,11 +17,9 @@
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<ExternalLink
|
<ExternalLink
|
||||||
ariaLabel={ariaLabel}
|
linkData={{ href, ariaLabel, clazz }}
|
||||||
href={href}
|
|
||||||
linkClass={clazz}
|
|
||||||
icon={lucideIcon}
|
|
||||||
textData={textData}
|
textData={textData}
|
||||||
|
iconData={{ type: 'icon', icon }}
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<style lang="postcss">
|
<style lang="postcss">
|
||||||
|
|
|
||||||
|
|
@ -13,9 +13,8 @@ export async function GET({ url }) {
|
||||||
const page = url.searchParams.get('page') ?? undefined;
|
const page = url.searchParams.get('page') ?? undefined;
|
||||||
const content = url.searchParams.get('content') ?? '';
|
const content = url.searchParams.get('content') ?? '';
|
||||||
|
|
||||||
// @ts-expect-error: Argument of type 'typeof SocialImageCard__SvelteComponent_' is not assignable to parameter of type 'SvelteComponent<any, any, any>'
|
|
||||||
return componentToPng(
|
return componentToPng(
|
||||||
SocialImageCard,
|
SocialImageCard as any,
|
||||||
{
|
{
|
||||||
header,
|
header,
|
||||||
page,
|
page,
|
||||||
|
|
|
||||||
|
|
@ -1,13 +1,9 @@
|
||||||
<script lang="ts">
|
<script lang="ts">
|
||||||
import ExternalLink from "$lib/components/ExternalLink.svelte";
|
import ExternalLink from "$lib/components/ExternalLink.svelte";
|
||||||
import Portfolio from "./Portfolio.svelte";
|
import Portfolio from "./Portfolio.svelte";
|
||||||
// @ts-expect-error: Cannot find module '$lib/content/uses/development.md' or its corresponding type declarations.ts(2307)
|
|
||||||
// import OldWebsite from "$lib/content/portfolio/personal/old-website.md";
|
// import OldWebsite from "$lib/content/portfolio/personal/old-website.md";
|
||||||
// @ts-expect-error: Cannot find module '$lib/content/uses/development.md' or its corresponding type declarations.ts(2307)
|
|
||||||
// import PersonalWebsiteSvelteKit from "$lib/content/portfolio/personal/personal-website-sveltekit.md";
|
// import PersonalWebsiteSvelteKit from "$lib/content/portfolio/personal/personal-website-sveltekit.md";
|
||||||
// @ts-expect-error: Cannot find module '$lib/content/uses/development.md' or its corresponding type declarations.ts(2307)
|
|
||||||
// import WeddingWebsite from "$lib/content/portfolio/personal/wedding-website.md";
|
// import WeddingWebsite from "$lib/content/portfolio/personal/wedding-website.md";
|
||||||
// @ts-expect-error: Cannot find module '$lib/content/uses/development.md' or its corresponding type declarations.ts(2307)
|
|
||||||
// import MarkShellnutArchitect from "$lib/content/portfolio/professional/mark-shellnut-architect.md";
|
// import MarkShellnutArchitect from "$lib/content/portfolio/professional/mark-shellnut-architect.md";
|
||||||
import type { ExternalLinkType } from "$lib/types/externalLinkType";
|
import type { ExternalLinkType } from "$lib/types/externalLinkType";
|
||||||
import { Tabs } from "bits-ui";
|
import { Tabs } from "bits-ui";
|
||||||
|
|
|
||||||
|
|
@ -14,7 +14,7 @@
|
||||||
loading = "lazy",
|
loading = "lazy",
|
||||||
children,
|
children,
|
||||||
}: {
|
}: {
|
||||||
links: Snippet<ExternalLinkType[]>;
|
links: Snippet<[ExternalLinkType[]]>;
|
||||||
externalLinks: ExternalLinkType[];
|
externalLinks: ExternalLinkType[];
|
||||||
name: string;
|
name: string;
|
||||||
src: string | Picture;
|
src: string | Picture;
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue