PureXML/Sources/Model
Mihaela Mihaljevic d667b4cf1e feat(editor): structured quick-fixes from completions
Slice 4 of #94 (completes the epic). Quick-fixes are derived from the structured
schema completions, never by parsing a diagnostic message:

- TreeNode gains contentRange (the span between an element's start and end tags),
  captured by the ranged reader, so an inserted attribute or child is placed
  exactly.
- QuickFix and TextEdit model an editor edit (a replacement over a source range;
  an insertion is a zero-width range).
- QuickFixEngine turns a Completions into fixes: a required-but-absent attribute
  becomes an insertion before the start tag's >, and a still-expected required
  child becomes an insertion before the end tag. Schema.Document.quickFixes(at:in:)
  is the entry over a ranged tree.

Tests apply a fix and re-validate: adding the required id, or inserting the
required qty, yields XML the schema then accepts; a complete element offers none.

#94 (editor integration) is complete: ranged recovering read, unified lint,
schema completions, and quick-fixes.
2026-06-08 13:35:33 +02:00
..
Attribute.swift chore: scaffold PureXML pure-Swift XML package 2026-06-07 23:20:20 +02:00
Element.swift chore: scaffold PureXML pure-Swift XML package 2026-06-07 23:20:20 +02:00
Node.swift chore: scaffold PureXML pure-Swift XML package 2026-06-07 23:20:20 +02:00
QualifiedName.swift feat(parser): resolve XML namespaces at the start-element boundary 2026-06-08 01:03:29 +02:00
TreeNode.swift feat(editor): structured quick-fixes from completions 2026-06-08 13:35:33 +02:00
TreeNodeConversion.swift feat(model): mutable parent-aware tree (libxml2 tree.h parity) 2026-06-08 03:13:59 +02:00
TreeNodeMutation.swift feat(model): mutable parent-aware tree (libxml2 tree.h parity) 2026-06-08 03:13:59 +02:00
TreeNodeNavigation.swift feat(model): mutable parent-aware tree (libxml2 tree.h parity) 2026-06-08 03:13:59 +02:00
TreeNodeSpan.swift feat(editor): source spans on the tree, mapping findings to positions 2026-06-08 13:14:29 +02:00