@xnetjs/data 0.0.2 → 0.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.
Files changed (139) hide show
  1. package/README.md +112 -0
  2. package/dist/account-MWNCH4GJ.js +12 -0
  3. package/dist/account-ledger-R2GAFJL6.js +38 -0
  4. package/dist/auth/index.d.ts +420 -0
  5. package/dist/auth/index.js +102 -0
  6. package/dist/budget-NN7P35XP.js +12 -0
  7. package/dist/canvas-6WYBNH53.js +10 -0
  8. package/dist/channel-AT3LQF4A.js +12 -0
  9. package/dist/chat-message-DSVO72B3.js +10 -0
  10. package/dist/chunk-2ZNJWIQG.js +84 -0
  11. package/dist/chunk-3J3HILXO.js +46 -0
  12. package/dist/chunk-3RUDVTMH.js +5543 -0
  13. package/dist/chunk-4EYKGTSQ.js +49 -0
  14. package/dist/chunk-53F4PRNC.js +32 -0
  15. package/dist/chunk-5EXHNXPL.js +48 -0
  16. package/dist/{chunk-BQBPA5HS.js → chunk-5HC5NO57.js} +16 -2
  17. package/dist/chunk-6KLGA6IR.js +47 -0
  18. package/dist/chunk-6OMG4I7M.js +41 -0
  19. package/dist/chunk-7PDRDSFH.js +69 -0
  20. package/dist/chunk-BQLQSWKZ.js +232 -0
  21. package/dist/chunk-BY5O6LNC.js +380 -0
  22. package/dist/chunk-DCTRX6II.js +40 -0
  23. package/dist/{chunk-VYR5GPJP.js → chunk-DWEXKD6E.js} +9 -3
  24. package/dist/chunk-EBNMV2VO.js +896 -0
  25. package/dist/chunk-FVEACSKE.js +102 -0
  26. package/dist/chunk-GU6THOAB.js +45 -0
  27. package/dist/chunk-H4GA4BBK.js +75 -0
  28. package/dist/chunk-IJ44LR7N.js +76 -0
  29. package/dist/chunk-J4ANIXIV.js +402 -0
  30. package/dist/chunk-JDFNMFOZ.js +45 -0
  31. package/dist/chunk-K7DOZWWT.js +1811 -0
  32. package/dist/chunk-KQAT4XBL.js +49 -0
  33. package/dist/chunk-KQUALW4O.js +183 -0
  34. package/dist/chunk-LYSWLCOI.js +47 -0
  35. package/dist/chunk-MBTUO3ZL.js +65 -0
  36. package/dist/chunk-NI4FHG2K.js +52 -0
  37. package/dist/chunk-OCMSAKWV.js +78 -0
  38. package/dist/chunk-OGJCRNGE.js +57 -0
  39. package/dist/chunk-OPPHF3TF.js +143 -0
  40. package/dist/{chunk-IDMBCRUC.js → chunk-OSAWNZVM.js} +1 -1
  41. package/dist/chunk-PMUQACPY.js +33 -0
  42. package/dist/chunk-PNESGUH5.js +63 -0
  43. package/dist/chunk-Q3IEGH4B.js +51 -0
  44. package/dist/chunk-QJW5LDP4.js +52 -0
  45. package/dist/chunk-QWFTRZQT.js +142 -0
  46. package/dist/{chunk-SZC345Z2.js → chunk-RL64OJJ5.js} +1025 -1110
  47. package/dist/chunk-S5RP5RKY.js +416 -0
  48. package/dist/chunk-S6U6TCMN.js +722 -0
  49. package/dist/chunk-SVNGSZZA.js +69 -0
  50. package/dist/chunk-T5AZAOG5.js +54 -0
  51. package/dist/chunk-TCTZW4A6.js +42 -0
  52. package/dist/chunk-U64CW73O.js +109 -0
  53. package/dist/chunk-UDWKWTAX.js +6526 -0
  54. package/dist/chunk-UQM3G5A2.js +148 -0
  55. package/dist/chunk-VQ7JHB67.js +57 -0
  56. package/dist/chunk-W7EBL7ZU.js +73 -0
  57. package/dist/chunk-WEPK7SZF.js +65 -0
  58. package/dist/chunk-XHEA5UER.js +75 -0
  59. package/dist/chunk-XMSKJ5PV.js +66 -0
  60. package/dist/chunk-XROI44ZP.js +64 -0
  61. package/dist/chunk-Y3S5SRVM.js +45 -0
  62. package/dist/chunk-YEFKQYKA.js +43 -0
  63. package/dist/chunk-YSUIXD2Y.js +105 -0
  64. package/dist/chunk-ZCOFZY5M.js +70 -0
  65. package/dist/chunk-ZLU4Y3O2.js +50 -0
  66. package/dist/chunk-ZPZ7XDA6.js +54 -0
  67. package/dist/chunk-ZZ6TWKGS.js +40 -0
  68. package/dist/clone-C0Jhk2UN.d.ts +2205 -0
  69. package/dist/comment-QSWYAQVS.js +10 -0
  70. package/dist/crm-L5RYAAF3.js +68 -0
  71. package/dist/dashboard-JMKTTRA7.js +10 -0
  72. package/dist/database/index.d.ts +882 -0
  73. package/dist/database/index.js +523 -0
  74. package/dist/database-GIXSPZJW.js +10 -0
  75. package/dist/database-field-3EPAMZUR.js +10 -0
  76. package/dist/database-row-6Q6TRVE4.js +10 -0
  77. package/dist/database-select-option-BBBJFLLH.js +10 -0
  78. package/dist/database-view-5PLSOBI2.js +10 -0
  79. package/dist/experiment-DOVOZ34Y.js +10 -0
  80. package/dist/external-item-P2E5X7BZ.js +14 -0
  81. package/dist/external-reference-7BSFF6SA.js +8 -0
  82. package/dist/feed-2IXHHP6O.js +12 -0
  83. package/dist/feed-item-DPE6LN7I.js +12 -0
  84. package/dist/folder-6KM3KYD5.js +21 -0
  85. package/dist/game-5AK5XWBR.js +50 -0
  86. package/dist/grant-WTQSNT5A.js +8 -0
  87. package/dist/grant-expiration-cleaner-CY6BcmlR.d.ts +249 -0
  88. package/dist/import-batch-IXBJLQPJ.js +12 -0
  89. package/dist/inbox-state-E5NSVOGP.js +12 -0
  90. package/dist/index.d.ts +224 -4548
  91. package/dist/index.js +2252 -4754
  92. package/dist/map-RG5Y3CPC.js +10 -0
  93. package/dist/media-asset-QTCGLIZA.js +8 -0
  94. package/dist/memory-PNRTMBZO.js +12 -0
  95. package/dist/metric-65SVOX5C.js +10 -0
  96. package/dist/milestone-XEO6ZGDG.js +12 -0
  97. package/dist/moderation-FFHETMRB.js +30 -0
  98. package/dist/observation-2Y3QKUXM.js +10 -0
  99. package/dist/page-2V27JGKJ.js +10 -0
  100. package/dist/posting-GBOSZCMZ.js +12 -0
  101. package/dist/profile-BLLDWIDK.js +8 -0
  102. package/dist/project-CQL5LN26.js +10 -0
  103. package/dist/query-ast-C3m6kZYv.d.ts +226 -0
  104. package/dist/reaction-T2DTJBBV.js +10 -0
  105. package/dist/registry-DunPv__d.d.ts +99 -0
  106. package/dist/saved-view-4R2DBCL3.js +10 -0
  107. package/dist/schema/index.d.ts +6489 -0
  108. package/dist/schema/index.js +677 -0
  109. package/dist/schema-extension-LNRF2YRD.js +18 -0
  110. package/dist/space-IJU24PBH.js +42 -0
  111. package/dist/space-membership-DEUMM7NV.js +14 -0
  112. package/dist/store/index.d.ts +518 -0
  113. package/dist/store/index.js +135 -0
  114. package/dist/store-DtIDjk7c.d.ts +355 -0
  115. package/dist/sync/awareness.d.ts +69 -0
  116. package/dist/sync/awareness.js +20 -0
  117. package/dist/system-ILHCZOVO.js +38 -0
  118. package/dist/tag-SKCHM3U5.js +16 -0
  119. package/dist/task-7AOBP7WC.js +16 -0
  120. package/dist/task-view-NUGKELJP.js +10 -0
  121. package/dist/transaction-ZDSEGDIR.js +12 -0
  122. package/dist/transcription-PSCLDAGX.js +12 -0
  123. package/dist/types-S-BJAKyK.d.ts +1576 -0
  124. package/dist/updates.d.ts +44 -0
  125. package/dist/updates.js +16 -0
  126. package/dist/user-widget-RLY2N46A.js +8 -0
  127. package/dist/view-types-DSde-uT_.d.ts +316 -0
  128. package/package.json +32 -9
  129. package/dist/canvas-HSIKIQFK.js +0 -7
  130. package/dist/chunk-2L5ZUGG5.js +0 -53
  131. package/dist/chunk-4MTS5KAQ.js +0 -22
  132. package/dist/chunk-GZHARFKC.js +0 -25
  133. package/dist/chunk-WKIKJTI2.js +0 -45
  134. package/dist/comment-277JD7DV.js +0 -7
  135. package/dist/database-W3KEHLI3.js +0 -7
  136. package/dist/database-row-3O2QSNZN.js +0 -7
  137. package/dist/grant-QVZ454YC.js +0 -7
  138. package/dist/page-O4WTOIEO.js +0 -7
  139. package/dist/task-SEKAYJH7.js +0 -7
@@ -0,0 +1,102 @@
1
+ import {
2
+ AUTHENTICATED,
3
+ AUTH_ACTIONS,
4
+ AUTH_FEATURE_FLAGS,
5
+ AuthMigrator,
6
+ BUILTIN_ROLES,
7
+ DEFAULT_OFFLINE_POLICY,
8
+ DecisionCache,
9
+ DefaultPolicyEvaluator,
10
+ DefaultRoleResolver,
11
+ GRANT_SCHEMA_IRI,
12
+ GrantExpirationCleaner,
13
+ GrantIndex,
14
+ GrantRateLimiter,
15
+ MAX_EXPRESSION_NODES,
16
+ PUBLIC,
17
+ PUBLIC_CONTENT_KEY,
18
+ PUBLIC_RECIPIENT,
19
+ StoreAuth,
20
+ StoreAuthError,
21
+ allow,
22
+ and,
23
+ buildPermissionMatrix,
24
+ canTransitionToPublic,
25
+ computeRecipients,
26
+ countExpressionNodes,
27
+ createPolicyEvaluator,
28
+ deny,
29
+ describeRoleResolver,
30
+ deserializeAuthExpression,
31
+ deserializeAuthorization,
32
+ evaluateExpression,
33
+ extractRoleRefs,
34
+ getAuthMode,
35
+ handleAuthMigration,
36
+ hasPublicAccess,
37
+ hasRecipientsChanged,
38
+ hubActionsForSpaceRole,
39
+ isGrantActive,
40
+ mergeOfflinePolicy,
41
+ not,
42
+ or,
43
+ presets,
44
+ relation,
45
+ role,
46
+ schemaToHubPolicy,
47
+ serializeAuthExpression,
48
+ serializeAuthorization,
49
+ validateAuthorization,
50
+ warnLegacySchema
51
+ } from "../chunk-RL64OJJ5.js";
52
+ export {
53
+ AUTHENTICATED,
54
+ AUTH_ACTIONS,
55
+ AUTH_FEATURE_FLAGS,
56
+ AuthMigrator,
57
+ BUILTIN_ROLES,
58
+ DEFAULT_OFFLINE_POLICY,
59
+ DecisionCache,
60
+ DefaultPolicyEvaluator,
61
+ DefaultRoleResolver,
62
+ GRANT_SCHEMA_IRI,
63
+ GrantExpirationCleaner,
64
+ GrantIndex,
65
+ GrantRateLimiter,
66
+ MAX_EXPRESSION_NODES,
67
+ PUBLIC,
68
+ PUBLIC_CONTENT_KEY,
69
+ PUBLIC_RECIPIENT,
70
+ StoreAuth,
71
+ StoreAuthError,
72
+ allow,
73
+ and,
74
+ buildPermissionMatrix,
75
+ canTransitionToPublic,
76
+ computeRecipients,
77
+ countExpressionNodes,
78
+ createPolicyEvaluator,
79
+ deny,
80
+ describeRoleResolver,
81
+ deserializeAuthExpression,
82
+ deserializeAuthorization,
83
+ evaluateExpression,
84
+ extractRoleRefs,
85
+ getAuthMode,
86
+ handleAuthMigration,
87
+ hasPublicAccess,
88
+ hasRecipientsChanged,
89
+ hubActionsForSpaceRole,
90
+ isGrantActive,
91
+ mergeOfflinePolicy,
92
+ not,
93
+ or,
94
+ presets,
95
+ relation,
96
+ role,
97
+ schemaToHubPolicy,
98
+ serializeAuthExpression,
99
+ serializeAuthorization,
100
+ validateAuthorization,
101
+ warnLegacySchema
102
+ };
@@ -0,0 +1,12 @@
1
+ import {
2
+ BUDGET_SCHEMA_IRI,
3
+ BudgetSchema
4
+ } from "./chunk-ZPZ7XDA6.js";
5
+ import "./chunk-OCMSAKWV.js";
6
+ import "./chunk-T5AZAOG5.js";
7
+ import "./chunk-EBNMV2VO.js";
8
+ import "./chunk-RL64OJJ5.js";
9
+ export {
10
+ BUDGET_SCHEMA_IRI,
11
+ BudgetSchema
12
+ };
@@ -0,0 +1,10 @@
1
+ import {
2
+ CanvasSchema
3
+ } from "./chunk-LYSWLCOI.js";
4
+ import "./chunk-OCMSAKWV.js";
5
+ import "./chunk-T5AZAOG5.js";
6
+ import "./chunk-EBNMV2VO.js";
7
+ import "./chunk-RL64OJJ5.js";
8
+ export {
9
+ CanvasSchema
10
+ };
@@ -0,0 +1,12 @@
1
+ import {
2
+ CHANNEL_KINDS,
3
+ ChannelSchema
4
+ } from "./chunk-ZCOFZY5M.js";
5
+ import "./chunk-OCMSAKWV.js";
6
+ import "./chunk-T5AZAOG5.js";
7
+ import "./chunk-EBNMV2VO.js";
8
+ import "./chunk-RL64OJJ5.js";
9
+ export {
10
+ CHANNEL_KINDS,
11
+ ChannelSchema
12
+ };
@@ -0,0 +1,10 @@
1
+ import {
2
+ ChatMessageSchema
3
+ } from "./chunk-Q3IEGH4B.js";
4
+ import "./chunk-OCMSAKWV.js";
5
+ import "./chunk-T5AZAOG5.js";
6
+ import "./chunk-EBNMV2VO.js";
7
+ import "./chunk-RL64OJJ5.js";
8
+ export {
9
+ ChatMessageSchema
10
+ };
@@ -0,0 +1,84 @@
1
+ import {
2
+ spaceCascadeAuthorization
3
+ } from "./chunk-OCMSAKWV.js";
4
+ import {
5
+ defineSchema,
6
+ file,
7
+ number,
8
+ relation,
9
+ select,
10
+ text
11
+ } from "./chunk-EBNMV2VO.js";
12
+
13
+ // src/schema/schemas/transcription.ts
14
+ var TRANSCRIPTION_SCHEMA_IRI = "xnet://xnet.fyi/Transcription@1.0.0";
15
+ var TranscriptionSchema = defineSchema({
16
+ name: "Transcription",
17
+ namespace: "xnet://xnet.fyi/",
18
+ properties: {
19
+ /** The transcribed text — FTS-indexed so history is searchable. */
20
+ text: text({ required: true }),
21
+ /** Detected/used language (BCP-47-ish, e.g. "en"). */
22
+ language: text({ maxLength: 16 }),
23
+ /** Which engine produced this, e.g. "whisper" | "parakeet" | "apple" | "byo". */
24
+ engineId: text({ maxLength: 120 }),
25
+ /** Which model produced this, e.g. "parakeet-tdt-0.6b-v2". */
26
+ modelId: text({ maxLength: 200 }),
27
+ /** Length of the source audio in milliseconds. */
28
+ durationMs: number({ integer: true, min: 0 }),
29
+ /** How the dictation was triggered. */
30
+ source: select({
31
+ options: [
32
+ { id: "inApp", name: "In-app field" },
33
+ { id: "pushToTalk", name: "Global push-to-talk" }
34
+ ],
35
+ default: "inApp"
36
+ }),
37
+ /**
38
+ * Optional source audio, stored as a content-addressed blob. Off by
39
+ * default — retained only when the user opts into keeping audio.
40
+ */
41
+ audio: file({}),
42
+ /** App / field the text was inserted into (for push-to-talk history). */
43
+ pastedInto: text({ maxLength: 300 }),
44
+ /** Pin a transcript so retention never prunes it. */
45
+ starred: select({
46
+ options: [
47
+ { id: "no", name: "Not starred" },
48
+ { id: "yes", name: "Starred" }
49
+ ],
50
+ default: "no"
51
+ }),
52
+ /** Canonical home; empty = Unfiled (exploration 0169). */
53
+ folder: relation({ target: "xnet://xnet.fyi/Folder@1.0.0" }),
54
+ /** Workspace-wide labels, referenced by id (exploration 0169). */
55
+ tags: relation({ target: "xnet://xnet.fyi/Tag@1.0.0", multiple: true }),
56
+ /** Order among siblings — fractional index. */
57
+ sortKey: text({ maxLength: 500 }),
58
+ /** Canonical SECURITY home; empty = personal/private (exploration 0179). */
59
+ space: relation({ target: "xnet://xnet.fyi/Space@1.0.0" }),
60
+ /**
61
+ * Per-node visibility. Defaults to `private` — a dictation may contain
62
+ * anything, and must never leak to public surfaces by accident (0192).
63
+ */
64
+ visibility: select({
65
+ options: [
66
+ { id: "inherit", name: "Inherit", color: "gray" },
67
+ { id: "private", name: "Private", color: "gray" },
68
+ { id: "unlisted", name: "Unlisted", color: "yellow" },
69
+ { id: "public", name: "Public", color: "green" }
70
+ ],
71
+ default: "private"
72
+ })
73
+ },
74
+ document: void 0,
75
+ // Owner-only by default; inherits access from its home Space when filed into
76
+ // one — same model as Metric, since transcripts are equally sensitive
77
+ // (explorations 0181/0192).
78
+ authorization: spaceCascadeAuthorization()
79
+ });
80
+
81
+ export {
82
+ TRANSCRIPTION_SCHEMA_IRI,
83
+ TranscriptionSchema
84
+ };
@@ -0,0 +1,46 @@
1
+ import {
2
+ defineSchema,
3
+ file,
4
+ number,
5
+ select,
6
+ text
7
+ } from "./chunk-EBNMV2VO.js";
8
+ import {
9
+ presets
10
+ } from "./chunk-RL64OJJ5.js";
11
+
12
+ // src/schema/schemas/media-asset.ts
13
+ var MediaAssetSchema = defineSchema({
14
+ name: "MediaAsset",
15
+ namespace: "xnet://xnet.fyi/",
16
+ properties: {
17
+ /** Display title */
18
+ title: text({ required: true, maxLength: 500 }),
19
+ /** Primary file reference */
20
+ file: file({ required: true }),
21
+ /** Normalized media kind */
22
+ kind: select({
23
+ options: [
24
+ { id: "image", name: "Image" },
25
+ { id: "video", name: "Video" },
26
+ { id: "audio", name: "Audio" },
27
+ { id: "document", name: "Document" },
28
+ { id: "file", name: "File" }
29
+ ],
30
+ default: "file"
31
+ }),
32
+ /** Optional alt text or description */
33
+ alt: text({ maxLength: 2e3 }),
34
+ /** Natural width when known */
35
+ width: number({ integer: true, min: 0 }),
36
+ /** Natural height when known */
37
+ height: number({ integer: true, min: 0 })
38
+ },
39
+ document: void 0,
40
+ // Standalone/personal content: owner-only by default (exploration 0192).
41
+ authorization: presets.private()
42
+ });
43
+
44
+ export {
45
+ MediaAssetSchema
46
+ };