divan/web/package.json
Anas Rashid 267c693c87 Urdu content editor on Tiptap (#28): structured editing of Divan text, with the source view
- web/src/lib/editor.ts (Tiptap 3 MIT core): verse units of misras (1 = مصرع, 2 = شعر, 3+ = بند, as in
  Divan text) with مطلع/حسن مطلع/مقطع labels, prose paragraphs, chapter headings and sub-headings, a
  dictionary-link mark, footnotes and variant readings; Enter adds a misra (or moves into the next
  empty one), Enter on an empty misra starts a new unit.
- Revision page: editor and source tabs over the same text, the work's data points as rows, a
  toolbar (couplet, paragraph, headings, labels, dictionary link, footnote, variant, undo/redo,
  Roman typing, Urdu keyboard). Saving always sends Divan text.
- Divan text: inline segments keep where links, footnotes and variants sit; toText writes a
  document back. All 11,087 works round-trip unchanged through toText and through the editor.
- The Urdu keyboard and Roman typing type into rich editors; the reader's word sidebar and
  selection menu stay out of editors.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-09 00:53:17 +02:00

23 lines
626 B
JSON

{
"name": "divan-web",
"private": true,
"type": "module",
"description": "Divan website (Astro, server-rendered) over the Divan API",
"scripts": {
"dev": "astro dev --port 4200",
"build": "astro build",
"start": "node dist/server/entry.mjs"
},
"dependencies": {
"@astrojs/node": "^11.1.7",
"@fontsource/noto-naskh-arabic": "^5.3.0",
"@fontsource/noto-nastaliq-urdu": "^5.3.0",
"@tiptap/core": "^3.31.4",
"@tiptap/extension-document": "^3.31.4",
"@tiptap/extension-text": "^3.31.4",
"@tiptap/extensions": "^3.31.4",
"@tiptap/pm": "^3.31.4",
"astro": "^7.3.8"
}
}