@a3s-lab/office 0.31.0 → 0.33.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 +63 -8
- package/dist/0~3539.js +2 -2
- package/dist/0~3557.js +1 -1
- package/dist/0~3635.js +1 -1
- package/dist/0~4808.js +1 -1
- package/dist/0~4980.js +1 -1
- package/dist/0~7048.js +1 -2
- package/dist/0~7240.js +1 -1
- package/dist/0~7614.js +1 -1
- package/dist/{0~6090.js → 0~8136.js} +71 -2
- package/dist/{0~4595.js → 0~9073.js} +3 -72
- package/dist/0~9445.js +1 -1
- package/dist/0~document-editor.js +1087 -6
- package/dist/0~markdown-editor.js +2 -2
- package/dist/0~pdf-page-organization-engine.js +187 -0
- package/dist/0~pdf-viewer.js +1014 -30
- package/dist/0~presentation-editor.js +2 -2
- package/dist/0~spreadsheet-editor.js +4 -3
- package/dist/0~work-docx-export.js +1 -1
- package/dist/0~work-docx-import.js +10 -27
- package/dist/0~work-docx-large-document-import.js +1 -1
- package/dist/0~work-office-diagnostics.js +3 -3
- package/dist/0~work-pptx-import.js +1 -1
- package/dist/{1544.js → 3266.js} +17 -1862
- package/dist/4121.js +13 -0
- package/dist/4166.js +3848 -0
- package/dist/{6282.js → 4174.js} +383 -10
- package/dist/9333.js +1849 -0
- package/dist/core.d.ts +1 -0
- package/dist/core.js +5259 -4
- package/dist/index.js +3 -3
- package/dist/internal/features/work/editors/document-compare-dialog.d.ts +14 -0
- package/dist/internal/features/work/editors/document-toolbar.d.ts +3 -1
- package/dist/internal/features/work/editors/pdf-editor-extensions.d.ts +11 -0
- package/dist/internal/features/work/editors/pdf-page-organization-engine.d.ts +2 -0
- package/dist/internal/features/work/editors/pdf-page-organization-plan.d.ts +10 -0
- package/dist/internal/features/work/editors/pdf-page-organization-types.d.ts +68 -0
- package/dist/internal/features/work/editors/pdf-page-organization-worker-client.d.ts +2 -0
- package/dist/internal/features/work/editors/pdf-page-organization-worker-protocol.d.ts +13 -0
- package/dist/internal/features/work/editors/pdf-page-organization.d.ts +3 -0
- package/dist/internal/features/work/editors/pdf-page-organization.worker.d.ts +1 -0
- package/dist/internal/features/work/editors/pdf-page-organizer-dialog.d.ts +17 -0
- package/dist/internal/features/work/editors/pdf-thumbnail-rail.d.ts +4 -0
- package/dist/internal/features/work/editors/pdf-toolbar.d.ts +2 -1
- package/dist/internal/features/work/editors/pdf-viewer.d.ts +3 -1
- package/dist/internal/features/work/editors/use-document-comparison.d.ts +9 -0
- package/dist/internal/features/work/editors/use-pdf-page-organization.d.ts +38 -0
- package/dist/internal/features/work/work-document-changes.d.ts +5 -0
- package/dist/internal/features/work/work-document-compare-diff.d.ts +38 -0
- package/dist/internal/features/work/work-document-compare-stability.d.ts +5 -0
- package/dist/internal/features/work/work-document-compare.d.ts +27 -0
- package/dist/office-kernel.wasm +0 -0
- package/dist/pdf-page-organization.worker.js +19667 -0
- package/dist/pdf-page-organization.worker.js.LICENSE.txt +14 -0
- package/dist/react.d.ts +1 -0
- package/dist/styles.css +509 -0
- package/dist/vue.d.ts +3 -1
- package/dist/vue.js +2 -0
- package/dist/web-component.d.ts +3 -1
- package/dist/web-component.js +9 -0
- package/docs/latest/en/browser-editor-architecture.md +52 -6
- package/package.json +10 -3
- package/dist/4104.js +0 -9336
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/*! *****************************************************************************
|
|
2
|
+
Copyright (c) Microsoft Corporation.
|
|
3
|
+
|
|
4
|
+
Permission to use, copy, modify, and/or distribute this software for any
|
|
5
|
+
purpose with or without fee is hereby granted.
|
|
6
|
+
|
|
7
|
+
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
8
|
+
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
9
|
+
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
10
|
+
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
11
|
+
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
12
|
+
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
13
|
+
PERFORMANCE OF THIS SOFTWARE.
|
|
14
|
+
***************************************************************************** */
|
package/dist/react.d.ts
CHANGED
|
@@ -3,6 +3,7 @@ import type { DocumentEditorProps as InternalDocumentEditorProps } from './inter
|
|
|
3
3
|
import type { MarkdownEditorProps as InternalMarkdownEditorProps } from './internal/features/work/editors/markdown-editor';
|
|
4
4
|
import type { PdfViewerProps as InternalPdfViewerProps } from './internal/features/work/editors/pdf-viewer';
|
|
5
5
|
export { PDF_EVIDENCE_COORDINATE_BASIS, type PdfEvidenceBounds, type PdfEvidenceOverlay, type PdfEvidencePage, type PdfEvidenceRegion, type PdfEvidenceRegionLocation, } from './internal/features/work/editors/pdf-evidence-contract';
|
|
6
|
+
export type { PdfPageOrganizationExport } from './internal/features/work/editors/use-pdf-page-organization';
|
|
6
7
|
import type { PresentationEditorProps as InternalPresentationEditorProps } from './internal/features/work/editors/presentation-editor';
|
|
7
8
|
import type { SpreadsheetEditorProps as InternalSpreadsheetEditorProps } from './internal/features/work/editors/spreadsheet-editor';
|
|
8
9
|
import type { WorkOfficeFileAction } from './internal/features/work/editors/work-office-chrome';
|
package/dist/styles.css
CHANGED
|
@@ -9930,6 +9930,200 @@ button.work-office-collaboration-participant:hover .work-office-collaboration-lo
|
|
|
9930
9930
|
}
|
|
9931
9931
|
}
|
|
9932
9932
|
|
|
9933
|
+
.work-document-compare-dialog {
|
|
9934
|
+
width: min(650px, 100%);
|
|
9935
|
+
}
|
|
9936
|
+
|
|
9937
|
+
.work-document-compare-dialog form {
|
|
9938
|
+
gap: 15px;
|
|
9939
|
+
display: grid;
|
|
9940
|
+
}
|
|
9941
|
+
|
|
9942
|
+
.work-document-compare-mode {
|
|
9943
|
+
border: 0;
|
|
9944
|
+
grid-template-columns: repeat(2, minmax(0, 1fr));
|
|
9945
|
+
gap: 10px;
|
|
9946
|
+
margin: 0;
|
|
9947
|
+
padding: 0;
|
|
9948
|
+
display: grid;
|
|
9949
|
+
}
|
|
9950
|
+
|
|
9951
|
+
.work-document-compare-mode > legend {
|
|
9952
|
+
color: var(--a3s-muted);
|
|
9953
|
+
margin-bottom: 8px;
|
|
9954
|
+
font-size: 11px;
|
|
9955
|
+
font-weight: 700;
|
|
9956
|
+
}
|
|
9957
|
+
|
|
9958
|
+
.work-document-compare-mode > label {
|
|
9959
|
+
cursor: pointer;
|
|
9960
|
+
min-width: 0;
|
|
9961
|
+
position: relative;
|
|
9962
|
+
}
|
|
9963
|
+
|
|
9964
|
+
.work-document-compare-mode input {
|
|
9965
|
+
opacity: 0;
|
|
9966
|
+
width: 1px;
|
|
9967
|
+
height: 1px;
|
|
9968
|
+
position: absolute;
|
|
9969
|
+
}
|
|
9970
|
+
|
|
9971
|
+
.work-document-compare-mode label > span {
|
|
9972
|
+
border: 1px solid var(--a3s-line);
|
|
9973
|
+
background: var(--a3s-panel);
|
|
9974
|
+
border-radius: 10px;
|
|
9975
|
+
grid-template-columns: auto minmax(0, 1fr);
|
|
9976
|
+
align-content: start;
|
|
9977
|
+
gap: 4px 9px;
|
|
9978
|
+
min-height: 94px;
|
|
9979
|
+
padding: 13px 14px;
|
|
9980
|
+
transition: border-color .14s, background-color .14s;
|
|
9981
|
+
display: grid;
|
|
9982
|
+
}
|
|
9983
|
+
|
|
9984
|
+
.work-document-compare-mode label:hover > span {
|
|
9985
|
+
border-color: var(--a3s-line-strong);
|
|
9986
|
+
background: var(--a3s-panel-soft);
|
|
9987
|
+
}
|
|
9988
|
+
|
|
9989
|
+
.work-document-compare-mode input:checked + span {
|
|
9990
|
+
border-color: var(--a3s-accent);
|
|
9991
|
+
background: color-mix(in srgb, var(--a3s-accent) 8%, var(--a3s-panel));
|
|
9992
|
+
}
|
|
9993
|
+
|
|
9994
|
+
.work-document-compare-mode input:focus-visible + span {
|
|
9995
|
+
outline: 2px solid var(--a3s-accent);
|
|
9996
|
+
outline-offset: 2px;
|
|
9997
|
+
}
|
|
9998
|
+
|
|
9999
|
+
.work-document-compare-mode svg {
|
|
10000
|
+
color: var(--a3s-accent);
|
|
10001
|
+
grid-row: 1 / span 2;
|
|
10002
|
+
}
|
|
10003
|
+
|
|
10004
|
+
.work-document-compare-mode strong {
|
|
10005
|
+
font-size: 13px;
|
|
10006
|
+
line-height: 1.2;
|
|
10007
|
+
}
|
|
10008
|
+
|
|
10009
|
+
.work-document-compare-mode small {
|
|
10010
|
+
color: var(--a3s-muted);
|
|
10011
|
+
font-size: 11px;
|
|
10012
|
+
line-height: 1.45;
|
|
10013
|
+
}
|
|
10014
|
+
|
|
10015
|
+
.work-document-compare-file {
|
|
10016
|
+
border: 1px dashed var(--a3s-line-strong);
|
|
10017
|
+
background: var(--a3s-panel-soft);
|
|
10018
|
+
width: 100%;
|
|
10019
|
+
min-height: 78px;
|
|
10020
|
+
color: var(--a3s-ink);
|
|
10021
|
+
text-align: left;
|
|
10022
|
+
cursor: pointer;
|
|
10023
|
+
border-radius: 10px;
|
|
10024
|
+
outline: 0;
|
|
10025
|
+
grid-template-columns: auto minmax(0, 1fr);
|
|
10026
|
+
align-items: center;
|
|
10027
|
+
gap: 12px;
|
|
10028
|
+
padding: 13px 15px;
|
|
10029
|
+
display: grid;
|
|
10030
|
+
}
|
|
10031
|
+
|
|
10032
|
+
.work-document-compare-file:hover:not(:disabled) {
|
|
10033
|
+
border-color: var(--a3s-accent);
|
|
10034
|
+
}
|
|
10035
|
+
|
|
10036
|
+
.work-document-compare-file:focus-visible {
|
|
10037
|
+
outline: 2px solid var(--a3s-accent);
|
|
10038
|
+
outline-offset: 2px;
|
|
10039
|
+
}
|
|
10040
|
+
|
|
10041
|
+
.work-document-compare-file:disabled {
|
|
10042
|
+
cursor: wait;
|
|
10043
|
+
opacity: .65;
|
|
10044
|
+
}
|
|
10045
|
+
|
|
10046
|
+
.work-document-compare-file > svg {
|
|
10047
|
+
color: var(--a3s-accent);
|
|
10048
|
+
}
|
|
10049
|
+
|
|
10050
|
+
.work-document-compare-file > span, .work-document-compare-author {
|
|
10051
|
+
gap: 4px;
|
|
10052
|
+
min-width: 0;
|
|
10053
|
+
display: grid;
|
|
10054
|
+
}
|
|
10055
|
+
|
|
10056
|
+
.work-document-compare-file strong {
|
|
10057
|
+
text-overflow: ellipsis;
|
|
10058
|
+
white-space: nowrap;
|
|
10059
|
+
font-size: 13px;
|
|
10060
|
+
overflow: hidden;
|
|
10061
|
+
}
|
|
10062
|
+
|
|
10063
|
+
.work-document-compare-file small, .work-document-compare-author small {
|
|
10064
|
+
color: var(--a3s-muted);
|
|
10065
|
+
font-size: 11px;
|
|
10066
|
+
line-height: 1.45;
|
|
10067
|
+
}
|
|
10068
|
+
|
|
10069
|
+
.work-document-compare-author > span {
|
|
10070
|
+
color: var(--a3s-muted);
|
|
10071
|
+
font-size: 11px;
|
|
10072
|
+
font-weight: 700;
|
|
10073
|
+
}
|
|
10074
|
+
|
|
10075
|
+
.work-document-compare-author .work-office-text-field {
|
|
10076
|
+
width: 100%;
|
|
10077
|
+
}
|
|
10078
|
+
|
|
10079
|
+
.work-document-compare-boundary, .work-document-compare-status, .work-document-compare-errors {
|
|
10080
|
+
border: 1px solid var(--a3s-line);
|
|
10081
|
+
border-radius: 9px;
|
|
10082
|
+
margin: 0;
|
|
10083
|
+
padding: 12px 14px;
|
|
10084
|
+
font-size: 11px;
|
|
10085
|
+
line-height: 1.5;
|
|
10086
|
+
}
|
|
10087
|
+
|
|
10088
|
+
.work-document-compare-boundary {
|
|
10089
|
+
background: var(--a3s-panel-soft);
|
|
10090
|
+
}
|
|
10091
|
+
|
|
10092
|
+
.work-document-compare-boundary > strong, .work-document-compare-errors > strong {
|
|
10093
|
+
font-size: 12px;
|
|
10094
|
+
}
|
|
10095
|
+
|
|
10096
|
+
.work-document-compare-boundary > p {
|
|
10097
|
+
color: var(--a3s-muted);
|
|
10098
|
+
margin: 3px 0 0;
|
|
10099
|
+
}
|
|
10100
|
+
|
|
10101
|
+
.work-document-compare-status {
|
|
10102
|
+
border-color: color-mix(in srgb, var(--a3s-green) 42%, var(--a3s-line));
|
|
10103
|
+
color: var(--a3s-green);
|
|
10104
|
+
}
|
|
10105
|
+
|
|
10106
|
+
.work-document-compare-errors {
|
|
10107
|
+
border-color: color-mix(in srgb, var(--a3s-red) 35%, var(--a3s-line));
|
|
10108
|
+
background: color-mix(in srgb, var(--a3s-red) 5%, var(--a3s-panel));
|
|
10109
|
+
color: var(--a3s-red);
|
|
10110
|
+
}
|
|
10111
|
+
|
|
10112
|
+
.work-document-compare-errors ul {
|
|
10113
|
+
margin: 5px 0 0;
|
|
10114
|
+
padding-left: 18px;
|
|
10115
|
+
}
|
|
10116
|
+
|
|
10117
|
+
@media (width <= 560px) {
|
|
10118
|
+
.work-document-compare-mode {
|
|
10119
|
+
grid-template-columns: minmax(0, 1fr);
|
|
10120
|
+
}
|
|
10121
|
+
|
|
10122
|
+
.work-document-compare-mode label > span {
|
|
10123
|
+
min-height: 0;
|
|
10124
|
+
}
|
|
10125
|
+
}
|
|
10126
|
+
|
|
9933
10127
|
[data-office-character-position-half-points] {
|
|
9934
10128
|
vertical-align: var(--work-document-character-position);
|
|
9935
10129
|
}
|
|
@@ -22506,6 +22700,321 @@ sub [data-office-character-position-half-points], sup [data-office-character-pos
|
|
|
22506
22700
|
}
|
|
22507
22701
|
}
|
|
22508
22702
|
|
|
22703
|
+
.work-pdf-page-organization {
|
|
22704
|
+
border-right: 1px solid var(--a3s-line);
|
|
22705
|
+
padding-right: 5px;
|
|
22706
|
+
}
|
|
22707
|
+
|
|
22708
|
+
.work-pdf-page-organizer-trigger.ds-button {
|
|
22709
|
+
border-color: #0000;
|
|
22710
|
+
gap: 5px;
|
|
22711
|
+
height: 28px;
|
|
22712
|
+
min-height: 28px;
|
|
22713
|
+
padding-inline: 8px;
|
|
22714
|
+
font-size: 10px;
|
|
22715
|
+
}
|
|
22716
|
+
|
|
22717
|
+
.work-pdf-page-organizer-dialog {
|
|
22718
|
+
width: min(980px, 100%);
|
|
22719
|
+
}
|
|
22720
|
+
|
|
22721
|
+
.work-pdf-page-organizer-dialog .ds-dialog-body {
|
|
22722
|
+
gap: 12px;
|
|
22723
|
+
min-height: 0;
|
|
22724
|
+
display: grid;
|
|
22725
|
+
}
|
|
22726
|
+
|
|
22727
|
+
.work-pdf-page-organizer-actions {
|
|
22728
|
+
grid-template-columns: repeat(9, minmax(72px, 1fr));
|
|
22729
|
+
gap: 5px;
|
|
22730
|
+
display: grid;
|
|
22731
|
+
}
|
|
22732
|
+
|
|
22733
|
+
.work-pdf-page-organizer-actions .ds-button {
|
|
22734
|
+
white-space: nowrap;
|
|
22735
|
+
gap: 5px;
|
|
22736
|
+
min-width: 0;
|
|
22737
|
+
min-height: 36px;
|
|
22738
|
+
padding-inline: 7px;
|
|
22739
|
+
font-size: 10px;
|
|
22740
|
+
}
|
|
22741
|
+
|
|
22742
|
+
.work-pdf-page-organizer-selection {
|
|
22743
|
+
min-height: 28px;
|
|
22744
|
+
color: var(--a3s-muted);
|
|
22745
|
+
align-items: center;
|
|
22746
|
+
gap: 8px;
|
|
22747
|
+
font-size: 11px;
|
|
22748
|
+
display: flex;
|
|
22749
|
+
}
|
|
22750
|
+
|
|
22751
|
+
.work-pdf-page-organizer-selection output {
|
|
22752
|
+
font-variant-numeric: tabular-nums;
|
|
22753
|
+
margin-right: auto;
|
|
22754
|
+
font-weight: 650;
|
|
22755
|
+
}
|
|
22756
|
+
|
|
22757
|
+
.work-pdf-page-organizer-selection button {
|
|
22758
|
+
border: 1px solid var(--a3s-line);
|
|
22759
|
+
background: var(--a3s-panel);
|
|
22760
|
+
min-height: 28px;
|
|
22761
|
+
color: var(--a3s-muted);
|
|
22762
|
+
font: inherit;
|
|
22763
|
+
cursor: pointer;
|
|
22764
|
+
border-radius: 6px;
|
|
22765
|
+
padding: 0 9px;
|
|
22766
|
+
}
|
|
22767
|
+
|
|
22768
|
+
.work-pdf-page-organizer-selection button:hover:not(:disabled), .work-pdf-page-organizer-selection button:focus-visible {
|
|
22769
|
+
border-color: var(--a3s-line-strong);
|
|
22770
|
+
background: var(--a3s-panel-soft);
|
|
22771
|
+
color: var(--a3s-ink);
|
|
22772
|
+
outline: 0;
|
|
22773
|
+
}
|
|
22774
|
+
|
|
22775
|
+
.work-pdf-page-organizer-viewport {
|
|
22776
|
+
border: 1px solid var(--a3s-line);
|
|
22777
|
+
background: linear-gradient(var(--a3s-panel-soft), var(--a3s-panel-soft)) padding-box,
|
|
22778
|
+
var(--a3s-panel-soft);
|
|
22779
|
+
overscroll-behavior: contain;
|
|
22780
|
+
scrollbar-gutter: stable;
|
|
22781
|
+
border-radius: 10px;
|
|
22782
|
+
height: min(51vh, 552px);
|
|
22783
|
+
min-height: 260px;
|
|
22784
|
+
overflow: auto;
|
|
22785
|
+
}
|
|
22786
|
+
|
|
22787
|
+
.work-pdf-page-organizer-list {
|
|
22788
|
+
gap: 12px;
|
|
22789
|
+
padding: 12px;
|
|
22790
|
+
display: grid;
|
|
22791
|
+
}
|
|
22792
|
+
|
|
22793
|
+
.work-pdf-page-organizer-list > span[aria-hidden="true"] {
|
|
22794
|
+
display: block;
|
|
22795
|
+
}
|
|
22796
|
+
|
|
22797
|
+
.work-pdf-page-organizer-list > button {
|
|
22798
|
+
border: 1px solid var(--a3s-line);
|
|
22799
|
+
background: var(--a3s-panel);
|
|
22800
|
+
width: 100%;
|
|
22801
|
+
height: 172px;
|
|
22802
|
+
color: var(--a3s-ink);
|
|
22803
|
+
text-align: left;
|
|
22804
|
+
cursor: grab;
|
|
22805
|
+
border-radius: 9px;
|
|
22806
|
+
outline: 0;
|
|
22807
|
+
grid-template-columns: 72px minmax(0, 1fr);
|
|
22808
|
+
align-items: center;
|
|
22809
|
+
gap: 14px;
|
|
22810
|
+
padding: 12px 16px;
|
|
22811
|
+
transition: border-color .12s, background-color .12s, box-shadow .12s;
|
|
22812
|
+
display: grid;
|
|
22813
|
+
}
|
|
22814
|
+
|
|
22815
|
+
.work-pdf-page-organizer-list > button:hover:not(:disabled) {
|
|
22816
|
+
border-color: var(--a3s-line-strong);
|
|
22817
|
+
background: color-mix(in srgb, var(--work-pdf-accent) 3%, var(--a3s-panel));
|
|
22818
|
+
}
|
|
22819
|
+
|
|
22820
|
+
.work-pdf-page-organizer-list > button:focus-visible {
|
|
22821
|
+
border-color: var(--work-pdf-accent);
|
|
22822
|
+
box-shadow: 0 0 0 2px
|
|
22823
|
+
color-mix(in srgb, var(--work-pdf-accent) 18%, transparent);
|
|
22824
|
+
}
|
|
22825
|
+
|
|
22826
|
+
.work-pdf-page-organizer-list > button.selected {
|
|
22827
|
+
border-color: color-mix(in srgb, var(--work-pdf-accent) 70%, var(--a3s-line));
|
|
22828
|
+
background: color-mix(in srgb, var(--work-pdf-accent) 8%, var(--a3s-panel));
|
|
22829
|
+
}
|
|
22830
|
+
|
|
22831
|
+
.work-pdf-page-organizer-list > button:active:not(:disabled) {
|
|
22832
|
+
cursor: grabbing;
|
|
22833
|
+
}
|
|
22834
|
+
|
|
22835
|
+
.work-pdf-page-organizer-number {
|
|
22836
|
+
color: var(--a3s-ink);
|
|
22837
|
+
font-variant-numeric: tabular-nums;
|
|
22838
|
+
justify-items: center;
|
|
22839
|
+
gap: 5px;
|
|
22840
|
+
font-size: 18px;
|
|
22841
|
+
font-weight: 700;
|
|
22842
|
+
display: grid;
|
|
22843
|
+
}
|
|
22844
|
+
|
|
22845
|
+
.work-pdf-page-organizer-number small {
|
|
22846
|
+
background: color-mix(in srgb, var(--work-pdf-accent) 10%, var(--a3s-panel));
|
|
22847
|
+
color: var(--work-pdf-accent);
|
|
22848
|
+
border-radius: 999px;
|
|
22849
|
+
padding: 2px 6px;
|
|
22850
|
+
font-size: 9px;
|
|
22851
|
+
font-weight: 650;
|
|
22852
|
+
}
|
|
22853
|
+
|
|
22854
|
+
.work-pdf-page-organizer-preview {
|
|
22855
|
+
border: 1px solid var(--a3s-line);
|
|
22856
|
+
background: #e7e9ee;
|
|
22857
|
+
border-radius: 4px;
|
|
22858
|
+
justify-self: center;
|
|
22859
|
+
place-items: center;
|
|
22860
|
+
width: min(100%, 560px);
|
|
22861
|
+
height: 146px;
|
|
22862
|
+
display: grid;
|
|
22863
|
+
overflow: hidden;
|
|
22864
|
+
}
|
|
22865
|
+
|
|
22866
|
+
.work-pdf-page-organizer-preview img {
|
|
22867
|
+
object-fit: contain;
|
|
22868
|
+
max-width: 100%;
|
|
22869
|
+
max-height: 100%;
|
|
22870
|
+
display: block;
|
|
22871
|
+
}
|
|
22872
|
+
|
|
22873
|
+
.work-pdf-page-organizer-preview[data-state="loading"]:after {
|
|
22874
|
+
content: "";
|
|
22875
|
+
background: linear-gradient(90deg, #ffffff47, #ffffffc2, #ffffff47);
|
|
22876
|
+
border-radius: 999px;
|
|
22877
|
+
width: 48%;
|
|
22878
|
+
height: 8px;
|
|
22879
|
+
animation: 1.1s ease-in-out infinite work-pdf-organizer-loading;
|
|
22880
|
+
}
|
|
22881
|
+
|
|
22882
|
+
.work-pdf-page-organizer-preview[data-state="error"]:after {
|
|
22883
|
+
color: #676d78;
|
|
22884
|
+
content: "无法生成缩略图";
|
|
22885
|
+
font-size: 10px;
|
|
22886
|
+
}
|
|
22887
|
+
|
|
22888
|
+
.work-pdf-page-organizer-error, .work-pdf-page-organizer-diagnostics, .work-pdf-page-organizer-boundary {
|
|
22889
|
+
border: 1px solid var(--a3s-line);
|
|
22890
|
+
border-radius: 8px;
|
|
22891
|
+
margin: 0;
|
|
22892
|
+
padding: 10px 12px;
|
|
22893
|
+
font-size: 11px;
|
|
22894
|
+
line-height: 1.5;
|
|
22895
|
+
}
|
|
22896
|
+
|
|
22897
|
+
.work-pdf-page-organizer-error {
|
|
22898
|
+
border-color: color-mix(in srgb, var(--a3s-red) 38%, var(--a3s-line));
|
|
22899
|
+
background: color-mix(in srgb, var(--a3s-red) 5%, var(--a3s-panel));
|
|
22900
|
+
color: var(--a3s-red);
|
|
22901
|
+
align-items: flex-start;
|
|
22902
|
+
gap: 12px;
|
|
22903
|
+
display: flex;
|
|
22904
|
+
}
|
|
22905
|
+
|
|
22906
|
+
.work-pdf-page-organizer-error > div {
|
|
22907
|
+
flex: 1;
|
|
22908
|
+
min-width: 0;
|
|
22909
|
+
}
|
|
22910
|
+
|
|
22911
|
+
.work-pdf-page-organizer-error p {
|
|
22912
|
+
overflow-wrap: anywhere;
|
|
22913
|
+
margin: 2px 0 4px;
|
|
22914
|
+
}
|
|
22915
|
+
|
|
22916
|
+
.work-pdf-page-organizer-error code {
|
|
22917
|
+
font-size: 9px;
|
|
22918
|
+
}
|
|
22919
|
+
|
|
22920
|
+
.work-pdf-page-organizer-error > button {
|
|
22921
|
+
color: currentColor;
|
|
22922
|
+
cursor: pointer;
|
|
22923
|
+
background: none;
|
|
22924
|
+
border: 0;
|
|
22925
|
+
border-radius: 6px;
|
|
22926
|
+
width: 30px;
|
|
22927
|
+
height: 30px;
|
|
22928
|
+
padding: 0;
|
|
22929
|
+
font-size: 18px;
|
|
22930
|
+
}
|
|
22931
|
+
|
|
22932
|
+
.work-pdf-page-organizer-diagnostics {
|
|
22933
|
+
border-color: color-mix(in srgb, #b7791f 35%, var(--a3s-line));
|
|
22934
|
+
color: #8b5e16;
|
|
22935
|
+
padding-left: 28px;
|
|
22936
|
+
}
|
|
22937
|
+
|
|
22938
|
+
.work-pdf-page-organizer-boundary {
|
|
22939
|
+
background: var(--a3s-panel-soft);
|
|
22940
|
+
color: var(--a3s-muted);
|
|
22941
|
+
}
|
|
22942
|
+
|
|
22943
|
+
@keyframes work-pdf-organizer-loading {
|
|
22944
|
+
0%, 100% {
|
|
22945
|
+
opacity: .45;
|
|
22946
|
+
transform: translateX(-12%);
|
|
22947
|
+
}
|
|
22948
|
+
|
|
22949
|
+
50% {
|
|
22950
|
+
opacity: 1;
|
|
22951
|
+
transform: translateX(12%);
|
|
22952
|
+
}
|
|
22953
|
+
}
|
|
22954
|
+
|
|
22955
|
+
@media (width <= 980px) {
|
|
22956
|
+
.work-pdf-page-organization {
|
|
22957
|
+
display: none;
|
|
22958
|
+
}
|
|
22959
|
+
|
|
22960
|
+
.work-pdf-page-organizer-actions {
|
|
22961
|
+
grid-template-columns: repeat(3, minmax(0, 1fr));
|
|
22962
|
+
}
|
|
22963
|
+
}
|
|
22964
|
+
|
|
22965
|
+
@media (width <= 560px) {
|
|
22966
|
+
.work-pdf-page-organizer-dialog .ds-dialog-body {
|
|
22967
|
+
gap: 9px;
|
|
22968
|
+
}
|
|
22969
|
+
|
|
22970
|
+
.work-pdf-page-organizer-actions {
|
|
22971
|
+
overscroll-behavior: contain;
|
|
22972
|
+
grid-template-columns: repeat(2, minmax(0, 1fr));
|
|
22973
|
+
max-height: 188px;
|
|
22974
|
+
overflow-y: auto;
|
|
22975
|
+
}
|
|
22976
|
+
|
|
22977
|
+
.work-pdf-page-organizer-actions .ds-button {
|
|
22978
|
+
min-height: 44px;
|
|
22979
|
+
}
|
|
22980
|
+
|
|
22981
|
+
.work-pdf-page-organizer-selection button {
|
|
22982
|
+
min-width: 44px;
|
|
22983
|
+
min-height: 36px;
|
|
22984
|
+
}
|
|
22985
|
+
|
|
22986
|
+
.work-pdf-page-organizer-viewport {
|
|
22987
|
+
height: min(38vh, 420px);
|
|
22988
|
+
min-height: 220px;
|
|
22989
|
+
}
|
|
22990
|
+
|
|
22991
|
+
.work-pdf-page-organizer-list {
|
|
22992
|
+
padding-inline: 8px;
|
|
22993
|
+
}
|
|
22994
|
+
|
|
22995
|
+
.work-pdf-page-organizer-list > button {
|
|
22996
|
+
grid-template-columns: 48px minmax(0, 1fr);
|
|
22997
|
+
padding-inline: 10px;
|
|
22998
|
+
}
|
|
22999
|
+
|
|
23000
|
+
.work-pdf-page-organizer-number {
|
|
23001
|
+
font-size: 15px;
|
|
23002
|
+
}
|
|
23003
|
+
}
|
|
23004
|
+
|
|
23005
|
+
@media (forced-colors: active) {
|
|
23006
|
+
.work-pdf-page-organizer-list > button.selected {
|
|
23007
|
+
outline: 2px solid highlight;
|
|
23008
|
+
}
|
|
23009
|
+
}
|
|
23010
|
+
|
|
23011
|
+
@media (prefers-reduced-motion: reduce) {
|
|
23012
|
+
.work-pdf-page-organizer-list > button, .work-pdf-page-organizer-preview[data-state="loading"]:after {
|
|
23013
|
+
transition: none;
|
|
23014
|
+
animation: none;
|
|
23015
|
+
}
|
|
23016
|
+
}
|
|
23017
|
+
|
|
22509
23018
|
.work-pdf-export-surface {
|
|
22510
23019
|
z-index: -1000;
|
|
22511
23020
|
color: #20232b;
|
package/dist/vue.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { Extensions } from '@tiptap/core';
|
|
2
2
|
import { type PropType } from 'vue';
|
|
3
|
-
import type { DocumentContent, DocumentReviewConflictEvent, EditorAgentRequest, GetDocumentSelectionMenuItems, GetMarkdownSelectionMenuItems, MarkdownContent, OfficeCollaborationPresence, OfficeCollaborationSession, PdfCollaborationContent, PresentationContent, SpreadsheetContent } from './core';
|
|
3
|
+
import type { DocumentContent, DocumentReviewConflictEvent, EditorAgentRequest, GetDocumentSelectionMenuItems, GetMarkdownSelectionMenuItems, MarkdownContent, OfficeCollaborationPresence, OfficeCollaborationSession, PdfCollaborationContent, PdfPageOrganizationExport, PresentationContent, SpreadsheetContent } from './core';
|
|
4
4
|
import type { OfficeTheme } from './office-surface';
|
|
5
5
|
import { type DocumentLayoutFont, type OfficeFileAction, type PdfEvidenceOverlay, type PdfEvidenceRegion } from './react';
|
|
6
6
|
export declare const DocumentEditor: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
@@ -274,6 +274,7 @@ export declare const PdfViewer: import("vue").DefineComponent<import("vue").Extr
|
|
|
274
274
|
type: PropType<() => Promise<Blob>>;
|
|
275
275
|
};
|
|
276
276
|
onSave: PropType<(pdf: Blob) => Promise<boolean>>;
|
|
277
|
+
onPageExport: PropType<(files: readonly PdfPageOrganizationExport[]) => boolean | Promise<boolean>>;
|
|
277
278
|
saveLabel: StringConstructor;
|
|
278
279
|
selectedEvidenceRegionId: StringConstructor;
|
|
279
280
|
sourceKey: StringConstructor;
|
|
@@ -302,6 +303,7 @@ export declare const PdfViewer: import("vue").DefineComponent<import("vue").Extr
|
|
|
302
303
|
type: PropType<() => Promise<Blob>>;
|
|
303
304
|
};
|
|
304
305
|
onSave: PropType<(pdf: Blob) => Promise<boolean>>;
|
|
306
|
+
onPageExport: PropType<(files: readonly PdfPageOrganizationExport[]) => boolean | Promise<boolean>>;
|
|
305
307
|
saveLabel: StringConstructor;
|
|
306
308
|
selectedEvidenceRegionId: StringConstructor;
|
|
307
309
|
sourceKey: StringConstructor;
|
package/dist/vue.js
CHANGED
|
@@ -232,6 +232,7 @@ const PdfViewer = defineComponent({
|
|
|
232
232
|
type: Function
|
|
233
233
|
},
|
|
234
234
|
onSave: Function,
|
|
235
|
+
onPageExport: Function,
|
|
235
236
|
saveLabel: String,
|
|
236
237
|
selectedEvidenceRegionId: String,
|
|
237
238
|
sourceKey: String,
|
|
@@ -257,6 +258,7 @@ const PdfViewer = defineComponent({
|
|
|
257
258
|
onCollaborationChange: (content)=>emit('collaborationChange', content),
|
|
258
259
|
onEvidenceRegionSelect: (region)=>emit('evidenceRegionSelect', region),
|
|
259
260
|
onPageChange: (pageNumber)=>emit('pageChange', pageNumber),
|
|
261
|
+
onPageExport: props.onPageExport,
|
|
260
262
|
onSave: props.onSave,
|
|
261
263
|
saveLabel: props.saveLabel,
|
|
262
264
|
selectedEvidenceRegionId: props.selectedEvidenceRegionId,
|
package/dist/web-component.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { Extensions } from '@tiptap/core';
|
|
2
2
|
import { type ReactNode } from 'react';
|
|
3
|
-
import type { DocumentContent, EditorAgentRequest, GetDocumentSelectionMenuItems, GetMarkdownSelectionMenuItems, MarkdownContent, OfficeCollaborationPresence, OfficeCollaborationSession, PdfCollaborationContent, PresentationContent, SpreadsheetContent } from './core';
|
|
3
|
+
import type { DocumentContent, EditorAgentRequest, GetDocumentSelectionMenuItems, GetMarkdownSelectionMenuItems, MarkdownContent, OfficeCollaborationPresence, OfficeCollaborationSession, PdfCollaborationContent, PdfPageOrganizationExport, PresentationContent, SpreadsheetContent } from './core';
|
|
4
4
|
import type { OfficeTheme } from './office-surface';
|
|
5
5
|
import { type DocumentLayoutFont, type OfficeFileAction, type PdfEvidenceOverlay } from './react';
|
|
6
6
|
declare const HTMLElementBase: {
|
|
@@ -92,6 +92,8 @@ export declare class A3SPdfViewerElement extends A3SOfficeElement {
|
|
|
92
92
|
set onCollaborationChange(value: ((content: PdfCollaborationContent) => void) | undefined);
|
|
93
93
|
get onSave(): ((pdf: Blob) => Promise<boolean>) | undefined;
|
|
94
94
|
set onSave(value: ((pdf: Blob) => Promise<boolean>) | undefined);
|
|
95
|
+
get onPageExport(): ((files: readonly PdfPageOrganizationExport[]) => boolean | Promise<boolean>) | undefined;
|
|
96
|
+
set onPageExport(value: ((files: readonly PdfPageOrganizationExport[]) => boolean | Promise<boolean>) | undefined);
|
|
95
97
|
get selectedEvidenceRegionId(): string | undefined;
|
|
96
98
|
set selectedEvidenceRegionId(value: string | undefined);
|
|
97
99
|
get theme(): OfficeTheme;
|
package/dist/web-component.js
CHANGED
|
@@ -308,6 +308,7 @@ class A3SPdfViewerElement extends A3SOfficeElement {
|
|
|
308
308
|
#loadSource;
|
|
309
309
|
#onCollaborationChange;
|
|
310
310
|
#onSave;
|
|
311
|
+
#onPageExport;
|
|
311
312
|
static get observedAttributes() {
|
|
312
313
|
return [
|
|
313
314
|
'file-name',
|
|
@@ -354,6 +355,13 @@ class A3SPdfViewerElement extends A3SOfficeElement {
|
|
|
354
355
|
this.#onSave = value;
|
|
355
356
|
this.requestRender();
|
|
356
357
|
}
|
|
358
|
+
get onPageExport() {
|
|
359
|
+
return this.#onPageExport;
|
|
360
|
+
}
|
|
361
|
+
set onPageExport(value) {
|
|
362
|
+
this.#onPageExport = value;
|
|
363
|
+
this.requestRender();
|
|
364
|
+
}
|
|
357
365
|
get selectedEvidenceRegionId() {
|
|
358
366
|
return this.getAttribute('selected-evidence-region-id') ?? void 0;
|
|
359
367
|
}
|
|
@@ -387,6 +395,7 @@ class A3SPdfViewerElement extends A3SOfficeElement {
|
|
|
387
395
|
},
|
|
388
396
|
onEvidenceRegionSelect: (region)=>dispatchDetail(this, 'evidence-select', region),
|
|
389
397
|
onPageChange: (pageNumber)=>dispatchDetail(this, 'page-change', pageNumber),
|
|
398
|
+
onPageExport: this.onPageExport,
|
|
390
399
|
onSave: this.onSave,
|
|
391
400
|
saveLabel: this.getAttribute('save-label') ?? void 0,
|
|
392
401
|
selectedEvidenceRegionId: this.selectedEvidenceRegionId,
|