@fluidframework/merge-tree 2.71.0 → 2.73.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/CHANGELOG.md +8 -26
- package/dist/client.js +3 -3
- package/dist/client.js.map +1 -1
- package/dist/mergeTreeDeltaCallback.js.map +1 -1
- package/dist/opBuilder.js +2 -2
- package/dist/opBuilder.js.map +1 -1
- package/dist/test/client.walkSegments.spec.js +15 -0
- package/dist/test/client.walkSegments.spec.js.map +1 -1
- package/lib/client.js +3 -3
- package/lib/client.js.map +1 -1
- package/lib/mergeTreeDeltaCallback.js.map +1 -1
- package/lib/opBuilder.js +2 -2
- package/lib/opBuilder.js.map +1 -1
- package/lib/test/client.walkSegments.spec.js +15 -0
- package/lib/test/client.walkSegments.spec.js.map +1 -1
- package/package.json +19 -19
- package/src/client.ts +7 -7
- package/src/mergeTreeDeltaCallback.ts +2 -2
- package/src/opBuilder.ts +4 -4
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
# @fluidframework/merge-tree
|
|
2
2
|
|
|
3
|
+
## 2.73.0
|
|
4
|
+
|
|
5
|
+
Dependency updates only.
|
|
6
|
+
|
|
7
|
+
## 2.72.0
|
|
8
|
+
|
|
9
|
+
Dependency updates only.
|
|
10
|
+
|
|
3
11
|
## 2.71.0
|
|
4
12
|
|
|
5
13
|
Dependency updates only.
|
|
@@ -103,7 +111,6 @@ Dependency updates only.
|
|
|
103
111
|
```
|
|
104
112
|
|
|
105
113
|
The following properties are removed from `ISegment` and its implementations:
|
|
106
|
-
|
|
107
114
|
- clientId
|
|
108
115
|
- index
|
|
109
116
|
- localMovedSeq
|
|
@@ -120,7 +127,6 @@ Dependency updates only.
|
|
|
120
127
|
- wasMovedOnInsert
|
|
121
128
|
|
|
122
129
|
Additionally, the following types are also removed:
|
|
123
|
-
|
|
124
130
|
- IMergeNodeCommon
|
|
125
131
|
- IMoveInfo
|
|
126
132
|
- IRemovalInfo
|
|
@@ -148,7 +154,6 @@ Dependency updates only.
|
|
|
148
154
|
```
|
|
149
155
|
|
|
150
156
|
The following properties are deprecated on ISegment and its implementations:
|
|
151
|
-
|
|
152
157
|
- clientId
|
|
153
158
|
- index
|
|
154
159
|
- localMovedSeq
|
|
@@ -165,7 +170,6 @@ Dependency updates only.
|
|
|
165
170
|
- wasMovedOnInsert
|
|
166
171
|
|
|
167
172
|
Additionally, the following types are also deprecated, and will become internal (i.e. users of the Fluid Framework will not have access to them):
|
|
168
|
-
|
|
169
173
|
- IMergeNodeCommon
|
|
170
174
|
- IMoveInfo
|
|
171
175
|
- IRemovalInfo
|
|
@@ -184,7 +188,6 @@ Dependency updates only.
|
|
|
184
188
|
As part of ongoing improvements, several internal types and related APIs have been removed. These types are unnecessary for any supported scenarios and could lead to errors if used. Since directly using these types would likely result in errors, these changes are not likely to impact any Fluid Framework consumers.
|
|
185
189
|
|
|
186
190
|
Removed types:
|
|
187
|
-
|
|
188
191
|
- IMergeTreeTextHelper
|
|
189
192
|
- MergeNode
|
|
190
193
|
- ObliterateInfo
|
|
@@ -196,12 +199,10 @@ Dependency updates only.
|
|
|
196
199
|
In addition to removing the above types, they are no longer exposed through the following interfaces and their implementations: `ISegment`, `ReferencePosition`, and `ISerializableInterval`.
|
|
197
200
|
|
|
198
201
|
Removed functions:
|
|
199
|
-
|
|
200
202
|
- addProperties
|
|
201
203
|
- ack
|
|
202
204
|
|
|
203
205
|
Removed properties:
|
|
204
|
-
|
|
205
206
|
- propertyManager
|
|
206
207
|
- segmentGroups
|
|
207
208
|
|
|
@@ -215,7 +216,6 @@ Dependency updates only.
|
|
|
215
216
|
An adjustment is a modification applied to a property value within a specified range. Adjustments can be used to increment or decrement property values dynamically. They are particularly useful in scenarios where property values need to be updated based on user interactions or other events. For example, in a rich text editor, adjustments can be used for modifying indentation levels or font sizes, where multiple users could apply differing numerical adjustments.
|
|
216
217
|
|
|
217
218
|
### Key Features and Use Cases:
|
|
218
|
-
|
|
219
219
|
- **Adjustments with Constraints**: Adjustments can include optional minimum and maximum constraints to ensure the final value falls within specified bounds. This is particularly useful for maintaining consistent formatting in rich text editors.
|
|
220
220
|
- **Consistent Property Changes**: The feature ensures that property changes are consistent, managing both local and remote changes effectively. This is essential for collaborative rich text editing where multiple users may be making adjustments simultaneously.
|
|
221
221
|
- **Rich Text Formatting**: Adjustments can be used to modify text properties such as font size, indentation, or other formatting attributes dynamically based on user actions.
|
|
@@ -237,7 +237,6 @@ Dependency updates only.
|
|
|
237
237
|
The `Client` class in the merge-tree package has been removed. Types that directly or indirectly expose the merge-tree `Client` class have also been removed.
|
|
238
238
|
|
|
239
239
|
The removed types were not meant to be used directly, and direct usage was not supported:
|
|
240
|
-
|
|
241
240
|
- AttributionPolicy
|
|
242
241
|
- IClientEvents
|
|
243
242
|
- IMergeTreeAttributionOptions
|
|
@@ -245,7 +244,6 @@ Dependency updates only.
|
|
|
245
244
|
- SharedStringClass
|
|
246
245
|
|
|
247
246
|
Some classes that referenced the `Client` class have been transitioned to interfaces. Direct instantiation of these classes was not supported or necessary for any supported scenario, so the change to an interface should not impact usage. This applies to the following types:
|
|
248
|
-
|
|
249
247
|
- SequenceInterval
|
|
250
248
|
- SequenceEvent
|
|
251
249
|
- SequenceDeltaEvent
|
|
@@ -293,7 +291,6 @@ Dependency updates only.
|
|
|
293
291
|
To reduce exposure of the `Client` class in the merge-tree package, several types have been deprecated. These types directly or indirectly expose the merge-tree `Client` class.
|
|
294
292
|
|
|
295
293
|
Most of these types are not meant to be used directly, and direct use is not supported:
|
|
296
|
-
|
|
297
294
|
- AttributionPolicy
|
|
298
295
|
- IClientEvents
|
|
299
296
|
- IMergeTreeAttributionOptions
|
|
@@ -301,7 +298,6 @@ Dependency updates only.
|
|
|
301
298
|
- SharedStringClass
|
|
302
299
|
|
|
303
300
|
Some of the deprecations are class constructors. In those cases, we plan to replace the class with an interface which has an equivalent API. Direct instantiation of these classes is not currently supported or necessary for any supported scenario, so the change to an interface should not impact usage. This applies to the following types:
|
|
304
|
-
|
|
305
301
|
- SequenceInterval
|
|
306
302
|
- SequenceEvent
|
|
307
303
|
- SequenceDeltaEvent
|
|
@@ -319,7 +315,6 @@ Dependency updates only.
|
|
|
319
315
|
|
|
320
316
|
The `PropertyManager` class, along with the `propertyManager` properties and `addProperties` functions on segments and intervals, are not intended for external use.
|
|
321
317
|
These elements will be removed in a future release for the following reasons:
|
|
322
|
-
|
|
323
318
|
- There are no scenarios where they need to be used directly.
|
|
324
319
|
- Using them directly will cause eventual consistency problems.
|
|
325
320
|
- Upcoming features will require modifications to these mechanisms.
|
|
@@ -328,7 +323,6 @@ Dependency updates only.
|
|
|
328
323
|
|
|
329
324
|
The `SegmentGroupCollection` class, along with the `segmentGroups` property and `ack` function on segments, are not intended for external use.
|
|
330
325
|
These elements will be removed in a future release for the following reasons:
|
|
331
|
-
|
|
332
326
|
- There are no scenarios where they need to be used directly.
|
|
333
327
|
- Using them directly will cause eventual consistency problems.
|
|
334
328
|
- Upcoming features will require modifications to these mechanisms.
|
|
@@ -371,7 +365,6 @@ Dependency updates only.
|
|
|
371
365
|
TypeScript types and implementation code.
|
|
372
366
|
|
|
373
367
|
This means that using Fluid Framework packages require the following TypeScript settings in tsconfig.json:
|
|
374
|
-
|
|
375
368
|
- `"moduleResolution": "Node16"` with `"module": "Node16"`
|
|
376
369
|
- `"moduleResolution": "Bundler"` with `"module": "ESNext"`
|
|
377
370
|
|
|
@@ -394,7 +387,6 @@ Dependency updates only.
|
|
|
394
387
|
- Updated server dependencies ([#19122](https://github.com/microsoft/FluidFramework/issues/19122)) [25366b4229](https://github.com/microsoft/FluidFramework/commits/25366b422918cb43685c5f328b50450749592902)
|
|
395
388
|
|
|
396
389
|
The following Fluid server dependencies have been updated to the latest version, 3.0.0. [See the full changelog.](https://github.com/microsoft/FluidFramework/releases/tag/server_v3.0.0)
|
|
397
|
-
|
|
398
390
|
- @fluidframework/gitresources
|
|
399
391
|
- @fluidframework/server-kafka-orderer
|
|
400
392
|
- @fluidframework/server-lambdas
|
|
@@ -452,7 +444,6 @@ Dependency updates only.
|
|
|
452
444
|
|
|
453
445
|
The following APIs have been removed or marked internal in merge-tree and sequence. This functionality was never
|
|
454
446
|
intended for public export.
|
|
455
|
-
|
|
456
447
|
- `BaseSegment.ack`
|
|
457
448
|
- `Client`
|
|
458
449
|
- `CollaborationWindow`
|
|
@@ -492,12 +483,10 @@ Dependency updates only.
|
|
|
492
483
|
- sequence: Remove support for combining ops [9a451d4946](https://github.com/microsoft/FluidFramework/commits/9a451d4946b5c51a52e4d1ab5bf51e7b285b0d74)
|
|
493
484
|
|
|
494
485
|
In sequence, removed the following APIs:
|
|
495
|
-
|
|
496
486
|
- the `combiningOp` argument from `SharedSegmentSequence.annotateRange` and `SharedString.annotateMarker`
|
|
497
487
|
- the function `SharedString.annotateMarkerNotifyConsensus`
|
|
498
488
|
|
|
499
489
|
In merge-tree, removed the following APIs:
|
|
500
|
-
|
|
501
490
|
- `ICombiningOp`
|
|
502
491
|
- the `combiningOp` field from `IMergeTreeAnnotateMsg`
|
|
503
492
|
- the `op` argument from `BaseSegment.addProperties`, `PropertiesManager.addProperties`, and `ReferencePosition.addProperties`
|
|
@@ -508,7 +497,6 @@ Dependency updates only.
|
|
|
508
497
|
- sequence: Removed several APIs [9a451d4946](https://github.com/microsoft/FluidFramework/commits/9a451d4946b5c51a52e4d1ab5bf51e7b285b0d74)
|
|
509
498
|
|
|
510
499
|
The following APIs have been removed:
|
|
511
|
-
|
|
512
500
|
- `Client.getStackContext`
|
|
513
501
|
- `SharedSegmentSequence.getStackContext`
|
|
514
502
|
- `IntervalType.Nest`
|
|
@@ -525,7 +513,6 @@ Dependency updates only.
|
|
|
525
513
|
- merge-tree: Remove several APIs [9a451d4946](https://github.com/microsoft/FluidFramework/commits/9a451d4946b5c51a52e4d1ab5bf51e7b285b0d74)
|
|
526
514
|
|
|
527
515
|
Removed the following APIs:
|
|
528
|
-
|
|
529
516
|
- `Stack`
|
|
530
517
|
- `clone`
|
|
531
518
|
- `combine`
|
|
@@ -567,7 +554,6 @@ Dependency updates only.
|
|
|
567
554
|
|
|
568
555
|
The following classes and functions have been deprecated. They were not intended for public export and will be removed
|
|
569
556
|
in a future release.
|
|
570
|
-
|
|
571
557
|
- Stack
|
|
572
558
|
- clone
|
|
573
559
|
- combine
|
|
@@ -580,7 +566,6 @@ Dependency updates only.
|
|
|
580
566
|
|
|
581
567
|
The following classes and functions have been deprecated. The functionality has poor test coverage and is largely
|
|
582
568
|
unused. They will be removed in a future release.
|
|
583
|
-
|
|
584
569
|
- IntervalType.Nest
|
|
585
570
|
- internedSpaces
|
|
586
571
|
- RangeStackMap
|
|
@@ -599,7 +584,6 @@ Dependency updates only.
|
|
|
599
584
|
- Dependencies on @fluidframework/protocol-definitions package updated to 3.0.0 [871b3493dd](https://github.com/microsoft/FluidFramework/commits/871b3493dd0d7ea3a89be64998ceb6cb9021a04e)
|
|
600
585
|
|
|
601
586
|
This included the following changes from the protocol-definitions release:
|
|
602
|
-
|
|
603
587
|
- Updating signal interfaces for some planned improvements. The intention is split the interface between signals
|
|
604
588
|
submitted by clients to the server and the resulting signals sent from the server to clients.
|
|
605
589
|
- A new optional type member is available on the ISignalMessage interface and a new ISentSignalMessage interface has
|
|
@@ -610,7 +594,6 @@ Dependency updates only.
|
|
|
610
594
|
- Server upgrade: dependencies on Fluid server packages updated to 2.0.1 [871b3493dd](https://github.com/microsoft/FluidFramework/commits/871b3493dd0d7ea3a89be64998ceb6cb9021a04e)
|
|
611
595
|
|
|
612
596
|
Dependencies on the following Fluid server package have been updated to version 2.0.1:
|
|
613
|
-
|
|
614
597
|
- @fluidframework/gitresources: 2.0.1
|
|
615
598
|
- @fluidframework/server-kafka-orderer: 2.0.1
|
|
616
599
|
- @fluidframework/server-lambdas: 2.0.1
|
|
@@ -661,7 +644,6 @@ Dependency updates only.
|
|
|
661
644
|
|
|
662
645
|
The **@fluidframework/common-definitions** package is being deprecated, so the following interfaces and types are now
|
|
663
646
|
imported from the **@fluidframework/core-interfaces** package:
|
|
664
|
-
|
|
665
647
|
- interface IDisposable
|
|
666
648
|
- interface IErrorEvent
|
|
667
649
|
- interface IErrorEvent
|
package/dist/client.js
CHANGED
|
@@ -181,7 +181,7 @@ class Client extends client_utils_1.TypedEventEmitter {
|
|
|
181
181
|
* (default is to be after the last included character, but number index is exclusive).
|
|
182
182
|
*/
|
|
183
183
|
obliterateRangeLocal(start, end) {
|
|
184
|
-
// eslint-disable-next-line import/no-deprecated
|
|
184
|
+
// eslint-disable-next-line import-x/no-deprecated
|
|
185
185
|
let obliterateOp;
|
|
186
186
|
if (this._mergeTree.options?.mergeTreeEnableSidedObliterate) {
|
|
187
187
|
obliterateOp = (0, opBuilder_js_1.createObliterateRangeOpSided)(start, end);
|
|
@@ -414,7 +414,7 @@ class Client extends client_utils_1.TypedEventEmitter {
|
|
|
414
414
|
* @throws LoggingError if the range is invalid
|
|
415
415
|
*/
|
|
416
416
|
getValidSidedRange(
|
|
417
|
-
// eslint-disable-next-line import/no-deprecated
|
|
417
|
+
// eslint-disable-next-line import-x/no-deprecated
|
|
418
418
|
op, perspective) {
|
|
419
419
|
const invalidPositions = [];
|
|
420
420
|
let start;
|
|
@@ -1037,7 +1037,7 @@ class Client extends client_utils_1.TypedEventEmitter {
|
|
|
1037
1037
|
const loader = new snapshotLoader_js_1.SnapshotLoader(runtime, this, this._mergeTree, this.logger, serializer);
|
|
1038
1038
|
return loader.initialize(storage);
|
|
1039
1039
|
}
|
|
1040
|
-
// eslint-disable-next-line import/no-deprecated
|
|
1040
|
+
// eslint-disable-next-line import-x/no-deprecated
|
|
1041
1041
|
localTransaction(groupOp) {
|
|
1042
1042
|
for (const op of groupOp.ops) {
|
|
1043
1043
|
const opArgs = {
|