@limetech/lime-web-components 6.8.0 → 6.10.0

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/index.d.ts CHANGED
@@ -49,4 +49,5 @@ export * from './notification-service';
49
49
  export * from './poller';
50
50
  export * from './logger';
51
51
  export * from './problem';
52
+ export * from './ai-context';
52
53
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAEH,cAAc,UAAU,CAAC;AACzB,cAAc,QAAQ,CAAC;AACvB,cAAc,YAAY,CAAC;AAC3B,cAAc,cAAc,CAAC;AAC7B,cAAc,SAAS,CAAC;AACxB,cAAc,QAAQ,CAAC;AACvB,cAAc,cAAc,CAAC;AAC7B,cAAc,mBAAmB,CAAC;AAClC,cAAc,cAAc,CAAC;AAC7B,cAAc,UAAU,CAAC;AACzB,cAAc,eAAe,CAAC;AAC9B,cAAc,aAAa,CAAC;AAC5B,cAAc,iBAAiB,CAAC;AAChC,cAAc,iBAAiB,CAAC;AAChC,cAAc,QAAQ,CAAC;AACvB,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,YAAY,CAAC;AAC3B,cAAc,eAAe,CAAC;AAC9B,cAAc,mBAAmB,CAAC;AAClC,cAAc,qBAAqB,CAAC;AACpC,cAAc,qBAAqB,CAAC;AACpC,cAAc,QAAQ,CAAC;AACvB,cAAc,gBAAgB,CAAC;AAC/B,cAAc,wBAAwB,CAAC;AACvC,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC;AAC1B,OAAO,SAAS,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAEH,cAAc,UAAU,CAAC;AACzB,cAAc,QAAQ,CAAC;AACvB,cAAc,YAAY,CAAC;AAC3B,cAAc,cAAc,CAAC;AAC7B,cAAc,SAAS,CAAC;AACxB,cAAc,QAAQ,CAAC;AACvB,cAAc,cAAc,CAAC;AAC7B,cAAc,mBAAmB,CAAC;AAClC,cAAc,cAAc,CAAC;AAC7B,cAAc,UAAU,CAAC;AACzB,cAAc,eAAe,CAAC;AAC9B,cAAc,aAAa,CAAC;AAC5B,cAAc,iBAAiB,CAAC;AAChC,cAAc,iBAAiB,CAAC;AAChC,cAAc,QAAQ,CAAC;AACvB,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,YAAY,CAAC;AAC3B,cAAc,eAAe,CAAC;AAC9B,cAAc,mBAAmB,CAAC;AAClC,cAAc,qBAAqB,CAAC;AACpC,cAAc,qBAAqB,CAAC;AACpC,cAAc,QAAQ,CAAC;AACvB,cAAc,gBAAgB,CAAC;AAC/B,cAAc,wBAAwB,CAAC;AACvC,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC;AAC1B,cAAc,cAAc,CAAC;AAC7B,OAAO,SAAS,CAAC"}
package/dist/index.esm.js CHANGED
@@ -1,8 +1,8 @@
1
1
  import { getElement as q, setErrorHandler as it } from "@stencil/core";
2
2
  const c = {
3
3
  Route: "route"
4
- }, Ge = "idle-state";
5
- function Qe(t) {
4
+ }, Qe = "idle-state";
5
+ function Ye(t) {
6
6
  return t && [
7
7
  "belongsto",
8
8
  "hasone",
@@ -10,10 +10,10 @@ function Qe(t) {
10
10
  "hasandbelongstomany"
11
11
  ].includes(t.type);
12
12
  }
13
- function Ye(t) {
13
+ function qe(t) {
14
14
  return t && ["belongsto", "hasone"].includes(t.type);
15
15
  }
16
- function qe(t) {
16
+ function Ke(t) {
17
17
  return t && [
18
18
  "time",
19
19
  "timeofday",
@@ -23,31 +23,31 @@ function qe(t) {
23
23
  "month"
24
24
  ].includes(t.type);
25
25
  }
26
- function Ke(t) {
26
+ function Xe(t) {
27
27
  return t && ["string", "text", "phone", "link"].includes(t.type);
28
28
  }
29
- function Xe(t) {
29
+ function Je(t) {
30
30
  return t && ["decimal", "percent"].includes(t.type);
31
31
  }
32
32
  const st = "state.limetypes";
33
33
  c.LimeTypeRepository = st;
34
- var O = function(t, e) {
35
- return O = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(r, n) {
34
+ var A = function(t, e) {
35
+ return A = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(r, n) {
36
36
  r.__proto__ = n;
37
37
  } || function(r, n) {
38
38
  for (var o in n) Object.prototype.hasOwnProperty.call(n, o) && (r[o] = n[o]);
39
- }, O(t, e);
39
+ }, A(t, e);
40
40
  };
41
41
  function m(t, e) {
42
42
  if (typeof e != "function" && e !== null)
43
43
  throw new TypeError("Class extends value " + String(e) + " is not a constructor or null");
44
- O(t, e);
44
+ A(t, e);
45
45
  function r() {
46
46
  this.constructor = t;
47
47
  }
48
48
  t.prototype = e === null ? Object.create(e) : (r.prototype = e.prototype, new r());
49
49
  }
50
- function A(t) {
50
+ function O(t) {
51
51
  var e = typeof Symbol == "function" && Symbol.iterator, r = e && t[e], n = 0;
52
52
  if (r) return r.call(t);
53
53
  if (t && typeof t.length == "number") return {
@@ -115,7 +115,7 @@ var _ = (function() {
115
115
  if (s)
116
116
  if (this._parentage = null, Array.isArray(s))
117
117
  try {
118
- for (var u = A(s), a = u.next(); !a.done; a = u.next()) {
118
+ for (var u = O(s), a = u.next(); !a.done; a = u.next()) {
119
119
  var C = a.value;
120
120
  C.remove(this);
121
121
  }
@@ -137,14 +137,14 @@ var _ = (function() {
137
137
  } catch (f) {
138
138
  i = f instanceof w ? f.errors : [f];
139
139
  }
140
- var D = this._finalizers;
141
- if (D) {
140
+ var N = this._finalizers;
141
+ if (N) {
142
142
  this._finalizers = null;
143
143
  try {
144
- for (var b = A(D), y = b.next(); !y.done; y = b.next()) {
144
+ for (var b = O(N), y = b.next(); !y.done; y = b.next()) {
145
145
  var ot = y.value;
146
146
  try {
147
- N(ot);
147
+ D(ot);
148
148
  } catch (f) {
149
149
  i = i ?? [], f instanceof w ? i = I(I([], P(i)), P(f.errors)) : i.push(f);
150
150
  }
@@ -166,7 +166,7 @@ var _ = (function() {
166
166
  var r;
167
167
  if (e && e !== this)
168
168
  if (this.closed)
169
- N(e);
169
+ D(e);
170
170
  else {
171
171
  if (e instanceof t) {
172
172
  if (e.closed || e._hasParent(this))
@@ -195,7 +195,7 @@ var _ = (function() {
195
195
  function J(t) {
196
196
  return t instanceof _ || t && "closed" in t && p(t.remove) && p(t.add) && p(t.unsubscribe);
197
197
  }
198
- function N(t) {
198
+ function D(t) {
199
199
  p(t) ? t() : t.unsubscribe();
200
200
  }
201
201
  var ct = {
@@ -412,7 +412,7 @@ var vt = K(function(t) {
412
412
  if (n._throwIfClosed(), !n.isStopped) {
413
413
  n.currentObservers || (n.currentObservers = Array.from(n.observers));
414
414
  try {
415
- for (var s = A(n.currentObservers), u = s.next(); !u.done; u = s.next()) {
415
+ for (var s = O(n.currentObservers), u = s.next(); !u.done; u = s.next()) {
416
416
  var a = u.value;
417
417
  a.next(r);
418
418
  }
@@ -561,7 +561,7 @@ function et(t, e) {
561
561
  const n = new gt(this.context);
562
562
  Rt(this, "context", n);
563
563
  for (const o of e)
564
- o.options = o.optionFactory(o.options, this), wt(o.options) && (o.options.context = n), Ot(this, o);
564
+ o.options = o.optionFactory(o.options, this), wt(o.options) && (o.options.context = n), At(this, o);
565
565
  if (t)
566
566
  return t.apply(this, r);
567
567
  };
@@ -574,7 +574,7 @@ function Ct(t, e) {
574
574
  function U(t) {
575
575
  return async function(...e) {
576
576
  let r;
577
- return t && (r = t.apply(this, e)), At(this), r;
577
+ return t && (r = t.apply(this, e)), Ot(this), r;
578
578
  };
579
579
  }
580
580
  function wt(t) {
@@ -608,13 +608,13 @@ function Rt(t, e, r) {
608
608
  }
609
609
  });
610
610
  }
611
- function Ot(t, e) {
611
+ function At(t, e) {
612
612
  const r = It(t, e);
613
613
  if (typeof r != "function")
614
614
  return;
615
615
  S.get(t).push(r);
616
616
  }
617
- function At(t) {
617
+ function Ot(t) {
618
618
  const e = S.get(t);
619
619
  for (const r of e) r();
620
620
  S.set(t, []);
@@ -638,13 +638,13 @@ function It(t, e) {
638
638
  function jt(t, e) {
639
639
  t.filter && (t.filter = t.filter.map((r) => r.bind(e))), t.map && (t.map = t.map.map((r) => r.bind(e)));
640
640
  }
641
- function Je(t = {}) {
641
+ function Ze(t = {}) {
642
642
  const e = {
643
643
  name: c.LimeTypeRepository
644
644
  };
645
645
  return l(t, e);
646
646
  }
647
- function Ze(t = {}) {
647
+ function ze(t = {}) {
648
648
  const e = {
649
649
  name: c.LimeTypeRepository
650
650
  };
@@ -654,39 +654,39 @@ function xt(t) {
654
654
  const { limetype: e } = this.context;
655
655
  return t[e];
656
656
  }
657
- const ze = (t) => (e) => Object.values(e).find(nt(t));
658
- function tr(t, e) {
657
+ const tr = (t) => (e) => Object.values(e).find(nt(t));
658
+ function er(t, e) {
659
659
  return Object.values(t.properties).filter(
660
660
  (r) => r.type === e
661
661
  );
662
662
  }
663
- function er(t, e) {
663
+ function rr(t, e) {
664
664
  return Object.values(t.properties).find(nt(e));
665
665
  }
666
- function rr(t, e) {
666
+ function nr(t, e) {
667
667
  return t.properties[e];
668
668
  }
669
669
  const nt = (t) => (e) => e?.label === t, Mt = "state.limeobjects";
670
670
  c.LimeObjectRepository = Mt;
671
- function nr(t = {}) {
671
+ function or(t = {}) {
672
672
  const e = {
673
673
  name: c.LimeObjectRepository,
674
- optionFactory: Nt
674
+ optionFactory: Dt
675
675
  };
676
676
  return l(t, e);
677
677
  }
678
- function or(t = {}) {
678
+ function ir(t = {}) {
679
679
  const e = {
680
680
  name: c.LimeObjectRepository
681
681
  };
682
- return t.map = [Dt, ...t.map || []], t.context = null, l(t, e);
682
+ return t.map = [Nt, ...t.map || []], t.context = null, l(t, e);
683
683
  }
684
- function Dt(t) {
684
+ function Nt(t) {
685
685
  const { limetype: e, id: r } = this.context;
686
686
  if (t[e])
687
687
  return t[e].find((n) => n.id === r);
688
688
  }
689
- function Nt(t, e) {
689
+ function Dt(t, e) {
690
690
  return t.getLimetype && (t.limetype = t.getLimetype(e)), t;
691
691
  }
692
692
  var $t = /* @__PURE__ */ ((t) => (t.Received = "command.received", t.Handled = "command.handled", t.Failed = "command.failed", t))($t || {});
@@ -843,7 +843,7 @@ Q = te([
843
843
  })
844
844
  ], Q);
845
845
  var re = /* @__PURE__ */ ((t) => (t.AND = "AND", t.OR = "OR", t.NOT = "!", t.EQUALS = "=", t.NOT_EQUALS = "!=", t.GREATER = ">", t.LESS = "<", t.IN = "IN", t.BEGINS = "=?", t.LIKE = "?", t.LESS_OR_EQUAL = "<=", t.GREATER_OR_EQUAL = ">=", t.ENDS = "=$", t))(re || {});
846
- const ir = {
846
+ const sr = {
847
847
  Count: "COUNT",
848
848
  Sum: "SUM",
849
849
  Average: "AVG",
@@ -851,7 +851,7 @@ const ir = {
851
851
  Minimum: "MIN"
852
852
  }, ne = "query";
853
853
  c.Query = ne;
854
- const sr = {
854
+ const cr = {
855
855
  Get: "GET",
856
856
  Post: "POST",
857
857
  Put: "PUT",
@@ -869,7 +869,7 @@ const ue = "keybindingRegistry";
869
869
  c.KeybindingRegistry = ue;
870
870
  const ae = "navigator";
871
871
  c.Navigator = ae;
872
- function cr(t) {
872
+ function ur(t) {
873
873
  const e = {
874
874
  name: c.Navigator
875
875
  };
@@ -901,7 +901,7 @@ const be = "state.tasks";
901
901
  c.TaskRepository = be;
902
902
  const ve = "state.configs";
903
903
  c.ConfigRepository = ve;
904
- function ur(t) {
904
+ function ar(t) {
905
905
  const e = {
906
906
  name: c.ConfigRepository
907
907
  };
@@ -909,7 +909,7 @@ function ur(t) {
909
909
  }
910
910
  const ge = "state.device";
911
911
  c.Device = ge;
912
- function ar(t = {}) {
912
+ function lr(t = {}) {
913
913
  const e = {
914
914
  name: c.Device
915
915
  };
@@ -917,7 +917,7 @@ function ar(t = {}) {
917
917
  }
918
918
  const Ee = "state.filters";
919
919
  c.FilterRepository = Ee;
920
- function lr(t = {}) {
920
+ function fr(t = {}) {
921
921
  const e = {
922
922
  name: c.FilterRepository
923
923
  };
@@ -925,7 +925,7 @@ function lr(t = {}) {
925
925
  }
926
926
  const Se = "state.user-data";
927
927
  c.UserDataRepository = Se;
928
- function fr(t = {}) {
928
+ function pr(t = {}) {
929
929
  const e = {
930
930
  name: c.UserDataRepository
931
931
  };
@@ -933,7 +933,7 @@ function fr(t = {}) {
933
933
  }
934
934
  const _e = "state.application";
935
935
  c.Application = _e;
936
- function pr(t = {}) {
936
+ function hr(t = {}) {
937
937
  const e = {
938
938
  name: c.Application
939
939
  };
@@ -942,7 +942,7 @@ function pr(t = {}) {
942
942
  function Ce(t) {
943
943
  return t.applicationName;
944
944
  }
945
- function hr(t = {}) {
945
+ function dr(t = {}) {
946
946
  const e = {
947
947
  name: c.Application
948
948
  };
@@ -951,7 +951,7 @@ function hr(t = {}) {
951
951
  function we(t) {
952
952
  return t.currentUser;
953
953
  }
954
- function dr(t = {}) {
954
+ function yr(t = {}) {
955
955
  const e = {
956
956
  name: c.Application
957
957
  };
@@ -960,14 +960,14 @@ function dr(t = {}) {
960
960
  function Re(t) {
961
961
  return t.session;
962
962
  }
963
- const Oe = "userPreferences";
964
- c.UserPreferencesRepository = Oe;
965
- const Ae = "datetimeformatter";
966
- c.DateTimeFormatter = Ae;
967
- function yr(t) {
963
+ const Ae = "userPreferences";
964
+ c.UserPreferencesRepository = Ae;
965
+ const Oe = "datetimeformatter";
966
+ c.DateTimeFormatter = Oe;
967
+ function mr(t) {
968
968
  return t.type === "limeobject";
969
969
  }
970
- function mr(t) {
970
+ function br(t) {
971
971
  return t.type === "action";
972
972
  }
973
973
  const Pe = "conditionRegistry";
@@ -980,15 +980,15 @@ const xe = "state.notifications";
980
980
  c.NotificationRepository = xe;
981
981
  const Me = "pollerFactory";
982
982
  c.PollerFactory = Me;
983
- const br = {
983
+ const vr = {
984
984
  Debug: "debug",
985
985
  Info: "info",
986
986
  Warn: "warn",
987
987
  Error: "error"
988
- }, De = "logger";
989
- c.Logger = De;
988
+ }, Ne = "logger";
989
+ c.Logger = Ne;
990
990
  let h, g;
991
- function Ne(t) {
991
+ function De(t) {
992
992
  const e = window.Lime?.logger?.createLogger;
993
993
  return typeof e != "function" ? (console.warn(
994
994
  `Logger factory is not configured. Returning console logger for scope "${t}".`
@@ -1038,70 +1038,72 @@ function ke(t) {
1038
1038
  const e = /\/static\/([^/]+)\//, r = t.match(e);
1039
1039
  return r ? r[1] : null;
1040
1040
  }
1041
- const vr = {
1041
+ const gr = {
1042
1042
  Low: "low",
1043
1043
  Medium: "medium",
1044
1044
  High: "high",
1045
1045
  Critical: "critical"
1046
1046
  }, Be = "problemRepository";
1047
1047
  c.ProblemRepository = Be;
1048
+ const He = "aiContextRegistry";
1049
+ c.AIContextRegistry = He;
1048
1050
  let R = null;
1049
- function He(t, e) {
1050
- R || (R = Ne("uncaught-error"));
1051
+ function We(t, e) {
1052
+ R || (R = De("uncaught-error"));
1051
1053
  const r = {};
1052
1054
  e && (r.element = e.tagName, e.id && (r.elementId = e.id));
1053
1055
  const n = t instanceof Error ? t.message : String(t), o = t instanceof Error ? t : void 0;
1054
1056
  R.error(n, o, r);
1055
1057
  }
1056
1058
  try {
1057
- it(He);
1059
+ it(We);
1058
1060
  } catch {
1059
1061
  }
1060
1062
  export {
1061
- ir as AggregateOperator,
1063
+ sr as AggregateOperator,
1062
1064
  B as BulkCreateDialogCommand,
1063
1065
  d as Command,
1064
1066
  $t as CommandEventName,
1065
1067
  H as CreateLimeobjectDialogCommand,
1066
1068
  W as DeleteObjectCommand,
1067
- sr as HttpMethod,
1068
- Ge as IdleStateEventName,
1069
- br as LogLevel,
1069
+ cr as HttpMethod,
1070
+ Qe as IdleStateEventName,
1071
+ vr as LogLevel,
1070
1072
  Y as NavigateCommand,
1071
1073
  G as OpenObjectAccessDialogCommand,
1072
1074
  re as Operator,
1073
1075
  c as PlatformServiceName,
1074
- vr as ProblemSeverity,
1076
+ gr as ProblemSeverity,
1075
1077
  Q as SaveLimeObjectCommand,
1076
- pr as SelectApplicationName,
1077
- ur as SelectConfig,
1078
- or as SelectCurrentLimeObject,
1079
- Ze as SelectCurrentLimeType,
1080
- hr as SelectCurrentUser,
1081
- ar as SelectDevice,
1082
- lr as SelectFilters,
1083
- nr as SelectLimeObjects,
1084
- Je as SelectLimeTypes,
1085
- cr as SelectQueryParam,
1086
- dr as SelectSession,
1087
- fr as SelectUserData,
1078
+ hr as SelectApplicationName,
1079
+ ar as SelectConfig,
1080
+ ir as SelectCurrentLimeObject,
1081
+ ze as SelectCurrentLimeType,
1082
+ dr as SelectCurrentUser,
1083
+ lr as SelectDevice,
1084
+ fr as SelectFilters,
1085
+ or as SelectLimeObjects,
1086
+ Ze as SelectLimeTypes,
1087
+ ur as SelectQueryParam,
1088
+ yr as SelectSession,
1089
+ pr as SelectUserData,
1088
1090
  me as TaskEventType,
1089
1091
  ye as TaskState,
1090
- Ne as createLogger,
1091
- ze as findLimetypeByLabel,
1092
+ De as createLogger,
1093
+ tr as findLimetypeByLabel,
1092
1094
  Vt as getCommandId,
1093
1095
  Ft as getCommandIds,
1094
1096
  Te as getPackageNameFromUrl,
1095
- tr as getPropertiesByType,
1096
- er as getPropertyByLabel,
1097
- rr as getPropertyByName,
1097
+ er as getPropertiesByType,
1098
+ rr as getPropertyByLabel,
1099
+ nr as getPropertyByName,
1098
1100
  nt as hasLabel,
1099
- mr as isActionCondition,
1100
- qe as isDate,
1101
- Xe as isFloat,
1102
- yr as isLimeObjectCondition,
1103
- Qe as isRelation,
1104
- Ye as isSingleRelation,
1105
- Ke as isString
1101
+ br as isActionCondition,
1102
+ Ke as isDate,
1103
+ Je as isFloat,
1104
+ mr as isLimeObjectCondition,
1105
+ Ye as isRelation,
1106
+ qe as isSingleRelation,
1107
+ Xe as isString
1106
1108
  };
1107
1109
  //# sourceMappingURL=index.esm.js.map