@apextelemed/partner-core 0.17.0-dev.52 → 0.17.0-dev.54
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +28 -1
- package/dist/api/index.d.ts +1 -1
- package/dist/api/index.js +3 -3
- package/dist/api/index.jsx +5 -3
- package/dist/chunk/{37UEVJEC.jsx → BI7NBPCA.jsx} +30 -1
- package/dist/chunk/{IQDVS3XA.jsx → CAG35QKZ.jsx} +5 -5
- package/dist/chunk/{TLDELI22.jsx → DC24EAWT.jsx} +11 -5
- package/dist/chunk/{2HDMTWLH.js → F5PDIE2J.js} +6 -6
- package/dist/chunk/{2HDMTWLH.js.map → F5PDIE2J.js.map} +1 -1
- package/dist/chunk/{5HQAA4UO.jsx → HXBRBHFR.jsx} +2 -2
- package/dist/chunk/{BYDMO5RM.js → MQRPGAH7.js} +12 -6
- package/dist/chunk/MQRPGAH7.js.map +1 -0
- package/dist/chunk/{RDZDD5UW.js → MUNFWRXF.js} +31 -3
- package/dist/chunk/MUNFWRXF.js.map +1 -0
- package/dist/chunk/{FTZ52PMM.jsx → P3TJ6ALH.jsx} +2 -2
- package/dist/chunk/{BJXD2NQQ.jsx → Q2L3CZPR.jsx} +2 -2
- package/dist/chunk/{T37L6JE6.jsx → VUDLDIMS.jsx} +1313 -831
- package/dist/chunk/{6V7RVUXX.js → WTQ63KR4.js} +3 -3
- package/dist/chunk/{6V7RVUXX.js.map → WTQ63KR4.js.map} +1 -1
- package/dist/chunk/{FXRGPBYU.js → XDRP4X2N.js} +3 -3
- package/dist/chunk/{FXRGPBYU.js.map → XDRP4X2N.js.map} +1 -1
- package/dist/chunk/{A6FJGQIS.js → XI4OZ4SZ.js} +3 -3
- package/dist/chunk/{A6FJGQIS.js.map → XI4OZ4SZ.js.map} +1 -1
- package/dist/chunk/{O7H7DAWO.js → Z5QDFCLZ.js} +1242 -765
- package/dist/chunk/Z5QDFCLZ.js.map +1 -0
- package/dist/{client-BLh8hFAu.d.ts → client-BH1wq2Pp.d.ts} +79 -2
- package/dist/flows/index.d.ts +12 -3
- package/dist/flows/index.js +6 -6
- package/dist/flows/index.jsx +6 -6
- package/dist/index/index.d.ts +2 -2
- package/dist/index/index.js +7 -7
- package/dist/index/index.jsx +11 -7
- package/dist/pages/index.d.ts +29 -3
- package/dist/pages/index.js +5 -5
- package/dist/pages/index.jsx +7 -5
- package/dist/stores/index.d.ts +1 -1
- package/dist/stores/index.js +2 -2
- package/dist/stores/index.jsx +2 -2
- package/package.json +1 -1
- package/dist/chunk/BYDMO5RM.js.map +0 -1
- package/dist/chunk/O7H7DAWO.js.map +0 -1
- package/dist/chunk/RDZDD5UW.js.map +0 -1
package/README.md
CHANGED
|
@@ -396,7 +396,7 @@ first), `<CheckoutPage>`, `<CartCheckoutPage>`, `<SignupPage>`,
|
|
|
396
396
|
`<RegisterPage>`, `<SubscribePage>`, `<UpdatePaymentMethod>`.
|
|
397
397
|
|
|
398
398
|
**Auth** — `<ForgotPasswordPage>`, `<ResetPasswordPage>`,
|
|
399
|
-
`<AffiliateForgotPassword>`, `<AffiliateResetPassword>`.
|
|
399
|
+
`<AcceptAdminInvitePage>`, `<AffiliateForgotPassword>`, `<AffiliateResetPassword>`.
|
|
400
400
|
|
|
401
401
|
**Portals** — `<AdminDashboard>`, `<EmailTemplates>`,
|
|
402
402
|
`<PatientDashboardPreview>`, `<MemberPortal>`, `<AffiliatePortal>`,
|
|
@@ -505,6 +505,33 @@ sequence email's link arrives carrying `?fs=…`, and the first `configure()` of
|
|
|
505
505
|
the page load posts it to the backend and takes it off the address bar. Sites
|
|
506
506
|
do nothing for this beyond being on a version that has it.
|
|
507
507
|
|
|
508
|
+
#### Admin roles and the Admins tab
|
|
509
|
+
|
|
510
|
+
Each admin has a role — owner, support agent, accounting or marketing — and
|
|
511
|
+
the backend enforces what each may do. `AdminDashboard` reads it from
|
|
512
|
+
`GET /admin/me` (`adminApi.getMe()`) and offers only the tabs the role can use;
|
|
513
|
+
until it answers, only Dashboard shows. A tab a site routes to directly that
|
|
514
|
+
the role can't use renders "Not available for your role". Against a backend
|
|
515
|
+
without roles every tab shows, as before. The package's own tabs also hide an
|
|
516
|
+
action the role is known to lack (internally, `adminCan` in
|
|
517
|
+
`pages/admin/adminRoleState`).
|
|
518
|
+
|
|
519
|
+
For roles without `patient.rx.read` (accounting, marketing) the backend blanks
|
|
520
|
+
patient drug data — medications, doses, product ids, prescription statuses —
|
|
521
|
+
and marks the response `rxRedacted: true`; components reading those fields
|
|
522
|
+
must tolerate `null`.
|
|
523
|
+
|
|
524
|
+
Owners get the **Admins** tab (`admins`, under Settings): the team with a role
|
|
525
|
+
per person, pending invites, and an invite form that picks the role (marketing
|
|
526
|
+
by default). An invite emails a one-time link back to the admin page with
|
|
527
|
+
`?adminInvite=1`; `AdminDashboard` sees the flag and renders
|
|
528
|
+
`<AcceptAdminInvitePage>` instead of its sign-in gate, so sites need no new
|
|
529
|
+
route. A site that wants its own accept page passes its absolute URL as
|
|
530
|
+
`adminInviteAcceptUrl` and renders `<AcceptAdminInvitePage>` there. A tenant whose admins sign in
|
|
531
|
+
through Apex emails nothing; the tab tells the owner to invite them on Apex
|
|
532
|
+
too, and the chosen role applies at their first sign-in. A site that passes
|
|
533
|
+
`enabledTabs` has to add `'admins'` to see it.
|
|
534
|
+
|
|
508
535
|
#### Customers and the detail-view standard
|
|
509
536
|
|
|
510
537
|
The Customers tab is a customer 360: the list carries a lifecycle bucket per
|
package/dist/api/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { A as
|
|
1
|
+
export { A as ADMIN_ROLES, a as AddPharmacyBody, b as AddPharmacyDoseMatch, c as AddPharmacyDoseOption, d as AddPharmacyFinding, e as AddPharmacyMatchQuestion, f as AddPharmacyMatchSource, g as AddPharmacyPlan, h as AddPharmacyPrice, i as AddPharmacyResult, j as AddPharmacyStrengthAfter, k as AddPharmacyStrengthBefore, l as AddressVerifyResult, m as AdminApexDrug, n as AdminApexItemStatus, o as AdminBillingAttempt, p as AdminCategory, q as AdminCategoryInput, r as AdminCategoryUpdate, s as AdminCustomer, t as AdminCustomerFacts, u as AdminCustomerFunnel, v as AdminCustomerListParams, w as AdminCustomerOverview, x as AdminCustomerProfile, y as AdminCustomerRequest, z as AdminCustomerRow, B as AdminCustomerSupport, C as AdminCustomerSupportThread, D as AdminDashboardStats, E as AdminInviteResult, F as AdminLifecycle, G as AdminLifecycleBucket, H as AdminListParams, I as AdminMe, J as AdminOffer, K as AdminOfferBase, L as AdminOfferGrant, M as AdminOfferGrantBase, N as AdminOfferInput, O as AdminOrderSummary, P as AdminOrphanReason, Q as AdminOrphanedDosePrice, R as AdminPayment, S as AdminPaymentDetail, T as AdminProduct, U as AdminProductOverlayField, V as AdminProductPharmacy, W as AdminProductStrength, X as AdminPromoCode, Y as AdminPromoCodeInput, Z as AdminRecurringPricePoint, _ as AdminRecurringRevenue, $ as AdminRefundResult, a0 as AdminRole, a1 as AdminSale, a2 as AdminSaleInput, a3 as AdminScheduledRefund, a4 as AdminScheduledRefundProblem, a5 as AdminSubscription, a6 as AdminSubscriptionDetail, a7 as AdminSubscriptionPatch, a8 as AdminSubscriptionWriteResult, a9 as AdminSupportCustomer, aa as AdminSupportStats, ab as AdminSupportThread, ac as AdminTeamInvite, ad as AdminTeamMember, ae as AdminWebhookEvent, af as Affiliate, ag as AffiliateAuthTokens, ah as AffiliateClickRecord, ai as AffiliateConversion, aj as AffiliateDashboardLinks, ak as AffiliateDashboardProfile, al as AffiliateDashboardStats, am as AffiliateDownlineMember, an as AffiliateEarningsBreakdown, ao as AffiliatePaymentMethod, ap as AffiliateProgram, aq as AffiliateRegisterInput, ar as AffiliateRegisterResponse, as as AffiliateSession, at as AffiliateStatsResponse, au as AffiliateStatus, av as AffiliateTrackResponse, aw as ApiError, ax as ApiResponse, ay as AttributionMethod, az as AuthTokens, aA as BillingReminderSettings, aB as CatalogAvailabilityItem, aC as CatalogAvailabilityReason, aD as CatalogAvailabilityResult, aE as CatalogClassification, aF as CatalogConversionChoice, aG as CatalogConversionCommitResult, aH as CatalogConversionDose, aI as CatalogConversionDoseMatch, aJ as CatalogConversionFinding, aK as CatalogConversionPointers, aL as CatalogConversionPrepareResult, aM as CatalogConversionPreview, aN as CatalogConversionRun, aO as CatalogConversionSource, aP as CatalogConversionStage, aQ as CatalogConversionTarget, aR as CatalogConversionUndoOptions, aS as CatalogConversionUndoResult, aT as CatalogDose, aU as CatalogDoseInput, aV as CatalogDoseModel, aW as CatalogDoseSuggestion, aX as CatalogDoseSuggestions, aY as CatalogEquivalentSuggestions, aZ as CatalogFulfillment, a_ as CatalogFulfillmentInput, a$ as CatalogItem, b0 as CatalogItemInput, b1 as CatalogMappableDrug, b2 as CatalogMatrixCell, b3 as CatalogProduct, b4 as CatalogReadiness, b5 as CategoryMetadata, b6 as CheckoutAddress, b7 as CheckoutPayload, b8 as CheckoutResult, b9 as CommissionConfig, ba as CommissionStatus, bb as CompleteSurveyPayload, bc as CreateAffiliatePayload, bd as CreateAffiliateProgramPayload, be as CreateOrderPayload, bf as CreateRequestPayload, bg as CreateSubscriptionPayload, bh as CustomTemplate, bi as CustomTemplateInput, bj as CustomerDiscountConfig, bk as DeliveryInfo, bl as DiscountType, bm as EmailNotificationSettings, bn as EmailTemplatesMap, bo as LoginPayload, bp as MemberOffer, bq as MemberPrescriptionRequest, br as MemberSurveyMode, bs as MemberSurveyResponseSummary, bt as MemberSurveyTranscript, bu as MemberSurveyTranscriptItem, bv as MemberSurveyTranscriptSection, bw as MembersMeResponse, bx as OfferGrantState, by as Order, bz as OrderItemInput, bA as PaginationParams, bB as PaymentCallbackPayload, bC as PaymentInitiatePayload, bD as PaymentType, bE as PendingRenewalSurvey, bF as Placeholder, bG as PlaceholderKind, bH as ProductSaleSummary, bI as ProductStrengthMatches, bJ as PromoValidationResponse, bK as PublicCategory, bL as RegisterAndSubscribePayload, bM as RegisterPayload, bN as RenewalStatus, bO as SUPPORT_ATTACHMENT_MAX_BYTES, bP as SUPPORT_ATTACHMENT_MIME_TYPES, bQ as SelectDrugPayload, bR as SendMessagePayload, bS as SendToPharmacyPayload, bT as StrengthMatchBody, bU as StrengthMatchDoseOption, bV as StrengthMatchRow, bW as SubscriptionPreview, bX as SubscriptionPreviewLine, bY as SubscriptionPreviewPayload, bZ as SupportAttachment, b_ as SupportChannel, b$ as SupportChannelSettings, c0 as SupportMessage, c1 as SupportRealtimeToken, c2 as SupportThread, c3 as SupportThreadCategory, c4 as SupportThreadStatus, c5 as SurveySubmitPayload, c6 as TemplatePlaceholdersMap, c7 as TemplateText, c8 as TenantFeature, c9 as TenantFeatureAccess, ca as TokenTrackName, cb as UpdateAffiliatePayload, cc as UpdateAffiliateProgramPayload, cd as UpdatePaymentMethodPayload, ce as UpdateProfilePayload, cf as User, cg as addressesApi, ch as adminAffiliatesApi, ci as adminApi, cj as adminCatalogApi, ck as adminCatalogConversionApi, cl as adminProductPharmaciesApi, cm as adminProductStrengthMatchesApi, cn as affiliateAuthStorageKey, co as affiliatePortalApi, cp as apexApi, cq as apiFetch, cr as authApi, cs as authStorageKey, ct as catalogApi, cu as clearAffiliateTokens, cv as clearTokens, cw as getAffiliateTokens, cx as getTokens, cy as membersApi, cz as messagesApi, cA as newIdempotencyKey, cB as offersApi, cC as onTokensCleared, cD as ordersApi, cE as paymentsApi, cF as productsApi, cG as promoCodesApi, cH as setAffiliateTokens, cI as setTokens, cJ as subscriptionsApi, cK as supportApi, cL as usersApi } from '../client-BH1wq2Pp.js';
|
|
2
2
|
export { EmbedApiError as ApexV2ApiError, EmbedApiClient, EmbedApiClientOptions, EmbedApiError, EmbedEvent, EmbedEventType, FetchLike, PatientInfo, V2Answer, V2ComposedSurvey, V2DrugResult, V2QualificationResult, V2Question, V2QuestionOption, V2Section, V2Step, V2SubmitResult, V2VisibilityCondition, createEmbedApiClient, disqualificationReasonText, disqualifiedDrugIds, qualifiedDrugIds } from '@apextelemed/survey-core';
|
|
3
3
|
export { C as CartCaptureConfig, a as CartSnapshotLine, F as FunnelConfig, b as FunnelDraftPayload, R as ResumedCart, c as ResumedCartLine, d as ResumedDraft, e as adoptCartId, f as adoptFunnelSessionId, g as captureAuthHeader, h as cartId, i as fetchCartConfig, j as fetchFunnelConfig, k as fetchResumedCart, l as fetchResumedDraft, m as funnelSessionId, p as peekFunnelSessionId, n as postCartSnapshot, o as postFunnelEvent, r as readCartToken, q as readResumeToken, s as resetCartConfigCache, t as resetCartId, u as resetFunnelConfigCache, v as saveFunnelDraft, w as stripCartToken, x as stripResumeToken } from '../cart-BwUwSzWh.js';
|
|
4
4
|
|
package/dist/api/index.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import '../chunk/JSHO46VZ.js';
|
|
2
|
-
export { adoptCartId, capturePromoCode, cartId, clearPromoCode, fetchCartConfig, fetchResumedCart, postCartSnapshot, readCartToken, readPromoCode, resetCartConfigCache, resetCartId, stripCartToken } from '../chunk/
|
|
2
|
+
export { adoptCartId, capturePromoCode, cartId, clearPromoCode, fetchCartConfig, fetchResumedCart, postCartSnapshot, readCartToken, readPromoCode, resetCartConfigCache, resetCartId, stripCartToken } from '../chunk/XDRP4X2N.js';
|
|
3
3
|
export { EmbedApiError2 as ApexV2ApiError, EmbedApiError, createEmbedApiClient, disqualificationReasonText, disqualifiedDrugIds, qualifiedDrugIds } from '../chunk/LZWA44KD.js';
|
|
4
|
-
export { adoptFunnelSessionId, captureAuthHeader, fetchFunnelConfig, fetchResumedDraft, funnelSessionId, peekFunnelSessionId, postFunnelEvent, readResumeToken, resetFunnelConfigCache, saveFunnelDraft, stripResumeToken } from '../chunk/
|
|
5
|
-
export { ApiError, SUPPORT_ATTACHMENT_MAX_BYTES, SUPPORT_ATTACHMENT_MIME_TYPES, addressesApi, adminAffiliatesApi, adminApi, adminCatalogApi, adminCatalogConversionApi, adminProductPharmaciesApi, adminProductStrengthMatchesApi, affiliateAuthStorageKey, affiliatePortalApi, apexApi, apiFetch, authApi, authStorageKey, captureAffiliateRef, catalogApi, clearAffiliateRef, clearAffiliateTokens, clearTokens, getAffiliateTokens, getTokens, membersApi, messagesApi, newIdempotencyKey, offersApi, onTokensCleared, ordersApi, paymentsApi, productsApi, promoCodesApi, readAffiliateRef, setAffiliateTokens, setTokens, subscriptionsApi, supportApi, usersApi } from '../chunk/
|
|
4
|
+
export { adoptFunnelSessionId, captureAuthHeader, fetchFunnelConfig, fetchResumedDraft, funnelSessionId, peekFunnelSessionId, postFunnelEvent, readResumeToken, resetFunnelConfigCache, saveFunnelDraft, stripResumeToken } from '../chunk/WTQ63KR4.js';
|
|
5
|
+
export { ADMIN_ROLES, ApiError, SUPPORT_ATTACHMENT_MAX_BYTES, SUPPORT_ATTACHMENT_MIME_TYPES, addressesApi, adminAffiliatesApi, adminApi, adminCatalogApi, adminCatalogConversionApi, adminProductPharmaciesApi, adminProductStrengthMatchesApi, affiliateAuthStorageKey, affiliatePortalApi, apexApi, apiFetch, authApi, authStorageKey, captureAffiliateRef, catalogApi, clearAffiliateRef, clearAffiliateTokens, clearTokens, getAffiliateTokens, getTokens, membersApi, messagesApi, newIdempotencyKey, offersApi, onTokensCleared, ordersApi, paymentsApi, productsApi, promoCodesApi, readAffiliateRef, setAffiliateTokens, setTokens, subscriptionsApi, supportApi, usersApi } from '../chunk/MUNFWRXF.js';
|
|
6
6
|
import '../chunk/2IFPDU4D.js';
|
|
7
7
|
//# sourceMappingURL=index.js.map
|
|
8
8
|
//# sourceMappingURL=index.js.map
|
package/dist/api/index.jsx
CHANGED
|
@@ -12,7 +12,7 @@ import {
|
|
|
12
12
|
resetCartConfigCache,
|
|
13
13
|
resetCartId,
|
|
14
14
|
stripCartToken
|
|
15
|
-
} from "../chunk/
|
|
15
|
+
} from "../chunk/P3TJ6ALH.jsx";
|
|
16
16
|
import {
|
|
17
17
|
EmbedApiError,
|
|
18
18
|
EmbedApiError2,
|
|
@@ -33,8 +33,9 @@ import {
|
|
|
33
33
|
resetFunnelConfigCache,
|
|
34
34
|
saveFunnelDraft,
|
|
35
35
|
stripResumeToken
|
|
36
|
-
} from "../chunk/
|
|
36
|
+
} from "../chunk/HXBRBHFR.jsx";
|
|
37
37
|
import {
|
|
38
|
+
ADMIN_ROLES,
|
|
38
39
|
ApiError,
|
|
39
40
|
SUPPORT_ATTACHMENT_MAX_BYTES,
|
|
40
41
|
SUPPORT_ATTACHMENT_MIME_TYPES,
|
|
@@ -73,9 +74,10 @@ import {
|
|
|
73
74
|
subscriptionsApi,
|
|
74
75
|
supportApi,
|
|
75
76
|
usersApi
|
|
76
|
-
} from "../chunk/
|
|
77
|
+
} from "../chunk/BI7NBPCA.jsx";
|
|
77
78
|
import "../chunk/QVZ7BRNO.jsx";
|
|
78
79
|
export {
|
|
80
|
+
ADMIN_ROLES,
|
|
79
81
|
EmbedApiError2 as ApexV2ApiError,
|
|
80
82
|
ApiError,
|
|
81
83
|
EmbedApiError,
|
|
@@ -502,6 +502,10 @@ var authApi = {
|
|
|
502
502
|
},
|
|
503
503
|
resetPassword(params) {
|
|
504
504
|
return post("/auth/reset-password", params, { skipAuth: true });
|
|
505
|
+
},
|
|
506
|
+
/** Accept an emailed admin invite: sets the password and makes the account an admin. */
|
|
507
|
+
acceptAdminInvite(params) {
|
|
508
|
+
return post("/auth/admin-invite/accept", params, { skipAuth: true });
|
|
505
509
|
}
|
|
506
510
|
};
|
|
507
511
|
var apexApi = {
|
|
@@ -978,6 +982,7 @@ var adminProductStrengthMatchesApi = {
|
|
|
978
982
|
return put(strengthMatchesPath(productId), body);
|
|
979
983
|
}
|
|
980
984
|
};
|
|
985
|
+
var ADMIN_ROLES = ["owner", "support", "accounting", "marketing"];
|
|
981
986
|
var adminApi = {
|
|
982
987
|
getDashboard() {
|
|
983
988
|
return apiFetch("/admin/dashboard/stats");
|
|
@@ -1143,6 +1148,29 @@ var adminApi = {
|
|
|
1143
1148
|
saveEmailNotifications(settings) {
|
|
1144
1149
|
return put("/admin/settings/email-notifications", settings);
|
|
1145
1150
|
},
|
|
1151
|
+
// ── Admin roles and team (owners manage the team; `getMe` is open to every admin) ──
|
|
1152
|
+
getMe() {
|
|
1153
|
+
return apiFetch("/admin/me");
|
|
1154
|
+
},
|
|
1155
|
+
listAdminTeam() {
|
|
1156
|
+
return apiFetch("/admin/admins");
|
|
1157
|
+
},
|
|
1158
|
+
/** `acceptUrl` is the page that accepts the invite; the backend adds `?token=…&email=…`. */
|
|
1159
|
+
inviteAdmin(params) {
|
|
1160
|
+
return post("/admin/admins/invite", params);
|
|
1161
|
+
},
|
|
1162
|
+
setAdminRole(userId, adminRole) {
|
|
1163
|
+
return patch(`/admin/admins/${encodeURIComponent(userId)}`, { adminRole });
|
|
1164
|
+
},
|
|
1165
|
+
removeAdmin(userId) {
|
|
1166
|
+
return del(`/admin/admins/${encodeURIComponent(userId)}`);
|
|
1167
|
+
},
|
|
1168
|
+
updateAdminInvite(inviteId, adminRole) {
|
|
1169
|
+
return patch(`/admin/admins/invites/${encodeURIComponent(inviteId)}`, { adminRole });
|
|
1170
|
+
},
|
|
1171
|
+
cancelAdminInvite(inviteId) {
|
|
1172
|
+
return del(`/admin/admins/invites/${encodeURIComponent(inviteId)}`);
|
|
1173
|
+
},
|
|
1146
1174
|
getSupportChannel() {
|
|
1147
1175
|
return apiFetch("/admin/settings/support-channel");
|
|
1148
1176
|
},
|
|
@@ -1568,6 +1596,7 @@ export {
|
|
|
1568
1596
|
adminCatalogConversionApi,
|
|
1569
1597
|
adminProductPharmaciesApi,
|
|
1570
1598
|
adminProductStrengthMatchesApi,
|
|
1599
|
+
ADMIN_ROLES,
|
|
1571
1600
|
adminApi,
|
|
1572
1601
|
adminAffiliatesApi,
|
|
1573
1602
|
affiliateAuthStorageKey,
|
|
@@ -1576,4 +1605,4 @@ export {
|
|
|
1576
1605
|
clearAffiliateTokens,
|
|
1577
1606
|
affiliatePortalApi
|
|
1578
1607
|
};
|
|
1579
|
-
//# sourceMappingURL=
|
|
1608
|
+
//# sourceMappingURL=BI7NBPCA.jsx.map
|
|
@@ -8,7 +8,7 @@ import {
|
|
|
8
8
|
readPromoCode,
|
|
9
9
|
resetCartId,
|
|
10
10
|
stripCartToken
|
|
11
|
-
} from "./
|
|
11
|
+
} from "./P3TJ6ALH.jsx";
|
|
12
12
|
import {
|
|
13
13
|
bestOfferDiscount,
|
|
14
14
|
catalogUnavailableMessage,
|
|
@@ -22,11 +22,11 @@ import {
|
|
|
22
22
|
useCardTokenizer,
|
|
23
23
|
useCatalogAvailability,
|
|
24
24
|
validateAddress
|
|
25
|
-
} from "./
|
|
25
|
+
} from "./DC24EAWT.jsx";
|
|
26
26
|
import {
|
|
27
27
|
auth_default,
|
|
28
28
|
cart_default
|
|
29
|
-
} from "./
|
|
29
|
+
} from "./Q2L3CZPR.jsx";
|
|
30
30
|
import {
|
|
31
31
|
ApiError,
|
|
32
32
|
newIdempotencyKey,
|
|
@@ -34,7 +34,7 @@ import {
|
|
|
34
34
|
promoCodesApi,
|
|
35
35
|
subscriptionsApi,
|
|
36
36
|
usersApi
|
|
37
|
-
} from "./
|
|
37
|
+
} from "./BI7NBPCA.jsx";
|
|
38
38
|
import {
|
|
39
39
|
getConfig
|
|
40
40
|
} from "./QVZ7BRNO.jsx";
|
|
@@ -648,4 +648,4 @@ export {
|
|
|
648
648
|
restoreCartFromLink,
|
|
649
649
|
startCartCapture
|
|
650
650
|
};
|
|
651
|
-
//# sourceMappingURL=
|
|
651
|
+
//# sourceMappingURL=CAG35QKZ.jsx.map
|
|
@@ -6,13 +6,13 @@ import {
|
|
|
6
6
|
readResumeToken,
|
|
7
7
|
saveFunnelDraft,
|
|
8
8
|
stripResumeToken
|
|
9
|
-
} from "./
|
|
9
|
+
} from "./HXBRBHFR.jsx";
|
|
10
10
|
import {
|
|
11
11
|
affiliateAuth_default,
|
|
12
12
|
auth_default,
|
|
13
13
|
cart_default,
|
|
14
14
|
medication_default
|
|
15
|
-
} from "./
|
|
15
|
+
} from "./Q2L3CZPR.jsx";
|
|
16
16
|
import {
|
|
17
17
|
ApiError,
|
|
18
18
|
addressesApi,
|
|
@@ -34,7 +34,7 @@ import {
|
|
|
34
34
|
subscriptionsApi,
|
|
35
35
|
supportApi,
|
|
36
36
|
usersApi
|
|
37
|
-
} from "./
|
|
37
|
+
} from "./BI7NBPCA.jsx";
|
|
38
38
|
import {
|
|
39
39
|
getConfig
|
|
40
40
|
} from "./QVZ7BRNO.jsx";
|
|
@@ -6374,7 +6374,7 @@ function useAddPharmacy(opts) {
|
|
|
6374
6374
|
// src/flows/strengthMatches.ts
|
|
6375
6375
|
import { createEffect as createEffect11, createMemo as createMemo4, createSignal as createSignal16, on as on5, onCleanup as onCleanup6 } from "solid-js";
|
|
6376
6376
|
function wantsStrengthMatches(product, enabled) {
|
|
6377
|
-
return enabled && !!product
|
|
6377
|
+
return enabled && !!product;
|
|
6378
6378
|
}
|
|
6379
6379
|
function matchBody(dosage, doseId, carryPrice) {
|
|
6380
6380
|
return { dosage, doseId, ...carryPrice === void 0 ? {} : { carryPrice } };
|
|
@@ -6382,6 +6382,7 @@ function matchBody(dosage, doseId, carryPrice) {
|
|
|
6382
6382
|
var matchValue = (row) => row.doseId ?? "";
|
|
6383
6383
|
var doseIdOf = (value) => value === "" ? null : value;
|
|
6384
6384
|
var isLeftForReview = (row) => row.doseId === null;
|
|
6385
|
+
var isFlatFee = (raw) => raw?.flatFee === true;
|
|
6385
6386
|
function normalizeMatches(raw) {
|
|
6386
6387
|
return {
|
|
6387
6388
|
rows: Array.isArray(raw?.rows) ? raw.rows : [],
|
|
@@ -6417,6 +6418,7 @@ function classifyStrengthMatchError(err, doseId) {
|
|
|
6417
6418
|
}
|
|
6418
6419
|
function useStrengthMatches(opts) {
|
|
6419
6420
|
const [status, setStatus] = createSignal16("idle");
|
|
6421
|
+
const [flatFee, setFlatFee] = createSignal16(false);
|
|
6420
6422
|
const [rows, setRows] = createSignal16([]);
|
|
6421
6423
|
const [doseOptions, setDoseOptions] = createSignal16([]);
|
|
6422
6424
|
const [pending, setPending] = createSignal16(null);
|
|
@@ -6438,6 +6440,7 @@ function useStrengthMatches(opts) {
|
|
|
6438
6440
|
});
|
|
6439
6441
|
const adopt = (raw) => {
|
|
6440
6442
|
const next = normalizeMatches(raw);
|
|
6443
|
+
setFlatFee(isFlatFee(raw));
|
|
6441
6444
|
setRows(next.rows);
|
|
6442
6445
|
setDoseOptions(next.doseOptions);
|
|
6443
6446
|
const p = pending();
|
|
@@ -6450,6 +6453,7 @@ function useStrengthMatches(opts) {
|
|
|
6450
6453
|
const seq = ++loadSeq;
|
|
6451
6454
|
const product = opts.product();
|
|
6452
6455
|
if (!wantsStrengthMatches(product, opts.enabled())) {
|
|
6456
|
+
setFlatFee(false);
|
|
6453
6457
|
setRows([]);
|
|
6454
6458
|
setDoseOptions([]);
|
|
6455
6459
|
setStatus("idle");
|
|
@@ -6484,6 +6488,7 @@ function useStrengthMatches(opts) {
|
|
|
6484
6488
|
on5(key, () => {
|
|
6485
6489
|
generation++;
|
|
6486
6490
|
loadSeq++;
|
|
6491
|
+
setFlatFee(false);
|
|
6487
6492
|
setRows([]);
|
|
6488
6493
|
setDoseOptions([]);
|
|
6489
6494
|
setPending(null);
|
|
@@ -6542,6 +6547,7 @@ function useStrengthMatches(opts) {
|
|
|
6542
6547
|
};
|
|
6543
6548
|
return {
|
|
6544
6549
|
status,
|
|
6550
|
+
flatFee,
|
|
6545
6551
|
rows,
|
|
6546
6552
|
doseOptions,
|
|
6547
6553
|
pending,
|
|
@@ -6729,4 +6735,4 @@ export {
|
|
|
6729
6735
|
classifyStrengthMatchError,
|
|
6730
6736
|
useStrengthMatches
|
|
6731
6737
|
};
|
|
6732
|
-
//# sourceMappingURL=
|
|
6738
|
+
//# sourceMappingURL=DC24EAWT.jsx.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { readPromoCode, clearPromoCode, readCartToken, fetchResumedCart, stripCartToken, adoptCartId, fetchCartConfig, postCartSnapshot, resetCartId } from './
|
|
2
|
-
import { useCardTokenizer, useAddressPair, useCatalogAvailability, isLive, formatCvv, formatExpiry, formatCardNumber, bestOfferDiscount, offerBeatsPromo, catalogUnavailableMessage, firstAddressError, validateAddress } from './
|
|
3
|
-
import { auth_default, cart_default } from './
|
|
4
|
-
import { promoCodesApi, subscriptionsApi, offersApi, newIdempotencyKey, usersApi, ApiError } from './
|
|
1
|
+
import { readPromoCode, clearPromoCode, readCartToken, fetchResumedCart, stripCartToken, adoptCartId, fetchCartConfig, postCartSnapshot, resetCartId } from './XDRP4X2N.js';
|
|
2
|
+
import { useCardTokenizer, useAddressPair, useCatalogAvailability, isLive, formatCvv, formatExpiry, formatCardNumber, bestOfferDiscount, offerBeatsPromo, catalogUnavailableMessage, firstAddressError, validateAddress } from './MQRPGAH7.js';
|
|
3
|
+
import { auth_default, cart_default } from './XI4OZ4SZ.js';
|
|
4
|
+
import { promoCodesApi, subscriptionsApi, offersApi, newIdempotencyKey, usersApi, ApiError } from './MUNFWRXF.js';
|
|
5
5
|
import { getConfig } from './2IFPDU4D.js';
|
|
6
6
|
import { createSignal, onMount, createEffect, on, createRoot } from 'solid-js';
|
|
7
7
|
|
|
@@ -603,5 +603,5 @@ function startCartCapture(opts = {}) {
|
|
|
603
603
|
}
|
|
604
604
|
|
|
605
605
|
export { OFFER_BEATS_PROMO_NOTICE, restoreCartFromLink, startCartCapture, useSubscriptionIntakeFlow, validateResumedPromo };
|
|
606
|
-
//# sourceMappingURL=
|
|
607
|
-
//# sourceMappingURL=
|
|
606
|
+
//# sourceMappingURL=F5PDIE2J.js.map
|
|
607
|
+
//# sourceMappingURL=F5PDIE2J.js.map
|