@sheetxl/studio-mui 0.8.0-beta.1 → 0.8.0-beta.10

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 (243) hide show
  1. package/browser/esm/{Cd6n1XUgF0VItpkH.mjs → 5cbK03T_Oh3tNdR7.mjs} +7 -5
  2. package/browser/esm/{Bz5LiUe3SZ8g42Ia.mjs → 9eKCkvqpMQwqcXiw.mjs} +1 -1
  3. package/browser/esm/B1Yp_uy1vFHcJB3U.mjs +13 -0
  4. package/browser/esm/Biy7bhzzzPb5sfRN.mjs +152 -0
  5. package/browser/esm/Blaj2R5hYxtLAW__.mjs +117 -0
  6. package/browser/esm/{ChwS_ougBsogOEsP.mjs → ByeL_BZuJ2kl8gtf.mjs} +46 -47
  7. package/browser/esm/{BUGepznywvV0tUjW.mjs → C1Rp2hZrApo5MUc8.mjs} +2 -2
  8. package/browser/esm/{DMLXV4EKl1NCp_jk.mjs → CEvZe2cZK-voZTif.mjs} +5 -5
  9. package/browser/esm/{BZBJG2tDdD3-VujP.mjs → CIu1bjPJe_x31Oww.mjs} +195 -174
  10. package/browser/esm/COv-m-c2byCgvU3M.mjs +14861 -0
  11. package/browser/esm/CjznclrKqJRi7u9O.mjs +77 -0
  12. package/browser/esm/{Cj2pgCNqBCGl4rTX.mjs → CoSiOS-og0zFw4Ws.mjs} +587 -556
  13. package/browser/esm/{rU8xNPVQtDSnujM-.mjs → CtEFHbzYNvYjDYvi.mjs} +7 -7
  14. package/browser/esm/D6S8kVTzOjCn0-SK.mjs +627 -0
  15. package/browser/esm/{DNDrQKMTzKzNMjl-.mjs → D8al_cJ4U-NgzwoK.mjs} +1 -1
  16. package/browser/esm/DBtc4lku0uHVcqWn.mjs +71 -0
  17. package/browser/esm/{BoLxSRdEWt-Yg2RI.mjs → DHY19rkSiiRZxShC.mjs} +130 -103
  18. package/browser/esm/{zWTZ8BvT4hjgC2ua.mjs → DU3J8Gcf-WpBxNYg.mjs} +11 -10
  19. package/browser/esm/Die9NXVFveHvcCT-.mjs +4205 -0
  20. package/browser/esm/{CVfuCNRpODUw04IH.mjs → DmCQbW4zwkT_Rq88.mjs} +1 -1
  21. package/browser/esm/IQLeaAbtGTipUsOD.mjs +516 -0
  22. package/browser/esm/{3ydDykDMtDYbfVVn.mjs → X1Db3b_7b_7OuCk6.mjs} +178 -129
  23. package/browser/esm/fb126BNj3F8URR19.mjs +225 -0
  24. package/browser/esm/index.mjs +418 -135
  25. package/browser/esm/sFOAxZpxXo-qvDSp.mjs +293 -0
  26. package/browser/esm/sam1KGQZ59B_fADz.mjs +1941 -0
  27. package/browser/esm/xKiLJKiLxto8SayF.mjs +256 -0
  28. package/browser/esm/yZxC4qUENOlMhVUH.mjs +68 -0
  29. package/licenses/dependencies.txt +58 -311
  30. package/node/esm/B8SQfjKjzYHLxzZR.mjs +632 -0
  31. package/node/esm/{DM7K7-284z-PczVz.mjs → BYVLi0md4AYuDsB_.mjs} +1 -1
  32. package/node/esm/BYsG3KYVmxSe_CIQ.mjs +294 -0
  33. package/node/esm/BYwXhrEwkRAt9nJS.mjs +71 -0
  34. package/node/esm/B_jRGdwGFkudwmL-.mjs +68 -0
  35. package/node/esm/Bb1sLMqXWKjdve23.mjs +77 -0
  36. package/node/esm/{BwZcoHDBmLPIVOT5.mjs → BcwMb6CyVfvEwbHn.mjs} +69 -70
  37. package/node/esm/{BhqI3pQFkV8K_612.mjs → CKu1AtRgyltyEdEN.mjs} +1 -1
  38. package/node/esm/Cmt8Wv806N7NmE4Y.mjs +3344 -0
  39. package/node/esm/{DXZrzWee8K5FPOW1.mjs → D6oQL8knsPpgdXuk.mjs} +2 -2
  40. package/node/esm/{BA7VzUQ2sKRLTZ5c.mjs → D9rzScOA9pEYFrtz.mjs} +1 -1
  41. package/node/esm/DNSjK5DAH3M14Qbc.mjs +521 -0
  42. package/node/esm/{CUMKTjYv6VTkcWYi.mjs → DZzvTQxIKr9LbEsA.mjs} +1 -1
  43. package/node/esm/{Qpuqm6xBr_da38Ht.mjs → ETK6T6G0SIcFXDe5.mjs} +163 -135
  44. package/node/esm/ah3CUg4-VmNstGk_.mjs +256 -0
  45. package/node/esm/{CHi3AuWEwEPOg9IZ.mjs → ci8d-mF1H9wnYzix.mjs} +1 -1
  46. package/node/esm/cqzp431iNSLWictb.mjs +116 -0
  47. package/node/esm/index.mjs +14783 -6793
  48. package/package.json +15 -18
  49. package/resources/locales/de/groups.cmd.json +29 -16
  50. package/resources/locales/de/studio.cmd.json +18 -1
  51. package/resources/locales/de/ui.msg.json +350 -40
  52. package/resources/locales/en/groups.cmd.json +39 -17
  53. package/resources/locales/en/studio.cmd.json +18 -1
  54. package/resources/locales/en/ui.msg.json +306 -40
  55. package/types/src/anchorItems/AnchorItemsDescriptor.d.ts +17 -1
  56. package/types/src/anchorItems/AnchorItemsPanel.d.ts +14 -0
  57. package/types/src/anchorItems/AnchoredRangeField.d.ts +40 -0
  58. package/types/src/anchorItems/index.d.ts +1 -0
  59. package/types/src/border/BorderPopupButton.d.ts +6 -6
  60. package/types/src/border/BorderStylePopupButton.d.ts +3 -3
  61. package/types/src/border/BorderTemplateIcon.d.ts +24 -0
  62. package/types/src/border/index.d.ts +1 -0
  63. package/types/src/color/ColorPanel.d.ts +8 -2
  64. package/types/src/color/ColorPopupButton.d.ts +2 -1
  65. package/types/src/command/NumberFormatQuickButtons.d.ts +32 -0
  66. package/types/src/command/PresetCellStylesCommandButton.d.ts +3 -3
  67. package/types/src/command/SheetZoomCommandButton.d.ts +4 -3
  68. package/types/src/comments/CommentCard.d.ts +41 -0
  69. package/types/src/comments/CommentsPlugin.d.ts +6 -0
  70. package/types/src/comments/CommentsTaskPane.d.ts +23 -0
  71. package/types/src/comments/index.d.ts +4 -0
  72. package/types/src/conditionalFormat/ConditionalFormatStylePicker.d.ts +4 -4
  73. package/types/src/conditionalFormat/IconPickerPopupButton.d.ts +2 -2
  74. package/types/src/conditionalFormat/IconSetRulePanel.d.ts +1 -1
  75. package/types/src/conditions/BetweenOption.d.ts +6 -1
  76. package/types/src/conditions/CombinatorOption.d.ts +7 -0
  77. package/types/src/conditions/ConditionEditor.d.ts +61 -4
  78. package/types/src/conditions/ConditionUtils.d.ts +65 -6
  79. package/types/src/conditions/ExpressionOption.d.ts +12 -6
  80. package/types/src/conditions/MembershipOption.d.ts +67 -0
  81. package/types/src/conditions/OperatorAndParamEditor.d.ts +36 -1
  82. package/types/src/conditions/ScalarOption.d.ts +25 -6
  83. package/types/src/conditions/SelectorSelect.d.ts +16 -7
  84. package/types/src/conditions/index.d.ts +1 -1
  85. package/types/src/conditions/useFormulaOption.d.ts +54 -0
  86. package/types/src/dataValidation/DataValidationDetailsPanel.d.ts +7 -1
  87. package/types/src/dataValidation/DataValidationDetailsTaskPane.d.ts +3 -2
  88. package/types/src/dataValidation/DataValidationEditorPanel.d.ts +13 -2
  89. package/types/src/dataValidation/DataValidationIcon.d.ts +22 -0
  90. package/types/src/dataValidation/DataValidationTitle.d.ts +13 -0
  91. package/types/src/dialog/FillSeriesDialog.d.ts +16 -0
  92. package/types/src/dialog/OutlineSettingsDialog.d.ts +12 -0
  93. package/types/src/dialog/TableNewDialog.d.ts +1 -4
  94. package/types/src/dialog/_ShortcutSearch.d.ts +26 -0
  95. package/types/src/dialog/index.d.ts +0 -2
  96. package/types/src/externalLink/ExternalLinkCardBody.d.ts +9 -0
  97. package/types/src/externalLink/ExternalLinkChip.d.ts +18 -0
  98. package/types/src/externalLink/ExternalLinkLocation.d.ts +18 -0
  99. package/types/src/externalLink/ExternalLinkSettingsTab.d.ts +18 -0
  100. package/types/src/externalLink/ExternalLinksPanel.d.ts +11 -0
  101. package/types/src/externalLink/ExternalLinksPlugin.d.ts +5 -0
  102. package/types/src/externalLink/ExternalLinksTaskPane.d.ts +19 -0
  103. package/types/src/externalLink/index.d.ts +8 -0
  104. package/types/src/fill/GradientEditor.d.ts +41 -0
  105. package/types/src/fill/GradientStopsBar.d.ts +43 -0
  106. package/types/src/fill/PatternPopupButton.d.ts +26 -0
  107. package/types/src/fill/PatternSwatch.d.ts +53 -0
  108. package/types/src/fill/index.d.ts +5 -0
  109. package/types/src/filter/ColumnMenu.d.ts +31 -1
  110. package/types/src/filter/index.d.ts +0 -1
  111. package/types/src/form/FormulaField.d.ts +35 -6
  112. package/types/src/form/InputField.d.ts +35 -5
  113. package/types/src/format/AlignmentPanel.d.ts +13 -0
  114. package/types/src/format/BorderPanel.d.ts +22 -0
  115. package/types/src/format/BorderPreview.d.ts +94 -0
  116. package/types/src/format/FillPanel.d.ts +65 -0
  117. package/types/src/format/FontPanel.d.ts +12 -0
  118. package/types/src/format/FormatCellPreview.d.ts +35 -0
  119. package/types/src/format/FormatPanelParts.d.ts +85 -0
  120. package/types/src/format/FormatPlugin.d.ts +11 -0
  121. package/types/src/format/FormatTaskPane.d.ts +39 -0
  122. package/types/src/format/LinePanel.d.ts +53 -0
  123. package/types/src/format/LinePreviews.d.ts +71 -0
  124. package/types/src/format/NumberFormatOption.d.ts +43 -0
  125. package/types/src/{numberFormat → format}/NumberFormatPanel.d.ts +20 -0
  126. package/types/src/format/index.d.ts +14 -0
  127. package/types/src/format/useFormatSelection.d.ts +93 -0
  128. package/types/src/formulaBar/IFormulaBar.d.ts +11 -0
  129. package/types/src/formulaBar/MobileFormulaBar.d.ts +21 -0
  130. package/types/src/formulaBar/MobileInputToolbar.d.ts +37 -0
  131. package/types/src/formulaBar/index.d.ts +3 -0
  132. package/types/src/formulaBar/useFormulaBarSession.d.ts +65 -0
  133. package/types/src/index.d.ts +7 -1
  134. package/types/src/itemsPanel/EditorCommit.d.ts +32 -0
  135. package/types/src/itemsPanel/EditorPanel.d.ts +4 -1
  136. package/types/src/itemsPanel/ItemCard.d.ts +60 -8
  137. package/types/src/itemsPanel/ItemsDescriptor.d.ts +68 -19
  138. package/types/src/itemsPanel/ItemsPanel.d.ts +9 -0
  139. package/types/src/itemsPanel/ItemsSearchField.d.ts +17 -0
  140. package/types/src/itemsPanel/index.d.ts +2 -0
  141. package/types/src/named/NamedDetailsPanel.d.ts +9 -2
  142. package/types/src/named/NamedDetailsTaskPane.d.ts +3 -2
  143. package/types/src/named/NamedEditorPanel.d.ts +1 -1
  144. package/types/src/named/NamedExpressionField.d.ts +32 -0
  145. package/types/src/named/NamedKindChip.d.ts +38 -0
  146. package/types/src/picture/PicturePlugin.d.ts +6 -0
  147. package/types/src/picture/index.d.ts +2 -0
  148. package/types/src/protectedRange/ProtectedRangeDetailsPanel.d.ts +6 -0
  149. package/types/src/protectedRange/ProtectedRangeDraft.d.ts +22 -0
  150. package/types/src/protectedRange/ProtectedRangeEditorPanel.d.ts +0 -14
  151. package/types/src/protectedRange/index.d.ts +2 -1
  152. package/types/src/protection/ManageProtectionTaskPane.d.ts +29 -0
  153. package/types/src/protection/PasswordDialog.d.ts +32 -0
  154. package/types/src/protection/PasswordField.d.ts +35 -0
  155. package/types/src/protection/ProtectedCellsPanel.d.ts +20 -0
  156. package/types/src/protection/ProtectionPlugin.d.ts +11 -0
  157. package/types/src/protection/SheetProtectionPanel.d.ts +35 -0
  158. package/types/src/protection/WorkbookProtectionPanel.d.ts +34 -15
  159. package/types/src/protection/WorkbookProtectionTab.d.ts +22 -0
  160. package/types/src/protection/index.d.ts +7 -1
  161. package/types/src/shape/InsertShapeCommandButton.d.ts +20 -0
  162. package/types/src/shape/ShapeFormatPanel.d.ts +11 -0
  163. package/types/src/shape/ShapePlugin.d.ts +6 -0
  164. package/types/src/shape/index.d.ts +3 -0
  165. package/types/src/slicer/PresetSlicerStylesCommandButton.d.ts +18 -0
  166. package/types/src/slicer/SlicerPlugin.d.ts +6 -0
  167. package/types/src/slicer/index.d.ts +3 -0
  168. package/types/src/statusBar/SheetZoomScale.d.ts +6 -0
  169. package/types/src/studio/CommandsWrapper.d.ts +5 -0
  170. package/types/src/studio/EagerStudio.d.ts +14 -1
  171. package/types/src/studio/StudioCommandProvider.d.ts +10 -0
  172. package/types/src/studio/StudioCommands.d.ts +40 -4
  173. package/types/src/studio/StudioProps.d.ts +64 -2
  174. package/types/src/studio/StudioSplitPane.d.ts +1 -1
  175. package/types/src/studio/formulaBarPlacement.d.ts +35 -0
  176. package/types/src/studio/splitStudioProps.d.ts +7 -0
  177. package/types/src/studio/useStudioApp.d.ts +31 -18
  178. package/types/src/template/TemplateCommands.d.ts +29 -0
  179. package/types/src/template/TemplateDialog.d.ts +19 -0
  180. package/types/src/template/TemplatePanel.d.ts +50 -0
  181. package/types/src/template/TemplateSearchField.d.ts +29 -0
  182. package/types/src/template/WelcomeDialog.d.ts +29 -0
  183. package/types/src/template/categoryColor.d.ts +8 -0
  184. package/types/src/template/index.d.ts +3 -0
  185. package/types/src/template/useTemplateCatalog.d.ts +71 -0
  186. package/types/src/toolbar/WorkbookToolbars.d.ts +1 -1
  187. package/types/src/workbook/DefaultRenderers.d.ts +15 -1
  188. package/types/src/workbook/FillMenu.d.ts +21 -0
  189. package/types/src/workbook/OutlineButtons.d.ts +11 -0
  190. package/types/src/workbook/WorkbookElement.d.ts +1 -1
  191. package/types/src/workbook/index.d.ts +1 -0
  192. package/browser/cjs/BQJKf40kttQWOzLw.cjs +0 -20
  193. package/browser/cjs/BTZ5uzK0wHzpiZGC.cjs +0 -1
  194. package/browser/cjs/B_D3JKseVvpRyX-E.cjs +0 -1
  195. package/browser/cjs/BeKpqOx8It0RD0Rf.cjs +0 -2
  196. package/browser/cjs/Bj-EvSYeDfqmU0V6.cjs +0 -2
  197. package/browser/cjs/Bo9Kx3L_XQkGPBJ5.cjs +0 -1
  198. package/browser/cjs/Bte6P3MhSjajJmmY.cjs +0 -7
  199. package/browser/cjs/C97KHSuikAbr1qVM.cjs +0 -1
  200. package/browser/cjs/CJLwX_A3y3TQUmzj.cjs +0 -1
  201. package/browser/cjs/CPSc2VSYZeZ1B9mi.cjs +0 -1
  202. package/browser/cjs/CPcBvw4ZPwHVTUZF.cjs +0 -1
  203. package/browser/cjs/CYxc8vnRi8dNpDPk.cjs +0 -1
  204. package/browser/cjs/CZm1jVZaHQ246prW.cjs +0 -1
  205. package/browser/cjs/CdDYyAfccXme8w6m.cjs +0 -1
  206. package/browser/cjs/Cm1APq2MraYNNhyI.cjs +0 -1
  207. package/browser/cjs/DO8V31Z1ewgMA1di.cjs +0 -5
  208. package/browser/cjs/Djsiad0Qha1Y-YaS.cjs +0 -1
  209. package/browser/cjs/IASAYG6qgv7lJY7y.cjs +0 -1
  210. package/browser/cjs/KZvriGbhEOVkQD0b.cjs +0 -1
  211. package/browser/cjs/UnMhi28mbvLiOXQe.cjs +0 -1
  212. package/browser/cjs/Vbigo0kFP3PFfmeA.cjs +0 -1
  213. package/browser/cjs/iMWEL01eC83oU-YY.cjs +0 -1
  214. package/browser/cjs/index.cjs +0 -2
  215. package/browser/cjs/w2GjebPlOFv3pCbm.cjs +0 -1
  216. package/browser/cjs/z0rB4fK6X1M6PpVD.cjs +0 -11
  217. package/browser/cjs/zQsyZpeXAvcVXJMs.cjs +0 -1
  218. package/browser/esm/BuY3uV47Bwbqpasq.mjs +0 -219
  219. package/browser/esm/CAs1MWvJTcRfJy26.mjs +0 -217
  220. package/browser/esm/CBU3LgLYmqtQjJbu.mjs +0 -1150
  221. package/browser/esm/CDU0rqpLNVtMLI-f.mjs +0 -52
  222. package/browser/esm/CVBub6pgTsJzCc5m.mjs +0 -5429
  223. package/browser/esm/C_XvSsQ9BVdHffCO.mjs +0 -47
  224. package/browser/esm/FT29q8yNwsEpVZjt.mjs +0 -9257
  225. package/browser/esm/Hb1rlHT4tE5hLcjM.mjs +0 -82
  226. package/browser/esm/UJOXCQv6KrG1gY3l.mjs +0 -105
  227. package/browser/esm/s46El7mT6oKLSnYB.mjs +0 -411
  228. package/node/esm/9FY82fj1R1c-AczW.mjs +0 -47
  229. package/node/esm/C-boHCnJditFzng3.mjs +0 -106
  230. package/node/esm/DxXM8qHi0Oz4Zovl.mjs +0 -4575
  231. package/node/esm/sQt2wWGTRLzqeJdG.mjs +0 -82
  232. package/node/esm/yCHAZKxJR7qY_ySy.mjs +0 -470
  233. package/types/src/conditionalFormat/ConditionalFormatRangeField.d.ts +0 -32
  234. package/types/src/conditions/DateTimeOption.d.ts +0 -43
  235. package/types/src/conditions/InSetOption.d.ts +0 -37
  236. package/types/src/dialog/CommentsDialog.d.ts +0 -11
  237. package/types/src/dialog/NumberFormatDialog.d.ts +0 -12
  238. package/types/src/filter/FilterList.d.ts +0 -28
  239. package/types/src/numberFormat/NumberFormatTaskPane.d.ts +0 -12
  240. package/types/src/numberFormat/index.d.ts +0 -8
  241. package/types/src/protectedRange/ProtectedRangeDetailsTaskPane.d.ts +0 -3
  242. package/types/src/protectedRange/ProtectedRangePlugin.d.ts +0 -2
  243. package/types/src/protection/WorkbookProtectionDialog.d.ts +0 -23
@@ -0,0 +1,32 @@
1
+ /**
2
+ * Commits whatever a field still holds onto the editor's draft.
3
+ *
4
+ * @returns `false` to refuse the save — the field holds text it cannot commit — which leaves the
5
+ * editor open on it.
6
+ */
7
+ export type EditorCommit = () => boolean;
8
+ /**
9
+ * Where a field inside an {@link EditorPanel} registers to be committed when Save is pressed.
10
+ */
11
+ export interface EditorCommits {
12
+ /**
13
+ * @returns An unregister callback.
14
+ */
15
+ register(commit: EditorCommit): () => void;
16
+ }
17
+ /**
18
+ * Provided by {@link EditorPanel}; `null` outside of one.
19
+ */
20
+ export declare const EditorCommitContext: import('react').Context<EditorCommits | null>;
21
+ /**
22
+ * Has the enclosing {@link EditorPanel} commit this field before it saves.
23
+ *
24
+ * @remarks
25
+ * For a field that commits on done rather than per change. Its commit points are its own keys, its
26
+ * ✓ and a blur to another field; Save is a button, which takes focus without any of them, so text
27
+ * typed but not yet committed would never reach the draft the save reads.
28
+ *
29
+ * Does nothing outside an editor — the same field on a card has no Save to answer to.
30
+ */
31
+ export declare const useEditorCommit: (commit: EditorCommit) => void;
32
+ //# sourceMappingURL=EditorCommit.d.ts.map
@@ -3,8 +3,11 @@ import { ItemMessageKeys } from './ItemsDescriptor';
3
3
  export interface EditorProps extends React.HTMLAttributes<HTMLDivElement> {
4
4
  /**
5
5
  * The feature's catalog keys for the cancel/save labels.
6
+ *
7
+ * `Required`, because these are the editor's own buttons: a list that reaches this panel at all
8
+ * is an authorable one, and an authorable list supplies them (see `ItemsDescriptor.createDraft`).
6
9
  */
7
- messageKeys: Pick<ItemMessageKeys, 'cancel' | 'save'>;
10
+ messageKeys: Required<Pick<ItemMessageKeys, 'cancel' | 'save'>>;
8
11
  /**
9
12
  * Called when save is requested
10
13
  */
@@ -1,11 +1,13 @@
1
1
  import { default as React } from 'react';
2
+ import { SxProps, Theme } from '@mui/material';
2
3
  import { ItemBodyProps, ItemMessageKeys } from './ItemsDescriptor';
3
4
  export interface ItemCardProps<T = any> extends React.HTMLAttributes<HTMLDivElement> {
4
5
  item: T;
5
6
  /**
6
- * The feature's catalog keys for the action tooltips.
7
+ * The feature's catalog keys for the built-in action tooltips. A built-in action whose key is
8
+ * missing is not offered.
7
9
  */
8
- messageKeys: Pick<ItemMessageKeys, 'moveUp' | 'moveDown' | 'edit' | 'duplicate' | 'delete'>;
10
+ messageKeys: Partial<Pick<ItemMessageKeys, 'moveUp' | 'moveDown' | 'edit' | 'duplicate' | 'delete'>>;
9
11
  /**
10
12
  * The one-line header.
11
13
  */
@@ -14,13 +16,34 @@ export interface ItemCardProps<T = any> extends React.HTMLAttributes<HTMLDivElem
14
16
  * The emphasized line below the header. `null` renders nothing.
15
17
  */
16
18
  subtitle?: string | null;
19
+ /**
20
+ * A quiet second line under the title, beside the {@link Media}. For a detail that belongs to the
21
+ * title (where an item is) rather than a section of the card under a divider, as {@link subtitle}
22
+ * is. With a caption the media and the actions align to the title's line rather than centering on
23
+ * the two lines.
24
+ */
25
+ caption?: React.ReactNode;
17
26
  /**
18
27
  * Hides every action affordance.
19
28
  */
20
29
  readOnly?: boolean;
30
+ /**
31
+ * Marks the card as the one the host is pointing at (the item revealed on the grid). Drawn as the
32
+ * focus outline, without taking focus.
33
+ */
34
+ selected?: boolean;
21
35
  canMoveUp?: boolean;
22
36
  canMoveDown?: boolean;
23
- onEdit: () => void;
37
+ /**
38
+ * Omit for an item with no editor — the title is then plain text and no edit action is offered.
39
+ * See `ItemsDescriptor.createDraft`.
40
+ */
41
+ onEdit?: () => void;
42
+ /**
43
+ * A click on the card's surface — anywhere that is not the title, an action, or a control the
44
+ * card carries. Omit when there is nothing on the grid to select.
45
+ */
46
+ onSelect?: () => void;
24
47
  /**
25
48
  * Omit to hide the move affordances (unordered list).
26
49
  */
@@ -29,11 +52,24 @@ export interface ItemCardProps<T = any> extends React.HTMLAttributes<HTMLDivElem
29
52
  * Omit to hide the duplicate affordance.
30
53
  */
31
54
  onDuplicate?: () => void;
32
- onDelete: () => void;
55
+ /**
56
+ * Omit to hide the delete affordance.
57
+ */
58
+ onDelete?: () => void;
59
+ /**
60
+ * The feature's own actions, shown in the hover row ahead of the built-in ones. Use
61
+ * {@link ItemCardAction} so they look and behave as the built-in ones do.
62
+ */
63
+ actions?: React.ReactNode;
33
64
  /**
34
65
  * Subscribes to the item's own events to re-render this card.
35
66
  */
36
67
  subscribeItem?: (item: T, onChange: () => void) => () => void;
68
+ /**
69
+ * Merged over the card's own styling — a host's accent (`'&.Mui-selected'`'s outline) or density
70
+ * (`gap`).
71
+ */
72
+ sx?: SxProps<Theme>;
37
73
  /**
38
74
  * Leading visual at the card's top-left, before the title.
39
75
  */
@@ -48,10 +84,26 @@ export interface ItemCardProps<T = any> extends React.HTMLAttributes<HTMLDivElem
48
84
  */
49
85
  Subtitle?: React.ComponentType<ItemBodyProps<T>>;
50
86
  }
87
+ export interface ItemCardActionProps {
88
+ /** The tooltip, already translated. Also the button's accessible name. */
89
+ title: string;
90
+ iconKey: string;
91
+ onClick: () => void;
92
+ disabled?: boolean;
93
+ }
94
+ /**
95
+ * One action in a card's hover row — the built-in ones (move, edit, duplicate, delete) and a
96
+ * feature's own (`ItemCardProps.actions`) alike. Its click does not reach the card.
97
+ */
98
+ export declare const ItemCardAction: React.NamedExoticComponent<ItemCardActionProps>;
51
99
  /**
52
- * Card chrome for one listed item: hover/focus action row (move/edit/duplicate/delete), title,
53
- * subtitle (a string, or a feature's own control via {@link ItemCardProps.Subtitle}), and an
54
- * optional feature body.
100
+ * Card chrome for one listed item. See {@link ItemCardProps}.
101
+ *
102
+ * @remarks
103
+ * `memo` erases the item type; this restores it, so a card's `Media`, `Subtitle` and `Body` are typed
104
+ * against the item they are handed.
55
105
  */
56
- export declare const ItemCard: React.MemoExoticComponent<(<T = any>(props: ItemCardProps<T>) => React.JSX.Element)>;
106
+ export declare const ItemCard: (<T = any>(props: ItemCardProps<T>) => React.ReactElement) & {
107
+ displayName?: string;
108
+ };
57
109
  //# sourceMappingURL=ItemCard.d.ts.map
@@ -50,27 +50,37 @@ export interface ItemEditorProps<D> {
50
50
  * English catalog while it is still in use.
51
51
  */
52
52
  export interface ItemMessageKeys {
53
- /** Empty-list text when nothing can be added (read-only). */
53
+ /** Empty-list text when nothing can be added (read-only, or an unauthorable list). */
54
54
  none: string;
55
- /** Empty-list text inviting the first item. */
56
- addPrompt: string;
57
- /** List header. */
58
- heading: string;
59
- /** Tooltip on the header's add affordance. */
60
- insert: string;
61
- /** Label of the empty-list add button. */
62
- new: string;
63
- /** Card action tooltips. */
64
- edit: string;
55
+ /**
56
+ * Empty-list text inviting the first item. Required for an AUTHORABLE list — see
57
+ * {@link ItemsDescriptor.createDraft}.
58
+ */
59
+ addPrompt?: string;
60
+ /** List header. Omit when the pane's own chrome (a tab, a section title) already names the list. */
61
+ heading?: string;
62
+ /** Tooltip on the header's add affordance. Authorable lists only. */
63
+ insert?: string;
64
+ /** Label of the empty-list add button. Authorable lists only. */
65
+ new?: string;
66
+ /** Card action tooltips. `edit` is for authorable lists only. */
67
+ edit?: string;
65
68
  delete: string;
66
69
  /** Card duplicate tooltip. Required when the feature supplies {@link ItemsDescriptor.duplicate}. */
67
70
  duplicate?: string;
68
- /** Editor buttons. */
69
- cancel: string;
70
- save: string;
71
+ /** Editor buttons. Authorable lists only. */
72
+ cancel?: string;
73
+ save?: string;
71
74
  /** Card reorder tooltips. Required when the feature supplies {@link ItemsDescriptor.moveBy}. */
72
75
  moveUp?: string;
73
76
  moveDown?: string;
77
+ /**
78
+ * Search field placeholder, its clear-button tooltip, and the text shown when a query matches
79
+ * nothing. Required when the feature supplies {@link ItemsDescriptor.getSearchText}.
80
+ */
81
+ search?: string;
82
+ clearSearch?: string;
83
+ noMatches?: string;
74
84
  }
75
85
  /**
76
86
  * Describes one listable feature to the generic {@link ItemsPanel}: where its items come from,
@@ -141,8 +151,14 @@ export interface ItemsDescriptor<T = any, D = T> {
141
151
  * `createItem` and edits that. A collection with no such notion — defined names are
142
152
  * aggregated from registries that own them, so there is nothing to detach — returns a plain
143
153
  * object instead, and {@link save} applies it. The panel only ever hands it back.
154
+ *
155
+ * **Omit it, with {@link save} and {@link EditorBody}, for a list that can be ACTED ON but not
156
+ * AUTHORED** — external links are made by typing a formula, and each one is an immutable
157
+ * snapshot, so the list offers Go to and Break link and no editor at all. The panel then shows
158
+ * no add affordance and no edit action, and the card title is plain text rather than a way in.
159
+ * This is not the same as {@link isReadOnly}, which hides every action including delete.
144
160
  */
145
- createDraft(workbook: IWorkbook, template?: T): D;
161
+ createDraft?(workbook: IWorkbook, template?: T): D;
146
162
  /**
147
163
  * Creates a draft from an ACTIVATION seed — the `draft` of the task pane's `ItemsPaneArgs`, put
148
164
  * there by whatever opened the pane (a conditional-format preset command, say). The panel opens
@@ -162,6 +178,19 @@ export interface ItemsDescriptor<T = any, D = T> {
162
178
  * {@link save} reads it (hashing a password, say).
163
179
  */
164
180
  beforeSave?(draft: D): Promise<void> | void;
181
+ /**
182
+ * Whether the draft can be saved as it is.
183
+ *
184
+ * @returns A message key naming the problem, or `null`. The problem is shown and the editor stays
185
+ * open on the draft.
186
+ *
187
+ * @remarks
188
+ * Asked after the editor's fields have committed what they still held and after
189
+ * {@link beforeSave}, so it reads the draft as {@link save} would. For what a single field
190
+ * cannot take, the field refuses the save itself (`useEditorCommit`); this is for what only the
191
+ * whole draft can answer — bounds the wrong way around, a condition missing an operand.
192
+ */
193
+ validate?(draft: D): string | null;
165
194
  /**
166
195
  * Persists the draft.
167
196
  *
@@ -172,9 +201,11 @@ export interface ItemsDescriptor<T = any, D = T> {
172
201
  * Whatever spans more than one model write belongs in one transaction here, or undo unwinds a
173
202
  * single edit a field at a time.
174
203
  */
175
- save(workbook: IWorkbook, draft: D, target: T | null): Promise<void> | void;
204
+ save?(workbook: IWorkbook, draft: D, target: T | null): Promise<void> | void;
176
205
  /**
177
- * Removes an item.
206
+ * Removes an item. For a list whose items are not deleted so much as retired — breaking an
207
+ * external link turns its formulas into values first — this is that operation, and
208
+ * {@link ItemMessageKeys.delete} names it.
178
209
  */
179
210
  delete(item: T, workbook: IWorkbook): void;
180
211
  /**
@@ -186,6 +217,23 @@ export interface ItemsDescriptor<T = any, D = T> {
186
217
  * move affordances.
187
218
  */
188
219
  moveBy?(item: T, delta: number, workbook: IWorkbook): void;
220
+ /**
221
+ * Selects what an item designates on the grid. Invoked by a click on the card's SURFACE — not on
222
+ * its title, its actions, or a field it carries, which act for themselves.
223
+ *
224
+ * @remarks
225
+ * Omit when nothing on the grid corresponds to an item. An item that sometimes has nothing to
226
+ * select (a name holding a constant) simply does nothing.
227
+ */
228
+ select?(item: T, workbook: IWorkbook): void;
229
+ /**
230
+ * The text a search query is matched against — everything a user might remember an item by.
231
+ *
232
+ * @remarks
233
+ * Supplying it puts a search field over the list. Matching is a case-insensitive substring
234
+ * test the panel performs; the feature only says what is searchable.
235
+ */
236
+ getSearchText?(item: T, t: (key: string, options?: any) => string): string;
189
237
  /**
190
238
  * The one-line card header.
191
239
  */
@@ -208,8 +256,9 @@ export interface ItemsDescriptor<T = any, D = T> {
208
256
  */
209
257
  CardSubtitle?: React.ComponentType<ItemBodyProps<T>>;
210
258
  /**
211
- * The feature editor, rendered inside the save/cancel shell.
259
+ * The feature editor, rendered inside the save/cancel shell. Omit for an unauthorable list —
260
+ * see {@link createDraft}.
212
261
  */
213
- EditorBody: React.ComponentType<ItemEditorProps<D>>;
262
+ EditorBody?: React.ComponentType<ItemEditorProps<D>>;
214
263
  }
215
264
  //# sourceMappingURL=ItemsDescriptor.d.ts.map
@@ -23,6 +23,15 @@ export interface ItemsPanelProps<T = any, D = T> extends React.HTMLAttributes<HT
23
23
  * `descriptor.getItems`, so the feature panel holds both and rebuilds the descriptor.
24
24
  */
25
25
  headerActions?: React.ReactNode;
26
+ /**
27
+ * Rendered right-aligned under the search field — view toggles that qualify what the list shows
28
+ * (a hidden-items switch) and should read as secondary to it, not as a peer of the heading.
29
+ *
30
+ * @remarks
31
+ * Kept reachable when the list is empty, for the same reason as {@link headerActions}: an empty
32
+ * list is a state these controls can produce.
33
+ */
34
+ listActions?: React.ReactNode;
26
35
  /**
27
36
  * Enables drag reordering of the cards, and animates every reorder — dropped drags and the
28
37
  * move up/down buttons alike.
@@ -0,0 +1,17 @@
1
+ import { default as React } from 'react';
2
+ import { SxProps, Theme } from '@mui/material';
3
+ export interface ItemsSearchFieldProps {
4
+ value: string;
5
+ onChange: (value: string) => void;
6
+ /** Placeholder, already translated. Also the field's accessible name. */
7
+ placeholder?: string;
8
+ /** The clear button's tooltip, already translated. */
9
+ clearLabel?: string;
10
+ sx?: SxProps<Theme>;
11
+ }
12
+ /**
13
+ * The search field above a card list: a find glyph, a clear button while there is a query, and
14
+ * Escape clearing the query before it does anything else.
15
+ */
16
+ export declare const ItemsSearchField: React.NamedExoticComponent<ItemsSearchFieldProps>;
17
+ //# sourceMappingURL=ItemsSearchField.d.ts.map
@@ -2,5 +2,7 @@ export * from './ItemsDescriptor';
2
2
  export * from './ItemsPanel';
3
3
  export * from './ItemCard';
4
4
  export * from './EditorPanel';
5
+ export * from './EditorCommit';
5
6
  export * from './SortableCards';
7
+ export * from './ItemsSearchField';
6
8
  //# sourceMappingURL=index.d.ts.map
@@ -1,11 +1,18 @@
1
1
  import { default as React } from 'react';
2
- import { IWorkbook } from '@sheetxl/sdk';
2
+ import { IWorkbook, INamed } from '@sheetxl/sdk';
3
+ import { ItemsPaneArgs } from '@sheetxl/react';
3
4
  export interface NamedDetailsPanelProps extends React.HTMLAttributes<HTMLDivElement> {
4
5
  workbook: IWorkbook;
6
+ /**
7
+ * The task pane's activation argument. `insert` opens the pane on a new name and `edit` on an
8
+ * existing one — how the name box's "Define Name…" and "Edit…" reach this editor rather than a
9
+ * dialog of their own. Nothing is seeded from properties: a name has no preset to hand over.
10
+ */
11
+ args?: ItemsPaneArgs<never, INamed>;
5
12
  }
6
13
  /**
7
14
  * The managed-names task pane: every defined name in the workbook — across all scopes and of every
8
- * type — with add/edit/delete and a hidden-names toggle.
15
+ * type — with add/edit/delete, search, and a hidden-names toggle.
9
16
  */
10
17
  export declare const NamedDetailsPanel: React.NamedExoticComponent<NamedDetailsPanelProps & React.RefAttributes<HTMLDivElement>>;
11
18
  //# sourceMappingURL=NamedDetailsPanel.d.ts.map
@@ -1,3 +1,4 @@
1
- import { TaskPaneProps } from '@sheetxl/react';
2
- export declare const NamedDetailsTaskPane: (props: TaskPaneProps) => import("react").JSX.Element;
1
+ import { INamed } from '@sheetxl/sdk';
2
+ import { TaskPaneProps, ItemsPaneArgs } from '@sheetxl/react';
3
+ export declare const NamedDetailsTaskPane: (props: TaskPaneProps<any, ItemsPaneArgs<never, INamed>>) => import("react").JSX.Element;
3
4
  //# sourceMappingURL=NamedDetailsTaskPane.d.ts.map
@@ -9,7 +9,7 @@ export interface NamedEditorPanelProps {
9
9
  workbook: IWorkbook;
10
10
  }
11
11
  /**
12
- * Editor panel for one defined name: its name, scope, expression, comment and visibility.
12
+ * Editor panel for one defined name: its name, expression, scope, comment and visibility.
13
13
  *
14
14
  * @remarks
15
15
  * Writes straight through to {@link NamedDraft} while mirroring each field in local state to
@@ -0,0 +1,32 @@
1
+ import { default as React } from 'react';
2
+ import { INamed } from '@sheetxl/sdk';
3
+ export interface NamedExpressionFieldProps {
4
+ /**
5
+ * The name to redefine. Written through on commit.
6
+ */
7
+ named: INamed;
8
+ /**
9
+ * Field label. Defaults to "Refers To"; `null` renders none, for a host that names it itself.
10
+ */
11
+ label?: React.ReactNode | null;
12
+ /**
13
+ * Helper line below the field. Defaults to `null` (none) — a reserved line is left for the error
14
+ * message, which is the one thing a user can get wrong here.
15
+ */
16
+ helperText?: React.ReactNode | null;
17
+ }
18
+ /**
19
+ * A name's "Refers to" — its expression, as a formula field that writes back to the name.
20
+ *
21
+ * @remarks
22
+ * The card's counterpart to a conditional format's "Apply to": re-pointing a name is the edit
23
+ * users reach for most, and it needs none of the editor. The FORMULA grammar, not `'reference'`,
24
+ * for the reason the editor gives — a name refers to any expression, of which a range is only the
25
+ * common case — and unanchored, so references stay sheet-qualified.
26
+ *
27
+ * Commit-on-done: a redefinition lands one entry on the undo stack and re-resolves every formula
28
+ * that reads the name, so it is not something to do on every keystroke. A derived name (a table's)
29
+ * shows its range but takes no edit; renaming or resizing a table belongs to the table.
30
+ */
31
+ export declare const NamedExpressionField: React.NamedExoticComponent<NamedExpressionFieldProps>;
32
+ //# sourceMappingURL=NamedExpressionField.d.ts.map
@@ -0,0 +1,38 @@
1
+ import { default as React } from 'react';
2
+ import { IWorkbook, INamed } from '@sheetxl/sdk';
3
+ /**
4
+ * What a name IS, as far as its glyph is concerned.
5
+ *
6
+ * @remarks
7
+ * `'range'` and `'formula'` are the same model — a named formula whose expression is a pure
8
+ * reference (`INamedFormula.getRanges` answers) against one whose expression is anything else. A
9
+ * `'table'` is a derived name a table owns; see `isEditableNamed`.
10
+ */
11
+ export type NamedKind = 'table' | 'range' | 'formula';
12
+ /**
13
+ * The {@link NamedKind} of an existing name.
14
+ */
15
+ export declare const namedKindOf: (item: INamed) => NamedKind;
16
+ /**
17
+ * The {@link NamedKind} an expression being AUTHORED would define — for the editor, where there is
18
+ * no item to ask yet.
19
+ */
20
+ export declare const namedKindOfExpression: (workbook: IWorkbook, expression: string) => NamedKind;
21
+ export interface NamedKindChipProps extends React.HTMLAttributes<HTMLElement> {
22
+ kind: NamedKind;
23
+ /**
24
+ * Chip height in px.
25
+ * @defaultValue 28
26
+ */
27
+ size?: number;
28
+ }
29
+ /**
30
+ * The glyph that leads a name's card and its editor: a table, a range, or a formula.
31
+ *
32
+ * @remarks
33
+ * Drawn in the same chip, at the same footprint, as a conditional format's preview — the two
34
+ * panes sit in the same task pane, and a reader moving between them should find the leading
35
+ * visual in the same place at the same size.
36
+ */
37
+ export declare const NamedKindChip: React.NamedExoticComponent<NamedKindChipProps>;
38
+ //# sourceMappingURL=NamedKindChip.d.ts.map
@@ -0,0 +1,6 @@
1
+ /**
2
+ * The studio's additions to pictures, added through the picture kind's contribution points as any
3
+ * host's would be.
4
+ */
5
+ export declare const PicturePlugin: () => void;
6
+ //# sourceMappingURL=PicturePlugin.d.ts.map
@@ -0,0 +1,2 @@
1
+ export * from './PicturePlugin';
2
+ //# sourceMappingURL=index.d.ts.map
@@ -1,5 +1,6 @@
1
1
  import { default as React } from 'react';
2
2
  import { IWorkbook, IProtectedRange } from '@sheetxl/sdk';
3
+ import { ItemsPaneArgs } from '@sheetxl/react';
3
4
  import { AnchorItemsDescriptor } from '../anchorItems';
4
5
  /**
5
6
  * Binds protected ranges to the generic {@link AnchorItemsPanel}.
@@ -11,6 +12,11 @@ import { AnchorItemsDescriptor } from '../anchorItems';
11
12
  export declare const ProtectedRangeItemsDescriptor: AnchorItemsDescriptor<IProtectedRange>;
12
13
  export interface ProtectedRangeDetailsPanelProps extends React.HTMLAttributes<HTMLDivElement> {
13
14
  workbook: IWorkbook;
15
+ /**
16
+ * The task pane's activation argument. `insert: true` opens the pane on a new range anchored to
17
+ * the selection, rather than on the list — what "Unlock Range…" asks for.
18
+ */
19
+ args?: ItemsPaneArgs;
14
20
  }
15
21
  /**
16
22
  * The protected-ranges task pane: the generic anchored-items list driven by
@@ -0,0 +1,22 @@
1
+ import { IProtectedRange } from '@sheetxl/sdk';
2
+ /**
3
+ * Plain-text passwords staged for the temporary item being edited.
4
+ *
5
+ * @remarks
6
+ * `IProtectedRange.setPassword` hashes, so it is async and cannot run from the editor without
7
+ * racing the Save button. The editor parks the plain text here and the descriptor's `beforeSave`
8
+ * awaits the hash — so the plain text lives only as long as the editor is open and never reaches
9
+ * the model, its JSON, or the file.
10
+ *
11
+ * Absent means "unchanged"; `null` means "remove it".
12
+ */
13
+ export declare const stagedPasswords: WeakMap<IProtectedRange, string | null>;
14
+ /**
15
+ * Applies any staged password to `item`. Called from the descriptor's `beforeSave`.
16
+ *
17
+ * @remarks
18
+ * Nothing to validate: the password is typed and confirmed in `PasswordDialog`, which only reports
19
+ * one it has already checked against its confirm field.
20
+ */
21
+ export declare const flushStagedPassword: (item: IProtectedRange) => Promise<void>;
22
+ //# sourceMappingURL=ProtectedRangeDraft.d.ts.map
@@ -1,19 +1,5 @@
1
1
  import { default as React } from 'react';
2
2
  import { IProtectedRange } from '@sheetxl/sdk';
3
- /**
4
- * Plain-text passwords staged for the temporary item being edited.
5
- *
6
- * @remarks
7
- * `IProtectedRange.setPassword` hashes, so it is async and cannot run from a field's `onChange`
8
- * without racing the Save button. The editor parks the plain text here and the descriptor's
9
- * `beforeSave` awaits the hash — so the plain text lives only as long as the editor is open and
10
- * never reaches the model, its JSON, or the file.
11
- *
12
- * `undefined` (absent) means "unchanged"; `null` means "clear it".
13
- */
14
- export declare const stagedPasswords: WeakMap<IProtectedRange, string | null>;
15
- /** Applies any staged password to `item`. Called from the descriptor's `beforeSave`. */
16
- export declare const flushStagedPassword: (item: IProtectedRange) => Promise<void>;
17
3
  export interface ProtectedRangeEditorPanelProps {
18
4
  /**
19
5
  * The protected range to edit.
@@ -1,2 +1,3 @@
1
- export * from './ProtectedRangePlugin';
1
+ export * from './ProtectedRangeDraft';
2
+ export * from './ProtectedRangeDetailsPanel';
2
3
  //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1,29 @@
1
+ import { default as React } from 'react';
2
+ import { IWorkbook } from '@sheetxl/sdk';
3
+ import { TaskPaneProps, ProtectionPaneArgs } from '@sheetxl/react';
4
+ export interface ManageProtectionTaskPaneProps extends TaskPaneProps<IWorkbook, ProtectionPaneArgs> {
5
+ /** The tab shown when the pane opens with no `args`. @defaultValue `'sheet'` */
6
+ defaultTab?: ProtectionPaneArgs.Tab;
7
+ }
8
+ /**
9
+ * **Manage Protection** — sheet protection, the selected cells' protection, the ranges that stay
10
+ * editable, and workbook protection, as four tabs of one pane.
11
+ *
12
+ * @remarks
13
+ * Tabs rather than Excel online's collapsible sections: the Ranges list is a full-height
14
+ * items panel with its own scroll, and stacking it under fifteen checkboxes would put two scrolling
15
+ * regions in one column.
16
+ *
17
+ * The tab is an ACTIVATION argument, not pane state, so the three entry points that used to open
18
+ * three separate surfaces each land where they mean to — and re-activating without one leaves the
19
+ * pane where the user left it (the area delivers `args` per activation, so an arriving value is an
20
+ * event; see {@link TaskPaneProps.args}).
21
+ */
22
+ export declare const ManageProtectionTaskPane: React.MemoExoticComponent<(props: ManageProtectionTaskPaneProps) => React.JSX.Element | null>;
23
+ /**
24
+ * Back-compat host for the retired `protectedRangeDetails` pane key — the same pane, opened on
25
+ * Ranges.
26
+ */
27
+ export declare const ProtectedRangeDetailsTaskPane: (props: TaskPaneProps<IWorkbook, ProtectionPaneArgs>) => React.JSX.Element;
28
+ export default ManageProtectionTaskPane;
29
+ //# sourceMappingURL=ManageProtectionTaskPane.d.ts.map
@@ -0,0 +1,32 @@
1
+ import { default as React } from 'react';
2
+ import { OptionsDialogProps } from '@sheetxl/utils-mui';
3
+ export interface PasswordDialogProps extends Omit<OptionsDialogProps, 'onOption' | 'children'> {
4
+ /** One line above the fields saying what this password will protect. */
5
+ description?: string;
6
+ /**
7
+ * Ask for the password already in force, above the new one.
8
+ *
9
+ * @remarks
10
+ * For a *change*: the model verifies the current password before it will write a new hash, so
11
+ * asking here keeps the whole edit in one dialog rather than a prompt followed by a dialog.
12
+ */
13
+ requireCurrent?: boolean;
14
+ /** Called with the new password when the user confirms; not called on cancel. */
15
+ onApply(password: string, current?: string): void | Promise<void>;
16
+ }
17
+ /**
18
+ * Sets one password — for a sheet, an unlocked range, workbook structure, or encryption.
19
+ *
20
+ * @remarks
21
+ * The **one** place a password is typed. It replaced a pair of inline fields on every panel that
22
+ * could hold a password, which had to show a sentinel (`••••••••`) standing in for a hash nobody can
23
+ * read back, and left every panel explaining the difference between "unchanged", "cleared" and
24
+ * "new". A panel now shows only whether a password is set, and this dialog is the whole edit.
25
+ *
26
+ * The confirm field is what makes it a dialog rather than a single prompt: a password that cannot be
27
+ * read back and cannot be recovered has to be typed twice, and Excel desktop confirms it in a second
28
+ * dialog for the same reason.
29
+ */
30
+ export declare const PasswordDialog: React.FC<PasswordDialogProps>;
31
+ export default PasswordDialog;
32
+ //# sourceMappingURL=PasswordDialog.d.ts.map
@@ -0,0 +1,35 @@
1
+ import { default as React } from 'react';
2
+ export interface PasswordFieldProps {
3
+ /** Whether a password is in force (or staged to be). */
4
+ hasPassword: boolean;
5
+ /** Heading above the row. Omit for a row that sits under someone else's heading. */
6
+ label?: string;
7
+ /** One line inside the dialog saying what this password will protect. */
8
+ description?: string;
9
+ /** Shown in place of the "a password is set" line — e.g. "will be set when you protect". */
10
+ note?: string;
11
+ disabled?: boolean;
12
+ /**
13
+ * Ask for the password already in force alongside the new one.
14
+ *
15
+ * @remarks
16
+ * True where the model verifies before it will write a new hash — a protected sheet, a protected
17
+ * workbook. False where the password is only staged and nothing has been committed yet.
18
+ */
19
+ requireCurrent?: boolean;
20
+ onSet(password: string, current?: string): void | Promise<void>;
21
+ onClear(): void | Promise<void>;
22
+ }
23
+ /**
24
+ * The password **row**: whether one is set, and the two things you can do about it.
25
+ *
26
+ * @remarks
27
+ * Deliberately not a text field. A password we hold as a hash cannot be read back, so an input
28
+ * showing it can only show a sentinel — and then every panel has to explain what an untouched
29
+ * sentinel, an emptied field and a typed value each mean. Set and Clear are the two acts; the
30
+ * typing happens in {@link PasswordDialog}, which is shared by the sheet, unlocked ranges, workbook
31
+ * structure and encryption.
32
+ */
33
+ export declare const PasswordField: React.NamedExoticComponent<PasswordFieldProps>;
34
+ export default PasswordField;
35
+ //# sourceMappingURL=PasswordField.d.ts.map
@@ -0,0 +1,20 @@
1
+ import { default as React } from 'react';
2
+ import { ISheet } from '@sheetxl/sdk';
3
+ export interface ProtectedCellsPanelProps extends React.HTMLAttributes<HTMLDivElement> {
4
+ /** The sheet whose selected cells are edited. */
5
+ sheet: ISheet;
6
+ }
7
+ /**
8
+ * The **Cells** tab of Manage Protection: the protection format of the selected cells.
9
+ *
10
+ * @remarks
11
+ * Two checkboxes over `ICellStyle.getProtection()` — **Always unlocked** and **Show formulas** — that act
12
+ * on the selection the way a format control does: a mixed selection reads indeterminate, and a click
13
+ * writes every selected cell. Like everything in the pane, a control commits when it is used.
14
+ *
15
+ * Disabled while the sheet is locked, as Excel greys out its Protection tab: which cells are unlocked
16
+ * is exactly what protection keeps from changing. A pause lifts that like any other protection.
17
+ */
18
+ export declare const ProtectedCellsPanel: React.NamedExoticComponent<ProtectedCellsPanelProps & React.RefAttributes<HTMLDivElement>>;
19
+ export default ProtectedCellsPanel;
20
+ //# sourceMappingURL=ProtectedCellsPanel.d.ts.map