@fluidframework/merge-tree 3.0.2 → 3.1.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 +4 -0
- package/README.md +30 -34
- package/dist/client.d.ts.map +1 -1
- package/dist/client.js +6 -7
- package/dist/client.js.map +1 -1
- package/dist/mergeTreeNodes.d.ts +0 -8
- package/dist/mergeTreeNodes.d.ts.map +1 -1
- package/dist/mergeTreeNodes.js +1 -11
- package/dist/mergeTreeNodes.js.map +1 -1
- package/dist/test/beastTest.spec.d.ts +0 -3
- package/dist/test/beastTest.spec.d.ts.map +1 -1
- package/dist/test/beastTest.spec.js +0 -201
- package/dist/test/beastTest.spec.js.map +1 -1
- package/dist/test/testServer.d.ts +1 -2
- package/dist/test/testServer.d.ts.map +1 -1
- package/dist/test/testServer.js +3 -6
- package/dist/test/testServer.js.map +1 -1
- package/lib/client.d.ts.map +1 -1
- package/lib/client.js +7 -8
- package/lib/client.js.map +1 -1
- package/lib/mergeTreeNodes.d.ts +0 -8
- package/lib/mergeTreeNodes.d.ts.map +1 -1
- package/lib/mergeTreeNodes.js +0 -8
- package/lib/mergeTreeNodes.js.map +1 -1
- package/lib/test/beastTest.spec.d.ts +0 -3
- package/lib/test/beastTest.spec.d.ts.map +1 -1
- package/lib/test/beastTest.spec.js +1 -199
- package/lib/test/beastTest.spec.js.map +1 -1
- package/lib/test/testServer.d.ts +1 -2
- package/lib/test/testServer.d.ts.map +1 -1
- package/lib/test/testServer.js +3 -6
- package/lib/test/testServer.js.map +1 -1
- package/package.json +15 -15
- package/src/client.ts +6 -8
- package/src/mergeTreeNodes.ts +0 -10
package/CHANGELOG.md
CHANGED
package/README.md
CHANGED
|
@@ -5,8 +5,7 @@ sequence of collaboratively edited items. MergeTree is used in both SharedSequen
|
|
|
5
5
|
|
|
6
6
|
See [GitHub](https://github.com/microsoft/FluidFramework) for more details on the Fluid Framework and packages within.
|
|
7
7
|
|
|
8
|
-
<!--
|
|
9
|
-
|
|
8
|
+
<!-- markdown-magic:begin {"transform":"library-readme-header","headingLevel":2} -->
|
|
10
9
|
<!-- prettier-ignore-start -->
|
|
11
10
|
<!-- NOTE: This section is automatically generated using @fluid-tools/markdown-magic. Do not update these generated contents directly. -->
|
|
12
11
|
|
|
@@ -40,8 +39,7 @@ Import the `legacy` APIs from `@fluidframework/merge-tree/legacy`.
|
|
|
40
39
|
Read the **@fluidframework/merge-tree** API documentation at <https://fluidframework.com/docs/apis/merge-tree>.
|
|
41
40
|
|
|
42
41
|
<!-- prettier-ignore-end -->
|
|
43
|
-
|
|
44
|
-
<!-- AUTO-GENERATED-CONTENT:END -->
|
|
42
|
+
<!-- markdown-magic:end -->
|
|
45
43
|
|
|
46
44
|
## Operations
|
|
47
45
|
|
|
@@ -136,8 +134,7 @@ consequently should be ignored during the search.
|
|
|
136
134
|
Note that any locally applied operations that are still pending sequencing by the Fluid service are unknown to
|
|
137
135
|
remote clients and should be ignored when processing remote ops.
|
|
138
136
|
|
|
139
|
-
<!--
|
|
140
|
-
|
|
137
|
+
<!-- markdown-magic:begin {"transform":"readme-footer","headingLevel":2} -->
|
|
141
138
|
<!-- prettier-ignore-start -->
|
|
142
139
|
<!-- NOTE: This section is automatically generated using @fluid-tools/markdown-magic. Do not update these generated contents directly. -->
|
|
143
140
|
|
|
@@ -154,29 +151,29 @@ To request support for a configuration that is not listed, file an issue.
|
|
|
154
151
|
The product team will evaluate your request.
|
|
155
152
|
In the issue, specify the current status of the configuration:
|
|
156
153
|
|
|
157
|
-
-
|
|
158
|
-
-
|
|
154
|
+
- The configuration works but needs official support.
|
|
155
|
+
- The configuration does not work and requires changes.
|
|
159
156
|
|
|
160
157
|
### Supported Runtimes
|
|
161
158
|
|
|
162
|
-
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
-
|
|
159
|
+
- Fluid Framework supports Node.js versions 22 and 24 while they receive [upstream support](https://nodejs.org/en/about/previous-releases).
|
|
160
|
+
- Fluid Framework will stop support for version 22 [when upstream support ends on 2027-04-30](https://github.com/nodejs/release#release-schedule).
|
|
161
|
+
- Fluid Framework does not support Node.js with the `--no-experimental-fetch` flag.
|
|
162
|
+
- Fluid Framework supports modern browsers that support the ES2022 standard library.
|
|
166
163
|
|
|
167
164
|
### Supported Tools
|
|
168
165
|
|
|
169
|
-
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
-
|
|
178
|
-
|
|
179
|
-
|
|
166
|
+
- [TypeScript 6.0](https://typescriptdocs.com/release-notes/TypeScript%206.0):
|
|
167
|
+
- Fluid Framework supports all [`strict`](https://www.typescriptlang.org/tsconfig) options.
|
|
168
|
+
- Set the build targets (`lib`, `target`) to `ES2022` or later.
|
|
169
|
+
- Enable [`strictNullChecks`](https://www.typescriptlang.org/tsconfig).
|
|
170
|
+
- Fluid Framework does not support [configuration options deprecated in TypeScript 6.0](https://typescriptdocs.com/release-notes/TypeScript%206.0#breaking-changes-and-deprecations-in-typescript-6-0).
|
|
171
|
+
- Fluid Framework does not fully support `exactOptionalPropertyTypes`.
|
|
172
|
+
If you enable this option, do not use `in`, `Reflect.has`, `Object.hasOwn`, or `Object.prototype.hasOwnProperty` to narrow members of Fluid Framework types.
|
|
173
|
+
These methods can incorrectly exclude `undefined` from the possible values.
|
|
174
|
+
- [webpack](https://webpack.js.org/) 5
|
|
175
|
+
- We do not require a specific bundler.
|
|
176
|
+
Other bundlers that handle ES Modules can work, but we actively test only webpack.
|
|
180
177
|
|
|
181
178
|
### Module Resolution
|
|
182
179
|
|
|
@@ -187,25 +184,25 @@ Do not use `Node10` module resolution.
|
|
|
187
184
|
|
|
188
185
|
### Module Formats
|
|
189
186
|
|
|
190
|
-
-
|
|
191
|
-
|
|
192
|
-
-
|
|
193
|
-
|
|
187
|
+
- ES Modules:
|
|
188
|
+
Use ES Modules to consume Fluid Framework client packages, including in Node.js.
|
|
189
|
+
- CommonJS:
|
|
190
|
+
Fluid Framework does not officially support CommonJS in version 3.0 or later.
|
|
194
191
|
|
|
195
192
|
## Contribution Guidelines
|
|
196
193
|
|
|
197
194
|
You can [contribute](https://github.com/microsoft/FluidFramework/blob/main/CONTRIBUTING.md) to Fluid Framework in these ways:
|
|
198
195
|
|
|
199
|
-
-
|
|
200
|
-
-
|
|
201
|
-
-
|
|
202
|
-
-
|
|
196
|
+
- Answer questions in [GitHub Discussions](https://github.com/microsoft/FluidFramework/discussions).
|
|
197
|
+
- [Submit bug reports](https://github.com/microsoft/FluidFramework/issues) and help verify fixes.
|
|
198
|
+
- Review [source code changes](https://github.com/microsoft/FluidFramework/pulls).
|
|
199
|
+
- [Contribute bug fixes](https://github.com/microsoft/FluidFramework/blob/main/CONTRIBUTING.md).
|
|
203
200
|
|
|
204
201
|
For detailed instructions, read the [repo documentation](https://github.com/microsoft/FluidFramework/blob/main/docs/content/Home.md).
|
|
205
202
|
|
|
206
203
|
This project follows the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/).
|
|
207
204
|
For more information, read the [Code of Conduct frequently asked questions](https://opensource.microsoft.com/codeofconduct/faq/).
|
|
208
|
-
For questions or comments, contact
|
|
205
|
+
For questions or comments, contact <opencode@microsoft.com>.
|
|
209
206
|
|
|
210
207
|
This project may contain Microsoft trademarks or logos for Microsoft projects, products, or services.
|
|
211
208
|
Use of these trademarks or logos must follow Microsoft’s [Trademark & Brand Guidelines](https://www.microsoft.com/trademarks).
|
|
@@ -226,5 +223,4 @@ Use of these trademarks or logos must follow Microsoft's [Trademark & Brand Guid
|
|
|
226
223
|
Use of Microsoft trademarks or logos in modified versions of this project must not cause confusion or imply Microsoft sponsorship.
|
|
227
224
|
|
|
228
225
|
<!-- prettier-ignore-end -->
|
|
229
|
-
|
|
230
|
-
<!-- AUTO-GENERATED-CONTENT:END -->
|
|
226
|
+
<!-- markdown-magic:end -->
|
package/dist/client.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../src/client.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAIH,OAAO,EAAE,iBAAiB,EAAE,MAAM,8BAA8B,CAAC;AACjE,OAAO,KAAK,EAAE,qBAAqB,EAAE,YAAY,EAAE,MAAM,iCAAiC,CAAC;AAO3F,OAAO,KAAK,EACX,sBAAsB,EACtB,sBAAsB,EACtB,MAAM,gDAAgD,CAAC;AACxD,OAAO,EAEN,KAAK,yBAAyB,EAC9B,MAAM,6CAA6C,CAAC;AACrD,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,8CAA8C,CAAC;AAE1F,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,6CAA6C,CAAC;AACpF,OAAO,EAEN,KAAK,kBAAkB,EAEvB,MAAM,0CAA0C,CAAC;AAElD,OAAO,EAAuB,KAAK,oBAAoB,EAAE,MAAM,0BAA0B,CAAC;
|
|
1
|
+
{"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../src/client.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAIH,OAAO,EAAE,iBAAiB,EAAE,MAAM,8BAA8B,CAAC;AACjE,OAAO,KAAK,EAAE,qBAAqB,EAAE,YAAY,EAAE,MAAM,iCAAiC,CAAC;AAO3F,OAAO,KAAK,EACX,sBAAsB,EACtB,sBAAsB,EACtB,MAAM,gDAAgD,CAAC;AACxD,OAAO,EAEN,KAAK,yBAAyB,EAC9B,MAAM,6CAA6C,CAAC;AACrD,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,8CAA8C,CAAC;AAE1F,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,6CAA6C,CAAC;AACpF,OAAO,EAEN,KAAK,kBAAkB,EAEvB,MAAM,0CAA0C,CAAC;AAElD,OAAO,EAAuB,KAAK,oBAAoB,EAAE,MAAM,0BAA0B,CAAC;AAE1F,OAAO,EAAE,KAAK,sBAAsB,EAAE,iBAAiB,EAAE,MAAM,qBAAqB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AC;IAOjE,gBAAgB,CAAC,OAAO,EAAE,kBAAkB,GAAG,IAAI;IA+BnD,YAAY,CAAC,MAAM,EAAE,MAAM,GAAG,IAAI;IAIlC,oBAAoB,CAAC,CAAC,SAAS,QAAQ,EACtC,GAAG,EAAE,MAAM,EACX,YAAY,CAAC,EAAE,IAAI,CAAC,yBAAyB,EAAE,yBAAyB,GAAG,UAAU,CAAC,EACtF,QAAQ,CAAC,EAAE,MAAM,GAEf;QACA,OAAO,EAAE,CAAC,CAAC;QACX,MAAM,EAAE,MAAM,CAAC;KACd,GACD,SAAS;IAuBZ,uBAAuB,CAAC,GAAG,EAAE,MAAM,GAAG,WAAW,GAAG,SAAS;IAK7D,yBAAyB,CAAC,GAAG,EAAE,MAAM,GAAG;QACvC,QAAQ,EAAE,MAAM,GAAG,SAAS,CAAC;QAC7B,WAAW,EAAE,MAAM,GAAG,SAAS,CAAC;KAChC;IAaD,aAAa,IAAI,MAAM;IAIvB,WAAW,IAAI,MAAM;IAIrB,SAAS,IAAI,MAAM;IAInB,0BAA0B,CACzB,YAAY,EAAE,MAAM,GAAG,SAAS,EAChC,MAAM,SAAI,EACV,UAAU,SAAI,GACZ,IAAI;IAyBP;;;;;;;;OAQG;IACH,eAAe,CAAC,QAAQ,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,EAAE,QAAQ,UAAO,GAAG,MAAM,GAAG,SAAS;CAG3F"}
|
package/dist/client.js
CHANGED
|
@@ -45,7 +45,6 @@ const internal_2 = require("@fluidframework/driver-definitions/internal");
|
|
|
45
45
|
const internal_3 = require("@fluidframework/runtime-utils/internal");
|
|
46
46
|
const internal_4 = require("@fluidframework/telemetry-utils/internal");
|
|
47
47
|
const MergeTreeTextHelper_js_1 = require("./MergeTreeTextHelper.js");
|
|
48
|
-
const index_js_1 = require("./collections/index.js");
|
|
49
48
|
const constants_js_1 = require("./constants.js");
|
|
50
49
|
const localReference_js_1 = require("./localReference.js");
|
|
51
50
|
const mergeTree_js_1 = require("./mergeTree.js");
|
|
@@ -76,7 +75,7 @@ class Client extends client_utils_1.TypedEventEmitter {
|
|
|
76
75
|
getMinInFlightRefSeq;
|
|
77
76
|
longClientId;
|
|
78
77
|
_mergeTree;
|
|
79
|
-
clientNameToIds = new
|
|
78
|
+
clientNameToIds = new Map();
|
|
80
79
|
shortClientIdMap = [];
|
|
81
80
|
/**
|
|
82
81
|
* @param specToSegment - Rehydrates a segment from its JSON representation
|
|
@@ -553,19 +552,19 @@ class Client extends client_utils_1.TypedEventEmitter {
|
|
|
553
552
|
}
|
|
554
553
|
}
|
|
555
554
|
getOrAddShortClientId(longClientId) {
|
|
556
|
-
if (!this.clientNameToIds.
|
|
555
|
+
if (!this.clientNameToIds.has(longClientId)) {
|
|
557
556
|
this.addLongClientId(longClientId);
|
|
558
557
|
}
|
|
559
558
|
return this.getShortClientId(longClientId);
|
|
560
559
|
}
|
|
561
560
|
getShortClientId(longClientId) {
|
|
562
|
-
return this.clientNameToIds.get(longClientId)
|
|
561
|
+
return this.clientNameToIds.get(longClientId);
|
|
563
562
|
}
|
|
564
563
|
getLongClientId(shortClientId) {
|
|
565
564
|
return shortClientId >= 0 ? this.shortClientIdMap[shortClientId] : "original";
|
|
566
565
|
}
|
|
567
566
|
addLongClientId(longClientId) {
|
|
568
|
-
this.clientNameToIds.
|
|
567
|
+
this.clientNameToIds.set(longClientId, this.shortClientIdMap.length);
|
|
569
568
|
this.shortClientIdMap.push(longClientId);
|
|
570
569
|
}
|
|
571
570
|
getOrAddShortClientIdFromMessage(msg) {
|
|
@@ -1145,9 +1144,9 @@ class Client extends client_utils_1.TypedEventEmitter {
|
|
|
1145
1144
|
}
|
|
1146
1145
|
else {
|
|
1147
1146
|
const oldClientId = this.longClientId;
|
|
1148
|
-
const oldData = this.clientNameToIds.get(oldClientId)
|
|
1147
|
+
const oldData = this.clientNameToIds.get(oldClientId);
|
|
1149
1148
|
this.longClientId = longClientId;
|
|
1150
|
-
this.clientNameToIds.
|
|
1149
|
+
this.clientNameToIds.set(longClientId, oldData);
|
|
1151
1150
|
this.shortClientIdMap[oldData] = longClientId;
|
|
1152
1151
|
}
|
|
1153
1152
|
}
|