@iit/precision-ui 0.5.5 → 0.7.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/Adapters.d.ts +1 -0
- package/dist/Adapters.d.ts.map +1 -1
- package/dist/components/ArticlePreviewTag.d.ts +11 -0
- package/dist/components/ArticlePreviewTag.d.ts.map +1 -0
- package/dist/components/GridIterator.d.ts +3 -2
- package/dist/components/GridIterator.d.ts.map +1 -1
- package/dist/components/cards/AdvantageWithAccordion.d.ts +12 -0
- package/dist/components/cards/AdvantageWithAccordion.d.ts.map +1 -0
- package/dist/components/cards/Connect.d.ts +19 -0
- package/dist/components/cards/Connect.d.ts.map +1 -0
- package/dist/components/cards/Doc.d.ts +11 -0
- package/dist/components/cards/Doc.d.ts.map +1 -0
- package/dist/components/cards/FAQ.d.ts +14 -0
- package/dist/components/cards/FAQ.d.ts.map +1 -0
- package/dist/components/cards/FeaturedCard.d.ts +1 -1
- package/dist/components/cards/FeaturedCard.d.ts.map +1 -1
- package/dist/components/cards/License.d.ts +10 -0
- package/dist/components/cards/License.d.ts.map +1 -0
- package/dist/components/cards/Package.d.ts +28 -0
- package/dist/components/cards/Package.d.ts.map +1 -0
- package/dist/components/pieces/ShowMoreAccordionTrigger.d.ts +8 -0
- package/dist/components/pieces/ShowMoreAccordionTrigger.d.ts.map +1 -0
- package/dist/components/ui/Link.d.ts +1 -1
- package/dist/components/ui/Link.d.ts.map +1 -1
- package/dist/components/ui/TagLink.d.ts +14 -0
- package/dist/components/ui/TagLink.d.ts.map +1 -0
- package/dist/components/ui/accordion.d.ts +15 -0
- package/dist/components/ui/accordion.d.ts.map +1 -0
- package/dist/components/ui/button/ButtonText.d.ts +1 -0
- package/dist/components/ui/button/ButtonText.d.ts.map +1 -1
- package/dist/components/ui/carousel.d.ts +5 -1
- package/dist/components/ui/carousel.d.ts.map +1 -1
- package/dist/components/ui/input/SearchInput.d.ts +1 -0
- package/dist/components/ui/input/SearchInput.d.ts.map +1 -1
- package/dist/components/ui/tabs.d.ts +8 -0
- package/dist/components/ui/tabs.d.ts.map +1 -0
- package/dist/decorators/CarouselWrapper.d.ts +3 -2
- package/dist/decorators/CarouselWrapper.d.ts.map +1 -1
- package/dist/icons/comet.svg +5 -0
- package/dist/index.d.ts +23 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.es.js +105 -63
- package/dist/index.es.js.map +1 -1
- package/dist/index.es10.js +1 -1
- package/dist/index.es11.js +1 -1
- package/dist/index.es13.js +1 -1
- package/dist/index.es15.js +1 -1
- package/dist/index.es16.js +2 -2
- package/dist/index.es18.js +1 -1
- package/dist/index.es19.js +1 -1
- package/dist/index.es2.js +1 -1
- package/dist/index.es20.js +1 -1
- package/dist/index.es21.js +14 -23
- package/dist/index.es21.js.map +1 -1
- package/dist/index.es22.js +36 -173
- package/dist/index.es22.js.map +1 -1
- package/dist/index.es23.js +31 -46
- package/dist/index.es23.js.map +1 -1
- package/dist/index.es24.js +48 -52
- package/dist/index.es24.js.map +1 -1
- package/dist/index.es25.js +14 -61
- package/dist/index.es25.js.map +1 -1
- package/dist/index.es26.js +6 -20
- package/dist/index.es26.js.map +1 -1
- package/dist/index.es27.js +52 -18
- package/dist/index.es27.js.map +1 -1
- package/dist/index.es28.js +27 -91
- package/dist/index.es28.js.map +1 -1
- package/dist/index.es29.js +88 -81
- package/dist/index.es29.js.map +1 -1
- package/dist/index.es3.js +2 -2
- package/dist/index.es30.js +54 -31
- package/dist/index.es30.js.map +1 -1
- package/dist/index.es31.js +92 -6
- package/dist/index.es31.js.map +1 -1
- package/dist/index.es32.js +97 -21
- package/dist/index.es32.js.map +1 -1
- package/dist/index.es33.js +12 -19
- package/dist/index.es33.js.map +1 -1
- package/dist/index.es34.js +43 -18
- package/dist/index.es34.js.map +1 -1
- package/dist/index.es35.js +23 -10
- package/dist/index.es35.js.map +1 -1
- package/dist/index.es36.js +26 -83
- package/dist/index.es36.js.map +1 -1
- package/dist/index.es37.js +207 -16
- package/dist/index.es37.js.map +1 -1
- package/dist/index.es38.js +47 -41
- package/dist/index.es38.js.map +1 -1
- package/dist/index.es39.js +53 -40
- package/dist/index.es39.js.map +1 -1
- package/dist/index.es4.js +1 -1
- package/dist/index.es40.js +59 -35
- package/dist/index.es40.js.map +1 -1
- package/dist/index.es41.js +18 -54
- package/dist/index.es41.js.map +1 -1
- package/dist/index.es42.js +17 -90
- package/dist/index.es42.js.map +1 -1
- package/dist/index.es43.js +88 -95
- package/dist/index.es43.js.map +1 -1
- package/dist/index.es44.js +88 -25
- package/dist/index.es44.js.map +1 -1
- package/dist/index.es45.js +33 -45
- package/dist/index.es45.js.map +1 -1
- package/dist/index.es46.js +75 -14
- package/dist/index.es46.js.map +1 -1
- package/dist/index.es47.js +39 -212
- package/dist/index.es47.js.map +1 -1
- package/dist/index.es48.js +10 -3
- package/dist/index.es48.js.map +1 -1
- package/dist/index.es49.js +9 -0
- package/dist/index.es49.js.map +1 -0
- package/dist/index.es5.js +1 -1
- package/dist/index.es50.js +25 -0
- package/dist/index.es50.js.map +1 -0
- package/dist/index.es51.js +23 -0
- package/dist/index.es51.js.map +1 -0
- package/dist/index.es52.js +23 -0
- package/dist/index.es52.js.map +1 -0
- package/dist/index.es53.js +88 -0
- package/dist/index.es53.js.map +1 -0
- package/dist/index.es54.js +42 -0
- package/dist/index.es54.js.map +1 -0
- package/dist/index.es55.js +30 -0
- package/dist/index.es55.js.map +1 -0
- package/dist/index.es56.js +19 -0
- package/dist/index.es56.js.map +1 -0
- package/dist/index.es57.js +50 -0
- package/dist/index.es57.js.map +1 -0
- package/dist/index.es58.js +7 -0
- package/dist/index.es58.js.map +1 -0
- package/dist/index.es59.js +245 -0
- package/dist/index.es59.js.map +1 -0
- package/dist/index.es6.js +36 -31
- package/dist/index.es6.js.map +1 -1
- package/dist/index.es7.js +1 -1
- package/dist/index.es8.js +11 -10
- package/dist/index.es8.js.map +1 -1
- package/dist/index.es9.js.map +1 -1
- package/dist/sections/CardsGridSection.d.ts +2 -2
- package/dist/sections/Hero.d.ts +2 -0
- package/dist/sections/Hero.d.ts.map +1 -1
- package/dist/styles.css +336 -15
- package/package.json +5 -3
package/dist/index.es40.js
CHANGED
|
@@ -1,40 +1,64 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
1
|
+
import G from "./index.es39.js";
|
|
2
|
+
import e from "./index.es21.js";
|
|
3
|
+
import S from "./index.es22.js";
|
|
4
|
+
import I from "./index.es27.js";
|
|
5
|
+
import P from "./index.es54.js";
|
|
6
|
+
import R from "./index.es30.js";
|
|
7
|
+
import _ from "./index.es31.js";
|
|
8
|
+
import k from "./index.es32.js";
|
|
9
|
+
import t from "react";
|
|
10
|
+
const x = {
|
|
11
|
+
Advantage: e,
|
|
12
|
+
Advantage2: S,
|
|
13
|
+
Rate: k,
|
|
14
|
+
Product: _,
|
|
15
|
+
FeaturedCard: I,
|
|
16
|
+
Plate: R
|
|
17
|
+
}, y = ({
|
|
18
|
+
title: r,
|
|
19
|
+
sectionId: o,
|
|
20
|
+
desc: a,
|
|
21
|
+
items: m,
|
|
22
|
+
component: n = "Advantage",
|
|
23
|
+
withoutTopPadding: f = !1,
|
|
24
|
+
withTopMargin: i = !1,
|
|
25
|
+
withBottomMargin: d = !1,
|
|
26
|
+
withoutBottomPadding: c = !1,
|
|
27
|
+
variant: p,
|
|
28
|
+
corners: s,
|
|
29
|
+
columns: l,
|
|
30
|
+
hideControlsOnDesktop: u,
|
|
31
|
+
withoutCarousel: C,
|
|
32
|
+
footnote: g
|
|
12
33
|
}) => {
|
|
13
|
-
const
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
return "grid grid-cols-1 gap-3";
|
|
17
|
-
case 2:
|
|
18
|
-
return "grid grid-cols-1 sm:grid-cols-2 gap-3";
|
|
19
|
-
case 3:
|
|
20
|
-
return "grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 gap-3";
|
|
21
|
-
case 4:
|
|
22
|
-
return "grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 xl:grid-cols-4 gap-3";
|
|
23
|
-
default:
|
|
24
|
-
return "grid grid-cols-1 gap-3";
|
|
25
|
-
}
|
|
26
|
-
};
|
|
27
|
-
return /* @__PURE__ */ r.createElement("div", null, g ? /* @__PURE__ */ r.createElement("div", { className: i(s) }, t.map((e, a) => /* @__PURE__ */ r.createElement(r.Fragment, { key: a }, l(e, a)))) : /* @__PURE__ */ r.createElement(
|
|
28
|
-
m,
|
|
34
|
+
const v = x[n] || e;
|
|
35
|
+
return /* @__PURE__ */ t.createElement(
|
|
36
|
+
G,
|
|
29
37
|
{
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
38
|
+
title: r,
|
|
39
|
+
sectionId: o,
|
|
40
|
+
desc: a,
|
|
41
|
+
variant: p,
|
|
42
|
+
corners: s,
|
|
43
|
+
withoutTopPadding: f,
|
|
44
|
+
withTopMargin: i,
|
|
45
|
+
withBottomMargin: d,
|
|
46
|
+
withoutBottomPadding: c
|
|
47
|
+
},
|
|
48
|
+
/* @__PURE__ */ t.createElement(
|
|
49
|
+
P,
|
|
50
|
+
{
|
|
51
|
+
items: m,
|
|
52
|
+
columns: l,
|
|
53
|
+
hideControlsOnDesktop: u,
|
|
54
|
+
withoutCarousel: C,
|
|
55
|
+
renderItem: (A, E) => /* @__PURE__ */ t.createElement(v, { key: E, ...A }),
|
|
56
|
+
footnote: g
|
|
57
|
+
}
|
|
58
|
+
)
|
|
59
|
+
);
|
|
60
|
+
}, B = y;
|
|
37
61
|
export {
|
|
38
|
-
|
|
62
|
+
B as default
|
|
39
63
|
};
|
|
40
64
|
//# sourceMappingURL=index.es40.js.map
|
package/dist/index.es40.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.es40.js","sources":["../src/
|
|
1
|
+
{"version":3,"file":"index.es40.js","sources":["../src/sections/CardsGridSection.tsx"],"sourcesContent":["import Section, { SectionProps } from './Section'\r\n\r\nimport Advantage from '@/components/cards/Advantage'\r\nimport Advantage2 from '@/components/cards/Advantage2'\r\nimport FeaturedCard from '@/components/cards/FeaturedCard'\r\nimport GridIterator from '@/components/GridIterator'\r\nimport Plate from '@/components/cards/Plate'\r\nimport Product from '@/components/cards/Product'\r\nimport Rate from '@/components/cards/Rate'\r\nimport React from 'react'\r\n\r\n// Map component names to actual components\r\nconst componentMap: { [key: string]: React.ElementType } = {\r\n Advantage,\r\n Advantage2,\r\n Rate,\r\n Product,\r\n FeaturedCard,\r\n Plate,\r\n}\r\n\r\ninterface CardsGridSectionProps<T> {\r\n title: string\r\n sectionId?: string\r\n desc?: string\r\n items: T[]\r\n component?: string\r\n withoutTopPadding?: boolean\r\n withoutBottomPadding?: boolean\r\n withTopMargin?: boolean\r\n withBottomMargin?: boolean\r\n variant?: SectionProps['variant']\r\n corners?: SectionProps['corners']\r\n columns?: number\r\n hideControlsOnDesktop?: boolean\r\n withoutCarousel?: boolean\r\n footnote?: string\r\n}\r\n\r\nconst CardsGridSection = <T,>({\r\n title,\r\n sectionId,\r\n desc,\r\n items,\r\n component = 'Advantage',\r\n withoutTopPadding = false,\r\n withTopMargin = false,\r\n withBottomMargin = false,\r\n withoutBottomPadding = false,\r\n variant,\r\n corners,\r\n columns,\r\n hideControlsOnDesktop,\r\n withoutCarousel,\r\n footnote,\r\n}: CardsGridSectionProps<T>) => {\r\n const Component = componentMap[component] || Advantage\r\n\r\n return (\r\n <Section\r\n title={title}\r\n sectionId={sectionId}\r\n desc={desc}\r\n variant={variant}\r\n corners={corners}\r\n withoutTopPadding={withoutTopPadding}\r\n withTopMargin={withTopMargin}\r\n withBottomMargin={withBottomMargin}\r\n withoutBottomPadding={withoutBottomPadding}\r\n >\r\n <GridIterator\r\n items={items}\r\n columns={columns}\r\n hideControlsOnDesktop={hideControlsOnDesktop}\r\n withoutCarousel={withoutCarousel}\r\n renderItem={(item, index) => <Component key={index} {...item} />}\r\n footnote={footnote}\r\n />\r\n </Section>\r\n )\r\n}\r\n\r\nexport default CardsGridSection\r\n"],"names":["componentMap","Advantage","Advantage2","Rate","Product","FeaturedCard","Plate","CardsGridSection","title","sectionId","desc","items","component","withoutTopPadding","withTopMargin","withBottomMargin","withoutBottomPadding","variant","corners","columns","hideControlsOnDesktop","withoutCarousel","footnote","Component","React","Section","GridIterator","item","index","CardsGridSection$1"],"mappings":";;;;;;;;;AAYA,MAAMA,IAAqD;AAAA,EACzD,WAAAC;AAAA,EACA,YAAAC;AAAA,EACA,MAAAC;AAAA,EACA,SAAAC;AAAA,EACA,cAAAC;AAAA,EACA,OAAAC;AACF,GAoBMC,IAAmB,CAAK;AAAA,EAC5B,OAAAC;AAAA,EACA,WAAAC;AAAA,EACA,MAAAC;AAAA,EACA,OAAAC;AAAA,EACA,WAAAC,IAAY;AAAA,EACZ,mBAAAC,IAAoB;AAAA,EACpB,eAAAC,IAAgB;AAAA,EAChB,kBAAAC,IAAmB;AAAA,EACnB,sBAAAC,IAAuB;AAAA,EACvB,SAAAC;AAAA,EACA,SAAAC;AAAA,EACA,SAAAC;AAAA,EACA,uBAAAC;AAAA,EACA,iBAAAC;AAAA,EACA,UAAAC;AACF,MAAgC;AACxB,QAAAC,IAAYvB,EAAaY,CAAS,KAAKX;AAG3C,SAAAuB,gBAAAA,EAAA;AAAA,IAACC;AAAA,IAAA;AAAA,MACC,OAAAjB;AAAA,MACA,WAAAC;AAAA,MACA,MAAAC;AAAA,MACA,SAAAO;AAAA,MACA,SAAAC;AAAA,MACA,mBAAAL;AAAA,MACA,eAAAC;AAAA,MACA,kBAAAC;AAAA,MACA,sBAAAC;AAAA,IAAA;AAAA,IAEAQ,gBAAAA,EAAA;AAAA,MAACE;AAAA,MAAA;AAAA,QACC,OAAAf;AAAA,QACA,SAAAQ;AAAA,QACA,uBAAAC;AAAA,QACA,iBAAAC;AAAA,QACA,YAAY,CAACM,GAAMC,sCAAWL,GAAU,EAAA,KAAKK,GAAQ,GAAGD,EAAM,CAAA;AAAA,QAC9D,UAAAL;AAAA,MAAA;AAAA,IACF;AAAA,EAAA;AAGN,GAEAO,IAAetB;"}
|
package/dist/index.es41.js
CHANGED
|
@@ -1,59 +1,23 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import p from "./index.
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
import { getAdapter as u } from "./index.es9.js";
|
|
9
|
-
const l = n("rounded-lg p-6 min-h-[190px] h-full", {
|
|
10
|
-
variants: {
|
|
11
|
-
variant: {
|
|
12
|
-
default: "bg-white",
|
|
13
|
-
sapphire: "bg-sapphire text-whitish"
|
|
14
|
-
}
|
|
15
|
-
},
|
|
16
|
-
defaultVariants: {
|
|
17
|
-
variant: "default"
|
|
18
|
-
}
|
|
19
|
-
}), v = n("", {
|
|
20
|
-
variants: {
|
|
21
|
-
variant: {
|
|
22
|
-
default: "text-navy-opacity-60",
|
|
23
|
-
sapphire: "text-whitish-opacity-60"
|
|
24
|
-
}
|
|
25
|
-
},
|
|
26
|
-
defaultVariants: {
|
|
27
|
-
variant: "default"
|
|
28
|
-
}
|
|
29
|
-
}), R = ({
|
|
30
|
-
title: s,
|
|
31
|
-
desc: m,
|
|
32
|
-
variant: t,
|
|
33
|
-
link: r,
|
|
34
|
-
detailsText: i
|
|
35
|
-
}) => {
|
|
36
|
-
const o = /* @__PURE__ */ e.createElement("div", { className: "space-y-2" }, /* @__PURE__ */ e.createElement(f, { level: 4, as: "div" }, s), /* @__PURE__ */ e.createElement(h, { className: a(v({ variant: t })), as: "div" }, /* @__PURE__ */ e.createElement(d, { html: m }))), c = u("LinkWrapper");
|
|
37
|
-
return r ? /* @__PURE__ */ e.createElement(
|
|
38
|
-
c,
|
|
39
|
-
{
|
|
40
|
-
href: r,
|
|
41
|
-
className: a(
|
|
42
|
-
l({ variant: t }),
|
|
43
|
-
"transition-all bottom-0 hover:bottom-1 transform duration-300 relative hover:scale1-[1.005]"
|
|
44
|
-
)
|
|
45
|
-
},
|
|
46
|
-
/* @__PURE__ */ e.createElement("div", { className: "flex flex-col justify-between h-full items-start" }, o, i && /* @__PURE__ */ e.createElement(
|
|
47
|
-
p,
|
|
1
|
+
import c, { forwardRef as f } from "react";
|
|
2
|
+
import { typeVariants as p } from "./index.es55.js";
|
|
3
|
+
const e = f(
|
|
4
|
+
({ level: a, as: n, className: t = "", children: r, id: o, ...i }, s) => {
|
|
5
|
+
const d = n || `h${a}`, m = p({ variant: `h${a}` });
|
|
6
|
+
return /* @__PURE__ */ c.createElement(
|
|
7
|
+
d,
|
|
48
8
|
{
|
|
49
|
-
|
|
50
|
-
|
|
9
|
+
ref: s,
|
|
10
|
+
id: o,
|
|
11
|
+
className: `${m}${t ? ` ${t}` : ""}`,
|
|
12
|
+
...i
|
|
51
13
|
},
|
|
52
|
-
|
|
53
|
-
)
|
|
54
|
-
|
|
55
|
-
|
|
14
|
+
r
|
|
15
|
+
);
|
|
16
|
+
}
|
|
17
|
+
);
|
|
18
|
+
e.displayName = "Heading";
|
|
19
|
+
const l = e;
|
|
56
20
|
export {
|
|
57
|
-
|
|
21
|
+
l as default
|
|
58
22
|
};
|
|
59
23
|
//# sourceMappingURL=index.es41.js.map
|
package/dist/index.es41.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.es41.js","sources":["../src/components/
|
|
1
|
+
{"version":3,"file":"index.es41.js","sources":["../src/components/core/typography/Heading.tsx"],"sourcesContent":["import React, { ElementType, ReactNode, forwardRef } from \"react\";\r\n\r\nimport { typeVariants } from \"./typeVariants\";\r\n\r\ninterface HeadingProps {\r\n level: 1 | 2 | 3 | 4 | 5 | 6;\r\n as?: ElementType;\r\n className?: string;\r\n children: ReactNode;\r\n id?: string;\r\n}\r\n\r\nconst Heading = forwardRef<HTMLHeadingElement, HeadingProps>(\r\n ({ level, as, className = \"\", children, id, ...props }, ref) => {\r\n const Component = as || `h${level}`;\r\n const variantClass = typeVariants({ variant: `h${level}` });\r\n\r\n return (\r\n <Component\r\n ref={ref}\r\n id={id}\r\n className={`${variantClass}${className ? ` ${className}` : \"\"}`}\r\n {...props}\r\n >\r\n {children}\r\n </Component>\r\n );\r\n }\r\n);\r\n\r\nHeading.displayName = \"Heading\";\r\n\r\nexport default Heading;\r\n"],"names":["Heading","forwardRef","level","as","className","children","id","props","ref","Component","variantClass","typeVariants","React","Heading$1"],"mappings":";;AAYA,MAAMA,IAAUC;AAAA,EACd,CAAC,EAAE,OAAAC,GAAO,IAAAC,GAAI,WAAAC,IAAY,IAAI,UAAAC,GAAU,IAAAC,GAAI,GAAGC,EAAM,GAAGC,MAAQ;AACxD,UAAAC,IAAYN,KAAM,IAAID,CAAK,IAC3BQ,IAAeC,EAAa,EAAE,SAAS,IAAIT,CAAK,IAAI;AAGxD,WAAAU,gBAAAA,EAAA;AAAA,MAACH;AAAA,MAAA;AAAA,QACC,KAAAD;AAAA,QACA,IAAAF;AAAA,QACA,WAAW,GAAGI,CAAY,GAAGN,IAAY,IAAIA,CAAS,KAAK,EAAE;AAAA,QAC5D,GAAGG;AAAA,MAAA;AAAA,MAEHF;AAAA,IAAA;AAAA,EAGP;AACF;AAEAL,EAAQ,cAAc;AAEtB,MAAAa,IAAeb;"}
|
package/dist/index.es42.js
CHANGED
|
@@ -1,95 +1,22 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
const x = d(
|
|
9
|
-
"group p-6 rounded-lg min-h-[300px] flex flex-col justify-between gap-12 items-start relative hover:scale1-[1.005] h-full",
|
|
10
|
-
{
|
|
11
|
-
variants: {
|
|
12
|
-
variant: {
|
|
13
|
-
default: "text-navy bg-whitish hover1:bg-navy-opacity-4 hover1:text-navy",
|
|
14
|
-
// navy: "text-whitish bg-gradient-to-b from-navy to-sapphire hover:from-sapphire hover:to-navy",
|
|
15
|
-
navy: "text-whitish primary-gradient"
|
|
16
|
-
},
|
|
17
|
-
size: {
|
|
18
|
-
1: "sm:col-span-1",
|
|
19
|
-
2: "sm:col-span-2"
|
|
20
|
-
}
|
|
21
|
-
},
|
|
22
|
-
defaultVariants: {
|
|
23
|
-
variant: "default",
|
|
24
|
-
size: 1
|
|
25
|
-
}
|
|
26
|
-
}
|
|
27
|
-
), E = d("", {
|
|
28
|
-
variants: {
|
|
29
|
-
variant: {
|
|
30
|
-
default: "text-navy-opacity-60",
|
|
31
|
-
navy: "text-whitish-opacity-60"
|
|
32
|
-
}
|
|
33
|
-
},
|
|
34
|
-
defaultVariants: {
|
|
35
|
-
variant: "default"
|
|
36
|
-
}
|
|
37
|
-
}), j = ({
|
|
38
|
-
title: i,
|
|
39
|
-
desc: p,
|
|
40
|
-
icon: v,
|
|
41
|
-
link: l,
|
|
42
|
-
variant: t,
|
|
43
|
-
size: s,
|
|
44
|
-
buttons: r
|
|
45
|
-
}) => {
|
|
46
|
-
const f = m("LinkWrapper"), h = m("ImageWrapper");
|
|
47
|
-
let n = /* @__PURE__ */ e.createElement("div", { className: o(x({ variant: t, size: s })) }, /* @__PURE__ */ e.createElement("div", { className: "rounded-lg p-4 bg-turquoise-opacity-20" }, /* @__PURE__ */ e.createElement(
|
|
48
|
-
h,
|
|
49
|
-
{
|
|
50
|
-
src: v,
|
|
51
|
-
alt: `Изображение для ${i}`,
|
|
52
|
-
width: 32,
|
|
53
|
-
height: 32,
|
|
54
|
-
className: "object-contain"
|
|
55
|
-
}
|
|
56
|
-
)), /* @__PURE__ */ e.createElement("div", { className: "space-y-2" }, /* @__PURE__ */ e.createElement(g, { level: 5, className: "mt-4 mb-2" }, i), /* @__PURE__ */ e.createElement(u, { variant: "small-body", className: o(E({ variant: t })) }, p)), !(r && r.length) && /* @__PURE__ */ e.createElement(
|
|
57
|
-
c,
|
|
58
|
-
{
|
|
59
|
-
icon: "arrowRight",
|
|
60
|
-
variant: t === "navy" ? "white" : "default"
|
|
61
|
-
},
|
|
62
|
-
"Подробнее"
|
|
63
|
-
), r && /* @__PURE__ */ e.createElement("div", { className: "flex space-x-3" }, r?.map((a, y) => /* @__PURE__ */ e.createElement("div", { key: y }, /* @__PURE__ */ e.createElement(
|
|
64
|
-
c,
|
|
65
|
-
{
|
|
66
|
-
variant: t === "navy" ? "white" : "default",
|
|
67
|
-
icon: a.icon,
|
|
68
|
-
asChild: !0
|
|
69
|
-
},
|
|
70
|
-
/* @__PURE__ */ e.createElement(
|
|
71
|
-
"a",
|
|
1
|
+
import c, { forwardRef as f } from "react";
|
|
2
|
+
import { typeVariants as d } from "./index.es55.js";
|
|
3
|
+
const e = f(
|
|
4
|
+
({ variant: a = "body", as: o, className: t = "", children: r, ...n }, s) => {
|
|
5
|
+
const m = o || "p", p = d({ variant: a });
|
|
6
|
+
return /* @__PURE__ */ c.createElement(
|
|
7
|
+
m,
|
|
72
8
|
{
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
9
|
+
ref: s,
|
|
10
|
+
className: `${p}${t ? ` ${t}` : ""}`,
|
|
11
|
+
...n
|
|
76
12
|
},
|
|
77
|
-
|
|
78
|
-
)
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
href: l,
|
|
84
|
-
className: o(
|
|
85
|
-
"relative transition-all bottom-0 hover:bottom-2 transform duration-300 border border-transparent rounded-lg hover1:border-navy-opacity-16",
|
|
86
|
-
s === 2 ? "sm:col-span-2" : "sm:col-span-1"
|
|
87
|
-
)
|
|
88
|
-
},
|
|
89
|
-
n
|
|
90
|
-
)), n;
|
|
91
|
-
};
|
|
13
|
+
r
|
|
14
|
+
);
|
|
15
|
+
}
|
|
16
|
+
);
|
|
17
|
+
e.displayName = "Text";
|
|
18
|
+
const x = e;
|
|
92
19
|
export {
|
|
93
|
-
|
|
20
|
+
x as default
|
|
94
21
|
};
|
|
95
22
|
//# sourceMappingURL=index.es42.js.map
|
package/dist/index.es42.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.es42.js","sources":["../src/components/
|
|
1
|
+
{"version":3,"file":"index.es42.js","sources":["../src/components/core/typography/Text.tsx"],"sourcesContent":["import React, { ElementType, ReactNode, forwardRef } from \"react\";\r\n\r\nimport { typeVariants } from \"./typeVariants\";\r\n\r\ninterface TextProps {\r\n variant?:\r\n | \"factoid\"\r\n | \"subtitle-1\"\r\n | \"subtitle-2\"\r\n | \"overline\"\r\n | \"lead-text\"\r\n | \"body\"\r\n | \"small-body\"\r\n | \"caption\"\r\n | \"button\"\r\n | \"link\";\r\n as?: ElementType;\r\n className?: string;\r\n children: ReactNode;\r\n}\r\n\r\nconst Text = forwardRef<HTMLParagraphElement, TextProps>(\r\n ({ variant = \"body\", as, className = \"\", children, ...props }, ref) => {\r\n const Component = as || \"p\";\r\n const variantClass = typeVariants({ variant });\r\n\r\n return (\r\n <Component\r\n ref={ref}\r\n className={`${variantClass}${className ? ` ${className}` : \"\"}`}\r\n {...props}\r\n >\r\n {children}\r\n </Component>\r\n );\r\n }\r\n);\r\n\r\nText.displayName = \"Text\";\r\n\r\nexport default Text;\r\n"],"names":["Text","forwardRef","variant","as","className","children","props","ref","Component","variantClass","typeVariants","React","Text$1"],"mappings":";;AAqBA,MAAMA,IAAOC;AAAA,EACX,CAAC,EAAE,SAAAC,IAAU,QAAQ,IAAAC,GAAI,WAAAC,IAAY,IAAI,UAAAC,GAAU,GAAGC,EAAM,GAAGC,MAAQ;AACrE,UAAMC,IAAYL,KAAM,KAClBM,IAAeC,EAAa,EAAE,SAAAR,EAAS,CAAA;AAG3C,WAAAS,gBAAAA,EAAA;AAAA,MAACH;AAAA,MAAA;AAAA,QACC,KAAAD;AAAA,QACA,WAAW,GAAGE,CAAY,GAAGL,IAAY,IAAIA,CAAS,KAAK,EAAE;AAAA,QAC5D,GAAGE;AAAA,MAAA;AAAA,MAEHD;AAAA,IAAA;AAAA,EAGP;AACF;AAEAL,EAAK,cAAc;AAEnB,MAAAY,IAAeZ;"}
|
package/dist/index.es43.js
CHANGED
|
@@ -1,101 +1,94 @@
|
|
|
1
|
-
import e from "react";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
{
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
|
|
1
|
+
import * as e from "react";
|
|
2
|
+
import { FormProvider as f, Controller as F, useFormContext as u } from "react-hook-form";
|
|
3
|
+
import { Label as p } from "./index.es15.js";
|
|
4
|
+
import { Slot as I } from "@radix-ui/react-slot";
|
|
5
|
+
import { cn as a } from "./index.es49.js";
|
|
6
|
+
const R = f, c = e.createContext(
|
|
7
|
+
{}
|
|
8
|
+
), $ = ({
|
|
9
|
+
...t
|
|
10
|
+
}) => /* @__PURE__ */ e.createElement(c.Provider, { value: { name: t.name } }, /* @__PURE__ */ e.createElement(F, { ...t })), i = () => {
|
|
11
|
+
const t = e.useContext(c), o = e.useContext(l), { getFieldState: r, formState: m } = u(), n = r(t.name, m);
|
|
12
|
+
if (!t)
|
|
13
|
+
throw new Error("useFormField should be used within <FormField>");
|
|
14
|
+
const { id: s } = o;
|
|
15
|
+
return {
|
|
16
|
+
id: s,
|
|
17
|
+
name: t.name,
|
|
18
|
+
formItemId: `${s}-form-item`,
|
|
19
|
+
formDescriptionId: `${s}-form-item-description`,
|
|
20
|
+
formMessageId: `${s}-form-item-message`,
|
|
21
|
+
...n
|
|
22
|
+
};
|
|
23
|
+
}, l = e.createContext(
|
|
24
|
+
{}
|
|
25
|
+
), x = e.forwardRef(({ className: t, ...o }, r) => {
|
|
26
|
+
const m = e.useId();
|
|
27
|
+
return /* @__PURE__ */ e.createElement(l.Provider, { value: { id: m } }, /* @__PURE__ */ e.createElement("div", { ref: r, className: a("space-y-2", t), ...o }));
|
|
28
|
+
});
|
|
29
|
+
x.displayName = "FormItem";
|
|
30
|
+
const C = e.forwardRef(({ className: t, ...o }, r) => {
|
|
31
|
+
const { error: m, formItemId: n } = i();
|
|
32
|
+
return /* @__PURE__ */ e.createElement(
|
|
33
|
+
p,
|
|
34
|
+
{
|
|
35
|
+
ref: r,
|
|
36
|
+
className: a(m && "text-destructive", t),
|
|
37
|
+
htmlFor: n,
|
|
38
|
+
...o
|
|
23
39
|
}
|
|
24
|
-
|
|
25
|
-
)
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
40
|
+
);
|
|
41
|
+
});
|
|
42
|
+
C.displayName = "FormLabel";
|
|
43
|
+
const g = e.forwardRef(({ ...t }, o) => {
|
|
44
|
+
const { error: r, formItemId: m, formDescriptionId: n, formMessageId: s } = i();
|
|
45
|
+
return /* @__PURE__ */ e.createElement(
|
|
46
|
+
I,
|
|
47
|
+
{
|
|
48
|
+
ref: o,
|
|
49
|
+
id: m,
|
|
50
|
+
"aria-describedby": r ? `${n} ${s}` : `${n}`,
|
|
51
|
+
"aria-invalid": !!r,
|
|
52
|
+
...t
|
|
30
53
|
}
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
54
|
+
);
|
|
55
|
+
});
|
|
56
|
+
g.displayName = "FormControl";
|
|
57
|
+
const v = e.forwardRef(({ className: t, ...o }, r) => {
|
|
58
|
+
const { formDescriptionId: m } = i();
|
|
59
|
+
return /* @__PURE__ */ e.createElement(
|
|
60
|
+
"p",
|
|
61
|
+
{
|
|
62
|
+
ref: r,
|
|
63
|
+
id: m,
|
|
64
|
+
className: a("text-sm text-muted-foreground", t),
|
|
65
|
+
...o
|
|
40
66
|
}
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
}),
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
},
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
price: m,
|
|
59
|
-
desc: i,
|
|
60
|
-
link: y,
|
|
61
|
-
onClickBuyButton: u,
|
|
62
|
-
buttons: h,
|
|
63
|
-
tags: v,
|
|
64
|
-
titleInformer: p
|
|
65
|
-
}) => /* @__PURE__ */ e.createElement("div", { className: s(k({ variant: a, className: l })) }, /* @__PURE__ */ e.createElement("div", null, v && /* @__PURE__ */ e.createElement("div", { className: "flex space-x-2 mb-6" }, v.map((t, c) => /* @__PURE__ */ e.createElement(g, { key: c, variant: t.color }, t.title))), /* @__PURE__ */ e.createElement("div", { className: "space-y-12 mb-6" }, /* @__PURE__ */ e.createElement("div", { className: "space-y-4" }, /* @__PURE__ */ e.createElement("div", { className: "flex space-x-2 items-center relative" }, /* @__PURE__ */ e.createElement(
|
|
66
|
-
x,
|
|
67
|
-
{
|
|
68
|
-
href: y,
|
|
69
|
-
variant: a === "navy" ? "white" : "navy"
|
|
70
|
-
},
|
|
71
|
-
/* @__PURE__ */ e.createElement(f, { level: 4, as: "span" }, r)
|
|
72
|
-
), p && /* @__PURE__ */ e.createElement(w, { content: p })), /* @__PURE__ */ e.createElement("div", { className: "flex space-x-4 items-baseline" }, n && /* @__PURE__ */ e.createElement(
|
|
73
|
-
d,
|
|
74
|
-
{
|
|
75
|
-
variant: "caption",
|
|
76
|
-
className: "text-navy-opacity-40 line-through"
|
|
77
|
-
},
|
|
78
|
-
n
|
|
79
|
-
), /* @__PURE__ */ e.createElement(f, { level: 5, as: "div" }, m))), /* @__PURE__ */ e.createElement("div", { className: "space-y-4" }, /* @__PURE__ */ e.createElement("div", { className: s(V({ variant: a })) }), /* @__PURE__ */ e.createElement(
|
|
80
|
-
d,
|
|
81
|
-
{
|
|
82
|
-
variant: "small-body",
|
|
83
|
-
as: "div",
|
|
84
|
-
className: s(B({ variant: a }), "content")
|
|
85
|
-
},
|
|
86
|
-
/* @__PURE__ */ e.createElement(N, { html: i })
|
|
87
|
-
)))), /* @__PURE__ */ e.createElement("div", { className: "w-full gap-2 flex" }, h?.map((t, c) => /* @__PURE__ */ e.createElement(
|
|
88
|
-
R,
|
|
89
|
-
{
|
|
90
|
-
key: c,
|
|
91
|
-
variant: t.variant,
|
|
92
|
-
title: t.title,
|
|
93
|
-
link: t.link,
|
|
94
|
-
onClick: () => t.isBuyButton && u?.(r)
|
|
95
|
-
}
|
|
96
|
-
))));
|
|
67
|
+
);
|
|
68
|
+
});
|
|
69
|
+
v.displayName = "FormDescription";
|
|
70
|
+
const E = e.forwardRef(({ className: t, children: o, ...r }, m) => {
|
|
71
|
+
const { error: n, formMessageId: s } = i(), d = n ? String(n?.message) : o;
|
|
72
|
+
return d ? /* @__PURE__ */ e.createElement(
|
|
73
|
+
"p",
|
|
74
|
+
{
|
|
75
|
+
ref: m,
|
|
76
|
+
id: s,
|
|
77
|
+
className: a("text-sm font-medium text-destructive", t),
|
|
78
|
+
...r
|
|
79
|
+
},
|
|
80
|
+
d
|
|
81
|
+
) : null;
|
|
82
|
+
});
|
|
83
|
+
E.displayName = "FormMessage";
|
|
97
84
|
export {
|
|
98
|
-
R as
|
|
99
|
-
|
|
85
|
+
R as Form,
|
|
86
|
+
g as FormControl,
|
|
87
|
+
v as FormDescription,
|
|
88
|
+
$ as FormField,
|
|
89
|
+
x as FormItem,
|
|
90
|
+
C as FormLabel,
|
|
91
|
+
E as FormMessage,
|
|
92
|
+
i as useFormField
|
|
100
93
|
};
|
|
101
94
|
//# sourceMappingURL=index.es43.js.map
|