verben-ng-ui 1.3.7 → 1.3.8

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.
@@ -75,6 +75,12 @@ class DataFilterComponent {
75
75
  // Set once the user edits the panel, so restored/host filters no longer
76
76
  // overwrite their in-progress work.
77
77
  userTouched = false;
78
+ /**
79
+ * The saved filter currently loaded into the operation row, if any. Held by
80
+ * reference rather than by index so deleting or reordering another filter
81
+ * cannot retarget the write-back.
82
+ */
83
+ editingFilter = null;
78
84
  ngOnInit() {
79
85
  this.initializeFilterableColumns();
80
86
  this.hydrateSavedFilters();
@@ -112,7 +118,14 @@ class DataFilterComponent {
112
118
  // Reset other values
113
119
  this.currentFilter.operator = undefined;
114
120
  this.currentFilter.value = undefined;
115
- // Determine column type and set available operators
121
+ this.applyColumnContext(column);
122
+ }
123
+ /**
124
+ * Derives the value control, operators and options for a column without
125
+ * touching the operator or value already in the operation row — `editFilter`
126
+ * depends on those surviving, where `onColumnSelect` clears them first.
127
+ */
128
+ applyColumnContext(column) {
116
129
  this.currentColumnType = this.resolveColumnType(column);
117
130
  this.valueOptions =
118
131
  this.currentColumnType === 'bool'
@@ -148,18 +161,98 @@ class DataFilterComponent {
148
161
  if (!this.currentFilter.columnId || !this.currentFilter.operator || !hasValue) {
149
162
  return;
150
163
  }
151
- const newFilter = {
164
+ const condition = {
152
165
  columnId: this.currentFilter.columnId,
153
166
  operator: this.currentFilter.operator,
154
167
  // Bool values round-trip through the dropdown as strings; hosts receive
155
168
  // a real boolean.
156
169
  value: this.currentColumnType === 'bool' ? value === 'true' : value,
157
- selected: true,
158
170
  };
159
- this.savedFilters.unshift(newFilter);
171
+ // Written back over the filter being edited, and over the existing chip of a
172
+ // required column, so neither case leaves a stale duplicate behind. Updated
173
+ // in place rather than removed and re-added so the chip keeps its position.
174
+ const target = this.editingFilter ??
175
+ (this.isRequiredColumn(condition.columnId)
176
+ ? this.savedFilters.find((f) => f.columnId === condition.columnId)
177
+ : undefined);
178
+ if (target) {
179
+ Object.assign(target, condition);
180
+ target.selected = true;
181
+ }
182
+ else {
183
+ this.savedFilters.unshift({ ...condition, selected: true });
184
+ }
185
+ this.editingFilter = null;
160
186
  this.userTouched = true;
161
187
  this.resetCurrentFilter();
162
188
  }
189
+ /** Loads a saved filter back into the operation row for correction. */
190
+ editFilter(filter) {
191
+ const column = this.filterableColumns.find((col) => col.id === filter.columnId);
192
+ if (!column)
193
+ return;
194
+ this.applyColumnContext(column);
195
+ this.currentFilter = {
196
+ columnId: filter.columnId,
197
+ operator: filter.operator,
198
+ value: this.toEditableValue(filter.value),
199
+ };
200
+ this.editingFilter = filter;
201
+ this.userTouched = true;
202
+ }
203
+ /**
204
+ * Converts a stored value back into what the value control expects: bools are
205
+ * held as real booleans but the dropdown's options are the strings
206
+ * 'true'/'false' (see `boolOptions`), and the native date input needs
207
+ * 'YYYY-MM-DD' rather than a `Date` a host may have restored.
208
+ */
209
+ toEditableValue(value) {
210
+ if (this.currentColumnType === 'bool')
211
+ return `${value}`;
212
+ if (value instanceof Date) {
213
+ // Built from the local parts: `toISOString` shifts to UTC and would move
214
+ // the date a day back west of Greenwich.
215
+ const month = `${value.getMonth() + 1}`.padStart(2, '0');
216
+ const day = `${value.getDate()}`.padStart(2, '0');
217
+ return `${value.getFullYear()}-${month}-${day}`;
218
+ }
219
+ return value;
220
+ }
221
+ /** Removes a saved filter. Required filters cannot be removed. */
222
+ deleteFilter(filter) {
223
+ if (this.isRequired(filter))
224
+ return;
225
+ const index = this.savedFilters.indexOf(filter);
226
+ if (index === -1)
227
+ return;
228
+ this.savedFilters.splice(index, 1);
229
+ if (this.editingFilter === filter)
230
+ this.clearCurrentFilter();
231
+ this.userTouched = true;
232
+ }
233
+ /** Empties the operation row, abandoning any edit in progress. */
234
+ clearCurrentFilter() {
235
+ this.editingFilter = null;
236
+ this.resetCurrentFilter();
237
+ }
238
+ /** True when the filter's column is declared `isRequiredFilter`. */
239
+ isRequired(filter) {
240
+ return this.isRequiredColumn(filter.columnId);
241
+ }
242
+ isRequiredColumn(columnId) {
243
+ const column = this.filterableColumns.find((col) => col.id === columnId);
244
+ return !!column?.isRequiredFilter;
245
+ }
246
+ isEditing(filter) {
247
+ return this.editingFilter === filter;
248
+ }
249
+ /**
250
+ * Locks the property dropdown while a required filter is being edited —
251
+ * switching it to another column would drop the required filter entirely.
252
+ */
253
+ get isEditingRequired() {
254
+ return !!this.editingFilter && this.isRequired(this.editingFilter);
255
+ }
163
256
  getFilterDescription(filter) {
164
257
  const column = this.filterableColumns.find((col) => col.id === filter.columnId);
165
258
  if (!column)
@@ -289,14 +382,23 @@ class DataFilterComponent {
289
382
  }
290
383
  resetAll() {
291
384
  this.userTouched = true;
292
- this.savedFilters = [];
293
- this.resetCurrentFilter();
385
+ this.savedFilters = this.savedFilters.filter((filter) => this.isRequired(filter));
386
+ this.clearCurrentFilter();
387
+ // Required filters survive a reset, so the host is told what is left rather
388
+ // than that everything is gone — a bare `resetFilter` would leave the panel
389
+ // showing chips the host is no longer filtering by.
390
+ if (this.savedFilters.length) {
391
+ this.applyFilters();
392
+ return;
393
+ }
294
394
  this.resetFilter.emit();
295
395
  }
296
396
  applyFilters() {
297
397
  this.userTouched = true;
298
398
  const activeFilters = this.savedFilters
299
- .filter((filter) => filter.selected)
399
+ // Required filters are emitted whether or not they are ticked: their
400
+ // checkbox is disabled, but the host must never be left without them.
401
+ .filter((filter) => filter.selected || this.isRequired(filter))
300
402
  .map(({ columnId, operator, value }) => ({
301
403
  columnId,
302
404
  operator,
@@ -312,20 +414,30 @@ class DataFilterComponent {
312
414
  : column.header
313
415
  : columnId;
314
416
  }
417
+ /**
418
+ * Required filters pinned to the top so the collapsed list can never hide one
419
+ * behind "Show More".
420
+ */
421
+ get orderedFilters() {
422
+ return [
423
+ ...this.savedFilters.filter((filter) => this.isRequired(filter)),
424
+ ...this.savedFilters.filter((filter) => !this.isRequired(filter)),
425
+ ];
426
+ }
315
427
  get visibleFilters() {
316
428
  return this.showAllFilters
317
- ? this.savedFilters
318
- : this.savedFilters.slice(0, this.maxVisibleItems);
429
+ ? this.orderedFilters
430
+ : this.orderedFilters.slice(0, this.maxVisibleItems);
319
431
  }
320
432
  get activeFilterCount() {
321
- return this.savedFilters.filter((filter) => filter.selected).length;
433
+ return this.savedFilters.filter((filter) => filter.selected || this.isRequired(filter)).length;
322
434
  }
323
435
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.10", ngImport: i0, type: DataFilterComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
324
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.10", type: DataFilterComponent, selector: "lib-data-filter", inputs: { columns: "columns", data: "data", initialFilters: "initialFilters" }, outputs: { filterApplied: "filterApplied", resetFilter: "resetFilter" }, usesOnChanges: true, ngImport: i0, template: "<verben-card\n width=\"24rem\"\n borderRadius=\"1rem\"\n [border]=\"'1px solid var(--vbn-color-primary)'\"\n bgColor=\"var(--vbn-color-surface)\"\n>\n <div card-header class=\"card-header\">\n <h4 class=\"header-title\">\n Filter <sup>({{ activeFilterCount }})</sup>\n </h4>\n <button\n class=\"reset-button\"\n [style.color]=\"'var(--vbn-color-border-focus)'\"\n [style.background-color]=\"'transparent'\"\n [style.border]=\"'none'\"\n [style.cursor]=\"'pointer'\"\n [style.font-size]=\"'12px'\"\n (click)=\"resetAll()\"\n >\n Reset\n </button>\n </div>\n\n <div card-body class=\"card-body\">\n <!-- Saved Filters Section -->\n <section class=\"section\">\n <div class=\"section-header\">\n <h3 class=\"section-title\">Filters</h3>\n <verben-svg\n icon=\"info\"\n [width]=\"15\"\n [height]=\"15\"\n fill=\"var(--vbn-color-text-muted)\"\n ></verben-svg>\n </div>\n\n <div *ngFor=\"let filter of visibleFilters\" class=\"item\">\n <div class=\"item-label\">\n <input type=\"checkbox\" [(ngModel)]=\"filter.selected\" (ngModelChange)=\"markTouched()\" />\n <label>{{ getFilterDescription(filter) }}</label>\n </div>\n </div>\n\n <div\n *ngIf=\"savedFilters.length > maxVisibleItems\"\n class=\"show-more\"\n (click)=\"showAllFilters = !showAllFilters\"\n >\n {{ showAllFilters ? \"Show Less\" : \"Show More\" }}\n </div>\n </section>\n\n <hr class=\"divider\" />\n\n <!-- New Filter Operation -->\n <section class=\"section\">\n <div class=\"section-header\">\n <h3 class=\"section-title\">Operation</h3>\n <verben-svg\n icon=\"info\"\n [width]=\"15\"\n [height]=\"15\"\n fill=\"var(--vbn-color-text-muted)\"\n ></verben-svg>\n </div>\n\n <div class=\"operation-grid\">\n <!-- Column Selection -->\n <verben-drop-down\n width=\"100%\"\n height=\"1.025rem\"\n placeholder=\"Select column\"\n [options]=\"filterableColumns\"\n optionLabel=\"header\"\n optionValue=\"id\"\n [(ngModel)]=\"currentFilter.columnId\"\n (ngModelChange)=\"onColumnSelect($event)\"\n ></verben-drop-down>\n\n <!-- Operator Selection -->\n <verben-drop-down\n width=\"100%\"\n height=\"1.025rem\"\n placeholder=\"Select operator\"\n [options]=\"availableOperators\"\n optionLabel=\"label\"\n optionValue=\"value\"\n [(ngModel)]=\"currentFilter.operator\"\n ></verben-drop-down>\n\n <!-- Value Input based on type -->\n <ng-container [ngSwitch]=\"currentColumnType\">\n <!-- Date Input \u2014 native rather than the library date picker, whose\n overlay renders off screen from this narrow panel. -->\n <verbena-input\n *ngSwitchCase=\"'date'\"\n type=\"date\"\n placeHolder=\"Select date\"\n border=\"1px solid var(--vbn-color-border)\"\n borderRadius=\"5px\"\n textColor=\"var(--vbn-color-text)\"\n width=\"100%\"\n height=\"1.025rem\"\n pd=\"2px 6px\"\n [(ngModel)]=\"currentFilter.value\"\n ></verbena-input>\n\n <!-- Number Input -->\n <verbena-input\n *ngSwitchCase=\"'number'\"\n type=\"number\"\n placeHolder=\"Enter number\"\n border=\"1px solid var(--vbn-color-border)\"\n borderRadius=\"5px\"\n textColor=\"var(--vbn-color-text)\"\n width=\"100%\"\n height=\"1.025rem\"\n pd=\"2px 6px\"\n [(ngModel)]=\"currentFilter.value\"\n ></verbena-input>\n\n <!-- Yes / No Selection -->\n <verben-drop-down\n *ngSwitchCase=\"'bool'\"\n width=\"100%\"\n height=\"1.025rem\"\n placeholder=\"Select value\"\n [options]=\"valueOptions\"\n optionLabel=\"label\"\n optionValue=\"value\"\n [(ngModel)]=\"currentFilter.value\"\n ></verben-drop-down>\n\n <!-- Enum Member Selection -->\n <verben-drop-down\n *ngSwitchCase=\"'enum'\"\n width=\"100%\"\n height=\"1.025rem\"\n placeholder=\"Select value\"\n [options]=\"valueOptions\"\n optionLabel=\"label\"\n optionValue=\"value\"\n [(ngModel)]=\"currentFilter.value\"\n ></verben-drop-down>\n\n <!-- Text Input (default) -->\n <verbena-input\n *ngSwitchDefault\n type=\"text\"\n placeHolder=\"Enter text\"\n border=\"1px solid var(--vbn-color-border)\"\n borderRadius=\"5px\"\n textColor=\"var(--vbn-color-text)\"\n width=\"100%\"\n height=\"1.025rem\"\n pd=\"2px 6px\"\n [(ngModel)]=\"currentFilter.value\"\n ></verbena-input>\n </ng-container>\n </div>\n\n <button class=\"add-button ml-auto\" (click)=\"addFilter()\">+ Add</button>\n </section>\n </div>\n\n <div card-footer class=\"card-footer\">\n <button class=\"export-button\" (click)=\"applyFilters()\">Filter</button>\n </div>\n</verben-card>\n", styles: [".export-card{font-size:.75rem;z-index:10}.card-header{display:flex;justify-content:space-between;align-items:center;background-color:transparent;padding:4px!important}.header-title{font-weight:600;font-size:.8125rem}.card-body,.section{display:flex;flex-direction:column;gap:.5rem}.section-header{display:flex;justify-content:space-between;align-items:center}.section-title{font-size:.8125rem}.item{display:flex;justify-content:space-between;align-items:center}.item-label{display:flex;align-items:center;gap:.5rem}.checkbox-label{line-height:1}.item-actions{display:flex;gap:.5rem}.show-more{display:flex;gap:.5em;align-items:center;color:var(--vbn-color-text-muted);cursor:pointer}.divider{border:none;border-top:1px solid var(--vbn-color-border)}.operation-grid{width:100%;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:1rem}.add-button{margin-top:.5rem;outline:none;border:none;background-color:transparent;color:var(--vbn-color-border-focus);font-size:.75rem;font-weight:500;cursor:pointer}.card-footer{display:flex;justify-content:flex-end;background-color:transparent}.export-button{margin-top:.5rem;outline:none;border:none;padding:.2rem 1.6rem;background-color:var(--vbn-color-primary);color:var(--vbn-color-on-primary);font-size:.75rem;font-weight:600;cursor:pointer}sup{color:var(--vbn-color-border-focus)}\n"], dependencies: [{ kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: i1.NgSwitchDefault, selector: "[ngSwitchDefault]" }, { kind: "directive", type: i2.CheckboxControlValueAccessor, selector: "input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i3.SvgComponent, selector: "verben-svg", inputs: ["icon", "width", "height", "fill", "stroke", "type", "size"] }, { kind: "component", type: i4.CardComponent, selector: "verben-card", inputs: ["pd", "mg", "height", "width", "textColor", "bgColor", "border", "borderRadius", "disabled", "aspectRatio"] }, { kind: "component", type: i5.DropDownComponent, selector: "verben-drop-down", inputs: ["options", "width", "overlayWidth", "showHorizontalLine", "horizontalLineColor", "optionLabel", "optionSubLabel", "optionValue", "placeholder", "invalidMessage", "errorPosition", "loadMoreCaption", "display", "showClear", "lazyLoad", "selectKey", "styleClass", "group", "multiselect", "filter", "avoidDuplication", "filterBy", "debounceTime", "minChar", "refPageSize", "disabled", "required", "load", "asyncLabel", "search"], outputs: ["optionsChange", "onChange", "onClick", "onClear"] }, { kind: "component", type: i6.VerbenaInputComponent, selector: "verbena-input", inputs: ["disabled", "label", "placeHolder", "required", "svgPosition", "minLength", "maxLength", "type", "bgColor", "border", "borderRadius", "textColor", "value", "labelPosition", "labelColor", "disable", "readOnly", "min", "max", "showBorder", "showErrorMessage", "errorMessageColor", "errorBorderColor", "errorPosition", "svg", "fontSize", "svgWidth", "svgHeight", "svgColor", "capitalization", "inputContainerClass", "inputFieldClass", "passLength", "inputWrapperClass", "passwordToggle", "customErrorMessages", "icon", "textPass"], outputs: ["valueChange"] }] });
436
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.10", type: DataFilterComponent, selector: "lib-data-filter", inputs: { columns: "columns", data: "data", initialFilters: "initialFilters" }, outputs: { filterApplied: "filterApplied", resetFilter: "resetFilter" }, usesOnChanges: true, ngImport: i0, template: "<verben-card\n width=\"24rem\"\n borderRadius=\"1rem\"\n [border]=\"'1px solid var(--vbn-color-primary)'\"\n bgColor=\"var(--vbn-color-surface)\"\n>\n <div card-header class=\"card-header\">\n <h4 class=\"header-title\">\n Filter <sup>({{ activeFilterCount }})</sup>\n </h4>\n <button\n class=\"reset-button\"\n [style.color]=\"'var(--vbn-color-border-focus)'\"\n [style.background-color]=\"'transparent'\"\n [style.border]=\"'none'\"\n [style.cursor]=\"'pointer'\"\n [style.font-size]=\"'12px'\"\n (click)=\"resetAll()\"\n >\n Reset\n </button>\n </div>\n\n <div card-body class=\"card-body\">\n <!-- Saved Filters Section -->\n <section class=\"section\">\n <div class=\"section-header\">\n <h3 class=\"section-title\">Filters</h3>\n <verben-svg\n icon=\"info\"\n [width]=\"15\"\n [height]=\"15\"\n fill=\"var(--vbn-color-text-muted)\"\n ></verben-svg>\n </div>\n\n <div\n *ngFor=\"let filter of visibleFilters\"\n class=\"item\"\n [class.item-editing]=\"isEditing(filter)\"\n >\n <div class=\"item-label\">\n <!-- A required filter is always active, so its checkbox is ticked and\n locked rather than hidden \u2014 the state stays readable. -->\n <input\n type=\"checkbox\"\n [(ngModel)]=\"filter.selected\"\n [disabled]=\"isRequired(filter)\"\n (ngModelChange)=\"markTouched()\"\n />\n <label>{{ getFilterDescription(filter) }}</label>\n </div>\n\n <div class=\"item-actions\">\n <button\n type=\"button\"\n class=\"icon-button\"\n aria-label=\"Edit filter\"\n (click)=\"editFilter(filter)\"\n >\n <!-- Only `stroke` is passed: `verben-svg` resolves a single colour as\n `fill || stroke` and applies it to both, so also passing `fill`\n would paint the icon in whatever `fill` holds. -->\n <verben-svg\n icon=\"edit\"\n [width]=\"15\"\n [height]=\"15\"\n stroke=\"var(--vbn-color-border-focus)\"\n ></verben-svg>\n </button>\n <button\n type=\"button\"\n class=\"icon-button\"\n aria-label=\"Delete filter\"\n [disabled]=\"isRequired(filter)\"\n (click)=\"deleteFilter(filter)\"\n >\n <verben-svg\n icon=\"delete\"\n [width]=\"15\"\n [height]=\"15\"\n stroke=\"var(--vbn-color-error)\"\n ></verben-svg>\n </button>\n </div>\n </div>\n\n <div\n *ngIf=\"savedFilters.length > maxVisibleItems\"\n class=\"show-more\"\n (click)=\"showAllFilters = !showAllFilters\"\n >\n {{ showAllFilters ? \"Show Less\" : \"Show More\" }}\n </div>\n </section>\n\n <hr class=\"divider\" />\n\n <!-- New Filter Operation -->\n <section class=\"section\">\n <div class=\"section-header\">\n <h3 class=\"section-title\">Operation</h3>\n <verben-svg\n icon=\"info\"\n [width]=\"15\"\n [height]=\"15\"\n fill=\"var(--vbn-color-text-muted)\"\n ></verben-svg>\n </div>\n\n <div class=\"operation-grid\">\n <!-- Column Selection -->\n <verben-drop-down\n width=\"100%\"\n height=\"1.025rem\"\n placeholder=\"Select column\"\n [options]=\"filterableColumns\"\n optionLabel=\"header\"\n optionValue=\"id\"\n [disabled]=\"isEditingRequired\"\n [(ngModel)]=\"currentFilter.columnId\"\n (ngModelChange)=\"onColumnSelect($event)\"\n ></verben-drop-down>\n\n <!-- Operator Selection -->\n <verben-drop-down\n width=\"100%\"\n height=\"1.025rem\"\n placeholder=\"Select operator\"\n [options]=\"availableOperators\"\n optionLabel=\"label\"\n optionValue=\"value\"\n [(ngModel)]=\"currentFilter.operator\"\n ></verben-drop-down>\n\n <!-- Value Input based on type -->\n <ng-container [ngSwitch]=\"currentColumnType\">\n <!-- Date Input \u2014 native rather than the library date picker, whose\n overlay renders off screen from this narrow panel. -->\n <verbena-input\n *ngSwitchCase=\"'date'\"\n type=\"date\"\n placeHolder=\"Select date\"\n border=\"1px solid var(--vbn-color-border)\"\n borderRadius=\"5px\"\n textColor=\"var(--vbn-color-text)\"\n width=\"100%\"\n height=\"1.025rem\"\n pd=\"2px 6px\"\n [(ngModel)]=\"currentFilter.value\"\n ></verbena-input>\n\n <!-- Number Input -->\n <verbena-input\n *ngSwitchCase=\"'number'\"\n type=\"number\"\n placeHolder=\"Enter number\"\n border=\"1px solid var(--vbn-color-border)\"\n borderRadius=\"5px\"\n textColor=\"var(--vbn-color-text)\"\n width=\"100%\"\n height=\"1.025rem\"\n pd=\"2px 6px\"\n [(ngModel)]=\"currentFilter.value\"\n ></verbena-input>\n\n <!-- Yes / No Selection -->\n <verben-drop-down\n *ngSwitchCase=\"'bool'\"\n width=\"100%\"\n height=\"1.025rem\"\n placeholder=\"Select value\"\n [options]=\"valueOptions\"\n optionLabel=\"label\"\n optionValue=\"value\"\n [(ngModel)]=\"currentFilter.value\"\n ></verben-drop-down>\n\n <!-- Enum Member Selection -->\n <verben-drop-down\n *ngSwitchCase=\"'enum'\"\n width=\"100%\"\n height=\"1.025rem\"\n placeholder=\"Select value\"\n [options]=\"valueOptions\"\n optionLabel=\"label\"\n optionValue=\"value\"\n [(ngModel)]=\"currentFilter.value\"\n ></verben-drop-down>\n\n <!-- Text Input (default) -->\n <verbena-input\n *ngSwitchDefault\n type=\"text\"\n placeHolder=\"Enter text\"\n border=\"1px solid var(--vbn-color-border)\"\n borderRadius=\"5px\"\n textColor=\"var(--vbn-color-text)\"\n width=\"100%\"\n height=\"1.025rem\"\n pd=\"2px 6px\"\n [(ngModel)]=\"currentFilter.value\"\n ></verbena-input>\n </ng-container>\n </div>\n\n <div class=\"operation-actions\">\n <button class=\"clear-button\" (click)=\"clearCurrentFilter()\">\n Clear\n </button>\n <button class=\"add-button\" (click)=\"addFilter()\">+ Add</button>\n </div>\n </section>\n </div>\n\n <div card-footer class=\"card-footer\">\n <button class=\"export-button\" (click)=\"applyFilters()\">Filter</button>\n </div>\n</verben-card>\n", styles: [".export-card{font-size:.75rem;z-index:10}.card-header{display:flex;justify-content:space-between;align-items:center;background-color:transparent;padding:4px!important}.header-title{font-weight:600;font-size:.8125rem}.card-body,.section{display:flex;flex-direction:column;gap:.5rem}.section-header{display:flex;justify-content:space-between;align-items:center}.section-title{font-size:.8125rem}.item{display:flex;justify-content:space-between;align-items:center;gap:.5rem}.item-editing{background-color:var(--vbn-color-surface-alt);border-radius:4px}.item-label{display:flex;align-items:center;gap:.5rem;flex:1;min-width:0}.item-label label{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.checkbox-label{line-height:1}.item-actions{display:flex;gap:.5rem}.icon-button{display:inline-flex;align-items:center;padding:0;border:none;background-color:transparent;cursor:pointer}.icon-button[disabled]{cursor:not-allowed;opacity:.4}.show-more{display:flex;gap:.5em;align-items:center;color:var(--vbn-color-text-muted);cursor:pointer}.divider{border:none;border-top:1px solid var(--vbn-color-border)}.operation-grid{width:100%;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:1rem}.operation-actions{display:flex;justify-content:flex-end;gap:.75rem}.add-button,.clear-button{margin-top:.5rem;outline:none;border:none;background-color:transparent;font-size:.75rem;font-weight:500;cursor:pointer}.add-button{color:var(--vbn-color-border-focus)}.clear-button{color:var(--vbn-color-text-muted)}.card-footer{display:flex;justify-content:flex-end;background-color:transparent}.export-button{margin-top:.5rem;outline:none;border:none;padding:.2rem 1.6rem;background-color:var(--vbn-color-primary);color:var(--vbn-color-on-primary);font-size:.75rem;font-weight:600;cursor:pointer}sup{color:var(--vbn-color-border-focus)}\n"], dependencies: [{ kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: i1.NgSwitchDefault, selector: "[ngSwitchDefault]" }, { kind: "directive", type: i2.CheckboxControlValueAccessor, selector: "input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i3.SvgComponent, selector: "verben-svg", inputs: ["icon", "width", "height", "fill", "stroke", "type", "size"] }, { kind: "component", type: i4.CardComponent, selector: "verben-card", inputs: ["pd", "mg", "height", "width", "textColor", "bgColor", "border", "borderRadius", "disabled", "aspectRatio"] }, { kind: "component", type: i5.DropDownComponent, selector: "verben-drop-down", inputs: ["options", "width", "overlayWidth", "showHorizontalLine", "horizontalLineColor", "optionLabel", "optionSubLabel", "optionValue", "placeholder", "invalidMessage", "errorPosition", "loadMoreCaption", "display", "showClear", "lazyLoad", "selectKey", "styleClass", "group", "multiselect", "filter", "avoidDuplication", "filterBy", "debounceTime", "minChar", "refPageSize", "disabled", "required", "load", "asyncLabel", "search"], outputs: ["optionsChange", "onChange", "onClick", "onClear"] }, { kind: "component", type: i6.VerbenaInputComponent, selector: "verbena-input", inputs: ["disabled", "label", "placeHolder", "required", "svgPosition", "minLength", "maxLength", "type", "bgColor", "border", "borderRadius", "textColor", "value", "labelPosition", "labelColor", "disable", "readOnly", "min", "max", "showBorder", "showErrorMessage", "errorMessageColor", "errorBorderColor", "errorPosition", "svg", "fontSize", "svgWidth", "svgHeight", "svgColor", "capitalization", "inputContainerClass", "inputFieldClass", "passLength", "inputWrapperClass", "passwordToggle", "customErrorMessages", "icon", "textPass"], outputs: ["valueChange"] }] });
325
437
  }
326
438
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.10", ngImport: i0, type: DataFilterComponent, decorators: [{
327
439
  type: Component,
328
- args: [{ selector: 'lib-data-filter', template: "<verben-card\n width=\"24rem\"\n borderRadius=\"1rem\"\n [border]=\"'1px solid var(--vbn-color-primary)'\"\n bgColor=\"var(--vbn-color-surface)\"\n>\n <div card-header class=\"card-header\">\n <h4 class=\"header-title\">\n Filter <sup>({{ activeFilterCount }})</sup>\n </h4>\n <button\n class=\"reset-button\"\n [style.color]=\"'var(--vbn-color-border-focus)'\"\n [style.background-color]=\"'transparent'\"\n [style.border]=\"'none'\"\n [style.cursor]=\"'pointer'\"\n [style.font-size]=\"'12px'\"\n (click)=\"resetAll()\"\n >\n Reset\n </button>\n </div>\n\n <div card-body class=\"card-body\">\n <!-- Saved Filters Section -->\n <section class=\"section\">\n <div class=\"section-header\">\n <h3 class=\"section-title\">Filters</h3>\n <verben-svg\n icon=\"info\"\n [width]=\"15\"\n [height]=\"15\"\n fill=\"var(--vbn-color-text-muted)\"\n ></verben-svg>\n </div>\n\n <div *ngFor=\"let filter of visibleFilters\" class=\"item\">\n <div class=\"item-label\">\n <input type=\"checkbox\" [(ngModel)]=\"filter.selected\" (ngModelChange)=\"markTouched()\" />\n <label>{{ getFilterDescription(filter) }}</label>\n </div>\n </div>\n\n <div\n *ngIf=\"savedFilters.length > maxVisibleItems\"\n class=\"show-more\"\n (click)=\"showAllFilters = !showAllFilters\"\n >\n {{ showAllFilters ? \"Show Less\" : \"Show More\" }}\n </div>\n </section>\n\n <hr class=\"divider\" />\n\n <!-- New Filter Operation -->\n <section class=\"section\">\n <div class=\"section-header\">\n <h3 class=\"section-title\">Operation</h3>\n <verben-svg\n icon=\"info\"\n [width]=\"15\"\n [height]=\"15\"\n fill=\"var(--vbn-color-text-muted)\"\n ></verben-svg>\n </div>\n\n <div class=\"operation-grid\">\n <!-- Column Selection -->\n <verben-drop-down\n width=\"100%\"\n height=\"1.025rem\"\n placeholder=\"Select column\"\n [options]=\"filterableColumns\"\n optionLabel=\"header\"\n optionValue=\"id\"\n [(ngModel)]=\"currentFilter.columnId\"\n (ngModelChange)=\"onColumnSelect($event)\"\n ></verben-drop-down>\n\n <!-- Operator Selection -->\n <verben-drop-down\n width=\"100%\"\n height=\"1.025rem\"\n placeholder=\"Select operator\"\n [options]=\"availableOperators\"\n optionLabel=\"label\"\n optionValue=\"value\"\n [(ngModel)]=\"currentFilter.operator\"\n ></verben-drop-down>\n\n <!-- Value Input based on type -->\n <ng-container [ngSwitch]=\"currentColumnType\">\n <!-- Date Input \u2014 native rather than the library date picker, whose\n overlay renders off screen from this narrow panel. -->\n <verbena-input\n *ngSwitchCase=\"'date'\"\n type=\"date\"\n placeHolder=\"Select date\"\n border=\"1px solid var(--vbn-color-border)\"\n borderRadius=\"5px\"\n textColor=\"var(--vbn-color-text)\"\n width=\"100%\"\n height=\"1.025rem\"\n pd=\"2px 6px\"\n [(ngModel)]=\"currentFilter.value\"\n ></verbena-input>\n\n <!-- Number Input -->\n <verbena-input\n *ngSwitchCase=\"'number'\"\n type=\"number\"\n placeHolder=\"Enter number\"\n border=\"1px solid var(--vbn-color-border)\"\n borderRadius=\"5px\"\n textColor=\"var(--vbn-color-text)\"\n width=\"100%\"\n height=\"1.025rem\"\n pd=\"2px 6px\"\n [(ngModel)]=\"currentFilter.value\"\n ></verbena-input>\n\n <!-- Yes / No Selection -->\n <verben-drop-down\n *ngSwitchCase=\"'bool'\"\n width=\"100%\"\n height=\"1.025rem\"\n placeholder=\"Select value\"\n [options]=\"valueOptions\"\n optionLabel=\"label\"\n optionValue=\"value\"\n [(ngModel)]=\"currentFilter.value\"\n ></verben-drop-down>\n\n <!-- Enum Member Selection -->\n <verben-drop-down\n *ngSwitchCase=\"'enum'\"\n width=\"100%\"\n height=\"1.025rem\"\n placeholder=\"Select value\"\n [options]=\"valueOptions\"\n optionLabel=\"label\"\n optionValue=\"value\"\n [(ngModel)]=\"currentFilter.value\"\n ></verben-drop-down>\n\n <!-- Text Input (default) -->\n <verbena-input\n *ngSwitchDefault\n type=\"text\"\n placeHolder=\"Enter text\"\n border=\"1px solid var(--vbn-color-border)\"\n borderRadius=\"5px\"\n textColor=\"var(--vbn-color-text)\"\n width=\"100%\"\n height=\"1.025rem\"\n pd=\"2px 6px\"\n [(ngModel)]=\"currentFilter.value\"\n ></verbena-input>\n </ng-container>\n </div>\n\n <button class=\"add-button ml-auto\" (click)=\"addFilter()\">+ Add</button>\n </section>\n </div>\n\n <div card-footer class=\"card-footer\">\n <button class=\"export-button\" (click)=\"applyFilters()\">Filter</button>\n </div>\n</verben-card>\n", styles: [".export-card{font-size:.75rem;z-index:10}.card-header{display:flex;justify-content:space-between;align-items:center;background-color:transparent;padding:4px!important}.header-title{font-weight:600;font-size:.8125rem}.card-body,.section{display:flex;flex-direction:column;gap:.5rem}.section-header{display:flex;justify-content:space-between;align-items:center}.section-title{font-size:.8125rem}.item{display:flex;justify-content:space-between;align-items:center}.item-label{display:flex;align-items:center;gap:.5rem}.checkbox-label{line-height:1}.item-actions{display:flex;gap:.5rem}.show-more{display:flex;gap:.5em;align-items:center;color:var(--vbn-color-text-muted);cursor:pointer}.divider{border:none;border-top:1px solid var(--vbn-color-border)}.operation-grid{width:100%;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:1rem}.add-button{margin-top:.5rem;outline:none;border:none;background-color:transparent;color:var(--vbn-color-border-focus);font-size:.75rem;font-weight:500;cursor:pointer}.card-footer{display:flex;justify-content:flex-end;background-color:transparent}.export-button{margin-top:.5rem;outline:none;border:none;padding:.2rem 1.6rem;background-color:var(--vbn-color-primary);color:var(--vbn-color-on-primary);font-size:.75rem;font-weight:600;cursor:pointer}sup{color:var(--vbn-color-border-focus)}\n"] }]
440
+ args: [{ selector: 'lib-data-filter', template: "<verben-card\n width=\"24rem\"\n borderRadius=\"1rem\"\n [border]=\"'1px solid var(--vbn-color-primary)'\"\n bgColor=\"var(--vbn-color-surface)\"\n>\n <div card-header class=\"card-header\">\n <h4 class=\"header-title\">\n Filter <sup>({{ activeFilterCount }})</sup>\n </h4>\n <button\n class=\"reset-button\"\n [style.color]=\"'var(--vbn-color-border-focus)'\"\n [style.background-color]=\"'transparent'\"\n [style.border]=\"'none'\"\n [style.cursor]=\"'pointer'\"\n [style.font-size]=\"'12px'\"\n (click)=\"resetAll()\"\n >\n Reset\n </button>\n </div>\n\n <div card-body class=\"card-body\">\n <!-- Saved Filters Section -->\n <section class=\"section\">\n <div class=\"section-header\">\n <h3 class=\"section-title\">Filters</h3>\n <verben-svg\n icon=\"info\"\n [width]=\"15\"\n [height]=\"15\"\n fill=\"var(--vbn-color-text-muted)\"\n ></verben-svg>\n </div>\n\n <div\n *ngFor=\"let filter of visibleFilters\"\n class=\"item\"\n [class.item-editing]=\"isEditing(filter)\"\n >\n <div class=\"item-label\">\n <!-- A required filter is always active, so its checkbox is ticked and\n locked rather than hidden \u2014 the state stays readable. -->\n <input\n type=\"checkbox\"\n [(ngModel)]=\"filter.selected\"\n [disabled]=\"isRequired(filter)\"\n (ngModelChange)=\"markTouched()\"\n />\n <label>{{ getFilterDescription(filter) }}</label>\n </div>\n\n <div class=\"item-actions\">\n <button\n type=\"button\"\n class=\"icon-button\"\n aria-label=\"Edit filter\"\n (click)=\"editFilter(filter)\"\n >\n <!-- Only `stroke` is passed: `verben-svg` resolves a single colour as\n `fill || stroke` and applies it to both, so also passing `fill`\n would paint the icon in whatever `fill` holds. -->\n <verben-svg\n icon=\"edit\"\n [width]=\"15\"\n [height]=\"15\"\n stroke=\"var(--vbn-color-border-focus)\"\n ></verben-svg>\n </button>\n <button\n type=\"button\"\n class=\"icon-button\"\n aria-label=\"Delete filter\"\n [disabled]=\"isRequired(filter)\"\n (click)=\"deleteFilter(filter)\"\n >\n <verben-svg\n icon=\"delete\"\n [width]=\"15\"\n [height]=\"15\"\n stroke=\"var(--vbn-color-error)\"\n ></verben-svg>\n </button>\n </div>\n </div>\n\n <div\n *ngIf=\"savedFilters.length > maxVisibleItems\"\n class=\"show-more\"\n (click)=\"showAllFilters = !showAllFilters\"\n >\n {{ showAllFilters ? \"Show Less\" : \"Show More\" }}\n </div>\n </section>\n\n <hr class=\"divider\" />\n\n <!-- New Filter Operation -->\n <section class=\"section\">\n <div class=\"section-header\">\n <h3 class=\"section-title\">Operation</h3>\n <verben-svg\n icon=\"info\"\n [width]=\"15\"\n [height]=\"15\"\n fill=\"var(--vbn-color-text-muted)\"\n ></verben-svg>\n </div>\n\n <div class=\"operation-grid\">\n <!-- Column Selection -->\n <verben-drop-down\n width=\"100%\"\n height=\"1.025rem\"\n placeholder=\"Select column\"\n [options]=\"filterableColumns\"\n optionLabel=\"header\"\n optionValue=\"id\"\n [disabled]=\"isEditingRequired\"\n [(ngModel)]=\"currentFilter.columnId\"\n (ngModelChange)=\"onColumnSelect($event)\"\n ></verben-drop-down>\n\n <!-- Operator Selection -->\n <verben-drop-down\n width=\"100%\"\n height=\"1.025rem\"\n placeholder=\"Select operator\"\n [options]=\"availableOperators\"\n optionLabel=\"label\"\n optionValue=\"value\"\n [(ngModel)]=\"currentFilter.operator\"\n ></verben-drop-down>\n\n <!-- Value Input based on type -->\n <ng-container [ngSwitch]=\"currentColumnType\">\n <!-- Date Input \u2014 native rather than the library date picker, whose\n overlay renders off screen from this narrow panel. -->\n <verbena-input\n *ngSwitchCase=\"'date'\"\n type=\"date\"\n placeHolder=\"Select date\"\n border=\"1px solid var(--vbn-color-border)\"\n borderRadius=\"5px\"\n textColor=\"var(--vbn-color-text)\"\n width=\"100%\"\n height=\"1.025rem\"\n pd=\"2px 6px\"\n [(ngModel)]=\"currentFilter.value\"\n ></verbena-input>\n\n <!-- Number Input -->\n <verbena-input\n *ngSwitchCase=\"'number'\"\n type=\"number\"\n placeHolder=\"Enter number\"\n border=\"1px solid var(--vbn-color-border)\"\n borderRadius=\"5px\"\n textColor=\"var(--vbn-color-text)\"\n width=\"100%\"\n height=\"1.025rem\"\n pd=\"2px 6px\"\n [(ngModel)]=\"currentFilter.value\"\n ></verbena-input>\n\n <!-- Yes / No Selection -->\n <verben-drop-down\n *ngSwitchCase=\"'bool'\"\n width=\"100%\"\n height=\"1.025rem\"\n placeholder=\"Select value\"\n [options]=\"valueOptions\"\n optionLabel=\"label\"\n optionValue=\"value\"\n [(ngModel)]=\"currentFilter.value\"\n ></verben-drop-down>\n\n <!-- Enum Member Selection -->\n <verben-drop-down\n *ngSwitchCase=\"'enum'\"\n width=\"100%\"\n height=\"1.025rem\"\n placeholder=\"Select value\"\n [options]=\"valueOptions\"\n optionLabel=\"label\"\n optionValue=\"value\"\n [(ngModel)]=\"currentFilter.value\"\n ></verben-drop-down>\n\n <!-- Text Input (default) -->\n <verbena-input\n *ngSwitchDefault\n type=\"text\"\n placeHolder=\"Enter text\"\n border=\"1px solid var(--vbn-color-border)\"\n borderRadius=\"5px\"\n textColor=\"var(--vbn-color-text)\"\n width=\"100%\"\n height=\"1.025rem\"\n pd=\"2px 6px\"\n [(ngModel)]=\"currentFilter.value\"\n ></verbena-input>\n </ng-container>\n </div>\n\n <div class=\"operation-actions\">\n <button class=\"clear-button\" (click)=\"clearCurrentFilter()\">\n Clear\n </button>\n <button class=\"add-button\" (click)=\"addFilter()\">+ Add</button>\n </div>\n </section>\n </div>\n\n <div card-footer class=\"card-footer\">\n <button class=\"export-button\" (click)=\"applyFilters()\">Filter</button>\n </div>\n</verben-card>\n", styles: [".export-card{font-size:.75rem;z-index:10}.card-header{display:flex;justify-content:space-between;align-items:center;background-color:transparent;padding:4px!important}.header-title{font-weight:600;font-size:.8125rem}.card-body,.section{display:flex;flex-direction:column;gap:.5rem}.section-header{display:flex;justify-content:space-between;align-items:center}.section-title{font-size:.8125rem}.item{display:flex;justify-content:space-between;align-items:center;gap:.5rem}.item-editing{background-color:var(--vbn-color-surface-alt);border-radius:4px}.item-label{display:flex;align-items:center;gap:.5rem;flex:1;min-width:0}.item-label label{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.checkbox-label{line-height:1}.item-actions{display:flex;gap:.5rem}.icon-button{display:inline-flex;align-items:center;padding:0;border:none;background-color:transparent;cursor:pointer}.icon-button[disabled]{cursor:not-allowed;opacity:.4}.show-more{display:flex;gap:.5em;align-items:center;color:var(--vbn-color-text-muted);cursor:pointer}.divider{border:none;border-top:1px solid var(--vbn-color-border)}.operation-grid{width:100%;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:1rem}.operation-actions{display:flex;justify-content:flex-end;gap:.75rem}.add-button,.clear-button{margin-top:.5rem;outline:none;border:none;background-color:transparent;font-size:.75rem;font-weight:500;cursor:pointer}.add-button{color:var(--vbn-color-border-focus)}.clear-button{color:var(--vbn-color-text-muted)}.card-footer{display:flex;justify-content:flex-end;background-color:transparent}.export-button{margin-top:.5rem;outline:none;border:none;padding:.2rem 1.6rem;background-color:var(--vbn-color-primary);color:var(--vbn-color-on-primary);font-size:.75rem;font-weight:600;cursor:pointer}sup{color:var(--vbn-color-border-focus)}\n"] }]
329
441
  }], propDecorators: { columns: [{
330
442
  type: Input
331
443
  }], data: [{
@@ -1 +1 @@
1
- {"version":3,"file":"verben-ng-ui-src-lib-components-data-filter.mjs","sources":["../../../projects/verben-ng-ui/src/lib/components/data-filter/data-filter.types.ts","../../../projects/verben-ng-ui/src/lib/components/data-filter/data-filter.component.ts","../../../projects/verben-ng-ui/src/lib/components/data-filter/data-filter.component.html","../../../projects/verben-ng-ui/src/lib/components/data-filter/data-filter.module.ts","../../../projects/verben-ng-ui/src/lib/components/data-filter/data-filter.service.ts","../../../projects/verben-ng-ui/src/lib/components/data-filter/verben-ng-ui-src-lib-components-data-filter.ts"],"sourcesContent":["export type FilterOperatorType =\n | 'string'\n | 'number'\n | 'date'\n | 'bool'\n | 'enum';\n\nexport interface FilterOperator {\n label: string;\n value: string;\n type: FilterOperatorType;\n}\n\nexport const STRING_OPERATORS: FilterOperator[] = [\n { label: 'Starts With', value: 'startsWith', type: 'string' },\n { label: 'Ends With', value: 'endsWith', type: 'string' },\n { label: 'Contains', value: 'contains', type: 'string' },\n { label: 'Equals', value: 'equals', type: 'string' },\n];\n\nexport const NUMBER_OPERATORS: FilterOperator[] = [\n { label: 'Equal', value: 'equal', type: 'number' },\n { label: 'Greater Than', value: 'greaterThan', type: 'number' },\n { label: 'Less Than', value: 'lessThan', type: 'number' },\n];\n\nexport const DATE_OPERATORS: FilterOperator[] = [\n { label: 'On', value: 'on', type: 'date' },\n { label: 'Before', value: 'before', type: 'date' },\n { label: 'After', value: 'after', type: 'date' },\n];\n\nexport const BOOL_OPERATORS: FilterOperator[] = [\n { label: 'Is', value: 'is', type: 'bool' },\n { label: 'Is Not', value: 'isNot', type: 'bool' },\n];\n\nexport const ENUM_OPERATORS: FilterOperator[] = [\n { label: 'Is', value: 'is', type: 'enum' },\n { label: 'Is Not', value: 'isNot', type: 'enum' },\n];\n\nexport interface FilterCondition {\n columnId: string;\n operator: string;\n value: string | number | boolean | Date;\n}\n\nexport interface FilterGroup {\n id: string;\n name: string;\n conditions: FilterCondition[];\n}\n\nexport interface FilterState {\n groups: FilterGroup[];\n activeFilters: FilterCondition[];\n}\n","import {\n Component,\n Input,\n Output,\n EventEmitter,\n OnChanges,\n OnInit,\n SimpleChanges,\n} from '@angular/core';\nimport {\n ColumnDefinition,\n ColumnValueOption,\n ColumnValueType,\n} from 'verben-ng-ui/src/lib/components/data-table';\nimport {\n FilterOperator,\n FilterOperatorType,\n FilterCondition,\n FilterGroup,\n STRING_OPERATORS,\n NUMBER_OPERATORS,\n DATE_OPERATORS,\n BOOL_OPERATORS,\n ENUM_OPERATORS,\n} from './data-filter.types';\n\n@Component({\n selector: 'lib-data-filter',\n templateUrl: './data-filter.component.html',\n styleUrl: './data-filter.component.css',\n})\nexport class DataFilterComponent<T> implements OnInit, OnChanges {\n @Input() columns!: ColumnDefinition<T>[];\n @Input() data!: T[];\n /**\n * Optional restored filters: the panel opens pre-populated with these as\n * selected filter chips. Applied once (the first time a non-empty value\n * arrives) so it never clobbers the user's in-progress edits afterwards.\n */\n @Input() initialFilters?: FilterCondition[];\n @Output() filterApplied = new EventEmitter<FilterCondition[]>();\n @Output() resetFilter = new EventEmitter();\n filterableColumns: ColumnDefinition<T>[] = [];\n availableOperators: FilterOperator[] = [];\n savedFilters: (FilterCondition & { selected: boolean })[] = [];\n currentFilter: Partial<FilterCondition> = {};\n showAllFilters = false;\n maxVisibleItems = 3;\n currentColumnType: FilterOperatorType | null = null;\n /**\n * Options for the value dropdown when the selected column is bool or enum.\n * Always normalised to `{ label, value }` so the template binds one shape.\n */\n valueOptions: ColumnValueOption[] = [];\n /**\n * Held as strings rather than booleans: `verben-drop-down` gates its selected\n * label on a truthiness check, so an option valued `false` would render as\n * though nothing were picked. Coerced back to a boolean in `addFilter`.\n */\n private readonly boolOptions: ColumnValueOption[] = [\n { label: 'Yes', value: 'true' },\n { label: 'No', value: 'false' },\n ];\n // Set once the user edits the panel, so restored/host filters no longer\n // overwrite their in-progress work.\n private userTouched = false;\n\n ngOnInit() {\n this.initializeFilterableColumns();\n this.hydrateSavedFilters();\n }\n\n ngOnChanges(changes: SimpleChanges) {\n // Pick up filters restored asynchronously by the host after first render.\n if (changes['initialFilters']) {\n this.hydrateSavedFilters();\n }\n }\n\n /**\n * Seed the saved-filter chips from the restored filters. Skipped once the user\n * has touched the panel so it never overwrites their in-progress edits.\n */\n private hydrateSavedFilters() {\n if (this.userTouched) return;\n this.savedFilters = (this.initialFilters ?? []).map((filter) => ({\n ...filter,\n selected: true,\n }));\n }\n\n /** Marks the panel as user-edited (called from template interactions). */\n markTouched() {\n this.userTouched = true;\n }\n\n private initializeFilterableColumns() {\n this.filterableColumns = this.columns.filter((col) => col.accessorKey);\n }\n\n onColumnSelect(columnId: string) {\n const column = this.filterableColumns.find((col) => col.id === columnId);\n if (!column) return;\n\n this.currentFilter.columnId = columnId;\n\n // Reset other values\n this.currentFilter.operator = undefined;\n this.currentFilter.value = undefined;\n\n // Determine column type and set available operators\n this.currentColumnType = this.resolveColumnType(column);\n this.valueOptions =\n this.currentColumnType === 'bool'\n ? this.boolOptions\n : this.currentColumnType === 'enum'\n ? this.normalizeValueOptions(column.valueOptions)\n : [];\n\n switch (this.currentColumnType) {\n case 'string':\n this.availableOperators = STRING_OPERATORS;\n break;\n case 'number':\n this.availableOperators = NUMBER_OPERATORS;\n break;\n case 'date':\n this.availableOperators = DATE_OPERATORS;\n break;\n case 'bool':\n this.availableOperators = BOOL_OPERATORS;\n break;\n case 'enum':\n this.availableOperators = ENUM_OPERATORS;\n break;\n default:\n this.availableOperators = [];\n }\n }\n\n addFilter() {\n const value = this.currentFilter.value;\n // Checked explicitly rather than for falsiness: `false` is a valid bool\n // filter and `0` a valid number one.\n const hasValue = value !== undefined && value !== null && value !== '';\n\n if (!this.currentFilter.columnId || !this.currentFilter.operator || !hasValue) {\n return;\n }\n\n const newFilter: FilterCondition & { selected: boolean } = {\n columnId: this.currentFilter.columnId!,\n operator: this.currentFilter.operator,\n // Bool values round-trip through the dropdown as strings; hosts receive\n // a real boolean.\n value: this.currentColumnType === 'bool' ? value === 'true' : value!,\n selected: true,\n };\n\n this.savedFilters.unshift(newFilter);\n this.userTouched = true;\n this.resetCurrentFilter();\n }\n\n getFilterDescription(filter: FilterCondition): string {\n const column = this.filterableColumns.find(\n (col) => col.id === filter.columnId\n );\n if (!column) return '';\n\n const columnName =\n typeof column.header === 'function' ? column.header({}) : column.header;\n\n const operator = this.getOperatorLabel(filter.operator);\n\n return `${columnName} ${operator} ${this.getValueLabel(column, filter.value)}`;\n }\n\n /** Renders a stored filter value the way it was chosen, not as raw data. */\n private getValueLabel(\n column: ColumnDefinition<T>,\n value: FilterCondition['value']\n ): string {\n if (value instanceof Date) return value.toLocaleDateString();\n if (typeof value === 'boolean') return value ? 'Yes' : 'No';\n\n // The native date input yields a 'YYYY-MM-DD' string; restored filters may\n // carry one too. Parsed as local time — `new Date('2026-07-28')` is treated\n // as UTC and would display as the previous day west of Greenwich.\n if (typeof value === 'string' && this.isDateString(value)) {\n const [year, month, day] = value.slice(0, 10).split('-').map(Number);\n return new Date(year, month - 1, day).toLocaleDateString();\n }\n\n const option = this.normalizeValueOptions(column.valueOptions).find(\n (candidate) => candidate.value === value\n );\n return option ? option.label : `${value}`;\n }\n\n private getOperatorLabel(operatorValue: string): string {\n const operator = [\n ...STRING_OPERATORS,\n ...NUMBER_OPERATORS,\n ...DATE_OPERATORS,\n ...BOOL_OPERATORS,\n ...ENUM_OPERATORS,\n ].find((op) => op.value === operatorValue);\n return operator ? operator.label.toLowerCase() : operatorValue;\n }\n\n /**\n * Prefers the type declared on the column, falling back to inspecting the data\n * only when the host has not declared one.\n */\n private resolveColumnType(column: ColumnDefinition<T>): FilterOperatorType {\n if (column.valueType) {\n // An Enum with no declared members has nothing to populate a dropdown\n // with, so it degrades to a free-text filter rather than an empty select.\n if (\n column.valueType === ColumnValueType.Enum &&\n !this.normalizeValueOptions(column.valueOptions).length\n ) {\n return 'string';\n }\n return this.mapValueType(column.valueType);\n }\n\n return this.inferColumnType(column);\n }\n\n private mapValueType(valueType: ColumnValueType): FilterOperatorType {\n switch (valueType) {\n case ColumnValueType.Date:\n return 'date';\n case ColumnValueType.Number:\n case ColumnValueType.Integer:\n case ColumnValueType.Decimal:\n case ColumnValueType.Currency:\n return 'number';\n case ColumnValueType.Bool:\n return 'bool';\n case ColumnValueType.Enum:\n return 'enum';\n default:\n return 'string';\n }\n }\n\n /**\n * Best-effort type detection for columns that declare no `valueType`. Falls\n * back to 'string' rather than null so the value field always renders.\n */\n private inferColumnType(column: ColumnDefinition<T>): FilterOperatorType {\n const sampleValue = this.firstNonEmptyValue(column);\n\n if (sampleValue instanceof Date) return 'date';\n if (typeof sampleValue === 'number') return 'number';\n if (typeof sampleValue === 'boolean') return 'bool';\n if (typeof sampleValue === 'string' && this.isDateString(sampleValue)) {\n return 'date';\n }\n return 'string';\n }\n\n /**\n * Scans rows for the first usable sample — sampling only the first row misses\n * the type whenever that row happens to hold a null or undefined value.\n */\n private firstNonEmptyValue(column: ColumnDefinition<T>): unknown {\n for (const row of this.data ?? []) {\n const value = this.readValue(column, row);\n if (value !== null && value !== undefined && value !== '') return value;\n }\n return null;\n }\n\n private readValue(column: ColumnDefinition<T>, row: T): unknown {\n if (column.accessorKey) return row[column.accessorKey];\n if (column.accessorFn) return column.accessorFn(row);\n return null;\n }\n\n /**\n * Dates usually arrive from an API as ISO strings, which would otherwise be\n * typed as plain text. Anchored to ISO-ish input so ordinary strings that\n * `Date` happens to parse (e.g. \"March\") are not misread as dates.\n */\n private isDateString(value: string): boolean {\n if (!/^\\d{4}-\\d{2}-\\d{2}([T\\s]|$)/.test(value)) return false;\n return !Number.isNaN(new Date(value).getTime());\n }\n\n /** Accepts either supported `valueOptions` shape and returns one of them. */\n private normalizeValueOptions(\n options: string[] | ColumnValueOption[] | undefined\n ): ColumnValueOption[] {\n if (!options?.length) return [];\n return (options as unknown[]).map((option) =>\n typeof option === 'string'\n ? { label: option, value: option }\n : (option as ColumnValueOption)\n );\n }\n\n private resetCurrentFilter() {\n this.currentFilter = {};\n this.availableOperators = [];\n this.currentColumnType = null;\n this.valueOptions = [];\n }\n\n resetAll() {\n this.userTouched = true;\n this.savedFilters = [];\n this.resetCurrentFilter();\n this.resetFilter.emit();\n }\n\n applyFilters() {\n this.userTouched = true;\n const activeFilters = this.savedFilters\n .filter((filter) => filter.selected)\n .map(({ columnId, operator, value }) => ({\n columnId,\n operator,\n value,\n }));\n this.filterApplied.emit(activeFilters);\n }\n\n getColumnLabel(columnId: string): string {\n const column = this.filterableColumns.find((col) => col.id === columnId);\n return column\n ? typeof column.header === 'function'\n ? column.header({})\n : column.header\n : columnId;\n }\n\n get visibleFilters() {\n return this.showAllFilters\n ? this.savedFilters\n : this.savedFilters.slice(0, this.maxVisibleItems);\n }\n\n get activeFilterCount(): number {\n return this.savedFilters.filter((filter) => filter.selected).length;\n }\n}\n","<verben-card\n width=\"24rem\"\n borderRadius=\"1rem\"\n [border]=\"'1px solid var(--vbn-color-primary)'\"\n bgColor=\"var(--vbn-color-surface)\"\n>\n <div card-header class=\"card-header\">\n <h4 class=\"header-title\">\n Filter <sup>({{ activeFilterCount }})</sup>\n </h4>\n <button\n class=\"reset-button\"\n [style.color]=\"'var(--vbn-color-border-focus)'\"\n [style.background-color]=\"'transparent'\"\n [style.border]=\"'none'\"\n [style.cursor]=\"'pointer'\"\n [style.font-size]=\"'12px'\"\n (click)=\"resetAll()\"\n >\n Reset\n </button>\n </div>\n\n <div card-body class=\"card-body\">\n <!-- Saved Filters Section -->\n <section class=\"section\">\n <div class=\"section-header\">\n <h3 class=\"section-title\">Filters</h3>\n <verben-svg\n icon=\"info\"\n [width]=\"15\"\n [height]=\"15\"\n fill=\"var(--vbn-color-text-muted)\"\n ></verben-svg>\n </div>\n\n <div *ngFor=\"let filter of visibleFilters\" class=\"item\">\n <div class=\"item-label\">\n <input type=\"checkbox\" [(ngModel)]=\"filter.selected\" (ngModelChange)=\"markTouched()\" />\n <label>{{ getFilterDescription(filter) }}</label>\n </div>\n </div>\n\n <div\n *ngIf=\"savedFilters.length > maxVisibleItems\"\n class=\"show-more\"\n (click)=\"showAllFilters = !showAllFilters\"\n >\n {{ showAllFilters ? \"Show Less\" : \"Show More\" }}\n </div>\n </section>\n\n <hr class=\"divider\" />\n\n <!-- New Filter Operation -->\n <section class=\"section\">\n <div class=\"section-header\">\n <h3 class=\"section-title\">Operation</h3>\n <verben-svg\n icon=\"info\"\n [width]=\"15\"\n [height]=\"15\"\n fill=\"var(--vbn-color-text-muted)\"\n ></verben-svg>\n </div>\n\n <div class=\"operation-grid\">\n <!-- Column Selection -->\n <verben-drop-down\n width=\"100%\"\n height=\"1.025rem\"\n placeholder=\"Select column\"\n [options]=\"filterableColumns\"\n optionLabel=\"header\"\n optionValue=\"id\"\n [(ngModel)]=\"currentFilter.columnId\"\n (ngModelChange)=\"onColumnSelect($event)\"\n ></verben-drop-down>\n\n <!-- Operator Selection -->\n <verben-drop-down\n width=\"100%\"\n height=\"1.025rem\"\n placeholder=\"Select operator\"\n [options]=\"availableOperators\"\n optionLabel=\"label\"\n optionValue=\"value\"\n [(ngModel)]=\"currentFilter.operator\"\n ></verben-drop-down>\n\n <!-- Value Input based on type -->\n <ng-container [ngSwitch]=\"currentColumnType\">\n <!-- Date Input — native rather than the library date picker, whose\n overlay renders off screen from this narrow panel. -->\n <verbena-input\n *ngSwitchCase=\"'date'\"\n type=\"date\"\n placeHolder=\"Select date\"\n border=\"1px solid var(--vbn-color-border)\"\n borderRadius=\"5px\"\n textColor=\"var(--vbn-color-text)\"\n width=\"100%\"\n height=\"1.025rem\"\n pd=\"2px 6px\"\n [(ngModel)]=\"currentFilter.value\"\n ></verbena-input>\n\n <!-- Number Input -->\n <verbena-input\n *ngSwitchCase=\"'number'\"\n type=\"number\"\n placeHolder=\"Enter number\"\n border=\"1px solid var(--vbn-color-border)\"\n borderRadius=\"5px\"\n textColor=\"var(--vbn-color-text)\"\n width=\"100%\"\n height=\"1.025rem\"\n pd=\"2px 6px\"\n [(ngModel)]=\"currentFilter.value\"\n ></verbena-input>\n\n <!-- Yes / No Selection -->\n <verben-drop-down\n *ngSwitchCase=\"'bool'\"\n width=\"100%\"\n height=\"1.025rem\"\n placeholder=\"Select value\"\n [options]=\"valueOptions\"\n optionLabel=\"label\"\n optionValue=\"value\"\n [(ngModel)]=\"currentFilter.value\"\n ></verben-drop-down>\n\n <!-- Enum Member Selection -->\n <verben-drop-down\n *ngSwitchCase=\"'enum'\"\n width=\"100%\"\n height=\"1.025rem\"\n placeholder=\"Select value\"\n [options]=\"valueOptions\"\n optionLabel=\"label\"\n optionValue=\"value\"\n [(ngModel)]=\"currentFilter.value\"\n ></verben-drop-down>\n\n <!-- Text Input (default) -->\n <verbena-input\n *ngSwitchDefault\n type=\"text\"\n placeHolder=\"Enter text\"\n border=\"1px solid var(--vbn-color-border)\"\n borderRadius=\"5px\"\n textColor=\"var(--vbn-color-text)\"\n width=\"100%\"\n height=\"1.025rem\"\n pd=\"2px 6px\"\n [(ngModel)]=\"currentFilter.value\"\n ></verbena-input>\n </ng-container>\n </div>\n\n <button class=\"add-button ml-auto\" (click)=\"addFilter()\">+ Add</button>\n </section>\n </div>\n\n <div card-footer class=\"card-footer\">\n <button class=\"export-button\" (click)=\"applyFilters()\">Filter</button>\n </div>\n</verben-card>\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { FormsModule, ReactiveFormsModule } from '@angular/forms';\nimport { SvgModule } from 'verben-ng-ui/src/lib/components/svg';\nimport { CardModule } from 'verben-ng-ui/src/lib/components/card';\nimport { DropDownModule } from 'verben-ng-ui/src/lib/components/drop-down';\nimport { TooltipModule } from 'verben-ng-ui/src/lib/components/tooltip';\nimport { VerbenaInputModule } from 'verben-ng-ui/src/lib/verbena-input';\nimport { DataFilterComponent } from './data-filter.component';\n\n@NgModule({\n declarations: [DataFilterComponent],\n imports: [\n CommonModule,\n FormsModule,\n ReactiveFormsModule,\n SvgModule,\n CardModule,\n DropDownModule,\n TooltipModule,\n VerbenaInputModule,\n ],\n exports: [DataFilterComponent],\n})\nexport class DataFilterModule {}\n","import { Injectable } from '@angular/core';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class DataFilterService {\n\n constructor() { }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;AAaa,MAAA,gBAAgB,GAAqB;IAChD,EAAE,KAAK,EAAE,aAAa,EAAE,KAA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AO,EAAE;wBACP,YAAY;wBACZ,WAAW;wBACX,mBAAmB;wBACnB,SAAS;wBACT,UAAU;wBACV,cAAc;wBACd,aAAa;wBACb,kBAAkB;AACnB,qBAAA;oBACD,OAAO,EAAE,CAAC,mBAAmB,CAAC;AAC/B,iBAAA,CAAA;;;MClBY,iBAAiB,CAAA;AAE5B,IAAA,WAAA,GAAA,GAAiB;wGAFN,iBAAiB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA;AAAjB,IAAA,OAAA,KAAA,GAAA,EAAA,CAAA,qBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,iBAAiB,cAFhB,MAAM,EAAA,CAAA,CAAA;;4FAEP,iBAAiB,EAAA,UAAA,EAAA,CAAA;kBAH7B,UAAU;AAAC,YAAA,IAAA,EAAA,CAAA;AACV,oBAAA,UAAU,EAAE,MAAM;AACnB,iBAAA,CAAA;;;ACJD;;AAEG;;;;"}
1
+ {"version":3,"file":"verben-ng-ui-src-lib-components-data-filter.mjs","sources":["../../../projects/verben-ng-ui/src/lib/components/data-filter/data-filter.types.ts","../../../projects/verben-ng-ui/src/lib/components/data-filter/data-filter.component.ts","../../../projects/verben-ng-ui/src/lib/components/data-filter/data-filter.component.html","../../../projects/verben-ng-ui/src/lib/components/data-filter/data-filter.module.ts","../../../projects/verben-ng-ui/src/lib/components/data-filter/data-filter.service.ts","../../../projects/verben-ng-ui/src/lib/components/data-filter/verben-ng-ui-src-lib-components-data-filter.ts"],"sourcesContent":["export type FilterOperatorType =\n | 'string'\n | 'number'\n | 'date'\n | 'bool'\n | 'enum';\n\nexport interface FilterOperator {\n label: string;\n value: string;\n type: FilterOperatorType;\n}\n\nexport const STRING_OPERATORS: FilterOperator[] = [\n { label: 'Starts With', value: 'startsWith', type: 'string' },\n { label: 'Ends With', value: 'endsWith', type: 'string' },\n { label: 'Contains', value: 'contains', type: 'string' },\n { label: 'Equals', value: 'equals', type: 'string' },\n];\n\nexport const NUMBER_OPERATORS: FilterOperator[] = [\n { label: 'Equal', value: 'equal', type: 'number' },\n { label: 'Greater Than', value: 'greaterThan', type: 'number' },\n { label: 'Less Than', value: 'lessThan', type: 'number' },\n];\n\nexport const DATE_OPERATORS: FilterOperator[] = [\n { label: 'On', value: 'on', type: 'date' },\n { label: 'Before', value: 'before', type: 'date' },\n { label: 'After', value: 'after', type: 'date' },\n];\n\nexport const BOOL_OPERATORS: FilterOperator[] = [\n { label: 'Is', value: 'is', type: 'bool' },\n { label: 'Is Not', value: 'isNot', type: 'bool' },\n];\n\nexport const ENUM_OPERATORS: FilterOperator[] = [\n { label: 'Is', value: 'is', type: 'enum' },\n { label: 'Is Not', value: 'isNot', type: 'enum' },\n];\n\nexport interface FilterCondition {\n columnId: string;\n operator: string;\n value: string | number | boolean | Date;\n}\n\nexport interface FilterGroup {\n id: string;\n name: string;\n conditions: FilterCondition[];\n}\n\nexport interface FilterState {\n groups: FilterGroup[];\n activeFilters: FilterCondition[];\n}\n","import {\n Component,\n Input,\n Output,\n EventEmitter,\n OnChanges,\n OnInit,\n SimpleChanges,\n} from '@angular/core';\nimport {\n ColumnDefinition,\n ColumnValueOption,\n ColumnValueType,\n} from 'verben-ng-ui/src/lib/components/data-table';\nimport {\n FilterOperator,\n FilterOperatorType,\n FilterCondition,\n FilterGroup,\n STRING_OPERATORS,\n NUMBER_OPERATORS,\n DATE_OPERATORS,\n BOOL_OPERATORS,\n ENUM_OPERATORS,\n} from './data-filter.types';\n\n/** A filter chip in the panel's list: a condition plus its active state. */\ntype SavedFilter = FilterCondition & { selected: boolean };\n\n@Component({\n selector: 'lib-data-filter',\n templateUrl: './data-filter.component.html',\n styleUrl: './data-filter.component.css',\n})\nexport class DataFilterComponent<T> implements OnInit, OnChanges {\n @Input() columns!: ColumnDefinition<T>[];\n @Input() data!: T[];\n /**\n * Optional restored filters: the panel opens pre-populated with these as\n * selected filter chips. Applied once (the first time a non-empty value\n * arrives) so it never clobbers the user's in-progress edits afterwards.\n */\n @Input() initialFilters?: FilterCondition[];\n @Output() filterApplied = new EventEmitter<FilterCondition[]>();\n @Output() resetFilter = new EventEmitter();\n filterableColumns: ColumnDefinition<T>[] = [];\n availableOperators: FilterOperator[] = [];\n savedFilters: SavedFilter[] = [];\n currentFilter: Partial<FilterCondition> = {};\n showAllFilters = false;\n maxVisibleItems = 3;\n currentColumnType: FilterOperatorType | null = null;\n /**\n * Options for the value dropdown when the selected column is bool or enum.\n * Always normalised to `{ label, value }` so the template binds one shape.\n */\n valueOptions: ColumnValueOption[] = [];\n /**\n * Held as strings rather than booleans: `verben-drop-down` gates its selected\n * label on a truthiness check, so an option valued `false` would render as\n * though nothing were picked. Coerced back to a boolean in `addFilter`.\n */\n private readonly boolOptions: ColumnValueOption[] = [\n { label: 'Yes', value: 'true' },\n { label: 'No', value: 'false' },\n ];\n // Set once the user edits the panel, so restored/host filters no longer\n // overwrite their in-progress work.\n private userTouched = false;\n /**\n * The saved filter currently loaded into the operation row, if any. Held by\n * reference rather than by index so deleting or reordering another filter\n * cannot retarget the write-back.\n */\n private editingFilter: SavedFilter | null = null;\n\n ngOnInit() {\n this.initializeFilterableColumns();\n this.hydrateSavedFilters();\n }\n\n ngOnChanges(changes: SimpleChanges) {\n // Pick up filters restored asynchronously by the host after first render.\n if (changes['initialFilters']) {\n this.hydrateSavedFilters();\n }\n }\n\n /**\n * Seed the saved-filter chips from the restored filters. Skipped once the user\n * has touched the panel so it never overwrites their in-progress edits.\n */\n private hydrateSavedFilters() {\n if (this.userTouched) return;\n this.savedFilters = (this.initialFilters ?? []).map((filter) => ({\n ...filter,\n selected: true,\n }));\n }\n\n /** Marks the panel as user-edited (called from template interactions). */\n markTouched() {\n this.userTouched = true;\n }\n\n private initializeFilterableColumns() {\n this.filterableColumns = this.columns.filter((col) => col.accessorKey);\n }\n\n onColumnSelect(columnId: string) {\n const column = this.filterableColumns.find((col) => col.id === columnId);\n if (!column) return;\n\n this.currentFilter.columnId = columnId;\n\n // Reset other values\n this.currentFilter.operator = undefined;\n this.currentFilter.value = undefined;\n\n this.applyColumnContext(column);\n }\n\n /**\n * Derives the value control, operators and options for a column without\n * touching the operator or value already in the operation row — `editFilter`\n * depends on those surviving, where `onColumnSelect` clears them first.\n */\n private applyColumnContext(column: ColumnDefinition<T>) {\n this.currentColumnType = this.resolveColumnType(column);\n this.valueOptions =\n this.currentColumnType === 'bool'\n ? this.boolOptions\n : this.currentColumnType === 'enum'\n ? this.normalizeValueOptions(column.valueOptions)\n : [];\n\n switch (this.currentColumnType) {\n case 'string':\n this.availableOperators = STRING_OPERATORS;\n break;\n case 'number':\n this.availableOperators = NUMBER_OPERATORS;\n break;\n case 'date':\n this.availableOperators = DATE_OPERATORS;\n break;\n case 'bool':\n this.availableOperators = BOOL_OPERATORS;\n break;\n case 'enum':\n this.availableOperators = ENUM_OPERATORS;\n break;\n default:\n this.availableOperators = [];\n }\n }\n\n addFilter() {\n const value = this.currentFilter.value;\n // Checked explicitly rather than for falsiness: `false` is a valid bool\n // filter and `0` a valid number one.\n const hasValue = value !== undefined && value !== null && value !== '';\n\n if (!this.currentFilter.columnId || !this.currentFilter.operator || !hasValue) {\n return;\n }\n\n const condition: FilterCondition = {\n columnId: this.currentFilter.columnId!,\n operator: this.currentFilter.operator,\n // Bool values round-trip through the dropdown as strings; hosts receive\n // a real boolean.\n value: this.currentColumnType === 'bool' ? value === 'true' : value!,\n };\n\n // Written back over the filter being edited, and over the existing chip of a\n // required column, so neither case leaves a stale duplicate behind. Updated\n // in place rather than removed and re-added so the chip keeps its position.\n const target =\n this.editingFilter ??\n (this.isRequiredColumn(condition.columnId)\n ? this.savedFilters.find((f) => f.columnId === condition.columnId)\n : undefined);\n\n if (target) {\n Object.assign(target, condition);\n target.selected = true;\n } else {\n this.savedFilters.unshift({ ...condition, selected: true });\n }\n\n this.editingFilter = null;\n this.userTouched = true;\n this.resetCurrentFilter();\n }\n\n /** Loads a saved filter back into the operation row for correction. */\n editFilter(filter: SavedFilter) {\n const column = this.filterableColumns.find(\n (col) => col.id === filter.columnId\n );\n if (!column) return;\n\n this.applyColumnContext(column);\n this.currentFilter = {\n columnId: filter.columnId,\n operator: filter.operator,\n value: this.toEditableValue(filter.value),\n };\n this.editingFilter = filter;\n this.userTouched = true;\n }\n\n /**\n * Converts a stored value back into what the value control expects: bools are\n * held as real booleans but the dropdown's options are the strings\n * 'true'/'false' (see `boolOptions`), and the native date input needs\n * 'YYYY-MM-DD' rather than a `Date` a host may have restored.\n */\n private toEditableValue(value: FilterCondition['value']) {\n if (this.currentColumnType === 'bool') return `${value}`;\n if (value instanceof Date) {\n // Built from the local parts: `toISOString` shifts to UTC and would move\n // the date a day back west of Greenwich.\n const month = `${value.getMonth() + 1}`.padStart(2, '0');\n const day = `${value.getDate()}`.padStart(2, '0');\n return `${value.getFullYear()}-${month}-${day}`;\n }\n return value;\n }\n\n /** Removes a saved filter. Required filters cannot be removed. */\n deleteFilter(filter: SavedFilter) {\n if (this.isRequired(filter)) return;\n\n const index = this.savedFilters.indexOf(filter);\n if (index === -1) return;\n\n this.savedFilters.splice(index, 1);\n if (this.editingFilter === filter) this.clearCurrentFilter();\n this.userTouched = true;\n }\n\n /** Empties the operation row, abandoning any edit in progress. */\n clearCurrentFilter() {\n this.editingFilter = null;\n this.resetCurrentFilter();\n }\n\n /** True when the filter's column is declared `isRequiredFilter`. */\n isRequired(filter: FilterCondition): boolean {\n return this.isRequiredColumn(filter.columnId);\n }\n\n private isRequiredColumn(columnId: string): boolean {\n const column = this.filterableColumns.find((col) => col.id === columnId);\n return !!column?.isRequiredFilter;\n }\n\n isEditing(filter: SavedFilter): boolean {\n return this.editingFilter === filter;\n }\n\n /**\n * Locks the property dropdown while a required filter is being edited —\n * switching it to another column would drop the required filter entirely.\n */\n get isEditingRequired(): boolean {\n return !!this.editingFilter && this.isRequired(this.editingFilter);\n }\n\n getFilterDescription(filter: FilterCondition): string {\n const column = this.filterableColumns.find(\n (col) => col.id === filter.columnId\n );\n if (!column) return '';\n\n const columnName =\n typeof column.header === 'function' ? column.header({}) : column.header;\n\n const operator = this.getOperatorLabel(filter.operator);\n\n return `${columnName} ${operator} ${this.getValueLabel(column, filter.value)}`;\n }\n\n /** Renders a stored filter value the way it was chosen, not as raw data. */\n private getValueLabel(\n column: ColumnDefinition<T>,\n value: FilterCondition['value']\n ): string {\n if (value instanceof Date) return value.toLocaleDateString();\n if (typeof value === 'boolean') return value ? 'Yes' : 'No';\n\n // The native date input yields a 'YYYY-MM-DD' string; restored filters may\n // carry one too. Parsed as local time — `new Date('2026-07-28')` is treated\n // as UTC and would display as the previous day west of Greenwich.\n if (typeof value === 'string' && this.isDateString(value)) {\n const [year, month, day] = value.slice(0, 10).split('-').map(Number);\n return new Date(year, month - 1, day).toLocaleDateString();\n }\n\n const option = this.normalizeValueOptions(column.valueOptions).find(\n (candidate) => candidate.value === value\n );\n return option ? option.label : `${value}`;\n }\n\n private getOperatorLabel(operatorValue: string): string {\n const operator = [\n ...STRING_OPERATORS,\n ...NUMBER_OPERATORS,\n ...DATE_OPERATORS,\n ...BOOL_OPERATORS,\n ...ENUM_OPERATORS,\n ].find((op) => op.value === operatorValue);\n return operator ? operator.label.toLowerCase() : operatorValue;\n }\n\n /**\n * Prefers the type declared on the column, falling back to inspecting the data\n * only when the host has not declared one.\n */\n private resolveColumnType(column: ColumnDefinition<T>): FilterOperatorType {\n if (column.valueType) {\n // An Enum with no declared members has nothing to populate a dropdown\n // with, so it degrades to a free-text filter rather than an empty select.\n if (\n column.valueType === ColumnValueType.Enum &&\n !this.normalizeValueOptions(column.valueOptions).length\n ) {\n return 'string';\n }\n return this.mapValueType(column.valueType);\n }\n\n return this.inferColumnType(column);\n }\n\n private mapValueType(valueType: ColumnValueType): FilterOperatorType {\n switch (valueType) {\n case ColumnValueType.Date:\n return 'date';\n case ColumnValueType.Number:\n case ColumnValueType.Integer:\n case ColumnValueType.Decimal:\n case ColumnValueType.Currency:\n return 'number';\n case ColumnValueType.Bool:\n return 'bool';\n case ColumnValueType.Enum:\n return 'enum';\n default:\n return 'string';\n }\n }\n\n /**\n * Best-effort type detection for columns that declare no `valueType`. Falls\n * back to 'string' rather than null so the value field always renders.\n */\n private inferColumnType(column: ColumnDefinition<T>): FilterOperatorType {\n const sampleValue = this.firstNonEmptyValue(column);\n\n if (sampleValue instanceof Date) return 'date';\n if (typeof sampleValue === 'number') return 'number';\n if (typeof sampleValue === 'boolean') return 'bool';\n if (typeof sampleValue === 'string' && this.isDateString(sampleValue)) {\n return 'date';\n }\n return 'string';\n }\n\n /**\n * Scans rows for the first usable sample — sampling only the first row misses\n * the type whenever that row happens to hold a null or undefined value.\n */\n private firstNonEmptyValue(column: ColumnDefinition<T>): unknown {\n for (const row of this.data ?? []) {\n const value = this.readValue(column, row);\n if (value !== null && value !== undefined && value !== '') return value;\n }\n return null;\n }\n\n private readValue(column: ColumnDefinition<T>, row: T): unknown {\n if (column.accessorKey) return row[column.accessorKey];\n if (column.accessorFn) return column.accessorFn(row);\n return null;\n }\n\n /**\n * Dates usually arrive from an API as ISO strings, which would otherwise be\n * typed as plain text. Anchored to ISO-ish input so ordinary strings that\n * `Date` happens to parse (e.g. \"March\") are not misread as dates.\n */\n private isDateString(value: string): boolean {\n if (!/^\\d{4}-\\d{2}-\\d{2}([T\\s]|$)/.test(value)) return false;\n return !Number.isNaN(new Date(value).getTime());\n }\n\n /** Accepts either supported `valueOptions` shape and returns one of them. */\n private normalizeValueOptions(\n options: string[] | ColumnValueOption[] | undefined\n ): ColumnValueOption[] {\n if (!options?.length) return [];\n return (options as unknown[]).map((option) =>\n typeof option === 'string'\n ? { label: option, value: option }\n : (option as ColumnValueOption)\n );\n }\n\n private resetCurrentFilter() {\n this.currentFilter = {};\n this.availableOperators = [];\n this.currentColumnType = null;\n this.valueOptions = [];\n }\n\n resetAll() {\n this.userTouched = true;\n this.savedFilters = this.savedFilters.filter((filter) =>\n this.isRequired(filter)\n );\n this.clearCurrentFilter();\n\n // Required filters survive a reset, so the host is told what is left rather\n // than that everything is gone — a bare `resetFilter` would leave the panel\n // showing chips the host is no longer filtering by.\n if (this.savedFilters.length) {\n this.applyFilters();\n return;\n }\n this.resetFilter.emit();\n }\n\n applyFilters() {\n this.userTouched = true;\n const activeFilters = this.savedFilters\n // Required filters are emitted whether or not they are ticked: their\n // checkbox is disabled, but the host must never be left without them.\n .filter((filter) => filter.selected || this.isRequired(filter))\n .map(({ columnId, operator, value }) => ({\n columnId,\n operator,\n value,\n }));\n this.filterApplied.emit(activeFilters);\n }\n\n getColumnLabel(columnId: string): string {\n const column = this.filterableColumns.find((col) => col.id === columnId);\n return column\n ? typeof column.header === 'function'\n ? column.header({})\n : column.header\n : columnId;\n }\n\n /**\n * Required filters pinned to the top so the collapsed list can never hide one\n * behind \"Show More\".\n */\n get orderedFilters(): SavedFilter[] {\n return [\n ...this.savedFilters.filter((filter) => this.isRequired(filter)),\n ...this.savedFilters.filter((filter) => !this.isRequired(filter)),\n ];\n }\n\n get visibleFilters(): SavedFilter[] {\n return this.showAllFilters\n ? this.orderedFilters\n : this.orderedFilters.slice(0, this.maxVisibleItems);\n }\n\n get activeFilterCount(): number {\n return this.savedFilters.filter(\n (filter) => filter.selected || this.isRequired(filter)\n ).length;\n }\n}\n","<verben-card\n width=\"24rem\"\n borderRadius=\"1rem\"\n [border]=\"'1px solid var(--vbn-color-primary)'\"\n bgColor=\"var(--vbn-color-surface)\"\n>\n <div card-header class=\"card-header\">\n <h4 class=\"header-title\">\n Filter <sup>({{ activeFilterCount }})</sup>\n </h4>\n <button\n class=\"reset-button\"\n [style.color]=\"'var(--vbn-color-border-focus)'\"\n [style.background-color]=\"'transparent'\"\n [style.border]=\"'none'\"\n [style.cursor]=\"'pointer'\"\n [style.font-size]=\"'12px'\"\n (click)=\"resetAll()\"\n >\n Reset\n </button>\n </div>\n\n <div card-body class=\"card-body\">\n <!-- Saved Filters Section -->\n <section class=\"section\">\n <div class=\"section-header\">\n <h3 class=\"section-title\">Filters</h3>\n <verben-svg\n icon=\"info\"\n [width]=\"15\"\n [height]=\"15\"\n fill=\"var(--vbn-color-text-muted)\"\n ></verben-svg>\n </div>\n\n <div\n *ngFor=\"let filter of visibleFilters\"\n class=\"item\"\n [class.item-editing]=\"isEditing(filter)\"\n >\n <div class=\"item-label\">\n <!-- A required filter is always active, so its checkbox is ticked and\n locked rather than hidden — the state stays readable. -->\n <input\n type=\"checkbox\"\n [(ngModel)]=\"filter.selected\"\n [disabled]=\"isRequired(filter)\"\n (ngModelChange)=\"markTouched()\"\n />\n <label>{{ getFilterDescription(filter) }}</label>\n </div>\n\n <div class=\"item-actions\">\n <button\n type=\"button\"\n class=\"icon-button\"\n aria-label=\"Edit filter\"\n (click)=\"editFilter(filter)\"\n >\n <!-- Only `stroke` is passed: `verben-svg` resolves a single colour as\n `fill || stroke` and applies it to both, so also passing `fill`\n would paint the icon in whatever `fill` holds. -->\n <verben-svg\n icon=\"edit\"\n [width]=\"15\"\n [height]=\"15\"\n stroke=\"var(--vbn-color-border-focus)\"\n ></verben-svg>\n </button>\n <button\n type=\"button\"\n class=\"icon-button\"\n aria-label=\"Delete filter\"\n [disabled]=\"isRequired(filter)\"\n (click)=\"deleteFilter(filter)\"\n >\n <verben-svg\n icon=\"delete\"\n [width]=\"15\"\n [height]=\"15\"\n stroke=\"var(--vbn-color-error)\"\n ></verben-svg>\n </button>\n </div>\n </div>\n\n <div\n *ngIf=\"savedFilters.length > maxVisibleItems\"\n class=\"show-more\"\n (click)=\"showAllFilters = !showAllFilters\"\n >\n {{ showAllFilters ? \"Show Less\" : \"Show More\" }}\n </div>\n </section>\n\n <hr class=\"divider\" />\n\n <!-- New Filter Operation -->\n <section class=\"section\">\n <div class=\"section-header\">\n <h3 class=\"section-title\">Operation</h3>\n <verben-svg\n icon=\"info\"\n [width]=\"15\"\n [height]=\"15\"\n fill=\"var(--vbn-color-text-muted)\"\n ></verben-svg>\n </div>\n\n <div class=\"operation-grid\">\n <!-- Column Selection -->\n <verben-drop-down\n width=\"100%\"\n height=\"1.025rem\"\n placeholder=\"Select column\"\n [options]=\"filterableColumns\"\n optionLabel=\"header\"\n optionValue=\"id\"\n [disabled]=\"isEditingRequired\"\n [(ngModel)]=\"currentFilter.columnId\"\n (ngModelChange)=\"onColumnSelect($event)\"\n ></verben-drop-down>\n\n <!-- Operator Selection -->\n <verben-drop-down\n width=\"100%\"\n height=\"1.025rem\"\n placeholder=\"Select operator\"\n [options]=\"availableOperators\"\n optionLabel=\"label\"\n optionValue=\"value\"\n [(ngModel)]=\"currentFilter.operator\"\n ></verben-drop-down>\n\n <!-- Value Input based on type -->\n <ng-container [ngSwitch]=\"currentColumnType\">\n <!-- Date Input — native rather than the library date picker, whose\n overlay renders off screen from this narrow panel. -->\n <verbena-input\n *ngSwitchCase=\"'date'\"\n type=\"date\"\n placeHolder=\"Select date\"\n border=\"1px solid var(--vbn-color-border)\"\n borderRadius=\"5px\"\n textColor=\"var(--vbn-color-text)\"\n width=\"100%\"\n height=\"1.025rem\"\n pd=\"2px 6px\"\n [(ngModel)]=\"currentFilter.value\"\n ></verbena-input>\n\n <!-- Number Input -->\n <verbena-input\n *ngSwitchCase=\"'number'\"\n type=\"number\"\n placeHolder=\"Enter number\"\n border=\"1px solid var(--vbn-color-border)\"\n borderRadius=\"5px\"\n textColor=\"var(--vbn-color-text)\"\n width=\"100%\"\n height=\"1.025rem\"\n pd=\"2px 6px\"\n [(ngModel)]=\"currentFilter.value\"\n ></verbena-input>\n\n <!-- Yes / No Selection -->\n <verben-drop-down\n *ngSwitchCase=\"'bool'\"\n width=\"100%\"\n height=\"1.025rem\"\n placeholder=\"Select value\"\n [options]=\"valueOptions\"\n optionLabel=\"label\"\n optionValue=\"value\"\n [(ngModel)]=\"currentFilter.value\"\n ></verben-drop-down>\n\n <!-- Enum Member Selection -->\n <verben-drop-down\n *ngSwitchCase=\"'enum'\"\n width=\"100%\"\n height=\"1.025rem\"\n placeholder=\"Select value\"\n [options]=\"valueOptions\"\n optionLabel=\"label\"\n optionValue=\"value\"\n [(ngModel)]=\"currentFilter.value\"\n ></verben-drop-down>\n\n <!-- Text Input (default) -->\n <verbena-input\n *ngSwitchDefault\n type=\"text\"\n placeHolder=\"Enter text\"\n border=\"1px solid var(--vbn-color-border)\"\n borderRadius=\"5px\"\n textColor=\"var(--vbn-color-text)\"\n width=\"100%\"\n height=\"1.025rem\"\n pd=\"2px 6px\"\n [(ngModel)]=\"currentFilter.value\"\n ></verbena-input>\n </ng-container>\n </div>\n\n <div class=\"operation-actions\">\n <button class=\"clear-button\" (click)=\"clearCurrentFilter()\">\n Clear\n </button>\n <button class=\"add-button\" (click)=\"addFilter()\">+ Add</button>\n </div>\n </section>\n </div>\n\n <div card-footer class=\"card-footer\">\n <button class=\"export-button\" (click)=\"applyFilters()\">Filter</button>\n </div>\n</verben-card>\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { FormsModule, ReactiveFormsModule } from '@angular/forms';\nimport { SvgModule } from 'verben-ng-ui/src/lib/components/svg';\nimport { CardModule } from 'verben-ng-ui/src/lib/components/card';\nimport { DropDownModule } from 'verben-ng-ui/src/lib/components/drop-down';\nimport { TooltipModule } from 'verben-ng-ui/src/lib/components/tooltip';\nimport { VerbenaInputModule } from 'verben-ng-ui/src/lib/verbena-input';\nimport { DataFilterComponent } from './data-filter.component';\n\n@NgModule({\n declarations: [DataFilterComponent],\n imports: [\n CommonModule,\n FormsModule,\n ReactiveFormsModule,\n SvgModule,\n CardModule,\n DropDownModule,\n TooltipModule,\n VerbenaInputModule,\n ],\n exports: [DataFilterComponent],\n})\nexport class DataFilterModule {}\n","import { Injectable } from '@angular/core';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class DataFilterService {\n\n constructor() { }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;AAaa,MAAA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