@a3s-lab/office 0.6.0 → 0.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -150,9 +150,10 @@ round trip preserves supported and untouched unsupported OOXML.
150
150
 
151
151
  ### Phase 3: Presentation
152
152
 
153
- Status: browser collaboration foundation and native conflict-local scene-element
154
- mutations implemented; rich-text CRDT, structural native operations, and PPTX
155
- round-trip concurrency coverage are pending.
153
+ Status: browser collaboration foundation and native conflict-local
154
+ scene-element content and z-order mutations implemented; rich-text CRDT,
155
+ remaining structural native operations, and PPTX round-trip concurrency
156
+ coverage are pending.
156
157
 
157
158
  - Stable slide/master/layout order arrays and ID-keyed record maps avoid a
158
159
  serialized whole-deck root. Scene elements and slide comments are ID-keyed
@@ -171,21 +172,25 @@ round-trip concurrency coverage are pending.
171
172
  - Tests cover bootstrap, identity validation, separate-record convergence,
172
173
  stale snapshots, concurrent comments, local-only undo, permissions, mounted
173
174
  projection, and framework adapters.
174
- - Rust, CLI, MCP, and A3S Code can create, optimistically update, or tombstone
175
- one element in a slide, master, or layout. Creation can insert after a stable
176
- active element. Update compares complete expected/current/next records and
177
- writes only changed top-level fields, so unrelated concurrent changes merge
178
- while a stale same-field edit fails atomically. Delete requires an exact
179
- complete-element match. Browser/Yrs fixtures, native restart, duplicate and
180
- reordered delivery, real CLI/MCP subprocesses, and the Playground cover the
181
- same lifecycle.
175
+ - Rust, CLI, MCP, and A3S Code can create, optimistically update, move, or
176
+ tombstone one element in a slide, master, or layout. Creation can insert
177
+ after a stable active element. Update compares complete
178
+ expected/current/next records and writes only changed top-level fields, so
179
+ unrelated concurrent changes merge while a stale same-field edit fails
180
+ atomically. Move compares stable observed and requested predecessor IDs,
181
+ treats an already-satisfied destination as idempotent, and changes only the
182
+ moved element's order entry; `null` means the first order position. Delete
183
+ requires an exact complete-element match. Browser/Yrs fixtures, native
184
+ restart, duplicate and reordered delivery, real CLI/MCP subprocesses, and
185
+ the Playground cover update/create/move/delete interoperability.
182
186
 
183
187
  Remaining:
184
188
 
185
189
  - Bind editable scene text to collaborative XML fragments instead of scalar
186
190
  text/run replacement.
187
191
  - Add structural native operations and explicit conflict handling for slide
188
- order, z-order, grouping, and theme changes.
192
+ order, grouping, and theme changes; extend z-order beyond stable scene-element
193
+ moves where a concrete browser workflow requires it.
189
194
  - Keep derived thumbnails and layout measurements local and prove this in UI
190
195
  tests.
191
196
  - Add offline/reordered-update property tests plus merged PPTX export/reopen.
@@ -389,10 +394,11 @@ projection are pending.
389
394
  an exact complete-cell match. They preserve the browser's field-addressed
390
395
  representation, dense/sparse projection mode, and atomic fail-closed
391
396
  semantics without replacing a worksheet or workbook.
392
- - Presentation scene-element mutations create, update, or tombstone one stable
393
- object inside a slide, master, or layout. Canonical creation claims prevent
394
- conflicting same-ID reuse, optimistic top-level field guards merge unrelated
395
- concurrent edits, and exact deletion guards prevent a stale destructive
397
+ - Presentation scene-element mutations create, update, move, or tombstone one
398
+ stable object inside a slide, master, or layout. Canonical creation claims
399
+ prevent conflicting same-ID reuse, optimistic top-level field guards merge
400
+ unrelated concurrent edits, stable predecessor guards move one order entry
401
+ without array indexes, and exact deletion guards prevent a stale destructive
396
402
  write without replacing the deck or container.
397
403
  - PDF form-value mutations write the browser-compatible conflict-local record
398
404
  roots by fully-qualified field name, retain idempotent receipts and optional
@@ -422,7 +428,7 @@ projection are pending.
422
428
  an authorization token.
423
429
  - Cross-language tests apply deterministic native UTF-16 Markdown, ProseMirror
424
430
  Document text/options/paragraph, Spreadsheet cell, Presentation
425
- scene-element, and PDF annotation/form-value updates in browser Yjs,
431
+ scene-element content/z-order, and PDF annotation/form-value updates in browser Yjs,
426
432
  including concurrent browser/native paragraph, cell-leaf, element-field,
427
433
  annotation-leaf, and PDF form edits, in addition to importing browser Yjs
428
434
  fixtures in Yrs.
@@ -432,7 +438,7 @@ projection are pending.
432
438
 
433
439
  Remaining:
434
440
 
435
- - Extend typed format-model mutations to Spreadsheet and Presentation
441
+ - Extend typed format-model mutations to Spreadsheet and remaining Presentation
436
442
  structural/rich-text operations plus PDF signatures; deepen Document
437
443
  mutations to additional nested structures and review operations, and add
438
444
  durable comment/suggest operations before enabling those modes for local
package/README.md CHANGED
@@ -139,9 +139,9 @@ The images below are committed visual-regression baselines from the real
139
139
  server, and Office Skill share bounded mutation contracts. Coding agents can
140
140
  also keep a durable Yrs replica, exchange standard Yjs v1 updates and state
141
141
  vectors, perform authorized typed Markdown, Document, Spreadsheet cell,
142
- Presentation scene-element, and PDF annotation, form-value, and review
143
- changes, retain browser/native actor attribution, and checkpoint without
144
- replacing a whole Office file.
142
+ Presentation scene-element and z-order, and PDF annotation, form-value, and
143
+ review changes, retain browser/native actor attribution, and checkpoint
144
+ without replacing a whole Office file.
145
145
 
146
146
  ## Quick start
147
147
 
@@ -1038,6 +1038,14 @@ cargo run -p a3s-office-cli -- collab mutate .a3s/deck.replica \
1038
1038
  --operation-id edit-46 \
1039
1039
  --mutation '{"type":"presentation-update-element","containerKind":"slide","containerId":"slide-1","elementId":"title-1","expectedElement":{"id":"title-1","type":"text","x":10,"y":10,"width":80,"height":20,"text":"Draft"},"nextElement":{"id":"title-1","type":"text","x":16,"y":10,"width":80,"height":20,"text":"Final"}}' --json
1040
1040
 
1041
+ # Move that element to the first order position after verifying its currently
1042
+ # observed predecessor. Destination and source positions use stable IDs, not
1043
+ # array indexes; null means no predecessor.
1044
+ cargo run -p a3s-office-cli -- collab mutate .a3s/deck.replica \
1045
+ --artifact-id deck --kind presentation --actor-id agent-7 --mode edit \
1046
+ --operation-id move-46 \
1047
+ --mutation '{"type":"presentation-move-element","containerKind":"slide","containerId":"slide-1","elementId":"title-1","expectedAfterElementId":"background-1","afterElementId":null}' --json
1048
+
1041
1049
  # Set one PDF form value through its stable fully-qualified field name.
1042
1050
  cargo run -p a3s-office-cli -- collab mutate .a3s/application.replica \
1043
1051
  --artifact-id application --kind pdf --actor-id agent-7 --mode edit \
@@ -1106,8 +1114,13 @@ plus a canonical immutable claim inside a slide, master, or layout and can
1106
1114
  place it after a stable active element. Presentation update compares complete
1107
1115
  expected/current/next elements and writes only changed top-level fields, so
1108
1116
  unrelated concurrent geometry, text, or style changes merge while a stale
1109
- same-field edit fails. Exact deletion writes a durable tombstone, and element
1110
- IDs and types never drift or become reusable. PDF annotation creation accepts the
1117
+ same-field edit fails. Presentation move compares the stable observed and
1118
+ requested predecessor IDs instead of array indexes; `null` means the first
1119
+ element-order position. An already-satisfied destination is idempotent, while
1120
+ a stale source position or unavailable anchor fails before a durable update.
1121
+ Only the moved element's order entry changes; no object fields, container, or
1122
+ deck are replaced. Exact deletion writes a durable tombstone, and element IDs
1123
+ and types never drift or become reusable. PDF annotation creation accepts the
1111
1124
  portable browser record for FreeText, Highlight, Underline, StrikeOut, or Ink,
1112
1125
  writes `source: created`, and commits its immutable claim atomically. An update
1113
1126
  supplies complete `expectedAnnotation` and `nextAnnotation` values; recursive
@@ -1185,6 +1198,7 @@ without hard-coded return URLs.
1185
1198
 
1186
1199
  - [Live Playground](https://a3s-lab.github.io/Office/)
1187
1200
  - [Documentation center](https://a3s-lab.github.io/Office/docs/)
1201
+ - [A3S Office 0.7.0 documentation](https://a3s-lab.github.io/Office/docs/0.7.0/)
1188
1202
  - [A3S Office 0.6.0 documentation](https://a3s-lab.github.io/Office/docs/0.6.0/)
1189
1203
  - [A3S Office 0.5.0 documentation](https://a3s-lab.github.io/Office/docs/0.5.0/)
1190
1204
  - [A3S Office 0.4.0 documentation](https://a3s-lab.github.io/Office/docs/0.4.0/)
Binary file
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@a3s-lab/office",
3
- "version": "0.6.0",
3
+ "version": "0.7.0",
4
4
  "description": "Open-source browser editors for documents, Markdown, spreadsheets, presentations, and PDFs.",
5
5
  "keywords": [
6
6
  "office",