diff --git a/apps/web/src/components/editor/panels/assets/draggable-item.tsx b/apps/web/src/components/editor/panels/assets/draggable-item.tsx
index 10cb1f8c..517fdc92 100644
--- a/apps/web/src/components/editor/panels/assets/draggable-item.tsx
+++ b/apps/web/src/components/editor/panels/assets/draggable-item.tsx
@@ -110,7 +110,7 @@ export function DraggableItem({
{
diff --git a/apps/web/src/components/editor/panels/assets/index.tsx b/apps/web/src/components/editor/panels/assets/index.tsx
index 9161cb1d..e7bd3d4f 100644
--- a/apps/web/src/components/editor/panels/assets/index.tsx
+++ b/apps/web/src/components/editor/panels/assets/index.tsx
@@ -43,7 +43,7 @@ export function AssetsPanel() {
};
return (
-
+
{viewMap[activeTab]}
diff --git a/apps/web/src/components/editor/panels/assets/tabbar.tsx b/apps/web/src/components/editor/panels/assets/tabbar.tsx
index 2c950fdc..31842306 100644
--- a/apps/web/src/components/editor/panels/assets/tabbar.tsx
+++ b/apps/web/src/components/editor/panels/assets/tabbar.tsx
@@ -6,6 +6,7 @@ import {
TooltipContent,
TooltipTrigger,
} from "@/components/ui/tooltip";
+import { Button } from "@/components/ui/button";
import { cn } from "@/utils/ui";
import {
TAB_KEYS,
@@ -15,9 +16,9 @@ import {
export function TabBar() {
const { activeTab, setActiveTab } = useAssetsPanelStore();
- const scrollRef = useRef
(null);
const [showTopFade, setShowTopFade] = useState(false);
const [showBottomFade, setShowBottomFade] = useState(false);
+ const scrollRef = useRef(null);
const checkScrollPosition = useCallback(() => {
const element = scrollRef.current;
@@ -48,32 +49,24 @@ export function TabBar() {
{TAB_KEYS.map((tabKey) => {
const tab = tabs[tabKey];
return (
-
+
+
);
diff --git a/apps/web/src/components/editor/panels/assets/views/captions.tsx b/apps/web/src/components/editor/panels/assets/views/captions.tsx
index d93baeff..daebf2c6 100644
--- a/apps/web/src/components/editor/panels/assets/views/captions.tsx
+++ b/apps/web/src/components/editor/panels/assets/views/captions.tsx
@@ -1,5 +1,4 @@
import { Button } from "@/components/ui/button";
-import { PropertyGroup } from "@/components/editor/panels/properties/property-item";
import { PanelBaseView as BaseView } from "@/components/editor/panels/panel-base-view";
import {
Select,
@@ -21,6 +20,7 @@ import { transcriptionService } from "@/services/transcription/service";
import { decodeAudioToFloat32 } from "@/lib/media/audio";
import { buildCaptionChunks } from "@/lib/transcription/caption";
import { Spinner } from "@/components/ui/spinner";
+import { Label } from "@/components/ui/label";
export function Captions() {
const [selectedLanguage, setSelectedLanguage] =
@@ -112,12 +112,13 @@ export function Captions() {
ref={containerRef}
className="flex h-full flex-col justify-between"
>
-
+
+
-
+
{error && (
diff --git a/apps/web/src/components/editor/panels/assets/views/media.tsx b/apps/web/src/components/editor/panels/assets/views/media.tsx
index 76ae0064..59395fd8 100644
--- a/apps/web/src/components/editor/panels/assets/views/media.tsx
+++ b/apps/web/src/components/editor/panels/assets/views/media.tsx
@@ -202,7 +202,7 @@ export function MediaView() {
className={`relative flex h-full flex-col gap-1 ${isDragOver ? "bg-accent/30" : ""}`}
{...dragProps}
>
-
+
Assets
@@ -320,10 +320,10 @@ export function MediaView() {
onClick={openFilePicker}
disabled={isProcessing}
size="sm"
- className="items-center justify-center gap-1.5 ml-1.5"
+ className="items-center justify-center gap-1.5 ml-1.5 hover:bg-accent px-3"
>
- Upload
+ Import
diff --git a/apps/web/src/components/editor/panels/assets/views/settings.tsx b/apps/web/src/components/editor/panels/assets/views/settings.tsx
index b8c54510..26afe566 100644
--- a/apps/web/src/components/editor/panels/assets/views/settings.tsx
+++ b/apps/web/src/components/editor/panels/assets/views/settings.tsx
@@ -21,7 +21,6 @@ import { colors } from "@/data/colors/solid";
import { syntaxUIGradients } from "@/data/colors/syntax-ui";
import { useEditor } from "@/hooks/use-editor";
import { useEditorStore } from "@/stores/editor-store";
-import type { TProject } from "@/types/project";
import { dimensionToAspectRatio } from "@/utils/geometry";
import { cn } from "@/utils/ui";
import {
@@ -30,8 +29,7 @@ import {
PropertyItemLabel,
PropertyItemValue,
} from "@/components/editor/panels/properties/property-item";
-import { HugeiconsIcon } from "@hugeicons/react";
-import { DropperIcon } from "@hugeicons/core-free-icons";
+import { ColorPicker } from "@/components/ui/color-picker";
export function SettingsView() {
return
;
@@ -56,24 +54,9 @@ function ProjectSettingsTabs() {
label: "Background",
content: (
-
+
- {/*
-
-
-
*/}
-
- {/* another ui */}
- {/*
*/}
),
},
@@ -83,15 +66,6 @@ function ProjectSettingsTabs() {
);
}
-function getCurrentCanvasSize({ activeProject }: { activeProject: TProject }) {
- const { canvasSize } = activeProject.settings;
-
- return {
- width: canvasSize.width,
- height: canvasSize.height,
- };
-}
-
function ProjectInfoView() {
const editor = useEditor();
const activeProject = editor.project.getActive();
@@ -117,7 +91,7 @@ function ProjectInfoView() {
return -1;
};
- const currentCanvasSize = getCurrentCanvasSize({ activeProject });
+ const currentCanvasSize = activeProject.settings.canvasSize;
const currentAspectRatio = dimensionToAspectRatio(currentCanvasSize);
const originalCanvasSize = activeProject.settings.originalCanvasSize ?? null;
const presetIndex = findPresetIndexByAspectRatio({
@@ -162,7 +136,7 @@ function ProjectInfoView() {
value={selectedPresetValue}
onValueChange={(value) => handleAspectRatioChange({ value })}
>
-
+
@@ -190,7 +164,7 @@ function ProjectInfoView() {
value={activeProject.settings.fps.toString()}
onValueChange={handleFpsChange}
>
-
+
@@ -219,7 +193,7 @@ const BlurPreview = memo(
}) => (