@nypl/design-system-react-components 1.0.1 → 1.0.3

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.
Files changed (129) hide show
  1. package/CHANGELOG.md +1452 -3
  2. package/README.md +389 -3
  3. package/dist/__tests__/fileMock.d.ts +4 -0
  4. package/dist/__tests__/setup.d.ts +2 -0
  5. package/{lib/stories/0-Welcome.stories.d.ts → dist/__tests__/utils/utils.test.d.ts} +1 -1
  6. package/dist/components/Accordion/Accordion.d.ts +21 -0
  7. package/dist/components/Autosuggest/Autosuggest.stories.d.ts +4 -0
  8. package/dist/components/Breadcrumbs/Breadcrumbs.d.ts +18 -0
  9. package/dist/components/Button/Button.d.ts +25 -0
  10. package/dist/components/ButtonGroup/ButtonGroup.d.ts +22 -0
  11. package/dist/components/Card/Card.d.ts +51 -0
  12. package/dist/components/Checkbox/Checkbox.d.ts +47 -0
  13. package/dist/components/CheckboxGroup/CheckboxGroup.d.ts +49 -0
  14. package/dist/components/ComponentWrapper/ComponentWrapper.d.ts +29 -0
  15. package/dist/components/DatePicker/DatePicker.d.ts +81 -0
  16. package/dist/components/Fieldset/Fieldset.d.ts +22 -0
  17. package/dist/components/Form/Form.d.ts +29 -0
  18. package/dist/components/Grid/SimpleGrid.d.ts +17 -0
  19. package/dist/components/Heading/Heading.d.ts +27 -0
  20. package/dist/components/HelperErrorText/HelperErrorText.d.ts +29 -0
  21. package/dist/components/Hero/Hero.d.ts +40 -0
  22. package/dist/components/HorizontalRule/HorizontalRule.d.ts +11 -0
  23. package/dist/components/Icons/Icon.d.ts +37 -0
  24. package/dist/components/Icons/IconSvgs.d.ts +33 -0
  25. package/dist/components/Image/Image.d.ts +61 -0
  26. package/dist/components/Label/Label.d.ts +20 -0
  27. package/dist/components/Link/Link.d.ts +20 -0
  28. package/dist/components/List/List.d.ts +35 -0
  29. package/dist/components/Logo/Logo.d.ts +26 -0
  30. package/dist/components/Logo/LogoSvgs.d.ts +48 -0
  31. package/dist/components/Modal/Modal.d.ts +33 -0
  32. package/dist/components/Notification/Notification.d.ts +50 -0
  33. package/dist/components/Pagination/Pagination.d.ts +27 -0
  34. package/dist/components/Placeholder/Placeholder.d.ts +10 -0
  35. package/dist/components/ProgressIndicator/ProgressIndicator.d.ts +30 -0
  36. package/dist/components/Radio/Radio.d.ts +43 -0
  37. package/dist/components/RadioGroup/RadioGroup.d.ts +51 -0
  38. package/dist/components/SearchBar/SearchBar.d.ts +61 -0
  39. package/dist/components/Select/Select.d.ts +57 -0
  40. package/dist/components/SkeletonLoader/SkeletonLoader.d.ts +39 -0
  41. package/dist/components/SkipNavigation/SkipNavigation.d.ts +17 -0
  42. package/dist/components/Slider/Slider.d.ts +59 -0
  43. package/dist/components/StatusBadge/StatusBadge.d.ts +16 -0
  44. package/dist/components/StructuredContent/StructuredContent.d.ts +28 -0
  45. package/dist/components/StyleGuide/ColorCard.d.ts +12 -0
  46. package/dist/components/Table/Table.d.ts +30 -0
  47. package/dist/components/Tabs/Tabs.d.ts +26 -0
  48. package/dist/components/Template/Template.d.ts +126 -0
  49. package/dist/components/Text/Text.d.ts +16 -0
  50. package/dist/components/TextInput/TextInput.d.ts +79 -0
  51. package/dist/components/Toggle/Toggle.d.ts +42 -0
  52. package/dist/components/VideoPlayer/VideoPlayer.d.ts +38 -0
  53. package/dist/design-system-react-components.cjs.development.js +11648 -0
  54. package/dist/design-system-react-components.cjs.development.js.map +1 -0
  55. package/dist/design-system-react-components.cjs.production.min.js +2 -0
  56. package/dist/design-system-react-components.cjs.production.min.js.map +1 -0
  57. package/dist/design-system-react-components.esm.js +11493 -0
  58. package/dist/design-system-react-components.esm.js.map +1 -0
  59. package/dist/helpers/types.d.ts +1 -0
  60. package/dist/hooks/__tests__/useCarouselStyles.test.d.ts +1 -0
  61. package/dist/hooks/useCarouselStyles.d.ts +17 -0
  62. package/dist/hooks/useNYPLTheme.d.ts +66 -0
  63. package/dist/hooks/useWindowSize.d.ts +10 -0
  64. package/dist/index.d.ts +48 -0
  65. package/dist/index.js +8 -0
  66. package/dist/resources.scss +386 -0
  67. package/dist/styles.css +3 -0
  68. package/dist/theme/components/accordion.d.ts +20 -0
  69. package/dist/theme/components/breadcrumb.d.ts +105 -0
  70. package/dist/theme/components/button.d.ts +120 -0
  71. package/dist/theme/components/buttonGroup.d.ts +11 -0
  72. package/dist/theme/components/card.d.ts +381 -0
  73. package/dist/theme/components/checkbox.d.ts +95 -0
  74. package/dist/theme/components/checkboxGroup.d.ts +14 -0
  75. package/dist/theme/components/componentWrapper.d.ts +12 -0
  76. package/dist/theme/components/customTable.d.ts +624 -0
  77. package/dist/theme/components/datePicker.d.ts +16 -0
  78. package/dist/theme/components/fieldset.d.ts +20 -0
  79. package/dist/theme/components/global.d.ts +73 -0
  80. package/dist/theme/components/globalMixins.d.ts +23 -0
  81. package/dist/theme/components/heading.d.ts +160 -0
  82. package/dist/theme/components/helperErrorText.d.ts +12 -0
  83. package/dist/theme/components/hero.d.ts +499 -0
  84. package/dist/theme/components/horizontalRule.d.ts +15 -0
  85. package/dist/theme/components/icon.d.ts +47755 -0
  86. package/dist/theme/components/image.d.ts +590 -0
  87. package/dist/theme/components/label.d.ts +18 -0
  88. package/dist/theme/components/link.d.ts +62 -0
  89. package/dist/theme/components/list.d.ts +182 -0
  90. package/dist/theme/components/logo.d.ts +477 -0
  91. package/dist/theme/components/notification.d.ts +95 -0
  92. package/dist/theme/components/pagination.d.ts +16 -0
  93. package/dist/theme/components/progressIndicator.d.ts +52 -0
  94. package/dist/theme/components/radio.d.ts +107 -0
  95. package/dist/theme/components/radioGroup.d.ts +14 -0
  96. package/dist/theme/components/searchBar.d.ts +18 -0
  97. package/dist/theme/components/select.d.ts +82 -0
  98. package/dist/theme/components/skeletonLoader.d.ts +102 -0
  99. package/dist/theme/components/skipNavigation.d.ts +25 -0
  100. package/dist/theme/components/slider.d.ts +59 -0
  101. package/dist/theme/components/statusBadge.d.ts +25 -0
  102. package/dist/theme/components/structuredContent.d.ts +326 -0
  103. package/dist/theme/components/tabs.d.ts +136 -0
  104. package/dist/theme/components/template.d.ts +108 -0
  105. package/dist/theme/components/text.d.ts +26 -0
  106. package/dist/theme/components/textInput.d.ts +124 -0
  107. package/dist/theme/components/toggle.d.ts +93 -0
  108. package/dist/theme/components/videoPlayer.d.ts +40 -0
  109. package/dist/theme/foundations/breakpoints.d.ts +23 -0
  110. package/dist/theme/foundations/colors.d.ts +3 -0
  111. package/dist/theme/foundations/global.d.ts +58 -0
  112. package/dist/theme/foundations/radii.d.ts +6 -0
  113. package/dist/theme/foundations/shadows.d.ts +4 -0
  114. package/dist/theme/foundations/spacing.d.ts +82 -0
  115. package/dist/theme/foundations/typography.d.ts +8 -0
  116. package/dist/theme/index.d.ts +20 -0
  117. package/dist/theme/provider.d.ts +3 -0
  118. package/dist/theme/types.d.ts +1 -0
  119. package/dist/utils/componentCategories.d.ts +1 -0
  120. package/dist/utils/interfaces.d.ts +5 -0
  121. package/dist/utils/utils.d.ts +31 -0
  122. package/package.json +132 -20
  123. package/lib/components/Button/Button.d.ts +0 -17
  124. package/lib/components/Button/Button.js +0 -42
  125. package/lib/index.d.ts +0 -1
  126. package/lib/index.js +0 -6
  127. package/lib/stories/0-Welcome.stories.js +0 -19
  128. package/lib/stories/1-Button.stories.d.ts +0 -6
  129. package/lib/stories/1-Button.stories.js +0 -20
@@ -0,0 +1,126 @@
1
+ import * as React from "react";
2
+ export interface TemplateProps {
3
+ }
4
+ export interface TemplateHeaderProps {
5
+ /** Flag to render an HTML header element. True by default. */
6
+ renderHeaderElement?: boolean;
7
+ }
8
+ export interface TemplateFooterProps {
9
+ /** Flag to render an HTML footer element. True by default. */
10
+ renderFooterElement?: boolean;
11
+ }
12
+ export interface TemplateSidebarProps {
13
+ /** Renders the `TemplateContentSidebar` component either on the left or
14
+ * right side of the `TemplateContentPrimary` component. */
15
+ sidebar?: "none" | "left" | "right";
16
+ }
17
+ export interface TemplateContentProps extends TemplateSidebarProps {
18
+ /** ID used for the `main` HTML element. Defaults to "mainContent". Useful
19
+ * anchor for the application skip navigation. */
20
+ id?: string;
21
+ }
22
+ export interface TemplateAppContainerProps extends TemplateFooterProps, TemplateHeaderProps, TemplateSidebarProps {
23
+ /** DOM that will be rendered before the rest of the components in
24
+ * `TemplateAppContainer` and immediately before the `TemplateHeader` component. */
25
+ aboveHeader?: React.ReactElement;
26
+ /** DOM that will be rendered in the `TemplateBreakout` component section. */
27
+ breakout?: React.ReactElement;
28
+ /** ID used for the `main` HTML element. Defaults to "mainContent". Useful
29
+ * anchor for the application skip navigation. */
30
+ contentId?: string;
31
+ /** DOM that will be rendered in the `TemplateContentPrimary` component section. */
32
+ contentPrimary?: React.ReactElement;
33
+ /** DOM that will be rendered in the `TemplateContentSidebar` component section. */
34
+ contentSidebar?: React.ReactElement;
35
+ /** DOM that will be rendered in the `TemplateContentTop` component section. */
36
+ contentTop?: React.ReactElement;
37
+ /** DOM that will be rendered in the `TemplateFooter` component section. */
38
+ footer?: React.ReactElement;
39
+ /** DOM that will be rendered in the `TemplateHeader` component section. */
40
+ header?: React.ReactElement;
41
+ /** Render the `SkipNavigation` component or not. False by default. */
42
+ renderSkipNavigation?: boolean;
43
+ }
44
+ /**
45
+ * The main top-level parent component that wraps all template-related
46
+ * components.
47
+ */
48
+ declare const Template: import("@chakra-ui/react").ChakraComponent<(props: React.PropsWithChildren<TemplateProps>) => JSX.Element, {}>;
49
+ /**
50
+ * This optional component renders its children from edge-to-edge and should
51
+ * be used for alerts or notifications that are typically site-wide. This must
52
+ * be rendered immediately before the `TemplateHeader` component. This is meant
53
+ * for components that render an `aside` HTML element or HTML element with the
54
+ * `role="complementary"` attribute. These elements should *not* be rendered
55
+ * in the `header` HTML section since that's an accessibility violation.
56
+ */
57
+ declare const TemplateAboveHeader: (props: React.PropsWithChildren<TemplateProps>) => JSX.Element;
58
+ /**
59
+ * This optional component should be the first child of the `Template`
60
+ * component. This is rendered as an HTML `<header>` element. If an HTML
61
+ * `<header>` element is already passed in a custom component as the children,
62
+ * set `renderFooterElement` to `false`. Otherwise, the parent wrapper will
63
+ * render an HTML `<header>` element.
64
+ */
65
+ declare const TemplateHeader: ({ children, renderHeaderElement, }: React.PropsWithChildren<TemplateHeaderProps>) => JSX.Element;
66
+ /**
67
+ * This optional component should be used inside the `TemplateHeader` component.
68
+ * This is meant to render its children from edge to edge and is most useful
69
+ * for the `Breadcrumbs` and `Hero` components, and other banner-like components.
70
+ */
71
+ declare const TemplateBreakout: (props: React.PropsWithChildren<TemplateProps>) => JSX.Element;
72
+ /**
73
+ * This component is most useful to render content on the page. This renders an
74
+ * HTML `<main>` element with an id of "mainContent". The "mainContent" id should
75
+ * be used as the consuming application's skip navigation link. The `TemplateContent`
76
+ * component also takes a `sidebar` prop with optional "left" or "right" values.
77
+ * This will set the correct *styling* needed for the `TemplateContentPrimary`
78
+ * and `TemplateContentSidebar` components. Note that `TemplateContentPrimary`
79
+ * and `TemplateContentSidebar` must be ordered correctly as children elements
80
+ * for the appropriate styles to take effect.
81
+ */
82
+ declare const TemplateContent: (props: React.PropsWithChildren<TemplateContentProps>) => JSX.Element;
83
+ /**
84
+ * This optional component must be used inside the `TemplateContent` component.
85
+ * This renders content in the main width of the container and will always render
86
+ * above the primary component and the sidebar component (if any).
87
+ */
88
+ declare const TemplateContentTop: (props: React.PropsWithChildren<TemplateProps>) => JSX.Element;
89
+ /**
90
+ * This component is used to render content in a column when there must be a
91
+ * sidebar component on either its left or right side. It must go inside the
92
+ * `TemplateContent` component. An optional `sidebar` prop value of "left" or
93
+ * "right" can be passed to render the correct CSS styles. If the `sidebar`
94
+ * prop is used in the `TemplateContent` component, there is no need to pass
95
+ * the `sidebar` prop to this component -- `TemplateContent` will handle it.
96
+ */
97
+ declare const TemplateContentPrimary: (props: React.PropsWithChildren<TemplateContentProps>) => JSX.Element;
98
+ /**
99
+ * This component is used to render content in a sidebar column. It must go
100
+ * inside the `TemplateContent` component and must be paired with the
101
+ * `TemplateContentPrimary` component. If this is a left sidebar, it needs to be
102
+ * rendered before the `TemplateContentPrimary` component. If this is a right
103
+ * sidebar, it needs to be rendered after the `TemplateContentPrimary` component.
104
+ * An optional `sidebar` prop value of "left" or "right" can be passed to render
105
+ * the correct CSS styles. If the `sidebar` prop is used in the `TemplateContent`
106
+ * component, there is no need to pass the `sidebar` prop to this component --
107
+ * `TemplateContent` will handle it.
108
+ */
109
+ declare const TemplateContentSidebar: (props: React.PropsWithChildren<TemplateContentProps>) => JSX.Element;
110
+ /**
111
+ * This optional component should be the last child of the `Template`
112
+ * component. This is rendered as an HTML `<footer>` element and spans the full
113
+ * width of the page. If an HTML `<footer>` element is already passed in a
114
+ * custom component, set `renderFooterElement` to `false`.
115
+ */
116
+ declare const TemplateFooter: ({ children, renderFooterElement, }: React.PropsWithChildren<TemplateFooterProps>) => JSX.Element;
117
+ /**
118
+ * This single component can be used instead of all the individual template
119
+ * components. Instead of importing and rendering the needed "template"
120
+ * components, each section is passed as a prop to the section where it should
121
+ * be rendered. For example, if you want to render content in the
122
+ * `TemplateContentPrimary` section, then pass it as a prop to `contentPrimary`.
123
+ */
124
+ export declare const TemplateAppContainer: import("@chakra-ui/react").ChakraComponent<(props: React.PropsWithChildren<TemplateAppContainerProps>) => JSX.Element, {}>;
125
+ export { Template, TemplateAboveHeader, TemplateHeader, TemplateBreakout, TemplateContent, TemplateContentTop, TemplateContentPrimary, TemplateContentSidebar, TemplateFooter, };
126
+ export default TemplateAppContainer;
@@ -0,0 +1,16 @@
1
+ import * as React from "react";
2
+ export declare type TextSizes = "default" | "caption" | "tag" | "mini";
3
+ export interface TextProps {
4
+ /** Additional class name to render in the `Text` component. */
5
+ className?: string;
6
+ /** Optional prop used to show bolded text */
7
+ isBold?: boolean;
8
+ /** Optional prop used to show itlicized text */
9
+ isItalic?: boolean;
10
+ /** Optional prop used to remove default spacing */
11
+ noSpace?: boolean;
12
+ /** Optional prop to control the text styling */
13
+ size?: TextSizes;
14
+ }
15
+ export declare const Text: import("@chakra-ui/react").ChakraComponent<(props: React.PropsWithChildren<TextProps>) => JSX.Element, {}>;
16
+ export default Text;
@@ -0,0 +1,79 @@
1
+ import * as React from "react";
2
+ import { HelperErrorTextType } from "../HelperErrorText/HelperErrorText";
3
+ export declare type TextInputTypes = "email" | "hidden" | "number" | "password" | "text" | "textarea" | "tel" | "url";
4
+ export declare const TextInputFormats: {
5
+ email: string;
6
+ hidden: string;
7
+ password: string;
8
+ text: string;
9
+ tel: string;
10
+ textarea: string;
11
+ url: string;
12
+ };
13
+ export declare type TextInputVariants = "default" | "searchBar" | "searchBarSelect";
14
+ export interface InputProps {
15
+ /** A class name for the TextInput parent div. */
16
+ className?: string;
17
+ /** The starting value of the input field. */
18
+ defaultValue?: string;
19
+ /** Populates the HelperErrorText for the standard state */
20
+ helperText?: HelperErrorTextType;
21
+ /** ID that other components can cross reference for accessibility purposes */
22
+ id: string;
23
+ /** Populates the HelperErrorText for the error state */
24
+ invalidText?: HelperErrorTextType;
25
+ /** Adds the `disabled` and `aria-disabled` prop to the input when true */
26
+ isDisabled?: boolean;
27
+ /** Adds errored styling to the input/textarea and helper text elements */
28
+ isInvalid?: boolean;
29
+ /** Will add `required` and `aria-required` props to the input/textarea elements */
30
+ isRequired?: boolean;
31
+ /** Provides text for a `Label` component if `showLabel` is set to true;
32
+ * populates an `aria-label` attribute if `showLabel` is set to false. */
33
+ labelText: string;
34
+ /** The max number for a `number` TextInput type. */
35
+ max?: number;
36
+ /** The max length of the input field. This prop is for all input types
37
+ * except for the `number` type. */
38
+ maxLength?: number;
39
+ /** The min number for a `number` TextInput type. */
40
+ min?: number;
41
+ /** Used to reference the input element in forms. */
42
+ name?: string;
43
+ /** The action to perform on the `input`/`textarea`'s onChange function */
44
+ onChange?: (event: React.ChangeEvent<HTMLInputElement> | React.ChangeEvent<HTMLTextAreaElement>) => void;
45
+ /** The action to perform on the `input`/`textarea`'s onClick function */
46
+ onClick?: (event: React.MouseEvent<HTMLInputElement, MouseEvent>) => void;
47
+ /** The action to perform on the `input`/`textarea`'s onFocus function */
48
+ onFocus?: (event: React.FocusEvent<HTMLInputElement>) => void;
49
+ /** Populates the placeholder for the input/textarea elements */
50
+ placeholder?: string;
51
+ /** Offers the ability to hide the helper/invalid text. */
52
+ showHelperInvalidText?: boolean;
53
+ /** Offers the ability to show the label onscreen or hide it. Refer to the
54
+ * `labelText` property for more information. */
55
+ showLabel?: boolean;
56
+ /** Whether or not to display the "(Required)" text in the label text.
57
+ * True by default. */
58
+ showRequiredLabel?: boolean;
59
+ /** The amount to increase or decrease when using the number type. */
60
+ step?: number;
61
+ /** FOR INTERNAL DS USE ONLY: the input variant to display. */
62
+ textInputType?: TextInputVariants;
63
+ /** HTML Input types as defined by MDN: https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input */
64
+ type?: TextInputTypes;
65
+ /** Populates the value of the input/textarea elements */
66
+ value?: string;
67
+ }
68
+ /**
69
+ * The type used for `ref`s. We want to extend both `input` and `textarea`
70
+ * since both are available to create through `TextInput`.
71
+ */
72
+ export declare type TextInputRefType = HTMLInputElement & HTMLTextAreaElement;
73
+ /**
74
+ * Renders either an `input` element with a specified type or a `textarea`
75
+ * element. All types will render an accessible `Label` component and an
76
+ * optional `HelperErrorText` component.
77
+ */
78
+ export declare const TextInput: import("@chakra-ui/react").ChakraComponent<React.ForwardRefExoticComponent<InputProps & React.RefAttributes<TextInputRefType>>, {}>;
79
+ export default TextInput;
@@ -0,0 +1,42 @@
1
+ import * as React from "react";
2
+ import { HelperErrorTextType } from "../HelperErrorText/HelperErrorText";
3
+ export declare type ToggleSizes = "default" | "small";
4
+ export interface ToggleProps {
5
+ /** Used for uncontrolled scenarios. Sets the state of the Toggle when the page first loads.
6
+ * If true, the toggle will be initially set to the "on" position. */
7
+ defaultChecked?: boolean;
8
+ /** Optional string to populate the HelperErrorText for standard state */
9
+ helperText?: HelperErrorTextType;
10
+ /** ID that other components can cross reference for accessibility purposes */
11
+ id: string;
12
+ /** Optional string to populate the HelperErrorText for the error state
13
+ * when `isInvalid` is true. */
14
+ invalidText?: HelperErrorTextType;
15
+ /** When using the Toggle as a "controlled" form element, you can specify
16
+ * the Toggle's checked state using this prop.
17
+ * Learn more about controlled and uncontrolled form fields:
18
+ * https://goshakkk.name/controlled-vs-uncontrolled-inputs-react/ */
19
+ isChecked?: boolean;
20
+ /** Adds the 'disabled' and `aria-disabled` attributes to the input when true.
21
+ * This also makes the text italic and color scheme gray. */
22
+ isDisabled?: boolean;
23
+ /** Adds the 'aria-invalid' attribute to the input when true. */
24
+ isInvalid?: boolean;
25
+ /** Adds the 'required' attribute to the input when true. */
26
+ isRequired?: boolean;
27
+ /** The toggle's label. This will serve as the text content for the `<label>` element */
28
+ labelText: string;
29
+ /** The name prop indicates the `Toggle`'s form element name. If none is
30
+ * specified, 'default' will be used. */
31
+ name?: string;
32
+ /** The action to perform on the `<input>`'s onChange function */
33
+ onChange?: (event: React.ChangeEvent<HTMLInputElement>) => void;
34
+ /** The size of the Toggle. Defaults to "large". */
35
+ size?: ToggleSizes;
36
+ }
37
+ export declare const onChangeDefault: () => void;
38
+ /**
39
+ * Component that renders Chakra's `Switch` component along with NYPL defaults.
40
+ */
41
+ export declare const Toggle: import("@chakra-ui/react").ChakraComponent<React.ForwardRefExoticComponent<ToggleProps & React.RefAttributes<HTMLInputElement>>, {}>;
42
+ export default Toggle;
@@ -0,0 +1,38 @@
1
+ import * as React from "react";
2
+ import { HelperErrorTextType } from "../HelperErrorText/HelperErrorText";
3
+ export declare type VideoPlayerTypes = "vimeo" | "youtube";
4
+ export declare type VideoPlayerAspectRatios = "fourByThree" | "sixteenByNine" | "square";
5
+ export interface VideoPlayerProps {
6
+ /** Optional aspect ratio prop to control the sizing of the video player; if
7
+ * omitted, the video player defaults to `sixteen-by-nine` */
8
+ aspectRatio?: VideoPlayerAspectRatios;
9
+ /** Optional className you can add in addition to `video-player` */
10
+ className?: string;
11
+ /** Optional string to set the text for a video description */
12
+ descriptionText?: string;
13
+ /** Optional string to set a code snippet provided by YouTube or Vimeo; the
14
+ * `videoPlayer` component will accept the `embedCode` prop or the `videoId`
15
+ * and `videoType` props */
16
+ embedCode?: string;
17
+ /** Optional string to set the text for a `Heading` component */
18
+ headingText?: string;
19
+ /** Optional string to set the text for a `HelperErrorText` component */
20
+ helperText?: HelperErrorTextType;
21
+ /** ID that other components can cross reference for accessibility purposes */
22
+ id?: string;
23
+ /** Optional title to be added to the `<iframe>` element for improved
24
+ * accessibility; this title should describe in a few words the content of
25
+ * the video; if omitted, a generic title will be added; if a `title`
26
+ * attribute is already present in the `embedCode` prop, this prop will be
27
+ * ignored */
28
+ iframeTitle?: string;
29
+ /** Offers the ability to hide the helper/invalid text. */
30
+ showHelperInvalidText?: boolean;
31
+ /** Required YouTube or Vimeo video ID. This value can be pulled from a
32
+ * video's YouTube or Vimeo URL. */
33
+ videoId?: string;
34
+ /** Required. Used to specify which video service is being used. */
35
+ videoType?: VideoPlayerTypes;
36
+ }
37
+ export declare const VideoPlayer: import("@chakra-ui/react").ChakraComponent<(props: React.PropsWithChildren<VideoPlayerProps>) => JSX.Element, {}>;
38
+ export default VideoPlayer;