@linagora/linid-im-front-corelib 0.0.25 → 0.0.26

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,7 +1,7 @@
1
1
  import * as $t from "vue";
2
2
  import { defineAsyncComponent as no, hasInjectionContext as Kt, inject as lt, getCurrentInstance as ro, ref as Ke, reactive as oo, markRaw as He, effectScope as so, isRef as Xe, isReactive as En, toRef as xt, toRaw as io, nextTick as An, computed as ge, getCurrentScope as ao, onScopeDispose as co, watch as Xt, toRefs as Pn, defineComponent as vt, watchEffect as lo, createElementBlock as Dn, openBlock as Wt, Fragment as ut, renderSlot as uo, createCommentVNode as fo, renderList as _o, createBlock as mo, resolveDynamicComponent as po, mergeProps as Eo, createElementVNode as ho, shallowRef as No, onMounted as go, onUnmounted as bo, h as Nr, createVNode as Oo, Text as vo } from "vue";
3
3
  let ft = null;
4
- function Oa(e) {
4
+ function va(e) {
5
5
  if (ft !== null) {
6
6
  console.warn(
7
7
  "[LinID CoreLib] Module Federation has already been initialized. Re-initialization is ignored."
@@ -325,7 +325,7 @@ This will fail in production.`);
325
325
  return s.$id = e, s;
326
326
  }
327
327
  let _t = null;
328
- function va(e) {
328
+ function ya(e) {
329
329
  if (_t !== null) {
330
330
  console.warn(
331
331
  "[LinID CoreLib] Pinia store has already been initialized. Re-initialization is ignored."
@@ -355,7 +355,7 @@ const Co = () => Ao(Nn()), Ao = /* @__PURE__ */ hn("linidZoneStore", {
355
355
  this.zones[e] || (this.zones[e] = []), this.zones[e].push(t);
356
356
  }
357
357
  }
358
- }), ya = /* @__PURE__ */ vt({
358
+ }), La = /* @__PURE__ */ vt({
359
359
  __name: "LinidZoneRenderer",
360
360
  props: {
361
361
  zone: {}
@@ -381,7 +381,7 @@ const Co = () => Ao(Nn()), Ao = /* @__PURE__ */ hn("linidZoneStore", {
381
381
  ], 64));
382
382
  }
383
383
  });
384
- function La() {
384
+ function Ta() {
385
385
  function e(n) {
386
386
  return {
387
387
  page: (n.page || 1) - 1,
@@ -3146,7 +3146,7 @@ if (process.env.NODE_ENV !== "production" || __INTLIFY_PROD_DEVTOOLS__) {
3146
3146
  }
3147
3147
  process.env.NODE_ENV;
3148
3148
  let Nt = null;
3149
- function Ta(e) {
3149
+ function Ia(e) {
3150
3150
  if (Nt !== null) {
3151
3151
  console.warn(
3152
3152
  "[LinID CoreLib] I18n has already been initialized. Re-initialization is ignored."
@@ -3162,7 +3162,7 @@ function Fi() {
3162
3162
  );
3163
3163
  return Nt;
3164
3164
  }
3165
- function Ia(e) {
3165
+ function Sa(e) {
3166
3166
  const { t, te: n, tm: r } = St({
3167
3167
  useScope: "global",
3168
3168
  __i18n: Fi().global
@@ -3188,7 +3188,7 @@ function Ia(e) {
3188
3188
  };
3189
3189
  }
3190
3190
  let gt = null;
3191
- function Sa(e) {
3191
+ function Ca(e) {
3192
3192
  if (gt !== null) {
3193
3193
  console.warn(
3194
3194
  "[LinID CoreLib] UI Design has already been initialized. Re-initialization is ignored."
@@ -3349,6 +3349,18 @@ const Vi = [
3349
3349
  "dense",
3350
3350
  "itemAligned",
3351
3351
  "noErrorIcon"
3352
+ ], Zi = [
3353
+ "landscape",
3354
+ "yearsInMonthView",
3355
+ "todayBtn",
3356
+ "minimal",
3357
+ "defaultView",
3358
+ "color",
3359
+ "textColor",
3360
+ "dark",
3361
+ "square",
3362
+ "flat",
3363
+ "bordered"
3352
3364
  ], fr = {
3353
3365
  "q-btn": Vi,
3354
3366
  "q-tabs": $i,
@@ -3363,7 +3375,8 @@ const Vi = [
3363
3375
  "q-card-actions": Xi,
3364
3376
  "q-icon": qi,
3365
3377
  "q-toggle": Qi,
3366
- "q-input": Ji
3378
+ "q-input": Ji,
3379
+ "q-date": Zi
3367
3380
  };
3368
3381
  function dr(e, t) {
3369
3382
  return t.split(".").reduce((n, r) => {
@@ -3371,7 +3384,7 @@ function dr(e, t) {
3371
3384
  return n[r];
3372
3385
  }, e);
3373
3386
  }
3374
- function Zi(e, t, n) {
3387
+ function zi(e, t, n) {
3375
3388
  let r = dr(e, `${t}.${n}`);
3376
3389
  if (r === void 0 && (r = dr(e, `default.${n}`)), typeof r == "object")
3377
3390
  throw new Error(
@@ -3379,19 +3392,19 @@ function Zi(e, t, n) {
3379
3392
  );
3380
3393
  return r;
3381
3394
  }
3382
- function zi(e) {
3395
+ function ea(e) {
3383
3396
  if (!(e in fr))
3384
3397
  throw new Error(
3385
3398
  `[UiDesign] The component '${e}' is not supported for UI design retrieval.`
3386
3399
  );
3387
3400
  return fr[e];
3388
3401
  }
3389
- function Ca() {
3402
+ function Aa() {
3390
3403
  const e = ge(() => Ui());
3391
3404
  function t(n, r, o) {
3392
- const s = zi(r), i = {};
3405
+ const s = ea(r), i = {};
3393
3406
  for (const l of s) {
3394
- const u = o?.[l] ?? Zi(e.value, n, `${r}.${String(l)}`);
3407
+ const u = o?.[l] ?? zi(e.value, n, `${r}.${String(l)}`);
3395
3408
  u !== void 0 && (i[l] = u);
3396
3409
  }
3397
3410
  return i;
@@ -3565,9 +3578,9 @@ function Jr(e) {
3565
3578
  function _r(e) {
3566
3579
  Ee(e) ? e() : e.unsubscribe();
3567
3580
  }
3568
- var ea = {
3581
+ var ta = {
3569
3582
  Promise: void 0
3570
- }, ta = {
3583
+ }, na = {
3571
3584
  setTimeout: function(e, t) {
3572
3585
  for (var n = [], r = 2; r < arguments.length; r++)
3573
3586
  n[r - 2] = arguments[r];
@@ -3578,8 +3591,8 @@ var ea = {
3578
3591
  },
3579
3592
  delegate: void 0
3580
3593
  };
3581
- function na(e) {
3582
- ta.setTimeout(function() {
3594
+ function ra(e) {
3595
+ na.setTimeout(function() {
3583
3596
  throw e;
3584
3597
  });
3585
3598
  }
@@ -3592,7 +3605,7 @@ var Zr = (function(e) {
3592
3605
  Ct(t, e);
3593
3606
  function t(n) {
3594
3607
  var r = e.call(this) || this;
3595
- return r.isStopped = !1, n ? (r.destination = n, Jr(n) && n.add(r)) : r.destination = sa, r;
3608
+ return r.isStopped = !1, n ? (r.destination = n, Jr(n) && n.add(r)) : r.destination = ia, r;
3596
3609
  }
3597
3610
  return t.create = function(n, r, o) {
3598
3611
  return new pn(n, r, o);
@@ -3619,7 +3632,7 @@ var Zr = (function(e) {
3619
3632
  this.unsubscribe();
3620
3633
  }
3621
3634
  }, t;
3622
- })(At), ra = (function() {
3635
+ })(At), oa = (function() {
3623
3636
  function e(t) {
3624
3637
  this.partialObserver = t;
3625
3638
  }
@@ -3658,29 +3671,29 @@ var Zr = (function(e) {
3658
3671
  next: n ?? void 0,
3659
3672
  error: r ?? void 0,
3660
3673
  complete: o ?? void 0
3661
- } : i = n, s.destination = new ra(i), s;
3674
+ } : i = n, s.destination = new oa(i), s;
3662
3675
  }
3663
3676
  return t;
3664
3677
  })(Zr);
3665
3678
  function it(e) {
3666
- na(e);
3679
+ ra(e);
3667
3680
  }
3668
- function oa(e) {
3681
+ function sa(e) {
3669
3682
  throw e;
3670
3683
  }
3671
- var sa = {
3684
+ var ia = {
3672
3685
  closed: !0,
3673
3686
  next: mr,
3674
- error: oa,
3687
+ error: sa,
3675
3688
  complete: mr
3676
- }, ia = (function() {
3689
+ }, aa = (function() {
3677
3690
  return typeof Symbol == "function" && Symbol.observable || "@@observable";
3678
3691
  })();
3679
- function aa(e) {
3692
+ function ca(e) {
3680
3693
  return e;
3681
3694
  }
3682
- function ca(e) {
3683
- return e.length === 0 ? aa : e.length === 1 ? e[0] : function(n) {
3695
+ function la(e) {
3696
+ return e.length === 0 ? ca : e.length === 1 ? e[0] : function(n) {
3684
3697
  return e.reduce(function(r, o) {
3685
3698
  return o(r);
3686
3699
  }, n);
@@ -3694,7 +3707,7 @@ var pr = (function() {
3694
3707
  var n = new e();
3695
3708
  return n.source = this, n.operator = t, n;
3696
3709
  }, e.prototype.subscribe = function(t, n, r) {
3697
- var o = this, s = ua(t) ? t : new pn(t, n, r);
3710
+ var o = this, s = fa(t) ? t : new pn(t, n, r);
3698
3711
  return ct(function() {
3699
3712
  var i = o, l = i.operator, u = i.source;
3700
3713
  s.add(l ? l.call(s, u) : u ? o._subscribe(s) : o._trySubscribe(s));
@@ -3724,12 +3737,12 @@ var pr = (function() {
3724
3737
  }, e.prototype._subscribe = function(t) {
3725
3738
  var n;
3726
3739
  return (n = this.source) === null || n === void 0 ? void 0 : n.subscribe(t);
3727
- }, e.prototype[ia] = function() {
3740
+ }, e.prototype[aa] = function() {
3728
3741
  return this;
3729
3742
  }, e.prototype.pipe = function() {
3730
3743
  for (var t = [], n = 0; n < arguments.length; n++)
3731
3744
  t[n] = arguments[n];
3732
- return ca(t)(this);
3745
+ return la(t)(this);
3733
3746
  }, e.prototype.toPromise = function(t) {
3734
3747
  var n = this;
3735
3748
  return t = Er(t), new t(function(r, o) {
@@ -3748,15 +3761,15 @@ var pr = (function() {
3748
3761
  })();
3749
3762
  function Er(e) {
3750
3763
  var t;
3751
- return (t = e ?? ea.Promise) !== null && t !== void 0 ? t : Promise;
3764
+ return (t = e ?? ta.Promise) !== null && t !== void 0 ? t : Promise;
3752
3765
  }
3753
- function la(e) {
3766
+ function ua(e) {
3754
3767
  return e && Ee(e.next) && Ee(e.error) && Ee(e.complete);
3755
3768
  }
3756
- function ua(e) {
3757
- return e && e instanceof Zr || la(e) && Jr(e);
3769
+ function fa(e) {
3770
+ return e && e instanceof Zr || ua(e) && Jr(e);
3758
3771
  }
3759
- var fa = qr(function(e) {
3772
+ var da = qr(function(e) {
3760
3773
  return function() {
3761
3774
  e(this), this.name = "ObjectUnsubscribedError", this.message = "object unsubscribed";
3762
3775
  };
@@ -3771,7 +3784,7 @@ var fa = qr(function(e) {
3771
3784
  return r.operator = n, r;
3772
3785
  }, t.prototype._throwIfClosed = function() {
3773
3786
  if (this.closed)
3774
- throw new fa();
3787
+ throw new da();
3775
3788
  }, t.prototype.next = function(n) {
3776
3789
  var r = this;
3777
3790
  ct(function() {
@@ -3859,10 +3872,10 @@ var fa = qr(function(e) {
3859
3872
  return (o = (r = this.source) === null || r === void 0 ? void 0 : r.subscribe(n)) !== null && o !== void 0 ? o : Qr;
3860
3873
  }, t;
3861
3874
  })(zr);
3862
- const da = new zr();
3863
- function Aa() {
3875
+ const _a = new zr();
3876
+ function Pa() {
3864
3877
  function e(t) {
3865
- da.next({
3878
+ _a.next({
3866
3879
  key: "notify",
3867
3880
  type: "open",
3868
3881
  data: t
@@ -3871,7 +3884,7 @@ function Aa() {
3871
3884
  return { Notify: e };
3872
3885
  }
3873
3886
  let bt = null;
3874
- function Pa(e) {
3887
+ function Da(e) {
3875
3888
  if (bt !== null) {
3876
3889
  console.warn(
3877
3890
  "[LinID CoreLib] HTTP client has already been initialized. Re-initialization is ignored."
@@ -3887,15 +3900,15 @@ function De() {
3887
3900
  );
3888
3901
  return bt;
3889
3902
  }
3890
- async function _a() {
3903
+ async function ma() {
3891
3904
  return (await De().get("/metadata/entities")).data;
3892
3905
  }
3893
- async function ma() {
3906
+ async function pa() {
3894
3907
  return (await De().get(
3895
3908
  "/metadata/routes"
3896
3909
  )).data;
3897
3910
  }
3898
- const Da = () => pa(Nn()), pa = /* @__PURE__ */ hn("LinidConfigurationStore", {
3911
+ const Ra = () => Ea(Nn()), Ea = /* @__PURE__ */ hn("LinidConfigurationStore", {
3899
3912
  state: () => ({
3900
3913
  entities: [],
3901
3914
  apiEndpoints: [],
@@ -3926,8 +3939,8 @@ const Da = () => pa(Nn()), pa = /* @__PURE__ */ hn("LinidConfigurationStore", {
3926
3939
  this.loading = !0, this.error = null;
3927
3940
  try {
3928
3941
  const [e, t] = await Promise.all([
3929
- _a(),
3930
- ma()
3942
+ ma(),
3943
+ pa()
3931
3944
  ]);
3932
3945
  this.entities = e, this.apiEndpoints = t;
3933
3946
  } catch (e) {
@@ -3937,7 +3950,7 @@ const Da = () => pa(Nn()), pa = /* @__PURE__ */ hn("LinidConfigurationStore", {
3937
3950
  }
3938
3951
  }
3939
3952
  }
3940
- }), Ra = () => Ea(Nn()), Ea = /* @__PURE__ */ hn("LinidUiStore", {
3953
+ }), ka = () => ha(Nn()), ha = /* @__PURE__ */ hn("LinidUiStore", {
3941
3954
  state: () => ({
3942
3955
  mainNavigationItems: []
3943
3956
  }),
@@ -3951,7 +3964,7 @@ const Da = () => pa(Nn()), pa = /* @__PURE__ */ hn("LinidConfigurationStore", {
3951
3964
  }
3952
3965
  }
3953
3966
  }), eo = /* @__PURE__ */ new Map();
3954
- function ka(e) {
3967
+ function wa(e) {
3955
3968
  eo.set(e.instanceId, e);
3956
3969
  }
3957
3970
  function ze(e) {
@@ -3962,37 +3975,37 @@ function ze(e) {
3962
3975
  );
3963
3976
  return t;
3964
3977
  }
3965
- async function wa(e, t) {
3978
+ async function Ma(e, t) {
3966
3979
  const n = ze(e);
3967
3980
  return De().post(`/${n.apiEndpoint}`, t).then(({ data: r }) => r);
3968
3981
  }
3969
- async function Ma(e, t, n) {
3982
+ async function Fa(e, t, n) {
3970
3983
  const r = ze(e);
3971
3984
  return De().put(`/${r.apiEndpoint}/${t}`, n).then(({ data: o }) => o);
3972
3985
  }
3973
- async function Fa(e, t, n) {
3986
+ async function Ua(e, t, n) {
3974
3987
  const r = ze(e);
3975
3988
  return De().get(`/${r.apiEndpoint}`, {
3976
3989
  params: { ...t, ...n }
3977
3990
  }).then(({ data: o }) => o);
3978
3991
  }
3979
- async function Ua(e, t) {
3992
+ async function Va(e, t) {
3980
3993
  const n = ze(e);
3981
3994
  return De().get(`/${n.apiEndpoint}/${t}`).then(({ data: r }) => r);
3982
3995
  }
3983
- async function Va(e, t) {
3996
+ async function $a(e, t) {
3984
3997
  const n = ze(e);
3985
3998
  return De().delete(`/${n.apiEndpoint}/${t}`);
3986
3999
  }
3987
- function ha(e, t) {
4000
+ function Na(e, t) {
3988
4001
  if (!Ot(e) || !Ot(t))
3989
4002
  return t;
3990
4003
  const n = { ...e };
3991
4004
  for (const r of Object.keys(t))
3992
- n[r] = ha(e[r], t[r]);
4005
+ n[r] = Na(e[r], t[r]);
3993
4006
  return n;
3994
4007
  }
3995
- function $a(e) {
4008
+ function xa(e) {
3996
4009
  const t = {};
3997
4010
  for (const [n, r] of Object.entries(e)) {
3998
4011
  const o = n.split(".");
@@ -4006,16 +4019,16 @@ function $a(e) {
4006
4019
  function Ot(e) {
4007
4020
  return typeof e == "object" && e !== null && !Array.isArray(e);
4008
4021
  }
4009
- function Na(e, t) {
4022
+ function ga(e, t) {
4010
4023
  return typeof e != "object" || e === null ? e : Object.fromEntries(
4011
4024
  Object.entries(e).map(([n, r]) => {
4012
- const o = t(n), s = Ot(r) ? Na(r, t) : r;
4025
+ const o = t(n), s = Ot(r) ? ga(r, t) : r;
4013
4026
  return [o, s];
4014
4027
  })
4015
4028
  );
4016
4029
  }
4017
- var ga = /* @__PURE__ */ ((e) => (e.SETUP = "setup", e.CONFIGURE = "configure", e.INITIALIZE = "initialize", e.READY = "ready", e.POST_INIT = "postInit", e))(ga || {});
4018
- class xa {
4030
+ var ba = /* @__PURE__ */ ((e) => (e.SETUP = "setup", e.CONFIGURE = "configure", e.INITIALIZE = "initialize", e.READY = "ready", e.POST_INIT = "postInit", e))(ba || {});
4031
+ class Wa {
4019
4032
  /**
4020
4033
  * Unique identifier for the module.
4021
4034
  *
@@ -4119,13 +4132,13 @@ class xa {
4119
4132
  }
4120
4133
  }
4121
4134
  export {
4122
- xa as BasicRemoteModule,
4123
- ya as LinidZoneRenderer,
4124
- ga as ModuleLifecyclePhase,
4125
- Va as deleteEntityById,
4126
- $a as fromDot,
4127
- Fa as getEntities,
4128
- Ua as getEntityById,
4135
+ Wa as BasicRemoteModule,
4136
+ La as LinidZoneRenderer,
4137
+ ba as ModuleLifecyclePhase,
4138
+ $a as deleteEntityById,
4139
+ xa as fromDot,
4140
+ Ua as getEntities,
4141
+ Va as getEntityById,
4129
4142
  De as getHttpClient,
4130
4143
  Fi as getI18nInstance,
4131
4144
  yo as getModuleFederation,
@@ -4134,22 +4147,22 @@ export {
4134
4147
  Ui as getUiDesign,
4135
4148
  Ot as isObject,
4136
4149
  Lo as loadAsyncComponent,
4137
- ha as merge,
4138
- ka as registerModuleHostConfiguration,
4139
- Na as renameKeys,
4140
- wa as saveEntity,
4141
- Pa as setHttpClient,
4142
- Ta as setI18nInstance,
4143
- Oa as setModuleFederation,
4144
- va as setPiniaStore,
4145
- Sa as setUiDesign,
4146
- da as uiEventSubject,
4147
- Ma as updateEntity,
4148
- Da as useLinidConfigurationStore,
4149
- Ra as useLinidUiStore,
4150
+ Na as merge,
4151
+ wa as registerModuleHostConfiguration,
4152
+ ga as renameKeys,
4153
+ Ma as saveEntity,
4154
+ Da as setHttpClient,
4155
+ Ia as setI18nInstance,
4156
+ va as setModuleFederation,
4157
+ ya as setPiniaStore,
4158
+ Ca as setUiDesign,
4159
+ _a as uiEventSubject,
4160
+ Fa as updateEntity,
4161
+ Ra as useLinidConfigurationStore,
4162
+ ka as useLinidUiStore,
4150
4163
  Co as useLinidZoneStore,
4151
- Aa as useNotify,
4152
- La as usePagination,
4153
- Ia as useScopedI18n,
4154
- Ca as useUiDesign
4164
+ Pa as useNotify,
4165
+ Ta as usePagination,
4166
+ Sa as useScopedI18n,
4167
+ Aa as useUiDesign
4155
4168
  };