Commit Graph
9 Commits
Author SHA1 Message Date
DarkSky 531da7466d feat(editor): add S3 rich blocks, live CRDT table cells, and mobile input
Add the S3 PageEditor stack on top of darksky/np/mobile:

- Read and render seven rich block kinds (callout, table, attachment,
  LaTeX, embed linked doc, embed synced doc, and surface ref) with pure
  Rust RaTeX math layout, syntax highlighting, Hayro PDF previews, and
  shared premultiplied RGBA-to-BGRA conversion via ui::swap_rgba_pa_to_bgra.
- Replace offline table cell string diffing and the conflict popover
  with direct in-place Y.Text CRDT splicing, O(1) read_table_block with
  zero-clone replacement, split_delta preedit, and RichParagraph cells.
- Share insertion_marks_at across paragraphs, table cells, surface
  elements, and block titles via single-delta splice_live_text; share
  AnchoredInlineInput and finish_inline_targets across table cells and
  Edgeless labels with unselected root-input suppression and same-target
  preedit commit on pointer press.
- Land mobile keyboard toolbar with 0.27.5 @blocksuite/icons tokens,
  bidi selection, touch gestures, native web clipboard paste, shared
  HTML/Markdown slice builders, and host-layer Emoji font registration.
2026-11-27 06:55:48 +09:00
DarkSky b21a21e30e fix(mobile): polish breadcrumb switcher, blank page placeholders, and delete confirmation sheet
Keep multi-location breadcrumb switcher chips visible with their dropdown chevron across narrow viewports and locales. Preserve the location count suffix while truncating only the owner document title.

Render high-contrast muted placeholders on blank documents using static empty-state copy, keep primary text color for non-empty body previews, and keep display titles in lists, breadcrumbs, trash pages, and accessibility landmarks.

Remove the ambiguous Done button from the permanent delete confirmation sheet in both the view and the accessibility tree.
2026-11-27 06:55:48 +09:00
DarkSky 9a3195bf81 feat(mobile): add S3 mobile shell, breadcrumb engine, and outbound doc refs
Implement the S3-Shell deliverables across L1 to L4:
- Add read-only outbound document reference extraction in `blocksuite/crates/doc/src/refs.rs` with zero-writeback tests.
- Add baked keyframe micro-icons, domain-neutral Breadcrumb layout, and RTL mirror tests in `packages/ui/kit`.
- Add sanitized FolderForest caching, NavHistory with 128-entry cap, pure breadcrumb derivation, and LinkGraph backlinks in `packages/frontend/client`.
- Add `affine-mobile` with interactive 4-TabBar routes, 10-section Settings, Location and Trail sheet, and `mobile-harness`.
2026-11-27 06:55:48 +09:00
DarkSky 0036df69b5 fix(frontend): close S2.1 parity gaps across editor, web, and CI
Close the S2.1 parity and review items across the editor, web host,
and CI workflows.

- Add affine:latex block layout and the equation editor popover.
- Support Space and Enter triggers, inline rendering, click-to-edit
  chips, IME commit on Done, and Web slash copy.
- Guard open equations with zero-width CRDT identity checks and skip
  writes when closing an unchanged equation.

- Align web sign-in OTP validation, resend state, anti-reentry,
  cross-Back cooldown, preflight races, and initial OTP errors.
- Align step-bound email submit, deployment Terms display, and native
  Chromium discovery in verify-idb-real-browser.

- Key WebTextSystem Canvas fallback descriptors by logical font ID so
  static single-face fonts preserve requested weights.
- Keep Release LTO active for s1-probes-bench in np-mobile.yml.
2026-11-27 06:55:48 +09:00
DarkSky 7fb559c89f fix(frontend): close S2 post-review edge cases across web, client, ios, and android
Address edge cases identified during the S2 review rounds:

- Make `extractYjsV1SubdocEntries` iterative on `origin` chains, binary-search
  merged `DeleteSet` ranges, require the trailing `DeleteSet` count on every
  update, and resolve concurrent `Y.Map` writes deterministically via YATA
  sibling ordering.
- Clear stale password and OTP inputs when returning to the email step in
  `sign-in.js`, run `/api/auth/preflight` on every email-step submit, and
  clarify the status message when email login is disabled while OAuth remains
  available.
- Guard `is_valid_rfc3339` against non-ASCII slices and invalid calendar days,
  enforce `1..=86400` `expiresIn` and non-empty token invariants in
  `StoredAuthTokenPair`, make `AuthController::load_stored_credentials`
  read-only on `HostBridge`, and add epoch-fenced session response helpers.
- Preserve same-ID `affine-cloud` `last_workspace_id` entries when removing a
  local workspace in `HostBootstrapCoordinator.swift` and `legacy_storage.rs`.
- Persist `auth-refresh-attempt:<endpoint>` digests across Android process
  restarts, preserve `FreshInstall` state across rollback write-back, surface
  legacy `affine.preferences_pb` cleanup failures from `deleteSession`, remove
  test-only JNI exports from `NativeBridge`, and gate `touch_dispatch.rs` on
  `#![cfg(feature = "harness")]`.
2026-11-27 06:55:48 +09:00
DarkSky 6efd971122 feat(editor): add web CJK/RTL fallback, touch dispatch, and BlockSuite parity
Enable browser Canvas CJK and fullwidth punctuation fallback by default,
bundle Noto Sans Arabic and Noto Sans Hebrew for native RTL shaping, and
bridge touch tap and pan gestures to window mouse and scroll listeners.

Align BlockSuite editor behavior with Web:
- Trigger the linked-doc menu on mid-word `@`, `[[`, and `【【`.
- Add all eight inline Markdown rules on ASCII space or Enter with IME
  guards and non-leaking trailing space or pending marks.
- Support block-level Markdown on Enter and inside list and quote blocks.
- Outdent nested empty list items on Enter and exit quote blocks on two
  Enter keys without an extra blank paragraph.
- Use subsequence fuzzy matching in the slash menu, pass through Enter
  and arrow keys when in-document search has no match, and split Linked
  Page into New Doc and Linked Doc commands.
- Add block conversion shortcuts, Mod-k link focus, and Escape / second
  Mod-a whole-block selection.
2026-11-27 06:55:48 +09:00
DarkSky 8e0b345036 feat(editor): extract ui-tokens, ui-kit, and blocksuite-editor crates
Add the zero-dependency ui-tokens crate to export generated theme tokens,
icon definitions, and bundled font bytes without cross-tree include_bytes!
paths.

Add the domain-neutral ui-kit crate with logical geometry helpers, SafeArea,
VirtualList, SwipeDialog, and SwipeMenu state machines backed by scheduler
time and four-rate replay invariance tests.

Extract blocksuite-editor from playground with the WorkspaceDocDirectory
host port, exact substring UTF-16 highlight matching, and LTR/RTL logical
start/end block flow layout. Slim playground to the demo and harness host.
Update workspace manifests, static invariant guards, CI workflows, and
AGENTS.md files.
2026-11-27 06:55:47 +09:00
DarkSky 0c9e634d08 feat(ui): add L0 mobile logical layout, bidi shaping, gestures, motion, web safe-area and iOS foundation
- Add logical geometry helpers on Edges, Corners, Svg, and scroll offsets, and propagate inherited LayoutDirection through Taffy and fast splice rebuilds with a zero-clone LTR fast path.
- Propagate explicit BaseDirection through LineLayoutCache and all platform shapers (Apple CoreText, CosmicText, and Web), sort visual clusters by x_start, add UAX #9 multi-line soft-wrap bidi reordering, preserve contextual Arabic joining across same-font runs, and align text truncation on shaped glyph-cluster boundaries (`UI_LOC_CEILING = 95200`).
- Add scheduler-clock TouchGestureRecognizer with tap, long-press timer wakeup, pan cancellation, pinch re-anchoring, and closed-form MotionCurve presets including SwipeMenu InOutSine and SwipeDialog cubic-bezier/outQuad.
- Replace Web four-element safe-area probing with a single hidden probe and exact per-edge float comparison, preserving non-double-subtracted IME insets.
- Align the iOS platform stub traits and PlatformInfo, update packages/ui/AGENTS.md, and add aarch64-apple-ios and aarch64-apple-ios-sim compile guards to native-playground CI.
2026-11-27 06:55:47 +09:00
DarkSky 6f9f1cace5 refactor(workspace): dissolve native-playground into domain directories 2026-11-27 06:55:47 +09:00