@liiift-studio/sanity-visitor-insights 0.17.0 → 0.19.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/index.d.mts +24 -11
- package/dist/index.d.ts +24 -11
- package/dist/index.js +247 -71
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +251 -75
- package/dist/index.mjs.map +1 -1
- package/dist/{ranges-B_OrmcdP.d.mts → ranges-BUZuS1c-.d.mts} +10 -1
- package/dist/{ranges-B_OrmcdP.d.ts → ranges-BUZuS1c-.d.ts} +10 -1
- package/dist/server.d.mts +2 -2
- package/dist/server.d.ts +2 -2
- package/dist/server.js +3 -0
- package/dist/server.js.map +1 -1
- package/dist/server.mjs +3 -0
- package/dist/server.mjs.map +1 -1
- package/package.json +1 -1
- package/src/reportData.ts +10 -1
- package/src/server/reports/measurementHealth.ts +3 -0
- package/src/studio/CrossSourceTimeline.tsx +218 -51
- package/src/studio/Figure.tsx +67 -20
- package/src/studio/VisitorInsightsTool.tsx +59 -2
- package/src/studio/panels.test.tsx +84 -11
- package/src/studio/panels.tsx +23 -18
package/dist/index.d.mts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as sanity from 'sanity';
|
|
2
2
|
import React from 'react';
|
|
3
|
-
import { R as ReportEnvelope, a as ReportName, b as RangeKey, M as MetricValue, A as AcquisitionData, D as DiagnosticReport, J as JourneyData, c as MeasurementHealthData, T as TypefaceInterestData } from './ranges-
|
|
4
|
-
export { C as CaptureBasis, d as CaptureEstimate, e as CaptureModel, f as CheckStatus, g as Coverage, h as CrossSourceDay, i as DailyPoint, j as DateRange, k as DiagnosticCheck, E as EmailCampaign, l as EventCutover, m as JourneyOutcome, n as JourneyStep, L as LandingPage, o as LicenceTierRow, P as PREEXISTING, p as REPORT_NAMES, q as ReportError, S as SiteAnalyticsConfig, r as SourceName, s as SourceRow, t as SourceStatus, u as TimelineEvent, v as TypefaceInterestRow, U as UnavailableReason, w as coverageForRange, x as estimated, y as isReportName, z as ok, B as partial, F as previousRange, G as resolveRange, H as unavailable, I as validateSiteConfig, K as valueOrNull } from './ranges-
|
|
3
|
+
import { R as ReportEnvelope, a as ReportName, b as RangeKey, M as MetricValue, A as AcquisitionData, D as DiagnosticReport, J as JourneyData, c as MeasurementHealthData, T as TypefaceInterestData } from './ranges-BUZuS1c-.mjs';
|
|
4
|
+
export { C as CaptureBasis, d as CaptureEstimate, e as CaptureModel, f as CheckStatus, g as Coverage, h as CrossSourceDay, i as DailyPoint, j as DateRange, k as DiagnosticCheck, E as EmailCampaign, l as EventCutover, m as JourneyOutcome, n as JourneyStep, L as LandingPage, o as LicenceTierRow, P as PREEXISTING, p as REPORT_NAMES, q as ReportError, S as SiteAnalyticsConfig, r as SourceName, s as SourceRow, t as SourceStatus, u as TimelineEvent, v as TypefaceInterestRow, U as UnavailableReason, w as coverageForRange, x as estimated, y as isReportName, z as ok, B as partial, F as previousRange, G as resolveRange, H as unavailable, I as validateSiteConfig, K as valueOrNull } from './ranges-BUZuS1c-.mjs';
|
|
5
5
|
|
|
6
6
|
/**
|
|
7
7
|
* The Visitor Insights Studio tool.
|
|
@@ -342,24 +342,37 @@ interface SeriesPoint {
|
|
|
342
342
|
}
|
|
343
343
|
/** How a value should be written out. */
|
|
344
344
|
type SeriesUnit = 'count' | 'money' | 'percent';
|
|
345
|
-
/**
|
|
345
|
+
/**
|
|
346
|
+
* One row of the chart: one answer, with what a lossier source saw underneath it.
|
|
347
|
+
*
|
|
348
|
+
* A row shows a SINGLE line by default. Two peer lines make the reader reconcile before they get
|
|
349
|
+
* an answer, and at a glance a foundry owner wants "how much", not "here are two measurements that
|
|
350
|
+
* disagree". The disagreement is still drawn — as a filled region, and in full on hover — because
|
|
351
|
+
* hiding it entirely would switch off the alarm: the 24 August collapse was visible precisely
|
|
352
|
+
* because two lines came apart.
|
|
353
|
+
*/
|
|
346
354
|
interface Series {
|
|
347
355
|
key: string;
|
|
348
356
|
label: string;
|
|
349
|
-
/** Which upstream
|
|
357
|
+
/** Which upstream the LINE came from. */
|
|
350
358
|
source: 'GA4' | 'Vercel' | 'Sanity' | 'Mailchimp';
|
|
351
|
-
/**
|
|
352
|
-
* Whether the source sees everything. GA4 does not; the others do.
|
|
353
|
-
* Drives the dashed stroke and the uncertainty band rather than a footnote nobody reads.
|
|
354
|
-
*/
|
|
359
|
+
/** Whether the line's source sees everything. Drives the stroke and the wording. */
|
|
355
360
|
complete: boolean;
|
|
356
361
|
unit: SeriesUnit;
|
|
357
362
|
points: SeriesPoint[];
|
|
358
363
|
/**
|
|
359
|
-
*
|
|
360
|
-
*
|
|
364
|
+
* What a lossier source saw of the same thing.
|
|
365
|
+
*
|
|
366
|
+
* Drawn as a filled region between the two, NOT as a symmetric uncertainty band. There is no
|
|
367
|
+
* doubt about the traffic here: Vercel counted it server-side. What is uncertain is how much of
|
|
368
|
+
* it the analytics could see, and the honest way to draw that is the area it missed — a
|
|
369
|
+
* quantity, visible to scale, rather than a percentage on another tab.
|
|
361
370
|
*/
|
|
362
|
-
|
|
371
|
+
shortfall?: {
|
|
372
|
+
label: string;
|
|
373
|
+
source: Series['source'];
|
|
374
|
+
points: SeriesPoint[];
|
|
375
|
+
};
|
|
363
376
|
}
|
|
364
377
|
/** A dated event drawn through every row, e.g. a campaign send. */
|
|
365
378
|
interface TimelineMarker {
|
package/dist/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as sanity from 'sanity';
|
|
2
2
|
import React from 'react';
|
|
3
|
-
import { R as ReportEnvelope, a as ReportName, b as RangeKey, M as MetricValue, A as AcquisitionData, D as DiagnosticReport, J as JourneyData, c as MeasurementHealthData, T as TypefaceInterestData } from './ranges-
|
|
4
|
-
export { C as CaptureBasis, d as CaptureEstimate, e as CaptureModel, f as CheckStatus, g as Coverage, h as CrossSourceDay, i as DailyPoint, j as DateRange, k as DiagnosticCheck, E as EmailCampaign, l as EventCutover, m as JourneyOutcome, n as JourneyStep, L as LandingPage, o as LicenceTierRow, P as PREEXISTING, p as REPORT_NAMES, q as ReportError, S as SiteAnalyticsConfig, r as SourceName, s as SourceRow, t as SourceStatus, u as TimelineEvent, v as TypefaceInterestRow, U as UnavailableReason, w as coverageForRange, x as estimated, y as isReportName, z as ok, B as partial, F as previousRange, G as resolveRange, H as unavailable, I as validateSiteConfig, K as valueOrNull } from './ranges-
|
|
3
|
+
import { R as ReportEnvelope, a as ReportName, b as RangeKey, M as MetricValue, A as AcquisitionData, D as DiagnosticReport, J as JourneyData, c as MeasurementHealthData, T as TypefaceInterestData } from './ranges-BUZuS1c-.js';
|
|
4
|
+
export { C as CaptureBasis, d as CaptureEstimate, e as CaptureModel, f as CheckStatus, g as Coverage, h as CrossSourceDay, i as DailyPoint, j as DateRange, k as DiagnosticCheck, E as EmailCampaign, l as EventCutover, m as JourneyOutcome, n as JourneyStep, L as LandingPage, o as LicenceTierRow, P as PREEXISTING, p as REPORT_NAMES, q as ReportError, S as SiteAnalyticsConfig, r as SourceName, s as SourceRow, t as SourceStatus, u as TimelineEvent, v as TypefaceInterestRow, U as UnavailableReason, w as coverageForRange, x as estimated, y as isReportName, z as ok, B as partial, F as previousRange, G as resolveRange, H as unavailable, I as validateSiteConfig, K as valueOrNull } from './ranges-BUZuS1c-.js';
|
|
5
5
|
|
|
6
6
|
/**
|
|
7
7
|
* The Visitor Insights Studio tool.
|
|
@@ -342,24 +342,37 @@ interface SeriesPoint {
|
|
|
342
342
|
}
|
|
343
343
|
/** How a value should be written out. */
|
|
344
344
|
type SeriesUnit = 'count' | 'money' | 'percent';
|
|
345
|
-
/**
|
|
345
|
+
/**
|
|
346
|
+
* One row of the chart: one answer, with what a lossier source saw underneath it.
|
|
347
|
+
*
|
|
348
|
+
* A row shows a SINGLE line by default. Two peer lines make the reader reconcile before they get
|
|
349
|
+
* an answer, and at a glance a foundry owner wants "how much", not "here are two measurements that
|
|
350
|
+
* disagree". The disagreement is still drawn — as a filled region, and in full on hover — because
|
|
351
|
+
* hiding it entirely would switch off the alarm: the 24 August collapse was visible precisely
|
|
352
|
+
* because two lines came apart.
|
|
353
|
+
*/
|
|
346
354
|
interface Series {
|
|
347
355
|
key: string;
|
|
348
356
|
label: string;
|
|
349
|
-
/** Which upstream
|
|
357
|
+
/** Which upstream the LINE came from. */
|
|
350
358
|
source: 'GA4' | 'Vercel' | 'Sanity' | 'Mailchimp';
|
|
351
|
-
/**
|
|
352
|
-
* Whether the source sees everything. GA4 does not; the others do.
|
|
353
|
-
* Drives the dashed stroke and the uncertainty band rather than a footnote nobody reads.
|
|
354
|
-
*/
|
|
359
|
+
/** Whether the line's source sees everything. Drives the stroke and the wording. */
|
|
355
360
|
complete: boolean;
|
|
356
361
|
unit: SeriesUnit;
|
|
357
362
|
points: SeriesPoint[];
|
|
358
363
|
/**
|
|
359
|
-
*
|
|
360
|
-
*
|
|
364
|
+
* What a lossier source saw of the same thing.
|
|
365
|
+
*
|
|
366
|
+
* Drawn as a filled region between the two, NOT as a symmetric uncertainty band. There is no
|
|
367
|
+
* doubt about the traffic here: Vercel counted it server-side. What is uncertain is how much of
|
|
368
|
+
* it the analytics could see, and the honest way to draw that is the area it missed — a
|
|
369
|
+
* quantity, visible to scale, rather than a percentage on another tab.
|
|
361
370
|
*/
|
|
362
|
-
|
|
371
|
+
shortfall?: {
|
|
372
|
+
label: string;
|
|
373
|
+
source: Series['source'];
|
|
374
|
+
points: SeriesPoint[];
|
|
375
|
+
};
|
|
363
376
|
}
|
|
364
377
|
/** A dated event drawn through every row, e.g. a campaign send. */
|
|
365
378
|
interface TimelineMarker {
|