@propbinder/mobile-design 0.3.41 → 0.3.42

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.
@@ -18318,12 +18318,18 @@ class DsMobileTenantPickerModalComponent {
18318
18318
  pickMode = false;
18319
18319
  /** Optional set of tenant IDs to exclude from the list (e.g. already-selected admins). */
18320
18320
  excludeIds;
18321
+ /** Optional list of external tenants to use instead of the internal dummy data */
18322
+ set tenants(val) {
18323
+ this._externalTenants.set(val);
18324
+ }
18325
+ _externalTenants = signal(undefined, ...(ngDevMode ? [{ debugName: "_externalTenants" }] : []));
18321
18326
  searchQuery = signal('', ...(ngDevMode ? [{ debugName: "searchQuery" }] : []));
18322
18327
  selectionMode = signal(false, ...(ngDevMode ? [{ debugName: "selectionMode" }] : []));
18323
18328
  selectedIds = signal(new Set(), ...(ngDevMode ? [{ debugName: "selectedIds" }] : []));
18324
18329
  filteredTenants = computed(() => {
18325
18330
  const q = this.searchQuery().toLowerCase().trim();
18326
- let tenants = this.peerMessaging.tenants();
18331
+ const external = this._externalTenants();
18332
+ let tenants = external ?? this.peerMessaging.tenants();
18327
18333
  if (this.excludeIds?.size) {
18328
18334
  tenants = tenants.filter(t => !this.excludeIds.has(t.id));
18329
18335
  }
@@ -18390,7 +18396,7 @@ class DsMobileTenantPickerModalComponent {
18390
18396
  const ids = [...this.selectedIds()];
18391
18397
  if (ids.length < 2)
18392
18398
  return;
18393
- const allTenants = this.peerMessaging.tenants();
18399
+ const allTenants = this._externalTenants() ?? this.peerMessaging.tenants();
18394
18400
  const selectedTenants = allTenants.filter(t => ids.includes(t.id));
18395
18401
  const groupName = selectedTenants
18396
18402
  .map(t => t.name.split(/\s+/)[0])
@@ -18401,7 +18407,7 @@ class DsMobileTenantPickerModalComponent {
18401
18407
  await this.peerChat.createGroup(ids, groupName);
18402
18408
  }
18403
18409
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: DsMobileTenantPickerModalComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
18404
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.16", type: DsMobileTenantPickerModalComponent, isStandalone: true, selector: "ds-mobile-tenant-picker-modal", inputs: { pickMode: "pickMode", excludeIds: "excludeIds" }, ngImport: i0, template: `
18410
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.16", type: DsMobileTenantPickerModalComponent, isStandalone: true, selector: "ds-mobile-tenant-picker-modal", inputs: { pickMode: "pickMode", excludeIds: "excludeIds", tenants: "tenants" }, ngImport: i0, template: `
18405
18411
  <ds-mobile-modal-base
18406
18412
  headerTitle="Beboere"
18407
18413
  closeButtonLabel="Luk"
@@ -18530,6 +18536,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImpo
18530
18536
  type: Input
18531
18537
  }], excludeIds: [{
18532
18538
  type: Input
18539
+ }], tenants: [{
18540
+ type: Input
18533
18541
  }] } });
18534
18542
 
18535
18543
  var index = /*#__PURE__*/Object.freeze({