bt-core-app 1.4.441 → 1.4.443

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.
@@ -8250,19 +8250,18 @@ function bx(e) {
8250
8250
  }
8251
8251
  async function u() {
8252
8252
  return e.testToken ?? (e.testToken = async () => {
8253
- var V;
8254
8253
  let b = l.value.token, T = !1;
8255
8254
  const D = e.getTokenTestUrl ?? (() => on(gu(), "test"));
8256
8255
  if (b != null) {
8257
- const N = await Rr().post({
8256
+ const L = await Rr().post({
8258
8257
  additionalUrl: D(b),
8259
8258
  data: {
8260
8259
  token: b
8261
8260
  }
8262
8261
  });
8263
- console.log("test result"), console.log(N), N.data === !0 && (T = !0);
8262
+ console.log("test result"), console.log(L), L.data === !0 && (T = !0);
8264
8263
  }
8265
- return T ? !0 : (v(), e.tokenInvalidRouteName != null && ((V = e == null ? void 0 : e.router) == null || V.push({ name: e.tokenInvalidRouteName })), !1);
8264
+ return T ? !0 : (v(e.tokenInvalidPath), !1);
8266
8265
  }), await e.testToken();
8267
8266
  }
8268
8267
  async function w(b, T) {
@@ -8673,19 +8672,24 @@ function Sx(e) {
8673
8672
  localStorage.setItem("cosmetics", JSON.stringify(t.value));
8674
8673
  }
8675
8674
  function r(m) {
8676
- n != null && (n.global.name.value = t.value.theme, n.global.name.value == "dark" ? (m && (t.value.dark = { ...bu, ...e.defaultDarkTheme }), n.themes.value.dark = {
8677
- ...n.themes.value.dark,
8678
- colors: {
8679
- ...n.themes.value.dark.colors,
8680
- ...t.value.dark
8681
- }
8682
- }) : (m && (t.value.light = { ...pu, ...e.defaultLightTheme }), n.themes.value.light = {
8683
- ...n.themes.value.light,
8684
- colors: {
8685
- ...n.themes.value.light.colors,
8686
- ...t.value.light
8687
- }
8688
- }), l());
8675
+ var h;
8676
+ if (n != null) {
8677
+ n.global.name.value = t.value.theme;
8678
+ let v;
8679
+ n.global.name.value == "dark" ? (m && (t.value.dark = { ...bu, ...e.defaultDarkTheme }), n.themes.value.dark = {
8680
+ ...n.themes.value.dark,
8681
+ colors: {
8682
+ ...n.themes.value.dark.colors,
8683
+ ...t.value.dark
8684
+ }
8685
+ }, v = n.themes.value.dark.colors.primary) : (m && (t.value.light = { ...pu, ...e.defaultLightTheme }), n.themes.value.light = {
8686
+ ...n.themes.value.light,
8687
+ colors: {
8688
+ ...n.themes.value.light.colors,
8689
+ ...t.value.light
8690
+ }
8691
+ }, v = n.themes.value.light.colors.primary), (h = document.querySelector('meta[name="theme-color"]')) == null || h.setAttribute("content", v), l();
8692
+ }
8689
8693
  }
8690
8694
  function i(m) {
8691
8695
  var h;
@@ -40339,16 +40343,16 @@ const $E = /* @__PURE__ */ Je({
40339
40343
  function FV(e) {
40340
40344
  return {
40341
40345
  install(t, n) {
40342
- var c, f, m, h, v;
40346
+ var c, f, m, h, v, g;
40343
40347
  e.includeComponents == !0 && (t.component("bt-avatar", mI), t.component("bt-blade-item", vI), t.component("bt-blade-items", Ep), t.component("bt-blade", CI), t.component("bt-btn", _I), t.component("bt-camera-overlay", DI), t.component("bt-col", AI), t.component("bt-cosmetics-menu", II), t.component("bt-cron", RI), t.component("bt-date", w1), t.component("bt-drag-counter", UI), t.component("bt-entity", qI), t.component("bt-field-checkbox", GI), t.component("bt-field-date", ZI), t.component("bt-field-entity", KI), t.component("bt-field-select", XI), t.component("bt-field-string", JI), t.component("bt-field-switch", QI), t.component("bt-field-tags", e5), t.component("bt-field-text-area", t5), t.component("bt-field-trigger", i5), t.component("bt-header-option", u5), t.component("bt-image-uploader", gE), t.component("bt-json", pE), t.component("bt-loader", bE), t.component("bt-nav-sidebar", wE), t.component("bt-number", x1), t.component("bt-numpad", xE), t.component("bt-select-inline", DE), t.component("bt-select-list-box", AE), t.component("bt-select", LE), t.component("bt-signature", $E), t.component("bt-signature-overlay", BE), t.component("bt-slider", NE), t.component("bt-span", FE)), e.cosmetics ?? (e.cosmetics = {}), (c = e.cosmetics).vuetifyInstance ?? (c.vuetifyInstance = n.vuetifyInstance);
40344
40348
  const a = mx(e.urls);
40345
40349
  Sx(e.cosmetics);
40346
40350
  const l = nM(e.navigation ?? {});
40347
40351
  e.heights ?? (e.heights = {}), (f = e.heights).display ?? (f.display = n.vuetifyDisplay), (m = e.heights).navigation ?? (m.navigation = l), nf(e.heights);
40348
40352
  const r = oI(e.menu);
40349
- lM(e), (h = e.auth).menu ?? (h.menu = r), e.auth.getAuthItem = l.findItem;
40353
+ lM(e), (h = e.auth).menu ?? (h.menu = r), (v = e.auth).router ?? (v.router = n.router), e.auth.getAuthItem = l.findItem;
40350
40354
  const i = bx(e.auth);
40351
- e.demo != null && ((v = e.demo).auth ?? (v.auth = i));
40355
+ e.demo != null && ((g = e.demo).auth ?? (g.auth = i));
40352
40356
  const o = Jx(e.demo), s = px({
40353
40357
  ...e.api,
40354
40358
  auth: i,
package/dist/index.d.ts CHANGED
@@ -368,7 +368,7 @@ export declare interface CreateAuthOptions {
368
368
  /**tests whether token is still valid after receiving a 401 Unauthorized Response */
369
369
  testToken?: (code?: string) => Promise<boolean>;
370
370
  /**where to route to if token is no longer valid */
371
- tokenInvalidRouteName?: string;
371
+ tokenInvalidPath?: string;
372
372
  }
373
373
 
374
374
  export declare function createCore(options: CreateCoreOptions): CoreApp;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "bt-core-app",
3
- "version": "1.4.441",
3
+ "version": "1.4.443",
4
4
  "description": "Core app tools for some basic features like navigation, authentication, server apis, and cosmetics",
5
5
  "homepage": "https://github.com/BlitzItTech/bt-core",
6
6
  "bugs": {