From 2ad97b5e3f8c9faead5fca78f62b507f4697691c Mon Sep 17 00:00:00 2001 From: xiaoxia Date: Thu, 30 Jul 2026 09:06:09 +0800 Subject: [PATCH] =?UTF-8?q?refactor(StickerPanel):=20=E6=8F=90=E5=8F=96?= =?UTF-8?q?=E5=B8=B8=E9=87=8F=E5=92=8C=E5=B7=A5=E5=85=B7=E5=87=BD=E6=95=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/StickerPanel/constants.ts | 65 +++++++++++++++++++ 1 file changed, 65 insertions(+) create mode 100644 apps/web/src/pages/editing-planner/components/StickerPanel/constants.ts diff --git a/apps/web/src/pages/editing-planner/components/StickerPanel/constants.ts b/apps/web/src/pages/editing-planner/components/StickerPanel/constants.ts new file mode 100644 index 000000000..97b8967e8 --- /dev/null +++ b/apps/web/src/pages/editing-planner/components/StickerPanel/constants.ts @@ -0,0 +1,65 @@ +import type { TextStickerPreset } from "../types" + +export const EMOJI_LIST = [ + "😀", + "😂", + "🥰", + "😎", + "🤔", + "😴", + "🥳", + "😭", + "👍", + "👎", + "👏", + "🙏", + "💪", + "🎉", + "❤️", + "💔", + "🔥", + "⭐", + "💯", + "✅", + "❌", + "⚠️", + "📌", + "🎯", + "🏆", + "💰", + "📢", + "💡", + "🎨", + "🎵", + "📷", + "🎬", +] + +export const TEXT_PRESET_STYLES: Record = { + title_bold: { + fontSize: 32, + fontWeight: 700, + color: "#ffffff", + textShadow: "0 2px 8px rgba(0,0,0,0.5)", + }, + subtitle: { + fontSize: 20, + fontWeight: 500, + color: "#ffffff", + textShadow: "0 1px 4px rgba(0,0,0,0.5)", + }, + caption: { + fontSize: 14, + fontWeight: 400, + color: "#ffffff", + textShadow: "0 1px 3px rgba(0,0,0,0.5)", + }, + highlight: { + fontSize: 24, + fontWeight: 700, + color: "#ffd700", + textShadow: "0 2px 6px rgba(0,0,0,0.5)", + }, +} + +export const genStickerId = () => `sticker_${Date.now()}_${Math.random().toString(36).slice(2, 8)}`