@univerjs-pro/collaboration 1.2.0 → 1.3.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/lib/cjs/index.js +1 -1
- package/lib/es/index.js +1 -1
- package/lib/index.js +1 -1
- package/lib/types/controllers/sheet-transform/algorithms/set-table-filter/set-table-filter.algo.d.ts +3 -0
- package/lib/types/controllers/sheet-transform/algorithms/slicer/slicer.algo.d.ts +7 -0
- package/lib/types/index.d.ts +1 -1
- package/lib/types/models/collaboration-events.d.ts +18 -3
- package/lib/umd/index.js +1 -1
- package/package.json +35 -30
package/lib/types/controllers/sheet-transform/algorithms/set-table-filter/set-table-filter.algo.d.ts
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import type { ISetSheetTableParams } from '@univerjs/sheets-table';
|
|
2
|
+
import type { IMutationTransformAlgorithm } from '../../../../services/transform/transform.service';
|
|
3
|
+
export declare const setTableFilterWithSelf: IMutationTransformAlgorithm<ISetSheetTableParams, ISetSheetTableParams>;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { IApplySlicerBatchMutationParams } from '@univerjs-pro/sheets-slicer';
|
|
2
|
+
import type { IRemoveSheetMutationParams } from '@univerjs/sheets';
|
|
3
|
+
import type { IMutationTransformAlgorithm } from '../../../../services/transform/transform.service';
|
|
4
|
+
export declare const applySlicerBatchWithSelf: IMutationTransformAlgorithm<IApplySlicerBatchMutationParams, IApplySlicerBatchMutationParams>;
|
|
5
|
+
export declare const applySlicerBatchWithRemoveSheet: IMutationTransformAlgorithm<IApplySlicerBatchMutationParams, IRemoveSheetMutationParams>;
|
|
6
|
+
export declare const removeSheetWithApplySlicerBatch: IMutationTransformAlgorithm<IRemoveSheetMutationParams, IApplySlicerBatchMutationParams>;
|
|
7
|
+
export declare const SLICER_TRANSFORM_ALGORITHMS: IMutationTransformAlgorithm[];
|
package/lib/types/index.d.ts
CHANGED
|
@@ -12,7 +12,7 @@ export { SlideTransformController } from './controllers/slide-transform/slide-tr
|
|
|
12
12
|
export { parseChangesetToProtocol, parseMutationToProtocol, parseProtocolChangeset, parseProtocolCommand, } from './models/changeset';
|
|
13
13
|
export type { IChangeset, IFetchMissingCSResult } from './models/changeset';
|
|
14
14
|
export { CollaborationEvent } from './models/collaboration-events';
|
|
15
|
-
export type { IAcknowledgedChangeset, IAcknowledgementEvent, ICollaborationEvent, ICollaborationUser, IFetchingMissEvent, IFetchOperationsEvent, INewChangesetsEvent, INewHostEvent, IOperationEvent, IPermissionUpdateEvent, IPseudoFetchMissingResultEvent, IRejectionEvent, IRequestHostEvent, IRetryEvent, IShouldCloseConnEvent, ISubmitChangesetEvent, ITerminateEvent, IUpdateCursorEvent, IUserJoinEvent, IUserLeaveEvent, } from './models/collaboration-events';
|
|
15
|
+
export type { IAcknowledgedChangeset, IAcknowledgementEvent, ICollaborationEvent, ICollaborationUser, IFetchingMissEvent, IFetchOperationsEvent, INewChangesetsEvent, INewHostEvent, IOperationEvent, IPermissionRejectionEvent, IPermissionUpdateEvent, IPseudoFetchMissingResultEvent, IRejectionEvent, IRequestHostEvent, IRetryEvent, IShouldCloseConnEvent, ISubmitChangesetEvent, ISubmitFailure, ITerminateEvent, IUpdateCursorEvent, IUserJoinEvent, IUserLeaveEvent, } from './models/collaboration-events';
|
|
16
16
|
export type { ICombRequestEvent, ICombResponseEvent, IHeartbeatRequestEvent, IHelloRequestEvent, IHelloResponseEvent, IIngestQuestEvent, IJoinRequestEvent, IJoinResponseEvent, ILeaveRequestEvent, IRecvResponseEvent, } from './models/socket-events';
|
|
17
17
|
export { UniverCollaborationPlugin } from './plugin';
|
|
18
18
|
export { CompressMutationService } from './services/compress-mutation/compress-mutation.service';
|
|
@@ -153,17 +153,32 @@ export interface IAcknowledgementEvent {
|
|
|
153
153
|
eventID: CollaborationEvent.CHANGESET_ACK;
|
|
154
154
|
data: IProtocolChangeset;
|
|
155
155
|
}
|
|
156
|
-
|
|
156
|
+
/**
|
|
157
|
+
* Why the server did not commit a submitted changeset, carried on the event next to `data`. Servers that do not send
|
|
158
|
+
* it leave both fields undefined.
|
|
159
|
+
*/
|
|
160
|
+
export interface ISubmitFailure {
|
|
161
|
+
/** The protocol `ErrorCode` of the failure. */
|
|
162
|
+
code?: number;
|
|
163
|
+
/** The reason in words. */
|
|
164
|
+
reason?: string;
|
|
165
|
+
}
|
|
166
|
+
export interface IRejectionEvent extends ISubmitFailure {
|
|
157
167
|
eventID: CollaborationEvent.CHANGESET_REJ;
|
|
158
168
|
data: {
|
|
159
169
|
unitID: string;
|
|
160
170
|
changeset: IRejectedChangeset;
|
|
161
171
|
};
|
|
162
172
|
}
|
|
163
|
-
export interface IRetryEvent {
|
|
173
|
+
export interface IRetryEvent extends ISubmitFailure {
|
|
164
174
|
eventID: CollaborationEvent.CHANGESET_SHOULD_RETRY;
|
|
165
175
|
data: IChangeset;
|
|
166
176
|
}
|
|
177
|
+
/** The server rejected the submitted changeset because the user may not edit the unit. */
|
|
178
|
+
export interface IPermissionRejectionEvent extends ISubmitFailure {
|
|
179
|
+
eventID: CollaborationEvent.PERMISSION_REJ;
|
|
180
|
+
data: IProtocolChangeset;
|
|
181
|
+
}
|
|
167
182
|
export interface ICollaborationUser {
|
|
168
183
|
userID: string;
|
|
169
184
|
memberID: string;
|
|
@@ -240,4 +255,4 @@ export interface IUniscriptRunEvent {
|
|
|
240
255
|
/**
|
|
241
256
|
* A union type of all possible collaboration events.
|
|
242
257
|
*/
|
|
243
|
-
export type ICollaborationEvent = IAcknowledgementEvent | INewChangesetsEvent | IRejectionEvent | ISubmitChangesetEvent | IPseudoFetchMissingResultEvent | IUserSelectionEvent | IFetchingMissEvent | IUpdateCursorEvent | IUserJoinEvent | IUserLeaveEvent | ICustomEvent | IRequestHostEvent | IFetchOperationsEvent | ITerminateEvent | INewHostEvent | IOperationEvent | IMsgErrEvent | ICommentUpdateEvent | IPermissionUpdateEvent | IShouldCloseConnEvent | IUniscriptRunEvent;
|
|
258
|
+
export type ICollaborationEvent = IAcknowledgementEvent | INewChangesetsEvent | IRejectionEvent | IPermissionRejectionEvent | ISubmitChangesetEvent | IPseudoFetchMissingResultEvent | IUserSelectionEvent | IFetchingMissEvent | IUpdateCursorEvent | IUserJoinEvent | IUserLeaveEvent | ICustomEvent | IRequestHostEvent | IFetchOperationsEvent | ITerminateEvent | INewHostEvent | IOperationEvent | IMsgErrEvent | ICommentUpdateEvent | IPermissionUpdateEvent | IShouldCloseConnEvent | IUniscriptRunEvent;
|