@fluidframework/id-compressor 2.53.1 → 2.61.0-355054
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/.mocharc.cjs +1 -2
- package/CHANGELOG.md +4 -0
- package/api-report/{id-compressor.legacy.alpha.api.md → id-compressor.legacy.beta.api.md} +11 -11
- package/dist/finalSpace.d.ts +2 -2
- package/dist/finalSpace.d.ts.map +1 -1
- package/dist/finalSpace.js.map +1 -1
- package/dist/idCompressor.d.ts +20 -17
- package/dist/idCompressor.d.ts.map +1 -1
- package/dist/idCompressor.js +14 -13
- package/dist/idCompressor.js.map +1 -1
- package/dist/identifiers.d.ts +1 -1
- package/dist/identifiers.d.ts.map +1 -1
- package/dist/identifiers.js.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js.map +1 -1
- package/dist/legacy.d.ts +4 -2
- package/dist/packageVersion.d.ts +1 -1
- package/dist/packageVersion.d.ts.map +1 -1
- package/dist/packageVersion.js +1 -1
- package/dist/packageVersion.js.map +1 -1
- package/dist/persistanceUtilities.d.ts +1 -1
- package/dist/persistanceUtilities.d.ts.map +1 -1
- package/dist/persistanceUtilities.js.map +1 -1
- package/dist/public.d.ts +2 -1
- package/dist/sessionSpaceNormalizer.d.ts +1 -1
- package/dist/sessionSpaceNormalizer.d.ts.map +1 -1
- package/dist/sessionSpaceNormalizer.js.map +1 -1
- package/dist/sessions.d.ts +2 -2
- package/dist/sessions.d.ts.map +1 -1
- package/dist/sessions.js.map +1 -1
- package/dist/test/appendOnlySortedMap.perf.spec.js.map +1 -1
- package/dist/test/idCompressor.perf.spec.js.map +1 -1
- package/dist/test/idCompressor.spec.js.map +1 -1
- package/dist/test/idCompressorTestUtilities.d.ts +4 -4
- package/dist/test/idCompressorTestUtilities.d.ts.map +1 -1
- package/dist/test/idCompressorTestUtilities.js +5 -2
- package/dist/test/idCompressorTestUtilities.js.map +1 -1
- package/dist/test/numericUuid.spec.js.map +1 -1
- package/dist/test/snapshots/summary.spec.js.map +1 -1
- package/dist/test/testCommon.d.ts +2 -2
- package/dist/test/testCommon.d.ts.map +1 -1
- package/dist/test/testCommon.js.map +1 -1
- package/dist/types/idCompressor.d.ts +3 -4
- package/dist/types/idCompressor.d.ts.map +1 -1
- package/dist/types/idCompressor.js.map +1 -1
- package/dist/types/index.d.ts +3 -3
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/index.js.map +1 -1
- package/dist/types/persisted-types/0.0.1.d.ts +4 -8
- package/dist/types/persisted-types/0.0.1.d.ts.map +1 -1
- package/dist/types/persisted-types/0.0.1.js.map +1 -1
- package/dist/types/persisted-types/index.d.ts +1 -1
- package/dist/types/persisted-types/index.d.ts.map +1 -1
- package/dist/types/persisted-types/index.js.map +1 -1
- package/dist/utilities.d.ts +3 -4
- package/dist/utilities.d.ts.map +1 -1
- package/dist/utilities.js +1 -2
- package/dist/utilities.js.map +1 -1
- package/internal.d.ts +1 -1
- package/legacy.d.ts +1 -1
- package/lib/finalSpace.d.ts +2 -2
- package/lib/finalSpace.d.ts.map +1 -1
- package/lib/finalSpace.js.map +1 -1
- package/lib/idCompressor.d.ts +20 -17
- package/lib/idCompressor.d.ts.map +1 -1
- package/lib/idCompressor.js +14 -13
- package/lib/idCompressor.js.map +1 -1
- package/lib/identifiers.d.ts +1 -1
- package/lib/identifiers.d.ts.map +1 -1
- package/lib/identifiers.js.map +1 -1
- package/lib/index.d.ts +1 -1
- package/lib/index.d.ts.map +1 -1
- package/lib/index.js.map +1 -1
- package/lib/legacy.d.ts +4 -2
- package/lib/packageVersion.d.ts +1 -1
- package/lib/packageVersion.d.ts.map +1 -1
- package/lib/packageVersion.js +1 -1
- package/lib/packageVersion.js.map +1 -1
- package/lib/persistanceUtilities.d.ts +1 -1
- package/lib/persistanceUtilities.d.ts.map +1 -1
- package/lib/persistanceUtilities.js.map +1 -1
- package/lib/public.d.ts +2 -1
- package/lib/sessionSpaceNormalizer.d.ts +1 -1
- package/lib/sessionSpaceNormalizer.d.ts.map +1 -1
- package/lib/sessionSpaceNormalizer.js.map +1 -1
- package/lib/sessions.d.ts +2 -2
- package/lib/sessions.d.ts.map +1 -1
- package/lib/sessions.js.map +1 -1
- package/lib/test/appendOnlySortedMap.perf.spec.js.map +1 -1
- package/lib/test/idCompressor.perf.spec.js.map +1 -1
- package/lib/test/idCompressor.spec.js.map +1 -1
- package/lib/test/idCompressorTestUtilities.d.ts +4 -4
- package/lib/test/idCompressorTestUtilities.d.ts.map +1 -1
- package/lib/test/idCompressorTestUtilities.js +5 -2
- package/lib/test/idCompressorTestUtilities.js.map +1 -1
- package/lib/test/numericUuid.spec.js.map +1 -1
- package/lib/test/snapshots/summary.spec.js.map +1 -1
- package/lib/test/testCommon.d.ts +2 -2
- package/lib/test/testCommon.d.ts.map +1 -1
- package/lib/test/testCommon.js.map +1 -1
- package/lib/tsdoc-metadata.json +1 -1
- package/lib/types/idCompressor.d.ts +3 -4
- package/lib/types/idCompressor.d.ts.map +1 -1
- package/lib/types/idCompressor.js.map +1 -1
- package/lib/types/index.d.ts +3 -3
- package/lib/types/index.d.ts.map +1 -1
- package/lib/types/index.js.map +1 -1
- package/lib/types/persisted-types/0.0.1.d.ts +4 -8
- package/lib/types/persisted-types/0.0.1.d.ts.map +1 -1
- package/lib/types/persisted-types/0.0.1.js.map +1 -1
- package/lib/types/persisted-types/index.d.ts +1 -1
- package/lib/types/persisted-types/index.d.ts.map +1 -1
- package/lib/types/persisted-types/index.js.map +1 -1
- package/lib/utilities.d.ts +3 -4
- package/lib/utilities.d.ts.map +1 -1
- package/lib/utilities.js +1 -2
- package/lib/utilities.js.map +1 -1
- package/package.json +17 -17
- package/src/finalSpace.ts +2 -2
- package/src/idCompressor.ts +42 -49
- package/src/identifiers.ts +1 -1
- package/src/index.ts +1 -1
- package/src/packageVersion.ts +1 -1
- package/src/persistanceUtilities.ts +1 -1
- package/src/sessionSpaceNormalizer.ts +1 -1
- package/src/sessions.ts +2 -2
- package/src/test/idCompressorTestUtilities.ts +18 -15
- package/src/test/testCommon.ts +2 -2
- package/src/types/idCompressor.ts +3 -4
- package/src/types/index.ts +3 -3
- package/src/types/persisted-types/0.0.1.ts +4 -8
- package/src/types/persisted-types/index.ts +1 -1
- package/src/utilities.ts +3 -4
|
@@ -7,8 +7,7 @@ import type { SessionId } from "../identifiers.js";
|
|
|
7
7
|
|
|
8
8
|
/**
|
|
9
9
|
* The serialized contents of an IdCompressor, suitable for persistence in a summary.
|
|
10
|
-
* @legacy
|
|
11
|
-
* @alpha
|
|
10
|
+
* @legacy @beta
|
|
12
11
|
*/
|
|
13
12
|
export type SerializedIdCompressor = string & {
|
|
14
13
|
readonly _serializedIdCompressor: "8c73c57c-1cf4-4278-8915-6444cb4f6af5";
|
|
@@ -16,8 +15,7 @@ export type SerializedIdCompressor = string & {
|
|
|
16
15
|
|
|
17
16
|
/**
|
|
18
17
|
* The serialized contents of an IdCompressor, suitable for persistence in a summary.
|
|
19
|
-
* @legacy
|
|
20
|
-
* @alpha
|
|
18
|
+
* @legacy @beta
|
|
21
19
|
*/
|
|
22
20
|
export type SerializedIdCompressorWithNoSession = SerializedIdCompressor & {
|
|
23
21
|
readonly _noLocalState: "3aa2e1e8-cc28-4ea7-bc1a-a11dc3f26dfb";
|
|
@@ -25,8 +23,7 @@ export type SerializedIdCompressorWithNoSession = SerializedIdCompressor & {
|
|
|
25
23
|
|
|
26
24
|
/**
|
|
27
25
|
* The serialized contents of an IdCompressor, suitable for persistence in a summary.
|
|
28
|
-
* @legacy
|
|
29
|
-
* @alpha
|
|
26
|
+
* @legacy @beta
|
|
30
27
|
*/
|
|
31
28
|
export type SerializedIdCompressorWithOngoingSession = SerializedIdCompressor & {
|
|
32
29
|
readonly _hasLocalState: "1281acae-6d14-47e7-bc92-71c8ee0819cb";
|
|
@@ -36,8 +33,7 @@ export type SerializedIdCompressorWithOngoingSession = SerializedIdCompressor &
|
|
|
36
33
|
* Data describing a range of session-local IDs (from a remote or local session).
|
|
37
34
|
*
|
|
38
35
|
* A range is composed of local IDs that were generated.
|
|
39
|
-
* @legacy
|
|
40
|
-
* @alpha
|
|
36
|
+
* @legacy @beta
|
|
41
37
|
*/
|
|
42
38
|
export interface IdCreationRange {
|
|
43
39
|
readonly sessionId: SessionId;
|
package/src/utilities.ts
CHANGED
|
@@ -7,8 +7,8 @@
|
|
|
7
7
|
import { assert } from "@fluidframework/core-utils/internal";
|
|
8
8
|
import { v4 } from "uuid";
|
|
9
9
|
|
|
10
|
-
import { LocalCompressedId, NumericUuid } from "./identifiers.js";
|
|
11
|
-
import { SessionId, StableId } from "./types/index.js";
|
|
10
|
+
import type { LocalCompressedId, NumericUuid } from "./identifiers.js";
|
|
11
|
+
import type { SessionId, StableId } from "./types/index.js";
|
|
12
12
|
|
|
13
13
|
const hexadecimalCharCodes = [..."09afAF"].map((c) => c.codePointAt(0)) as [
|
|
14
14
|
zero: number,
|
|
@@ -29,8 +29,7 @@ function isHexadecimalCharacter(charCode: number): boolean {
|
|
|
29
29
|
|
|
30
30
|
/**
|
|
31
31
|
* Generate a random session ID
|
|
32
|
-
* @legacy
|
|
33
|
-
* @alpha
|
|
32
|
+
* @legacy @beta
|
|
34
33
|
*/
|
|
35
34
|
export function createSessionId(): SessionId {
|
|
36
35
|
return assertIsStableId(v4()) as SessionId;
|