@xnetjs/data 2.4.0 → 3.0.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 +5 -0
- package/dist/auth/index.d.ts +4 -4
- package/dist/{chunk-56EXPOJ4.js → chunk-ANMAR3KY.js} +34 -19
- package/dist/chunk-GJAOMEQO.js +114 -0
- package/dist/chunk-KY62NUOI.js +67 -0
- package/dist/chunk-N37U6ZPI.js +789 -0
- package/dist/chunk-NFPEFD2I.js +42 -0
- package/dist/{chunk-EGGRKSRH.js → chunk-QKVIKVAL.js} +70 -31
- package/dist/{chunk-CY6EJUNV.js → chunk-S7SEN4LH.js} +5 -1
- package/dist/{chunk-4HJZJMPI.js → chunk-TN7LGV66.js} +1 -1
- package/dist/{chunk-YRFCXKJC.js → chunk-UQ2VFHU3.js} +2 -2
- package/dist/chunk-VZSEZNYA.js +83 -0
- package/dist/chunk-WSINZHSR.js +90 -0
- package/dist/{chunk-CNGEXCIH.js → chunk-YCBJDT23.js} +69 -55
- package/dist/{clone-BsoRt89i.d.ts → clone-ywzFVkID.d.ts} +16 -6
- package/dist/course-C5DXOIVO.js +24 -0
- package/dist/database/index.d.ts +17 -5
- package/dist/database/index.js +7 -7
- package/dist/event-VW3FBN4F.js +20 -0
- package/dist/{form-types-Dkqm9UO2.d.ts → form-types-BrHYdpi0.d.ts} +1 -1
- package/dist/{game-NEQP7OFX.js → game-7AXW7XKS.js} +1 -1
- package/dist/{grant-expiration-cleaner-BwdmRFua.d.ts → grant-expiration-cleaner-CRS9OyhV.d.ts} +3 -3
- package/dist/index.d.ts +10 -320
- package/dist/index.js +522 -1097
- package/dist/{moderation-HRMMBFVH.js → moderation-5Z4LKOKN.js} +5 -3
- package/dist/{page-RUS2BKMX.js → page-W4G6433H.js} +1 -1
- package/dist/portability/index.d.ts +330 -0
- package/dist/portability/index.js +34 -0
- package/dist/post-7IOO64MD.js +14 -0
- package/dist/{profile-5H6XWCK4.js → profile-KLHCAQY2.js} +1 -1
- package/dist/publication-3MN3WWKP.js +10 -0
- package/dist/{query-ast-DYGcKxoa.d.ts → query-ast-DQJO7yRV.d.ts} +1 -1
- package/dist/{registry-D_3b1Lg6.d.ts → registry-C9IRLLeR.d.ts} +1 -1
- package/dist/schema/index.d.ts +375 -26
- package/dist/schema/index.js +213 -167
- package/dist/space-GBTEHZOK.js +1 -1
- package/dist/store/index.d.ts +4 -4
- package/dist/store/index.js +4 -4
- package/dist/{store-BMnhBWzM.d.ts → store-D1oiFQuF.d.ts} +19 -2
- package/dist/{types-cycApzib.d.ts → types-gws1tSf-.d.ts} +1 -1
- package/package.json +27 -25
- package/dist/chunk-Y2XWK7AA.js +0 -50
|
@@ -1673,4 +1673,4 @@ type InferNode<P extends Record<string, PropertyBuilder>> = {
|
|
|
1673
1673
|
createdBy: DID;
|
|
1674
1674
|
} & InferProperties<P>;
|
|
1675
1675
|
|
|
1676
|
-
export {
|
|
1676
|
+
export { lensRegistry as $, isNode as A, createNodeId as B, type CreateNodeOptions$1 as C, type DefinedSchema as D, type PropertyType as E, type PropertyDefinition as F, type GetWithMigrationOptions as G, type ValidationError as H, type InferCreateProps as I, type CreateNodeOptions as J, type InferPropertyType as K, type ListNodesOptions as L, type MigratedNodeState as M, type NodeQueryPageCountMode as N, type OfflineAuthPolicy as O, type PropertyBuilder as P, type InferProperties as Q, type InferNode as R, type SchemaIRI as S, type TransactionOperation as T, type UpdateNodeOptions as U, type ValidationResult as V, type SchemaLens as W, type LensOperation as X, type MigrationResult as Y, MigrationError as Z, LensRegistry as _, type Schema as a, mergeOfflinePolicy as a$, type PropertyKey as a0, type NodePayload as a1, type PropertyTimestamp as a2, type PinEntry as a3, type PinRegistry as a4, type SetNodeOptions as a5, type ImportNodesOptions as a6, type RebuildNodeIndexesOptions as a7, type ApplyNodeBatchInput as a8, type ApplyNodeBatchResult as a9, type NodeContentCipher as aA, type ContentKeyCache as aB, type MigrationInfo as aC, createNodeQueryDescriptor as aD, encodeNodeQueryCursor as aE, decodeNodeQueryCursor as aF, nodeQueryDescriptorToOptions as aG, serializeNodeQueryDescriptor as aH, matchesNodeQueryDescriptor as aI, filterNodeQueryResults as aJ, sortNodeQueryResults as aK, applyNodeQueryDescriptor as aL, getNodeQuerySearchTokens as aM, nodeQueryDescriptorNeedsBoundedReload as aN, withoutNodeQueryPagination as aO, withoutNodeQueryMaterializedView as aP, isTempId as aQ, TEMP_ID_PREFIX as aR, resolveTempIds as aS, createSchemaLookup as aT, type SchemaLookup as aU, type TempIdResolution as aV, StoreAuth as aW, GrantRateLimiter as aX, GRANT_SCHEMA_IRI as aY, isGrantActive as aZ, DEFAULT_OFFLINE_POLICY as a_, type NodeBatchIndexMode as aa, type NodeBatchNotificationMode as ab, type NodeBatchSyncMode as ac, type NodeBatchPreflightResult as ad, type DeterministicNodeBatchWriteInput as ae, type NodeBatchWritePolicy as af, type NodeBatchWriteTimings as ag, type CountNodesOptions as ah, type NodeQuerySpatialPoint as ai, type NodeQuerySpatialRect as aj, type NodeQuerySpatialPointFields as ak, type NodeQuerySpatialRectFields as al, type NodeQuerySpatialWindow as am, type NodeQuerySpatialRadius as an, type NodeQuerySpatialFilter as ao, type NodeQuerySearchField as ap, type NodeQuerySearchFilter as aq, type NodeQueryMaterializedViewOptions as ar, type NodeQueryPageOptions as as, type NodeQueryCursorOrderEntry as at, type NodeQueryCursor as au, type NodeQueryOptions as av, type NodeQueryPlanMetadata as aw, type NodeQueryParityCheckMetadata as ax, type ConflictResult as ay, type NodeBatchChangeEvent as az, type ParsedSchemaIRI as b, type StoreAuthOptions as b0, type StoreAuthStore as b1, type StoreAuthKeyManager as b2, type GrantInput as b3, type Grant as b4, StoreAuthError as b5, type StoreAuthErrorCode as b6, type GrantNode as b7, type GrantIndexStore as b8, type GrantIndexOptions as b9, type RevocationConsistency as ba, type RevocationConfig as bb, type GrantRateLimiterOptions as bc, type DocumentType as bd, DEFAULT_SCHEMA_VERSION as be, parseSchemaIRI as bf, buildSchemaIRI as bg, normalizeSchemaIRI as bh, getBaseSchemaIRI as bi, isSameSchema as bj, getSchemaVersion as bk, type NodeReadAuthorizer as bl, type AuthorizationStateVersion as bm, type OperationNodeBatchWriteInput as bn, type PropertyLookup as bo, createPropertyLookup as bp, type SortDirection as c, type SystemOrderField as d, type StoreAuthAPI as e, type NodeStoreOptions as f, type NodeStorageAdapter as g, type NodeState as h, type NodeId as i, type CheckedOutDraftOverlay as j, type NodeQueryDescriptor as k, type NodeQueryResult as l, type TransactionResult as m, type DeterministicNodeImportDraft as n, type ImportDeterministicNodesOptions as o, type ImportDeterministicNodesResult as p, type NodeBatchWriteInput as q, type NodeBatchWriteResult as r, type NodeChange as s, type MergeConflict as t, type NodeChangeListener as u, type NodeBatchChangeListener as v, type NodeChangeEvent as w, GrantIndex as x, type Node as y, type DID as z };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@xnetjs/data",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "3.0.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -11,36 +11,36 @@
|
|
|
11
11
|
"types": "./dist/index.d.ts",
|
|
12
12
|
"exports": {
|
|
13
13
|
".": {
|
|
14
|
-
"
|
|
15
|
-
"
|
|
14
|
+
"types": "./dist/index.d.ts",
|
|
15
|
+
"import": "./dist/index.js"
|
|
16
16
|
},
|
|
17
17
|
"./schema": {
|
|
18
|
-
"
|
|
19
|
-
"
|
|
18
|
+
"types": "./dist/schema/index.d.ts",
|
|
19
|
+
"import": "./dist/schema/index.js"
|
|
20
20
|
},
|
|
21
21
|
"./store": {
|
|
22
|
-
"
|
|
23
|
-
"
|
|
22
|
+
"types": "./dist/store/index.d.ts",
|
|
23
|
+
"import": "./dist/store/index.js"
|
|
24
24
|
},
|
|
25
25
|
"./database": {
|
|
26
|
-
"
|
|
27
|
-
"
|
|
26
|
+
"types": "./dist/database/index.d.ts",
|
|
27
|
+
"import": "./dist/database/index.js"
|
|
28
28
|
},
|
|
29
29
|
"./auth": {
|
|
30
|
-
"
|
|
31
|
-
"
|
|
30
|
+
"types": "./dist/auth/index.d.ts",
|
|
31
|
+
"import": "./dist/auth/index.js"
|
|
32
32
|
},
|
|
33
33
|
"./portability": {
|
|
34
|
-
"
|
|
35
|
-
"
|
|
34
|
+
"types": "./dist/portability/index.d.ts",
|
|
35
|
+
"import": "./dist/portability/index.js"
|
|
36
36
|
},
|
|
37
37
|
"./updates": {
|
|
38
|
-
"
|
|
39
|
-
"
|
|
38
|
+
"types": "./dist/updates.d.ts",
|
|
39
|
+
"import": "./dist/updates.js"
|
|
40
40
|
},
|
|
41
41
|
"./awareness": {
|
|
42
|
-
"
|
|
43
|
-
"
|
|
42
|
+
"types": "./dist/sync/awareness.d.ts",
|
|
43
|
+
"import": "./dist/sync/awareness.js"
|
|
44
44
|
},
|
|
45
45
|
"./ts-plugin": {
|
|
46
46
|
"types": "./dist/ts-plugin/index.d.ts",
|
|
@@ -61,21 +61,23 @@
|
|
|
61
61
|
"nanoid": "^5.1.6",
|
|
62
62
|
"y-protocols": "^1.0.6",
|
|
63
63
|
"yjs": "^13.6.24",
|
|
64
|
-
"@xnetjs/core": "
|
|
65
|
-
"@xnetjs/crypto": "
|
|
66
|
-
"@xnetjs/identity": "
|
|
67
|
-
"@xnetjs/sqlite": "
|
|
68
|
-
"@xnetjs/storage": "
|
|
69
|
-
"@xnetjs/sync": "
|
|
64
|
+
"@xnetjs/core": "3.0.0",
|
|
65
|
+
"@xnetjs/crypto": "3.0.0",
|
|
66
|
+
"@xnetjs/identity": "3.0.0",
|
|
67
|
+
"@xnetjs/sqlite": "3.0.0",
|
|
68
|
+
"@xnetjs/storage": "3.0.0",
|
|
69
|
+
"@xnetjs/sync": "3.0.0"
|
|
70
70
|
},
|
|
71
71
|
"devDependencies": {
|
|
72
72
|
"tsup": "^8.0.0",
|
|
73
73
|
"typescript": "^5.4.0"
|
|
74
74
|
},
|
|
75
75
|
"scripts": {
|
|
76
|
-
"build": "tsup src/index.ts src/schema/index.ts src/store/index.ts src/database/index.ts src/auth/index.ts src/updates.ts src/sync/awareness.ts --format esm --dts && tsup src/ts-plugin/index.ts --format cjs,esm --dts --outDir dist/ts-plugin",
|
|
76
|
+
"build": "tsup src/index.ts src/schema/index.ts src/store/index.ts src/database/index.ts src/auth/index.ts src/portability/index.ts src/updates.ts src/sync/awareness.ts --format esm --dts && tsup src/ts-plugin/index.ts --format cjs,esm --dts --outDir dist/ts-plugin",
|
|
77
77
|
"test": "vitest run",
|
|
78
78
|
"typecheck": "tsc --noEmit",
|
|
79
|
-
"clean": "rm -rf dist"
|
|
79
|
+
"clean": "rm -rf dist",
|
|
80
|
+
"api:check": "api-extractor run",
|
|
81
|
+
"api:update": "api-extractor run --local"
|
|
80
82
|
}
|
|
81
83
|
}
|
package/dist/chunk-Y2XWK7AA.js
DELETED
|
@@ -1,50 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
spaceCascadeAuthorization
|
|
3
|
-
} from "./chunk-RLRAWZJE.js";
|
|
4
|
-
import {
|
|
5
|
-
defineSchema,
|
|
6
|
-
file,
|
|
7
|
-
relation,
|
|
8
|
-
select,
|
|
9
|
-
text
|
|
10
|
-
} from "./chunk-NH6OLO3X.js";
|
|
11
|
-
|
|
12
|
-
// src/schema/schemas/page.ts
|
|
13
|
-
var PageSchema = defineSchema({
|
|
14
|
-
name: "Page",
|
|
15
|
-
namespace: "xnet://xnet.fyi/",
|
|
16
|
-
properties: {
|
|
17
|
-
/** Page title */
|
|
18
|
-
title: text({ required: true, maxLength: 500 }),
|
|
19
|
-
/** Emoji or icon URL */
|
|
20
|
-
icon: text({}),
|
|
21
|
-
/** Cover image */
|
|
22
|
-
cover: file({ accept: ["image/*"] }),
|
|
23
|
-
/** Canonical home; empty = Unfiled (exploration 0169) */
|
|
24
|
-
folder: relation({ target: "xnet://xnet.fyi/Folder@1.0.0" }),
|
|
25
|
-
/** Order among folder siblings — fractional index */
|
|
26
|
-
sortKey: text({ maxLength: 500 }),
|
|
27
|
-
/** Workspace-wide labels, referenced by id (exploration 0169) */
|
|
28
|
-
tags: relation({ target: "xnet://xnet.fyi/Tag@1.0.0", multiple: true }),
|
|
29
|
-
/** Canonical SECURITY home; empty = personal/private (exploration 0179) */
|
|
30
|
-
space: relation({ target: "xnet://xnet.fyi/Space@1.0.0" }),
|
|
31
|
-
/** Per-node visibility; `inherit` defers to the Space (exploration 0179) */
|
|
32
|
-
visibility: select({
|
|
33
|
-
options: [
|
|
34
|
-
{ id: "inherit", name: "Inherit", color: "gray" },
|
|
35
|
-
{ id: "private", name: "Private", color: "gray" },
|
|
36
|
-
{ id: "unlisted", name: "Unlisted", color: "yellow" },
|
|
37
|
-
{ id: "public", name: "Public", color: "green" }
|
|
38
|
-
],
|
|
39
|
-
default: "inherit"
|
|
40
|
-
})
|
|
41
|
-
},
|
|
42
|
-
document: "yjs",
|
|
43
|
-
// Collaborative Y.Doc for rich text
|
|
44
|
-
// Inherits access from its home Space (exploration 0181/0192).
|
|
45
|
-
authorization: spaceCascadeAuthorization()
|
|
46
|
-
});
|
|
47
|
-
|
|
48
|
-
export {
|
|
49
|
-
PageSchema
|
|
50
|
-
};
|