@twick/studio 0.14.5 → 0.14.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +147 -122
- package/dist/components/panel/circle-panel.d.ts +1 -1
- package/dist/components/panel/icon-panel.d.ts +1 -1
- package/dist/components/panel/rect-panel.d.ts +1 -1
- package/dist/components/props-toolbar.d.ts +1 -1
- package/dist/components/shared/file-input.d.ts +3 -1
- package/dist/hooks/use-circle-panel.d.ts +1 -0
- package/dist/hooks/use-rect-panel.d.ts +1 -0
- package/dist/index.js +511 -620
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +511 -620
- package/dist/index.mjs.map +1 -1
- package/dist/studio.css +2160 -284
- package/dist/twick.svg +3 -3
- package/package.json +48 -50
- package/dist/components/shared/prop-container.d.ts +0 -7
- package/dist/styles/input-styles.d.ts +0 -39
package/dist/index.js
CHANGED
|
@@ -471,20 +471,18 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
471
471
|
const handleToolSelect = (toolId) => {
|
|
472
472
|
setSelectedTool(toolId);
|
|
473
473
|
};
|
|
474
|
-
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "
|
|
474
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "sidebar", children: toolCategories.map((tool) => {
|
|
475
475
|
const Icon2 = getIcon$1(tool.icon);
|
|
476
476
|
const isSelected = selectedTool === tool.id;
|
|
477
477
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
478
|
-
"
|
|
478
|
+
"div",
|
|
479
479
|
{
|
|
480
480
|
onClick: () => handleToolSelect(tool.id),
|
|
481
|
-
className: `
|
|
482
|
-
toolbar-btn group ${isSelected ? "active" : ""}
|
|
483
|
-
`,
|
|
481
|
+
className: `toolbar-btn ${isSelected ? "active" : ""}`,
|
|
484
482
|
title: `${tool.name}${tool.shortcut ? ` (${tool.shortcut})` : ""}`,
|
|
485
483
|
children: [
|
|
486
|
-
/* @__PURE__ */ jsxRuntime.jsx(Icon2, { className: "
|
|
487
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "
|
|
484
|
+
/* @__PURE__ */ jsxRuntime.jsx(Icon2, { className: "icon-sm" }),
|
|
485
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "toolbar-label", children: tool.name })
|
|
488
486
|
]
|
|
489
487
|
},
|
|
490
488
|
tool.id
|
|
@@ -515,20 +513,20 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
515
513
|
setVideoResolution({ width: 720, height: 1280 });
|
|
516
514
|
}
|
|
517
515
|
}, [orientation]);
|
|
518
|
-
return /* @__PURE__ */ jsxRuntime.jsxs("header", { className: "
|
|
519
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex
|
|
520
|
-
/* @__PURE__ */ jsxRuntime.jsx(Clapperboard, { className: "
|
|
521
|
-
/* @__PURE__ */ jsxRuntime.jsx("h1", { className: "text-
|
|
516
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("header", { className: "header", children: [
|
|
517
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-container", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex-container", children: [
|
|
518
|
+
/* @__PURE__ */ jsxRuntime.jsx(Clapperboard, { className: "icon-lg accent-purple" }),
|
|
519
|
+
/* @__PURE__ */ jsxRuntime.jsx("h1", { className: "text-gradient", children: "Twick Studio" })
|
|
522
520
|
] }) }),
|
|
523
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex
|
|
521
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex-container", children: [
|
|
524
522
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
525
523
|
"button",
|
|
526
524
|
{
|
|
527
|
-
className: "btn
|
|
525
|
+
className: "btn-ghost",
|
|
528
526
|
title: "Load Project",
|
|
529
527
|
onClick: onLoadProject,
|
|
530
528
|
children: [
|
|
531
|
-
/* @__PURE__ */ jsxRuntime.jsx(File, { className: "
|
|
529
|
+
/* @__PURE__ */ jsxRuntime.jsx(File, { className: "icon-sm" }),
|
|
532
530
|
"Load Project"
|
|
533
531
|
]
|
|
534
532
|
}
|
|
@@ -536,11 +534,11 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
536
534
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
537
535
|
"button",
|
|
538
536
|
{
|
|
539
|
-
className: "btn
|
|
537
|
+
className: "btn-ghost",
|
|
540
538
|
title: "Save Draft",
|
|
541
539
|
onClick: onSaveProject,
|
|
542
540
|
children: [
|
|
543
|
-
/* @__PURE__ */ jsxRuntime.jsx(Save, { className: "
|
|
541
|
+
/* @__PURE__ */ jsxRuntime.jsx(Save, { className: "icon-sm" }),
|
|
544
542
|
"Save Draft"
|
|
545
543
|
]
|
|
546
544
|
}
|
|
@@ -548,11 +546,11 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
548
546
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
549
547
|
"button",
|
|
550
548
|
{
|
|
551
|
-
className: "btn
|
|
549
|
+
className: "btn-primary",
|
|
552
550
|
title: "Export",
|
|
553
551
|
onClick: onExportVideo,
|
|
554
552
|
children: [
|
|
555
|
-
/* @__PURE__ */ jsxRuntime.jsx(Download, { className: "
|
|
553
|
+
/* @__PURE__ */ jsxRuntime.jsx(Download, { className: "icon-sm" }),
|
|
556
554
|
"Export"
|
|
557
555
|
]
|
|
558
556
|
}
|
|
@@ -629,14 +627,14 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
629
627
|
(sub) => sub.id === id ? { ...sub, [field]: value } : sub
|
|
630
628
|
));
|
|
631
629
|
};
|
|
632
|
-
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
633
|
-
/* @__PURE__ */ jsxRuntime.jsx("h3", { className: "
|
|
634
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex
|
|
630
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-container", children: [
|
|
631
|
+
/* @__PURE__ */ jsxRuntime.jsx("h3", { className: "panel-title", children: "Subtitles" }),
|
|
632
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "panel-section", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex-container", children: [
|
|
635
633
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
636
634
|
"button",
|
|
637
635
|
{
|
|
638
636
|
onClick: handleGenerate,
|
|
639
|
-
className: "
|
|
637
|
+
className: "btn-primary",
|
|
640
638
|
children: "Generate"
|
|
641
639
|
}
|
|
642
640
|
),
|
|
@@ -644,19 +642,19 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
644
642
|
"button",
|
|
645
643
|
{
|
|
646
644
|
onClick: handleAdd,
|
|
647
|
-
className: "
|
|
645
|
+
className: "btn-primary",
|
|
648
646
|
children: "Add"
|
|
649
647
|
}
|
|
650
648
|
)
|
|
651
|
-
] }),
|
|
652
|
-
|
|
649
|
+
] }) }),
|
|
650
|
+
subtitles.map((subtitle) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
653
651
|
"div",
|
|
654
652
|
{
|
|
655
|
-
className: "
|
|
653
|
+
className: "panel-section",
|
|
656
654
|
children: [
|
|
657
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex
|
|
658
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", {
|
|
659
|
-
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "
|
|
655
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex-container", children: [
|
|
656
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
657
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-small", children: "Start" }),
|
|
660
658
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
661
659
|
"input",
|
|
662
660
|
{
|
|
@@ -665,12 +663,12 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
665
663
|
step: "0.1",
|
|
666
664
|
value: subtitle.start,
|
|
667
665
|
onChange: (e) => handleUpdateSubtitle(subtitle.id, "start", Number(e.target.value)),
|
|
668
|
-
className: "
|
|
666
|
+
className: "input-dark"
|
|
669
667
|
}
|
|
670
668
|
)
|
|
671
669
|
] }),
|
|
672
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", {
|
|
673
|
-
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "
|
|
670
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
671
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-small", children: "End" }),
|
|
674
672
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
675
673
|
"input",
|
|
676
674
|
{
|
|
@@ -679,56 +677,61 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
679
677
|
step: "0.1",
|
|
680
678
|
value: subtitle.end,
|
|
681
679
|
onChange: (e) => handleUpdateSubtitle(subtitle.id, "end", Number(e.target.value)),
|
|
682
|
-
className: "
|
|
680
|
+
className: "input-dark"
|
|
683
681
|
}
|
|
684
682
|
)
|
|
685
683
|
] })
|
|
686
684
|
] }),
|
|
687
|
-
/* @__PURE__ */ jsxRuntime.
|
|
688
|
-
"
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
|
|
697
|
-
|
|
685
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
686
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-dark", children: "Subtitle Text" }),
|
|
687
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
688
|
+
"input",
|
|
689
|
+
{
|
|
690
|
+
type: "text",
|
|
691
|
+
placeholder: "Enter subtitle text",
|
|
692
|
+
value: subtitle.text,
|
|
693
|
+
onChange: (e) => handleUpdateSubtitle(subtitle.id, "text", e.target.value),
|
|
694
|
+
className: "input-dark"
|
|
695
|
+
}
|
|
696
|
+
)
|
|
697
|
+
] }),
|
|
698
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex-container justify-between", children: [
|
|
698
699
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
699
700
|
"button",
|
|
700
701
|
{
|
|
701
702
|
onClick: () => handleDelete(subtitle.id),
|
|
702
|
-
className: "
|
|
703
|
+
className: "btn-danger",
|
|
703
704
|
title: "Delete subtitle",
|
|
704
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(Trash2, { className: "
|
|
705
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(Trash2, { className: "icon-sm" })
|
|
705
706
|
}
|
|
706
707
|
),
|
|
707
708
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
708
709
|
"button",
|
|
709
710
|
{
|
|
710
711
|
onClick: () => handleSave(subtitle.id),
|
|
711
|
-
className: "
|
|
712
|
+
className: "btn-primary",
|
|
712
713
|
title: "Save subtitle",
|
|
713
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(Check, { className: "
|
|
714
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(Check, { className: "icon-sm" })
|
|
714
715
|
}
|
|
715
716
|
)
|
|
716
717
|
] })
|
|
717
718
|
]
|
|
718
719
|
},
|
|
719
720
|
subtitle.id
|
|
720
|
-
))
|
|
721
|
-
subtitles.length === 0 && /* @__PURE__ */ jsxRuntime.
|
|
722
|
-
/* @__PURE__ */ jsxRuntime.jsx("p", { children: "No subtitles yet" }),
|
|
723
|
-
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "
|
|
724
|
-
] })
|
|
721
|
+
)),
|
|
722
|
+
subtitles.length === 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "panel-section", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "empty-state", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "empty-state-content", children: [
|
|
723
|
+
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "empty-state-text", children: "No subtitles yet" }),
|
|
724
|
+
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "empty-state-subtext", children: 'Click "Add" to create your first subtitle' })
|
|
725
|
+
] }) }) })
|
|
725
726
|
] });
|
|
726
727
|
}
|
|
727
728
|
const FileInput = ({
|
|
728
729
|
acceptFileTypes,
|
|
729
730
|
onFileLoad,
|
|
730
731
|
buttonText,
|
|
731
|
-
id
|
|
732
|
+
id,
|
|
733
|
+
className,
|
|
734
|
+
icon
|
|
732
735
|
}) => {
|
|
733
736
|
const onFileChange = (e) => {
|
|
734
737
|
var _a;
|
|
@@ -757,13 +760,13 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
757
760
|
}
|
|
758
761
|
}
|
|
759
762
|
};
|
|
760
|
-
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
763
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "file-input-container", children: [
|
|
761
764
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
762
765
|
"input",
|
|
763
766
|
{
|
|
764
767
|
type: "file",
|
|
765
768
|
accept: acceptFileTypes.join(","),
|
|
766
|
-
className: "
|
|
769
|
+
className: "file-input-hidden",
|
|
767
770
|
id,
|
|
768
771
|
onChange: onFileChange
|
|
769
772
|
}
|
|
@@ -772,9 +775,9 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
772
775
|
"label",
|
|
773
776
|
{
|
|
774
777
|
htmlFor: id,
|
|
775
|
-
className:
|
|
778
|
+
className: className || "btn-primary file-input-label",
|
|
776
779
|
children: [
|
|
777
|
-
/* @__PURE__ */ jsxRuntime.jsx(Upload, { className: "
|
|
780
|
+
icon || /* @__PURE__ */ jsxRuntime.jsx(Upload, { className: "icon-sm" }),
|
|
778
781
|
buttonText ?? "Upload"
|
|
779
782
|
]
|
|
780
783
|
}
|
|
@@ -965,7 +968,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
965
968
|
searchQuery,
|
|
966
969
|
setSearchQuery
|
|
967
970
|
}) => {
|
|
968
|
-
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
971
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "search-container", children: [
|
|
969
972
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
970
973
|
"input",
|
|
971
974
|
{
|
|
@@ -973,60 +976,12 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
973
976
|
placeholder: "Search media...",
|
|
974
977
|
value: searchQuery,
|
|
975
978
|
onChange: (e) => setSearchQuery(e.target.value),
|
|
976
|
-
className: "
|
|
979
|
+
className: "input search-input w-full"
|
|
977
980
|
}
|
|
978
981
|
),
|
|
979
|
-
/* @__PURE__ */ jsxRuntime.jsx(Search, { className: "
|
|
982
|
+
/* @__PURE__ */ jsxRuntime.jsx(Search, { className: "search-icon" })
|
|
980
983
|
] });
|
|
981
984
|
};
|
|
982
|
-
const inputStyles = {
|
|
983
|
-
// Base container styles for form groups
|
|
984
|
-
container: "mb-6",
|
|
985
|
-
// Label styles
|
|
986
|
-
label: {
|
|
987
|
-
base: "block text-sm font-semibold text-gray-300 mb-2",
|
|
988
|
-
small: "block text-xs text-gray-400 mb-1"
|
|
989
|
-
},
|
|
990
|
-
// Text input and select styles
|
|
991
|
-
input: {
|
|
992
|
-
base: "w-full bg-neutral-700/50 border border-gray-600 rounded-lg text-white text-sm px-3 py-2 focus:border-purple-500 focus:outline-none focus:ring-2 focus:ring-purple-500/20 transition-all duration-200 backdrop-blur-sm",
|
|
993
|
-
small: "bg-neutral-700/50 border border-gray-600 rounded-lg text-white text-xs px-2 py-1 focus:border-purple-500 focus:outline-none focus:ring-2 focus:ring-purple-500/20 transition-all duration-200 backdrop-blur-sm"
|
|
994
|
-
},
|
|
995
|
-
// Range input styles
|
|
996
|
-
range: {
|
|
997
|
-
base: "flex-1 h-2 bg-neutral-600 rounded-full appearance-none cursor-pointer slider-thumb",
|
|
998
|
-
gradient: "flex-1 h-2 bg-gradient-to-r from-purple-500 to-neutral-600 rounded-full appearance-none cursor-pointer slider-thumb",
|
|
999
|
-
container: "flex items-center gap-3",
|
|
1000
|
-
value: "text-white text-sm font-medium min-w-[50px]"
|
|
1001
|
-
},
|
|
1002
|
-
// Color input styles
|
|
1003
|
-
color: {
|
|
1004
|
-
container: "flex items-center gap-2",
|
|
1005
|
-
picker: "w-6 h-6 rounded border border-gray-600 cursor-pointer",
|
|
1006
|
-
preview: "flex-1 h-8 rounded-lg border border-gray-600"
|
|
1007
|
-
},
|
|
1008
|
-
// Toggle button styles
|
|
1009
|
-
toggle: {
|
|
1010
|
-
base: "w-10 h-10 rounded-lg border-2 transition-all duration-200 hover:bg-purple-400 hover:text-white",
|
|
1011
|
-
active: "bg-purple-600 border-purple-500 text-white",
|
|
1012
|
-
inactive: "bg-transparent border-gray-600 text-gray-400 hover:border-gray-500"
|
|
1013
|
-
},
|
|
1014
|
-
// Radio button styles
|
|
1015
|
-
radio: {
|
|
1016
|
-
base: "w-4 h-4 text-purple-600 bg-neutral-700 border-gray-600 focus:ring-purple-500 focus:ring-2",
|
|
1017
|
-
label: "text-sm text-gray-300",
|
|
1018
|
-
container: "flex items-center gap-2"
|
|
1019
|
-
},
|
|
1020
|
-
// Action button styles
|
|
1021
|
-
button: {
|
|
1022
|
-
primary: "w-full bg-purple-600 hover:bg-purple-700 text-white font-medium py-3 px-4 rounded-lg transition-all duration-200 focus:outline-none focus:ring-2 focus:ring-purple-500/20"
|
|
1023
|
-
},
|
|
1024
|
-
// Panel container styles
|
|
1025
|
-
panel: {
|
|
1026
|
-
container: "w-72 h-full bg-neutral-800/80 border-l border-gray-600/50 p-4 overflow-y-auto overflow-x-hidden backdrop-blur-md shadow-lg",
|
|
1027
|
-
title: "text-xl font-bold text-white mb-6"
|
|
1028
|
-
}
|
|
1029
|
-
};
|
|
1030
985
|
const useAudioPreview = () => {
|
|
1031
986
|
const [playingAudio, setPlayingAudio] = react.useState(null);
|
|
1032
987
|
const audioRef = react.useRef(null);
|
|
@@ -1073,33 +1028,35 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
1073
1028
|
acceptFileTypes
|
|
1074
1029
|
}) => {
|
|
1075
1030
|
const { playingAudio, togglePlayPause } = useAudioPreview();
|
|
1076
|
-
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
1077
|
-
/* @__PURE__ */ jsxRuntime.jsx("
|
|
1078
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className:
|
|
1031
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-container", children: [
|
|
1032
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "panel-title", children: "Audio Library" }),
|
|
1033
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex panel-section", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
1079
1034
|
SearchInput,
|
|
1080
1035
|
{
|
|
1081
1036
|
searchQuery,
|
|
1082
1037
|
setSearchQuery: onSearchChange
|
|
1083
1038
|
}
|
|
1084
1039
|
) }),
|
|
1085
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className:
|
|
1040
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex panel-section", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
1086
1041
|
FileInput,
|
|
1087
1042
|
{
|
|
1088
1043
|
id: "audio-upload",
|
|
1089
1044
|
acceptFileTypes,
|
|
1090
1045
|
onFileLoad: onFileUpload,
|
|
1091
|
-
buttonText: "
|
|
1046
|
+
buttonText: "Import media",
|
|
1047
|
+
className: "btn-primary w-full",
|
|
1048
|
+
icon: /* @__PURE__ */ jsxRuntime.jsx(Upload, { className: "icon-sm" })
|
|
1092
1049
|
}
|
|
1093
1050
|
) }),
|
|
1094
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
1095
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "
|
|
1096
|
-
var _a;
|
|
1051
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "media-content", children: [
|
|
1052
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "media-list", children: (items || []).map((item) => {
|
|
1053
|
+
var _a, _b;
|
|
1097
1054
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1098
1055
|
"div",
|
|
1099
1056
|
{
|
|
1100
1057
|
onDoubleClick: () => onItemSelect(item),
|
|
1101
|
-
className: "
|
|
1102
|
-
children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
1058
|
+
className: "media-list-item",
|
|
1059
|
+
children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "media-list-content", children: [
|
|
1103
1060
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1104
1061
|
"button",
|
|
1105
1062
|
{
|
|
@@ -1107,12 +1064,12 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
1107
1064
|
e.stopPropagation();
|
|
1108
1065
|
togglePlayPause(item);
|
|
1109
1066
|
},
|
|
1110
|
-
className: "
|
|
1111
|
-
children: playingAudio === item.id ? /* @__PURE__ */ jsxRuntime.jsx(Pause, { className: "
|
|
1067
|
+
className: "media-action-btn",
|
|
1068
|
+
children: playingAudio === item.id ? /* @__PURE__ */ jsxRuntime.jsx(Pause, { className: "icon-sm" }) : /* @__PURE__ */ jsxRuntime.jsx(Play, { className: "icon-sm" })
|
|
1112
1069
|
}
|
|
1113
1070
|
),
|
|
1114
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: `
|
|
1115
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "
|
|
1071
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: `media-list-icon ${playingAudio === item.id ? "active" : ""}`, children: /* @__PURE__ */ jsxRuntime.jsx(Volume2, { className: "icon-sm" }) }),
|
|
1072
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "media-list-title", children: ((_a = item.metadata) == null ? void 0 : _a.title) || ((_b = item.metadata) == null ? void 0 : _b.name) }),
|
|
1116
1073
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1117
1074
|
"button",
|
|
1118
1075
|
{
|
|
@@ -1120,8 +1077,8 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
1120
1077
|
e.stopPropagation();
|
|
1121
1078
|
onItemSelect(item, true);
|
|
1122
1079
|
},
|
|
1123
|
-
className: "
|
|
1124
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(Plus, { className: "
|
|
1080
|
+
className: "media-action-btn",
|
|
1081
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(Plus, { className: "icon-sm" })
|
|
1125
1082
|
}
|
|
1126
1083
|
)
|
|
1127
1084
|
] })
|
|
@@ -1129,10 +1086,10 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
1129
1086
|
item.id
|
|
1130
1087
|
);
|
|
1131
1088
|
}) }),
|
|
1132
|
-
items.length === 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className:
|
|
1133
|
-
/* @__PURE__ */ jsxRuntime.jsx(WandSparkles, { className: "
|
|
1134
|
-
/* @__PURE__ */ jsxRuntime.jsx("p", { className:
|
|
1135
|
-
searchQuery && /* @__PURE__ */ jsxRuntime.jsx("p", { className:
|
|
1089
|
+
items.length === 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "empty-state", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "empty-state-content", children: [
|
|
1090
|
+
/* @__PURE__ */ jsxRuntime.jsx(WandSparkles, { className: "empty-state-icon" }),
|
|
1091
|
+
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "empty-state-text", children: "No audio files found" }),
|
|
1092
|
+
searchQuery && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "empty-state-subtext", children: "Try adjusting your search" })
|
|
1136
1093
|
] }) })
|
|
1137
1094
|
] })
|
|
1138
1095
|
] });
|
|
@@ -1176,59 +1133,53 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
1176
1133
|
onFileUpload,
|
|
1177
1134
|
acceptFileTypes
|
|
1178
1135
|
}) {
|
|
1179
|
-
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
1180
|
-
/* @__PURE__ */ jsxRuntime.jsx("
|
|
1181
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className:
|
|
1136
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-container", children: [
|
|
1137
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "panel-title", children: "Image Library" }),
|
|
1138
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex panel-section", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
1182
1139
|
SearchInput,
|
|
1183
1140
|
{
|
|
1184
1141
|
searchQuery,
|
|
1185
1142
|
setSearchQuery: onSearchChange
|
|
1186
1143
|
}
|
|
1187
1144
|
) }),
|
|
1188
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className:
|
|
1145
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex panel-section", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
1189
1146
|
FileInput,
|
|
1190
1147
|
{
|
|
1191
1148
|
id: "image-upload",
|
|
1192
1149
|
acceptFileTypes,
|
|
1193
1150
|
onFileLoad: onFileUpload,
|
|
1194
|
-
buttonText: "
|
|
1151
|
+
buttonText: "Import media",
|
|
1152
|
+
className: "btn-primary w-full",
|
|
1153
|
+
icon: /* @__PURE__ */ jsxRuntime.jsx(Upload, { className: "icon-sm" })
|
|
1195
1154
|
}
|
|
1196
1155
|
) }),
|
|
1197
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
1198
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "grid
|
|
1156
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "media-content", children: [
|
|
1157
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "media-grid", children: (items || []).map((item) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
1199
1158
|
"div",
|
|
1200
1159
|
{
|
|
1201
1160
|
onDoubleClick: () => onItemSelect(item),
|
|
1202
|
-
className: "media-item
|
|
1161
|
+
className: "media-item",
|
|
1203
1162
|
children: [
|
|
1204
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1205
|
-
|
|
1206
|
-
{
|
|
1207
|
-
src: item.url,
|
|
1208
|
-
alt: "",
|
|
1209
|
-
className: "h-full w-full object-cover transition-transform group-hover:scale-105"
|
|
1210
|
-
}
|
|
1211
|
-
),
|
|
1212
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute inset-0 bg-black bg-opacity-0 transition-opacity group-hover:bg-opacity-20" }),
|
|
1213
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute top-1 right-1 opacity-0 group-hover:opacity-100 transition-opacity duration-200", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
1163
|
+
/* @__PURE__ */ jsxRuntime.jsx("img", { src: item.url, alt: "", className: "media-item-content" }),
|
|
1164
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "media-actions", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
1214
1165
|
"button",
|
|
1215
1166
|
{
|
|
1216
1167
|
onClick: (e) => {
|
|
1217
1168
|
e.stopPropagation();
|
|
1218
1169
|
onItemSelect(item, true);
|
|
1219
1170
|
},
|
|
1220
|
-
className: "
|
|
1221
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(Plus, { className: "
|
|
1171
|
+
className: "media-action-btn",
|
|
1172
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(Plus, { className: "icon-sm" })
|
|
1222
1173
|
}
|
|
1223
1174
|
) })
|
|
1224
1175
|
]
|
|
1225
1176
|
},
|
|
1226
1177
|
item.id
|
|
1227
1178
|
)) }),
|
|
1228
|
-
items.length === 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className:
|
|
1229
|
-
/* @__PURE__ */ jsxRuntime.jsx(WandSparkles, { className: "
|
|
1230
|
-
/* @__PURE__ */ jsxRuntime.jsx("p", { className:
|
|
1231
|
-
searchQuery && /* @__PURE__ */ jsxRuntime.jsx("p", { className:
|
|
1179
|
+
items.length === 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "empty-state", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "empty-state-content", children: [
|
|
1180
|
+
/* @__PURE__ */ jsxRuntime.jsx(WandSparkles, { className: "empty-state-icon" }),
|
|
1181
|
+
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "empty-state-text", children: "No images found" }),
|
|
1182
|
+
searchQuery && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "empty-state-subtext", children: "Try adjusting your search" })
|
|
1232
1183
|
] }) })
|
|
1233
1184
|
] })
|
|
1234
1185
|
] });
|
|
@@ -1311,37 +1262,39 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
1311
1262
|
acceptFileTypes
|
|
1312
1263
|
}) {
|
|
1313
1264
|
const { playingVideo, togglePlayPause } = useVideoPreview();
|
|
1314
|
-
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
1315
|
-
/* @__PURE__ */ jsxRuntime.jsx("
|
|
1316
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className:
|
|
1265
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-container", children: [
|
|
1266
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "panel-title", children: "Video Library" }),
|
|
1267
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex panel-section", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
1317
1268
|
SearchInput,
|
|
1318
1269
|
{
|
|
1319
1270
|
searchQuery,
|
|
1320
1271
|
setSearchQuery: onSearchChange
|
|
1321
1272
|
}
|
|
1322
1273
|
) }),
|
|
1323
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className:
|
|
1274
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex panel-section", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
1324
1275
|
FileInput,
|
|
1325
1276
|
{
|
|
1326
1277
|
id: "video-upload",
|
|
1327
1278
|
acceptFileTypes,
|
|
1328
1279
|
onFileLoad: onFileUpload,
|
|
1329
|
-
buttonText: "
|
|
1280
|
+
buttonText: "Import media",
|
|
1281
|
+
className: "btn-primary w-full",
|
|
1282
|
+
icon: /* @__PURE__ */ jsxRuntime.jsx(Upload, { className: "icon-sm" })
|
|
1330
1283
|
}
|
|
1331
1284
|
) }),
|
|
1332
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
1333
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "grid
|
|
1285
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "media-content", children: [
|
|
1286
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "media-grid", children: (items || []).map((item) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
1334
1287
|
"div",
|
|
1335
1288
|
{
|
|
1336
1289
|
onDoubleClick: () => onItemSelect(item),
|
|
1337
|
-
className: "media-item
|
|
1290
|
+
className: "media-item",
|
|
1338
1291
|
children: [
|
|
1339
1292
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1340
1293
|
"video",
|
|
1341
1294
|
{
|
|
1342
1295
|
src: item.url,
|
|
1343
1296
|
poster: item.thumbnail,
|
|
1344
|
-
className:
|
|
1297
|
+
className: "media-item-content",
|
|
1345
1298
|
ref: (el) => {
|
|
1346
1299
|
if (el) {
|
|
1347
1300
|
el.addEventListener("ended", () => {
|
|
@@ -1351,8 +1304,8 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
1351
1304
|
}
|
|
1352
1305
|
}
|
|
1353
1306
|
),
|
|
1354
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className:
|
|
1355
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
1307
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "media-duration", children: "0:13" }),
|
|
1308
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "media-actions", children: [
|
|
1356
1309
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1357
1310
|
"button",
|
|
1358
1311
|
{
|
|
@@ -1364,8 +1317,8 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
1364
1317
|
togglePlayPause(item, videoEl);
|
|
1365
1318
|
}
|
|
1366
1319
|
},
|
|
1367
|
-
className:
|
|
1368
|
-
children: playingVideo === item.id ? /* @__PURE__ */ jsxRuntime.jsx(Pause, { className: "
|
|
1320
|
+
className: "media-action-btn",
|
|
1321
|
+
children: playingVideo === item.id ? /* @__PURE__ */ jsxRuntime.jsx(Pause, { className: "icon-sm" }) : /* @__PURE__ */ jsxRuntime.jsx(Play, { className: "icon-sm" })
|
|
1369
1322
|
}
|
|
1370
1323
|
),
|
|
1371
1324
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -1375,8 +1328,8 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
1375
1328
|
e.stopPropagation();
|
|
1376
1329
|
onItemSelect(item, true);
|
|
1377
1330
|
},
|
|
1378
|
-
className: "
|
|
1379
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(Plus, { className: "
|
|
1331
|
+
className: "media-action-btn",
|
|
1332
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(Plus, { className: "icon-sm" })
|
|
1380
1333
|
}
|
|
1381
1334
|
)
|
|
1382
1335
|
] })
|
|
@@ -1384,10 +1337,10 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
1384
1337
|
},
|
|
1385
1338
|
item.id
|
|
1386
1339
|
)) }),
|
|
1387
|
-
items.length === 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className:
|
|
1388
|
-
/* @__PURE__ */ jsxRuntime.jsx(WandSparkles, { className: "
|
|
1389
|
-
/* @__PURE__ */ jsxRuntime.jsx("p", { className:
|
|
1390
|
-
searchQuery && /* @__PURE__ */ jsxRuntime.jsx("p", { className:
|
|
1340
|
+
items.length === 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "empty-state", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "empty-state-content", children: [
|
|
1341
|
+
/* @__PURE__ */ jsxRuntime.jsx(WandSparkles, { className: "empty-state-icon" }),
|
|
1342
|
+
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "empty-state-text", children: "No videos found" }),
|
|
1343
|
+
searchQuery && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "empty-state-subtext", children: "Try adjusting your search" })
|
|
1391
1344
|
] }) })
|
|
1392
1345
|
] })
|
|
1393
1346
|
] });
|
|
@@ -1448,23 +1401,21 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
1448
1401
|
setStrokeWidth,
|
|
1449
1402
|
handleApplyChanges
|
|
1450
1403
|
}) {
|
|
1451
|
-
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
1452
|
-
/* @__PURE__ */ jsxRuntime.jsx("
|
|
1453
|
-
/* @__PURE__ */ jsxRuntime.
|
|
1454
|
-
|
|
1455
|
-
|
|
1456
|
-
"
|
|
1457
|
-
|
|
1458
|
-
|
|
1459
|
-
|
|
1460
|
-
|
|
1461
|
-
|
|
1462
|
-
|
|
1463
|
-
|
|
1464
|
-
|
|
1465
|
-
|
|
1466
|
-
/* @__PURE__ */ jsxRuntime.jsx("label", { className: inputStyles.label.base, children: "Font Size" }),
|
|
1467
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: inputStyles.range.container, children: [
|
|
1404
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-container", children: [
|
|
1405
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "panel-title", children: "Text" }),
|
|
1406
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex panel-section", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
1407
|
+
"input",
|
|
1408
|
+
{
|
|
1409
|
+
type: "text",
|
|
1410
|
+
value: textContent,
|
|
1411
|
+
placeholder: "Sample",
|
|
1412
|
+
onChange: (e) => setTextContent(e.target.value),
|
|
1413
|
+
className: "input-dark"
|
|
1414
|
+
}
|
|
1415
|
+
) }),
|
|
1416
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-section", children: [
|
|
1417
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-dark", children: "Font Size" }),
|
|
1418
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "slider-container", children: [
|
|
1468
1419
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1469
1420
|
"input",
|
|
1470
1421
|
{
|
|
@@ -1473,24 +1424,24 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
1473
1424
|
max: "120",
|
|
1474
1425
|
value: fontSize,
|
|
1475
1426
|
onChange: (e) => setFontSize(Number(e.target.value)),
|
|
1476
|
-
className:
|
|
1427
|
+
className: "slider-purple"
|
|
1477
1428
|
}
|
|
1478
1429
|
),
|
|
1479
|
-
/* @__PURE__ */ jsxRuntime.jsxs("span", { className:
|
|
1430
|
+
/* @__PURE__ */ jsxRuntime.jsxs("span", { className: "slider-value", children: [
|
|
1480
1431
|
fontSize,
|
|
1481
1432
|
"px"
|
|
1482
1433
|
] })
|
|
1483
1434
|
] })
|
|
1484
1435
|
] }),
|
|
1485
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
1486
|
-
/* @__PURE__ */ jsxRuntime.jsx("label", { className:
|
|
1487
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
1436
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-section", children: [
|
|
1437
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-dark", children: "Font" }),
|
|
1438
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "font-controls", children: [
|
|
1488
1439
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1489
1440
|
"select",
|
|
1490
1441
|
{
|
|
1491
1442
|
value: selectedFont,
|
|
1492
1443
|
onChange: (e) => setSelectedFont(e.target.value),
|
|
1493
|
-
className:
|
|
1444
|
+
className: "select-dark",
|
|
1494
1445
|
children: fonts.map((font) => /* @__PURE__ */ jsxRuntime.jsx("option", { value: font, children: font }, font))
|
|
1495
1446
|
}
|
|
1496
1447
|
),
|
|
@@ -1498,33 +1449,33 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
1498
1449
|
"button",
|
|
1499
1450
|
{
|
|
1500
1451
|
onClick: () => setIsBold(!isBold),
|
|
1501
|
-
className:
|
|
1502
|
-
children:
|
|
1452
|
+
className: `btn-icon ${isBold ? "btn-icon-active" : ""}`,
|
|
1453
|
+
children: "B"
|
|
1503
1454
|
}
|
|
1504
1455
|
),
|
|
1505
1456
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1506
1457
|
"button",
|
|
1507
1458
|
{
|
|
1508
1459
|
onClick: () => setIsItalic(!isItalic),
|
|
1509
|
-
className:
|
|
1510
|
-
children:
|
|
1460
|
+
className: `btn-icon ${isItalic ? "btn-icon-active" : ""}`,
|
|
1461
|
+
children: "I"
|
|
1511
1462
|
}
|
|
1512
1463
|
)
|
|
1513
1464
|
] })
|
|
1514
1465
|
] }),
|
|
1515
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
1516
|
-
/* @__PURE__ */ jsxRuntime.jsx("label", { className:
|
|
1517
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
1518
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
1519
|
-
/* @__PURE__ */ jsxRuntime.jsx("label", { className:
|
|
1520
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
1466
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-section", children: [
|
|
1467
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-dark", children: "Colors" }),
|
|
1468
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "color-section", children: [
|
|
1469
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "color-control", children: [
|
|
1470
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-small", children: "Text Color" }),
|
|
1471
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "color-inputs", children: [
|
|
1521
1472
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1522
1473
|
"input",
|
|
1523
1474
|
{
|
|
1524
1475
|
type: "color",
|
|
1525
1476
|
value: textColor,
|
|
1526
1477
|
onChange: (e) => setTextColor(e.target.value),
|
|
1527
|
-
className:
|
|
1478
|
+
className: "color-picker"
|
|
1528
1479
|
}
|
|
1529
1480
|
),
|
|
1530
1481
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -1533,21 +1484,21 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
1533
1484
|
type: "text",
|
|
1534
1485
|
value: textColor,
|
|
1535
1486
|
onChange: (e) => setTextColor(e.target.value),
|
|
1536
|
-
className:
|
|
1487
|
+
className: "color-text"
|
|
1537
1488
|
}
|
|
1538
1489
|
)
|
|
1539
1490
|
] })
|
|
1540
1491
|
] }),
|
|
1541
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
1542
|
-
/* @__PURE__ */ jsxRuntime.jsx("label", { className:
|
|
1543
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
1492
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "color-control", children: [
|
|
1493
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-small", children: "Stroke Color" }),
|
|
1494
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "color-inputs", children: [
|
|
1544
1495
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1545
1496
|
"input",
|
|
1546
1497
|
{
|
|
1547
1498
|
type: "color",
|
|
1548
1499
|
value: strokeColor,
|
|
1549
1500
|
onChange: (e) => setStrokeColor(e.target.value),
|
|
1550
|
-
className:
|
|
1501
|
+
className: "color-picker"
|
|
1551
1502
|
}
|
|
1552
1503
|
),
|
|
1553
1504
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -1556,34 +1507,33 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
1556
1507
|
type: "text",
|
|
1557
1508
|
value: strokeColor,
|
|
1558
1509
|
onChange: (e) => setStrokeColor(e.target.value),
|
|
1559
|
-
className:
|
|
1510
|
+
className: "color-text"
|
|
1560
1511
|
}
|
|
1561
1512
|
)
|
|
1562
1513
|
] })
|
|
1563
1514
|
] }),
|
|
1564
|
-
/* @__PURE__ */ jsxRuntime.
|
|
1515
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "checkbox-control", children: /* @__PURE__ */ jsxRuntime.jsxs("label", { className: "checkbox-label", children: [
|
|
1565
1516
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1566
1517
|
"input",
|
|
1567
1518
|
{
|
|
1568
1519
|
type: "checkbox",
|
|
1569
|
-
id: "applyShadow",
|
|
1570
1520
|
checked: applyShadow,
|
|
1571
1521
|
onChange: (e) => setApplyShadow(e.target.checked),
|
|
1572
|
-
className:
|
|
1522
|
+
className: "checkbox-purple"
|
|
1573
1523
|
}
|
|
1574
1524
|
),
|
|
1575
|
-
|
|
1576
|
-
] }),
|
|
1577
|
-
applyShadow && /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
1578
|
-
/* @__PURE__ */ jsxRuntime.jsx("label", { className:
|
|
1579
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
1525
|
+
"Apply Shadow"
|
|
1526
|
+
] }) }),
|
|
1527
|
+
applyShadow && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "color-control", children: [
|
|
1528
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-small", children: "Shadow Color" }),
|
|
1529
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "color-inputs", children: [
|
|
1580
1530
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1581
1531
|
"input",
|
|
1582
1532
|
{
|
|
1583
1533
|
type: "color",
|
|
1584
1534
|
value: shadowColor,
|
|
1585
1535
|
onChange: (e) => setShadowColor(e.target.value),
|
|
1586
|
-
className:
|
|
1536
|
+
className: "color-picker"
|
|
1587
1537
|
}
|
|
1588
1538
|
),
|
|
1589
1539
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -1592,16 +1542,16 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
1592
1542
|
type: "text",
|
|
1593
1543
|
value: shadowColor,
|
|
1594
1544
|
onChange: (e) => setShadowColor(e.target.value),
|
|
1595
|
-
className:
|
|
1545
|
+
className: "color-text"
|
|
1596
1546
|
}
|
|
1597
1547
|
)
|
|
1598
1548
|
] })
|
|
1599
1549
|
] })
|
|
1600
1550
|
] })
|
|
1601
1551
|
] }),
|
|
1602
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
1603
|
-
/* @__PURE__ */ jsxRuntime.jsx("label", { className:
|
|
1604
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
1552
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-section", children: [
|
|
1553
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-dark", children: "Stroke Width" }),
|
|
1554
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "slider-container", children: [
|
|
1605
1555
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1606
1556
|
"input",
|
|
1607
1557
|
{
|
|
@@ -1611,13 +1561,13 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
1611
1561
|
step: 0.1,
|
|
1612
1562
|
value: strokeWidth,
|
|
1613
1563
|
onChange: (e) => setStrokeWidth(Number(e.target.value)),
|
|
1614
|
-
className:
|
|
1564
|
+
className: "slider-purple"
|
|
1615
1565
|
}
|
|
1616
1566
|
),
|
|
1617
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className:
|
|
1567
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "slider-value", children: strokeWidth })
|
|
1618
1568
|
] })
|
|
1619
1569
|
] }),
|
|
1620
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "
|
|
1570
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex panel-section", children: /* @__PURE__ */ jsxRuntime.jsx("button", { onClick: handleApplyChanges, className: "btn-primary w-full", children: operation }) })
|
|
1621
1571
|
] });
|
|
1622
1572
|
}
|
|
1623
1573
|
const DEFAULT_TEXT_PROPS = {
|
|
@@ -1759,7 +1709,6 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
1759
1709
|
function IconPanel({
|
|
1760
1710
|
icons,
|
|
1761
1711
|
loading,
|
|
1762
|
-
hasMore,
|
|
1763
1712
|
totalIcons,
|
|
1764
1713
|
searchQuery,
|
|
1765
1714
|
handleSearch,
|
|
@@ -1767,44 +1716,30 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
1767
1716
|
handleDownloadIcon,
|
|
1768
1717
|
handleLoadMore
|
|
1769
1718
|
}) {
|
|
1770
|
-
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
1771
|
-
/* @__PURE__ */ jsxRuntime.jsx("
|
|
1772
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className:
|
|
1773
|
-
|
|
1774
|
-
|
|
1775
|
-
{
|
|
1776
|
-
className: "absolute left-2.5 top-1/2 transform -translate-y-1/2 w-4 h-4 text-gray-400 z-10 pointer-events-none"
|
|
1777
|
-
}
|
|
1778
|
-
),
|
|
1779
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1780
|
-
"input",
|
|
1781
|
-
{
|
|
1782
|
-
type: "text",
|
|
1783
|
-
placeholder: "Search icons...",
|
|
1784
|
-
value: searchQuery,
|
|
1785
|
-
onChange: (e) => handleSearch(e.target.value),
|
|
1786
|
-
className: `${inputStyles.input.base} pl-8`
|
|
1787
|
-
}
|
|
1788
|
-
)
|
|
1789
|
-
] }) }),
|
|
1790
|
-
loading && icons.length === 0 ? /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center justify-center py-8", children: /* @__PURE__ */ jsxRuntime.jsx(LoaderCircle, { className: "h-8 w-8 animate-spin text-purple-500" }) }) : /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
1791
|
-
totalIcons > 0 && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mb-4 text-sm text-gray-400", children: [
|
|
1719
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-container", children: [
|
|
1720
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "panel-title", children: "Icon Library" }),
|
|
1721
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex panel-section", children: /* @__PURE__ */ jsxRuntime.jsx(SearchInput, { searchQuery, setSearchQuery: handleSearch }) }),
|
|
1722
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "media-content", children: [
|
|
1723
|
+
totalIcons > 0 && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "media-count", children: [
|
|
1792
1724
|
"Showing ",
|
|
1793
1725
|
icons.length,
|
|
1794
1726
|
" of ",
|
|
1795
1727
|
totalIcons,
|
|
1796
1728
|
" icons"
|
|
1797
1729
|
] }),
|
|
1798
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "
|
|
1730
|
+
loading && icons.length === 0 ? /* @__PURE__ */ jsxRuntime.jsx("div", { className: "empty-state", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "empty-state-content", children: [
|
|
1731
|
+
/* @__PURE__ */ jsxRuntime.jsx(LoaderCircle, { className: "empty-state-icon animate-spin" }),
|
|
1732
|
+
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "empty-state-text", children: "Loading icons..." })
|
|
1733
|
+
] }) }) : /* @__PURE__ */ jsxRuntime.jsx("div", { className: "icon-grid", children: (icons || []).map((icon, index) => /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "icon-item", children: [
|
|
1799
1734
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1800
1735
|
"div",
|
|
1801
1736
|
{
|
|
1802
1737
|
onClick: () => handleSelection(icon),
|
|
1803
|
-
className: "
|
|
1738
|
+
className: "icon-content",
|
|
1804
1739
|
dangerouslySetInnerHTML: { __html: icon.svg }
|
|
1805
1740
|
}
|
|
1806
1741
|
),
|
|
1807
|
-
/* @__PURE__ */ jsxRuntime.
|
|
1742
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "icon-actions", children: [
|
|
1808
1743
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1809
1744
|
"button",
|
|
1810
1745
|
{
|
|
@@ -1812,9 +1747,9 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
1812
1747
|
e.stopPropagation();
|
|
1813
1748
|
handleSelection(icon);
|
|
1814
1749
|
},
|
|
1815
|
-
className: "
|
|
1750
|
+
className: "icon-action-btn",
|
|
1816
1751
|
title: "Add to timeline",
|
|
1817
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
1752
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(Plus, { className: "icon-sm" })
|
|
1818
1753
|
}
|
|
1819
1754
|
),
|
|
1820
1755
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -1824,30 +1759,27 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
1824
1759
|
e.stopPropagation();
|
|
1825
1760
|
handleDownloadIcon(icon);
|
|
1826
1761
|
},
|
|
1827
|
-
className: "
|
|
1762
|
+
className: "icon-action-btn",
|
|
1828
1763
|
title: "Download SVG",
|
|
1829
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(Download, { className: "
|
|
1764
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(Download, { className: "icon-sm" })
|
|
1830
1765
|
}
|
|
1831
1766
|
)
|
|
1832
|
-
] })
|
|
1833
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "
|
|
1767
|
+
] }),
|
|
1768
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "icon-name", children: icon.name })
|
|
1834
1769
|
] }, index)) }),
|
|
1835
|
-
|
|
1770
|
+
!loading && icons.length === 0 && searchQuery && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "empty-state", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "empty-state-content", children: [
|
|
1771
|
+
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "empty-state-text", children: "No icons found" }),
|
|
1772
|
+
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "empty-state-subtext", children: "Try a different search term" })
|
|
1773
|
+
] }) }),
|
|
1774
|
+
!loading && totalIcons && icons.length < totalIcons && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex panel-section", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
1836
1775
|
"button",
|
|
1837
1776
|
{
|
|
1838
1777
|
onClick: handleLoadMore,
|
|
1839
1778
|
disabled: loading,
|
|
1840
|
-
className:
|
|
1841
|
-
children:
|
|
1842
|
-
/* @__PURE__ */ jsxRuntime.jsx(LoaderCircle, { className: "h-4 w-4 animate-spin" }),
|
|
1843
|
-
"Loading..."
|
|
1844
|
-
] }) : "Load More"
|
|
1779
|
+
className: "btn-primary",
|
|
1780
|
+
children: "Load More Icons"
|
|
1845
1781
|
}
|
|
1846
|
-
)
|
|
1847
|
-
!loading && icons.length === 0 && searchQuery && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "text-center py-8 text-gray-400", children: [
|
|
1848
|
-
/* @__PURE__ */ jsxRuntime.jsx("p", { children: "No icons found" }),
|
|
1849
|
-
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm mt-2", children: "Try a different search term" })
|
|
1850
|
-
] })
|
|
1782
|
+
) })
|
|
1851
1783
|
] })
|
|
1852
1784
|
] });
|
|
1853
1785
|
}
|
|
@@ -1973,6 +1905,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
1973
1905
|
opacity,
|
|
1974
1906
|
strokeColor,
|
|
1975
1907
|
lineWidth,
|
|
1908
|
+
operation,
|
|
1976
1909
|
setCornerRadius,
|
|
1977
1910
|
setFillColor,
|
|
1978
1911
|
setOpacity,
|
|
@@ -1980,11 +1913,11 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
1980
1913
|
setLineWidth,
|
|
1981
1914
|
handleApplyChanges
|
|
1982
1915
|
}) {
|
|
1983
|
-
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
1984
|
-
/* @__PURE__ */ jsxRuntime.jsx("
|
|
1985
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
1986
|
-
/* @__PURE__ */ jsxRuntime.jsx("label", { className:
|
|
1987
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
1916
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-container", children: [
|
|
1917
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "panel-title", children: "Rectangle" }),
|
|
1918
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-section", children: [
|
|
1919
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-dark", children: "Corner Radius" }),
|
|
1920
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "slider-container", children: [
|
|
1988
1921
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1989
1922
|
"input",
|
|
1990
1923
|
{
|
|
@@ -1993,39 +1926,41 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
1993
1926
|
max: "100",
|
|
1994
1927
|
value: cornerRadius,
|
|
1995
1928
|
onChange: (e) => setCornerRadius(Number(e.target.value)),
|
|
1996
|
-
className:
|
|
1929
|
+
className: "slider-purple"
|
|
1997
1930
|
}
|
|
1998
1931
|
),
|
|
1999
|
-
/* @__PURE__ */ jsxRuntime.jsxs("span", { className:
|
|
1932
|
+
/* @__PURE__ */ jsxRuntime.jsxs("span", { className: "slider-value", children: [
|
|
2000
1933
|
cornerRadius,
|
|
2001
1934
|
"px"
|
|
2002
1935
|
] })
|
|
2003
1936
|
] })
|
|
2004
1937
|
] }),
|
|
2005
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
2006
|
-
/* @__PURE__ */ jsxRuntime.jsx("label", { className:
|
|
2007
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
1938
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-section", children: [
|
|
1939
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-dark", children: "Fill Color" }),
|
|
1940
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "color-inputs", children: [
|
|
2008
1941
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2009
1942
|
"input",
|
|
2010
1943
|
{
|
|
2011
1944
|
type: "color",
|
|
2012
1945
|
value: fillColor,
|
|
2013
1946
|
onChange: (e) => setFillColor(e.target.value),
|
|
2014
|
-
className:
|
|
1947
|
+
className: "color-picker"
|
|
2015
1948
|
}
|
|
2016
1949
|
),
|
|
2017
1950
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2018
|
-
"
|
|
1951
|
+
"input",
|
|
2019
1952
|
{
|
|
2020
|
-
|
|
2021
|
-
|
|
1953
|
+
type: "text",
|
|
1954
|
+
value: fillColor,
|
|
1955
|
+
onChange: (e) => setFillColor(e.target.value),
|
|
1956
|
+
className: "color-text"
|
|
2022
1957
|
}
|
|
2023
1958
|
)
|
|
2024
1959
|
] })
|
|
2025
1960
|
] }),
|
|
2026
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
2027
|
-
/* @__PURE__ */ jsxRuntime.jsx("label", { className:
|
|
2028
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
1961
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-section", children: [
|
|
1962
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-dark", children: "Opacity" }),
|
|
1963
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "slider-container", children: [
|
|
2029
1964
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2030
1965
|
"input",
|
|
2031
1966
|
{
|
|
@@ -2034,39 +1969,41 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
2034
1969
|
max: "100",
|
|
2035
1970
|
value: opacity,
|
|
2036
1971
|
onChange: (e) => setOpacity(Number(e.target.value)),
|
|
2037
|
-
className:
|
|
1972
|
+
className: "slider-purple"
|
|
2038
1973
|
}
|
|
2039
1974
|
),
|
|
2040
|
-
/* @__PURE__ */ jsxRuntime.jsxs("span", { className:
|
|
1975
|
+
/* @__PURE__ */ jsxRuntime.jsxs("span", { className: "slider-value", children: [
|
|
2041
1976
|
opacity,
|
|
2042
1977
|
"%"
|
|
2043
1978
|
] })
|
|
2044
1979
|
] })
|
|
2045
1980
|
] }),
|
|
2046
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
2047
|
-
/* @__PURE__ */ jsxRuntime.jsx("label", { className:
|
|
2048
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
1981
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-section", children: [
|
|
1982
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-dark", children: "Stroke Color" }),
|
|
1983
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "color-inputs", children: [
|
|
2049
1984
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2050
1985
|
"input",
|
|
2051
1986
|
{
|
|
2052
1987
|
type: "color",
|
|
2053
1988
|
value: strokeColor,
|
|
2054
1989
|
onChange: (e) => setStrokeColor(e.target.value),
|
|
2055
|
-
className:
|
|
1990
|
+
className: "color-picker"
|
|
2056
1991
|
}
|
|
2057
1992
|
),
|
|
2058
1993
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2059
|
-
"
|
|
1994
|
+
"input",
|
|
2060
1995
|
{
|
|
2061
|
-
|
|
2062
|
-
|
|
1996
|
+
type: "text",
|
|
1997
|
+
value: strokeColor,
|
|
1998
|
+
onChange: (e) => setStrokeColor(e.target.value),
|
|
1999
|
+
className: "color-text"
|
|
2063
2000
|
}
|
|
2064
2001
|
)
|
|
2065
2002
|
] })
|
|
2066
2003
|
] }),
|
|
2067
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
2068
|
-
/* @__PURE__ */ jsxRuntime.jsx("label", { className:
|
|
2069
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
2004
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-section", children: [
|
|
2005
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-dark", children: "Line Width" }),
|
|
2006
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "slider-container", children: [
|
|
2070
2007
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2071
2008
|
"input",
|
|
2072
2009
|
{
|
|
@@ -2075,21 +2012,21 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
2075
2012
|
max: "20",
|
|
2076
2013
|
value: lineWidth,
|
|
2077
2014
|
onChange: (e) => setLineWidth(Number(e.target.value)),
|
|
2078
|
-
className:
|
|
2015
|
+
className: "slider-purple"
|
|
2079
2016
|
}
|
|
2080
2017
|
),
|
|
2081
|
-
/* @__PURE__ */ jsxRuntime.jsxs("span", { className:
|
|
2018
|
+
/* @__PURE__ */ jsxRuntime.jsxs("span", { className: "slider-value", children: [
|
|
2082
2019
|
lineWidth,
|
|
2083
2020
|
"px"
|
|
2084
2021
|
] })
|
|
2085
2022
|
] })
|
|
2086
2023
|
] }),
|
|
2087
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "
|
|
2024
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex panel-section", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
2088
2025
|
"button",
|
|
2089
2026
|
{
|
|
2090
2027
|
onClick: handleApplyChanges,
|
|
2091
|
-
className:
|
|
2092
|
-
children:
|
|
2028
|
+
className: "btn-primary w-full",
|
|
2029
|
+
children: operation
|
|
2093
2030
|
}
|
|
2094
2031
|
) })
|
|
2095
2032
|
] });
|
|
@@ -2140,6 +2077,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
2140
2077
|
opacity,
|
|
2141
2078
|
strokeColor,
|
|
2142
2079
|
lineWidth,
|
|
2080
|
+
operation: selectedElement instanceof timeline.RectElement ? "Apply Changes" : "Add Rectangle",
|
|
2143
2081
|
setCornerRadius,
|
|
2144
2082
|
setFillColor,
|
|
2145
2083
|
setOpacity,
|
|
@@ -2162,6 +2100,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
2162
2100
|
opacity,
|
|
2163
2101
|
strokeColor,
|
|
2164
2102
|
lineWidth,
|
|
2103
|
+
operation,
|
|
2165
2104
|
setRadius,
|
|
2166
2105
|
setFillColor,
|
|
2167
2106
|
setOpacity,
|
|
@@ -2169,11 +2108,11 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
2169
2108
|
setLineWidth,
|
|
2170
2109
|
handleApplyChanges
|
|
2171
2110
|
}) {
|
|
2172
|
-
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
2173
|
-
/* @__PURE__ */ jsxRuntime.jsx("
|
|
2174
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
2175
|
-
/* @__PURE__ */ jsxRuntime.jsx("label", { className:
|
|
2176
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
2111
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-container", children: [
|
|
2112
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "panel-title", children: "Circle" }),
|
|
2113
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-section", children: [
|
|
2114
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-dark", children: "Radius" }),
|
|
2115
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "slider-container", children: [
|
|
2177
2116
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2178
2117
|
"input",
|
|
2179
2118
|
{
|
|
@@ -2182,39 +2121,41 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
2182
2121
|
max: "300",
|
|
2183
2122
|
value: radius,
|
|
2184
2123
|
onChange: (e) => setRadius(Number(e.target.value)),
|
|
2185
|
-
className:
|
|
2124
|
+
className: "slider-purple"
|
|
2186
2125
|
}
|
|
2187
2126
|
),
|
|
2188
|
-
/* @__PURE__ */ jsxRuntime.jsxs("span", { className:
|
|
2127
|
+
/* @__PURE__ */ jsxRuntime.jsxs("span", { className: "slider-value", children: [
|
|
2189
2128
|
radius,
|
|
2190
2129
|
"px"
|
|
2191
2130
|
] })
|
|
2192
2131
|
] })
|
|
2193
2132
|
] }),
|
|
2194
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
2195
|
-
/* @__PURE__ */ jsxRuntime.jsx("label", { className:
|
|
2196
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
2133
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-section", children: [
|
|
2134
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-dark", children: "Fill Color" }),
|
|
2135
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "color-inputs", children: [
|
|
2197
2136
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2198
2137
|
"input",
|
|
2199
2138
|
{
|
|
2200
2139
|
type: "color",
|
|
2201
2140
|
value: fillColor,
|
|
2202
2141
|
onChange: (e) => setFillColor(e.target.value),
|
|
2203
|
-
className:
|
|
2142
|
+
className: "color-picker"
|
|
2204
2143
|
}
|
|
2205
2144
|
),
|
|
2206
2145
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2207
|
-
"
|
|
2146
|
+
"input",
|
|
2208
2147
|
{
|
|
2209
|
-
|
|
2210
|
-
|
|
2148
|
+
type: "text",
|
|
2149
|
+
value: fillColor,
|
|
2150
|
+
onChange: (e) => setFillColor(e.target.value),
|
|
2151
|
+
className: "color-text"
|
|
2211
2152
|
}
|
|
2212
2153
|
)
|
|
2213
2154
|
] })
|
|
2214
2155
|
] }),
|
|
2215
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
2216
|
-
/* @__PURE__ */ jsxRuntime.jsx("label", { className:
|
|
2217
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
2156
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-section", children: [
|
|
2157
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-dark", children: "Opacity" }),
|
|
2158
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "slider-container", children: [
|
|
2218
2159
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2219
2160
|
"input",
|
|
2220
2161
|
{
|
|
@@ -2223,39 +2164,41 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
2223
2164
|
max: "100",
|
|
2224
2165
|
value: opacity,
|
|
2225
2166
|
onChange: (e) => setOpacity(Number(e.target.value)),
|
|
2226
|
-
className:
|
|
2167
|
+
className: "slider-purple"
|
|
2227
2168
|
}
|
|
2228
2169
|
),
|
|
2229
|
-
/* @__PURE__ */ jsxRuntime.jsxs("span", { className:
|
|
2170
|
+
/* @__PURE__ */ jsxRuntime.jsxs("span", { className: "slider-value", children: [
|
|
2230
2171
|
opacity,
|
|
2231
2172
|
"%"
|
|
2232
2173
|
] })
|
|
2233
2174
|
] })
|
|
2234
2175
|
] }),
|
|
2235
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
2236
|
-
/* @__PURE__ */ jsxRuntime.jsx("label", { className:
|
|
2237
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
2176
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-section", children: [
|
|
2177
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-dark", children: "Stroke Color" }),
|
|
2178
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "color-inputs", children: [
|
|
2238
2179
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2239
2180
|
"input",
|
|
2240
2181
|
{
|
|
2241
2182
|
type: "color",
|
|
2242
2183
|
value: strokeColor,
|
|
2243
2184
|
onChange: (e) => setStrokeColor(e.target.value),
|
|
2244
|
-
className:
|
|
2185
|
+
className: "color-picker"
|
|
2245
2186
|
}
|
|
2246
2187
|
),
|
|
2247
2188
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2248
|
-
"
|
|
2189
|
+
"input",
|
|
2249
2190
|
{
|
|
2250
|
-
|
|
2251
|
-
|
|
2191
|
+
type: "text",
|
|
2192
|
+
value: strokeColor,
|
|
2193
|
+
onChange: (e) => setStrokeColor(e.target.value),
|
|
2194
|
+
className: "color-text"
|
|
2252
2195
|
}
|
|
2253
2196
|
)
|
|
2254
2197
|
] })
|
|
2255
2198
|
] }),
|
|
2256
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
2257
|
-
/* @__PURE__ */ jsxRuntime.jsx("label", { className:
|
|
2258
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
2199
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-section", children: [
|
|
2200
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-dark", children: "Line Width" }),
|
|
2201
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "slider-container", children: [
|
|
2259
2202
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2260
2203
|
"input",
|
|
2261
2204
|
{
|
|
@@ -2264,23 +2207,16 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
2264
2207
|
max: "20",
|
|
2265
2208
|
value: lineWidth,
|
|
2266
2209
|
onChange: (e) => setLineWidth(Number(e.target.value)),
|
|
2267
|
-
className:
|
|
2210
|
+
className: "slider-purple"
|
|
2268
2211
|
}
|
|
2269
2212
|
),
|
|
2270
|
-
/* @__PURE__ */ jsxRuntime.jsxs("span", { className:
|
|
2213
|
+
/* @__PURE__ */ jsxRuntime.jsxs("span", { className: "slider-value", children: [
|
|
2271
2214
|
lineWidth,
|
|
2272
2215
|
"px"
|
|
2273
2216
|
] })
|
|
2274
2217
|
] })
|
|
2275
2218
|
] }),
|
|
2276
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "
|
|
2277
|
-
"button",
|
|
2278
|
-
{
|
|
2279
|
-
onClick: handleApplyChanges,
|
|
2280
|
-
className: inputStyles.button.primary,
|
|
2281
|
-
children: "Apply Changes"
|
|
2282
|
-
}
|
|
2283
|
-
) })
|
|
2219
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex panel-section", children: /* @__PURE__ */ jsxRuntime.jsx("button", { onClick: handleApplyChanges, className: "btn-primary w-full", children: operation }) })
|
|
2284
2220
|
] });
|
|
2285
2221
|
}
|
|
2286
2222
|
const DEFAULT_CIRCLE_PROPS = {
|
|
@@ -2330,6 +2266,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
2330
2266
|
opacity,
|
|
2331
2267
|
strokeColor,
|
|
2332
2268
|
lineWidth,
|
|
2269
|
+
operation: selectedElement instanceof timeline.CircleElement ? "Apply Changes" : "Add Circle",
|
|
2333
2270
|
setRadius,
|
|
2334
2271
|
setFillColor,
|
|
2335
2272
|
setOpacity,
|
|
@@ -2434,9 +2371,9 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
2434
2371
|
case "subtitle":
|
|
2435
2372
|
return /* @__PURE__ */ jsxRuntime.jsx(SubtitlesPanel, {});
|
|
2436
2373
|
default:
|
|
2437
|
-
return /* @__PURE__ */ jsxRuntime.jsx("div", { className:
|
|
2438
|
-
/* @__PURE__ */ jsxRuntime.jsx(WandSparkles, { className: "
|
|
2439
|
-
/* @__PURE__ */ jsxRuntime.jsx("p", { className:
|
|
2374
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "panel-container", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "empty-state", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "empty-state-content", children: [
|
|
2375
|
+
/* @__PURE__ */ jsxRuntime.jsx(WandSparkles, { className: "empty-state-icon" }),
|
|
2376
|
+
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "empty-state-text", children: "Select a Tool to Begin" })
|
|
2440
2377
|
] }) }) });
|
|
2441
2378
|
}
|
|
2442
2379
|
};
|
|
@@ -2559,23 +2496,25 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
2559
2496
|
}
|
|
2560
2497
|
return sections;
|
|
2561
2498
|
}, [selectedElement]);
|
|
2562
|
-
|
|
2563
|
-
|
|
2564
|
-
|
|
2565
|
-
|
|
2499
|
+
react.useEffect(() => {
|
|
2500
|
+
if (availableSections == null ? void 0 : availableSections.length) {
|
|
2501
|
+
if (availableSections.map((section) => section.id).indexOf(selectedProp) === -1) {
|
|
2502
|
+
setSelectedProp(availableSections[0].id);
|
|
2503
|
+
}
|
|
2504
|
+
}
|
|
2505
|
+
}, [availableSections]);
|
|
2506
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "sidebar", children: availableSections.map((tool) => {
|
|
2566
2507
|
const Icon2 = getIcon(tool.icon);
|
|
2567
2508
|
const isSelected = selectedProp === tool.id;
|
|
2568
2509
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2569
|
-
"
|
|
2510
|
+
"div",
|
|
2570
2511
|
{
|
|
2571
2512
|
onClick: () => setSelectedProp(tool.id),
|
|
2572
|
-
className: `
|
|
2573
|
-
props-toolbar-btn group ${isSelected ? "active" : ""}
|
|
2574
|
-
`,
|
|
2513
|
+
className: `toolbar-btn ${isSelected ? "active" : ""}`,
|
|
2575
2514
|
title: `${tool.name}${tool.shortcut ? ` (${tool.shortcut})` : ""}`,
|
|
2576
2515
|
children: [
|
|
2577
|
-
/* @__PURE__ */ jsxRuntime.jsx(Icon2, { className: "
|
|
2578
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "
|
|
2516
|
+
/* @__PURE__ */ jsxRuntime.jsx(Icon2, { className: "icon-sm" }),
|
|
2517
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "props-toolbar-label", children: tool.name })
|
|
2579
2518
|
]
|
|
2580
2519
|
},
|
|
2581
2520
|
tool.id
|
|
@@ -2590,79 +2529,75 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
2590
2529
|
updateElement == null ? void 0 : updateElement(selectedElement == null ? void 0 : selectedElement.setProps({ ...elementProps, ...props }));
|
|
2591
2530
|
}
|
|
2592
2531
|
};
|
|
2593
|
-
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
2594
|
-
/* @__PURE__ */ jsxRuntime.
|
|
2595
|
-
|
|
2596
|
-
|
|
2597
|
-
|
|
2598
|
-
] }),
|
|
2599
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid grid-cols-2 gap-2", children: [
|
|
2532
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-container", children: [
|
|
2533
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "panel-title", children: "All Properties" }),
|
|
2534
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-section", children: [
|
|
2535
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-dark", children: "Position" }),
|
|
2536
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex-container", children: [
|
|
2600
2537
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
2601
|
-
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "
|
|
2538
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-small", children: "X" }),
|
|
2602
2539
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2603
2540
|
"input",
|
|
2604
2541
|
{
|
|
2605
2542
|
type: "number",
|
|
2606
2543
|
value: x ?? 0,
|
|
2607
2544
|
onChange: (e) => handleUpdateElement({ x: Number(e.target.value) }),
|
|
2608
|
-
className: "
|
|
2545
|
+
className: "input-dark"
|
|
2609
2546
|
}
|
|
2610
2547
|
)
|
|
2611
2548
|
] }),
|
|
2612
2549
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
2613
|
-
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "
|
|
2550
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-small", children: "Y" }),
|
|
2614
2551
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2615
2552
|
"input",
|
|
2616
2553
|
{
|
|
2617
2554
|
type: "number",
|
|
2618
2555
|
value: y ?? 0,
|
|
2619
2556
|
onChange: (e) => handleUpdateElement({ y: Number(e.target.value) }),
|
|
2620
|
-
className: "
|
|
2557
|
+
className: "input-dark"
|
|
2621
2558
|
}
|
|
2622
2559
|
)
|
|
2623
2560
|
] })
|
|
2624
2561
|
] })
|
|
2625
2562
|
] }),
|
|
2626
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
2627
|
-
/* @__PURE__ */ jsxRuntime.
|
|
2628
|
-
|
|
2629
|
-
|
|
2630
|
-
|
|
2631
|
-
|
|
2632
|
-
|
|
2633
|
-
|
|
2634
|
-
|
|
2635
|
-
|
|
2636
|
-
|
|
2637
|
-
|
|
2638
|
-
|
|
2639
|
-
|
|
2640
|
-
|
|
2641
|
-
|
|
2642
|
-
|
|
2643
|
-
|
|
2644
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { children: "100%" })
|
|
2563
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-section", children: [
|
|
2564
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-dark", children: "Opacity" }),
|
|
2565
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "slider-container", children: [
|
|
2566
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2567
|
+
"input",
|
|
2568
|
+
{
|
|
2569
|
+
type: "range",
|
|
2570
|
+
min: "0",
|
|
2571
|
+
max: "100",
|
|
2572
|
+
value: (opacity ?? 1) * 100,
|
|
2573
|
+
onChange: (e) => handleUpdateElement({ opacity: Number(e.target.value) / 100 }),
|
|
2574
|
+
className: "slider-purple"
|
|
2575
|
+
}
|
|
2576
|
+
),
|
|
2577
|
+
/* @__PURE__ */ jsxRuntime.jsxs("span", { className: "slider-value", children: [
|
|
2578
|
+
Math.round((opacity ?? 1) * 100),
|
|
2579
|
+
"%"
|
|
2580
|
+
] })
|
|
2645
2581
|
] })
|
|
2646
2582
|
] }),
|
|
2647
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
2648
|
-
/* @__PURE__ */ jsxRuntime.
|
|
2649
|
-
|
|
2650
|
-
|
|
2651
|
-
|
|
2652
|
-
|
|
2653
|
-
|
|
2654
|
-
|
|
2655
|
-
|
|
2656
|
-
|
|
2657
|
-
|
|
2658
|
-
|
|
2659
|
-
|
|
2660
|
-
|
|
2661
|
-
|
|
2662
|
-
|
|
2663
|
-
|
|
2664
|
-
|
|
2665
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { children: "360°" })
|
|
2583
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-section", children: [
|
|
2584
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-dark", children: "Rotation" }),
|
|
2585
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "slider-container", children: [
|
|
2586
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2587
|
+
"input",
|
|
2588
|
+
{
|
|
2589
|
+
type: "range",
|
|
2590
|
+
min: "0",
|
|
2591
|
+
max: "360",
|
|
2592
|
+
value: rotation ?? 0,
|
|
2593
|
+
onChange: (e) => handleUpdateElement({ rotation: Number(e.target.value) }),
|
|
2594
|
+
className: "slider-purple"
|
|
2595
|
+
}
|
|
2596
|
+
),
|
|
2597
|
+
/* @__PURE__ */ jsxRuntime.jsxs("span", { className: "slider-value", children: [
|
|
2598
|
+
rotation ?? 0,
|
|
2599
|
+
"°"
|
|
2600
|
+
] })
|
|
2666
2601
|
] })
|
|
2667
2602
|
] })
|
|
2668
2603
|
] });
|
|
@@ -2695,18 +2630,16 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
2695
2630
|
selectedElement.setTextEffect(effect);
|
|
2696
2631
|
updateElement == null ? void 0 : updateElement(selectedElement);
|
|
2697
2632
|
};
|
|
2698
|
-
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
2699
|
-
/* @__PURE__ */ jsxRuntime.
|
|
2700
|
-
|
|
2701
|
-
|
|
2702
|
-
"Text Effect Type"
|
|
2703
|
-
] }),
|
|
2633
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-container", children: [
|
|
2634
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "panel-title", children: "Text Effects" }),
|
|
2635
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-section", children: [
|
|
2636
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-dark", children: "Text Effect Type" }),
|
|
2704
2637
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
2705
2638
|
"select",
|
|
2706
2639
|
{
|
|
2707
2640
|
value: (currentEffect == null ? void 0 : currentEffect.getName()) || "",
|
|
2708
2641
|
onChange: (e) => handleUpdateEffect({ name: e.target.value }),
|
|
2709
|
-
className: "w-full
|
|
2642
|
+
className: "select-dark w-full",
|
|
2710
2643
|
children: [
|
|
2711
2644
|
/* @__PURE__ */ jsxRuntime.jsx("option", { value: "", children: "No Effect" }),
|
|
2712
2645
|
VideoEditor.TEXT_EFFECTS.map((effect) => /* @__PURE__ */ jsxRuntime.jsx("option", { value: effect.name, children: effect.name.charAt(0).toUpperCase() + effect.name.slice(1) }, effect.name))
|
|
@@ -2714,57 +2647,51 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
2714
2647
|
}
|
|
2715
2648
|
)
|
|
2716
2649
|
] }),
|
|
2717
|
-
currentEffect && /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2718
|
-
/* @__PURE__ */ jsxRuntime.jsxs("
|
|
2719
|
-
/* @__PURE__ */ jsxRuntime.jsx("
|
|
2720
|
-
|
|
2650
|
+
currentEffect && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
2651
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-section", children: [
|
|
2652
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-dark", children: "Delay (seconds)" }),
|
|
2653
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2654
|
+
"input",
|
|
2655
|
+
{
|
|
2656
|
+
type: "number",
|
|
2657
|
+
min: "0",
|
|
2658
|
+
max: "5",
|
|
2659
|
+
step: "0.1",
|
|
2660
|
+
value: currentEffect.getDelay() ?? 0,
|
|
2661
|
+
onChange: (e) => handleUpdateEffect({ delay: Number(e.target.value) }),
|
|
2662
|
+
className: "input-dark"
|
|
2663
|
+
}
|
|
2664
|
+
)
|
|
2721
2665
|
] }),
|
|
2722
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
2723
|
-
/* @__PURE__ */ jsxRuntime.
|
|
2724
|
-
|
|
2725
|
-
|
|
2726
|
-
|
|
2727
|
-
|
|
2728
|
-
|
|
2729
|
-
|
|
2730
|
-
|
|
2731
|
-
|
|
2732
|
-
|
|
2733
|
-
|
|
2734
|
-
|
|
2735
|
-
|
|
2736
|
-
|
|
2737
|
-
|
|
2738
|
-
/* @__PURE__ */ jsxRuntime.
|
|
2739
|
-
|
|
2740
|
-
|
|
2741
|
-
|
|
2742
|
-
|
|
2743
|
-
|
|
2744
|
-
|
|
2745
|
-
|
|
2746
|
-
|
|
2747
|
-
|
|
2748
|
-
|
|
2749
|
-
|
|
2750
|
-
|
|
2751
|
-
)
|
|
2752
|
-
] }),
|
|
2753
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
2754
|
-
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "block text-xs text-gray-400 mb-1", children: "Buffer Time (seconds)" }),
|
|
2755
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2756
|
-
"input",
|
|
2757
|
-
{
|
|
2758
|
-
type: "number",
|
|
2759
|
-
min: "0.05",
|
|
2760
|
-
max: "1",
|
|
2761
|
-
step: "0.05",
|
|
2762
|
-
value: currentEffect.getBufferTime() ?? 0.1,
|
|
2763
|
-
onChange: (e) => handleUpdateEffect({ bufferTime: Number(e.target.value) }),
|
|
2764
|
-
className: "w-full bg-neutral-700/60 border border-gray-600/40 rounded-md text-white text-xs px-2 py-1.5 focus:border-purple-500 focus:outline-none focus:ring-1 focus:ring-purple-500/30 transition-all duration-200"
|
|
2765
|
-
}
|
|
2766
|
-
)
|
|
2767
|
-
] })
|
|
2666
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-section", children: [
|
|
2667
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-dark", children: "Duration (seconds)" }),
|
|
2668
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2669
|
+
"input",
|
|
2670
|
+
{
|
|
2671
|
+
type: "number",
|
|
2672
|
+
min: "0.1",
|
|
2673
|
+
max: "10",
|
|
2674
|
+
step: "0.1",
|
|
2675
|
+
value: currentEffect.getDuration() ?? 1,
|
|
2676
|
+
onChange: (e) => handleUpdateEffect({ duration: Number(e.target.value) }),
|
|
2677
|
+
className: "input-dark"
|
|
2678
|
+
}
|
|
2679
|
+
)
|
|
2680
|
+
] }),
|
|
2681
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-section", children: [
|
|
2682
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-dark", children: "Buffer Time (seconds)" }),
|
|
2683
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2684
|
+
"input",
|
|
2685
|
+
{
|
|
2686
|
+
type: "number",
|
|
2687
|
+
min: "0.05",
|
|
2688
|
+
max: "1",
|
|
2689
|
+
step: "0.05",
|
|
2690
|
+
value: currentEffect.getBufferTime() ?? 0.1,
|
|
2691
|
+
onChange: (e) => handleUpdateEffect({ bufferTime: Number(e.target.value) }),
|
|
2692
|
+
className: "input-dark"
|
|
2693
|
+
}
|
|
2694
|
+
)
|
|
2768
2695
|
] })
|
|
2769
2696
|
] })
|
|
2770
2697
|
] });
|
|
@@ -2824,18 +2751,16 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
2824
2751
|
selectedElement.setAnimation(animation);
|
|
2825
2752
|
updateElement == null ? void 0 : updateElement(selectedElement);
|
|
2826
2753
|
};
|
|
2827
|
-
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
2828
|
-
/* @__PURE__ */ jsxRuntime.
|
|
2829
|
-
|
|
2830
|
-
|
|
2831
|
-
"Animation Type"
|
|
2832
|
-
] }),
|
|
2754
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-container", children: [
|
|
2755
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "panel-title", children: "Animations" }),
|
|
2756
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-section", children: [
|
|
2757
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-dark", children: "Type" }),
|
|
2833
2758
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
2834
2759
|
"select",
|
|
2835
2760
|
{
|
|
2836
2761
|
value: (currentAnimation == null ? void 0 : currentAnimation.getName()) || "",
|
|
2837
2762
|
onChange: (e) => handleUpdateAnimation({ name: e.target.value }),
|
|
2838
|
-
className: "w-full
|
|
2763
|
+
className: "select-dark w-full",
|
|
2839
2764
|
children: [
|
|
2840
2765
|
/* @__PURE__ */ jsxRuntime.jsx("option", { value: "", children: "No Animation" }),
|
|
2841
2766
|
VideoEditor.ANIMATIONS.map((animation) => /* @__PURE__ */ jsxRuntime.jsx("option", { value: animation.name, children: animation.name.charAt(0).toUpperCase() + animation.name.slice(1) }, animation.name))
|
|
@@ -2843,66 +2768,62 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
2843
2768
|
}
|
|
2844
2769
|
)
|
|
2845
2770
|
] }),
|
|
2846
|
-
currentAnimation && /* @__PURE__ */ jsxRuntime.
|
|
2847
|
-
|
|
2848
|
-
|
|
2849
|
-
|
|
2850
|
-
|
|
2851
|
-
|
|
2852
|
-
|
|
2853
|
-
|
|
2854
|
-
|
|
2855
|
-
|
|
2856
|
-
|
|
2857
|
-
|
|
2858
|
-
|
|
2859
|
-
|
|
2860
|
-
|
|
2861
|
-
|
|
2862
|
-
|
|
2863
|
-
|
|
2864
|
-
|
|
2865
|
-
|
|
2866
|
-
|
|
2867
|
-
|
|
2868
|
-
|
|
2869
|
-
|
|
2870
|
-
|
|
2871
|
-
|
|
2872
|
-
|
|
2873
|
-
|
|
2874
|
-
|
|
2875
|
-
|
|
2876
|
-
|
|
2877
|
-
|
|
2878
|
-
|
|
2879
|
-
|
|
2880
|
-
|
|
2881
|
-
|
|
2882
|
-
|
|
2883
|
-
|
|
2884
|
-
|
|
2885
|
-
|
|
2886
|
-
|
|
2887
|
-
|
|
2888
|
-
|
|
2889
|
-
|
|
2890
|
-
|
|
2891
|
-
|
|
2892
|
-
|
|
2893
|
-
|
|
2894
|
-
|
|
2895
|
-
|
|
2896
|
-
|
|
2897
|
-
|
|
2898
|
-
)
|
|
2899
|
-
] }),
|
|
2900
|
-
((_g = animationDef.options) == null ? void 0 : _g.duration) && /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
2901
|
-
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "block text-xs text-gray-400 mb-1", children: "Duration (seconds)" }),
|
|
2771
|
+
currentAnimation && /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, { children: (() => {
|
|
2772
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o;
|
|
2773
|
+
const animationDef = VideoEditor.ANIMATIONS.find(
|
|
2774
|
+
(a) => a.name === currentAnimation.getName()
|
|
2775
|
+
);
|
|
2776
|
+
if (!animationDef || !animationDef.options) return null;
|
|
2777
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
2778
|
+
((_a = animationDef.options) == null ? void 0 : _a.animate) && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-section", children: [
|
|
2779
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-dark", children: "When to Animate" }),
|
|
2780
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2781
|
+
"select",
|
|
2782
|
+
{
|
|
2783
|
+
value: currentAnimation.getAnimate(),
|
|
2784
|
+
onChange: (e) => handleUpdateAnimation({
|
|
2785
|
+
animate: e.target.value
|
|
2786
|
+
}),
|
|
2787
|
+
className: "select-dark w-full",
|
|
2788
|
+
children: (_b = animationDef.options) == null ? void 0 : _b.animate.map((option) => /* @__PURE__ */ jsxRuntime.jsx("option", { value: option, children: option.charAt(0).toUpperCase() + option.slice(1) }, option))
|
|
2789
|
+
}
|
|
2790
|
+
)
|
|
2791
|
+
] }),
|
|
2792
|
+
((_c = animationDef.options) == null ? void 0 : _c.direction) && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-section", children: [
|
|
2793
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-dark", children: "Direction" }),
|
|
2794
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2795
|
+
"select",
|
|
2796
|
+
{
|
|
2797
|
+
value: currentAnimation.getDirection(),
|
|
2798
|
+
onChange: (e) => handleUpdateAnimation({
|
|
2799
|
+
direction: e.target.value
|
|
2800
|
+
}),
|
|
2801
|
+
className: "select-dark w-full",
|
|
2802
|
+
children: (_d = animationDef.options) == null ? void 0 : _d.direction.map((option) => /* @__PURE__ */ jsxRuntime.jsx("option", { value: option, children: option.charAt(0).toUpperCase() + option.slice(1) }, option))
|
|
2803
|
+
}
|
|
2804
|
+
)
|
|
2805
|
+
] }),
|
|
2806
|
+
((_e = animationDef.options) == null ? void 0 : _e.mode) && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-section", children: [
|
|
2807
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-dark", children: "Mode" }),
|
|
2808
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2809
|
+
"select",
|
|
2810
|
+
{
|
|
2811
|
+
value: currentAnimation.getMode(),
|
|
2812
|
+
onChange: (e) => handleUpdateAnimation({
|
|
2813
|
+
mode: e.target.value
|
|
2814
|
+
}),
|
|
2815
|
+
className: "select-dark w-full",
|
|
2816
|
+
children: (_f = animationDef.options) == null ? void 0 : _f.mode.map((option) => /* @__PURE__ */ jsxRuntime.jsx("option", { value: option, children: option.charAt(0).toUpperCase() + option.slice(1) }, option))
|
|
2817
|
+
}
|
|
2818
|
+
)
|
|
2819
|
+
] }),
|
|
2820
|
+
((_g = animationDef.options) == null ? void 0 : _g.duration) && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-section", children: [
|
|
2821
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-dark", children: "Duration (seconds)" }),
|
|
2822
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "slider-container", children: [
|
|
2902
2823
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2903
2824
|
"input",
|
|
2904
2825
|
{
|
|
2905
|
-
type: "
|
|
2826
|
+
type: "range",
|
|
2906
2827
|
min: (_h = animationDef.options) == null ? void 0 : _h.duration[0],
|
|
2907
2828
|
max: (_i = animationDef.options) == null ? void 0 : _i.duration[1],
|
|
2908
2829
|
step: "0.1",
|
|
@@ -2910,16 +2831,19 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
2910
2831
|
onChange: (e) => handleUpdateAnimation({
|
|
2911
2832
|
duration: Number(e.target.value)
|
|
2912
2833
|
}),
|
|
2913
|
-
className: "
|
|
2834
|
+
className: "slider-purple"
|
|
2914
2835
|
}
|
|
2915
|
-
)
|
|
2916
|
-
|
|
2917
|
-
|
|
2918
|
-
|
|
2836
|
+
),
|
|
2837
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "slider-value", children: currentAnimation.getDuration() })
|
|
2838
|
+
] })
|
|
2839
|
+
] }),
|
|
2840
|
+
((_j = animationDef.options) == null ? void 0 : _j.interval) && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-section", children: [
|
|
2841
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-dark", children: "Interval (seconds)" }),
|
|
2842
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "slider-container", children: [
|
|
2919
2843
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2920
2844
|
"input",
|
|
2921
2845
|
{
|
|
2922
|
-
type: "
|
|
2846
|
+
type: "range",
|
|
2923
2847
|
min: (_k = animationDef.options) == null ? void 0 : _k.interval[0],
|
|
2924
2848
|
max: (_l = animationDef.options) == null ? void 0 : _l.interval[1],
|
|
2925
2849
|
step: "0.1",
|
|
@@ -2927,16 +2851,19 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
2927
2851
|
onChange: (e) => handleUpdateAnimation({
|
|
2928
2852
|
interval: Number(e.target.value)
|
|
2929
2853
|
}),
|
|
2930
|
-
className: "
|
|
2854
|
+
className: "slider-purple"
|
|
2931
2855
|
}
|
|
2932
|
-
)
|
|
2933
|
-
|
|
2934
|
-
|
|
2935
|
-
|
|
2856
|
+
),
|
|
2857
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "slider-value", children: currentAnimation.getInterval() })
|
|
2858
|
+
] })
|
|
2859
|
+
] }),
|
|
2860
|
+
((_m = animationDef.options) == null ? void 0 : _m.intensity) && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-section", children: [
|
|
2861
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-dark", children: "Intensity" }),
|
|
2862
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "slider-container", children: [
|
|
2936
2863
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2937
2864
|
"input",
|
|
2938
2865
|
{
|
|
2939
|
-
type: "
|
|
2866
|
+
type: "range",
|
|
2940
2867
|
min: (_n = animationDef.options) == null ? void 0 : _n.intensity[0],
|
|
2941
2868
|
max: (_o = animationDef.options) == null ? void 0 : _o.intensity[1],
|
|
2942
2869
|
step: "0.1",
|
|
@@ -2944,13 +2871,14 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
2944
2871
|
onChange: (e) => handleUpdateAnimation({
|
|
2945
2872
|
intensity: Number(e.target.value)
|
|
2946
2873
|
}),
|
|
2947
|
-
className: "
|
|
2874
|
+
className: "slider-purple"
|
|
2948
2875
|
}
|
|
2949
|
-
)
|
|
2876
|
+
),
|
|
2877
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "slider-value", children: currentAnimation.getIntensity() })
|
|
2950
2878
|
] })
|
|
2951
|
-
] })
|
|
2952
|
-
|
|
2953
|
-
|
|
2879
|
+
] })
|
|
2880
|
+
] });
|
|
2881
|
+
})() })
|
|
2954
2882
|
] });
|
|
2955
2883
|
}
|
|
2956
2884
|
function PlaybackPropsPanel({
|
|
@@ -2964,42 +2892,26 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
2964
2892
|
updateElement == null ? void 0 : updateElement(selectedElement == null ? void 0 : selectedElement.setProps({ ...elementProps, ...props }));
|
|
2965
2893
|
}
|
|
2966
2894
|
};
|
|
2967
|
-
return /* @__PURE__ */ jsxRuntime.
|
|
2968
|
-
/* @__PURE__ */ jsxRuntime.
|
|
2969
|
-
|
|
2970
|
-
"Volume"
|
|
2971
|
-
|
|
2972
|
-
|
|
2973
|
-
|
|
2974
|
-
|
|
2975
|
-
|
|
2976
|
-
|
|
2977
|
-
|
|
2978
|
-
|
|
2979
|
-
|
|
2980
|
-
|
|
2981
|
-
|
|
2982
|
-
|
|
2983
|
-
|
|
2984
|
-
|
|
2985
|
-
|
|
2986
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { children: "3" })
|
|
2895
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-container", children: [
|
|
2896
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "panel-title", children: "Playback Properties" }),
|
|
2897
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "panel-section", children: [
|
|
2898
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "label-dark", children: "Volume" }),
|
|
2899
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "slider-container", children: [
|
|
2900
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2901
|
+
"input",
|
|
2902
|
+
{
|
|
2903
|
+
type: "range",
|
|
2904
|
+
min: "0",
|
|
2905
|
+
max: "3",
|
|
2906
|
+
step: 0.1,
|
|
2907
|
+
value: volume ?? 0,
|
|
2908
|
+
onChange: (e) => handleUpdateElement({ volume: Number(e.target.value) }),
|
|
2909
|
+
className: "slider-purple"
|
|
2910
|
+
}
|
|
2911
|
+
),
|
|
2912
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "slider-value", children: volume ?? 0 })
|
|
2913
|
+
] })
|
|
2987
2914
|
] })
|
|
2988
|
-
] }) });
|
|
2989
|
-
}
|
|
2990
|
-
function PropContainer({ title, icon, children }) {
|
|
2991
|
-
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "border-b border-gray-600/30 last:border-b-0 bg-gradient-to-b from-neutral-800/40 to-neutral-800/20 backdrop-blur-sm", children: [
|
|
2992
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full flex items-center justify-between px-3 py-2.5 text-left text-gray-200 hover:text-white hover:bg-gradient-to-r hover:from-purple-600/20 hover:to-purple-500/10 transition-all duration-200 rounded-none border-l-2 border-transparent hover:border-purple-500/50", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2.5", children: [
|
|
2993
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-purple-400/80", children: icon }),
|
|
2994
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "font-medium text-sm", children: title })
|
|
2995
|
-
] }) }),
|
|
2996
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2997
|
-
"div",
|
|
2998
|
-
{
|
|
2999
|
-
className: `overflow-x-hidden overflow-y-auto p-1 transition-all duration-300 ease-in-out`,
|
|
3000
|
-
children
|
|
3001
|
-
}
|
|
3002
|
-
)
|
|
3003
2915
|
] });
|
|
3004
2916
|
}
|
|
3005
2917
|
function PropertiesPanelContainer({
|
|
@@ -3008,58 +2920,37 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
3008
2920
|
updateElement
|
|
3009
2921
|
}) {
|
|
3010
2922
|
if (!selectedElement) {
|
|
3011
|
-
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "
|
|
2923
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "panel-container", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "properties-header", children: /* @__PURE__ */ jsxRuntime.jsx("h3", { className: "properties-title", children: "Select Element to see properties" }) }) });
|
|
3012
2924
|
}
|
|
3013
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2925
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
3014
2926
|
selectedProp === "element-props" && /* @__PURE__ */ jsxRuntime.jsx(
|
|
3015
|
-
|
|
2927
|
+
ElementProps,
|
|
3016
2928
|
{
|
|
3017
|
-
|
|
3018
|
-
|
|
3019
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
3020
|
-
ElementProps,
|
|
3021
|
-
{
|
|
3022
|
-
selectedElement,
|
|
3023
|
-
updateElement
|
|
3024
|
-
}
|
|
3025
|
-
)
|
|
2929
|
+
selectedElement,
|
|
2930
|
+
updateElement
|
|
3026
2931
|
}
|
|
3027
2932
|
),
|
|
3028
2933
|
selectedProp === "playback-props" && /* @__PURE__ */ jsxRuntime.jsx(
|
|
3029
|
-
|
|
2934
|
+
PlaybackPropsPanel,
|
|
3030
2935
|
{
|
|
3031
|
-
|
|
3032
|
-
|
|
3033
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
3034
|
-
PlaybackPropsPanel,
|
|
3035
|
-
{
|
|
3036
|
-
selectedElement,
|
|
3037
|
-
updateElement
|
|
3038
|
-
}
|
|
3039
|
-
)
|
|
2936
|
+
selectedElement,
|
|
2937
|
+
updateElement
|
|
3040
2938
|
}
|
|
3041
2939
|
),
|
|
3042
2940
|
selectedProp === "text-effects" && /* @__PURE__ */ jsxRuntime.jsx(
|
|
3043
|
-
|
|
2941
|
+
TextEffects,
|
|
3044
2942
|
{
|
|
3045
|
-
|
|
3046
|
-
|
|
3047
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
3048
|
-
TextEffects,
|
|
3049
|
-
{
|
|
3050
|
-
selectedElement,
|
|
3051
|
-
updateElement
|
|
3052
|
-
}
|
|
3053
|
-
)
|
|
2943
|
+
selectedElement,
|
|
2944
|
+
updateElement
|
|
3054
2945
|
}
|
|
3055
2946
|
),
|
|
3056
|
-
selectedProp === "animations" && /* @__PURE__ */ jsxRuntime.jsx(
|
|
2947
|
+
selectedProp === "animations" && /* @__PURE__ */ jsxRuntime.jsx(
|
|
3057
2948
|
Animation,
|
|
3058
2949
|
{
|
|
3059
2950
|
selectedElement,
|
|
3060
2951
|
updateElement
|
|
3061
2952
|
}
|
|
3062
|
-
)
|
|
2953
|
+
)
|
|
3063
2954
|
] });
|
|
3064
2955
|
}
|
|
3065
2956
|
const loadFile = (accept) => {
|
|
@@ -3178,7 +3069,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
3178
3069
|
}),
|
|
3179
3070
|
[videoResolution, studioConfig]
|
|
3180
3071
|
);
|
|
3181
|
-
return /* @__PURE__ */ jsxRuntime.jsx(MediaProvider, { children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
3072
|
+
return /* @__PURE__ */ jsxRuntime.jsx(MediaProvider, { children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "studio-container", children: [
|
|
3182
3073
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
3183
3074
|
StudioHeader,
|
|
3184
3075
|
{
|
|
@@ -3188,7 +3079,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
3188
3079
|
onExportVideo
|
|
3189
3080
|
}
|
|
3190
3081
|
),
|
|
3191
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
3082
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "studio-content", children: [
|
|
3192
3083
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
3193
3084
|
Toolbar,
|
|
3194
3085
|
{
|
|
@@ -3196,7 +3087,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
3196
3087
|
setSelectedTool
|
|
3197
3088
|
}
|
|
3198
3089
|
),
|
|
3199
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
3090
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
3200
3091
|
ElementPanelContainer,
|
|
3201
3092
|
{
|
|
3202
3093
|
videoResolution,
|
|
@@ -3206,8 +3097,8 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
3206
3097
|
addElement,
|
|
3207
3098
|
updateElement
|
|
3208
3099
|
}
|
|
3209
|
-
)
|
|
3210
|
-
/* @__PURE__ */ jsxRuntime.jsx("main", { className: "
|
|
3100
|
+
),
|
|
3101
|
+
/* @__PURE__ */ jsxRuntime.jsx("main", { className: "main-container", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "canvas-wrapper", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
3211
3102
|
"div",
|
|
3212
3103
|
{
|
|
3213
3104
|
className: "canvas-container",
|
|
@@ -3217,14 +3108,14 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
3217
3108
|
children: /* @__PURE__ */ jsxRuntime.jsx(VideoEditor, { editorConfig: twickStudiConfig })
|
|
3218
3109
|
}
|
|
3219
3110
|
) }) }),
|
|
3220
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
3111
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
3221
3112
|
PropertiesPanelContainer,
|
|
3222
3113
|
{
|
|
3223
3114
|
selectedProp,
|
|
3224
3115
|
selectedElement,
|
|
3225
3116
|
updateElement
|
|
3226
3117
|
}
|
|
3227
|
-
)
|
|
3118
|
+
),
|
|
3228
3119
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
3229
3120
|
PropsToolbar,
|
|
3230
3121
|
{
|