Create professional demos and 3D mockups in seconds, directly in your browser
feat: Enhance UI components and update translations for improved user experience
CristianOlivera1460ab9a0a46a
diff --git a/app/components/ui/ExportImageDropdown.tsx b/app/components/ui/ExportImageDropdown.tsxindex 27cbf0a..1befc2a 100644--- a/app/components/ui/ExportImageDropdown.tsx+++ b/app/components/ui/ExportImageDropdown.tsx@@ -222,18 +222,14 @@ export function ExportImageDropdown({aria-pressed={isSelected}><div- className={`relative size-12 squircle-element flex items-center justify-center transition-all duration-300 border ${isSelected- ? "border-white/30 scale-105"+ className={`relative size-12 squircle-element flex items-center justify-center transition-all duration-300 border overflow-hidden ${isSelected+ ? "border-transparent scale-105 text-white": "border-border hover:border-foreground/30"}`}- style={{- background: isSelected- ? "radial-gradient(circle at 50% 0%, rgb(85, 85, 85) 0%, rgb(40, 40, 40) 80%)"- : "transparent",- boxShadow: isSelected- ? "rgb(255, 255, 255) 0px 0.5rem 0.2rem -0.5rem inset, rgba(255, 255, 255, 0.1) 0px 0px 0px 1px"- : "none",- }}+ style={isSelected ? {+ background: "radial-gradient(circle at 50% 0%, #555555 0%, #454545 64%)",+ boxShadow: "inset 0 1.01rem 0.2rem -1rem #fff, 0 0 0 1px #fff4, 0 4px 4px 0 #0004, 0 0 0 1px #333",+ } : undefined}><Iconicon={opt.icon}@@ -243,9 +239,10 @@ export function ExportImageDropdown({/>{isSelected && (- <div className="absolute left-1.5 top-1.5 size-4 bg-white rounded-full blur-[6px] opacity-30 rotate-45" />+ <div className="absolute -top-3 -left-1 size-8 bg-white rounded-full blur-[5px] rotate-45 opacity-50 pointer-events-none" />)}</div>+<spanclassName={`text-[9px] font-bold tracking-tighter ${isSelected ? "text-foreground" : "text-muted-foreground/60"}`}@@ -253,6 +250,7 @@ export function ExportImageDropdown({{opt.label}</span></button>+);})}</div>diff --git a/app/components/ui/editor/ControlPanel.tsx b/app/components/ui/editor/ControlPanel.tsxindex 9397b4d..c59fa67 100644--- a/app/components/ui/editor/ControlPanel.tsx+++ b/app/components/ui/editor/ControlPanel.tsx@@ -152,7 +152,7 @@ export function ControlPanel({<divclassName={`absolute inset-0 z-0 bg-cover bg-center bg-no-repeat pointer-events-none opacity-90 ${isDark? "bg-[url('/images/pages/header-gradient.avif')]"- : "bg-[url('/images/pages/header-gradient-light2.png')]"+ : "bg-[url('/images/pages/header-gradient-light.png')]"}`}style={{maskImage: `diff --git a/app/components/ui/editor/FeedbackWidget.tsx b/app/components/ui/editor/FeedbackWidget.tsxindex f7c27cf..566fbea 100644--- a/app/components/ui/editor/FeedbackWidget.tsx+++ b/app/components/ui/editor/FeedbackWidget.tsx@@ -153,8 +153,8 @@ export function FeedbackWidget() {key={opt.value}type="button"onClick={() => setType(opt.value)}- className={`group relative flex flex-col items-center justify-center gap-1.5 p-3 rounded-xl border text-xs font-medium transition-all duration-200 squircle-element-camera cursor-pointer focus:outline-none w-full h-full min-h-[90px]- ${isSelected+ className={`group relative flex flex-col items-center justify-center gap-1.5 p-3 rounded-xl border text-xs font-medium transition-all duration-200 squircle-element-camera cursor-pointer focus:outline-none w-full h-full min-h-[90px] overflow-hidden+ ${isSelected? "border-transparent text-white": "bg-transparent border-border text-muted-foreground hover:bg-muted hover:text-foreground hover:border-muted-foreground/50"}`}@@ -163,18 +163,19 @@ export function FeedbackWidget() {boxShadow: "inset 0 1.01rem 0.2rem -1rem #fff, 0 0 0 1px #fff4, 0 4px 4px 0 #0004, 0 0 0 1px #333",} : undefined}>- <div className="flex items-center justify-center transition-transform duration-300 scale-110 group-hover:scale-115 size-5">+ <div className={`flex items-center justify-center transition-transform duration-300 size-5 ${isSelected ? "scale-110" : "group-hover:scale-115"+ }`}><Icon icon={opt.icon} className="size-5" aria-hidden="true" /></div>-{isSelected && (- <div className="absolute left-3 w-8 h-2 top-3 bg-white rounded-full blur-[5px] rotate-45 pointer-events-none opacity-50" />+ <div className="absolute -top-3 -left-0 size-12 bg-white rounded-full blur-[12px] rotate-45 opacity-60 pointer-events-none" />)}- <span className="whitespace-nowrap overflow-hidden text-ellipsis max-w-full text-center mt-0.5">+ <span className="whitespace-nowrap overflow-hidden text-ellipsis max-w-full text-center mt-0.5 relative z-10">{t(`types.${opt.value}`)}</span></button>+);})}</div>diff --git a/components/ui/HeroEditorPreviewComponents.tsx b/components/ui/HeroEditorPreviewComponents.tsxindex a138460..2f52eba 100644--- a/components/ui/HeroEditorPreviewComponents.tsx+++ b/components/ui/HeroEditorPreviewComponents.tsx@@ -124,9 +124,8 @@ export const DraggableRange = memo(function DraggableRange({onPointerDown={startDrag("resize-left")}><div- className={`w-1.5 h-8 rounded-full transition-all ${- handleClassName ?? "bg-[#34A853] group-hover/trim:bg-[#4ade80]"- }`}+ className={`w-1.5 h-8 rounded-full transition-all ${handleClassName ?? "bg-[#34A853] group-hover/trim:bg-[#4ade80]"+ }`}/></div><div@@ -134,9 +133,8 @@ export const DraggableRange = memo(function DraggableRange({onPointerDown={startDrag("resize-right")}><div- className={`w-1.5 h-8 rounded-full transition-all ${- handleClassName ?? "bg-[#34A853] group-hover/trim:bg-[#4ade80]"- }`}+ className={`w-1.5 h-8 rounded-full transition-all ${handleClassName ?? "bg-[#34A853] group-hover/trim:bg-[#4ade80]"+ }`}/></div></div>@@ -156,11 +154,10 @@ export const TimelineClipContent = memo(function TimelineClipContent({}) {return (<div- className={`relative h-full w-full rounded-md overflow-hidden transition-colors duration-200 z-0 bg-emerald-100 ${- isSelected+ className={`relative h-full w-full rounded-md overflow-hidden transition-colors duration-200 z-0 bg-emerald-100 ${isSelected? "border-2 border-[#34A853] shadow-[0_0_12px_rgba(52,168,83,0.3)]": ""- }`}+ }`}style={{border: isSelected ? undefined : "1px solid rgba(52, 168, 83, 0.4)",}}@@ -222,16 +219,14 @@ export const TimelineZoomContent = memo(function TimelineZoomContent({}) {return (<div- className={`flex h-full w-full flex-col items-center justify-center gap-0 rounded-md transition-all duration-200 pointer-events-none ${- isSelected+ className={`flex h-full w-full flex-col items-center justify-center gap-0 rounded-md transition-all duration-200 pointer-events-none ${isSelected? "border-2 border-blue-600 ring-1 ring-blue-600/20 shadow-[0_0_12px_rgba(59,130,246,0.25)] bg-blue-100": "border border-blue-300 hover:border-blue-500 bg-blue-50/90"- }`}+ }`}><span- className={`flex items-center gap-1 text-[9px] leading-tight font-semibold ${- isSelected ? "text-blue-950" : "text-blue-900"- }`}+ className={`flex items-center gap-1 text-[9px] leading-tight font-semibold ${isSelected ? "text-blue-950" : "text-blue-900"+ }`}><Iconicon="iconamoon:zoom-in-bold"@@ -241,9 +236,8 @@ export const TimelineZoomContent = memo(function TimelineZoomContent({{zoomLabel}</span><span- className={`font-mono text-[8px] leading-tight ${- isSelected ? "text-blue-800" : "text-blue-700/80"- }`}+ className={`font-mono text-[8px] leading-tight ${isSelected ? "text-blue-800" : "text-blue-700/80"+ }`}>{zoomLevelToFactor(zoomLevel).toFixed(1)}× · {duration.toFixed(1)}s</span>@@ -306,19 +300,33 @@ export const MiniSidebar = memo(function MiniSidebar({ t }: { t: TFunc }) {return (<div key={tool.id} className="relative"><div- className={`w-11 h-11 rounded-2xl flex items-center justify-center transition-colors ${- active ? "bg-[#EAF6FF]" : "hover:bg-black/[0.04]"- }`}+ className={`w-11 h-11 squircle-element flex items-center justify-center transition-all duration-200 relative ${active ? "text-white" : "hover:bg-black/[0.04]"+ }`}+ style={+ active+ ? {+ background: "radial-gradient(circle at 50% 0%, #555555 0%, #454545 64%)",+ boxShadow: "inset 0 1.01rem 0.2rem -1rem #fff, 0 0 0 1px #fff4, 0 4px 4px 0 #0004, 0 0 0 1px #333",+ }+ : {}+ }>- {tool.icon ? (- <Icon icon={tool.icon} width={19} style={{ color: active ? ACCENT : "rgba(0,0,0,0.4)" }} />- ) : (- <ElementsIcon className="w-[19px] h-[19px] text-gray-400" />+ <div className={`transition-transform duration-300 ${active ? "scale-110" : "hover:scale-105"}`}>+ {tool.icon ? (+ <Icon icon={tool.icon} width={19} style={{ color: active ? "#ffffff" : "rgba(0,0,0,0.4)" }} />+ ) : (+ <ElementsIcon className={`w-[19px] h-[19px] ${active ? "text-white" : "text-gray-400"}`} />+ )}+ </div>++ {active && (+ <div className="absolute -top-3 -left-1 size-8 bg-white rounded-full blur-[5px] rotate-45 opacity-50 pointer-events-none" />)}</div>+{tool.badge === "new" && (- <span className="absolute -top-0.5 -right-0.5 px-[3px] py-[1px] rounded-full bg-amber-700 text-[6px] font-semibold text-white leading-tight">- NEW+ <span className="absolute -top-0.5 -right-0.5 px-[3px] py-[1px] rounded-full bg-amber-700 text-[6px] font-semibold text-white leading-tight uppercase">+ {t("sidebar.new")}</span>)}</div>@@ -395,9 +403,8 @@ export const MiniSlider = memo(function MiniSlider({<divref={trackRef}onPointerDown={handlePointerDown}- className={`relative flex h-[28px] w-full items-center overflow-hidden rounded-lg border border-black/6 bg-black/[0.035] ${- onChange ? "cursor-pointer touch-none select-none" : ""- }`}+ className={`relative flex h-[28px] w-full items-center overflow-hidden rounded-lg border border-black/6 bg-black/[0.035] ${onChange ? "cursor-pointer touch-none select-none" : ""+ }`}><divclassName="absolute bottom-0 left-0 top-0 bg-black/10 transition-[width] duration-150 ease-out"@@ -522,7 +529,7 @@ export const BackgroundPanel = memo(function BackgroundPanel({<div className="hidden md:flex flex-col w-64 lg:w-72 shrink-0 bg-white overflow-hidden"><header className="relative flex items-center justify-between h-12 px-3 shrink-0 bg-transparent isolation-isolate"><div- className="absolute inset-0 z-0 bg-[url('/images/pages/header-gradient2.avif')] bg-cover bg-center bg-no-repeat pointer-events-none"+ className="absolute inset-0 z-0 bg-[url('/images/pages/header-gradient-light.png')] bg-cover bg-center bg-no-repeat pointer-events-none"style={{maskImage: `linear-gradient(to bottom, black 55%, transparent 99%),@@ -539,14 +546,14 @@ export const BackgroundPanel = memo(function BackgroundPanel({}}/><div className="relative flex items-center gap-1.5 z-10">- <Image src="/svg/openvid-complete-static.svg" alt="Openvid" width={100} height={80} />+ <Image src="/svg/openvid-complete-light.svg" alt="Openvid" width={100} height={80} /></div><Icon icon="lucide:sidebar-close" width={16} className="relative text-black/30 z-10" /></header><div className="flex-1 overflow-y-none custom-scrollbar"><div className="p-4 pb-2"><div className="flex items-center gap-2 text-black/80 font-medium text-[13px] mb-3">- <Icon icon="solar:gallery-wide-linear" width={16} style={{ color: ACCENT }} />+ <Icon icon="solar:gallery-wide-linear" width={16} /><span>{t("background.title")}</span></div><div className="flex bg-black/[0.04] rounded-lg p-0.5 text-[11px] font-medium">diff --git a/components/ui/SliderControl.tsx b/components/ui/SliderControl.tsxindex 5de339b..9500d47 100644--- a/components/ui/SliderControl.tsx+++ b/components/ui/SliderControl.tsx@@ -73,7 +73,7 @@ export function SliderControl({return (<divref={sliderRef}- className="relative flex h-[30px] w-full cursor-pointer touch-none select-none items-center rounded-lg overflow-hidden border border-border"+ className="relative flex h-[35px] w-full cursor-pointer touch-none select-none items-center rounded-lg overflow-hidden border border-border"onClick={handleClick}onMouseDown={handleMouseDown}>diff --git a/messages/en.json b/messages/en.jsonindex 643b62c..08d6a11 100644--- a/messages/en.json+++ b/messages/en.json@@ -1450,7 +1450,8 @@"heroPreview": {"sidebar": {"record": "Record",- "upload": "Upload"+ "upload": "Upload",+ "new": "New"},"background": {"title": "Background",diff --git a/messages/es.json b/messages/es.jsonindex e00479f..a8c4fe4 100644--- a/messages/es.json+++ b/messages/es.json@@ -418,7 +418,7 @@"blur": "Desenfoque del fondo","padding": "Padding","rounded": "Esquinas redondeadas",- "shadows": "Sombras"+ "shadows": "Sombra"}},"tools": {@@ -1428,20 +1428,21 @@"heroPreview": {"sidebar": {"record": "Grabar",- "upload": "Subir"+ "upload": "Subir",+ "new": "Nuevo"},"background": {"title": "Fondo","tabWallpaper": "Wallpaper","tabColor": "Color","options": "Opciones",- "desktopLabel": "Desktop",- "gradientsLabel": "Gradients",+ "desktopLabel": "Escritorio",+ "gradientsLabel": "Gradientes","showMore": "MOSTRAR MÁS","settings": "Ajustes",- "blur": "Blur",+ "blur": "Desenfoque de fondo","padding": "Padding",- "rounded": "Bordes",+ "rounded": "Esquinas redondeadas","shadow": "Sombra"},"timeline": {diff --git a/messages/ko.json b/messages/ko.jsonindex 81ba120..bfbf651 100644--- a/messages/ko.json+++ b/messages/ko.json@@ -1450,7 +1450,8 @@"heroPreview": {"sidebar": {"record": "녹화",- "upload": "업로드"+ "upload": "업로드",+ "new": "새로운 기능"},"background": {"title": "배경",diff --git a/messages/ru.json b/messages/ru.jsonindex 8e1b2e4..a9abf47 100644--- a/messages/ru.json+++ b/messages/ru.json@@ -1450,7 +1450,8 @@"heroPreview": {"sidebar": {"record": "Запись",- "upload": "Загрузить"+ "upload": "Загрузить",+ "new": "НОВИНКА"},"background": {"title": "Фон",