@apextelemed/partner-core 0.19.0 → 0.20.0-dev.67

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.
@@ -1,5 +1,5 @@
1
1
  import { disqualificationReasonText, qualifiedDrugIds } from './LZWA44KD.js';
2
- import { SUPPORT_CATEGORIES, useSurveyFlow, reconcileCartAgainstCatalog, resolveSurveyV2DrugIntent, emailGateAnswered, redeemResumeLink, useSurveyV2Flow, US_STATE_OPTIONS, availableStateOptions, useCheckoutFlow, catalogUnavailableMessage, useCartCheckoutFlow, useSignupFlow, useRegisterFlow, useSubscribeFlow, useDashboardData, useUpdatePaymentMethodFlow, useMemberPortalData, useMessagesThread, captureFunnelEmail, markEmailGateAnswered, isCatalogItemId, subscribeToSupportTopic, useAffiliateStats, useAffiliateConversions, useAffiliateDownline, useAffiliateLinks, stateAvailabilityNote, hasStateRestrictions, uploadPrescriptionPhoto, deriveAttention, deriveJourney, buildTimeline, lifecycleReason, accountSource, intakeEvidence, LIFECYCLE_BUCKETS, LIFECYCLE_LABEL, classifyCatalogError, groupDrugsByPharmacy, useProductCatalogEditor, skuBindingModeFor, isCssColorValue, categoryLabel, useSmsPreferences, formatUsPhone, formatConversationTime, buildTrackerView, ACCOUNT_SOURCE_LABEL, fmtDay, createCatalogProduct, addCatalogItemAsProduct, applyPriceDrafts, resolveStrengthPrices, invalidDraftKeys, orphanKey, ORPHAN_REASON, useAddPharmacy, READINESS_LABEL, useCatalogConversion, formatCalendarDate, formatMessageTime, formatEventDate, formatStageDate, offerSummaryText, LIFECYCLE_TONE, buildTrackingUrl, buildStrengthRows, pharmacyLabel, isImageAttachment, buildRefillView, toTrackerRequest, needsReview, visibleWarnings, compareStrengths, MATCH_DEPENDENT_WARNINGS, SOURCE_FIELD_NOTE, MATCH_HOW_LABEL, explainFinding, matchKey } from './WM5KNUNX.js';
2
+ import { SUPPORT_CATEGORIES, useSurveyFlow, reconcileCartAgainstCatalog, resolveSurveyV2DrugIntent, emailGateAnswered, redeemResumeLink, useSurveyV2Flow, US_STATE_OPTIONS, availableStateOptions, useCheckoutFlow, catalogUnavailableMessage, useCartCheckoutFlow, useSignupFlow, useRegisterFlow, useSubscribeFlow, useDashboardData, useUpdatePaymentMethodFlow, useMemberPortalData, useMessagesThread, captureFunnelEmail, markEmailGateAnswered, isCatalogItemId, subscribeToSupportTopic, useAffiliateStats, useAffiliateConversions, useAffiliateDownline, useAffiliateLinks, stateAvailabilityNote, hasStateRestrictions, uploadPrescriptionPhoto, deriveAttention, deriveJourney, buildTimeline, lifecycleReason, accountSource, intakeEvidence, LIFECYCLE_BUCKETS, LIFECYCLE_LABEL, classifyCatalogError, groupDrugsByPharmacy, useProductCatalogEditor, skuBindingModeFor, isCssColorValue, categoryLabel, useSmsPreferences, formatUsPhone, formatConversationTime, buildTrackerView, ACCOUNT_SOURCE_LABEL, fmtDay, createCatalogProduct, addCatalogItemAsProduct, applyPriceDrafts, resolveStrengthPrices, invalidDraftKeys, orphanKey, ORPHAN_REASON, useAddPharmacy, READINESS_LABEL, useCatalogConversion, formatCalendarDate, formatMessageTime, formatEventDate, formatStageDate, offerSummaryText, LIFECYCLE_TONE, buildTrackingUrl, buildStrengthRows, pharmacyLabel, isImageAttachment, buildRefillView, toTrackerRequest, needsReview, visibleWarnings, compareStrengths, MATCH_DEPENDENT_WARNINGS, SOURCE_FIELD_NOTE, MATCH_HOW_LABEL, explainFinding, matchKey } from './ALIVUPFC.js';
3
3
  import { fetchFunnelConfig } from './WUVYCWKW.js';
4
4
  import { usePrimitives } from './67KHO66G.js';
5
5
  import { cart_default, auth_default, affiliateAuth_default } from './O2VF7KNG.js';
@@ -8786,7 +8786,7 @@ var editLinkStyle = {
8786
8786
  };
8787
8787
  function EarningsBar(props) {
8788
8788
  const total = () => Math.max(1, props.earnings.pending + props.earnings.approved + props.earnings.paid + props.earnings.cancelled);
8789
- const pct = (n) => `${n / total() * 100}%`;
8789
+ const pct2 = (n) => `${n / total() * 100}%`;
8790
8790
  return (() => {
8791
8791
  var _el$80 = _tmpl$206(), _el$81 = _el$80.firstChild, _el$82 = _el$81.firstChild, _el$83 = _el$82.nextSibling, _el$84 = _el$83.nextSibling, _el$85 = _el$84.nextSibling, _el$86 = _el$81.nextSibling;
8792
8792
  insert(_el$86, createComponent(Legend, {
@@ -8818,7 +8818,7 @@ function EarningsBar(props) {
8818
8818
  }
8819
8819
  }), null);
8820
8820
  effect((_p$) => {
8821
- var _v$0 = pct(props.earnings.pending), _v$1 = `Pending ${fmtCents4(props.earnings.pending)}`, _v$10 = pct(props.earnings.approved), _v$11 = `Approved ${fmtCents4(props.earnings.approved)}`, _v$12 = pct(props.earnings.paid), _v$13 = `Paid ${fmtCents4(props.earnings.paid)}`, _v$14 = pct(props.earnings.cancelled), _v$15 = `Canceled ${fmtCents4(props.earnings.cancelled)}`;
8821
+ var _v$0 = pct2(props.earnings.pending), _v$1 = `Pending ${fmtCents4(props.earnings.pending)}`, _v$10 = pct2(props.earnings.approved), _v$11 = `Approved ${fmtCents4(props.earnings.approved)}`, _v$12 = pct2(props.earnings.paid), _v$13 = `Paid ${fmtCents4(props.earnings.paid)}`, _v$14 = pct2(props.earnings.cancelled), _v$15 = `Canceled ${fmtCents4(props.earnings.cancelled)}`;
8822
8822
  _v$0 !== _p$.e && setStyleProperty(_el$82, "width", _p$.e = _v$0);
8823
8823
  _v$1 !== _p$.t && setAttribute(_el$82, "title", _p$.t = _v$1);
8824
8824
  _v$10 !== _p$.a && setStyleProperty(_el$83, "width", _p$.a = _v$10);
@@ -8892,10 +8892,10 @@ function OverrideEditor(props) {
8892
8892
  setSaving(true);
8893
8893
  try {
8894
8894
  const fixed = fixedDollars().trim();
8895
- const pct = pctRate().trim();
8896
- const customCommission = fixed === "" && pct === "" ? void 0 : {
8895
+ const pct2 = pctRate().trim();
8896
+ const customCommission = fixed === "" && pct2 === "" ? void 0 : {
8897
8897
  fixedAmountCents: fixed === "" ? void 0 : Math.round(parseFloat(fixed) * 100),
8898
- percentageRate: pct === "" ? void 0 : parseFloat(pct)
8898
+ percentageRate: pct2 === "" ? void 0 : parseFloat(pct2)
8899
8899
  };
8900
8900
  const discountStr = discountPct().trim();
8901
8901
  const cyclesStr = minCycles().trim();
@@ -9052,10 +9052,10 @@ function SecondTierEditor(props) {
9052
9052
  setSaving(true);
9053
9053
  try {
9054
9054
  const fixed = fixedDollars().trim();
9055
- const pct = pctRate().trim();
9056
- const customSecondTierCommission = fixed === "" && pct === "" ? null : {
9055
+ const pct2 = pctRate().trim();
9056
+ const customSecondTierCommission = fixed === "" && pct2 === "" ? null : {
9057
9057
  fixedAmountCents: fixed === "" ? void 0 : Math.round(parseFloat(fixed) * 100),
9058
- percentageRate: pct === "" ? void 0 : parseFloat(pct)
9058
+ percentageRate: pct2 === "" ? void 0 : parseFloat(pct2)
9059
9059
  };
9060
9060
  await adminAffiliatesApi.update(props.affiliate.id, {
9061
9061
  customSecondTierCommission
@@ -9688,15 +9688,15 @@ function ProgramEditPanel(props) {
9688
9688
  const save = async () => {
9689
9689
  if (!name().trim()) return setErr("Name is required.");
9690
9690
  const fixed = fixedDollars().trim();
9691
- const pct = pctRate().trim();
9692
- if (fixed === "" && pct === "") {
9691
+ const pct2 = pctRate().trim();
9692
+ if (fixed === "" && pct2 === "") {
9693
9693
  return setErr("Set at least one of fixed amount or percentage rate.");
9694
9694
  }
9695
9695
  setErr("");
9696
9696
  setSaving(true);
9697
9697
  const defaultCommission = {
9698
9698
  fixedAmountCents: fixed === "" ? void 0 : Math.round(parseFloat(fixed) * 100),
9699
- percentageRate: pct === "" ? void 0 : parseFloat(pct)
9699
+ percentageRate: pct2 === "" ? void 0 : parseFloat(pct2)
9700
9700
  };
9701
9701
  const t2Fixed = tier2FixedDollars().trim();
9702
9702
  const t2Pct = tier2PctRate().trim();
@@ -9759,13 +9759,13 @@ function ProgramEditPanel(props) {
9759
9759
  const exampleBilledCents = createMemo(() => Math.round(exampleBaseCents * (1 - exampleDiscountPct() / 100)));
9760
9760
  const examplePerCycleCents = createMemo(() => {
9761
9761
  const fixed = (parseFloat(fixedDollars()) || 0) * 100;
9762
- const pct = parseFloat(pctRate()) || 0;
9763
- return Math.round(fixed + exampleBilledCents() * (pct / 100));
9762
+ const pct2 = parseFloat(pctRate()) || 0;
9763
+ return Math.round(fixed + exampleBilledCents() * (pct2 / 100));
9764
9764
  });
9765
9765
  const exampleTier2Cents = createMemo(() => {
9766
9766
  const fixed = (parseFloat(tier2FixedDollars()) || 0) * 100;
9767
- const pct = parseFloat(tier2PctRate()) || 0;
9768
- return Math.round(fixed + exampleBilledCents() * (pct / 100));
9767
+ const pct2 = parseFloat(tier2PctRate()) || 0;
9768
+ return Math.round(fixed + exampleBilledCents() * (pct2 / 100));
9769
9769
  });
9770
9770
  const exampleCyclesNum = createMemo(() => Math.max(1, parseInt(minCycles(), 10) || 1));
9771
9771
  const exampleHoldDaysNum = createMemo(() => Math.max(0, parseInt(holdDays(), 10) || 0));
@@ -19968,8 +19968,8 @@ delegateEvents(["click", "input", "keydown"]);
19968
19968
 
19969
19969
  // src/pages/admin/funnelShared.ts
19970
19970
  var SEGMENT_KEYS = {
19971
- a: ["a.cart", "a.survey_finished", "a.survey_started"],
19972
- b: ["b.card_declined", "b.cart", "b.survey_finished", "b.survey_started", "b.no_activity"]
19971
+ a: ["a.cart", "a.survey_finished", "a.rejected", "a.survey_started"],
19972
+ b: ["b.card_declined", "b.cart", "b.survey_finished", "b.rejected", "b.survey_started", "b.no_activity"]
19973
19973
  };
19974
19974
  var GROUP_LABEL = {
19975
19975
  a: "No account",
@@ -19978,10 +19978,12 @@ var GROUP_LABEL = {
19978
19978
  var SEGMENT_LABEL = {
19979
19979
  "a.cart": "Abandoned a cart",
19980
19980
  "a.survey_finished": "Finished the questionnaire",
19981
+ "a.rejected": "Rejected by the questionnaire",
19981
19982
  "a.survey_started": "Started the questionnaire",
19982
19983
  "b.card_declined": "Card declined",
19983
19984
  "b.cart": "Abandoned a cart",
19984
19985
  "b.survey_finished": "Finished the questionnaire",
19986
+ "b.rejected": "Rejected by the questionnaire",
19985
19987
  "b.survey_started": "Started the questionnaire",
19986
19988
  "b.no_activity": "No tracked activity"
19987
19989
  };
@@ -24708,23 +24710,62 @@ delegateEvents(["click", "input"]);
24708
24710
  // src/pages/admin/Funnel.tsx
24709
24711
  var _tmpl$397 = /* @__PURE__ */ template(`<p style="font-size:0.75rem;color:var(--app-admin-fg-muted);margin:0.25rem 0 0">`);
24710
24712
  var _tmpl$2121 = /* @__PURE__ */ template(`<div style="padding:1rem 1.25rem;border-bottom:1px solid var(--app-admin-border-soft)"><h2 class=app-admin-heading style=font-size:0.9375rem;font-weight:600;margin:0>`);
24711
- var _tmpl$398 = /* @__PURE__ */ template(`<label style=font-size:0.8125rem;display:flex;gap:0.375rem;align-items:center;margin-top:0.25rem><input type=checkbox>Savings program only (<!>)`);
24712
- var _tmpl$468 = /* @__PURE__ */ template(`<th>Account`);
24713
- var _tmpl$558 = /* @__PURE__ */ template(`<p class=app-admin-text-muted style="font-size:0.75rem;padding:0.625rem 1.25rem;margin:0">Showing the 50 most recent of <!>.`);
24714
- var _tmpl$654 = /* @__PURE__ */ template(`<div class=app-admin-card style=margin-top:1.25rem;overflow:hidden><div style="padding:1rem 1.25rem;display:grid;gap:0.5rem"></div><div style="padding:0.5rem 1.25rem 0.75rem;border-top:1px solid var(--app-admin-border-soft)"></div><table class=app-admin-table><thead><tr><th style=width:2rem><input type=checkbox aria-label="Select all"></th><th>Person</th><th>Where they stopped</th><th>Since</th></tr></thead><tbody>`);
24715
- var _tmpl$747 = /* @__PURE__ */ template(`<span style=color:var(--app-admin-fg-subtle);margin-left:0.375rem> savings`);
24716
- var _tmpl$839 = /* @__PURE__ */ template(`<button type=button style="display:grid;grid-template-columns:12rem 1fr 7rem;align-items:center;gap:0.75rem;background:none;border:none;padding:0.125rem 0;cursor:pointer;text-align:left;color:inherit;font:inherit"><span style=font-size:0.8125rem;color:var(--app-admin-fg-muted)></span><span style=display:block;background:var(--app-admin-border-soft);border-radius:4px;height:1.125rem><span style=display:block;height:100%;background:var(--app-admin-primary);border-radius:4px></span></span><span style=font-size:0.8125rem;text-align:right>`);
24717
- var _tmpl$935 = /* @__PURE__ */ template(`<tr><td colspan=5>`);
24718
- var _tmpl$031 = /* @__PURE__ */ template(`<button type=button class=app-admin-link-btn style=font-size:inherit;font-weight:inherit>`);
24719
- var _tmpl$1127 = /* @__PURE__ */ template(`<span class="app-admin-badge app-admin-badge--neutral"style=margin-left:0.5rem>Opted out`);
24720
- var _tmpl$1024 = /* @__PURE__ */ template(`<div class=app-admin-text-muted style=font-size:0.75rem>`);
24721
- var _tmpl$1128 = /* @__PURE__ */ template(`<span class="app-admin-badge app-admin-badge--info"style=margin-left:0.5rem>Savings`);
24722
- var _tmpl$1220 = /* @__PURE__ */ template(`<td data-label=Account><span class=app-admin-text-muted>`);
24723
- var _tmpl$1318 = /* @__PURE__ */ template(`<tr><td><input type=checkbox></td><td data-label=Person><div></div></td><td data-label="Where they stopped"></td><td data-label=Since class=app-admin-text-muted>`);
24724
- var _tmpl$1418 = /* @__PURE__ */ template(`<div><div style=margin-bottom:1rem><select class=app-admin-input style=width:auto><option value=7>Last 7 days</option><option value=30>Last 30 days</option><option value=90>Last 90 days`);
24725
- var _tmpl$1518 = /* @__PURE__ */ template(`<div class=app-admin-card style=margin-top:1.25rem><div style=padding:1.25rem;display:flex;align-items:flex-end;gap:0.375rem;height:9rem>`);
24726
- var _tmpl$1618 = /* @__PURE__ */ template(`<span style=font-size:0.6875rem;color:var(--app-admin-fg-muted)>`);
24727
- var _tmpl$1718 = /* @__PURE__ */ template(`<div style=flex:1;display:flex;flex-direction:column;align-items:center;gap:0.25rem;height:100%;justify-content:flex-end><div style="width:100%;max-width:1.75rem;border-radius:4px 4px 0 0"></div><span style=font-size:0.625rem;color:var(--app-admin-fg-subtle)>`);
24713
+ var _tmpl$398 = /* @__PURE__ */ template(`<div style=font-size:0.6875rem;color:var(--app-admin-fg-subtle)>`);
24714
+ var _tmpl$468 = /* @__PURE__ */ template(`<div style="padding:0.75rem 0.875rem;border-radius:var(--app-admin-radius-sm, 0.5rem);min-width:0"><div style=font-size:0.75rem></div><div style=font-size:1.375rem;font-weight:600>`);
24715
+ var _tmpl$558 = /* @__PURE__ */ template(`<div class=app-admin-card style=overflow:hidden><div style="padding:1rem 1.25rem;display:grid;grid-template-columns:repeat(auto-fit, minmax(8.5rem, 1fr));gap:0.5rem">`);
24716
+ var _tmpl$654 = /* @__PURE__ */ template(`<th style=width:6rem;text-align:right>Rejected here`);
24717
+ var _tmpl$747 = /* @__PURE__ */ template(`<table class=app-admin-table><thead><tr><th>Page and its questions</th><th style=width:6rem;text-align:right>Left here</th><th style=width:11rem>Of those who reached it</th></tr></thead><tbody>`);
24718
+ var _tmpl$839 = /* @__PURE__ */ template(`<div style=display:grid;gap:0.25rem>`);
24719
+ var _tmpl$935 = /* @__PURE__ */ template(`<p class=app-admin-text-muted style="font-size:0.6875rem;margin:0.5rem 0 0">People, not medications: someone ruled out of two medications for the same reason counts once.`);
24720
+ var _tmpl$031 = /* @__PURE__ */ template(`<div style="padding:1rem 1.25rem;border-top:1px solid var(--app-admin-border-soft)"><h3 class=app-admin-heading style="font-size:0.8125rem;font-weight:600;margin:0 0 0.5rem">Why people were rejected`);
24721
+ var _tmpl$1127 = /* @__PURE__ */ template(`<details style="padding:0.75rem 1.25rem;border-top:1px solid var(--app-admin-border-soft)"><summary style=font-size:0.75rem;color:var(--app-admin-fg-muted);cursor:pointer>Older drop-offs by position (<!>) \u2014 from before page tracking, so only how far through they were is known</summary><div style=padding-top:0.75rem;display:flex;align-items:flex-end;gap:0.375rem;height:7rem>`);
24722
+ var _tmpl$1024 = /* @__PURE__ */ template(`<div class=app-admin-card style=margin-top:1.25rem;overflow:hidden>`);
24723
+ var _tmpl$1128 = /* @__PURE__ */ template(`<div style="padding:1rem 1.25rem">`);
24724
+ var _tmpl$1220 = /* @__PURE__ */ template(`<div class=app-admin-text-muted style=font-size:0.6875rem>`);
24725
+ var _tmpl$1318 = /* @__PURE__ */ template(`<ul class=app-admin-text-muted style="font-size:0.75rem;margin:0.25rem 0 0;padding-left:1rem">`);
24726
+ var _tmpl$1418 = /* @__PURE__ */ template(`<td data-label="Rejected here"style=text-align:right>`);
24727
+ var _tmpl$1518 = /* @__PURE__ */ template(`<tr><td data-label=Page><div style=font-weight:500></div></td><td data-label="Left here"style=text-align:right></td><td data-label="Of those who reached it"><div style=display:flex;align-items:center;gap:0.5rem><span style=flex:1;display:block;background:var(--app-admin-border-soft);border-radius:4px;height:0.5rem><span style=display:block;height:100%;background:var(--app-admin-primary);border-radius:4px></span></span><span style=font-size:0.75rem;min-width:5.5rem;text-align:right>% of `);
24728
+ var _tmpl$1618 = /* @__PURE__ */ template(`<li>`);
24729
+ var _tmpl$1718 = /* @__PURE__ */ template(`<p class=app-admin-text-muted style=font-size:0.75rem;margin:0>Apex gave no reason text for these rejections.`);
24730
+ var _tmpl$1818 = /* @__PURE__ */ template(`<div style=display:flex;justify-content:space-between;gap:1rem;font-size:0.8125rem><span></span><span class=app-admin-text-muted>`);
24731
+ var _tmpl$1917 = /* @__PURE__ */ template(`<span style=font-size:0.6875rem;color:var(--app-admin-fg-muted)>`);
24732
+ var _tmpl$2016 = /* @__PURE__ */ template(`<div style=flex:1;display:flex;flex-direction:column;align-items:center;gap:0.25rem;height:100%;justify-content:flex-end><div style="width:100%;max-width:1.75rem;border-radius:4px 4px 0 0"></div><span style=font-size:0.625rem;color:var(--app-admin-fg-subtle)>`);
24733
+ var _tmpl$2122 = /* @__PURE__ */ template(`<span class="app-admin-badge app-admin-badge--danger">Rejected`);
24734
+ var _tmpl$2216 = /* @__PURE__ */ template(`<div class=app-admin-text-muted style=font-size:0.75rem>`);
24735
+ var _tmpl$2315 = /* @__PURE__ */ template(`<span>`);
24736
+ var _tmpl$2415 = /* @__PURE__ */ template(`<label style=display:flex;gap:0.375rem;align-items:center><input type=checkbox>Savings program only (<!>)`);
24737
+ var _tmpl$2515 = /* @__PURE__ */ template(`<p class=app-admin-text-muted style="font-size:0.75rem;padding:0.625rem 1.25rem;margin:0">Showing the 50 most recent of <!>.`);
24738
+ var _tmpl$2615 = /* @__PURE__ */ template(`<p class=app-admin-text-muted style="font-size:0.75rem;padding:0.625rem 1.25rem;margin:0"> rejected <!> not listed: whether a named patient qualified is health information your role can't see. They're still in the totals above.`);
24739
+ var _tmpl$2715 = /* @__PURE__ */ template(`<div class=app-admin-card style=margin-top:1.25rem;overflow:hidden><div style="padding:0.875rem 1.25rem 0;display:grid;gap:0.5rem"><div class=app-admin-chips role=group aria-label="Where they stopped"></div><div style=display:flex;gap:1rem;align-items:center;flex-wrap:wrap;font-size:0.8125rem><label style=display:flex;gap:0.375rem;align-items:center>Account<select class=app-admin-input style=width:auto><option value=all>Everyone (<!>)</option><option value=a>No account \u2014 email only (<!>)</option><option value=b>Has an account (<!>)</option></select></label></div></div><div style="padding:0.75rem 1.25rem"></div><table class=app-admin-table><thead><tr><th style=width:2rem><input type=checkbox aria-label="Select all"></th><th>Person</th><th>Where they stopped</th><th style=width:7rem>When</th></tr></thead><tbody>`);
24740
+ var _tmpl$2813 = /* @__PURE__ */ template(`<tr><td colspan=4>`);
24741
+ var _tmpl$2912 = /* @__PURE__ */ template(`<button type=button class=app-admin-link-btn style=font-size:inherit;font-weight:inherit>`);
24742
+ var _tmpl$3011 = /* @__PURE__ */ template(`<span class="app-admin-badge app-admin-badge--neutral">Account`);
24743
+ var _tmpl$3116 = /* @__PURE__ */ template(`<span class="app-admin-badge app-admin-badge--info">Savings`);
24744
+ var _tmpl$3215 = /* @__PURE__ */ template(`<span class="app-admin-badge app-admin-badge--neutral">Opted out`);
24745
+ var _tmpl$3315 = /* @__PURE__ */ template(`<tr><td><input type=checkbox></td><td data-label=Person><div style=display:flex;gap:0.375rem;align-items:center;flex-wrap:wrap></div></td><td data-label="Where they stopped"></td><td data-label=When class=app-admin-text-muted>`);
24746
+ var _tmpl$3415 = /* @__PURE__ */ template(`<div><div style=margin-bottom:1rem><select class=app-admin-input aria-label="Time window"style=width:auto><option value=7>Last 7 days</option><option value=30>Last 30 days</option><option value=90>Last 90 days`);
24747
+ var STAGES = [{
24748
+ id: "survey_started",
24749
+ label: "Left the survey"
24750
+ }, {
24751
+ id: "rejected",
24752
+ label: "Rejected"
24753
+ }, {
24754
+ id: "survey_finished",
24755
+ label: "Finished, never bought"
24756
+ }, {
24757
+ id: "cart",
24758
+ label: "Left a cart"
24759
+ }, {
24760
+ id: "card_declined",
24761
+ label: "Card declined"
24762
+ }, {
24763
+ id: "no_activity",
24764
+ label: "Account, no activity"
24765
+ }];
24766
+ var STAGE_LABEL = Object.fromEntries(STAGES.map((s) => [s.id, s.label]));
24767
+ var stageOf = (key) => key.slice(2);
24768
+ var PAGE_SIZE = 50;
24728
24769
  function CardHeader(props) {
24729
24770
  return (() => {
24730
24771
  var _el$ = _tmpl$2121(), _el$2 = _el$.firstChild;
@@ -24742,92 +24783,440 @@ function CardHeader(props) {
24742
24783
  return _el$;
24743
24784
  })();
24744
24785
  }
24745
- function stoppedAt(p) {
24746
- const base = SEGMENT_LABEL[p.key];
24747
- if (p.key.endsWith("survey_started") && p.lastStep != null && p.stepCount) {
24748
- return `${base} \u2014 step ${Math.min(p.lastStep + 1, p.stepCount)} of ${p.stepCount}`;
24749
- }
24750
- if (p.key.endsWith("survey_finished") && p.qualified === false) return `${base} \u2014 not qualified`;
24751
- return base;
24786
+ function Tile(props) {
24787
+ const danger = () => props.tone === "danger";
24788
+ return (() => {
24789
+ var _el$4 = _tmpl$468(), _el$5 = _el$4.firstChild, _el$6 = _el$5.nextSibling;
24790
+ insert(_el$5, () => props.label);
24791
+ insert(_el$6, () => props.value);
24792
+ insert(_el$4, createComponent(Show, {
24793
+ get when() {
24794
+ return props.note;
24795
+ },
24796
+ get children() {
24797
+ var _el$7 = _tmpl$398();
24798
+ insert(_el$7, () => props.note);
24799
+ return _el$7;
24800
+ }
24801
+ }), null);
24802
+ effect((_p$) => {
24803
+ var _v$ = danger() ? "var(--app-admin-danger-bg)" : "var(--app-admin-surface-light, var(--app-admin-border-soft))", _v$2 = danger() ? "var(--app-admin-danger-fg)" : "var(--app-admin-fg-muted)", _v$3 = danger() ? "var(--app-admin-danger-fg)" : void 0;
24804
+ _v$ !== _p$.e && setStyleProperty(_el$4, "background", _p$.e = _v$);
24805
+ _v$2 !== _p$.t && setStyleProperty(_el$5, "color", _p$.t = _v$2);
24806
+ _v$3 !== _p$.a && setStyleProperty(_el$6, "color", _p$.a = _v$3);
24807
+ return _p$;
24808
+ }, {
24809
+ e: void 0,
24810
+ t: void 0,
24811
+ a: void 0
24812
+ });
24813
+ return _el$4;
24814
+ })();
24815
+ }
24816
+ function pageName(p) {
24817
+ return p.title || p.sectionTitle || (p.stepId === "patient_info" ? "Contact information" : "Untitled page");
24818
+ }
24819
+ var pct = (n, d) => d > 0 ? Math.round(n / d * 100) : 0;
24820
+ function Totals(props) {
24821
+ const s = () => props.summary;
24822
+ const carts = () => s().carts;
24823
+ return (() => {
24824
+ var _el$8 = _tmpl$558(), _el$9 = _el$8.firstChild;
24825
+ insert(_el$8, createComponent(CardHeader, {
24826
+ title: "Everyone who started, and where they ended up",
24827
+ note: "Counts survey attempts, so someone who tried twice counts twice. The people list below counts each person once."
24828
+ }), _el$9);
24829
+ insert(_el$9, createComponent(Tile, {
24830
+ label: "Started the survey",
24831
+ get value() {
24832
+ return s().sessions.started;
24833
+ },
24834
+ get note() {
24835
+ return memo(() => s().sessions.active > 0)() ? `${s().sessions.active} still in progress` : void 0;
24836
+ }
24837
+ }), null);
24838
+ insert(_el$9, createComponent(Tile, {
24839
+ label: "Left partway",
24840
+ get value() {
24841
+ return s().sessions.abandoned;
24842
+ }
24843
+ }), null);
24844
+ insert(_el$9, createComponent(Show, {
24845
+ get when() {
24846
+ return s().sessions.rejected !== void 0;
24847
+ },
24848
+ get children() {
24849
+ return createComponent(Tile, {
24850
+ label: "Rejected",
24851
+ get value() {
24852
+ return s().sessions.rejected ?? 0;
24853
+ },
24854
+ note: "Told they don't qualify",
24855
+ tone: "danger"
24856
+ });
24857
+ }
24858
+ }), null);
24859
+ insert(_el$9, createComponent(Tile, {
24860
+ label: "Finished the survey",
24861
+ get value() {
24862
+ return s().sessions.completed;
24863
+ }
24864
+ }), null);
24865
+ insert(_el$9, createComponent(Show, {
24866
+ get when() {
24867
+ return (carts()?.total ?? 0) > 0;
24868
+ },
24869
+ get children() {
24870
+ return createComponent(Tile, {
24871
+ label: "Left a cart",
24872
+ get value() {
24873
+ return carts().abandoned;
24874
+ },
24875
+ get note() {
24876
+ return `of ${carts().total} carts`;
24877
+ }
24878
+ });
24879
+ }
24880
+ }), null);
24881
+ insert(_el$9, createComponent(Show, {
24882
+ get when() {
24883
+ return s().captures;
24884
+ },
24885
+ get children() {
24886
+ return createComponent(Tile, {
24887
+ label: "Finished and bought",
24888
+ get value() {
24889
+ return s().captures.converted;
24890
+ }
24891
+ });
24892
+ }
24893
+ }), null);
24894
+ return _el$8;
24895
+ })();
24896
+ }
24897
+ function PagesCard(props) {
24898
+ const pages = () => props.summary.pages ?? [];
24899
+ const anyRejected = () => pages().some((p) => p.rejected > 0);
24900
+ const untracked = () => props.summary.untrackedAbandons ?? 0;
24901
+ const reasons = () => props.summary.rejections ?? [];
24902
+ const maxRate = () => Math.max(1, ...pages().map((p) => pct(p.stopped, p.reached)));
24903
+ const dropoffMax = () => Math.max(1, ...props.summary.stepDropoff.map((b) => b.count));
24904
+ return (() => {
24905
+ var _el$0 = _tmpl$1024();
24906
+ insert(_el$0, createComponent(CardHeader, {
24907
+ title: "Survey pages people stop on",
24908
+ note: "The last page someone saw before they left, most stops first. Leaving the page counts at once; a session that just goes quiet counts after 4 hours."
24909
+ }), null);
24910
+ insert(_el$0, createComponent(Show, {
24911
+ get when() {
24912
+ return pages().length > 0;
24913
+ },
24914
+ get fallback() {
24915
+ return (() => {
24916
+ var _el$27 = _tmpl$1128();
24917
+ insert(_el$27, createComponent(EmptyState, {
24918
+ get message() {
24919
+ return props.summary.pages === void 0 ? "Page details need a newer backend." : "No page details yet. They start with surveys taken after this update.";
24920
+ }
24921
+ }));
24922
+ return _el$27;
24923
+ })();
24924
+ },
24925
+ get children() {
24926
+ var _el$1 = _tmpl$747(), _el$10 = _el$1.firstChild, _el$11 = _el$10.firstChild, _el$12 = _el$11.firstChild, _el$13 = _el$12.nextSibling, _el$15 = _el$13.nextSibling, _el$16 = _el$10.nextSibling;
24927
+ insert(_el$11, createComponent(Show, {
24928
+ get when() {
24929
+ return anyRejected();
24930
+ },
24931
+ get children() {
24932
+ return _tmpl$654();
24933
+ }
24934
+ }), _el$15);
24935
+ insert(_el$16, createComponent(For, {
24936
+ get each() {
24937
+ return pages();
24938
+ },
24939
+ children: (p) => (() => {
24940
+ var _el$28 = _tmpl$1518(), _el$29 = _el$28.firstChild, _el$30 = _el$29.firstChild, _el$33 = _el$29.nextSibling, _el$35 = _el$33.nextSibling, _el$36 = _el$35.firstChild, _el$37 = _el$36.firstChild, _el$38 = _el$37.firstChild, _el$39 = _el$37.nextSibling, _el$40 = _el$39.firstChild;
24941
+ insert(_el$30, () => pageName(p));
24942
+ insert(_el$29, createComponent(Show, {
24943
+ get when() {
24944
+ return memo(() => !!(p.title && p.sectionTitle))() && p.sectionTitle !== p.title;
24945
+ },
24946
+ get children() {
24947
+ var _el$31 = _tmpl$1220();
24948
+ insert(_el$31, () => p.sectionTitle);
24949
+ return _el$31;
24950
+ }
24951
+ }), null);
24952
+ insert(_el$29, createComponent(Show, {
24953
+ get when() {
24954
+ return p.questions.length > 0;
24955
+ },
24956
+ get children() {
24957
+ var _el$32 = _tmpl$1318();
24958
+ insert(_el$32, createComponent(For, {
24959
+ get each() {
24960
+ return p.questions;
24961
+ },
24962
+ children: (q) => (() => {
24963
+ var _el$41 = _tmpl$1618();
24964
+ insert(_el$41, q);
24965
+ return _el$41;
24966
+ })()
24967
+ }));
24968
+ return _el$32;
24969
+ }
24970
+ }), null);
24971
+ insert(_el$33, () => p.stopped);
24972
+ insert(_el$28, createComponent(Show, {
24973
+ get when() {
24974
+ return anyRejected();
24975
+ },
24976
+ get children() {
24977
+ var _el$34 = _tmpl$1418();
24978
+ insert(_el$34, () => p.rejected || "\u2014");
24979
+ return _el$34;
24980
+ }
24981
+ }), _el$35);
24982
+ insert(_el$39, () => pct(p.stopped, p.reached), _el$40);
24983
+ insert(_el$39, () => p.reached, null);
24984
+ effect((_p$) => {
24985
+ var _v$4 = `${pct(p.stopped, p.reached) / maxRate() * 100}%`, _v$5 = `${p.stopped} of ${p.reached} who reached this page left on it`;
24986
+ _v$4 !== _p$.e && setStyleProperty(_el$38, "width", _p$.e = _v$4);
24987
+ _v$5 !== _p$.t && setAttribute(_el$39, "title", _p$.t = _v$5);
24988
+ return _p$;
24989
+ }, {
24990
+ e: void 0,
24991
+ t: void 0
24992
+ });
24993
+ return _el$28;
24994
+ })()
24995
+ }));
24996
+ return _el$1;
24997
+ }
24998
+ }), null);
24999
+ insert(_el$0, createComponent(Show, {
25000
+ get when() {
25001
+ return (props.summary.sessions.rejected ?? 0) > 0;
25002
+ },
25003
+ get children() {
25004
+ var _el$17 = _tmpl$031(); _el$17.firstChild;
25005
+ insert(_el$17, createComponent(Show, {
25006
+ get when() {
25007
+ return reasons().length > 0;
25008
+ },
25009
+ get fallback() {
25010
+ return _tmpl$1718();
25011
+ },
25012
+ get children() {
25013
+ return [(() => {
25014
+ var _el$19 = _tmpl$839();
25015
+ insert(_el$19, createComponent(For, {
25016
+ get each() {
25017
+ return reasons();
25018
+ },
25019
+ children: (r) => (() => {
25020
+ var _el$43 = _tmpl$1818(), _el$44 = _el$43.firstChild, _el$45 = _el$44.nextSibling;
25021
+ insert(_el$44, () => r.reason);
25022
+ insert(_el$45, () => r.count);
25023
+ return _el$43;
25024
+ })()
25025
+ }));
25026
+ return _el$19;
25027
+ })(), _tmpl$935()];
25028
+ }
25029
+ }), null);
25030
+ return _el$17;
25031
+ }
25032
+ }), null);
25033
+ insert(_el$0, createComponent(Show, {
25034
+ get when() {
25035
+ return untracked() > 0;
25036
+ },
25037
+ get children() {
25038
+ var _el$21 = _tmpl$1127(), _el$22 = _el$21.firstChild, _el$23 = _el$22.firstChild, _el$25 = _el$23.nextSibling; _el$25.nextSibling; var _el$26 = _el$22.nextSibling;
25039
+ insert(_el$22, untracked, _el$25);
25040
+ insert(_el$26, createComponent(For, {
25041
+ get each() {
25042
+ return props.summary.stepDropoff;
25043
+ },
25044
+ children: (b) => (() => {
25045
+ var _el$46 = _tmpl$2016(), _el$48 = _el$46.firstChild, _el$49 = _el$48.nextSibling;
25046
+ insert(_el$46, createComponent(Show, {
25047
+ get when() {
25048
+ return b.count > 0;
25049
+ },
25050
+ get children() {
25051
+ var _el$47 = _tmpl$1917();
25052
+ insert(_el$47, () => b.count);
25053
+ return _el$47;
25054
+ }
25055
+ }), _el$48);
25056
+ insert(_el$49, (() => {
25057
+ var _c$ = memo(() => b.bucket === 0);
25058
+ return () => _c$() ? "Start" : memo(() => b.bucket === 10)() ? "Info" : b.bucket === 5 ? "50%" : "";
25059
+ })());
25060
+ effect((_p$) => {
25061
+ var _v$6 = `${b.bucket * 10}% through: ${b.count}`, _v$7 = `${Math.max(b.count > 0 ? 6 : 2, b.count / dropoffMax() * 70)}px`, _v$8 = b.count > 0 ? "var(--app-admin-primary)" : "var(--app-admin-border-soft)";
25062
+ _v$6 !== _p$.e && setAttribute(_el$46, "title", _p$.e = _v$6);
25063
+ _v$7 !== _p$.t && setStyleProperty(_el$48, "height", _p$.t = _v$7);
25064
+ _v$8 !== _p$.a && setStyleProperty(_el$48, "background", _p$.a = _v$8);
25065
+ return _p$;
25066
+ }, {
25067
+ e: void 0,
25068
+ t: void 0,
25069
+ a: void 0
25070
+ });
25071
+ return _el$46;
25072
+ })()
25073
+ }));
25074
+ return _el$21;
25075
+ }
25076
+ }), null);
25077
+ return _el$0;
25078
+ })();
24752
25079
  }
24753
- function SegmentSection(props) {
25080
+ function whereStopped(p) {
25081
+ const stage = stageOf(p.key);
25082
+ const detail = () => {
25083
+ if (stage === "survey_started" || stage === "rejected") {
25084
+ if (p.stepTitle) return p.stepTitle;
25085
+ if (p.lastStep != null && p.stepCount) return `Step ${Math.min(p.lastStep + 1, p.stepCount)} of ${p.stepCount}`;
25086
+ }
25087
+ if (stage === "survey_finished" && p.qualified === false) return "Not qualified";
25088
+ return null;
25089
+ };
25090
+ return [createComponent(Show, {
25091
+ when: stage === "rejected",
25092
+ get fallback() {
25093
+ return (() => {
25094
+ var _el$53 = _tmpl$2315();
25095
+ insert(_el$53, () => STAGE_LABEL[stage]);
25096
+ return _el$53;
25097
+ })();
25098
+ },
25099
+ get children() {
25100
+ return _tmpl$2122();
25101
+ }
25102
+ }), createComponent(Show, {
25103
+ get when() {
25104
+ return detail();
25105
+ },
25106
+ get children() {
25107
+ var _el$51 = _tmpl$2216();
25108
+ insert(_el$51, detail);
25109
+ return _el$51;
25110
+ }
25111
+ }), createComponent(Show, {
25112
+ get when() {
25113
+ return memo(() => !!(stage === "rejected" && p.rejectionReasons))() && p.rejectionReasons.length > 0;
25114
+ },
25115
+ get children() {
25116
+ var _el$52 = _tmpl$2216();
25117
+ insert(_el$52, () => p.rejectionReasons.join("; "));
25118
+ return _el$52;
25119
+ }
25120
+ })];
25121
+ }
25122
+ function keysFor(stage, account, known) {
25123
+ const groups = account === "all" ? ["a", "b"] : [account];
25124
+ if (stage === "all") return groups;
25125
+ return groups.map((g) => `${g}.${stage}`).filter((k) => SEGMENT_KEYS[k.charAt(0)].includes(k) && known.has(k));
25126
+ }
25127
+ function PeopleCard(props) {
24754
25128
  const nav = useAdminNav();
24755
- const [filter, setFilter] = createSignal("all");
25129
+ const [stage, setStage] = createSignal("all");
25130
+ const [account, setAccount] = createSignal("all");
24756
25131
  const [savingsOnly, setSavingsOnly] = createSignal(false);
24757
25132
  const [selected, setSelected] = createSignal({});
25133
+ const known = createMemo(() => new Set([...props.segments.noAccount.segments, ...props.segments.account.segments].map((s) => s.key)));
25134
+ const groupSummary = (g) => g === "a" ? props.segments.noAccount : props.segments.account;
25135
+ const stageCount = (st) => {
25136
+ const groups = account() === "all" ? ["a", "b"] : [account()];
25137
+ return groups.reduce((n, g) => {
25138
+ const seg = groupSummary(g).segments.find((s) => s.key === `${g}.${st}`);
25139
+ return n + (savingsOnly() ? seg?.savingsMembers ?? 0 : seg?.count ?? 0);
25140
+ }, 0);
25141
+ };
25142
+ const visibleStages = () => STAGES.filter((st) => keysFor(st.id, account(), known()).length > 0);
25143
+ const savingsTotal = () => props.segments.account.savingsMembers;
24758
25144
  const [people, {
24759
25145
  refetch
24760
25146
  }] = createResource(() => ({
24761
25147
  days: props.days,
24762
- filter: filter(),
25148
+ stage: stage(),
25149
+ account: savingsOnly() ? "b" : account(),
24763
25150
  savings: savingsOnly()
24764
- }), (q) => apiFetch(`/admin/funnel/segments/${q.filter === "all" ? props.group : q.filter}/people?days=${q.days}&limit=50` + (q.savings ? "&savings=true" : "")));
24765
- const max = () => Math.max(1, ...props.summary.segments.map((s) => s.count));
24766
- const hasSavings = () => props.group === "b" && props.summary.savingsMembers > 0;
25151
+ }), async (q) => {
25152
+ const keys = keysFor(q.stage, q.account, known());
25153
+ const pages = await Promise.all(keys.map((k) => apiFetch(`/admin/funnel/segments/${k}/people?days=${q.days}&limit=${PAGE_SIZE}` + (q.savings ? "&savings=true" : ""))));
25154
+ const merged = pages.flatMap((p) => p.people).sort((x, y) => y.enteredAt.localeCompare(x.enteredAt)).slice(0, PAGE_SIZE);
25155
+ return {
25156
+ people: merged,
25157
+ total: pages.reduce((n, p) => n + p.total, 0),
25158
+ hasMore: pages.some((p) => p.hasMore) || pages.reduce((n, p) => n + p.people.length, 0) > PAGE_SIZE,
25159
+ rejectedHidden: pages.reduce((n, p) => n + (p.rejectedHidden ?? 0), 0)
25160
+ };
25161
+ });
24767
25162
  const selectable = () => (people()?.people ?? []).filter((p) => !p.optedOut);
24768
25163
  const picked = () => selectable().filter((p) => selected()[p.email]);
24769
25164
  const allPicked = () => selectable().length > 0 && picked().length === selectable().length;
24770
25165
  const toggleAll = () => setSelected(allPicked() ? {} : Object.fromEntries(selectable().map((p) => [p.email, true])));
25166
+ const totalPeople = createMemo(() => (account() === "all" ? ["a", "b"] : [account()]).reduce((n, g) => n + (savingsOnly() ? g === "b" ? savingsTotal() : 0 : groupSummary(g).total), 0));
24771
25167
  return (() => {
24772
- var _el$4 = _tmpl$654(), _el$5 = _el$4.firstChild, _el$1 = _el$5.nextSibling, _el$10 = _el$1.nextSibling, _el$11 = _el$10.firstChild, _el$12 = _el$11.firstChild, _el$13 = _el$12.firstChild, _el$14 = _el$13.firstChild, _el$15 = _el$13.nextSibling, _el$16 = _el$15.nextSibling; _el$16.nextSibling; var _el$19 = _el$11.nextSibling;
24773
- insert(_el$4, createComponent(CardHeader, {
24774
- get title() {
24775
- return `${props.title} \u2014 ${props.summary.total}`;
25168
+ var _el$54 = _tmpl$2715(), _el$55 = _el$54.firstChild, _el$56 = _el$55.firstChild, _el$57 = _el$56.nextSibling, _el$58 = _el$57.firstChild, _el$59 = _el$58.firstChild, _el$60 = _el$59.nextSibling, _el$61 = _el$60.firstChild, _el$62 = _el$61.firstChild, _el$64 = _el$62.nextSibling; _el$64.nextSibling; var _el$65 = _el$61.nextSibling, _el$66 = _el$65.firstChild, _el$68 = _el$66.nextSibling; _el$68.nextSibling; var _el$69 = _el$65.nextSibling, _el$70 = _el$69.firstChild, _el$72 = _el$70.nextSibling; _el$72.nextSibling; var _el$78 = _el$55.nextSibling, _el$79 = _el$78.nextSibling, _el$80 = _el$79.firstChild, _el$81 = _el$80.firstChild, _el$82 = _el$81.firstChild, _el$83 = _el$82.firstChild, _el$84 = _el$82.nextSibling, _el$85 = _el$84.nextSibling; _el$85.nextSibling; var _el$87 = _el$80.nextSibling;
25169
+ insert(_el$54, createComponent(CardHeader, {
25170
+ title: "People who didn't buy",
25171
+ note: "Each person once, at the furthest point they reached. Anyone who has bought is left out."
25172
+ }), _el$55);
25173
+ insert(_el$56, createComponent(Chip, {
25174
+ label: "Everyone",
25175
+ get count() {
25176
+ return totalPeople();
24776
25177
  },
24777
- get note() {
24778
- return props.note;
24779
- }
24780
- }), _el$5);
24781
- insert(_el$5, createComponent(For, {
25178
+ get active() {
25179
+ return stage() === "all";
25180
+ },
25181
+ onClick: () => setStage("all")
25182
+ }), null);
25183
+ insert(_el$56, createComponent(For, {
24782
25184
  get each() {
24783
- return props.summary.segments;
25185
+ return visibleStages();
24784
25186
  },
24785
- children: (seg) => (() => {
24786
- var _el$24 = _tmpl$839(), _el$25 = _el$24.firstChild, _el$26 = _el$25.nextSibling, _el$27 = _el$26.firstChild, _el$28 = _el$26.nextSibling;
24787
- _el$24.$$click = () => setFilter(filter() === seg.key ? "all" : seg.key);
24788
- insert(_el$25, () => SEGMENT_LABEL[seg.key]);
24789
- insert(_el$28, () => seg.count, null);
24790
- insert(_el$28, createComponent(Show, {
24791
- get when() {
24792
- return hasSavings();
24793
- },
24794
- get children() {
24795
- var _el$29 = _tmpl$747(), _el$30 = _el$29.firstChild;
24796
- insert(_el$29, () => seg.savingsMembers, _el$30);
24797
- return _el$29;
24798
- }
24799
- }), null);
24800
- effect((_p$) => {
24801
- var _v$ = filter() === seg.key, _v$2 = `${SEGMENT_LABEL[seg.key]}: ${seg.count}`, _v$3 = filter() === "all" || filter() === seg.key ? 1 : 0.45, _v$4 = `${seg.count / max() * 100}%`, _v$5 = seg.count > 0 ? "4px" : "0";
24802
- _v$ !== _p$.e && setAttribute(_el$24, "aria-pressed", _p$.e = _v$);
24803
- _v$2 !== _p$.t && setAttribute(_el$24, "title", _p$.t = _v$2);
24804
- _v$3 !== _p$.a && setStyleProperty(_el$24, "opacity", _p$.a = _v$3);
24805
- _v$4 !== _p$.o && setStyleProperty(_el$27, "width", _p$.o = _v$4);
24806
- _v$5 !== _p$.i && setStyleProperty(_el$27, "min-width", _p$.i = _v$5);
24807
- return _p$;
24808
- }, {
24809
- e: void 0,
24810
- t: void 0,
24811
- a: void 0,
24812
- o: void 0,
24813
- i: void 0
24814
- });
24815
- return _el$24;
24816
- })()
25187
+ children: (st) => createComponent(Chip, {
25188
+ get label() {
25189
+ return st.label;
25190
+ },
25191
+ get count() {
25192
+ return stageCount(st.id);
25193
+ },
25194
+ get active() {
25195
+ return stage() === st.id;
25196
+ },
25197
+ onClick: () => setStage(stage() === st.id ? "all" : st.id)
25198
+ })
24817
25199
  }), null);
24818
- insert(_el$5, createComponent(Show, {
25200
+ _el$60.addEventListener("change", (e) => {
25201
+ setAccount(e.currentTarget.value);
25202
+ if (stage() !== "all" && keysFor(stage(), e.currentTarget.value, known()).length === 0) setStage("all");
25203
+ });
25204
+ insert(_el$61, () => props.segments.noAccount.total + props.segments.account.total, _el$64);
25205
+ insert(_el$65, () => props.segments.noAccount.total, _el$68);
25206
+ insert(_el$69, () => props.segments.account.total, _el$72);
25207
+ insert(_el$57, createComponent(Show, {
24819
25208
  get when() {
24820
- return hasSavings();
25209
+ return savingsTotal() > 0;
24821
25210
  },
24822
25211
  get children() {
24823
- var _el$6 = _tmpl$398(), _el$7 = _el$6.firstChild, _el$8 = _el$7.nextSibling, _el$0 = _el$8.nextSibling; _el$0.nextSibling;
24824
- _el$7.addEventListener("change", (e) => setSavingsOnly(e.currentTarget.checked));
24825
- insert(_el$6, () => props.summary.savingsMembers, _el$0);
24826
- effect(() => _el$7.checked = savingsOnly());
24827
- return _el$6;
25212
+ var _el$73 = _tmpl$2415(), _el$74 = _el$73.firstChild, _el$75 = _el$74.nextSibling, _el$77 = _el$75.nextSibling; _el$77.nextSibling;
25213
+ _el$74.addEventListener("change", (e) => setSavingsOnly(e.currentTarget.checked));
25214
+ insert(_el$73, savingsTotal, _el$77);
25215
+ effect(() => _el$74.checked = savingsOnly());
25216
+ return _el$73;
24828
25217
  }
24829
25218
  }), null);
24830
- insert(_el$1, createComponent(AddToSequence, {
25219
+ insert(_el$78, createComponent(AddToSequence, {
24831
25220
  get people() {
24832
25221
  return picked().map((p) => ({
24833
25222
  email: p.email,
@@ -24840,24 +25229,16 @@ function SegmentSection(props) {
24840
25229
  void refetch();
24841
25230
  }
24842
25231
  }));
24843
- _el$14.addEventListener("change", toggleAll);
24844
- insert(_el$12, createComponent(Show, {
24845
- get when() {
24846
- return props.group === "b";
24847
- },
24848
- get children() {
24849
- return _tmpl$468();
24850
- }
24851
- }), null);
24852
- insert(_el$19, createComponent(Show, {
25232
+ _el$83.addEventListener("change", toggleAll);
25233
+ insert(_el$87, createComponent(Show, {
24853
25234
  get when() {
24854
25235
  return people();
24855
25236
  },
24856
25237
  get fallback() {
24857
25238
  return (() => {
24858
- var _el$31 = _tmpl$935(), _el$32 = _el$31.firstChild;
24859
- insert(_el$32, createComponent(LoadingSpinner, {}));
24860
- return _el$31;
25239
+ var _el$98 = _tmpl$2813(), _el$99 = _el$98.firstChild;
25240
+ insert(_el$99, createComponent(LoadingSpinner, {}));
25241
+ return _el$98;
24861
25242
  })();
24862
25243
  },
24863
25244
  children: (page) => createComponent(Show, {
@@ -24866,11 +25247,11 @@ function SegmentSection(props) {
24866
25247
  },
24867
25248
  get fallback() {
24868
25249
  return (() => {
24869
- var _el$33 = _tmpl$935(), _el$34 = _el$33.firstChild;
24870
- insert(_el$34, createComponent(EmptyState, {
25250
+ var _el$100 = _tmpl$2813(), _el$101 = _el$100.firstChild;
25251
+ insert(_el$101, createComponent(EmptyState, {
24871
25252
  message: "Nobody here in this window"
24872
25253
  }));
24873
- return _el$33;
25254
+ return _el$100;
24874
25255
  })();
24875
25256
  },
24876
25257
  get children() {
@@ -24879,193 +25260,156 @@ function SegmentSection(props) {
24879
25260
  return page().people;
24880
25261
  },
24881
25262
  children: (p) => (() => {
24882
- var _el$35 = _tmpl$1318(), _el$36 = _el$35.firstChild, _el$37 = _el$36.firstChild, _el$38 = _el$36.nextSibling, _el$39 = _el$38.firstChild, _el$43 = _el$38.nextSibling, _el$44 = _el$43.nextSibling;
24883
- _el$37.addEventListener("change", (e) => setSelected({
25263
+ var _el$102 = _tmpl$3315(), _el$103 = _el$102.firstChild, _el$104 = _el$103.firstChild, _el$105 = _el$103.nextSibling, _el$106 = _el$105.firstChild, _el$112 = _el$105.nextSibling, _el$113 = _el$112.nextSibling;
25264
+ _el$104.addEventListener("change", (e) => setSelected({
24884
25265
  ...selected(),
24885
25266
  [p.email]: e.currentTarget.checked
24886
25267
  }));
24887
- insert(_el$39, createComponent(Show, {
25268
+ insert(_el$106, createComponent(Show, {
24888
25269
  get when() {
24889
25270
  return p.userId && nav;
24890
25271
  },
24891
25272
  get fallback() {
24892
- return p.name || p.email;
25273
+ return (() => {
25274
+ var _el$114 = _tmpl$2315();
25275
+ insert(_el$114, () => p.name || p.email);
25276
+ return _el$114;
25277
+ })();
24893
25278
  },
24894
25279
  get children() {
24895
- var _el$40 = _tmpl$031();
24896
- _el$40.$$click = () => nav.openCustomer(p.userId);
24897
- insert(_el$40, () => p.name || p.email);
24898
- return _el$40;
25280
+ var _el$107 = _tmpl$2912();
25281
+ _el$107.$$click = () => nav.openCustomer(p.userId);
25282
+ insert(_el$107, () => p.name || p.email);
25283
+ return _el$107;
24899
25284
  }
24900
25285
  }), null);
24901
- insert(_el$39, createComponent(Show, {
25286
+ insert(_el$106, createComponent(Show, {
24902
25287
  get when() {
24903
- return p.optedOut;
25288
+ return p.userId;
24904
25289
  },
24905
25290
  get children() {
24906
- return _tmpl$1127();
25291
+ return _tmpl$3011();
24907
25292
  }
24908
25293
  }), null);
24909
- insert(_el$38, createComponent(Show, {
25294
+ insert(_el$106, createComponent(Show, {
24910
25295
  get when() {
24911
- return p.name;
25296
+ return p.savingsMember;
24912
25297
  },
24913
25298
  get children() {
24914
- var _el$42 = _tmpl$1024();
24915
- insert(_el$42, () => p.email);
24916
- return _el$42;
25299
+ return _tmpl$3116();
24917
25300
  }
24918
25301
  }), null);
24919
- insert(_el$43, () => stoppedAt(p));
24920
- insert(_el$44, () => formatDate(p.enteredAt));
24921
- insert(_el$35, createComponent(Show, {
25302
+ insert(_el$106, createComponent(Show, {
24922
25303
  get when() {
24923
- return props.group === "b";
25304
+ return p.optedOut;
24924
25305
  },
24925
25306
  get children() {
24926
- var _el$45 = _tmpl$1220(), _el$46 = _el$45.firstChild;
24927
- insert(_el$46, (() => {
24928
- var _c$ = memo(() => !!p.accountCreatedAt);
24929
- return () => _c$() ? formatDate(p.accountCreatedAt) : "\u2014";
24930
- })());
24931
- insert(_el$45, createComponent(Show, {
24932
- get when() {
24933
- return p.savingsMember;
24934
- },
24935
- get children() {
24936
- return _tmpl$1128();
24937
- }
24938
- }), null);
24939
- return _el$45;
25307
+ return _tmpl$3215();
24940
25308
  }
24941
25309
  }), null);
25310
+ insert(_el$105, createComponent(Show, {
25311
+ get when() {
25312
+ return p.name;
25313
+ },
25314
+ get children() {
25315
+ var _el$111 = _tmpl$2216();
25316
+ insert(_el$111, () => p.email);
25317
+ return _el$111;
25318
+ }
25319
+ }), null);
25320
+ insert(_el$112, () => whereStopped(p));
25321
+ insert(_el$113, () => formatDate(p.enteredAt));
24942
25322
  effect((_p$) => {
24943
- var _v$6 = `Select ${p.name || p.email}`, _v$7 = p.optedOut;
24944
- _v$6 !== _p$.e && setAttribute(_el$37, "aria-label", _p$.e = _v$6);
24945
- _v$7 !== _p$.t && (_el$37.disabled = _p$.t = _v$7);
25323
+ var _v$9 = `Select ${p.name || p.email}`, _v$0 = p.optedOut;
25324
+ _v$9 !== _p$.e && setAttribute(_el$104, "aria-label", _p$.e = _v$9);
25325
+ _v$0 !== _p$.t && (_el$104.disabled = _p$.t = _v$0);
24946
25326
  return _p$;
24947
25327
  }, {
24948
25328
  e: void 0,
24949
25329
  t: void 0
24950
25330
  });
24951
- effect(() => _el$37.checked = !!selected()[p.email]);
24952
- return _el$35;
25331
+ effect(() => _el$104.checked = !!selected()[p.email]);
25332
+ return _el$102;
24953
25333
  })()
24954
25334
  });
24955
25335
  }
24956
25336
  })
24957
25337
  }));
24958
- insert(_el$4, createComponent(Show, {
25338
+ insert(_el$54, createComponent(Show, {
24959
25339
  get when() {
24960
25340
  return people()?.hasMore;
24961
25341
  },
24962
25342
  get children() {
24963
- var _el$20 = _tmpl$558(), _el$21 = _el$20.firstChild, _el$23 = _el$21.nextSibling; _el$23.nextSibling;
24964
- insert(_el$20, () => people().total, _el$23);
24965
- return _el$20;
25343
+ var _el$88 = _tmpl$2515(), _el$89 = _el$88.firstChild, _el$93 = _el$89.nextSibling; _el$93.nextSibling;
25344
+ insert(_el$88, () => people().total, _el$93);
25345
+ return _el$88;
24966
25346
  }
24967
25347
  }), null);
24968
- effect(() => _el$14.checked = allPicked());
24969
- return _el$4;
25348
+ insert(_el$54, createComponent(Show, {
25349
+ get when() {
25350
+ return (people()?.rejectedHidden ?? 0) > 0;
25351
+ },
25352
+ get children() {
25353
+ var _el$94 = _tmpl$2615(), _el$95 = _el$94.firstChild, _el$97 = _el$95.nextSibling; _el$97.nextSibling;
25354
+ insert(_el$94, () => people().rejectedHidden, _el$95);
25355
+ insert(_el$94, () => people().rejectedHidden === 1 ? "person is" : "people are", _el$97);
25356
+ return _el$94;
25357
+ }
25358
+ }), null);
25359
+ effect(() => _el$60.disabled = savingsOnly());
25360
+ effect(() => _el$60.value = account());
25361
+ effect(() => _el$83.checked = allPicked());
25362
+ return _el$54;
24970
25363
  })();
24971
25364
  }
24972
25365
  function Funnel() {
24973
25366
  const [days, setDays] = createSignal(30);
24974
25367
  const [summary] = createResource(days, (d) => apiFetch(`/admin/funnel/summary?days=${d}`));
24975
25368
  const [segments] = createResource(days, (d) => apiFetch(`/admin/funnel/segments?days=${d}`));
24976
- const dropoffMax = () => Math.max(1, ...(summary()?.stepDropoff ?? []).map((b) => b.count));
24977
25369
  return (() => {
24978
- var _el$48 = _tmpl$1418(), _el$49 = _el$48.firstChild, _el$50 = _el$49.firstChild;
24979
- insert(_el$48, createComponent(PageTitle, {
24980
- subtitle: "Who stopped short of a subscription, and where",
25370
+ var _el$115 = _tmpl$3415(), _el$116 = _el$115.firstChild, _el$117 = _el$116.firstChild;
25371
+ insert(_el$115, createComponent(PageTitle, {
25372
+ subtitle: "Who stopped short of buying, and where",
24981
25373
  children: "Funnel"
24982
- }), _el$49);
24983
- _el$50.addEventListener("change", (e) => setDays(parseInt(e.currentTarget.value)));
24984
- insert(_el$48, createComponent(Show, {
25374
+ }), _el$116);
25375
+ _el$117.addEventListener("change", (e) => setDays(parseInt(e.currentTarget.value)));
25376
+ insert(_el$115, createComponent(Show, {
24985
25377
  get when() {
24986
- return segments();
25378
+ return summary();
24987
25379
  },
24988
25380
  get fallback() {
24989
25381
  return createComponent(LoadingSpinner, {});
24990
25382
  },
24991
- children: (seg) => [createComponent(SegmentSection, {
24992
- group: "a",
24993
- title: "No account",
24994
- note: "We hold an email and nothing else. The only thing to offer them is to come back and finish the questionnaire. Buyers are excluded; the hottest stage wins when someone has done several.",
25383
+ children: (s) => [createComponent(Totals, {
24995
25384
  get summary() {
24996
- return seg().noAccount;
24997
- },
24998
- get days() {
24999
- return days();
25385
+ return s();
25000
25386
  }
25001
- }), createComponent(SegmentSection, {
25002
- group: "b",
25003
- title: "Account, not subscribed",
25004
- note: "They registered and never bought. They can log in and pick up their visit. \u201CNo tracked activity\u201D means we saw nothing after the account \u2014 for accounts older than step tracking, that is all we know.",
25387
+ }), createComponent(PagesCard, {
25005
25388
  get summary() {
25006
- return seg().account;
25007
- },
25008
- get days() {
25009
- return days();
25389
+ return s();
25010
25390
  }
25011
25391
  })]
25012
25392
  }), null);
25013
- insert(_el$48, createComponent(Show, {
25393
+ insert(_el$115, createComponent(Show, {
25014
25394
  get when() {
25015
- return summary();
25395
+ return segments();
25016
25396
  },
25017
- children: (s) => (() => {
25018
- var _el$51 = _tmpl$1518(), _el$52 = _el$51.firstChild;
25019
- insert(_el$51, createComponent(CardHeader, {
25020
- title: "Where abandons quit",
25021
- get note() {
25022
- return "Survey progress at last activity \u2014 the final bucket is the contact-info step. Leaving the page counts immediately; a silently-dropped session counts after 4 quiet hours." + (s().sessions.active > 0 ? ` ${s().sessions.active} session${s().sessions.active === 1 ? "" : "s"} still in progress \u2014 not counted yet.` : "");
25023
- }
25024
- }), _el$52);
25025
- insert(_el$52, createComponent(For, {
25026
- get each() {
25027
- return s().stepDropoff;
25028
- },
25029
- children: (b) => (() => {
25030
- var _el$53 = _tmpl$1718(), _el$55 = _el$53.firstChild, _el$56 = _el$55.nextSibling;
25031
- insert(_el$53, createComponent(Show, {
25032
- get when() {
25033
- return b.count > 0;
25034
- },
25035
- get children() {
25036
- var _el$54 = _tmpl$1618();
25037
- insert(_el$54, () => b.count);
25038
- return _el$54;
25039
- }
25040
- }), _el$55);
25041
- insert(_el$56, (() => {
25042
- var _c$2 = memo(() => b.bucket === 0);
25043
- return () => _c$2() ? "Start" : memo(() => b.bucket === 10)() ? "Info" : b.bucket === 5 ? "50%" : "";
25044
- })());
25045
- effect((_p$) => {
25046
- var _v$8 = `${b.bucket * 10}% through: ${b.count} abandon${b.count === 1 ? "" : "s"}`, _v$9 = `${Math.max(b.count > 0 ? 6 : 2, b.count / dropoffMax() * 100)}px`, _v$0 = b.count > 0 ? "var(--app-admin-primary)" : "var(--app-admin-border-soft)";
25047
- _v$8 !== _p$.e && setAttribute(_el$53, "title", _p$.e = _v$8);
25048
- _v$9 !== _p$.t && setStyleProperty(_el$55, "height", _p$.t = _v$9);
25049
- _v$0 !== _p$.a && setStyleProperty(_el$55, "background", _p$.a = _v$0);
25050
- return _p$;
25051
- }, {
25052
- e: void 0,
25053
- t: void 0,
25054
- a: void 0
25055
- });
25056
- return _el$53;
25057
- })()
25058
- }));
25059
- return _el$51;
25060
- })()
25397
+ children: (seg) => createComponent(PeopleCard, {
25398
+ get segments() {
25399
+ return seg();
25400
+ },
25401
+ get days() {
25402
+ return days();
25403
+ }
25404
+ })
25061
25405
  }), null);
25062
- effect(() => _el$50.value = days());
25063
- return _el$48;
25406
+ effect(() => _el$117.value = days());
25407
+ return _el$115;
25064
25408
  })();
25065
25409
  }
25066
25410
  delegateEvents(["click"]);
25067
25411
  var _tmpl$399 = /* @__PURE__ */ template(`<div>`);
25068
- var _tmpl$2122 = /* @__PURE__ */ template(`<div style=min-width:7.5rem><div style=font-size:0.75rem;text-transform:uppercase;letter-spacing:0.04em></div><div class=app-admin-heading style=font-size:1.375rem;font-weight:600;line-height:1.3>`);
25412
+ var _tmpl$2123 = /* @__PURE__ */ template(`<div style=min-width:7.5rem><div style=font-size:0.75rem;text-transform:uppercase;letter-spacing:0.04em></div><div class=app-admin-heading style=font-size:1.375rem;font-weight:600;line-height:1.3>`);
25069
25413
  var _tmpl$3100 = /* @__PURE__ */ template(`<div style="display:flex;flex-wrap:wrap;gap:1.25rem 2rem;margin-bottom:1.25rem">`);
25070
25414
  var _tmpl$469 = /* @__PURE__ */ template(`<table class=app-admin-table style=margin-bottom:1rem><thead><tr><th>Email</th><th>Sent</th><th>Link followed</th><th>Bought after this email</th><th>Unsubscribed after it</th></tr></thead><tbody>`);
25071
25415
  var _tmpl$559 = /* @__PURE__ */ template(`<div> of the <!> bought before any email reached them, so no email is credited above.`);
@@ -25083,11 +25427,11 @@ var _tmpl$1419 = /* @__PURE__ */ template(`<div>Offer: <!> granted \u2014 <!> op
25083
25427
  var _tmpl$1519 = /* @__PURE__ */ template(`<td data-label="Claimed the offer">`);
25084
25428
  var _tmpl$1619 = /* @__PURE__ */ template(`<tr><td data-label=Person></td><td data-label=Bought></td><td data-label="Last email before buying"></td><td data-label="Followed a link"></td><td data-label="Paid since">`);
25085
25429
  var _tmpl$1719 = /* @__PURE__ */ template(`<span>none yet`);
25086
- var _tmpl$1818 = /* @__PURE__ */ template(`<span>No`);
25087
- var _tmpl$1917 = /* @__PURE__ */ template(`<button type=button class="app-admin-btn app-admin-btn-sm">Open Sequences`);
25088
- var _tmpl$2016 = /* @__PURE__ */ template(`<div style=display:flex;justify-content:flex-end;gap:0.5rem;margin-bottom:0.75rem><button type=button class="app-admin-btn app-admin-btn-sm">Refresh`);
25089
- var _tmpl$2123 = /* @__PURE__ */ template(`<div style=display:grid;gap:1.25rem>`);
25090
- var _tmpl$2216 = /* @__PURE__ */ template(`<div style=margin-top:1.25rem;display:grid;gap:0.25rem><div>A purchase counts if it happened while the person was in the sequence, or within <!> days of their last email from it.</div><div>A link counts as followed when the person\u2019s browser opens the site from the email. Emails sent before link tracking was added show none.</div><div>Paid is every settled payment from those buyers since they were enrolled, not only the first.`);
25430
+ var _tmpl$1819 = /* @__PURE__ */ template(`<span>No`);
25431
+ var _tmpl$1918 = /* @__PURE__ */ template(`<button type=button class="app-admin-btn app-admin-btn-sm">Open Sequences`);
25432
+ var _tmpl$2017 = /* @__PURE__ */ template(`<div style=display:flex;justify-content:flex-end;gap:0.5rem;margin-bottom:0.75rem><button type=button class="app-admin-btn app-admin-btn-sm">Refresh`);
25433
+ var _tmpl$2124 = /* @__PURE__ */ template(`<div style=display:grid;gap:1.25rem>`);
25434
+ var _tmpl$2217 = /* @__PURE__ */ template(`<div style=margin-top:1.25rem;display:grid;gap:0.25rem><div>A purchase counts if it happened while the person was in the sequence, or within <!> days of their last email from it.</div><div>A link counts as followed when the person\u2019s browser opens the site from the email. Emails sent before link tracking was added show none.</div><div>Paid is every settled payment from those buyers since they were enrolled, not only the first.`);
25091
25435
  var muted = {
25092
25436
  color: "var(--app-admin-fg-muted)",
25093
25437
  "font-size": "0.8125rem"
@@ -25104,7 +25448,7 @@ function money(cents) {
25104
25448
  }
25105
25449
  function Figure(props) {
25106
25450
  return (() => {
25107
- var _el$ = _tmpl$2122(), _el$2 = _el$.firstChild, _el$3 = _el$2.nextSibling;
25451
+ var _el$ = _tmpl$2123(), _el$2 = _el$.firstChild, _el$3 = _el$2.nextSibling;
25108
25452
  insert(_el$2, () => props.label);
25109
25453
  insert(_el$3, () => props.value);
25110
25454
  insert(_el$, createComponent(Show, {
@@ -25337,7 +25681,7 @@ function SequenceCard(props) {
25337
25681
  insert(_el$56, (() => {
25338
25682
  var _c$2 = memo(() => !!b.clicked);
25339
25683
  return () => _c$2() ? "Yes" : (() => {
25340
- var _el$60 = _tmpl$1818();
25684
+ var _el$60 = _tmpl$1819();
25341
25685
  effect((_$p) => style(_el$60, muted, _$p));
25342
25686
  return _el$60;
25343
25687
  })();
@@ -25351,7 +25695,7 @@ function SequenceCard(props) {
25351
25695
  insert(_el$57, (() => {
25352
25696
  var _c$3 = memo(() => !!b.claimedOffer);
25353
25697
  return () => _c$3() ? "Yes" : (() => {
25354
- var _el$61 = _tmpl$1818();
25698
+ var _el$61 = _tmpl$1819();
25355
25699
  effect((_$p) => style(_el$61, muted, _$p));
25356
25700
  return _el$61;
25357
25701
  })();
@@ -25413,13 +25757,13 @@ function SequenceResults() {
25413
25757
  },
25414
25758
  get children() {
25415
25759
  return [(() => {
25416
- var _el$63 = _tmpl$2016(), _el$65 = _el$63.firstChild;
25760
+ var _el$63 = _tmpl$2017(), _el$65 = _el$63.firstChild;
25417
25761
  insert(_el$63, createComponent(Show, {
25418
25762
  get when() {
25419
25763
  return nav?.isTabEnabled("sequences");
25420
25764
  },
25421
25765
  get children() {
25422
- var _el$64 = _tmpl$1917();
25766
+ var _el$64 = _tmpl$1918();
25423
25767
  _el$64.$$click = () => nav.selectTab("sequences");
25424
25768
  return _el$64;
25425
25769
  }
@@ -25427,7 +25771,7 @@ function SequenceResults() {
25427
25771
  _el$65.$$click = () => void refetch();
25428
25772
  return _el$63;
25429
25773
  })(), (() => {
25430
- var _el$66 = _tmpl$2123();
25774
+ var _el$66 = _tmpl$2124();
25431
25775
  insert(_el$66, createComponent(For, {
25432
25776
  get each() {
25433
25777
  return report().sequences;
@@ -25438,7 +25782,7 @@ function SequenceResults() {
25438
25782
  }));
25439
25783
  return _el$66;
25440
25784
  })(), (() => {
25441
- var _el$67 = _tmpl$2216(), _el$68 = _el$67.firstChild, _el$69 = _el$68.firstChild, _el$71 = _el$69.nextSibling; _el$71.nextSibling;
25785
+ var _el$67 = _tmpl$2217(), _el$68 = _el$67.firstChild, _el$69 = _el$68.firstChild, _el$71 = _el$69.nextSibling; _el$71.nextSibling;
25442
25786
  insert(_el$68, days, _el$71);
25443
25787
  effect((_$p) => style(_el$67, {
25444
25788
  ...muted
@@ -25459,7 +25803,7 @@ var [supportChannelMode, setSupportChannelMode] = createSignal(null);
25459
25803
 
25460
25804
  // src/pages/admin/EmailNotifications.tsx
25461
25805
  var _tmpl$400 = /* @__PURE__ */ template(`<p style="font-size:0.75rem;margin:0.25rem 0 0">`);
25462
- var _tmpl$2124 = /* @__PURE__ */ template(`<div class=app-admin-card style=margin-top:1.25rem><div style="padding:1rem 1.25rem;border-bottom:1px solid var(--app-admin-border-soft);display:flex;justify-content:space-between;align-items:center;gap:1rem"><div><h2 class=app-admin-heading style=font-size:0.9375rem;font-weight:600;margin:0></h2></div></div><div style="padding:1rem 1.25rem;display:grid;gap:0.875rem">`);
25806
+ var _tmpl$2125 = /* @__PURE__ */ template(`<div class=app-admin-card style=margin-top:1.25rem><div style="padding:1rem 1.25rem;border-bottom:1px solid var(--app-admin-border-soft);display:flex;justify-content:space-between;align-items:center;gap:1rem"><div><h2 class=app-admin-heading style=font-size:0.9375rem;font-weight:600;margin:0></h2></div></div><div style="padding:1rem 1.25rem;display:grid;gap:0.875rem">`);
25463
25807
  var _tmpl$3101 = /* @__PURE__ */ template(`<label style=display:flex;align-items:center;gap:0.5rem;font-size:0.875rem;cursor:pointer><input type=checkbox>`);
25464
25808
  var _tmpl$470 = /* @__PURE__ */ template(`<button type=button class="app-admin-btn app-admin-btn-primary app-admin-btn-sm">`);
25465
25809
  var _tmpl$560 = /* @__PURE__ */ template(`<div><div style=margin-bottom:0.375rem>Recipients</div><div style=display:flex;flex-wrap:wrap;gap:0.375rem;margin-bottom:0.5rem></div><div style=display:flex;gap:0.5rem;max-width:28rem><input type=email class=app-admin-input placeholder=admin@example.com aria-label="Add recipient"><button type=button class="app-admin-btn app-admin-btn-sm">Add`);
@@ -25483,7 +25827,7 @@ var label2 = {
25483
25827
  };
25484
25828
  function Card(props) {
25485
25829
  return (() => {
25486
- var _el$ = _tmpl$2124(), _el$2 = _el$.firstChild, _el$3 = _el$2.firstChild, _el$4 = _el$3.firstChild, _el$6 = _el$2.nextSibling;
25830
+ var _el$ = _tmpl$2125(), _el$2 = _el$.firstChild, _el$3 = _el$2.firstChild, _el$4 = _el$3.firstChild, _el$6 = _el$2.nextSibling;
25487
25831
  insert(_el$4, () => props.title);
25488
25832
  insert(_el$3, createComponent(Show, {
25489
25833
  get when() {
@@ -25921,7 +26265,7 @@ function EmailNotifications() {
25921
26265
  }
25922
26266
  delegateEvents(["click", "input", "keydown"]);
25923
26267
  var _tmpl$401 = /* @__PURE__ */ template(`<div class=app-admin-card style=margin-top:1.25rem><div style="padding:1rem 1.25rem;border-bottom:1px solid var(--app-admin-border-soft)"><h2 class=app-admin-heading style=font-size:0.9375rem;font-weight:600;margin:0></h2><p style="font-size:0.75rem;margin:0.25rem 0 0"></p></div><div>`);
25924
- var _tmpl$2125 = /* @__PURE__ */ template(`<div style=font-size:0.75rem;margin-top:0.25rem>`);
26268
+ var _tmpl$2126 = /* @__PURE__ */ template(`<div style=font-size:0.75rem;margin-top:0.25rem>`);
25925
26269
  var _tmpl$3102 = /* @__PURE__ */ template(`<div style="display:flex;align-items:center;justify-content:space-between;gap:1rem;padding:0.875rem 1.25rem;border-bottom:1px solid var(--app-admin-border-soft)"><div style=min-width:0><div style=font-size:0.875rem;font-weight:600></div><div style=margin-top:0.125rem></div></div><div style=flex-shrink:0>`);
25926
26270
  var _tmpl$471 = /* @__PURE__ */ template(`<div class=app-admin-notice role=alert style=margin-top:1.25rem>Features could not be loaded. `);
25927
26271
  var _tmpl$561 = /* @__PURE__ */ template(`<div>`);
@@ -25967,7 +26311,7 @@ function Row(props) {
25967
26311
  return props.note;
25968
26312
  },
25969
26313
  get children() {
25970
- var _el$0 = _tmpl$2125();
26314
+ var _el$0 = _tmpl$2126();
25971
26315
  insert(_el$0, () => props.note);
25972
26316
  effect((_$p) => style(_el$0, {
25973
26317
  ...muted2
@@ -26237,14 +26581,14 @@ function Features() {
26237
26581
  }
26238
26582
  delegateEvents(["click", "input"]);
26239
26583
  var _tmpl$407 = /* @__PURE__ */ template(`<p style="font-size:0.75rem;margin:0.25rem 0 0">`);
26240
- var _tmpl$2126 = /* @__PURE__ */ template(`<div class=app-admin-card style=margin-top:1.25rem><div style="padding:1rem 1.25rem;border-bottom:1px solid var(--app-admin-border-soft);display:flex;justify-content:space-between;align-items:center;gap:1rem"><div><h2 class=app-admin-heading style=font-size:0.9375rem;font-weight:600;margin:0></h2></div></div><div style="padding:1rem 1.25rem;display:grid;gap:0.875rem">`);
26584
+ var _tmpl$2127 = /* @__PURE__ */ template(`<div class=app-admin-card style=margin-top:1.25rem><div style="padding:1rem 1.25rem;border-bottom:1px solid var(--app-admin-border-soft);display:flex;justify-content:space-between;align-items:center;gap:1rem"><div><h2 class=app-admin-heading style=font-size:0.9375rem;font-weight:600;margin:0></h2></div></div><div style="padding:1rem 1.25rem;display:grid;gap:0.875rem">`);
26241
26585
  var muted3 = {
26242
26586
  "font-size": "0.8125rem",
26243
26587
  color: "var(--app-admin-fg-muted)"
26244
26588
  };
26245
26589
  function SmsCard(props) {
26246
26590
  return (() => {
26247
- var _el$ = _tmpl$2126(), _el$2 = _el$.firstChild, _el$3 = _el$2.firstChild, _el$4 = _el$3.firstChild, _el$6 = _el$2.nextSibling;
26591
+ var _el$ = _tmpl$2127(), _el$2 = _el$.firstChild, _el$3 = _el$2.firstChild, _el$4 = _el$3.firstChild, _el$6 = _el$2.nextSibling;
26248
26592
  insert(_el$4, () => props.title);
26249
26593
  insert(_el$3, createComponent(Show, {
26250
26594
  get when() {
@@ -26265,12 +26609,12 @@ function SmsCard(props) {
26265
26609
  })();
26266
26610
  }
26267
26611
  var _tmpl$408 = /* @__PURE__ */ template(`<div class=app-admin-notice role=alert>`);
26268
- var _tmpl$2127 = /* @__PURE__ */ template(`<div style=overflow:auto><table class=app-admin-table><thead><tr><th>To</th><th>Text</th><th>Status</th><th>Sent</th><th>Problem</th></tr></thead><tbody>`);
26612
+ var _tmpl$2128 = /* @__PURE__ */ template(`<div style=overflow:auto><table class=app-admin-table><thead><tr><th>To</th><th>Text</th><th>Status</th><th>Sent</th><th>Problem</th></tr></thead><tbody>`);
26269
26613
  var _tmpl$3103 = /* @__PURE__ */ template(`<div><button type=button class="app-admin-btn app-admin-btn-sm">`);
26270
26614
  var _tmpl$475 = /* @__PURE__ */ template(`<select class=app-admin-input aria-label="Filter by status"style=width:auto><option value>All statuses`);
26271
26615
  var _tmpl$564 = /* @__PURE__ */ template(`<option>`);
26272
26616
  var _tmpl$658 = /* @__PURE__ */ template(`<tr><td data-label=To class=app-admin-text-mono></td><td data-label=Text></td><td data-label=Status><span></span></td><td data-label=Sent class=app-admin-text-muted></td><td data-label=Problem class=app-admin-text-muted>`);
26273
- var PAGE_SIZE = 25;
26617
+ var PAGE_SIZE2 = 25;
26274
26618
  var BASE_STATUSES = ["delivered", "sent", "failed", "blocked"];
26275
26619
  var humanize4 = (key) => key.replace(/([A-Z])/g, " $1").replace(/[_-]/g, " ").replace(/^\w/, (c) => c.toUpperCase()).trim();
26276
26620
  var statusVariant = (status) => {
@@ -26310,7 +26654,7 @@ function SmsLogCard(props) {
26310
26654
  const res = await adminApi.listSmsMessages({
26311
26655
  status: status() || void 0,
26312
26656
  before: more ? next() ?? void 0 : void 0,
26313
- limit: PAGE_SIZE
26657
+ limit: PAGE_SIZE2
26314
26658
  });
26315
26659
  if (mine !== generation) return;
26316
26660
  setRows(more ? [...rows(), ...res.messages] : res.messages);
@@ -26366,7 +26710,7 @@ function SmsLogCard(props) {
26366
26710
  return rows().length > 0;
26367
26711
  },
26368
26712
  get children() {
26369
- var _el$2 = _tmpl$2127(), _el$3 = _el$2.firstChild, _el$4 = _el$3.firstChild, _el$5 = _el$4.nextSibling;
26713
+ var _el$2 = _tmpl$2128(), _el$3 = _el$2.firstChild, _el$4 = _el$3.firstChild, _el$5 = _el$4.nextSibling;
26370
26714
  insert(_el$5, createComponent(For, {
26371
26715
  get each() {
26372
26716
  return rows();
@@ -26478,7 +26822,7 @@ var tokenText = (token) => `{{${token}}}`;
26478
26822
 
26479
26823
  // src/pages/admin/sms/SmsTemplatesCard.tsx
26480
26824
  var _tmpl$409 = /* @__PURE__ */ template(`<div class=app-admin-notice role=note>This text has a character outside the basic SMS alphabet (a curly quote, an emoji or an accented letter), so it is sent in a form that fits only 70 characters per segment instead of 160.`);
26481
- var _tmpl$2128 = /* @__PURE__ */ template(`<div style=display:flex;flex-wrap:wrap;align-items:center;gap:0.375rem><span>Insert:`);
26825
+ var _tmpl$2129 = /* @__PURE__ */ template(`<div style=display:flex;flex-wrap:wrap;align-items:center;gap:0.375rem><span>Insert:`);
26482
26826
  var _tmpl$3104 = /* @__PURE__ */ template(`<div>Preview: <span style=color:var(--app-admin-fg)>`);
26483
26827
  var _tmpl$476 = /* @__PURE__ */ template(`<div class=app-admin-notice role=alert>`);
26484
26828
  var _tmpl$565 = /* @__PURE__ */ template(`<div>The test sends the saved text. Save your changes first to try them.`);
@@ -26608,7 +26952,7 @@ function TemplateEditor(props) {
26608
26952
  return saved().tokens.length > 0;
26609
26953
  },
26610
26954
  get children() {
26611
- var _el$24 = _tmpl$2128(), _el$25 = _el$24.firstChild;
26955
+ var _el$24 = _tmpl$2129(), _el$25 = _el$24.firstChild;
26612
26956
  insert(_el$24, createComponent(For, {
26613
26957
  get each() {
26614
26958
  return saved().tokens;
@@ -26752,7 +27096,7 @@ delegateEvents(["input", "click"]);
26752
27096
 
26753
27097
  // src/pages/admin/SmsSettings.tsx
26754
27098
  var _tmpl$477 = /* @__PURE__ */ template(`<div style=display:flex;gap:1rem;font-size:0.875rem><div style=width:8rem;flex-shrink:0></div><div style=min-width:0;word-break:break-word>`);
26755
- var _tmpl$2129 = /* @__PURE__ */ template(`<p data-testid=sms-status-text style=margin:0;font-size:0.875rem>`);
27099
+ var _tmpl$2130 = /* @__PURE__ */ template(`<p data-testid=sms-status-text style=margin:0;font-size:0.875rem>`);
26756
27100
  var _tmpl$3105 = /* @__PURE__ */ template(`<button type=button class=app-admin-link-btn>Go to Features`);
26757
27101
  var _tmpl$478 = /* @__PURE__ */ template(`<div class=app-admin-notice data-testid=sms-feature-off>Before this site can text customers, a number has to be registered with carriers, which we set up for you. Ask for it under Settings \u203A Features.`);
26758
27102
  var _tmpl$566 = /* @__PURE__ */ template(`<a target=_blank rel="noopener noreferrer">`);
@@ -26794,7 +27138,7 @@ function StatusCard(props) {
26794
27138
  },
26795
27139
  get children() {
26796
27140
  return [(() => {
26797
- var _el$4 = _tmpl$2129();
27141
+ var _el$4 = _tmpl$2130();
26798
27142
  insert(_el$4, (() => {
26799
27143
  var _c$ = memo(() => !!s().ready);
26800
27144
  return () => _c$() ? "Text messages are on and ready to send." : NOT_READY[s().notReadyReason ?? "feature_off"];
@@ -26955,7 +27299,7 @@ function SmsSettings() {
26955
27299
  }
26956
27300
  delegateEvents(["click"]);
26957
27301
  var _tmpl$479 = /* @__PURE__ */ template(`<option value disabled>Unknown role`);
26958
- var _tmpl$2130 = /* @__PURE__ */ template(`<select class=app-admin-input>`);
27302
+ var _tmpl$2131 = /* @__PURE__ */ template(`<select class=app-admin-input>`);
26959
27303
  var _tmpl$3106 = /* @__PURE__ */ template(`<option>`);
26960
27304
  var _tmpl$480 = /* @__PURE__ */ template(`<div class=app-admin-card-soft style="padding:0.625rem 0.875rem;margin-top:0.75rem;font-size:0.875rem">`);
26961
27305
  var _tmpl$567 = /* @__PURE__ */ template(`<table class=app-admin-table><thead><tr><th>Admin</th><th>Role</th><th style=text-align:right></th></tr></thead><tbody>`);
@@ -26979,7 +27323,7 @@ var ROLE_LABEL = {
26979
27323
  };
26980
27324
  function RoleSelect(props) {
26981
27325
  return (() => {
26982
- var _el$ = _tmpl$2130();
27326
+ var _el$ = _tmpl$2131();
26983
27327
  _el$.addEventListener("change", (e) => props.onChange(e.currentTarget.value));
26984
27328
  insert(_el$, createComponent(Show, {
26985
27329
  get when() {
@@ -27176,7 +27520,7 @@ delegateEvents(["input", "click"]);
27176
27520
 
27177
27521
  // src/pages/AdminDashboard.tsx
27178
27522
  var _tmpl$481 = /* @__PURE__ */ template(`<span style=font-size:1rem;opacity:0.7;flex-shrink:0>`);
27179
- var _tmpl$2131 = /* @__PURE__ */ template(`<button type=button style="display:flex;align-items:center;gap:0.75rem;padding:0.625rem 0.75rem;border-radius:var(--app-admin-radius-sm);font-size:0.875rem;font-weight:500;text-align:left;border:none;cursor:pointer">`);
27523
+ var _tmpl$2132 = /* @__PURE__ */ template(`<button type=button style="display:flex;align-items:center;gap:0.75rem;padding:0.625rem 0.75rem;border-radius:var(--app-admin-radius-sm);font-size:0.875rem;font-weight:500;text-align:left;border:none;cursor:pointer">`);
27180
27524
  var _tmpl$3107 = /* @__PURE__ */ template(`<div class="app-admin-root app-admin-shell"data-scrollable style=position:sticky><div class=app-admin-shell-header><button type=button class=app-admin-shell-menu-trigger aria-label="Open admin menu"><svg width=22 height=22 viewBox="0 0 24 24"fill=none stroke=currentColor stroke-width=2 stroke-linecap=round aria-hidden=true><line x1=3 y1=6 x2=21 y2=6></line><line x1=3 y1=12 x2=21 y2=12></line><line x1=3 y1=18 x2=21 y2=18></line></svg></button><span class=app-admin-shell-header-title></span></div><div class=app-admin-backdrop aria-hidden=true></div><aside class=app-admin-sidebar><div style=padding:1.25rem><h2 style="font-size:0.7rem;font-weight:500;color:var(--app-admin-fg-muted);text-transform:uppercase;letter-spacing:0.08em;margin:0 0 1rem">Admin Panel</h2><nav style=display:flex;flex-direction:column;gap:0.25rem></nav></div></aside><div class=app-admin-content>`);
27181
27525
  var _tmpl$485 = /* @__PURE__ */ template(`<h3 style="font-size:0.625rem;font-weight:600;color:var(--app-admin-fg-muted);text-transform:uppercase;letter-spacing:0.08em;margin:1rem 0 0.375rem;padding:0 0.75rem">`);
27182
27526
  var _tmpl$568 = /* @__PURE__ */ template(`<div role=alert style="margin:1rem 0;padding:1.25rem 1.5rem;border:1px solid var(--app-admin-border);border-radius:var(--app-admin-radius-sm);background:var(--app-admin-surface);color:var(--app-admin-fg)"><div style=font-weight:600;margin-bottom:0.375rem>Not available for your role</div><div style=color:var(--app-admin-fg-muted);font-size:0.875rem>Ask an owner of this site if you need access to this section.`);
@@ -27347,7 +27691,7 @@ function AdminDashboard(props) {
27347
27691
  };
27348
27692
  const topOffset = () => props.topOffset ?? "0px";
27349
27693
  const TabButton = (btnProps) => (() => {
27350
- var _el$ = _tmpl$2131();
27694
+ var _el$ = _tmpl$2132();
27351
27695
  _el$.$$click = () => handleTabClick(btnProps.tab);
27352
27696
  insert(_el$, createComponent(Show, {
27353
27697
  get when() {
@@ -27761,7 +28105,7 @@ function affiliateSubTabFromPath(pathname, base = "/admin") {
27761
28105
  return "overview";
27762
28106
  }
27763
28107
  var _tmpl$486 = /* @__PURE__ */ template(`<div class=app-admin-modal-backdrop><div class="app-admin-card app-admin-modal"style=max-width:32rem><div class=app-admin-modal-header><h3 class=app-admin-heading style=font-size:1rem;margin:0>Customer dashboard preview</h3><button type=button class="app-admin-btn app-admin-btn-ghost"style="border:none;padding:0.25rem 0.5rem;font-size:1.25rem">\xD7</button></div><div class=app-admin-modal-body><div style="padding:0.5rem 0.75rem;border-radius:var(--app-admin-radius-sm);background:var(--app-admin-warning-bg);color:var(--app-admin-warning-fg);font-size:0.75rem;font-weight:500">Viewing as <!> \u2014 read-only`);
27764
- var _tmpl$2132 = /* @__PURE__ */ template(`<div style="display:flex;align-items:center;justify-content:space-between;gap:0.75rem;padding:0.5rem 0.75rem;border-radius:var(--app-admin-radius-sm);background:var(--app-admin-danger-bg);color:var(--app-admin-danger-fg);font-size:0.75rem;font-weight:500"><span></span><button type=button class="app-admin-btn app-admin-btn-ghost"style="padding:0.25rem 0.75rem">Retry`);
28108
+ var _tmpl$2133 = /* @__PURE__ */ template(`<div style="display:flex;align-items:center;justify-content:space-between;gap:0.75rem;padding:0.5rem 0.75rem;border-radius:var(--app-admin-radius-sm);background:var(--app-admin-danger-bg);color:var(--app-admin-danger-fg);font-size:0.75rem;font-weight:500"><span></span><button type=button class="app-admin-btn app-admin-btn-ghost"style="padding:0.25rem 0.75rem">Retry`);
27765
28109
  var _tmpl$3108 = /* @__PURE__ */ template(`<p style=color:var(--app-admin-fg-muted);font-size:0.875rem>Could not load this customer's dashboard.`);
27766
28110
  var _tmpl$487 = /* @__PURE__ */ template(`<div><h3>Profile</h3><div class=app-admin-card-soft style=padding:0.75rem><p style=font-weight:600;font-size:0.9375rem;margin:0></p><p style="font-size:0.8125rem;color:var(--app-admin-fg-muted);margin:0.25rem 0 0">`);
27767
28111
  var _tmpl$569 = /* @__PURE__ */ template(`<div><h3>Subscription`);
@@ -27796,7 +28140,7 @@ function PatientDashboardPreview(props) {
27796
28140
  },
27797
28141
  keyed: true,
27798
28142
  children: (msg) => (() => {
27799
- var _el$1 = _tmpl$2132(), _el$10 = _el$1.firstChild, _el$11 = _el$10.nextSibling;
28143
+ var _el$1 = _tmpl$2133(), _el$10 = _el$1.firstChild, _el$11 = _el$10.nextSibling;
27800
28144
  insert(_el$10, msg);
27801
28145
  _el$11.$$click = () => data.retry();
27802
28146
  return _el$1;
@@ -27975,7 +28319,7 @@ function PatientDashboardPreview(props) {
27975
28319
  }
27976
28320
  delegateEvents(["click"]);
27977
28321
  var _tmpl$488 = /* @__PURE__ */ template(`<div style=margin-bottom:1rem>`);
27978
- var _tmpl$2133 = /* @__PURE__ */ template(`<form><div style=display:grid;gap:1rem;margin-bottom:1.5rem><div style="display:grid;grid-template-columns:repeat(2, 1fr);gap:1rem"></div></div><div style=margin-bottom:1.5rem></div><div style=display:flex;gap:0.75rem>`);
28322
+ var _tmpl$2134 = /* @__PURE__ */ template(`<form><div style=display:grid;gap:1rem;margin-bottom:1.5rem><div style="display:grid;grid-template-columns:repeat(2, 1fr);gap:1rem"></div></div><div style=margin-bottom:1.5rem></div><div style=display:flex;gap:0.75rem>`);
27979
28323
  var _tmpl$3109 = /* @__PURE__ */ template(`<div class=pay-method style="max-width:480px;margin:0 auto;padding:2rem 1.25rem"><p style="color:var(--app-portal-fg-muted, #6e6a66);margin-bottom:1.5rem">Enter a new card for your subscription. Your current card stays active until this succeeds.`);
27980
28324
  var LIVE = /* @__PURE__ */ new Set(["active", "paused", "past_due"]);
27981
28325
  function UpdatePaymentMethod(props) {
@@ -28037,7 +28381,7 @@ function UpdatePaymentMethod(props) {
28037
28381
  return memo(() => !!!resolving())() && !noSubscription();
28038
28382
  },
28039
28383
  get children() {
28040
- var _el$3 = _tmpl$2133(), _el$5 = _el$3.firstChild, _el$6 = _el$5.firstChild, _el$7 = _el$5.nextSibling, _el$8 = _el$7.nextSibling;
28384
+ var _el$3 = _tmpl$2134(), _el$5 = _el$3.firstChild, _el$6 = _el$5.firstChild, _el$7 = _el$5.nextSibling, _el$8 = _el$7.nextSibling;
28041
28385
  _el$3.addEventListener("submit", handleSubmit);
28042
28386
  insert(_el$3, createComponent(Show, {
28043
28387
  get when() {
@@ -28123,8 +28467,8 @@ function UpdatePaymentMethod(props) {
28123
28467
  })();
28124
28468
  }
28125
28469
  var _tmpl$489 = /* @__PURE__ */ template(`<a class=ship__track target=_blank rel="noopener noreferrer">Track<!> \u2197`);
28126
- var _tmpl$2134 = /* @__PURE__ */ template(`<div class=ship><p class=ship__eta></p><div class=ship__chip-row><button type=button class=ship__chip><span class=ship__num></span><i class="ph ph-copy ship__copy-icon"aria-hidden=true></i><span class=ship__copied>Copied \u2713</span></button></div><span class=portal-sr-only role=status aria-live=polite>`);
28127
- var _tmpl$3116 = /* @__PURE__ */ template(`<span class=refill__cycle>Day <!> of `);
28470
+ var _tmpl$2135 = /* @__PURE__ */ template(`<div class=ship><p class=ship__eta></p><div class=ship__chip-row><button type=button class=ship__chip><span class=ship__num></span><i class="ph ph-copy ship__copy-icon"aria-hidden=true></i><span class=ship__copied>Copied \u2713</span></button></div><span class=portal-sr-only role=status aria-live=polite>`);
28471
+ var _tmpl$3117 = /* @__PURE__ */ template(`<span class=refill__cycle>Day <!> of `);
28128
28472
  var _tmpl$490 = /* @__PURE__ */ template(`<div class=refill data-testid=refill-strip><div class=refill__head><span class=lab-label>Your plan</span></div><div class=refill__rail>`);
28129
28473
  var _tmpl$570 = /* @__PURE__ */ template(`<span class=refill__cycle>Preparing your next fill`);
28130
28474
  var _tmpl$666 = /* @__PURE__ */ template(`<div><span class=refill__dot aria-hidden=true></span><span class="lab-label refill__label"></span><span class=refill__date></span><span class=refill__rel>`);
@@ -28141,9 +28485,9 @@ var _tmpl$1422 = /* @__PURE__ */ template(`<button type=button class="portal-btn
28141
28485
  var _tmpl$1521 = /* @__PURE__ */ template(`<button type=button class="portal-btn portal-btn--ghost thread__action">Talk to your provider`);
28142
28486
  var _tmpl$1621 = /* @__PURE__ */ template(`<li><div class=thread__rail><span class=thread__bead></span></div><div><div class=thread__top><span class="lab-label thread__label">`);
28143
28487
  var _tmpl$1721 = /* @__PURE__ */ template(`<p class="thread__caption thread__await"data-testid=await-messaging>Your care team is reviewing your request. You\u2019ll be able to message them here once your consult begins.`);
28144
- var _tmpl$1819 = /* @__PURE__ */ template(`<p class="thread__caption thread__await"data-testid=await-messaging>Your provider will follow up with you about next steps.`);
28145
- var _tmpl$1918 = /* @__PURE__ */ template(`<span class=tracker__dose> \xB7 `);
28146
- var _tmpl$2017 = /* @__PURE__ */ template(`<div class=tracker data-testid=order-tracker><div class=tracker__intro><span class=lab-label>Your order</span><p class=tracker__med></p></div><ol>`);
28488
+ var _tmpl$1820 = /* @__PURE__ */ template(`<p class="thread__caption thread__await"data-testid=await-messaging>Your provider will follow up with you about next steps.`);
28489
+ var _tmpl$1919 = /* @__PURE__ */ template(`<span class=tracker__dose> \xB7 `);
28490
+ var _tmpl$2018 = /* @__PURE__ */ template(`<div class=tracker data-testid=order-tracker><div class=tracker__intro><span class=lab-label>Your order</span><p class=tracker__med></p></div><ol>`);
28147
28491
  function TrackingChip(props) {
28148
28492
  let copied;
28149
28493
  const [announce, setAnnounce] = createSignal("");
@@ -28160,7 +28504,7 @@ function TrackingChip(props) {
28160
28504
  }
28161
28505
  };
28162
28506
  return (() => {
28163
- var _el$ = _tmpl$2134(), _el$2 = _el$.firstChild, _el$3 = _el$2.nextSibling, _el$4 = _el$3.firstChild, _el$5 = _el$4.firstChild, _el$6 = _el$5.nextSibling, _el$7 = _el$6.nextSibling, _el$10 = _el$3.nextSibling;
28507
+ var _el$ = _tmpl$2135(), _el$2 = _el$.firstChild, _el$3 = _el$2.nextSibling, _el$4 = _el$3.firstChild, _el$5 = _el$4.firstChild, _el$6 = _el$5.nextSibling, _el$7 = _el$6.nextSibling, _el$10 = _el$3.nextSibling;
28164
28508
  insert(_el$2, () => props.eta);
28165
28509
  _el$4.$$click = copy;
28166
28510
  insert(_el$5, () => props.number);
@@ -28201,7 +28545,7 @@ function OrderTracker(props) {
28201
28545
  return _tmpl$570();
28202
28546
  },
28203
28547
  get children() {
28204
- var _el$14 = _tmpl$3116(), _el$15 = _el$14.firstChild, _el$17 = _el$15.nextSibling; _el$17.nextSibling;
28548
+ var _el$14 = _tmpl$3117(), _el$15 = _el$14.firstChild, _el$17 = _el$15.nextSibling; _el$17.nextSibling;
28205
28549
  insert(_el$14, () => r().cycleDay, _el$17);
28206
28550
  insert(_el$14, () => r().cycleLength, null);
28207
28551
  return _el$14;
@@ -28373,7 +28717,7 @@ function OrderTracker(props) {
28373
28717
  return props.messagingEnabled;
28374
28718
  },
28375
28719
  get fallback() {
28376
- return _tmpl$1819();
28720
+ return _tmpl$1820();
28377
28721
  },
28378
28722
  get children() {
28379
28723
  var _el$54 = _tmpl$1521();
@@ -28409,14 +28753,14 @@ function OrderTracker(props) {
28409
28753
  children: (rx) => {
28410
28754
  const view = buildTrackerView(rx());
28411
28755
  return (() => {
28412
- var _el$57 = _tmpl$2017(), _el$58 = _el$57.firstChild, _el$59 = _el$58.firstChild, _el$60 = _el$59.nextSibling, _el$63 = _el$58.nextSibling;
28756
+ var _el$57 = _tmpl$2018(), _el$58 = _el$57.firstChild, _el$59 = _el$58.firstChild, _el$60 = _el$59.nextSibling, _el$63 = _el$58.nextSibling;
28413
28757
  insert(_el$60, () => props.medicationName, null);
28414
28758
  insert(_el$60, createComponent(Show, {
28415
28759
  get when() {
28416
28760
  return rx().dosage;
28417
28761
  },
28418
28762
  get children() {
28419
- var _el$61 = _tmpl$1918(); _el$61.firstChild;
28763
+ var _el$61 = _tmpl$1919(); _el$61.firstChild;
28420
28764
  insert(_el$61, () => rx().dosage, null);
28421
28765
  return _el$61;
28422
28766
  }
@@ -28452,8 +28796,8 @@ function OrderTracker(props) {
28452
28796
  }
28453
28797
  delegateEvents(["click"]);
28454
28798
  var _tmpl$491 = /* @__PURE__ */ template(`<span class=rx-row__dose> \xB7 `);
28455
- var _tmpl$2135 = /* @__PURE__ */ template(`<div class=rx-row__body>`);
28456
- var _tmpl$3117 = /* @__PURE__ */ template(`<div data-testid=rx-row><button type=button class=rx-row__head><span class=rx-row__med></span><span class=rx-row__status></span><i aria-hidden=true>`);
28799
+ var _tmpl$2136 = /* @__PURE__ */ template(`<div class=rx-row__body>`);
28800
+ var _tmpl$3118 = /* @__PURE__ */ template(`<div data-testid=rx-row><button type=button class=rx-row__head><span class=rx-row__med></span><span class=rx-row__status></span><i aria-hidden=true>`);
28457
28801
  var STATUS_LABEL = {
28458
28802
  pending: "Under review",
28459
28803
  approved: "Approved",
@@ -28470,7 +28814,7 @@ function RxRow(props) {
28470
28814
  return STATUS_LABEL[props.rx.status] ?? props.rx.status;
28471
28815
  };
28472
28816
  return (() => {
28473
- var _el$ = _tmpl$3117(), _el$2 = _el$.firstChild, _el$3 = _el$2.firstChild, _el$6 = _el$3.nextSibling, _el$7 = _el$6.nextSibling;
28817
+ var _el$ = _tmpl$3118(), _el$2 = _el$.firstChild, _el$3 = _el$2.firstChild, _el$6 = _el$3.nextSibling, _el$7 = _el$6.nextSibling;
28474
28818
  _el$2.$$click = () => setOpen((v) => !v);
28475
28819
  insert(_el$3, () => props.rx.drugName ?? "Medication", null);
28476
28820
  insert(_el$3, createComponent(Show, {
@@ -28489,7 +28833,7 @@ function RxRow(props) {
28489
28833
  return open();
28490
28834
  },
28491
28835
  get children() {
28492
- var _el$8 = _tmpl$2135();
28836
+ var _el$8 = _tmpl$2136();
28493
28837
  insert(_el$8, createComponent(OrderTracker, {
28494
28838
  get request() {
28495
28839
  return props.request;
@@ -28533,8 +28877,8 @@ function RxRow(props) {
28533
28877
  }
28534
28878
  delegateEvents(["click"]);
28535
28879
  var _tmpl$495 = /* @__PURE__ */ template(`<div class=plan data-testid=plan-billing><span class=lab-label>Plan &amp; billing`);
28536
- var _tmpl$2136 = /* @__PURE__ */ template(`<div class=plan__empty><h2 class=plan__empty-title>No active plan</h2><p class=plan__empty-text>Start your treatment to set up your monthly plan.</p><a class="portal-btn portal-btn--primary">Start your intake`);
28537
- var _tmpl$3118 = /* @__PURE__ */ template(`<p class=membership__dose>`);
28880
+ var _tmpl$2137 = /* @__PURE__ */ template(`<div class=plan__empty><h2 class=plan__empty-title>No active plan</h2><p class=plan__empty-text>Start your treatment to set up your monthly plan.</p><a class="portal-btn portal-btn--primary">Start your intake`);
28881
+ var _tmpl$3119 = /* @__PURE__ */ template(`<p class=membership__dose>`);
28538
28882
  var _tmpl$496 = /* @__PURE__ */ template(`<div data-testid=membership-card><div class=membership__sheen aria-hidden=true></div><div class=membership__top><span class="lab-label membership__status"></span><span class=membership__brand></span></div><h2 class=membership__med></h2><div class=membership__bottom><span class=membership__price><span class=membership__per>/mo</span></span><span class=membership__renew>Renews `);
28539
28883
  var _tmpl$571 = /* @__PURE__ */ template(`<dl class=ledger><div class=ledger__row><dt>Member since</dt><dd></dd></div><div class=ledger__row><dt>Next billing date</dt><dd></dd></div><div class=ledger__row><dt>Billing amount</dt><dd>/mo`);
28540
28884
  var _tmpl$667 = /* @__PURE__ */ template(`<p class=plan__note>Question about billing? <button type=button class=plan__note-link>Message support`);
@@ -28594,7 +28938,7 @@ function PlanBilling(props) {
28594
28938
  },
28595
28939
  get fallback() {
28596
28940
  return (() => {
28597
- var _el$3 = _tmpl$2136(), _el$4 = _el$3.firstChild, _el$5 = _el$4.nextSibling, _el$6 = _el$5.nextSibling;
28941
+ var _el$3 = _tmpl$2137(), _el$4 = _el$3.firstChild, _el$5 = _el$4.nextSibling, _el$6 = _el$5.nextSibling;
28598
28942
  effect(() => setAttribute(_el$6, "href", props.intakeHref));
28599
28943
  return _el$3;
28600
28944
  })();
@@ -28609,7 +28953,7 @@ function PlanBilling(props) {
28609
28953
  return sub().dosage;
28610
28954
  },
28611
28955
  get children() {
28612
- var _el$11 = _tmpl$3118();
28956
+ var _el$11 = _tmpl$3119();
28613
28957
  insert(_el$11, () => sub().dosage);
28614
28958
  return _el$11;
28615
28959
  }
@@ -28712,8 +29056,8 @@ function PlanBilling(props) {
28712
29056
  }
28713
29057
  delegateEvents(["click"]);
28714
29058
  var _tmpl$497 = /* @__PURE__ */ template(`<dd class=account__sms-edit><input class=account__sms-input type=tel inputmode=tel autocomplete=tel aria-label="Mobile number"><button type=button class="portal-btn portal-btn--primary">Save number</button><button type=button class="portal-btn portal-btn--ghost">Cancel`);
28715
- var _tmpl$2137 = /* @__PURE__ */ template(`<p class=account__sms-error role=alert>`);
28716
- var _tmpl$3119 = /* @__PURE__ */ template(`<div class=account__sms-on><span>Texts are on</span><button type=button class=plan__link-btn>Turn off texts`);
29059
+ var _tmpl$2138 = /* @__PURE__ */ template(`<p class=account__sms-error role=alert>`);
29060
+ var _tmpl$3120 = /* @__PURE__ */ template(`<div class=account__sms-on><span>Texts are on</span><button type=button class=plan__link-btn>Turn off texts`);
28717
29061
  var _tmpl$498 = /* @__PURE__ */ template(`<ul class=account__sms-events aria-label="Which texts you get">`);
28718
29062
  var _tmpl$574 = /* @__PURE__ */ template(`<section class=account__sms data-testid=sms-section aria-labelledby=sms-heading><span class=lab-label id=sms-heading>Text messages</span><dl class=account__fields><div class=account__field><dt class=lab-label>Mobile number`);
28719
29063
  var _tmpl$668 = /* @__PURE__ */ template(`<dd class=account__sms-number><span></span><button type=button class=account__note-link>`);
@@ -28782,7 +29126,7 @@ function SmsSection() {
28782
29126
  return sms.error();
28783
29127
  },
28784
29128
  get children() {
28785
- var _el$0 = _tmpl$2137();
29129
+ var _el$0 = _tmpl$2138();
28786
29130
  insert(_el$0, () => sms.error());
28787
29131
  return _el$0;
28788
29132
  }
@@ -28875,7 +29219,7 @@ function SmsSection() {
28875
29219
  },
28876
29220
  get children() {
28877
29221
  return [(() => {
28878
- var _el$1 = _tmpl$3119(), _el$10 = _el$1.firstChild, _el$11 = _el$10.nextSibling;
29222
+ var _el$1 = _tmpl$3120(), _el$10 = _el$1.firstChild, _el$11 = _el$10.nextSibling;
28879
29223
  _el$11.$$click = () => sms.optOut();
28880
29224
  effect(() => _el$11.disabled = sms.busy());
28881
29225
  return _el$1;
@@ -28913,8 +29257,8 @@ delegateEvents(["input", "click"]);
28913
29257
 
28914
29258
  // src/pages/member/AccountPanel.tsx
28915
29259
  var _tmpl$499 = /* @__PURE__ */ template(`<p class=account__empty>We don\u2019t have your details on file yet.`);
28916
- var _tmpl$2138 = /* @__PURE__ */ template(`<p class=account__note>Need to update something? <button type=button class=account__note-link>Message support</button> and we\u2019ll take care of it.`);
28917
- var _tmpl$3120 = /* @__PURE__ */ template(`<button type=button class="account__support-link account__support-btn">Messages`);
29260
+ var _tmpl$2139 = /* @__PURE__ */ template(`<p class=account__note>Need to update something? <button type=button class=account__note-link>Message support</button> and we\u2019ll take care of it.`);
29261
+ var _tmpl$3121 = /* @__PURE__ */ template(`<button type=button class="account__support-link account__support-btn">Messages`);
28918
29262
  var _tmpl$4100 = /* @__PURE__ */ template(`<div class=account data-testid=account-panel><span class=lab-label>Account</span><h1 class=account__title>Your details</h1><dl class=account__fields></dl><div class=account__support></div><button type=button class="portal-btn portal-btn--ghost account__signout">Sign out`);
28919
29263
  var _tmpl$575 = /* @__PURE__ */ template(`<div class=account__field><dt class=lab-label></dt><dd>`);
28920
29264
  var _tmpl$669 = /* @__PURE__ */ template(`<a class=account__support-link>`);
@@ -28984,7 +29328,7 @@ function AccountPanel(props) {
28984
29328
  return props.messagingEnabled;
28985
29329
  },
28986
29330
  get children() {
28987
- var _el$6 = _tmpl$2138(), _el$7 = _el$6.firstChild, _el$9 = _el$7.nextSibling;
29331
+ var _el$6 = _tmpl$2139(), _el$7 = _el$6.firstChild, _el$9 = _el$7.nextSibling;
28988
29332
  _el$9.$$click = () => props.onOpenMessages({
28989
29333
  channel: "support",
28990
29334
  category: "account"
@@ -28997,7 +29341,7 @@ function AccountPanel(props) {
28997
29341
  return props.messagingEnabled;
28998
29342
  },
28999
29343
  get children() {
29000
- var _el$1 = _tmpl$3120();
29344
+ var _el$1 = _tmpl$3121();
29001
29345
  _el$1.$$click = () => props.onOpenMessages();
29002
29346
  return _el$1;
29003
29347
  }
@@ -29019,8 +29363,8 @@ function AccountPanel(props) {
29019
29363
  }
29020
29364
  delegateEvents(["click"]);
29021
29365
  var _tmpl$500 = /* @__PURE__ */ template(`<section class="leaflet__section leaflet__section--caution"><h2 class=leaflet__h2>Birth control</h2><p class=leaflet__body>`);
29022
- var _tmpl$2139 = /* @__PURE__ */ template(`<ul class=leaflet__disclaimers id=leaflet-disclaimers>`);
29023
- var _tmpl$3121 = /* @__PURE__ */ template(`<div class=leaflet data-testid=medication-guide><header class=leaflet__header><span class=lab-label>How to take it</span><h1 class=leaflet__title></h1><p class=leaflet__summary></p></header><section class=leaflet__boxed aria-label="Boxed warning"><div class=leaflet__boxed-head><i class="ph-fill ph-warning"aria-hidden=true></i><span>Important warning</span></div><p></p></section><section class="leaflet__section leaflet__section--caution"><h2 class=leaflet__h2>Do not use this medicine if\u2026</h2><ul class="leaflet__list leaflet__list--caution"></ul></section><section class=leaflet__section><h2 class=leaflet__h2>Your dose over time</h2><p class=leaflet__note>A typical step-up. Your prescriber sets your exact doses and timing.</p><ol class=titration></ol></section><section class=leaflet__section><h2 class=leaflet__h2>Giving your injection</h2><ol class=steps></ol></section><div class=leaflet__grid><section class=leaflet__section><h2 class=leaflet__h2>Storing your medicine</h2><ul class=leaflet__list></ul></section><section class=leaflet__section><h2 class=leaflet__h2>If you miss a dose</h2><p class=leaflet__body></p></section></div><div class=leaflet__grid><section class=leaflet__section><h2 class=leaflet__h2>Common side effects</h2><ul class="leaflet__list leaflet__list--check"></ul></section><section class="leaflet__section leaflet__section--alert"><h2 class=leaflet__h2>Call right away if you notice\u2026</h2><ul class="leaflet__list leaflet__list--alert"></ul></section></div><section class=leaflet__section><h2 class=leaflet__h2>When to contact your care team</h2><ul class=leaflet__list></ul></section><section class=leaflet__section><h2 class=leaflet__h2>Tips for feeling your best</h2><ul class="leaflet__list leaflet__list--check"></ul></section><section class=leaflet__footnote><button type=button class=leaflet__disclose aria-controls=leaflet-disclaimers> the important details<i aria-hidden=true>`);
29366
+ var _tmpl$2140 = /* @__PURE__ */ template(`<ul class=leaflet__disclaimers id=leaflet-disclaimers>`);
29367
+ var _tmpl$3122 = /* @__PURE__ */ template(`<div class=leaflet data-testid=medication-guide><header class=leaflet__header><span class=lab-label>How to take it</span><h1 class=leaflet__title></h1><p class=leaflet__summary></p></header><section class=leaflet__boxed aria-label="Boxed warning"><div class=leaflet__boxed-head><i class="ph-fill ph-warning"aria-hidden=true></i><span>Important warning</span></div><p></p></section><section class="leaflet__section leaflet__section--caution"><h2 class=leaflet__h2>Do not use this medicine if\u2026</h2><ul class="leaflet__list leaflet__list--caution"></ul></section><section class=leaflet__section><h2 class=leaflet__h2>Your dose over time</h2><p class=leaflet__note>A typical step-up. Your prescriber sets your exact doses and timing.</p><ol class=titration></ol></section><section class=leaflet__section><h2 class=leaflet__h2>Giving your injection</h2><ol class=steps></ol></section><div class=leaflet__grid><section class=leaflet__section><h2 class=leaflet__h2>Storing your medicine</h2><ul class=leaflet__list></ul></section><section class=leaflet__section><h2 class=leaflet__h2>If you miss a dose</h2><p class=leaflet__body></p></section></div><div class=leaflet__grid><section class=leaflet__section><h2 class=leaflet__h2>Common side effects</h2><ul class="leaflet__list leaflet__list--check"></ul></section><section class="leaflet__section leaflet__section--alert"><h2 class=leaflet__h2>Call right away if you notice\u2026</h2><ul class="leaflet__list leaflet__list--alert"></ul></section></div><section class=leaflet__section><h2 class=leaflet__h2>When to contact your care team</h2><ul class=leaflet__list></ul></section><section class=leaflet__section><h2 class=leaflet__h2>Tips for feeling your best</h2><ul class="leaflet__list leaflet__list--check"></ul></section><section class=leaflet__footnote><button type=button class=leaflet__disclose aria-controls=leaflet-disclaimers> the important details<i aria-hidden=true>`);
29024
29368
  var _tmpl$4101 = /* @__PURE__ */ template(`<li>`);
29025
29369
  var _tmpl$576 = /* @__PURE__ */ template(`<li><span class=titration__bead aria-hidden=true></span><div class=titration__body><div class=titration__row><span class=titration__dose></span><span class="lab-label titration__phase"></span></div><span class=titration__time></span><p class=titration__note>`);
29026
29370
  var _tmpl$670 = /* @__PURE__ */ template(`<li class=steps__item><span class=steps__num></span><div class=steps__body><h3 class=steps__title></h3><p class=steps__detail>`);
@@ -29044,7 +29388,7 @@ function MedicationGuide(props) {
29044
29388
  return "upcoming";
29045
29389
  };
29046
29390
  return (() => {
29047
- var _el$ = _tmpl$3121(), _el$2 = _el$.firstChild, _el$3 = _el$2.firstChild, _el$4 = _el$3.nextSibling, _el$5 = _el$4.nextSibling, _el$6 = _el$2.nextSibling, _el$7 = _el$6.firstChild, _el$8 = _el$7.nextSibling, _el$9 = _el$6.nextSibling, _el$0 = _el$9.firstChild, _el$1 = _el$0.nextSibling, _el$10 = _el$9.nextSibling, _el$11 = _el$10.firstChild, _el$12 = _el$11.nextSibling, _el$13 = _el$12.nextSibling, _el$14 = _el$10.nextSibling, _el$15 = _el$14.firstChild, _el$16 = _el$15.nextSibling, _el$17 = _el$14.nextSibling, _el$18 = _el$17.firstChild, _el$19 = _el$18.firstChild, _el$20 = _el$19.nextSibling, _el$21 = _el$18.nextSibling, _el$22 = _el$21.firstChild, _el$23 = _el$22.nextSibling, _el$27 = _el$17.nextSibling, _el$28 = _el$27.firstChild, _el$29 = _el$28.firstChild, _el$30 = _el$29.nextSibling, _el$31 = _el$28.nextSibling, _el$32 = _el$31.firstChild, _el$33 = _el$32.nextSibling, _el$34 = _el$27.nextSibling, _el$35 = _el$34.firstChild, _el$36 = _el$35.nextSibling, _el$37 = _el$34.nextSibling, _el$38 = _el$37.firstChild, _el$39 = _el$38.nextSibling, _el$40 = _el$37.nextSibling, _el$41 = _el$40.firstChild, _el$42 = _el$41.firstChild, _el$43 = _el$42.nextSibling;
29391
+ var _el$ = _tmpl$3122(), _el$2 = _el$.firstChild, _el$3 = _el$2.firstChild, _el$4 = _el$3.nextSibling, _el$5 = _el$4.nextSibling, _el$6 = _el$2.nextSibling, _el$7 = _el$6.firstChild, _el$8 = _el$7.nextSibling, _el$9 = _el$6.nextSibling, _el$0 = _el$9.firstChild, _el$1 = _el$0.nextSibling, _el$10 = _el$9.nextSibling, _el$11 = _el$10.firstChild, _el$12 = _el$11.nextSibling, _el$13 = _el$12.nextSibling, _el$14 = _el$10.nextSibling, _el$15 = _el$14.firstChild, _el$16 = _el$15.nextSibling, _el$17 = _el$14.nextSibling, _el$18 = _el$17.firstChild, _el$19 = _el$18.firstChild, _el$20 = _el$19.nextSibling, _el$21 = _el$18.nextSibling, _el$22 = _el$21.firstChild, _el$23 = _el$22.nextSibling, _el$27 = _el$17.nextSibling, _el$28 = _el$27.firstChild, _el$29 = _el$28.firstChild, _el$30 = _el$29.nextSibling, _el$31 = _el$28.nextSibling, _el$32 = _el$31.firstChild, _el$33 = _el$32.nextSibling, _el$34 = _el$27.nextSibling, _el$35 = _el$34.firstChild, _el$36 = _el$35.nextSibling, _el$37 = _el$34.nextSibling, _el$38 = _el$37.firstChild, _el$39 = _el$38.nextSibling, _el$40 = _el$37.nextSibling, _el$41 = _el$40.firstChild, _el$42 = _el$41.firstChild, _el$43 = _el$42.nextSibling;
29048
29392
  insert(_el$4, () => props.guide.title);
29049
29393
  insert(_el$5, () => props.guide.summary);
29050
29394
  insert(_el$8, () => props.guide.boxedWarning);
@@ -29152,7 +29496,7 @@ function MedicationGuide(props) {
29152
29496
  return showDisclaimers();
29153
29497
  },
29154
29498
  get children() {
29155
- var _el$44 = _tmpl$2139();
29499
+ var _el$44 = _tmpl$2140();
29156
29500
  insert(_el$44, createComponent(For, {
29157
29501
  get each() {
29158
29502
  return props.guide.disclaimers;
@@ -29180,8 +29524,8 @@ function MedicationGuide(props) {
29180
29524
  }
29181
29525
  delegateEvents(["click"]);
29182
29526
  var _tmpl$501 = /* @__PURE__ */ template(`<span data-testid=channel-chip>`);
29183
- var _tmpl$2140 = /* @__PURE__ */ template(`<span class=channel-chip__category>`);
29184
- var _tmpl$3122 = /* @__PURE__ */ template(`<div class=msg-list__header><div class=msg-list__header-title><button type=button class=msg-list__back aria-label="Choose a different team"data-testid=messages-choose-different><i class="ph-thin ph-arrow-left"aria-hidden=true></i></button><h2 class=msg-list__title></h2></div><button type=button class=msg-list__new data-testid=messages-new-support><i class="ph-thin ph-plus"aria-hidden=true></i>New message`);
29527
+ var _tmpl$2141 = /* @__PURE__ */ template(`<span class=channel-chip__category>`);
29528
+ var _tmpl$3123 = /* @__PURE__ */ template(`<div class=msg-list__header><div class=msg-list__header-title><button type=button class=msg-list__back aria-label="Choose a different team"data-testid=messages-choose-different><i class="ph-thin ph-arrow-left"aria-hidden=true></i></button><h2 class=msg-list__title></h2></div><button type=button class=msg-list__new data-testid=messages-new-support><i class="ph-thin ph-plus"aria-hidden=true></i>New message`);
29185
29529
  var _tmpl$4102 = /* @__PURE__ */ template(`<div class=msg-list__state><div class=request-status__spinner>`);
29186
29530
  var _tmpl$577 = /* @__PURE__ */ template(`<div class="msg-list__state msg-list__state--empty"data-testid=messages-empty><i class="ph-thin ph-chat-circle msg-list__empty-icon"aria-hidden=true></i><p class=msg-list__empty-title>No conversations yet.</p><p class=msg-list__empty-hint>`);
29187
29531
  var _tmpl$671 = /* @__PURE__ */ template(`<div class=msg-list__scroll data-scrollable>`);
@@ -29198,23 +29542,23 @@ var _tmpl$1423 = /* @__PURE__ */ template(`<p class=msg-thread__system data-test
29198
29542
  var _tmpl$1522 = /* @__PURE__ */ template(`<p class=msg-thread__text>`);
29199
29543
  var _tmpl$1622 = /* @__PURE__ */ template(`<button type=button class="msg-compose__staged-remove msg-compose__staged-remove--inline">Remove file`);
29200
29544
  var _tmpl$1722 = /* @__PURE__ */ template(`<p class=msg-compose__error role=alert>`);
29201
- var _tmpl$1820 = /* @__PURE__ */ template(`<form class="msg-thread msg-thread--compose"data-testid=support-compose><div class=msg-thread__header><button type=button class=msg-thread__back-btn aria-label=Back data-testid=support-compose-back><i class="ph-thin ph-arrow-left"aria-hidden=true></i></button><div><h3 class=msg-thread__name>Message support</h3><p class=msg-thread__role data-testid=support-compose-reply-note></p></div></div><div class=msg-compose__new><label class=msg-compose__label id=support-category-label>What's this about? <span class=msg-compose__label-optional>(optional)</span></label><div class=msg-compose__categories role=group aria-labelledby=support-category-label></div><label class=msg-compose__label for=support-subject>Subject</label><input id=support-subject class=msg-compose__subject type=text maxlength=500 required placeholder="e.g. Question about my order"><label class=msg-compose__label for=support-body>How can we help?</label><textarea id=support-body class=msg-compose__body rows=6 maxlength=5000 required placeholder="Tell us what's going on\u2026"></textarea><label class="msg-compose__attach msg-compose__attach--block"title="Attach a file"><i class="ph-thin ph-paperclip"aria-hidden=true></i><span class=msg-compose__attach-label></span><input class=msg-compose__file-input type=file data-testid=support-compose-attach></label><button type=submit class=msg-compose__send data-testid=support-compose-send>`);
29202
- var _tmpl$1919 = /* @__PURE__ */ template(`<button type=button>`);
29203
- var _tmpl$2018 = /* @__PURE__ */ template(`<form class="msg-thread msg-thread--compose"data-testid=care-compose><div class=msg-thread__header><button type=button class=msg-thread__back-btn aria-label=Back data-testid=care-compose-back><i class="ph-thin ph-arrow-left"aria-hidden=true></i></button><div><h3 class=msg-thread__name>Message your care team</h3><p class=msg-thread__role>Your prescriber or their team will reply</p></div></div><div class=msg-compose__new><label class=msg-compose__label for=care-body>Message</label><textarea id=care-body class=msg-compose__body rows=6 maxlength=5000 required placeholder="Tell your care team what's going on\u2026"></textarea><label class="msg-compose__attach msg-compose__attach--block"title="Attach a file"><i class="ph-thin ph-paperclip"aria-hidden=true></i><span class=msg-compose__attach-label></span><input class=msg-compose__file-input type=file data-testid=care-compose-attach></label><button type=submit class=msg-compose__send data-testid=care-compose-send>`);
29204
- var _tmpl$2141 = /* @__PURE__ */ template(`<span class=msg-choice__option-badge data-testid=gate-care-badge>`);
29205
- var _tmpl$2217 = /* @__PURE__ */ template(`<span class=msg-choice__option-badge data-testid=gate-support-badge>`);
29206
- var _tmpl$2315 = /* @__PURE__ */ template(`<p class=msg-choice__notice-text data-testid=messages-gate-note>That conversation isn't available.`);
29207
- var _tmpl$2415 = /* @__PURE__ */ template(`<div class="msg-thread msg-choice"data-testid=messages-gate><div class=msg-thread__header><div><h3 class=msg-thread__name>Messages</h3><p class=msg-thread__role>Who do you want to talk to?</p></div></div><div class=msg-choice__options><button type=button class=msg-choice__option data-testid=gate-care-team><i class="ph-thin ph-heartbeat msg-choice__option-icon"aria-hidden=true></i><span class=msg-choice__option-title>My care team</span><span class=msg-choice__option-sub>Treatment, medication or side effects</span></button><button type=button class=msg-choice__option data-testid=gate-support><i class="ph-thin ph-lifebuoy msg-choice__option-icon"aria-hidden=true></i><span class=msg-choice__option-title>Support</span><span class=msg-choice__option-sub>Account, orders, billing or the website`);
29208
- var _tmpl$2515 = /* @__PURE__ */ template(`<span class="msg-choice__option-spinner request-status__spinner"data-testid=gate-care-loading>`);
29209
- var _tmpl$2615 = /* @__PURE__ */ template(`<span class="msg-choice__option-spinner request-status__spinner"data-testid=gate-support-loading>`);
29210
- var _tmpl$2715 = /* @__PURE__ */ template(`<div class="msg-thread msg-choice"data-testid=care-team-notice><div class=msg-thread__header><button type=button class=msg-thread__back-btn aria-label=Back><i class="ph-thin ph-arrow-left"aria-hidden=true></i></button><div><h3 class=msg-thread__name>Care team</h3><p class=msg-thread__role>Goes to your care team</p></div></div><div class=msg-choice__notice><p class=msg-choice__notice-text>Your care team will reach out after reviewing your case. If you have a question about your account or order in the meantime, send it to support.</p><button type=button class="portal-btn portal-btn--primary"data-testid=care-team-notice-switch>Message support instead`);
29211
- var _tmpl$2813 = /* @__PURE__ */ template(`<div class="msg-thread msg-choice"data-testid=support-email-sent><div class=msg-thread__header><button type=button class=msg-thread__back-btn aria-label=Back><i class="ph-thin ph-arrow-left"aria-hidden=true></i></button><div><h3 class=msg-thread__name>Message sent</h3><p class=msg-thread__role>Support</p></div></div><div class=msg-choice__notice><p class=msg-choice__notice-text>Thanks, your message is on its way to our support team. We'll reply by email, usually within one business day.</p><button type=button class="portal-btn portal-btn--primary"data-testid=support-email-another>Send another message`);
29212
- var _tmpl$2912 = /* @__PURE__ */ template(`<span class=msg-thread__status data-testid=thread-status-closed>Resolved`);
29213
- var _tmpl$3011 = /* @__PURE__ */ template(`<span class=msg-thread__status data-testid=thread-status-transferred>Moved to care team`);
29214
- var _tmpl$3123 = /* @__PURE__ */ template(`<div class=msg-thread__header><button type=button class=msg-thread__back-btn aria-label="Back to conversations"data-testid=messages-back><i class="ph-thin ph-arrow-left"aria-hidden=true></i></button><div><div class=msg-thread__title-row><h3 class=msg-thread__name></h3></div><p class=msg-thread__role>`);
29215
- var _tmpl$3215 = /* @__PURE__ */ template(`<div class=msg-thread__banner><button type=button class=msg-thread__banner-link data-testid=continue-with-care-team>Continue with your care team`);
29216
- var _tmpl$3315 = /* @__PURE__ */ template(`<div class=msg-thread__messages data-scrollable><div>`);
29217
- var _tmpl$3415 = /* @__PURE__ */ template(`<span class=msg-compose__error role=alert>`);
29545
+ var _tmpl$1821 = /* @__PURE__ */ template(`<form class="msg-thread msg-thread--compose"data-testid=support-compose><div class=msg-thread__header><button type=button class=msg-thread__back-btn aria-label=Back data-testid=support-compose-back><i class="ph-thin ph-arrow-left"aria-hidden=true></i></button><div><h3 class=msg-thread__name>Message support</h3><p class=msg-thread__role data-testid=support-compose-reply-note></p></div></div><div class=msg-compose__new><label class=msg-compose__label id=support-category-label>What's this about? <span class=msg-compose__label-optional>(optional)</span></label><div class=msg-compose__categories role=group aria-labelledby=support-category-label></div><label class=msg-compose__label for=support-subject>Subject</label><input id=support-subject class=msg-compose__subject type=text maxlength=500 required placeholder="e.g. Question about my order"><label class=msg-compose__label for=support-body>How can we help?</label><textarea id=support-body class=msg-compose__body rows=6 maxlength=5000 required placeholder="Tell us what's going on\u2026"></textarea><label class="msg-compose__attach msg-compose__attach--block"title="Attach a file"><i class="ph-thin ph-paperclip"aria-hidden=true></i><span class=msg-compose__attach-label></span><input class=msg-compose__file-input type=file data-testid=support-compose-attach></label><button type=submit class=msg-compose__send data-testid=support-compose-send>`);
29546
+ var _tmpl$1920 = /* @__PURE__ */ template(`<button type=button>`);
29547
+ var _tmpl$2019 = /* @__PURE__ */ template(`<form class="msg-thread msg-thread--compose"data-testid=care-compose><div class=msg-thread__header><button type=button class=msg-thread__back-btn aria-label=Back data-testid=care-compose-back><i class="ph-thin ph-arrow-left"aria-hidden=true></i></button><div><h3 class=msg-thread__name>Message your care team</h3><p class=msg-thread__role>Your prescriber or their team will reply</p></div></div><div class=msg-compose__new><label class=msg-compose__label for=care-body>Message</label><textarea id=care-body class=msg-compose__body rows=6 maxlength=5000 required placeholder="Tell your care team what's going on\u2026"></textarea><label class="msg-compose__attach msg-compose__attach--block"title="Attach a file"><i class="ph-thin ph-paperclip"aria-hidden=true></i><span class=msg-compose__attach-label></span><input class=msg-compose__file-input type=file data-testid=care-compose-attach></label><button type=submit class=msg-compose__send data-testid=care-compose-send>`);
29548
+ var _tmpl$2142 = /* @__PURE__ */ template(`<span class=msg-choice__option-badge data-testid=gate-care-badge>`);
29549
+ var _tmpl$2218 = /* @__PURE__ */ template(`<span class=msg-choice__option-badge data-testid=gate-support-badge>`);
29550
+ var _tmpl$2316 = /* @__PURE__ */ template(`<p class=msg-choice__notice-text data-testid=messages-gate-note>That conversation isn't available.`);
29551
+ var _tmpl$2416 = /* @__PURE__ */ template(`<div class="msg-thread msg-choice"data-testid=messages-gate><div class=msg-thread__header><div><h3 class=msg-thread__name>Messages</h3><p class=msg-thread__role>Who do you want to talk to?</p></div></div><div class=msg-choice__options><button type=button class=msg-choice__option data-testid=gate-care-team><i class="ph-thin ph-heartbeat msg-choice__option-icon"aria-hidden=true></i><span class=msg-choice__option-title>My care team</span><span class=msg-choice__option-sub>Treatment, medication or side effects</span></button><button type=button class=msg-choice__option data-testid=gate-support><i class="ph-thin ph-lifebuoy msg-choice__option-icon"aria-hidden=true></i><span class=msg-choice__option-title>Support</span><span class=msg-choice__option-sub>Account, orders, billing or the website`);
29552
+ var _tmpl$2516 = /* @__PURE__ */ template(`<span class="msg-choice__option-spinner request-status__spinner"data-testid=gate-care-loading>`);
29553
+ var _tmpl$2616 = /* @__PURE__ */ template(`<span class="msg-choice__option-spinner request-status__spinner"data-testid=gate-support-loading>`);
29554
+ var _tmpl$2716 = /* @__PURE__ */ template(`<div class="msg-thread msg-choice"data-testid=care-team-notice><div class=msg-thread__header><button type=button class=msg-thread__back-btn aria-label=Back><i class="ph-thin ph-arrow-left"aria-hidden=true></i></button><div><h3 class=msg-thread__name>Care team</h3><p class=msg-thread__role>Goes to your care team</p></div></div><div class=msg-choice__notice><p class=msg-choice__notice-text>Your care team will reach out after reviewing your case. If you have a question about your account or order in the meantime, send it to support.</p><button type=button class="portal-btn portal-btn--primary"data-testid=care-team-notice-switch>Message support instead`);
29555
+ var _tmpl$2814 = /* @__PURE__ */ template(`<div class="msg-thread msg-choice"data-testid=support-email-sent><div class=msg-thread__header><button type=button class=msg-thread__back-btn aria-label=Back><i class="ph-thin ph-arrow-left"aria-hidden=true></i></button><div><h3 class=msg-thread__name>Message sent</h3><p class=msg-thread__role>Support</p></div></div><div class=msg-choice__notice><p class=msg-choice__notice-text>Thanks, your message is on its way to our support team. We'll reply by email, usually within one business day.</p><button type=button class="portal-btn portal-btn--primary"data-testid=support-email-another>Send another message`);
29556
+ var _tmpl$2913 = /* @__PURE__ */ template(`<span class=msg-thread__status data-testid=thread-status-closed>Resolved`);
29557
+ var _tmpl$3012 = /* @__PURE__ */ template(`<span class=msg-thread__status data-testid=thread-status-transferred>Moved to care team`);
29558
+ var _tmpl$3124 = /* @__PURE__ */ template(`<div class=msg-thread__header><button type=button class=msg-thread__back-btn aria-label="Back to conversations"data-testid=messages-back><i class="ph-thin ph-arrow-left"aria-hidden=true></i></button><div><div class=msg-thread__title-row><h3 class=msg-thread__name></h3></div><p class=msg-thread__role>`);
29559
+ var _tmpl$3216 = /* @__PURE__ */ template(`<div class=msg-thread__banner><button type=button class=msg-thread__banner-link data-testid=continue-with-care-team>Continue with your care team`);
29560
+ var _tmpl$3316 = /* @__PURE__ */ template(`<div class=msg-thread__messages data-scrollable><div>`);
29561
+ var _tmpl$3416 = /* @__PURE__ */ template(`<span class=msg-compose__error role=alert>`);
29218
29562
  var _tmpl$3513 = /* @__PURE__ */ template(`<div class=msg-compose__staged>`);
29219
29563
  var _tmpl$3611 = /* @__PURE__ */ template(`<label class=msg-compose__attach title="Attach a file"><i class="ph-thin ph-paperclip"aria-hidden=true></i><span class=msg-compose__attach-label>Attach a file</span><input class=msg-compose__file-input type=file data-testid=messages-attach>`);
29220
29564
  var _tmpl$3711 = /* @__PURE__ */ template(`<div class=msg-compose><textarea class=msg-compose__input rows=1 placeholder="Type a message\u2026"aria-label=Message></textarea><button type=button class=msg-compose__send data-testid=messages-send>`);
@@ -29431,7 +29775,7 @@ function MessagesPanel(props) {
29431
29775
  return memo(() => p.source === "support")() && categoryLabel(p.category);
29432
29776
  },
29433
29777
  children: (label3) => (() => {
29434
- var _el$2 = _tmpl$2140();
29778
+ var _el$2 = _tmpl$2141();
29435
29779
  insert(_el$2, label3);
29436
29780
  return _el$2;
29437
29781
  })()
@@ -29449,7 +29793,7 @@ function MessagesPanel(props) {
29449
29793
  })();
29450
29794
  const channelConversations = () => thread().conversations().filter((c) => c.source === (channel() === "care" ? "clinical" : "support"));
29451
29795
  const ConversationList = () => [(() => {
29452
- var _el$3 = _tmpl$3122(), _el$4 = _el$3.firstChild, _el$5 = _el$4.firstChild, _el$6 = _el$5.nextSibling, _el$7 = _el$4.nextSibling;
29796
+ var _el$3 = _tmpl$3123(), _el$4 = _el$3.firstChild, _el$5 = _el$4.firstChild, _el$6 = _el$5.nextSibling, _el$7 = _el$4.nextSibling;
29453
29797
  _el$5.$$click = goToGate;
29454
29798
  insert(_el$6, () => channel() === "care" ? "My care team" : "Support");
29455
29799
  _el$7.$$click = openCompose;
@@ -29673,14 +30017,14 @@ function MessagesPanel(props) {
29673
30017
  });
29674
30018
  };
29675
30019
  const NewSupportThread = () => (() => {
29676
- var _el$36 = _tmpl$1820(), _el$37 = _el$36.firstChild, _el$38 = _el$37.firstChild, _el$39 = _el$38.nextSibling, _el$40 = _el$39.firstChild, _el$41 = _el$40.nextSibling, _el$42 = _el$37.nextSibling, _el$43 = _el$42.firstChild, _el$44 = _el$43.nextSibling, _el$45 = _el$44.nextSibling, _el$46 = _el$45.nextSibling, _el$47 = _el$46.nextSibling, _el$48 = _el$47.nextSibling, _el$49 = _el$48.nextSibling, _el$50 = _el$49.firstChild, _el$51 = _el$50.nextSibling, _el$52 = _el$51.nextSibling, _el$55 = _el$49.nextSibling;
30020
+ var _el$36 = _tmpl$1821(), _el$37 = _el$36.firstChild, _el$38 = _el$37.firstChild, _el$39 = _el$38.nextSibling, _el$40 = _el$39.firstChild, _el$41 = _el$40.nextSibling, _el$42 = _el$37.nextSibling, _el$43 = _el$42.firstChild, _el$44 = _el$43.nextSibling, _el$45 = _el$44.nextSibling, _el$46 = _el$45.nextSibling, _el$47 = _el$46.nextSibling, _el$48 = _el$47.nextSibling, _el$49 = _el$48.nextSibling, _el$50 = _el$49.firstChild, _el$51 = _el$50.nextSibling, _el$52 = _el$51.nextSibling, _el$55 = _el$49.nextSibling;
29677
30021
  _el$36.addEventListener("submit", submitCompose);
29678
30022
  _el$38.$$click = () => emailSupport() ? goToGate() : setComposing(false);
29679
30023
  insert(_el$41, () => emailSupport() ? "We'll reply by email, usually within one business day" : "We usually reply within one business day");
29680
30024
  insert(_el$44, createComponent(For, {
29681
30025
  each: SUPPORT_CATEGORIES,
29682
30026
  children: (c) => (() => {
29683
- var _el$56 = _tmpl$1919();
30027
+ var _el$56 = _tmpl$1920();
29684
30028
  _el$56.$$click = () => setNewCategory((prev) => prev === c.key ? null : c.key);
29685
30029
  insert(_el$56, () => c.label);
29686
30030
  effect((_p$) => {
@@ -29736,7 +30080,7 @@ function MessagesPanel(props) {
29736
30080
  return _el$36;
29737
30081
  })();
29738
30082
  const NewCareTeamThread = () => (() => {
29739
- var _el$57 = _tmpl$2018(), _el$58 = _el$57.firstChild, _el$59 = _el$58.firstChild, _el$60 = _el$58.nextSibling, _el$61 = _el$60.firstChild, _el$62 = _el$61.nextSibling, _el$63 = _el$62.nextSibling, _el$64 = _el$63.firstChild, _el$65 = _el$64.nextSibling, _el$66 = _el$65.nextSibling, _el$69 = _el$63.nextSibling;
30083
+ var _el$57 = _tmpl$2019(), _el$58 = _el$57.firstChild, _el$59 = _el$58.firstChild, _el$60 = _el$58.nextSibling, _el$61 = _el$60.firstChild, _el$62 = _el$61.nextSibling, _el$63 = _el$62.nextSibling, _el$64 = _el$63.firstChild, _el$65 = _el$64.nextSibling, _el$66 = _el$65.nextSibling, _el$69 = _el$63.nextSibling;
29740
30084
  _el$57.addEventListener("submit", submitCareCompose);
29741
30085
  _el$59.$$click = () => setComposing(false);
29742
30086
  _el$62.$$input = (e) => setNewBody(e.currentTarget.value);
@@ -29778,14 +30122,14 @@ function MessagesPanel(props) {
29778
30122
  const careUnreadCount = () => thread().conversations().filter((c) => c.source === "clinical").reduce((sum, c) => sum + (c.unreadCount ?? 0), 0);
29779
30123
  const supportUnreadCount = () => thread().conversations().filter((c) => c.source === "support" && (c.unreadCount ?? 0) > 0).length;
29780
30124
  const ChannelGate = () => (() => {
29781
- var _el$70 = _tmpl$2415(), _el$71 = _el$70.firstChild, _el$72 = _el$71.nextSibling, _el$73 = _el$72.firstChild, _el$74 = _el$73.firstChild, _el$75 = _el$74.nextSibling; _el$75.nextSibling; var _el$78 = _el$73.nextSibling, _el$79 = _el$78.firstChild, _el$80 = _el$79.nextSibling; _el$80.nextSibling;
30125
+ var _el$70 = _tmpl$2416(), _el$71 = _el$70.firstChild, _el$72 = _el$71.nextSibling, _el$73 = _el$72.firstChild, _el$74 = _el$73.firstChild, _el$75 = _el$74.nextSibling; _el$75.nextSibling; var _el$78 = _el$73.nextSibling, _el$79 = _el$78.firstChild, _el$80 = _el$79.nextSibling; _el$80.nextSibling;
29782
30126
  _el$73.$$click = () => switchChannel("care");
29783
30127
  insert(_el$73, createComponent(Show, {
29784
30128
  get when() {
29785
30129
  return !thread().loadingConversations();
29786
30130
  },
29787
30131
  get fallback() {
29788
- return _tmpl$2515();
30132
+ return _tmpl$2516();
29789
30133
  },
29790
30134
  get children() {
29791
30135
  return createComponent(Show, {
@@ -29793,7 +30137,7 @@ function MessagesPanel(props) {
29793
30137
  return careUnreadCount() > 0;
29794
30138
  },
29795
30139
  get children() {
29796
- var _el$77 = _tmpl$2141();
30140
+ var _el$77 = _tmpl$2142();
29797
30141
  insert(_el$77, careUnreadCount);
29798
30142
  return _el$77;
29799
30143
  }
@@ -29806,7 +30150,7 @@ function MessagesPanel(props) {
29806
30150
  return !thread().loadingConversations();
29807
30151
  },
29808
30152
  get fallback() {
29809
- return _tmpl$2615();
30153
+ return _tmpl$2616();
29810
30154
  },
29811
30155
  get children() {
29812
30156
  return createComponent(Show, {
@@ -29814,7 +30158,7 @@ function MessagesPanel(props) {
29814
30158
  return memo(() => supportUnreadCount() > 0)() && !emailSupport();
29815
30159
  },
29816
30160
  get children() {
29817
- var _el$82 = _tmpl$2217();
30161
+ var _el$82 = _tmpl$2218();
29818
30162
  insert(_el$82, supportUnreadCount);
29819
30163
  return _el$82;
29820
30164
  }
@@ -29826,13 +30170,13 @@ function MessagesPanel(props) {
29826
30170
  return threadNotFound();
29827
30171
  },
29828
30172
  get children() {
29829
- return _tmpl$2315();
30173
+ return _tmpl$2316();
29830
30174
  }
29831
30175
  }), null);
29832
30176
  return _el$70;
29833
30177
  })();
29834
30178
  const CareTeamNotice = () => (() => {
29835
- var _el$86 = _tmpl$2715(), _el$87 = _el$86.firstChild, _el$88 = _el$87.firstChild, _el$89 = _el$87.nextSibling, _el$90 = _el$89.firstChild, _el$91 = _el$90.nextSibling;
30179
+ var _el$86 = _tmpl$2716(), _el$87 = _el$86.firstChild, _el$88 = _el$87.firstChild, _el$89 = _el$87.nextSibling, _el$90 = _el$89.firstChild, _el$91 = _el$90.nextSibling;
29836
30180
  _el$88.$$click = () => setComposing(false);
29837
30181
  _el$91.$$click = () => {
29838
30182
  switchChannel("support");
@@ -29841,13 +30185,13 @@ function MessagesPanel(props) {
29841
30185
  return _el$86;
29842
30186
  })();
29843
30187
  const SupportEmailSent = () => (() => {
29844
- var _el$92 = _tmpl$2813(), _el$93 = _el$92.firstChild, _el$94 = _el$93.firstChild, _el$95 = _el$93.nextSibling, _el$96 = _el$95.firstChild, _el$97 = _el$96.nextSibling;
30188
+ var _el$92 = _tmpl$2814(), _el$93 = _el$92.firstChild, _el$94 = _el$93.firstChild, _el$95 = _el$93.nextSibling, _el$96 = _el$95.firstChild, _el$97 = _el$96.nextSibling;
29845
30189
  _el$94.$$click = goToGate;
29846
30190
  _el$97.$$click = () => setEmailSent(false);
29847
30191
  return _el$92;
29848
30192
  })();
29849
30193
  const Thread = () => [(() => {
29850
- var _el$98 = _tmpl$3123(), _el$99 = _el$98.firstChild, _el$100 = _el$99.nextSibling, _el$101 = _el$100.firstChild, _el$102 = _el$101.firstChild, _el$103 = _el$101.nextSibling;
30194
+ var _el$98 = _tmpl$3124(), _el$99 = _el$98.firstChild, _el$100 = _el$99.nextSibling, _el$101 = _el$100.firstChild, _el$102 = _el$101.firstChild, _el$103 = _el$101.nextSibling;
29851
30195
  _el$99.$$click = () => thread().clearSelection();
29852
30196
  insert(_el$102, () => selectedConvo()?.participantName ?? "Provider");
29853
30197
  insert(_el$101, createComponent(Show, {
@@ -29869,7 +30213,7 @@ function MessagesPanel(props) {
29869
30213
  return memo(() => selectedConvo()?.source === "support")() && selectedConvo()?.status === "closed";
29870
30214
  },
29871
30215
  get children() {
29872
- return _tmpl$2912();
30216
+ return _tmpl$2913();
29873
30217
  }
29874
30218
  }), null);
29875
30219
  insert(_el$98, createComponent(Show, {
@@ -29877,7 +30221,7 @@ function MessagesPanel(props) {
29877
30221
  return memo(() => selectedConvo()?.source === "support")() && selectedConvo()?.status === "transferred";
29878
30222
  },
29879
30223
  get children() {
29880
- return _tmpl$3011();
30224
+ return _tmpl$3012();
29881
30225
  }
29882
30226
  }), null);
29883
30227
  return _el$98;
@@ -29886,12 +30230,12 @@ function MessagesPanel(props) {
29886
30230
  return memo(() => selectedConvo()?.source === "support")() && (selectedConvo()?.status === "closed" || selectedConvo()?.status === "transferred");
29887
30231
  },
29888
30232
  get children() {
29889
- var _el$106 = _tmpl$3215(), _el$107 = _el$106.firstChild;
30233
+ var _el$106 = _tmpl$3216(), _el$107 = _el$106.firstChild;
29890
30234
  _el$107.$$click = continueWithCareTeam;
29891
30235
  return _el$106;
29892
30236
  }
29893
30237
  }), (() => {
29894
- var _el$108 = _tmpl$3315(), _el$110 = _el$108.firstChild;
30238
+ var _el$108 = _tmpl$3316(), _el$110 = _el$108.firstChild;
29895
30239
  insert(_el$108, createComponent(Show, {
29896
30240
  get when() {
29897
30241
  return thread().loadingMessages();
@@ -29934,7 +30278,7 @@ function MessagesPanel(props) {
29934
30278
  return attachError();
29935
30279
  },
29936
30280
  get children() {
29937
- var _el$112 = _tmpl$3415();
30281
+ var _el$112 = _tmpl$3416();
29938
30282
  insert(_el$112, attachError);
29939
30283
  return _el$112;
29940
30284
  }
@@ -30082,8 +30426,8 @@ function MessagesPanel(props) {
30082
30426
  }
30083
30427
  delegateEvents(["click", "input", "keydown"]);
30084
30428
  var _tmpl$505 = /* @__PURE__ */ template(`<ul class=history-list data-testid=history-list>`);
30085
- var _tmpl$2142 = /* @__PURE__ */ template(`<div class=portal-state data-testid=history-error><p>We couldn't load your submitted surveys. Please try again in a moment.`);
30086
- var _tmpl$3124 = /* @__PURE__ */ template(`<div class=portal-state data-testid=history-empty><p>No submitted questionnaires yet.</p><p class=history-hint>Your intake and refill check-in answers will appear here once you've submitted them.`);
30429
+ var _tmpl$2143 = /* @__PURE__ */ template(`<div class=portal-state data-testid=history-error><p>We couldn't load your submitted surveys. Please try again in a moment.`);
30430
+ var _tmpl$3125 = /* @__PURE__ */ template(`<div class=portal-state data-testid=history-empty><p>No submitted questionnaires yet.</p><p class=history-hint>Your intake and refill check-in answers will appear here once you've submitted them.`);
30087
30431
  var _tmpl$4103 = /* @__PURE__ */ template(`<li><button type=button class=history-row><span class=history-row__mode></span><span class=history-row__date></span><i class="ph-thin ph-caret-right portal-icon"aria-hidden=true>`);
30088
30432
  var _tmpl$578 = /* @__PURE__ */ template(`<div data-testid=history-detail><button type=button class="portal-btn portal-btn--ghost history-back"><i class="ph-thin ph-caret-left portal-icon"aria-hidden=true></i> All questionnaires`);
30089
30433
  var _tmpl$673 = /* @__PURE__ */ template(`<div class=portal-state><div class=request-status__spinner></div><p>Loading your answers\u2026`);
@@ -30120,7 +30464,7 @@ function SurveyHistory() {
30120
30464
  return !list.error;
30121
30465
  },
30122
30466
  get fallback() {
30123
- return _tmpl$2142();
30467
+ return _tmpl$2143();
30124
30468
  },
30125
30469
  get children() {
30126
30470
  return createComponent(Show, {
@@ -30128,7 +30472,7 @@ function SurveyHistory() {
30128
30472
  return (list() ?? []).length > 0;
30129
30473
  },
30130
30474
  get fallback() {
30131
- return _tmpl$3124();
30475
+ return _tmpl$3125();
30132
30476
  },
30133
30477
  get children() {
30134
30478
  var _el$ = _tmpl$505();
@@ -30229,8 +30573,8 @@ delegateEvents(["click"]);
30229
30573
 
30230
30574
  // src/pages/MemberPortal.tsx
30231
30575
  var _tmpl$506 = /* @__PURE__ */ template(`<span class=portal-item__live aria-label="In progress">`);
30232
- var _tmpl$2143 = /* @__PURE__ */ template(`<span>`);
30233
- var _tmpl$3125 = /* @__PURE__ */ template(`<button type=button><i aria-hidden=true></i><span class=portal-item__label>`);
30576
+ var _tmpl$2144 = /* @__PURE__ */ template(`<span>`);
30577
+ var _tmpl$3126 = /* @__PURE__ */ template(`<button type=button><i aria-hidden=true></i><span class=portal-item__label>`);
30234
30578
  var _tmpl$4104 = /* @__PURE__ */ template(`<div class=rx-others data-testid=rx-others><span class=lab-label>Other orders`);
30235
30579
  var _tmpl$579 = /* @__PURE__ */ template(`<div class=rx-stack>`);
30236
30580
  var _tmpl$674 = /* @__PURE__ */ template(`<div class=portal-state><div class=request-status__spinner></div><p>Loading your portal\u2026`);
@@ -30367,7 +30711,7 @@ function MemberPortal(props) {
30367
30711
  return tabs();
30368
30712
  },
30369
30713
  children: (item) => (() => {
30370
- var _el$ = _tmpl$3125(), _el$2 = _el$.firstChild, _el$3 = _el$2.nextSibling;
30714
+ var _el$ = _tmpl$3126(), _el$2 = _el$.firstChild, _el$3 = _el$2.nextSibling;
30371
30715
  _el$.$$click = () => selectTab(item.key);
30372
30716
  insert(_el$3, () => item.label);
30373
30717
  insert(_el$, createComponent(Show, {
@@ -30383,7 +30727,7 @@ function MemberPortal(props) {
30383
30727
  return memo(() => item.key === "messages")() && unreadTotal() > 0;
30384
30728
  },
30385
30729
  get children() {
30386
- var _el$5 = _tmpl$2143();
30730
+ var _el$5 = _tmpl$2144();
30387
30731
  insert(_el$5, (() => {
30388
30732
  var _c$ = memo(() => unreadTotal() > 99);
30389
30733
  return () => _c$() ? "99+" : unreadTotal();
@@ -30695,8 +31039,8 @@ function MemberPortal(props) {
30695
31039
  }
30696
31040
  delegateEvents(["click"]);
30697
31041
  var _tmpl$507 = /* @__PURE__ */ template(`<div style="padding:1rem 1.25rem;border-radius:var(--app-affiliate-radius);background:var(--app-affiliate-warning-bg);color:var(--app-affiliate-warning-fg);border:1px solid var(--app-affiliate-border)">Your affiliate account is awaiting approval. Once an admin activates it, your referral link will start earning commissions.`);
30698
- var _tmpl$2144 = /* @__PURE__ */ template(`<div style=display:flex;flex-direction:column;gap:1.5rem><h1 style=font-family:var(--app-affiliate-font-display);font-size:1.5rem;margin:0;color:var(--app-affiliate-fg)>Overview`);
30699
- var _tmpl$3126 = /* @__PURE__ */ template(`<div style=color:var(--app-affiliate-fg-muted)>Loading stats\u2026`);
31042
+ var _tmpl$2145 = /* @__PURE__ */ template(`<div style=display:flex;flex-direction:column;gap:1.5rem><h1 style=font-family:var(--app-affiliate-font-display);font-size:1.5rem;margin:0;color:var(--app-affiliate-fg)>Overview`);
31043
+ var _tmpl$3127 = /* @__PURE__ */ template(`<div style=color:var(--app-affiliate-fg-muted)>Loading stats\u2026`);
30700
31044
  var _tmpl$4105 = /* @__PURE__ */ template(`<div style="display:grid;grid-template-columns:repeat(auto-fit, minmax(180px, 1fr));gap:1rem">`);
30701
31045
  var _tmpl$580 = /* @__PURE__ */ template(`<div style="padding:1.25rem;background:var(--app-affiliate-surface);border:1px solid var(--app-affiliate-border);border-radius:var(--app-affiliate-radius)"><div style=font-size:0.75rem;text-transform:uppercase;letter-spacing:0.05em;color:var(--app-affiliate-fg-muted);margin-bottom:0.5rem></div><div style=font-family:var(--app-affiliate-font-display);font-size:1.75rem;color:var(--app-affiliate-fg)>`);
30702
31046
  function formatMoney(cents) {
@@ -30731,7 +31075,7 @@ function AffiliateOverview() {
30731
31075
  value: `${(s.conversionRate * 100).toFixed(1)}%`
30732
31076
  }];
30733
31077
  return (() => {
30734
- var _el$ = _tmpl$2144(); _el$.firstChild;
31078
+ var _el$ = _tmpl$2145(); _el$.firstChild;
30735
31079
  insert(_el$, createComponent(Show, {
30736
31080
  get when() {
30737
31081
  return isPending();
@@ -30745,7 +31089,7 @@ function AffiliateOverview() {
30745
31089
  return stats();
30746
31090
  },
30747
31091
  get fallback() {
30748
- return _tmpl$3126();
31092
+ return _tmpl$3127();
30749
31093
  },
30750
31094
  children: (s) => (() => {
30751
31095
  var _el$5 = _tmpl$4105();
@@ -30767,8 +31111,8 @@ function AffiliateOverview() {
30767
31111
  })();
30768
31112
  }
30769
31113
  var _tmpl$508 = /* @__PURE__ */ template(`<div style="background:var(--app-affiliate-surface);border:1px solid var(--app-affiliate-border);border-radius:var(--app-affiliate-radius);overflow:hidden"><table class=app-affiliate-table style=width:100%;border-collapse:collapse;font-size:0.875rem><thead><tr style=background:var(--app-affiliate-surface-light)><th>Date</th><th>Type</th><th>Order total</th><th>Commission</th><th>Status</th></tr></thead><tbody>`);
30770
- var _tmpl$2145 = /* @__PURE__ */ template(`<div style=display:flex;flex-direction:column;gap:1.5rem><h1 style=font-family:var(--app-affiliate-font-display);font-size:1.5rem;margin:0;color:var(--app-affiliate-fg)>Conversions`);
30771
- var _tmpl$3127 = /* @__PURE__ */ template(`<div style="padding:2rem;background:var(--app-affiliate-surface);border:1px solid var(--app-affiliate-border);border-radius:var(--app-affiliate-radius);color:var(--app-affiliate-fg-muted);text-align:center">No conversions yet. Share your referral link to start earning.`);
31114
+ var _tmpl$2146 = /* @__PURE__ */ template(`<div style=display:flex;flex-direction:column;gap:1.5rem><h1 style=font-family:var(--app-affiliate-font-display);font-size:1.5rem;margin:0;color:var(--app-affiliate-fg)>Conversions`);
31115
+ var _tmpl$3128 = /* @__PURE__ */ template(`<div style="padding:2rem;background:var(--app-affiliate-surface);border:1px solid var(--app-affiliate-border);border-radius:var(--app-affiliate-radius);color:var(--app-affiliate-fg-muted);text-align:center">No conversions yet. Share your referral link to start earning.`);
30772
31116
  var _tmpl$4106 = /* @__PURE__ */ template(`<span title="Override commission earned on a sub-affiliate's sale"style="margin-left:0.4rem;padding:0.1rem 0.45rem;border-radius:999px;font-size:0.65rem;font-weight:600;background:var(--app-affiliate-primary-soft);color:var(--app-affiliate-primary-soft-fg)">Override`);
30773
31117
  var _tmpl$581 = /* @__PURE__ */ template(`<tr style="border-top:1px solid var(--app-affiliate-border)"><td data-label=Date></td><td data-label=Type></td><td data-label="Order total"></td><td data-label=Commission style=color:var(--app-affiliate-fg);font-weight:600></td><td data-label=Status><span style="padding:0.2rem 0.6rem;border-radius:999px;font-size:0.75rem;font-weight:600">`);
30774
31118
  function formatMoney2(cents) {
@@ -30808,13 +31152,13 @@ function AffiliateConversions() {
30808
31152
  limit: 100
30809
31153
  });
30810
31154
  return (() => {
30811
- var _el$ = _tmpl$2145(); _el$.firstChild;
31155
+ var _el$ = _tmpl$2146(); _el$.firstChild;
30812
31156
  insert(_el$, createComponent(Show, {
30813
31157
  get when() {
30814
31158
  return (conversions() ?? []).length > 0;
30815
31159
  },
30816
31160
  get fallback() {
30817
- return _tmpl$3127();
31161
+ return _tmpl$3128();
30818
31162
  },
30819
31163
  get children() {
30820
31164
  var _el$3 = _tmpl$508(), _el$4 = _el$3.firstChild, _el$5 = _el$4.firstChild, _el$6 = _el$5.firstChild, _el$7 = _el$6.firstChild, _el$8 = _el$7.nextSibling, _el$9 = _el$8.nextSibling, _el$0 = _el$9.nextSibling, _el$1 = _el$0.nextSibling, _el$10 = _el$5.nextSibling;
@@ -30903,8 +31247,8 @@ function td() {
30903
31247
  };
30904
31248
  }
30905
31249
  var _tmpl$509 = /* @__PURE__ */ template(`<div style="background:var(--app-affiliate-surface);border:1px solid var(--app-affiliate-border);border-radius:var(--app-affiliate-radius);overflow:hidden"><table class=app-affiliate-table style=width:100%;border-collapse:collapse;font-size:0.875rem><thead><tr style=background:var(--app-affiliate-surface-light)><th>Code</th><th>Name</th><th>Status</th><th>Joined</th></tr></thead><tbody>`);
30906
- var _tmpl$2146 = /* @__PURE__ */ template(`<div style=display:flex;flex-direction:column;gap:1.5rem><h1 style=font-family:var(--app-affiliate-font-display);font-size:1.5rem;margin:0;color:var(--app-affiliate-fg)>Downline</h1><p style=margin:0;color:var(--app-affiliate-fg-muted);font-size:0.875rem>Affiliates you've referred. You earn an override commission on every qualifying sale they make \u2014 those show up as \u201COverride\u201D rows on your Conversions.`);
30907
- var _tmpl$3128 = /* @__PURE__ */ template(`<div style="padding:2rem;background:var(--app-affiliate-surface);border:1px solid var(--app-affiliate-border);border-radius:var(--app-affiliate-radius);color:var(--app-affiliate-fg-muted);text-align:center">No sub-affiliates yet.`);
31250
+ var _tmpl$2147 = /* @__PURE__ */ template(`<div style=display:flex;flex-direction:column;gap:1.5rem><h1 style=font-family:var(--app-affiliate-font-display);font-size:1.5rem;margin:0;color:var(--app-affiliate-fg)>Downline</h1><p style=margin:0;color:var(--app-affiliate-fg-muted);font-size:0.875rem>Affiliates you've referred. You earn an override commission on every qualifying sale they make \u2014 those show up as \u201COverride\u201D rows on your Conversions.`);
31251
+ var _tmpl$3129 = /* @__PURE__ */ template(`<div style="padding:2rem;background:var(--app-affiliate-surface);border:1px solid var(--app-affiliate-border);border-radius:var(--app-affiliate-radius);color:var(--app-affiliate-fg-muted);text-align:center">No sub-affiliates yet.`);
30908
31252
  var _tmpl$4107 = /* @__PURE__ */ template(`<tr style="border-top:1px solid var(--app-affiliate-border)"><td data-label=Code style=font-family:var(--app-affiliate-font-mono)></td><td data-label=Name></td><td data-label=Status><span style="padding:0.2rem 0.6rem;border-radius:999px;font-size:0.75rem;font-weight:600"></span></td><td data-label=Joined>`);
30909
31253
  function formatDate5(iso) {
30910
31254
  const d = new Date(iso);
@@ -30938,13 +31282,13 @@ function AffiliateDownline() {
30938
31282
  downline
30939
31283
  } = useAffiliateDownline();
30940
31284
  return (() => {
30941
- var _el$ = _tmpl$2146(), _el$2 = _el$.firstChild; _el$2.nextSibling;
31285
+ var _el$ = _tmpl$2147(), _el$2 = _el$.firstChild; _el$2.nextSibling;
30942
31286
  insert(_el$, createComponent(Show, {
30943
31287
  get when() {
30944
31288
  return (downline() ?? []).length > 0;
30945
31289
  },
30946
31290
  get fallback() {
30947
- return _tmpl$3128();
31291
+ return _tmpl$3129();
30948
31292
  },
30949
31293
  get children() {
30950
31294
  var _el$4 = _tmpl$509(), _el$5 = _el$4.firstChild, _el$6 = _el$5.firstChild, _el$7 = _el$6.firstChild, _el$8 = _el$7.firstChild, _el$9 = _el$8.nextSibling, _el$0 = _el$9.nextSibling, _el$1 = _el$0.nextSibling, _el$10 = _el$6.nextSibling;
@@ -31017,8 +31361,8 @@ function td2() {
31017
31361
  };
31018
31362
  }
31019
31363
  var _tmpl$584 = /* @__PURE__ */ template(`<div style="padding:1.5rem;background:var(--app-affiliate-surface);border:1px solid var(--app-affiliate-border);border-radius:var(--app-affiliate-radius);display:flex;flex-direction:column;gap:0.75rem"><div style=font-size:0.75rem;text-transform:uppercase;letter-spacing:0.05em;color:var(--app-affiliate-fg-muted)>Share this link</div><div style=display:flex;gap:0.5rem;align-items:stretch;flex-wrap:wrap><code style="flex:1;min-width:16rem;padding:0.75rem 1rem;background:var(--app-affiliate-surface-light);border-radius:var(--app-affiliate-radius-sm);font-family:var(--app-affiliate-font-mono);color:var(--app-affiliate-fg);word-break:break-all"></code><button type=button style="padding:0.75rem 1.25rem;background:var(--app-affiliate-primary);color:var(--app-affiliate-primary-fg);border:none;border-radius:var(--app-affiliate-radius-sm);font-weight:600;cursor:pointer"></button></div><div style=font-size:0.875rem;color:var(--app-affiliate-fg-muted)>Anyone who visits this URL has a tracking cookie set for the duration of your program. If they sign up and subscribe within the cookie window, you earn commission on the conversion.`);
31020
- var _tmpl$2147 = /* @__PURE__ */ template(`<div style=display:flex;flex-direction:column;gap:1.5rem><h1 style=font-family:var(--app-affiliate-font-display);font-size:1.5rem;margin:0;color:var(--app-affiliate-fg)>Referral link`);
31021
- var _tmpl$3129 = /* @__PURE__ */ template(`<div style=color:var(--app-affiliate-fg-muted)>Your referral link will appear here once your account is approved.`);
31364
+ var _tmpl$2148 = /* @__PURE__ */ template(`<div style=display:flex;flex-direction:column;gap:1.5rem><h1 style=font-family:var(--app-affiliate-font-display);font-size:1.5rem;margin:0;color:var(--app-affiliate-fg)>Referral link`);
31365
+ var _tmpl$3130 = /* @__PURE__ */ template(`<div style=color:var(--app-affiliate-fg-muted)>Your referral link will appear here once your account is approved.`);
31022
31366
  function AffiliateReferralLink() {
31023
31367
  const {
31024
31368
  links
@@ -31043,13 +31387,13 @@ function AffiliateReferralLink() {
31043
31387
  }
31044
31388
  }
31045
31389
  return (() => {
31046
- var _el$ = _tmpl$2147(); _el$.firstChild;
31390
+ var _el$ = _tmpl$2148(); _el$.firstChild;
31047
31391
  insert(_el$, createComponent(Show, {
31048
31392
  get when() {
31049
31393
  return homepageLink();
31050
31394
  },
31051
31395
  get fallback() {
31052
- return _tmpl$3129();
31396
+ return _tmpl$3130();
31053
31397
  },
31054
31398
  get children() {
31055
31399
  var _el$3 = _tmpl$584(), _el$4 = _el$3.firstChild, _el$5 = _el$4.nextSibling, _el$6 = _el$5.firstChild, _el$7 = _el$6.nextSibling; _el$5.nextSibling;
@@ -31064,8 +31408,8 @@ function AffiliateReferralLink() {
31064
31408
  }
31065
31409
  delegateEvents(["click"]);
31066
31410
  var _tmpl$585 = /* @__PURE__ */ template(`<div style=display:flex;flex-direction:column;gap:1.5rem><h1 style=font-family:var(--app-affiliate-font-display);font-size:1.5rem;margin:0;color:var(--app-affiliate-fg)>Account</h1><div><button type=button style="padding:0.75rem 1.25rem;background:transparent;color:var(--app-affiliate-fg);border:1px solid var(--app-affiliate-border-strong);border-radius:var(--app-affiliate-radius-sm);cursor:pointer;font-weight:500">Log out</button></div><div style=font-size:0.875rem;color:var(--app-affiliate-fg-muted)>To update your profile or payment details, contact your program administrator.`);
31067
- var _tmpl$2148 = /* @__PURE__ */ template(`<div style=color:var(--app-affiliate-fg-muted)>Loading\u2026`);
31068
- var _tmpl$3130 = /* @__PURE__ */ template(`<div style="background:var(--app-affiliate-surface);border:1px solid var(--app-affiliate-border);border-radius:var(--app-affiliate-radius);overflow:hidden">`);
31411
+ var _tmpl$2149 = /* @__PURE__ */ template(`<div style=color:var(--app-affiliate-fg-muted)>Loading\u2026`);
31412
+ var _tmpl$3131 = /* @__PURE__ */ template(`<div style="background:var(--app-affiliate-surface);border:1px solid var(--app-affiliate-border);border-radius:var(--app-affiliate-radius);overflow:hidden">`);
31069
31413
  var _tmpl$4108 = /* @__PURE__ */ template(`<div style="display:flex;justify-content:space-between;align-items:center;padding:0.875rem 1.25rem;border-bottom:1px solid var(--app-affiliate-border)"><div style=font-size:0.75rem;text-transform:uppercase;letter-spacing:0.05em;color:var(--app-affiliate-fg-muted)></div><div style=color:var(--app-affiliate-fg)>`);
31070
31414
  var STATUS_LABEL2 = {
31071
31415
  pending: "Pending approval",
@@ -31107,10 +31451,10 @@ function AffiliateSettings() {
31107
31451
  return affiliate();
31108
31452
  },
31109
31453
  get fallback() {
31110
- return _tmpl$2148();
31454
+ return _tmpl$2149();
31111
31455
  },
31112
31456
  children: (a) => (() => {
31113
- var _el$7 = _tmpl$3130();
31457
+ var _el$7 = _tmpl$3131();
31114
31458
  insert(_el$7, createComponent(For, {
31115
31459
  get each() {
31116
31460
  return rows(a());
@@ -31133,8 +31477,8 @@ delegateEvents(["click"]);
31133
31477
 
31134
31478
  // src/pages/AffiliatePortal.tsx
31135
31479
  var _tmpl$586 = /* @__PURE__ */ template(`<div class="app-affiliate-root app-affiliate-shell"style=position:sticky;background:var(--app-affiliate-bg);color:var(--app-affiliate-fg)><div class=app-affiliate-shell-header><button type=button class=app-affiliate-shell-menu-trigger aria-label="Open portal menu"><svg width=22 height=22 viewBox="0 0 24 24"fill=none stroke=currentColor stroke-width=2 stroke-linecap=round aria-hidden=true><line x1=3 y1=6 x2=21 y2=6></line><line x1=3 y1=12 x2=21 y2=12></line><line x1=3 y1=18 x2=21 y2=18></line></svg></button><span class=app-affiliate-shell-header-title></span></div><div class=app-affiliate-backdrop aria-hidden=true></div><aside class=app-affiliate-sidebar><div style=padding:1.25rem><h2 style="font-size:0.7rem;font-weight:500;color:var(--app-affiliate-fg-muted);text-transform:uppercase;letter-spacing:0.08em;margin:0 0 1rem">Affiliate Portal</h2><nav style=display:flex;flex-direction:column;gap:0.25rem></nav></div></aside><div class=app-affiliate-content>`);
31136
- var _tmpl$2149 = /* @__PURE__ */ template(`<span style=font-size:1rem;opacity:0.7;flex-shrink:0>`);
31137
- var _tmpl$3131 = /* @__PURE__ */ template(`<button type=button style="display:flex;align-items:center;gap:0.75rem;padding:0.625rem 0.75rem;border-radius:var(--app-affiliate-radius-sm);font-size:0.875rem;font-weight:500;text-align:left;border:none;cursor:pointer">`);
31480
+ var _tmpl$2150 = /* @__PURE__ */ template(`<span style=font-size:1rem;opacity:0.7;flex-shrink:0>`);
31481
+ var _tmpl$3132 = /* @__PURE__ */ template(`<button type=button style="display:flex;align-items:center;gap:0.75rem;padding:0.625rem 0.75rem;border-radius:var(--app-affiliate-radius-sm);font-size:0.875rem;font-weight:500;text-align:left;border:none;cursor:pointer">`);
31138
31482
  var _tmpl$4109 = /* @__PURE__ */ template(`<div class=app-affiliate-root style=display:flex;align-items:center;justify-content:center;position:sticky;background:var(--app-affiliate-bg)><div role=status aria-label="Loading affiliate portal"style="width:1.75rem;height:1.75rem;border-radius:9999px;border:2px solid var(--app-affiliate-border);border-top-color:var(--app-affiliate-primary);animation:app-affiliate-gate-spin 0.8s linear infinite"></div><style>@keyframes app-affiliate-gate-spin { to { transform: rotate(360deg); } }`);
31139
31483
  var TAB_LABELS2 = {
31140
31484
  overview: "Overview",
@@ -31189,14 +31533,14 @@ function AffiliatePortal(props) {
31189
31533
  return orderedTabs();
31190
31534
  },
31191
31535
  children: (tab) => (() => {
31192
- var _el$1 = _tmpl$3131();
31536
+ var _el$1 = _tmpl$3132();
31193
31537
  _el$1.$$click = () => handleTabClick(tab);
31194
31538
  insert(_el$1, createComponent(Show, {
31195
31539
  get when() {
31196
31540
  return props.tabIcons?.[tab];
31197
31541
  },
31198
31542
  get children() {
31199
- var _el$10 = _tmpl$2149();
31543
+ var _el$10 = _tmpl$2150();
31200
31544
  effect(() => className(_el$10, props.tabIcons[tab]));
31201
31545
  return _el$10;
31202
31546
  }
@@ -31338,8 +31682,8 @@ delegateEvents(["input", "click"]);
31338
31682
 
31339
31683
  // src/pages/AffiliateRegister.tsx
31340
31684
  var _tmpl$588 = /* @__PURE__ */ template(`<input type=text required autocomplete=given-name>`);
31341
- var _tmpl$2150 = /* @__PURE__ */ template(`<input type=text required autocomplete=family-name>`);
31342
- var _tmpl$3132 = /* @__PURE__ */ template(`<input type=email required autocomplete=email>`);
31685
+ var _tmpl$2151 = /* @__PURE__ */ template(`<input type=text required autocomplete=family-name>`);
31686
+ var _tmpl$3133 = /* @__PURE__ */ template(`<input type=email required autocomplete=email>`);
31343
31687
  var _tmpl$4115 = /* @__PURE__ */ template(`<input type=text required minlength=4>`);
31344
31688
  var _tmpl$589 = /* @__PURE__ */ template(`<div style="padding:0.625rem 0.875rem;background:var(--app-affiliate-danger-bg);color:var(--app-affiliate-danger-fg);border-radius:var(--app-affiliate-radius-sm);font-size:0.875rem">`);
31345
31689
  var _tmpl$675 = /* @__PURE__ */ template(`<button type=button>Already have an account? Log in`);
@@ -31402,7 +31746,7 @@ function AffiliateRegister(props) {
31402
31746
  insert(_el$6, createComponent(Row3, {
31403
31747
  label: "Last name",
31404
31748
  get children() {
31405
- var _el$8 = _tmpl$2150();
31749
+ var _el$8 = _tmpl$2151();
31406
31750
  _el$8.$$input = (e) => setLastName(e.currentTarget.value);
31407
31751
  effect((_$p) => style(_el$8, inputStyle2(), _$p));
31408
31752
  effect(() => _el$8.value = lastName());
@@ -31412,7 +31756,7 @@ function AffiliateRegister(props) {
31412
31756
  insert(_el$6, createComponent(Row3, {
31413
31757
  label: "Email",
31414
31758
  get children() {
31415
- var _el$9 = _tmpl$3132();
31759
+ var _el$9 = _tmpl$3133();
31416
31760
  _el$9.$$input = (e) => setEmail(e.currentTarget.value);
31417
31761
  effect((_$p) => style(_el$9, inputStyle2(), _$p));
31418
31762
  effect(() => _el$9.value = email());
@@ -31532,8 +31876,8 @@ function linkStyle() {
31532
31876
  }
31533
31877
  delegateEvents(["input", "click"]);
31534
31878
  var _tmpl$590 = /* @__PURE__ */ template(`<div style="padding:0.625rem 0.875rem;background:var(--app-affiliate-danger-bg);color:var(--app-affiliate-danger-fg);border-radius:var(--app-affiliate-radius-sm);font-size:0.875rem">`);
31535
- var _tmpl$2151 = /* @__PURE__ */ template(`<button type=button style=background:transparent;border:none;color:var(--app-affiliate-fg-muted);cursor:pointer;text-decoration:underline;font-size:0.875rem;padding:0;text-align:center>Forgot your password?`);
31536
- var _tmpl$3133 = /* @__PURE__ */ template(`<button type=button style=background:transparent;border:none;color:var(--app-affiliate-primary-soft-fg);cursor:pointer;text-decoration:underline;font-size:0.875rem;padding:0;text-align:center>New affiliate? Apply`);
31879
+ var _tmpl$2152 = /* @__PURE__ */ template(`<button type=button style=background:transparent;border:none;color:var(--app-affiliate-fg-muted);cursor:pointer;text-decoration:underline;font-size:0.875rem;padding:0;text-align:center>Forgot your password?`);
31880
+ var _tmpl$3134 = /* @__PURE__ */ template(`<button type=button style=background:transparent;border:none;color:var(--app-affiliate-primary-soft-fg);cursor:pointer;text-decoration:underline;font-size:0.875rem;padding:0;text-align:center>New affiliate? Apply`);
31537
31881
  var _tmpl$4116 = /* @__PURE__ */ template(`<div class=app-affiliate-root style="background:var(--app-affiliate-bg);color:var(--app-affiliate-fg);min-height:100vh;display:flex;align-items:center;justify-content:center;padding:2rem 1rem"><div style="width:100%;max-width:24rem;background:var(--app-affiliate-surface);border:1px solid var(--app-affiliate-border);border-radius:var(--app-affiliate-radius);padding:2rem;display:flex;flex-direction:column;gap:1.25rem"><h1 style=font-family:var(--app-affiliate-font-display);margin:0;font-size:1.5rem>Affiliate login</h1><form style=display:flex;flex-direction:column;gap:0.875rem><label style=display:flex;flex-direction:column;gap:0.35rem><span>Email</span><input type=email required autocomplete=email></label><label style=display:flex;flex-direction:column;gap:0.35rem><span>Password</span></label><button type=submit style="padding:0.75rem 1rem;background:var(--app-affiliate-primary);color:var(--app-affiliate-primary-fg);border:none;border-radius:var(--app-affiliate-radius-sm);font-weight:600">`);
31538
31882
  function AffiliateLogin(props) {
31539
31883
  const [email, setEmail] = createSignal("");
@@ -31581,7 +31925,7 @@ function AffiliateLogin(props) {
31581
31925
  return props.onNavigateForgotPassword;
31582
31926
  },
31583
31927
  get children() {
31584
- var _el$10 = _tmpl$2151();
31928
+ var _el$10 = _tmpl$2152();
31585
31929
  _el$10.$$click = () => props.onNavigateForgotPassword?.();
31586
31930
  return _el$10;
31587
31931
  }
@@ -31591,7 +31935,7 @@ function AffiliateLogin(props) {
31591
31935
  return props.onNavigateRegister;
31592
31936
  },
31593
31937
  get children() {
31594
- var _el$11 = _tmpl$3133();
31938
+ var _el$11 = _tmpl$3134();
31595
31939
  _el$11.$$click = () => props.onNavigateRegister?.();
31596
31940
  return _el$11;
31597
31941
  }
@@ -31640,8 +31984,8 @@ function inputStyle3() {
31640
31984
  }
31641
31985
  delegateEvents(["input", "click"]);
31642
31986
  var _tmpl$591 = /* @__PURE__ */ template(`<div style="padding:0.625rem 0.875rem;background:var(--app-affiliate-danger-bg);color:var(--app-affiliate-danger-fg);border-radius:var(--app-affiliate-radius-sm);font-size:0.875rem">`);
31643
- var _tmpl$2152 = /* @__PURE__ */ template(`<form style=display:flex;flex-direction:column;gap:0.875rem><label style=display:flex;flex-direction:column;gap:0.35rem><span>Email</span><input type=email required></label><button type=submit style="padding:0.75rem 1rem;background:var(--app-affiliate-primary);color:var(--app-affiliate-primary-fg);border:none;border-radius:var(--app-affiliate-radius-sm);font-weight:600">`);
31644
- var _tmpl$3134 = /* @__PURE__ */ template(`<div class=app-affiliate-root style="background:var(--app-affiliate-bg);color:var(--app-affiliate-fg);min-height:100vh;display:flex;align-items:center;justify-content:center;padding:2rem 1rem"><div style="width:100%;max-width:24rem;background:var(--app-affiliate-surface);border:1px solid var(--app-affiliate-border);border-radius:var(--app-affiliate-radius);padding:2rem;display:flex;flex-direction:column;gap:1.25rem"><h1 style=font-family:var(--app-affiliate-font-display);margin:0;font-size:1.5rem>Reset your password`);
31987
+ var _tmpl$2153 = /* @__PURE__ */ template(`<form style=display:flex;flex-direction:column;gap:0.875rem><label style=display:flex;flex-direction:column;gap:0.35rem><span>Email</span><input type=email required></label><button type=submit style="padding:0.75rem 1rem;background:var(--app-affiliate-primary);color:var(--app-affiliate-primary-fg);border:none;border-radius:var(--app-affiliate-radius-sm);font-weight:600">`);
31988
+ var _tmpl$3135 = /* @__PURE__ */ template(`<div class=app-affiliate-root style="background:var(--app-affiliate-bg);color:var(--app-affiliate-fg);min-height:100vh;display:flex;align-items:center;justify-content:center;padding:2rem 1rem"><div style="width:100%;max-width:24rem;background:var(--app-affiliate-surface);border:1px solid var(--app-affiliate-border);border-radius:var(--app-affiliate-radius);padding:2rem;display:flex;flex-direction:column;gap:1.25rem"><h1 style=font-family:var(--app-affiliate-font-display);margin:0;font-size:1.5rem>Reset your password`);
31645
31989
  var _tmpl$4117 = /* @__PURE__ */ template(`<div style="padding:0.625rem 0.875rem;background:var(--app-affiliate-surface-light);border-radius:var(--app-affiliate-radius-sm);font-size:0.875rem">`);
31646
31990
  var _tmpl$594 = /* @__PURE__ */ template(`<p style=margin:0;font-size:0.8125rem;opacity:0.8>The link is good for one hour. If nothing arrives, check your spam folder \u2014 and make sure this is the address you signed up with.`);
31647
31991
  var _tmpl$676 = /* @__PURE__ */ template(`<button type=button style="padding:0.75rem 1rem;background:var(--app-affiliate-primary);color:var(--app-affiliate-primary-fg);border:none;border-radius:var(--app-affiliate-radius-sm);font-weight:600;cursor:pointer">Back to sign in`);
@@ -31667,7 +32011,7 @@ function ForgotPasswordPage(props) {
31667
32011
  }
31668
32012
  }
31669
32013
  return (() => {
31670
- var _el$ = _tmpl$3134(), _el$2 = _el$.firstChild; _el$2.firstChild;
32014
+ var _el$ = _tmpl$3135(), _el$2 = _el$.firstChild; _el$2.firstChild;
31671
32015
  insert(_el$2, createComponent(Show, {
31672
32016
  get when() {
31673
32017
  return !message();
@@ -31689,7 +32033,7 @@ function ForgotPasswordPage(props) {
31689
32033
  })];
31690
32034
  },
31691
32035
  get children() {
31692
- var _el$4 = _tmpl$2152(), _el$5 = _el$4.firstChild, _el$6 = _el$5.firstChild, _el$7 = _el$6.nextSibling, _el$9 = _el$5.nextSibling;
32036
+ var _el$4 = _tmpl$2153(), _el$5 = _el$4.firstChild, _el$6 = _el$5.firstChild, _el$7 = _el$6.nextSibling, _el$9 = _el$5.nextSibling;
31693
32037
  _el$4.addEventListener("submit", handleSubmit);
31694
32038
  _el$7.$$input = (e) => setEmail(e.currentTarget.value);
31695
32039
  insert(_el$4, createComponent(Show, {
@@ -31748,8 +32092,8 @@ function inputStyle4() {
31748
32092
  }
31749
32093
  delegateEvents(["input", "click"]);
31750
32094
  var _tmpl$595 = /* @__PURE__ */ template(`<div style="padding:0.625rem 0.875rem;background:var(--app-affiliate-danger-bg);color:var(--app-affiliate-danger-fg);border-radius:var(--app-affiliate-radius-sm);font-size:0.875rem">`);
31751
- var _tmpl$2153 = /* @__PURE__ */ template(`<form style=display:flex;flex-direction:column;gap:0.875rem><label style=display:flex;flex-direction:column;gap:0.35rem><span>New password</span><input type=password required autocomplete=new-password></label><label style=display:flex;flex-direction:column;gap:0.35rem><span>Confirm password</span><input type=password required autocomplete=new-password></label><button type=submit style="padding:0.75rem 1rem;background:var(--app-affiliate-primary);color:var(--app-affiliate-primary-fg);border:none;border-radius:var(--app-affiliate-radius-sm);font-weight:600">`);
31752
- var _tmpl$3135 = /* @__PURE__ */ template(`<div class=app-affiliate-root style="background:var(--app-affiliate-bg);color:var(--app-affiliate-fg);min-height:100vh;display:flex;align-items:center;justify-content:center;padding:2rem 1rem"><div style="width:100%;max-width:24rem;background:var(--app-affiliate-surface);border:1px solid var(--app-affiliate-border);border-radius:var(--app-affiliate-radius);padding:2rem;display:flex;flex-direction:column;gap:1.25rem"><h1 style=font-family:var(--app-affiliate-font-display);margin:0;font-size:1.5rem>Choose a new password`);
32095
+ var _tmpl$2154 = /* @__PURE__ */ template(`<form style=display:flex;flex-direction:column;gap:0.875rem><label style=display:flex;flex-direction:column;gap:0.35rem><span>New password</span><input type=password required autocomplete=new-password></label><label style=display:flex;flex-direction:column;gap:0.35rem><span>Confirm password</span><input type=password required autocomplete=new-password></label><button type=submit style="padding:0.75rem 1rem;background:var(--app-affiliate-primary);color:var(--app-affiliate-primary-fg);border:none;border-radius:var(--app-affiliate-radius-sm);font-weight:600">`);
32096
+ var _tmpl$3136 = /* @__PURE__ */ template(`<div class=app-affiliate-root style="background:var(--app-affiliate-bg);color:var(--app-affiliate-fg);min-height:100vh;display:flex;align-items:center;justify-content:center;padding:2rem 1rem"><div style="width:100%;max-width:24rem;background:var(--app-affiliate-surface);border:1px solid var(--app-affiliate-border);border-radius:var(--app-affiliate-radius);padding:2rem;display:flex;flex-direction:column;gap:1.25rem"><h1 style=font-family:var(--app-affiliate-font-display);margin:0;font-size:1.5rem>Choose a new password`);
31753
32097
  var _tmpl$4118 = /* @__PURE__ */ template(`<div style="padding:0.625rem 0.875rem;background:var(--app-affiliate-surface-light);border-radius:var(--app-affiliate-radius-sm);font-size:0.875rem">`);
31754
32098
  function queryParam(name) {
31755
32099
  if (typeof window === "undefined") return "";
@@ -31790,7 +32134,7 @@ function ResetPasswordPage(props) {
31790
32134
  }
31791
32135
  }
31792
32136
  return (() => {
31793
- var _el$ = _tmpl$3135(), _el$2 = _el$.firstChild; _el$2.firstChild;
32137
+ var _el$ = _tmpl$3136(), _el$2 = _el$.firstChild; _el$2.firstChild;
31794
32138
  insert(_el$2, createComponent(Show, {
31795
32139
  get when() {
31796
32140
  return !message();
@@ -31803,7 +32147,7 @@ function ResetPasswordPage(props) {
31803
32147
  })();
31804
32148
  },
31805
32149
  get children() {
31806
- var _el$4 = _tmpl$2153(), _el$5 = _el$4.firstChild, _el$6 = _el$5.firstChild, _el$7 = _el$6.nextSibling, _el$8 = _el$5.nextSibling, _el$9 = _el$8.firstChild, _el$0 = _el$9.nextSibling, _el$10 = _el$8.nextSibling;
32150
+ var _el$4 = _tmpl$2154(), _el$5 = _el$4.firstChild, _el$6 = _el$5.firstChild, _el$7 = _el$6.nextSibling, _el$8 = _el$5.nextSibling, _el$9 = _el$8.firstChild, _el$0 = _el$9.nextSibling, _el$10 = _el$8.nextSibling;
31807
32151
  _el$4.addEventListener("submit", handleSubmit);
31808
32152
  _el$7.$$input = (e) => setPassword(e.currentTarget.value);
31809
32153
  _el$0.$$input = (e) => setConfirm(e.currentTarget.value);
@@ -31868,8 +32212,8 @@ function inputStyle5() {
31868
32212
  }
31869
32213
  delegateEvents(["input"]);
31870
32214
  var _tmpl$596 = /* @__PURE__ */ template(`<div style="padding:0.625rem 0.875rem;background:var(--app-affiliate-danger-bg);color:var(--app-affiliate-danger-fg);border-radius:var(--app-affiliate-radius-sm);font-size:0.875rem">`);
31871
- var _tmpl$2154 = /* @__PURE__ */ template(`<form style=display:flex;flex-direction:column;gap:0.875rem><label style=display:flex;flex-direction:column;gap:0.35rem><span>Choose a password</span><input type=password required autocomplete=new-password></label><label style=display:flex;flex-direction:column;gap:0.35rem><span>Confirm password</span><input type=password required autocomplete=new-password></label><button type=submit style="padding:0.75rem 1rem;background:var(--app-affiliate-primary);color:var(--app-affiliate-primary-fg);border:none;border-radius:var(--app-affiliate-radius-sm);font-weight:600">`);
31872
- var _tmpl$3136 = /* @__PURE__ */ template(`<div class=app-affiliate-root style="background:var(--app-affiliate-bg);color:var(--app-affiliate-fg);min-height:100vh;display:flex;align-items:center;justify-content:center;padding:2rem 1rem"><div style="width:100%;max-width:24rem;background:var(--app-affiliate-surface);border:1px solid var(--app-affiliate-border);border-radius:var(--app-affiliate-radius);padding:2rem;display:flex;flex-direction:column;gap:1.25rem"><h1 style=font-family:var(--app-affiliate-font-display);margin:0;font-size:1.5rem>Accept your admin invite`);
32215
+ var _tmpl$2155 = /* @__PURE__ */ template(`<form style=display:flex;flex-direction:column;gap:0.875rem><label style=display:flex;flex-direction:column;gap:0.35rem><span>Choose a password</span><input type=password required autocomplete=new-password></label><label style=display:flex;flex-direction:column;gap:0.35rem><span>Confirm password</span><input type=password required autocomplete=new-password></label><button type=submit style="padding:0.75rem 1rem;background:var(--app-affiliate-primary);color:var(--app-affiliate-primary-fg);border:none;border-radius:var(--app-affiliate-radius-sm);font-weight:600">`);
32216
+ var _tmpl$3137 = /* @__PURE__ */ template(`<div class=app-affiliate-root style="background:var(--app-affiliate-bg);color:var(--app-affiliate-fg);min-height:100vh;display:flex;align-items:center;justify-content:center;padding:2rem 1rem"><div style="width:100%;max-width:24rem;background:var(--app-affiliate-surface);border:1px solid var(--app-affiliate-border);border-radius:var(--app-affiliate-radius);padding:2rem;display:flex;flex-direction:column;gap:1.25rem"><h1 style=font-family:var(--app-affiliate-font-display);margin:0;font-size:1.5rem>Accept your admin invite`);
31873
32217
  var _tmpl$4119 = /* @__PURE__ */ template(`<div style="padding:0.625rem 0.875rem;background:var(--app-affiliate-surface-light);border-radius:var(--app-affiliate-radius-sm);font-size:0.875rem">`);
31874
32218
  function queryParam2(name) {
31875
32219
  if (typeof window === "undefined") return "";
@@ -31915,7 +32259,7 @@ function AcceptAdminInvitePage(props) {
31915
32259
  }
31916
32260
  }
31917
32261
  return (() => {
31918
- var _el$ = _tmpl$3136(), _el$2 = _el$.firstChild; _el$2.firstChild;
32262
+ var _el$ = _tmpl$3137(), _el$2 = _el$.firstChild; _el$2.firstChild;
31919
32263
  insert(_el$2, createComponent(Show, {
31920
32264
  get when() {
31921
32265
  return !message();
@@ -31928,7 +32272,7 @@ function AcceptAdminInvitePage(props) {
31928
32272
  })();
31929
32273
  },
31930
32274
  get children() {
31931
- var _el$4 = _tmpl$2154(), _el$5 = _el$4.firstChild, _el$6 = _el$5.firstChild, _el$7 = _el$6.nextSibling, _el$8 = _el$5.nextSibling, _el$9 = _el$8.firstChild, _el$0 = _el$9.nextSibling, _el$10 = _el$8.nextSibling;
32275
+ var _el$4 = _tmpl$2155(), _el$5 = _el$4.firstChild, _el$6 = _el$5.firstChild, _el$7 = _el$6.nextSibling, _el$8 = _el$5.nextSibling, _el$9 = _el$8.firstChild, _el$0 = _el$9.nextSibling, _el$10 = _el$8.nextSibling;
31932
32276
  _el$4.addEventListener("submit", handleSubmit);
31933
32277
  _el$7.$$input = (e) => setPassword(e.currentTarget.value);
31934
32278
  _el$0.$$input = (e) => setConfirm(e.currentTarget.value);
@@ -31993,8 +32337,8 @@ function inputStyle6() {
31993
32337
  }
31994
32338
  delegateEvents(["input"]);
31995
32339
  var _tmpl$597 = /* @__PURE__ */ template(`<div>`);
31996
- var _tmpl$2155 = /* @__PURE__ */ template(`<form style=display:flex;flex-direction:column;gap:0.875rem><label style=display:flex;flex-direction:column;gap:0.35rem><span>Email</span><input type=email required autocomplete=email></label><button type=submit>`);
31997
- var _tmpl$3137 = /* @__PURE__ */ template(`<button type=button>Back to login`);
32340
+ var _tmpl$2156 = /* @__PURE__ */ template(`<form style=display:flex;flex-direction:column;gap:0.875rem><label style=display:flex;flex-direction:column;gap:0.35rem><span>Email</span><input type=email required autocomplete=email></label><button type=submit>`);
32341
+ var _tmpl$3138 = /* @__PURE__ */ template(`<button type=button>Back to login`);
31998
32342
  var _tmpl$4120 = /* @__PURE__ */ template(`<div class=app-affiliate-root><div><h1>Reset your password`);
31999
32343
  var _tmpl$598 = /* @__PURE__ */ template(`<p style=margin:0;font-size:0.9rem>`);
32000
32344
  function AffiliateForgotPassword(props) {
@@ -32032,7 +32376,7 @@ function AffiliateForgotPassword(props) {
32032
32376
  })();
32033
32377
  },
32034
32378
  get children() {
32035
- var _el$4 = _tmpl$2155(), _el$5 = _el$4.firstChild, _el$6 = _el$5.firstChild, _el$7 = _el$6.nextSibling, _el$9 = _el$5.nextSibling;
32379
+ var _el$4 = _tmpl$2156(), _el$5 = _el$4.firstChild, _el$6 = _el$5.firstChild, _el$7 = _el$6.nextSibling, _el$9 = _el$5.nextSibling;
32036
32380
  _el$4.addEventListener("submit", handleSubmit);
32037
32381
  _el$7.$$input = (e) => setEmail(e.currentTarget.value);
32038
32382
  insert(_el$4, createComponent(Show, {
@@ -32069,7 +32413,7 @@ function AffiliateForgotPassword(props) {
32069
32413
  return props.onNavigateLogin;
32070
32414
  },
32071
32415
  get children() {
32072
- var _el$0 = _tmpl$3137();
32416
+ var _el$0 = _tmpl$3138();
32073
32417
  _el$0.$$click = () => props.onNavigateLogin?.();
32074
32418
  effect((_$p) => style(_el$0, linkStyle2(), _$p));
32075
32419
  return _el$0;
@@ -32176,8 +32520,8 @@ function linkStyle2() {
32176
32520
  }
32177
32521
  delegateEvents(["input", "click"]);
32178
32522
  var _tmpl$599 = /* @__PURE__ */ template(`<div>`);
32179
- var _tmpl$2156 = /* @__PURE__ */ template(`<form style=display:flex;flex-direction:column;gap:0.875rem><label style=display:flex;flex-direction:column;gap:0.35rem><span>New password</span></label><label style=display:flex;flex-direction:column;gap:0.35rem><span>Confirm new password</span></label><button type=submit>`);
32180
- var _tmpl$3138 = /* @__PURE__ */ template(`<div class=app-affiliate-root><div><h1>Choose a new password`);
32523
+ var _tmpl$2157 = /* @__PURE__ */ template(`<form style=display:flex;flex-direction:column;gap:0.875rem><label style=display:flex;flex-direction:column;gap:0.35rem><span>New password</span></label><label style=display:flex;flex-direction:column;gap:0.35rem><span>Confirm new password</span></label><button type=submit>`);
32524
+ var _tmpl$3139 = /* @__PURE__ */ template(`<div class=app-affiliate-root><div><h1>Choose a new password`);
32181
32525
  var _tmpl$4121 = /* @__PURE__ */ template(`<p style=margin:0;font-size:0.9rem>Your password has been reset. You can now log in with your new password.`);
32182
32526
  function queryParam3(name) {
32183
32527
  if (typeof window === "undefined") return "";
@@ -32222,7 +32566,7 @@ function AffiliateResetPassword(props) {
32222
32566
  }
32223
32567
  }
32224
32568
  return (() => {
32225
- var _el$ = _tmpl$3138(), _el$2 = _el$.firstChild, _el$3 = _el$2.firstChild;
32569
+ var _el$ = _tmpl$3139(), _el$2 = _el$.firstChild, _el$3 = _el$2.firstChild;
32226
32570
  insert(_el$2, createComponent(Show, {
32227
32571
  get when() {
32228
32572
  return !done();
@@ -32231,7 +32575,7 @@ function AffiliateResetPassword(props) {
32231
32575
  return _tmpl$4121();
32232
32576
  },
32233
32577
  get children() {
32234
- var _el$4 = _tmpl$2156(), _el$5 = _el$4.firstChild, _el$6 = _el$5.firstChild, _el$7 = _el$5.nextSibling, _el$8 = _el$7.firstChild, _el$0 = _el$7.nextSibling;
32578
+ var _el$4 = _tmpl$2157(), _el$5 = _el$4.firstChild, _el$6 = _el$5.firstChild, _el$7 = _el$5.nextSibling, _el$8 = _el$7.firstChild, _el$0 = _el$7.nextSibling;
32235
32579
  _el$4.addEventListener("submit", handleSubmit);
32236
32580
  insert(_el$5, createComponent(AffiliatePasswordInput, {
32237
32581
  required: true,
@@ -32355,5 +32699,5 @@ function primaryButtonStyle2(submitting) {
32355
32699
  }
32356
32700
 
32357
32701
  export { ADMIN_TAB_SEGMENTS, AFFILIATE_SUB_TAB_SEGMENTS, AcceptAdminInvitePage, AddressFields, AdminDashboard, AffiliateForgotPassword, AffiliateLogin, AffiliatePortal, AffiliateRegister, AffiliateResetPassword, CartCheckoutPage, CheckoutPage, EmailTemplates, ForgotPasswordPage, MemberPortal, PatientDashboardPreview, RegisterPage, ResetPasswordPage, SignupPage, SmsConsentField, SubscribePage, SurveyPage, SurveyV2Page, UpdatePaymentMethod, adminTabFromPath, adminTabPath, affiliateSubTabFromPath, affiliateSubTabPath };
32358
- //# sourceMappingURL=P6YCW73X.js.map
32359
- //# sourceMappingURL=P6YCW73X.js.map
32702
+ //# sourceMappingURL=7EOGR4UK.js.map
32703
+ //# sourceMappingURL=7EOGR4UK.js.map