@powersync/nuxt 0.0.0-dev-20260216124709 → 0.0.1
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/dist/module.json
CHANGED
|
@@ -95,68 +95,22 @@
|
|
|
95
95
|
|
|
96
96
|
<span border="b" border-color="gray-100" />
|
|
97
97
|
|
|
98
|
-
<
|
|
99
|
-
<
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
<div
|
|
105
|
-
<
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
<div flex="~ col gap-2">
|
|
110
|
-
<span text="sm gray-500">Rows Synced</span>
|
|
111
|
-
<span text="sm"> {{ totals?.row_count }} </span>
|
|
112
|
-
</div>
|
|
113
|
-
|
|
114
|
-
<div flex="~ col gap-2">
|
|
115
|
-
<span text="sm gray-500">Data size</span>
|
|
116
|
-
<span text="sm">
|
|
117
|
-
{{ totals?.data_size }}
|
|
118
|
-
</span>
|
|
119
|
-
</div>
|
|
120
|
-
|
|
121
|
-
<div flex="~ col gap-2">
|
|
122
|
-
<span text="sm gray-500">Metadata size</span>
|
|
123
|
-
<span text="sm">
|
|
124
|
-
{{ totals?.metadata_size }}
|
|
125
|
-
</span>
|
|
126
|
-
</div>
|
|
127
|
-
|
|
128
|
-
<div flex="~ col gap-2">
|
|
129
|
-
<span text="sm gray-500">Download size</span>
|
|
130
|
-
<span text="sm">
|
|
131
|
-
{{ totals?.download_size }}
|
|
132
|
-
</span>
|
|
133
|
-
</div>
|
|
134
|
-
</div>
|
|
135
|
-
</NSectionBlock>
|
|
136
|
-
|
|
137
|
-
<span border="b" border-color="gray-100" />
|
|
138
|
-
|
|
139
|
-
<NSectionBlock icon="carbon:data-share" text="Operations">
|
|
140
|
-
<NTip v-if="!isDiagnosticSchemaSetup" n="red6 dark:red5" icon="carbon:warning-alt">
|
|
141
|
-
Make sure to extend your schema with the diagnostics schema using the `diagnosticsSchema` from the
|
|
142
|
-
`usePowerSyncInspector` composable.
|
|
143
|
-
</NTip>
|
|
144
|
-
<div v-else grid="~ cols-2 gap-4" mb="4">
|
|
145
|
-
<div flex="~ col gap-2">
|
|
146
|
-
<span text="sm gray-500">Total operations</span>
|
|
147
|
-
<span text="sm">
|
|
148
|
-
{{ totals?.total_operations }}
|
|
149
|
-
</span>
|
|
98
|
+
<template v-for="(section, index) in metricSections" :key="section.text">
|
|
99
|
+
<NSectionBlock :icon="section.icon" :text="section.text">
|
|
100
|
+
<NTip v-if="!isDiagnosticSchemaSetup" n="red6 dark:red5" icon="carbon:warning-alt">
|
|
101
|
+
Make sure to extend your schema with the diagnostics schema using the `diagnosticsSchema` from the
|
|
102
|
+
`usePowerSyncInspector` composable.
|
|
103
|
+
</NTip>
|
|
104
|
+
<div v-else :grid="`~ cols-${section.cols} gap-4`" mb="4">
|
|
105
|
+
<div v-for="metric in section.metrics" :key="metric.label" flex="~ col gap-2">
|
|
106
|
+
<span text="sm gray-500">{{ metric.label }}</span>
|
|
107
|
+
<span text="sm">{{ metric.value }}</span>
|
|
108
|
+
</div>
|
|
150
109
|
</div>
|
|
110
|
+
</NSectionBlock>
|
|
151
111
|
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
<span text="sm">
|
|
155
|
-
{{ totals?.downloaded_operations }}
|
|
156
|
-
</span>
|
|
157
|
-
</div>
|
|
158
|
-
</div>
|
|
159
|
-
</NSectionBlock>
|
|
112
|
+
<span v-if="index < metricSections.length - 1" border="b" border-color="gray-100" />
|
|
113
|
+
</template>
|
|
160
114
|
|
|
161
115
|
<span border="b" border-color="gray-100" />
|
|
162
116
|
</div>
|
|
@@ -165,7 +119,7 @@
|
|
|
165
119
|
|
|
166
120
|
<script setup>
|
|
167
121
|
import { usePowerSyncInspectorDiagnostics } from "#imports";
|
|
168
|
-
import { onMounted } from "vue";
|
|
122
|
+
import { computed, onMounted } from "vue";
|
|
169
123
|
const {
|
|
170
124
|
db,
|
|
171
125
|
isDiagnosticSchemaSetup,
|
|
@@ -178,7 +132,30 @@ const {
|
|
|
178
132
|
uploadQueueSize,
|
|
179
133
|
totals
|
|
180
134
|
} = usePowerSyncInspectorDiagnostics();
|
|
135
|
+
const metricSections = computed(() => [
|
|
136
|
+
{
|
|
137
|
+
icon: "carbon:data-volume",
|
|
138
|
+
text: "Data Size",
|
|
139
|
+
cols: 5,
|
|
140
|
+
metrics: [
|
|
141
|
+
{ label: "Buckets Synced", value: totals.value?.buckets },
|
|
142
|
+
{ label: "Rows Synced", value: totals.value?.row_count },
|
|
143
|
+
{ label: "Data size", value: totals.value?.data_size },
|
|
144
|
+
{ label: "Metadata size", value: totals.value?.metadata_size },
|
|
145
|
+
{ label: "Download size", value: totals.value?.download_size }
|
|
146
|
+
]
|
|
147
|
+
},
|
|
148
|
+
{
|
|
149
|
+
icon: "carbon:data-share",
|
|
150
|
+
text: "Operations",
|
|
151
|
+
cols: 2,
|
|
152
|
+
metrics: [
|
|
153
|
+
{ label: "Total operations", value: totals.value?.total_operations },
|
|
154
|
+
{ label: "Downloaded operations", value: totals.value?.downloaded_operations }
|
|
155
|
+
]
|
|
156
|
+
}
|
|
157
|
+
]);
|
|
181
158
|
onMounted(async () => {
|
|
182
|
-
await db
|
|
159
|
+
await db?.value?.waitForFirstSync();
|
|
183
160
|
});
|
|
184
161
|
</script>
|
|
@@ -4,10 +4,7 @@ export class RecordingStorageAdapter extends SqliteBucketStorage {
|
|
|
4
4
|
schemaManager;
|
|
5
5
|
tables = {};
|
|
6
6
|
constructor(db, schemaManager) {
|
|
7
|
-
super(
|
|
8
|
-
db.value.database,
|
|
9
|
-
AbstractPowerSyncDatabase.transactionMutex
|
|
10
|
-
);
|
|
7
|
+
super(db.value.database, AbstractPowerSyncDatabase.transactionMutex);
|
|
11
8
|
this.rdb = db.value.database;
|
|
12
9
|
this.schemaManager = schemaManager.value;
|
|
13
10
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@powersync/nuxt",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.1",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"registry": "https://registry.npmjs.org/",
|
|
6
6
|
"access": "public"
|
|
@@ -52,9 +52,9 @@
|
|
|
52
52
|
},
|
|
53
53
|
"peerDependencies": {
|
|
54
54
|
"@journeyapps/wa-sqlite": "^1.2.6",
|
|
55
|
-
"@powersync/kysely-driver": "
|
|
56
|
-
"@powersync/vue": "0.
|
|
57
|
-
"@powersync/web": "
|
|
55
|
+
"@powersync/kysely-driver": "1.3.3",
|
|
56
|
+
"@powersync/vue": "0.4.2",
|
|
57
|
+
"@powersync/web": "1.34.0"
|
|
58
58
|
},
|
|
59
59
|
"peerDependenciesMeta": {
|
|
60
60
|
"@powersync/kysely-driver": {
|
|
@@ -73,9 +73,9 @@
|
|
|
73
73
|
"vitest": "^3.2.4",
|
|
74
74
|
"vue": "^3.5.20",
|
|
75
75
|
"vue-tsc": "^3.0.8",
|
|
76
|
-
"@powersync/kysely-driver": "
|
|
77
|
-
"@powersync/
|
|
78
|
-
"@powersync/
|
|
76
|
+
"@powersync/kysely-driver": "1.3.3",
|
|
77
|
+
"@powersync/web": "1.34.0",
|
|
78
|
+
"@powersync/vue": "0.4.2"
|
|
79
79
|
},
|
|
80
80
|
"scripts": {
|
|
81
81
|
"prebuild": "nuxt-module-build prepare",
|
/package/{README → README.md}
RENAMED
|
File without changes
|