forked from 77media/video-flow
edit modal交互
This commit is contained in:
parent
cd0cb015df
commit
3ccc6e44a5
@ -235,7 +235,7 @@ export function EditModal({
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
{/* 底部操作栏 */}
|
{/* 底部操作栏 */}
|
||||||
{/* <div className="p-4 border-t border-white/10 bg-black/20">
|
<div className="p-4 border-t border-white/10 bg-black/20">
|
||||||
<div className="flex justify-end gap-3">
|
<div className="flex justify-end gap-3">
|
||||||
<motion.button
|
<motion.button
|
||||||
className="px-4 py-2 rounded-lg bg-white/10 text-white hover:bg-white/20 transition-colors"
|
className="px-4 py-2 rounded-lg bg-white/10 text-white hover:bg-white/20 transition-colors"
|
||||||
@ -253,7 +253,7 @@ export function EditModal({
|
|||||||
Save
|
Save
|
||||||
</motion.button>
|
</motion.button>
|
||||||
</div>
|
</div>
|
||||||
</div> */}
|
</div>
|
||||||
</motion.div>
|
</motion.div>
|
||||||
</div>
|
</div>
|
||||||
</>
|
</>
|
||||||
|
|||||||
@ -43,7 +43,7 @@ export function CharacterToken(props: ReactNodeViewProps) {
|
|||||||
animate={{ opacity: 1, y: 0 }}
|
animate={{ opacity: 1, y: 0 }}
|
||||||
exit={{ opacity: 0, y: 4 }}
|
exit={{ opacity: 0, y: 4 }}
|
||||||
transition={{ duration: 0.2 }}
|
transition={{ duration: 0.2 }}
|
||||||
className="absolute top-full left-0 mt-2 w-64 rounded-lg bg-gray-900 border border-gray-800 shadow-2xl p-4 z-50"
|
className="absolute top-full left-0 mt-2 w-64 rounded-lg backdrop-blur-md bg-white/10 border border-white/20 p-4 z-50"
|
||||||
>
|
>
|
||||||
<div className="flex items-center gap-3">
|
<div className="flex items-center gap-3">
|
||||||
<img
|
<img
|
||||||
|
|||||||
@ -121,6 +121,12 @@ export function ShotTabContent({
|
|||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
// 切换选择分镜
|
||||||
|
const handleSelectShot = (index: number) => {
|
||||||
|
// 切换前 判断数据是否发生变化
|
||||||
|
onSketchSelect(index);
|
||||||
|
};
|
||||||
|
|
||||||
// 如果没有数据,显示空状态
|
// 如果没有数据,显示空状态
|
||||||
if (sketches.length === 0) {
|
if (sketches.length === 0) {
|
||||||
return (
|
return (
|
||||||
@ -143,7 +149,7 @@ export function ShotTabContent({
|
|||||||
itemWidth={128}
|
itemWidth={128}
|
||||||
gap={0}
|
gap={0}
|
||||||
selectedIndex={currentSketchIndex}
|
selectedIndex={currentSketchIndex}
|
||||||
onItemClick={(i: number) => onSketchSelect(i)}
|
onItemClick={(i: number) => handleSelectShot(i)}
|
||||||
>
|
>
|
||||||
{sketches.map((sketch, index) => (
|
{sketches.map((sketch, index) => (
|
||||||
<motion.div
|
<motion.div
|
||||||
@ -187,7 +193,7 @@ export function ShotTabContent({
|
|||||||
itemWidth={'auto'}
|
itemWidth={'auto'}
|
||||||
gap={0}
|
gap={0}
|
||||||
selectedIndex={currentSketchIndex}
|
selectedIndex={currentSketchIndex}
|
||||||
onItemClick={(i: number) => onSketchSelect(i)}
|
onItemClick={(i: number) => handleSelectShot(i)}
|
||||||
>
|
>
|
||||||
{sketches.map((video, index) => {
|
{sketches.map((video, index) => {
|
||||||
const isActive = currentSketchIndex === index;
|
const isActive = currentSketchIndex === index;
|
||||||
@ -198,7 +204,6 @@ export function ShotTabContent({
|
|||||||
'flex-shrink-0 cursor-pointer transition-all duration-300',
|
'flex-shrink-0 cursor-pointer transition-all duration-300',
|
||||||
isActive ? 'text-white' : 'text-white/50 hover:text-white/80'
|
isActive ? 'text-white' : 'text-white/50 hover:text-white/80'
|
||||||
)}
|
)}
|
||||||
onClick={() => onSketchSelect(index)}
|
|
||||||
initial={false}
|
initial={false}
|
||||||
animate={{
|
animate={{
|
||||||
scale: isActive ? 1.02 : 1,
|
scale: isActive ? 1.02 : 1,
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user