From 6737f016f5c3d4ddc01a7b29ebb3b5df17138b96 Mon Sep 17 00:00:00 2001 From: Dogtiti <499960698@qq.com> Date: Fri, 26 Jul 2024 15:50:26 +0800 Subject: [PATCH] chore: artifact => artifacts --- app/api/{artifact => artifacts}/route.ts | 0 ...fact.module.scss => artifacts.module.scss} | 4 +-- .../{artifact.tsx => artifacts.tsx} | 36 ++++++++++--------- app/components/chat.tsx | 4 +-- app/components/home.tsx | 6 ++-- app/components/markdown.tsx | 6 ++-- app/constant.ts | 6 ++-- app/locales/cn.ts | 4 +-- app/locales/en.ts | 6 ++-- 9 files changed, 38 insertions(+), 34 deletions(-) rename app/api/{artifact => artifacts}/route.ts (100%) rename app/components/{artifact.module.scss => artifacts.module.scss} (93%) rename app/components/{artifact.tsx => artifacts.tsx} (87%) diff --git a/app/api/artifact/route.ts b/app/api/artifacts/route.ts similarity index 100% rename from app/api/artifact/route.ts rename to app/api/artifacts/route.ts diff --git a/app/components/artifact.module.scss b/app/components/artifacts.module.scss similarity index 93% rename from app/components/artifact.module.scss rename to app/components/artifacts.module.scss index 2909008b0..7ea572a90 100644 --- a/app/components/artifact.module.scss +++ b/app/components/artifacts.module.scss @@ -1,4 +1,4 @@ -.artifact { +.artifacts { display: flex; width: 100%; height: 100%; @@ -23,7 +23,7 @@ } } -.artifact-iframe { +.artifacts-iframe { width: 100%; border: var(--border-in-light); border-radius: 6px; diff --git a/app/components/artifact.tsx b/app/components/artifacts.tsx similarity index 87% rename from app/components/artifact.tsx rename to app/components/artifacts.tsx index 295a4230e..326891e73 100644 --- a/app/components/artifact.tsx +++ b/app/components/artifacts.tsx @@ -13,7 +13,7 @@ import { Modal, showToast } from "./ui-lib"; import { copyToClipboard, downloadAs } from "../utils"; import { Path, ApiPath, REPO_URL } from "@/app/constant"; import { Loading } from "./home"; -import styles from "./artifact.module.scss"; +import styles from "./artifacts.module.scss"; export function HTMLPreview(props: { code: string; @@ -72,7 +72,7 @@ export function HTMLPreview(props: { return (