Swipe gestures on rows everywhere: research, then grill #400

Closed
opened 2026-10-15 03:55:20 +00:00 by kayg · 9 comments
Owner

kayg, 2026-10-15: "I feel like each search row should have its swipe actions so that I could just insert the link of that item into the place the cursor right now is, or I could copy the link to that item, or I could just open the link. So I would love if sidebar included, or the middle pane included, things generally having swipe gestures. So I believe what I'm saying is that swipe gestures, the UX needs to be researched and it needs another grill."

Scope: one swipe-gesture system for rows everywhere (search results, the note list / middle pane, the sidebar or Places, Trash, maybe tags). It also has to live alongside block swipe-select in the editor (#397, G1–G6) and the browser and iOS back-swipe from the left edge.

Research (cite sources): the iOS Mail/Reminders/Things swipe conventions (leading versus trailing, full-swipe commits the first action, haptics, rubber-banding, reveal widths), Android Material swipe; how web apps do it on iOS Safari without fighting scroll or the edge back gesture (touch-action, thresholds, velocity); accessibility (every swipe action must also be reachable by long press or a ⋯ menu, and by keyboard on desktop); desktop equivalents (hover actions, right-click).

Then draft a numbered grill with recommended answers for kayg, and after that a mockup on preview.

kayg, 2026-10-15: "I feel like each search row should have its swipe actions so that I could just insert the link of that item into the place the cursor right now is, or I could copy the link to that item, or I could just open the link. So I would love if sidebar included, or the middle pane included, things generally having swipe gestures. So I believe what I'm saying is that swipe gestures, the UX needs to be researched and it needs another grill." Scope: one swipe-gesture system for rows everywhere (search results, the note list / middle pane, the sidebar or Places, Trash, maybe tags). It also has to live alongside block swipe-select in the editor (#397, G1–G6) and the browser and iOS back-swipe from the left edge. Research (cite sources): the iOS Mail/Reminders/Things swipe conventions (leading versus trailing, full-swipe commits the first action, haptics, rubber-banding, reveal widths), Android Material swipe; how web apps do it on iOS Safari without fighting scroll or the edge back gesture (touch-action, thresholds, velocity); accessibility (every swipe action must also be reachable by long press or a ⋯ menu, and by keyboard on desktop); desktop equivalents (hover actions, right-click). Then draft a numbered grill with recommended answers for kayg, and after that a mockup on preview.
Author
Owner

Research: swipe actions on rows

Reference products are named in these notes only, never in the UI.

1. What the platforms do

  • iOS lists. Trailing actions (swipe left) are the default edge. The first action is the one nearest the edge, and by default a full swipe performs it. A destructive action is red. Apps often put Delete first, which is why community advice turns full swipe off for destructive actions. Sources: SwiftUI swipeActions, Use Your Loaf, UIKit performsFirstActionWithFullSwipe.
  • Mail. Leading means read or unread. Trailing is More, then Flag, then Trash, and a full swipe left trashes. You can set one action per side, and iOS fills in the other trailing slots. Even with both sides set to None, a full swipe left still deletes. Undo is a three-finger swipe or shake. Sources: iPhone Life, Cult of Mac.
  • Reminders and Files. Swipe left to delete, with no confirmation. Files keeps deleted items in Recently Deleted for 30 days. Sources: iPhone Life, MacMost.
  • Things. It uses swipes for other jobs. Swipe left selects a row, and more swipes or taps add to the selection, with a toolbar acting on all of them. Swipe right opens When, its single most useful action. Touch and hold drags. Source: Cultured Code gestures. This is the closest match to our block swipe-select (G1–G6).
  • Material. "The swipe action of each tile should be consistent within lists" (M1 lists). Compose and Flutter use swipe-to-dismiss with a colored leave-behind and a snackbar with Undo (Flutter, Compose). Wear OS uses right-to-left only, so it never fights the system's swipe-dismiss, and snaps back below 50% (Wear SwipeToReveal).
  • Apple HIG. Don't give a familiar gesture an app-only meaning. Gestures need on-screen alternatives: "if you use a swipe gesture … also make a button available" (HIG gestures, HIG accessibility).

2. Numbers that work, from web libraries

Ionic item-sliding Framework7 swipeout react-swipeable-list
start 5px first move decides the axis (|dy| > |dx| means scroll) 10px
open or close on release past half the reveal width, or velocity > 0.3 px/ms flick under 300ms, or past half the reveal width 0.5 of the width
rubber band past the actions × 0.55 follows the finger none
full swipe reveal width + 30px 1.2 × the reveal width n/a
edge back no start within 15px of the screen edge none none

Sources: item-sliding.tsx, swipeout.js, react-swipeable-list.

Our own numbers already line up. PhoneStack's back swipe only starts within 24px of the edge. touch.ts uses BACK_EDGE = 24 and decides a swipe at 10px. #397's new claim is ≥10px sideways, more than 2× the vertical movement, within 300ms.

3. iOS Safari specifics

  • touch-action: pan-y is not enough on iOS. When the page doesn't scroll sideways, a touch that starts horizontally can still turn into a vertical scroll (WebKit 232545, open since 2021). A pointer stream also gets pointercancel as soon as Safari decides to scroll. So rows need a non-passive touchmove that calls preventDefault() once the axis is locked sideways. This is the #397 finding: only the first touchmove gets a vote (WebPageProxy.cpp). We can still use Pointer Events for mouse and pen, and Touch Events for fingers on iOS.
  • Edge back. In Safari the edge swipe is the system's and can't be cancelled. In the home-screen app it's our PhoneStack. Either way, rows must ignore touches that start within 24px of the left edge, as Ionic does with 15px.
  • Rows are not contenteditable, so the #397 loupe race doesn't apply. Two things still matter. A row needs user-select: none so a drag doesn't select its title. And long-press on an <a> or image starts a native drag or callout: #399 has a screenshot of a drag ghost over search rows. -webkit-touch-callout: none plus draggable="false" usually helps, but has been reported ignored on iOS 26.1 (Apple forums). The reliable fix is a non-passive touchstart that only calls preventDefault on rows that have a long-press of their own (WebKit 231161). It must also keep taps working.
  • Haptics. iOS Safari has no navigator.vibrate. The workaround clicks the <label> of a hidden <input type=checkbox switch>, which plays the system switch tick (Safari 18+). WebKit then limited this to user activation (WebKit 285120). Sources: ios-haptics, Ionic #29942, azukiazusa. A touchmove is not user activation, so we can't tick at the moment a full swipe crosses its threshold, which is the moment that matters. At best we could tick on release. One tester reports that iOS 26.5 closed it entirely (rapidtoolset, unverified). Android has navigator.vibrate.
  • Performance. Only transform: translate3d on the row's content, no layout reads per frame. Action widths are fixed in CSS, so there's nothing to measure. One row is open at a time. Any scroll, tap elsewhere or new swipe closes it. The note list is virtual (NoteList.svelte), so the open state is keyed by note id and dropped when the row unmounts.

4. Accessibility and desktop

  • WCAG 2.5.1 (A). A swipe is a path-based gesture, so every swipe action needs a single-pointer alternative, such as a tap on ⋯ or a menu item (Understanding 2.5.1).
  • VoiceOver custom actions. The web has no stable way to offer them yet. aria-actions is proposed for ARIA 1.3. Firefox and Chrome 151 ship it, and Safari has it behind a flag; it has only been tested with macOS VoiceOver (azukiazusa, Aug 2026, ARIA minutes 2026-01). Cheap to add now (it points at the row's action buttons), but it can't be the only route.
  • Today. Rows have right-click menus (noteMenu, sidebarMenu) but no ⋯ and no touch route to them, apart from the sidebar's press-drag and search r3's long-press preview. On phones, the note list's actions can't be reached at all except by the native long-press contextmenu, which is unreliable on iOS.
  • Desktop. Use hover ⋯ (and, at most, the first one or two actions as quiet icons on hover), right-click for the same menu, and shortcuts on the focused row (roving focus already exists). For search, the provider already has open (Enter) and link (⌘Enter inserts the link). Swipes don't exist on desktop, and keyboard actions never animate.

Inventory: rows and proposed actions

Leading means swipe right, revealed from the left. Trailing means swipe left. Full is what a full swipe commits.

# Row Where Today Leading (full) Trailing (full first) ⋯ / right-click adds
1 Search result (r3/r4) mockup search/ResultRow.svelte tap opens; 500ms long-press preview Insert link at caret (accent), only when a note is open behind search Copy link, then ⋯ Open, Open in focus, Copy link, Insert link; provider extras
2 Note list row NoteList.svelte:196 tap opens; right-click noteMenu Pin / Unpin (accent) Delete (danger, with an Undo toast), then ⋯ Open in focus, Copy link, Insert link (when a note is open)
3 Sidebar place (Today, Journal, …) Sidebar.svelte:170 tap; 320ms press-drag reorders none none Move up / down (exists)
4 Sidebar tag Sidebar.svelte:176 tap; dbl-click renames; drag merges none ⋯ only Rename, Move up / down, Copy link to the tag
5 Trash row TrashList.svelte:66 Restore pill and delete icon in the row Restore (accent) Delete forever (danger, no full swipe, confirms in place) the same two
6 Note picker, tag picker, palette NotePicker, TagPicker, Palette tap picks none (these are choosers) none none
7 Linked-from / unlinked mention InfoSheet.svelte:146/161 tap opens; unlinked has a Link button unlinked only: Link it (accent) none Open, Copy link
8 Passkey, device, versions, settings, prop rows, tiles, tabs various inline buttons none none none (buttons are already visible)
9 Editor blocks packages/editor/src/blocks/touch.ts either swipe selects (G1–G6, #397) n/a: block swipe-select keeps both directions n/a block ⋯ (exists)

Rows 1, 2, 4, 5 and 7 should all use one rowActions registry. Each plugin adds {id, label, icon, tone: accent|plain|danger, side, full?, when(row), run(row), key?} for a row kind (note, search:<provider>, tag, trash, …). The same list builds the swipe tray, the ⋯ and right-click menu, the long-press menu, the shortcut map and aria-actions. That replaces the hand-written noteMenu / sidebarMenu builders for rows. Today the palette's ACTIONS and the menus aren't shared.

Grill for kayg

  1. Which rows swipe?
    Recommended: search results, the note list, Trash and unlinked mentions. Not the sidebar, the pickers or settings.
    Why: the sidebar is navigation with a press-drag already, and its few actions (rename, reorder) are rare enough for ⋯.
  2. Search row, swipe right: "Insert link here" at the caret, and a full swipe does it?
    Recommended: yes. It only appears when a note is open behind search. After inserting, search stays open with a small "Linked" confirmation, so you can link several in a row.
    Why: it's the action you asked for first, and it's what ⌘Enter does on desktop.
  3. Search row, swipe left: Copy link, plus ⋯ for the rest. Open stays a tap.
    Recommended: yes. A full swipe left copies.
    Why: Open as a swipe would only repeat the tap. Copy needs no confirmation and can't hurt.
  4. Note list, swipe right is Pin, swipe left is Delete (full swipe deletes, toast with Undo)?
    Recommended: yes.
    Why: this matches what people's thumbs already expect in mail and to-do apps. Delete only moves the note to Trash, and the Undo toast covers mistakes, so no confirmation is needed.
  5. Should a full swipe ever delete forever?
    Recommended: never. In Trash, swipe left shows "Delete forever", which needs a tap and then confirms in place. A full swipe there only opens the tray.
    Why: it's the only action that can't be undone.
  6. How many actions per side?
    Recommended: at most one leading, and at most two trailing plus ⋯. Each button is a fixed 72px icon with a label, on the accent, plain or danger color, never a gradient.
    Why: fixed widths mean nothing is measured while the finger moves. More than three buttons won't fit a 390px row.
  7. Motion.
    Recommended: the row follows your finger 1:1. Past the buttons it stretches with resistance (×0.55). When you cross the full-swipe point, the first button grows to fill the row with a small spring "detent". On release, a spring settles it open or closed, and it opens if past half the tray or flicked faster than 0.3 px/ms. Keyboard and menu actions run with no animation.
    Why: this is springy and in place without a per-frame layout read, and it matches what native rows feel like.
  8. Haptics.
    Recommended: none on iPhone for now, with a visual detent instead. Use navigator.vibrate(8) on Android only.
    Why: iOS Safari can only tick from a tap or release, never at the threshold mid-swipe. The workaround is a hack Apple has already narrowed, and may have closed in 26.5.
  9. Gesture zones and timing.
    Recommended:
    • Ignore touches that start within 24px of the left edge, which belong to back.
    • Claim the swipe at ≥10px sideways, more than 2× the vertical movement, within 300ms, the same rule as #397.
    • Anything held longer goes to long-press: the search preview, or the sidebar's press-drag.
    • Opening a tray or starting a scroll closes any other open row.
      Why: one rule everywhere means rows, blocks and back never argue.
  10. What does long-press do on a row?
    Recommended: on search results, the preview card (#271) with the same actions listed under it. On note-list rows, the same card. Never the browser's own drag or callout.
    Why: one hold gesture, everywhere, gives the touch route to every swipe action (WCAG 2.5.1), and it fixes the drag ghost in #399.
  11. Show ⋯ on rows?
    Recommended: on desktop, show ⋯ on hover and on the focused row. On phones, no permanent ⋯. The swipe tray's last button is ⋯, and long-press opens the same actions.
    Why: this keeps rows quiet ("no machinery") while every action stays reachable.
  12. Keyboard on the focused row.
    Recommended:
    • Enter opens.
    • ⌘Enter inserts the link.
    • ⌘C (or ⌘L) copies the link.
    • ⌘⌫ deletes, with Undo.
    • P pins (note list only).
    • The context-menu key or ⇧F10 opens the menu.
      All of these come from the same registry, so a plugin's action gets a shortcut for free.
      Why: desktop gets the same actions with no gesture, and they don't animate.
## Research: swipe actions on rows Reference products are named in these notes only, never in the UI. ### 1. What the platforms do - **iOS lists.** Trailing actions (swipe left) are the default edge. The first action is the one nearest the edge, and by default a **full swipe performs it**. A destructive action is red. Apps often put Delete first, which is why community advice turns full swipe off for destructive actions. Sources: [SwiftUI `swipeActions`](https://developer.apple.com/tutorials/data/documentation/swiftui/view/swipeactions(edge:allowsfullswipe:content:).md), [Use Your Loaf](https://useyourloaf.com/blog/swiftui-swipe-actions/), [UIKit `performsFirstActionWithFullSwipe`](https://codemia.io/knowledge-hub/path/add_swipe_to_delete_uitableviewcell). - **Mail.** Leading means read or unread. Trailing is More, then Flag, then Trash, and a full swipe left trashes. You can set one action per side, and iOS fills in the other trailing slots. Even with both sides set to None, a full swipe left still deletes. Undo is a three-finger swipe or shake. Sources: [iPhone Life](https://iphonelife.com/blog/5/tip-day-change-mail-swipe-options-settings), [Cult of Mac](https://www.cultofmac.com/?p=536809). - **Reminders and Files.** Swipe left to delete, with no confirmation. Files keeps deleted items in Recently Deleted for 30 days. Sources: [iPhone Life](https://iphonelife.com/content/how-to-delete-reminders-iphone), [MacMost](https://macmost.com/18-iphone-files-app-tips.html). - **Things.** It uses swipes for other jobs. **Swipe left selects** a row, and more swipes or taps add to the selection, with a toolbar acting on all of them. **Swipe right opens When**, its single most useful action. Touch and hold drags. Source: [Cultured Code gestures](https://culturedcode.com/things/support/articles/2803582/). This is the closest match to our block swipe-select (G1–G6). - **Material.** "The swipe action of each tile should be consistent within lists" ([M1 lists](https://m1.material.io/components/lists.html)). Compose and Flutter use swipe-to-dismiss with a colored leave-behind and a snackbar with Undo ([Flutter](https://docs.flutter.dev/cookbook/gestures/dismissible), [Compose](https://composables.com/material/swipetodismiss)). Wear OS uses right-to-left only, so it never fights the system's swipe-dismiss, and snaps back below 50% ([Wear SwipeToReveal](https://developer.android.com/design/ui/wear/guides/components/swipe-to-reveal)). - **Apple HIG.** Don't give a familiar gesture an app-only meaning. Gestures need on-screen alternatives: "if you use a swipe gesture … also make a button available" ([HIG gestures](https://developer.apple.com/design/human-interface-guidelines/gestures), [HIG accessibility](https://developer.apple.com/design/human-interface-guidelines/accessibility)). ### 2. Numbers that work, from web libraries | | Ionic `item-sliding` | Framework7 `swipeout` | react-swipeable-list | |---|---|---|---| | start | 5px | first move decides the axis (\|dy\| > \|dx\| means scroll) | 10px | | open or close on release | past half the reveal width, **or** velocity > 0.3 px/ms | flick under 300ms, or past half the reveal width | 0.5 of the width | | rubber band past the actions | × 0.55 | follows the finger | none | | full swipe | reveal width + 30px | 1.2 × the reveal width | n/a | | edge back | **no start within 15px of the screen edge** | none | none | Sources: [item-sliding.tsx](https://github.com/ionic-team/ionic-framework/blob/main/core/src/components/item-sliding/item-sliding.tsx), [swipeout.js](https://github.com/framework7io/framework7/blob/master/src/core/components/swipeout/swipeout.js), [react-swipeable-list](https://github.com/sandstreamdev/react-swipeable-list/). Our own numbers already line up. PhoneStack's back swipe only starts within 24px of the edge. `touch.ts` uses `BACK_EDGE = 24` and decides a swipe at 10px. #397's new claim is ≥10px sideways, more than 2× the vertical movement, within 300ms. ### 3. iOS Safari specifics - **`touch-action: pan-y` is not enough on iOS.** When the page doesn't scroll sideways, a touch that starts horizontally can still turn into a vertical scroll ([WebKit 232545](https://bugs.webkit.org/show_bug.cgi?id=232545), open since 2021). A pointer stream also gets `pointercancel` as soon as Safari decides to scroll. So rows need a **non-passive `touchmove`** that calls `preventDefault()` once the axis is locked sideways. This is the #397 finding: only the first `touchmove` gets a vote ([WebPageProxy.cpp](https://github.com/WebKit/WebKit/blob/main/Source/WebKit/UIProcess/WebPageProxy.cpp)). We can still use Pointer Events for mouse and pen, and Touch Events for fingers on iOS. - **Edge back.** In Safari the edge swipe is the system's and can't be cancelled. In the home-screen app it's our PhoneStack. Either way, rows must ignore touches that start within 24px of the left edge, as Ionic does with 15px. - **Rows are not contenteditable,** so the #397 loupe race doesn't apply. Two things still matter. A row needs `user-select: none` so a drag doesn't select its title. And long-press on an `<a>` or image starts a native drag or callout: #399 has a screenshot of a drag ghost over search rows. `-webkit-touch-callout: none` plus `draggable="false"` usually helps, but has been reported ignored on iOS 26.1 ([Apple forums](https://developer.apple.com/forums/thread/808606)). The reliable fix is a non-passive `touchstart` that only calls `preventDefault` on rows that have a long-press of their own ([WebKit 231161](https://bugs.webkit.org/show_bug.cgi?id=231161)). It must also keep taps working. - **Haptics.** iOS Safari has no `navigator.vibrate`. The workaround clicks the `<label>` of a hidden `<input type=checkbox switch>`, which plays the system switch tick (Safari 18+). WebKit then limited this to **user activation** ([WebKit 285120](https://bugs.webkit.org/show_bug.cgi?id=285120)). Sources: [ios-haptics](https://npmjs.com/package/ios-haptics), [Ionic #29942](https://github.com/ionic-team/ionic-framework/issues/29942), [azukiazusa](https://azukiazusa.dev/en/blog/ios-safari-web-haptics). A `touchmove` is not user activation, so we **can't tick at the moment a full swipe crosses its threshold**, which is the moment that matters. At best we could tick on release. One tester reports that iOS 26.5 closed it entirely ([rapidtoolset](https://rapidtoolset.com/en/tool/ios-haptics-tester), unverified). Android has `navigator.vibrate`. - **Performance.** Only `transform: translate3d` on the row's content, no layout reads per frame. Action widths are fixed in CSS, so there's nothing to measure. One row is open at a time. Any scroll, tap elsewhere or new swipe closes it. The note list is virtual (`NoteList.svelte`), so the open state is keyed by note id and dropped when the row unmounts. ### 4. Accessibility and desktop - **WCAG 2.5.1 (A).** A swipe is a path-based gesture, so every swipe action needs a single-pointer alternative, such as a tap on ⋯ or a menu item ([Understanding 2.5.1](https://www.w3.org/WAI/WCAG22/Understanding/pointer-gestures.html)). - **VoiceOver custom actions.** The web has no stable way to offer them yet. `aria-actions` is proposed for ARIA 1.3. Firefox and Chrome 151 ship it, and Safari has it behind a flag; it has only been tested with macOS VoiceOver ([azukiazusa, Aug 2026](https://azukiazusa.dev/en/blog/aria-actions-attribute), [ARIA minutes 2026-01](https://www.w3.org/2026/01/15-aria-minutes.html)). Cheap to add now (it points at the row's action buttons), but it can't be the only route. - **Today.** Rows have right-click menus (`noteMenu`, `sidebarMenu`) but **no ⋯ and no touch route** to them, apart from the sidebar's press-drag and search r3's long-press preview. On phones, the note list's actions can't be reached at all except by the native long-press `contextmenu`, which is unreliable on iOS. - **Desktop.** Use hover ⋯ (and, at most, the first one or two actions as quiet icons on hover), right-click for the same menu, and shortcuts on the focused row (roving focus already exists). For search, the provider already has `open` (Enter) and `link` (⌘Enter inserts the link). Swipes don't exist on desktop, and keyboard actions never animate. ## Inventory: rows and proposed actions **Leading** means swipe right, revealed from the left. **Trailing** means swipe left. **Full** is what a full swipe commits. | # | Row | Where | Today | Leading (full) | Trailing (full first) | ⋯ / right-click adds | |---|---|---|---|---|---|---| | 1 | Search result (r3/r4) | mockup `search/ResultRow.svelte` | tap opens; 500ms long-press preview | **Insert link at caret** (accent), only when a note is open behind search | **Copy link**, then ⋯ | Open, Open in focus, Copy link, Insert link; provider extras | | 2 | Note list row | `NoteList.svelte:196` | tap opens; right-click `noteMenu` | **Pin / Unpin** (accent) | **Delete** (danger, with an Undo toast), then ⋯ | Open in focus, Copy link, Insert link (when a note is open) | | 3 | Sidebar place (Today, Journal, …) | `Sidebar.svelte:170` | tap; 320ms press-drag reorders | none | none | Move up / down (exists) | | 4 | Sidebar tag | `Sidebar.svelte:176` | tap; dbl-click renames; drag merges | none | ⋯ only | Rename, Move up / down, Copy link to the tag | | 5 | Trash row | `TrashList.svelte:66` | Restore pill and delete icon in the row | **Restore** (accent) | **Delete forever** (danger, no full swipe, confirms in place) | the same two | | 6 | Note picker, tag picker, palette | `NotePicker`, `TagPicker`, `Palette` | tap picks | none (these are choosers) | none | none | | 7 | Linked-from / unlinked mention | `InfoSheet.svelte:146/161` | tap opens; unlinked has a Link button | unlinked only: **Link it** (accent) | none | Open, Copy link | | 8 | Passkey, device, versions, settings, prop rows, tiles, tabs | various | inline buttons | none | none | none (buttons are already visible) | | 9 | Editor blocks | `packages/editor/src/blocks/touch.ts` | **either swipe selects** (G1–G6, #397) | n/a: block swipe-select keeps both directions | n/a | block ⋯ (exists) | Rows 1, 2, 4, 5 and 7 should all use **one `rowActions` registry**. Each plugin adds `{id, label, icon, tone: accent|plain|danger, side, full?, when(row), run(row), key?}` for a row kind (`note`, `search:<provider>`, `tag`, `trash`, …). The same list builds the swipe tray, the ⋯ and right-click menu, the long-press menu, the shortcut map and `aria-actions`. That replaces the hand-written `noteMenu` / `sidebarMenu` builders for rows. Today the palette's `ACTIONS` and the menus aren't shared. ## Grill for kayg 1. **Which rows swipe?** **Recommended:** search results, the note list, Trash and unlinked mentions. Not the sidebar, the pickers or settings. *Why:* the sidebar is navigation with a press-drag already, and its few actions (rename, reorder) are rare enough for ⋯. 2. **Search row, swipe right:** "Insert link here" at the caret, and a full swipe does it? **Recommended:** yes. It only appears when a note is open behind search. After inserting, search stays open with a small "Linked" confirmation, so you can link several in a row. *Why:* it's the action you asked for first, and it's what ⌘Enter does on desktop. 3. **Search row, swipe left:** Copy link, plus ⋯ for the rest. Open stays a tap. **Recommended:** yes. A full swipe left copies. *Why:* Open as a swipe would only repeat the tap. Copy needs no confirmation and can't hurt. 4. **Note list, swipe right is Pin, swipe left is Delete (full swipe deletes, toast with Undo)?** **Recommended:** yes. *Why:* this matches what people's thumbs already expect in mail and to-do apps. Delete only moves the note to Trash, and the Undo toast covers mistakes, so no confirmation is needed. 5. **Should a full swipe ever delete forever?** **Recommended:** never. In Trash, swipe left shows "Delete forever", which needs a tap and then confirms in place. A full swipe there only opens the tray. *Why:* it's the only action that can't be undone. 6. **How many actions per side?** **Recommended:** at most one leading, and at most two trailing plus ⋯. Each button is a fixed 72px icon with a label, on the accent, plain or danger color, never a gradient. *Why:* fixed widths mean nothing is measured while the finger moves. More than three buttons won't fit a 390px row. 7. **Motion.** **Recommended:** the row follows your finger 1:1. Past the buttons it stretches with resistance (×0.55). When you cross the full-swipe point, the first button grows to fill the row with a small spring "detent". On release, a spring settles it open or closed, and it opens if past half the tray or flicked faster than 0.3 px/ms. Keyboard and menu actions run with no animation. *Why:* this is springy and in place without a per-frame layout read, and it matches what native rows feel like. 8. **Haptics.** **Recommended:** none on iPhone for now, with a visual detent instead. Use `navigator.vibrate(8)` on Android only. *Why:* iOS Safari can only tick from a tap or release, never at the threshold mid-swipe. The workaround is a hack Apple has already narrowed, and may have closed in 26.5. 9. **Gesture zones and timing.** **Recommended:** - Ignore touches that start within 24px of the left edge, which belong to back. - Claim the swipe at ≥10px sideways, more than 2× the vertical movement, within 300ms, the same rule as #397. - Anything held longer goes to long-press: the search preview, or the sidebar's press-drag. - Opening a tray or starting a scroll closes any other open row. *Why:* one rule everywhere means rows, blocks and back never argue. 10. **What does long-press do on a row?** **Recommended:** on search results, the preview card (#271) with the same actions listed under it. On note-list rows, the same card. Never the browser's own drag or callout. *Why:* one hold gesture, everywhere, gives the touch route to every swipe action (WCAG 2.5.1), and it fixes the drag ghost in #399. 11. **Show ⋯ on rows?** **Recommended:** on desktop, show ⋯ on hover and on the focused row. On phones, no permanent ⋯. The swipe tray's last button is ⋯, and long-press opens the same actions. *Why:* this keeps rows quiet ("no machinery") while every action stays reachable. 12. **Keyboard on the focused row.** **Recommended:** - Enter opens. - ⌘Enter inserts the link. - ⌘C (or ⌘L) copies the link. - ⌘⌫ deletes, with Undo. - P pins (note list only). - The context-menu key or ⇧F10 opens the menu. All of these come from the same registry, so a plugin's action gets a shortcut for free. *Why:* desktop gets the same actions with no gesture, and they don't animate.
Author
Owner

kayg's grill answers, 2026-10-15:

  • W1: sidebar items (Views, tags) and the notes pane swipe too.
    • Left → right: Open and Copy link. Each button is an icon with its label underneath; cleaner than the iOS look, not a copy of it. A long swipe copies the link.
    • Right → left: Archive, Hide and Delete. A long swipe deletes.
  • W2: correct. Search rows get Insert link here when a note is open behind search.
  • W3: keep it consistent: left → right copies the link (in search too).
  • W4: correct (delete moves the note to Trash, with an Undo toast). Pin moves off the swipe; see the open questions.
  • W5: kayg asked what 'a full swipe opens the tray' means. Explained in chat.
  • W6: design agreed; kayg asked why the limit is 1 + 2. Explained in chat; it's now up to 3 per side.
  • W7: yes; motion and responsiveness are very important.
  • W8, W9, W11, W12: yes.
  • W10: kayg wants to see it in a mockup.

Open questions W13–W16 are in chat: what Archive and Hide mean, search's left-to-right set, where Pin goes, and how many buttons fit at 320.

**kayg's grill answers, 2026-10-15:** - **W1:** sidebar items (Views, tags) and the notes pane swipe too. - **Left → right:** Open and Copy link. Each button is an icon with its label underneath; cleaner than the iOS look, not a copy of it. A long swipe copies the link. - **Right → left:** Archive, Hide and Delete. A long swipe deletes. - **W2:** correct. Search rows get *Insert link here* when a note is open behind search. - **W3:** keep it consistent: left → right copies the link (in search too). - **W4:** correct (delete moves the note to Trash, with an Undo toast). Pin moves off the swipe; see the open questions. - **W5:** kayg asked what 'a full swipe opens the tray' means. Explained in chat. - **W6:** design agreed; kayg asked why the limit is 1 + 2. Explained in chat; it's now up to 3 per side. - **W7:** yes; motion and responsiveness are very important. - **W8, W9, W11, W12:** yes. - **W10:** kayg wants to see it in a mockup. Open questions W13–W16 are in chat: what Archive and Hide mean, search's left-to-right set, where Pin goes, and how many buttons fit at 320.
Author
Owner

kayg's grill answers, 2026-10-15 (Archive and Hide):

  • W5: agreed. In Trash, a full swipe only reveals the buttons; Delete forever takes a tap and a confirmation.
  • W6: up to 3 buttons per side.
  • W13: Archive is for things you no longer need but don't want to delete: notes, files, photos, mail, transactions. Archived items leave search. Hide means truly hidden from view: a note, a block, mail, a transaction, a file or a photo. Hidden items stay out of search unless marked unhidden, and search gets a Show all hidden items action.
  • W17: frontmatter keys archived: true and hidden: true.
  • W18: archived items are left out of lists and search by default. The word 'archived' brings them back (it joins the S8 words). An Archive place appears in the sidebar once anything is archived, and Unarchive is a swipe action there.
  • W19: hidden items are left out of every list, search and 'Linked here'. Search gets 'Show hidden items', and the word 'hidden' works too. A link to a hidden note still opens it.
  • W20: a hidden block gets a trailing <!-- hidden --> marker, kept separate from the block id so links don't break. Make sure it doesn't break our renderer: the editor must neither show nor mangle the comment, and must round-trip it losslessly.
  • W21: open. kayg: 'isn't .xmp a valid sidecar already? … would love a .md … but we should also follow conventions and standards wherever appropriate.' Research is in #412.
  • W14–W16: still open.
**kayg's grill answers, 2026-10-15 (Archive and Hide):** - **W5:** agreed. In Trash, a full swipe only reveals the buttons; Delete forever takes a tap and a confirmation. - **W6:** up to 3 buttons per side. - **W13:** **Archive** is for things you no longer need but don't want to delete: notes, files, photos, mail, transactions. Archived items leave search. **Hide** means truly hidden from view: a note, a block, mail, a transaction, a file or a photo. Hidden items stay out of search unless marked unhidden, and search gets a *Show all hidden items* action. - **W17:** frontmatter keys `archived: true` and `hidden: true`. - **W18:** archived items are left out of lists and search by default. The word 'archived' brings them back (it joins the S8 words). An Archive place appears in the sidebar once anything is archived, and Unarchive is a swipe action there. - **W19:** hidden items are left out of every list, search and 'Linked here'. Search gets 'Show hidden items', and the word 'hidden' works too. A link to a hidden note still opens it. - **W20:** a hidden block gets a trailing `<!-- hidden -->` marker, kept separate from the block id so links don't break. **Make sure it doesn't break our renderer:** the editor must neither show nor mangle the comment, and must round-trip it losslessly. - **W21:** open. kayg: 'isn't .xmp a valid sidecar already? … would love a .md … but we should also follow conventions and standards wherever appropriate.' Research is in #412. - **W14–W16:** still open.
Author
Owner

kayg, 2026-10-15 (W22): agreed. 'Hidden' means decluttering, not protection, so the UI always says Hide, never Private or Lock. Truly protected notes (encrypted, unlocked with a passkey) are a separate feature, to be grilled alongside sharing in #409.

**kayg, 2026-10-15 (W22):** agreed. 'Hidden' means decluttering, not protection, so the UI always says Hide, never Private or Lock. Truly protected notes (encrypted, unlocked with a passkey) are a separate feature, to be grilled alongside sharing in #409.
Author
Owner

Mockup: swipe actions on rows (PR #433)

Try it: on a phone, https://preview.calternal.cloud/swipe.html#/list/all (the note list), the sidebar, search with a note open and the Trash. On a desktop: https://preview.calternal.cloud/swipe.html#/note/calternal-rewrite?list=all. Rows also drag with a mouse there, so you can feel the motion. It's a new page, so the other mockups are untouched (backup site.bak-400-202610151309).

What it does

  • Left → right: Copy link and Open; a long swipe copies the link. In search, Insert link here joins them while a note is open behind search, and search stays open after it.
  • Right → left: Archive, Hide and Delete; a long swipe moves the note to the Trash, with Undo. Tags get Hide and Delete. Places get Hide only, so a long swipe there just opens the buttons.
  • Trash: Restore from the left. Delete forever is never a long swipe: the swipe only shows the button, which asks Confirm in place, and it turns back after 3 s.
  • Archive and Hide, as you decided them:
    • Archive: an Archive place appears in the sidebar once anything is archived, and a long swipe there unarchives.
    • Hide: hidden notes leave every list, search and Linked here.
    • In search, the words "archived" and "hidden" bring them back, and every result's ⋯ has Show hidden items.
    • Photos and files in search get Archive and Hide too. Blocks aren't in this mockup; that's the editor's side, with W20's <!-- hidden -->.
  • Buttons: soft tiles in the accent, plain or danger colours, with the icon over a short label. They're 64 px slots, at most 3 a side, inset 4 px from the row. They slide out from under the row in proportion as it moves. At the long-swipe point, the outer tile grows into one solid bar with a small spring bounce (iPhone gets no buzz; Android gets an 8 ms tick).
  • Long press: the preview card, with every action listed under it. No drag ghost and no callout.
  • Desktop: ⋯ on hover and on the focused row, the same menu on right-click, and ⌘↵ / ⌘C / ⌘⌫ / ⇧F10 on the focused row. Keys and menus never animate.

Still open: try them from the Mockup pill (top right on a phone)

  • W14, search's left → right order: Copy link first (a long swipe copies, the same as everywhere else) or Insert link first (a long swipe inserts). &slead=insert
  • W15, Pin: only in the long-press card and ⋯ (default), or a third left → right button. &pin=swipe
  • W16, Open as a swipe button: on (default), or off so a tap opens. &open=tap

Frame strip: a long swipe left to delete (390, real touch)

The finger at −12 … −240 px, then crossing the long-swipe point (the tile grows into the bar), then let go, with the spring frozen and stepped through at +0 to +260 ms, and the list closing the gap.
strip.png

390 wide

Notes, light: rest · left → right mid-swipe · left → right open · right → left mid-swipe · long-swipe detent · deleted, with Undo · long-press card
notes-390-light.png
Archive and the sidebar, light: right → left open · the Archive place appears · long swipe to Unarchive · "archived" in search · a tag, right → left · a place, left → right
archive-side-390-light.png
Search and the Trash, light: left → right mid-swipe · long swipe (Copy link) · long-press card with Show hidden items · Trash, right → left open · Delete forever asks Confirm
search-trash-390-light.png

Notes, dark: rest · left → right mid-swipe · left → right open · right → left mid-swipe · long-swipe detent · deleted, with Undo · long-press card
notes-390-dark.png
Archive and the sidebar, dark: right → left open · the Archive place appears · long swipe to Unarchive · "archived" in search · a tag, right → left · a place, left → right
archive-side-390-dark.png
Search and the Trash, dark: left → right mid-swipe · long swipe (Copy link) · long-press card with Show hidden items · Trash, right → left open · Delete forever asks Confirm
search-trash-390-dark.png

375 wide

Notes, light: rest · left → right mid-swipe · left → right open · right → left mid-swipe · long-swipe detent · deleted, with Undo · long-press card
notes-375-light.png
Archive and the sidebar, light: right → left open · the Archive place appears · long swipe to Unarchive · "archived" in search · a tag, right → left · a place, left → right
archive-side-375-light.png
Search and the Trash, light: left → right mid-swipe · long swipe (Copy link) · long-press card with Show hidden items · Trash, right → left open · Delete forever asks Confirm
search-trash-375-light.png

Notes, dark: rest · left → right mid-swipe · left → right open · right → left mid-swipe · long-swipe detent · deleted, with Undo · long-press card
notes-375-dark.png
Archive and the sidebar, dark: right → left open · the Archive place appears · long swipe to Unarchive · "archived" in search · a tag, right → left · a place, left → right
archive-side-375-dark.png
Search and the Trash, dark: left → right mid-swipe · long swipe (Copy link) · long-press card with Show hidden items · Trash, right → left open · Delete forever asks Confirm
search-trash-375-dark.png

320 wide

Notes, light: rest · left → right mid-swipe · left → right open · right → left mid-swipe · long-swipe detent · deleted, with Undo · long-press card
notes-320-light.png
Archive and the sidebar, light: right → left open · the Archive place appears · long swipe to Unarchive · "archived" in search · a tag, right → left · a place, left → right
archive-side-320-light.png
Search and the Trash, light: left → right mid-swipe · long swipe (Copy link) · long-press card with Show hidden items · Trash, right → left open · Delete forever asks Confirm
search-trash-320-light.png

Notes, dark: rest · left → right mid-swipe · left → right open · right → left mid-swipe · long-swipe detent · deleted, with Undo · long-press card
notes-320-dark.png
Archive and the sidebar, dark: right → left open · the Archive place appears · long swipe to Unarchive · "archived" in search · a tag, right → left · a place, left → right
archive-side-320-dark.png
Search and the Trash, dark: left → right mid-swipe · long swipe (Copy link) · long-press card with Show hidden items · Trash, right → left open · Delete forever asks Confirm
search-trash-320-dark.png

At 390 light, the "long swipe" search frame shows the long-press card: the shared build host was busy enough that the hold won that one run. Every other width and theme shows the long-swipe bar.

1440

light: ⋯ on hover · its menu · a mouse swipe · right-click in search
desk-a-light.png desk-b-light.png
dark: ⋯ on hover · its menu · a mouse swipe · right-click in search
desk-a-dark.png desk-b-dark.png

Noticed, not changed here: at 320, the shared toast wraps "moved to Trash" mid-word ("Tras / h") next to Undo. That's the toast component's, not this PR's; it needs its own issue.

iPhone checklist (emulation can't prove the gesture; please try these on the phone)

Open the phone links above in Safari, and once more from the Home Screen app if you have it installed. Tick what works and note anything that doesn't.

Swiping a row

  • In the note list, a quick sideways swipe moves the row with your finger, and the page does not scroll up or down at the same time.
  • A normal vertical scroll that starts on a row still scrolls, with momentum, and never nudges the row sideways.
  • A slightly diagonal scroll stays a scroll (the row only moves for clearly sideways swipes).
  • Past the buttons, the row stretches with resistance, and the stretch looks smooth with no stutter.
  • Crossing the long-swipe point, the outer button grows into a solid bar with a small bounce, and you can tell when you've crossed it. (There's no buzz on iPhone; this is on purpose, W8.)
  • Moving back before letting go shrinks the bar again, and nothing happens.
  • Letting go past half the buttons opens them. A quick flick opens them even from a short swipe.
  • A long swipe left on a note sends it to the Trash, the row flies out, the rows below close the gap, and the Undo toast brings it back.
  • A long swipe right copies the link and shows the check, and the row springs back.

Edges and other gestures

  • Swiping back from the very left edge of the screen still goes back. It never opens a row.
  • Opening one row closes any other open row.
  • Tapping elsewhere, or scrolling, closes an open row.
  • Tapping an open row closes it and does not open the note.
  • In the sidebar, a press-and-drag still reorders rows.

Long press

  • Holding a row (without moving) opens the card with the preview and every action listed under it.
  • No grey drag ghost of the row, no text selection, and no Safari callout (Copy / Share / link preview) appears.
  • Letting go after the card opens doesn't also open the note.
  • Tapping the preview opens the note. Tapping outside closes the card.

Search (?find=1&q=canal with a note open)

  • Swiping a result right shows Copy link and Insert link here. A long swipe runs the first one. After Insert link here, search stays open and the link is in the note.
  • Holding a result shows its preview card with the actions, and no drag ghost (#399's bug).

Trash

  • A long swipe left on a Trash row only opens the button. It never deletes.
  • Tapping Delete forever turns the button into Confirm, and only a second tap deletes. If you leave it, it changes back after 3 seconds.

Archive and Hide (decided)

  • Archive a note: the Archive place appears in the sidebar, and a long swipe right there unarchives it.
  • Hide a note: it leaves the list. In search, typing "hidden" (or ⋯ → Show hidden items) brings it back.

Feel

  • Nothing jumps at the moment the swipe starts. The row starts with your finger about 10 px away.
  • Rotating the phone or changing the text size doesn't break the button labels.
## Mockup: swipe actions on rows (PR #433) **Try it:** on a phone, [https://preview.calternal.cloud/swipe.html#/list/all](https://preview.calternal.cloud/swipe.html#/list/all) (the note list), [the sidebar](https://preview.calternal.cloud/swipe.html#/home), [search with a note open](https://preview.calternal.cloud/swipe.html#/note/calternal-rewrite?list=all&find=1&q=canal) and [the Trash](https://preview.calternal.cloud/swipe.html#/list/trash). On a desktop: [https://preview.calternal.cloud/swipe.html#/note/calternal-rewrite?list=all](https://preview.calternal.cloud/swipe.html#/note/calternal-rewrite?list=all). Rows also drag with a mouse there, so you can feel the motion. It's a new page, so the other mockups are untouched (backup `site.bak-400-202610151309`). **What it does** - **Left → right:** Copy link and Open; a long swipe copies the link. In search, *Insert link here* joins them while a note is open behind search, and search stays open after it. - **Right → left:** Archive, Hide and Delete; a long swipe moves the note to the Trash, with Undo. Tags get Hide and Delete. Places get Hide only, so a long swipe there just opens the buttons. - **Trash:** Restore from the left. *Delete forever* is never a long swipe: the swipe only shows the button, which asks **Confirm** in place, and it turns back after 3 s. - **Archive and Hide, as you decided them:** - Archive: an **Archive** place appears in the sidebar once anything is archived, and a long swipe there unarchives. - Hide: hidden notes leave every list, search and Linked here. - In search, the words "archived" and "hidden" bring them back, and every result's ⋯ has **Show hidden items**. - Photos and files in search get Archive and Hide too. Blocks aren't in this mockup; that's the editor's side, with W20's `<!-- hidden -->`. - **Buttons:** soft tiles in the accent, plain or danger colours, with the icon over a short label. They're 64 px slots, at most 3 a side, inset 4 px from the row. They slide out from under the row in proportion as it moves. At the long-swipe point, the outer tile grows into one solid bar with a small spring bounce (iPhone gets no buzz; Android gets an 8 ms tick). - **Long press:** the preview card, with every action listed under it. No drag ghost and no callout. - **Desktop:** ⋯ on hover and on the focused row, the same menu on right-click, and ⌘↵ / ⌘C / ⌘⌫ / ⇧F10 on the focused row. Keys and menus never animate. **Still open: try them from the Mockup pill (top right on a phone)** - **W14, search's left → right order:** *Copy link first* (a long swipe copies, the same as everywhere else) or *Insert link first* (a long swipe inserts). `&slead=insert` - **W15, Pin:** only in the long-press card and ⋯ (default), or a third left → right button. `&pin=swipe` - **W16, Open as a swipe button:** on (default), or off so a tap opens. `&open=tap` ### Frame strip: a long swipe left to delete (390, real touch) The finger at −12 … −240 px, then crossing the long-swipe point (the tile grows into the bar), then let go, with the spring frozen and stepped through at +0 to +260 ms, and the list closing the gap. ![strip.png](https://git.kayg.org/attachments/c4f7e751-6560-4faa-988f-c0e7048d29c4) ### 390 wide **Notes, light:** rest · left → right mid-swipe · left → right open · right → left mid-swipe · long-swipe detent · deleted, with Undo · long-press card ![notes-390-light.png](https://git.kayg.org/attachments/d4fe2961-228c-489a-b1e1-9be70c6be41b) **Archive and the sidebar, light:** right → left open · the Archive place appears · long swipe to Unarchive · "archived" in search · a tag, right → left · a place, left → right ![archive-side-390-light.png](https://git.kayg.org/attachments/b1690711-e23f-4cfa-935a-148b13bf0575) **Search and the Trash, light:** left → right mid-swipe · long swipe (Copy link) · long-press card with Show hidden items · Trash, right → left open · Delete forever asks Confirm ![search-trash-390-light.png](https://git.kayg.org/attachments/f3b6d27f-4b56-4d94-9a48-c678e84daa21) **Notes, dark:** rest · left → right mid-swipe · left → right open · right → left mid-swipe · long-swipe detent · deleted, with Undo · long-press card ![notes-390-dark.png](https://git.kayg.org/attachments/86bd60b0-dd90-46eb-a692-887b6d5e45b3) **Archive and the sidebar, dark:** right → left open · the Archive place appears · long swipe to Unarchive · "archived" in search · a tag, right → left · a place, left → right ![archive-side-390-dark.png](https://git.kayg.org/attachments/1cc577a3-85bd-4019-a84b-e92f83224620) **Search and the Trash, dark:** left → right mid-swipe · long swipe (Copy link) · long-press card with Show hidden items · Trash, right → left open · Delete forever asks Confirm ![search-trash-390-dark.png](https://git.kayg.org/attachments/415f9085-15a8-4a7f-8d2a-07ccc985b6d5) ### 375 wide **Notes, light:** rest · left → right mid-swipe · left → right open · right → left mid-swipe · long-swipe detent · deleted, with Undo · long-press card ![notes-375-light.png](https://git.kayg.org/attachments/0d3a113a-9160-400e-8c11-b6b78e1880ca) **Archive and the sidebar, light:** right → left open · the Archive place appears · long swipe to Unarchive · "archived" in search · a tag, right → left · a place, left → right ![archive-side-375-light.png](https://git.kayg.org/attachments/26c6bdf2-d7f8-45e7-ba3e-d5d88f115198) **Search and the Trash, light:** left → right mid-swipe · long swipe (Copy link) · long-press card with Show hidden items · Trash, right → left open · Delete forever asks Confirm ![search-trash-375-light.png](https://git.kayg.org/attachments/1729b53c-42ce-4a8e-8f0b-6c2f654fb1bd) **Notes, dark:** rest · left → right mid-swipe · left → right open · right → left mid-swipe · long-swipe detent · deleted, with Undo · long-press card ![notes-375-dark.png](https://git.kayg.org/attachments/01231f80-0bc9-44f3-99c8-1c7ba817ed91) **Archive and the sidebar, dark:** right → left open · the Archive place appears · long swipe to Unarchive · "archived" in search · a tag, right → left · a place, left → right ![archive-side-375-dark.png](https://git.kayg.org/attachments/aefc382e-c9d5-42ab-8969-11f79f2d862c) **Search and the Trash, dark:** left → right mid-swipe · long swipe (Copy link) · long-press card with Show hidden items · Trash, right → left open · Delete forever asks Confirm ![search-trash-375-dark.png](https://git.kayg.org/attachments/21c6211c-05be-4c2e-b915-674db5714e22) ### 320 wide **Notes, light:** rest · left → right mid-swipe · left → right open · right → left mid-swipe · long-swipe detent · deleted, with Undo · long-press card ![notes-320-light.png](https://git.kayg.org/attachments/8699cf2b-815a-4740-a338-dd49ea40cf07) **Archive and the sidebar, light:** right → left open · the Archive place appears · long swipe to Unarchive · "archived" in search · a tag, right → left · a place, left → right ![archive-side-320-light.png](https://git.kayg.org/attachments/269978f3-6add-480e-8cc8-c6ffc076b2e9) **Search and the Trash, light:** left → right mid-swipe · long swipe (Copy link) · long-press card with Show hidden items · Trash, right → left open · Delete forever asks Confirm ![search-trash-320-light.png](https://git.kayg.org/attachments/1c7c1444-c5d3-4e49-9c9c-df53fa59d4e6) **Notes, dark:** rest · left → right mid-swipe · left → right open · right → left mid-swipe · long-swipe detent · deleted, with Undo · long-press card ![notes-320-dark.png](https://git.kayg.org/attachments/e7353ba2-fca2-435f-8ade-97f4a91a3e65) **Archive and the sidebar, dark:** right → left open · the Archive place appears · long swipe to Unarchive · "archived" in search · a tag, right → left · a place, left → right ![archive-side-320-dark.png](https://git.kayg.org/attachments/b0e9e44e-e647-4d68-8ddd-0227e5002e18) **Search and the Trash, dark:** left → right mid-swipe · long swipe (Copy link) · long-press card with Show hidden items · Trash, right → left open · Delete forever asks Confirm ![search-trash-320-dark.png](https://git.kayg.org/attachments/e62dc89d-141f-4d59-b0e1-87ca6b0bbb47) _At 390 light, the "long swipe" search frame shows the long-press card: the shared build host was busy enough that the hold won that one run. Every other width and theme shows the long-swipe bar._ ### 1440 **light:** ⋯ on hover · its menu · a mouse swipe · right-click in search ![desk-a-light.png](https://git.kayg.org/attachments/8e2ae87c-e356-42eb-87f2-2fa3d4dadbde) ![desk-b-light.png](https://git.kayg.org/attachments/ba9a75e1-db53-4e52-92ad-cdc2922717a4) **dark:** ⋯ on hover · its menu · a mouse swipe · right-click in search ![desk-a-dark.png](https://git.kayg.org/attachments/0d872994-097c-4569-b504-3d775fb4def4) ![desk-b-dark.png](https://git.kayg.org/attachments/4cbaae5c-f8c5-4a62-b774-2464e3eab342) **Noticed, not changed here:** at 320, the shared toast wraps "moved to Trash" mid-word ("Tras / h") next to Undo. That's the toast component's, not this PR's; it needs its own issue. ### iPhone checklist (emulation can't prove the gesture; please try these on the phone) Open the phone links above in Safari, and once more from the Home Screen app if you have it installed. Tick what works and note anything that doesn't. **Swiping a row** - [ ] In the note list, a quick sideways swipe moves the row with your finger, and the page does **not** scroll up or down at the same time. - [ ] A normal vertical scroll that starts on a row still scrolls, with momentum, and never nudges the row sideways. - [ ] A slightly diagonal scroll stays a scroll (the row only moves for clearly sideways swipes). - [ ] Past the buttons, the row stretches with resistance, and the stretch looks smooth with no stutter. - [ ] Crossing the long-swipe point, the outer button grows into a solid bar with a small bounce, and you can tell when you've crossed it. (There's no buzz on iPhone; this is on purpose, W8.) - [ ] Moving back before letting go shrinks the bar again, and nothing happens. - [ ] Letting go past half the buttons opens them. A quick flick opens them even from a short swipe. - [ ] A long swipe left on a note sends it to the Trash, the row flies out, the rows below close the gap, and the Undo toast brings it back. - [ ] A long swipe right copies the link and shows the check, and the row springs back. **Edges and other gestures** - [ ] Swiping back from the very left edge of the screen still goes back. It never opens a row. - [ ] Opening one row closes any other open row. - [ ] Tapping elsewhere, or scrolling, closes an open row. - [ ] Tapping an open row closes it and does **not** open the note. - [ ] In the sidebar, a press-and-drag still reorders rows. **Long press** - [ ] Holding a row (without moving) opens the card with the preview and every action listed under it. - [ ] No grey drag ghost of the row, no text selection, and no Safari callout (Copy / Share / link preview) appears. - [ ] Letting go after the card opens doesn't also open the note. - [ ] Tapping the preview opens the note. Tapping outside closes the card. **Search** (`?find=1&q=canal` with a note open) - [ ] Swiping a result right shows Copy link and Insert link here. A long swipe runs the first one. After Insert link here, search stays open and the link is in the note. - [ ] Holding a result shows its preview card with the actions, and no drag ghost (#399's bug). **Trash** - [ ] A long swipe left on a Trash row only opens the button. It never deletes. - [ ] Tapping Delete forever turns the button into Confirm, and only a second tap deletes. If you leave it, it changes back after 3 seconds. **Archive and Hide** (decided) - [ ] Archive a note: the Archive place appears in the sidebar, and a long swipe right there unarchives it. - [ ] Hide a note: it leaves the list. In search, typing "hidden" (or ⋯ → Show hidden items) brings it back. **Feel** - [ ] Nothing jumps at the moment the swipe starts. The row starts with your finger about 10 px away. - [ ] Rotating the phone or changing the text size doesn't break the button labels.
Author
Owner

Row changes from the chrome round are live on https://preview.calternal.cloud/swipe.html (PR #501) and chrome.html: no hover dots, one pill at a time, Copy link then Pin (Open is gone, a tap opens), a sideways trackpad scroll swipes rows, a full swipe springs back with a toast ('Link copied') or collapses with Undo. Details on #469.

Row changes from the chrome round are live on https://preview.calternal.cloud/swipe.html (PR #501) and chrome.html: no hover dots, one pill at a time, Copy link then Pin (Open is gone, a tap opens), a sideways trackpad scroll swipes rows, a full swipe springs back with a toast ('Link copied') or collapses with Undo. Details on #469.
Author
Owner

Approved by kayg on 2026-10-17 (IST morning): "the list view swipes are approved". This covers the swipe rows as on preview chrome.html and swipe.html: one pill at a time, the elastic outer pill, trackpad swipe, Copy link then Pin, a toast for what a swipe did, and one rowActions registry. Next: port them into the app (apps/web) on top of the list port slice 1 (#516).

**Approved by kayg on 2026-10-17 (IST morning):** "the list view swipes are approved". This covers the swipe rows as on preview `chrome.html` and `swipe.html`: one pill at a time, the elastic outer pill, trackpad swipe, Copy link then Pin, a toast for what a swipe did, and one rowActions registry. Next: port them into the app (`apps/web`) on top of the list port slice 1 (#516).
Author
Owner

Port rebased onto dev (train AA) and re-checked. PR into dev: #575

Gates (E2E_MATRIX=sample, --no-deps --workers=1; swipe-rows, touch-select, contrast, list-chrome, phone-bars):

  • chromium-1440: 13 passed
  • webkit-1440: 13 passed
  • chromium-390: 105 passed, 2 skipped (the first run had 2 phone-bars failures from two runs sharing one test-results folder; both pass alone)
  • webkit-390: 106 passed, 3 skipped
  • svelte-check: 0 errors. Editor unit tests: 186 passed.
  • actions.gen.ts was out of date on dev (attachments actions), so check failed there; regenerated in its own commit.

Perf (phone-size All notes, 10,000 notes, Chromium, CPU 4x, touch gestures, 60 per run, frame time of the frames while the finger moves; one run of 3 earlier under heavy host load is noted below):

run scroll p50 / p95 / >20 ms swipe p50 / p95 / >20 ms
1 16.7 / 16.8 / 0% 16.7 / 16.8 / 2%
2 16.7 / 16.7 / 0% 16.7 / 16.8 / 1%
3 16.7 / 16.8 / 0% 16.7 / 16.7 / 1%

Gate (swipe p95 within 2 ms of scroll p95, no more frames over 20 ms): p95 passes. Share over 20 ms is 1 to 2% for swipe against 0% for scroll. Scroll is now a pure compositor scroll on the new base, so it sits at the vsync floor. An earlier set of 3 runs (40 gestures) taken while the host was at load 10 to 13 showed swipe at p95 33 / 33 / 17 ms and 17% / 7% / 0% over 20 ms, with scroll at 16.8; the quiet-host rerun above did not reproduce it.

iPhone simulator (iOS 27, iPhone 18 Pro, Safari, new base). Icons and labels sit centred in each pill, and the pills are centred on the row, in light and dark.

Light Dark
Mid-swipe (held)
Long pull (outer pill armed)
Revealed, swiped right: Copy link, Pin
Revealed, swiped left: Delete
**Port rebased onto dev (train AA) and re-checked.** PR into dev: https://git.kayg.org/kayg/calternal/pulls/575 **Gates** (`E2E_MATRIX=sample`, `--no-deps --workers=1`; swipe-rows, touch-select, contrast, list-chrome, phone-bars): - chromium-1440: 13 passed - webkit-1440: 13 passed - chromium-390: 105 passed, 2 skipped (the first run had 2 phone-bars failures from two runs sharing one `test-results` folder; both pass alone) - webkit-390: 106 passed, 3 skipped - svelte-check: 0 errors. Editor unit tests: 186 passed. - `actions.gen.ts` was out of date on dev (attachments actions), so `check` failed there; regenerated in its own commit. **Perf** (phone-size All notes, 10,000 notes, Chromium, CPU 4x, touch gestures, 60 per run, frame time of the frames while the finger moves; one run of 3 earlier under heavy host load is noted below): | run | scroll p50 / p95 / >20 ms | swipe p50 / p95 / >20 ms | |---|---|---| | 1 | 16.7 / 16.8 / 0% | 16.7 / 16.8 / 2% | | 2 | 16.7 / 16.7 / 0% | 16.7 / 16.8 / 1% | | 3 | 16.7 / 16.8 / 0% | 16.7 / 16.7 / 1% | Gate (swipe p95 within 2 ms of scroll p95, no more frames over 20 ms): p95 passes. Share over 20 ms is 1 to 2% for swipe against 0% for scroll. Scroll is now a pure compositor scroll on the new base, so it sits at the vsync floor. An earlier set of 3 runs (40 gestures) taken while the host was at load 10 to 13 showed swipe at p95 33 / 33 / 17 ms and 17% / 7% / 0% over 20 ms, with scroll at 16.8; the quiet-host rerun above did not reproduce it. **iPhone simulator** (iOS 27, iPhone 18 Pro, Safari, new base). Icons and labels sit centred in each pill, and the pills are centred on the row, in light and dark. | | Light | Dark | |---|---|---| | Mid-swipe (held) | ![](https://git.kayg.org/attachments/b179b4b8-11d5-47fe-9414-1eaf4c3b2e37) | ![](https://git.kayg.org/attachments/5528c1e3-5515-4435-9c89-8639d08080d7) | | Long pull (outer pill armed) | ![](https://git.kayg.org/attachments/85d41dd3-beb6-496a-b850-b95dda142bec) | ![](https://git.kayg.org/attachments/823387ca-449e-4d5f-bf82-06af284aa2c4) | | Revealed, swiped right: Copy link, Pin | ![](https://git.kayg.org/attachments/aefe0079-d08b-427e-910a-2c3307382418) | ![](https://git.kayg.org/attachments/eedc1375-f388-474a-9c9e-a037a5e910e0) | | Revealed, swiped left: Delete | ![](https://git.kayg.org/attachments/c77fdeec-4351-4124-b0c7-023ca5473734) | ![](https://git.kayg.org/attachments/caaa1365-c953-4c1f-99a6-378f3c88b698) |
Author
Owner

Housekeeping: linked PR #575 is merged into dev. Comments record kayg’s approval of the requested swipe research/mockup and the completed port with browser and iPhone simulator evidence. Closing the completed issue.

Housekeeping: linked PR #575 is merged into dev. Comments record kayg’s approval of the requested swipe research/mockup and the completed port with browser and iPhone simulator evidence. Closing the completed issue.
kayg closed this issue 2026-11-10 16:07:20 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
kayg/calternal#400
No description provided.