osi-cards-lib 1.5.50 → 1.5.51

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.
@@ -2,7 +2,7 @@ import * as i1 from '@angular/common';
2
2
  import { CommonModule } from '@angular/common';
3
3
  import * as i0 from '@angular/core';
4
4
  import { signal, Injectable, inject, Component } from '@angular/core';
5
- import { B as BaseSectionComponent, S as SectionLayoutPreferenceService, a as SectionHeaderComponent, E as EmptyStateComponent, L as LucideIconsModule } from './osi-cards-lib-osi-cards-lib-Cg-ENr-a.mjs';
5
+ import { B as BaseSectionComponent, S as SectionLayoutPreferenceService, a as SectionHeaderComponent, E as EmptyStateComponent, L as LucideIconsModule } from './osi-cards-lib-osi-cards-lib-BLZhabZB.mjs';
6
6
  import * as i2 from 'lucide-angular';
7
7
 
8
8
  /**
@@ -260,4 +260,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.14", ngImpo
260
260
  }] });
261
261
 
262
262
  export { OverviewSectionComponent };
263
- //# sourceMappingURL=osi-cards-lib-overview-section.component-BcpudPjx.mjs.map
263
+ //# sourceMappingURL=osi-cards-lib-overview-section.component-B_Sgus2D.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"osi-cards-lib-overview-section.component-BcpudPjx.mjs","sources":["../../../projects/osi-cards-lib/src/lib/services/clipboard.service.ts","../../../projects/osi-cards-lib/src/lib/components/sections/overview-section/overview-section.component.ts","../../../projects/osi-cards-lib/src/lib/components/sections/overview-section/overview-section.component.html"],"sourcesContent":["/**\n * Clipboard Service\n *\n * Enhanced clipboard service with history and formatting.\n *\n * @example\n * ```typescript\n * const clipboard = inject(ClipboardService);\n *\n * await clipboard.copy('Hello World');\n * const text = await clipboard.paste();\n * const history = clipboard.getHistory();\n * ```\n */\n\nimport { Injectable, signal } from '@angular/core';\n\nexport interface ClipboardEntry {\n text: string;\n timestamp: Date;\n type: 'text' | 'html' | 'image';\n}\n\n@Injectable({\n providedIn: 'root',\n})\nexport class ClipboardService {\n private history = signal<ClipboardEntry[]>([]);\n private maxHistory = 10;\n\n /**\n * Copy text to clipboard\n */\n async copy(text: string): Promise<void> {\n try {\n await navigator.clipboard.writeText(text);\n this.addToHistory(text, 'text');\n } catch (error) {\n this.fallbackCopy(text);\n this.addToHistory(text, 'text');\n }\n }\n\n /**\n * Copy HTML to clipboard\n */\n async copyHTML(html: string, plainText: string): Promise<void> {\n try {\n const blob = new Blob([html], { type: 'text/html' });\n const data = [new ClipboardItem({ 'text/html': blob })];\n await navigator.clipboard.write(data);\n this.addToHistory(plainText, 'html');\n } catch (error) {\n await this.copy(plainText);\n }\n }\n\n /**\n * Paste from clipboard\n */\n async paste(): Promise<string> {\n try {\n return await navigator.clipboard.readText();\n } catch (error) {\n throw new Error('Clipboard read permission denied');\n }\n }\n\n /**\n * Copy element content\n */\n async copyElement(element: HTMLElement): Promise<void> {\n const text = element.textContent || '';\n await this.copy(text);\n }\n\n /**\n * Get clipboard history\n */\n getHistory(): ClipboardEntry[] {\n return this.history();\n }\n\n /**\n * Clear history\n */\n clearHistory(): void {\n this.history.set([]);\n }\n\n /**\n * Add to history\n */\n private addToHistory(text: string, type: ClipboardEntry['type']): void {\n this.history.update((history) => {\n const entry: ClipboardEntry = {\n text,\n timestamp: new Date(),\n type,\n };\n\n const newHistory = [entry, ...history];\n return newHistory.slice(0, this.maxHistory);\n });\n }\n\n /**\n * Fallback copy method\n */\n private fallbackCopy(text: string): void {\n const textarea = document.createElement('textarea');\n textarea.value = text;\n textarea.style.position = 'fixed';\n textarea.style.opacity = '0';\n document.body.appendChild(textarea);\n textarea.select();\n document.execCommand('copy');\n document.body.removeChild(textarea);\n }\n\n /**\n * Check if clipboard API is available\n */\n isAvailable(): boolean {\n return !!(navigator.clipboard && navigator.clipboard.writeText);\n }\n}\n","import { CommonModule } from '@angular/common';\nimport { Component, OnInit, inject } from '@angular/core';\nimport { CardSection } from '../../../models';\nimport { ClipboardService } from '../../../services/clipboard.service';\nimport { SectionLayoutPreferenceService } from '../../../services/section-layout-preference.service';\nimport { LucideIconsModule } from '../../../icons';\nimport { EmptyStateComponent, SectionHeaderComponent } from '../../shared';\nimport { BaseSectionComponent, SectionLayoutPreferences } from '../base-section.component';\n\n/**\n * Overview Section Component\n *\n * Displays high-level summaries, executive dashboards, and key highlights.\n * Supports newline characters in field values for better text formatting.\n */\n@Component({\n selector: 'lib-overview-section',\n standalone: true,\n imports: [CommonModule, SectionHeaderComponent, EmptyStateComponent, LucideIconsModule],\n templateUrl: './overview-section.component.html',\n styleUrl: './overview-section.scss',\n})\nexport class OverviewSectionComponent extends BaseSectionComponent implements OnInit {\n private readonly layoutService = inject(SectionLayoutPreferenceService);\n private readonly clipboardService = inject(ClipboardService);\n\n ngOnInit(): void {\n // Register layout preference function for this section type\n this.layoutService.register('overview', (section: CardSection, availableColumns: number) => {\n return this.calculateOverviewLayoutPreferences(section, availableColumns);\n });\n }\n\n /**\n * Calculate layout preferences for overview section based on content.\n * Overview sections: 1 col default, can expand to 2\n */\n private calculateOverviewLayoutPreferences(\n section: CardSection,\n availableColumns: number\n ): SectionLayoutPreferences {\n const fields = section.fields ?? [];\n const fieldCount = fields.length;\n\n // Overview sections: 1 col default, can expand to 2\n let preferredColumns: 1 | 2 | 3 | 4 = 1;\n if (fieldCount >= 6) {\n preferredColumns = 2;\n }\n\n // Respect explicit preferences\n if (section.preferredColumns) {\n preferredColumns = section.preferredColumns;\n }\n\n preferredColumns = Math.min(preferredColumns, availableColumns) as 1 | 2 | 3 | 4;\n\n return {\n preferredColumns,\n minColumns: (section.minColumns ?? 1) as 1 | 2 | 3 | 4,\n maxColumns: Math.min((section.maxColumns ?? 2) as 1 | 2 | 3 | 4, availableColumns) as\n | 1\n | 2\n | 3\n | 4,\n canShrinkToFill: true,\n shrinkPriority: 15,\n expandOnContent: {\n fieldCount: 6, // Expand to 2 columns at 6+ fields\n },\n };\n }\n\n /**\n * Get layout preferences for overview section.\n */\n override getLayoutPreferences(availableColumns: number = 4): SectionLayoutPreferences {\n const servicePrefs = this.layoutService.getPreferences(this.section, availableColumns);\n if (servicePrefs) {\n return servicePrefs;\n }\n return this.calculateOverviewLayoutPreferences(this.section, availableColumns);\n }\n\n /**\n * Format field value, converting newlines to HTML breaks\n * For single text blocks (empty label), also style uppercase section headers\n */\n formatFieldValue(field: any): string {\n const value = this.getFieldValue(field);\n if (value === null || value === undefined) {\n return '';\n }\n const stringValue = String(value);\n\n // If this is a single text block (no label), style uppercase headers\n if (!field.label) {\n // Split by lines and process each line\n const lines = stringValue.split('\\n');\n const processedLines = lines.map((line, index) => {\n const trimmed = line.trim();\n // Check if line is an uppercase header (all caps, reasonable length, no lowercase letters)\n if (\n trimmed.length > 0 &&\n trimmed.length <= 50 &&\n trimmed === trimmed.toUpperCase() &&\n /^[A-Z\\s&•\\-]+$/.test(trimmed) &&\n trimmed.length >= 2\n ) {\n // This is a section header\n return `<span class=\"section-header\">${trimmed}</span>`;\n }\n return line;\n });\n // Convert newlines to <br> tags for HTML rendering\n return processedLines.join('<br>');\n }\n\n // Convert newlines to <br> tags for HTML rendering\n return stringValue.replace(/\\n/g, '<br>');\n }\n\n /**\n * Copy section content to clipboard\n */\n async onCopySection(): Promise<void> {\n if (!this.section.fields?.length) {\n return;\n }\n\n // Build text content from all fields\n const textParts: string[] = [];\n\n // Add title if available\n if (this.section.title) {\n textParts.push(this.section.title);\n }\n\n // Add description if available\n if (this.section.description) {\n textParts.push(this.section.description);\n }\n\n // Add field content\n this.section.fields.forEach((field) => {\n const value = this.getFieldValue(field);\n if (value !== null && value !== undefined) {\n const stringValue = String(value);\n if (field.label) {\n textParts.push(`${field.label}: ${stringValue}`);\n } else {\n textParts.push(stringValue);\n }\n }\n });\n\n const textToCopy = textParts.join('\\n\\n');\n\n try {\n await this.clipboardService.copy(textToCopy);\n } catch (error) {\n console.error('Failed to copy section content to clipboard', error);\n }\n }\n}\n","<div class=\"ai-section ai-section--overview section-content\">\n <button\n type=\"button\"\n class=\"overview-section-copy-btn\"\n [attr.aria-label]=\"'Copy section: ' + (section.title || 'Overview')\"\n title=\"Copy section content\"\n (click)=\"onCopySection()\"\n (keydown.enter)=\"onCopySection()\"\n (keydown.space)=\"$event.preventDefault(); onCopySection()\"\n >\n <lucide-icon name=\"copy\" [size]=\"12\" aria-hidden=\"true\"></lucide-icon>\n </button>\n <lib-section-header *ngIf=\"section.title\" [title]=\"section.title\" [description]=\"section.description\">\n </lib-section-header>\n\n <div class=\"overview-grid\" *ngIf=\"section.fields?.length\">\n <div class=\"overview-item\" *ngFor=\"let field of section.fields\" [class.overview-item--single-text]=\"!field.label\">\n <div class=\"overview-item__label\" *ngIf=\"field.label\">{{ field.label }}</div>\n <div\n class=\"overview-item__value\"\n [innerHTML]=\"formatFieldValue(field)\"\n [class.overview-item__value--single-text]=\"!field.label\"\n ></div>\n </div>\n </div>\n\n <lib-empty-state *ngIf=\"!section.fields?.length\" message=\"No overview data\" icon=\"📋\" variant=\"minimal\">\n </lib-empty-state>\n</div>\n"],"names":[],"mappings":";;;;;;;AAAA;;;;;;;;;;;;;AAaG;MAaU,gBAAgB,CAAA;AAH7B,IAAA,WAAA,GAAA;AAIU,QAAA,IAAA,CAAA,OAAO,GAAG,MAAM,CAAmB,EAAE,mDAAC;QACtC,IAAA,CAAA,UAAU,GAAG,EAAE;AAkGxB,IAAA;AAhGC;;AAEG;IACH,MAAM,IAAI,CAAC,IAAY,EAAA;AACrB,QAAA,IAAI;YACF,MAAM,SAAS,CAAC,SAAS,CAAC,SAAS,CAAC,IAAI,CAAC;AACzC,YAAA,IAAI,CAAC,YAAY,CAAC,IAAI,EAAE,MAAM,CAAC;QACjC;QAAE,OAAO,KAAK,EAAE;AACd,YAAA,IAAI,CAAC,YAAY,CAAC,IAAI,CAAC;AACvB,YAAA,IAAI,CAAC,YAAY,CAAC,IAAI,EAAE,MAAM,CAAC;QACjC;IACF;AAEA;;AAEG;AACH,IAAA,MAAM,QAAQ,CAAC,IAAY,EAAE,SAAi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../../../projects/osi-cards-lib/src/lib/services/clipboard.service.ts","../../../projects/osi-cards-lib/src/lib/components/sections/overview-section/overview-section.component.ts","../../../projects/osi-cards-lib/src/lib/components/sections/overview-section/overview-section.component.html"],"sourcesContent":["/**\n * Clipboard Service\n *\n * Enhanced clipboard service with history and formatting.\n *\n * @example\n * ```typescript\n * const clipboard = inject(ClipboardService);\n *\n * await clipboard.copy('Hello World');\n * const text = await clipboard.paste();\n * const history = clipboard.getHistory();\n * ```\n */\n\nimport { Injectable, signal } from '@angular/core';\n\nexport interface ClipboardEntry {\n text: string;\n timestamp: Date;\n type: 'text' | 'html' | 'image';\n}\n\n@Injectable({\n providedIn: 'root',\n})\nexport class ClipboardService {\n private history = signal<ClipboardEntry[]>([]);\n private maxHistory = 10;\n\n /**\n * Copy text to clipboard\n */\n async copy(text: string): Promise<void> {\n try {\n await navigator.clipboard.writeText(text);\n this.addToHistory(text, 'text');\n } catch (error) {\n this.fallbackCopy(text);\n this.addToHistory(text, 'text');\n }\n }\n\n /**\n * Copy HTML to clipboard\n */\n async copyHTML(html: string, plainText: string): Promise<void> {\n try {\n const blob = new Blob([html], { type: 'text/html' });\n const data = [new ClipboardItem({ 'text/html': blob })];\n await navigator.clipboard.write(data);\n this.addToHistory(plainText, 'html');\n } catch (error) {\n await this.copy(plainText);\n }\n }\n\n /**\n * Paste from clipboard\n */\n async paste(): Promise<string> {\n try {\n return await navigator.clipboard.readText();\n } catch (error) {\n throw new Error('Clipboard read permission denied');\n }\n }\n\n /**\n * Copy element content\n */\n async copyElement(element: HTMLElement): Promise<void> {\n const text = element.textContent || '';\n await this.copy(text);\n }\n\n /**\n * Get clipboard history\n */\n getHistory(): ClipboardEntry[] {\n return this.history();\n }\n\n /**\n * Clear history\n */\n clearHistory(): void {\n this.history.set([]);\n }\n\n /**\n * Add to history\n */\n private addToHistory(text: string, type: ClipboardEntry['type']): void {\n this.history.update((history) => {\n const entry: ClipboardEntry = {\n text,\n timestamp: new Date(),\n type,\n };\n\n const newHistory = [entry, ...history];\n return newHistory.slice(0, this.maxHistory);\n });\n }\n\n /**\n * Fallback copy method\n */\n private fallbackCopy(text: string): void {\n const textarea = document.createElement('textarea');\n textarea.value = text;\n textarea.style.position = 'fixed';\n textarea.style.opacity = '0';\n document.body.appendChild(textarea);\n textarea.select();\n document.execCommand('copy');\n document.body.removeChild(textarea);\n }\n\n /**\n * Check if clipboard API is available\n */\n isAvailable(): boolean {\n return !!(navigator.clipboard && navigator.clipboard.writeText);\n }\n}\n","import { CommonModule } from '@angular/common';\nimport { Component, OnInit, inject } from '@angular/core';\nimport { CardSection } from '../../../models';\nimport { ClipboardService } from '../../../services/clipboard.service';\nimport { SectionLayoutPreferenceService } from '../../../services/section-layout-preference.service';\nimport { LucideIconsModule } from '../../../icons';\nimport { EmptyStateComponent, SectionHeaderComponent } from '../../shared';\nimport { BaseSectionComponent, SectionLayoutPreferences } from '../base-section.component';\n\n/**\n * Overview Section Component\n *\n * Displays high-level summaries, executive dashboards, and key highlights.\n * Supports newline characters in field values for better text formatting.\n */\n@Component({\n selector: 'lib-overview-section',\n standalone: true,\n imports: [CommonModule, SectionHeaderComponent, EmptyStateComponent, LucideIconsModule],\n templateUrl: './overview-section.component.html',\n styleUrl: './overview-section.scss',\n})\nexport class OverviewSectionComponent extends BaseSectionComponent implements OnInit {\n private readonly layoutService = inject(SectionLayoutPreferenceService);\n private readonly clipboardService = inject(ClipboardService);\n\n ngOnInit(): void {\n // Register layout preference function for this section type\n this.layoutService.register('overview', (section: CardSection, availableColumns: number) => {\n return this.calculateOverviewLayoutPreferences(section, availableColumns);\n });\n }\n\n /**\n * Calculate layout preferences for overview section based on content.\n * Overview sections: 1 col default, can expand to 2\n */\n private calculateOverviewLayoutPreferences(\n section: CardSection,\n availableColumns: number\n ): SectionLayoutPreferences {\n const fields = section.fields ?? [];\n const fieldCount = fields.length;\n\n // Overview sections: 1 col default, can expand to 2\n let preferredColumns: 1 | 2 | 3 | 4 = 1;\n if (fieldCount >= 6) {\n preferredColumns = 2;\n }\n\n // Respect explicit preferences\n if (section.preferredColumns) {\n preferredColumns = section.preferredColumns;\n }\n\n preferredColumns = Math.min(preferredColumns, availableColumns) as 1 | 2 | 3 | 4;\n\n return {\n preferredColumns,\n minColumns: (section.minColumns ?? 1) as 1 | 2 | 3 | 4,\n maxColumns: Math.min((section.maxColumns ?? 2) as 1 | 2 | 3 | 4, availableColumns) as\n | 1\n | 2\n | 3\n | 4,\n canShrinkToFill: true,\n shrinkPriority: 15,\n expandOnContent: {\n fieldCount: 6, // Expand to 2 columns at 6+ fields\n },\n };\n }\n\n /**\n * Get layout preferences for overview section.\n */\n override getLayoutPreferences(availableColumns: number = 4): SectionLayoutPreferences {\n const servicePrefs = this.layoutService.getPreferences(this.section, availableColumns);\n if (servicePrefs) {\n return servicePrefs;\n }\n return this.calculateOverviewLayoutPreferences(this.section, availableColumns);\n }\n\n /**\n * Format field value, converting newlines to HTML breaks\n * For single text blocks (empty label), also style uppercase section headers\n */\n formatFieldValue(field: any): string {\n const value = this.getFieldValue(field);\n if (value === null || value === undefined) {\n return '';\n }\n const stringValue = String(value);\n\n // If this is a single text block (no label), style uppercase headers\n if (!field.label) {\n // Split by lines and process each line\n const lines = stringValue.split('\\n');\n const processedLines = lines.map((line, index) => {\n const trimmed = line.trim();\n // Check if line is an uppercase header (all caps, reasonable length, no lowercase letters)\n if (\n trimmed.length > 0 &&\n trimmed.length <= 50 &&\n trimmed === trimmed.toUpperCase() &&\n /^[A-Z\\s&•\\-]+$/.test(trimmed) &&\n trimmed.length >= 2\n ) {\n // This is a section header\n return `<span class=\"section-header\">${trimmed}</span>`;\n }\n return line;\n });\n // Convert newlines to <br> tags for HTML rendering\n return processedLines.join('<br>');\n }\n\n // Convert newlines to <br> tags for HTML rendering\n return stringValue.replace(/\\n/g, '<br>');\n }\n\n /**\n * Copy section content to clipboard\n */\n async onCopySection(): Promise<void> {\n if (!this.section.fields?.length) {\n return;\n }\n\n // Build text content from all fields\n const textParts: string[] = [];\n\n // Add title if available\n if (this.section.title) {\n textParts.push(this.section.title);\n }\n\n // Add description if available\n if (this.section.description) {\n textParts.push(this.section.description);\n }\n\n // Add field content\n this.section.fields.forEach((field) => {\n const value = this.getFieldValue(field);\n if (value !== null && value !== undefined) {\n const stringValue = String(value);\n if (field.label) {\n textParts.push(`${field.label}: ${stringValue}`);\n } else {\n textParts.push(stringValue);\n }\n }\n });\n\n const textToCopy = textParts.join('\\n\\n');\n\n try {\n await this.clipboardService.copy(textToCopy);\n } catch (error) {\n console.error('Failed to copy section content to clipboard', error);\n }\n }\n}\n","<div class=\"ai-section ai-section--overview section-content\">\n <button\n type=\"button\"\n class=\"overview-section-copy-btn\"\n [attr.aria-label]=\"'Copy section: ' + (section.title || 'Overview')\"\n title=\"Copy section content\"\n (click)=\"onCopySection()\"\n (keydown.enter)=\"onCopySection()\"\n (keydown.space)=\"$event.preventDefault(); onCopySection()\"\n >\n <lucide-icon name=\"copy\" [size]=\"12\" aria-hidden=\"true\"></lucide-icon>\n </button>\n <lib-section-header *ngIf=\"section.title\" [title]=\"section.title\" [description]=\"section.description\">\n </lib-section-header>\n\n <div class=\"overview-grid\" *ngIf=\"section.fields?.length\">\n <div class=\"overview-item\" *ngFor=\"let field of section.fields\" [class.overview-item--single-text]=\"!field.label\">\n <div class=\"overview-item__label\" *ngIf=\"field.label\">{{ field.label }}</div>\n <div\n class=\"overview-item__value\"\n [innerHTML]=\"formatFieldValue(field)\"\n [class.overview-item__value--single-text]=\"!field.label\"\n ></div>\n </div>\n </div>\n\n <lib-empty-state *ngIf=\"!section.fields?.length\" message=\"No overview data\" icon=\"📋\" variant=\"minimal\">\n </lib-empty-state>\n</div>\n"],"names":[],"mappings":";;;;;;;AAAA;;;;;;;;;;;;;AAaG;MAaU,gBAAgB,CAAA;AAH7B,IAAA,WAAA,GAAA;AAIU,QAAA,IAAA,CAAA,OAAO,GAAG,MAAM,CAAmB,EAAE,mDAAC;QACtC,IAAA,CAAA,UAAU,GAAG,EAAE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AA,EAAA,KAAA,EAAA,OAAA,EAAA,qBAAA,EAAA,MAAA,EAAA,aAAA,CAAA,EAAA,CAAA,EAAA,CAAA,CAAA;;4FAI3E,wBAAwB,EAAA,UAAA,EAAA,CAAA;kBAPpC,SAAS;+BACE,sBAAsB,EAAA,UAAA,EACpB,IAAI,EAAA,OAAA,EACP,CAAC,YAAY,EAAE,sBAAsB,EAAE,mBAAmB,EAAE,iBAAiB,CAAC,EAAA,QAAA,EAAA,4vCAAA,EAAA,MAAA,EAAA,CAAA,8plDAAA,CAAA,EAAA;;;;;"}
@@ -1,2 +1,2 @@
1
- export { ar as AICardRendererComponent, c5 as ALL_SECTION_TYPES, A as ANIMATION_PRESETS, b as ANIMATION_TIMING, _ as AccessibilityService, N as ActionFactory, au as AnalyticsSectionComponent, aZ as AutoUnsubscribe, c as BORDER_RADIUS, d as BREAKPOINTS, b4 as BUILD_BRANCH, b5 as BUILD_DATE, b6 as BUILD_HASH, df as BadgeComponent, B as BaseSectionComponent, av as BrandColorsSectionComponent, bD as BrandedIds, e as CARD_SIZES, f as CARD_SPACING, g as COLUMNS_BY_BREAKPOINT, h as CONTAINER_CONFIG, cS as CSS_ISOLATION_MODE, $ as CachedSectionNormalizationService, di as CardActionsComponent, dj as CardBodyComponent, a0 as CardFacadeService, O as CardFactory, dk as CardFooterComponent, dl as CardHeaderComponent, d9 as CardPreviewComponent, dm as CardSectionListComponent, da as CardSkeletonComponent, as as CardStreamingIndicatorComponent, C as CardTypeGuards, aU as CardUtil, aw as ChartSectionComponent, ax as ContactCardSectionComponent, dn as CopyToClipboardDirective, c6 as DECORATED_SECTION_COMPONENTS, cK as DEFAULT_ACCESSIBILITY_CONFIG, cC as DEFAULT_ANIMATION_CONFIG, cR as DEFAULT_CSS_ISOLATION_MODE, cN as DEFAULT_ERROR_CONFIG, a$ as DEFAULT_GRID_CONFIG, cE as DEFAULT_LAYOUT_CONFIG, D as DEFAULT_LOADING_MESSAGES, cG as DEFAULT_LOGGING_CONFIG, cP as DEFAULT_OSI_CARDS_FULL_CONFIG, cI as DEFAULT_OSI_THEME_CONFIG, cA as DEFAULT_STREAMING_CONFIG, cT as DEFAULT_THEME, an as DEFAULT_THEME_CONFIG, a1 as DynamicSectionLoaderService, i as EASING, j as EMPTY_STATE_CONFIG, a2 as EmailHandlerService, E as EmptyStateComponent, at as ErrorBoundaryComponent, a3 as ErrorTrackingService, a4 as EventBusService, a5 as EventMiddlewareService, ay as EventSectionComponent, a6 as FEATURE_FLAG_META, a7 as FeatureFlagsService, Q as FieldFactory, az as FinancialsSectionComponent, aR as FlipAnimator, G as GRID_CONFIG, a8 as I18nService, I as ICON_SIZE, a9 as IconService, R as ItemFactory, aa as KeyboardShortcutsService, ab as LayoutCalculationService, dB as LayoutError, ac as LayoutStateManager, ad as LayoutWorkerService, dp as LazyRenderDirective, aA as ListSectionComponent, W as LogValidationErrors, ae as LoggerService, L as LucideIconsModule, cg as MANIFEST_META, M as MASONRY_CONFIG, af as MagneticTiltService, aB as MapSectionComponent, db as MasonryGridComponent, aJ as Memoize, aK as MemoizeLRU, aL as MemoizeTTL, aC as NetworkCardSectionComponent, aD as NewsSectionComponent, dt as OSICardsError, ag as OSICardsStreamingService, cL as OSI_ACCESSIBILITY_CONFIG, cD as OSI_ANIMATION_CONFIG, cu as OSI_CARDS_ICONS, cM as OSI_CUSTOM_SECTIONS, cO as OSI_ERROR_CONFIG, ch as OSI_EVENTS, ah as OSI_FEATURE_FLAGS, cQ as OSI_FULL_CONFIG, cF as OSI_LAYOUT_CONFIG, cH as OSI_LOGGING_CONFIG, cB as OSI_STREAMING_CONFIG, ao as OSI_THEME_CONFIG, cJ as OSI_THEME_CONFIG_TOKEN, aM as ObjectPool, dc as OsiCardsComponent, dd as OsiCardsContainerComponent, dr as OsiThemeDirective, P as PARTICLE_CONFIG, k as PLACEHOLDER_TEXT, c4 as PUBLIC_SECTION_TYPES, aN as PerfectBinPacker, dD as PluginRegistrationError, d5 as PresetFactory, aE as ProductSectionComponent, dh as ProgressBarComponent, aF as QuotationSectionComponent, dA as RequiredFieldError, cU as SCOPED_ANIMATION_SERVICE, cX as SCOPED_SELECTION_SERVICE, c_ as SCOPED_STATE_SERVICE, cc as SECTION_MANIFEST, b$ as SECTION_METADATA, c0 as SECTION_TYPE_ALIASES, l as SHADOWS, m as SKELETON_CONFIG, n as SPACING, o as STAGGER_DELAYS, p as STREAMING_CONFIG, q as STREAMING_PROGRESS, r as STREAMING_STAGES, cV as ScopedAnimationService, cY as ScopedSelectionService, c$ as ScopedStateService, c7 as SectionComponent, U as SectionConfigFactory, ds as SectionDesignDirective, V as SectionFactory, a as SectionHeaderComponent, ai as SectionNormalizationService, aj as SectionPluginRegistry, du as SectionRenderError, de as SectionRendererComponent, ak as SectionUtilsService, aG as SocialMediaSectionComponent, aH as SolutionsSectionComponent, dw as StreamingError, dy as StreamingParseError, dx as StreamingTimeoutError, a_ as SubscriptionTracker, T as TILT_CONFIG, aI as TextReferenceSectionComponent, ap as ThemeService, al as ToastService, dq as TooltipDirective, dg as TrendIndicatorComponent, dv as UnknownSectionTypeError, b7 as VERSION, b8 as VERSION_INFO, dz as ValidationError, dC as WorkerError, Z as Z_INDEX, b_ as assertNever, s as calculateChunkDelay, b0 as calculateColumnWidth, b1 as calculateColumns, ck as createActionClickEvent, bq as createActionId, d4 as createAnalyticsDashboard, d8 as createAnalyticsPreset, bm as createCardId, cl as createCardInteractionEvent, d1 as createCompanyCard, d6 as createCompanyPreset, d3 as createContactCard, d7 as createContactPreset, bv as createEmail, d2 as createEnhancedCompanyCard, ci as createFieldClickEvent, bo as createFieldId, aS as createFlipList, bt as createHexColor, cj as createItemClickEvent, bp as createItemId, am as createLogger, bx as createMilliseconds, bs as createPercentage, bw as createPixels, br as createPluginId, aV as createSafeAsyncFunction, aW as createSafeFunction, bn as createSectionId, co as createSectionRenderedEvent, cn as createStreamingStateEvent, cm as createThemeChangeEvent, bu as createUrl, aP as debounce, bC as generateActionId, by as generateCardId, bA as generateFieldId, bB as generateItemId, bz as generateSectionId, t as generateStreamingId, u as getAnimationTiming, b9 as getBuildInfo, v as getColumnsForBreakpoint, w as getCurrentBreakpoint, x as getEasing, cd as getManifestEntry, b2 as getPreferredColumns, ce as getPublicSectionTypes, y as getRandomLoadingMessage, ca as getRegisteredComponent, c8 as getRegisteredSectionComponents, cb as getRegisteredSectionTypes, c3 as getSectionMetadata, cf as getSectionsRequiringExternalLibs, ba as getShortVersion, dG as getUserMessage, bb as getVersionString, bZ as hasChartData, bX as hasFields, bY as hasItems, c9 as hasRegisteredComponent, bI as isAnalyticsSection, bU as isBrandColorsSection, bE as isCardId, bP as isChartSection, bJ as isContactCardSection, z as isDesktopViewport, bN as isEventSection, bG as isFieldId, bM as isFinancialsSection, bH as isItemId, bO as isListSection, bL as isMapSection, F as isMobileViewport, bK as isNetworkCardSection, bV as isNewsSection, cr as isOSIActionClickEvent, cs as isOSICardInteractionEvent, dE as isOSICardsError, cp as isOSIFieldClickEvent, cq as isOSIItemClickEvent, bc as isPrerelease, bQ as isProductSection, bd as isProductionBuild, bS as isQuotationSection, bF as isSectionId, bW as isSocialMediaSection, bR as isSolutionsSection, H as isStreamingPlaceholder, J as isTabletViewport, bT as isTextReferenceSection, be as isValidCardId, bl as isValidEmail, bg as isValidFieldId, bj as isValidHexColor, bh as isValidItemId, bi as isValidPercentage, bf as isValidSectionId, c2 as isValidSectionType, bk as isValidUrl, aO as packWithZeroGapsGuarantee, K as prefersReducedMotion, ct as provideLucideIcons, aq as provideOSICardsTheme, cw as provideOsiCards, cy as provideOsiCardsAdvanced, cv as provideOsiCardsCore, cx as provideOsiCardsMinimal, cz as provideOsiCardsTesting, cW as provideScopedAnimationService, cZ as provideScopedSelectionService, d0 as provideScopedStateService, aT as recordPositions, b3 as resolveColumnSpan, c1 as resolveSectionType, aQ as throttle, aX as tryCatch, aY as useErrorBoundary, X as validateField, Y as validateSection, dF as wrapError } from './osi-cards-lib-osi-cards-lib-Cg-ENr-a.mjs';
1
+ export { ar as AICardRendererComponent, c5 as ALL_SECTION_TYPES, A as ANIMATION_PRESETS, b as ANIMATION_TIMING, _ as AccessibilityService, N as ActionFactory, au as AnalyticsSectionComponent, aZ as AutoUnsubscribe, c as BORDER_RADIUS, d as BREAKPOINTS, b4 as BUILD_BRANCH, b5 as BUILD_DATE, b6 as BUILD_HASH, df as BadgeComponent, B as BaseSectionComponent, av as BrandColorsSectionComponent, bD as BrandedIds, e as CARD_SIZES, f as CARD_SPACING, g as COLUMNS_BY_BREAKPOINT, h as CONTAINER_CONFIG, cS as CSS_ISOLATION_MODE, $ as CachedSectionNormalizationService, di as CardActionsComponent, dj as CardBodyComponent, a0 as CardFacadeService, O as CardFactory, dk as CardFooterComponent, dl as CardHeaderComponent, d9 as CardPreviewComponent, dm as CardSectionListComponent, da as CardSkeletonComponent, as as CardStreamingIndicatorComponent, C as CardTypeGuards, aU as CardUtil, aw as ChartSectionComponent, ax as ContactCardSectionComponent, dn as CopyToClipboardDirective, c6 as DECORATED_SECTION_COMPONENTS, cK as DEFAULT_ACCESSIBILITY_CONFIG, cC as DEFAULT_ANIMATION_CONFIG, cR as DEFAULT_CSS_ISOLATION_MODE, cN as DEFAULT_ERROR_CONFIG, a$ as DEFAULT_GRID_CONFIG, cE as DEFAULT_LAYOUT_CONFIG, D as DEFAULT_LOADING_MESSAGES, cG as DEFAULT_LOGGING_CONFIG, cP as DEFAULT_OSI_CARDS_FULL_CONFIG, cI as DEFAULT_OSI_THEME_CONFIG, cA as DEFAULT_STREAMING_CONFIG, cT as DEFAULT_THEME, an as DEFAULT_THEME_CONFIG, a1 as DynamicSectionLoaderService, i as EASING, j as EMPTY_STATE_CONFIG, a2 as EmailHandlerService, E as EmptyStateComponent, at as ErrorBoundaryComponent, a3 as ErrorTrackingService, a4 as EventBusService, a5 as EventMiddlewareService, ay as EventSectionComponent, a6 as FEATURE_FLAG_META, a7 as FeatureFlagsService, Q as FieldFactory, az as FinancialsSectionComponent, aR as FlipAnimator, G as GRID_CONFIG, a8 as I18nService, I as ICON_SIZE, a9 as IconService, R as ItemFactory, aa as KeyboardShortcutsService, ab as LayoutCalculationService, dB as LayoutError, ac as LayoutStateManager, ad as LayoutWorkerService, dp as LazyRenderDirective, aA as ListSectionComponent, W as LogValidationErrors, ae as LoggerService, L as LucideIconsModule, cg as MANIFEST_META, M as MASONRY_CONFIG, af as MagneticTiltService, aB as MapSectionComponent, db as MasonryGridComponent, aJ as Memoize, aK as MemoizeLRU, aL as MemoizeTTL, aC as NetworkCardSectionComponent, aD as NewsSectionComponent, dt as OSICardsError, ag as OSICardsStreamingService, cL as OSI_ACCESSIBILITY_CONFIG, cD as OSI_ANIMATION_CONFIG, cu as OSI_CARDS_ICONS, cM as OSI_CUSTOM_SECTIONS, cO as OSI_ERROR_CONFIG, ch as OSI_EVENTS, ah as OSI_FEATURE_FLAGS, cQ as OSI_FULL_CONFIG, cF as OSI_LAYOUT_CONFIG, cH as OSI_LOGGING_CONFIG, cB as OSI_STREAMING_CONFIG, ao as OSI_THEME_CONFIG, cJ as OSI_THEME_CONFIG_TOKEN, aM as ObjectPool, dc as OsiCardsComponent, dd as OsiCardsContainerComponent, dr as OsiThemeDirective, P as PARTICLE_CONFIG, k as PLACEHOLDER_TEXT, c4 as PUBLIC_SECTION_TYPES, aN as PerfectBinPacker, dD as PluginRegistrationError, d5 as PresetFactory, aE as ProductSectionComponent, dh as ProgressBarComponent, aF as QuotationSectionComponent, dA as RequiredFieldError, cU as SCOPED_ANIMATION_SERVICE, cX as SCOPED_SELECTION_SERVICE, c_ as SCOPED_STATE_SERVICE, cc as SECTION_MANIFEST, b$ as SECTION_METADATA, c0 as SECTION_TYPE_ALIASES, l as SHADOWS, m as SKELETON_CONFIG, n as SPACING, o as STAGGER_DELAYS, p as STREAMING_CONFIG, q as STREAMING_PROGRESS, r as STREAMING_STAGES, cV as ScopedAnimationService, cY as ScopedSelectionService, c$ as ScopedStateService, c7 as SectionComponent, U as SectionConfigFactory, ds as SectionDesignDirective, V as SectionFactory, a as SectionHeaderComponent, ai as SectionNormalizationService, aj as SectionPluginRegistry, du as SectionRenderError, de as SectionRendererComponent, ak as SectionUtilsService, aG as SocialMediaSectionComponent, aH as SolutionsSectionComponent, dw as StreamingError, dy as StreamingParseError, dx as StreamingTimeoutError, a_ as SubscriptionTracker, T as TILT_CONFIG, aI as TextReferenceSectionComponent, ap as ThemeService, al as ToastService, dq as TooltipDirective, dg as TrendIndicatorComponent, dv as UnknownSectionTypeError, b7 as VERSION, b8 as VERSION_INFO, dz as ValidationError, dC as WorkerError, Z as Z_INDEX, b_ as assertNever, s as calculateChunkDelay, b0 as calculateColumnWidth, b1 as calculateColumns, ck as createActionClickEvent, bq as createActionId, d4 as createAnalyticsDashboard, d8 as createAnalyticsPreset, bm as createCardId, cl as createCardInteractionEvent, d1 as createCompanyCard, d6 as createCompanyPreset, d3 as createContactCard, d7 as createContactPreset, bv as createEmail, d2 as createEnhancedCompanyCard, ci as createFieldClickEvent, bo as createFieldId, aS as createFlipList, bt as createHexColor, cj as createItemClickEvent, bp as createItemId, am as createLogger, bx as createMilliseconds, bs as createPercentage, bw as createPixels, br as createPluginId, aV as createSafeAsyncFunction, aW as createSafeFunction, bn as createSectionId, co as createSectionRenderedEvent, cn as createStreamingStateEvent, cm as createThemeChangeEvent, bu as createUrl, aP as debounce, bC as generateActionId, by as generateCardId, bA as generateFieldId, bB as generateItemId, bz as generateSectionId, t as generateStreamingId, u as getAnimationTiming, b9 as getBuildInfo, v as getColumnsForBreakpoint, w as getCurrentBreakpoint, x as getEasing, cd as getManifestEntry, b2 as getPreferredColumns, ce as getPublicSectionTypes, y as getRandomLoadingMessage, ca as getRegisteredComponent, c8 as getRegisteredSectionComponents, cb as getRegisteredSectionTypes, c3 as getSectionMetadata, cf as getSectionsRequiringExternalLibs, ba as getShortVersion, dG as getUserMessage, bb as getVersionString, bZ as hasChartData, bX as hasFields, bY as hasItems, c9 as hasRegisteredComponent, bI as isAnalyticsSection, bU as isBrandColorsSection, bE as isCardId, bP as isChartSection, bJ as isContactCardSection, z as isDesktopViewport, bN as isEventSection, bG as isFieldId, bM as isFinancialsSection, bH as isItemId, bO as isListSection, bL as isMapSection, F as isMobileViewport, bK as isNetworkCardSection, bV as isNewsSection, cr as isOSIActionClickEvent, cs as isOSICardInteractionEvent, dE as isOSICardsError, cp as isOSIFieldClickEvent, cq as isOSIItemClickEvent, bc as isPrerelease, bQ as isProductSection, bd as isProductionBuild, bS as isQuotationSection, bF as isSectionId, bW as isSocialMediaSection, bR as isSolutionsSection, H as isStreamingPlaceholder, J as isTabletViewport, bT as isTextReferenceSection, be as isValidCardId, bl as isValidEmail, bg as isValidFieldId, bj as isValidHexColor, bh as isValidItemId, bi as isValidPercentage, bf as isValidSectionId, c2 as isValidSectionType, bk as isValidUrl, aO as packWithZeroGapsGuarantee, K as prefersReducedMotion, ct as provideLucideIcons, aq as provideOSICardsTheme, cw as provideOsiCards, cy as provideOsiCardsAdvanced, cv as provideOsiCardsCore, cx as provideOsiCardsMinimal, cz as provideOsiCardsTesting, cW as provideScopedAnimationService, cZ as provideScopedSelectionService, d0 as provideScopedStateService, aT as recordPositions, b3 as resolveColumnSpan, c1 as resolveSectionType, aQ as throttle, aX as tryCatch, aY as useErrorBoundary, X as validateField, Y as validateSection, dF as wrapError } from './osi-cards-lib-osi-cards-lib-BLZhabZB.mjs';
2
2
  //# sourceMappingURL=osi-cards-lib.mjs.map
package/index.d.ts CHANGED
@@ -10282,7 +10282,7 @@ declare abstract class ChartSectionBaseComponent extends BaseSectionComponent {
10282
10282
  /**
10283
10283
  * Chart type (bar, line, pie, doughnut)
10284
10284
  */
10285
- readonly chartType: i0.Signal<"line" | "bar" | "pie" | "doughnut">;
10285
+ readonly chartType: i0.Signal<"bar" | "line" | "pie" | "doughnut">;
10286
10286
  /**
10287
10287
  * Processed chart configuration
10288
10288
  */
@@ -11659,11 +11659,11 @@ declare function packWithZeroGapsGuarantee(sections: CardSection[], columns?: nu
11659
11659
  * Do not edit manually - generated by scripts/generate-version.js
11660
11660
  *
11661
11661
  * Source of truth: version.config.json
11662
- * Last synced: 2026-01-08T15:43:54.082Z
11662
+ * Last synced: 2026-01-08T15:54:52.794Z
11663
11663
  */
11664
- declare const VERSION = "1.5.50";
11665
- declare const BUILD_DATE = "2026-01-08T15:43:54.082Z";
11666
- declare const BUILD_HASH = "3f4ad1c";
11664
+ declare const VERSION = "1.5.51";
11665
+ declare const BUILD_DATE = "2026-01-08T15:54:52.794Z";
11666
+ declare const BUILD_HASH = "5c9afa0";
11667
11667
  declare const BUILD_BRANCH = "main";
11668
11668
  interface VersionInfo {
11669
11669
  version: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "osi-cards-lib",
3
- "version": "1.5.50",
3
+ "version": "1.5.51",
4
4
  "description": "Standalone OSI Cards library for Angular applications with CSS Layer support for easy style overrides",
5
5
  "keywords": [
6
6
  "angular",
@@ -41,8 +41,6 @@
41
41
  "tslib": "^2.3.0"
42
42
  },
43
43
  "optionalDependencies": {
44
- "frappe-charts": "^1.7.3",
45
- "leaflet": "^1.9.4",
46
44
  "marked": "^17.0.0"
47
45
  },
48
46
  "exports": {