@trebco/treb 32.14.0 → 36.1.2

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 (266) hide show
  1. package/api-generator/api-generator-types.ts +3 -0
  2. package/api-generator/api-generator.ts +15 -1
  3. package/bun.lock +145 -99
  4. package/dist/chunk-43DLP2OX.mjs +11 -0
  5. package/dist/chunk-4CKS56PE.mjs +11 -0
  6. package/dist/chunk-75PARUQE.mjs +11 -0
  7. package/dist/chunk-7QD63AZS.mjs +24601 -0
  8. package/dist/chunk-A55ARVRD.mjs +11 -0
  9. package/dist/chunk-DESAKYW4.mjs +11 -0
  10. package/dist/chunk-EQ2R5W6P.mjs +24565 -0
  11. package/dist/chunk-IYJU2J6D.mjs +24601 -0
  12. package/dist/chunk-KSJFPGXT.mjs +11 -0
  13. package/dist/chunk-ORQFKLXM.mjs +24601 -0
  14. package/dist/chunk-SFDNNDHY.mjs +11 -0
  15. package/dist/chunk-T47DX5MI.mjs +11 -0
  16. package/dist/chunk-T6ILBVEX.mjs +11 -0
  17. package/dist/chunk-TPRCDYYG.mjs +11 -0
  18. package/dist/chunk-YAHNOOHO.mjs +11 -0
  19. package/dist/treb-export-worker.mjs +9 -2
  20. package/dist/treb-spreadsheet.mjs +7 -19
  21. package/dist/treb.d.ts +20 -4
  22. package/esbuild-composite.mjs +18 -6
  23. package/esbuild-utils.mjs +62 -3
  24. package/i18n/languages/treb-i18n-da.mjs +1 -1
  25. package/i18n/languages/treb-i18n-de.mjs +1 -1
  26. package/i18n/languages/treb-i18n-es.mjs +1 -1
  27. package/i18n/languages/treb-i18n-fr.mjs +1 -1
  28. package/i18n/languages/treb-i18n-it.mjs +1 -1
  29. package/i18n/languages/treb-i18n-nl.mjs +1 -1
  30. package/i18n/languages/treb-i18n-no.mjs +1 -1
  31. package/i18n/languages/treb-i18n-pl.mjs +1 -1
  32. package/i18n/languages/treb-i18n-pt.mjs +1 -1
  33. package/i18n/languages/treb-i18n-sv.mjs +1 -1
  34. package/ooxml-types/README.md +141 -0
  35. package/ooxml-types/package.json +5 -0
  36. package/ooxml-types/src/types/drawingml/chart.ts +327 -0
  37. package/ooxml-types/src/types/drawingml/index.ts +63 -0
  38. package/ooxml-types/src/types/drawingml/spreadsheetDrawing.ts +105 -0
  39. package/ooxml-types/src/types/drawingml/theme.ts +104 -0
  40. package/ooxml-types/src/types/index.ts +3 -0
  41. package/ooxml-types/src/types/package/contentTypes.ts +49 -0
  42. package/ooxml-types/src/types/package/docProps.ts +46 -0
  43. package/ooxml-types/src/types/package/index.ts +17 -0
  44. package/ooxml-types/src/types/package/relationships.ts +37 -0
  45. package/ooxml-types/src/types/spreadsheetml/columns.ts +20 -0
  46. package/ooxml-types/src/types/spreadsheetml/comments.ts +30 -0
  47. package/ooxml-types/src/types/spreadsheetml/dataFeatures.ts +261 -0
  48. package/ooxml-types/src/types/spreadsheetml/enums.ts +175 -0
  49. package/ooxml-types/src/types/spreadsheetml/index.ts +186 -0
  50. package/ooxml-types/src/types/spreadsheetml/metadata.ts +90 -0
  51. package/ooxml-types/src/types/spreadsheetml/misc.ts +35 -0
  52. package/ooxml-types/src/types/spreadsheetml/pageLayout.ts +83 -0
  53. package/ooxml-types/src/types/spreadsheetml/sharedStrings.ts +33 -0
  54. package/ooxml-types/src/types/spreadsheetml/sheetData.ts +70 -0
  55. package/ooxml-types/src/types/spreadsheetml/sheetProperties.ts +86 -0
  56. package/ooxml-types/src/types/spreadsheetml/sheetViews.ts +51 -0
  57. package/ooxml-types/src/types/spreadsheetml/sparkline.ts +46 -0
  58. package/ooxml-types/src/types/spreadsheetml/styles.ts +274 -0
  59. package/ooxml-types/src/types/spreadsheetml/table.ts +106 -0
  60. package/ooxml-types/src/types/spreadsheetml/util.ts +15 -0
  61. package/ooxml-types/src/types/spreadsheetml/workbook.ts +165 -0
  62. package/ooxml-types/src/types/spreadsheetml/worksheet.ts +60 -0
  63. package/package.json +13 -11
  64. package/treb-base-types/src/api_types.ts +1 -1
  65. package/treb-base-types/src/area-utils.ts +1 -1
  66. package/treb-base-types/src/area.ts +1 -1
  67. package/treb-base-types/src/basic_types.ts +1 -1
  68. package/treb-base-types/src/cell.ts +1 -1
  69. package/treb-base-types/src/cells.ts +1 -1
  70. package/treb-base-types/src/color.ts +1 -1
  71. package/treb-base-types/src/dom-utilities.ts +1 -1
  72. package/treb-base-types/src/evaluate-options.ts +1 -1
  73. package/treb-base-types/src/font-stack.ts +1 -1
  74. package/treb-base-types/src/gradient.ts +1 -1
  75. package/treb-base-types/src/import.ts +1 -1
  76. package/treb-base-types/src/index-standalone.ts +1 -1
  77. package/treb-base-types/src/index.ts +2 -1
  78. package/treb-base-types/src/layout.ts +1 -1
  79. package/treb-base-types/src/localization.ts +1 -1
  80. package/treb-base-types/src/rectangle.ts +1 -1
  81. package/treb-base-types/src/render_text.ts +7 -1
  82. package/treb-base-types/src/style.ts +1 -1
  83. package/treb-base-types/src/table.ts +1 -1
  84. package/treb-base-types/src/text_part.ts +1 -1
  85. package/treb-base-types/src/theme.ts +1 -1
  86. package/treb-base-types/src/union.ts +4 -1
  87. package/treb-base-types/src/value-type.ts +1 -1
  88. package/treb-base-types/src/worker-proxy.ts +294 -0
  89. package/treb-base-types/style/resizable.css +1 -1
  90. package/treb-calculator/src/calculator.ts +133 -14
  91. package/treb-calculator/src/complex-math.ts +1 -1
  92. package/treb-calculator/src/dag/array-vertex.ts +1 -1
  93. package/treb-calculator/src/dag/calculation_leaf_vertex.ts +1 -1
  94. package/treb-calculator/src/dag/graph.ts +1 -1
  95. package/treb-calculator/src/dag/spreadsheet_vertex.ts +1 -1
  96. package/treb-calculator/src/dag/spreadsheet_vertex_base.ts +1 -1
  97. package/treb-calculator/src/dag/state_leaf_vertex.ts +1 -1
  98. package/treb-calculator/src/dag/vertex.ts +1 -1
  99. package/treb-calculator/src/descriptors.ts +9 -1
  100. package/treb-calculator/src/expression-calculator.ts +1 -1
  101. package/treb-calculator/src/function-error.ts +1 -1
  102. package/treb-calculator/src/function-library.ts +1 -1
  103. package/treb-calculator/src/functions/base-functions.ts +8 -4
  104. package/treb-calculator/src/functions/beta.ts +1 -1
  105. package/treb-calculator/src/functions/checkbox.ts +1 -1
  106. package/treb-calculator/src/functions/complex-functions.ts +1 -1
  107. package/treb-calculator/src/functions/date-utils.ts +1 -1
  108. package/treb-calculator/src/functions/finance-functions.ts +2 -4
  109. package/treb-calculator/src/functions/fp.ts +1 -1
  110. package/treb-calculator/src/functions/function-utilities.ts +1 -1
  111. package/treb-calculator/src/functions/gamma.ts +1 -1
  112. package/treb-calculator/src/functions/information-functions.ts +1 -1
  113. package/treb-calculator/src/functions/lambda-functions.ts +4 -1
  114. package/treb-calculator/src/functions/matrix-functions.ts +1 -1
  115. package/treb-calculator/src/functions/normal.ts +1 -1
  116. package/treb-calculator/src/functions/regex-functions.ts +13 -4
  117. package/treb-calculator/src/functions/sparkline.ts +1 -1
  118. package/treb-calculator/src/functions/statistics-functions.ts +1 -1
  119. package/treb-calculator/src/functions/students-t.ts +1 -1
  120. package/treb-calculator/src/functions/text-functions.ts +5 -1
  121. package/treb-calculator/src/index.ts +1 -1
  122. package/treb-calculator/src/notifier-types.ts +1 -1
  123. package/treb-calculator/src/primitives.ts +1 -1
  124. package/treb-calculator/src/utilities.ts +1 -1
  125. package/treb-charts/src/chart-functions.ts +1 -1
  126. package/treb-charts/src/chart-types.ts +1 -1
  127. package/treb-charts/src/chart-utils.ts +1 -1
  128. package/treb-charts/src/chart.ts +1 -1
  129. package/treb-charts/src/default-chart-renderer.ts +1 -1
  130. package/treb-charts/src/index.ts +1 -1
  131. package/treb-charts/src/main.ts +1 -1
  132. package/treb-charts/src/quicksort.ts +1 -1
  133. package/treb-charts/src/rectangle.ts +1 -1
  134. package/treb-charts/src/renderer-type.ts +1 -1
  135. package/treb-charts/src/renderer.ts +1 -1
  136. package/treb-charts/src/util.ts +1 -1
  137. package/treb-charts/style/charts.scss +1 -1
  138. package/treb-data-model/src/annotation.ts +1 -1
  139. package/treb-data-model/src/conditional_format.ts +1 -1
  140. package/treb-data-model/src/data-validation.ts +1 -1
  141. package/treb-data-model/src/data_model.ts +32 -5
  142. package/treb-data-model/src/index.ts +1 -1
  143. package/treb-data-model/src/language-model.ts +1 -1
  144. package/treb-data-model/src/named.ts +1 -1
  145. package/treb-data-model/src/serialize_options.ts +1 -1
  146. package/treb-data-model/src/sheet.ts +1 -1
  147. package/treb-data-model/src/sheet_collection.ts +1 -1
  148. package/treb-data-model/src/sheet_selection.ts +1 -1
  149. package/treb-data-model/src/sheet_types.ts +1 -1
  150. package/treb-data-model/src/types.ts +1 -1
  151. package/treb-embed/src/content-types.d.ts +1 -1
  152. package/treb-embed/src/custom-element/global.d.ts +1 -1
  153. package/treb-embed/src/custom-element/spreadsheet-constructor.ts +1 -1
  154. package/treb-embed/src/custom-element/treb-global.ts +1 -1
  155. package/treb-embed/src/custom-element/treb-spreadsheet-element.ts +1 -1
  156. package/treb-embed/src/embedded-spreadsheet.ts +342 -149
  157. package/treb-embed/src/index.ts +1 -1
  158. package/treb-embed/src/options.ts +4 -2
  159. package/treb-embed/src/plugin.ts +1 -1
  160. package/treb-embed/src/progress-dialog.ts +1 -1
  161. package/treb-embed/src/selection-state.ts +1 -1
  162. package/treb-embed/src/spinner.ts +1 -1
  163. package/treb-embed/src/toolbar-message.ts +6 -1
  164. package/treb-embed/src/types.ts +13 -1
  165. package/treb-embed/style/autocomplete.scss +1 -1
  166. package/treb-embed/style/dark-theme.scss +1 -1
  167. package/treb-embed/style/defaults.scss +1 -1
  168. package/treb-embed/style/dialog.scss +1 -1
  169. package/treb-embed/style/dropdown-select.scss +1 -1
  170. package/treb-embed/style/font-stacks.scss +1 -1
  171. package/treb-embed/style/formula-bar.scss +1 -1
  172. package/treb-embed/style/grid.scss +1 -1
  173. package/treb-embed/style/layout.scss +1 -1
  174. package/treb-embed/style/mouse-mask.scss +1 -1
  175. package/treb-embed/style/note.scss +1 -1
  176. package/treb-embed/style/overlay-editor.scss +1 -1
  177. package/treb-embed/style/spinner.scss +1 -1
  178. package/treb-embed/style/tab-bar.scss +1 -1
  179. package/treb-embed/style/table.scss +1 -1
  180. package/treb-embed/style/theme-defaults.scss +1 -1
  181. package/treb-embed/style/toolbar.scss +1 -1
  182. package/treb-embed/style/tooltip.scss +1 -1
  183. package/treb-embed/style/treb-icons.scss +1 -1
  184. package/treb-embed/style/treb-spreadsheet-element.scss +1 -1
  185. package/treb-embed/style/z-index.scss +1 -1
  186. package/treb-export/src/address-type.ts +1 -1
  187. package/treb-export/src/base-template.ts +1 -1
  188. package/treb-export/src/column-width.ts +1 -1
  189. package/treb-export/src/drawing/bubble-chart-template.ts +1 -1
  190. package/treb-export/src/drawing/chart-template-components2.ts +1 -1
  191. package/treb-export/src/drawing/chart.ts +1 -1
  192. package/treb-export/src/drawing/column-chart-template2.ts +1 -1
  193. package/treb-export/src/drawing/donut-chart-template2.ts +1 -1
  194. package/treb-export/src/drawing/drawing.ts +1 -1
  195. package/treb-export/src/drawing/embedded-image.ts +1 -1
  196. package/treb-export/src/drawing/scatter-chart-template2.ts +1 -1
  197. package/treb-export/src/export.ts +10 -6
  198. package/treb-export/src/import-export-messages.ts +61 -0
  199. package/treb-export/src/import.ts +318 -301
  200. package/treb-export/src/index.worker.ts +85 -53
  201. package/treb-export/src/metadata.ts +71 -3
  202. package/treb-export/src/ooxml.ts +47 -0
  203. package/treb-export/src/relationship.ts +1 -1
  204. package/treb-export/src/shared-strings.ts +19 -15
  205. package/treb-export/src/template-2.ts +1 -1
  206. package/treb-export/src/unescape_xml.ts +1 -1
  207. package/treb-export/src/workbook-sheet.ts +11 -6
  208. package/treb-export/src/workbook-style.ts +137 -25
  209. package/treb-export/src/workbook-theme.ts +20 -4
  210. package/treb-export/src/workbook.ts +85 -88
  211. package/treb-export/src/xml-test.ts +1 -1
  212. package/treb-export/src/xml-utils.ts +1 -1
  213. package/treb-export/src/zip-wrapper.ts +1 -1
  214. package/treb-export/tsconfig.json +2 -1
  215. package/treb-format/src/format.test.ts +1 -1
  216. package/treb-format/src/format.ts +12 -5
  217. package/treb-format/src/format_cache.ts +3 -3
  218. package/treb-format/src/format_parser.ts +1 -1
  219. package/treb-format/src/index.ts +1 -1
  220. package/treb-format/src/number_format_section.ts +1 -1
  221. package/treb-format/src/value_parser.ts +1 -1
  222. package/treb-grid/src/editors/autocomplete.ts +1 -1
  223. package/treb-grid/src/editors/autocomplete_matcher.ts +1 -1
  224. package/treb-grid/src/editors/editor.ts +15 -6
  225. package/treb-grid/src/editors/external_editor.ts +33 -8
  226. package/treb-grid/src/editors/formula_bar.ts +12 -1
  227. package/treb-grid/src/editors/overlay_editor.ts +4 -1
  228. package/treb-grid/src/index.ts +1 -1
  229. package/treb-grid/src/layout/base_layout.ts +1 -1
  230. package/treb-grid/src/layout/grid_layout.ts +1 -1
  231. package/treb-grid/src/layout/mock-layout.ts +1 -1
  232. package/treb-grid/src/render/selection-renderer.ts +1 -1
  233. package/treb-grid/src/render/svg_header_overlay.ts +1 -1
  234. package/treb-grid/src/render/svg_selection_block.ts +1 -1
  235. package/treb-grid/src/render/tile_renderer.ts +36 -7
  236. package/treb-grid/src/types/border_constants.ts +1 -1
  237. package/treb-grid/src/types/clipboard_data.ts +1 -1
  238. package/treb-grid/src/types/clipboard_data2.ts +1 -1
  239. package/treb-grid/src/types/drag_mask.ts +1 -1
  240. package/treb-grid/src/types/external_editor_config.ts +1 -1
  241. package/treb-grid/src/types/grid.ts +181 -40
  242. package/treb-grid/src/types/grid_base.ts +7 -4
  243. package/treb-grid/src/types/grid_command.ts +7 -1
  244. package/treb-grid/src/types/grid_events.ts +2 -1
  245. package/treb-grid/src/types/grid_options.ts +1 -1
  246. package/treb-grid/src/types/scale-control.ts +1 -1
  247. package/treb-grid/src/types/set_range_options.ts +1 -1
  248. package/treb-grid/src/types/tab_bar.ts +1 -1
  249. package/treb-grid/src/types/tile.ts +1 -1
  250. package/treb-grid/src/types/update_flags.ts +1 -1
  251. package/treb-grid/src/util/fontmetrics.ts +1 -1
  252. package/treb-grid/src/util/ua.ts +1 -1
  253. package/treb-parser/src/csv-parser.ts +1 -1
  254. package/treb-parser/src/index.ts +1 -1
  255. package/treb-parser/src/md-parser.ts +1 -1
  256. package/treb-parser/src/parser-types.ts +1 -1
  257. package/treb-parser/src/parser.ts +1 -1
  258. package/treb-utils/src/event_source.ts +1 -1
  259. package/treb-utils/src/ievent_source.ts +1 -1
  260. package/treb-utils/src/index.ts +1 -1
  261. package/treb-utils/src/measurement.ts +1 -1
  262. package/treb-utils/src/scale.ts +1 -1
  263. package/treb-utils/src/serialize_html.ts +1 -1
  264. package/treb-utils/src/validate_uri.ts +1 -1
  265. package/tsproject.json +2 -3
  266. package/treb-embed/src/export-worker.ts +0 -44
@@ -0,0 +1,37 @@
1
+ import type { OneOrMany } from "../spreadsheetml/util.js";
2
+
3
+ /** Common relationship types. Not exhaustive — Type fields accept any string. */
4
+ export type WellKnownRelationshipType =
5
+ | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument"
6
+ | "http://schemas.openxmlformats.org/package/2006/relationships/metadata/core-properties"
7
+ | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/extended-properties"
8
+ | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/worksheet"
9
+ | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/sharedStrings"
10
+ | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/styles"
11
+ | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/theme"
12
+ | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/chart"
13
+ | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/drawing"
14
+ | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/table"
15
+ | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/comments"
16
+ | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/vmlDrawing"
17
+ | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/hyperlink"
18
+ | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/pivotTable"
19
+ | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/pivotCacheDefinition"
20
+ | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/externalLink"
21
+ | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/printerSettings"
22
+ | "http://schemas.microsoft.com/office/2006/relationships/vbaProject"
23
+ | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/image"
24
+ | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/customXml";
25
+
26
+ export interface Relationship {
27
+ $attributes?: {
28
+ Id: string;
29
+ Type: WellKnownRelationshipType | (string & {});
30
+ Target: string;
31
+ TargetMode?: "External" | "Internal";
32
+ };
33
+ }
34
+
35
+ export interface Relationships {
36
+ Relationship?: OneOrMany<Relationship>;
37
+ }
@@ -0,0 +1,20 @@
1
+ import type { OneOrMany, XsdBoolean } from "./util.js";
2
+
3
+ export interface Col {
4
+ $attributes?: {
5
+ min: number;
6
+ max: number;
7
+ width?: number;
8
+ style?: number;
9
+ hidden?: XsdBoolean;
10
+ bestFit?: XsdBoolean;
11
+ customWidth?: XsdBoolean;
12
+ outlineLevel?: number;
13
+ collapsed?: XsdBoolean;
14
+ phonetic?: XsdBoolean;
15
+ };
16
+ }
17
+
18
+ export interface Cols {
19
+ col: OneOrMany<Col>;
20
+ }
@@ -0,0 +1,30 @@
1
+ import type { OneOrMany, TextElement } from "./util.js";
2
+ import type { RichTextRun } from "./sheetData.js";
3
+
4
+ export interface CommentText {
5
+ t?: TextElement;
6
+ r?: OneOrMany<RichTextRun>;
7
+ }
8
+
9
+ export interface Comment {
10
+ $attributes?: {
11
+ ref: string;
12
+ authorId: number;
13
+ guid?: string;
14
+ shapeId?: number;
15
+ };
16
+ text: CommentText;
17
+ }
18
+
19
+ export interface CommentList {
20
+ comment: OneOrMany<Comment>;
21
+ }
22
+
23
+ export interface Authors {
24
+ author: OneOrMany<TextElement>;
25
+ }
26
+
27
+ export interface Comments {
28
+ authors: Authors;
29
+ commentList: CommentList;
30
+ }
@@ -0,0 +1,261 @@
1
+ import type { OneOrMany, TextElement, XsdBoolean } from "./util.js";
2
+ import type { Color } from "./sheetProperties.js";
3
+ import type { Extension, ExtensionList } from "./misc.js";
4
+ import type {
5
+ ST_CfType,
6
+ ST_ConditionalFormattingOperator,
7
+ ST_TimePeriod,
8
+ ST_DataValidationType,
9
+ ST_DataValidationErrorStyle,
10
+ ST_DataValidationOperator,
11
+ } from "./enums.js";
12
+
13
+ // --- Merge Cells ---
14
+
15
+ export interface MergeCell {
16
+ $attributes?: {
17
+ ref: string;
18
+ };
19
+ }
20
+
21
+ export interface MergeCells {
22
+ $attributes?: {
23
+ count?: number;
24
+ };
25
+ mergeCell: OneOrMany<MergeCell>;
26
+ }
27
+
28
+ // --- Conditional Formatting ---
29
+
30
+ export interface ConditionalFormattingValueObject {
31
+ $attributes?: {
32
+ type: "num" | "percent" | "max" | "min" | "formula" | "percentile";
33
+ val?: string;
34
+ gte?: XsdBoolean;
35
+ };
36
+ }
37
+
38
+ export interface ColorScale {
39
+ cfvo: OneOrMany<ConditionalFormattingValueObject>;
40
+ color: OneOrMany<Color>;
41
+ }
42
+
43
+ export interface DataBar {
44
+ $attributes?: {
45
+ minLength?: number;
46
+ maxLength?: number;
47
+ showValue?: XsdBoolean;
48
+ };
49
+ cfvo: OneOrMany<ConditionalFormattingValueObject>;
50
+ color: Color;
51
+ }
52
+
53
+ export interface IconSet {
54
+ $attributes?: {
55
+ iconSet?: string;
56
+ showValue?: XsdBoolean;
57
+ percent?: XsdBoolean;
58
+ reverse?: XsdBoolean;
59
+ };
60
+ cfvo: OneOrMany<ConditionalFormattingValueObject>;
61
+ }
62
+
63
+ export interface CfRule {
64
+ $attributes?: {
65
+ type: ST_CfType;
66
+ priority: number;
67
+ dxfId?: number;
68
+ stopIfTrue?: XsdBoolean;
69
+ aboveAverage?: XsdBoolean;
70
+ percent?: XsdBoolean;
71
+ bottom?: XsdBoolean;
72
+ operator?: ST_ConditionalFormattingOperator;
73
+ text?: string;
74
+ timePeriod?: ST_TimePeriod;
75
+ rank?: number;
76
+ stdDev?: number;
77
+ equalAverage?: XsdBoolean;
78
+ };
79
+ formula?: OneOrMany<TextElement>;
80
+ colorScale?: ColorScale;
81
+ dataBar?: DataBar;
82
+ iconSet?: IconSet;
83
+ extLst?: ExtensionList<CfRuleExtension>;
84
+ }
85
+
86
+ /** Extension linking a standard cfRule to its x14 counterpart by GUID. */
87
+ export interface CfRuleExtension extends Extension {
88
+ id?: TextElement;
89
+ }
90
+
91
+ export interface ConditionalFormatting {
92
+ $attributes?: {
93
+ sqref: string;
94
+ pivot?: XsdBoolean;
95
+ };
96
+ cfRule: OneOrMany<CfRule>;
97
+ }
98
+
99
+ // --- Data Validations ---
100
+
101
+ export interface DataValidation {
102
+ $attributes?: {
103
+ type?: ST_DataValidationType;
104
+ errorStyle?: ST_DataValidationErrorStyle;
105
+ operator?: ST_DataValidationOperator;
106
+ allowBlank?: XsdBoolean;
107
+ showDropDown?: XsdBoolean;
108
+ showInputMessage?: XsdBoolean;
109
+ showErrorMessage?: XsdBoolean;
110
+ errorTitle?: string;
111
+ error?: string;
112
+ promptTitle?: string;
113
+ prompt?: string;
114
+ sqref: string;
115
+ imeMode?: string;
116
+ };
117
+ formula1?: TextElement;
118
+ formula2?: TextElement;
119
+ }
120
+
121
+ export interface DataValidations {
122
+ $attributes?: {
123
+ disablePrompts?: XsdBoolean;
124
+ xWindow?: number;
125
+ yWindow?: number;
126
+ count?: number;
127
+ };
128
+ dataValidation: OneOrMany<DataValidation>;
129
+ }
130
+
131
+ // --- Auto Filter ---
132
+
133
+ export interface FilterColumn {
134
+ $attributes?: {
135
+ colId: number;
136
+ hiddenButton?: XsdBoolean;
137
+ showButton?: XsdBoolean;
138
+ };
139
+ filters?: Record<string, unknown>;
140
+ customFilters?: Record<string, unknown>;
141
+ top10?: Record<string, unknown>;
142
+ dynamicFilter?: Record<string, unknown>;
143
+ colorFilter?: Record<string, unknown>;
144
+ iconFilter?: Record<string, unknown>;
145
+ }
146
+
147
+ export interface AutoFilter {
148
+ $attributes?: {
149
+ ref: string;
150
+ };
151
+ filterColumn?: OneOrMany<FilterColumn>;
152
+ sortState?: SortState;
153
+ }
154
+
155
+ // --- Sort State ---
156
+
157
+ export interface SortCondition {
158
+ $attributes?: {
159
+ descending?: XsdBoolean;
160
+ sortBy?: string;
161
+ ref: string;
162
+ customList?: string;
163
+ dxfId?: number;
164
+ iconSet?: string;
165
+ iconId?: number;
166
+ };
167
+ }
168
+
169
+ export interface SortState {
170
+ $attributes?: {
171
+ columnSort?: XsdBoolean;
172
+ caseSensitive?: XsdBoolean;
173
+ sortMethod?: string;
174
+ ref: string;
175
+ };
176
+ sortCondition?: OneOrMany<SortCondition>;
177
+ }
178
+
179
+ // --- x14 Conditional Formatting (extension) ---
180
+
181
+ export interface X14ConditionalFormattingValueObject {
182
+ $attributes?: {
183
+ type: "autoMin" | "autoMax" | "min" | "max" | "percent" | "percentile" | "num" | "formula";
184
+ };
185
+ f?: TextElement;
186
+ }
187
+
188
+ export interface X14DataBar {
189
+ $attributes?: {
190
+ minLength?: number;
191
+ maxLength?: number;
192
+ border?: XsdBoolean;
193
+ gradient?: XsdBoolean;
194
+ direction?: "context" | "leftToRight" | "rightToLeft";
195
+ negativeBarColorSameAsPositive?: XsdBoolean;
196
+ negativeBarBorderColorSameAsPositive?: XsdBoolean;
197
+ axisPosition?: "automatic" | "middle" | "none";
198
+ };
199
+ cfvo?: OneOrMany<X14ConditionalFormattingValueObject>;
200
+ fillColor?: Color;
201
+ borderColor?: Color;
202
+ negativeFillColor?: Color;
203
+ negativeBorderColor?: Color;
204
+ axisColor?: Color;
205
+ }
206
+
207
+ export interface X14CfIcon {
208
+ $attributes?: {
209
+ iconSet: string;
210
+ iconId: number;
211
+ };
212
+ }
213
+
214
+ export interface X14IconSet {
215
+ $attributes?: {
216
+ iconSet?: string;
217
+ showValue?: XsdBoolean;
218
+ reverse?: XsdBoolean;
219
+ custom?: XsdBoolean;
220
+ };
221
+ cfvo?: OneOrMany<X14ConditionalFormattingValueObject>;
222
+ cfIcon?: OneOrMany<X14CfIcon>;
223
+ }
224
+
225
+ export interface X14CfRule {
226
+ $attributes?: {
227
+ type: ST_CfType | "dataBar" | "iconSet";
228
+ priority?: number;
229
+ id: string;
230
+ };
231
+ dataBar?: X14DataBar;
232
+ iconSet?: X14IconSet;
233
+ formula?: OneOrMany<TextElement>;
234
+ colorScale?: Record<string, unknown>;
235
+ }
236
+
237
+ export interface X14ConditionalFormatting {
238
+ cfRule?: OneOrMany<X14CfRule>;
239
+ /** sqref from xm namespace — cell range this formatting applies to. */
240
+ sqref?: TextElement;
241
+ }
242
+
243
+ export interface X14ConditionalFormattings {
244
+ conditionalFormatting?: OneOrMany<X14ConditionalFormatting>;
245
+ }
246
+
247
+ // --- Hyperlinks ---
248
+
249
+ export interface Hyperlink {
250
+ $attributes?: {
251
+ ref: string;
252
+ id?: string;
253
+ location?: string;
254
+ tooltip?: string;
255
+ display?: string;
256
+ };
257
+ }
258
+
259
+ export interface Hyperlinks {
260
+ hyperlink: OneOrMany<Hyperlink>;
261
+ }
@@ -0,0 +1,175 @@
1
+ /** Cell data type (§18.18.11) */
2
+ export type ST_CellType = "b" | "d" | "e" | "inlineStr" | "n" | "s" | "str";
3
+
4
+ /** Cell formula type (§18.18.6) */
5
+ export type ST_CellFormulaType = "normal" | "array" | "dataTable" | "shared";
6
+
7
+ /** Pane position (§18.18.52) */
8
+ export type ST_Pane = "bottomLeft" | "bottomRight" | "topLeft" | "topRight";
9
+
10
+ /** Pane state (§18.18.53) */
11
+ export type ST_PaneState = "frozen" | "frozenSplit" | "split";
12
+
13
+ /** Sheet view type (§18.18.69) */
14
+ export type ST_SheetViewType = "normal" | "pageBreakPreview" | "pageLayout";
15
+
16
+ /** Page orientation (§18.18.50) */
17
+ export type ST_Orientation = "default" | "portrait" | "landscape";
18
+
19
+ /** Page order (§18.18.51) */
20
+ export type ST_PageOrder = "downThenOver" | "overThenDown";
21
+
22
+ /** Cell comments print mode (§18.18.5) */
23
+ export type ST_CellComments = "none" | "asDisplayed" | "atEnd";
24
+
25
+ /** Print error display (§18.18.58) */
26
+ export type ST_PrintError = "displayed" | "blank" | "dash" | "NA";
27
+
28
+ /** Data validation type (§18.18.21) */
29
+ export type ST_DataValidationType =
30
+ | "none"
31
+ | "whole"
32
+ | "decimal"
33
+ | "list"
34
+ | "date"
35
+ | "time"
36
+ | "textLength"
37
+ | "custom";
38
+
39
+ /** Data validation error style (§18.18.18) */
40
+ export type ST_DataValidationErrorStyle = "stop" | "warning" | "information";
41
+
42
+ /** Data validation operator (§18.18.20) */
43
+ export type ST_DataValidationOperator =
44
+ | "between"
45
+ | "notBetween"
46
+ | "equal"
47
+ | "notEqual"
48
+ | "lessThan"
49
+ | "lessThanOrEqual"
50
+ | "greaterThan"
51
+ | "greaterThanOrEqual";
52
+
53
+ /** Conditional format type (§18.18.12) */
54
+ export type ST_CfType =
55
+ | "expression"
56
+ | "cellIs"
57
+ | "colorScale"
58
+ | "dataBar"
59
+ | "iconSet"
60
+ | "top10"
61
+ | "uniqueValues"
62
+ | "duplicateValues"
63
+ | "containsText"
64
+ | "notContainsText"
65
+ | "beginsWith"
66
+ | "endsWith"
67
+ | "containsBlanks"
68
+ | "notContainsBlanks"
69
+ | "containsErrors"
70
+ | "notContainsErrors"
71
+ | "timePeriod"
72
+ | "aboveAverage";
73
+
74
+ /** Conditional formatting operator (§18.18.15) */
75
+ export type ST_ConditionalFormattingOperator =
76
+ | "lessThan"
77
+ | "lessThanOrEqual"
78
+ | "equal"
79
+ | "notEqual"
80
+ | "greaterThanOrEqual"
81
+ | "greaterThan"
82
+ | "between"
83
+ | "notBetween"
84
+ | "containsText"
85
+ | "notContains"
86
+ | "beginsWith"
87
+ | "endsWith";
88
+
89
+ /** Time period for conditional formatting (§18.18.82) */
90
+ export type ST_TimePeriod =
91
+ | "today"
92
+ | "yesterday"
93
+ | "tomorrow"
94
+ | "last7Days"
95
+ | "thisMonth"
96
+ | "lastMonth"
97
+ | "nextMonth"
98
+ | "thisWeek"
99
+ | "lastWeek"
100
+ | "nextWeek";
101
+
102
+ /** Sparkline type (x14:type) */
103
+ export type ST_SparklineType = "line" | "column" | "stacked";
104
+
105
+ /** Border style (§18.18.3) */
106
+ export type ST_BorderStyle =
107
+ | "none"
108
+ | "thin"
109
+ | "medium"
110
+ | "dashed"
111
+ | "dotted"
112
+ | "thick"
113
+ | "double"
114
+ | "hair"
115
+ | "mediumDashed"
116
+ | "dashDot"
117
+ | "mediumDashDot"
118
+ | "dashDotDot"
119
+ | "mediumDashDotDot"
120
+ | "slantDashDot";
121
+
122
+ /** Horizontal alignment (§18.18.40) */
123
+ export type ST_HorizontalAlignment =
124
+ | "general"
125
+ | "left"
126
+ | "center"
127
+ | "right"
128
+ | "fill"
129
+ | "justify"
130
+ | "centerContinuous"
131
+ | "distributed";
132
+
133
+ /** Vertical alignment (§18.18.88) */
134
+ export type ST_VerticalAlignment =
135
+ | "top"
136
+ | "center"
137
+ | "bottom"
138
+ | "justify"
139
+ | "distributed";
140
+
141
+ /** Pattern type (§18.18.55) */
142
+ export type ST_PatternType =
143
+ | "none"
144
+ | "solid"
145
+ | "mediumGray"
146
+ | "darkGray"
147
+ | "lightGray"
148
+ | "darkHorizontal"
149
+ | "darkVertical"
150
+ | "darkDown"
151
+ | "darkUp"
152
+ | "darkGrid"
153
+ | "darkTrellis"
154
+ | "lightHorizontal"
155
+ | "lightVertical"
156
+ | "lightDown"
157
+ | "lightUp"
158
+ | "lightGrid"
159
+ | "lightTrellis"
160
+ | "gray125"
161
+ | "gray0625";
162
+
163
+ /** Underline values (§18.4.13) */
164
+ export type ST_UnderlineValues =
165
+ | "single"
166
+ | "double"
167
+ | "singleAccounting"
168
+ | "doubleAccounting"
169
+ | "none";
170
+
171
+ /** Font scheme (§18.18.33) */
172
+ export type ST_FontScheme = "none" | "major" | "minor";
173
+
174
+ /** Gradient fill type (§18.18.37) */
175
+ export type ST_GradientType = "linear" | "path";
@@ -0,0 +1,186 @@
1
+ export type { OneOrMany, TextElement, ValElement, XsdBoolean } from "./util.js";
2
+
3
+ export type {
4
+ ST_CellType,
5
+ ST_CellFormulaType,
6
+ ST_Pane,
7
+ ST_PaneState,
8
+ ST_SheetViewType,
9
+ ST_Orientation,
10
+ ST_PageOrder,
11
+ ST_CellComments,
12
+ ST_PrintError,
13
+ ST_DataValidationType,
14
+ ST_DataValidationErrorStyle,
15
+ ST_DataValidationOperator,
16
+ ST_CfType,
17
+ ST_ConditionalFormattingOperator,
18
+ ST_TimePeriod,
19
+ ST_SparklineType,
20
+ ST_BorderStyle,
21
+ ST_HorizontalAlignment,
22
+ ST_VerticalAlignment,
23
+ ST_PatternType,
24
+ ST_UnderlineValues,
25
+ ST_FontScheme,
26
+ ST_GradientType,
27
+ } from "./enums.js";
28
+
29
+ export type { Col, Cols } from "./columns.js";
30
+
31
+ export type {
32
+ SheetDimension,
33
+ Color,
34
+ SheetPr,
35
+ SheetFormatPr,
36
+ SheetProtection,
37
+ } from "./sheetProperties.js";
38
+
39
+ export type {
40
+ PageMargins,
41
+ PageSetup,
42
+ PrintOptions,
43
+ HeaderFooter,
44
+ Break,
45
+ PageBreak,
46
+ } from "./pageLayout.js";
47
+
48
+ export type {
49
+ Drawing,
50
+ TablePart,
51
+ TableParts,
52
+ Extension,
53
+ ExtensionList,
54
+ OleObjects,
55
+ Controls,
56
+ } from "./misc.js";
57
+
58
+ export type {
59
+ Sparkline,
60
+ SparklineGroup,
61
+ SparklineGroups,
62
+ } from "./sparkline.js";
63
+
64
+ export type {
65
+ CellFormula,
66
+ RunProperties,
67
+ RichTextRun,
68
+ InlineString,
69
+ Cell,
70
+ Row,
71
+ SheetData,
72
+ } from "./sheetData.js";
73
+
74
+ export type { Selection, Pane, SheetView, SheetViews } from "./sheetViews.js";
75
+
76
+ export type {
77
+ MergeCell,
78
+ MergeCells,
79
+ ConditionalFormattingValueObject,
80
+ ColorScale,
81
+ DataBar,
82
+ IconSet,
83
+ CfRule,
84
+ CfRuleExtension,
85
+ ConditionalFormatting,
86
+ DataValidation,
87
+ DataValidations,
88
+ FilterColumn,
89
+ AutoFilter,
90
+ SortCondition,
91
+ SortState,
92
+ X14ConditionalFormattingValueObject,
93
+ X14DataBar,
94
+ X14CfIcon,
95
+ X14IconSet,
96
+ X14CfRule,
97
+ X14ConditionalFormatting,
98
+ X14ConditionalFormattings,
99
+ Hyperlink,
100
+ Hyperlinks,
101
+ } from "./dataFeatures.js";
102
+
103
+ export type {
104
+ PhoneticRun,
105
+ PhoneticProperties,
106
+ StringItem,
107
+ SharedStringTable,
108
+ } from "./sharedStrings.js";
109
+
110
+ export type {
111
+ FileVersion,
112
+ WorkbookPr,
113
+ WorkbookProtection,
114
+ WorkbookView,
115
+ BookViews,
116
+ Sheet,
117
+ Sheets,
118
+ DefinedName,
119
+ DefinedNames,
120
+ CalcPr,
121
+ PivotCache,
122
+ PivotCaches,
123
+ ExternalReference,
124
+ ExternalReferences,
125
+ Workbook,
126
+ } from "./workbook.js";
127
+
128
+ export type {
129
+ MetadataType,
130
+ MetadataTypes,
131
+ MetadataRecord,
132
+ MetadataBlock,
133
+ MetadataBlocks,
134
+ DynamicArrayProperties,
135
+ MetadataExtension,
136
+ FutureMetadataBlock,
137
+ FutureMetadata,
138
+ Metadata,
139
+ } from "./metadata.js";
140
+
141
+ export type {
142
+ NumFmt,
143
+ NumFmts,
144
+ Font,
145
+ Fonts,
146
+ PatternFill,
147
+ GradientStop,
148
+ GradientFill,
149
+ Fill,
150
+ Fills,
151
+ BorderEdge,
152
+ Border,
153
+ Borders,
154
+ Alignment,
155
+ CellProtection,
156
+ CellFormat,
157
+ CellFormats,
158
+ CellStyle,
159
+ CellStyles,
160
+ DifferentialFormat,
161
+ DifferentialFormats,
162
+ TableStyle,
163
+ TableStyles,
164
+ RgbColor,
165
+ IndexedColors,
166
+ MruColors,
167
+ Colors,
168
+ StyleSheet,
169
+ } from "./styles.js";
170
+
171
+ export type {
172
+ CommentText,
173
+ Comment,
174
+ CommentList,
175
+ Authors,
176
+ Comments,
177
+ } from "./comments.js";
178
+
179
+ export type {
180
+ TableColumn,
181
+ TableColumns,
182
+ TableStyleInfo,
183
+ Table,
184
+ } from "./table.js";
185
+
186
+ export type { WorksheetExtension, Worksheet } from "./worksheet.js";