mirror of
https://github.com/blitzkit/blitzkit.git
synced 2026-10-23 11:39:50 +02:00
update embed and fix varuna bug
This commit is contained in:
1 parent
d2041d0ee6
commit
645cfacecb
8 files changed
+81
-69
No files matched your search
+20
-20
@@ -8,32 +8,32 @@ import {
|
||||
} from "@radix-ui/react-icons";
|
||||
import { Box, Button, Flex, Heading, ScrollArea, Text } from "@radix-ui/themes";
|
||||
import { useEffect, useRef, useState, type ReactNode } from "react";
|
||||
import { CopyButton } from "../../../../components/CopyButton";
|
||||
import { Boolean } from "../../../../components/Embeds/Boolean";
|
||||
import { Color } from "../../../../components/Embeds/Color";
|
||||
import { Enum } from "../../../../components/Embeds/Enum";
|
||||
import { GenerateURL } from "../../../../components/Embeds/GenerateURL";
|
||||
import { Import } from "../../../../components/Embeds/Import";
|
||||
import { PreviewWrapper } from "../../../../components/Embeds/PreviewWrapper";
|
||||
import { Radius } from "../../../../components/Embeds/Radius";
|
||||
import { RichText } from "../../../../components/Embeds/RichText";
|
||||
import { Size } from "../../../../components/Embeds/Size";
|
||||
import { SizeWithout0 } from "../../../../components/Embeds/SizeWithout0";
|
||||
import { Slider } from "../../../../components/Embeds/Slider";
|
||||
import { TextController } from "../../../../components/Embeds/TextController";
|
||||
import { PageWrapper } from "../../../../components/PageWrapper";
|
||||
import { CopyButton } from "../../../../../components/CopyButton";
|
||||
import { Boolean } from "../../../../../components/Embeds/Boolean";
|
||||
import { Color } from "../../../../../components/Embeds/Color";
|
||||
import { Enum } from "../../../../../components/Embeds/Enum";
|
||||
import { GenerateURL } from "../../../../../components/Embeds/GenerateURL";
|
||||
import { Import } from "../../../../../components/Embeds/Import";
|
||||
import { PreviewWrapper } from "../../../../../components/Embeds/PreviewWrapper";
|
||||
import { Radius } from "../../../../../components/Embeds/Radius";
|
||||
import { RichText } from "../../../../../components/Embeds/RichText";
|
||||
import { Size } from "../../../../../components/Embeds/Size";
|
||||
import { SizeWithout0 } from "../../../../../components/Embeds/SizeWithout0";
|
||||
import { Slider } from "../../../../../components/Embeds/Slider";
|
||||
import { TextController } from "../../../../../components/Embeds/TextController";
|
||||
import { PageWrapper } from "../../../../../components/PageWrapper";
|
||||
import {
|
||||
embedConfigurations,
|
||||
extractEmbedConfigDefaults,
|
||||
} from "../../../../constants/embeds";
|
||||
import { NAVBAR_HEIGHT } from "../../../../constants/navbar";
|
||||
} from "../../../../../constants/embeds";
|
||||
import { NAVBAR_HEIGHT } from "../../../../../constants/navbar";
|
||||
import {
|
||||
LocaleProvider,
|
||||
useLocale,
|
||||
type LocaleAcceptorProps,
|
||||
} from "../../../../hooks/useLocale";
|
||||
import { EmbedState, type EmbedConfig } from "../../../../stores/embedState";
|
||||
import { EmbedItemType } from "../../../../stores/embedState/constants";
|
||||
} from "../../../../../hooks/useLocale";
|
||||
import { EmbedState, type EmbedConfig } from "../../../../../stores/embedState";
|
||||
import { EmbedItemType } from "../../../../../stores/embedState/constants";
|
||||
|
||||
export interface EmbedPreviewControllerProps {
|
||||
configKey: string;
|
||||
@@ -58,7 +58,7 @@ export function Page({ embed, locale }: PageProps & LocaleAcceptorProps) {
|
||||
function Content({ embed }: PageProps) {
|
||||
const config = embedConfigurations[embed] as EmbedConfig;
|
||||
const [backgroundImage, setBackgroundImage] = useState(
|
||||
"/assets/images/backgrounds/embed-default.webp"
|
||||
"/assets/images/backgrounds/embed-default.webp",
|
||||
);
|
||||
const fileInput = useRef<HTMLInputElement>(null!);
|
||||
const { strings } = useLocale();
|
||||
|
||||
@@ -2,8 +2,8 @@
|
||||
import { AstroSeo } from "@astrolib/seo";
|
||||
import type { GetStaticPaths } from "astro";
|
||||
import { capitalize } from "lodash-es";
|
||||
import { embedConfigurations } from "../../../../constants/embeds";
|
||||
import BaseLayout from "../../../../layouts/BaseLayout.astro";
|
||||
import { embedConfigurations } from "../../../../../constants/embeds";
|
||||
import BaseLayout from "../../../../../layouts/BaseLayout.astro";
|
||||
import { getStaticPaths as parentGetStaticPaths } from "../index.astro";
|
||||
import { Page } from "./_index";
|
||||
|
||||
@@ -17,7 +17,7 @@ export const getStaticPaths = (() => {
|
||||
...parent.params,
|
||||
embed: embed as keyof typeof embedConfigurations,
|
||||
},
|
||||
}))
|
||||
})),
|
||||
)
|
||||
.flat();
|
||||
}) satisfies GetStaticPaths;
|
||||
|
||||
@@ -1,14 +1,14 @@
|
||||
import { Box, Flex, Link, Text } from "@radix-ui/themes";
|
||||
import { PreviewWrapper } from "../../../components/Embeds/PreviewWrapper";
|
||||
import { LinkI18n } from "../../../components/LinkI18n";
|
||||
import { PageWrapper } from "../../../components/PageWrapper";
|
||||
import { embedConfigurations } from "../../../constants/embeds";
|
||||
import { Var } from "../../../core/radix/var";
|
||||
import { PreviewWrapper } from "../../../../components/Embeds/PreviewWrapper";
|
||||
import { LinkI18n } from "../../../../components/LinkI18n";
|
||||
import { PageWrapper } from "../../../../components/PageWrapper";
|
||||
import { embedConfigurations } from "../../../../constants/embeds";
|
||||
import { Var } from "../../../../core/radix/var";
|
||||
import {
|
||||
type LocaleAcceptorProps,
|
||||
LocaleProvider,
|
||||
useLocale,
|
||||
} from "../../../hooks/useLocale";
|
||||
} from "../../../../hooks/useLocale";
|
||||
|
||||
export function Page({ locale }: LocaleAcceptorProps) {
|
||||
return (
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
---
|
||||
import { tools } from "../../../constants/tools";
|
||||
import ToolLayout from "../../../layouts/ToolLayout.astro";
|
||||
import { tools } from "../../../../constants/tools";
|
||||
import ToolLayout from "../../../../layouts/ToolLayout.astro";
|
||||
import { Page } from "./_index";
|
||||
|
||||
export { getStaticPaths } from "../index.astro";
|
||||
|
||||
Reference in new issue
Block a user