fix: update editor delete animations
This commit is contained in:
@@ -530,14 +530,14 @@ export function TableEditor({
|
|||||||
show={deleteDiag}
|
show={deleteDiag}
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
<div className="w-full overflow-hidden my-1 flex flex-col gap-3">
|
<div className="w-full overflow-hidden my-1 flex flex-col gap-3 pb-40">
|
||||||
<div className="flex gap-2 flex-wrap">
|
<div className="flex gap-2 flex-wrap">
|
||||||
<DengiButton onClick={handleUndo} disabled={undoItems.length == 0}>
|
<DengiButton onClick={handleUndo} disabled={undoItems.length == 0}>
|
||||||
<BiUndo />
|
<BiUndo />
|
||||||
</DengiButton>
|
</DengiButton>
|
||||||
<DengiButton onClick={handleRedo} disabled={redoItems.length == 0}>
|
<DengiButton onClick={handleRedo} disabled={redoItems.length == 0}>
|
||||||
<BiRedo />
|
<BiRedo />
|
||||||
</DengiButton>
|
</DengiButton>
|
||||||
<AnimatePresence mode="popLayout">
|
<AnimatePresence mode="popLayout">
|
||||||
{selectedTab == 0 && (
|
{selectedTab == 0 && (
|
||||||
<motion.div exit={{ opacity: 0 }}>
|
<motion.div exit={{ opacity: 0 }}>
|
||||||
@@ -601,10 +601,10 @@ export function TableEditor({
|
|||||||
<SortableContext
|
<SortableContext
|
||||||
items={items.map((item) => item.id)}
|
items={items.map((item) => item.id)}
|
||||||
strategy={verticalListSortingStrategy}
|
strategy={verticalListSortingStrategy}
|
||||||
>
|
>
|
||||||
<div>
|
<div>
|
||||||
<AnimatePresence mode={items.length > 0 ? "sync" : "wait"}>
|
<AnimatePresence mode="popLayout">
|
||||||
{items.map((item) => (
|
{items.map((item, idx) => (
|
||||||
<motion.div
|
<motion.div
|
||||||
initial={{
|
initial={{
|
||||||
x: -15,
|
x: -15,
|
||||||
@@ -632,12 +632,10 @@ export function TableEditor({
|
|||||||
initial={{
|
initial={{
|
||||||
filter: "blur(5px)",
|
filter: "blur(5px)",
|
||||||
opacity: 0,
|
opacity: 0,
|
||||||
scale: 0.8,
|
|
||||||
}}
|
}}
|
||||||
animate={{
|
animate={{
|
||||||
filter: "blur(0px)",
|
filter: "blur(0px)",
|
||||||
opacity: 1,
|
opacity: 1,
|
||||||
scale: 1,
|
|
||||||
}}
|
}}
|
||||||
className={`border-2 border-dashed ${
|
className={`border-2 border-dashed ${
|
||||||
pickmeMode ? "border-pink-700" : "border-gray-700"
|
pickmeMode ? "border-pink-700" : "border-gray-700"
|
||||||
@@ -658,7 +656,7 @@ export function TableEditor({
|
|||||||
<LoadingSpinner size={35} />
|
<LoadingSpinner size={35} />
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
<motion.div className="flex w-full justify-end gap-2 fixed pr-20 bottom-2 left-0">
|
<motion.div layout="position" className="flex w-full justify-end gap-2">
|
||||||
<DengiButton
|
<DengiButton
|
||||||
onClick={handleDeleteAll}
|
onClick={handleDeleteAll}
|
||||||
className="border-red-600! md:not-disabled:not-hover:border-red-400!"
|
className="border-red-600! md:not-disabled:not-hover:border-red-400!"
|
||||||
|
|||||||
Reference in New Issue
Block a user