@a3s-lab/office 0.19.0 → 0.21.0
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/README.md +14 -5
- package/dist/0~3635.js +23 -2
- package/dist/0~spreadsheet-editor.js +395 -90
- package/dist/0~work-office-diagnostics.js +1 -1
- package/dist/4104.js +714 -282
- package/dist/{6164.js → 5045.js} +109 -56
- package/dist/core.js +1 -1
- package/dist/index.js +1 -1
- package/dist/internal/features/work/editors/office-color-picker.d.ts +6 -1
- package/dist/internal/features/work/editors/spreadsheet-cell-border.d.ts +8 -2
- package/dist/internal/features/work/editors/spreadsheet-command-catalog.d.ts +21 -12
- package/dist/internal/features/work/work-spreadsheet-diagonal-border-canvas.d.ts +12 -0
- package/dist/internal/features/work/work-spreadsheet-diagonal-borders.d.ts +13 -0
- package/dist/internal/features/work/work-xlsx-cell-style-origin.d.ts +44 -0
- package/dist/internal/features/work/work-xlsx-cell-style-values.d.ts +26 -0
- package/dist/internal/features/work/work-xlsx-cell-style-writer.d.ts +4 -1
- package/dist/internal/features/work/work-xlsx-cell-styles.d.ts +2 -0
- package/dist/office-kernel.wasm +0 -0
- package/dist/styles.css +73 -4
- package/package.json +7 -1
package/README.md
CHANGED
|
@@ -563,13 +563,18 @@ interaction model.
|
|
|
563
563
|
per-cell mixed-size stepping, native rectangle compaction, a 10,000-cell
|
|
564
564
|
bound, and one-step Undo, a WPS-style Underline split control with single,
|
|
565
565
|
double, single-accounting, and double-accounting styles, exact Format Cells
|
|
566
|
-
and XLSX round trips,
|
|
566
|
+
and XLSX round trips, active-style-aware `Cmd/Ctrl+U` toggling, and WPS
|
|
567
|
+
`Ctrl+2`, `Ctrl+3`, and `Ctrl+4` aliases for Bold, Italic, and Underline;
|
|
568
|
+
Automatic Color and No Fill remove direct text and background colors instead
|
|
569
|
+
of hard-coding replacements, a
|
|
567
570
|
keyboard-accessible WPS Text Orientation menu with horizontal, both 45-degree
|
|
568
571
|
angles, stacked vertical, rotate-up, and rotate-down choices, exact Fortune
|
|
569
572
|
`rt` / `tr='3'` and OOXML 0–180 / 255 round trips, a 10,000-cell guard, and
|
|
570
573
|
one-batch Undo, plus a cell-border split control with side, all,
|
|
571
|
-
outside, inside, horizontal, vertical, clear,
|
|
572
|
-
|
|
574
|
+
outside, inside, horizontal, vertical, clear, independent diagonal-down and
|
|
575
|
+
diagonal-up targets, crossed-border composition, ten native line styles,
|
|
576
|
+
exact color selection, compact overlapping range writes, exact OOXML
|
|
577
|
+
direction preservation through Paste Special, Yjs, XLSX export, and reopen,
|
|
573
578
|
`Cmd/Ctrl+Shift+&` Outside Borders and `Cmd/Ctrl+Shift+_` Clear Borders,
|
|
574
579
|
single-update undo, and grid-focus restoration, Conditional Formatting under
|
|
575
580
|
Home and Styles, executable
|
|
@@ -613,8 +618,10 @@ interaction model.
|
|
|
613
618
|
keyboard navigation, a 10,000-cell bound, blank-cell styling, per-cell border
|
|
614
619
|
semantics, current-style recognition without private markers, one-step
|
|
615
620
|
history, and direct XLSX font, fill, alignment, wrap, rotation, border, and
|
|
616
|
-
number-format XF round trips
|
|
617
|
-
|
|
621
|
+
number-format XF round trips; imported theme, indexed, automatic, and tint
|
|
622
|
+
identities for direct font, solid-fill, and border colors survive unrelated
|
|
623
|
+
edits and Yjs transport when the rendered RGB and palette slot still agree,
|
|
624
|
+
while changed or conflicting colors safely export as explicit RGB,
|
|
618
625
|
a View and Window Freeze Panes menu for current-cell, top-row, first-column,
|
|
619
626
|
and unfreeze patterns with XLSX round trips, and visible F9 workbook
|
|
620
627
|
recalculation,
|
|
@@ -1528,6 +1535,8 @@ without hard-coded return URLs.
|
|
|
1528
1535
|
|
|
1529
1536
|
- [Live Playground](https://a3s-lab.github.io/Office/)
|
|
1530
1537
|
- [Documentation center](https://a3s-lab.github.io/Office/docs/)
|
|
1538
|
+
- [A3S Office 0.21.0 documentation](https://a3s-lab.github.io/Office/docs/0.21.0/)
|
|
1539
|
+
- [A3S Office 0.20.0 documentation](https://a3s-lab.github.io/Office/docs/0.20.0/)
|
|
1531
1540
|
- [A3S Office 0.19.0 documentation](https://a3s-lab.github.io/Office/docs/0.19.0/)
|
|
1532
1541
|
- [A3S Office 0.18.0 documentation](https://a3s-lab.github.io/Office/docs/0.18.0/)
|
|
1533
1542
|
- [A3S Office 0.17.0 documentation](https://a3s-lab.github.io/Office/docs/0.17.0/)
|
package/dist/0~3635.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { Check, ChevronDown } from "lucide-react";
|
|
2
|
+
import { Ban, Check, ChevronDown } from "lucide-react";
|
|
3
3
|
import { useEffect, useRef, useState } from "react";
|
|
4
4
|
import { button_Button, Popover } from "./0~6090.js";
|
|
5
5
|
const THEME_COLORS = [
|
|
@@ -72,7 +72,7 @@ const OFFICE_COLORS = [
|
|
|
72
72
|
];
|
|
73
73
|
const COLOR_GRID_COLUMNS = 10;
|
|
74
74
|
const COLOR_GRID_COLUMNS_PROPERTY = '--work-office-color-grid-columns';
|
|
75
|
-
function OfficeColorPicker({ ariaLabel, value, onValueChange, disabled = false, compact = false, className = '', triggerLabel, triggerIcon }) {
|
|
75
|
+
function OfficeColorPicker({ ariaLabel, value, onValueChange, disabled = false, compact = false, className = '', resetAction, triggerLabel, triggerIcon }) {
|
|
76
76
|
const [draft, setDraft] = useState(value);
|
|
77
77
|
const [open, setOpen] = useState(false);
|
|
78
78
|
const [activeIndex, setActiveIndex] = useState(()=>Math.max(0, OFFICE_COLORS.indexOf(value.toLowerCase())));
|
|
@@ -186,6 +186,27 @@ function OfficeColorPicker({ ariaLabel, value, onValueChange, disabled = false,
|
|
|
186
186
|
}),
|
|
187
187
|
children: (close)=>/*#__PURE__*/ jsxs(Fragment, {
|
|
188
188
|
children: [
|
|
189
|
+
resetAction ? /*#__PURE__*/ jsxs("button", {
|
|
190
|
+
type: "button",
|
|
191
|
+
className: "work-office-color-reset",
|
|
192
|
+
"data-kind": resetAction.kind,
|
|
193
|
+
onClick: ()=>{
|
|
194
|
+
close();
|
|
195
|
+
resetAction.onSelect();
|
|
196
|
+
},
|
|
197
|
+
children: [
|
|
198
|
+
/*#__PURE__*/ jsx("span", {
|
|
199
|
+
className: "work-office-color-reset-swatch",
|
|
200
|
+
"aria-hidden": "true",
|
|
201
|
+
children: 'none' === resetAction.kind ? /*#__PURE__*/ jsx(Ban, {
|
|
202
|
+
size: 13
|
|
203
|
+
}) : null
|
|
204
|
+
}),
|
|
205
|
+
/*#__PURE__*/ jsx("span", {
|
|
206
|
+
children: resetAction.label
|
|
207
|
+
})
|
|
208
|
+
]
|
|
209
|
+
}) : null,
|
|
189
210
|
/*#__PURE__*/ jsxs("div", {
|
|
190
211
|
className: "work-office-color-palette",
|
|
191
212
|
role: "listbox",
|