@memberjunction/ng-artifacts 5.11.0 → 5.12.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.
- package/dist/lib/artifacts.module.d.ts +2 -1
- package/dist/lib/artifacts.module.d.ts.map +1 -1
- package/dist/lib/artifacts.module.js +7 -3
- package/dist/lib/artifacts.module.js.map +1 -1
- package/dist/lib/components/artifact-message-card.component.js +2 -2
- package/dist/lib/components/artifact-message-card.component.js.map +1 -1
- package/dist/lib/components/artifact-viewer-panel.component.js +2 -2
- package/dist/lib/components/plugins/component-artifact-viewer.component.d.ts +2 -0
- package/dist/lib/components/plugins/component-artifact-viewer.component.d.ts.map +1 -1
- package/dist/lib/components/plugins/component-artifact-viewer.component.js +43 -14
- package/dist/lib/components/plugins/component-artifact-viewer.component.js.map +1 -1
- package/dist/lib/components/plugins/component-feedback-panel/component-feedback-panel.component.d.ts +75 -0
- package/dist/lib/components/plugins/component-feedback-panel/component-feedback-panel.component.d.ts.map +1 -0
- package/dist/lib/components/plugins/component-feedback-panel/component-feedback-panel.component.js +569 -0
- package/dist/lib/components/plugins/component-feedback-panel/component-feedback-panel.component.js.map +1 -0
- package/dist/lib/components/plugins/data-artifact-viewer.component.d.ts +10 -0
- package/dist/lib/components/plugins/data-artifact-viewer.component.d.ts.map +1 -1
- package/dist/lib/components/plugins/data-artifact-viewer.component.js +44 -11
- package/dist/lib/components/plugins/data-artifact-viewer.component.js.map +1 -1
- package/dist/lib/components/plugins/data-requirements-viewer/data-requirements-viewer.component.js +2 -2
- package/dist/lib/components/plugins/json-artifact-viewer.component.d.ts.map +1 -1
- package/dist/lib/components/plugins/json-artifact-viewer.component.js +3 -3
- package/dist/lib/components/plugins/json-artifact-viewer.component.js.map +1 -1
- package/dist/public-api.d.ts +1 -0
- package/dist/public-api.d.ts.map +1 -1
- package/dist/public-api.js +1 -0
- package/dist/public-api.js.map +1 -1
- package/package.json +15 -14
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"json-artifact-viewer.component.js","sourceRoot":"","sources":["../../../../src/lib/components/plugins/json-artifact-viewer.component.ts"],"names":[],"mappings":";;;;;;AAAA,OAAO,EAAE,SAAS,EAAwC,SAAS,EAAc,MAAM,eAAe,CAAC;AAEvG,OAAO,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AACvD,OAAO,EAAE,iCAAiC,EAAE,MAAM,mCAAmC,CAAC;AACtF,OAAO,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;;;;;;;;;;IAmBrC,iCAAgF;IAA5B,+LAAS,wBAAiB,KAAC;IAC7E,wBAAwC;IAAC,4BAC3C;IAAA,iBAAS;IACT,kCAA6D;IAAtB,+LAAS,kBAAW,KAAC;IAC1D,wBAA4B;IAAC,uBAC/B;IAAA,iBAAS;;;;IAQT,qCAK0B;IAAxB,6LAAQ,qBAAc,KAAC;IACzB,iBAAS;;;IAJP,kEAAmB;;;IAMrB,8BAA8B;IAC5B,kCAI+C;IACjD,iBAAM;;;IALS,cAAwB;IAIxB,AADA,AADA,AADA,AADA,6CAAwB,mCACU,2BACR,2BACA,oBACP;;;;IAIhC,AADF,8BAAmC,yBAKI;IAHnC,kUAAyB;IAK7B,AADE,iBAAiB,EACb;;;IALF,cAAyB;IAAzB,kDAAyB;IAEzB,AADA,iCAAmB,kBACF;;AAjD/B;;;;GAIG;AAsHI,IAAM,2BAA2B,GAAjC,MAAM,2BAA4B,SAAQ,iCAAiC;IAkBtE;IACA;IAlBc,SAAS,CAAiC;IAE3D,WAAW,GAAG,EAAE,CAAC;IACjB,eAAe,GAAkB,IAAI,CAAC;IACtC,WAAW,GAAkB,IAAI,CAAC;IAClC,WAAW,GAA2B,IAAI,CAAC;IAC1C,iBAAiB,GAAuC,EAAE,CAAC;IAC3D,aAAa,GAAkB,IAAI,CAAC,CAAC,8BAA8B;IAE3E;;OAEG;IACH,IAAoB,iBAAiB;QACnC,OAAO,IAAI,CAAC;IACd,CAAC;IAED,YACU,G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WAAW;;kFADX,2BAA2B","sourcesContent":["import { Component, OnInit, OnDestroy, ChangeDetectorRef, ViewChild, ElementRef } from '@angular/core';\nimport { DomSanitizer, SafeResourceUrl } from '@angular/platform-browser';\nimport { RegisterClass } from '@memberjunction/global';\nimport { BaseArtifactViewerPluginComponent } from '../base-artifact-viewer.component';\nimport { RunView } from '@memberjunction/core';\nimport { MJArtifactVersionAttributeEntity } from '@memberjunction/core-entities';\n\n/**\n * Viewer component for JSON artifacts.\n * Supports extract rules - shows displayMarkdown, displayHtml, or raw JSON editor (in that priority order).\n * All content is displayed in the parent's Display tab.\n */\n@Component({\n standalone: false,\n selector: 'mj-json-artifact-viewer',\n template: `\n <div class=\"json-artifact-viewer\" [ngClass]=\"cssClass\">\n <!-- Display toolbar -->\n <div class=\"display-toolbar\">\n <button class=\"btn-icon\" title=\"Copy Content\" (click)=\"onCopy()\">\n <i class=\"fas fa-copy\"></i> Copy\n </button>\n @if (displayHtml) {\n <button class=\"btn-icon\" title=\"Open in New Window\" (click)=\"openInNewWindow()\">\n <i class=\"fas fa-external-link-alt\"></i> New Window\n </button>\n <button class=\"btn-icon\" title=\"Print\" (click)=\"printHtml()\">\n <i class=\"fas fa-print\"></i> Print\n </button>\n }\n </div>\n\n <!-- Display content: priority order = displayHtml > displayMarkdown > JSON editor -->\n <div class=\"display-content\">\n @if (displayHtml && htmlBlobUrl) {\n <!-- Sandboxed iframe for rich HTML using blob URL -->\n <iframe\n #htmlFrame\n [src]=\"htmlBlobUrl\"\n sandbox=\"allow-same-origin allow-scripts allow-popups allow-popups-to-escape-sandbox allow-modals\"\n class=\"html-iframe\"\n (load)=\"onIframeLoad()\">\n </iframe>\n } @else if (displayMarkdown) {\n <div class=\"markdown-content\">\n <mj-markdown [data]=\"displayMarkdown\"\n [enableCollapsibleHeadings]=\"true\"\n [enableLineNumbers]=\"true\"\n [enableSmartypants]=\"true\"\n [enableHtml]=\"true\"></mj-markdown>\n </div>\n } @else {\n <div class=\"json-editor-container\">\n <mj-code-editor\n [(ngModel)]=\"jsonContent\"\n [language]=\"'json'\"\n [readonly]=\"true\"\n style=\"width: 100%; height: 100%;\">\n </mj-code-editor>\n </div>\n }\n </div>\n </div>\n `,\n styles: [`\n .json-artifact-viewer {\n display: flex;\n flex-direction: column;\n height: 100%;\n }\n\n .display-toolbar {\n display: flex;\n justify-content: flex-end;\n gap: 8px;\n padding: 8px;\n background: #f8f9fa;\n border-bottom: 1px solid #dee2e6;\n }\n\n .btn-icon {\n padding: 6px 12px;\n background: white;\n border: 1px solid #ccc;\n border-radius: 4px;\n cursor: pointer;\n font-size: 12px;\n display: flex;\n align-items: center;\n gap: 6px;\n transition: all 0.2s;\n }\n\n .btn-icon:hover {\n background: #e9ecef;\n border-color: #999;\n }\n\n .display-content {\n flex: 1;\n overflow: auto;\n min-height: 0;\n display: flex;\n flex-direction: column;\n }\n\n .html-iframe {\n width: 100%;\n border: none;\n background: white;\n display: block;\n }\n\n .markdown-content {\n flex: 1;\n padding: 20px;\n overflow: auto;\n min-height: 0;\n background: white;\n }\n\n .json-editor-container {\n flex: 1;\n overflow: auto;\n min-height: 0;\n }\n `]\n})\n@RegisterClass(BaseArtifactViewerPluginComponent, 'JsonArtifactViewerPlugin')\nexport class JsonArtifactViewerComponent extends BaseArtifactViewerPluginComponent implements OnInit, OnDestroy {\n @ViewChild('htmlFrame') htmlFrame?: ElementRef<HTMLIFrameElement>;\n\n public jsonContent = '';\n public displayMarkdown: string | null = null;\n public displayHtml: string | null = null;\n public htmlBlobUrl: SafeResourceUrl | null = null;\n private versionAttributes: MJArtifactVersionAttributeEntity[] = [];\n private unsafeBlobUrl: string | null = null; // Keep unsafe URL for cleanup\n\n /**\n * JSON artifacts always have content to display (JSON editor, displayHtml, or displayMarkdown)\n */\n public override get hasDisplayContent(): boolean {\n return true;\n }\n\n constructor(\n private cdr: ChangeDetectorRef,\n private sanitizer: DomSanitizer\n ) {\n super();\n }\n\n ngOnDestroy(): void {\n // Clean up blob URL to prevent memory leaks\n if (this.unsafeBlobUrl) {\n URL.revokeObjectURL(this.unsafeBlobUrl);\n this.unsafeBlobUrl = null;\n this.htmlBlobUrl = null;\n }\n }\n\n async ngOnInit(): Promise<void> {\n this.jsonContent = this.getContent();\n\n // Load version attributes to check for extract rules\n await this.loadVersionAttributes();\n\n // Trigger change detection after async load\n this.cdr.detectChanges();\n }\n\n /**\n * Override to return true when showing extracted displayHtml or displayMarkdown.\n * Returns false when showing raw JSON editor (no extract rules available).\n */\n public override get isShowingElevatedDisplay(): boolean {\n return !!(this.displayHtml || this.displayMarkdown);\n }\n\n /**\n * Override to tell parent whether to show raw JSON tab.\n * When showing elevated display (markdown/HTML), return true so parent shows JSON tab.\n * When showing raw JSON editor, return false (no need for duplicate JSON tab).\n */\n public override get parentShouldShowRawContent(): boolean {\n return this.isShowingElevatedDisplay;\n }\n\n private async loadVersionAttributes(): Promise<void> {\n if (!this.artifactVersion?.ID) {\n console.log('📦 JSON Plugin: No artifactVersion.ID, skipping attribute load');\n return;\n }\n\n console.log(`📦 JSON Plugin: Loading attributes for version ID: ${this.artifactVersion.ID}`);\n\n try {\n const rv = new RunView();\n const result = await rv.RunView<MJArtifactVersionAttributeEntity>({\n EntityName: 'MJ: Artifact Version Attributes',\n ExtraFilter: `ArtifactVersionID='${this.artifactVersion.ID}'`,\n ResultType: 'entity_object'\n });\n\n console.log(`📦 JSON Plugin: RunView completed. Success=${result.Success}, Results count=${result.Results?.length || 0}`);\n\n if (result.Success && result.Results) {\n this.versionAttributes = result.Results;\n\n console.log(`📦 JSON Plugin: Loaded ${this.versionAttributes.length} attributes for version ${this.artifactVersion.ID}`);\n console.log(`📦 Attributes:`, this.versionAttributes.map(a => ({ name: a.Name, hasValue: !!a.Value })));\n\n // Check for displayHtml and displayMarkdown attributes (from extract rules)\n // Priority: displayHtml > displayMarkdown\n const displayHtmlAttr = this.versionAttributes.find(a => a.Name?.toLowerCase() === 'displayhtml');\n const displayMarkdownAttr = this.versionAttributes.find(a => a.Name?.toLowerCase() === 'displaymarkdown');\n\n console.log(`📦 displayHtmlAttr:`, displayHtmlAttr ? { name: displayHtmlAttr.Name, valueLength: displayHtmlAttr.Value?.length } : 'not found');\n console.log(`📦 displayMarkdownAttr:`, displayMarkdownAttr ? { name: displayMarkdownAttr.Name, valueLength: displayMarkdownAttr.Value?.length } : 'not found');\n\n // Parse attribute values - fix \"null\" string bug\n this.displayHtml = this.parseAttributeValue(displayHtmlAttr?.Value);\n this.displayMarkdown = this.parseAttributeValue(displayMarkdownAttr?.Value);\n\n // Clean up double-escaped characters in HTML (from LLM generation)\n if (this.displayHtml) {\n this.displayHtml = this.cleanEscapedCharacters(this.displayHtml);\n }\n\n // Create blob URL for HTML to avoid srcdoc sanitization issues\n if (this.displayHtml) {\n const blob = new Blob([this.displayHtml], { type: 'text/html' });\n this.unsafeBlobUrl = URL.createObjectURL(blob);\n // Sanitize the blob URL so Angular trusts it in the iframe\n this.htmlBlobUrl = this.sanitizer.bypassSecurityTrustResourceUrl(this.unsafeBlobUrl);\n }\n\n // Note: Markdown rendering is now handled by <mj-markdown> component in template\n\n console.log(`📦 JSON Plugin: displayHtml=${!!this.displayHtml} (${this.displayHtml?.length || 0} chars), displayMarkdown=${!!this.displayMarkdown} (${this.displayMarkdown?.length || 0} chars)`);\n console.log(`📦 isShowingElevatedDisplay=${this.isShowingElevatedDisplay}`);\n } else {\n console.log(`📦 JSON Plugin: No attributes found or query failed. Success=${result.Success}, ResultsLength=${result.Results?.length}`);\n }\n } catch (err) {\n console.error('📦 JSON Plugin: Error loading version attributes:', err);\n }\n }\n\n private parseAttributeValue(value: string | null | undefined): string | null {\n if (!value) return null;\n\n // Fix bug: Some extractors return string \"null\" instead of actual null\n if (value === 'null' || value.trim() === '') {\n return null;\n }\n\n try {\n // Try to parse as JSON first\n const parsed = JSON.parse(value);\n if (typeof parsed === 'string') {\n // Check if parsed string is also \"null\"\n if (parsed === 'null' || parsed.trim() === '') {\n return null;\n }\n return parsed;\n }\n return JSON.stringify(parsed, null, 2);\n } catch {\n // If not valid JSON, return as-is (unless it's \"null\")\n return value === 'null' ? null : value;\n }\n }\n\n onIframeLoad(): void {\n // Inject base styles if HTML doesn't have them\n if (this.htmlFrame) {\n const iframe = this.htmlFrame.nativeElement;\n const iframeDoc = iframe.contentDocument || iframe.contentWindow?.document;\n\n if (iframeDoc) {\n // Check if HTML already has styles\n const hasStyles = iframeDoc.querySelector('style') || iframeDoc.querySelector('link[rel=\"stylesheet\"]');\n\n if (!hasStyles) {\n // Inject minimal base styles for better defaults\n const style = iframeDoc.createElement('style');\n style.textContent = `\n body {\n font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;\n line-height: 1.6;\n color: #333;\n margin: 20px;\n padding: 0;\n }\n h1, h2, h3 { color: #2c3e50; margin-top: 1.5em; margin-bottom: 0.5em; }\n h1 { font-size: 2em; border-bottom: 2px solid #3498db; padding-bottom: 0.3em; }\n h2 { font-size: 1.5em; }\n table { border-collapse: collapse; width: 100%; margin: 1em 0; }\n th, td { border: 1px solid #ddd; padding: 8px; text-align: left; }\n th { background-color: #f8f9fa; font-weight: 600; }\n pre { background: #f6f8fa; padding: 16px; border-radius: 6px; overflow-x: auto; }\n code { background: #f6f8fa; padding: 2px 6px; border-radius: 3px; font-family: monospace; }\n `;\n iframeDoc.head.appendChild(style);\n }\n\n // Inject width guardrails to prevent iframe content from causing horizontal overflow\n const widthOverride = iframeDoc.createElement('style');\n widthOverride.textContent = `\n html, body {\n max-width: 100% !important;\n overflow-x: hidden !important;\n }\n body {\n margin: 20px 10px 5px 20px !important; /* top right bottom left */\n padding: 0 !important;\n box-sizing: border-box !important;\n }\n img, svg, table, pre {\n max-width: 100% !important;\n }\n `;\n iframeDoc.head.appendChild(widthOverride);\n\n console.log('📦 Iframe loaded, hasStyles:', !!hasStyles);\n\n // Auto-resize iframe to fit content\n this.resizeIframeToContent();\n }\n }\n }\n\n private resizeIframeToContent(): void {\n if (this.htmlFrame) {\n const iframe = this.htmlFrame.nativeElement;\n const iframeDoc = iframe.contentDocument || iframe.contentWindow?.document;\n\n if (iframeDoc && iframeDoc.body) {\n // Get the actual content height\n const contentHeight = Math.max(\n iframeDoc.body.scrollHeight,\n iframeDoc.body.offsetHeight,\n iframeDoc.documentElement.scrollHeight,\n iframeDoc.documentElement.offsetHeight\n );\n\n // Set iframe height to match content (with a bit of padding)\n iframe.style.height = `${contentHeight + 20}px`;\n\n console.log('📦 Iframe resized - Height:', contentHeight + 20, 'px');\n }\n }\n }\n\n openInNewWindow(): void {\n if (this.displayHtml) {\n const newWindow = window.open('', '_blank');\n if (newWindow) {\n newWindow.document.write(this.displayHtml);\n newWindow.document.close();\n }\n }\n }\n\n printHtml(): void {\n if (this.htmlFrame) {\n const iframe = this.htmlFrame.nativeElement;\n const iframeWindow = iframe.contentWindow;\n if (iframeWindow) {\n iframeWindow.focus();\n iframeWindow.print();\n }\n }\n }\n\n onCopy(): void {\n // Copy based on what's being displayed - prioritize displayHtml\n const content = this.displayHtml || this.displayMarkdown || this.jsonContent;\n if (content) {\n navigator.clipboard.writeText(content).then(() => {\n console.log('✅ Copied content to clipboard');\n }).catch(err => {\n console.error('Failed to copy to clipboard:', err);\n });\n }\n }\n\n /**\n * Clean up double-escaped characters that appear in LLM-generated HTML\n * Removes literal \"\\\\n\", \"\\\\t\", and \"\\\\\\\"\" which cause rendering issues\n */\n private cleanEscapedCharacters(html: string): string {\n // Remove escaped quotes (\\\" becomes \")\n let cleaned = html.replace(/\\\\\"/g, '\"');\n\n // Remove escaped newlines (\\\\n becomes nothing)\n // HTML doesn't need whitespace for formatting, and these cause display issues\n cleaned = cleaned.replace(/\\\\n/g, '');\n\n // Remove escaped tabs\n cleaned = cleaned.replace(/\\\\t/g, '');\n\n // Remove double-escaped tabs\n cleaned = cleaned.replace(/\\\\\\\\t/g, '');\n\n // Remove double-escaped newlines\n cleaned = cleaned.replace(/\\\\\\\\n/g, '');\n\n return cleaned;\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"json-artifact-viewer.component.js","sourceRoot":"","sources":["../../../../src/lib/components/plugins/json-artifact-viewer.component.ts"],"names":[],"mappings":";;;;;;AAAA,OAAO,EAAE,SAAS,EAAwC,SAAS,EAAc,MAAM,eAAe,CAAC;AAEvG,OAAO,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AACvD,OAAO,EAAE,iCAAiC,EAAE,MAAM,mCAAmC,CAAC;AACtF,OAAO,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;;;;;;;;;;IAmBrC,iCAAgF;IAA5B,+LAAS,wBAAiB,KAAC;IAC7E,wBAAwC;IAAC,4BAC3C;IAAA,iBAAS;IACT,kCAA6D;IAAtB,+LAAS,kBAAW,KAAC;IAC1D,wBAA4B;IAAC,uBAC/B;IAAA,iBAAS;;;;IAQT,qCAK0B;IAAxB,6LAAQ,qBAAc,KAAC;IACzB,iBAAS;;;IAJP,kEAAmB;;;IAMrB,8BAA8B;IAC5B,kCAI+C;IACjD,iBAAM;;;IALS,cAAwB;IAIxB,AADA,AADA,AADA,AADA,6CAAwB,mCACU,2BACR,2BACA,oBACP;;;;IAIhC,AADF,8BAAmC,yBAKI;IAHnC,kUAAyB;IAK7B,AADE,iBAAiB,EACb;;;IALF,cAAyB;IAAzB,kDAAyB;IAEzB,AADA,iCAAmB,kBACF;;AAjD/B;;;;GAIG;AAuHI,IAAM,2BAA2B,GAAjC,MAAM,2BAA4B,SAAQ,iCAAiC;IAkBtE;IACA;IAlBc,SAAS,CAAiC;IAE3D,WAAW,GAAG,EAAE,CAAC;IACjB,eAAe,GAAkB,IAAI,CAAC;IACtC,WAAW,GAAkB,IAAI,CAAC;IAClC,WAAW,GAA2B,IAAI,CAAC;IAC1C,iBAAiB,GAAuC,EAAE,CAAC;IAC3D,aAAa,GAAkB,IAAI,CAAC,CAAC,8BAA8B;IAE3E;;OAEG;IACH,IAAoB,iBAAiB;QACnC,OAAO,IAAI,CAAC;IACd,CAAC;IAED,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mBAAC,WAAW;;kFADX,2BAA2B","sourcesContent":["import { Component, OnInit, OnDestroy, ChangeDetectorRef, ViewChild, ElementRef } from '@angular/core';\nimport { DomSanitizer, SafeResourceUrl } from '@angular/platform-browser';\nimport { RegisterClass } from '@memberjunction/global';\nimport { BaseArtifactViewerPluginComponent } from '../base-artifact-viewer.component';\nimport { RunView } from '@memberjunction/core';\nimport { MJArtifactVersionAttributeEntity } from '@memberjunction/core-entities';\n\n/**\n * Viewer component for JSON artifacts.\n * Supports extract rules - shows displayMarkdown, displayHtml, or raw JSON editor (in that priority order).\n * All content is displayed in the parent's Display tab.\n */\n@Component({\n standalone: false,\n selector: 'mj-json-artifact-viewer',\n template: `\n <div class=\"json-artifact-viewer\" [ngClass]=\"cssClass\">\n <!-- Display toolbar -->\n <div class=\"display-toolbar\">\n <button class=\"btn-icon\" title=\"Copy Content\" (click)=\"onCopy()\">\n <i class=\"fas fa-copy\"></i> Copy\n </button>\n @if (displayHtml) {\n <button class=\"btn-icon\" title=\"Open in New Window\" (click)=\"openInNewWindow()\">\n <i class=\"fas fa-external-link-alt\"></i> New Window\n </button>\n <button class=\"btn-icon\" title=\"Print\" (click)=\"printHtml()\">\n <i class=\"fas fa-print\"></i> Print\n </button>\n }\n </div>\n\n <!-- Display content: priority order = displayHtml > displayMarkdown > JSON editor -->\n <div class=\"display-content\">\n @if (displayHtml && htmlBlobUrl) {\n <!-- Sandboxed iframe for rich HTML using blob URL -->\n <iframe\n #htmlFrame\n [src]=\"htmlBlobUrl\"\n sandbox=\"allow-same-origin allow-scripts allow-popups allow-popups-to-escape-sandbox allow-modals\"\n class=\"html-iframe\"\n (load)=\"onIframeLoad()\">\n </iframe>\n } @else if (displayMarkdown) {\n <div class=\"markdown-content\">\n <mj-markdown [data]=\"displayMarkdown\"\n [enableCollapsibleHeadings]=\"true\"\n [enableLineNumbers]=\"true\"\n [enableSmartypants]=\"true\"\n [enableHtml]=\"true\"></mj-markdown>\n </div>\n } @else {\n <div class=\"json-editor-container\">\n <mj-code-editor\n [(ngModel)]=\"jsonContent\"\n [language]=\"'json'\"\n [readonly]=\"true\"\n style=\"width: 100%; height: 100%;\">\n </mj-code-editor>\n </div>\n }\n </div>\n </div>\n `,\n styles: [`\n .json-artifact-viewer {\n display: flex;\n flex-direction: column;\n height: 100%;\n }\n\n .display-toolbar {\n display: flex;\n justify-content: flex-end;\n gap: 8px;\n padding: 8px;\n background: var(--mj-bg-surface-sunken);\n border-bottom: 1px solid var(--mj-border-default);\n }\n\n .btn-icon {\n padding: 6px 12px;\n background: var(--mj-bg-surface);\n border: 1px solid var(--mj-border-strong);\n border-radius: 4px;\n cursor: pointer;\n font-size: 12px;\n color: var(--mj-text-secondary);\n display: flex;\n align-items: center;\n gap: 6px;\n transition: all 0.2s;\n }\n\n .btn-icon:hover {\n background: var(--mj-bg-surface-sunken);\n border-color: var(--mj-text-disabled);\n }\n\n .display-content {\n flex: 1;\n overflow: auto;\n min-height: 0;\n display: flex;\n flex-direction: column;\n }\n\n .html-iframe {\n width: 100%;\n border: none;\n background: var(--mj-bg-surface);\n display: block;\n }\n\n .markdown-content {\n flex: 1;\n padding: 20px;\n overflow: auto;\n min-height: 0;\n background: var(--mj-bg-surface);\n }\n\n .json-editor-container {\n flex: 1;\n overflow: auto;\n min-height: 0;\n }\n `]\n})\n@RegisterClass(BaseArtifactViewerPluginComponent, 'JsonArtifactViewerPlugin')\nexport class JsonArtifactViewerComponent extends BaseArtifactViewerPluginComponent implements OnInit, OnDestroy {\n @ViewChild('htmlFrame') htmlFrame?: ElementRef<HTMLIFrameElement>;\n\n public jsonContent = '';\n public displayMarkdown: string | null = null;\n public displayHtml: string | null = null;\n public htmlBlobUrl: SafeResourceUrl | null = null;\n private versionAttributes: MJArtifactVersionAttributeEntity[] = [];\n private unsafeBlobUrl: string | null = null; // Keep unsafe URL for cleanup\n\n /**\n * JSON artifacts always have content to display (JSON editor, displayHtml, or displayMarkdown)\n */\n public override get hasDisplayContent(): boolean {\n return true;\n }\n\n constructor(\n private cdr: ChangeDetectorRef,\n private sanitizer: DomSanitizer\n ) {\n super();\n }\n\n ngOnDestroy(): void {\n // Clean up blob URL to prevent memory leaks\n if (this.unsafeBlobUrl) {\n URL.revokeObjectURL(this.unsafeBlobUrl);\n this.unsafeBlobUrl = null;\n this.htmlBlobUrl = null;\n }\n }\n\n async ngOnInit(): Promise<void> {\n this.jsonContent = this.getContent();\n\n // Load version attributes to check for extract rules\n await this.loadVersionAttributes();\n\n // Trigger change detection after async load\n this.cdr.detectChanges();\n }\n\n /**\n * Override to return true when showing extracted displayHtml or displayMarkdown.\n * Returns false when showing raw JSON editor (no extract rules available).\n */\n public override get isShowingElevatedDisplay(): boolean {\n return !!(this.displayHtml || this.displayMarkdown);\n }\n\n /**\n * Override to tell parent whether to show raw JSON tab.\n * When showing elevated display (markdown/HTML), return true so parent shows JSON tab.\n * When showing raw JSON editor, return false (no need for duplicate JSON tab).\n */\n public override get parentShouldShowRawContent(): boolean {\n return this.isShowingElevatedDisplay;\n }\n\n private async loadVersionAttributes(): Promise<void> {\n if (!this.artifactVersion?.ID) {\n console.log('📦 JSON Plugin: No artifactVersion.ID, skipping attribute load');\n return;\n }\n\n console.log(`📦 JSON Plugin: Loading attributes for version ID: ${this.artifactVersion.ID}`);\n\n try {\n const rv = new RunView();\n const result = await rv.RunView<MJArtifactVersionAttributeEntity>({\n EntityName: 'MJ: Artifact Version Attributes',\n ExtraFilter: `ArtifactVersionID='${this.artifactVersion.ID}'`,\n ResultType: 'entity_object'\n });\n\n console.log(`📦 JSON Plugin: RunView completed. Success=${result.Success}, Results count=${result.Results?.length || 0}`);\n\n if (result.Success && result.Results) {\n this.versionAttributes = result.Results;\n\n console.log(`📦 JSON Plugin: Loaded ${this.versionAttributes.length} attributes for version ${this.artifactVersion.ID}`);\n console.log(`📦 Attributes:`, this.versionAttributes.map(a => ({ name: a.Name, hasValue: !!a.Value })));\n\n // Check for displayHtml and displayMarkdown attributes (from extract rules)\n // Priority: displayHtml > displayMarkdown\n const displayHtmlAttr = this.versionAttributes.find(a => a.Name?.toLowerCase() === 'displayhtml');\n const displayMarkdownAttr = this.versionAttributes.find(a => a.Name?.toLowerCase() === 'displaymarkdown');\n\n console.log(`📦 displayHtmlAttr:`, displayHtmlAttr ? { name: displayHtmlAttr.Name, valueLength: displayHtmlAttr.Value?.length } : 'not found');\n console.log(`📦 displayMarkdownAttr:`, displayMarkdownAttr ? { name: displayMarkdownAttr.Name, valueLength: displayMarkdownAttr.Value?.length } : 'not found');\n\n // Parse attribute values - fix \"null\" string bug\n this.displayHtml = this.parseAttributeValue(displayHtmlAttr?.Value);\n this.displayMarkdown = this.parseAttributeValue(displayMarkdownAttr?.Value);\n\n // Clean up double-escaped characters in HTML (from LLM generation)\n if (this.displayHtml) {\n this.displayHtml = this.cleanEscapedCharacters(this.displayHtml);\n }\n\n // Create blob URL for HTML to avoid srcdoc sanitization issues\n if (this.displayHtml) {\n const blob = new Blob([this.displayHtml], { type: 'text/html' });\n this.unsafeBlobUrl = URL.createObjectURL(blob);\n // Sanitize the blob URL so Angular trusts it in the iframe\n this.htmlBlobUrl = this.sanitizer.bypassSecurityTrustResourceUrl(this.unsafeBlobUrl);\n }\n\n // Note: Markdown rendering is now handled by <mj-markdown> component in template\n\n console.log(`📦 JSON Plugin: displayHtml=${!!this.displayHtml} (${this.displayHtml?.length || 0} chars), displayMarkdown=${!!this.displayMarkdown} (${this.displayMarkdown?.length || 0} chars)`);\n console.log(`📦 isShowingElevatedDisplay=${this.isShowingElevatedDisplay}`);\n } else {\n console.log(`📦 JSON Plugin: No attributes found or query failed. Success=${result.Success}, ResultsLength=${result.Results?.length}`);\n }\n } catch (err) {\n console.error('📦 JSON Plugin: Error loading version attributes:', err);\n }\n }\n\n private parseAttributeValue(value: string | null | undefined): string | null {\n if (!value) return null;\n\n // Fix bug: Some extractors return string \"null\" instead of actual null\n if (value === 'null' || value.trim() === '') {\n return null;\n }\n\n try {\n // Try to parse as JSON first\n const parsed = JSON.parse(value);\n if (typeof parsed === 'string') {\n // Check if parsed string is also \"null\"\n if (parsed === 'null' || parsed.trim() === '') {\n return null;\n }\n return parsed;\n }\n return JSON.stringify(parsed, null, 2);\n } catch {\n // If not valid JSON, return as-is (unless it's \"null\")\n return value === 'null' ? null : value;\n }\n }\n\n onIframeLoad(): void {\n // Inject base styles if HTML doesn't have them\n if (this.htmlFrame) {\n const iframe = this.htmlFrame.nativeElement;\n const iframeDoc = iframe.contentDocument || iframe.contentWindow?.document;\n\n if (iframeDoc) {\n // Check if HTML already has styles\n const hasStyles = iframeDoc.querySelector('style') || iframeDoc.querySelector('link[rel=\"stylesheet\"]');\n\n if (!hasStyles) {\n // Inject minimal base styles for better defaults\n const style = iframeDoc.createElement('style');\n style.textContent = `\n body {\n font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;\n line-height: 1.6;\n color: #333;\n margin: 20px;\n padding: 0;\n }\n h1, h2, h3 { color: #2c3e50; margin-top: 1.5em; margin-bottom: 0.5em; }\n h1 { font-size: 2em; border-bottom: 2px solid #3498db; padding-bottom: 0.3em; }\n h2 { font-size: 1.5em; }\n table { border-collapse: collapse; width: 100%; margin: 1em 0; }\n th, td { border: 1px solid #ddd; padding: 8px; text-align: left; }\n th { background-color: #f8f9fa; font-weight: 600; }\n pre { background: #f6f8fa; padding: 16px; border-radius: 6px; overflow-x: auto; }\n code { background: #f6f8fa; padding: 2px 6px; border-radius: 3px; font-family: monospace; }\n `;\n iframeDoc.head.appendChild(style);\n }\n\n // Inject width guardrails to prevent iframe content from causing horizontal overflow\n const widthOverride = iframeDoc.createElement('style');\n widthOverride.textContent = `\n html, body {\n max-width: 100% !important;\n overflow-x: hidden !important;\n }\n body {\n margin: 20px 10px 5px 20px !important; /* top right bottom left */\n padding: 0 !important;\n box-sizing: border-box !important;\n }\n img, svg, table, pre {\n max-width: 100% !important;\n }\n `;\n iframeDoc.head.appendChild(widthOverride);\n\n console.log('📦 Iframe loaded, hasStyles:', !!hasStyles);\n\n // Auto-resize iframe to fit content\n this.resizeIframeToContent();\n }\n }\n }\n\n private resizeIframeToContent(): void {\n if (this.htmlFrame) {\n const iframe = this.htmlFrame.nativeElement;\n const iframeDoc = iframe.contentDocument || iframe.contentWindow?.document;\n\n if (iframeDoc && iframeDoc.body) {\n // Get the actual content height\n const contentHeight = Math.max(\n iframeDoc.body.scrollHeight,\n iframeDoc.body.offsetHeight,\n iframeDoc.documentElement.scrollHeight,\n iframeDoc.documentElement.offsetHeight\n );\n\n // Set iframe height to match content (with a bit of padding)\n iframe.style.height = `${contentHeight + 20}px`;\n\n console.log('📦 Iframe resized - Height:', contentHeight + 20, 'px');\n }\n }\n }\n\n openInNewWindow(): void {\n if (this.displayHtml) {\n const newWindow = window.open('', '_blank');\n if (newWindow) {\n newWindow.document.write(this.displayHtml);\n newWindow.document.close();\n }\n }\n }\n\n printHtml(): void {\n if (this.htmlFrame) {\n const iframe = this.htmlFrame.nativeElement;\n const iframeWindow = iframe.contentWindow;\n if (iframeWindow) {\n iframeWindow.focus();\n iframeWindow.print();\n }\n }\n }\n\n onCopy(): void {\n // Copy based on what's being displayed - prioritize displayHtml\n const content = this.displayHtml || this.displayMarkdown || this.jsonContent;\n if (content) {\n navigator.clipboard.writeText(content).then(() => {\n console.log('✅ Copied content to clipboard');\n }).catch(err => {\n console.error('Failed to copy to clipboard:', err);\n });\n }\n }\n\n /**\n * Clean up double-escaped characters that appear in LLM-generated HTML\n * Removes literal \"\\\\n\", \"\\\\t\", and \"\\\\\\\"\" which cause rendering issues\n */\n private cleanEscapedCharacters(html: string): string {\n // Remove escaped quotes (\\\" becomes \")\n let cleaned = html.replace(/\\\\\"/g, '\"');\n\n // Remove escaped newlines (\\\\n becomes nothing)\n // HTML doesn't need whitespace for formatting, and these cause display issues\n cleaned = cleaned.replace(/\\\\n/g, '');\n\n // Remove escaped tabs\n cleaned = cleaned.replace(/\\\\t/g, '');\n\n // Remove double-escaped tabs\n cleaned = cleaned.replace(/\\\\\\\\t/g, '');\n\n // Remove double-escaped newlines\n cleaned = cleaned.replace(/\\\\\\\\n/g, '');\n\n return cleaned;\n }\n}\n"]}
|
package/dist/public-api.d.ts
CHANGED
|
@@ -13,4 +13,5 @@ export * from './lib/components/plugins/html-artifact-viewer.component';
|
|
|
13
13
|
export * from './lib/components/plugins/svg-artifact-viewer.component';
|
|
14
14
|
export * from './lib/components/plugins/component-artifact-viewer.component';
|
|
15
15
|
export * from './lib/components/plugins/data-artifact-viewer.component';
|
|
16
|
+
export * from './lib/components/plugins/component-feedback-panel/component-feedback-panel.component';
|
|
16
17
|
//# sourceMappingURL=public-api.d.ts.map
|
package/dist/public-api.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"public-api.d.ts","sourceRoot":"","sources":["../src/public-api.ts"],"names":[],"mappings":"AAKA,cAAc,wBAAwB,CAAC;AAGvC,cAAc,sCAAsC,CAAC;AAGrD,cAAc,mDAAmD,CAAC;AAGlE,cAAc,iDAAiD,CAAC;AAGhE,cAAc,wDAAwD,CAAC;AAGvE,cAAc,kDAAkD,CAAC;AACjE,cAAc,qDAAqD,CAAC;AACpE,cAAc,kDAAkD,CAAC;AAGjE,cAAc,yDAAyD,CAAC;AACxE,cAAc,yDAAyD,CAAC;AACxE,cAAc,6DAA6D,CAAC;AAC5E,cAAc,yDAAyD,CAAC;AACxE,cAAc,wDAAwD,CAAC;AACvE,cAAc,8DAA8D,CAAC;AAC7E,cAAc,yDAAyD,CAAC"}
|
|
1
|
+
{"version":3,"file":"public-api.d.ts","sourceRoot":"","sources":["../src/public-api.ts"],"names":[],"mappings":"AAKA,cAAc,wBAAwB,CAAC;AAGvC,cAAc,sCAAsC,CAAC;AAGrD,cAAc,mDAAmD,CAAC;AAGlE,cAAc,iDAAiD,CAAC;AAGhE,cAAc,wDAAwD,CAAC;AAGvE,cAAc,kDAAkD,CAAC;AACjE,cAAc,qDAAqD,CAAC;AACpE,cAAc,kDAAkD,CAAC;AAGjE,cAAc,yDAAyD,CAAC;AACxE,cAAc,yDAAyD,CAAC;AACxE,cAAc,6DAA6D,CAAC;AAC5E,cAAc,yDAAyD,CAAC;AACxE,cAAc,wDAAwD,CAAC;AACvE,cAAc,8DAA8D,CAAC;AAC7E,cAAc,yDAAyD,CAAC;AACxE,cAAc,sFAAsF,CAAC"}
|
package/dist/public-api.js
CHANGED
|
@@ -23,4 +23,5 @@ export * from './lib/components/plugins/html-artifact-viewer.component';
|
|
|
23
23
|
export * from './lib/components/plugins/svg-artifact-viewer.component';
|
|
24
24
|
export * from './lib/components/plugins/component-artifact-viewer.component';
|
|
25
25
|
export * from './lib/components/plugins/data-artifact-viewer.component';
|
|
26
|
+
export * from './lib/components/plugins/component-feedback-panel/component-feedback-panel.component';
|
|
26
27
|
//# sourceMappingURL=public-api.js.map
|
package/dist/public-api.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"public-api.js","sourceRoot":"","sources":["../src/public-api.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,SAAS;AACT,cAAc,wBAAwB,CAAC;AAEvC,WAAW;AACX,cAAc,sCAAsC,CAAC;AAErD,aAAa;AACb,cAAc,mDAAmD,CAAC;AAElE,iBAAiB;AACjB,cAAc,iDAAiD,CAAC;AAEhE,8EAA8E;AAC9E,cAAc,wDAAwD,CAAC;AAEvE,gCAAgC;AAChC,cAAc,kDAAkD,CAAC;AACjE,cAAc,qDAAqD,CAAC;AACpE,cAAc,kDAAkD,CAAC;AAEjE,oBAAoB;AACpB,cAAc,yDAAyD,CAAC;AACxE,cAAc,yDAAyD,CAAC;AACxE,cAAc,6DAA6D,CAAC;AAC5E,cAAc,yDAAyD,CAAC;AACxE,cAAc,wDAAwD,CAAC;AACvE,cAAc,8DAA8D,CAAC;AAC7E,cAAc,yDAAyD,CAAC","sourcesContent":["/*\n * Public API Surface of @memberjunction/ng-artifacts\n */\n\n// Module\nexport * from './lib/artifacts.module';\n\n// Services\nexport * from './lib/services/artifact-icon.service';\n\n// Interfaces\nexport * from './lib/interfaces/artifact-viewer-plugin.interface';\n\n// Base component\nexport * from './lib/components/base-artifact-viewer.component';\n\n// Artifact type plugin viewer (loads appropriate plugin based on DriverClass)\nexport * from './lib/components/artifact-type-plugin-viewer.component';\n\n// Artifact viewer UI components\nexport * from './lib/components/artifact-viewer-panel.component';\nexport * from './lib/components/artifact-version-history.component';\nexport * from './lib/components/artifact-message-card.component';\n\n// Plugin components\nexport * from './lib/components/plugins/json-artifact-viewer.component';\nexport * from './lib/components/plugins/code-artifact-viewer.component';\nexport * from './lib/components/plugins/markdown-artifact-viewer.component';\nexport * from './lib/components/plugins/html-artifact-viewer.component';\nexport * from './lib/components/plugins/svg-artifact-viewer.component';\nexport * from './lib/components/plugins/component-artifact-viewer.component';\nexport * from './lib/components/plugins/data-artifact-viewer.component';\n"]}
|
|
1
|
+
{"version":3,"file":"public-api.js","sourceRoot":"","sources":["../src/public-api.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,SAAS;AACT,cAAc,wBAAwB,CAAC;AAEvC,WAAW;AACX,cAAc,sCAAsC,CAAC;AAErD,aAAa;AACb,cAAc,mDAAmD,CAAC;AAElE,iBAAiB;AACjB,cAAc,iDAAiD,CAAC;AAEhE,8EAA8E;AAC9E,cAAc,wDAAwD,CAAC;AAEvE,gCAAgC;AAChC,cAAc,kDAAkD,CAAC;AACjE,cAAc,qDAAqD,CAAC;AACpE,cAAc,kDAAkD,CAAC;AAEjE,oBAAoB;AACpB,cAAc,yDAAyD,CAAC;AACxE,cAAc,yDAAyD,CAAC;AACxE,cAAc,6DAA6D,CAAC;AAC5E,cAAc,yDAAyD,CAAC;AACxE,cAAc,wDAAwD,CAAC;AACvE,cAAc,8DAA8D,CAAC;AAC7E,cAAc,yDAAyD,CAAC;AACxE,cAAc,sFAAsF,CAAC","sourcesContent":["/*\n * Public API Surface of @memberjunction/ng-artifacts\n */\n\n// Module\nexport * from './lib/artifacts.module';\n\n// Services\nexport * from './lib/services/artifact-icon.service';\n\n// Interfaces\nexport * from './lib/interfaces/artifact-viewer-plugin.interface';\n\n// Base component\nexport * from './lib/components/base-artifact-viewer.component';\n\n// Artifact type plugin viewer (loads appropriate plugin based on DriverClass)\nexport * from './lib/components/artifact-type-plugin-viewer.component';\n\n// Artifact viewer UI components\nexport * from './lib/components/artifact-viewer-panel.component';\nexport * from './lib/components/artifact-version-history.component';\nexport * from './lib/components/artifact-message-card.component';\n\n// Plugin components\nexport * from './lib/components/plugins/json-artifact-viewer.component';\nexport * from './lib/components/plugins/code-artifact-viewer.component';\nexport * from './lib/components/plugins/markdown-artifact-viewer.component';\nexport * from './lib/components/plugins/html-artifact-viewer.component';\nexport * from './lib/components/plugins/svg-artifact-viewer.component';\nexport * from './lib/components/plugins/component-artifact-viewer.component';\nexport * from './lib/components/plugins/data-artifact-viewer.component';\nexport * from './lib/components/plugins/component-feedback-panel/component-feedback-panel.component';\n"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@memberjunction/ng-artifacts",
|
|
3
|
-
"version": "5.
|
|
3
|
+
"version": "5.12.0",
|
|
4
4
|
"description": "MemberJunction: Artifact viewer plugin system for rendering different artifact types (JSON, Code, Markdown, HTML, SVG, Components)",
|
|
5
5
|
"main": "./dist/public-api.js",
|
|
6
6
|
"typings": "./dist/public-api.d.ts",
|
|
@@ -32,19 +32,20 @@
|
|
|
32
32
|
"dependencies": {
|
|
33
33
|
"@angular/cdk": "21.1.3",
|
|
34
34
|
"@angular/forms": "21.1.3",
|
|
35
|
-
"@memberjunction/core": "5.
|
|
36
|
-
"@memberjunction/core-entities": "5.
|
|
37
|
-
"@memberjunction/global": "5.
|
|
38
|
-
"@memberjunction/interactive-component-types": "5.
|
|
39
|
-
"@memberjunction/ng-base-types": "5.
|
|
40
|
-
"@memberjunction/ng-code-editor": "5.
|
|
41
|
-
"@memberjunction/ng-notifications": "5.
|
|
42
|
-
"@memberjunction/ng-react": "5.
|
|
43
|
-
"@memberjunction/ng-
|
|
44
|
-
"@memberjunction/ng-
|
|
45
|
-
"@memberjunction/ng-
|
|
46
|
-
"@memberjunction/ng-
|
|
47
|
-
"@memberjunction/ng-
|
|
35
|
+
"@memberjunction/core": "5.12.0",
|
|
36
|
+
"@memberjunction/core-entities": "5.12.0",
|
|
37
|
+
"@memberjunction/global": "5.12.0",
|
|
38
|
+
"@memberjunction/interactive-component-types": "5.12.0",
|
|
39
|
+
"@memberjunction/ng-base-types": "5.12.0",
|
|
40
|
+
"@memberjunction/ng-code-editor": "5.12.0",
|
|
41
|
+
"@memberjunction/ng-notifications": "5.12.0",
|
|
42
|
+
"@memberjunction/ng-react": "5.12.0",
|
|
43
|
+
"@memberjunction/ng-pagination": "5.12.0",
|
|
44
|
+
"@memberjunction/ng-shared-generic": "5.12.0",
|
|
45
|
+
"@memberjunction/ng-query-viewer": "5.12.0",
|
|
46
|
+
"@memberjunction/ng-trees": "5.12.0",
|
|
47
|
+
"@memberjunction/ng-export-service": "5.12.0",
|
|
48
|
+
"@memberjunction/ng-markdown": "5.12.0",
|
|
48
49
|
"marked": "^17.0.1",
|
|
49
50
|
"rxjs": "^7.8.2",
|
|
50
51
|
"tslib": "^2.8.1"
|