@ovalbee/reportifact 0.0.2 → 0.0.3
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/README.md +15 -15
- package/dist/{Chart.vue_vue_type_style_index_0_lang-Bp14Es_r.js → Chart.vue_vue_type_style_index_0_lang-Bxrsp8Oz.js} +53 -43
- package/dist/{Chart.vue_vue_type_style_index_0_lang-Dj7m6i3v.cjs → Chart.vue_vue_type_style_index_0_lang-mN1IaQ_U.cjs} +1 -1
- package/dist/ImageGallery.vue_vue_type_style_index_0_lang-Ak_OUL_c.js +197 -0
- package/dist/ImageGallery.vue_vue_type_style_index_0_lang-Ch0UPxhs.cjs +1 -0
- package/dist/MetricCallout.vue_vue_type_style_index_0_lang-ANFFq7CE.js +62 -0
- package/dist/MetricCallout.vue_vue_type_style_index_0_lang-CT9lFI28.cjs +1 -0
- package/dist/MetricCards.vue_vue_type_style_index_0_lang-1hn2BMbU.js +46 -0
- package/dist/MetricCards.vue_vue_type_style_index_0_lang-BDU7pisC.cjs +1 -0
- package/dist/MetricsTable.vue_vue_type_style_index_0_lang-BfxK3vcz.js +140 -0
- package/dist/MetricsTable.vue_vue_type_style_index_0_lang-CS7xiHRk.cjs +1 -0
- package/dist/{Timeline.vue_vue_type_style_index_0_lang-BTA6fIp9.js → Timeline.vue_vue_type_style_index_0_lang-EmkZbKjQ.js} +9 -3
- package/dist/{Timeline.vue_vue_type_style_index_0_lang-CZ8Y2pXG.cjs → Timeline.vue_vue_type_style_index_0_lang-HOC43_F3.cjs} +2 -2
- package/dist/WidgetWrapper.vue_vue_type_style_index_0_lang-BY2t_Hvs.cjs +1 -0
- package/dist/WidgetWrapper.vue_vue_type_style_index_0_lang-BbnW8GXT.js +72 -0
- package/dist/portable/contracts.d.ts +6 -1
- package/dist/reportifact.cjs +24 -24
- package/dist/reportifact.js +1408 -1403
- package/dist/style.css +1 -1
- package/dist/widgets/Chart.vue.d.ts +7 -4
- package/dist/widgets/ImageGallery.vue.d.ts +7 -4
- package/dist/widgets/Markdown.vue.d.ts +1 -1
- package/dist/widgets/MetricCallout.vue.d.ts +5 -2
- package/dist/widgets/MetricCards.vue.d.ts +6 -3
- package/dist/widgets/MetricsTable.vue.d.ts +7 -4
- package/dist/widgets/ModelClassComparison.vue.d.ts +1 -1
- package/dist/widgets/ModelComparisonGallery.vue.d.ts +1 -1
- package/dist/widgets/Table.vue.d.ts +1 -1
- package/dist/widgets/Tensorboard.vue.d.ts +1 -1
- package/dist/widgets/Timeline.vue.d.ts +7 -4
- package/dist/widgets/WidgetWrapper.vue.d.ts +11 -5
- package/dist/widgets/chart.cjs +1 -1
- package/dist/widgets/chart.js +1 -1
- package/dist/widgets/image-gallery.cjs +1 -1
- package/dist/widgets/image-gallery.js +1 -1
- package/dist/widgets/metric-callout.cjs +1 -1
- package/dist/widgets/metric-callout.js +1 -1
- package/dist/widgets/metric-cards.cjs +1 -1
- package/dist/widgets/metric-cards.js +1 -1
- package/dist/widgets/metrics-table.cjs +1 -1
- package/dist/widgets/metrics-table.js +1 -1
- package/dist/widgets/timeline.cjs +1 -1
- package/dist/widgets/timeline.js +1 -1
- package/package.json +1 -6
- package/dist/ImageGallery.vue_vue_type_style_index_0_lang-BB4dG0CB.cjs +0 -1
- package/dist/ImageGallery.vue_vue_type_style_index_0_lang-DPY6mSdA.js +0 -191
- package/dist/MetricCallout.vue_vue_type_style_index_0_lang-BZbc-Wkf.js +0 -49
- package/dist/MetricCallout.vue_vue_type_style_index_0_lang-WpuALh8Z.cjs +0 -1
- package/dist/MetricCards.vue_vue_type_style_index_0_lang-CDPSu7no.cjs +0 -1
- package/dist/MetricCards.vue_vue_type_style_index_0_lang-CfxCCXmB.js +0 -33
- package/dist/MetricsTable.vue_vue_type_style_index_0_lang-BzrxoJW4.cjs +0 -1
- package/dist/MetricsTable.vue_vue_type_style_index_0_lang-CO9HvYfr.js +0 -132
- package/dist/WidgetWrapper.vue_vue_type_style_index_0_lang-BQQ4Vv5j.cjs +0 -1
- package/dist/WidgetWrapper.vue_vue_type_style_index_0_lang-D-oXqmI2.js +0 -59
- package/dist/entries/figure.d.ts +0 -1
- package/dist/portable/ReportifactFigure.vue.d.ts +0 -40
- package/dist/widgets/figure.cjs +0 -1
- package/dist/widgets/figure.d.ts +0 -6
- package/dist/widgets/figure.js +0 -84
package/dist/style.css
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
.reportifact{--reportifact-bg: #ffffff;--reportifact-toc-bg: #ffffff;--reportifact-bg-subtle: #f8fafc;--reportifact-bg-muted: #f1f5f9;--reportifact-bg-overlay: rgba(255, 255, 255, .9);--reportifact-text: #1f2937;--reportifact-text-muted: #64748b;--reportifact-text-faint: #94a3b8;--reportifact-border: #e2e8f0;--reportifact-error-bg: #fef2f2;--reportifact-error-text: #dc2626;--reportifact-highlight: #fef08a;--reportifact-accent: #0ea5e9;--reportifact-focus-border: #3b82f6;--reportifact-tone-low: #ef4444;--reportifact-tone-low-bg: #fee2e2;--reportifact-tone-low-border: #fecaca;--reportifact-tone-mid: #d97706;--reportifact-tone-mid-bg: #fef3c7;--reportifact-tone-mid-border: #fde68a;--reportifact-tone-high: #059669;--reportifact-tone-high-bg: #d1fae5;--reportifact-tone-high-border: #a7f3d0;--reportifact-widget-gap: 16px;--reportifact-section-gap: 32px;display:flex;flex-direction:column;color:var(--reportifact-text);font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,sans-serif;font-size:14px;line-height:1.5}.dark .reportifact{--reportifact-tone-low: #f06464;--reportifact-tone-low-bg: rgba(239, 68, 68, .16);--reportifact-tone-low-border: rgba(239, 68, 68, .32);--reportifact-tone-mid: #d99a2b;--reportifact-tone-mid-bg: rgba(217, 119, 6, .16);--reportifact-tone-mid-border: rgba(217, 119, 6, .32);--reportifact-tone-high: #41b883;--reportifact-tone-high-bg: rgba(16, 185, 129, .14);--reportifact-tone-high-border: rgba(16, 185, 129, .3)}.reportifact-skeleton-line{height:16px;border-radius:4px;background:linear-gradient(90deg,var(--reportifact-border) 25%,var(--reportifact-bg-muted) 50%,var(--reportifact-border) 75%);background-size:200% 100%;animation:reportifact-skeleton-pulse 1.5s ease-in-out infinite}.reportifact-skeleton-column{display:flex;flex-direction:column;gap:12px}@keyframes reportifact-skeleton-pulse{0%{background-position:200% 0}to{background-position:-200% 0}}.reportifact-widget-host{width:100%;min-width:0}.reportifact-widget-wrapper,.reportifact-widget-content{position:relative}.reportifact-widget-error{padding:16px;background:var(--reportifact-error-bg);border-radius:8px}.reportifact-widget-error-message{color:var(--reportifact-error-text);font-size:14px;text-align:center}.reportifact-chart-skeleton{background:var(--reportifact-bg);border:1px solid var(--reportifact-border);border-radius:8px;padding:16px;height:var(--reportifact-chart-height);display:flex;flex-direction:column;overflow:hidden}.reportifact-chart-skeleton-body{width:100%;flex:1;min-height:0;border-radius:4px}.reportifact-chart-container{background:var(--reportifact-bg);border:1px solid var(--reportifact-border);border-radius:8px;padding:16px;width:100%;height:var(--reportifact-chart-height);display:flex;flex-direction:column;overflow:hidden}.reportifact-chart{width:100%;flex:1;min-height:0}.reportifact-metric-cards{display:grid;grid-template-columns:repeat(4,minmax(92px,1fr));gap:10px;padding:12px;border:1px solid var(--reportifact-border);border-radius:8px;background:var(--reportifact-bg)}.reportifact-metric-card{position:relative;min-height:148px;overflow:hidden;padding:14px;border:1px solid var(--reportifact-border);border-radius:6px;background:var(--reportifact-bg)}.reportifact-metric-card-fill{position:absolute;inset:auto 0 0;border-top:1px solid transparent}.reportifact-metric-card--low .reportifact-metric-card-fill{border-top-color:var(--reportifact-tone-low-border);background:var(--reportifact-tone-low-bg)}.reportifact-metric-card--mid .reportifact-metric-card-fill{border-top-color:var(--reportifact-tone-mid-border);background:var(--reportifact-tone-mid-bg)}.reportifact-metric-card--high .reportifact-metric-card-fill{border-top-color:var(--reportifact-tone-high-border);background:var(--reportifact-tone-high-bg)}.reportifact-metric-card-label,.reportifact-metric-card-value,.reportifact-metric-card-description{position:relative;z-index:1}.reportifact-metric-card-label{display:block;color:var(--reportifact-text-muted);font-size:11px;font-weight:750;letter-spacing:.04em;text-transform:uppercase}.reportifact-metric-card-value{display:block;margin-top:10px;font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;font-size:26px;line-height:1}.reportifact-metric-card--low .reportifact-metric-card-value{color:var(--reportifact-tone-low)}.reportifact-metric-card--mid .reportifact-metric-card-value{color:var(--reportifact-tone-mid)}.reportifact-metric-card--high .reportifact-metric-card-value{color:var(--reportifact-tone-high)}.reportifact-metric-card-description{margin:8px 0 0;color:var(--reportifact-text-muted);font-size:12px}@media (max-width: 720px){.reportifact-metric-cards{grid-template-columns:repeat(2,minmax(92px,1fr))}}.reportifact-metric-callout{overflow:hidden;border:1px solid var(--reportifact-border);border-radius:8px;background:var(--reportifact-bg)}.reportifact-metric-callout-header{display:grid;grid-template-columns:148px minmax(0,1fr);gap:14px;align-items:center;padding:14px 15px;border-bottom:1px solid var(--reportifact-border);background:var(--reportifact-bg-subtle)}.reportifact-metric-callout-label{color:var(--reportifact-text-muted);font-size:11px;font-weight:750;letter-spacing:.04em;text-transform:uppercase}.reportifact-metric-callout-value{display:block;margin-top:5px;font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;font-size:28px;line-height:1}.reportifact-metric-callout-value--low{color:var(--reportifact-tone-low)}.reportifact-metric-callout-value--mid{color:var(--reportifact-tone-mid)}.reportifact-metric-callout-value--high{color:var(--reportifact-tone-high)}.reportifact-metric-callout-description,.reportifact-metric-callout-body{color:var(--reportifact-text-muted)}.reportifact-metric-callout-body{padding:13px 15px}.rm-skeleton{display:flex;flex-direction:column;gap:10px;padding:4px 0}.rm-skeleton-row{display:flex;gap:10px;align-items:center}.rm-title{font-weight:bolder;font-size:13px;margin-bottom:8px;color:var(--reportifact-text)}.rm-metrics{display:grid;grid-template-columns:auto 3.8em 1fr;align-items:center;gap:8px 10px;padding:2px 0;max-width:400px}.rm-metrics--with-pct{grid-template-columns:auto 3.8em 1fr auto}.rm-row{display:contents}.rm-name{font-weight:500;font-size:13px;white-space:nowrap;color:var(--reportifact-text)}.rm-value{font-family:monospace;font-size:13px;text-align:right;color:var(--reportifact-text-muted)}.rm-bar-track{height:6px;background:var(--reportifact-bg-muted);border-radius:3px;overflow:hidden;min-width:40px}.rm-bar-fill{height:100%;background:var(--reportifact-accent);border-radius:3px;transition:width .3s ease}.rm-pct{font-size:12px;color:var(--reportifact-text-muted);white-space:nowrap;min-width:3.2em;text-align:right}.rm-empty{grid-column:1 / -1;color:var(--reportifact-text-faint);font-style:italic;font-size:13px}.rm-table{width:100%;max-width:400px;border-collapse:collapse;font-size:13px}.rm-table th{text-align:left;padding:6px 8px;font-weight:500;border-bottom:1px solid var(--reportifact-border);color:var(--reportifact-text-muted);font-size:12px}.rm-table td{padding:5px 8px;border-bottom:1px solid var(--reportifact-border);color:var(--reportifact-text)}.rm-table tr:last-child td{border-bottom:none}.rm-table tbody tr:hover td{background:var(--reportifact-bg-subtle)}.reportifact-timeline-container{position:relative;background:var(--reportifact-bg);border:1px solid var(--reportifact-border);border-radius:8px;padding:16px;width:100%;height:var(--reportifact-chart-height);display:flex;flex-direction:column;overflow:hidden}.reportifact-timeline-toolbar{position:absolute;top:12px;right:12px;z-index:1;display:flex;gap:2px;border:1px solid var(--reportifact-border);border-radius:6px;padding:2px;background:var(--reportifact-bg-subtle)}.reportifact-timeline-mode{border:none;background:transparent;color:var(--reportifact-text-muted);font-size:11px;line-height:1;padding:4px 8px;border-radius:4px;cursor:pointer}.reportifact-timeline-mode.is-active{background:var(--reportifact-bg);color:var(--reportifact-text);box-shadow:0 1px 2px #00000014}.reportifact-image-gallery{container-type:inline-size;display:grid;gap:12px;grid-template-columns:repeat(4,minmax(0,1fr))}.reportifact-image-gallery-tile{min-width:0}.reportifact-image-gallery-frame{position:relative;aspect-ratio:var(--reportifact-gallery-aspect-ratio);overflow:hidden;border-radius:8px;background:var(--reportifact-bg-subtle)}.reportifact-image-gallery-image,.reportifact-image-gallery-overlay{position:absolute;top:0;right:0;bottom:0;left:0;width:100%;height:100%}.reportifact-image-gallery-image--contain{object-fit:contain}.reportifact-image-gallery-image--cover{object-fit:cover}.reportifact-image-gallery-overlay{pointer-events:none}.reportifact-image-gallery-empty{display:flex;height:100%;align-items:center;justify-content:center;color:var(--reportifact-text-muted);font-size:12px}.reportifact-image-gallery-skeleton{height:100%;min-height:160px}.reportifact-image-gallery-more{margin-top:10px;padding:0;border:0;background:transparent;color:var(--reportifact-accent);cursor:pointer;font:inherit;font-size:14px;font-weight:600;text-align:left}.reportifact-image-gallery-more:hover{text-decoration:underline}@container (max-width: 720px){.reportifact-image-gallery{grid-template-columns:repeat(2,minmax(0,1fr))}}.reportifact-figure{width:100%;margin:24px 0}.reportifact-figure-title{margin-bottom:10px;font-size:15px;font-weight:700}.reportifact-figure-skeleton{display:flex;min-height:280px;flex-direction:column;gap:16px;padding:16px;border:1px solid var(--reportifact-border);border-radius:8px;background:var(--reportifact-bg)}.reportifact-figure-fallback{display:block;width:100%;height:auto;border:1px solid var(--reportifact-border);border-radius:8px;background:var(--reportifact-bg)}.reportifact-figure-runtime-fallback{display:none}.reportifact-widget-host:has(.reportifact-widget-error)>.reportifact-widget-wrapper:has(+.reportifact-figure-runtime-fallback){display:none}.reportifact-widget-host:has(.reportifact-widget-error)>.reportifact-figure-runtime-fallback{display:block}.reportifact-figure-caption{display:flex;flex-wrap:wrap;justify-content:space-between;gap:8px 16px;margin-top:8px;color:var(--reportifact-text-muted, #64748b);font-size:13px}.reportifact-figure-caption a{color:var(--reportifact-accent, #0ea5e9)}pre code.hljs{display:block;overflow-x:auto;padding:1em}code.hljs{padding:3px 5px}/*!
|
|
1
|
+
.reportifact{--reportifact-bg: #ffffff;--reportifact-toc-bg: #ffffff;--reportifact-bg-subtle: #f8fafc;--reportifact-bg-muted: #f1f5f9;--reportifact-bg-overlay: rgba(255, 255, 255, .9);--reportifact-text: #1f2937;--reportifact-text-muted: #64748b;--reportifact-text-faint: #94a3b8;--reportifact-border: #e2e8f0;--reportifact-error-bg: #fef2f2;--reportifact-error-text: #dc2626;--reportifact-highlight: #fef08a;--reportifact-accent: #0ea5e9;--reportifact-focus-border: #3b82f6;--reportifact-tone-low: #ef4444;--reportifact-tone-low-bg: #fee2e2;--reportifact-tone-low-border: #fecaca;--reportifact-tone-mid: #d97706;--reportifact-tone-mid-bg: #fef3c7;--reportifact-tone-mid-border: #fde68a;--reportifact-tone-high: #059669;--reportifact-tone-high-bg: #d1fae5;--reportifact-tone-high-border: #a7f3d0;--reportifact-widget-gap: 16px;--reportifact-section-gap: 32px;display:flex;flex-direction:column;color:var(--reportifact-text);font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,sans-serif;font-size:14px;line-height:1.5}.dark .reportifact{--reportifact-tone-low: #f06464;--reportifact-tone-low-bg: rgba(239, 68, 68, .16);--reportifact-tone-low-border: rgba(239, 68, 68, .32);--reportifact-tone-mid: #d99a2b;--reportifact-tone-mid-bg: rgba(217, 119, 6, .16);--reportifact-tone-mid-border: rgba(217, 119, 6, .32);--reportifact-tone-high: #41b883;--reportifact-tone-high-bg: rgba(16, 185, 129, .14);--reportifact-tone-high-border: rgba(16, 185, 129, .3)}.reportifact-skeleton-line{height:16px;border-radius:4px;background:linear-gradient(90deg,var(--reportifact-border) 25%,var(--reportifact-bg-muted) 50%,var(--reportifact-border) 75%);background-size:200% 100%;animation:reportifact-skeleton-pulse 1.5s ease-in-out infinite}.reportifact-skeleton-column{display:flex;flex-direction:column;gap:12px}@keyframes reportifact-skeleton-pulse{0%{background-position:200% 0}to{background-position:-200% 0}}.reportifact-widget-host{width:100%;min-width:0}.reportifact-widget-wrapper{position:relative;width:100%;min-width:0;margin:0}.reportifact-widget-content{position:relative}.reportifact-widget-error{padding:16px;background:var(--reportifact-error-bg);border-radius:8px}.reportifact-widget-error-message{color:var(--reportifact-error-text);font-size:14px;text-align:center}.reportifact-figure-caption{display:flex;flex-wrap:wrap;justify-content:center;gap:8px 16px;margin-top:8px;color:var(--reportifact-text-muted, #64748b);font-size:13px;text-align:center}.reportifact-figure-caption a{color:var(--reportifact-accent, #0ea5e9)}.reportifact-chart-skeleton{background:var(--reportifact-bg);border:1px solid var(--reportifact-border);border-radius:8px;padding:16px;height:var(--reportifact-chart-height);display:flex;flex-direction:column;overflow:hidden}.reportifact-chart-skeleton-body{width:100%;flex:1;min-height:0;border-radius:4px}.reportifact-chart-container{background:var(--reportifact-bg);border:1px solid var(--reportifact-border);border-radius:8px;padding:16px;width:100%;height:var(--reportifact-chart-height);display:flex;flex-direction:column;overflow:hidden}.reportifact-chart{width:100%;flex:1;min-height:0}.reportifact-metric-cards{display:grid;grid-template-columns:repeat(4,minmax(92px,1fr));gap:10px;padding:12px;border:1px solid var(--reportifact-border);border-radius:8px;background:var(--reportifact-bg)}.reportifact-metric-card{position:relative;min-height:148px;overflow:hidden;padding:14px;border:1px solid var(--reportifact-border);border-radius:6px;background:var(--reportifact-bg)}.reportifact-metric-card-fill{position:absolute;inset:auto 0 0;border-top:1px solid transparent}.reportifact-metric-card--low .reportifact-metric-card-fill{border-top-color:var(--reportifact-tone-low-border);background:var(--reportifact-tone-low-bg)}.reportifact-metric-card--mid .reportifact-metric-card-fill{border-top-color:var(--reportifact-tone-mid-border);background:var(--reportifact-tone-mid-bg)}.reportifact-metric-card--high .reportifact-metric-card-fill{border-top-color:var(--reportifact-tone-high-border);background:var(--reportifact-tone-high-bg)}.reportifact-metric-card-label,.reportifact-metric-card-value,.reportifact-metric-card-description{position:relative;z-index:1}.reportifact-metric-card-label{display:block;color:var(--reportifact-text-muted);font-size:11px;font-weight:750;letter-spacing:.04em;text-transform:uppercase}.reportifact-metric-card-value{display:block;margin-top:10px;font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;font-size:26px;line-height:1}.reportifact-metric-card--low .reportifact-metric-card-value{color:var(--reportifact-tone-low)}.reportifact-metric-card--mid .reportifact-metric-card-value{color:var(--reportifact-tone-mid)}.reportifact-metric-card--high .reportifact-metric-card-value{color:var(--reportifact-tone-high)}.reportifact-metric-card-description{margin:8px 0 0;color:var(--reportifact-text-muted);font-size:12px}@media (max-width: 720px){.reportifact-metric-cards{grid-template-columns:repeat(2,minmax(92px,1fr))}}.reportifact-metric-callout{overflow:hidden;border:1px solid var(--reportifact-border);border-radius:8px;background:var(--reportifact-bg)}.reportifact-metric-callout-header{display:grid;grid-template-columns:148px minmax(0,1fr);gap:14px;align-items:center;padding:14px 15px;border-bottom:1px solid var(--reportifact-border);background:var(--reportifact-bg-subtle)}.reportifact-metric-callout-label{color:var(--reportifact-text-muted);font-size:11px;font-weight:750;letter-spacing:.04em;text-transform:uppercase}.reportifact-metric-callout-value{display:block;margin-top:5px;font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;font-size:28px;line-height:1}.reportifact-metric-callout-value--low{color:var(--reportifact-tone-low)}.reportifact-metric-callout-value--mid{color:var(--reportifact-tone-mid)}.reportifact-metric-callout-value--high{color:var(--reportifact-tone-high)}.reportifact-metric-callout-description,.reportifact-metric-callout-body{color:var(--reportifact-text-muted)}.reportifact-metric-callout-body{padding:13px 15px}.rm-card{width:100%;padding:16px;overflow-x:auto;background:var(--reportifact-bg);border:1px solid var(--reportifact-border);border-radius:8px}.rm-skeleton{display:flex;flex-direction:column;gap:10px;padding:4px 0}.rm-skeleton-row{display:flex;gap:10px;align-items:center}.rm-title{font-weight:bolder;font-size:13px;margin-bottom:8px;color:var(--reportifact-text)}.rm-metrics{display:grid;grid-template-columns:auto 3.8em 1fr;align-items:center;gap:8px 10px;padding:2px 0;max-width:400px}.rm-metrics--with-pct{grid-template-columns:auto 3.8em 1fr auto}.rm-row{display:contents}.rm-name{font-weight:500;font-size:13px;white-space:nowrap;color:var(--reportifact-text)}.rm-value{font-family:monospace;font-size:13px;text-align:right;color:var(--reportifact-text-muted)}.rm-bar-track{height:6px;background:var(--reportifact-bg-muted);border-radius:3px;overflow:hidden;min-width:40px}.rm-bar-fill{height:100%;background:var(--reportifact-accent);border-radius:3px;transition:width .3s ease}.rm-pct{font-size:12px;color:var(--reportifact-text-muted);white-space:nowrap;min-width:3.2em;text-align:right}.rm-empty{grid-column:1 / -1;color:var(--reportifact-text-faint);font-style:italic;font-size:13px}.rm-table{width:100%;border-collapse:collapse;font-size:13px}.rm-table th{text-align:left;padding:6px 8px;font-weight:500;border-bottom:1px solid var(--reportifact-border);color:var(--reportifact-text-muted);font-size:12px}.rm-table td{padding:5px 8px;border-bottom:1px solid var(--reportifact-border);color:var(--reportifact-text)}.rm-table tr:last-child td{border-bottom:none}.rm-table tbody tr:hover td{background:var(--reportifact-bg-subtle)}.reportifact-timeline-container{position:relative;background:var(--reportifact-bg);border:1px solid var(--reportifact-border);border-radius:8px;padding:16px;width:100%;height:var(--reportifact-chart-height);display:flex;flex-direction:column;overflow:hidden}.reportifact-timeline-toolbar{position:absolute;top:12px;right:12px;z-index:1;display:flex;gap:2px;border:1px solid var(--reportifact-border);border-radius:6px;padding:2px;background:var(--reportifact-bg-subtle)}.reportifact-timeline-mode{border:none;background:transparent;color:var(--reportifact-text-muted);font-size:11px;line-height:1;padding:4px 8px;border-radius:4px;cursor:pointer}.reportifact-timeline-mode.is-active{background:var(--reportifact-bg);color:var(--reportifact-text);box-shadow:0 1px 2px #00000014}.reportifact-image-gallery{container-type:inline-size;display:grid;gap:12px;grid-template-columns:repeat(4,minmax(0,1fr))}.reportifact-image-gallery-tile{min-width:0}.reportifact-image-gallery-frame{position:relative;aspect-ratio:var(--reportifact-gallery-aspect-ratio);overflow:hidden;border-radius:8px;background:var(--reportifact-bg-subtle)}.reportifact-image-gallery-image,.reportifact-image-gallery-overlay{position:absolute;top:0;right:0;bottom:0;left:0;width:100%;height:100%}.reportifact-image-gallery-image--contain{object-fit:contain}.reportifact-image-gallery-image--cover{object-fit:cover}.reportifact-image-gallery-overlay{pointer-events:none}.reportifact-image-gallery-empty{display:flex;height:100%;align-items:center;justify-content:center;color:var(--reportifact-text-muted);font-size:12px}.reportifact-image-gallery-skeleton{height:100%;min-height:160px}.reportifact-image-gallery-more{margin-top:10px;padding:0;border:0;background:transparent;color:var(--reportifact-accent);cursor:pointer;font:inherit;font-size:14px;font-weight:600;text-align:left}.reportifact-image-gallery-more:hover{text-decoration:underline}@container (max-width: 720px){.reportifact-image-gallery{grid-template-columns:repeat(2,minmax(0,1fr))}}pre code.hljs{display:block;overflow-x:auto;padding:1em}code.hljs{padding:3px 5px}/*!
|
|
2
2
|
Theme: StackOverflow Light
|
|
3
3
|
Description: Light theme as used on stackoverflow.com
|
|
4
4
|
Author: stackoverflow.com
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ChartType } from './chart-config';
|
|
2
|
-
import { ReportifactChartData } from '../portable/contracts';
|
|
3
|
-
type __VLS_Props = {
|
|
2
|
+
import { ReportifactChartData, ReportifactWidgetFrameProps } from '../portable/contracts';
|
|
3
|
+
type __VLS_Props = ReportifactWidgetFrameProps & {
|
|
4
4
|
/** Legacy/full-report resource URL. */
|
|
5
5
|
url?: string;
|
|
6
6
|
/** Portable resource URL. */
|
|
@@ -20,7 +20,10 @@ declare const _default: import('vue').DefineComponent<__VLS_Props, {
|
|
|
20
20
|
}>, {
|
|
21
21
|
options: Record<string, unknown>;
|
|
22
22
|
data: undefined;
|
|
23
|
-
url: string;
|
|
24
23
|
src: string;
|
|
25
|
-
|
|
24
|
+
url: string;
|
|
25
|
+
caption: string;
|
|
26
|
+
sourceHref: string;
|
|
27
|
+
sourceLabel: string;
|
|
28
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLElement>;
|
|
26
29
|
export default _default;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { WidgetItem } from '../utils/parseIndexMd';
|
|
2
2
|
import { ReportifactMediaResolver } from '../mediaResolver';
|
|
3
|
-
import { ReportifactImageGalleryData } from '../portable/contracts';
|
|
4
|
-
type __VLS_Props = {
|
|
3
|
+
import { ReportifactWidgetFrameProps, ReportifactImageGalleryData } from '../portable/contracts';
|
|
4
|
+
type __VLS_Props = ReportifactWidgetFrameProps & {
|
|
5
5
|
widget?: WidgetItem;
|
|
6
6
|
url?: string;
|
|
7
7
|
src?: string;
|
|
@@ -18,9 +18,12 @@ declare const _default: import('vue').DefineComponent<__VLS_Props, {
|
|
|
18
18
|
}>, {
|
|
19
19
|
options: Record<string, unknown>;
|
|
20
20
|
data: ReportifactImageGalleryData;
|
|
21
|
-
url: string;
|
|
22
21
|
widget: WidgetItem;
|
|
23
22
|
src: string;
|
|
23
|
+
url: string;
|
|
24
|
+
caption: string;
|
|
25
|
+
sourceHref: string;
|
|
26
|
+
sourceLabel: string;
|
|
24
27
|
mediaResolver: ReportifactMediaResolver;
|
|
25
|
-
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {},
|
|
28
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLElement>;
|
|
26
29
|
export default _default;
|
|
@@ -4,5 +4,5 @@ type __VLS_Props = {
|
|
|
4
4
|
};
|
|
5
5
|
declare const _default: import('vue').DefineComponent<__VLS_Props, {
|
|
6
6
|
refresh(): void;
|
|
7
|
-
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {},
|
|
7
|
+
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLElement>;
|
|
8
8
|
export default _default;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { WidgetItem } from '../utils/parseIndexMd';
|
|
2
|
-
import { ReportifactMetricCalloutData } from '../portable/contracts';
|
|
3
|
-
type __VLS_Props = {
|
|
2
|
+
import { ReportifactMetricCalloutData, ReportifactWidgetFrameProps } from '../portable/contracts';
|
|
3
|
+
type __VLS_Props = ReportifactWidgetFrameProps & {
|
|
4
4
|
widget?: WidgetItem;
|
|
5
5
|
data?: ReportifactMetricCalloutData;
|
|
6
6
|
label?: string;
|
|
@@ -14,6 +14,9 @@ declare const _default: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {
|
|
|
14
14
|
data: ReportifactMetricCalloutData;
|
|
15
15
|
value: string | number;
|
|
16
16
|
widget: WidgetItem;
|
|
17
|
+
caption: string;
|
|
18
|
+
sourceHref: string;
|
|
19
|
+
sourceLabel: string;
|
|
17
20
|
description: string;
|
|
18
21
|
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLElement>;
|
|
19
22
|
export default _default;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { WidgetItem } from '../utils/parseIndexMd';
|
|
2
|
-
import { ReportifactMetricCardData } from '../portable/contracts';
|
|
3
|
-
type __VLS_Props = {
|
|
2
|
+
import { ReportifactMetricCardData, ReportifactWidgetFrameProps } from '../portable/contracts';
|
|
3
|
+
type __VLS_Props = ReportifactWidgetFrameProps & {
|
|
4
4
|
widget?: WidgetItem;
|
|
5
5
|
content?: string;
|
|
6
6
|
data?: ReportifactMetricCardData[];
|
|
@@ -9,5 +9,8 @@ declare const _default: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {
|
|
|
9
9
|
data: ReportifactMetricCardData[];
|
|
10
10
|
widget: WidgetItem;
|
|
11
11
|
content: string;
|
|
12
|
-
|
|
12
|
+
caption: string;
|
|
13
|
+
sourceHref: string;
|
|
14
|
+
sourceLabel: string;
|
|
15
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLElement>;
|
|
13
16
|
export default _default;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ReportifactMetricsTableData } from '../portable/contracts';
|
|
2
|
-
type __VLS_Props = {
|
|
1
|
+
import { ReportifactWidgetFrameProps, ReportifactMetricsTableData } from '../portable/contracts';
|
|
2
|
+
type __VLS_Props = ReportifactWidgetFrameProps & {
|
|
3
3
|
url?: string;
|
|
4
4
|
src?: string;
|
|
5
5
|
data?: ReportifactMetricsTableData;
|
|
@@ -11,7 +11,10 @@ declare const _default: import('vue').DefineComponent<__VLS_Props, {
|
|
|
11
11
|
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
|
|
12
12
|
options: Record<string, unknown>;
|
|
13
13
|
data: ReportifactMetricsTableData;
|
|
14
|
-
url: string;
|
|
15
14
|
src: string;
|
|
16
|
-
|
|
15
|
+
url: string;
|
|
16
|
+
caption: string;
|
|
17
|
+
sourceHref: string;
|
|
18
|
+
sourceLabel: string;
|
|
19
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLElement>;
|
|
17
20
|
export default _default;
|
|
@@ -3,5 +3,5 @@ type __VLS_Props = {
|
|
|
3
3
|
};
|
|
4
4
|
declare const _default: import('vue').DefineComponent<__VLS_Props, {
|
|
5
5
|
refresh(): void;
|
|
6
|
-
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {},
|
|
6
|
+
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLElement>;
|
|
7
7
|
export default _default;
|
|
@@ -11,5 +11,5 @@ declare const _default: import('vue').DefineComponent<__VLS_Props, {
|
|
|
11
11
|
"row-click": (payload: unknown) => any;
|
|
12
12
|
}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
13
13
|
"onRow-click"?: ((payload: unknown) => any) | undefined;
|
|
14
|
-
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {},
|
|
14
|
+
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLElement>;
|
|
15
15
|
export default _default;
|
|
@@ -14,5 +14,5 @@ declare const _default: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {
|
|
|
14
14
|
"onRow-click"?: ((payload: unknown) => any) | undefined;
|
|
15
15
|
}>, {
|
|
16
16
|
options: TableOptions;
|
|
17
|
-
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {},
|
|
17
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLElement>;
|
|
18
18
|
export default _default;
|
|
@@ -9,5 +9,5 @@ type __VLS_Props = {
|
|
|
9
9
|
declare function refresh(): void;
|
|
10
10
|
declare const _default: import('vue').DefineComponent<__VLS_Props, {
|
|
11
11
|
refresh: typeof refresh;
|
|
12
|
-
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {},
|
|
12
|
+
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLElement>;
|
|
13
13
|
export default _default;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ReportifactTimelineData } from '../portable/contracts';
|
|
2
|
-
type __VLS_Props = {
|
|
1
|
+
import { ReportifactWidgetFrameProps, ReportifactTimelineData } from '../portable/contracts';
|
|
2
|
+
type __VLS_Props = ReportifactWidgetFrameProps & {
|
|
3
3
|
url?: string;
|
|
4
4
|
src?: string;
|
|
5
5
|
data?: ReportifactTimelineData;
|
|
@@ -15,7 +15,10 @@ declare const _default: import('vue').DefineComponent<__VLS_Props, {
|
|
|
15
15
|
}>, {
|
|
16
16
|
options: Record<string, unknown>;
|
|
17
17
|
data: ReportifactTimelineData;
|
|
18
|
-
url: string;
|
|
19
18
|
src: string;
|
|
20
|
-
|
|
19
|
+
url: string;
|
|
20
|
+
caption: string;
|
|
21
|
+
sourceHref: string;
|
|
22
|
+
sourceLabel: string;
|
|
23
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLElement>;
|
|
21
24
|
export default _default;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
import { ReportifactWidgetFrameProps } from '../portable/contracts';
|
|
2
|
+
type __VLS_Props = ReportifactWidgetFrameProps & {
|
|
3
|
+
loading?: boolean;
|
|
4
|
+
error?: string | null;
|
|
4
5
|
showSkeleton?: boolean;
|
|
5
6
|
};
|
|
6
7
|
declare function __VLS_template(): {
|
|
@@ -13,12 +14,17 @@ declare function __VLS_template(): {
|
|
|
13
14
|
default?(_: {}): any;
|
|
14
15
|
};
|
|
15
16
|
refs: {};
|
|
16
|
-
rootEl:
|
|
17
|
+
rootEl: HTMLElement;
|
|
17
18
|
};
|
|
18
19
|
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
19
20
|
declare const __VLS_component: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
|
|
21
|
+
caption: string;
|
|
22
|
+
sourceHref: string;
|
|
23
|
+
sourceLabel: string;
|
|
24
|
+
loading: boolean;
|
|
25
|
+
error: string | null;
|
|
20
26
|
showSkeleton: boolean;
|
|
21
|
-
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {},
|
|
27
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLElement>;
|
|
22
28
|
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
23
29
|
export default _default;
|
|
24
30
|
type __VLS_WithTemplateSlots<T, S> = T & {
|
package/dist/widgets/chart.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../Chart.vue_vue_type_style_index_0_lang-
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../Chart.vue_vue_type_style_index_0_lang-mN1IaQ_U.cjs");exports.ReportifactChart=e._sfc_main;exports.default=e._sfc_main;
|
package/dist/widgets/chart.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../ImageGallery.vue_vue_type_style_index_0_lang-
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../ImageGallery.vue_vue_type_style_index_0_lang-Ch0UPxhs.cjs");exports.ReportifactImageGallery=e._sfc_main;exports.default=e._sfc_main;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../MetricCallout.vue_vue_type_style_index_0_lang-
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../MetricCallout.vue_vue_type_style_index_0_lang-CT9lFI28.cjs");exports.ReportifactMetricCallout=e._sfc_main;exports.default=e._sfc_main;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../MetricCards.vue_vue_type_style_index_0_lang-
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../MetricCards.vue_vue_type_style_index_0_lang-BDU7pisC.cjs");exports.ReportifactMetricCards=e._sfc_main;exports.default=e._sfc_main;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../MetricsTable.vue_vue_type_style_index_0_lang-
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../MetricsTable.vue_vue_type_style_index_0_lang-CS7xiHRk.cjs");exports.ReportifactMetricsTable=e._sfc_main;exports.default=e._sfc_main;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../Timeline.vue_vue_type_style_index_0_lang-
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../Timeline.vue_vue_type_style_index_0_lang-HOC43_F3.cjs");exports.ReportifactTimeline=e._sfc_main;exports.default=e._sfc_main;
|
package/dist/widgets/timeline.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ovalbee/reportifact",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.3",
|
|
4
4
|
"description": "Vue 3 component + Express middleware for reports from Parquet files via DuckDB",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/reportifact.js",
|
|
@@ -17,11 +17,6 @@
|
|
|
17
17
|
"import": "./dist/widgets/host.js",
|
|
18
18
|
"require": "./dist/widgets/host.cjs"
|
|
19
19
|
},
|
|
20
|
-
"./widgets/figure": {
|
|
21
|
-
"types": "./dist/entries/figure.d.ts",
|
|
22
|
-
"import": "./dist/widgets/figure.js",
|
|
23
|
-
"require": "./dist/widgets/figure.cjs"
|
|
24
|
-
},
|
|
25
20
|
"./widgets/chart": {
|
|
26
21
|
"types": "./dist/entries/chart.d.ts",
|
|
27
22
|
"import": "./dist/widgets/chart.js",
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";const a=require("vue"),$=require("./useFetch-BfOAq-Kg.cjs"),x=require("./WidgetWrapper.vue_vue_type_style_index_0_lang-BQQ4Vv5j.cjs"),G={class:"reportifact-image-gallery"},D={class:"reportifact-image-gallery-frame"},j=["src"],P=["src"],W={key:2,class:"reportifact-image-gallery-empty"},m=4,H=a.defineComponent({__name:"ImageGallery",props:{widget:{default:void 0},url:{default:void 0},src:{default:void 0},data:{default:void 0},options:{default:void 0},mediaResolver:{type:Function,default:void 0}},emits:["row-click"],setup(_,{expose:h,emit:S}){const r=_,l=a.ref([]),g=a.ref([]),B=a.computed(()=>r.data===void 0?r.src??r.url??"":""),n=a.computed(()=>{var e;return r.options??((e=r.widget)==null?void 0:e.options)??{}}),E=a.computed(()=>g.value.slice(0,m)),N=a.computed(()=>l.value.length>m&&l.value.some(e=>e.asset)),d=a.computed(()=>String(n.value.fit??"contain")==="cover"?"cover":"contain"),C=a.computed(()=>String(n.value.aspectRatio??"4 / 3")),v=a.computed(()=>A(n.value.overlayOpacity,.7)),y=a.computed(()=>n.value.drawTags!==!1&&n.value.drawTags!=="false"),{loading:R,error:V,fetchData:U}=$.useFetch(B,{async onSuccess(e){await u(await e.json())}}),b=a.computed(()=>r.data===void 0&&R.value),I=a.computed(()=>r.data!==void 0?null:r.src||r.url?V.value:"Resource not found in asset");async function u(e){l.value=F(e),await p()}a.watch(()=>r.data,e=>{e!==void 0&&u(e)},{immediate:!0,deep:!0});const O=S;a.watch(()=>[r.mediaResolver,v.value],()=>{p()});async function p(){const e=l.value.slice(0,m);g.value=await Promise.all(e.map(z))}async function z(e,t){const o=await f({role:"image",item:e,index:t,src:e.imageSrc,asset:e.asset}),s=await f({role:"overlay",item:e,index:t,src:e.overlaySrc,annotation:e.annotation,imageAsset:e.asset,imageSrc:e.imageSrc,imageUrl:o,drawTags:y.value});return{key:`${t}:${e.asset??e.imageSrc??""}:${e.annotation??e.overlaySrc??""}`,imageUrl:o,overlayUrl:s,overlayOpacity:v.value}}async function f(e){return!e.src&&!e.asset&&!e.annotation?null:r.mediaResolver?T(await r.mediaResolver({role:e.role,index:e.index,item:e.item,src:e.src,asset:e.asset,annotation:e.annotation,imageAsset:e.imageAsset,imageSrc:e.imageSrc,imageUrl:e.imageUrl,drawTags:e.drawTags,defaultResolve:t=>t})):e.src??null}function T(e){return typeof e=="string"?e||null:e&&typeof e=="object"?e.url??null:null}function A(e,t){const o=typeof e=="number"?e:Number(e);return Number.isFinite(o)?Math.max(0,Math.min(1,o)):t}function F(e){const t=i(e.assets),o=i(e.annotations),s=i(e.images),w=i(e.overlays),L=Math.max(t.length,o.length,s.length,w.length);return Array.from({length:L},(J,c)=>({imageSrc:s[c],overlaySrc:w[c],asset:t[c],annotation:o[c]}))}function i(e){return Array.isArray(e)?e.map(t=>typeof t=="string"?t:""):[]}function M(){const e=l.value.filter(t=>k(t.asset)).map(t=>({asset:t.asset,layers:k(t.annotation)?[{annotation:t.annotation}]:[]}));e.length&&O("row-click",{action:"asset-preview",title:"Images",assets:e,layout:"collection",click:"preview",grid:4,drawTags:y.value})}function k(e){return typeof e=="string"&&e.length>0}return h({refresh(){r.data!==void 0?u(r.data):U()}}),(e,t)=>(a.openBlock(),a.createBlock(x._sfc_main,{loading:b.value,error:I.value},{skeleton:a.withCtx(()=>[a.createElementVNode("div",G,[(a.openBlock(),a.createElementBlock(a.Fragment,null,a.renderList(4,o=>a.createElementVNode("div",{key:o,class:"reportifact-image-gallery-tile"},[...t[0]||(t[0]=[a.createElementVNode("div",{class:"reportifact-skeleton-line reportifact-image-gallery-skeleton"},null,-1)])])),64))])]),default:a.withCtx(()=>[a.createElementVNode("div",null,[a.createElementVNode("div",{class:"reportifact-image-gallery",style:a.normalizeStyle({"--reportifact-gallery-aspect-ratio":C.value})},[(a.openBlock(!0),a.createElementBlock(a.Fragment,null,a.renderList(E.value,o=>(a.openBlock(),a.createElementBlock("article",{key:o.key,class:"reportifact-image-gallery-tile"},[a.createElementVNode("div",D,[o.imageUrl?(a.openBlock(),a.createElementBlock("img",{key:0,class:a.normalizeClass(["reportifact-image-gallery-image",`reportifact-image-gallery-image--${d.value}`]),src:o.imageUrl,alt:"Gallery image",loading:"lazy"},null,10,j)):a.createCommentVNode("",!0),o.overlayUrl?(a.openBlock(),a.createElementBlock("img",{key:1,class:a.normalizeClass(["reportifact-image-gallery-overlay",`reportifact-image-gallery-image--${d.value}`]),src:o.overlayUrl,alt:"Gallery overlay",style:a.normalizeStyle({opacity:o.overlayOpacity}),loading:"lazy"},null,14,P)):a.createCommentVNode("",!0),o.imageUrl?a.createCommentVNode("",!0):(a.openBlock(),a.createElementBlock("div",W," Media unavailable "))])]))),128))],4),N.value?(a.openBlock(),a.createElementBlock("button",{key:0,type:"button",class:"reportifact-image-gallery-more",onClick:M}," Show all "+a.toDisplayString(l.value.length)+" images ",1)):a.createCommentVNode("",!0)])]),_:1},8,["loading","error"]))}});exports._sfc_main=H;
|
|
@@ -1,191 +0,0 @@
|
|
|
1
|
-
import { defineComponent as X, ref as U, computed as o, watch as b, createBlock as Y, openBlock as l, withCtx as I, createElementVNode as s, createElementBlock as n, createCommentVNode as m, normalizeStyle as O, Fragment as T, renderList as A, normalizeClass as M, toDisplayString as Z } from "vue";
|
|
2
|
-
import { u as q } from "./useFetch-CHQm_TmB.js";
|
|
3
|
-
import { _ as aa } from "./WidgetWrapper.vue_vue_type_style_index_0_lang-D-oXqmI2.js";
|
|
4
|
-
const ea = { class: "reportifact-image-gallery" }, ta = { class: "reportifact-image-gallery-frame" }, ra = ["src"], oa = ["src"], la = {
|
|
5
|
-
key: 2,
|
|
6
|
-
class: "reportifact-image-gallery-empty"
|
|
7
|
-
}, d = 4, ga = /* @__PURE__ */ X({
|
|
8
|
-
__name: "ImageGallery",
|
|
9
|
-
props: {
|
|
10
|
-
widget: { default: void 0 },
|
|
11
|
-
url: { default: void 0 },
|
|
12
|
-
src: { default: void 0 },
|
|
13
|
-
data: { default: void 0 },
|
|
14
|
-
options: { default: void 0 },
|
|
15
|
-
mediaResolver: { type: Function, default: void 0 }
|
|
16
|
-
},
|
|
17
|
-
emits: ["row-click"],
|
|
18
|
-
setup($, { expose: z, emit: C }) {
|
|
19
|
-
const r = $, i = U([]), f = U([]), F = o(() => r.data === void 0 ? r.src ?? r.url ?? "" : ""), c = o(() => {
|
|
20
|
-
var a;
|
|
21
|
-
return r.options ?? ((a = r.widget) == null ? void 0 : a.options) ?? {};
|
|
22
|
-
}), G = o(() => f.value.slice(0, d)), L = o(
|
|
23
|
-
() => i.value.length > d && i.value.some((a) => a.asset)
|
|
24
|
-
), p = o(() => String(c.value.fit ?? "contain") === "cover" ? "cover" : "contain"), N = o(() => String(c.value.aspectRatio ?? "4 / 3")), w = o(() => J(c.value.overlayOpacity, 0.7)), h = o(
|
|
25
|
-
() => c.value.drawTags !== !1 && c.value.drawTags !== "false"
|
|
26
|
-
), { loading: x, error: B, fetchData: D } = q(F, {
|
|
27
|
-
async onSuccess(a) {
|
|
28
|
-
await y(await a.json());
|
|
29
|
-
}
|
|
30
|
-
}), E = o(() => r.data === void 0 && x.value), j = o(() => r.data !== void 0 ? null : r.src || r.url ? B.value : "Resource not found in asset");
|
|
31
|
-
async function y(a) {
|
|
32
|
-
i.value = K(a), await _();
|
|
33
|
-
}
|
|
34
|
-
b(
|
|
35
|
-
() => r.data,
|
|
36
|
-
(a) => {
|
|
37
|
-
a !== void 0 && y(a);
|
|
38
|
-
},
|
|
39
|
-
{ immediate: !0, deep: !0 }
|
|
40
|
-
);
|
|
41
|
-
const P = C;
|
|
42
|
-
b(
|
|
43
|
-
() => [r.mediaResolver, w.value],
|
|
44
|
-
() => {
|
|
45
|
-
_();
|
|
46
|
-
}
|
|
47
|
-
);
|
|
48
|
-
async function _() {
|
|
49
|
-
const a = i.value.slice(0, d);
|
|
50
|
-
f.value = await Promise.all(a.map(V));
|
|
51
|
-
}
|
|
52
|
-
async function V(a, e) {
|
|
53
|
-
const t = await k({
|
|
54
|
-
role: "image",
|
|
55
|
-
item: a,
|
|
56
|
-
index: e,
|
|
57
|
-
src: a.imageSrc,
|
|
58
|
-
asset: a.asset
|
|
59
|
-
}), u = await k({
|
|
60
|
-
role: "overlay",
|
|
61
|
-
item: a,
|
|
62
|
-
index: e,
|
|
63
|
-
src: a.overlaySrc,
|
|
64
|
-
annotation: a.annotation,
|
|
65
|
-
imageAsset: a.asset,
|
|
66
|
-
imageSrc: a.imageSrc,
|
|
67
|
-
imageUrl: t,
|
|
68
|
-
drawTags: h.value
|
|
69
|
-
});
|
|
70
|
-
return {
|
|
71
|
-
key: `${e}:${a.asset ?? a.imageSrc ?? ""}:${a.annotation ?? a.overlaySrc ?? ""}`,
|
|
72
|
-
imageUrl: t,
|
|
73
|
-
overlayUrl: u,
|
|
74
|
-
overlayOpacity: w.value
|
|
75
|
-
};
|
|
76
|
-
}
|
|
77
|
-
async function k(a) {
|
|
78
|
-
return !a.src && !a.asset && !a.annotation ? null : r.mediaResolver ? H(await r.mediaResolver({
|
|
79
|
-
role: a.role,
|
|
80
|
-
index: a.index,
|
|
81
|
-
item: a.item,
|
|
82
|
-
src: a.src,
|
|
83
|
-
asset: a.asset,
|
|
84
|
-
annotation: a.annotation,
|
|
85
|
-
imageAsset: a.imageAsset,
|
|
86
|
-
imageSrc: a.imageSrc,
|
|
87
|
-
imageUrl: a.imageUrl,
|
|
88
|
-
drawTags: a.drawTags,
|
|
89
|
-
defaultResolve: (e) => e
|
|
90
|
-
})) : a.src ?? null;
|
|
91
|
-
}
|
|
92
|
-
function H(a) {
|
|
93
|
-
return typeof a == "string" ? a || null : a && typeof a == "object" ? a.url ?? null : null;
|
|
94
|
-
}
|
|
95
|
-
function J(a, e) {
|
|
96
|
-
const t = typeof a == "number" ? a : Number(a);
|
|
97
|
-
return Number.isFinite(t) ? Math.max(0, Math.min(1, t)) : e;
|
|
98
|
-
}
|
|
99
|
-
function K(a) {
|
|
100
|
-
const e = g(a.assets), t = g(a.annotations), u = g(a.images), R = g(a.overlays), W = Math.max(e.length, t.length, u.length, R.length);
|
|
101
|
-
return Array.from({ length: W }, (na, v) => ({
|
|
102
|
-
imageSrc: u[v],
|
|
103
|
-
overlaySrc: R[v],
|
|
104
|
-
asset: e[v],
|
|
105
|
-
annotation: t[v]
|
|
106
|
-
}));
|
|
107
|
-
}
|
|
108
|
-
function g(a) {
|
|
109
|
-
return Array.isArray(a) ? a.map((e) => typeof e == "string" ? e : "") : [];
|
|
110
|
-
}
|
|
111
|
-
function Q() {
|
|
112
|
-
const a = i.value.filter((e) => S(e.asset)).map((e) => ({
|
|
113
|
-
asset: e.asset,
|
|
114
|
-
layers: S(e.annotation) ? [{ annotation: e.annotation }] : []
|
|
115
|
-
}));
|
|
116
|
-
a.length && P("row-click", {
|
|
117
|
-
action: "asset-preview",
|
|
118
|
-
title: "Images",
|
|
119
|
-
assets: a,
|
|
120
|
-
layout: "collection",
|
|
121
|
-
click: "preview",
|
|
122
|
-
grid: 4,
|
|
123
|
-
drawTags: h.value
|
|
124
|
-
});
|
|
125
|
-
}
|
|
126
|
-
function S(a) {
|
|
127
|
-
return typeof a == "string" && a.length > 0;
|
|
128
|
-
}
|
|
129
|
-
return z({
|
|
130
|
-
refresh() {
|
|
131
|
-
r.data !== void 0 ? y(r.data) : D();
|
|
132
|
-
}
|
|
133
|
-
}), (a, e) => (l(), Y(aa, {
|
|
134
|
-
loading: E.value,
|
|
135
|
-
error: j.value
|
|
136
|
-
}, {
|
|
137
|
-
skeleton: I(() => [
|
|
138
|
-
s("div", ea, [
|
|
139
|
-
(l(), n(T, null, A(4, (t) => s("div", {
|
|
140
|
-
key: t,
|
|
141
|
-
class: "reportifact-image-gallery-tile"
|
|
142
|
-
}, [...e[0] || (e[0] = [
|
|
143
|
-
s("div", { class: "reportifact-skeleton-line reportifact-image-gallery-skeleton" }, null, -1)
|
|
144
|
-
])])), 64))
|
|
145
|
-
])
|
|
146
|
-
]),
|
|
147
|
-
default: I(() => [
|
|
148
|
-
s("div", null, [
|
|
149
|
-
s("div", {
|
|
150
|
-
class: "reportifact-image-gallery",
|
|
151
|
-
style: O({ "--reportifact-gallery-aspect-ratio": N.value })
|
|
152
|
-
}, [
|
|
153
|
-
(l(!0), n(T, null, A(G.value, (t) => (l(), n("article", {
|
|
154
|
-
key: t.key,
|
|
155
|
-
class: "reportifact-image-gallery-tile"
|
|
156
|
-
}, [
|
|
157
|
-
s("div", ta, [
|
|
158
|
-
t.imageUrl ? (l(), n("img", {
|
|
159
|
-
key: 0,
|
|
160
|
-
class: M(["reportifact-image-gallery-image", `reportifact-image-gallery-image--${p.value}`]),
|
|
161
|
-
src: t.imageUrl,
|
|
162
|
-
alt: "Gallery image",
|
|
163
|
-
loading: "lazy"
|
|
164
|
-
}, null, 10, ra)) : m("", !0),
|
|
165
|
-
t.overlayUrl ? (l(), n("img", {
|
|
166
|
-
key: 1,
|
|
167
|
-
class: M(["reportifact-image-gallery-overlay", `reportifact-image-gallery-image--${p.value}`]),
|
|
168
|
-
src: t.overlayUrl,
|
|
169
|
-
alt: "Gallery overlay",
|
|
170
|
-
style: O({ opacity: t.overlayOpacity }),
|
|
171
|
-
loading: "lazy"
|
|
172
|
-
}, null, 14, oa)) : m("", !0),
|
|
173
|
-
t.imageUrl ? m("", !0) : (l(), n("div", la, " Media unavailable "))
|
|
174
|
-
])
|
|
175
|
-
]))), 128))
|
|
176
|
-
], 4),
|
|
177
|
-
L.value ? (l(), n("button", {
|
|
178
|
-
key: 0,
|
|
179
|
-
type: "button",
|
|
180
|
-
class: "reportifact-image-gallery-more",
|
|
181
|
-
onClick: Q
|
|
182
|
-
}, " Show all " + Z(i.value.length) + " images ", 1)) : m("", !0)
|
|
183
|
-
])
|
|
184
|
-
]),
|
|
185
|
-
_: 1
|
|
186
|
-
}, 8, ["loading", "error"]));
|
|
187
|
-
}
|
|
188
|
-
});
|
|
189
|
-
export {
|
|
190
|
-
ga as _
|
|
191
|
-
};
|
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
import { defineComponent as v, computed as a, createElementBlock as s, openBlock as n, createElementVNode as l, createCommentVNode as f, toDisplayString as i, normalizeClass as _ } from "vue";
|
|
2
|
-
import { m as h } from "./markdownTable-B5207r3E.js";
|
|
3
|
-
const g = { class: "reportifact-metric-callout" }, b = { class: "reportifact-metric-callout-header" }, w = { class: "reportifact-metric-callout-label" }, k = { class: "reportifact-metric-callout-description" }, y = ["innerHTML"], S = /* @__PURE__ */ v({
|
|
4
|
-
__name: "MetricCallout",
|
|
5
|
-
props: {
|
|
6
|
-
widget: { default: void 0 },
|
|
7
|
-
data: { default: void 0 },
|
|
8
|
-
label: { default: void 0 },
|
|
9
|
-
value: { default: void 0 },
|
|
10
|
-
description: { default: void 0 },
|
|
11
|
-
html: { default: void 0 }
|
|
12
|
-
},
|
|
13
|
-
setup(d) {
|
|
14
|
-
const t = d, u = a(() => {
|
|
15
|
-
var e, o;
|
|
16
|
-
return String(t.label ?? ((e = t.data) == null ? void 0 : e.label) ?? ((o = t.widget) == null ? void 0 : o.options.label) ?? "Metric");
|
|
17
|
-
}), c = a(() => {
|
|
18
|
-
var e, o;
|
|
19
|
-
return String(t.value ?? ((e = t.data) == null ? void 0 : e.value) ?? ((o = t.widget) == null ? void 0 : o.options.value) ?? "");
|
|
20
|
-
}), p = a(() => {
|
|
21
|
-
var e, o;
|
|
22
|
-
return String(
|
|
23
|
-
t.description ?? ((e = t.data) == null ? void 0 : e.description) ?? ((o = t.widget) == null ? void 0 : o.options.description) ?? ""
|
|
24
|
-
);
|
|
25
|
-
}), r = a(() => {
|
|
26
|
-
var e, o;
|
|
27
|
-
return t.html ?? ((e = t.data) == null ? void 0 : e.html) ?? ((o = t.widget) == null ? void 0 : o.html) ?? "";
|
|
28
|
-
}), m = a(() => h(c.value));
|
|
29
|
-
return (e, o) => (n(), s("section", g, [
|
|
30
|
-
l("header", b, [
|
|
31
|
-
l("div", null, [
|
|
32
|
-
l("div", w, i(u.value), 1),
|
|
33
|
-
l("strong", {
|
|
34
|
-
class: _(["reportifact-metric-callout-value", `reportifact-metric-callout-value--${m.value}`])
|
|
35
|
-
}, i(c.value), 3)
|
|
36
|
-
]),
|
|
37
|
-
l("div", k, i(p.value), 1)
|
|
38
|
-
]),
|
|
39
|
-
r.value ? (n(), s("div", {
|
|
40
|
-
key: 0,
|
|
41
|
-
class: "reportifact-metric-callout-body reportifact-markdown",
|
|
42
|
-
innerHTML: r.value
|
|
43
|
-
}, null, 8, y)) : f("", !0)
|
|
44
|
-
]));
|
|
45
|
-
}
|
|
46
|
-
});
|
|
47
|
-
export {
|
|
48
|
-
S as _
|
|
49
|
-
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";const e=require("vue"),s=require("./markdownTable-Cbn1Du3L.cjs"),u={class:"reportifact-metric-callout"},m={class:"reportifact-metric-callout-header"},p={class:"reportifact-metric-callout-label"},v={class:"reportifact-metric-callout-description"},_=["innerHTML"],f=e.defineComponent({__name:"MetricCallout",props:{widget:{default:void 0},data:{default:void 0},label:{default:void 0},value:{default:void 0},description:{default:void 0},html:{default:void 0}},setup(i){const t=i,r=e.computed(()=>{var o,a;return String(t.label??((o=t.data)==null?void 0:o.label)??((a=t.widget)==null?void 0:a.options.label)??"Metric")}),l=e.computed(()=>{var o,a;return String(t.value??((o=t.data)==null?void 0:o.value)??((a=t.widget)==null?void 0:a.options.value)??"")}),n=e.computed(()=>{var o,a;return String(t.description??((o=t.data)==null?void 0:o.description)??((a=t.widget)==null?void 0:a.options.description)??"")}),c=e.computed(()=>{var o,a;return t.html??((o=t.data)==null?void 0:o.html)??((a=t.widget)==null?void 0:a.html)??""}),d=e.computed(()=>s.metricTone(l.value));return(o,a)=>(e.openBlock(),e.createElementBlock("section",u,[e.createElementVNode("header",m,[e.createElementVNode("div",null,[e.createElementVNode("div",p,e.toDisplayString(r.value),1),e.createElementVNode("strong",{class:e.normalizeClass(["reportifact-metric-callout-value",`reportifact-metric-callout-value--${d.value}`])},e.toDisplayString(l.value),3)]),e.createElementVNode("div",v,e.toDisplayString(n.value),1)]),c.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:"reportifact-metric-callout-body reportifact-markdown",innerHTML:c.value},null,8,_)):e.createCommentVNode("",!0)]))}});exports._sfc_main=f;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";const e=require("vue"),a=require("./markdownTable-Cbn1Du3L.cjs"),i={class:"reportifact-metric-cards"},d={class:"reportifact-metric-card-label"},p={class:"reportifact-metric-card-value"},m={class:"reportifact-metric-card-description"},u=e.defineComponent({__name:"MetricCards",props:{widget:{default:void 0},content:{default:void 0},data:{default:void 0}},setup(n){const c=n,o=e.computed(()=>{var r;return c.data??a.parseMarkdownTable(c.content??((r=c.widget)==null?void 0:r.content)??"")}),l=a.metricTone,s=a.metricPercent;return(r,f)=>(e.openBlock(),e.createElementBlock("div",i,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.value,t=>(e.openBlock(),e.createElementBlock("article",{key:t.label,class:e.normalizeClass(["reportifact-metric-card",`reportifact-metric-card--${e.unref(l)(t.value)}`])},[e.createElementVNode("span",{class:"reportifact-metric-card-fill",style:e.normalizeStyle({height:`${e.unref(s)(t.value)}%`})},null,4),e.createElementVNode("span",d,e.toDisplayString(t.label),1),e.createElementVNode("strong",p,e.toDisplayString(t.value),1),e.createElementVNode("p",m,e.toDisplayString(t.description),1)],2))),128))]))}});exports._sfc_main=u;
|