@auxilium/datalynk-client 1.0.16 → 1.0.18

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.
@@ -1 +1 @@
1
- {"version":3,"file":"auth.d.ts","sourceRoot":"","sources":["../src/auth.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,eAAe,EAAyB,MAAM,MAAM,CAAC;AAC7D,OAAO,EAAC,GAAG,EAAC,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAC,WAAW,EAAE,kBAAkB,EAAC,MAAM,gBAAgB,CAAC;AAE/D,mBAAmB;AACnB,MAAM,MAAM,IAAI,GAAG;IAClB,cAAc;IACd,EAAE,EAAE,MAAM,CAAC;IACX,4BAA4B;IAC5B,KAAK,EAAE,MAAM,CAAC;IACd,4CAA4C;IAC5C,KAAK,EAAE,OAAO,CAAC;IACf,kCAAkC;IAClC,QAAQ,EAAE,OAAO,CAAC;IAClB,gCAAgC;IAChC,UAAU,EAAE,MAAM,CAAC;IACnB,+BAA+B;IAC/B,SAAS,EAAE,MAAM,CAAC;IAClB,4BAA4B;IAC5B,KAAK,EAAE,MAAM,CAAC;IACd,8BAA8B;IAC9B,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,2BAA2B;IAC3B,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,4BAA4B;IAC5B,KAAK,EAAE,MAAM,CAAC;CACd,CAAA;AAED;;GAEG;AACH,qBAAa,IAAI;IAUJ,OAAO,CAAC,QAAQ,CAAC,GAAG;IAThC,oCAAoC;IACpC,KAAK,2CAA2D;IAChE,mBAAmB;IACnB,IAAI,IAAI,IAEO,IAAI,GAAG,IAAI,GAAG,SAAS,CAFM;IAC5C,4BAA4B;IAC5B,IAAI,IAAI,CAAC,IAAI,EAAE,IAAI,GAAG,IAAI,GAAG,SAAS,EAA4B;IAElE,IAAI,KAAK,kBAAi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OAAO,CAAC,EAAE,kBAAkB,GAAG,OAAO,CAAC,IAAI,CAAC;IAgB7E;;;;OAIG;IACH,eAAe;IAEf;;;;OAIG;IACH,OAAO;IAEP;;;;OAIG;IACG,UAAU,IAAI,OAAO,CAAC,OAAO,CAAC;IAOpC;;;;OAIG;IACG,YAAY,IAAI,OAAO,CAAC,OAAO,CAAC;IAOtC;;;;OAIG;IACG,WAAW,IAAI,OAAO,CAAC,OAAO,CAAC;IAOrC;;;;;;;;OAQG;IACH,KAAK,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE;QAAC,SAAS,CAAC,EAAE,MAAM,CAAC;QAAC,MAAM,CAAC,EAAE,IAAI,GAAG,MAAM,CAAA;KAAC,GAAG,OAAO,CAAC,IAAI,CAAC;IAsBzH;;;;OAIG;IACH,UAAU,IAAI,OAAO,CAAC,IAAI,CAAC;IAS3B;;;;;;OAMG;IACH,WAAW,CAAC,KAAK,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,kBAAkB,GAAG,WAAW;IAIrE;;;;OAIG;IACH,MAAM;gBAC6B,MAAM;aAAO,MAAM;;IAMtD;;;;;;;OAOG;IACH,KAAK,CAAC,KAAK,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,MAAM;IAWvD;;;;;;OAMG;IACH,YAAY,CAAC,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,OAAO,GAAG,KAAK,GAAG,OAAO;CAI3D"}
package/dist/index.cjs CHANGED
@@ -1,20 +1,20 @@
1
- (function(global, factory) {
2
- typeof exports === "object" && typeof module !== "undefined" ? factory(exports) : typeof define === "function" && define.amd ? define(["exports"], factory) : (global = typeof globalThis !== "undefined" ? globalThis : global || self, factory(global.utils = {}));
1
+ (function(global2, factory) {
2
+ typeof exports === "object" && typeof module !== "undefined" ? factory(exports) : typeof define === "function" && define.amd ? define(["exports"], factory) : (global2 = typeof globalThis !== "undefined" ? globalThis : global2 || self, factory(global2.utils = {}));
3
3
  })(this, function(exports2) {
4
4
  "use strict";var __defProp = Object.defineProperty;
5
5
  var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
6
6
  var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
7
7
 
8
8
  var __defProp2 = Object.defineProperty;
9
- var __defNormalProp2 = (obj, key, value2) => key in obj ? __defProp2(obj, key, { enumerable: true, configurable: true, writable: true, value: value2 }) : obj[key] = value2;
10
- var __publicField2 = (obj, key, value2) => __defNormalProp2(obj, typeof key !== "symbol" ? key + "" : key, value2);
9
+ var __defNormalProp2 = (obj, key, value) => key in obj ? __defProp2(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
10
+ var __publicField2 = (obj, key, value) => __defNormalProp2(obj, typeof key !== "symbol" ? key + "" : key, value);
11
11
  function clean(obj, undefinedOnly = false) {
12
12
  if (obj == null) throw new Error("Cannot clean a NULL value");
13
13
  if (Array.isArray(obj)) {
14
- obj = obj.filter((o) => o != null);
14
+ obj = obj.filter((o) => undefinedOnly ? o !== void 0 : o != null);
15
15
  } else {
16
- Object.entries(obj).forEach(([key, value2]) => {
17
- if (undefinedOnly && value2 === void 0 || !undefinedOnly && value2 == null) delete obj[key];
16
+ Object.entries(obj).forEach(([key, value]) => {
17
+ if (undefinedOnly && value === void 0 || !undefinedOnly && value == null) delete obj[key];
18
18
  });
19
19
  }
20
20
  return obj;
@@ -27,21 +27,26 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
27
27
  }
28
28
  }
29
29
  function JSONSanitize(obj, space) {
30
- return JSON.stringify(obj, (key, value2) => {
31
- return value2;
30
+ const cache = [];
31
+ return JSON.stringify(obj, (key, value) => {
32
+ if (typeof value === "object" && value !== null) {
33
+ if (cache.includes(value)) return "[Circular]";
34
+ cache.push(value);
35
+ }
36
+ return value;
32
37
  }, space);
33
38
  }
34
- function blackOrWhite(background) {
35
- const exploded = background == null ? void 0 : background.match(background.length >= 6 ? /\w\w/g : /\w/g);
36
- if (!exploded) return "black";
37
- const [r2, g, b2] = exploded.map((hex) => parseInt(hex, 16));
38
- const luminance = (0.299 * r2 + 0.587 * g + 0.114 * b2) / 255;
39
+ function contrast(background) {
40
+ const exploded = background == null ? void 0 : background.match(background.length >= 6 ? /[0-9a-fA-F]{2}/g : /[0-9a-fA-F]/g);
41
+ if (!exploded || (exploded == null ? void 0 : exploded.length) < 3) return "black";
42
+ const [r, g, b] = exploded.map((hex) => parseInt(hex.length == 1 ? `${hex}${hex}` : hex, 16));
43
+ const luminance = (0.299 * r + 0.587 * g + 0.114 * b) / 255;
39
44
  return luminance > 0.5 ? "black" : "white";
40
45
  }
41
46
  class PromiseProgress extends Promise {
42
47
  constructor(executor) {
43
48
  super((resolve, reject) => executor(
44
- (value2) => resolve(value2),
49
+ (value) => resolve(value),
45
50
  (reason) => reject(reason),
46
51
  (progress) => this.progress = progress
47
52
  ));
@@ -51,10 +56,10 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
51
56
  get progress() {
52
57
  return this._progress;
53
58
  }
54
- set progress(p2) {
55
- if (p2 == this._progress) return;
56
- this._progress = p2;
57
- this.listeners.forEach((l) => l(p2));
59
+ set progress(p) {
60
+ if (p == this._progress) return;
61
+ this._progress = p;
62
+ this.listeners.forEach((l) => l(p));
58
63
  }
59
64
  static from(promise) {
60
65
  if (promise instanceof PromiseProgress) return promise;
@@ -62,7 +67,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
62
67
  }
63
68
  from(promise) {
64
69
  const newPromise = PromiseProgress.from(promise);
65
- this.onProgress((p2) => newPromise.progress = p2);
70
+ this.onProgress((p) => newPromise.progress = p);
66
71
  return newPromise;
67
72
  }
68
73
  onProgress(callback) {
@@ -144,7 +149,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
144
149
  const minutes = offset % 60;
145
150
  return (offset > 0 ? "-" : "") + `${hours}:${minutes.toString().padStart(2, "0")}`;
146
151
  }
147
- if (typeof date == "number" || typeof date == "string") date = new Date(date);
152
+ if (typeof date == "number" || typeof date == "string" || date == null) date = new Date(date);
148
153
  let t;
149
154
  if (tz == null) tz = -(date.getTimezoneOffset() / 60);
150
155
  t = timezones.find((t2) => isNaN(tz) ? t2[0] == tz : t2[1] == tz);
@@ -190,7 +195,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
190
195
  }
191
196
  static off(event, listener) {
192
197
  const e = event.toString();
193
- this.listeners[e] = (this.listeners[e] || []).filter((l) => l === listener);
198
+ this.listeners[e] = (this.listeners[e] || []).filter((l) => l != listener);
194
199
  }
195
200
  static on(event, listener) {
196
201
  var _a;
@@ -213,7 +218,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
213
218
  (this.listeners[event] || []).forEach((l) => l(...args));
214
219
  }
215
220
  off(event, listener) {
216
- this.listeners[event] = (this.listeners[event] || []).filter((l) => l === listener);
221
+ this.listeners[event] = (this.listeners[event] || []).filter((l) => l != listener);
217
222
  }
218
223
  on(event, listener) {
219
224
  var _a;
@@ -429,16 +434,16 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
429
434
  defaults.interceptors.forEach((i) => _Http2.addInterceptor(i));
430
435
  }
431
436
  }
432
- static addInterceptor(fn) {
437
+ static addInterceptor(fn2) {
433
438
  const key = Object.keys(_Http2.interceptors).length.toString();
434
- _Http2.interceptors[key] = fn;
439
+ _Http2.interceptors[key] = fn2;
435
440
  return () => {
436
441
  _Http2.interceptors[key] = null;
437
442
  };
438
443
  }
439
- addInterceptor(fn) {
444
+ addInterceptor(fn2) {
440
445
  const key = Object.keys(this.interceptors).length.toString();
441
- this.interceptors[key] = fn;
446
+ this.interceptors[key] = fn2;
442
447
  return () => {
443
448
  this.interceptors[key] = null;
444
449
  };
@@ -469,8 +474,8 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
469
474
  body: opts.body
470
475
  }).then(async (resp) => {
471
476
  var _a2, _b;
472
- for (let fn of [...Object.values(_Http2.interceptors), ...Object.values(this.interceptors)]) {
473
- await new Promise((res2) => fn(resp, () => res2()));
477
+ for (let fn2 of [...Object.values(_Http2.interceptors), ...Object.values(this.interceptors)]) {
478
+ await new Promise((res2) => fn2(resp, () => res2()));
474
479
  }
475
480
  const contentLength = resp.headers.get("Content-Length");
476
481
  const total = contentLength ? parseInt(contentLength, 10) : 0;
@@ -509,7 +514,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
509
514
  };
510
515
  __publicField2(_Http, "interceptors", {});
511
516
  __publicField2(_Http, "headers", {});
512
- function jwtDecode(token) {
517
+ function decodeJwt(token) {
513
518
  const base64 = token.split(".")[1].replace(/-/g, "+").replace(/_/g, "/");
514
519
  return JSONAttemptParse(decodeURIComponent(atob(base64).split("").map(function(c) {
515
520
  return "%" + ("00" + c.charCodeAt(0).toString(16)).slice(-2);
@@ -566,6 +571,173 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
566
571
  }
567
572
  };
568
573
  __publicField2(_Logger, "LOG_LEVEL", 4);
574
+ var commonjsGlobal = typeof globalThis !== "undefined" ? globalThis : typeof window !== "undefined" ? window : typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : {};
575
+ var dist = {};
576
+ var persist$1 = {};
577
+ Object.defineProperty(persist$1, "__esModule", { value: true });
578
+ persist$1.persist = persist$1.Persist = void 0;
579
+ class Persist {
580
+ /**
581
+ * @param {string} key Primary key value will be stored under
582
+ * @param {PersistOptions<T>} options Configure using {@link PersistOptions}
583
+ */
584
+ constructor(key, options = {}) {
585
+ __publicField2(this, "key");
586
+ __publicField2(this, "options");
587
+ __publicField2(this, "storage");
588
+ __publicField2(this, "watches", {});
589
+ __publicField2(this, "_value");
590
+ this.key = key;
591
+ this.options = options;
592
+ this.storage = options.storage || localStorage;
593
+ this.load();
594
+ }
595
+ /** Current value or default if undefined */
596
+ get value() {
597
+ var _a;
598
+ return this._value !== void 0 ? this._value : (_a = this.options) == null ? void 0 : _a.default;
599
+ }
600
+ /** Set value with proxy object wrapper to sync future changes */
601
+ set value(v) {
602
+ if (v == null || typeof v != "object")
603
+ this._value = v;
604
+ else
605
+ this._value = new Proxy(v, {
606
+ get: (target, p) => {
607
+ const f = typeof target[p] == "function";
608
+ if (!f)
609
+ return target[p];
610
+ return (...args) => {
611
+ const value = target[p](...args);
612
+ this.save();
613
+ return value;
614
+ };
615
+ },
616
+ set: (target, p, newValue) => {
617
+ target[p] = newValue;
618
+ this.save();
619
+ return true;
620
+ }
621
+ });
622
+ this.save();
623
+ }
624
+ /** Notify listeners of change */
625
+ notify(value) {
626
+ Object.values(this.watches).forEach((watch) => watch(value));
627
+ }
628
+ /** Delete value from storage */
629
+ clear() {
630
+ this.storage.removeItem(this.key);
631
+ }
632
+ /** Save current value to storage */
633
+ save() {
634
+ if (this._value === void 0)
635
+ this.clear();
636
+ else
637
+ this.storage.setItem(this.key, JSON.stringify(this._value));
638
+ this.notify(this.value);
639
+ }
640
+ /** Load value from storage */
641
+ load() {
642
+ if (this.storage[this.key] != void 0) {
643
+ let value = JSON.parse(this.storage.getItem(this.key));
644
+ if (value != null && typeof value == "object" && this.options.type)
645
+ value.__proto__ = this.options.type.prototype;
646
+ this.value = value;
647
+ } else
648
+ this.value = this.options.default || void 0;
649
+ }
650
+ /**
651
+ * Callback function which is run when there are changes
652
+ *
653
+ * @param {(value: T) => any} fn Callback will run on each change; it's passed the next value & it's return is ignored
654
+ * @returns {() => void} Function which will unsubscribe the watch/callback when called
655
+ */
656
+ watch(fn2) {
657
+ const index = Object.keys(this.watches).length;
658
+ this.watches[index] = fn2;
659
+ return () => {
660
+ delete this.watches[index];
661
+ };
662
+ }
663
+ /**
664
+ * Return value as JSON string
665
+ *
666
+ * @returns {string} Stringified object as JSON
667
+ */
668
+ toString() {
669
+ return JSON.stringify(this.value);
670
+ }
671
+ /**
672
+ * Return current value
673
+ *
674
+ * @returns {T} Current value
675
+ */
676
+ valueOf() {
677
+ return this.value;
678
+ }
679
+ }
680
+ persist$1.Persist = Persist;
681
+ function persist(options) {
682
+ return (target, prop) => {
683
+ const key = (options == null ? void 0 : options.key) || `${target.constructor.name}.${prop.toString()}`;
684
+ const wrapper = new Persist(key, options);
685
+ Object.defineProperty(target, prop, {
686
+ get: function() {
687
+ return wrapper.value;
688
+ },
689
+ set: function(v) {
690
+ wrapper.value = v;
691
+ }
692
+ });
693
+ };
694
+ }
695
+ persist$1.persist = persist;
696
+ var memoryStorage = {};
697
+ Object.defineProperty(memoryStorage, "__esModule", { value: true });
698
+ memoryStorage.MemoryStorage = void 0;
699
+ class MemoryStorage {
700
+ get length() {
701
+ return Object.keys(this).length;
702
+ }
703
+ clear() {
704
+ Object.keys(this).forEach((k) => this.removeItem(k));
705
+ }
706
+ getItem(key) {
707
+ return this[key];
708
+ }
709
+ key(index) {
710
+ return Object.keys(this)[index];
711
+ }
712
+ removeItem(key) {
713
+ delete this[key];
714
+ }
715
+ setItem(key, value) {
716
+ this[key] = value;
717
+ }
718
+ }
719
+ memoryStorage.MemoryStorage = MemoryStorage;
720
+ (function(exports3) {
721
+ var __createBinding = commonjsGlobal && commonjsGlobal.__createBinding || (Object.create ? function(o, m, k, k2) {
722
+ if (k2 === void 0) k2 = k;
723
+ var desc = Object.getOwnPropertyDescriptor(m, k);
724
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
725
+ desc = { enumerable: true, get: function() {
726
+ return m[k];
727
+ } };
728
+ }
729
+ Object.defineProperty(o, k2, desc);
730
+ } : function(o, m, k, k2) {
731
+ if (k2 === void 0) k2 = k;
732
+ o[k2] = m[k];
733
+ });
734
+ var __exportStar = commonjsGlobal && commonjsGlobal.__exportStar || function(m, exports22) {
735
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports22, p)) __createBinding(exports22, m, p);
736
+ };
737
+ Object.defineProperty(exports3, "__esModule", { value: true });
738
+ __exportStar(persist$1, exports3);
739
+ __exportStar(memoryStorage, exports3);
740
+ })(dist);
569
741
  var extendStatics = function(d, b) {
570
742
  extendStatics = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(d2, b2) {
571
743
  d2.__proto__ = b2;
@@ -1531,7 +1703,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
1531
1703
  background-color: var(--theme-primary);
1532
1704
  background-image: none;
1533
1705
  border: 0;
1534
- color: ${blackOrWhite(options.color)};
1706
+ color: ${contrast(options.color)};
1535
1707
  padding: 8px 24px;
1536
1708
  border-radius: 5px;
1537
1709
  }
@@ -1543,7 +1715,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
1543
1715
 
1544
1716
  #datalynk-login button:hover:not(:disabled) {
1545
1717
  cursor: pointer;
1546
- filter: ${blackOrWhite(options.color) == "black" ? "brightness(105%)" : "brightness(80%)"};
1718
+ filter: ${contrast(options.color) == "black" ? "brightness(105%)" : "brightness(80%)"};
1547
1719
  }
1548
1720
 
1549
1721
  #datalynk-login .login-links{
@@ -2270,6 +2442,16 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
2270
2442
  rows() {
2271
2443
  return this.pop("rows");
2272
2444
  }
2445
+ /**
2446
+ * Save multiple rows to the slice, automatically inserts/updates
2447
+ * @param {T} rows Rows to add to slice
2448
+ * @returns {this<T>}
2449
+ */
2450
+ save(...rows) {
2451
+ this.operation = "$/slice/multisave";
2452
+ this.request.rows = rows;
2453
+ return this;
2454
+ }
2273
2455
  /**
2274
2456
  * Set the request type to select
2275
2457
  * @example
@@ -2514,7 +2696,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
2514
2696
  } });
2515
2697
  }
2516
2698
  }
2517
- const version = "1.0.16";
2699
+ const version = "1.0.18";
2518
2700
  class Api {
2519
2701
  /**
2520
2702
  * Connect to Datalynk & send requests
@@ -2581,7 +2763,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
2581
2763
  /** Get session info from JWT payload */
2582
2764
  get jwtPayload() {
2583
2765
  if (!this.token) return null;
2584
- return jwtDecode(this.token);
2766
+ return decodeJwt(this.token);
2585
2767
  }
2586
2768
  _request(req, options = {}) {
2587
2769
  const token = options.token || this.token;
package/dist/index.mjs CHANGED
@@ -2,15 +2,15 @@ var __defProp = Object.defineProperty;
2
2
  var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3
3
  var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
4
4
  var __defProp2 = Object.defineProperty;
5
- var __defNormalProp2 = (obj, key, value2) => key in obj ? __defProp2(obj, key, { enumerable: true, configurable: true, writable: true, value: value2 }) : obj[key] = value2;
6
- var __publicField2 = (obj, key, value2) => __defNormalProp2(obj, typeof key !== "symbol" ? key + "" : key, value2);
5
+ var __defNormalProp2 = (obj, key, value) => key in obj ? __defProp2(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
6
+ var __publicField2 = (obj, key, value) => __defNormalProp2(obj, typeof key !== "symbol" ? key + "" : key, value);
7
7
  function clean(obj, undefinedOnly = false) {
8
8
  if (obj == null) throw new Error("Cannot clean a NULL value");
9
9
  if (Array.isArray(obj)) {
10
- obj = obj.filter((o) => o != null);
10
+ obj = obj.filter((o) => undefinedOnly ? o !== void 0 : o != null);
11
11
  } else {
12
- Object.entries(obj).forEach(([key, value2]) => {
13
- if (undefinedOnly && value2 === void 0 || !undefinedOnly && value2 == null) delete obj[key];
12
+ Object.entries(obj).forEach(([key, value]) => {
13
+ if (undefinedOnly && value === void 0 || !undefinedOnly && value == null) delete obj[key];
14
14
  });
15
15
  }
16
16
  return obj;
@@ -23,21 +23,26 @@ function JSONAttemptParse(json) {
23
23
  }
24
24
  }
25
25
  function JSONSanitize(obj, space) {
26
- return JSON.stringify(obj, (key, value2) => {
27
- return value2;
26
+ const cache = [];
27
+ return JSON.stringify(obj, (key, value) => {
28
+ if (typeof value === "object" && value !== null) {
29
+ if (cache.includes(value)) return "[Circular]";
30
+ cache.push(value);
31
+ }
32
+ return value;
28
33
  }, space);
29
34
  }
30
- function blackOrWhite(background) {
31
- const exploded = background == null ? void 0 : background.match(background.length >= 6 ? /\w\w/g : /\w/g);
32
- if (!exploded) return "black";
33
- const [r2, g, b2] = exploded.map((hex) => parseInt(hex, 16));
34
- const luminance = (0.299 * r2 + 0.587 * g + 0.114 * b2) / 255;
35
+ function contrast(background) {
36
+ const exploded = background == null ? void 0 : background.match(background.length >= 6 ? /[0-9a-fA-F]{2}/g : /[0-9a-fA-F]/g);
37
+ if (!exploded || (exploded == null ? void 0 : exploded.length) < 3) return "black";
38
+ const [r, g, b] = exploded.map((hex) => parseInt(hex.length == 1 ? `${hex}${hex}` : hex, 16));
39
+ const luminance = (0.299 * r + 0.587 * g + 0.114 * b) / 255;
35
40
  return luminance > 0.5 ? "black" : "white";
36
41
  }
37
42
  class PromiseProgress extends Promise {
38
43
  constructor(executor) {
39
44
  super((resolve, reject) => executor(
40
- (value2) => resolve(value2),
45
+ (value) => resolve(value),
41
46
  (reason) => reject(reason),
42
47
  (progress) => this.progress = progress
43
48
  ));
@@ -47,10 +52,10 @@ class PromiseProgress extends Promise {
47
52
  get progress() {
48
53
  return this._progress;
49
54
  }
50
- set progress(p2) {
51
- if (p2 == this._progress) return;
52
- this._progress = p2;
53
- this.listeners.forEach((l) => l(p2));
55
+ set progress(p) {
56
+ if (p == this._progress) return;
57
+ this._progress = p;
58
+ this.listeners.forEach((l) => l(p));
54
59
  }
55
60
  static from(promise) {
56
61
  if (promise instanceof PromiseProgress) return promise;
@@ -58,7 +63,7 @@ class PromiseProgress extends Promise {
58
63
  }
59
64
  from(promise) {
60
65
  const newPromise = PromiseProgress.from(promise);
61
- this.onProgress((p2) => newPromise.progress = p2);
66
+ this.onProgress((p) => newPromise.progress = p);
62
67
  return newPromise;
63
68
  }
64
69
  onProgress(callback) {
@@ -140,7 +145,7 @@ function formatDate(format = "YYYY-MM-DD H:mm", date = /* @__PURE__ */ new Date(
140
145
  const minutes = offset % 60;
141
146
  return (offset > 0 ? "-" : "") + `${hours}:${minutes.toString().padStart(2, "0")}`;
142
147
  }
143
- if (typeof date == "number" || typeof date == "string") date = new Date(date);
148
+ if (typeof date == "number" || typeof date == "string" || date == null) date = new Date(date);
144
149
  let t;
145
150
  if (tz == null) tz = -(date.getTimezoneOffset() / 60);
146
151
  t = timezones.find((t2) => isNaN(tz) ? t2[0] == tz : t2[1] == tz);
@@ -186,7 +191,7 @@ class TypedEmitter {
186
191
  }
187
192
  static off(event, listener) {
188
193
  const e = event.toString();
189
- this.listeners[e] = (this.listeners[e] || []).filter((l) => l === listener);
194
+ this.listeners[e] = (this.listeners[e] || []).filter((l) => l != listener);
190
195
  }
191
196
  static on(event, listener) {
192
197
  var _a;
@@ -209,7 +214,7 @@ class TypedEmitter {
209
214
  (this.listeners[event] || []).forEach((l) => l(...args));
210
215
  }
211
216
  off(event, listener) {
212
- this.listeners[event] = (this.listeners[event] || []).filter((l) => l === listener);
217
+ this.listeners[event] = (this.listeners[event] || []).filter((l) => l != listener);
213
218
  }
214
219
  on(event, listener) {
215
220
  var _a;
@@ -425,16 +430,16 @@ const _Http = class _Http2 {
425
430
  defaults.interceptors.forEach((i) => _Http2.addInterceptor(i));
426
431
  }
427
432
  }
428
- static addInterceptor(fn) {
433
+ static addInterceptor(fn2) {
429
434
  const key = Object.keys(_Http2.interceptors).length.toString();
430
- _Http2.interceptors[key] = fn;
435
+ _Http2.interceptors[key] = fn2;
431
436
  return () => {
432
437
  _Http2.interceptors[key] = null;
433
438
  };
434
439
  }
435
- addInterceptor(fn) {
440
+ addInterceptor(fn2) {
436
441
  const key = Object.keys(this.interceptors).length.toString();
437
- this.interceptors[key] = fn;
442
+ this.interceptors[key] = fn2;
438
443
  return () => {
439
444
  this.interceptors[key] = null;
440
445
  };
@@ -465,8 +470,8 @@ const _Http = class _Http2 {
465
470
  body: opts.body
466
471
  }).then(async (resp) => {
467
472
  var _a2, _b;
468
- for (let fn of [...Object.values(_Http2.interceptors), ...Object.values(this.interceptors)]) {
469
- await new Promise((res2) => fn(resp, () => res2()));
473
+ for (let fn2 of [...Object.values(_Http2.interceptors), ...Object.values(this.interceptors)]) {
474
+ await new Promise((res2) => fn2(resp, () => res2()));
470
475
  }
471
476
  const contentLength = resp.headers.get("Content-Length");
472
477
  const total = contentLength ? parseInt(contentLength, 10) : 0;
@@ -505,7 +510,7 @@ const _Http = class _Http2 {
505
510
  };
506
511
  __publicField2(_Http, "interceptors", {});
507
512
  __publicField2(_Http, "headers", {});
508
- function jwtDecode(token) {
513
+ function decodeJwt(token) {
509
514
  const base64 = token.split(".")[1].replace(/-/g, "+").replace(/_/g, "/");
510
515
  return JSONAttemptParse(decodeURIComponent(atob(base64).split("").map(function(c) {
511
516
  return "%" + ("00" + c.charCodeAt(0).toString(16)).slice(-2);
@@ -562,6 +567,173 @@ const _Logger = class _Logger2 extends TypedEmitter {
562
567
  }
563
568
  };
564
569
  __publicField2(_Logger, "LOG_LEVEL", 4);
570
+ var commonjsGlobal = typeof globalThis !== "undefined" ? globalThis : typeof window !== "undefined" ? window : typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : {};
571
+ var dist = {};
572
+ var persist$1 = {};
573
+ Object.defineProperty(persist$1, "__esModule", { value: true });
574
+ persist$1.persist = persist$1.Persist = void 0;
575
+ class Persist {
576
+ /**
577
+ * @param {string} key Primary key value will be stored under
578
+ * @param {PersistOptions<T>} options Configure using {@link PersistOptions}
579
+ */
580
+ constructor(key, options = {}) {
581
+ __publicField2(this, "key");
582
+ __publicField2(this, "options");
583
+ __publicField2(this, "storage");
584
+ __publicField2(this, "watches", {});
585
+ __publicField2(this, "_value");
586
+ this.key = key;
587
+ this.options = options;
588
+ this.storage = options.storage || localStorage;
589
+ this.load();
590
+ }
591
+ /** Current value or default if undefined */
592
+ get value() {
593
+ var _a;
594
+ return this._value !== void 0 ? this._value : (_a = this.options) == null ? void 0 : _a.default;
595
+ }
596
+ /** Set value with proxy object wrapper to sync future changes */
597
+ set value(v) {
598
+ if (v == null || typeof v != "object")
599
+ this._value = v;
600
+ else
601
+ this._value = new Proxy(v, {
602
+ get: (target, p) => {
603
+ const f = typeof target[p] == "function";
604
+ if (!f)
605
+ return target[p];
606
+ return (...args) => {
607
+ const value = target[p](...args);
608
+ this.save();
609
+ return value;
610
+ };
611
+ },
612
+ set: (target, p, newValue) => {
613
+ target[p] = newValue;
614
+ this.save();
615
+ return true;
616
+ }
617
+ });
618
+ this.save();
619
+ }
620
+ /** Notify listeners of change */
621
+ notify(value) {
622
+ Object.values(this.watches).forEach((watch) => watch(value));
623
+ }
624
+ /** Delete value from storage */
625
+ clear() {
626
+ this.storage.removeItem(this.key);
627
+ }
628
+ /** Save current value to storage */
629
+ save() {
630
+ if (this._value === void 0)
631
+ this.clear();
632
+ else
633
+ this.storage.setItem(this.key, JSON.stringify(this._value));
634
+ this.notify(this.value);
635
+ }
636
+ /** Load value from storage */
637
+ load() {
638
+ if (this.storage[this.key] != void 0) {
639
+ let value = JSON.parse(this.storage.getItem(this.key));
640
+ if (value != null && typeof value == "object" && this.options.type)
641
+ value.__proto__ = this.options.type.prototype;
642
+ this.value = value;
643
+ } else
644
+ this.value = this.options.default || void 0;
645
+ }
646
+ /**
647
+ * Callback function which is run when there are changes
648
+ *
649
+ * @param {(value: T) => any} fn Callback will run on each change; it's passed the next value & it's return is ignored
650
+ * @returns {() => void} Function which will unsubscribe the watch/callback when called
651
+ */
652
+ watch(fn2) {
653
+ const index = Object.keys(this.watches).length;
654
+ this.watches[index] = fn2;
655
+ return () => {
656
+ delete this.watches[index];
657
+ };
658
+ }
659
+ /**
660
+ * Return value as JSON string
661
+ *
662
+ * @returns {string} Stringified object as JSON
663
+ */
664
+ toString() {
665
+ return JSON.stringify(this.value);
666
+ }
667
+ /**
668
+ * Return current value
669
+ *
670
+ * @returns {T} Current value
671
+ */
672
+ valueOf() {
673
+ return this.value;
674
+ }
675
+ }
676
+ persist$1.Persist = Persist;
677
+ function persist(options) {
678
+ return (target, prop) => {
679
+ const key = (options == null ? void 0 : options.key) || `${target.constructor.name}.${prop.toString()}`;
680
+ const wrapper = new Persist(key, options);
681
+ Object.defineProperty(target, prop, {
682
+ get: function() {
683
+ return wrapper.value;
684
+ },
685
+ set: function(v) {
686
+ wrapper.value = v;
687
+ }
688
+ });
689
+ };
690
+ }
691
+ persist$1.persist = persist;
692
+ var memoryStorage = {};
693
+ Object.defineProperty(memoryStorage, "__esModule", { value: true });
694
+ memoryStorage.MemoryStorage = void 0;
695
+ class MemoryStorage {
696
+ get length() {
697
+ return Object.keys(this).length;
698
+ }
699
+ clear() {
700
+ Object.keys(this).forEach((k) => this.removeItem(k));
701
+ }
702
+ getItem(key) {
703
+ return this[key];
704
+ }
705
+ key(index) {
706
+ return Object.keys(this)[index];
707
+ }
708
+ removeItem(key) {
709
+ delete this[key];
710
+ }
711
+ setItem(key, value) {
712
+ this[key] = value;
713
+ }
714
+ }
715
+ memoryStorage.MemoryStorage = MemoryStorage;
716
+ (function(exports) {
717
+ var __createBinding = commonjsGlobal && commonjsGlobal.__createBinding || (Object.create ? function(o, m, k, k2) {
718
+ if (k2 === void 0) k2 = k;
719
+ var desc = Object.getOwnPropertyDescriptor(m, k);
720
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
721
+ desc = { enumerable: true, get: function() {
722
+ return m[k];
723
+ } };
724
+ }
725
+ Object.defineProperty(o, k2, desc);
726
+ } : function(o, m, k, k2) {
727
+ if (k2 === void 0) k2 = k;
728
+ o[k2] = m[k];
729
+ });
730
+ var __exportStar = commonjsGlobal && commonjsGlobal.__exportStar || function(m, exports2) {
731
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports2, p)) __createBinding(exports2, m, p);
732
+ };
733
+ Object.defineProperty(exports, "__esModule", { value: true });
734
+ __exportStar(persist$1, exports);
735
+ __exportStar(memoryStorage, exports);
736
+ })(dist);
565
737
  var extendStatics = function(d, b) {
566
738
  extendStatics = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(d2, b2) {
567
739
  d2.__proto__ = b2;
@@ -1527,7 +1699,7 @@ __publicField(_LoginPrompt, "css", (options) => `
1527
1699
  background-color: var(--theme-primary);
1528
1700
  background-image: none;
1529
1701
  border: 0;
1530
- color: ${blackOrWhite(options.color)};
1702
+ color: ${contrast(options.color)};
1531
1703
  padding: 8px 24px;
1532
1704
  border-radius: 5px;
1533
1705
  }
@@ -1539,7 +1711,7 @@ __publicField(_LoginPrompt, "css", (options) => `
1539
1711
 
1540
1712
  #datalynk-login button:hover:not(:disabled) {
1541
1713
  cursor: pointer;
1542
- filter: ${blackOrWhite(options.color) == "black" ? "brightness(105%)" : "brightness(80%)"};
1714
+ filter: ${contrast(options.color) == "black" ? "brightness(105%)" : "brightness(80%)"};
1543
1715
  }
1544
1716
 
1545
1717
  #datalynk-login .login-links{
@@ -2266,6 +2438,16 @@ const _Slice = class _Slice {
2266
2438
  rows() {
2267
2439
  return this.pop("rows");
2268
2440
  }
2441
+ /**
2442
+ * Save multiple rows to the slice, automatically inserts/updates
2443
+ * @param {T} rows Rows to add to slice
2444
+ * @returns {this<T>}
2445
+ */
2446
+ save(...rows) {
2447
+ this.operation = "$/slice/multisave";
2448
+ this.request.rows = rows;
2449
+ return this;
2450
+ }
2269
2451
  /**
2270
2452
  * Set the request type to select
2271
2453
  * @example
@@ -2510,7 +2692,7 @@ class Superuser {
2510
2692
  } });
2511
2693
  }
2512
2694
  }
2513
- const version = "1.0.16";
2695
+ const version = "1.0.18";
2514
2696
  class Api {
2515
2697
  /**
2516
2698
  * Connect to Datalynk & send requests
@@ -2577,7 +2759,7 @@ class Api {
2577
2759
  /** Get session info from JWT payload */
2578
2760
  get jwtPayload() {
2579
2761
  if (!this.token) return null;
2580
- return jwtDecode(this.token);
2762
+ return decodeJwt(this.token);
2581
2763
  }
2582
2764
  _request(req, options = {}) {
2583
2765
  const token = options.token || this.token;
package/dist/slice.d.ts CHANGED
@@ -194,6 +194,12 @@ export declare class Slice<T = any> {
194
194
  * @return {Slice<T>}
195
195
  */
196
196
  rows(): Slice<T>;
197
+ /**
198
+ * Save multiple rows to the slice, automatically inserts/updates
199
+ * @param {T} rows Rows to add to slice
200
+ * @returns {this<T>}
201
+ */
202
+ save(...rows: T[]): this;
197
203
  /**
198
204
  * Set the request type to select
199
205
  * @example
@@ -1 +1 @@
1
- {"version":3,"file":"slice.d.ts","sourceRoot":"","sources":["../src/slice.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,eAAe,EAAC,MAAM,MAAM,CAAC;AACrC,OAAO,EAAC,GAAG,EAAE,iBAAiB,EAAC,MAAM,OAAO,CAAC;AAC7C,OAAO,EAAmB,WAAW,EAAC,MAAM,UAAU,CAAC;AAEvD;;GAEG;AACH,qBAAa,KAAK,CAAC,CAAC,GAAG,GAAG;IAoCb,OAAO,CAAC,KAAK;IAAmB,OAAO,CAAC,GAAG;IAnCvD,MAAM,CAAC,GAAG,EAAE,GAAG,CAAC;IAEhB,OAAO,CAAC,SAAS,CAAU;IAC3B,OAAO,CAAC,QAAQ,CAAC,CAAgB;IACjC,OAAO,CAAC,OAAO,CAAW;IAE1B,iCAAiC;IACjC,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,4DAA4D;IAC5D,WAAW,CAAC,EAAE,WAAW,GAAG,IAAI,CAAC;IAEjC,yCAAyC;IACzC,OAAO,CAAC,MAAM,CAAgC;IAC9C,wBAAwB;IACxB,OAAO,KAAK,KAAK,GAA0C;IAC3D,0CAA0C;IAC1C,OAAO,KAAK,KAAK,QAAyC;IAE1D,0BAA0B;IAC1B,IAAI,GAAG;;;OAQN;IAED;;;;;OAKG;gBACiB,KAAK,EAAE,MAAM,GA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IAQzD;;;OAGG;IACH,EAAE,IAAI,KAAK,CAAC,CAAC,CAAC;IAId;;;;;;;;;;;OAWG;IACH,MAAM,CAAC,IAAI,EAAE,CAAC,GAAG,CAAC,EAAE,GAAG,KAAK,CAAC,CAAC,CAAC;IAQ/B;;;;;;;;;OASG;IACH,KAAK,CAAC,GAAG,EAAE,MAAM;IAKjB;;;;;;;;;;;;;OAaG;IACH,EAAE;IAUF;;;;;;;;;;OAUG;IACH,KAAK,CAAC,KAAK,EAAE,MAAM,EAAE,SAAS,UAAO,GAAG,KAAK,CAAC,CAAC,CAAC;IAMhD;;;;OAIG;IACH,GAAG,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,GAAG,KAAK,CAAC,CAAC,CAAC;IAKnC;;;OAGG;IACH,GAAG,IAAI,KAAK,CAAC,CAAC,CAAC;IAIf;;;OAGG;IACH,IAAI,IAAI,KAAK,CAAC,CAAC,CAAC;IAIhB;;;;OAIG;IACH,IAAI,CAAC,GAAG,IAAI,EAAE,CAAC,EAAE;IAMjB;;;;;;;;;OASG;IACH,MAAM,CAAC,EAAE,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,GAAG,KAAK,CAAC,CAAC,CAAC;IASxC;;;;;;;;;OASG;IACH,IAAI,CAAC,EAAE,UAAO;IAoBd;;;;;;;;;;;OAWG;IACH,MAAM,CAAC,IAAI,EAAE,CAAC,GAAG,CAAC,EAAE;IAQpB;;;;;;;;;;;;;;;OAeG;IACH,KAAK,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,EAAE,QAAQ,CAAC,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,GAAG,GAAG,KAAK,CAAC,CAAC,CAAC;CAgCvE"}
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@auxilium/datalynk-client",
3
3
  "description": "Datalynk client library",
4
4
  "repository": "https://gitlab.auxiliumgroup.com/auxilium/datalynk/datalynk-client",
5
- "version": "1.0.16",
5
+ "version": "1.0.18",
6
6
  "author": "Zak Timson <zaktimson@gmail.com>",
7
7
  "private": false,
8
8
  "main": "./dist/index.cjs",
@@ -25,8 +25,8 @@
25
25
  "watch": "vite build --watch"
26
26
  },
27
27
  "dependencies": {
28
- "@ztimson/node-utils": "^1.0.0",
29
- "@ztimson/utils": "^0.23.22",
28
+ "@ztimson/node-utils": "1.0.0",
29
+ "@ztimson/utils": "0.25.7",
30
30
  "rxjs": "^7.8.2"
31
31
  },
32
32
  "devDependencies": {