@embedpdf/viewer-chrome 3.0.0-next.14 → 3.0.0-next.16

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.
Files changed (177) hide show
  1. package/README.md +175 -132
  2. package/dist/annotation-fonts-DWjVOTP0.js +80 -0
  3. package/dist/annotation-fonts-DWjVOTP0.js.map +1 -0
  4. package/dist/annotation-fonts-dpfVkhnq.cjs +91 -0
  5. package/dist/annotation-fonts-dpfVkhnq.cjs.map +1 -0
  6. package/dist/annotation-style-B3XKAyZ-.cjs +879 -0
  7. package/dist/annotation-style-B3XKAyZ-.cjs.map +1 -0
  8. package/dist/annotation-style-CXF3X47Z.js +879 -0
  9. package/dist/annotation-style-CXF3X47Z.js.map +1 -0
  10. package/dist/ar-B132r9bo.cjs +659 -0
  11. package/dist/ar-B132r9bo.cjs.map +1 -0
  12. package/dist/ar-BLWFJoA_.js +659 -0
  13. package/dist/ar-BLWFJoA_.js.map +1 -0
  14. package/dist/attachments-panel-Cxln8xos.cjs +217 -0
  15. package/dist/attachments-panel-Cxln8xos.cjs.map +1 -0
  16. package/dist/attachments-panel-H1ucRbwo.js +217 -0
  17. package/dist/attachments-panel-H1ucRbwo.js.map +1 -0
  18. package/dist/chrome.cjs +399 -242
  19. package/dist/chrome.cjs.map +1 -1
  20. package/dist/chrome.d.cts +5 -35
  21. package/dist/chrome.d.ts +5 -35
  22. package/dist/chrome.js +398 -239
  23. package/dist/chrome.js.map +1 -1
  24. package/dist/commands-BkgLP3Om.js +1348 -0
  25. package/dist/commands-BkgLP3Om.js.map +1 -0
  26. package/dist/commands-DL1gjZt7.cjs +1473 -0
  27. package/dist/commands-DL1gjZt7.cjs.map +1 -0
  28. package/dist/commands.cjs +13 -649
  29. package/dist/commands.d.cts +30 -3
  30. package/dist/commands.d.ts +30 -3
  31. package/dist/commands.js +2 -647
  32. package/dist/comments-panel-BsnWedTh.cjs +514 -0
  33. package/dist/comments-panel-BsnWedTh.cjs.map +1 -0
  34. package/dist/comments-panel-D7Eadws9.js +514 -0
  35. package/dist/comments-panel-D7Eadws9.js.map +1 -0
  36. package/dist/de-7_MvFWzN.cjs +658 -0
  37. package/dist/de-7_MvFWzN.cjs.map +1 -0
  38. package/dist/de-BUhwc9-x.js +658 -0
  39. package/dist/de-BUhwc9-x.js.map +1 -0
  40. package/dist/dialog-BIb373cg.js +55 -0
  41. package/dist/dialog-BIb373cg.js.map +1 -0
  42. package/dist/dialog-CngKTnAM.cjs +60 -0
  43. package/dist/dialog-CngKTnAM.cjs.map +1 -0
  44. package/dist/es-DgYj-1L3.cjs +658 -0
  45. package/dist/es-DgYj-1L3.cjs.map +1 -0
  46. package/dist/es-DoXTqFoO.js +658 -0
  47. package/dist/es-DoXTqFoO.js.map +1 -0
  48. package/dist/form-design-panel-CgV_5YWC.js +418 -0
  49. package/dist/form-design-panel-CgV_5YWC.js.map +1 -0
  50. package/dist/form-design-panel-D0FdmWXW.cjs +418 -0
  51. package/dist/form-design-panel-D0FdmWXW.cjs.map +1 -0
  52. package/dist/fr-B-8NDhBA.js +658 -0
  53. package/dist/fr-B-8NDhBA.js.map +1 -0
  54. package/dist/fr-C856dmQJ.cjs +658 -0
  55. package/dist/fr-C856dmQJ.cjs.map +1 -0
  56. package/dist/he-BFTeNc4t.cjs +659 -0
  57. package/dist/he-BFTeNc4t.cjs.map +1 -0
  58. package/dist/he-Dlh0fNXM.js +659 -0
  59. package/dist/he-Dlh0fNXM.js.map +1 -0
  60. package/dist/icons-1UfLUZ_y.cjs +1029 -0
  61. package/dist/icons-1UfLUZ_y.cjs.map +1 -0
  62. package/dist/icons-7dB0Y1ct.js +875 -0
  63. package/dist/icons-7dB0Y1ct.js.map +1 -0
  64. package/dist/index.cjs +3651 -5447
  65. package/dist/index.cjs.map +1 -1
  66. package/dist/index.d.cts +646 -144
  67. package/dist/index.d.ts +646 -144
  68. package/dist/index.js +3618 -5368
  69. package/dist/index.js.map +1 -1
  70. package/dist/it-Bef-2Yxq.cjs +658 -0
  71. package/dist/it-Bef-2Yxq.cjs.map +1 -0
  72. package/dist/it-BkirG7ol.js +658 -0
  73. package/dist/it-BkirG7ol.js.map +1 -0
  74. package/dist/ja-CGEjCE-s.js +658 -0
  75. package/dist/ja-CGEjCE-s.js.map +1 -0
  76. package/dist/ja-DNw2zqSD.cjs +658 -0
  77. package/dist/ja-DNw2zqSD.cjs.map +1 -0
  78. package/dist/ko-CTkl5vMh.js +658 -0
  79. package/dist/ko-CTkl5vMh.js.map +1 -0
  80. package/dist/ko-YHzeBqP6.cjs +658 -0
  81. package/dist/ko-YHzeBqP6.cjs.map +1 -0
  82. package/dist/labels-BiM9wp9K.cjs +21 -0
  83. package/dist/labels-BiM9wp9K.cjs.map +1 -0
  84. package/dist/labels-C6_i87Oj.js +16 -0
  85. package/dist/labels-C6_i87Oj.js.map +1 -0
  86. package/dist/link-editor-CAS7MZM2.cjs +125 -0
  87. package/dist/link-editor-CAS7MZM2.cjs.map +1 -0
  88. package/dist/link-editor-CkwtqRvb.js +125 -0
  89. package/dist/link-editor-CkwtqRvb.js.map +1 -0
  90. package/dist/measurement-CQdbnIrn.js +325 -0
  91. package/dist/measurement-CQdbnIrn.js.map +1 -0
  92. package/dist/measurement-Cxv1Ahxx.cjs +326 -0
  93. package/dist/measurement-Cxv1Ahxx.cjs.map +1 -0
  94. package/dist/nl-BjkbaLq3.cjs +658 -0
  95. package/dist/nl-BjkbaLq3.cjs.map +1 -0
  96. package/dist/nl-Dya4sR8_.js +658 -0
  97. package/dist/nl-Dya4sR8_.js.map +1 -0
  98. package/dist/outline-panel-BpGtBdj0.cjs +707 -0
  99. package/dist/outline-panel-BpGtBdj0.cjs.map +1 -0
  100. package/dist/outline-panel-DO5_REYw.js +707 -0
  101. package/dist/outline-panel-DO5_REYw.js.map +1 -0
  102. package/dist/outline-properties-BCa2cc0t.js +330 -0
  103. package/dist/outline-properties-BCa2cc0t.js.map +1 -0
  104. package/dist/outline-properties-DT3FIxCw.cjs +330 -0
  105. package/dist/outline-properties-DT3FIxCw.cjs.map +1 -0
  106. package/dist/pl-CKKdVnpZ.cjs +658 -0
  107. package/dist/pl-CKKdVnpZ.cjs.map +1 -0
  108. package/dist/pl-DA9b5NVg.js +658 -0
  109. package/dist/pl-DA9b5NVg.js.map +1 -0
  110. package/dist/print-dialog-BqIrHCBh.cjs +276 -0
  111. package/dist/print-dialog-BqIrHCBh.cjs.map +1 -0
  112. package/dist/print-dialog-DvcI2m2_.js +276 -0
  113. package/dist/print-dialog-DvcI2m2_.js.map +1 -0
  114. package/dist/pt-DLcszlzi.cjs +658 -0
  115. package/dist/pt-DLcszlzi.cjs.map +1 -0
  116. package/dist/pt-Nm8yyjbX.js +658 -0
  117. package/dist/pt-Nm8yyjbX.js.map +1 -0
  118. package/dist/redact-confirm-C6EiK8yN.cjs +83 -0
  119. package/dist/redact-confirm-C6EiK8yN.cjs.map +1 -0
  120. package/dist/redact-confirm-CKuv9iN_.js +83 -0
  121. package/dist/redact-confirm-CKuv9iN_.js.map +1 -0
  122. package/dist/redaction-panel-CgNZ-pQk.js +96 -0
  123. package/dist/redaction-panel-CgNZ-pQk.js.map +1 -0
  124. package/dist/redaction-panel-ZhX0dlMi.cjs +96 -0
  125. package/dist/redaction-panel-ZhX0dlMi.cjs.map +1 -0
  126. package/dist/search-panel-BE4xzWlm.js +249 -0
  127. package/dist/search-panel-BE4xzWlm.js.map +1 -0
  128. package/dist/search-panel-wcbTNG1z.cjs +249 -0
  129. package/dist/search-panel-wcbTNG1z.cjs.map +1 -0
  130. package/dist/sheet-DTBFiwde.cjs +461 -0
  131. package/dist/sheet-DTBFiwde.cjs.map +1 -0
  132. package/dist/sheet-DyjKfAq0.js +378 -0
  133. package/dist/sheet-DyjKfAq0.js.map +1 -0
  134. package/dist/sign-dialog-D5WGx-Yn.cjs +155 -0
  135. package/dist/sign-dialog-D5WGx-Yn.cjs.map +1 -0
  136. package/dist/sign-dialog-DerNe8qT.js +155 -0
  137. package/dist/sign-dialog-DerNe8qT.js.map +1 -0
  138. package/dist/signature-inspector-Bz6TAfZM.cjs +160 -0
  139. package/dist/signature-inspector-Bz6TAfZM.cjs.map +1 -0
  140. package/dist/signature-inspector-CsGr9EBk.js +160 -0
  141. package/dist/signature-inspector-CsGr9EBk.js.map +1 -0
  142. package/dist/signature-maker-D_YfBXLn.cjs +393 -0
  143. package/dist/signature-maker-D_YfBXLn.cjs.map +1 -0
  144. package/dist/signature-maker-Dnth4rV4.js +393 -0
  145. package/dist/signature-maker-Dnth4rV4.js.map +1 -0
  146. package/dist/signatures-panel-Ci_LaI1C.cjs +294 -0
  147. package/dist/signatures-panel-Ci_LaI1C.cjs.map +1 -0
  148. package/dist/signatures-panel-DZ9ywrjz.js +294 -0
  149. package/dist/signatures-panel-DZ9ywrjz.js.map +1 -0
  150. package/dist/stamp-store-BHvRs-Do.cjs +147 -0
  151. package/dist/stamp-store-BHvRs-Do.cjs.map +1 -0
  152. package/dist/stamp-store-WuF-L3Jj.js +112 -0
  153. package/dist/stamp-store-WuF-L3Jj.js.map +1 -0
  154. package/dist/stamps-panel-BrczStaz.js +225 -0
  155. package/dist/stamps-panel-BrczStaz.js.map +1 -0
  156. package/dist/stamps-panel-Cv9nJBwx.cjs +225 -0
  157. package/dist/stamps-panel-Cv9nJBwx.cjs.map +1 -0
  158. package/dist/theme-Be0OZokZ.js +97 -0
  159. package/dist/theme-Be0OZokZ.js.map +1 -0
  160. package/dist/theme-FR26JI3r.cjs +126 -0
  161. package/dist/theme-FR26JI3r.cjs.map +1 -0
  162. package/dist/toolbar-DF361xWY.js +1565 -0
  163. package/dist/toolbar-DF361xWY.js.map +1 -0
  164. package/dist/toolbar-ddvpsvTb.cjs +1660 -0
  165. package/dist/toolbar-ddvpsvTb.cjs.map +1 -0
  166. package/dist/zh-cn-BMPPkLpL.js +658 -0
  167. package/dist/zh-cn-BMPPkLpL.js.map +1 -0
  168. package/dist/zh-cn-CZOO3p4H.cjs +658 -0
  169. package/dist/zh-cn-CZOO3p4H.cjs.map +1 -0
  170. package/package.json +6 -4
  171. package/src/styles.css +161 -89
  172. package/dist/commands.cjs.map +0 -1
  173. package/dist/commands.js.map +0 -1
  174. package/dist/es-BXLlBo2b.cjs +0 -321
  175. package/dist/es-BXLlBo2b.cjs.map +0 -1
  176. package/dist/es-CLgTsFDS.js +0 -321
  177. package/dist/es-CLgTsFDS.js.map +0 -1
@@ -0,0 +1 @@
1
+ {"version":3,"file":"zh-cn-CZOO3p4H.cjs","names":[],"sources":["../src/locales/zh-cn.ts"],"sourcesContent":["import type { Locale } from '@embedpdf/react/i18n';\n\n/**\n * Simplified Chinese pack, in the words Adobe Acrobat's Simplified Chinese edition uses.\n * Machine-translated from the English pack (`./en.ts`) and not yet reviewed by a native speaker.\n */\nexport const zhCN: Locale = {\n code: 'zh-CN',\n name: '简体中文',\n translations: {\n measurement: {\n title: '测量',\n distance: '距离',\n perimeter: '周长',\n area: '面积',\n areaUnit: '面积单位',\n resetLabel: '重置标签位置',\n calibrate: '校准比例',\n scale: '比例',\n custom: '自定义',\n unavailable: '不可用',\n instructions:\n '拖动以测量距离,然后单击以放置尺寸线。单击各个顶点以测量周长或面积,双击完成。面积边界不得交叉;不可用的预览无法完成。按 Escape 取消。拖动标签本身可移动标签。',\n sessionOnly: '此引擎仅在本次会话中保留页面校准。',\n allPages: '应用于所有页面',\n recalculate: '重新计算现有测量',\n preset: '比例预设',\n choosePreset: '选择预设',\n unit: '单位',\n precision: '精度',\n selection: '所选测量',\n report: '已更新 {updated} 项 · 已跳过 {skipped} 项 · 失败 {failed} 项',\n knownLength: '输入您刚绘制的线条所代表的实际长度。',\n length: '已知长度',\n apply: '应用比例',\n applying: '正在应用…',\n },\n commands: {\n zoom: {\n in: '放大',\n out: '缩小',\n fitPage: '适合页面',\n fitWidth: '适合宽度',\n automatic: '自动',\n menu: '缩放',\n level: '缩放级别',\n p50: '50%',\n p100: '100%',\n p150: '150%',\n p200: '200%',\n p400: '400%',\n },\n pan: '平移',\n pointer: '选择',\n comment: '注释',\n style: '样式',\n menu: '菜单',\n viewControls: '视图控件',\n open: '打开',\n download: '下载',\n print: '打印',\n fullscreen: '全屏',\n spread: {\n group: '页面布局',\n none: '单页',\n odd: '双页',\n even: '封面页',\n },\n scroll: {\n group: '滚动',\n vertical: '垂直',\n horizontal: '水平',\n },\n rotate: {\n group: '旋转',\n clockwise: '顺时针旋转',\n counterclockwise: '逆时针旋转',\n },\n mode: {\n measure: '测量',\n group: '模式',\n view: '查看',\n annotate: '注释',\n shapes: '形状',\n insert: '插入',\n form: '表单',\n redact: '涂黑',\n },\n annotate: {\n cancelCreation: '取消绘制',\n highlight: '高亮',\n strikeout: '删除线',\n underline: '下划线',\n squiggly: '波浪线',\n ink: '绘图',\n inkHighlight: '荧光笔',\n text: '文本框',\n insertText: '插入文本',\n replaceText: '替换文本',\n callout: '标注',\n note: '注释',\n link: '链接',\n gotoLink: '转到链接',\n saveFile: '保存文件',\n removeLink: '删除链接',\n delete: '删除',\n group: '分组',\n ungroup: '取消分组',\n stampFromSelection: '创建图章',\n strip: '注释操作',\n },\n selection: {\n copy: '复制',\n strip: '文本选择操作',\n },\n shapes: {\n rectangle: '矩形',\n circle: '椭圆',\n line: '直线',\n arrow: '箭头',\n polygon: '多边形',\n polyline: '折线',\n },\n insert: {\n stamp: '图章',\n attachment: '附加文件',\n signature: '签名',\n image: '图像',\n },\n form: {\n textfield: '文本字段',\n checkbox: '复选框',\n radio: '单选按钮',\n select: '下拉列表',\n listbox: '列表框',\n button: '按钮',\n signature: '签名字段',\n // The Form mode's design switch, which opens the form designer's sidebar.\n design: '表单设计',\n },\n redact: {\n mark: '标记涂黑',\n applyAll: '应用涂黑',\n clearAll: '清除标记',\n },\n undo: '撤销',\n redo: '重做',\n page: {\n next: '下一页',\n previous: '上一页',\n first: '第一页',\n last: '最后一页',\n goTo: '转到页面',\n },\n find: '查找',\n shortcuts: '键盘快捷键',\n notAllowed: {\n default: '不允许使用“{label}”',\n 'annotations-create': '不允许添加注释',\n 'doc-annotate-modify': '不允许更改注释',\n 'doc-annotate-read': '不允许查看注释',\n 'doc-attachments-modify': '不允许添加文件',\n 'doc-download': '不允许下载',\n 'doc-forms-modify': '不允许编辑表单字段',\n 'doc-outline-modify': '不允许更改书签',\n 'doc-pages-assemble': '不允许更改页面',\n 'doc-print': '不允许打印',\n 'doc-text-copy': '不允许复制',\n 'doc-text-search': '不允许搜索',\n },\n attachment: {\n add: '添加文件',\n save: '保存',\n goTo: '转到页面',\n delete: '删除',\n more: '更多选项',\n },\n outline: {\n add: '添加书签',\n addChild: '添加子书签',\n rename: '重命名',\n setDestination: '将目标设为当前视图',\n properties: '属性…',\n delete: '删除',\n expandAll: '全部展开',\n collapseAll: '全部折叠',\n more: '更多选项',\n },\n // The page commands, in the Pages mode and a page's menu.\n pages: {\n rotateClockwise: '顺时针旋转页面',\n rotateCounterclockwise: '逆时针旋转页面',\n delete: '删除页面',\n duplicate: '复制页面',\n insertBlank: '插入空白页',\n insertFile: '从文件插入…',\n extract: '提取页面',\n selectAll: '选择所有页面',\n more: '页面选项',\n },\n turnedOff: '“{label}”不可用',\n },\n passwordPrompt: {\n title: '需要密码',\n required: '此文档受密码保护。请输入密码以打开文档。',\n incorrect: '密码不正确。请重试。',\n incorrectWarning: '密码不正确',\n label: '密码',\n placeholder: '输入密码',\n cancel: '取消',\n open: '打开',\n opening: '正在打开…',\n },\n dropToOpen: {\n label: '拖放 PDF 以打开',\n },\n documentError: {\n title: '无法打开文档',\n unknown: '无法打开该文档。',\n notFound: '找不到该文件。',\n notAllowed: '您无权访问此文档。',\n damaged: '此文件不是 PDF,或已损坏。',\n unsupported: '此查看器无法打开这类文档。',\n retry: '重试',\n close: '关闭文档',\n },\n tabs: {\n close: '关闭 {name}',\n loading: '正在加载',\n untitled: '文档 {id}',\n },\n closeUnsaved: {\n title: '不保存就关闭?',\n body: '“{name}”有未下载的更改,这些更改将会丢失。',\n cancel: '取消',\n close: '不保存并关闭',\n },\n viewOnly: {\n label: '仅查看',\n turnedOff: '可更改此文档的工具已关闭',\n notAllowed: '您可以阅读此文档,但不能更改它',\n },\n panel: {\n close: '关闭',\n resize: '调整“{title}”大小',\n },\n menu: {\n back: '返回',\n },\n shortcuts: {\n document: '文档',\n viewing: '查看',\n editing: '编辑',\n other: '其他',\n },\n goToPage: {\n go: '转到',\n },\n print: {\n title: '打印',\n pages: '页面',\n allPages: '全部页面',\n currentPage: '当前页',\n range: '自定义',\n rangeLabel: '要打印的页面',\n rangePlaceholder: '例如:1-3, 5',\n rangeInvalid: '请输入 1 到 {total} 的页码,例如 1-3, 5',\n annotations: '打印注释',\n preparing: '正在准备…',\n preparingPage: '正在准备第 {page} 页,共 {total} 页…',\n ready: '已准备好打印。',\n images: '页面将以 {dpi} DPI 的图像打印。',\n lowResolution: '此文档仅允许低分辨率打印({dpi} DPI)。',\n failed: '无法准备打印内容。',\n cancel: '取消',\n print: '打印',\n },\n panels: {\n thumbnails: '缩略图',\n outline: '书签',\n attachments: '附件',\n search: '搜索',\n comments: '注释',\n style: '样式',\n stamps: '图章',\n signatures: '签名',\n redaction: '涂黑',\n measurement: '测量',\n formDesign: '表单设计',\n switch: '切换面板',\n },\n annotation: {\n comment: '注释',\n highlight: '高亮',\n underline: '下划线',\n squiggly: '波浪线',\n strikeout: '删除线',\n square: '矩形',\n circle: '椭圆',\n line: '直线',\n polygon: '多边形',\n polyline: '折线',\n ink: '墨迹',\n freeText: '文本框',\n stamp: '图章',\n caret: '插入符',\n redact: '涂黑',\n fileAttachment: '附件',\n // The style panel's labels, as the annotation kinds name them (`labelKey`), by wording:\n // one field is called different things by different kinds.\n style: {\n opacity: '不透明度',\n stroke: '描边',\n fill: '填充',\n color: '颜色',\n strokeWidth: '描边宽度',\n border: '边框',\n borderStyle: '边框样式',\n borderColor: '边框颜色',\n borderWidth: '边框宽度',\n background: '背景',\n outline: '轮廓',\n lineEndings: '线条端点',\n blendMode: '混合模式',\n font: '字体',\n fontSize: '字体大小',\n textColor: '文本颜色',\n bold: '粗体',\n italic: '斜体',\n underline: '下划线',\n align: '对齐',\n alignment: '对齐方式',\n label: '标签',\n labelFont: '标签字体',\n labelSize: '标签大小',\n labelColor: '标签颜色',\n icon: '图标',\n link: '链接',\n },\n // The annotation flags (`/F`).\n flags: {\n print: '打印',\n hidden: '隐藏',\n noView: '不显示',\n toggleNoView: '切换不显示',\n readOnly: '只读',\n locked: '锁定',\n lockedContents: '锁定内容',\n noZoom: '不缩放',\n noRotate: '不旋转',\n invisible: '不可见',\n },\n borderStyles: { solid: '实线', dashed: '虚线', cloudy: '云状' },\n lineEndings: {\n none: '无',\n square: '正方形',\n circle: '圆形',\n diamond: '菱形',\n openArrow: '开放箭头',\n closedArrow: '闭合箭头',\n butt: '平头',\n reverseOpenArrow: '反向开放箭头',\n reverseClosedArrow: '反向闭合箭头',\n slash: '斜线',\n },\n blendModes: {\n normal: '正常',\n multiply: '正片叠底',\n screen: '滤色',\n overlay: '叠加',\n darken: '变暗',\n lighten: '变亮',\n colorDodge: '颜色减淡',\n colorBurn: '颜色加深',\n hardLight: '强光',\n softLight: '柔光',\n difference: '差值',\n exclusion: '排除',\n hue: '色相',\n saturation: '饱和度',\n color: '颜色',\n luminosity: '明度',\n },\n // The standard PDF fonts, by their names: a language may keep them as they are.\n fonts: {\n courier: 'Courier',\n courierBold: 'Courier Bold',\n courierBoldOblique: 'Courier Bold Oblique',\n courierOblique: 'Courier Oblique',\n helvetica: 'Helvetica',\n helveticaBold: 'Helvetica Bold',\n helveticaBoldOblique: 'Helvetica Bold Oblique',\n helveticaOblique: 'Helvetica Oblique',\n timesRoman: 'Times Roman',\n timesBold: 'Times Bold',\n timesBoldItalic: 'Times Bold Italic',\n timesItalic: 'Times Italic',\n symbol: 'Symbol',\n zapfDingbats: 'Zapf Dingbats',\n },\n alignments: { left: '左对齐', center: '居中', right: '右对齐' },\n noteIcons: {\n comment: '注释',\n key: '键',\n note: '附注',\n help: '帮助',\n newParagraph: '新段落',\n paragraph: '段落',\n insert: '插入',\n },\n attachmentIcons: {\n pushPin: '图钉',\n paperclip: '回形针',\n graph: '图表',\n tag: '标签',\n },\n },\n // A form field's settings, as the form plugin names them (`labelKey`).\n form: {\n settings: {\n name: '名称',\n tooltip: '工具提示',\n required: '必填',\n readOnly: '只读',\n noExport: '不导出',\n defaultValue: '默认值',\n maxLength: '最大长度',\n multiline: '多行',\n password: '密码',\n comb: '每格一个字符',\n radiosInUnison: '值相同的按钮同时选中',\n keepOneOn: '始终保持一项选中',\n options: '选项',\n allowTyping: '允许输入',\n multiSelect: '多项选择',\n },\n },\n // A thumbnail's tooltip.\n thumbnails: { page: '第 {page} 页' },\n // The form designer's sidebar: the fields by page, and the selected one's buttons.\n formDesign: {\n empty: '尚无字段。选择一个字段工具以添加字段。',\n page: '第 {page} 页',\n allFields: '所有字段',\n buttons: '按钮',\n boxes: '复选框',\n box: '复选框 {number}',\n addButton: '添加按钮',\n addBox: '添加复选框',\n },\n // The style panel's own words around the properties.\n stylePanel: {\n mixed: '(混合)',\n // A color swatch that takes the color away.\n transparent: '透明',\n lineStart: '起点',\n lineEnd: '终点',\n empty: '选择一个绘图工具或选中一个注释以编辑其样式。',\n selected: '已选择 {count} 项',\n toolDefaults: '{tool} 默认值',\n defaults: '默认值',\n },\n // The flags section of the style panel: its title, and what each flag does.\n annotationFlags: {\n title: '标志 (/F)',\n print: '打印页面时包含',\n hidden: '在屏幕、单击和打印中均隐藏',\n noView: '在屏幕上隐藏,但仍可能打印',\n toggleNoView: '选中时显示设为“不显示”的注释',\n readOnly: '可见但不可单击',\n locked: '不可移动、调整大小、删除或更改样式',\n lockedContents: '文本不可更改;几何形状可以更改',\n noZoom: '屏幕上大小固定(锚定于左上角)',\n noRotate: '页面旋转时保持直立',\n invisible: '旧版:隐藏未知的子类型',\n },\n // The link editor over a selected annotation.\n attachments: {\n loading: '正在加载附件…',\n failed: '无法读取附件。',\n empty: '此文档没有附加文件',\n drop: '拖放文件以附加',\n dropHint: '或将文件拖放到此处',\n adding: '正在添加…',\n onPage: '第 {page} 页',\n count: '{count} 个文件',\n countPlural: '{count} 个文件',\n },\n outline: {\n filter: '筛选书签',\n loading: '正在加载书签…',\n failed: '无法读取书签。',\n empty: '此文档没有书签',\n noMatches: '没有匹配的书签',\n incomplete: '部分书签无法读取。',\n untitled: '无标题',\n properties: {\n title: '书签属性',\n name: '标题',\n color: '颜色',\n noColor: '无',\n customColor: '自定义颜色',\n bold: '粗体',\n italic: '斜体',\n open: '打开文档时展开',\n target: '目标',\n targetNone: '无',\n targetView: '当前视图',\n targetNamed: '页面操作',\n targetKept: '保持不变',\n keptNote: '此书签会运行脚本或打开其他文件,无法在此更改。',\n fit: '适合方式',\n fitKept: '保持原样',\n save: '保存',\n cancel: '取消',\n },\n },\n linkEditor: {\n toUrl: '链接到 URL',\n url: 'URL',\n toPage: '链接到页面',\n page: '页面',\n urlPlaceholder: 'https://…',\n pagePlaceholder: '页码',\n add: '添加链接',\n update: '更新链接',\n },\n demo: {\n starting: '正在启动查看器…',\n opening: '正在打开文档…',\n more: '更多',\n searchPlaceholder: '搜索文档…',\n searchCaseSensitive: '区分大小写',\n searchWholeWord: '全字匹配',\n searchRegex: '正则表达式',\n searchSearching: '正在搜索…',\n searchResults: '找到 {count} 个结果',\n searchNoResults: '无结果',\n searchPrevious: '上一个结果',\n searchNext: '下一个结果',\n searchPage: '第 {page} 页',\n commentsForbidden: '您无权访问此文档的注释。',\n commentsLoading: '正在加载注释…',\n commentsError: '注释加载失败。',\n commentsRetry: '重试',\n commentsEmpty: '尚无注释。使用注释工具开始讨论。',\n commentsEmptyReadOnly: '此文档没有注释。',\n commentsAnonymous: '未知',\n commentsPage: '第 {page} 页',\n commentCount: '{count} 条注释',\n commentCountPlural: '{count} 条注释',\n commentsReply: '回复',\n commentsReplyPlaceholder: '回复…',\n commentsAddPlaceholder: '添加注释…',\n commentsDelete: '删除注释',\n commentsDeleteThread: '删除讨论',\n commentsEdit: '编辑注释',\n commentsStatus: '状态',\n commentsStatusNone: '无状态',\n commentsStatusAccepted: '已接受',\n commentsStatusRejected: '已拒绝',\n commentsStatusCancelled: '已取消',\n commentsStatusCompleted: '已完成',\n empty: '此演示面板暂无内容。',\n page: '第 {current} 页,共 {total} 页',\n goToPage: '转到页面',\n cancel: '取消',\n pageBadge: '第 {page} 页',\n redactionEmpty: '没有待处理的涂黑标记。使用涂黑工具标记文本或区域。',\n redactionArea: '区域标记',\n redactionText: '文本标记',\n redactionRemove: '删除标记',\n redactConfirmTitle: '应用涂黑?',\n redactConfirmBody: '永久删除 {count} 个涂黑标记下的内容。此操作无法撤销。',\n redactConfirmCollateral: '另有 {count} 个注释也将被删除。',\n redactApply: '应用',\n redactApplying: '正在应用…',\n formatLabel: '格式',\n fieldSettingsTitle: '字段',\n fieldOptionLabel: '标签',\n fieldOptionValue: '值',\n fieldOptionAdd: '添加选项',\n fieldOptionRemove: '删除选项',\n fieldNone: '无',\n redactLabelTitle: '涂黑标签',\n redactLabelPlaceholder: '例如:已涂黑',\n redactLabelRepeat: '在区域内重复标签',\n stampsAll: '所有图章',\n stampsLoading: '正在加载图章…',\n stampsEmpty: '尚无图章。导入 PDF,将其每一页转换为一个图章。',\n stampsRemoveStamp: '删除图章',\n stampsArmedHint: '单击页面以放置图章。',\n stampsImport: '导入 PDF…',\n stampsImporting: '正在导入…',\n stampsImportHint: '将 PDF 导入为图章库——每一页成为一个图章。',\n stampsRemoveLibrary: '删除图章库',\n stampsExportLibrary: '将图章库导出为 PDF',\n stampsCustomLibrary: '我的图章',\n stampsCustomLabel: '自定义图章',\n stampsError: '无法加载内置图章。',\n stampsArmError: '无法选用该图章。',\n stampsImportError: '无法将该 PDF 导入为图章库。',\n quickStampsLabel: '快速图章',\n signaturesEmpty: '尚无签名。请创建一个签名用于签署。',\n signaturesNew: '新建签名…',\n signaturesArmedHint: '单击签名字段以签名,或单击页面上的任意位置放置签名标记。',\n signaturesTargetHint: '为所选字段选择一个签名标记。',\n signaturesInDocument: '此文档中',\n signaturesNone: '此文档没有签名字段。',\n signaturesValidate: '验证',\n signaturesValidating: '正在验证…',\n signaturesSigned: '已签名',\n signaturesUnsigned: '未签名',\n signaturesRename: '重命名',\n signaturesRemove: '删除',\n signaturesExport: '导出为 PDF',\n signaturesAddInitials: '添加姓名缩写',\n signatureLabel: '签名',\n initialsLabel: '姓名缩写',\n makerTitle: '新建签名',\n makerName: '姓名',\n makerNamePlaceholder: '您的姓名',\n makerDraw: '绘制',\n makerType: '键入',\n makerUpload: '上传',\n makerTypePlaceholder: '键入您的姓名',\n makerFont: '字体',\n makerUploadHint: '选择 PNG、JPEG 或单页 PDF',\n makerClear: '清除',\n makerOptional: '(可选)',\n makerSave: '保存',\n makerSaving: '正在保存…',\n makerError: '无法保存签名。',\n signTitle: '签署此字段',\n signReason: '原因',\n signLocation: '位置',\n signKind: '签名后允许的更改',\n signKindApproval: '批准签名——填写表单和添加更多签名后仍然有效',\n signKindCertifyAnnotate: '认证——允许注释、填写表单和签名',\n signKindCertifyFill: '认证——仅允许填写表单和签名',\n signKindCertifyLocked: '认证——不允许任何更改',\n signButton: '签名',\n signSigning: '正在签名…',\n signFill: '放置但不签名',\n signError: '无法签署该字段。',\n inspectTitle: '签名',\n inspectSigner: '签名者',\n inspectReason: '原因',\n inspectLocation: '位置',\n inspectTime: '时间',\n inspectIntegrity: '文档',\n inspectCryptography: '签名',\n inspectTrust: '签名者',\n inspectChanges: '此后的更改',\n inspectDownload: '下载已签名版本',\n verdictValid: '有效',\n verdictValidUntrusted: '有效,签名者不受信任',\n verdictInvalid: '无效——签名后已被修改',\n verdictWillInvalidate: '有效,保存后将失效',\n signaturesInvalidating: '保存文档时,此更改将使 {field} 失效。撤销此更改可保留该签名。',\n verdictIndeterminate: '无法验证',\n verdictUnchanged: '无',\n verdictRestored: '已更改,后又恢复',\n inspectLaterRevisions: '签名后的修订版本',\n verdictPermitted: '允许',\n verdictForbidden: '不允许',\n },\n },\n};\n"],"mappings":";;;;;AAMA,MAAa,OAAe;CAC1B,MAAM;CACN,MAA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;GACzB,aAAa;GACb,gBAAgB;GAChB,aAAa;GACb,oBAAoB;GACpB,kBAAkB;GAClB,kBAAkB;GAClB,gBAAgB;GAChB,mBAAmB;GACnB,WAAW;GACX,kBAAkB;GAClB,wBAAwB;GACxB,mBAAmB;GACnB,WAAW;GACX,eAAe;GACf,aAAa;GACb,mBAAmB;GACnB,iBAAiB;GACjB,cAAc;GACd,iBAAiB;GACjB,kBAAkB;GAClB,qBAAqB;GACrB,qBAAqB;GACrB,qBAAqB;GACrB,mBAAmB;GACnB,aAAa;GACb,gBAAgB;GAChB,mBAAmB;GACnB,kBAAkB;GAClB,iBAAiB;GACjB,eAAe;GACf,qBAAqB;GACrB,sBAAsB;GACtB,sBAAsB;GACtB,gBAAgB;GAChB,oBAAoB;GACpB,sBAAsB;GACtB,kBAAkB;GAClB,oBAAoB;GACpB,kBAAkB;GAClB,kBAAkB;GAClB,kBAAkB;GAClB,uBAAuB;GACvB,gBAAgB;GAChB,eAAe;GACf,YAAY;GACZ,WAAW;GACX,sBAAsB;GACtB,WAAW;GACX,WAAW;GACX,aAAa;GACb,sBAAsB;GACtB,WAAW;GACX,iBAAiB;GACjB,YAAY;GACZ,eAAe;GACf,WAAW;GACX,aAAa;GACb,YAAY;GACZ,WAAW;GACX,YAAY;GACZ,cAAc;GACd,UAAU;GACV,kBAAkB;GAClB,yBAAyB;GACzB,qBAAqB;GACrB,uBAAuB;GACvB,YAAY;GACZ,aAAa;GACb,UAAU;GACV,WAAW;GACX,cAAc;GACd,eAAe;GACf,eAAe;GACf,iBAAiB;GACjB,aAAa;GACb,kBAAkB;GAClB,qBAAqB;GACrB,cAAc;GACd,gBAAgB;GAChB,iBAAiB;GACjB,cAAc;GACd,uBAAuB;GACvB,gBAAgB;GAChB,uBAAuB;GACvB,wBAAwB;GACxB,sBAAsB;GACtB,kBAAkB;GAClB,iBAAiB;GACjB,uBAAuB;GACvB,kBAAkB;GAClB,kBAAkB;EACpB;CACF;AACF"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@embedpdf/viewer-chrome",
3
- "version": "3.0.0-next.14",
3
+ "version": "3.0.0-next.16",
4
4
  "private": false,
5
5
  "description": "The full viewer's chrome - the one React implementation of the snippet UI (structure-only chrome schema, measured toolbar, Tailwind pixels). Published as an implementation dependency of @embedpdf/viewer; it is not a documented user-facing entry point for now.",
6
6
  "type": "module",
@@ -34,9 +34,11 @@
34
34
  "src/styles.css"
35
35
  ],
36
36
  "dependencies": {
37
- "@embedpdf/web": "3.0.0-next.14",
38
- "@embedpdf/default-stamps": "1.0.0-next.0",
39
- "@embedpdf/react": "3.0.0-next.14"
37
+ "@embedpdf/core-ui": "3.0.0-next.16",
38
+ "@embedpdf/default-signature-fonts": "1.0.0-next.1",
39
+ "@embedpdf/default-stamps": "1.0.0-next.1",
40
+ "@embedpdf/react": "3.0.0-next.16",
41
+ "@embedpdf/web": "3.0.0-next.16"
40
42
  },
41
43
  "peerDependencies": {
42
44
  "react": ">=18",
package/src/styles.css CHANGED
@@ -9,82 +9,132 @@
9
9
  so the `theme` preference is authoritative over the OS setting. */
10
10
  @custom-variant dark (&:where(.dark, .dark *));
11
11
 
12
- /* Semantic theme tokens — ported 1:1 from the snippet's light/dark themes
13
- (viewers/snippet/src/config/theme.ts). Runtime CSS variables so the theme
14
- switches with a class; `@theme inline` below turns each into a Tailwind
15
- color utility (bg-surface, text-fg-muted, border-subtle, …). */
16
- /* `:host` alongside `:root`: inside the <embedpdf-viewer> shadow root there is
17
- no :root match, so the host carries the base tokens. The dark override stays
18
- a plain `.dark` class — the element applies it to its shadow WRAPPER (and
19
- apps to <html>), so one selector serves both worlds. */
20
- :root,
12
+ /* A floating bar's pill (places.tsx): on its toolbar, styles the section that holds the bar's
13
+ items, the toolbar's child with an item (`data-epdf-toolbar-item`) that draws something. */
14
+ @custom-variant float-pill (& > div:has(> [data-epdf-toolbar-item]:not(:empty)));
15
+
16
+ /* The viewer's look, as the `--epdf-*` variables the Theming page lists: its accent, the
17
+ colors of its surfaces, text and lines, the corner radius and the font. Every other color the
18
+ chrome draws with is mixed from them in `@theme inline` below, so setting one restyles
19
+ everything made of it. They turn into Tailwind utilities there: `bg-surface`, `text-fg-muted`,
20
+ `border-border-subtle`, `rounded-md` and the rest. */
21
+
22
+ /* The page's own value of each public variable this sheet gives a default, read on the host,
23
+ where the page's CSS arrives (set on the element or inherited from around it). Nothing public
24
+ is declared on the host: a value there would hide one set around the viewer. */
21
25
  :host {
22
- --ep-app: #f3f4f6;
23
- --ep-surface: #ffffff;
24
- --ep-surface-alt: #f1f3f5;
25
- --ep-elevated: #ffffff;
26
- --ep-fg: #111827;
27
- --ep-fg-secondary: #374151;
28
- --ep-fg-muted: #6b7280;
29
- --ep-fg-disabled: #9ca3af;
30
- --ep-on-accent: #ffffff;
31
- --ep-border: #d1d5db;
32
- --ep-border-subtle: #e5e7eb;
33
- --ep-border-strong: #9ca3af;
34
- --ep-accent: #3b82f6;
35
- --ep-accent-hover: #2563eb;
36
- --ep-accent-active: #1d4ed8;
37
- --ep-accent-light: #eff6ff;
38
- --ep-hover: #f3f4f6;
39
- --ep-active: #e5e7eb;
40
- --ep-selected: #eff6ff;
41
- --ep-canvas: #f3f4f6;
26
+ --embedpdf-host-accent: var(--epdf-accent);
27
+ --embedpdf-host-background: var(--epdf-background);
28
+ --embedpdf-host-surface: var(--epdf-surface);
29
+ --embedpdf-host-surface-raised: var(--epdf-surface-raised);
30
+ --embedpdf-host-text: var(--epdf-text);
31
+ --embedpdf-host-text-muted: var(--epdf-text-muted);
32
+ --embedpdf-host-border: var(--epdf-border);
33
+ --embedpdf-host-hover: var(--epdf-hover);
34
+ --embedpdf-host-canvas: var(--epdf-canvas);
35
+ --embedpdf-host-radius: var(--epdf-radius);
36
+ --embedpdf-host-font: var(--epdf-font);
37
+ --embedpdf-host-scrollbar-thumb: var(--epdf-scrollbar-thumb);
38
+ --embedpdf-host-toolbar-surface: var(--epdf-toolbar-surface);
39
+ --embedpdf-host-toolbar-border: var(--epdf-toolbar-border);
40
+ --embedpdf-host-toolbar-active: var(--epdf-toolbar-active);
41
+ }
42
+
43
+ /* The variables live on the viewer's root: the element's shadow wrapper (`data-embedpdf-root`),
44
+ or the document when the chrome is the page. Each is the page's value when it set one, else
45
+ this mode's default, so the parts drawn on the pages (which read the same variables) and your
46
+ own components in the viewer always agree with the chrome. The dark defaults are a plain
47
+ `.dark` class, which the element puts on its wrapper and apps on <html>. */
48
+ :root,
49
+ [data-embedpdf-root] {
50
+ --epdf-accent: var(--embedpdf-host-accent, #3b82f6);
51
+ --epdf-background: var(--embedpdf-host-background, #f3f4f6);
52
+ --epdf-surface: var(--embedpdf-host-surface, #ffffff);
53
+ --epdf-surface-raised: var(--embedpdf-host-surface-raised, #ffffff);
54
+ --epdf-text: var(--embedpdf-host-text, #111827);
55
+ --epdf-text-muted: var(--embedpdf-host-text-muted, #6b7280);
56
+ --epdf-border: var(--embedpdf-host-border, #d1d5db);
57
+ --epdf-hover: var(--embedpdf-host-hover, #f3f4f6);
58
+ --epdf-canvas: var(--embedpdf-host-canvas, #f3f4f6);
59
+ --epdf-radius: var(--embedpdf-host-radius, 6px);
60
+ --epdf-font: var(
61
+ --embedpdf-host-font,
62
+ ui-sans-serif,
63
+ system-ui,
64
+ sans-serif,
65
+ 'Apple Color Emoji',
66
+ 'Segoe UI Emoji',
67
+ 'Segoe UI Symbol',
68
+ 'Noto Color Emoji'
69
+ );
70
+
71
+ /* The headless parts' own variables (the headless docs' "Colors & theming"), defaulting to the
72
+ viewer's look. */
73
+ --epdf-scrollbar-thumb: var(
74
+ --embedpdf-host-scrollbar-thumb,
75
+ color-mix(in srgb, var(--epdf-text) 35%, transparent)
76
+ );
77
+ --epdf-toolbar-surface: var(--embedpdf-host-toolbar-surface, var(--epdf-surface-raised));
78
+ --epdf-toolbar-border: var(--embedpdf-host-toolbar-border, var(--epdf-border));
79
+ --epdf-toolbar-active: var(
80
+ --embedpdf-host-toolbar-active,
81
+ color-mix(in srgb, var(--epdf-hover) 90%, var(--epdf-text))
82
+ );
83
+
84
+ /* The pressed and chosen look: a tint of the accent on the surface, stronger in dark, where a
85
+ light tint barely shows. */
86
+ --embedpdf-accent-tint: color-mix(in srgb, var(--epdf-accent) 8%, var(--epdf-surface));
42
87
  }
43
88
 
44
89
  .dark {
45
- --ep-app: #111827;
46
- --ep-surface: #1f2937;
47
- --ep-surface-alt: #374151;
48
- --ep-elevated: #1f2937;
49
- --ep-fg: #f9fafb;
50
- --ep-fg-secondary: #e5e7eb;
51
- --ep-fg-muted: #9ca3af;
52
- --ep-fg-disabled: #6b7280;
53
- --ep-on-accent: #111827;
54
- --ep-border: #4b5563;
55
- --ep-border-subtle: #374151;
56
- --ep-border-strong: #6b7280;
57
- --ep-accent: #60a5fa;
58
- --ep-accent-hover: #3b82f6;
59
- --ep-accent-active: #2563eb;
60
- --ep-accent-light: #1e3a5f;
61
- --ep-hover: #374151;
62
- --ep-active: #4b5563;
63
- --ep-selected: #1e3a5f;
64
- --ep-canvas: #0d1117;
90
+ --epdf-accent: var(--embedpdf-host-accent, #60a5fa);
91
+ --epdf-background: var(--embedpdf-host-background, #111827);
92
+ --epdf-surface: var(--embedpdf-host-surface, #1f2937);
93
+ --epdf-surface-raised: var(--embedpdf-host-surface-raised, #1f2937);
94
+ --epdf-text: var(--embedpdf-host-text, #f9fafb);
95
+ --epdf-text-muted: var(--embedpdf-host-text-muted, #9ca3af);
96
+ --epdf-border: var(--embedpdf-host-border, #4b5563);
97
+ --epdf-hover: var(--embedpdf-host-hover, #374151);
98
+ --epdf-canvas: var(--embedpdf-host-canvas, #0d1117);
99
+ --epdf-scrollbar-thumb: var(
100
+ --embedpdf-host-scrollbar-thumb,
101
+ color-mix(in srgb, var(--epdf-text) 28%, transparent)
102
+ );
103
+ --embedpdf-accent-tint: color-mix(in srgb, var(--epdf-accent) 25%, var(--epdf-surface));
65
104
  }
66
105
 
106
+ /* Each utility reads the variables where it's used, so a variable set in a part of the viewer
107
+ (or for one of your components) restyles that part. The shades between two tokens are mixes,
108
+ which follow both. Corners scale with `--epdf-radius`: `rounded-md` is the radius itself. */
67
109
  @theme inline {
68
- --color-app: var(--ep-app);
69
- --color-surface: var(--ep-surface);
70
- --color-surface-alt: var(--ep-surface-alt);
71
- --color-elevated: var(--ep-elevated);
72
- --color-fg: var(--ep-fg);
73
- --color-fg-secondary: var(--ep-fg-secondary);
74
- --color-fg-muted: var(--ep-fg-muted);
75
- --color-fg-disabled: var(--ep-fg-disabled);
76
- --color-on-accent: var(--ep-on-accent);
77
- --color-border: var(--ep-border);
78
- --color-border-subtle: var(--ep-border-subtle);
79
- --color-border-strong: var(--ep-border-strong);
80
- --color-accent: var(--ep-accent);
81
- --color-accent-hover: var(--ep-accent-hover);
82
- --color-accent-active: var(--ep-accent-active);
83
- --color-accent-light: var(--ep-accent-light);
84
- --color-hover: var(--ep-hover);
85
- --color-active: var(--ep-active);
86
- --color-selected: var(--ep-selected);
87
- --color-canvas: var(--ep-canvas);
110
+ --color-app: var(--epdf-background);
111
+ --color-surface: var(--epdf-surface);
112
+ --color-surface-alt: color-mix(in srgb, var(--epdf-surface), var(--epdf-text) 6%);
113
+ --color-elevated: var(--epdf-surface-raised);
114
+ --color-fg: var(--epdf-text);
115
+ --color-fg-secondary: color-mix(in srgb, var(--epdf-text) 65%, var(--epdf-text-muted));
116
+ --color-fg-muted: var(--epdf-text-muted);
117
+ --color-fg-disabled: color-mix(in srgb, var(--epdf-text-muted) 60%, var(--epdf-surface));
118
+ --color-on-accent: var(--epdf-surface);
119
+ --color-border: var(--epdf-border);
120
+ --color-border-subtle: color-mix(in srgb, var(--epdf-border) 50%, var(--epdf-surface));
121
+ --color-border-strong: color-mix(in srgb, var(--epdf-border) 75%, var(--epdf-text));
122
+ --color-accent: var(--epdf-accent);
123
+ --color-accent-hover: color-mix(in srgb, var(--epdf-accent) 80%, black);
124
+ --color-accent-active: color-mix(in srgb, var(--epdf-accent) 65%, black);
125
+ --color-accent-light: var(--embedpdf-accent-tint);
126
+ --color-hover: var(--epdf-hover);
127
+ --color-active: color-mix(in srgb, var(--epdf-hover) 90%, var(--epdf-text));
128
+ --color-selected: var(--embedpdf-accent-tint);
129
+ --color-canvas: var(--epdf-canvas);
130
+
131
+ --radius: calc(var(--epdf-radius) * 2 / 3);
132
+ --radius-xs: calc(var(--epdf-radius) / 2);
133
+ --radius-sm: calc(var(--epdf-radius) * 2 / 3);
134
+ --radius-md: var(--epdf-radius);
135
+ --radius-lg: calc(var(--epdf-radius) * 4 / 3);
136
+ --radius-xl: calc(var(--epdf-radius) * 2);
137
+ --radius-2xl: calc(var(--epdf-radius) * 8 / 3);
88
138
  }
89
139
 
90
140
  html,
@@ -95,17 +145,9 @@ body,
95
145
  }
96
146
 
97
147
  body {
98
- font-family:
99
- ui-sans-serif,
100
- system-ui,
101
- -apple-system,
102
- 'Segoe UI',
103
- Roboto,
104
- Helvetica,
105
- Arial,
106
- sans-serif;
107
- color: var(--ep-fg);
108
- background: var(--ep-app);
148
+ font-family: var(--epdf-font);
149
+ color: var(--epdf-text);
150
+ background: var(--epdf-background);
109
151
  }
110
152
 
111
153
  /* The measurement layer in <Toolbar> is aria-hidden + visibility:hidden; make
@@ -115,18 +157,48 @@ body {
115
157
  }
116
158
 
117
159
  /* Headless scrollbar theming. The component ships geometry + behavior only
118
- (thumb drag, track paging, auto-hide → data-state); everything visual is
119
- these few rules — restyle or replace them freely. */
120
- :root {
121
- --epdf-scrollbar-thumb: rgba(17, 24, 39, 0.35);
122
- }
123
- .dark {
124
- --epdf-scrollbar-thumb: rgba(249, 250, 251, 0.28);
125
- }
160
+ (thumb drag, track paging, auto-hide → data-state); its color is
161
+ `--epdf-scrollbar-thumb` above, and everything else is these few rules —
162
+ restyle or replace them freely. */
126
163
  [data-embedpdf-scrollbar-thumb] {
127
164
  transition: background 150ms;
128
165
  }
129
166
  [data-embedpdf-scrollbar-thumb]:hover,
130
167
  [data-embedpdf-scrollbar][data-dragging] [data-embedpdf-scrollbar-thumb] {
131
- background: var(--ep-fg-muted);
168
+ background: var(--epdf-text-muted);
169
+ }
170
+
171
+ /* With a finger as the main way of pointing (`data-touch` on the viewer's root, from its env),
172
+ every button in a bar, document tab, panel header button and menu row, in a sheet or not, is
173
+ at least 44 px tall: the size a fingertip hits. It follows the viewer's env, not a media
174
+ query, like the rest of its layout. */
175
+ [data-touch] [role='toolbar'] button,
176
+ [data-touch] [role='tab'],
177
+ [data-touch] [data-epdf-panel-header] button,
178
+ [data-touch]
179
+ [role='menu']
180
+ :is([role='menuitem'], [role='menuitemradio'], [role='menuitemcheckbox']) {
181
+ min-height: 44px;
182
+ }
183
+ [data-touch] [role='toolbar'] button,
184
+ [data-touch] [data-epdf-panel-header] button {
185
+ min-width: 44px;
186
+ }
187
+
188
+ /* With a finger as the main way of pointing, the chrome's own fields write in 16 px text: iOS
189
+ Safari zooms the page in when a field with smaller text takes focus. The fields on the pages
190
+ (a form field, a text box) size their text inline, which wins over this, and are laid out at a
191
+ legible size instead (`legible-text.ts` in `@embedpdf/web`). */
192
+ [data-touch] :is(input, textarea, select) {
193
+ font-size: 16px;
194
+ }
195
+
196
+ /* On a phone, the floating bar with the page number gets out of the way while the pages scroll
197
+ (places.tsx): it fades out, then takes no presses or focus until it fades back in. */
198
+ [data-scroll-hidden] {
199
+ opacity: 0;
200
+ visibility: hidden;
201
+ transition:
202
+ opacity 200ms,
203
+ visibility 0s 200ms;
132
204
  }
@@ -1 +0,0 @@
1
- {"version":3,"file":"commands.cjs","names":["StageToken","InteractionToken","AnnotationToken","SelectionToken","FormToken","RedactionToken","ZoomMode","SearchToken","DocumentsToken","ActionsToken","ShellToken","StampToken","SignatureToken","MeasurementToken","I18nToken","LinkToken"],"sources":["../src/config/commands.ts"],"sourcesContent":["/**\n * The command vocabulary — the semantic layer. Ported in spirit from the v2\n * snippet's commands.ts, but every command is a pure value: label key, icon,\n * shortcut, derivations, and a `run` (or a declarative surface target). The\n * v2 `registry.getPlugin<T>(id)?.provides()` string-and-cast dance becomes a\n * typed `ctx.get(Token)`.\n *\n * Wiring reality (chrome-parity scope):\n * zoom/pan/pointer/spread/scroll/rotate → real Stage / Interaction / PageEdit\n * modes → shell exclusive surfaces ('mode')\n * panels / menus / modals → declarative shell targets\n * annotate + shape tools → real interaction tools\n * form tools → real form plugin palette (draw-to-place)\n * insert tools → real stamp library panel + image/\n * attachment click-then-pick (signature\n * still inert, via demo-tools)\n * history undo/redo → disabled (no history plugin in v3 yet)\n */\nimport type { CommandDef, IconAccent } from '@embedpdf/react/commands';\nimport { DocumentsToken } from '@embedpdf/react/runtime';\nimport { StageToken, ZoomMode } from '@embedpdf/react/stage';\nimport type { SpreadMode } from '@embedpdf/react/stage';\nimport { InteractionToken } from '@embedpdf/react/interaction';\nimport { ShellToken } from '@embedpdf/react/shell';\nimport { AnnotationToken } from '@embedpdf/react/annotation';\nimport { copySelection, SelectionToken, type TextRange } from '@embedpdf/react/selection';\nimport { fieldKeyOf, FormToken } from '@embedpdf/react/form';\nimport { ActionsToken } from '@embedpdf/react/actions';\nimport { LinkToken, openLinkTarget, type PdfLinkTarget } from '@embedpdf/react/link';\nimport { SearchToken } from '@embedpdf/react/search';\nimport { MeasurementToken } from '@embedpdf/react/measurement';\nimport { RedactionToken } from '@embedpdf/react/redaction';\nimport { StampToken } from '@embedpdf/react/stamp';\nimport { SignatureToken } from '@embedpdf/react/signature';\nimport { I18nToken } from '@embedpdf/react/i18n';\n\n// ── helpers ────────────────────────────────────────────────────────────────\ntype Ctx = Parameters<NonNullable<CommandDef['run']>>[0];\n\n/** Where selection-made stamps go: the user's own library, persisted. */\nconst CUSTOM_LIBRARY_ID = 'embedpdf-custom';\n\nconst stage = (c: Ctx) => c.tryGet(StageToken);\nconst interaction = (c: Ctx) => c.tryGet(InteractionToken);\nconst anno = (c: Ctx) => c.tryGet(AnnotationToken);\nconst textSelection = (c: Ctx) => c.tryGet(SelectionToken);\nconst sameTextRange = (a: TextRange | null, b: TextRange | null): boolean =>\n a === b ||\n (!!a &&\n !!b &&\n a.start.pon === b.start.pon &&\n a.start.index === b.start.index &&\n a.end.pon === b.end.pon &&\n a.end.index === b.end.index);\n\n// ── annotation-selection predicates (drive the floating strip's contents) ────\nconst hasAnnotationSelection = (c: Ctx) => (anno(c)?.selection().length ?? 0) > 0;\n/** v2 gated strip items per subtype (comment hidden on links/widgets) — here\n * it's one derivation over the selected DTOs instead of per-command lookups. */\nconst selectionSubtypes = (c: Ctx) => new Set((anno(c)?.getSelected() ?? []).map((a) => a.subtype));\n/**\n * The selection's `link` value: a target, `null` (linkable but none set), or\n * `undefined` when the selection cannot carry a link at all (widgets, mixed\n * link states) — the schema decides, never a subtype blocklist.\n */\nconst selectionLink = (c: Ctx): PdfLinkTarget | null | undefined => {\n const p = anno(c)?.getSelectionProps();\n if (!p || !p.specs.some((s) => s.key === 'link') || p.mixed.includes('link')) return undefined;\n return (p.values.link ?? null) as PdfLinkTarget | null;\n};\n\n// ── tool icon accents: THIS viewer's design decision ─────────────────────────\n// A tool declares which drawing default each colored part of its glyph previews.\n// This is intentionally explicit at the command definition: property-panel order\n// does not determine icon meaning, and another viewer may make a different choice.\ntype ColorKey = 'color' | 'interiorColor' | 'fontColor';\nexport interface ToolAccentDefinition {\n primary: ColorKey;\n secondary?: ColorKey;\n}\n\n/**\n * toolId → the SAME icon + accent definition its toolbar button uses, recorded\n * as a side effect of the `tool()` command definitions below — ONE source of\n * truth, so the tool cursor (ui/tool-cursor.tsx) and the button can never\n * drift apart.\n */\nexport const TOOL_ICONS: Record<string, { icon: string; accent?: ToolAccentDefinition }> = {};\n\n// The `stamp` tool has no toolbar button of its own: it is ARMED by the stamps\n// panel (picking a library asset), never activated directly — so its cursor\n// skin is recorded here rather than as a side effect of a `tool()` definition.\nTOOL_ICONS['stamp'] = { icon: 'rubberStamp' };\n\nconst toolAccent = (\n c: Ctx,\n toolId: string,\n accent: ToolAccentDefinition | undefined,\n): IconAccent | null => {\n if (!accent) return null;\n const anno = c.tryGet(AnnotationToken);\n if (!anno) return null;\n const d = anno.currentDefaults(toolId);\n return {\n primary: d[accent.primary] ?? undefined,\n secondary: accent.secondary ? (d[accent.secondary] ?? undefined) : undefined,\n };\n};\n\n/** A tool command: activates a real interaction tool; active = it's the tool.\n * The icon previews the tool's current defaults — keyed by the SAME toolId\n * as run/active, so the accent can't drift to another tool's colors. */\nconst tool = (\n id: string,\n toolId: string,\n labelKey: string,\n icon: string,\n accent?: ToolAccentDefinition,\n): CommandDef => {\n TOOL_ICONS[toolId] = { icon, ...(accent ? { accent } : {}) };\n // Authoring tools grey out without their family's authority — the SAME\n // twin the owning plugin's gesture gate consults (permissions.md), so a\n // button can never offer a doomed paint: annotation/insert tools ask\n // annotation create authority, form-design tools ask `form.canDesign()`,\n // the redact marker asks `redaction.canMark()`. Absent plugin → ungated\n // (a build without the plugin has no authority question to ask).\n const authority: ((c: Ctx) => boolean) | null =\n id.startsWith('annotation:add') || id.startsWith('insert:add')\n ? (c) => anno(c)?.canCreate() ?? true\n : id.startsWith('form:add')\n ? (c) => c.tryGet(FormToken)?.canDesign() ?? true\n : id === 'redaction:redact'\n ? (c) => c.tryGet(RedactionToken)?.canMark() ?? true\n : null;\n return {\n id,\n labelKey,\n icon,\n categories: ['tool'],\n run: (c) => interaction(c)?.activateTool(toolId),\n active: (c) => interaction(c)?.activeToolId() === toolId,\n enabled: (c) => interaction(c) != null && (authority?.(c) ?? true),\n iconAccent: (c) => toolAccent(c, toolId, accent),\n };\n};\n\n/** A fixed zoom level (fraction), e.g. 1 = 100%. */\nconst zoomLevel = (id: string, level: number, label: string): CommandDef => ({\n id,\n labelKey: label,\n categories: ['zoom', 'zoom-level'],\n run: (c) => stage(c)?.zoomTo({ level }),\n enabled: (c) => stage(c) != null,\n});\n\nconst spread = (id: string, mode: SpreadMode, labelKey: string, icon: string): CommandDef => ({\n id,\n labelKey,\n icon,\n categories: ['page', 'spread'],\n run: (c) => stage(c)?.setSpread(mode),\n active: (c) => stage(c)?.spread() === mode,\n enabled: (c) => stage(c) != null,\n});\n\nexport const defaultCommands: CommandDef[] = [\n // ── zoom ───────────────────────────────────────────────────────────────\n {\n id: 'zoom:in',\n labelKey: 'commands.zoom.in',\n icon: 'zoomIn',\n shortcut: ['Mod+=', 'Mod+NumpadAdd'],\n categories: ['zoom'],\n run: (c) => stage(c)?.zoomIn(),\n enabled: (c) => stage(c) != null,\n },\n {\n id: 'zoom:out',\n labelKey: 'commands.zoom.out',\n icon: 'zoomOut',\n shortcut: ['Mod+-', 'Mod+NumpadSubtract'],\n categories: ['zoom'],\n run: (c) => stage(c)?.zoomOut(),\n enabled: (c) => stage(c) != null,\n },\n {\n id: 'zoom:fit-page',\n labelKey: 'commands.zoom.fitPage',\n icon: 'fitToPage',\n shortcut: 'Mod+0',\n categories: ['zoom'],\n run: (c) => stage(c)?.fitPage(),\n active: (c) => stage(c)?.zoomMode() === ZoomMode.FitPage,\n enabled: (c) => stage(c) != null,\n },\n {\n id: 'zoom:fit-width',\n labelKey: 'commands.zoom.fitWidth',\n icon: 'fitToWidth',\n shortcut: 'Mod+1',\n categories: ['zoom'],\n run: (c) => stage(c)?.fitWidth(),\n active: (c) => stage(c)?.zoomMode() === ZoomMode.FitWidth,\n enabled: (c) => stage(c) != null,\n },\n {\n id: 'zoom:automatic',\n labelKey: 'commands.zoom.automatic',\n categories: ['zoom'],\n run: (c) => stage(c)?.automatic(),\n active: (c) => stage(c)?.zoomMode() === ZoomMode.Automatic,\n enabled: (c) => stage(c) != null,\n },\n zoomLevel('zoom:50', 0.5, 'commands.zoom.p50'),\n zoomLevel('zoom:100', 1, 'commands.zoom.p100'),\n zoomLevel('zoom:150', 1.5, 'commands.zoom.p150'),\n zoomLevel('zoom:200', 2, 'commands.zoom.p200'),\n zoomLevel('zoom:400', 4, 'commands.zoom.p400'),\n {\n id: 'zoom:menu',\n labelKey: 'commands.zoom.menu',\n icon: 'zoomIn',\n categories: ['zoom'],\n menu: 'zoom',\n },\n\n // ── tools ──────────────────────────────────────────────────────────────\n {\n id: 'pan:toggle',\n labelKey: 'commands.pan',\n icon: 'hand',\n categories: ['tools'],\n run: (c) => interaction(c)?.activateTool('pan'),\n active: (c) => interaction(c)?.activeToolId() === 'pan',\n enabled: (c) => interaction(c) != null,\n },\n {\n id: 'pointer:toggle',\n labelKey: 'commands.pointer',\n icon: 'pointer',\n categories: ['tools'],\n run: (c) => interaction(c)?.activateTool('pointer'),\n active: (c) => interaction(c)?.activeToolId() === 'pointer',\n enabled: (c) => interaction(c) != null,\n },\n\n // ── panels (declarative shell targets) ──────────────────────────────────\n {\n id: 'panel:sidebar',\n labelKey: 'commands.sidebar',\n icon: 'sidebar',\n categories: ['panel'],\n panel: { id: 'sidebar', exclusive: 'left' },\n },\n {\n id: 'panel:search',\n labelKey: 'commands.search',\n icon: 'search',\n // No doc.text.search → every query would 403; the panel has no job.\n visible: (c) => c.tryGet(SearchToken)?.canSearch() ?? true,\n categories: ['panel'],\n panel: { id: 'search', exclusive: 'right' },\n },\n {\n id: 'panel:comment',\n labelKey: 'commands.comment',\n icon: 'comment',\n // No doc.annotate.read → there is nothing this panel could show.\n visible: (c) => anno(c)?.canRead() ?? true,\n categories: ['panel'],\n panel: { id: 'comment', exclusive: 'right' },\n },\n {\n id: 'panel:annotation-style',\n labelKey: 'commands.style',\n icon: 'palette',\n categories: ['panel'],\n panel: { id: 'annotation-style', exclusive: 'right' },\n },\n\n // ── menus (declarative) ─────────────────────────────────────────────────\n {\n id: 'document:menu',\n labelKey: 'commands.menu',\n icon: 'menu',\n categories: ['document'],\n menu: 'document',\n },\n {\n id: 'page:settings',\n labelKey: 'commands.viewControls',\n icon: 'viewSettings',\n categories: ['page'],\n menu: 'page-settings',\n },\n\n // ── document actions ────────────────────────────────────────────────────\n {\n id: 'document:download',\n labelKey: 'commands.download',\n icon: 'download',\n categories: ['document'],\n run: (c) => {\n const id = c.documentId ?? undefined;\n const documents = c.tryGet(DocumentsToken);\n if (!documents) return;\n const pull = () => documents.download(id);\n // The Phase-4 verb-owner contract: WS → serialize → DS as ONE queued\n // operation, so the WillSave mutations are IN the downloaded bytes\n // and two rapid saves can never interleave. Without the actions\n // plugin this degrades to a plain download.\n const actions = c.tryGet(ActionsToken);\n (actions ? actions.runDocumentVerb('save', pull) : pull())\n .then((bytes) => {\n const blob = new Blob([bytes as BlobPart], { type: 'application/pdf' });\n const url = URL.createObjectURL(blob);\n const a = document.createElement('a');\n a.href = url;\n a.download = 'document.pdf';\n a.click();\n URL.revokeObjectURL(url);\n })\n .catch((e) => console.warn('[snippet-react] download failed', e));\n },\n // The permissions.md chrome exception: a kernel verb with a 1:1\n // capability reads the kernel's `allows` directly — no owning plugin.\n enabled: (c) =>\n c.documentId != null && (c.tryGet(DocumentsToken)?.allows('doc.download') ?? false),\n },\n {\n id: 'document:print',\n labelKey: 'commands.print',\n icon: 'print',\n shortcut: 'Mod+p',\n categories: ['document'],\n // WP → window.print() → DP through the one serialized verb op (the\n // latch suppresses any nested script print); documentless chrome (or\n // no actions plugin) keeps today's direct dialog.\n run: (c) => {\n const actions = c.documentId != null ? c.tryGet(ActionsToken) : null;\n if (actions) void actions.runDocumentVerb('print', () => window.print());\n else window.print();\n },\n // Same exception; documentless chrome (no doc open) keeps print enabled\n // for whatever the host page shows.\n enabled: (c) => c.documentId == null || (c.tryGet(DocumentsToken)?.allows('doc.print') ?? true),\n },\n {\n id: 'document:fullscreen',\n labelKey: 'commands.fullscreen',\n icon: 'externalLink',\n categories: ['document'],\n run: () => {\n if (document.fullscreenElement) document.exitFullscreen();\n else document.documentElement.requestFullscreen().catch(() => {});\n },\n active: () => Boolean(document.fullscreenElement),\n },\n\n // ── page settings (spread / scroll / rotate) ────────────────────────────\n spread('spread:none', 'none', 'commands.spread.none', 'singlePage'),\n spread('spread:odd', 'odd', 'commands.spread.odd', 'doublePage'),\n spread('spread:even', 'even', 'commands.spread.even', 'book2'),\n {\n id: 'scroll:vertical',\n labelKey: 'commands.scroll.vertical',\n icon: 'vertical',\n categories: ['page', 'scroll'],\n run: (c) => stage(c)?.setLayout('vertical'),\n active: (c) => stage(c)?.layout() === 'vertical',\n enabled: (c) => stage(c) != null,\n },\n {\n id: 'scroll:horizontal',\n labelKey: 'commands.scroll.horizontal',\n icon: 'horizontal',\n categories: ['page', 'scroll'],\n run: (c) => stage(c)?.setLayout('horizontal'),\n active: (c) => stage(c)?.layout() === 'horizontal',\n enabled: (c) => stage(c) != null,\n },\n // VIEW rotation (Adobe's \"Rotate View\"): rotates how every page displays in\n // the main stage lens — non-persistent, nothing written to the PDF. The\n // PERMANENT per-page rotation (PageEditToken.rotateBy) belongs in a\n // page-organize surface, not behind the view-settings buttons.\n {\n id: 'rotate:clockwise',\n labelKey: 'commands.rotate.clockwise',\n icon: 'rotateClockwise',\n categories: ['page', 'rotate'],\n run: (c) => stage(c)?.rotateView(90),\n enabled: (c) => stage(c) != null,\n },\n {\n id: 'rotate:counter-clockwise',\n labelKey: 'commands.rotate.counterclockwise',\n icon: 'rotateCounterClockwise',\n categories: ['page', 'rotate'],\n run: (c) => stage(c)?.rotateView(-90),\n enabled: (c) => stage(c) != null,\n },\n\n // ── modes (shell exclusive surfaces, tag 'mode') ────────────────────────\n {\n id: 'mode:view',\n labelKey: 'commands.mode.view',\n categories: ['mode'],\n // View = no mode band. Close any open mode surface and drop to pointer.\n run: (c) => {\n const shell = c.tryGet(ShellToken);\n for (const m of MODE_SURFACES) shell?.close(m);\n interaction(c)?.activateTool('pointer');\n },\n active: (c) => {\n const shell = c.tryGet(ShellToken);\n return shell ? MODE_SURFACES.every((m) => !shell.isOpen(m)) : true;\n },\n },\n modeCommand('mode:annotate', 'commands.mode.annotate'),\n modeCommand('mode:shapes', 'commands.mode.shapes'),\n modeCommand('mode:insert', 'commands.mode.insert'),\n modeCommand('mode:form', 'commands.mode.form', 'form-edit'),\n modeCommand('mode:redact', 'commands.mode.redact'),\n modeCommand('mode:measure', 'commands.mode.measure'),\n\n // ── annotate tools (real interaction tools) ─────────────────────────────\n tool('annotation:add-highlight', 'highlight', 'commands.annotate.highlight', 'highlight', {\n primary: 'color',\n }),\n tool('annotation:add-strikeout', 'strikeout', 'commands.annotate.strikeout', 'strikethrough', {\n primary: 'color',\n }),\n tool('annotation:add-underline', 'underline', 'commands.annotate.underline', 'underline', {\n primary: 'color',\n }),\n tool('annotation:add-squiggly', 'squiggly', 'commands.annotate.squiggly', 'squiggly', {\n primary: 'color',\n }),\n tool('annotation:add-ink', 'ink', 'commands.annotate.ink', 'pencilMarker', {\n primary: 'color',\n }),\n tool(\n 'annotation:add-ink-highlight',\n 'ink-highlight',\n 'commands.annotate.inkHighlight',\n 'inkHighlighter',\n { primary: 'color' },\n ),\n tool('annotation:add-text', 'free-text', 'commands.annotate.text', 'freeText', {\n primary: 'fontColor',\n }),\n tool('annotation:add-insert-text', 'insert-text', 'commands.annotate.insertText', 'insertText', {\n primary: 'color',\n }),\n tool(\n 'annotation:add-replace-text',\n 'replace-text',\n 'commands.annotate.replaceText',\n 'replaceText',\n { primary: 'color' },\n ),\n tool('annotation:add-callout', 'free-text-callout', 'commands.annotate.callout', 'callout', {\n primary: 'color',\n secondary: 'interiorColor',\n }),\n // Sticky note (\"comment\") — click-to-place; the icon renders from the\n // engine-baked /AP in the tool's current color.\n tool('annotation:add-note', 'note', 'commands.annotate.note', 'message'),\n // Link — drag an invisible hit rectangle, then set the target in the style\n // panel's Link control (create-then-edit). While active, existing links\n // become editable rects instead of navigating.\n tool('annotation:add-link', 'link', 'commands.annotate.link', 'link'),\n\n // ── shape tools (real interaction tools) ────────────────────────────────\n tool('annotation:add-rectangle', 'square', 'commands.shapes.rectangle', 'square', {\n primary: 'color',\n secondary: 'interiorColor',\n }),\n tool('annotation:add-circle', 'circle', 'commands.shapes.circle', 'circle', {\n primary: 'color',\n secondary: 'interiorColor',\n }),\n tool('annotation:add-line', 'line', 'commands.shapes.line', 'line', { primary: 'color' }),\n // The arrow tool is a `line` preset (a line with an arrowhead) — registered by\n // the annotationPlugin `tools` config in App.tsx, activated like any other tool.\n tool('annotation:add-arrow', 'arrow', 'commands.shapes.arrow', 'lineArrow', {\n primary: 'color',\n }),\n tool('annotation:add-polygon', 'polygon', 'commands.shapes.polygon', 'polygon', {\n primary: 'color',\n secondary: 'interiorColor',\n }),\n tool('annotation:add-polyline', 'polyline', 'commands.shapes.polyline', 'zigzag', {\n primary: 'color',\n }),\n\n // ── insert tools (stamp/image/attachment real; signature inert) ─────────\n // Stamps open a LIBRARY, they are not a file dialog: the panel lists the\n // reusable named assets the stamp plugin holds, and picking one arms the\n // annotation plugin's stamp tool with that asset's bytes (stamps-panel.tsx).\n // Arbitrary image bytes are `insert:add-image` below — a different gesture,\n // so a different button.\n {\n id: 'insert:add-stamp',\n labelKey: 'commands.insert.stamp',\n icon: 'rubberStamp',\n // No stamp plugin → no library to show. No create authority → nothing the\n // picker could place (the same twin every insert tool's button asks).\n visible: (c) => c.tryGet(StampToken) != null,\n enabled: (c) => anno(c)?.canCreate() ?? true,\n categories: ['panel'],\n panel: { id: 'stamps', exclusive: 'right' },\n },\n // File attachment — click the spot, pick the file (the attachment provider).\n tool('insert:add-attachment', 'attachment', 'commands.insert.attachment', 'paperclip'),\n // Signatures open the PEOPLE panel (libraries of kind 'signatures'): pick a\n // mark → with a target field it signs (or fills) it, else it arms — a click\n // on a signature field signs, anywhere else drops a stamp (Preview).\n {\n id: 'insert:add-signature',\n labelKey: 'commands.insert.signature',\n icon: 'signature',\n visible: (c) => c.tryGet(StampToken) != null && c.tryGet(SignatureToken) != null,\n enabled: (c) => anno(c)?.canCreate() ?? true,\n categories: ['panel'],\n panel: { id: 'signatures', exclusive: 'right' },\n },\n // Image — the click-then-pick placement: click the spot, the file dialog\n // opens (narrowed to rasters), the picture lands where you clicked. The\n // tool itself is a `stamp` preset registered in viewer.tsx.\n tool('insert:add-image', 'image', 'commands.insert.image', 'photo'),\n\n // ── form tools (the form plugin's draw-to-place palette) ────────────────\n tool('form:add-textfield', 'form-text', 'commands.form.textfield', 'formTextfield'),\n tool('form:add-checkbox', 'form-checkbox', 'commands.form.checkbox', 'formCheckbox'),\n tool('form:add-radio', 'form-radio', 'commands.form.radio', 'formRadio'),\n tool('form:add-select', 'form-combobox', 'commands.form.select', 'formSelect'),\n tool('form:add-listbox', 'form-listbox', 'commands.form.listbox', 'formListbox'),\n tool('form:add-signature', 'form-signature', 'commands.form.signature', 'signature'),\n\n // ── redaction (v2 parity: the toolbar arms the tool; the panel owns the\n // destructive verbs — Apply All / Clear live in the redaction sidebar) ────\n tool('redaction:redact', 'redact', 'commands.redact.mark', 'redactArea'),\n {\n id: 'panel:redaction',\n labelKey: 'commands.redact.panel',\n icon: 'redactionSidebar',\n // Useful to a session that can propose marks OR apply them; with neither\n // power the panel could only display other people's pending marks.\n visible: (c) => {\n const r = c.tryGet(RedactionToken);\n return r ? r.canMark() || r.canApply() : true;\n },\n categories: ['panel'],\n panel: { id: 'redaction', exclusive: 'right' },\n },\n\n {\n ...tool('measurement:distance', 'distance', 'measurement.distance', 'distance', {\n primary: 'color',\n }),\n enabled: (c) => {\n const s = stage(c);\n const pon = s?.pages()[s.currentPage()]?.pon;\n return pon != null && (c.tryGet(MeasurementToken)?.canMeasure(pon) ?? false);\n },\n },\n {\n ...tool('measurement:perimeter', 'perimeter', 'measurement.perimeter', 'perimeter', {\n primary: 'color',\n }),\n enabled: (c) => {\n const s = stage(c);\n const pon = s?.pages()[s.currentPage()]?.pon;\n return pon != null && (c.tryGet(MeasurementToken)?.canMeasure(pon) ?? false);\n },\n },\n {\n ...tool('measurement:area', 'area', 'measurement.area', 'area', {\n primary: 'color',\n }),\n enabled: (c) => {\n const s = stage(c);\n const pon = s?.pages()[s.currentPage()]?.pon;\n return pon != null && (c.tryGet(MeasurementToken)?.canMeasure(pon) ?? false);\n },\n },\n {\n id: 'measurement:calibrate',\n labelKey: 'measurement.calibrate',\n icon: 'calibrate',\n categories: ['tool'],\n enabled: (c) => c.tryGet(MeasurementToken)?.canCalibrate() ?? false,\n active: (c) => interaction(c)?.activeToolId() === 'calibrate',\n run: (c) => c.tryGet(MeasurementToken)?.startCalibration(),\n },\n {\n id: 'panel:measurement',\n labelKey: 'measurement.title',\n icon: 'updateScale',\n categories: ['panel'],\n panel: { id: 'measurement', exclusive: 'right' },\n },\n\n // ── annotation selection (the floating strip's verbs) ──────────────────\n {\n id: 'annotation:cancel-creation',\n labelKey: 'commands.annotate.cancelCreation',\n categories: ['annotation'],\n shortcut: 'Escape',\n enabled: (c) => anno(c)?.hasCreationDraft() ?? false,\n run: (c) => anno(c)?.cancelCreationDraft(),\n },\n {\n id: 'annotation:delete',\n labelKey: 'commands.annotate.delete',\n icon: 'trash',\n categories: ['annotation'],\n run: (c) => {\n const a = anno(c);\n if (!a) return;\n const form = c.tryGet(FormToken);\n const dtos = a.getSelected();\n const widgets = form ? dtos.filter((d) => d.subtype === 'widget') : [];\n if (widgets.length === 0) {\n a.deleteSelection();\n return;\n }\n // Widgets are FIELD-plane citizens: deleting one goes through doc.forms\n // (the field and every widget of it cascade), never the raw annotation —\n // otherwise the /AcroForm entry would be orphaned.\n const keys = new Set<string>();\n for (const w of widgets) {\n const objnum = w.ref.kind === 'objectNumber' ? w.ref.annotObjectNumber : 0;\n const field = objnum > 0 ? form!.fieldForWidget(objnum) : null;\n if (field) keys.add(fieldKeyOf(field));\n }\n for (const key of keys) void form!.deleteField(key);\n for (const d of dtos) if (d.subtype !== 'widget') void a.delete(d.ref);\n a.deselect();\n },\n visible: hasAnnotationSelection,\n // Mirrors the engine's own authorization: locked/unauthorized annotations\n // keep the button visible but disabled (the engine still enforces).\n enabled: (c) => {\n const a = anno(c);\n const refs = a?.getSelection() ?? [];\n return refs.length > 0 && refs.every((r) => a!.canDelete(r));\n },\n },\n {\n id: 'annotation:comment',\n labelKey: 'commands.comment',\n icon: 'comment',\n categories: ['annotation'],\n // Same 'comment' surface panel:comment toggles — `active` derives from it.\n panel: { id: 'comment', exclusive: 'right' },\n visible: (c) => hasAnnotationSelection(c) && !selectionSubtypes(c).has('widget'),\n },\n {\n id: 'annotation:style',\n labelKey: 'commands.style',\n icon: 'palette',\n categories: ['annotation'],\n panel: { id: 'annotation-style', exclusive: 'right' },\n // The kind table decides: no declared editable props → no style button\n // (v2 hardcoded a subtype blocklist for this).\n visible: (c) => (anno(c)?.getSelectionProps().specs.length ?? 0) > 0,\n },\n {\n // The selection becomes a reusable stamp: the engine flattens the\n // selected appearances into one page (vector, positions kept) and the\n // stamp plugin files it under the user's own library — persisted like\n // any library, exportable as a PDF Acrobat reads.\n id: 'annotation:stamp-from-selection',\n labelKey: 'commands.annotate.stampFromSelection',\n icon: 'rubberStampPlus',\n categories: ['annotation'],\n run: (c) => {\n const a = anno(c);\n const stamp = c.tryGet(StampToken);\n const documentId = c.documentId;\n if (!a || !stamp || documentId == null) return;\n const dtos = a.getSelected();\n const pon = dtos[0]?.ref.pageObjectNumber;\n if (pon === undefined) return;\n const i18n = c.tryGet(I18nToken);\n const label = i18n?.t('demo.stampsCustomLabel') ?? 'Custom stamp';\n const libraryName = i18n?.t('demo.stampsCustomLibrary') ?? 'My stamps';\n const libraryId = CUSTOM_LIBRARY_ID;\n const ensureLibrary = stamp.library(libraryId)\n ? Promise.resolve(libraryId)\n : stamp.createLibrary(libraryName, { id: libraryId, categories: ['custom'] });\n ensureLibrary\n .then((id) =>\n stamp.addAssetFromAnnotations(\n documentId,\n pon,\n dtos.map((d) => d.ref),\n { libraryId: id, label: `${label} ${stamp.assets(id).length + 1}` },\n ),\n )\n // v2 jumped the sidebar to the custom library; the panel reads the\n // surface's open props for its picker.\n .then(() =>\n c.tryGet(ShellToken)?.open('stamps', {\n exclusive: 'right',\n props: { libraryId },\n }),\n )\n .catch((e) => console.warn('[embedpdf] stamp from selection failed', e));\n },\n // One page, no widgets (a form field is not artwork), no pending\n // redaction marks, and a library to put it in. The engine refuses hidden\n // or appearance-less annotations itself — all-or-nothing, never a stamp\n // missing a part.\n visible: (c) =>\n c.tryGet(StampToken) != null &&\n hasAnnotationSelection(c) &&\n !selectionSubtypes(c).has('widget') &&\n !selectionSubtypes(c).has('redact') &&\n new Set((anno(c)?.getSelected() ?? []).map((d) => d.ref.pageObjectNumber)).size === 1,\n enabled: (c) => c.tryGet(DocumentsToken)?.allows('doc.download') ?? true,\n },\n {\n id: 'annotation:group',\n labelKey: 'commands.annotate.group',\n icon: 'group',\n categories: ['annotation'],\n run: (c) => void anno(c)?.group(),\n visible: (c) => anno(c)?.canGroup() ?? false,\n },\n {\n id: 'annotation:ungroup',\n labelKey: 'commands.annotate.ungroup',\n icon: 'ungroup',\n categories: ['annotation'],\n run: (c) => void anno(c)?.ungroup(),\n visible: (c) => anno(c)?.canUngroup() ?? false,\n },\n\n // ── text selection (the selection strip's verbs) ────────────────────────\n {\n id: 'selection:copy',\n labelKey: 'commands.selection.copy',\n icon: 'copy',\n categories: ['selection'],\n // The permission story rides `visible`: a deployment denying\n // doc.text.copy shows no Copy at all — and with zero visible commands\n // the strip renders nothing, so there is never an empty bubble.\n visible: (c) => {\n const s = textSelection(c);\n return !!s && s.hasSelection() && s.canCopy();\n },\n // Async Clipboard write inside the click's activation window; instant\n // when <SelectionClipboard>'s commit prefetch already fetched the text.\n // A successful copy consumes the selection, which also dismisses its strip.\n run: (c) => {\n const s = textSelection(c);\n if (!s) return;\n const copiedRange = s.snapshot().range;\n void copySelection(s).then(\n (text) => {\n // Clipboard writes can outlive the click. Never let an older copy\n // completion clear a newer selection the user made in the meantime.\n if (text !== '' && sameTextRange(s.snapshot().range, copiedRange)) s.clear();\n },\n () => {}, // Copy failed: preserve the selection so the user can retry.\n );\n },\n },\n\n // ── link strip items (v2's \"Link / Go to link / Remove link\") ───────────\n {\n // Make the selection a link: opens the anchored POPOVER (v2's popup —\n // a link is a verb on the selection, not a style), whose editor sets\n // the target through `updateSelection({ link })`; the plugin's\n // reconciler materializes the attached child annotations.\n id: 'annotation:link',\n labelKey: 'commands.annotate.link',\n icon: 'link',\n categories: ['annotation'],\n run: (c) => c.tryGet(ShellToken)?.toggle('link-editor'),\n active: (c) => c.tryGet(ShellToken)?.isOpen('link-editor') ?? false,\n visible: (c) => selectionLink(c) === null,\n },\n {\n id: 'annotation:goto-link',\n labelKey: 'commands.annotate.gotoLink',\n icon: 'externalLink',\n categories: ['annotation'],\n run: (c) => {\n const target = selectionLink(c);\n const link = c.tryGet(LinkToken);\n // The opener PERFORMS the uri outcome (window.open) — bare `activate`\n // resolves but opens nothing for URL targets.\n if (target && link) openLinkTarget(link, target);\n },\n visible: (c) => selectionLink(c) != null,\n },\n {\n id: 'annotation:remove-link',\n labelKey: 'commands.annotate.removeLink',\n icon: 'linkOff',\n categories: ['annotation'],\n run: (c) => anno(c)?.updateSelection({ link: null }),\n visible: (c) => selectionLink(c) != null,\n },\n\n // ── history (no plugin yet → disabled, shows the disabled styling) ──────\n {\n id: 'history:undo',\n labelKey: 'commands.undo',\n icon: 'arrowBackUp',\n categories: ['history'],\n run: () => {},\n enabled: () => false,\n },\n {\n id: 'history:redo',\n labelKey: 'commands.redo',\n icon: 'arrowForwardUp',\n categories: ['history'],\n run: () => {},\n enabled: () => false,\n },\n];\n\n// ── mode helpers ─────────────────────────────────────────────────────────────\n// Modes are exclusive shell surfaces tagged 'mode'; the secondary band renders\n// whichever one is open. Kept below the array to keep the list readable.\nexport const MODE_SURFACES = [\n 'mode:annotate',\n 'mode:shapes',\n 'mode:insert',\n 'mode:form',\n 'mode:redact',\n 'mode:measure',\n] as const;\n\nfunction modeCommand(\n id: (typeof MODE_SURFACES)[number],\n labelKey: string,\n toolId: string = 'pointer',\n): CommandDef {\n return {\n id,\n labelKey,\n categories: ['mode'],\n // A mode tab is a shell surface AND a tool policy: the Form tab flips the\n // pointer into form design ('form-edit' — widgets select/move/resize like\n // annotations); every other tab (and closing one) drops back to the\n // default pointer, where widgets are fill controls again.\n run: (c) => {\n const shell = c.tryGet(ShellToken);\n shell?.toggle(id, { exclusive: 'mode' });\n interaction(c)?.activateTool(shell?.isOpen(id) ? toolId : 'pointer');\n },\n active: (c) => c.tryGet(ShellToken)?.isOpen(id) ?? false,\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