mirror of
https://github.com/SableClient/Sable.git
synced 2026-12-06 00:32:26 -08:00
formatting
This commit is contained in:
1 parent
955336aa39
commit
04acab0d78
4 files changed
+7
-4
No files matched your search
@@ -48,7 +48,10 @@ export function MobileSwipeDownModal({ children, requestClose }: MobileSwipeDown
|
||||
|
||||
const handleTouchEnd = () => {
|
||||
const endTime = Date.now();
|
||||
if (touchYDiff.current > 100 || (endTime - startTime.current < 600 && touchYDiff.current > 20)) {
|
||||
if (
|
||||
touchYDiff.current > 100 ||
|
||||
(endTime - startTime.current < 600 && touchYDiff.current > 20)
|
||||
) {
|
||||
requestClose();
|
||||
} else {
|
||||
touchYDiff.current = 0;
|
||||
|
||||
@@ -70,7 +70,9 @@ function ActiveSwipeWrapper({ children, onReply }: { children: ReactNode; onRepl
|
||||
/>
|
||||
</motion.div>
|
||||
</div>
|
||||
<motion.div style={{ x, position: 'relative', zIndex: 1, willChange: 'transform' }}>{children}</motion.div>
|
||||
<motion.div style={{ x, position: 'relative', zIndex: 1, willChange: 'transform' }}>
|
||||
{children}
|
||||
</motion.div>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -39,4 +39,3 @@ export const useSelectedOrLastRoom = (): string | undefined => {
|
||||
|
||||
return listMatch ? lastRoomId : undefined;
|
||||
};
|
||||
|
||||
@@ -18,4 +18,3 @@ export const lastVisitedRoomAtom = lastVisitedRoomBaseAtom;
|
||||
/** Returns a read-only derived atom for a single section's last-visited room. */
|
||||
export const lastVisitedRoomSectionAtom = (sectionKey: string) =>
|
||||
atom((get) => get(lastVisitedRoomAtom)[sectionKey]);
|
||||
|
||||
Reference in new issue
Block a user