@rxdrag/website-lib-react 0.0.3 → 0.0.6
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/ReactModalTrigger-9207e763.js +26 -0
- package/dist/ReactModalTrigger-9207e763.js.map +1 -0
- package/dist/components/RichTextOutline/parseOutline.d.ts +5 -0
- package/dist/components/all.d.ts +0 -21
- package/dist/components/index.d.ts +0 -5
- package/dist/forms.d.ts +1 -0
- package/dist/forms.mjs +1647 -0
- package/dist/forms.mjs.map +1 -0
- package/dist/index.mjs +9 -3918
- package/dist/index.mjs.map +1 -1
- package/dist/jsx-runtime-c02cc059.js +325 -0
- package/dist/jsx-runtime-c02cc059.js.map +1 -0
- package/dist/media.d.ts +1 -0
- package/dist/media.mjs +613 -0
- package/dist/media.mjs.map +1 -0
- package/dist/richtext.d.ts +1 -0
- package/dist/richtext.mjs +191 -0
- package/dist/richtext.mjs.map +1 -0
- package/dist/ui.d.ts +10 -0
- package/dist/ui.mjs +687 -0
- package/dist/ui.mjs.map +1 -0
- package/dist/video.d.ts +2 -0
- package/dist/video.mjs +426 -0
- package/dist/video.mjs.map +1 -0
- package/forms.ts +1 -0
- package/index.ts +1 -0
- package/media.ts +1 -0
- package/package.json +41 -6
- package/richtext.ts +1 -0
- package/src/components/Analytics/eventHandlers.ts +173 -0
- package/src/components/Analytics/index.tsx +21 -0
- package/src/components/Analytics/singleton.ts +214 -0
- package/src/components/Analytics/tracking.ts +221 -0
- package/src/components/Analytics/types.ts +60 -0
- package/src/components/Analytics/utils.ts +95 -0
- package/src/components/AttachmentIcon/index.tsx +53 -0
- package/src/components/BackgroundHlsVideoPlayer.tsx +97 -0
- package/src/components/BackgroundVideoPlayer.tsx +32 -0
- package/src/components/Bulletin.tsx +30 -0
- package/src/components/ContactForm/ContactForm.tsx +290 -0
- package/src/components/ContactForm/FileUpload2.tsx +423 -0
- package/src/components/ContactForm/Input.tsx +48 -0
- package/src/components/ContactForm/Input2.tsx +59 -0
- package/src/components/ContactForm/Submit.tsx +48 -0
- package/src/components/ContactForm/TelInput.tsx +215 -0
- package/src/components/ContactForm/TelInput2.tsx +213 -0
- package/src/components/ContactForm/Textarea.tsx +48 -0
- package/src/components/ContactForm/Textarea2.tsx +89 -0
- package/src/components/ContactForm/countryDialCodes.ts +243 -0
- package/src/components/ContactForm/factory.tsx +60 -0
- package/src/components/ContactForm/funcs.ts +64 -0
- package/src/components/ContactForm/hooks/useInlineLabelPadding.ts +43 -0
- package/src/components/ContactForm/hooks/useTelControl.ts +81 -0
- package/src/components/ContactForm/index.ts +7 -0
- package/src/components/ContactForm/types.ts +68 -0
- package/src/components/Icon/index.tsx +20 -0
- package/src/components/Medias/MainMedia.tsx +257 -0
- package/src/components/Medias/Thumbnail.tsx +62 -0
- package/src/components/Medias/VideoPlayer.tsx +114 -0
- package/src/components/Medias/index.tsx +271 -0
- package/src/components/ProductCard/ProductCard.tsx +24 -0
- package/src/components/ProductCard/ProductCta/index.tsx +28 -0
- package/src/components/ProductCard/ProductCta/style.css +4 -0
- package/src/components/ProductCard/ProductDescription/index.tsx +13 -0
- package/src/components/ProductCard/ProductDescription/style.css +6 -0
- package/src/components/ProductCard/ProductMedia/index.tsx +35 -0
- package/src/components/ProductCard/ProductMedia/style.css +6 -0
- package/src/components/ProductCard/ProductTitle/index.tsx +7 -0
- package/src/components/ProductCard/ProductTitle/style.css +4 -0
- package/src/components/ProductCard/ProductView.tsx +36 -0
- package/src/components/ProductCard/index.ts +5 -0
- package/src/components/ProductCard/useQueryProduct.ts +32 -0
- package/src/components/ReactModalTrigger.tsx +28 -0
- package/src/components/ReactVideoPlayer.tsx +332 -0
- package/src/components/RichTextOutline/index.tsx +74 -0
- package/src/components/RichTextOutline/parseOutline.ts +63 -0
- package/src/components/RichTextOutline/useAcitviedHeading.ts +142 -0
- package/src/components/RichTextOutline/useAnchorScroll.ts +24 -0
- package/src/components/Scroller.tsx +39 -0
- package/src/components/SearchInput.tsx +21 -0
- package/src/components/Share/index.tsx +86 -0
- package/src/components/Share/socials.tsx +80 -0
- package/src/components/Share//350/265/204/346/226/231.md +7 -0
- package/src/components/ToTop.tsx +72 -0
- package/src/components/VideoPlayIcon.tsx +43 -0
- package/src/components/all.ts +25 -0
- package/src/components/index.ts +12 -0
- package/src/forms.ts +1 -0
- package/src/index.ts +1 -0
- package/src/media.ts +1 -0
- package/src/richtext.ts +1 -0
- package/src/types/view-model.ts +37 -0
- package/src/ui.ts +10 -0
- package/src/video.ts +2 -0
- package/ui.ts +1 -0
- package/video.ts +1 -0
- package/dist/style.css +0 -17
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { j as jsxRuntimeExports } from "./jsx-runtime-c02cc059.js";
|
|
2
|
+
function ReactModalTrigger(props) {
|
|
3
|
+
const {
|
|
4
|
+
className,
|
|
5
|
+
callToAction,
|
|
6
|
+
openableKey = "enquiry-modal",
|
|
7
|
+
children
|
|
8
|
+
} = props;
|
|
9
|
+
const roleProps = {
|
|
10
|
+
"data-modal-open": openableKey,
|
|
11
|
+
"data-call-to-action": callToAction
|
|
12
|
+
};
|
|
13
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
14
|
+
"button",
|
|
15
|
+
{
|
|
16
|
+
...roleProps,
|
|
17
|
+
className,
|
|
18
|
+
type: "button",
|
|
19
|
+
children: children || "Get a quote"
|
|
20
|
+
}
|
|
21
|
+
);
|
|
22
|
+
}
|
|
23
|
+
export {
|
|
24
|
+
ReactModalTrigger as R
|
|
25
|
+
};
|
|
26
|
+
//# sourceMappingURL=ReactModalTrigger-9207e763.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ReactModalTrigger-9207e763.js","sources":["../src/components/ReactModalTrigger.tsx"],"sourcesContent":["import type { ReactNode } from \"react\";\n\nexport function ReactModalTrigger(props: {\n className?: string;\n openableKey?: string;\n callToAction?: string;\n children?: ReactNode;\n}) {\n const {\n className,\n callToAction,\n openableKey = \"enquiry-modal\",\n children,\n } = props;\n const roleProps = {\n \"data-modal-open\": openableKey,\n \"data-call-to-action\": callToAction,\n };\n return (\n <button\n {...roleProps}\n className={className}\n type=\"button\"\n >\n {children || \"Get a quote\"}\n </button>\n );\n}\n"],"names":["jsx"],"mappings":";AAEO,SAAS,kBAAkB,OAK/B;AACK,QAAA;AAAA,IACJ;AAAA,IACA;AAAA,IACA,cAAc;AAAA,IACd;AAAA,EACE,IAAA;AACJ,QAAM,YAAY;AAAA,IAChB,mBAAmB;AAAA,IACnB,uBAAuB;AAAA,EAAA;AAGvB,SAAAA,kCAAA;AAAA,IAAC;AAAA,IAAA;AAAA,MACE,GAAG;AAAA,MACJ;AAAA,MACA,MAAK;AAAA,MAEJ,UAAY,YAAA;AAAA,IAAA;AAAA,EAAA;AAGnB;"}
|
package/dist/components/all.d.ts
CHANGED
|
@@ -1,38 +1,17 @@
|
|
|
1
1
|
import { Analytics } from './Analytics';
|
|
2
|
-
import { BackgroundHlsVideoPlayer } from './BackgroundHlsVideoPlayer';
|
|
3
2
|
import { BackgroundVideoPlayer } from './BackgroundVideoPlayer';
|
|
4
3
|
import { Bulletin } from './Bulletin';
|
|
5
|
-
import { ProductCta, ProductDescription, ProductMedia, ProductTitle } from './ProductCard';
|
|
6
4
|
import { ReactModalTrigger } from './ReactModalTrigger';
|
|
7
5
|
import { Scroller } from './Scroller';
|
|
8
6
|
|
|
9
7
|
export declare const allCoreComponents: {
|
|
10
8
|
Analytics: typeof Analytics;
|
|
11
9
|
AttachmentIcon: import('react').ForwardRefExoticComponent<import('./AttachmentIcon').AttachmentIconProps & import('react').RefAttributes<HTMLDivElement>>;
|
|
12
|
-
BackgroundHlsVideoPlayer: typeof BackgroundHlsVideoPlayer;
|
|
13
10
|
BackgroundVideoPlayer: typeof BackgroundVideoPlayer;
|
|
14
11
|
Bulletin: typeof Bulletin;
|
|
15
12
|
ContactForm: import('react').ForwardRefExoticComponent<import('./ContactForm').ContactFormProps & import('react').RefAttributes<HTMLDivElement>>;
|
|
16
13
|
Icon: import('react').ForwardRefExoticComponent<Omit<import('./Icon').IconProps, "ref"> & import('react').RefAttributes<SVGSVGElement>>;
|
|
17
|
-
Medias: import('react').ForwardRefExoticComponent<import('./Medias').MediasProps & import('react').RefAttributes<HTMLDivElement>>;
|
|
18
|
-
ProductCard: ({ node }: import('./ProductCard').ProductCardProps) => import("react/jsx-runtime").JSX.Element;
|
|
19
|
-
ProductCta: typeof ProductCta;
|
|
20
|
-
ProductDescription: typeof ProductDescription;
|
|
21
|
-
ProductMedia: typeof ProductMedia;
|
|
22
|
-
ProductTitle: typeof ProductTitle;
|
|
23
14
|
ReactModalTrigger: typeof ReactModalTrigger;
|
|
24
|
-
ReactVideoPlayer: import('react').ForwardRefExoticComponent<{
|
|
25
|
-
endTitle?: string;
|
|
26
|
-
media?: import('@rxdrag/rxcms-models').Media;
|
|
27
|
-
posterUrl?: string;
|
|
28
|
-
eagerLoad?: boolean;
|
|
29
|
-
classNames?: import('./ReactVideoPlayer').VideoPlayerClassNames;
|
|
30
|
-
callToAction?: string;
|
|
31
|
-
onToggleSelect?: (id: import('./ReactVideoPlayer').ID) => void;
|
|
32
|
-
designMode?: boolean;
|
|
33
|
-
children?: React.ReactNode;
|
|
34
|
-
} & import('react').RefAttributes<HTMLDivElement>>;
|
|
35
|
-
RichTextOutline: import('react').ForwardRefExoticComponent<import('./RichTextOutline').RichTextOutlineProps & import('react').RefAttributes<HTMLUListElement>>;
|
|
36
15
|
Scroller: typeof Scroller;
|
|
37
16
|
SearchInput: import('react').ForwardRefExoticComponent<import('./SearchInput').SearchProps & import('react').RefAttributes<HTMLInputElement>>;
|
|
38
17
|
Share: import('react').ForwardRefExoticComponent<import('./Share').ShareProps & import('react').RefAttributes<HTMLDivElement>>;
|
|
@@ -2,16 +2,11 @@ export * from './Analytics';
|
|
|
2
2
|
export * from './AttachmentIcon';
|
|
3
3
|
export * from './ContactForm';
|
|
4
4
|
export * from './Icon';
|
|
5
|
-
export * from './Medias';
|
|
6
|
-
export * from './ProductCard';
|
|
7
|
-
export * from './RichTextOutline';
|
|
8
5
|
export * from './Share';
|
|
9
6
|
export * from './Scroller';
|
|
10
7
|
export * from './SearchInput';
|
|
11
8
|
export * from './ToTop';
|
|
12
9
|
export * from './BackgroundVideoPlayer';
|
|
13
|
-
export * from './BackgroundHlsVideoPlayer';
|
|
14
10
|
export * from './Bulletin';
|
|
15
11
|
export * from './ReactModalTrigger';
|
|
16
|
-
export * from './ReactVideoPlayer';
|
|
17
12
|
export * from './all';
|
package/dist/forms.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './components/ContactForm';
|