@memberjunction/ng-list-management 5.42.0 → 5.44.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (27) hide show
  1. package/dist/lib/components/list-delta-confirm/list-delta-confirm.component.js +32 -36
  2. package/dist/lib/components/list-delta-confirm/list-delta-confirm.component.js.map +1 -1
  3. package/dist/lib/components/list-management-dialog/list-management-dialog.component.js +73 -94
  4. package/dist/lib/components/list-management-dialog/list-management-dialog.component.js.map +1 -1
  5. package/dist/lib/components/list-share-dialog/list-share-dialog.component.d.ts +5 -0
  6. package/dist/lib/components/list-share-dialog/list-share-dialog.component.d.ts.map +1 -1
  7. package/dist/lib/components/list-share-dialog/list-share-dialog.component.js +20 -22
  8. package/dist/lib/components/list-share-dialog/list-share-dialog.component.js.map +1 -1
  9. package/dist/lib/components/save-view-as-list-dialog/save-view-as-list-dialog.component.js +72 -74
  10. package/dist/lib/components/save-view-as-list-dialog/save-view-as-list-dialog.component.js.map +1 -1
  11. package/dist/lib/module.d.ts +1 -1
  12. package/dist/lib/module.d.ts.map +1 -1
  13. package/dist/lib/module.js +7 -1
  14. package/dist/lib/module.js.map +1 -1
  15. package/package.json +12 -11
  16. package/dist/__tests__/index.test.d.ts +0 -2
  17. package/dist/__tests__/index.test.d.ts.map +0 -1
  18. package/dist/__tests__/index.test.js +0 -7
  19. package/dist/__tests__/index.test.js.map +0 -1
  20. package/dist/__tests__/list-models.test.d.ts +0 -2
  21. package/dist/__tests__/list-models.test.d.ts.map +0 -1
  22. package/dist/__tests__/list-models.test.js +0 -86
  23. package/dist/__tests__/list-models.test.js.map +0 -1
  24. package/dist/lib/components/list-invitations/__tests__/list-invitations.component.test.d.ts +0 -2
  25. package/dist/lib/components/list-invitations/__tests__/list-invitations.component.test.d.ts.map +0 -1
  26. package/dist/lib/components/list-invitations/__tests__/list-invitations.component.test.js +0 -145
  27. package/dist/lib/components/list-invitations/__tests__/list-invitations.component.test.js.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"list-share-dialog.component.js","sourceRoot":"","sources":["../../../../src/lib/components/list-share-dialog/list-share-dialog.component.ts","../../../../src/lib/components/list-share-dialog/list-share-dialog.component.html"],"names":[],"mappings":"AAAA,OAAO,EACL,SAAS,EACT,KAAK,EACL,MAAM,EACN,YAAY,EAIb,MAAM,eAAe,CAAC;AACvB,OAAO,EAAE,OAAO,EAAE,MAAM,MAAM,CAAC;AAC/B,OAAO,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAC;AACrE,OAAO,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;;;;;;;ICFjD,8BAA+B;IAC7B,iCAAkD;IACpD,iBAAM;;;IAyCY,gCAA8B;IAAA,YAAqB;IAAA,iBAAO;;;IAA5B,cAAqB;IAArB,wCAAqB;;;;IANzD,+BAC2C;IAAzC,kRAAa,oCAA0B,KAAC;IACxC,oBAAkD;IAEhD,AADF,+BAA4B,eACG;IAAA,YAAoB;IAAA,iBAAO;IACxD,2JAAuB;IAI3B,AADE,iBAAM,EACF;;;;IAPD,cAA0C;IAA1C,yDAA0C;IAEd,eAAoB;IAApB,uCAAoB;IACjD,cAEC;IAFD,6CAEC;;;IATT,+BAA4B;IAC1B,uKAWC;IACH,iBAAM;;;IAZJ,cAWC;IAXD,mCAWC;;;IAuBG,AADF,+BAA+B,eACE;IAAA,YAAoB;IAAA,iBAAO;IAC1D,gCAA8B;IAAA,YAA0B;IAC1D,AAD0D,iBAAO,EAC3D;;;IAF2B,eAAoB;IAApB,uCAAoB;IACrB,eAA0B;IAA1B,6CAA0B;;;;IAjB9D,AADF,+BAAgC,cACF;IAC1B,oBAA0D;IAC1D,4BAAM;IAAA,YAA4B;IAAA,iBAAO;IACzC,kCAAkE;IAAxB,wOAAS,oBAAa,KAAC;IAC/D,wBAAiC;IAErC,AADE,iBAAS,EACL;IACN,uCAM8B;IAF5B,sXAAgC;IAGhC,mLAA0C;IAM5C,iBAAc;IACd,m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E,CAAC;IACrB,CAAC;IAED;;OAEG;IACH,IAAI,eAAe;QACjB,OAAO,IAAI,CAAC,MAAM,EAAE,OAAO,KAAK,IAAI,CAAC;IACvC,CAAC;kHA7YU,wBAAwB;6DAAxB,wBAAwB;YCtCrC,iGAAe;;YAAf,sCAoMC;;;iFD9JY,wBAAwB;cANpC,SAAS;6BACI,KAAK,YACP,sBAAsB;;kBAQ/B,KAAK;;kBAKL,KAAK;;kBAeL,MAAM;;kBAKN,MAAM;;kBAMN,MAAM;;kBAMN,MAAM;;kFAzCI,wBAAwB","sourcesContent":["import {\n Component,\n Input,\n Output,\n EventEmitter,\n OnInit,\n OnDestroy,\n ChangeDetectorRef\n} from '@angular/core';\nimport { Subject } from 'rxjs';\nimport { BaseAngularComponent } from '@memberjunction/ng-base-types';\nimport { debounceTime, takeUntil } from 'rxjs/operators';\nimport { Metadata } from '@memberjunction/core';\nimport { ListSharingService } from '../../services/list-sharing.service';\nimport {\n ListShareDialogConfig,\n ListShareDialogResult,\n ListShareInfo,\n ListPermissionLevel,\n ShareRecipient\n} from '../../models/list-sharing.models';\n\n/**\n * Dialog component for managing list sharing.\n * Allows users to share lists with other users or roles with different permission levels.\n *\n * Features:\n * - User/role search with autocomplete\n * - Permission level selection (View, Edit, Owner)\n * - Current shares management\n * - Remove access functionality\n */\n@Component({\n standalone: false,\n selector: 'mj-list-share-dialog',\n templateUrl: './list-share-dialog.component.html',\n styleUrls: ['./list-share-dialog.component.css']\n})\nexport class ListShareDialogComponent extends BaseAngularComponent implements OnInit, OnDestroy {\n /**\n * Configuration for the dialog\n */\n @Input() config!: ListShareDialogConfig;\n\n /**\n * Controls dialog visibility\n */\n @Input()\n get visible(): boolean {\n return this._visible;\n }\n set visible(value: boolean) {\n if (value && !this._visible) {\n this.initializeDialog();\n }\n this._visible = value;\n }\n private _visible = false;\n\n /**\n * Emitted when dialog is closed with results\n */\n @Output() complete = new EventEmitter<ListShareDialogResult>();\n\n /**\n * Emitted when dialog is cancelled\n */\n @Output() cancel = new EventEmitter<void>();\n\n /**\n * Emitted when the user clicks \"Manage Invitations\" in the footer.\n * Phase 2: opens the invitations management UI for this list.\n */\n @Output() manageInvitations = new EventEmitter<void>();\n\n /**\n * Emitted when the user clicks \"View audit log\" in the footer.\n * Phase 2: opens the per-list audit log view.\n */\n @Output() viewAuditLog = new EventEmitter<void>();\n\n /**\n * When true (the default), newly-added shares fan out as notifications\n * to the recipient (email + in-app, depending on user preferences).\n * The state is captured on the dialog so consumers can read it back\n * via `ListShareDialogResult.notifyByEmail`.\n */\n public notifyByEmail = true;\n\n // State\n loading = false;\n saving = false;\n searchText = '';\n searchType: 'User' | 'Role' = 'User';\n showSearchResults = false;\n\n // Data\n currentShares: ListShareInfo[] = [];\n searchResults: ShareRecipient[] = [];\n selectedRecipient: ShareRecipient | null = null;\n selectedPermission: ListPermissionLevel = 'View';\n\n // Track changes\n sharesAdded: ListShareInfo[] = [];\n sharesUpdated: ListShareInfo[] = [];\n sharesRemoved: string[] = [];\n\n // Permission options\n permissionOptions: { value: ListPermissionLevel; label: string; description: string }[] = [\n { value: 'View', label: 'Viewer', description: 'Can view list contents' },\n { value: 'Edit', label: 'Editor', description: 'Can add/remove items' },\n { value: 'Owner', label: 'Co-owner', description: 'Full control including sharing' }\n ];\n\n // Cleanup\n private destroy$ = new Subject<void>();\n private searchSubject = new Subject<string>();\n\n constructor(\n private sharingService: ListSharingService,\n private cdr: ChangeDetectorRef\n ) {\n super();}\n\n ngOnInit(): void {\n this.setupSearchDebounce();\n }\n\n ngOnDestroy(): void {\n this.destroy$.next();\n this.destroy$.complete();\n }\n\n /**\n * Get dialog title\n */\n get dialogTitle(): string {\n return `Share \"${this.config?.listName || 'List'}\"`;\n }\n\n /**\n * Check if there are pending changes\n */\n get hasChanges(): boolean {\n return this.sharesAdded.length > 0 ||\n this.sharesUpdated.length > 0 ||\n this.sharesRemoved.length > 0;\n }\n\n /**\n * Setup search with debounce\n */\n private setupSearchDebounce(): void {\n this.searchSubject.pipe(\n debounceTime(300),\n takeUntil(this.destroy$)\n ).subscribe(async (searchText: string) => {\n if (searchText.trim().length >= 2) {\n await this.performSearch(searchText);\n } else {\n this.searchResults = [];\n this.showSearchResults = false;\n }\n this.cdr.detectChanges();\n });\n }\n\n /**\n * Initialize dialog when opened\n */\n private async initializeDialog(): Promise<void> {\n this.resetState();\n await this.loadCurrentShares();\n }\n\n /**\n * Reset all state\n */\n private resetState(): void {\n this.searchText = '';\n this.searchType = 'User';\n this.showSearchResults = false;\n this.searchResults = [];\n this.selectedRecipient = null;\n this.selectedPermission = 'View';\n this.sharesAdded = [];\n this.sharesUpdated = [];\n this.sharesRemoved = [];\n }\n\n /**\n * Load current shares for the list\n */\n private async loadCurrentShares(): Promise<void> {\n if (!this.config) return;\n\n this.loading = true;\n this.cdr.detectChanges();\n\n try {\n this.currentShares = await this.sharingService.getListShares(this.config.listId);\n } catch (error) {\n console.error('Error loading shares:', error);\n this.currentShares = [];\n } finally {\n this.loading = false;\n this.cdr.detectChanges();\n }\n }\n\n /**\n * Handle search input\n */\n onSearchInput(event: Event): void {\n const value = (event.target as HTMLInputElement).value;\n this.searchText = value;\n this.searchSubject.next(value);\n }\n\n /**\n * Clear search\n */\n clearSearch(): void {\n this.searchText = '';\n this.searchResults = [];\n this.showSearchResults = false;\n this.selectedRecipient = null;\n }\n\n /**\n * Switch search type\n */\n setSearchType(type: 'User' | 'Role'): void {\n this.searchType = type;\n if (this.searchText.trim().length >= 2) {\n this.searchSubject.next(this.searchText);\n }\n }\n\n /**\n * Perform search\n */\n private async performSearch(searchText: string): Promise<void> {\n try {\n if (this.searchType === 'User') {\n this.searchResults = await this.sharingService.searchUsers(searchText);\n } else {\n this.searchResults = await this.sharingService.searchRoles(searchText);\n }\n\n // Filter out recipients that already have access\n const existingIds = new Set(this.currentShares.map(s => s.recipientId));\n this.searchResults = this.searchResults.filter(r => !existingIds.has(r.id));\n\n // Also filter out the list owner\n this.searchResults = this.searchResults.filter(r => r.id !== this.config?.currentUserId);\n\n this.showSearchResults = this.searchResults.length > 0;\n } catch (error) {\n console.error('Error searching:', error);\n this.searchResults = [];\n }\n }\n\n /**\n * Select a recipient from search results\n */\n selectRecipient(recipient: ShareRecipient): void {\n this.selectedRecipient = recipient;\n this.searchText = recipient.name;\n this.showSearchResults = false;\n this.cdr.detectChanges();\n }\n\n /**\n * Add the selected recipient as a share\n */\n async addShare(): Promise<void> {\n if (!this.selectedRecipient || !this.config) return;\n\n this.saving = true;\n\n try {\n const md = this.ProviderToUse;\n let result;\n\n if (this.selectedRecipient.type === 'User') {\n result = await this.sharingService.shareListWithUser(\n this.config.listId,\n this.selectedRecipient.id,\n this.selectedPermission,\n this.config.currentUserId\n );\n } else {\n result = await this.sharingService.shareListWithRole(\n this.config.listId,\n this.selectedRecipient.id,\n this.selectedPermission,\n this.config.currentUserId\n );\n }\n\n if (result.success && result.shareId) {\n // Create a ListShareInfo for tracking\n const newShare: ListShareInfo = {\n shareId: result.shareId,\n listId: this.config.listId,\n type: this.selectedRecipient.type,\n recipientId: this.selectedRecipient.id,\n recipientName: this.selectedRecipient.name,\n recipientEmail: this.selectedRecipient.email,\n permissionLevel: this.selectedPermission,\n status: 'Approved'\n };\n\n this.currentShares.push(newShare);\n this.sharesAdded.push(newShare);\n\n // Clear selection\n this.clearSearch();\n this.selectedPermission = 'View';\n } else {\n console.error('Failed to add share:', result.message);\n }\n } catch (error) {\n console.error('Error adding share:', error);\n } finally {\n this.saving = false;\n this.cdr.detectChanges();\n }\n }\n\n /**\n * Update permission level for an existing share\n */\n async updateSharePermission(share: ListShareInfo, newLevel: ListPermissionLevel): Promise<void> {\n if (share.permissionLevel === newLevel) return;\n\n this.saving = true;\n\n try {\n const result = await this.sharingService.updateSharePermission(share.shareId, newLevel);\n\n if (result.success) {\n share.permissionLevel = newLevel;\n\n // Track the update if not already tracked\n const existingUpdate = this.sharesUpdated.find(s => s.shareId === share.shareId);\n if (!existingUpdate) {\n this.sharesUpdated.push({ ...share });\n }\n } else {\n console.error('Failed to update permission:', result.message);\n }\n } catch (error) {\n console.error('Error updating permission:', error);\n } finally {\n this.saving = false;\n this.cdr.detectChanges();\n }\n }\n\n /**\n * Remove a share\n */\n async removeShare(share: ListShareInfo): Promise<void> {\n this.saving = true;\n\n try {\n const result = await this.sharingService.removeShare(share.shareId);\n\n if (result.success) {\n // Remove from current shares\n this.currentShares = this.currentShares.filter(s => s.shareId !== share.shareId);\n\n // Track the removal\n this.sharesRemoved.push(share.shareId);\n\n // Remove from added if it was just added in this session\n this.sharesAdded = this.sharesAdded.filter(s => s.shareId !== share.shareId);\n } else {\n console.error('Failed to remove share:', result.message);\n }\n } catch (error) {\n console.error('Error removing share:', error);\n } finally {\n this.saving = false;\n this.cdr.detectChanges();\n }\n }\n\n /**\n * Get icon for share type\n */\n getShareTypeIcon(type: 'User' | 'Role'): string {\n return type === 'User' ? 'fa-solid fa-user' : 'fa-solid fa-users';\n }\n\n /**\n * Get permission label\n */\n getPermissionLabel(level: ListPermissionLevel): string {\n const option = this.permissionOptions.find(o => o.value === level);\n return option?.label || level;\n }\n\n /**\n * Close dialog with results\n */\n onDone(): void {\n const result: ListShareDialogResult = {\n action: 'apply',\n sharesAdded: this.sharesAdded,\n sharesUpdated: this.sharesUpdated,\n sharesRemoved: this.sharesRemoved,\n notifyByEmail: this.notifyByEmail\n };\n\n this._visible = false;\n this.complete.emit(result);\n }\n\n /**\n * Cancel and close dialog\n */\n onCancel(): void {\n this._visible = false;\n this.cancel.emit();\n }\n\n /**\n * Check if current user can modify shares\n */\n get canModifyShares(): boolean {\n return this.config?.isOwner === true;\n }\n}\n","@if (visible) {\n <mj-dialog\n [Visible]=\"true\"\n [Title]=\"dialogTitle\"\n [Width]=\"500\"\n (Close)=\"onCancel()\">\n <div class=\"share-dialog-content\">\n <!-- Loading state -->\n @if (loading) {\n <div class=\"loading-container\">\n <mj-loading text=\"Loading shares...\"></mj-loading>\n </div>\n }\n @if (!loading) {\n <!-- Add new share section -->\n @if (canModifyShares) {\n <div class=\"add-share-section\">\n <h4 class=\"section-title\">Add people or roles</h4>\n <!-- Search type toggle -->\n <div class=\"search-type-toggle\">\n <button mjButton\n [variant]=\"searchType === 'User' ? 'primary' : 'outline'\"\n (click)=\"setSearchType('User')\">\n <i class=\"fa-solid fa-user\"></i> Users\n </button>\n <button mjButton\n [variant]=\"searchType === 'Role' ? 'primary' : 'outline'\"\n (click)=\"setSearchType('Role')\">\n <i class=\"fa-solid fa-users\"></i> Roles\n </button>\n </div>\n <!-- Search input -->\n <div class=\"search-container\">\n <div class=\"search-input-wrapper\">\n <i class=\"fa-solid fa-search search-icon\"></i>\n <input type=\"text\"\n class=\"mj-input\"\n [value]=\"searchText\"\n (input)=\"onSearchInput($any($event.target).value)\"\n [placeholder]=\"'Search for ' + (searchType === 'User' ? 'users' : 'roles') + '...'\"\n (blur)=\"showSearchResults = false\" />\n </div>\n <!-- Search results dropdown -->\n @if (showSearchResults && searchResults.length > 0) {\n <div class=\"search-results\">\n @for (recipient of searchResults; track recipient) {\n <div class=\"search-result-item\"\n (mousedown)=\"selectRecipient(recipient)\">\n <i [class]=\"getShareTypeIcon(recipient.type)\"></i>\n <div class=\"recipient-info\">\n <span class=\"recipient-name\">{{ recipient.name }}</span>\n @if (recipient.email) {\n <span class=\"recipient-email\">{{ recipient.email }}</span>\n }\n </div>\n </div>\n }\n </div>\n }\n </div>\n <!-- Selected recipient and permission -->\n @if (selectedRecipient) {\n <div class=\"selected-recipient\">\n <div class=\"recipient-chip\">\n <i [class]=\"getShareTypeIcon(selectedRecipient.type)\"></i>\n <span>{{ selectedRecipient.name }}</span>\n <button mjButton variant=\"flat\" size=\"sm\" (click)=\"clearSearch()\">\n <i class=\"fa-solid fa-times\"></i>\n </button>\n </div>\n <mj-dropdown\n [Data]=\"permissionOptions\"\n TextField=\"label\"\n ValueField=\"value\"\n [(ngModel)]=\"selectedPermission\"\n [ValuePrimitive]=\"true\"\n class=\"permission-dropdown\">\n <ng-template #mjDropdownItem let-dataItem>\n <div class=\"permission-option\">\n <span class=\"permission-label\">{{ dataItem.label }}</span>\n <span class=\"permission-desc\">{{ dataItem.description }}</span>\n </div>\n </ng-template>\n </mj-dropdown>\n <button mjButton\n variant=\"primary\"\n [disabled]=\"saving\"\n (click)=\"addShare()\">\n <i class=\"fa-solid fa-plus\"></i> Add\n </button>\n </div>\n }\n </div>\n }\n <!-- Divider -->\n @if (currentShares.length > 0 && canModifyShares) {\n <hr class=\"section-divider\">\n }\n <!-- Current shares section -->\n @if (currentShares.length > 0) {\n <div class=\"current-shares-section\">\n <h4 class=\"section-title\">People with access</h4>\n <div class=\"share-list\">\n @for (share of currentShares; track share) {\n <div class=\"share-item\">\n <div class=\"share-info\">\n <i [class]=\"getShareTypeIcon(share.type)\" class=\"share-type-icon\"></i>\n <div class=\"share-details\">\n <span class=\"share-name\">{{ share.recipientName }}</span>\n @if (share.recipientEmail) {\n <span class=\"share-email\">{{ share.recipientEmail }}</span>\n }\n @if (share.type === 'Role') {\n <span class=\"share-type-label\">Role</span>\n }\n </div>\n </div>\n <div class=\"share-actions\">\n @if (canModifyShares) {\n <mj-dropdown\n [Data]=\"permissionOptions\"\n TextField=\"label\"\n ValueField=\"value\"\n [ngModel]=\"share.permissionLevel\"\n [ValuePrimitive]=\"true\"\n (ValueChange)=\"updateSharePermission(share, $any($event))\"\n [Disabled]=\"saving\"\n class=\"permission-dropdown-small\">\n </mj-dropdown>\n }\n @if (!canModifyShares) {\n <span class=\"permission-badge\">\n {{ getPermissionLabel(share.permissionLevel) }}\n </span>\n }\n @if (canModifyShares) {\n <button mjButton\n variant=\"danger\"\n size=\"sm\"\n title=\"Remove access\"\n [disabled]=\"saving\"\n (click)=\"removeShare(share)\">\n <i class=\"fa-solid fa-trash\"></i>\n </button>\n }\n </div>\n </div>\n }\n </div>\n </div>\n }\n <!-- Empty state -->\n @if (currentShares.length === 0 && !loading) {\n <div class=\"empty-state\">\n <i class=\"fa-solid fa-share-nodes empty-icon\"></i>\n <p>This list hasn't been shared with anyone yet.</p>\n @if (canModifyShares) {\n <p class=\"empty-hint\">\n Use the search above to find users or roles to share with.\n </p>\n }\n </div>\n }\n <!-- Read-only notice -->\n @if (!canModifyShares) {\n <div class=\"readonly-notice\">\n <i class=\"fa-solid fa-info-circle\"></i>\n <span>Only the list owner can manage sharing.</span>\n </div>\n }\n }\n </div>\n <!-- Notify-by-email toggle (mockup 15). Sits above the action footer so\n the user can flip it after adding shares but before clicking Done. -->\n @if (canModifyShares) {\n <div class=\"notify-toggle\">\n <input id=\"share-notify\" type=\"checkbox\" [(ngModel)]=\"notifyByEmail\" />\n <label for=\"share-notify\">\n <i class=\"fa-solid fa-envelope\"></i>\n Send email notification to new shares\n </label>\n </div>\n }\n <mj-dialog-actions>\n <button mjButton variant=\"primary\" (click)=\"onDone()\">Done</button>\n <button mjButton variant=\"outline\" (click)=\"manageInvitations.emit()\">\n <i class=\"fa-solid fa-envelope-open-text\"></i>\n Manage Invitations\n </button>\n <button mjButton (click)=\"onCancel()\">Cancel</button>\n <a class=\"audit-log-link\" (click)=\"viewAuditLog.emit(); $event.preventDefault()\" href=\"#\">\n <i class=\"fa-solid fa-clock-rotate-left\"></i>\n View audit log\n </a>\n </mj-dialog-actions>\n </mj-dialog>\n}\n"]}
1
+ {"version":3,"file":"list-share-dialog.component.js","sourceRoot":"","sources":["../../../../src/lib/components/list-share-dialog/list-share-dialog.component.ts","../../../../src/lib/components/list-share-dialog/list-share-dialog.component.html"],"names":[],"mappings":"AAAA,OAAO,EACL,SAAS,EACT,KAAK,EACL,MAAM,EACN,YAAY,EAIb,MAAM,eAAe,CAAC;AACvB,OAAO,EAAE,OAAO,EAAE,MAAM,MAAM,CAAC;AAC/B,OAAO,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAC;AACrE,OAAO,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;;;;;;;ICFjD,8BAA+B;IAC7B,iCAAkD;IACpD,iBAAM;;;IAyCY,gCAA8B;IAA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ectorRef\n} from '@angular/core';\nimport { Subject } from 'rxjs';\nimport { BaseAngularComponent } from '@memberjunction/ng-base-types';\nimport { debounceTime, takeUntil } from 'rxjs/operators';\nimport { Metadata } from '@memberjunction/core';\nimport { ListSharingService } from '../../services/list-sharing.service';\nimport {\n ListShareDialogConfig,\n ListShareDialogResult,\n ListShareInfo,\n ListPermissionLevel,\n ShareRecipient\n} from '../../models/list-sharing.models';\n\n/**\n * Dialog component for managing list sharing.\n * Allows users to share lists with other users or roles with different permission levels.\n *\n * Features:\n * - User/role search with autocomplete\n * - Permission level selection (View, Edit, Owner)\n * - Current shares management\n * - Remove access functionality\n */\n@Component({\n standalone: false,\n selector: 'mj-list-share-dialog',\n templateUrl: './list-share-dialog.component.html',\n styleUrls: ['./list-share-dialog.component.css']\n})\nexport class ListShareDialogComponent extends BaseAngularComponent implements OnInit, OnDestroy {\n /**\n * Configuration for the dialog\n */\n @Input() config!: ListShareDialogConfig;\n\n /**\n * Supporting message for the empty-state shown when a list has no shares.\n * Appends a usage hint when the current user can manage shares.\n */\n public get EmptyShareMessage(): string {\n const base = \"This list hasn't been shared with anyone yet.\";\n return this.canModifyShares\n ? `${base} Use the search above to find users or roles to share with.`\n : base;\n }\n\n /**\n * Controls dialog visibility\n */\n @Input()\n get visible(): boolean {\n return this._visible;\n }\n set visible(value: boolean) {\n if (value && !this._visible) {\n this.initializeDialog();\n }\n this._visible = value;\n }\n private _visible = false;\n\n /**\n * Emitted when dialog is closed with results\n */\n @Output() complete = new EventEmitter<ListShareDialogResult>();\n\n /**\n * Emitted when dialog is cancelled\n */\n @Output() cancel = new EventEmitter<void>();\n\n /**\n * Emitted when the user clicks \"Manage Invitations\" in the footer.\n * Phase 2: opens the invitations management UI for this list.\n */\n @Output() manageInvitations = new EventEmitter<void>();\n\n /**\n * Emitted when the user clicks \"View audit log\" in the footer.\n * Phase 2: opens the per-list audit log view.\n */\n @Output() viewAuditLog = new EventEmitter<void>();\n\n /**\n * When true (the default), newly-added shares fan out as notifications\n * to the recipient (email + in-app, depending on user preferences).\n * The state is captured on the dialog so consumers can read it back\n * via `ListShareDialogResult.notifyByEmail`.\n */\n public notifyByEmail = true;\n\n // State\n loading = false;\n saving = false;\n searchText = '';\n searchType: 'User' | 'Role' = 'User';\n showSearchResults = false;\n\n // Data\n currentShares: ListShareInfo[] = [];\n searchResults: ShareRecipient[] = [];\n selectedRecipient: ShareRecipient | null = null;\n selectedPermission: ListPermissionLevel = 'View';\n\n // Track changes\n sharesAdded: ListShareInfo[] = [];\n sharesUpdated: ListShareInfo[] = [];\n sharesRemoved: string[] = [];\n\n // Permission options\n permissionOptions: { value: ListPermissionLevel; label: string; description: string }[] = [\n { value: 'View', label: 'Viewer', description: 'Can view list contents' },\n { value: 'Edit', label: 'Editor', description: 'Can add/remove items' },\n { value: 'Owner', label: 'Co-owner', description: 'Full control including sharing' }\n ];\n\n // Cleanup\n private destroy$ = new Subject<void>();\n private searchSubject = new Subject<string>();\n\n constructor(\n private sharingService: ListSharingService,\n private cdr: ChangeDetectorRef\n ) {\n super();}\n\n ngOnInit(): void {\n this.setupSearchDebounce();\n }\n\n ngOnDestroy(): void {\n this.destroy$.next();\n this.destroy$.complete();\n }\n\n /**\n * Get dialog title\n */\n get dialogTitle(): string {\n return `Share \"${this.config?.listName || 'List'}\"`;\n }\n\n /**\n * Check if there are pending changes\n */\n get hasChanges(): boolean {\n return this.sharesAdded.length > 0 ||\n this.sharesUpdated.length > 0 ||\n this.sharesRemoved.length > 0;\n }\n\n /**\n * Setup search with debounce\n */\n private setupSearchDebounce(): void {\n this.searchSubject.pipe(\n debounceTime(300),\n takeUntil(this.destroy$)\n ).subscribe(async (searchText: string) => {\n if (searchText.trim().length >= 2) {\n await this.performSearch(searchText);\n } else {\n this.searchResults = [];\n this.showSearchResults = false;\n }\n this.cdr.detectChanges();\n });\n }\n\n /**\n * Initialize dialog when opened\n */\n private async initializeDialog(): Promise<void> {\n this.resetState();\n await this.loadCurrentShares();\n }\n\n /**\n * Reset all state\n */\n private resetState(): void {\n this.searchText = '';\n this.searchType = 'User';\n this.showSearchResults = false;\n this.searchResults = [];\n this.selectedRecipient = null;\n this.selectedPermission = 'View';\n this.sharesAdded = [];\n this.sharesUpdated = [];\n this.sharesRemoved = [];\n }\n\n /**\n * Load current shares for the list\n */\n private async loadCurrentShares(): Promise<void> {\n if (!this.config) return;\n\n this.loading = true;\n this.cdr.detectChanges();\n\n try {\n this.currentShares = await this.sharingService.getListShares(this.config.listId);\n } catch (error) {\n console.error('Error loading shares:', error);\n this.currentShares = [];\n } finally {\n this.loading = false;\n this.cdr.detectChanges();\n }\n }\n\n /**\n * Handle search input\n */\n onSearchInput(event: Event): void {\n const value = (event.target as HTMLInputElement).value;\n this.searchText = value;\n this.searchSubject.next(value);\n }\n\n /**\n * Clear search\n */\n clearSearch(): void {\n this.searchText = '';\n this.searchResults = [];\n this.showSearchResults = false;\n this.selectedRecipient = null;\n }\n\n /**\n * Switch search type\n */\n setSearchType(type: 'User' | 'Role'): void {\n this.searchType = type;\n if (this.searchText.trim().length >= 2) {\n this.searchSubject.next(this.searchText);\n }\n }\n\n /**\n * Perform search\n */\n private async performSearch(searchText: string): Promise<void> {\n try {\n if (this.searchType === 'User') {\n this.searchResults = await this.sharingService.searchUsers(searchText);\n } else {\n this.searchResults = await this.sharingService.searchRoles(searchText);\n }\n\n // Filter out recipients that already have access\n const existingIds = new Set(this.currentShares.map(s => s.recipientId));\n this.searchResults = this.searchResults.filter(r => !existingIds.has(r.id));\n\n // Also filter out the list owner\n this.searchResults = this.searchResults.filter(r => r.id !== this.config?.currentUserId);\n\n this.showSearchResults = this.searchResults.length > 0;\n } catch (error) {\n console.error('Error searching:', error);\n this.searchResults = [];\n }\n }\n\n /**\n * Select a recipient from search results\n */\n selectRecipient(recipient: ShareRecipient): void {\n this.selectedRecipient = recipient;\n this.searchText = recipient.name;\n this.showSearchResults = false;\n this.cdr.detectChanges();\n }\n\n /**\n * Add the selected recipient as a share\n */\n async addShare(): Promise<void> {\n if (!this.selectedRecipient || !this.config) return;\n\n this.saving = true;\n\n try {\n const md = this.ProviderToUse;\n let result;\n\n if (this.selectedRecipient.type === 'User') {\n result = await this.sharingService.shareListWithUser(\n this.config.listId,\n this.selectedRecipient.id,\n this.selectedPermission,\n this.config.currentUserId\n );\n } else {\n result = await this.sharingService.shareListWithRole(\n this.config.listId,\n this.selectedRecipient.id,\n this.selectedPermission,\n this.config.currentUserId\n );\n }\n\n if (result.success && result.shareId) {\n // Create a ListShareInfo for tracking\n const newShare: ListShareInfo = {\n shareId: result.shareId,\n listId: this.config.listId,\n type: this.selectedRecipient.type,\n recipientId: this.selectedRecipient.id,\n recipientName: this.selectedRecipient.name,\n recipientEmail: this.selectedRecipient.email,\n permissionLevel: this.selectedPermission,\n status: 'Approved'\n };\n\n this.currentShares.push(newShare);\n this.sharesAdded.push(newShare);\n\n // Clear selection\n this.clearSearch();\n this.selectedPermission = 'View';\n } else {\n console.error('Failed to add share:', result.message);\n }\n } catch (error) {\n console.error('Error adding share:', error);\n } finally {\n this.saving = false;\n this.cdr.detectChanges();\n }\n }\n\n /**\n * Update permission level for an existing share\n */\n async updateSharePermission(share: ListShareInfo, newLevel: ListPermissionLevel): Promise<void> {\n if (share.permissionLevel === newLevel) return;\n\n this.saving = true;\n\n try {\n const result = await this.sharingService.updateSharePermission(share.shareId, newLevel);\n\n if (result.success) {\n share.permissionLevel = newLevel;\n\n // Track the update if not already tracked\n const existingUpdate = this.sharesUpdated.find(s => s.shareId === share.shareId);\n if (!existingUpdate) {\n this.sharesUpdated.push({ ...share });\n }\n } else {\n console.error('Failed to update permission:', result.message);\n }\n } catch (error) {\n console.error('Error updating permission:', error);\n } finally {\n this.saving = false;\n this.cdr.detectChanges();\n }\n }\n\n /**\n * Remove a share\n */\n async removeShare(share: ListShareInfo): Promise<void> {\n this.saving = true;\n\n try {\n const result = await this.sharingService.removeShare(share.shareId);\n\n if (result.success) {\n // Remove from current shares\n this.currentShares = this.currentShares.filter(s => s.shareId !== share.shareId);\n\n // Track the removal\n this.sharesRemoved.push(share.shareId);\n\n // Remove from added if it was just added in this session\n this.sharesAdded = this.sharesAdded.filter(s => s.shareId !== share.shareId);\n } else {\n console.error('Failed to remove share:', result.message);\n }\n } catch (error) {\n console.error('Error removing share:', error);\n } finally {\n this.saving = false;\n this.cdr.detectChanges();\n }\n }\n\n /**\n * Get icon for share type\n */\n getShareTypeIcon(type: 'User' | 'Role'): string {\n return type === 'User' ? 'fa-solid fa-user' : 'fa-solid fa-users';\n }\n\n /**\n * Get permission label\n */\n getPermissionLabel(level: ListPermissionLevel): string {\n const option = this.permissionOptions.find(o => o.value === level);\n return option?.label || level;\n }\n\n /**\n * Close dialog with results\n */\n onDone(): void {\n const result: ListShareDialogResult = {\n action: 'apply',\n sharesAdded: this.sharesAdded,\n sharesUpdated: this.sharesUpdated,\n sharesRemoved: this.sharesRemoved,\n notifyByEmail: this.notifyByEmail\n };\n\n this._visible = false;\n this.complete.emit(result);\n }\n\n /**\n * Cancel and close dialog\n */\n onCancel(): void {\n this._visible = false;\n this.cancel.emit();\n }\n\n /**\n * Check if current user can modify shares\n */\n get canModifyShares(): boolean {\n return this.config?.isOwner === true;\n }\n}\n","@if (visible) {\n <mj-dialog\n [Visible]=\"true\"\n [Title]=\"dialogTitle\"\n [Width]=\"500\"\n (Close)=\"onCancel()\">\n <div class=\"share-dialog-content\">\n <!-- Loading state -->\n @if (loading) {\n <div class=\"loading-container\">\n <mj-loading text=\"Loading shares...\"></mj-loading>\n </div>\n }\n @if (!loading) {\n <!-- Add new share section -->\n @if (canModifyShares) {\n <div class=\"add-share-section\">\n <h4 class=\"section-title\">Add people or roles</h4>\n <!-- Search type toggle -->\n <div class=\"search-type-toggle\">\n <button mjButton\n [variant]=\"searchType === 'User' ? 'primary' : 'outline'\"\n (click)=\"setSearchType('User')\">\n <i class=\"fa-solid fa-user\"></i> Users\n </button>\n <button mjButton\n [variant]=\"searchType === 'Role' ? 'primary' : 'outline'\"\n (click)=\"setSearchType('Role')\">\n <i class=\"fa-solid fa-users\"></i> Roles\n </button>\n </div>\n <!-- Search input -->\n <div class=\"search-container\">\n <div class=\"search-input-wrapper\">\n <i class=\"fa-solid fa-search search-icon\"></i>\n <input type=\"text\"\n class=\"mj-input\"\n [value]=\"searchText\"\n (input)=\"onSearchInput($any($event.target).value)\"\n [placeholder]=\"'Search for ' + (searchType === 'User' ? 'users' : 'roles') + '...'\"\n (blur)=\"showSearchResults = false\" />\n </div>\n <!-- Search results dropdown -->\n @if (showSearchResults && searchResults.length > 0) {\n <div class=\"search-results\">\n @for (recipient of searchResults; track recipient) {\n <div class=\"search-result-item\"\n (mousedown)=\"selectRecipient(recipient)\">\n <i [class]=\"getShareTypeIcon(recipient.type)\"></i>\n <div class=\"recipient-info\">\n <span class=\"recipient-name\">{{ recipient.name }}</span>\n @if (recipient.email) {\n <span class=\"recipient-email\">{{ recipient.email }}</span>\n }\n </div>\n </div>\n }\n </div>\n }\n </div>\n <!-- Selected recipient and permission -->\n @if (selectedRecipient) {\n <div class=\"selected-recipient\">\n <div class=\"recipient-chip\">\n <i [class]=\"getShareTypeIcon(selectedRecipient.type)\"></i>\n <span>{{ selectedRecipient.name }}</span>\n <button mjButton variant=\"flat\" size=\"sm\" (click)=\"clearSearch()\">\n <i class=\"fa-solid fa-times\"></i>\n </button>\n </div>\n <mj-dropdown\n [Data]=\"permissionOptions\"\n TextField=\"label\"\n ValueField=\"value\"\n [(ngModel)]=\"selectedPermission\"\n [ValuePrimitive]=\"true\"\n class=\"permission-dropdown\">\n <ng-template #mjDropdownItem let-dataItem>\n <div class=\"permission-option\">\n <span class=\"permission-label\">{{ dataItem.label }}</span>\n <span class=\"permission-desc\">{{ dataItem.description }}</span>\n </div>\n </ng-template>\n </mj-dropdown>\n <button mjButton\n variant=\"primary\"\n [disabled]=\"saving\"\n (click)=\"addShare()\">\n <i class=\"fa-solid fa-plus\"></i> Add\n </button>\n </div>\n }\n </div>\n }\n <!-- Divider -->\n @if (currentShares.length > 0 && canModifyShares) {\n <hr class=\"section-divider\">\n }\n <!-- Current shares section -->\n @if (currentShares.length > 0) {\n <div class=\"current-shares-section\">\n <h4 class=\"section-title\">People with access</h4>\n <div class=\"share-list\">\n @for (share of currentShares; track share) {\n <div class=\"share-item\">\n <div class=\"share-info\">\n <i [class]=\"getShareTypeIcon(share.type)\" class=\"share-type-icon\"></i>\n <div class=\"share-details\">\n <span class=\"share-name\">{{ share.recipientName }}</span>\n @if (share.recipientEmail) {\n <span class=\"share-email\">{{ share.recipientEmail }}</span>\n }\n @if (share.type === 'Role') {\n <span class=\"share-type-label\">Role</span>\n }\n </div>\n </div>\n <div class=\"share-actions\">\n @if (canModifyShares) {\n <mj-dropdown\n [Data]=\"permissionOptions\"\n TextField=\"label\"\n ValueField=\"value\"\n [ngModel]=\"share.permissionLevel\"\n [ValuePrimitive]=\"true\"\n (ValueChange)=\"updateSharePermission(share, $any($event))\"\n [Disabled]=\"saving\"\n class=\"permission-dropdown-small\">\n </mj-dropdown>\n }\n @if (!canModifyShares) {\n <span class=\"permission-badge\">\n {{ getPermissionLabel(share.permissionLevel) }}\n </span>\n }\n @if (canModifyShares) {\n <button mjButton\n variant=\"danger\"\n size=\"sm\"\n title=\"Remove access\"\n [disabled]=\"saving\"\n (click)=\"removeShare(share)\">\n <i class=\"fa-solid fa-trash\"></i>\n </button>\n }\n </div>\n </div>\n }\n </div>\n </div>\n }\n <!-- Empty state -->\n @if (currentShares.length === 0 && !loading) {\n <mj-empty-state\n Icon=\"fa-solid fa-share-nodes\"\n Title=\"Not shared yet\"\n [Message]=\"EmptyShareMessage\"\n Size=\"compact\" />\n }\n <!-- Read-only notice -->\n @if (!canModifyShares) {\n <div class=\"readonly-notice\">\n <i class=\"fa-solid fa-info-circle\"></i>\n <span>Only the list owner can manage sharing.</span>\n </div>\n }\n }\n </div>\n <!-- Notify-by-email toggle (mockup 15). Sits above the action footer so\n the user can flip it after adding shares but before clicking Done. -->\n @if (canModifyShares) {\n <div class=\"notify-toggle\">\n <input id=\"share-notify\" type=\"checkbox\" [(ngModel)]=\"notifyByEmail\" />\n <label for=\"share-notify\">\n <i class=\"fa-solid fa-envelope\"></i>\n Send email notification to new shares\n </label>\n </div>\n }\n <mj-dialog-actions>\n <button mjButton variant=\"primary\" (click)=\"onDone()\">Done</button>\n <button mjButton variant=\"outline\" (click)=\"manageInvitations.emit()\">\n <i class=\"fa-solid fa-envelope-open-text\"></i>\n Manage Invitations\n </button>\n <button mjButton (click)=\"onCancel()\">Cancel</button>\n <a class=\"audit-log-link\" (click)=\"viewAuditLog.emit(); $event.preventDefault()\" href=\"#\">\n <i class=\"fa-solid fa-clock-rotate-left\"></i>\n View audit log\n </a>\n </mj-dialog-actions>\n </mj-dialog>\n}\n"]}
@@ -5,7 +5,7 @@ import * as i0 from "@angular/core";
5
5
  import * as i1 from "@angular/forms";
6
6
  import * as i2 from "@memberjunction/ng-ui-components";
7
7
  const _forTrack0 = ($index, $item) => $item.ID;
8
- function SaveViewAsListDialogComponent_Conditional_0_Conditional_6_Template(rf, ctx) { if (rf & 1) {
8
+ function SaveViewAsListDialogComponent_Conditional_0_Conditional_5_Template(rf, ctx) { if (rf & 1) {
9
9
  i0.ɵɵelementStart(0, "strong");
10
10
  i0.ɵɵtext(1);
11
11
  i0.ɵɵelementEnd();
@@ -14,12 +14,12 @@ function SaveViewAsListDialogComponent_Conditional_0_Conditional_6_Template(rf,
14
14
  i0.ɵɵadvance();
15
15
  i0.ɵɵtextInterpolate1("", ctx_r1.RecordCount, " records");
16
16
  } }
17
- function SaveViewAsListDialogComponent_Conditional_0_Conditional_7_Template(rf, ctx) { if (rf & 1) {
17
+ function SaveViewAsListDialogComponent_Conditional_0_Conditional_6_Template(rf, ctx) { if (rf & 1) {
18
18
  i0.ɵɵelementStart(0, "strong");
19
19
  i0.ɵɵtext(1, "view results");
20
20
  i0.ɵɵelementEnd();
21
21
  } }
22
- function SaveViewAsListDialogComponent_Conditional_0_Conditional_8_Template(rf, ctx) { if (rf & 1) {
22
+ function SaveViewAsListDialogComponent_Conditional_0_Conditional_7_Template(rf, ctx) { if (rf & 1) {
23
23
  i0.ɵɵtext(0, " from ");
24
24
  i0.ɵɵelementStart(1, "strong");
25
25
  i0.ɵɵtext(2);
@@ -29,8 +29,8 @@ function SaveViewAsListDialogComponent_Conditional_0_Conditional_8_Template(rf,
29
29
  i0.ɵɵadvance(2);
30
30
  i0.ɵɵtextInterpolate(ctx_r1.ViewName);
31
31
  } }
32
- function SaveViewAsListDialogComponent_Conditional_0_For_25_Template(rf, ctx) { if (rf & 1) {
33
- i0.ɵɵelementStart(0, "option", 12);
32
+ function SaveViewAsListDialogComponent_Conditional_0_For_24_Template(rf, ctx) { if (rf & 1) {
33
+ i0.ɵɵelementStart(0, "option", 11);
34
34
  i0.ɵɵtext(1);
35
35
  i0.ɵɵelementEnd();
36
36
  } if (rf & 2) {
@@ -39,29 +39,29 @@ function SaveViewAsListDialogComponent_Conditional_0_For_25_Template(rf, ctx) {
39
39
  i0.ɵɵadvance();
40
40
  i0.ɵɵtextInterpolate(cat_r3.Name);
41
41
  } }
42
- function SaveViewAsListDialogComponent_Conditional_0_Conditional_50_Template(rf, ctx) { if (rf & 1) {
42
+ function SaveViewAsListDialogComponent_Conditional_0_Conditional_49_Template(rf, ctx) { if (rf & 1) {
43
43
  const _r4 = i0.ɵɵgetCurrentView();
44
- i0.ɵɵelementStart(0, "div", 23)(1, "input", 24);
45
- i0.ɵɵtwoWayListener("ngModelChange", function SaveViewAsListDialogComponent_Conditional_0_Conditional_50_Template_input_ngModelChange_1_listener($event) { i0.ɵɵrestoreView(_r4); const ctx_r1 = i0.ɵɵnextContext(2); i0.ɵɵtwoWayBindingSet(ctx_r1.useSnapshot, $event) || (ctx_r1.useSnapshot = $event); return i0.ɵɵresetView($event); });
44
+ i0.ɵɵelementStart(0, "div", 22)(1, "input", 23);
45
+ i0.ɵɵtwoWayListener("ngModelChange", function SaveViewAsListDialogComponent_Conditional_0_Conditional_49_Template_input_ngModelChange_1_listener($event) { i0.ɵɵrestoreView(_r4); const ctx_r1 = i0.ɵɵnextContext(2); i0.ɵɵtwoWayBindingSet(ctx_r1.useSnapshot, $event) || (ctx_r1.useSnapshot = $event); return i0.ɵɵresetView($event); });
46
46
  i0.ɵɵelementEnd();
47
- i0.ɵɵelementStart(2, "label", 25);
47
+ i0.ɵɵelementStart(2, "label", 24);
48
48
  i0.ɵɵtext(3, " Freeze filter at current value ");
49
- i0.ɵɵelementStart(4, "span", 26);
49
+ i0.ɵɵelementStart(4, "span", 25);
50
50
  i0.ɵɵtext(5, " (");
51
51
  i0.ɵɵelementStart(6, "code");
52
52
  i0.ɵɵtext(7, "UseSnapshot = true");
53
53
  i0.ɵɵelementEnd();
54
54
  i0.ɵɵtext(8, ") \u2014 refresh re-runs the saved filter, even if the view is later edited ");
55
55
  i0.ɵɵelementEnd()()();
56
- i0.ɵɵelementStart(9, "div", 5)(10, "label", 27);
56
+ i0.ɵɵelementStart(9, "div", 4)(10, "label", 26);
57
57
  i0.ɵɵtext(11, "Default refresh mode");
58
58
  i0.ɵɵelementEnd();
59
- i0.ɵɵelementStart(12, "select", 28);
60
- i0.ɵɵtwoWayListener("ngModelChange", function SaveViewAsListDialogComponent_Conditional_0_Conditional_50_Template_select_ngModelChange_12_listener($event) { i0.ɵɵrestoreView(_r4); const ctx_r1 = i0.ɵɵnextContext(2); i0.ɵɵtwoWayBindingSet(ctx_r1.refreshMode, $event) || (ctx_r1.refreshMode = $event); return i0.ɵɵresetView($event); });
61
- i0.ɵɵelementStart(13, "option", 29);
59
+ i0.ɵɵelementStart(12, "select", 27);
60
+ i0.ɵɵtwoWayListener("ngModelChange", function SaveViewAsListDialogComponent_Conditional_0_Conditional_49_Template_select_ngModelChange_12_listener($event) { i0.ɵɵrestoreView(_r4); const ctx_r1 = i0.ɵɵnextContext(2); i0.ɵɵtwoWayBindingSet(ctx_r1.refreshMode, $event) || (ctx_r1.refreshMode = $event); return i0.ɵɵresetView($event); });
61
+ i0.ɵɵelementStart(13, "option", 28);
62
62
  i0.ɵɵtext(14, "Additive \u2014 only adds new records on refresh");
63
63
  i0.ɵɵelementEnd();
64
- i0.ɵɵelementStart(15, "option", 30);
64
+ i0.ɵɵelementStart(15, "option", 29);
65
65
  i0.ɵɵtext(16, "Sync \u2014 reconciles in both directions (may remove records)");
66
66
  i0.ɵɵelementEnd()()();
67
67
  } if (rf & 2) {
@@ -77,84 +77,82 @@ function SaveViewAsListDialogComponent_Conditional_0_Template(rf, ctx) { if (rf
77
77
  i0.ɵɵlistener("Close", function SaveViewAsListDialogComponent_Conditional_0_Template_mj_dialog_Close_0_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnCancel()); });
78
78
  i0.ɵɵelementStart(1, "form", 2);
79
79
  i0.ɵɵlistener("submit", function SaveViewAsListDialogComponent_Conditional_0_Template_form_submit_1_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); $event.preventDefault(); return i0.ɵɵresetView(ctx_r1.OnSave()); });
80
- i0.ɵɵelementStart(2, "div", 3);
81
- i0.ɵɵelement(3, "i", 4);
82
- i0.ɵɵelementStart(4, "div");
83
- i0.ɵɵtext(5, " Materializes ");
84
- i0.ɵɵconditionalCreate(6, SaveViewAsListDialogComponent_Conditional_0_Conditional_6_Template, 2, 1, "strong")(7, SaveViewAsListDialogComponent_Conditional_0_Conditional_7_Template, 2, 0, "strong");
85
- i0.ɵɵconditionalCreate(8, SaveViewAsListDialogComponent_Conditional_0_Conditional_8_Template, 3, 1);
86
- i0.ɵɵtext(9, " into a static List. The list can be refreshed from this view later if you keep lineage on. ");
80
+ i0.ɵɵelementStart(2, "mj-alert", 3)(3, "div");
81
+ i0.ɵɵtext(4, " Materializes ");
82
+ i0.ɵɵconditionalCreate(5, SaveViewAsListDialogComponent_Conditional_0_Conditional_5_Template, 2, 1, "strong")(6, SaveViewAsListDialogComponent_Conditional_0_Conditional_6_Template, 2, 0, "strong");
83
+ i0.ɵɵconditionalCreate(7, SaveViewAsListDialogComponent_Conditional_0_Conditional_7_Template, 3, 1);
84
+ i0.ɵɵtext(8, " into a static List. The list can be refreshed from this view later if you keep lineage on. ");
87
85
  i0.ɵɵelementEnd()();
88
- i0.ɵɵelementStart(10, "div", 5)(11, "label", 6);
89
- i0.ɵɵtext(12, "List name");
86
+ i0.ɵɵelementStart(9, "div", 4)(10, "label", 5);
87
+ i0.ɵɵtext(11, "List name");
90
88
  i0.ɵɵelementEnd();
91
- i0.ɵɵelementStart(13, "input", 7);
92
- i0.ɵɵtwoWayListener("ngModelChange", function SaveViewAsListDialogComponent_Conditional_0_Template_input_ngModelChange_13_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); i0.ɵɵtwoWayBindingSet(ctx_r1.listName, $event) || (ctx_r1.listName = $event); return i0.ɵɵresetView($event); });
89
+ i0.ɵɵelementStart(12, "input", 6);
90
+ i0.ɵɵtwoWayListener("ngModelChange", function SaveViewAsListDialogComponent_Conditional_0_Template_input_ngModelChange_12_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); i0.ɵɵtwoWayBindingSet(ctx_r1.listName, $event) || (ctx_r1.listName = $event); return i0.ɵɵresetView($event); });
93
91
  i0.ɵɵelementEnd()();
94
- i0.ɵɵelementStart(14, "div", 5)(15, "label", 8);
95
- i0.ɵɵtext(16, "Description");
92
+ i0.ɵɵelementStart(13, "div", 4)(14, "label", 7);
93
+ i0.ɵɵtext(15, "Description");
96
94
  i0.ɵɵelementEnd();
97
- i0.ɵɵelementStart(17, "textarea", 9);
98
- i0.ɵɵtwoWayListener("ngModelChange", function SaveViewAsListDialogComponent_Conditional_0_Template_textarea_ngModelChange_17_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); i0.ɵɵtwoWayBindingSet(ctx_r1.description, $event) || (ctx_r1.description = $event); return i0.ɵɵresetView($event); });
95
+ i0.ɵɵelementStart(16, "textarea", 8);
96
+ i0.ɵɵtwoWayListener("ngModelChange", function SaveViewAsListDialogComponent_Conditional_0_Template_textarea_ngModelChange_16_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); i0.ɵɵtwoWayBindingSet(ctx_r1.description, $event) || (ctx_r1.description = $event); return i0.ɵɵresetView($event); });
99
97
  i0.ɵɵelementEnd()();
100
- i0.ɵɵelementStart(18, "div", 5)(19, "label", 10);
101
- i0.ɵɵtext(20, "Category");
98
+ i0.ɵɵelementStart(17, "div", 4)(18, "label", 9);
99
+ i0.ɵɵtext(19, "Category");
102
100
  i0.ɵɵelementEnd();
103
- i0.ɵɵelementStart(21, "select", 11);
104
- i0.ɵɵtwoWayListener("ngModelChange", function SaveViewAsListDialogComponent_Conditional_0_Template_select_ngModelChange_21_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); i0.ɵɵtwoWayBindingSet(ctx_r1.categoryId, $event) || (ctx_r1.categoryId = $event); return i0.ɵɵresetView($event); });
105
- i0.ɵɵelementStart(22, "option", 12);
106
- i0.ɵɵtext(23, "(uncategorized)");
101
+ i0.ɵɵelementStart(20, "select", 10);
102
+ i0.ɵɵtwoWayListener("ngModelChange", function SaveViewAsListDialogComponent_Conditional_0_Template_select_ngModelChange_20_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); i0.ɵɵtwoWayBindingSet(ctx_r1.categoryId, $event) || (ctx_r1.categoryId = $event); return i0.ɵɵresetView($event); });
103
+ i0.ɵɵelementStart(21, "option", 11);
104
+ i0.ɵɵtext(22, "(uncategorized)");
107
105
  i0.ɵɵelementEnd();
108
- i0.ɵɵrepeaterCreate(24, SaveViewAsListDialogComponent_Conditional_0_For_25_Template, 2, 2, "option", 12, _forTrack0);
106
+ i0.ɵɵrepeaterCreate(23, SaveViewAsListDialogComponent_Conditional_0_For_24_Template, 2, 2, "option", 11, _forTrack0);
109
107
  i0.ɵɵelementEnd()();
110
- i0.ɵɵelement(26, "div", 13);
111
- i0.ɵɵelementStart(27, "div", 14)(28, "div", 15);
112
- i0.ɵɵtext(29, "Source lineage");
108
+ i0.ɵɵelement(25, "div", 12);
109
+ i0.ɵɵelementStart(26, "div", 13)(27, "div", 14);
110
+ i0.ɵɵtext(28, "Source lineage");
113
111
  i0.ɵɵelementEnd();
114
- i0.ɵɵelementStart(30, "label", 16)(31, "input", 17);
115
- i0.ɵɵlistener("change", function SaveViewAsListDialogComponent_Conditional_0_Template_input_change_31_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnLineageChange(true)); });
112
+ i0.ɵɵelementStart(29, "label", 15)(30, "input", 16);
113
+ i0.ɵɵlistener("change", function SaveViewAsListDialogComponent_Conditional_0_Template_input_change_30_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnLineageChange(true)); });
116
114
  i0.ɵɵelementEnd();
117
- i0.ɵɵelementStart(32, "div")(33, "div", 18);
118
- i0.ɵɵtext(34, "Remember source view (recommended)");
115
+ i0.ɵɵelementStart(31, "div")(32, "div", 17);
116
+ i0.ɵɵtext(33, "Remember source view (recommended)");
119
117
  i0.ɵɵelementEnd();
120
- i0.ɵɵelementStart(35, "div", 19);
121
- i0.ɵɵtext(36, " Stores ");
122
- i0.ɵɵelementStart(37, "code");
123
- i0.ɵɵtext(38, "SourceViewID");
118
+ i0.ɵɵelementStart(34, "div", 18);
119
+ i0.ɵɵtext(35, " Stores ");
120
+ i0.ɵɵelementStart(36, "code");
121
+ i0.ɵɵtext(37, "SourceViewID");
124
122
  i0.ɵɵelementEnd();
125
- i0.ɵɵtext(39, " and (optionally) the current filter. Enables ");
126
- i0.ɵɵelementStart(40, "strong");
127
- i0.ɵɵtext(41, "Refresh from source");
123
+ i0.ɵɵtext(38, " and (optionally) the current filter. Enables ");
124
+ i0.ɵɵelementStart(39, "strong");
125
+ i0.ɵɵtext(40, "Refresh from source");
128
126
  i0.ɵɵelementEnd();
129
- i0.ɵɵtext(42, " later. You'll choose Additive or Sync each refresh. ");
127
+ i0.ɵɵtext(41, " later. You'll choose Additive or Sync each refresh. ");
130
128
  i0.ɵɵelementEnd()()();
131
- i0.ɵɵelementStart(43, "label", 16)(44, "input", 17);
132
- i0.ɵɵlistener("change", function SaveViewAsListDialogComponent_Conditional_0_Template_input_change_44_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnLineageChange(false)); });
129
+ i0.ɵɵelementStart(42, "label", 15)(43, "input", 16);
130
+ i0.ɵɵlistener("change", function SaveViewAsListDialogComponent_Conditional_0_Template_input_change_43_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnLineageChange(false)); });
133
131
  i0.ɵɵelementEnd();
134
- i0.ɵɵelementStart(45, "div")(46, "div", 18);
135
- i0.ɵɵtext(47, "One-time snapshot");
132
+ i0.ɵɵelementStart(44, "div")(45, "div", 17);
133
+ i0.ɵɵtext(46, "One-time snapshot");
136
134
  i0.ɵɵelementEnd();
137
- i0.ɵɵelementStart(48, "div", 19);
138
- i0.ɵɵtext(49, " No lineage stored. List is fully static; later changes to the view do not propagate. ");
135
+ i0.ɵɵelementStart(47, "div", 18);
136
+ i0.ɵɵtext(48, " No lineage stored. List is fully static; later changes to the view do not propagate. ");
139
137
  i0.ɵɵelementEnd()()()();
140
- i0.ɵɵconditionalCreate(50, SaveViewAsListDialogComponent_Conditional_0_Conditional_50_Template, 17, 2);
138
+ i0.ɵɵconditionalCreate(49, SaveViewAsListDialogComponent_Conditional_0_Conditional_49_Template, 17, 2);
141
139
  i0.ɵɵelementEnd();
142
- i0.ɵɵelementStart(51, "mj-dialog-actions")(52, "button", 20);
143
- i0.ɵɵlistener("click", function SaveViewAsListDialogComponent_Conditional_0_Template_button_click_52_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnSave()); });
144
- i0.ɵɵelement(53, "i", 21);
145
- i0.ɵɵtext(54);
140
+ i0.ɵɵelementStart(50, "mj-dialog-actions")(51, "button", 19);
141
+ i0.ɵɵlistener("click", function SaveViewAsListDialogComponent_Conditional_0_Template_button_click_51_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnSave()); });
142
+ i0.ɵɵelement(52, "i", 20);
143
+ i0.ɵɵtext(53);
146
144
  i0.ɵɵelementEnd();
147
- i0.ɵɵelementStart(55, "button", 22);
148
- i0.ɵɵlistener("click", function SaveViewAsListDialogComponent_Conditional_0_Template_button_click_55_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnCancel()); });
149
- i0.ɵɵtext(56, "Cancel");
145
+ i0.ɵɵelementStart(54, "button", 21);
146
+ i0.ɵɵlistener("click", function SaveViewAsListDialogComponent_Conditional_0_Template_button_click_54_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnCancel()); });
147
+ i0.ɵɵtext(55, "Cancel");
150
148
  i0.ɵɵelementEnd()()();
151
149
  } if (rf & 2) {
152
150
  const ctx_r1 = i0.ɵɵnextContext();
153
151
  i0.ɵɵproperty("Visible", true)("Width", 560);
154
- i0.ɵɵadvance(6);
155
- i0.ɵɵconditional(ctx_r1.RecordCount != null ? 6 : 7);
152
+ i0.ɵɵadvance(5);
153
+ i0.ɵɵconditional(ctx_r1.RecordCount != null ? 5 : 6);
156
154
  i0.ɵɵadvance(2);
157
- i0.ɵɵconditional(ctx_r1.ViewName ? 8 : -1);
155
+ i0.ɵɵconditional(ctx_r1.ViewName ? 7 : -1);
158
156
  i0.ɵɵadvance(5);
159
157
  i0.ɵɵtwoWayProperty("ngModel", ctx_r1.listName);
160
158
  i0.ɵɵadvance(4);
@@ -175,7 +173,7 @@ function SaveViewAsListDialogComponent_Conditional_0_Template(rf, ctx) { if (rf
175
173
  i0.ɵɵadvance();
176
174
  i0.ɵɵproperty("checked", !ctx_r1.rememberLineage);
177
175
  i0.ɵɵadvance(6);
178
- i0.ɵɵconditional(ctx_r1.rememberLineage ? 50 : -1);
176
+ i0.ɵɵconditional(ctx_r1.rememberLineage ? 49 : -1);
179
177
  i0.ɵɵadvance(2);
180
178
  i0.ɵɵproperty("disabled", !ctx_r1.canSave);
181
179
  i0.ɵɵadvance(2);
@@ -290,15 +288,15 @@ export class SaveViewAsListDialogComponent extends BaseAngularComponent {
290
288
  this.submitting = false;
291
289
  }
292
290
  static ɵfac = /*@__PURE__*/ (() => { let ɵSaveViewAsListDialogComponent_BaseFactory; return function SaveViewAsListDialogComponent_Factory(__ngFactoryType__) { return (ɵSaveViewAsListDialogComponent_BaseFactory || (ɵSaveViewAsListDialogComponent_BaseFactory = i0.ɵɵgetInheritedFactory(SaveViewAsListDialogComponent)))(__ngFactoryType__ || SaveViewAsListDialogComponent); }; })();
293
- static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: SaveViewAsListDialogComponent, selectors: [["mj-save-view-as-list-dialog"]], inputs: { Visible: "Visible", ViewId: "ViewId", ViewName: "ViewName", RecordCount: "RecordCount" }, outputs: { Save: "Save", Cancel: "Cancel" }, standalone: false, features: [i0.ɵɵInheritDefinitionFeature], decls: 1, vars: 1, consts: [["Title", "Save View Results as List", 3, "Visible", "Width"], ["Title", "Save View Results as List", 3, "Close", "Visible", "Width"], [1, "save-view-form", 3, "submit"], [1, "info-banner"], [1, "fa-solid", "fa-circle-info"], [1, "field"], ["for", "save-view-list-name", 1, "field__label"], ["id", "save-view-list-name", "name", "listName", "required", "", "autofocus", "", 1, "mj-input", 3, "ngModelChange", "ngModel"], ["for", "save-view-description", 1, "field__label"], ["id", "save-view-description", "name", "description", "rows", "2", 1, "mj-input", 3, "ngModelChange", "ngModel"], ["for", "save-view-category", 1, "field__label"], ["id", "save-view-category", "name", "categoryId", 1, "mj-input", "mj-select", 3, "ngModelChange", "ngModel", "disabled"], [3, "ngValue"], [1, "divider"], [1, "lineage-section"], [1, "field__label"], [1, "lineage-option"], ["type", "radio", "name", "lineage", 3, "change", "checked"], [1, "lineage-option__title"], [1, "lineage-option__desc"], ["mjButton", "", "variant", "primary", "type", "button", 3, "click", "disabled"], [1, "fa-solid", "fa-check"], ["mjButton", "", "variant", "outline", "type", "button", 3, "click"], [1, "field--inline"], ["id", "save-view-freeze", "type", "checkbox", "name", "useSnapshot", 3, "ngModelChange", "ngModel"], ["for", "save-view-freeze"], [1, "muted"], ["for", "save-view-mode", 1, "field__label"], ["id", "save-view-mode", "name", "refreshMode", 1, "mj-input", "mj-select", 3, "ngModelChange", "ngModel"], ["value", "Additive"], ["value", "Sync"]], template: function SaveViewAsListDialogComponent_Template(rf, ctx) { if (rf & 1) {
294
- i0.ɵɵconditionalCreate(0, SaveViewAsListDialogComponent_Conditional_0_Template, 57, 18, "mj-dialog", 0);
291
+ static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: SaveViewAsListDialogComponent, selectors: [["mj-save-view-as-list-dialog"]], inputs: { Visible: "Visible", ViewId: "ViewId", ViewName: "ViewName", RecordCount: "RecordCount" }, outputs: { Save: "Save", Cancel: "Cancel" }, standalone: false, features: [i0.ɵɵInheritDefinitionFeature], decls: 1, vars: 1, consts: [["Title", "Save View Results as List", 3, "Visible", "Width"], ["Title", "Save View Results as List", 3, "Close", "Visible", "Width"], [1, "save-view-form", 3, "submit"], ["Variant", "info"], [1, "field"], ["for", "save-view-list-name", 1, "field__label"], ["id", "save-view-list-name", "name", "listName", "required", "", "autofocus", "", 1, "mj-input", 3, "ngModelChange", "ngModel"], ["for", "save-view-description", 1, "field__label"], ["id", "save-view-description", "name", "description", "rows", "2", 1, "mj-input", 3, "ngModelChange", "ngModel"], ["for", "save-view-category", 1, "field__label"], ["id", "save-view-category", "name", "categoryId", 1, "mj-input", "mj-select", 3, "ngModelChange", "ngModel", "disabled"], [3, "ngValue"], [1, "divider"], [1, "lineage-section"], [1, "field__label"], [1, "lineage-option"], ["type", "radio", "name", "lineage", 3, "change", "checked"], [1, "lineage-option__title"], [1, "lineage-option__desc"], ["mjButton", "", "variant", "primary", "type", "button", 3, "click", "disabled"], [1, "fa-solid", "fa-check"], ["mjButton", "", "variant", "outline", "type", "button", 3, "click"], [1, "field--inline"], ["id", "save-view-freeze", "type", "checkbox", "name", "useSnapshot", 3, "ngModelChange", "ngModel"], ["for", "save-view-freeze"], [1, "muted"], ["for", "save-view-mode", 1, "field__label"], ["id", "save-view-mode", "name", "refreshMode", 1, "mj-input", "mj-select", 3, "ngModelChange", "ngModel"], ["value", "Additive"], ["value", "Sync"]], template: function SaveViewAsListDialogComponent_Template(rf, ctx) { if (rf & 1) {
292
+ i0.ɵɵconditionalCreate(0, SaveViewAsListDialogComponent_Conditional_0_Template, 56, 18, "mj-dialog", 0);
295
293
  } if (rf & 2) {
296
294
  i0.ɵɵconditional(ctx.Visible ? 0 : -1);
297
- } }, dependencies: [i1.ɵNgNoValidate, i1.NgSelectOption, i1.ɵNgSelectMultipleOption, i1.DefaultValueAccessor, i1.CheckboxControlValueAccessor, i1.SelectControlValueAccessor, i1.NgControlStatus, i1.NgControlStatusGroup, i1.RequiredValidator, i1.NgModel, i1.NgForm, i2.MJButtonDirective, i2.MJDialogComponent, i2.MJDialogActionsComponent], styles: ["[_nghost-%COMP%] {\n display: contents;\n}\n\n.save-view-form[_ngcontent-%COMP%] {\n padding: 16px 20px 8px;\n display: flex;\n flex-direction: column;\n gap: 14px;\n color: var(--mj-text-primary);\n font-size: 13px;\n}\n\n.info-banner[_ngcontent-%COMP%] {\n display: flex;\n gap: 10px;\n padding: 10px 12px;\n background: var(--mj-status-info-bg);\n border: 1px solid var(--mj-status-info-border);\n color: var(--mj-status-info-text);\n border-radius: 8px;\n font-size: 12.5px;\n line-height: 1.5;\n}\n\n.field[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n gap: 6px;\n}\n\n.field__label[_ngcontent-%COMP%] {\n font-size: 11px;\n letter-spacing: 0.04em;\n text-transform: uppercase;\n color: var(--mj-text-muted);\n}\n\n.field--inline[_ngcontent-%COMP%] {\n display: flex;\n align-items: flex-start;\n gap: 10px;\n font-size: 12.5px;\n}\n\n.field--inline[_ngcontent-%COMP%] input[type='checkbox'][_ngcontent-%COMP%] {\n margin-top: 3px;\n cursor: pointer;\n}\n\n.divider[_ngcontent-%COMP%] {\n height: 1px;\n background: var(--mj-border-default);\n margin: 4px 0;\n}\n\n.lineage-section[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n gap: 8px;\n}\n\n.lineage-option[_ngcontent-%COMP%] {\n display: flex;\n align-items: flex-start;\n gap: 10px;\n padding: 10px;\n border: 1px solid var(--mj-border-default);\n border-radius: 8px;\n cursor: pointer;\n background: var(--mj-bg-surface);\n}\n\n.lineage-option--selected[_ngcontent-%COMP%] {\n border-color: var(--mj-brand-primary);\n background: color-mix(in srgb, var(--mj-brand-primary) 6%, var(--mj-bg-surface));\n}\n\n.lineage-option[_ngcontent-%COMP%] input[type='radio'][_ngcontent-%COMP%] {\n margin-top: 3px;\n cursor: pointer;\n}\n\n.lineage-option__title[_ngcontent-%COMP%] {\n font-weight: 600;\n font-size: 13px;\n}\n\n.lineage-option__desc[_ngcontent-%COMP%] {\n font-size: 12px;\n color: var(--mj-text-muted);\n margin-top: 2px;\n line-height: 1.5;\n}\n\n.muted[_ngcontent-%COMP%] {\n color: var(--mj-text-muted);\n}"], changeDetection: 0 });
295
+ } }, dependencies: [i1.ɵNgNoValidate, i1.NgSelectOption, i1.ɵNgSelectMultipleOption, i1.DefaultValueAccessor, i1.CheckboxControlValueAccessor, i1.SelectControlValueAccessor, i1.NgControlStatus, i1.NgControlStatusGroup, i1.RequiredValidator, i1.NgModel, i1.NgForm, i2.MJButtonDirective, i2.MJDialogComponent, i2.MJDialogActionsComponent, i2.MJAlertComponent], styles: ["[_nghost-%COMP%] {\n display: contents;\n}\n\n.save-view-form[_ngcontent-%COMP%] {\n padding: 16px 20px 8px;\n display: flex;\n flex-direction: column;\n gap: 14px;\n color: var(--mj-text-primary);\n font-size: 13px;\n}\n\n\n.field[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n gap: 6px;\n}\n\n.field__label[_ngcontent-%COMP%] {\n font-size: 11px;\n letter-spacing: 0.04em;\n text-transform: uppercase;\n color: var(--mj-text-muted);\n}\n\n.field--inline[_ngcontent-%COMP%] {\n display: flex;\n align-items: flex-start;\n gap: 10px;\n font-size: 12.5px;\n}\n\n.field--inline[_ngcontent-%COMP%] input[type='checkbox'][_ngcontent-%COMP%] {\n margin-top: 3px;\n cursor: pointer;\n}\n\n.divider[_ngcontent-%COMP%] {\n height: 1px;\n background: var(--mj-border-default);\n margin: 4px 0;\n}\n\n.lineage-section[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n gap: 8px;\n}\n\n.lineage-option[_ngcontent-%COMP%] {\n display: flex;\n align-items: flex-start;\n gap: 10px;\n padding: 10px;\n border: 1px solid var(--mj-border-default);\n border-radius: 8px;\n cursor: pointer;\n background: var(--mj-bg-surface);\n}\n\n.lineage-option--selected[_ngcontent-%COMP%] {\n border-color: var(--mj-brand-primary);\n background: color-mix(in srgb, var(--mj-brand-primary) 6%, var(--mj-bg-surface));\n}\n\n.lineage-option[_ngcontent-%COMP%] input[type='radio'][_ngcontent-%COMP%] {\n margin-top: 3px;\n cursor: pointer;\n}\n\n.lineage-option__title[_ngcontent-%COMP%] {\n font-weight: 600;\n font-size: 13px;\n}\n\n.lineage-option__desc[_ngcontent-%COMP%] {\n font-size: 12px;\n color: var(--mj-text-muted);\n margin-top: 2px;\n line-height: 1.5;\n}\n\n.muted[_ngcontent-%COMP%] {\n color: var(--mj-text-muted);\n}"], changeDetection: 0 });
298
296
  }
299
297
  (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(SaveViewAsListDialogComponent, [{
300
298
  type: Component,
301
- args: [{ standalone: false, selector: 'mj-save-view-as-list-dialog', changeDetection: ChangeDetectionStrategy.OnPush, template: "@if (Visible) {\n <mj-dialog\n [Visible]=\"true\"\n [Width]=\"560\"\n Title=\"Save View Results as List\"\n (Close)=\"OnCancel()\">\n <form class=\"save-view-form\" (submit)=\"$event.preventDefault(); OnSave()\">\n <div class=\"info-banner\">\n <i class=\"fa-solid fa-circle-info\"></i>\n <div>\n Materializes\n @if (RecordCount != null) {\n <strong>{{ RecordCount }} records</strong>\n } @else {\n <strong>view results</strong>\n }\n @if (ViewName) {\n from <strong>{{ ViewName }}</strong>\n }\n into a static List. The list can be refreshed from this view later if you keep lineage on.\n </div>\n </div>\n\n <div class=\"field\">\n <label class=\"field__label\" for=\"save-view-list-name\">List name</label>\n <input\n id=\"save-view-list-name\"\n class=\"mj-input\"\n [(ngModel)]=\"listName\"\n name=\"listName\"\n required\n autofocus />\n </div>\n\n <div class=\"field\">\n <label class=\"field__label\" for=\"save-view-description\">Description</label>\n <textarea\n id=\"save-view-description\"\n class=\"mj-input\"\n [(ngModel)]=\"description\"\n name=\"description\"\n rows=\"2\"></textarea>\n </div>\n\n <div class=\"field\">\n <label class=\"field__label\" for=\"save-view-category\">Category</label>\n <select\n id=\"save-view-category\"\n class=\"mj-input mj-select\"\n [(ngModel)]=\"categoryId\"\n name=\"categoryId\"\n [disabled]=\"loadingCategories\">\n <option [ngValue]=\"null\">(uncategorized)</option>\n @for (cat of categories; track cat.ID) {\n <option [ngValue]=\"cat.ID\">{{ cat.Name }}</option>\n }\n </select>\n </div>\n\n <div class=\"divider\"></div>\n\n <div class=\"lineage-section\">\n <div class=\"field__label\">Source lineage</div>\n <label class=\"lineage-option\" [class.lineage-option--selected]=\"rememberLineage\">\n <input\n type=\"radio\"\n name=\"lineage\"\n [checked]=\"rememberLineage\"\n (change)=\"OnLineageChange(true)\" />\n <div>\n <div class=\"lineage-option__title\">Remember source view (recommended)</div>\n <div class=\"lineage-option__desc\">\n Stores <code>SourceViewID</code> and (optionally) the current filter. Enables\n <strong>Refresh from source</strong> later. You'll choose Additive or Sync each refresh.\n </div>\n </div>\n </label>\n <label class=\"lineage-option\" [class.lineage-option--selected]=\"!rememberLineage\">\n <input\n type=\"radio\"\n name=\"lineage\"\n [checked]=\"!rememberLineage\"\n (change)=\"OnLineageChange(false)\" />\n <div>\n <div class=\"lineage-option__title\">One-time snapshot</div>\n <div class=\"lineage-option__desc\">\n No lineage stored. List is fully static; later changes to the view do not propagate.\n </div>\n </div>\n </label>\n </div>\n\n @if (rememberLineage) {\n <div class=\"field--inline\">\n <input\n id=\"save-view-freeze\"\n type=\"checkbox\"\n [(ngModel)]=\"useSnapshot\"\n name=\"useSnapshot\" />\n <label for=\"save-view-freeze\">\n Freeze filter at current value\n <span class=\"muted\">\n (<code>UseSnapshot = true</code>) \u2014 refresh re-runs the saved filter, even if the view is later edited\n </span>\n </label>\n </div>\n\n <div class=\"field\">\n <label class=\"field__label\" for=\"save-view-mode\">Default refresh mode</label>\n <select\n id=\"save-view-mode\"\n class=\"mj-input mj-select\"\n [(ngModel)]=\"refreshMode\"\n name=\"refreshMode\">\n <option value=\"Additive\">Additive \u2014 only adds new records on refresh</option>\n <option value=\"Sync\">Sync \u2014 reconciles in both directions (may remove records)</option>\n </select>\n </div>\n }\n </form>\n\n <mj-dialog-actions>\n <button mjButton variant=\"primary\" type=\"button\" [disabled]=\"!canSave\" (click)=\"OnSave()\">\n <i class=\"fa-solid fa-check\"></i>\n {{ confirmButtonLabel }}\n </button>\n <button mjButton variant=\"outline\" type=\"button\" (click)=\"OnCancel()\">Cancel</button>\n </mj-dialog-actions>\n </mj-dialog>\n}\n", styles: [":host {\n display: contents;\n}\n\n.save-view-form {\n padding: 16px 20px 8px;\n display: flex;\n flex-direction: column;\n gap: 14px;\n color: var(--mj-text-primary);\n font-size: 13px;\n}\n\n.info-banner {\n display: flex;\n gap: 10px;\n padding: 10px 12px;\n background: var(--mj-status-info-bg);\n border: 1px solid var(--mj-status-info-border);\n color: var(--mj-status-info-text);\n border-radius: 8px;\n font-size: 12.5px;\n line-height: 1.5;\n}\n\n.field {\n display: flex;\n flex-direction: column;\n gap: 6px;\n}\n\n.field__label {\n font-size: 11px;\n letter-spacing: 0.04em;\n text-transform: uppercase;\n color: var(--mj-text-muted);\n}\n\n.field--inline {\n display: flex;\n align-items: flex-start;\n gap: 10px;\n font-size: 12.5px;\n}\n\n.field--inline input[type='checkbox'] {\n margin-top: 3px;\n cursor: pointer;\n}\n\n.divider {\n height: 1px;\n background: var(--mj-border-default);\n margin: 4px 0;\n}\n\n.lineage-section {\n display: flex;\n flex-direction: column;\n gap: 8px;\n}\n\n.lineage-option {\n display: flex;\n align-items: flex-start;\n gap: 10px;\n padding: 10px;\n border: 1px solid var(--mj-border-default);\n border-radius: 8px;\n cursor: pointer;\n background: var(--mj-bg-surface);\n}\n\n.lineage-option--selected {\n border-color: var(--mj-brand-primary);\n background: color-mix(in srgb, var(--mj-brand-primary) 6%, var(--mj-bg-surface));\n}\n\n.lineage-option input[type='radio'] {\n margin-top: 3px;\n cursor: pointer;\n}\n\n.lineage-option__title {\n font-weight: 600;\n font-size: 13px;\n}\n\n.lineage-option__desc {\n font-size: 12px;\n color: var(--mj-text-muted);\n margin-top: 2px;\n line-height: 1.5;\n}\n\n.muted {\n color: var(--mj-text-muted);\n}\n"] }]
299
+ args: [{ standalone: false, selector: 'mj-save-view-as-list-dialog', changeDetection: ChangeDetectionStrategy.OnPush, template: "@if (Visible) {\n <mj-dialog\n [Visible]=\"true\"\n [Width]=\"560\"\n Title=\"Save View Results as List\"\n (Close)=\"OnCancel()\">\n <form class=\"save-view-form\" (submit)=\"$event.preventDefault(); OnSave()\">\n <mj-alert Variant=\"info\">\n <div>\n Materializes\n @if (RecordCount != null) {\n <strong>{{ RecordCount }} records</strong>\n } @else {\n <strong>view results</strong>\n }\n @if (ViewName) {\n from <strong>{{ ViewName }}</strong>\n }\n into a static List. The list can be refreshed from this view later if you keep lineage on.\n </div>\n </mj-alert>\n\n <div class=\"field\">\n <label class=\"field__label\" for=\"save-view-list-name\">List name</label>\n <input\n id=\"save-view-list-name\"\n class=\"mj-input\"\n [(ngModel)]=\"listName\"\n name=\"listName\"\n required\n autofocus />\n </div>\n\n <div class=\"field\">\n <label class=\"field__label\" for=\"save-view-description\">Description</label>\n <textarea\n id=\"save-view-description\"\n class=\"mj-input\"\n [(ngModel)]=\"description\"\n name=\"description\"\n rows=\"2\"></textarea>\n </div>\n\n <div class=\"field\">\n <label class=\"field__label\" for=\"save-view-category\">Category</label>\n <select\n id=\"save-view-category\"\n class=\"mj-input mj-select\"\n [(ngModel)]=\"categoryId\"\n name=\"categoryId\"\n [disabled]=\"loadingCategories\">\n <option [ngValue]=\"null\">(uncategorized)</option>\n @for (cat of categories; track cat.ID) {\n <option [ngValue]=\"cat.ID\">{{ cat.Name }}</option>\n }\n </select>\n </div>\n\n <div class=\"divider\"></div>\n\n <div class=\"lineage-section\">\n <div class=\"field__label\">Source lineage</div>\n <label class=\"lineage-option\" [class.lineage-option--selected]=\"rememberLineage\">\n <input\n type=\"radio\"\n name=\"lineage\"\n [checked]=\"rememberLineage\"\n (change)=\"OnLineageChange(true)\" />\n <div>\n <div class=\"lineage-option__title\">Remember source view (recommended)</div>\n <div class=\"lineage-option__desc\">\n Stores <code>SourceViewID</code> and (optionally) the current filter. Enables\n <strong>Refresh from source</strong> later. You'll choose Additive or Sync each refresh.\n </div>\n </div>\n </label>\n <label class=\"lineage-option\" [class.lineage-option--selected]=\"!rememberLineage\">\n <input\n type=\"radio\"\n name=\"lineage\"\n [checked]=\"!rememberLineage\"\n (change)=\"OnLineageChange(false)\" />\n <div>\n <div class=\"lineage-option__title\">One-time snapshot</div>\n <div class=\"lineage-option__desc\">\n No lineage stored. List is fully static; later changes to the view do not propagate.\n </div>\n </div>\n </label>\n </div>\n\n @if (rememberLineage) {\n <div class=\"field--inline\">\n <input\n id=\"save-view-freeze\"\n type=\"checkbox\"\n [(ngModel)]=\"useSnapshot\"\n name=\"useSnapshot\" />\n <label for=\"save-view-freeze\">\n Freeze filter at current value\n <span class=\"muted\">\n (<code>UseSnapshot = true</code>) \u2014 refresh re-runs the saved filter, even if the view is later edited\n </span>\n </label>\n </div>\n\n <div class=\"field\">\n <label class=\"field__label\" for=\"save-view-mode\">Default refresh mode</label>\n <select\n id=\"save-view-mode\"\n class=\"mj-input mj-select\"\n [(ngModel)]=\"refreshMode\"\n name=\"refreshMode\">\n <option value=\"Additive\">Additive \u2014 only adds new records on refresh</option>\n <option value=\"Sync\">Sync \u2014 reconciles in both directions (may remove records)</option>\n </select>\n </div>\n }\n </form>\n\n <mj-dialog-actions>\n <button mjButton variant=\"primary\" type=\"button\" [disabled]=\"!canSave\" (click)=\"OnSave()\">\n <i class=\"fa-solid fa-check\"></i>\n {{ confirmButtonLabel }}\n </button>\n <button mjButton variant=\"outline\" type=\"button\" (click)=\"OnCancel()\">Cancel</button>\n </mj-dialog-actions>\n </mj-dialog>\n}\n", styles: [":host {\n display: contents;\n}\n\n.save-view-form {\n padding: 16px 20px 8px;\n display: flex;\n flex-direction: column;\n gap: 14px;\n color: var(--mj-text-primary);\n font-size: 13px;\n}\n\n\n.field {\n display: flex;\n flex-direction: column;\n gap: 6px;\n}\n\n.field__label {\n font-size: 11px;\n letter-spacing: 0.04em;\n text-transform: uppercase;\n color: var(--mj-text-muted);\n}\n\n.field--inline {\n display: flex;\n align-items: flex-start;\n gap: 10px;\n font-size: 12.5px;\n}\n\n.field--inline input[type='checkbox'] {\n margin-top: 3px;\n cursor: pointer;\n}\n\n.divider {\n height: 1px;\n background: var(--mj-border-default);\n margin: 4px 0;\n}\n\n.lineage-section {\n display: flex;\n flex-direction: column;\n gap: 8px;\n}\n\n.lineage-option {\n display: flex;\n align-items: flex-start;\n gap: 10px;\n padding: 10px;\n border: 1px solid var(--mj-border-default);\n border-radius: 8px;\n cursor: pointer;\n background: var(--mj-bg-surface);\n}\n\n.lineage-option--selected {\n border-color: var(--mj-brand-primary);\n background: color-mix(in srgb, var(--mj-brand-primary) 6%, var(--mj-bg-surface));\n}\n\n.lineage-option input[type='radio'] {\n margin-top: 3px;\n cursor: pointer;\n}\n\n.lineage-option__title {\n font-weight: 600;\n font-size: 13px;\n}\n\n.lineage-option__desc {\n font-size: 12px;\n color: var(--mj-text-muted);\n margin-top: 2px;\n line-height: 1.5;\n}\n\n.muted {\n color: var(--mj-text-muted);\n}\n"] }]
302
300
  }], null, { Visible: [{
303
301
  type: Input
304
302
  }], ViewId: [{
@@ -1 +1 @@
1
- {"version":3,"file":"save-view-as-list-dialog.component.js","sourceRoot":"","sources":["../../../../src/lib/components/save-view-as-list-dialog/save-view-as-list-dialog.component.ts","../../../../src/lib/components/save-view-as-list-dialog/save-view-as-list-dialog.component.html"],"names":[],"mappings":"AAAA,OAAO,EAAE,uBAAuB,EAAE,iBAAiB,EAAE,SAAS,EAAE,YAAY,EAAE,KAAK,EAAU,MAAM,EAAE,MAAM,EAAE,MAAM,eAAe,CAAC;AAEnI,OAAO,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAC;AACrE,OAAO,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;;;;;;ICSnC,8BAAQ;IAAA,YAAyB;IAAA,iBAAS;;;IAAlC,cAAyB;IAAzB,yDAAyB;;;IAEjC,8BAAQ;IAAA,4BAAY;IAAA,iBAAS;;;IAG7B,sBAAK;IAAA,8BAAQ;IAAA,YAAc;IAAA,iBAAS;;;IAAvB,eAAc;IAAd,qCAAc;;;IAqC3B,kCAA2B;IAAA,YAAc;IAAA,iBAAS;;;IAA1C,mCAAkB;IAAC,cAAc;IAAd,iCAAc;;;;IAwC3C,AADF,+BAA2B,gBAKF;IADrB,2UAAyB;IAH3B,iBAIuB;IACvB,iCAA8B;IAC5B,g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,SAAS;QACf,IAAI,CAAC,QAAQ,GAAG,IAAI,CAAC,QAAQ,CAAC,CAAC,CAAC,GAAG,IAAI,CAAC,QAAQ,eAAe,IAAI,IAAI,EAAE,CAAC,WAAW,EAAE,CAAC,KAAK,CAAC,CAAC,EAAE,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;QAC5G,IAAI,CAAC,WAAW,GAAG,EAAE,CAAC;QACtB,IAAI,CAAC,UAAU,GAAG,IAAI,CAAC;QACvB,IAAI,CAAC,eAAe,GAAG,IAAI,CAAC;QAC5B,IAAI,CAAC,WAAW,GAAG,IAAI,CAAC;QACxB,IAAI,CAAC,WAAW,GAAG,UAAU,CAAC;QAC9B,IAAI,CAAC,UAAU,GAAG,KAAK,CAAC;IAC1B,CAAC;iSA5GU,6BAA6B,yBAA7B,6BAA6B;6DAA7B,6BAA6B;YCtC1C,uGAAe;;YAAf,sCAiIC;;;iFD3FY,6BAA6B;cAPzC,SAAS;6BACI,KAAK,YACP,6BAA6B,mBAGtB,uBAAuB,CAAC,MAAM;;kBAM9C,KAAK;;kBAWL,KAAK;;kBAGL,KAAK;;kBAGL,KAAK;;kBAEL,MAAM;;kBACN,MAAM;;kFAxBI,6BAA6B","sourcesContent":["import { ChangeDetectionStrategy, ChangeDetectorRef, Component, EventEmitter, Input, OnInit, Output, inject } from '@angular/core';\n\nimport { BaseAngularComponent } from '@memberjunction/ng-base-types';\nimport { RunView } from '@memberjunction/core';\nimport { MJListCategoryEntity } from '@memberjunction/core-entities';\n\n/**\n * Form payload emitted when the user clicks Save. The parent component is\n * responsible for calling `GraphQLListsClient.MaterializeFromView` with these\n * options — we keep the dialog generic so it doesn't have to know about the\n * GraphQL transport.\n */\nexport interface SaveViewAsListResult {\n ListName: string;\n Description?: string;\n CategoryId?: string;\n RememberLineage: boolean;\n UseSnapshot: boolean;\n RefreshMode: 'Additive' | 'Sync';\n}\n\n/**\n * Dialog for materializing a User View into a new static List. Matches\n * mockup `09-save-view-as-list.html`: name + description + category, then\n * a radio group for source-lineage (remember vs one-time snapshot), then a\n * \"freeze filter\" checkbox that maps to `UseSnapshot` on the list.\n *\n * The dialog is reusable — pass `ViewId` + `ViewName` + the displayed\n * record count and listen for `Save` / `Cancel`. Multi-provider safe via\n * `BaseAngularComponent.ProviderToUse`.\n */\n@Component({\n standalone: false,\n selector: 'mj-save-view-as-list-dialog',\n templateUrl: './save-view-as-list-dialog.component.html',\n styleUrls: ['./save-view-as-list-dialog.component.css'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class SaveViewAsListDialogComponent extends BaseAngularComponent implements OnInit {\n private readonly cdr = inject(ChangeDetectorRef);\n\n /** Visibility toggle, getter/setter so opening resets the form. */\n @Input()\n get Visible(): boolean {\n return this._visible;\n }\n set Visible(value: boolean) {\n if (value && !this._visible) this.resetForm();\n this._visible = value;\n }\n private _visible = false;\n\n /** Required — the User View we're materializing from. */\n @Input() ViewId: string | null = null;\n\n /** Display name of the source view (shown in the info banner + default list name). */\n @Input() ViewName: string | null = null;\n\n /** Optional — record count shown in the button label + info banner. */\n @Input() RecordCount: number | null = null;\n\n @Output() Save = new EventEmitter<SaveViewAsListResult>();\n @Output() Cancel = new EventEmitter<void>();\n\n public listName = '';\n public description = '';\n public categoryId: string | null = null;\n public rememberLineage = true;\n public useSnapshot = true;\n public refreshMode: 'Additive' | 'Sync' = 'Additive';\n\n public categories: MJListCategoryEntity[] = [];\n public loadingCategories = false;\n public submitting = false;\n\n async ngOnInit(): Promise<void> {\n await this.loadCategories();\n }\n\n public OnSave(): void {\n if (!this.canSave) return;\n this.submitting = true;\n const payload: SaveViewAsListResult = {\n ListName: this.listName.trim(),\n Description: this.description.trim() || undefined,\n CategoryId: this.categoryId ?? undefined,\n RememberLineage: this.rememberLineage,\n // UseSnapshot only meaningful when lineage is remembered.\n UseSnapshot: this.rememberLineage && this.useSnapshot,\n RefreshMode: this.refreshMode,\n };\n this.Save.emit(payload);\n }\n\n public OnCancel(): void {\n this.Cancel.emit();\n }\n\n public OnLineageChange(remember: boolean): void {\n this.rememberLineage = remember;\n // If lineage is off, snapshot has no meaning — keep the checkbox state\n // intact so re-enabling lineage restores it, but the emitted payload\n // forces UseSnapshot=false (see `OnSave`).\n }\n\n public get canSave(): boolean {\n return !!this.ViewId && this.listName.trim().length > 0 && !this.submitting;\n }\n\n public get confirmButtonLabel(): string {\n if (this.submitting) return 'Saving...';\n if (this.RecordCount != null) return `Save List (${this.RecordCount} records)`;\n return 'Save List';\n }\n\n /**\n * Load list categories for the category dropdown. Multi-provider safe.\n * Failures degrade gracefully — the dropdown just shows \"Uncategorized\"\n * and we log so the user can troubleshoot.\n */\n private async loadCategories(): Promise<void> {\n this.loadingCategories = true;\n try {\n const rv = RunView.FromMetadataProvider(this.ProviderToUse);\n const result = await rv.RunView<MJListCategoryEntity>({\n EntityName: 'MJ: List Categories',\n OrderBy: 'Name ASC',\n ResultType: 'entity_object',\n });\n if (result.Success) {\n this.categories = result.Results ?? [];\n }\n } finally {\n this.loadingCategories = false;\n this.cdr.markForCheck();\n }\n }\n\n private resetForm(): void {\n this.listName = this.ViewName ? `${this.ViewName} — Snapshot ${new Date().toISOString().slice(0, 10)}` : '';\n this.description = '';\n this.categoryId = null;\n this.rememberLineage = true;\n this.useSnapshot = true;\n this.refreshMode = 'Additive';\n this.submitting = false;\n }\n}\n","@if (Visible) {\n <mj-dialog\n [Visible]=\"true\"\n [Width]=\"560\"\n Title=\"Save View Results as List\"\n (Close)=\"OnCancel()\">\n <form class=\"save-view-form\" (submit)=\"$event.preventDefault(); OnSave()\">\n <div class=\"info-banner\">\n <i class=\"fa-solid fa-circle-info\"></i>\n <div>\n Materializes\n @if (RecordCount != null) {\n <strong>{{ RecordCount }} records</strong>\n } @else {\n <strong>view results</strong>\n }\n @if (ViewName) {\n from <strong>{{ ViewName }}</strong>\n }\n into a static List. The list can be refreshed from this view later if you keep lineage on.\n </div>\n </div>\n\n <div class=\"field\">\n <label class=\"field__label\" for=\"save-view-list-name\">List name</label>\n <input\n id=\"save-view-list-name\"\n class=\"mj-input\"\n [(ngModel)]=\"listName\"\n name=\"listName\"\n required\n autofocus />\n </div>\n\n <div class=\"field\">\n <label class=\"field__label\" for=\"save-view-description\">Description</label>\n <textarea\n id=\"save-view-description\"\n class=\"mj-input\"\n [(ngModel)]=\"description\"\n name=\"description\"\n rows=\"2\"></textarea>\n </div>\n\n <div class=\"field\">\n <label class=\"field__label\" for=\"save-view-category\">Category</label>\n <select\n id=\"save-view-category\"\n class=\"mj-input mj-select\"\n [(ngModel)]=\"categoryId\"\n name=\"categoryId\"\n [disabled]=\"loadingCategories\">\n <option [ngValue]=\"null\">(uncategorized)</option>\n @for (cat of categories; track cat.ID) {\n <option [ngValue]=\"cat.ID\">{{ cat.Name }}</option>\n }\n </select>\n </div>\n\n <div class=\"divider\"></div>\n\n <div class=\"lineage-section\">\n <div class=\"field__label\">Source lineage</div>\n <label class=\"lineage-option\" [class.lineage-option--selected]=\"rememberLineage\">\n <input\n type=\"radio\"\n name=\"lineage\"\n [checked]=\"rememberLineage\"\n (change)=\"OnLineageChange(true)\" />\n <div>\n <div class=\"lineage-option__title\">Remember source view (recommended)</div>\n <div class=\"lineage-option__desc\">\n Stores <code>SourceViewID</code> and (optionally) the current filter. Enables\n <strong>Refresh from source</strong> later. You'll choose Additive or Sync each refresh.\n </div>\n </div>\n </label>\n <label class=\"lineage-option\" [class.lineage-option--selected]=\"!rememberLineage\">\n <input\n type=\"radio\"\n name=\"lineage\"\n [checked]=\"!rememberLineage\"\n (change)=\"OnLineageChange(false)\" />\n <div>\n <div class=\"lineage-option__title\">One-time snapshot</div>\n <div class=\"lineage-option__desc\">\n No lineage stored. List is fully static; later changes to the view do not propagate.\n </div>\n </div>\n </label>\n </div>\n\n @if (rememberLineage) {\n <div class=\"field--inline\">\n <input\n id=\"save-view-freeze\"\n type=\"checkbox\"\n [(ngModel)]=\"useSnapshot\"\n name=\"useSnapshot\" />\n <label for=\"save-view-freeze\">\n Freeze filter at current value\n <span class=\"muted\">\n (<code>UseSnapshot = true</code>) — refresh re-runs the saved filter, even if the view is later edited\n </span>\n </label>\n </div>\n\n <div class=\"field\">\n <label class=\"field__label\" for=\"save-view-mode\">Default refresh mode</label>\n <select\n id=\"save-view-mode\"\n class=\"mj-input mj-select\"\n [(ngModel)]=\"refreshMode\"\n name=\"refreshMode\">\n <option value=\"Additive\">Additive — only adds new records on refresh</option>\n <option value=\"Sync\">Sync — reconciles in both directions (may remove records)</option>\n </select>\n </div>\n }\n </form>\n\n <mj-dialog-actions>\n <button mjButton variant=\"primary\" type=\"button\" [disabled]=\"!canSave\" (click)=\"OnSave()\">\n <i class=\"fa-solid fa-check\"></i>\n {{ confirmButtonLabel }}\n </button>\n <button mjButton variant=\"outline\" type=\"button\" (click)=\"OnCancel()\">Cancel</button>\n </mj-dialog-actions>\n </mj-dialog>\n}\n"]}
1
+ {"version":3,"file":"save-view-as-list-dialog.component.js","sourceRoot":"","sources":["../../../../src/lib/components/save-view-as-list-dialog/save-view-as-list-dialog.component.ts","../../../../src/lib/components/save-view-as-list-dialog/save-view-as-list-dialog.component.html"],"names":[],"mappings":"AAAA,OAAO,EAAE,uBAAuB,EAAE,iBAAiB,EAAE,SAAS,EAAE,YAAY,EAAE,KAAK,EAAU,MAAM,EAAE,MAAM,EAAE,MAAM,eAAe,CAAC;AAEnI,OAAO,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAC;AACrE,OAAO,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;;;;;;ICQnC,8BAAQ;IAAA,YAAyB;IAAA,iBAAS;;;IAAlC,cAAyB;IAAzB,yDAAyB;;;IAEjC,8BAAQ;IAAA,4BAAY;IAAA,iBAAS;;;IAG7B,sBAAK;IAAA,8BAAQ;IAAA,YAAc;IAAA,iBAAS;;;IAAvB,eAAc;IAAd,qCAAc;;;IAqC3B,kCAA2B;IAAA,YAAc;IAAA,iBAAS;;;IAA1C,mCAAkB;IAAC,cAAc;IAAd,iCA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IAAI,CAAC,GAAG,CAAC,YAAY,EAAE,CAAC;QAC1B,CAAC;IACH,CAAC;IAEO,SAAS;QACf,IAAI,CAAC,QAAQ,GAAG,IAAI,CAAC,QAAQ,CAAC,CAAC,CAAC,GAAG,IAAI,CAAC,QAAQ,eAAe,IAAI,IAAI,EAAE,CAAC,WAAW,EAAE,CAAC,KAAK,CAAC,CAAC,EAAE,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;QAC5G,IAAI,CAAC,WAAW,GAAG,EAAE,CAAC;QACtB,IAAI,CAAC,UAAU,GAAG,IAAI,CAAC;QACvB,IAAI,CAAC,eAAe,GAAG,IAAI,CAAC;QAC5B,IAAI,CAAC,WAAW,GAAG,IAAI,CAAC;QACxB,IAAI,CAAC,WAAW,GAAG,UAAU,CAAC;QAC9B,IAAI,CAAC,UAAU,GAAG,KAAK,CAAC;IAC1B,CAAC;iSA5GU,6BAA6B,yBAA7B,6BAA6B;6DAA7B,6BAA6B;YCtC1C,uGAAe;;YAAf,sCAgIC;;;iFD1FY,6BAA6B;cAPzC,SAAS;6BACI,KAAK,YACP,6BAA6B,mBAGtB,uBAAuB,CAAC,MAAM;;kBAM9C,KAAK;;kBAWL,KAAK;;kBAGL,KAAK;;kBAGL,KAAK;;kBAEL,MAAM;;kBACN,MAAM;;kFAxBI,6BAA6B","sourcesContent":["import { ChangeDetectionStrategy, ChangeDetectorRef, Component, EventEmitter, Input, OnInit, Output, inject } from '@angular/core';\n\nimport { BaseAngularComponent } from '@memberjunction/ng-base-types';\nimport { RunView } from '@memberjunction/core';\nimport { MJListCategoryEntity } from '@memberjunction/core-entities';\n\n/**\n * Form payload emitted when the user clicks Save. The parent component is\n * responsible for calling `GraphQLListsClient.MaterializeFromView` with these\n * options — we keep the dialog generic so it doesn't have to know about the\n * GraphQL transport.\n */\nexport interface SaveViewAsListResult {\n ListName: string;\n Description?: string;\n CategoryId?: string;\n RememberLineage: boolean;\n UseSnapshot: boolean;\n RefreshMode: 'Additive' | 'Sync';\n}\n\n/**\n * Dialog for materializing a User View into a new static List. Matches\n * mockup `09-save-view-as-list.html`: name + description + category, then\n * a radio group for source-lineage (remember vs one-time snapshot), then a\n * \"freeze filter\" checkbox that maps to `UseSnapshot` on the list.\n *\n * The dialog is reusable — pass `ViewId` + `ViewName` + the displayed\n * record count and listen for `Save` / `Cancel`. Multi-provider safe via\n * `BaseAngularComponent.ProviderToUse`.\n */\n@Component({\n standalone: false,\n selector: 'mj-save-view-as-list-dialog',\n templateUrl: './save-view-as-list-dialog.component.html',\n styleUrls: ['./save-view-as-list-dialog.component.css'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class SaveViewAsListDialogComponent extends BaseAngularComponent implements OnInit {\n private readonly cdr = inject(ChangeDetectorRef);\n\n /** Visibility toggle, getter/setter so opening resets the form. */\n @Input()\n get Visible(): boolean {\n return this._visible;\n }\n set Visible(value: boolean) {\n if (value && !this._visible) this.resetForm();\n this._visible = value;\n }\n private _visible = false;\n\n /** Required — the User View we're materializing from. */\n @Input() ViewId: string | null = null;\n\n /** Display name of the source view (shown in the info banner + default list name). */\n @Input() ViewName: string | null = null;\n\n /** Optional — record count shown in the button label + info banner. */\n @Input() RecordCount: number | null = null;\n\n @Output() Save = new EventEmitter<SaveViewAsListResult>();\n @Output() Cancel = new EventEmitter<void>();\n\n public listName = '';\n public description = '';\n public categoryId: string | null = null;\n public rememberLineage = true;\n public useSnapshot = true;\n public refreshMode: 'Additive' | 'Sync' = 'Additive';\n\n public categories: MJListCategoryEntity[] = [];\n public loadingCategories = false;\n public submitting = false;\n\n async ngOnInit(): Promise<void> {\n await this.loadCategories();\n }\n\n public OnSave(): void {\n if (!this.canSave) return;\n this.submitting = true;\n const payload: SaveViewAsListResult = {\n ListName: this.listName.trim(),\n Description: this.description.trim() || undefined,\n CategoryId: this.categoryId ?? undefined,\n RememberLineage: this.rememberLineage,\n // UseSnapshot only meaningful when lineage is remembered.\n UseSnapshot: this.rememberLineage && this.useSnapshot,\n RefreshMode: this.refreshMode,\n };\n this.Save.emit(payload);\n }\n\n public OnCancel(): void {\n this.Cancel.emit();\n }\n\n public OnLineageChange(remember: boolean): void {\n this.rememberLineage = remember;\n // If lineage is off, snapshot has no meaning — keep the checkbox state\n // intact so re-enabling lineage restores it, but the emitted payload\n // forces UseSnapshot=false (see `OnSave`).\n }\n\n public get canSave(): boolean {\n return !!this.ViewId && this.listName.trim().length > 0 && !this.submitting;\n }\n\n public get confirmButtonLabel(): string {\n if (this.submitting) return 'Saving...';\n if (this.RecordCount != null) return `Save List (${this.RecordCount} records)`;\n return 'Save List';\n }\n\n /**\n * Load list categories for the category dropdown. Multi-provider safe.\n * Failures degrade gracefully — the dropdown just shows \"Uncategorized\"\n * and we log so the user can troubleshoot.\n */\n private async loadCategories(): Promise<void> {\n this.loadingCategories = true;\n try {\n const rv = RunView.FromMetadataProvider(this.ProviderToUse);\n const result = await rv.RunView<MJListCategoryEntity>({\n EntityName: 'MJ: List Categories',\n OrderBy: 'Name ASC',\n ResultType: 'entity_object',\n });\n if (result.Success) {\n this.categories = result.Results ?? [];\n }\n } finally {\n this.loadingCategories = false;\n this.cdr.markForCheck();\n }\n }\n\n private resetForm(): void {\n this.listName = this.ViewName ? `${this.ViewName} — Snapshot ${new Date().toISOString().slice(0, 10)}` : '';\n this.description = '';\n this.categoryId = null;\n this.rememberLineage = true;\n this.useSnapshot = true;\n this.refreshMode = 'Additive';\n this.submitting = false;\n }\n}\n","@if (Visible) {\n <mj-dialog\n [Visible]=\"true\"\n [Width]=\"560\"\n Title=\"Save View Results as List\"\n (Close)=\"OnCancel()\">\n <form class=\"save-view-form\" (submit)=\"$event.preventDefault(); OnSave()\">\n <mj-alert Variant=\"info\">\n <div>\n Materializes\n @if (RecordCount != null) {\n <strong>{{ RecordCount }} records</strong>\n } @else {\n <strong>view results</strong>\n }\n @if (ViewName) {\n from <strong>{{ ViewName }}</strong>\n }\n into a static List. The list can be refreshed from this view later if you keep lineage on.\n </div>\n </mj-alert>\n\n <div class=\"field\">\n <label class=\"field__label\" for=\"save-view-list-name\">List name</label>\n <input\n id=\"save-view-list-name\"\n class=\"mj-input\"\n [(ngModel)]=\"listName\"\n name=\"listName\"\n required\n autofocus />\n </div>\n\n <div class=\"field\">\n <label class=\"field__label\" for=\"save-view-description\">Description</label>\n <textarea\n id=\"save-view-description\"\n class=\"mj-input\"\n [(ngModel)]=\"description\"\n name=\"description\"\n rows=\"2\"></textarea>\n </div>\n\n <div class=\"field\">\n <label class=\"field__label\" for=\"save-view-category\">Category</label>\n <select\n id=\"save-view-category\"\n class=\"mj-input mj-select\"\n [(ngModel)]=\"categoryId\"\n name=\"categoryId\"\n [disabled]=\"loadingCategories\">\n <option [ngValue]=\"null\">(uncategorized)</option>\n @for (cat of categories; track cat.ID) {\n <option [ngValue]=\"cat.ID\">{{ cat.Name }}</option>\n }\n </select>\n </div>\n\n <div class=\"divider\"></div>\n\n <div class=\"lineage-section\">\n <div class=\"field__label\">Source lineage</div>\n <label class=\"lineage-option\" [class.lineage-option--selected]=\"rememberLineage\">\n <input\n type=\"radio\"\n name=\"lineage\"\n [checked]=\"rememberLineage\"\n (change)=\"OnLineageChange(true)\" />\n <div>\n <div class=\"lineage-option__title\">Remember source view (recommended)</div>\n <div class=\"lineage-option__desc\">\n Stores <code>SourceViewID</code> and (optionally) the current filter. Enables\n <strong>Refresh from source</strong> later. You'll choose Additive or Sync each refresh.\n </div>\n </div>\n </label>\n <label class=\"lineage-option\" [class.lineage-option--selected]=\"!rememberLineage\">\n <input\n type=\"radio\"\n name=\"lineage\"\n [checked]=\"!rememberLineage\"\n (change)=\"OnLineageChange(false)\" />\n <div>\n <div class=\"lineage-option__title\">One-time snapshot</div>\n <div class=\"lineage-option__desc\">\n No lineage stored. List is fully static; later changes to the view do not propagate.\n </div>\n </div>\n </label>\n </div>\n\n @if (rememberLineage) {\n <div class=\"field--inline\">\n <input\n id=\"save-view-freeze\"\n type=\"checkbox\"\n [(ngModel)]=\"useSnapshot\"\n name=\"useSnapshot\" />\n <label for=\"save-view-freeze\">\n Freeze filter at current value\n <span class=\"muted\">\n (<code>UseSnapshot = true</code>) — refresh re-runs the saved filter, even if the view is later edited\n </span>\n </label>\n </div>\n\n <div class=\"field\">\n <label class=\"field__label\" for=\"save-view-mode\">Default refresh mode</label>\n <select\n id=\"save-view-mode\"\n class=\"mj-input mj-select\"\n [(ngModel)]=\"refreshMode\"\n name=\"refreshMode\">\n <option value=\"Additive\">Additive — only adds new records on refresh</option>\n <option value=\"Sync\">Sync — reconciles in both directions (may remove records)</option>\n </select>\n </div>\n }\n </form>\n\n <mj-dialog-actions>\n <button mjButton variant=\"primary\" type=\"button\" [disabled]=\"!canSave\" (click)=\"OnSave()\">\n <i class=\"fa-solid fa-check\"></i>\n {{ confirmButtonLabel }}\n </button>\n <button mjButton variant=\"outline\" type=\"button\" (click)=\"OnCancel()\">Cancel</button>\n </mj-dialog-actions>\n </mj-dialog>\n}\n"]}
@@ -20,7 +20,7 @@ import * as i16 from "@memberjunction/ng-shared-generic";
20
20
  */
21
21
  export declare class ListManagementModule {
22
22
  static ɵfac: i0.ɵɵFactoryDeclaration<ListManagementModule, never>;
23
- static ɵmod: i0.ɵɵNgModuleDeclaration<ListManagementModule, [typeof i1.AudienceSourcePickerComponent, typeof i2.AudienceSourceSummaryComponent, typeof i3.ListAuditLogComponent, typeof i4.ListDeltaConfirmComponent, typeof i5.ListInvitationsComponent, typeof i6.ListManagementDialogComponent, typeof i7.ListShareDialogComponent, typeof i8.ListStatsComponent, typeof i9.ListsSharedWithMeComponent, typeof i10.SaveViewAsListDialogComponent, typeof i11.TagChipsComponent], [typeof i12.CommonModule, typeof i13.FormsModule, typeof i14.MJButtonDirective, typeof i14.MJDialogComponent, typeof i14.MJDialogActionsComponent, typeof i14.MJDropdownComponent, typeof i15.ContainerDirectivesModule, typeof i16.SharedGenericModule], [typeof i1.AudienceSourcePickerComponent, typeof i2.AudienceSourceSummaryComponent, typeof i3.ListAuditLogComponent, typeof i4.ListDeltaConfirmComponent, typeof i5.ListInvitationsComponent, typeof i6.ListManagementDialogComponent, typeof i7.ListShareDialogComponent, typeof i8.ListStatsComponent, typeof i9.ListsSharedWithMeComponent, typeof i10.SaveViewAsListDialogComponent, typeof i11.TagChipsComponent]>;
23
+ static ɵmod: i0.ɵɵNgModuleDeclaration<ListManagementModule, [typeof i1.AudienceSourcePickerComponent, typeof i2.AudienceSourceSummaryComponent, typeof i3.ListAuditLogComponent, typeof i4.ListDeltaConfirmComponent, typeof i5.ListInvitationsComponent, typeof i6.ListManagementDialogComponent, typeof i7.ListShareDialogComponent, typeof i8.ListStatsComponent, typeof i9.ListsSharedWithMeComponent, typeof i10.SaveViewAsListDialogComponent, typeof i11.TagChipsComponent], [typeof i12.CommonModule, typeof i13.FormsModule, typeof i14.MJButtonDirective, typeof i14.MJDialogComponent, typeof i14.MJDialogActionsComponent, typeof i14.MJDropdownComponent, typeof i14.MJEmptyStateComponent, typeof i14.MJAlertComponent, typeof i15.ContainerDirectivesModule, typeof i16.SharedGenericModule], [typeof i1.AudienceSourcePickerComponent, typeof i2.AudienceSourceSummaryComponent, typeof i3.ListAuditLogComponent, typeof i4.ListDeltaConfirmComponent, typeof i5.ListInvitationsComponent, typeof i6.ListManagementDialogComponent, typeof i7.ListShareDialogComponent, typeof i8.ListStatsComponent, typeof i9.ListsSharedWithMeComponent, typeof i10.SaveViewAsListDialogComponent, typeof i11.TagChipsComponent]>;
24
24
  static ɵinj: i0.ɵɵInjectorDeclaration<ListManagementModule>;
25
25
  }
26
26
  //# sourceMappingURL=module.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"module.d.ts","sourceRoot":"","sources":["../../src/lib/module.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;AAiCA;;GAEG;AACH,qBA0Ca,oBAAoB;yCAApB,oBAAoB;0CAApB,oBAAoB;0CAApB,oBAAoB;CAAI"}
1
+ {"version":3,"file":"module.d.ts","sourceRoot":"","sources":["../../src/lib/module.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;AAmCA;;GAEG;AACH,qBA4Ca,oBAAoB;yCAApB,oBAAoB;0CAApB,oBAAoB;0CAApB,oBAAoB;CAAI"}