fix: fixed issue that caused items dropped to mobile disappear

This commit is contained in:
Johnson Cherian 2023-12-21 11:51:00 +05:30
parent 4dfe3bae4c
commit f17244c346

View file

@ -78,10 +78,10 @@ export default function DragContainer({
const childMoveableRefs = useRef([]);
const [movableTargets, setMovableTargets] = useState({});
const boxList = boxes
.filter(
(box) =>
box?.component?.definition?.others[currentLayout === 'mobile' ? 'showOnMobile' : 'showOnDesktop'].value ===
'{{true}}'
.filter((box) =>
['{{true}}', true].includes(
box?.component?.definition?.others[currentLayout === 'mobile' ? 'showOnMobile' : 'showOnDesktop'].value
)
)
.map((box) => ({
id: box.id,