@trebco/treb 23.6.5 → 25.0.0-rc1
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.
- package/.eslintignore +8 -0
- package/.eslintrc.js +164 -0
- package/README-shadow-DOM.md +88 -0
- package/README.md +37 -130
- package/api-config.json +29 -0
- package/api-generator/api-generator-types.ts +82 -0
- package/api-generator/api-generator.ts +1172 -0
- package/api-generator/package.json +3 -0
- package/build/treb-spreadsheet.mjs +14 -0
- package/{treb.d.ts → build/treb.d.ts} +285 -269
- package/esbuild-custom-element.mjs +336 -0
- package/esbuild.js +305 -0
- package/package.json +43 -14
- package/treb-base-types/package.json +5 -0
- package/treb-base-types/src/api_types.ts +36 -0
- package/treb-base-types/src/area.ts +583 -0
- package/treb-base-types/src/basic_types.ts +45 -0
- package/treb-base-types/src/cell.ts +612 -0
- package/treb-base-types/src/cells.ts +1066 -0
- package/treb-base-types/src/color.ts +124 -0
- package/treb-base-types/src/import.ts +71 -0
- package/treb-base-types/src/index-standalone.ts +29 -0
- package/treb-base-types/src/index.ts +42 -0
- package/treb-base-types/src/layout.ts +47 -0
- package/treb-base-types/src/localization.ts +187 -0
- package/treb-base-types/src/rectangle.ts +145 -0
- package/treb-base-types/src/render_text.ts +72 -0
- package/treb-base-types/src/style.ts +545 -0
- package/treb-base-types/src/table.ts +109 -0
- package/treb-base-types/src/text_part.ts +54 -0
- package/treb-base-types/src/theme.ts +608 -0
- package/treb-base-types/src/union.ts +152 -0
- package/treb-base-types/src/value-type.ts +164 -0
- package/treb-base-types/style/resizable.css +59 -0
- package/treb-calculator/modern.tsconfig.json +11 -0
- package/treb-calculator/package.json +5 -0
- package/treb-calculator/src/calculator.ts +2546 -0
- package/treb-calculator/src/complex-math.ts +558 -0
- package/treb-calculator/src/dag/array-vertex.ts +198 -0
- package/treb-calculator/src/dag/graph.ts +951 -0
- package/treb-calculator/src/dag/leaf_vertex.ts +118 -0
- package/treb-calculator/src/dag/spreadsheet_vertex.ts +327 -0
- package/treb-calculator/src/dag/spreadsheet_vertex_base.ts +44 -0
- package/treb-calculator/src/dag/vertex.ts +352 -0
- package/treb-calculator/src/descriptors.ts +162 -0
- package/treb-calculator/src/expression-calculator.ts +1069 -0
- package/treb-calculator/src/function-error.ts +103 -0
- package/treb-calculator/src/function-library.ts +103 -0
- package/treb-calculator/src/functions/base-functions.ts +1214 -0
- package/treb-calculator/src/functions/checkbox.ts +164 -0
- package/treb-calculator/src/functions/complex-functions.ts +253 -0
- package/treb-calculator/src/functions/finance-functions.ts +399 -0
- package/treb-calculator/src/functions/information-functions.ts +102 -0
- package/treb-calculator/src/functions/matrix-functions.ts +182 -0
- package/treb-calculator/src/functions/sparkline.ts +335 -0
- package/treb-calculator/src/functions/statistics-functions.ts +350 -0
- package/treb-calculator/src/functions/text-functions.ts +298 -0
- package/treb-calculator/src/index.ts +27 -0
- package/treb-calculator/src/notifier-types.ts +59 -0
- package/treb-calculator/src/primitives.ts +428 -0
- package/treb-calculator/src/utilities.ts +305 -0
- package/treb-charts/package.json +5 -0
- package/treb-charts/src/chart-functions.ts +156 -0
- package/treb-charts/src/chart-types.ts +230 -0
- package/treb-charts/src/chart.ts +1288 -0
- package/treb-charts/src/index.ts +24 -0
- package/treb-charts/src/main.ts +37 -0
- package/treb-charts/src/rectangle.ts +52 -0
- package/treb-charts/src/renderer.ts +1841 -0
- package/treb-charts/src/util.ts +122 -0
- package/treb-charts/style/charts.scss +221 -0
- package/treb-charts/style/old-charts.scss +250 -0
- package/treb-embed/markup/layout.html +137 -0
- package/treb-embed/markup/toolbar.html +175 -0
- package/treb-embed/modern.tsconfig.json +25 -0
- package/treb-embed/src/custom-element/content-types.d.ts +18 -0
- package/treb-embed/src/custom-element/global.d.ts +11 -0
- package/treb-embed/src/custom-element/spreadsheet-constructor.ts +1227 -0
- package/treb-embed/src/custom-element/treb-global.ts +44 -0
- package/treb-embed/src/custom-element/treb-spreadsheet-element.ts +52 -0
- package/treb-embed/src/embedded-spreadsheet.ts +5362 -0
- package/treb-embed/src/index.ts +16 -0
- package/treb-embed/src/language-model.ts +41 -0
- package/treb-embed/src/options.ts +320 -0
- package/treb-embed/src/progress-dialog.ts +228 -0
- package/treb-embed/src/selection-state.ts +16 -0
- package/treb-embed/src/spinner.ts +42 -0
- package/treb-embed/src/toolbar-message.ts +96 -0
- package/treb-embed/src/types.ts +167 -0
- package/treb-embed/style/autocomplete.scss +103 -0
- package/treb-embed/style/dark-theme.scss +114 -0
- package/treb-embed/style/defaults.scss +36 -0
- package/treb-embed/style/dialog.scss +181 -0
- package/treb-embed/style/dropdown-select.scss +101 -0
- package/treb-embed/style/formula-bar.scss +193 -0
- package/treb-embed/style/grid.scss +374 -0
- package/treb-embed/style/layout.scss +424 -0
- package/treb-embed/style/mouse-mask.scss +67 -0
- package/treb-embed/style/note.scss +92 -0
- package/treb-embed/style/overlay-editor.scss +102 -0
- package/treb-embed/style/spinner.scss +92 -0
- package/treb-embed/style/tab-bar.scss +228 -0
- package/treb-embed/style/table.scss +80 -0
- package/treb-embed/style/theme-defaults.scss +444 -0
- package/treb-embed/style/toolbar.scss +416 -0
- package/treb-embed/style/tooltip.scss +68 -0
- package/treb-embed/style/treb-icons.scss +130 -0
- package/treb-embed/style/treb-spreadsheet-element.scss +20 -0
- package/treb-embed/style/z-index.scss +43 -0
- package/treb-export/docs/charts.md +68 -0
- package/treb-export/modern.tsconfig.json +19 -0
- package/treb-export/package.json +4 -0
- package/treb-export/src/address-type.ts +77 -0
- package/treb-export/src/base-template.ts +22 -0
- package/treb-export/src/column-width.ts +85 -0
- package/treb-export/src/drawing2/chart-template-components2.ts +389 -0
- package/treb-export/src/drawing2/chart2.ts +282 -0
- package/treb-export/src/drawing2/column-chart-template2.ts +521 -0
- package/treb-export/src/drawing2/donut-chart-template2.ts +296 -0
- package/treb-export/src/drawing2/drawing2.ts +355 -0
- package/treb-export/src/drawing2/embedded-image.ts +71 -0
- package/treb-export/src/drawing2/scatter-chart-template2.ts +555 -0
- package/treb-export/src/export-worker/export-worker.ts +99 -0
- package/treb-export/src/export-worker/index-modern.ts +22 -0
- package/treb-export/src/export2.ts +2204 -0
- package/treb-export/src/import2.ts +882 -0
- package/treb-export/src/relationship.ts +36 -0
- package/treb-export/src/shared-strings2.ts +128 -0
- package/treb-export/src/template-2.ts +22 -0
- package/treb-export/src/unescape_xml.ts +47 -0
- package/treb-export/src/workbook-sheet2.ts +182 -0
- package/treb-export/src/workbook-style2.ts +1285 -0
- package/treb-export/src/workbook-theme2.ts +88 -0
- package/treb-export/src/workbook2.ts +491 -0
- package/treb-export/src/xml-utils.ts +201 -0
- package/treb-export/template/base/[Content_Types].xml +2 -0
- package/treb-export/template/base/_rels/.rels +2 -0
- package/treb-export/template/base/docProps/app.xml +2 -0
- package/treb-export/template/base/docProps/core.xml +12 -0
- package/treb-export/template/base/xl/_rels/workbook.xml.rels +2 -0
- package/treb-export/template/base/xl/sharedStrings.xml +2 -0
- package/treb-export/template/base/xl/styles.xml +2 -0
- package/treb-export/template/base/xl/theme/theme1.xml +2 -0
- package/treb-export/template/base/xl/workbook.xml +2 -0
- package/treb-export/template/base/xl/worksheets/sheet1.xml +2 -0
- package/treb-export/template/base.xlsx +0 -0
- package/treb-format/package.json +8 -0
- package/treb-format/src/format.test.ts +213 -0
- package/treb-format/src/format.ts +942 -0
- package/treb-format/src/format_cache.ts +199 -0
- package/treb-format/src/format_parser.ts +723 -0
- package/treb-format/src/index.ts +25 -0
- package/treb-format/src/number_format_section.ts +100 -0
- package/treb-format/src/value_parser.ts +337 -0
- package/treb-grid/package.json +5 -0
- package/treb-grid/src/editors/autocomplete.ts +394 -0
- package/treb-grid/src/editors/autocomplete_matcher.ts +260 -0
- package/treb-grid/src/editors/formula_bar.ts +473 -0
- package/treb-grid/src/editors/formula_editor_base.ts +910 -0
- package/treb-grid/src/editors/overlay_editor.ts +511 -0
- package/treb-grid/src/index.ts +37 -0
- package/treb-grid/src/layout/base_layout.ts +2618 -0
- package/treb-grid/src/layout/grid_layout.ts +299 -0
- package/treb-grid/src/layout/rectangle_cache.ts +86 -0
- package/treb-grid/src/render/selection-renderer.ts +414 -0
- package/treb-grid/src/render/svg_header_overlay.ts +93 -0
- package/treb-grid/src/render/svg_selection_block.ts +187 -0
- package/treb-grid/src/render/tile_renderer.ts +2122 -0
- package/treb-grid/src/types/annotation.ts +216 -0
- package/treb-grid/src/types/border_constants.ts +34 -0
- package/treb-grid/src/types/clipboard_data.ts +31 -0
- package/treb-grid/src/types/data_model.ts +334 -0
- package/treb-grid/src/types/drag_mask.ts +81 -0
- package/treb-grid/src/types/grid.ts +7743 -0
- package/treb-grid/src/types/grid_base.ts +3644 -0
- package/treb-grid/src/types/grid_command.ts +470 -0
- package/treb-grid/src/types/grid_events.ts +124 -0
- package/treb-grid/src/types/grid_options.ts +97 -0
- package/treb-grid/src/types/grid_selection.ts +60 -0
- package/treb-grid/src/types/named_range.ts +369 -0
- package/treb-grid/src/types/scale-control.ts +202 -0
- package/treb-grid/src/types/serialize_options.ts +72 -0
- package/treb-grid/src/types/set_range_options.ts +52 -0
- package/treb-grid/src/types/sheet.ts +3099 -0
- package/treb-grid/src/types/sheet_types.ts +95 -0
- package/treb-grid/src/types/tab_bar.ts +464 -0
- package/treb-grid/src/types/tile.ts +59 -0
- package/treb-grid/src/types/update_flags.ts +75 -0
- package/treb-grid/src/util/dom_utilities.ts +44 -0
- package/treb-grid/src/util/fontmetrics2.ts +179 -0
- package/treb-grid/src/util/ua.ts +104 -0
- package/treb-logo.svg +18 -0
- package/treb-parser/package.json +5 -0
- package/treb-parser/src/csv-parser.ts +122 -0
- package/treb-parser/src/index.ts +25 -0
- package/treb-parser/src/md-parser.ts +526 -0
- package/treb-parser/src/parser-types.ts +397 -0
- package/treb-parser/src/parser.test.ts +298 -0
- package/treb-parser/src/parser.ts +2673 -0
- package/treb-utils/package.json +5 -0
- package/treb-utils/src/dispatch.ts +57 -0
- package/treb-utils/src/event_source.ts +147 -0
- package/treb-utils/src/ievent_source.ts +33 -0
- package/treb-utils/src/index.ts +31 -0
- package/treb-utils/src/measurement.ts +174 -0
- package/treb-utils/src/resizable.ts +160 -0
- package/treb-utils/src/scale.ts +137 -0
- package/treb-utils/src/serialize_html.ts +124 -0
- package/treb-utils/src/template.ts +70 -0
- package/treb-utils/src/validate_uri.ts +61 -0
- package/tsconfig.json +10 -0
- package/tsproject.json +30 -0
- package/util/license-plugin-esbuild.js +86 -0
- package/util/list-css-vars.sh +46 -0
- package/README-esm.md +0 -37
- package/treb-bundle.css +0 -2
- package/treb-bundle.mjs +0 -15
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
|
|
2
|
+
<div class="treb-layout">
|
|
3
|
+
|
|
4
|
+
<div class="treb-layout-header treb-animate">
|
|
5
|
+
<div class="treb-toolbar">
|
|
6
|
+
|
|
7
|
+
<!-- toolbar layout is in a separate file -->
|
|
8
|
+
|
|
9
|
+
<!--
|
|
10
|
+
|
|
11
|
+
should we have an include syntax?
|
|
12
|
+
...
|
|
13
|
+
actually I'd rather not, atm we use pure html and not
|
|
14
|
+
templates. if you want to use templates we should use
|
|
15
|
+
something that already exists, rather than reinventing
|
|
16
|
+
that particular wheel.
|
|
17
|
+
|
|
18
|
+
-->
|
|
19
|
+
|
|
20
|
+
</div>
|
|
21
|
+
</div>
|
|
22
|
+
|
|
23
|
+
<!--
|
|
24
|
+
dialog plus a mask... do we need the mask? it's used to
|
|
25
|
+
center the dialog. we can use the grid to put the mask
|
|
26
|
+
in the right place.
|
|
27
|
+
-->
|
|
28
|
+
|
|
29
|
+
<div class='treb-dialog-mask'>
|
|
30
|
+
<div data-bind='dialog' class='treb-embed-dialog'>
|
|
31
|
+
<div data-bind='left'>
|
|
32
|
+
<a href='https://treb.app' target='_blank'>
|
|
33
|
+
<div class='treb-icon-64'></div>
|
|
34
|
+
</a>
|
|
35
|
+
</div>
|
|
36
|
+
<div data-bind='middle'>
|
|
37
|
+
<div data-bind='title' class='treb-embed-dialog-title'></div>
|
|
38
|
+
<div data-bind='message' class='treb-embed-dialog-message'></div>
|
|
39
|
+
<div data-bind='about' class='treb-embed-dialog-body'></div>
|
|
40
|
+
</div>
|
|
41
|
+
<button type='button' title='Close dialog' data-bind='close' class='treb-close-box'>
|
|
42
|
+
<svg viewBox='0 0 16 16'>
|
|
43
|
+
<path d='M11.854 4.146a.5.5 0 0 1 0 .708l-7 7a.5.5 0 0 1-.708-.708l7-7a.5.5 0 0 1 .708 0z'/>
|
|
44
|
+
<path d='M4.146 4.146a.5.5 0 0 0 0 .708l7 7a.5.5 0 0 0 .708-.708l-7-7a.5.5 0 0 0-.708 0z'/>
|
|
45
|
+
</svg>
|
|
46
|
+
</button>
|
|
47
|
+
</div>
|
|
48
|
+
</div>
|
|
49
|
+
|
|
50
|
+
<div class="treb-layout-spreadsheet treb-views">
|
|
51
|
+
|
|
52
|
+
<!-- I rather like <template/>. perhaps we could make more use of them. -->
|
|
53
|
+
|
|
54
|
+
<!--
|
|
55
|
+
how about we move the view template (or raw html) into the spreadsheet class?
|
|
56
|
+
as it stands now, if we have two spreadsheets on a page we'll have two templates
|
|
57
|
+
as well. seems unecessary.
|
|
58
|
+
-->
|
|
59
|
+
|
|
60
|
+
<template class="treb-view-template">
|
|
61
|
+
<div class="treb-view">
|
|
62
|
+
|
|
63
|
+
<div class="treb-formula-bar notranslate" hidden>
|
|
64
|
+
<div class="treb-address-label"><div></div></div>
|
|
65
|
+
<div class="treb-editor-container">
|
|
66
|
+
<div contenteditable="true"></div>
|
|
67
|
+
</div>
|
|
68
|
+
</div>
|
|
69
|
+
|
|
70
|
+
<!-- shouldn't grid be on the next one? which has a tabindex? -->
|
|
71
|
+
<div class="treb-spreadsheet-body" role="grid">
|
|
72
|
+
<div class="treb-grid" tabindex="-1">
|
|
73
|
+
|
|
74
|
+
<!--
|
|
75
|
+
this used to be dynamically created, but optionally; what
|
|
76
|
+
happens now if we _don't_ want the overlay editor? we should
|
|
77
|
+
probably remove it, at least from flow.
|
|
78
|
+
-->
|
|
79
|
+
|
|
80
|
+
<div class="treb-overlay-container notranslate" translate="no">
|
|
81
|
+
<div class="treb-overlay-inset">
|
|
82
|
+
<div class="treb-overlay-editor" contenteditable tabindex="-1" spellcheck="true" role="gridcell"></div>
|
|
83
|
+
</div>
|
|
84
|
+
</div>
|
|
85
|
+
|
|
86
|
+
</div>
|
|
87
|
+
</div>
|
|
88
|
+
|
|
89
|
+
<div class="treb-spreadsheet-footer" hidden>
|
|
90
|
+
|
|
91
|
+
<!--
|
|
92
|
+
add/remove tab should both be buttons, or at least have tabindexes
|
|
93
|
+
-->
|
|
94
|
+
|
|
95
|
+
<!-- why is this a div (...and see below) -->
|
|
96
|
+
<div class="treb-delete-tab" title="Delete current sheet" data-command="delete-tab" data-conditional="delete-tab">
|
|
97
|
+
<svg viewbox='0 0 16 16'><path d='M4,4 L12,12 M12,4 L4,12'/></svg>
|
|
98
|
+
</div>
|
|
99
|
+
|
|
100
|
+
<!-- list of tabs for sheets -->
|
|
101
|
+
<ol class="treb-spreadsheet-tabs" role="tablist"></ol>
|
|
102
|
+
|
|
103
|
+
<!-- ...and why is this an anchor? -->
|
|
104
|
+
<a class="treb-add-tab" data-command="add-tab" data-conditional="add-tab" title="Add sheet">+</a>
|
|
105
|
+
|
|
106
|
+
<!--
|
|
107
|
+
we removed the junk node with "flex grow" to split the layout, in
|
|
108
|
+
favor of giving stats panel `margin-left:auto` which consumes all
|
|
109
|
+
available space. but that means you cannot remove this node from
|
|
110
|
+
layout, or it will get out of alignment. if this is empty it should
|
|
111
|
+
take up no space, so it should be harmless.
|
|
112
|
+
-->
|
|
113
|
+
|
|
114
|
+
<div class="treb-stats-panel"></div>
|
|
115
|
+
|
|
116
|
+
<div class="treb-scale-control" data-conditional="scale-control"></div>
|
|
117
|
+
|
|
118
|
+
</div>
|
|
119
|
+
|
|
120
|
+
<div class="treb-layout-resize-handle" data-conditional="resize"></div>
|
|
121
|
+
|
|
122
|
+
</div> <!-- /treb-view -->
|
|
123
|
+
</template>
|
|
124
|
+
|
|
125
|
+
</div>
|
|
126
|
+
|
|
127
|
+
<div class="treb-layout-sidebar treb-animate">
|
|
128
|
+
<button data-command="recalculate" title="Recalculate"></button>
|
|
129
|
+
<button data-command="toggle-toolbar" data-conditional="toolbar" title="Toggle toolbar"></button>
|
|
130
|
+
<button data-command="export-xlsx" data-conditional="export" title="Export as XLSX"></button>
|
|
131
|
+
<button data-command="revert" data-conditional="revert" title="Revert to original version"></button>
|
|
132
|
+
<button data-command="about" title="What's this?"></button>
|
|
133
|
+
</div>
|
|
134
|
+
|
|
135
|
+
<button class="treb-toggle-sidebar-button" title="Toggle sidebar"></button>
|
|
136
|
+
|
|
137
|
+
</div>
|
|
@@ -0,0 +1,175 @@
|
|
|
1
|
+
|
|
2
|
+
<div class="treb-menu" title="File menu" file-menu>
|
|
3
|
+
<div>
|
|
4
|
+
<button data-command="reset">New document</button>
|
|
5
|
+
<div separator></div>
|
|
6
|
+
<button data-command="import-file">Open file...</button>
|
|
7
|
+
<button data-command="save-json">Save JSON</button>
|
|
8
|
+
<div separator></div>
|
|
9
|
+
<button data-command="export-xlsx">Export XLSX</button>
|
|
10
|
+
</div>
|
|
11
|
+
<button data-icon="file-menu"></button>
|
|
12
|
+
</div>
|
|
13
|
+
|
|
14
|
+
<div composite narrow>
|
|
15
|
+
<button data-command="justify-left" data-target="justify" title="Left-align text"></button>
|
|
16
|
+
<div class="treb-menu">
|
|
17
|
+
<div class="treb-icon-buttons" data-replace="justify">
|
|
18
|
+
<button data-command="justify-left" title="Left-align text"></button>
|
|
19
|
+
<button data-command="justify-center" title="Center-align text"></button>
|
|
20
|
+
<button data-command="justify-right" title="Right-align text"></button>
|
|
21
|
+
</div>
|
|
22
|
+
<button dropdown></button>
|
|
23
|
+
</div>
|
|
24
|
+
</div>
|
|
25
|
+
|
|
26
|
+
<div composite narrow>
|
|
27
|
+
<button data-command="align-top" data-target="align" title="Align to top"></button>
|
|
28
|
+
<div class="treb-menu">
|
|
29
|
+
<div class="treb-icon-buttons" data-replace="align">
|
|
30
|
+
<button data-command="align-top" title="Align to top"></button>
|
|
31
|
+
<button data-command="align-middle" title="Align to middle"></button>
|
|
32
|
+
<button data-command="align-bottom" title="Align to bottom"></button>
|
|
33
|
+
</div>
|
|
34
|
+
<button dropdown></button>
|
|
35
|
+
</div>
|
|
36
|
+
</div>
|
|
37
|
+
|
|
38
|
+
<div class="group" wide>
|
|
39
|
+
<button data-command="justify-left" title="Left-align text"></button>
|
|
40
|
+
<button data-command="justify-center" title="Center-align text"></button>
|
|
41
|
+
<button data-command="justify-right" title="Right-align text"></button>
|
|
42
|
+
</div>
|
|
43
|
+
|
|
44
|
+
<div class="group" wide>
|
|
45
|
+
<button data-command="align-top" title="Align to top"></button>
|
|
46
|
+
<button data-command="align-middle" title="Align to middle"></button>
|
|
47
|
+
<button data-command="align-bottom" title="Align to bottom"></button>
|
|
48
|
+
</div>
|
|
49
|
+
|
|
50
|
+
<div class="group">
|
|
51
|
+
<button data-command="wrap-text" title="Wrap text"></button>
|
|
52
|
+
<button data-command="merge-cells" data-id="merge" data-title="Merge cells" data-active-title="Unmerge cells"></button>
|
|
53
|
+
<button data-command="lock-cells" data-title="Lock cells" data-active-title="Unlock cells"></button>
|
|
54
|
+
<button data-command="freeze-panes" data-title="Freeze panes" data-active-title="Unfreeze panes" freeze-button></button>
|
|
55
|
+
<button data-command="insert-table" data-icon="table" data-title="Insert table" data-active-title="Remove table" table-button></button>
|
|
56
|
+
<div class="treb-menu">
|
|
57
|
+
<div class="treb-comment-box">
|
|
58
|
+
<textarea></textarea>
|
|
59
|
+
<div>
|
|
60
|
+
<button data-command="clear-comment">Clear</button>
|
|
61
|
+
<button data-command="update-comment">Save</button>
|
|
62
|
+
</div>
|
|
63
|
+
</div>
|
|
64
|
+
<button data-icon="comment" data-title="Comment" data-active-title="Update comment"></button>
|
|
65
|
+
</div>
|
|
66
|
+
</div>
|
|
67
|
+
|
|
68
|
+
<div composite>
|
|
69
|
+
<button data-command="fill-color" data-color-bar="fill" data-color="{}" title="Fill color"></button>
|
|
70
|
+
<div class="treb-menu treb-color-menu" data-color-command="fill-color" data-replace-color="fill" data-default-color-text="No fill">
|
|
71
|
+
<div class="treb-color-chooser">
|
|
72
|
+
<div class="treb-caption">Theme colors</div>
|
|
73
|
+
<div class="treb-swatches"></div>
|
|
74
|
+
<div class="treb-caption">Other colors</div>
|
|
75
|
+
<div class="treb-swatches"></div>
|
|
76
|
+
<div>
|
|
77
|
+
<input placeholder="New color" class="treb-color-input">
|
|
78
|
+
<button data-command="set-color" data-color="">
|
|
79
|
+
<!-- source: bootstrap-icons-1.8.3/check2.svg -->
|
|
80
|
+
<svg xmlns='http://www.w3.org/2000/svg' width='24' height='24' fill='currentColor' viewBox='0 0 16 16'>
|
|
81
|
+
<path d='M13.854 3.646a.5.5 0 0 1 0 .708l-7 7a.5.5 0 0 1-.708 0l-3.5-3.5a.5.5 0 1 1 .708-.708L6.5 10.293l6.646-6.647a.5.5 0 0 1 .708 0z'/>
|
|
82
|
+
</svg>
|
|
83
|
+
</button>
|
|
84
|
+
</div>
|
|
85
|
+
</div>
|
|
86
|
+
<button dropdown></button>
|
|
87
|
+
</div>
|
|
88
|
+
</div>
|
|
89
|
+
|
|
90
|
+
<div composite>
|
|
91
|
+
<button data-command="text-color" data-color-bar="text" data-color="{}" title="Text color"></button>
|
|
92
|
+
<div class="treb-menu treb-color-menu" data-color-command="text-color" data-replace-color="text" data-default-color-text="Default text color">
|
|
93
|
+
<button dropdown></button>
|
|
94
|
+
</div>
|
|
95
|
+
</div>
|
|
96
|
+
|
|
97
|
+
<div composite>
|
|
98
|
+
<button data-command="border-bottom" data-target="border" title="Bottom border"></button>
|
|
99
|
+
<div class="treb-menu">
|
|
100
|
+
<div class="treb-icon-buttons" data-replace="border">
|
|
101
|
+
<button data-command="border-top" title="Top border"></button>
|
|
102
|
+
<button data-command="border-left" title="Left border"></button>
|
|
103
|
+
<button data-command="border-right" title="Right border"></button>
|
|
104
|
+
<button data-command="border-bottom" title="Bottom border"></button>
|
|
105
|
+
<button data-command="border-double-bottom" title="Double bottom border"></button>
|
|
106
|
+
<button data-command="border-outside" title="Outside borders"></button>
|
|
107
|
+
<button data-command="border-all" title="All borders"></button>
|
|
108
|
+
<button data-command="border-none" title="Clear borders"></button>
|
|
109
|
+
<div separator></div>
|
|
110
|
+
<div class="treb-menu treb-color-menu treb-submenu" data-color-command="border-color" data-replace-color="border" title="Border color" data-default-color-text="Default border color">
|
|
111
|
+
<button data-icon="palette" data-color-bar="border" data-color="{}"></button>
|
|
112
|
+
</div>
|
|
113
|
+
</div>
|
|
114
|
+
<button dropdown></button>
|
|
115
|
+
</div>
|
|
116
|
+
</div>
|
|
117
|
+
|
|
118
|
+
<div composite font-scale>
|
|
119
|
+
<input class="treb-font-scale" title="Font scale">
|
|
120
|
+
<div class="treb-menu">
|
|
121
|
+
<div>
|
|
122
|
+
<button data-command="font-scale" data-scale="0.8">0.80</button>
|
|
123
|
+
<button data-command="font-scale" data-scale="0.9">0.90</button>
|
|
124
|
+
<button data-command="font-scale" data-scale="1.0">1.00</button>
|
|
125
|
+
<button data-command="font-scale" data-scale="1.1">1.10</button>
|
|
126
|
+
<button data-command="font-scale" data-scale="1.2">1.20</button>
|
|
127
|
+
<button data-command="font-scale" data-scale="1.5">1.50</button>
|
|
128
|
+
<button data-command="font-scale" data-scale="2.0">2.00</button>
|
|
129
|
+
</div>
|
|
130
|
+
<button dropdown></button>
|
|
131
|
+
</div>
|
|
132
|
+
</div>
|
|
133
|
+
|
|
134
|
+
<div class="treb-menu">
|
|
135
|
+
<div>
|
|
136
|
+
<button data-command="insert-row">Insert row</button>
|
|
137
|
+
<button data-command="insert-column">Insert column</button>
|
|
138
|
+
<button data-command="delete-row">Delete row</button>
|
|
139
|
+
<button data-command="delete-column">Delete column</button>
|
|
140
|
+
<div separator add-remove-sheet></div>
|
|
141
|
+
<button data-command="insert-sheet" add-remove-sheet>Add sheet</button>
|
|
142
|
+
<button data-command="delete-sheet" add-remove-sheet>Delete sheet</button>
|
|
143
|
+
</div>
|
|
144
|
+
<button data-icon="layout" title="Rows & columns"></button>
|
|
145
|
+
</div>
|
|
146
|
+
|
|
147
|
+
<div composite>
|
|
148
|
+
<input class="treb-number-format" title="Number format">
|
|
149
|
+
<div class="treb-menu">
|
|
150
|
+
<div class="treb-number-format-menu"></div>
|
|
151
|
+
<button dropdown></button>
|
|
152
|
+
</div>
|
|
153
|
+
</div>
|
|
154
|
+
|
|
155
|
+
<div class="treb-split">
|
|
156
|
+
<button data-command="decrease-precision" title="Decrease precision"></button>
|
|
157
|
+
<button data-command="increase-precision" title="Increase precision"></button>
|
|
158
|
+
</div>
|
|
159
|
+
|
|
160
|
+
<div composite chart-menu>
|
|
161
|
+
<button data-command="insert-column-chart" data-target="annotation" title="Insert column chart"></button>
|
|
162
|
+
<div class="treb-menu">
|
|
163
|
+
<div class="treb-icon-buttons" data-replace="annotation">
|
|
164
|
+
<button data-command="insert-column-chart" title="Insert column chart"></button>
|
|
165
|
+
<button data-command="insert-donut-chart" title="Insert donut chart"></button>
|
|
166
|
+
<button data-command="insert-bar-chart" title="Insert bar chart"></button>
|
|
167
|
+
<button data-command="insert-line-chart" title="Insert line chart"></button>
|
|
168
|
+
<div separator></div>
|
|
169
|
+
<button data-command="insert-image" title="Insert image"></button>
|
|
170
|
+
</div>
|
|
171
|
+
<button dropdown></button>
|
|
172
|
+
</div>
|
|
173
|
+
</div>
|
|
174
|
+
|
|
175
|
+
<button data-command="recalculate" title="Recalculate" recalculate-button></button>
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
{
|
|
2
|
+
"extends": "../tsproject.json",
|
|
3
|
+
"include": [
|
|
4
|
+
"../package.json",
|
|
5
|
+
"src/**/*.ts",
|
|
6
|
+
"../treb-utils/**/*.ts",
|
|
7
|
+
"../treb-grid/**/*.ts",
|
|
8
|
+
"../treb-charts/**/*.ts",
|
|
9
|
+
"../treb-format/**/*.ts",
|
|
10
|
+
"../treb-parser/**/*.ts",
|
|
11
|
+
"../treb-calculator/**/*.ts",
|
|
12
|
+
"../treb-base-types/**/*.ts"
|
|
13
|
+
],
|
|
14
|
+
"exclude": [
|
|
15
|
+
"src/custom-element/global.d.ts",
|
|
16
|
+
|
|
17
|
+
"src/API/api-v1.ts",
|
|
18
|
+
"src/API/api-utils.ts",
|
|
19
|
+
"src/index-modern-mc.ts",
|
|
20
|
+
"src/index-module-mc.ts",
|
|
21
|
+
"../treb-parser/test/**/*.ts",
|
|
22
|
+
"../**/*.test.ts"
|
|
23
|
+
]
|
|
24
|
+
}
|
|
25
|
+
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
|
|
2
|
+
/** imported html as text */
|
|
3
|
+
declare module '*.html' {
|
|
4
|
+
const text: string;
|
|
5
|
+
export default text;
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
/** imported css as text */
|
|
9
|
+
declare module '*.scss' {
|
|
10
|
+
const text: string;
|
|
11
|
+
export default text;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
/** workers imported as text */
|
|
15
|
+
declare module 'worker:*' {
|
|
16
|
+
const text: string;
|
|
17
|
+
export default text;
|
|
18
|
+
}
|