@nypl/design-system-react-components 3.4.0-rc → 3.4.0-rc-hero
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.
|
@@ -4,8 +4,6 @@ import { ComponentImageProps } from "../Image/Image";
|
|
|
4
4
|
export declare const heroTypesArray: readonly ["primary", "secondary", "secondaryBooksAndMore", "secondaryLocations", "secondaryResearch", "secondaryWhatsOn", "tertiary", "campaign", "fiftyFifty"];
|
|
5
5
|
export type HeroTypes = typeof heroTypesArray[number];
|
|
6
6
|
export declare const heroSecondaryTypes: string[];
|
|
7
|
-
export interface HeroImageProps extends Pick<ComponentImageProps, "alt" | "fallbackSrc" | "id" | "src" | "onError"> {
|
|
8
|
-
}
|
|
9
7
|
export interface HeroProps {
|
|
10
8
|
/**
|
|
11
9
|
* Optional background color for the backdrop only in the `campaign` variant.
|
|
@@ -38,7 +36,7 @@ export interface HeroProps {
|
|
|
38
36
|
* the "secondary", "fiftyFifty" and "campaign" `Hero` types; Note: `imageProps.src`
|
|
39
37
|
* can only be used in conjunction with `backgroundImageSrc` for the "campaign"
|
|
40
38
|
* `Hero` type. Note: not all `Hero` variations utilize this prop. */
|
|
41
|
-
imageProps?:
|
|
39
|
+
imageProps?: ComponentImageProps;
|
|
42
40
|
/** Optional boolean used to toggle the default text color from light to dark.
|
|
43
41
|
* Set isDarkText to `true` if the backgroundColor is set to a light color. */
|
|
44
42
|
isDarkText?: boolean;
|
package/dist/src/index.d.ts
CHANGED
|
@@ -40,7 +40,7 @@ export type { HeadingLevels, HeadingProps, HeadingSizes, } from "./components/He
|
|
|
40
40
|
export { default as HelperErrorText } from "./components/HelperErrorText/HelperErrorText";
|
|
41
41
|
export type { HelperErrorTextProps } from "./components/HelperErrorText/HelperErrorText";
|
|
42
42
|
export { default as Hero } from "./components/Hero/Hero";
|
|
43
|
-
export type {
|
|
43
|
+
export type { HeroProps, HeroTypes } from "./components/Hero/Hero";
|
|
44
44
|
export { default as HorizontalRule } from "./components/HorizontalRule/HorizontalRule";
|
|
45
45
|
export type { HorizontalRuleProps } from "./components/HorizontalRule/HorizontalRule";
|
|
46
46
|
export { default as Icon } from "./components/Icons/Icon";
|
|
@@ -40,7 +40,14 @@ declare const _default: {
|
|
|
40
40
|
TemplateContent: {
|
|
41
41
|
baseStyle?: {
|
|
42
42
|
gridColumn: string;
|
|
43
|
-
display:
|
|
43
|
+
display: {
|
|
44
|
+
base: "flex";
|
|
45
|
+
md: "grid";
|
|
46
|
+
};
|
|
47
|
+
flexDirection: {
|
|
48
|
+
base: "column";
|
|
49
|
+
md: any;
|
|
50
|
+
};
|
|
44
51
|
gridTemplateColumns: string;
|
|
45
52
|
paddingY: number;
|
|
46
53
|
paddingX: string;
|
|
@@ -109,12 +116,20 @@ declare const _default: {
|
|
|
109
116
|
minWidth: {
|
|
110
117
|
md: number;
|
|
111
118
|
};
|
|
119
|
+
overflow: {
|
|
120
|
+
base: "unset";
|
|
121
|
+
md: "hidden";
|
|
122
|
+
};
|
|
112
123
|
};
|
|
113
124
|
right: {
|
|
114
125
|
gridColumn: {
|
|
115
126
|
base: "1";
|
|
116
127
|
md: "1";
|
|
117
128
|
};
|
|
129
|
+
overflow: {
|
|
130
|
+
base: "unset";
|
|
131
|
+
md: "hidden";
|
|
132
|
+
};
|
|
118
133
|
};
|
|
119
134
|
};
|
|
120
135
|
defaultProps?: {
|