@limetech/lime-crm-building-blocks 1.115.0 → 1.115.1

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/CHANGELOG.md CHANGED
@@ -1,3 +1,11 @@
1
+ ## [1.115.1](https://github.com/Lundalogik/lime-crm-building-blocks/compare/v1.115.0...v1.115.1) (2026-04-16)
2
+
3
+ ### Bug Fixes
4
+
5
+
6
+ * **component-picker:** support multi-word search queries ([e43250b](https://github.com/Lundalogik/lime-crm-building-blocks/commit/e43250beacfe1c04287fafc95a4741000e63c6e1))
7
+ * **component-picker:** unify blur and submit functionality ([d0f84e0](https://github.com/Lundalogik/lime-crm-building-blocks/commit/d0f84e04f489173687bac8925d4872fd090efe0e)), closes [#1311](https://github.com/Lundalogik/lime-crm-building-blocks/issues/1311)
8
+
1
9
  ## [1.115.0](https://github.com/Lundalogik/lime-crm-building-blocks/compare/v1.114.0...v1.115.0) (2026-04-15)
2
10
 
3
11
  ### Features
@@ -49,10 +49,7 @@ const ComponentPicker = class {
49
49
  return this.tags.some((tag) => { var _a; return (_a = config.tags) === null || _a === void 0 ? void 0 : _a.includes(tag); });
50
50
  };
51
51
  this.handleBlur = () => {
52
- const value = this.currentInput;
53
- if (value && this.isValidIdentifier(value)) {
54
- this.change.emit(this.currentInput);
55
- }
52
+ this.emitIfValidValue(this.currentInput);
56
53
  };
57
54
  this.handleChange = (event) => {
58
55
  var _a;
@@ -64,20 +61,24 @@ const ComponentPicker = class {
64
61
  this.copy.emit(this.value);
65
62
  };
66
63
  this.handleKeyUp = (event) => {
67
- var _a;
68
64
  if (event.key !== 'Enter') {
69
65
  return;
70
66
  }
71
- const value = (_a = this.currentInput) !== null && _a !== void 0 ? _a : '';
67
+ this.emitIfValidValue(this.currentInput);
68
+ };
69
+ this.emitIfValidValue = (value) => {
72
70
  if (this.isValidIdentifier(value)) {
73
- this.change.emit(this.currentInput);
71
+ this.change.emit(value);
74
72
  }
75
73
  };
76
74
  this.isValidIdentifier = (identifier) => {
75
+ if (!identifier) {
76
+ return false;
77
+ }
77
78
  if (this.type === 'component') {
78
79
  return Boolean(customElements.get(identifier));
79
80
  }
80
- return true;
81
+ return this.allItems.some((item) => item.value === identifier);
81
82
  };
82
83
  this.renderPicker = () => {
83
84
  let value = this.allItems.find((item) => this.value === item.value);
@@ -106,10 +107,13 @@ const ComponentPicker = class {
106
107
  return this.allItems.filter(this.isItemMatching(query.toLocaleLowerCase()));
107
108
  };
108
109
  this.isItemMatching = (query) => (item) => {
109
- var _a, _b;
110
- return (item.text.toLocaleLowerCase().includes(query) ||
111
- ((_a = item.secondaryText) === null || _a === void 0 ? void 0 : _a.toLocaleLowerCase().includes(query)) ||
112
- ((_b = item.value) === null || _b === void 0 ? void 0 : _b.toLocaleLowerCase().includes(query)));
110
+ const queryParts = query.split(/\s+/);
111
+ return queryParts.every((part) => {
112
+ var _a, _b;
113
+ return item.text.toLocaleLowerCase().includes(part) ||
114
+ ((_a = item.secondaryText) === null || _a === void 0 ? void 0 : _a.toLocaleLowerCase().includes(part)) ||
115
+ ((_b = item.value) === null || _b === void 0 ? void 0 : _b.toLocaleLowerCase().includes(part));
116
+ });
113
117
  };
114
118
  }
115
119
  componentWillLoad() {
@@ -130,8 +134,8 @@ const ComponentPicker = class {
130
134
  return [this.renderPicker(), this.renderCopyButton()];
131
135
  }
132
136
  get currentInput() {
133
- var _a, _b, _c, _d, _e, _f;
134
- return (_f = (_e = (_d = (_c = (_b = (_a = this.host.shadowRoot) === null || _a === void 0 ? void 0 : _a.querySelector('limel-picker')) === null || _b === void 0 ? void 0 : _b.shadowRoot) === null || _c === void 0 ? void 0 : _c.querySelector('limel-chip-set')) === null || _d === void 0 ? void 0 : _d.shadowRoot) === null || _e === void 0 ? void 0 : _e.querySelector('input')) === null || _f === void 0 ? void 0 : _f.value;
137
+ var _a, _b, _c, _d, _e, _f, _g;
138
+ return ((_g = (_f = (_e = (_d = (_c = (_b = (_a = this.host.shadowRoot) === null || _a === void 0 ? void 0 : _a.querySelector('limel-picker')) === null || _b === void 0 ? void 0 : _b.shadowRoot) === null || _c === void 0 ? void 0 : _c.querySelector('limel-chip-set')) === null || _d === void 0 ? void 0 : _d.shadowRoot) === null || _e === void 0 ? void 0 : _e.querySelector('input')) === null || _f === void 0 ? void 0 : _f.value) !== null && _g !== void 0 ? _g : '');
135
139
  }
136
140
  get webComponentRegistry() {
137
141
  return this.platform.get(index_esm.c.WebComponentRegistry);
@@ -49,10 +49,7 @@ export class ComponentPicker {
49
49
  return this.tags.some((tag) => { var _a; return (_a = config.tags) === null || _a === void 0 ? void 0 : _a.includes(tag); });
50
50
  };
51
51
  this.handleBlur = () => {
52
- const value = this.currentInput;
53
- if (value && this.isValidIdentifier(value)) {
54
- this.change.emit(this.currentInput);
55
- }
52
+ this.emitIfValidValue(this.currentInput);
56
53
  };
57
54
  this.handleChange = (event) => {
58
55
  var _a;
@@ -64,20 +61,24 @@ export class ComponentPicker {
64
61
  this.copy.emit(this.value);
65
62
  };
66
63
  this.handleKeyUp = (event) => {
67
- var _a;
68
64
  if (event.key !== 'Enter') {
69
65
  return;
70
66
  }
71
- const value = (_a = this.currentInput) !== null && _a !== void 0 ? _a : '';
67
+ this.emitIfValidValue(this.currentInput);
68
+ };
69
+ this.emitIfValidValue = (value) => {
72
70
  if (this.isValidIdentifier(value)) {
73
- this.change.emit(this.currentInput);
71
+ this.change.emit(value);
74
72
  }
75
73
  };
76
74
  this.isValidIdentifier = (identifier) => {
75
+ if (!identifier) {
76
+ return false;
77
+ }
77
78
  if (this.type === 'component') {
78
79
  return Boolean(customElements.get(identifier));
79
80
  }
80
- return true;
81
+ return this.allItems.some((item) => item.value === identifier);
81
82
  };
82
83
  this.renderPicker = () => {
83
84
  let value = this.allItems.find((item) => this.value === item.value);
@@ -106,10 +107,13 @@ export class ComponentPicker {
106
107
  return this.allItems.filter(this.isItemMatching(query.toLocaleLowerCase()));
107
108
  };
108
109
  this.isItemMatching = (query) => (item) => {
109
- var _a, _b;
110
- return (item.text.toLocaleLowerCase().includes(query) ||
111
- ((_a = item.secondaryText) === null || _a === void 0 ? void 0 : _a.toLocaleLowerCase().includes(query)) ||
112
- ((_b = item.value) === null || _b === void 0 ? void 0 : _b.toLocaleLowerCase().includes(query)));
110
+ const queryParts = query.split(/\s+/);
111
+ return queryParts.every((part) => {
112
+ var _a, _b;
113
+ return item.text.toLocaleLowerCase().includes(part) ||
114
+ ((_a = item.secondaryText) === null || _a === void 0 ? void 0 : _a.toLocaleLowerCase().includes(part)) ||
115
+ ((_b = item.value) === null || _b === void 0 ? void 0 : _b.toLocaleLowerCase().includes(part));
116
+ });
113
117
  };
114
118
  }
115
119
  componentWillLoad() {
@@ -130,8 +134,8 @@ export class ComponentPicker {
130
134
  return [this.renderPicker(), this.renderCopyButton()];
131
135
  }
132
136
  get currentInput() {
133
- var _a, _b, _c, _d, _e, _f;
134
- return (_f = (_e = (_d = (_c = (_b = (_a = this.host.shadowRoot) === null || _a === void 0 ? void 0 : _a.querySelector('limel-picker')) === null || _b === void 0 ? void 0 : _b.shadowRoot) === null || _c === void 0 ? void 0 : _c.querySelector('limel-chip-set')) === null || _d === void 0 ? void 0 : _d.shadowRoot) === null || _e === void 0 ? void 0 : _e.querySelector('input')) === null || _f === void 0 ? void 0 : _f.value;
137
+ var _a, _b, _c, _d, _e, _f, _g;
138
+ return ((_g = (_f = (_e = (_d = (_c = (_b = (_a = this.host.shadowRoot) === null || _a === void 0 ? void 0 : _a.querySelector('limel-picker')) === null || _b === void 0 ? void 0 : _b.shadowRoot) === null || _c === void 0 ? void 0 : _c.querySelector('limel-chip-set')) === null || _d === void 0 ? void 0 : _d.shadowRoot) === null || _e === void 0 ? void 0 : _e.querySelector('input')) === null || _f === void 0 ? void 0 : _f.value) !== null && _g !== void 0 ? _g : '');
135
139
  }
136
140
  get webComponentRegistry() {
137
141
  return this.platform.get(PlatformServiceName.WebComponentRegistry);
@@ -47,10 +47,7 @@ const ComponentPicker = /*@__PURE__*/ proxyCustomElement(class ComponentPicker e
47
47
  return this.tags.some((tag) => { var _a; return (_a = config.tags) === null || _a === void 0 ? void 0 : _a.includes(tag); });
48
48
  };
49
49
  this.handleBlur = () => {
50
- const value = this.currentInput;
51
- if (value && this.isValidIdentifier(value)) {
52
- this.change.emit(this.currentInput);
53
- }
50
+ this.emitIfValidValue(this.currentInput);
54
51
  };
55
52
  this.handleChange = (event) => {
56
53
  var _a;
@@ -62,20 +59,24 @@ const ComponentPicker = /*@__PURE__*/ proxyCustomElement(class ComponentPicker e
62
59
  this.copy.emit(this.value);
63
60
  };
64
61
  this.handleKeyUp = (event) => {
65
- var _a;
66
62
  if (event.key !== 'Enter') {
67
63
  return;
68
64
  }
69
- const value = (_a = this.currentInput) !== null && _a !== void 0 ? _a : '';
65
+ this.emitIfValidValue(this.currentInput);
66
+ };
67
+ this.emitIfValidValue = (value) => {
70
68
  if (this.isValidIdentifier(value)) {
71
- this.change.emit(this.currentInput);
69
+ this.change.emit(value);
72
70
  }
73
71
  };
74
72
  this.isValidIdentifier = (identifier) => {
73
+ if (!identifier) {
74
+ return false;
75
+ }
75
76
  if (this.type === 'component') {
76
77
  return Boolean(customElements.get(identifier));
77
78
  }
78
- return true;
79
+ return this.allItems.some((item) => item.value === identifier);
79
80
  };
80
81
  this.renderPicker = () => {
81
82
  let value = this.allItems.find((item) => this.value === item.value);
@@ -104,10 +105,13 @@ const ComponentPicker = /*@__PURE__*/ proxyCustomElement(class ComponentPicker e
104
105
  return this.allItems.filter(this.isItemMatching(query.toLocaleLowerCase()));
105
106
  };
106
107
  this.isItemMatching = (query) => (item) => {
107
- var _a, _b;
108
- return (item.text.toLocaleLowerCase().includes(query) ||
109
- ((_a = item.secondaryText) === null || _a === void 0 ? void 0 : _a.toLocaleLowerCase().includes(query)) ||
110
- ((_b = item.value) === null || _b === void 0 ? void 0 : _b.toLocaleLowerCase().includes(query)));
108
+ const queryParts = query.split(/\s+/);
109
+ return queryParts.every((part) => {
110
+ var _a, _b;
111
+ return item.text.toLocaleLowerCase().includes(part) ||
112
+ ((_a = item.secondaryText) === null || _a === void 0 ? void 0 : _a.toLocaleLowerCase().includes(part)) ||
113
+ ((_b = item.value) === null || _b === void 0 ? void 0 : _b.toLocaleLowerCase().includes(part));
114
+ });
111
115
  };
112
116
  }
113
117
  componentWillLoad() {
@@ -128,8 +132,8 @@ const ComponentPicker = /*@__PURE__*/ proxyCustomElement(class ComponentPicker e
128
132
  return [this.renderPicker(), this.renderCopyButton()];
129
133
  }
130
134
  get currentInput() {
131
- var _a, _b, _c, _d, _e, _f;
132
- return (_f = (_e = (_d = (_c = (_b = (_a = this.host.shadowRoot) === null || _a === void 0 ? void 0 : _a.querySelector('limel-picker')) === null || _b === void 0 ? void 0 : _b.shadowRoot) === null || _c === void 0 ? void 0 : _c.querySelector('limel-chip-set')) === null || _d === void 0 ? void 0 : _d.shadowRoot) === null || _e === void 0 ? void 0 : _e.querySelector('input')) === null || _f === void 0 ? void 0 : _f.value;
135
+ var _a, _b, _c, _d, _e, _f, _g;
136
+ return ((_g = (_f = (_e = (_d = (_c = (_b = (_a = this.host.shadowRoot) === null || _a === void 0 ? void 0 : _a.querySelector('limel-picker')) === null || _b === void 0 ? void 0 : _b.shadowRoot) === null || _c === void 0 ? void 0 : _c.querySelector('limel-chip-set')) === null || _d === void 0 ? void 0 : _d.shadowRoot) === null || _e === void 0 ? void 0 : _e.querySelector('input')) === null || _f === void 0 ? void 0 : _f.value) !== null && _g !== void 0 ? _g : '');
133
137
  }
134
138
  get webComponentRegistry() {
135
139
  return this.platform.get(c.WebComponentRegistry);
@@ -45,10 +45,7 @@ const ComponentPicker = class {
45
45
  return this.tags.some((tag) => { var _a; return (_a = config.tags) === null || _a === void 0 ? void 0 : _a.includes(tag); });
46
46
  };
47
47
  this.handleBlur = () => {
48
- const value = this.currentInput;
49
- if (value && this.isValidIdentifier(value)) {
50
- this.change.emit(this.currentInput);
51
- }
48
+ this.emitIfValidValue(this.currentInput);
52
49
  };
53
50
  this.handleChange = (event) => {
54
51
  var _a;
@@ -60,20 +57,24 @@ const ComponentPicker = class {
60
57
  this.copy.emit(this.value);
61
58
  };
62
59
  this.handleKeyUp = (event) => {
63
- var _a;
64
60
  if (event.key !== 'Enter') {
65
61
  return;
66
62
  }
67
- const value = (_a = this.currentInput) !== null && _a !== void 0 ? _a : '';
63
+ this.emitIfValidValue(this.currentInput);
64
+ };
65
+ this.emitIfValidValue = (value) => {
68
66
  if (this.isValidIdentifier(value)) {
69
- this.change.emit(this.currentInput);
67
+ this.change.emit(value);
70
68
  }
71
69
  };
72
70
  this.isValidIdentifier = (identifier) => {
71
+ if (!identifier) {
72
+ return false;
73
+ }
73
74
  if (this.type === 'component') {
74
75
  return Boolean(customElements.get(identifier));
75
76
  }
76
- return true;
77
+ return this.allItems.some((item) => item.value === identifier);
77
78
  };
78
79
  this.renderPicker = () => {
79
80
  let value = this.allItems.find((item) => this.value === item.value);
@@ -102,10 +103,13 @@ const ComponentPicker = class {
102
103
  return this.allItems.filter(this.isItemMatching(query.toLocaleLowerCase()));
103
104
  };
104
105
  this.isItemMatching = (query) => (item) => {
105
- var _a, _b;
106
- return (item.text.toLocaleLowerCase().includes(query) ||
107
- ((_a = item.secondaryText) === null || _a === void 0 ? void 0 : _a.toLocaleLowerCase().includes(query)) ||
108
- ((_b = item.value) === null || _b === void 0 ? void 0 : _b.toLocaleLowerCase().includes(query)));
106
+ const queryParts = query.split(/\s+/);
107
+ return queryParts.every((part) => {
108
+ var _a, _b;
109
+ return item.text.toLocaleLowerCase().includes(part) ||
110
+ ((_a = item.secondaryText) === null || _a === void 0 ? void 0 : _a.toLocaleLowerCase().includes(part)) ||
111
+ ((_b = item.value) === null || _b === void 0 ? void 0 : _b.toLocaleLowerCase().includes(part));
112
+ });
109
113
  };
110
114
  }
111
115
  componentWillLoad() {
@@ -126,8 +130,8 @@ const ComponentPicker = class {
126
130
  return [this.renderPicker(), this.renderCopyButton()];
127
131
  }
128
132
  get currentInput() {
129
- var _a, _b, _c, _d, _e, _f;
130
- return (_f = (_e = (_d = (_c = (_b = (_a = this.host.shadowRoot) === null || _a === void 0 ? void 0 : _a.querySelector('limel-picker')) === null || _b === void 0 ? void 0 : _b.shadowRoot) === null || _c === void 0 ? void 0 : _c.querySelector('limel-chip-set')) === null || _d === void 0 ? void 0 : _d.shadowRoot) === null || _e === void 0 ? void 0 : _e.querySelector('input')) === null || _f === void 0 ? void 0 : _f.value;
133
+ var _a, _b, _c, _d, _e, _f, _g;
134
+ return ((_g = (_f = (_e = (_d = (_c = (_b = (_a = this.host.shadowRoot) === null || _a === void 0 ? void 0 : _a.querySelector('limel-picker')) === null || _b === void 0 ? void 0 : _b.shadowRoot) === null || _c === void 0 ? void 0 : _c.querySelector('limel-chip-set')) === null || _d === void 0 ? void 0 : _d.shadowRoot) === null || _e === void 0 ? void 0 : _e.querySelector('input')) === null || _f === void 0 ? void 0 : _f.value) !== null && _g !== void 0 ? _g : '');
131
135
  }
132
136
  get webComponentRegistry() {
133
137
  return this.platform.get(c.WebComponentRegistry);
@@ -1 +1 @@
1
- import{p as e,b as t}from"./p-52cf8641.js";export{s as setNonce}from"./p-52cf8641.js";import{g as i}from"./p-e1255160.js";(()=>{const t=import.meta.url,i={};return""!==t&&(i.resourcesUrl=new URL(".",t).href),e(i)})().then((async e=>(await i(),t(JSON.parse('[["p-4dad4ce8",[[1,"limebb-lime-query-builder",{"platform":[16],"context":[16],"value":[16],"label":[1],"activeLimetype":[1,"active-limetype"],"limetypes":[32],"mode":[32],"codeValue":[32],"limetype":[32],"filter":[32],"internalResponseFormat":[32],"limit":[32],"orderBy":[32],"description":[32]}]]],["p-0d0f4c0f",[[1,"limebb-feed",{"platform":[16],"context":[16],"items":[16],"emptyStateMessage":[1,"empty-state-message"],"heading":[1],"loading":[4],"minutesOfProximity":[2,"minutes-of-proximity"],"totalCount":[2,"total-count"],"direction":[513],"lastVisitedTimestamp":[1,"last-visited-timestamp"],"highlightedItemId":[8,"highlighted-item-id"]},null,{"highlightedItemId":["highlightedItemIdChanged"]}]]],["p-973146f7",[[1,"limebb-kanban",{"platform":[16],"context":[16],"groups":[16]}]]],["p-dddd8a43",[[1,"limebb-lime-query-response-format-builder",{"platform":[16],"context":[16],"limetype":[1],"value":[16],"label":[1],"helperText":[1,"helper-text"],"limetypes":[32],"mode":[32],"codeValue":[32],"internalValue":[32]}]]],["p-7f72be40",[[1,"limebb-chat-list",{"platform":[16],"context":[16],"items":[16],"loading":[516],"isTypingIndicatorVisible":[516,"is-typing-indicator-visible"],"lastVisitedTimestamp":[513,"last-visited-timestamp"],"order":[513]},null,{"items":["handleItemsChange"]}]]],["p-6bf1ab6d",[[1,"limebb-document-chips",{"accessibleLabel":[513,"accessible-label"],"files":[16]},null,{"files":["onFilesChanged"]}]]],["p-50aad872",[[1,"limebb-limeobject-file-viewer",{"platform":[16],"context":[16],"property":[1],"fileTypes":[16],"limeobject":[32],"limetype":[32]}]]],["p-3a7b37cc",[[17,"limebb-text-editor",{"platform":[16],"context":[16],"allowMentioning":[4,"allow-mentioning"],"contentType":[1,"content-type"],"language":[513],"disabled":[516],"readonly":[516],"helperText":[513,"helper-text"],"placeholder":[513],"label":[513],"invalid":[516],"required":[516],"selectedContext":[16],"ui":[513],"allowResize":[4,"allow-resize"],"value":[1],"draftIdentifier":[1,"draft-identifier"],"triggerMap":[16],"customElements":[16],"allowInlineImages":[4,"allow-inline-images"],"items":[32],"highlightedItemIndex":[32],"editorPickerQuery":[32],"searchableLimetypes":[32],"isPickerOpen":[32],"isSearching":[32]},null,{"isPickerOpen":["watchOpen"],"editorPickerQuery":["watchQuery"]}]]],["p-77e7d7da",[[1,"limebb-data-cells",{"platform":[16],"context":[16],"limeobject":[8],"items":[16]}]]],["p-9c334694",[[1,"limebb-date-range",{"platform":[16],"context":[16],"startTime":[16],"endTime":[16],"startTimeLabel":[1,"start-time-label"],"endTimeLabel":[1,"end-time-label"],"language":[1],"timeFormat":[1,"time-format"],"type":[1]}]]],["p-7b5a1e83",[[1,"limebb-document-picker",{"platform":[16],"context":[16],"items":[16],"label":[513],"helperText":[513,"helper-text"],"invalid":[516],"required":[516],"type":[513]}]]],["p-4ca1caf4",[[1,"limebb-info-tile-currency-format",{"platform":[16],"context":[16],"value":[16]}]]],["p-4b494de7",[[1,"limebb-notification-list",{"platform":[16],"context":[16],"items":[16],"loading":[4],"lastVisitedTimestamp":[1,"last-visited-timestamp"]},null,{"items":["handleItemsChange"]}]]],["p-6a87a407",[[1,"limebb-alert-dialog",{"type":[513],"open":[516],"icon":[513],"heading":[513],"subheading":[1]}]]],["p-6ad6a88d",[[17,"limebb-browser",{"platform":[16],"context":[16],"items":[16],"layout":[1],"filter":[32]}]]],["p-95b6eaf5",[[1,"limebb-component-config",{"platform":[16],"context":[16],"value":[16],"required":[4],"readonly":[4],"disabled":[4],"label":[1],"helperText":[1,"helper-text"],"formInfo":[16],"type":[1],"nameField":[1,"name-field"],"configComponent":[32],"configViewType":[32]},null,{"formInfo":["watchFormInfo"],"configComponent":["watchconfigComponent"]}]]],["p-a954d06e",[[1,"limebb-component-picker",{"platform":[16],"context":[16],"type":[1],"tags":[16],"value":[1],"copyLabel":[1,"copy-label"],"hideCopyButton":[4,"hide-copy-button"],"required":[4],"readonly":[4],"disabled":[4],"label":[1],"helperText":[1,"helper-text"]}]]],["p-20939cd4",[[1,"limebb-composer-toolbar",{"platform":[16],"mentions":[516],"textSnippets":[516,"text-snippets"],"internalLinks":[516,"internal-links"],"richText":[516,"rich-text"],"fileInput":[16]}]]],["p-f31eeeaa",[[1,"limebb-dashboard-widget",{"heading":[513],"subheading":[513],"supportingText":[513,"supporting-text"],"icon":[513]}]]],["p-d5b835a6",[[1,"limebb-icon-picker",{"value":[1],"required":[4],"readonly":[4],"invalid":[4],"disabled":[4],"label":[1],"helperText":[1,"helper-text"]}]]],["p-d9f76810",[[1,"limebb-info-tile",{"platform":[16],"context":[16],"filterId":[513,"filter-id"],"disabled":[4],"icon":[513],"label":[1],"prefix":[1],"suffix":[1],"propertyName":[1,"property-name"],"aggregateOperator":[1,"aggregate-operator"],"format":[16],"config":[32],"filters":[32],"value":[32],"loading":[32],"error":[32],"limetypes":[32]},null,{"filterId":["watchFilterId"],"propertyName":["watchPropertyName"],"aggregateOperator":["watchAggregateOperator"]}]]],["p-eb56d4eb",[[1,"limebb-info-tile-date-format",{"value":[16]}]]],["p-fb292b3f",[[1,"limebb-info-tile-decimal-format",{"value":[16]}]]],["p-812bf26e",[[1,"limebb-info-tile-format",{"platform":[16],"context":[16],"type":[1],"value":[16]}]]],["p-579be797",[[1,"limebb-info-tile-relative-date-format",{"value":[16]}]]],["p-3da67f32",[[1,"limebb-info-tile-unit-format",{"value":[16]}]]],["p-b7959ddb",[[1,"limebb-loader",{"platform":[16],"context":[16]}]]],["p-103654ac",[[1,"limebb-locale-picker",{"platform":[16],"context":[16],"value":[1],"required":[4],"disabled":[4],"label":[1],"helperText":[1,"helper-text"],"readonly":[4],"multipleChoice":[4,"multiple-choice"],"allLanguages":[32]}]]],["p-eb4aa158",[[1,"limebb-mention",{"limetype":[1],"objectid":[2],"limeobject":[32]}]]],["p-94e6f0de",[[1,"limebb-mention-group-counter",{"count":[2],"limetype":[16],"helperLabel":[1,"helper-label"]}]]],["p-f7122d8e",[[1,"limebb-object-chip",{"limetype":[1],"objectid":[2],"size":[1],"platform":[16],"data":[32]},null,{"limetype":["handlePropChange"],"objectid":["handlePropChange"]}]]],["p-3b3e7328",[[1,"limebb-trend-indicator",{"platform":[16],"context":[16],"value":[520],"formerValue":[514,"former-value"],"suffix":[513],"label":[513],"invalid":[516],"required":[516],"helperText":[513,"helper-text"],"reducePresence":[516,"reduce-presence"]},null,{"value":["valueChanged"]}]]],["p-22fffe85",[[1,"limebb-feed-item-thumbnail-file-info",{"description":[1]}]]],["p-7a6c1595",[[1,"limebb-feed-timeline-item",{"platform":[16],"context":[16],"item":[16],"ui":[513],"helperText":[1,"helper-text"],"hasError":[516,"has-error"],"isBundled":[516,"is-bundled"],"headingCanExpand":[32],"isHeadingExpanded":[32],"showMore":[32],"isTall":[32]}]]],["p-81f8e5df",[[1,"limebb-kanban-group",{"platform":[16],"context":[16],"identifier":[1],"heading":[513],"help":[1],"items":[16],"summary":[1],"loading":[516],"totalCount":[514,"total-count"]}]]],["p-e79f16ca",[[1,"limebb-empty-state",{"heading":[513],"value":[513],"icon":[16]}]]],["p-b675d5f0",[[1,"limebb-text-editor-picker",{"items":[16],"open":[516],"isSearching":[4,"is-searching"],"emptyMessage":[1,"empty-message"]},null,{"open":["watchOpen"]}]]],["p-8c3f563e",[[1,"limebb-currency-picker",{"platform":[16],"context":[16],"label":[513],"currencies":[16],"helperText":[513,"helper-text"],"required":[516],"readonly":[516],"invalid":[516],"disabled":[516],"value":[1]}]]],["p-0eac6b68",[[1,"limebb-date-picker",{"platform":[16],"context":[16],"disabled":[516],"readonly":[516],"invalid":[516],"label":[513],"placeholder":[513],"helperText":[513,"helper-text"],"required":[516],"value":[1],"type":[513]}]]],["p-a7e55181",[[17,"limebb-document-item",{"platform":[16],"context":[16],"item":[16],"type":[513],"fileTypes":[16]}]]],["p-375f40d9",[[1,"limebb-live-docs-info"]]],["p-6bd5c65f",[[1,"limebb-notification-item",{"platform":[16],"context":[16],"item":[16]}]]],["p-9c204549",[[1,"limebb-percentage-visualizer",{"platform":[16],"context":[16],"value":[520],"rangeMax":[514,"range-max"],"rangeMin":[514,"range-min"],"multiplier":[514],"label":[513],"invalid":[516],"required":[516],"helperText":[513,"helper-text"],"reducePresence":[516,"reduce-presence"],"displayPercentageColors":[516,"display-percentage-colors"]},null,{"value":["valueChanged"]}]]],["p-9bc5caac",[[1,"limebb-kanban-item",{"platform":[16],"context":[16],"item":[16]}]]],["p-2ed843e9",[[1,"limebb-lime-query-order-by-item",{"platform":[16],"context":[16],"limetype":[1],"item":[16]}]]],["p-703fa2fe",[[1,"limebb-chat-item",{"platform":[16],"context":[16],"item":[16],"helperText":[1,"helper-text"],"hasError":[516,"has-error"]}],[1,"limebb-typing-indicator"]]],["p-81583fc8",[[1,"limebb-property-selector",{"platform":[16],"context":[16],"limetype":[1],"value":[1],"label":[1],"required":[4],"helperText":[1,"helper-text"],"limetypes":[32],"isOpen":[32],"navigationPath":[32]}]]],["p-18d1ab86",[[1,"limebb-lime-query-filter-expression",{"platform":[16],"context":[16],"label":[1],"limetype":[1],"activeLimetype":[1,"active-limetype"],"expression":[16]}],[1,"limebb-lime-query-filter-comparison",{"platform":[16],"context":[16],"label":[513],"limetype":[1],"activeLimetype":[1,"active-limetype"],"expression":[16]}]]],["p-4066e17a",[[1,"limebb-lime-query-filter-builder",{"platform":[16],"context":[16],"limetype":[1],"activeLimetype":[1,"active-limetype"],"expression":[16]}],[1,"limebb-lime-query-order-by-editor",{"platform":[16],"context":[16],"limetype":[1],"value":[16],"label":[1],"items":[32]},null,{"value":["handleValueChange"]}],[0,"limebb-limetype-field",{"platform":[16],"context":[16],"label":[513],"required":[516],"readonly":[516],"disabled":[516],"value":[513],"helperText":[513,"helper-text"],"invalid":[4],"limetypes":[16],"propertyFields":[16],"fieldName":[1,"field-name"],"formInfo":[16]}]]],["p-53d54dc8",[[1,"limebb-lime-query-response-format-editor",{"platform":[16],"context":[16],"limetype":[1],"value":[16],"label":[1],"items":[32]}],[1,"limebb-lime-query-response-format-item",{"platform":[16],"context":[16],"limetype":[1],"item":[16],"showAliasInput":[32],"showDescriptionInput":[32]}]]],["p-d7fc530f",[[1,"limebb-summary-popover",{"triggerDelay":[514,"trigger-delay"],"heading":[513],"subheading":[513],"image":[16],"file":[16],"icon":[513],"value":[1],"openDirection":[513,"open-direction"],"popoverMaxWidth":[513,"popover-max-width"],"popoverMaxHeight":[513,"popover-max-height"],"actions":[16],"isPopoverOpen":[32]}],[17,"limebb-navigation-button",{"href":[513],"tooltipLabel":[513,"tooltip-label"],"tooltipHelperLabel":[513,"tooltip-helper-label"],"type":[513]}]]],["p-20b5ff30",[[1,"limebb-lime-query-value-input",{"platform":[16],"context":[16],"limetype":[1],"activeLimetype":[1,"active-limetype"],"propertyPath":[1,"property-path"],"operator":[1],"value":[8],"label":[1],"limetypes":[32],"inputMode":[32]}],[1,"limebb-lime-query-filter-group",{"platform":[16],"context":[16],"limetype":[1],"activeLimetype":[1,"active-limetype"],"expression":[16],"value":[32]}],[1,"limebb-lime-query-filter-not",{"platform":[16],"context":[16],"label":[1],"limetype":[1],"activeLimetype":[1,"active-limetype"],"expression":[16]}]]]]'),e))));
1
+ import{p as e,b as t}from"./p-52cf8641.js";export{s as setNonce}from"./p-52cf8641.js";import{g as i}from"./p-e1255160.js";(()=>{const t=import.meta.url,i={};return""!==t&&(i.resourcesUrl=new URL(".",t).href),e(i)})().then((async e=>(await i(),t(JSON.parse('[["p-4dad4ce8",[[1,"limebb-lime-query-builder",{"platform":[16],"context":[16],"value":[16],"label":[1],"activeLimetype":[1,"active-limetype"],"limetypes":[32],"mode":[32],"codeValue":[32],"limetype":[32],"filter":[32],"internalResponseFormat":[32],"limit":[32],"orderBy":[32],"description":[32]}]]],["p-0d0f4c0f",[[1,"limebb-feed",{"platform":[16],"context":[16],"items":[16],"emptyStateMessage":[1,"empty-state-message"],"heading":[1],"loading":[4],"minutesOfProximity":[2,"minutes-of-proximity"],"totalCount":[2,"total-count"],"direction":[513],"lastVisitedTimestamp":[1,"last-visited-timestamp"],"highlightedItemId":[8,"highlighted-item-id"]},null,{"highlightedItemId":["highlightedItemIdChanged"]}]]],["p-973146f7",[[1,"limebb-kanban",{"platform":[16],"context":[16],"groups":[16]}]]],["p-dddd8a43",[[1,"limebb-lime-query-response-format-builder",{"platform":[16],"context":[16],"limetype":[1],"value":[16],"label":[1],"helperText":[1,"helper-text"],"limetypes":[32],"mode":[32],"codeValue":[32],"internalValue":[32]}]]],["p-7f72be40",[[1,"limebb-chat-list",{"platform":[16],"context":[16],"items":[16],"loading":[516],"isTypingIndicatorVisible":[516,"is-typing-indicator-visible"],"lastVisitedTimestamp":[513,"last-visited-timestamp"],"order":[513]},null,{"items":["handleItemsChange"]}]]],["p-6bf1ab6d",[[1,"limebb-document-chips",{"accessibleLabel":[513,"accessible-label"],"files":[16]},null,{"files":["onFilesChanged"]}]]],["p-50aad872",[[1,"limebb-limeobject-file-viewer",{"platform":[16],"context":[16],"property":[1],"fileTypes":[16],"limeobject":[32],"limetype":[32]}]]],["p-3a7b37cc",[[17,"limebb-text-editor",{"platform":[16],"context":[16],"allowMentioning":[4,"allow-mentioning"],"contentType":[1,"content-type"],"language":[513],"disabled":[516],"readonly":[516],"helperText":[513,"helper-text"],"placeholder":[513],"label":[513],"invalid":[516],"required":[516],"selectedContext":[16],"ui":[513],"allowResize":[4,"allow-resize"],"value":[1],"draftIdentifier":[1,"draft-identifier"],"triggerMap":[16],"customElements":[16],"allowInlineImages":[4,"allow-inline-images"],"items":[32],"highlightedItemIndex":[32],"editorPickerQuery":[32],"searchableLimetypes":[32],"isPickerOpen":[32],"isSearching":[32]},null,{"isPickerOpen":["watchOpen"],"editorPickerQuery":["watchQuery"]}]]],["p-77e7d7da",[[1,"limebb-data-cells",{"platform":[16],"context":[16],"limeobject":[8],"items":[16]}]]],["p-9c334694",[[1,"limebb-date-range",{"platform":[16],"context":[16],"startTime":[16],"endTime":[16],"startTimeLabel":[1,"start-time-label"],"endTimeLabel":[1,"end-time-label"],"language":[1],"timeFormat":[1,"time-format"],"type":[1]}]]],["p-7b5a1e83",[[1,"limebb-document-picker",{"platform":[16],"context":[16],"items":[16],"label":[513],"helperText":[513,"helper-text"],"invalid":[516],"required":[516],"type":[513]}]]],["p-4ca1caf4",[[1,"limebb-info-tile-currency-format",{"platform":[16],"context":[16],"value":[16]}]]],["p-4b494de7",[[1,"limebb-notification-list",{"platform":[16],"context":[16],"items":[16],"loading":[4],"lastVisitedTimestamp":[1,"last-visited-timestamp"]},null,{"items":["handleItemsChange"]}]]],["p-6a87a407",[[1,"limebb-alert-dialog",{"type":[513],"open":[516],"icon":[513],"heading":[513],"subheading":[1]}]]],["p-6ad6a88d",[[17,"limebb-browser",{"platform":[16],"context":[16],"items":[16],"layout":[1],"filter":[32]}]]],["p-95b6eaf5",[[1,"limebb-component-config",{"platform":[16],"context":[16],"value":[16],"required":[4],"readonly":[4],"disabled":[4],"label":[1],"helperText":[1,"helper-text"],"formInfo":[16],"type":[1],"nameField":[1,"name-field"],"configComponent":[32],"configViewType":[32]},null,{"formInfo":["watchFormInfo"],"configComponent":["watchconfigComponent"]}]]],["p-87d3f42c",[[1,"limebb-component-picker",{"platform":[16],"context":[16],"type":[1],"tags":[16],"value":[1],"copyLabel":[1,"copy-label"],"hideCopyButton":[4,"hide-copy-button"],"required":[4],"readonly":[4],"disabled":[4],"label":[1],"helperText":[1,"helper-text"]}]]],["p-20939cd4",[[1,"limebb-composer-toolbar",{"platform":[16],"mentions":[516],"textSnippets":[516,"text-snippets"],"internalLinks":[516,"internal-links"],"richText":[516,"rich-text"],"fileInput":[16]}]]],["p-f31eeeaa",[[1,"limebb-dashboard-widget",{"heading":[513],"subheading":[513],"supportingText":[513,"supporting-text"],"icon":[513]}]]],["p-d5b835a6",[[1,"limebb-icon-picker",{"value":[1],"required":[4],"readonly":[4],"invalid":[4],"disabled":[4],"label":[1],"helperText":[1,"helper-text"]}]]],["p-d9f76810",[[1,"limebb-info-tile",{"platform":[16],"context":[16],"filterId":[513,"filter-id"],"disabled":[4],"icon":[513],"label":[1],"prefix":[1],"suffix":[1],"propertyName":[1,"property-name"],"aggregateOperator":[1,"aggregate-operator"],"format":[16],"config":[32],"filters":[32],"value":[32],"loading":[32],"error":[32],"limetypes":[32]},null,{"filterId":["watchFilterId"],"propertyName":["watchPropertyName"],"aggregateOperator":["watchAggregateOperator"]}]]],["p-eb56d4eb",[[1,"limebb-info-tile-date-format",{"value":[16]}]]],["p-fb292b3f",[[1,"limebb-info-tile-decimal-format",{"value":[16]}]]],["p-812bf26e",[[1,"limebb-info-tile-format",{"platform":[16],"context":[16],"type":[1],"value":[16]}]]],["p-579be797",[[1,"limebb-info-tile-relative-date-format",{"value":[16]}]]],["p-3da67f32",[[1,"limebb-info-tile-unit-format",{"value":[16]}]]],["p-b7959ddb",[[1,"limebb-loader",{"platform":[16],"context":[16]}]]],["p-103654ac",[[1,"limebb-locale-picker",{"platform":[16],"context":[16],"value":[1],"required":[4],"disabled":[4],"label":[1],"helperText":[1,"helper-text"],"readonly":[4],"multipleChoice":[4,"multiple-choice"],"allLanguages":[32]}]]],["p-eb4aa158",[[1,"limebb-mention",{"limetype":[1],"objectid":[2],"limeobject":[32]}]]],["p-94e6f0de",[[1,"limebb-mention-group-counter",{"count":[2],"limetype":[16],"helperLabel":[1,"helper-label"]}]]],["p-f7122d8e",[[1,"limebb-object-chip",{"limetype":[1],"objectid":[2],"size":[1],"platform":[16],"data":[32]},null,{"limetype":["handlePropChange"],"objectid":["handlePropChange"]}]]],["p-3b3e7328",[[1,"limebb-trend-indicator",{"platform":[16],"context":[16],"value":[520],"formerValue":[514,"former-value"],"suffix":[513],"label":[513],"invalid":[516],"required":[516],"helperText":[513,"helper-text"],"reducePresence":[516,"reduce-presence"]},null,{"value":["valueChanged"]}]]],["p-22fffe85",[[1,"limebb-feed-item-thumbnail-file-info",{"description":[1]}]]],["p-7a6c1595",[[1,"limebb-feed-timeline-item",{"platform":[16],"context":[16],"item":[16],"ui":[513],"helperText":[1,"helper-text"],"hasError":[516,"has-error"],"isBundled":[516,"is-bundled"],"headingCanExpand":[32],"isHeadingExpanded":[32],"showMore":[32],"isTall":[32]}]]],["p-81f8e5df",[[1,"limebb-kanban-group",{"platform":[16],"context":[16],"identifier":[1],"heading":[513],"help":[1],"items":[16],"summary":[1],"loading":[516],"totalCount":[514,"total-count"]}]]],["p-e79f16ca",[[1,"limebb-empty-state",{"heading":[513],"value":[513],"icon":[16]}]]],["p-b675d5f0",[[1,"limebb-text-editor-picker",{"items":[16],"open":[516],"isSearching":[4,"is-searching"],"emptyMessage":[1,"empty-message"]},null,{"open":["watchOpen"]}]]],["p-8c3f563e",[[1,"limebb-currency-picker",{"platform":[16],"context":[16],"label":[513],"currencies":[16],"helperText":[513,"helper-text"],"required":[516],"readonly":[516],"invalid":[516],"disabled":[516],"value":[1]}]]],["p-0eac6b68",[[1,"limebb-date-picker",{"platform":[16],"context":[16],"disabled":[516],"readonly":[516],"invalid":[516],"label":[513],"placeholder":[513],"helperText":[513,"helper-text"],"required":[516],"value":[1],"type":[513]}]]],["p-a7e55181",[[17,"limebb-document-item",{"platform":[16],"context":[16],"item":[16],"type":[513],"fileTypes":[16]}]]],["p-375f40d9",[[1,"limebb-live-docs-info"]]],["p-6bd5c65f",[[1,"limebb-notification-item",{"platform":[16],"context":[16],"item":[16]}]]],["p-9c204549",[[1,"limebb-percentage-visualizer",{"platform":[16],"context":[16],"value":[520],"rangeMax":[514,"range-max"],"rangeMin":[514,"range-min"],"multiplier":[514],"label":[513],"invalid":[516],"required":[516],"helperText":[513,"helper-text"],"reducePresence":[516,"reduce-presence"],"displayPercentageColors":[516,"display-percentage-colors"]},null,{"value":["valueChanged"]}]]],["p-9bc5caac",[[1,"limebb-kanban-item",{"platform":[16],"context":[16],"item":[16]}]]],["p-2ed843e9",[[1,"limebb-lime-query-order-by-item",{"platform":[16],"context":[16],"limetype":[1],"item":[16]}]]],["p-703fa2fe",[[1,"limebb-chat-item",{"platform":[16],"context":[16],"item":[16],"helperText":[1,"helper-text"],"hasError":[516,"has-error"]}],[1,"limebb-typing-indicator"]]],["p-81583fc8",[[1,"limebb-property-selector",{"platform":[16],"context":[16],"limetype":[1],"value":[1],"label":[1],"required":[4],"helperText":[1,"helper-text"],"limetypes":[32],"isOpen":[32],"navigationPath":[32]}]]],["p-18d1ab86",[[1,"limebb-lime-query-filter-expression",{"platform":[16],"context":[16],"label":[1],"limetype":[1],"activeLimetype":[1,"active-limetype"],"expression":[16]}],[1,"limebb-lime-query-filter-comparison",{"platform":[16],"context":[16],"label":[513],"limetype":[1],"activeLimetype":[1,"active-limetype"],"expression":[16]}]]],["p-4066e17a",[[1,"limebb-lime-query-filter-builder",{"platform":[16],"context":[16],"limetype":[1],"activeLimetype":[1,"active-limetype"],"expression":[16]}],[1,"limebb-lime-query-order-by-editor",{"platform":[16],"context":[16],"limetype":[1],"value":[16],"label":[1],"items":[32]},null,{"value":["handleValueChange"]}],[0,"limebb-limetype-field",{"platform":[16],"context":[16],"label":[513],"required":[516],"readonly":[516],"disabled":[516],"value":[513],"helperText":[513,"helper-text"],"invalid":[4],"limetypes":[16],"propertyFields":[16],"fieldName":[1,"field-name"],"formInfo":[16]}]]],["p-53d54dc8",[[1,"limebb-lime-query-response-format-editor",{"platform":[16],"context":[16],"limetype":[1],"value":[16],"label":[1],"items":[32]}],[1,"limebb-lime-query-response-format-item",{"platform":[16],"context":[16],"limetype":[1],"item":[16],"showAliasInput":[32],"showDescriptionInput":[32]}]]],["p-d7fc530f",[[1,"limebb-summary-popover",{"triggerDelay":[514,"trigger-delay"],"heading":[513],"subheading":[513],"image":[16],"file":[16],"icon":[513],"value":[1],"openDirection":[513,"open-direction"],"popoverMaxWidth":[513,"popover-max-width"],"popoverMaxHeight":[513,"popover-max-height"],"actions":[16],"isPopoverOpen":[32]}],[17,"limebb-navigation-button",{"href":[513],"tooltipLabel":[513,"tooltip-label"],"tooltipHelperLabel":[513,"tooltip-helper-label"],"type":[513]}]]],["p-20b5ff30",[[1,"limebb-lime-query-value-input",{"platform":[16],"context":[16],"limetype":[1],"activeLimetype":[1,"active-limetype"],"propertyPath":[1,"property-path"],"operator":[1],"value":[8],"label":[1],"limetypes":[32],"inputMode":[32]}],[1,"limebb-lime-query-filter-group",{"platform":[16],"context":[16],"limetype":[1],"activeLimetype":[1,"active-limetype"],"expression":[16],"value":[32]}],[1,"limebb-lime-query-filter-not",{"platform":[16],"context":[16],"label":[1],"limetype":[1],"activeLimetype":[1,"active-limetype"],"expression":[16]}]]]]'),e))));
@@ -0,0 +1 @@
1
+ import{r as i,c as t,h as s,g as e}from"./p-52cf8641.js";import{c as o}from"./p-199799ff.js";const h=class{constructor(e){i(this,e),this.change=t(this,"change",7),this.copy=t(this,"copy",7),this.type="component",this.copyLabel="Copy value",this.hideCopyButton=!1,this.allItems=[],this.getConfigs=()=>({component:()=>this.webComponentRegistry.getAll(),command:()=>this.commandbus.getAll()}[this.type]()),this.getConfigValue=i=>"name"in i&&"string"==typeof i.name?i.name:"id"in i&&"string"==typeof i.id?i.id:"",this.hasTag=i=>!this.tags||this.tags.some((t=>{var s;return null===(s=i.tags)||void 0===s?void 0:s.includes(t)})),this.handleBlur=()=>{this.emitIfValidValue(this.currentInput)},this.handleChange=i=>{var t;i.stopPropagation(),this.change.emit(null===(t=i.detail)||void 0===t?void 0:t.value)},this.handleCopyButton=()=>{navigator.clipboard.writeText(this.value),this.copy.emit(this.value)},this.handleKeyUp=i=>{"Enter"===i.key&&this.emitIfValidValue(this.currentInput)},this.emitIfValidValue=i=>{this.isValidIdentifier(i)&&this.change.emit(i)},this.isValidIdentifier=i=>!!i&&("component"===this.type?Boolean(customElements.get(i)):this.allItems.some((t=>t.value===i))),this.renderPicker=()=>{let i=this.allItems.find((i=>this.value===i.value));return!i&&this.value&&(i={text:this.value,value:this.value,icon:{name:"question",color:"rgb(var(--color-glaucous-light))"}}),s("limel-picker",{disabled:this.disabled,helperText:this.helperText,label:this.label,readonly:this.readonly,required:this.required,searcher:this.search,value:i,title:null==i?void 0:i.text,onBlur:this.handleBlur,onChange:this.handleChange,onKeyUp:this.handleKeyUp})},this.renderCopyButton=()=>{if(!this.hideCopyButton)return s("limel-icon-button",{icon:"copy",disabled:!this.value,label:this.copyLabel,onClick:this.handleCopyButton})},this.search=async i=>i?this.allItems.filter(this.isItemMatching(i.toLocaleLowerCase())):this.allItems,this.isItemMatching=i=>t=>i.split(/\s+/).every((i=>{var s,e;return t.text.toLocaleLowerCase().includes(i)||(null===(s=t.secondaryText)||void 0===s?void 0:s.toLocaleLowerCase().includes(i))||(null===(e=t.value)||void 0===e?void 0:e.toLocaleLowerCase().includes(i))}))}componentWillLoad(){this.allItems=this.getConfigs().filter(this.hasTag).map((i=>{var t,s;return{value:this.getConfigValue(i),text:this.translator.get(null!==(t=i.title)&&void 0!==t?t:this.getConfigValue(i)),secondaryText:this.translator.get(null!==(s=i.description)&&void 0!==s?s:""),icon:i.icon}})).sort(((i,t)=>i.text.localeCompare(t.text)))}render(){return[this.renderPicker(),this.renderCopyButton()]}get currentInput(){var i,t,s,e,o,h,n;return null!==(n=null===(h=null===(o=null===(e=null===(s=null===(t=null===(i=this.host.shadowRoot)||void 0===i?void 0:i.querySelector("limel-picker"))||void 0===t?void 0:t.shadowRoot)||void 0===s?void 0:s.querySelector("limel-chip-set"))||void 0===e?void 0:e.shadowRoot)||void 0===o?void 0:o.querySelector("input"))||void 0===h?void 0:h.value)&&void 0!==n?n:""}get webComponentRegistry(){return this.platform.get(o.WebComponentRegistry)}get commandbus(){return this.platform.get(o.CommandBus)}get translator(){return this.platform.get(o.Translate)}get host(){return e(this)}};h.style=":host(limebb-component-picker){position:relative;display:flex;align-items:center}:host(limebb-component-picker) limel-picker{flex-grow:1;min-width:0}:host(limebb-component-picker) limel-icon-button{position:absolute;right:0.25rem}";export{h as limebb_component_picker}
@@ -58,6 +58,7 @@ export declare class ComponentPicker implements FormComponent<string>, LimeWebCo
58
58
  private handleChange;
59
59
  private handleCopyButton;
60
60
  private handleKeyUp;
61
+ private emitIfValidValue;
61
62
  private isValidIdentifier;
62
63
  render(): any[];
63
64
  private renderPicker;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@limetech/lime-crm-building-blocks",
3
- "version": "1.115.0",
3
+ "version": "1.115.1",
4
4
  "description": "A home for shared components meant for use with Lime CRM",
5
5
  "main": "dist/index.cjs.js",
6
6
  "module": "dist/index.js",
@@ -35,7 +35,7 @@
35
35
  },
36
36
  "devDependencies": {
37
37
  "@limetech/eslint-config": "^3.0.1",
38
- "@limetech/lime-elements": "^39.13.1",
38
+ "@limetech/lime-elements": "^39.13.2",
39
39
  "@limetech/lime-web-components": "^6.13.1",
40
40
  "@limetech/lime-web-components-testing": "^1.0.0",
41
41
  "@lundalogik/lime-icons8": "^2.38.2",
@@ -1 +0,0 @@
1
- import{r as i,c as t,h as s,g as o}from"./p-52cf8641.js";import{c as e}from"./p-199799ff.js";const n=class{constructor(o){i(this,o),this.change=t(this,"change",7),this.copy=t(this,"copy",7),this.type="component",this.copyLabel="Copy value",this.hideCopyButton=!1,this.allItems=[],this.getConfigs=()=>({component:()=>this.webComponentRegistry.getAll(),command:()=>this.commandbus.getAll()}[this.type]()),this.getConfigValue=i=>"name"in i&&"string"==typeof i.name?i.name:"id"in i&&"string"==typeof i.id?i.id:"",this.hasTag=i=>!this.tags||this.tags.some((t=>{var s;return null===(s=i.tags)||void 0===s?void 0:s.includes(t)})),this.handleBlur=()=>{const i=this.currentInput;i&&this.isValidIdentifier(i)&&this.change.emit(this.currentInput)},this.handleChange=i=>{var t;i.stopPropagation(),this.change.emit(null===(t=i.detail)||void 0===t?void 0:t.value)},this.handleCopyButton=()=>{navigator.clipboard.writeText(this.value),this.copy.emit(this.value)},this.handleKeyUp=i=>{var t;if("Enter"!==i.key)return;const s=null!==(t=this.currentInput)&&void 0!==t?t:"";this.isValidIdentifier(s)&&this.change.emit(this.currentInput)},this.isValidIdentifier=i=>"component"!==this.type||Boolean(customElements.get(i)),this.renderPicker=()=>{let i=this.allItems.find((i=>this.value===i.value));return!i&&this.value&&(i={text:this.value,value:this.value,icon:{name:"question",color:"rgb(var(--color-glaucous-light))"}}),s("limel-picker",{disabled:this.disabled,helperText:this.helperText,label:this.label,readonly:this.readonly,required:this.required,searcher:this.search,value:i,title:null==i?void 0:i.text,onBlur:this.handleBlur,onChange:this.handleChange,onKeyUp:this.handleKeyUp})},this.renderCopyButton=()=>{if(!this.hideCopyButton)return s("limel-icon-button",{icon:"copy",disabled:!this.value,label:this.copyLabel,onClick:this.handleCopyButton})},this.search=async i=>i?this.allItems.filter(this.isItemMatching(i.toLocaleLowerCase())):this.allItems,this.isItemMatching=i=>t=>{var s,o;return t.text.toLocaleLowerCase().includes(i)||(null===(s=t.secondaryText)||void 0===s?void 0:s.toLocaleLowerCase().includes(i))||(null===(o=t.value)||void 0===o?void 0:o.toLocaleLowerCase().includes(i))}}componentWillLoad(){this.allItems=this.getConfigs().filter(this.hasTag).map((i=>{var t,s;return{value:this.getConfigValue(i),text:this.translator.get(null!==(t=i.title)&&void 0!==t?t:this.getConfigValue(i)),secondaryText:this.translator.get(null!==(s=i.description)&&void 0!==s?s:""),icon:i.icon}})).sort(((i,t)=>i.text.localeCompare(t.text)))}render(){return[this.renderPicker(),this.renderCopyButton()]}get currentInput(){var i,t,s,o,e,n;return null===(n=null===(e=null===(o=null===(s=null===(t=null===(i=this.host.shadowRoot)||void 0===i?void 0:i.querySelector("limel-picker"))||void 0===t?void 0:t.shadowRoot)||void 0===s?void 0:s.querySelector("limel-chip-set"))||void 0===o?void 0:o.shadowRoot)||void 0===e?void 0:e.querySelector("input"))||void 0===n?void 0:n.value}get webComponentRegistry(){return this.platform.get(e.WebComponentRegistry)}get commandbus(){return this.platform.get(e.CommandBus)}get translator(){return this.platform.get(e.Translate)}get host(){return o(this)}};n.style=":host(limebb-component-picker){position:relative;display:flex;align-items:center}:host(limebb-component-picker) limel-picker{flex-grow:1;min-width:0}:host(limebb-component-picker) limel-icon-button{position:absolute;right:0.25rem}";export{n as limebb_component_picker}