randmarcomps 1.576.0 → 1.577.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/randmarcomps.d.ts +1 -1
- package/dist/randmarcomps.js +19 -49
- package/dist/randmarcomps.umd.cjs +4 -4
- package/package.json +1 -1
package/dist/randmarcomps.d.ts
CHANGED
|
@@ -722,7 +722,7 @@ export declare interface PartnerActionsProps {
|
|
|
722
722
|
isAdmin: boolean;
|
|
723
723
|
}
|
|
724
724
|
|
|
725
|
-
export declare function PartnerCard({ account, action, loading, className, withAbout
|
|
725
|
+
export declare function PartnerCard({ account, action, loading, className, withAbout }: PartnerCardProps): JSX.Element;
|
|
726
726
|
|
|
727
727
|
declare interface PartnerCardProps {
|
|
728
728
|
account?: AccountWithShopifyStore;
|
package/dist/randmarcomps.js
CHANGED
|
@@ -62647,7 +62647,6 @@ function PartnerRelationshipPage({
|
|
|
62647
62647
|
account: l,
|
|
62648
62648
|
loading: c || d,
|
|
62649
62649
|
withAbout: !0,
|
|
62650
|
-
withVoice: !1,
|
|
62651
62650
|
action: " "
|
|
62652
62651
|
}
|
|
62653
62652
|
),
|
|
@@ -66617,14 +66616,13 @@ function PartnerCard({
|
|
|
66617
66616
|
action: t,
|
|
66618
66617
|
loading: n = !1,
|
|
66619
66618
|
className: a,
|
|
66620
|
-
withAbout: s = !1
|
|
66621
|
-
withVoice: o = !0
|
|
66619
|
+
withAbout: s = !1
|
|
66622
66620
|
}) {
|
|
66623
|
-
const [
|
|
66624
|
-
{ applicationId:
|
|
66625
|
-
{ skip: !
|
|
66626
|
-
),
|
|
66627
|
-
|
|
66621
|
+
const [o, l] = useState(!0), [c, d] = useState(!1), f = e?.ApplicationId, S = f ? `https://api.randmar.io/V4/Partner/${f}/Account/Video` : null, { data: A } = useGetV4PartnerByApplicationIdAccountVideoExistsQuery(
|
|
66622
|
+
{ applicationId: f ?? "" },
|
|
66623
|
+
{ skip: !f || n }
|
|
66624
|
+
), R = typeof A == "boolean" ? A : typeof A == "string" ? A.toLowerCase() === "true" : !1, V = () => {
|
|
66625
|
+
l(!1);
|
|
66628
66626
|
};
|
|
66629
66627
|
return n || !e ? /* @__PURE__ */ jsxs(Card, { className: `flex flex-col h-full ${a}`, children: [
|
|
66630
66628
|
/* @__PURE__ */ jsx(CardHeader, { className: "flex flex-row items-start justify-between space-y-0 pb-2 pt-4", children: /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-3", children: [
|
|
@@ -66647,21 +66645,7 @@ function PartnerCard({
|
|
|
66647
66645
|
/* @__PURE__ */ jsx(Skeleton, { className: "h-5 w-full" }),
|
|
66648
66646
|
/* @__PURE__ */ jsx(Skeleton, { className: "h-5 w-full" }),
|
|
66649
66647
|
/* @__PURE__ */ jsx(Skeleton, { className: "h-5 w-full" })
|
|
66650
|
-
] })
|
|
66651
|
-
o && /* @__PURE__ */ jsx("div", { className: "p-3 bg-slate-50 rounded-md", children: /* @__PURE__ */ jsxs("div", { className: "grid grid-cols-1 @lg:grid-cols-3 gap-2", children: [
|
|
66652
|
-
/* @__PURE__ */ jsxs("div", { children: [
|
|
66653
|
-
/* @__PURE__ */ jsx(Skeleton, { className: "h-3 w-20 mb-1" }),
|
|
66654
|
-
/* @__PURE__ */ jsx(Skeleton, { className: "h-5 w-24" })
|
|
66655
|
-
] }),
|
|
66656
|
-
/* @__PURE__ */ jsxs("div", { children: [
|
|
66657
|
-
/* @__PURE__ */ jsx(Skeleton, { className: "h-3 w-20 mb-1" }),
|
|
66658
|
-
/* @__PURE__ */ jsx(Skeleton, { className: "h-5 w-24" })
|
|
66659
|
-
] }),
|
|
66660
|
-
/* @__PURE__ */ jsxs("div", { children: [
|
|
66661
|
-
/* @__PURE__ */ jsx(Skeleton, { className: "h-3 w-20 mb-1" }),
|
|
66662
|
-
/* @__PURE__ */ jsx(Skeleton, { className: "h-5 w-24" })
|
|
66663
|
-
] })
|
|
66664
|
-
] }) })
|
|
66648
|
+
] })
|
|
66665
66649
|
] }) }),
|
|
66666
66650
|
/* @__PURE__ */ jsxs(CardFooter, { className: "px-6 py-4 flex justify-between gap-2 mt-auto", children: [
|
|
66667
66651
|
/* @__PURE__ */ jsx(Skeleton, { className: "h-9 w-32" }),
|
|
@@ -66697,29 +66681,15 @@ function PartnerCard({
|
|
|
66697
66681
|
className: "prose prose-sm max-w-none",
|
|
66698
66682
|
dangerouslySetInnerHTML: { __html: e.About ?? "" }
|
|
66699
66683
|
}
|
|
66700
|
-
)
|
|
66701
|
-
o && /* @__PURE__ */ jsx("div", { className: "p-3 bg-slate-50 rounded-md", children: /* @__PURE__ */ jsxs("div", { className: "grid grid-cols-1 @lg:grid-cols-3 gap-2", children: [
|
|
66702
|
-
/* @__PURE__ */ jsxs("div", { children: [
|
|
66703
|
-
/* @__PURE__ */ jsx("div", { className: "text-sm text-muted-foreground", children: "Voice Name" }),
|
|
66704
|
-
/* @__PURE__ */ jsx("div", { className: "font-medium", children: e.VoiceName ?? "Regular" })
|
|
66705
|
-
] }),
|
|
66706
|
-
/* @__PURE__ */ jsxs("div", { children: [
|
|
66707
|
-
/* @__PURE__ */ jsx("div", { className: "text-sm text-muted-foreground", children: "Voice Style" }),
|
|
66708
|
-
/* @__PURE__ */ jsx("div", { className: "font-medium", children: e.VoiceStyle ?? "Regular" })
|
|
66709
|
-
] }),
|
|
66710
|
-
/* @__PURE__ */ jsxs("div", { children: [
|
|
66711
|
-
/* @__PURE__ */ jsx("div", { className: "text-sm text-muted-foreground", children: "Scene Name" }),
|
|
66712
|
-
/* @__PURE__ */ jsx("div", { className: "font-medium", children: e.SceneName ?? "N/A" })
|
|
66713
|
-
] })
|
|
66714
|
-
] }) })
|
|
66684
|
+
)
|
|
66715
66685
|
] }) }),
|
|
66716
66686
|
/* @__PURE__ */ jsxs(CardFooter, { className: "px-6 py-4 flex justify-between gap-2 mt-auto", children: [
|
|
66717
|
-
|
|
66687
|
+
R && S ? /* @__PURE__ */ jsxs(
|
|
66718
66688
|
Dialog,
|
|
66719
66689
|
{
|
|
66720
|
-
open:
|
|
66721
|
-
onOpenChange: (
|
|
66722
|
-
|
|
66690
|
+
open: c,
|
|
66691
|
+
onOpenChange: (at) => {
|
|
66692
|
+
d(at), at && l(!0);
|
|
66723
66693
|
},
|
|
66724
66694
|
children: [
|
|
66725
66695
|
/* @__PURE__ */ jsx(DialogTrigger, { asChild: !0, children: /* @__PURE__ */ jsxs(Button$1, { variant: "outline", className: "flex items-center gap-2", children: [
|
|
@@ -66732,19 +66702,19 @@ function PartnerCard({
|
|
|
66732
66702
|
" Video"
|
|
66733
66703
|
] }) }),
|
|
66734
66704
|
/* @__PURE__ */ jsxs("div", { className: "w-full h-[640px] rounded-md overflow-hidden", children: [
|
|
66735
|
-
|
|
66705
|
+
o && /* @__PURE__ */ jsx(Skeleton, { className: "w-full h-full" }),
|
|
66736
66706
|
/* @__PURE__ */ jsx(
|
|
66737
66707
|
"video",
|
|
66738
66708
|
{
|
|
66739
|
-
src:
|
|
66709
|
+
src: S,
|
|
66740
66710
|
controls: !0,
|
|
66741
66711
|
preload: "auto",
|
|
66742
66712
|
playsInline: !0,
|
|
66743
66713
|
autoPlay: !0,
|
|
66744
66714
|
"aria-label": `Video for ${e.PublicName}`,
|
|
66745
|
-
className: `w-full h-full object-cover object-center ${
|
|
66746
|
-
onLoadedData:
|
|
66747
|
-
onError: () =>
|
|
66715
|
+
className: `w-full h-full object-cover object-center ${o ? "invisible" : "visible"}`,
|
|
66716
|
+
onLoadedData: V,
|
|
66717
|
+
onError: () => l(!1)
|
|
66748
66718
|
}
|
|
66749
66719
|
)
|
|
66750
66720
|
] })
|
|
@@ -74043,7 +74013,7 @@ function ProductCard({
|
|
|
74043
74013
|
const complexComponents = [
|
|
74044
74014
|
`----
|
|
74045
74015
|
PartnerCard: For data that fits this shape:
|
|
74046
|
-
{ "ApplicationId": "19022", "PublicName": "BiOSS", "
|
|
74016
|
+
{ "ApplicationId": "19022", "PublicName": "BiOSS", "About": "example", "IsReseller": true, "IsManufacturer": true, "IsSalesAgency": false, "Socials": [ { "ApplicationId": "19022", "SocialNetwork": "Facebook", "Tag": "@bioss.ca" }, { "ApplicationId": "19022", "SocialNetwork": "Instagram", "Tag": "@bioss.ca" }, { "ApplicationId": "19022", "SocialNetwork": "LinkedIn", "Tag": "@biossinc" }, { "ApplicationId": "19022", "SocialNetwork": "Youtube", "Tag": "@biosssolutionssanitairessa4095" } ], "Manufacturer": null, "Reseller": null }
|
|
74047
74017
|
Use <PartnerCard account={data} action={<></>}>`,
|
|
74048
74018
|
`----
|
|
74049
74019
|
ManufacturerCard: For data that fits this shape:
|
|
@@ -74055,7 +74025,7 @@ const complexComponents = [
|
|
|
74055
74025
|
Use <ResellerCard reseller={data}>`,
|
|
74056
74026
|
`----
|
|
74057
74027
|
Sometimes, manufacturer and reseller data can be embed into a partner object: For example, for data that fits this shape:
|
|
74058
|
-
{ "ApplicationId": "19022", "PublicName": "BiOSS", "
|
|
74028
|
+
{ "ApplicationId": "19022", "PublicName": "BiOSS", "About": "example", "IsReseller": true, "IsManufacturer": true, "IsSalesAgency": false, "Socials": [ { "ApplicationId": "19022", "SocialNetwork": "Facebook", "Tag": "@bioss.ca" }, { "ApplicationId": "19022", "SocialNetwork": "Instagram", "Tag": "@bioss.ca" }, { "ApplicationId": "19022", "SocialNetwork": "LinkedIn", "Tag": "@biossinc" }, { "ApplicationId": "19022", "SocialNetwork": "Youtube", "Tag": "@biosssolutionssanitairessa4095" } ], "Manufacturer": { "ManufacturerId": "19022", "Website": "https://www.example.ca", "PublicName": "BiOSS", "LastUpdatedDate": 20241217, "AutoReorderDate": -1, "AutoUpdate": false, "PublicEmail": "example@example.ca", "DefaultWeeksOfStocking": 4, "Tags": "Health & Cleaning", "CreationDate": 20220127, "PartnerPortal": "", "PartnerRegistrationLink": "", "About": "example...", "OpenToWork": false, "PublicResourcesLink": "https://drive.google.com/drive/folders/example", "CurrencyCode": "CAD", "YoutubePlaylist": "null" }, "Reseller": null }
|
|
74059
74029
|
Use both <PartnerCard account={data} action={<></>}> and <ManufacturerCard manufacturer={data.Manufacturer}>`,
|
|
74060
74030
|
`----
|
|
74061
74031
|
ProductCard, for data that fits this shape:
|