@lensjs/core 1.0.6 → 1.0.8

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 (60) hide show
  1. package/dist/abstracts/adapter.cjs +3 -3
  2. package/dist/abstracts/adapter.js +2 -2
  3. package/dist/{chunk-AUDSBNLF.cjs → chunk-45JBO7ME.cjs} +2 -4
  4. package/dist/chunk-66RDYK2I.js +9 -0
  5. package/dist/{chunk-WU6IZUEV.cjs → chunk-7FBZAVQ3.cjs} +4 -25
  6. package/dist/{chunk-BFFOUTTE.cjs → chunk-7MOTQS6N.cjs} +2 -2
  7. package/dist/{chunk-FCMQ3WE3.cjs → chunk-CGPET47D.cjs} +4 -4
  8. package/dist/{chunk-IPMTMCFP.js → chunk-HLBMQ3ID.js} +1 -3
  9. package/dist/{chunk-5PYQWLAZ.js → chunk-HMBQ2DF7.js} +2 -2
  10. package/dist/{chunk-TPUVRGYT.js → chunk-JTRKNE5Q.js} +1 -1
  11. package/dist/{chunk-3R5QARPT.cjs → chunk-NUSVID2Q.cjs} +1 -6
  12. package/dist/{chunk-EJ5BW35V.js → chunk-YXSPADWE.js} +1 -22
  13. package/dist/core/lens.cjs +4 -4
  14. package/dist/core/lens.js +3 -3
  15. package/dist/{index-D0Vszdac.d.cts → index-DiLfwsvc.d.cts} +2 -11
  16. package/dist/{index-D0Vszdac.d.ts → index-DiLfwsvc.d.ts} +2 -11
  17. package/dist/index.cjs +6 -10
  18. package/dist/index.d.cts +2 -4
  19. package/dist/index.d.ts +2 -4
  20. package/dist/index.js +6 -10
  21. package/dist/stores/better_sqlite.cjs +2 -3
  22. package/dist/stores/better_sqlite.js +1 -2
  23. package/dist/stores/index.cjs +2 -3
  24. package/dist/stores/index.js +1 -2
  25. package/dist/ui/assets/QueriesContainer-DhnU1ndx.js +2 -0
  26. package/dist/ui/assets/{QueryDetailsContainer-BAT2wB5L.js → QueryDetailsContainer-CtNxjUvF.js} +17 -17
  27. package/dist/ui/assets/QueryTable-B6L0F5jL.js +1 -0
  28. package/dist/ui/assets/RequestDetails-BfxFQmp1.js +1 -0
  29. package/dist/ui/assets/RequestDetailsContainer-C0s7VLpw.js +2 -0
  30. package/dist/ui/assets/{RequestsContainer-C1EP5an3.js → RequestsContainer-rWbSc4Py.js} +2 -2
  31. package/dist/ui/assets/RequetsTable-D2qBWqFN.js +1 -0
  32. package/dist/ui/assets/{StatusCode-BWWAporK.js → StatusCode-BZGwjlgz.js} +1 -1
  33. package/dist/ui/assets/{TabbedDataViewer-EN6cPPrM.js → TabbedDataViewer-CmztxF70.js} +1 -1
  34. package/dist/ui/assets/{Table-4XTvSMgl.js → Table-DF4sxTNg.js} +2 -2
  35. package/dist/ui/assets/index-DzNHqeKh.css +1 -0
  36. package/dist/ui/assets/index-Dzy6B_ZD.js +114 -0
  37. package/dist/ui/assets/index-byVaIWe8.js +1 -0
  38. package/dist/ui/assets/{useLensApi-B_mHSSRc.js → useLensApi-CkgX8mtY.js} +1 -1
  39. package/dist/ui/assets/{useLoadMore-Dq8oeHnX.js → useLoadMore-BRca6vvh.js} +1 -1
  40. package/dist/ui/assets/{useQueries-SgNjl9M_.js → useQueries-CVt1cLYV.js} +1 -1
  41. package/dist/ui/index.html +2 -2
  42. package/dist/utils/event_emitter.cjs +2 -6
  43. package/dist/utils/event_emitter.d.cts +1 -11
  44. package/dist/utils/event_emitter.d.ts +1 -11
  45. package/dist/utils/event_emitter.js +3 -7
  46. package/dist/utils/index.cjs +2 -10
  47. package/dist/utils/index.d.cts +1 -2
  48. package/dist/utils/index.d.ts +1 -2
  49. package/dist/utils/index.js +1 -9
  50. package/package.json +18 -18
  51. package/README.md +0 -1
  52. package/dist/chunk-RMZ4UAQ2.js +0 -14
  53. package/dist/ui/assets/QueriesContainer-BCIu2qYI.js +0 -2
  54. package/dist/ui/assets/QueryTable-QMHnJtqC.js +0 -1
  55. package/dist/ui/assets/RequestDetails-tHepW82n.js +0 -1
  56. package/dist/ui/assets/RequestDetailsContainer-BgqtcO2z.js +0 -2
  57. package/dist/ui/assets/RequetsTable-CPE6Q8n4.js +0 -1
  58. package/dist/ui/assets/date-D4hQ6oAL.js +0 -1
  59. package/dist/ui/assets/index-BZL6Xmfs.js +0 -114
  60. package/dist/ui/assets/index-C4Vyfz2T.css +0 -1
@@ -1,8 +1,8 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
2
 
3
- var _chunkBFFOUTTEcjs = require('../chunk-BFFOUTTE.cjs');
4
- require('../chunk-WU6IZUEV.cjs');
3
+ var _chunk7MOTQS6Ncjs = require('../chunk-7MOTQS6N.cjs');
4
+ require('../chunk-7FBZAVQ3.cjs');
5
5
  require('../chunk-75ZPJI57.cjs');
6
6
 
7
7
 
8
- exports.default = _chunkBFFOUTTEcjs.Adapter;
8
+ exports.default = _chunk7MOTQS6Ncjs.Adapter;
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  Adapter
3
- } from "../chunk-TPUVRGYT.js";
4
- import "../chunk-EJ5BW35V.js";
3
+ } from "../chunk-JTRKNE5Q.js";
4
+ import "../chunk-YXSPADWE.js";
5
5
  import "../chunk-MLKGABMK.js";
6
6
  export {
7
7
  Adapter as default
@@ -1,13 +1,11 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } }
2
2
 
3
- var _chunkWU6IZUEVcjs = require('./chunk-WU6IZUEV.cjs');
4
-
5
-
6
3
  var _chunkEHOWCXZVcjs = require('./chunk-EHOWCXZV.cjs');
7
4
 
8
5
  // src/stores/better_sqlite.ts
9
6
  var _crypto = require('crypto');
10
7
  var _libsql = require('libsql'); var _libsql2 = _interopRequireDefault(_libsql);
8
+ var _date = require('@repo/date');
11
9
  var TABLE_NAME = "lens_entries";
12
10
  var BetterSqliteStore = class extends _chunkEHOWCXZVcjs.Store {
13
11
 
@@ -26,7 +24,7 @@ var BetterSqliteStore = class extends _chunkEHOWCXZVcjs.Store {
26
24
  id: _nullishCoalesce(entry.id, () => ( _crypto.randomUUID.call(void 0, ))),
27
25
  data: JSON.stringify(entry.data),
28
26
  type: entry.type,
29
- created_at: _nullishCoalesce(entry.timestamp, () => ( _chunkWU6IZUEVcjs.sqlDateTime.call(void 0, ))),
27
+ created_at: _nullishCoalesce(entry.timestamp, () => ( _date.sqlDateTime.call(void 0, ))),
30
28
  lens_entry_id: entry.requestId || null,
31
29
  minimalData: JSON.stringify(_nullishCoalesce(entry.minimal_data, () => ( {})))
32
30
  });
@@ -0,0 +1,9 @@
1
+ // src/utils/event_emitter.ts
2
+ import Emittery from "emittery";
3
+ var createEmittery = () => {
4
+ return new Emittery();
5
+ };
6
+
7
+ export {
8
+ createEmittery
9
+ };
@@ -1,29 +1,25 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } }
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { newObj[key] = obj[key]; } } } newObj.default = obj; return newObj; } }
2
2
 
3
3
  var _chunk75ZPJI57cjs = require('./chunk-75ZPJI57.cjs');
4
4
 
5
5
  // src/utils/index.ts
6
6
  var utils_exports = {};
7
7
  _chunk75ZPJI57cjs.__export.call(void 0, utils_exports, {
8
- convertToUTC: () => convertToUTC,
9
8
  formatSqlQuery: () => formatSqlQuery,
10
9
  generateRandomUuid: () => generateRandomUuid,
11
10
  getMeta: () => getMeta,
12
11
  interpolateQuery: () => interpolateQuery,
13
12
  isStaticFile: () => isStaticFile,
14
- now: () => now,
15
- nowISO: () => nowISO,
16
13
  prepareIgnoredPaths: () => prepareIgnoredPaths,
17
14
  prettyHrTime: () => prettyHrTime,
18
15
  shouldIgnoreCurrentPath: () => shouldIgnoreCurrentPath,
19
- sqlDateTime: () => sqlDateTime,
20
16
  stripBeforeAssetsPath: () => stripBeforeAssetsPath
21
17
  });
22
18
  var _luxon = require('luxon');
23
19
  var _sqlformatter = require('sql-formatter');
24
20
  var _crypto = require('crypto');
25
21
  var _url = require('url');
26
- var _posix = require('path/posix'); var _posix2 = _interopRequireDefault(_posix);
22
+ var _path = require('path'); var path = _interopRequireWildcard(_path);
27
23
  var generateRandomUuid = () => {
28
24
  return _crypto.randomUUID.call(void 0, );
29
25
  };
@@ -71,19 +67,6 @@ var formatSqlQuery = (query, language) => {
71
67
  functionCase: "upper"
72
68
  });
73
69
  };
74
- function now() {
75
- return _luxon.DateTime.now().setZone("utc");
76
- }
77
- function nowISO() {
78
- return now().toISO({ includeOffset: false });
79
- }
80
- function sqlDateTime(dateTime) {
81
- const time = _nullishCoalesce(dateTime, () => ( now()));
82
- return time.toSQL({ includeOffset: false });
83
- }
84
- function convertToUTC(dateTime) {
85
- return _luxon.DateTime.fromISO(dateTime).setZone("utc").toISO({ includeOffset: false });
86
- }
87
70
  function getMeta(metaUrl) {
88
71
  const isESM = typeof __dirname === "undefined";
89
72
  if (isESM) {
@@ -91,7 +74,7 @@ function getMeta(metaUrl) {
91
74
  throw new Error("In ESM, you must pass import.meta.url to getMeta()");
92
75
  }
93
76
  const __filename2 = _url.fileURLToPath.call(void 0, metaUrl);
94
- const __dirname2 = _posix2.default.dirname(__filename2);
77
+ const __dirname2 = path.dirname(__filename2);
95
78
  return { __filename: __filename2, __dirname: __dirname2 };
96
79
  } else {
97
80
  return { __filename, __dirname };
@@ -152,8 +135,4 @@ function prettyHrTime(hrtime, verbose = false) {
152
135
 
153
136
 
154
137
 
155
-
156
-
157
-
158
-
159
- exports.generateRandomUuid = generateRandomUuid; exports.interpolateQuery = interpolateQuery; exports.formatSqlQuery = formatSqlQuery; exports.now = now; exports.nowISO = nowISO; exports.sqlDateTime = sqlDateTime; exports.convertToUTC = convertToUTC; exports.getMeta = getMeta; exports.isStaticFile = isStaticFile; exports.stripBeforeAssetsPath = stripBeforeAssetsPath; exports.prepareIgnoredPaths = prepareIgnoredPaths; exports.shouldIgnoreCurrentPath = shouldIgnoreCurrentPath; exports.prettyHrTime = prettyHrTime; exports.utils_exports = utils_exports;
138
+ exports.generateRandomUuid = generateRandomUuid; exports.interpolateQuery = interpolateQuery; exports.formatSqlQuery = formatSqlQuery; exports.getMeta = getMeta; exports.isStaticFile = isStaticFile; exports.stripBeforeAssetsPath = stripBeforeAssetsPath; exports.prepareIgnoredPaths = prepareIgnoredPaths; exports.shouldIgnoreCurrentPath = shouldIgnoreCurrentPath; exports.prettyHrTime = prettyHrTime; exports.utils_exports = utils_exports;
@@ -1,6 +1,6 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true}); var _class;
2
2
 
3
- var _chunkWU6IZUEVcjs = require('./chunk-WU6IZUEV.cjs');
3
+ var _chunk7FBZAVQ3cjs = require('./chunk-7FBZAVQ3.cjs');
4
4
 
5
5
  // src/abstracts/adapter.ts
6
6
  var Adapter = (_class = class {constructor() { _class.prototype.__init.call(this);_class.prototype.__init2.call(this);_class.prototype.__init3.call(this); }
@@ -23,7 +23,7 @@ var Adapter = (_class = class {constructor() { _class.prototype.__init.call(this
23
23
  return this.watchers;
24
24
  }
25
25
  shouldIgnorePath(path) {
26
- return _chunkWU6IZUEVcjs.shouldIgnoreCurrentPath.call(void 0, path, this.ignoredPaths, this.onlyPaths);
26
+ return _chunk7FBZAVQ3cjs.shouldIgnoreCurrentPath.call(void 0, path, this.ignoredPaths, this.onlyPaths);
27
27
  }
28
28
  }, _class);
29
29
 
@@ -1,9 +1,9 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { newObj[key] = obj[key]; } } } newObj.default = obj; return newObj; } } async function _asyncNullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return await rhsFn(); } } var _class;
2
2
 
3
- var _chunkAUDSBNLFcjs = require('./chunk-AUDSBNLF.cjs');
3
+ var _chunk45JBO7MEcjs = require('./chunk-45JBO7ME.cjs');
4
4
 
5
5
 
6
- var _chunkWU6IZUEVcjs = require('./chunk-WU6IZUEV.cjs');
6
+ var _chunk7FBZAVQ3cjs = require('./chunk-7FBZAVQ3.cjs');
7
7
 
8
8
 
9
9
  var _chunkJZ2JLQXLcjs = require('./chunk-JZ2JLQXL.cjs');
@@ -43,7 +43,7 @@ var Lens = (_class = class {
43
43
  basePath: config.basePath
44
44
  });
45
45
  adapter.registerRoutes(apiRoutes);
46
- const { __dirname } = _chunkWU6IZUEVcjs.getMeta.call(void 0, import.meta.url);
46
+ const { __dirname } = _chunk7FBZAVQ3cjs.getMeta.call(void 0, import.meta.url);
47
47
  const uiPath = path.resolve(this.normalizeDirName(__dirname), "ui");
48
48
  adapter.serveUI(uiPath, config.basePath, _chunkQRZUNYF6cjs.getUiConfig.call(void 0, ));
49
49
  }
@@ -115,7 +115,7 @@ var Lens = (_class = class {
115
115
  return { apiRoutes };
116
116
  }
117
117
  static async getDefaultStore() {
118
- const store = new (0, _chunkAUDSBNLFcjs.BetterSqliteStore)();
118
+ const store = new (0, _chunk45JBO7MEcjs.BetterSqliteStore)();
119
119
  await store.initialize();
120
120
  return store;
121
121
  }
@@ -1,6 +1,3 @@
1
- import {
2
- sqlDateTime
3
- } from "./chunk-EJ5BW35V.js";
4
1
  import {
5
2
  Store
6
3
  } from "./chunk-FKMBNWX4.js";
@@ -8,6 +5,7 @@ import {
8
5
  // src/stores/better_sqlite.ts
9
6
  import { randomUUID } from "crypto";
10
7
  import Database from "libsql";
8
+ import { sqlDateTime } from "@repo/date";
11
9
  var TABLE_NAME = "lens_entries";
12
10
  var BetterSqliteStore = class extends Store {
13
11
  connection;
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  BetterSqliteStore
3
- } from "./chunk-IPMTMCFP.js";
3
+ } from "./chunk-HLBMQ3ID.js";
4
4
  import {
5
5
  getMeta
6
- } from "./chunk-EJ5BW35V.js";
6
+ } from "./chunk-YXSPADWE.js";
7
7
  import {
8
8
  ApiController
9
9
  } from "./chunk-TJDE6AZM.js";
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  shouldIgnoreCurrentPath
3
- } from "./chunk-EJ5BW35V.js";
3
+ } from "./chunk-YXSPADWE.js";
4
4
 
5
5
  // src/abstracts/adapter.ts
6
6
  var Adapter = class {
@@ -1,14 +1,9 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }// src/utils/event_emitter.ts
2
- var _async_hooks = require('async_hooks');
3
2
  var _emittery = require('emittery'); var _emittery2 = _interopRequireDefault(_emittery);
4
3
  var createEmittery = () => {
5
4
  return new (0, _emittery2.default)();
6
5
  };
7
- var lensResource = new (0, _async_hooks.AsyncResource)("lens-emitter");
8
- var lensEmitter = new (0, _emittery2.default)();
9
6
 
10
7
 
11
8
 
12
-
13
-
14
- exports.createEmittery = createEmittery; exports.lensResource = lensResource; exports.lensEmitter = lensEmitter;
9
+ exports.createEmittery = createEmittery;
@@ -5,25 +5,21 @@ import {
5
5
  // src/utils/index.ts
6
6
  var utils_exports = {};
7
7
  __export(utils_exports, {
8
- convertToUTC: () => convertToUTC,
9
8
  formatSqlQuery: () => formatSqlQuery,
10
9
  generateRandomUuid: () => generateRandomUuid,
11
10
  getMeta: () => getMeta,
12
11
  interpolateQuery: () => interpolateQuery,
13
12
  isStaticFile: () => isStaticFile,
14
- now: () => now,
15
- nowISO: () => nowISO,
16
13
  prepareIgnoredPaths: () => prepareIgnoredPaths,
17
14
  prettyHrTime: () => prettyHrTime,
18
15
  shouldIgnoreCurrentPath: () => shouldIgnoreCurrentPath,
19
- sqlDateTime: () => sqlDateTime,
20
16
  stripBeforeAssetsPath: () => stripBeforeAssetsPath
21
17
  });
22
18
  import { DateTime } from "luxon";
23
19
  import { format } from "sql-formatter";
24
20
  import { randomUUID } from "crypto";
25
21
  import { fileURLToPath } from "url";
26
- import path from "path/posix";
22
+ import * as path from "path";
27
23
  var generateRandomUuid = () => {
28
24
  return randomUUID();
29
25
  };
@@ -71,19 +67,6 @@ var formatSqlQuery = (query, language) => {
71
67
  functionCase: "upper"
72
68
  });
73
69
  };
74
- function now() {
75
- return DateTime.now().setZone("utc");
76
- }
77
- function nowISO() {
78
- return now().toISO({ includeOffset: false });
79
- }
80
- function sqlDateTime(dateTime) {
81
- const time = dateTime ?? now();
82
- return time.toSQL({ includeOffset: false });
83
- }
84
- function convertToUTC(dateTime) {
85
- return DateTime.fromISO(dateTime).setZone("utc").toISO({ includeOffset: false });
86
- }
87
70
  function getMeta(metaUrl) {
88
71
  const isESM = typeof __dirname === "undefined";
89
72
  if (isESM) {
@@ -145,10 +128,6 @@ export {
145
128
  generateRandomUuid,
146
129
  interpolateQuery,
147
130
  formatSqlQuery,
148
- now,
149
- nowISO,
150
- sqlDateTime,
151
- convertToUTC,
152
131
  getMeta,
153
132
  isStaticFile,
154
133
  stripBeforeAssetsPath,
@@ -1,9 +1,9 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
2
 
3
- var _chunkFCMQ3WE3cjs = require('../chunk-FCMQ3WE3.cjs');
3
+ var _chunkCGPET47Dcjs = require('../chunk-CGPET47D.cjs');
4
4
  require('../chunk-XZFXXD3A.cjs');
5
- require('../chunk-AUDSBNLF.cjs');
6
- require('../chunk-WU6IZUEV.cjs');
5
+ require('../chunk-45JBO7ME.cjs');
6
+ require('../chunk-7FBZAVQ3.cjs');
7
7
  require('../chunk-EHOWCXZV.cjs');
8
8
  require('../chunk-JZ2JLQXL.cjs');
9
9
  require('../chunk-2HRVJRKV.cjs');
@@ -12,4 +12,4 @@ require('../chunk-GI7SJDNQ.cjs');
12
12
  require('../chunk-75ZPJI57.cjs');
13
13
 
14
14
 
15
- exports.default = _chunkFCMQ3WE3cjs.Lens;
15
+ exports.default = _chunkCGPET47Dcjs.Lens;
package/dist/core/lens.js CHANGED
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  Lens
3
- } from "../chunk-5PYQWLAZ.js";
3
+ } from "../chunk-HMBQ2DF7.js";
4
4
  import "../chunk-VD5IMUWL.js";
5
- import "../chunk-IPMTMCFP.js";
6
- import "../chunk-EJ5BW35V.js";
5
+ import "../chunk-HLBMQ3ID.js";
6
+ import "../chunk-YXSPADWE.js";
7
7
  import "../chunk-FKMBNWX4.js";
8
8
  import "../chunk-TJDE6AZM.js";
9
9
  import "../chunk-FLOVBBFU.js";
@@ -1,4 +1,3 @@
1
- import { DateTime } from 'luxon';
2
1
  import { SqlLanguage } from 'sql-formatter';
3
2
 
4
3
  declare const generateRandomUuid: () => `${string}-${string}-${string}-${string}-${string}`;
@@ -12,10 +11,6 @@ type Bindings = any[] | Record<string, any>;
12
11
  */
13
12
  declare function interpolateQuery(query: string, bindings: Bindings): string;
14
13
  declare const formatSqlQuery: (query: string, language: SqlLanguage) => string;
15
- declare function now(): DateTime<true> | DateTime<false>;
16
- declare function nowISO(): string;
17
- declare function sqlDateTime(dateTime?: DateTime | null): string | null;
18
- declare function convertToUTC(dateTime: string): string;
19
14
  declare function getMeta(metaUrl?: string): {
20
15
  __filename: string;
21
16
  __dirname: string;
@@ -29,21 +24,17 @@ declare function prepareIgnoredPaths(path: string, ignoredPaths: RegExp[]): {
29
24
  declare function shouldIgnoreCurrentPath(path: string, ignoredPaths: RegExp[], onlyPaths: RegExp[]): boolean;
30
25
  declare function prettyHrTime(hrtime: [number, number], verbose?: boolean): string;
31
26
 
32
- declare const index_convertToUTC: typeof convertToUTC;
33
27
  declare const index_formatSqlQuery: typeof formatSqlQuery;
34
28
  declare const index_generateRandomUuid: typeof generateRandomUuid;
35
29
  declare const index_getMeta: typeof getMeta;
36
30
  declare const index_interpolateQuery: typeof interpolateQuery;
37
31
  declare const index_isStaticFile: typeof isStaticFile;
38
- declare const index_now: typeof now;
39
- declare const index_nowISO: typeof nowISO;
40
32
  declare const index_prepareIgnoredPaths: typeof prepareIgnoredPaths;
41
33
  declare const index_prettyHrTime: typeof prettyHrTime;
42
34
  declare const index_shouldIgnoreCurrentPath: typeof shouldIgnoreCurrentPath;
43
- declare const index_sqlDateTime: typeof sqlDateTime;
44
35
  declare const index_stripBeforeAssetsPath: typeof stripBeforeAssetsPath;
45
36
  declare namespace index {
46
- export { index_convertToUTC as convertToUTC, index_formatSqlQuery as formatSqlQuery, index_generateRandomUuid as generateRandomUuid, index_getMeta as getMeta, index_interpolateQuery as interpolateQuery, index_isStaticFile as isStaticFile, index_now as now, index_nowISO as nowISO, index_prepareIgnoredPaths as prepareIgnoredPaths, index_prettyHrTime as prettyHrTime, index_shouldIgnoreCurrentPath as shouldIgnoreCurrentPath, index_sqlDateTime as sqlDateTime, index_stripBeforeAssetsPath as stripBeforeAssetsPath };
37
+ export { index_formatSqlQuery as formatSqlQuery, index_generateRandomUuid as generateRandomUuid, index_getMeta as getMeta, index_interpolateQuery as interpolateQuery, index_isStaticFile as isStaticFile, index_prepareIgnoredPaths as prepareIgnoredPaths, index_prettyHrTime as prettyHrTime, index_shouldIgnoreCurrentPath as shouldIgnoreCurrentPath, index_stripBeforeAssetsPath as stripBeforeAssetsPath };
47
38
  }
48
39
 
49
- export { interpolateQuery as a, nowISO as b, convertToUTC as c, getMeta as d, isStaticFile as e, formatSqlQuery as f, generateRandomUuid as g, stripBeforeAssetsPath as h, index as i, shouldIgnoreCurrentPath as j, prettyHrTime as k, now as n, prepareIgnoredPaths as p, sqlDateTime as s };
40
+ export { interpolateQuery as a, getMeta as b, isStaticFile as c, shouldIgnoreCurrentPath as d, prettyHrTime as e, formatSqlQuery as f, generateRandomUuid as g, index as i, prepareIgnoredPaths as p, stripBeforeAssetsPath as s };
@@ -1,4 +1,3 @@
1
- import { DateTime } from 'luxon';
2
1
  import { SqlLanguage } from 'sql-formatter';
3
2
 
4
3
  declare const generateRandomUuid: () => `${string}-${string}-${string}-${string}-${string}`;
@@ -12,10 +11,6 @@ type Bindings = any[] | Record<string, any>;
12
11
  */
13
12
  declare function interpolateQuery(query: string, bindings: Bindings): string;
14
13
  declare const formatSqlQuery: (query: string, language: SqlLanguage) => string;
15
- declare function now(): DateTime<true> | DateTime<false>;
16
- declare function nowISO(): string;
17
- declare function sqlDateTime(dateTime?: DateTime | null): string | null;
18
- declare function convertToUTC(dateTime: string): string;
19
14
  declare function getMeta(metaUrl?: string): {
20
15
  __filename: string;
21
16
  __dirname: string;
@@ -29,21 +24,17 @@ declare function prepareIgnoredPaths(path: string, ignoredPaths: RegExp[]): {
29
24
  declare function shouldIgnoreCurrentPath(path: string, ignoredPaths: RegExp[], onlyPaths: RegExp[]): boolean;
30
25
  declare function prettyHrTime(hrtime: [number, number], verbose?: boolean): string;
31
26
 
32
- declare const index_convertToUTC: typeof convertToUTC;
33
27
  declare const index_formatSqlQuery: typeof formatSqlQuery;
34
28
  declare const index_generateRandomUuid: typeof generateRandomUuid;
35
29
  declare const index_getMeta: typeof getMeta;
36
30
  declare const index_interpolateQuery: typeof interpolateQuery;
37
31
  declare const index_isStaticFile: typeof isStaticFile;
38
- declare const index_now: typeof now;
39
- declare const index_nowISO: typeof nowISO;
40
32
  declare const index_prepareIgnoredPaths: typeof prepareIgnoredPaths;
41
33
  declare const index_prettyHrTime: typeof prettyHrTime;
42
34
  declare const index_shouldIgnoreCurrentPath: typeof shouldIgnoreCurrentPath;
43
- declare const index_sqlDateTime: typeof sqlDateTime;
44
35
  declare const index_stripBeforeAssetsPath: typeof stripBeforeAssetsPath;
45
36
  declare namespace index {
46
- export { index_convertToUTC as convertToUTC, index_formatSqlQuery as formatSqlQuery, index_generateRandomUuid as generateRandomUuid, index_getMeta as getMeta, index_interpolateQuery as interpolateQuery, index_isStaticFile as isStaticFile, index_now as now, index_nowISO as nowISO, index_prepareIgnoredPaths as prepareIgnoredPaths, index_prettyHrTime as prettyHrTime, index_shouldIgnoreCurrentPath as shouldIgnoreCurrentPath, index_sqlDateTime as sqlDateTime, index_stripBeforeAssetsPath as stripBeforeAssetsPath };
37
+ export { index_formatSqlQuery as formatSqlQuery, index_generateRandomUuid as generateRandomUuid, index_getMeta as getMeta, index_interpolateQuery as interpolateQuery, index_isStaticFile as isStaticFile, index_prepareIgnoredPaths as prepareIgnoredPaths, index_prettyHrTime as prettyHrTime, index_shouldIgnoreCurrentPath as shouldIgnoreCurrentPath, index_stripBeforeAssetsPath as stripBeforeAssetsPath };
47
38
  }
48
39
 
49
- export { interpolateQuery as a, nowISO as b, convertToUTC as c, getMeta as d, isStaticFile as e, formatSqlQuery as f, generateRandomUuid as g, stripBeforeAssetsPath as h, index as i, shouldIgnoreCurrentPath as j, prettyHrTime as k, now as n, prepareIgnoredPaths as p, sqlDateTime as s };
40
+ export { interpolateQuery as a, getMeta as b, isStaticFile as c, shouldIgnoreCurrentPath as d, prettyHrTime as e, formatSqlQuery as f, generateRandomUuid as g, index as i, prepareIgnoredPaths as p, stripBeforeAssetsPath as s };
package/dist/index.cjs CHANGED
@@ -1,8 +1,6 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
2
 
3
-
4
-
5
- var _chunk3R5QARPTcjs = require('./chunk-3R5QARPT.cjs');
3
+ var _chunkNUSVID2Qcjs = require('./chunk-NUSVID2Q.cjs');
6
4
  require('./chunk-7EKM5HB5.cjs');
7
5
 
8
6
 
@@ -12,17 +10,17 @@ var _chunkSJXZARBJcjs = require('./chunk-SJXZARBJ.cjs');
12
10
  var _chunkBL4Z6JFHcjs = require('./chunk-BL4Z6JFH.cjs');
13
11
 
14
12
 
15
- var _chunkBFFOUTTEcjs = require('./chunk-BFFOUTTE.cjs');
13
+ var _chunk7MOTQS6Ncjs = require('./chunk-7MOTQS6N.cjs');
16
14
 
17
15
 
18
- var _chunkFCMQ3WE3cjs = require('./chunk-FCMQ3WE3.cjs');
16
+ var _chunkCGPET47Dcjs = require('./chunk-CGPET47D.cjs');
19
17
  require('./chunk-XZFXXD3A.cjs');
20
18
 
21
19
 
22
- var _chunkAUDSBNLFcjs = require('./chunk-AUDSBNLF.cjs');
20
+ var _chunk45JBO7MEcjs = require('./chunk-45JBO7ME.cjs');
23
21
 
24
22
 
25
- var _chunkWU6IZUEVcjs = require('./chunk-WU6IZUEV.cjs');
23
+ var _chunk7FBZAVQ3cjs = require('./chunk-7FBZAVQ3.cjs');
26
24
 
27
25
 
28
26
  var _chunkEHOWCXZVcjs = require('./chunk-EHOWCXZV.cjs');
@@ -50,6 +48,4 @@ require('./chunk-75ZPJI57.cjs');
50
48
 
51
49
 
52
50
 
53
-
54
-
55
- exports.BetterSqliteStore = _chunkAUDSBNLFcjs.BetterSqliteStore; exports.Lens = _chunkFCMQ3WE3cjs.Lens; exports.LensAdapter = _chunkBFFOUTTEcjs.Adapter; exports.LensStore = _chunkEHOWCXZVcjs.Store; exports.LensWatcher = _chunkEKG3FVLVcjs.Watcher; exports.QueryWatcher = _chunkSJXZARBJcjs.QueryWatcher; exports.RequestWatcher = _chunkBL4Z6JFHcjs.RequestWatcher; exports.WatcherTypeEnum = _chunk2HRVJRKVcjs.WatcherTypeEnum; exports.createEmittery = _chunk3R5QARPTcjs.createEmittery; exports.getLensStore = _chunkQRZUNYF6cjs.getStore; exports.lensEmitter = _chunk3R5QARPTcjs.lensEmitter; exports.lensResource = _chunk3R5QARPTcjs.lensResource; exports.lensUtils = _chunkWU6IZUEVcjs.utils_exports;
51
+ exports.BetterSqliteStore = _chunk45JBO7MEcjs.BetterSqliteStore; exports.Lens = _chunkCGPET47Dcjs.Lens; exports.LensAdapter = _chunk7MOTQS6Ncjs.Adapter; exports.LensStore = _chunkEHOWCXZVcjs.Store; exports.LensWatcher = _chunkEKG3FVLVcjs.Watcher; exports.QueryWatcher = _chunkSJXZARBJcjs.QueryWatcher; exports.RequestWatcher = _chunkBL4Z6JFHcjs.RequestWatcher; exports.WatcherTypeEnum = _chunk2HRVJRKVcjs.WatcherTypeEnum; exports.createEmittery = _chunkNUSVID2Qcjs.createEmittery; exports.getLensStore = _chunkQRZUNYF6cjs.getStore; exports.lensUtils = _chunk7FBZAVQ3cjs.utils_exports;
package/dist/index.d.cts CHANGED
@@ -7,10 +7,8 @@ export { default as LensAdapter } from './abstracts/adapter.cjs';
7
7
  export { default as LensStore } from './abstracts/store.cjs';
8
8
  export { default as LensWatcher } from './core/watcher.cjs';
9
9
  export { getStore as getLensStore } from './context/context.cjs';
10
- export { i as lensUtils } from './index-D0Vszdac.cjs';
11
- export { createEmittery, lensEmitter, lensResource } from './utils/event_emitter.cjs';
10
+ export { i as lensUtils } from './index-DiLfwsvc.cjs';
11
+ export { createEmittery } from './utils/event_emitter.cjs';
12
12
  import 'libsql';
13
13
  import 'sql-formatter';
14
- import 'luxon';
15
14
  import 'emittery';
16
- import 'node:async_hooks';
package/dist/index.d.ts CHANGED
@@ -7,10 +7,8 @@ export { default as LensAdapter } from './abstracts/adapter.js';
7
7
  export { default as LensStore } from './abstracts/store.js';
8
8
  export { default as LensWatcher } from './core/watcher.js';
9
9
  export { getStore as getLensStore } from './context/context.js';
10
- export { i as lensUtils } from './index-D0Vszdac.js';
11
- export { createEmittery, lensEmitter, lensResource } from './utils/event_emitter.js';
10
+ export { i as lensUtils } from './index-DiLfwsvc.js';
11
+ export { createEmittery } from './utils/event_emitter.js';
12
12
  import 'libsql';
13
13
  import 'sql-formatter';
14
- import 'luxon';
15
14
  import 'emittery';
16
- import 'node:async_hooks';
package/dist/index.js CHANGED
@@ -1,8 +1,6 @@
1
1
  import {
2
- createEmittery,
3
- lensEmitter,
4
- lensResource
5
- } from "./chunk-RMZ4UAQ2.js";
2
+ createEmittery
3
+ } from "./chunk-66RDYK2I.js";
6
4
  import "./chunk-XXYRWHSQ.js";
7
5
  import {
8
6
  QueryWatcher
@@ -12,17 +10,17 @@ import {
12
10
  } from "./chunk-4HLDYZJA.js";
13
11
  import {
14
12
  Adapter
15
- } from "./chunk-TPUVRGYT.js";
13
+ } from "./chunk-JTRKNE5Q.js";
16
14
  import {
17
15
  Lens
18
- } from "./chunk-5PYQWLAZ.js";
16
+ } from "./chunk-HMBQ2DF7.js";
19
17
  import "./chunk-VD5IMUWL.js";
20
18
  import {
21
19
  BetterSqliteStore
22
- } from "./chunk-IPMTMCFP.js";
20
+ } from "./chunk-HLBMQ3ID.js";
23
21
  import {
24
22
  utils_exports
25
- } from "./chunk-EJ5BW35V.js";
23
+ } from "./chunk-YXSPADWE.js";
26
24
  import {
27
25
  Store
28
26
  } from "./chunk-FKMBNWX4.js";
@@ -49,7 +47,5 @@ export {
49
47
  WatcherTypeEnum,
50
48
  createEmittery,
51
49
  getStore as getLensStore,
52
- lensEmitter,
53
- lensResource,
54
50
  utils_exports as lensUtils
55
51
  };
@@ -1,10 +1,9 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
2
 
3
- var _chunkAUDSBNLFcjs = require('../chunk-AUDSBNLF.cjs');
4
- require('../chunk-WU6IZUEV.cjs');
3
+ var _chunk45JBO7MEcjs = require('../chunk-45JBO7ME.cjs');
5
4
  require('../chunk-EHOWCXZV.cjs');
6
5
  require('../chunk-2HRVJRKV.cjs');
7
6
  require('../chunk-75ZPJI57.cjs');
8
7
 
9
8
 
10
- exports.default = _chunkAUDSBNLFcjs.BetterSqliteStore;
9
+ exports.default = _chunk45JBO7MEcjs.BetterSqliteStore;
@@ -1,7 +1,6 @@
1
1
  import {
2
2
  BetterSqliteStore
3
- } from "../chunk-IPMTMCFP.js";
4
- import "../chunk-EJ5BW35V.js";
3
+ } from "../chunk-HLBMQ3ID.js";
5
4
  import "../chunk-FKMBNWX4.js";
6
5
  import "../chunk-FLOVBBFU.js";
7
6
  import "../chunk-MLKGABMK.js";
@@ -1,11 +1,10 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true});require('../chunk-XZFXXD3A.cjs');
2
2
 
3
3
 
4
- var _chunkAUDSBNLFcjs = require('../chunk-AUDSBNLF.cjs');
5
- require('../chunk-WU6IZUEV.cjs');
4
+ var _chunk45JBO7MEcjs = require('../chunk-45JBO7ME.cjs');
6
5
  require('../chunk-EHOWCXZV.cjs');
7
6
  require('../chunk-2HRVJRKV.cjs');
8
7
  require('../chunk-75ZPJI57.cjs');
9
8
 
10
9
 
11
- exports.BetterSqliteStore = _chunkAUDSBNLFcjs.BetterSqliteStore;
10
+ exports.BetterSqliteStore = _chunk45JBO7MEcjs.BetterSqliteStore;
@@ -1,8 +1,7 @@
1
1
  import "../chunk-VD5IMUWL.js";
2
2
  import {
3
3
  BetterSqliteStore
4
- } from "../chunk-IPMTMCFP.js";
5
- import "../chunk-EJ5BW35V.js";
4
+ } from "../chunk-HLBMQ3ID.js";
6
5
  import "../chunk-FKMBNWX4.js";
7
6
  import "../chunk-FLOVBBFU.js";
8
7
  import "../chunk-MLKGABMK.js";
@@ -0,0 +1,2 @@
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./QueryTable-B6L0F5jL.js","./index-Dzy6B_ZD.js","./index-DzNHqeKh.css","./Table-DF4sxTNg.js","./index-byVaIWe8.js"])))=>i.map(i=>d[i]);
2
+ import{r as t,j as s,_ as a}from"./index-Dzy6B_ZD.js";import{u as i}from"./useQueries-CVt1cLYV.js";import{u}from"./useLoadMore-BRca6vvh.js";import"./useLensApi-CkgX8mtY.js";const m=t.lazy(()=>a(()=>import("./QueryTable-B6L0F5jL.js"),__vite__mapDeps([0,1,2,3,4]),import.meta.url)),l=()=>{const{loadMoreRequests:o,fetchQueries:r}=i(),e=u({paginatedPage:o});return t.useEffect(()=>{r()},[]),console.log("data",e.data),s.jsx(m,{hasMoreObject:e})};export{l as default};