@rozenite/storage-plugin 2.1.0 → 2.3.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 +34 -0
- package/dist/devtools/assets/panel-CcThj-0Z.js +32 -0
- package/dist/devtools/assets/panel-DTYbHqnH.css +1 -0
- package/dist/devtools/panel.html +2 -2
- package/dist/react-native/cjs/package.json +3 -0
- package/dist/react-native/cjs/react-native.js +38 -0
- package/dist/react-native/cjs/src/react-native/adapters/async-storage.js +60 -0
- package/dist/react-native/cjs/src/react-native/adapters/index.js +10 -0
- package/dist/react-native/cjs/src/react-native/adapters/mmkv.js +143 -0
- package/dist/react-native/cjs/src/react-native/adapters/secure-storage.js +51 -0
- package/dist/react-native/cjs/src/react-native/entry-preview-pagination.js +198 -0
- package/dist/react-native/cjs/src/react-native/export-snapshot.js +70 -0
- package/dist/react-native/cjs/src/react-native/full-entry-request.js +72 -0
- package/dist/react-native/cjs/src/react-native/import.js +185 -0
- package/dist/react-native/cjs/src/react-native/storage-discovery.js +69 -0
- package/dist/react-native/cjs/src/react-native/storage-view.js +128 -0
- package/dist/react-native/cjs/src/react-native/useRozeniteStoragePlugin.js +145 -0
- package/dist/react-native/cjs/src/react-native/useStorageAgentTools.js +228 -0
- package/dist/react-native/cjs/src/shared/agent-tools.js +119 -0
- package/dist/react-native/cjs/src/shared/entry-preview.js +48 -0
- package/dist/react-native/cjs/src/shared/messaging.js +2 -0
- package/dist/react-native/cjs/src/shared/snapshot.js +185 -0
- package/dist/react-native/cjs/src/shared/types.js +13 -0
- package/dist/react-native/package.json +3 -0
- package/dist/react-native/react-native.d.ts +7 -0
- package/dist/react-native/react-native.js +40 -0
- package/dist/react-native/src/react-native/adapters/async-storage.d.ts +34 -0
- package/dist/react-native/src/react-native/adapters/async-storage.js +56 -0
- package/dist/react-native/src/react-native/adapters/index.d.ts +6 -0
- package/dist/react-native/src/react-native/adapters/index.js +3 -0
- package/dist/react-native/src/react-native/adapters/mmkv.d.ts +13 -0
- package/dist/react-native/src/react-native/adapters/mmkv.js +139 -0
- package/dist/react-native/src/react-native/adapters/secure-storage.d.ts +18 -0
- package/dist/react-native/src/react-native/adapters/secure-storage.js +47 -0
- package/dist/react-native/src/react-native/entry-preview-pagination.d.ts +7 -0
- package/dist/react-native/src/react-native/entry-preview-pagination.js +194 -0
- package/dist/react-native/src/react-native/export-snapshot.d.ts +5 -0
- package/dist/react-native/src/react-native/export-snapshot.js +66 -0
- package/dist/react-native/src/react-native/full-entry-request.d.ts +5 -0
- package/dist/react-native/src/react-native/full-entry-request.js +68 -0
- package/dist/react-native/src/react-native/import.d.ts +7 -0
- package/dist/react-native/src/react-native/import.js +180 -0
- package/dist/react-native/src/react-native/storage-discovery.d.ts +5 -0
- package/dist/react-native/src/react-native/storage-discovery.js +65 -0
- package/dist/react-native/src/react-native/storage-view.d.ts +19 -0
- package/dist/react-native/src/react-native/storage-view.js +123 -0
- package/dist/react-native/src/react-native/useRozeniteStoragePlugin.d.ts +6 -0
- package/dist/react-native/src/react-native/useRozeniteStoragePlugin.js +141 -0
- package/dist/react-native/src/react-native/useStorageAgentTools.d.ts +37 -0
- package/dist/react-native/src/react-native/useStorageAgentTools.js +223 -0
- package/dist/react-native/src/shared/agent-tools.d.ts +76 -0
- package/dist/react-native/src/shared/agent-tools.js +116 -0
- package/dist/react-native/src/shared/entry-preview.d.ts +4 -0
- package/dist/react-native/src/shared/entry-preview.js +44 -0
- package/dist/react-native/src/shared/messaging.d.ts +134 -0
- package/dist/react-native/src/shared/messaging.js +1 -0
- package/dist/react-native/src/shared/snapshot.d.ts +53 -0
- package/dist/react-native/src/shared/snapshot.js +179 -0
- package/dist/react-native/src/shared/types.d.ts +78 -0
- package/dist/react-native/src/shared/types.js +8 -0
- package/dist/rozenite.json +1 -1
- package/dist/sdk/package.json +3 -0
- package/dist/sdk/sdk.d.ts +44 -0
- package/dist/sdk/sdk.js +9 -0
- package/dist/sdk/src/shared/agent-tools.d.ts +76 -0
- package/dist/sdk/src/shared/agent-tools.js +119 -0
- package/dist/sdk/src/shared/types.d.ts +78 -0
- package/dist/sdk/src/shared/types.js +13 -0
- package/package.json +16 -16
- package/react-native.ts +8 -1
- package/rozenite.config.ts +1 -0
- package/src/__tests__/release-bundle.test.ts +32 -0
- package/src/ui/__tests__/panel.test.tsx +14 -0
- package/src/ui/add-entry-dialog.tsx +63 -73
- package/src/ui/binary-value-editor.tsx +1 -1
- package/src/ui/edit-entry-dialog.tsx +59 -70
- package/src/ui/entry-detail-dialog.tsx +4 -2
- package/src/ui/format-value.tsx +1 -1
- package/src/ui/import-dialog.tsx +5 -5
- package/src/ui/panel.tsx +70 -88
- package/tsconfig.json +4 -7
- package/dist/devtools/assets/panel-BlDRXgVW.js +0 -32
- package/dist/devtools/assets/panel-DBweZnW5.css +0 -1
- package/dist/react-native/chunks/async-storage.require.cjs +0 -1
- package/dist/react-native/chunks/async-storage.require.js +0 -53
- package/dist/react-native/chunks/index.require.cjs +0 -1
- package/dist/react-native/chunks/index.require.js +0 -103
- package/dist/react-native/chunks/secure-storage.require.cjs +0 -1
- package/dist/react-native/chunks/secure-storage.require.js +0 -46
- package/dist/react-native/chunks/types.cjs +0 -1
- package/dist/react-native/chunks/types.js +0 -11
- package/dist/react-native/chunks/useRozeniteStoragePlugin.require.cjs +0 -1
- package/dist/react-native/chunks/useRozeniteStoragePlugin.require.js +0 -1037
- package/dist/react-native/index.cjs +0 -1
- package/dist/react-native/index.d.ts +0 -365
- package/dist/react-native/index.js +0 -28
- package/dist/sdk/index.cjs +0 -1
- package/dist/sdk/index.d.ts +0 -206
- package/dist/sdk/index.js +0 -122
package/dist/sdk/index.js
DELETED
|
@@ -1,122 +0,0 @@
|
|
|
1
|
-
import { defineAgentToolContract as e, definePaginatedAgentToolContract as i, defineAgentToolDescriptors as n } from "@rozenite/agent-shared";
|
|
2
|
-
const t = {
|
|
3
|
-
adapterId: {
|
|
4
|
-
type: "string",
|
|
5
|
-
description: "Storage adapter ID. Required when multiple adapters are configured."
|
|
6
|
-
},
|
|
7
|
-
storageId: {
|
|
8
|
-
type: "string",
|
|
9
|
-
description: "Storage node ID within the adapter. Required when multiple storages are configured."
|
|
10
|
-
}
|
|
11
|
-
}, o = "@rozenite/storage-plugin", r = [
|
|
12
|
-
"string",
|
|
13
|
-
"number",
|
|
14
|
-
"boolean",
|
|
15
|
-
"buffer"
|
|
16
|
-
], s = {
|
|
17
|
-
listStorages: e({
|
|
18
|
-
name: "list-storages",
|
|
19
|
-
description: "List all storage adapters and their storage nodes currently available on the device, including supported entry types. Entry counts are omitted to avoid enumerating every storage.",
|
|
20
|
-
inputSchema: { type: "object", properties: {} }
|
|
21
|
-
}),
|
|
22
|
-
listEntries: i({
|
|
23
|
-
name: "list-entries",
|
|
24
|
-
description: "List keys in a storage. This call intentionally does not return entry values to keep responses token-efficient.",
|
|
25
|
-
inputSchema: {
|
|
26
|
-
type: "object",
|
|
27
|
-
properties: {
|
|
28
|
-
...t,
|
|
29
|
-
limit: {
|
|
30
|
-
type: "number",
|
|
31
|
-
description: "Pagination size. Defaults to 20 and is capped at 100."
|
|
32
|
-
},
|
|
33
|
-
cursor: {
|
|
34
|
-
type: "string",
|
|
35
|
-
description: "Opaque pagination cursor from a previous list-entries call."
|
|
36
|
-
},
|
|
37
|
-
offset: {
|
|
38
|
-
type: "number",
|
|
39
|
-
description: "Deprecated initial pagination offset. Must be a non-negative integer and cannot be combined with cursor."
|
|
40
|
-
}
|
|
41
|
-
}
|
|
42
|
-
},
|
|
43
|
-
pagination: {
|
|
44
|
-
kind: "cursor",
|
|
45
|
-
fields: ["key"],
|
|
46
|
-
defaultFields: ["key"]
|
|
47
|
-
}
|
|
48
|
-
}),
|
|
49
|
-
readEntry: e({
|
|
50
|
-
name: "read-entry",
|
|
51
|
-
description: "Read a single storage entry value by key.",
|
|
52
|
-
inputSchema: {
|
|
53
|
-
type: "object",
|
|
54
|
-
properties: {
|
|
55
|
-
...t,
|
|
56
|
-
key: { type: "string", description: "Entry key." }
|
|
57
|
-
},
|
|
58
|
-
required: ["key"]
|
|
59
|
-
}
|
|
60
|
-
}),
|
|
61
|
-
createEntry: e({
|
|
62
|
-
name: "create-entry",
|
|
63
|
-
description: "Create a new storage entry. Fails if the key already exists.",
|
|
64
|
-
inputSchema: {
|
|
65
|
-
type: "object",
|
|
66
|
-
properties: {
|
|
67
|
-
...t,
|
|
68
|
-
key: { type: "string", description: "Entry key." },
|
|
69
|
-
type: {
|
|
70
|
-
type: "string",
|
|
71
|
-
enum: [...r],
|
|
72
|
-
description: "Entry value type. Must be one of the supported types for the target storage (see list-storages)."
|
|
73
|
-
},
|
|
74
|
-
value: {
|
|
75
|
-
description: "Entry value matching the provided type."
|
|
76
|
-
}
|
|
77
|
-
},
|
|
78
|
-
required: ["key", "type", "value"]
|
|
79
|
-
}
|
|
80
|
-
}),
|
|
81
|
-
editEntry: e({
|
|
82
|
-
name: "edit-entry",
|
|
83
|
-
description: "Edit an existing storage entry. Fails if the key does not exist.",
|
|
84
|
-
inputSchema: {
|
|
85
|
-
type: "object",
|
|
86
|
-
properties: {
|
|
87
|
-
...t,
|
|
88
|
-
key: { type: "string", description: "Entry key." },
|
|
89
|
-
type: {
|
|
90
|
-
type: "string",
|
|
91
|
-
enum: [...r],
|
|
92
|
-
description: "Entry value type. Must be one of the supported types for the target storage (see list-storages)."
|
|
93
|
-
},
|
|
94
|
-
value: {
|
|
95
|
-
description: "Entry value matching the provided type."
|
|
96
|
-
}
|
|
97
|
-
},
|
|
98
|
-
required: ["key", "type", "value"]
|
|
99
|
-
}
|
|
100
|
-
}),
|
|
101
|
-
removeEntry: e({
|
|
102
|
-
name: "remove-entry",
|
|
103
|
-
description: "Remove a storage entry by key.",
|
|
104
|
-
inputSchema: {
|
|
105
|
-
type: "object",
|
|
106
|
-
properties: {
|
|
107
|
-
...t,
|
|
108
|
-
key: { type: "string", description: "Entry key." }
|
|
109
|
-
},
|
|
110
|
-
required: ["key"]
|
|
111
|
-
}
|
|
112
|
-
})
|
|
113
|
-
}, p = n(
|
|
114
|
-
o,
|
|
115
|
-
s
|
|
116
|
-
);
|
|
117
|
-
export {
|
|
118
|
-
r as STORAGE_AGENT_ENTRY_TYPES,
|
|
119
|
-
o as STORAGE_AGENT_PLUGIN_ID,
|
|
120
|
-
s as storageToolDefinitions,
|
|
121
|
-
p as storageTools
|
|
122
|
-
};
|