@royaloperahouse/harmonic 0.12.1 → 0.13.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/CHANGELOG.md +3 -0
- package/dist/components/Typography/Typography.d.ts +277 -6
- package/dist/components/atoms/Buttons/Secondary/utils.d.ts +4 -4
- package/dist/components/atoms/RotatorButtons/RotatorButtons.d.ts +1 -1
- package/dist/components/atoms/RotatorButtons/RotatorButtons.style.d.ts +1 -0
- package/dist/components/atoms/SectionSplitter/SectionSplitter.d.ts +1 -1
- package/dist/components/atoms/TextField/TextField.style.d.ts +1 -1
- package/dist/components/index.d.ts +2 -2
- package/dist/components/molecules/Accordion/Accordion.style.d.ts +8 -4
- package/dist/components/molecules/BodyContent/BodyContent.d.ts +4 -0
- package/dist/components/molecules/BodyContent/BodyContent.style.d.ts +1 -0
- package/dist/components/molecules/BodyContent/index.d.ts +2 -0
- package/dist/components/molecules/Card/Card.style.d.ts +1 -1
- package/dist/components/molecules/ContactCard/ContactCard.style.d.ts +5 -4
- package/dist/components/molecules/ContentSummary/ContentSummary.style.d.ts +1 -1
- package/dist/components/molecules/Editorial/Editorial.style.d.ts +2 -2
- package/dist/components/molecules/ImageWithCaption/ImageWithCaption.style.d.ts +1 -1
- package/dist/components/molecules/Information/Information.style.d.ts +1 -1
- package/dist/components/molecules/PageHeading/Promo/Promo.d.ts +1 -2
- package/dist/components/molecules/PromoWithTags/PromoWithTags.style.d.ts +273 -6
- package/dist/components/molecules/PromoWithTitle/PromoWithTitle.style.d.ts +1 -1
- package/dist/components/molecules/Quote/Quote.style.d.ts +3 -4
- package/dist/components/molecules/SectionTitle/SectionTitle.d.ts +1 -1
- package/dist/components/molecules/index.d.ts +1 -3
- package/dist/components/organisms/AnchorTabBar/AnchorTabBar.style.d.ts +8 -3
- package/dist/components/organisms/Carousels/Carousel/Carousel.style.d.ts +271 -0
- package/dist/components/organisms/StickyBar/StickyBar.style.d.ts +1 -1
- package/dist/harmonic.cjs.development.css +26 -16
- package/dist/harmonic.cjs.development.js +2486 -2479
- package/dist/harmonic.cjs.development.js.map +1 -1
- package/dist/harmonic.cjs.production.min.js +1 -1
- package/dist/harmonic.cjs.production.min.js.map +1 -1
- package/dist/harmonic.esm.js +4740 -4734
- package/dist/harmonic.esm.js.map +1 -1
- package/dist/index.d.ts +6 -3
- package/dist/styles/HarmonicThemeProvider/HarmonicThemeProvider.d.ts +3 -0
- package/dist/styles/HarmonicThemeProvider/index.d.ts +2 -1
- package/dist/types/buttonTypes.d.ts +6 -2
- package/dist/types/contactCard.d.ts +8 -22
- package/dist/types/editorial.d.ts +6 -20
- package/dist/types/image.d.ts +5 -9
- package/dist/types/impactHeader.d.ts +2 -0
- package/dist/types/information.d.ts +23 -43
- package/dist/types/navigation.d.ts +31 -61
- package/dist/types/promoWithTags.d.ts +9 -1
- package/dist/types/quote.d.ts +4 -15
- package/dist/types/types.d.ts +26 -71
- package/dist/types/typography.d.ts +9 -1
- package/package.json +1 -1
- package/dist/components/molecules/TextOnly/TextOnly.d.ts +0 -4
- package/dist/components/molecules/TextOnly/TextOnly.style.d.ts +0 -1
- package/dist/components/molecules/TextOnly/index.d.ts +0 -2
package/dist/index.d.ts
CHANGED
|
@@ -1,11 +1,14 @@
|
|
|
1
|
-
import { Accordion, Accordions, AnchorBar, AnnouncementBanner, AltHeader, AnchorTabBar, AuxiliaryNav, BodyText, Card, Cards, Carousel, CinemaBadge, ContactCard, ContentSummary, ControlledDropdown, CreditListing, Editorial, Footer, GlobalStyles, Grid, GridItem, Header, HighlightsCarousel, HighlightsCarouselCinema, HighlightsCarouselCore, HighlightsCarouselStream, HotFilters, Icon, ImageAspectRatioWrapper, ImageWithCaption, Information, Navigation, MinimalCarousel, Overline, PageHeading, PageHeadingCompact, PageHeadingImpact, PageHeadingPanel, PageHeadingPromo, Pagination, PasswordStrength, PeopleListing, PrimaryButton, Progress, PromoWithTags, PromoWithTitle, Radio, Radio2, RadioGroup, RadioGroup2, ReadMore, RotatorButtons, StatusBanner, SearchBar, SecondaryButton, SecondaryLogo, SectionSplitter, SectionTitle, Select, Select2, Select2Async, SignUpForm, Sponsorship, StickyBar, Stepper, StreamBadge, Subtitle, TertiaryButton,
|
|
1
|
+
import { Accordion, Accordions, AnchorBar, AnnouncementBanner, AltHeader, AnchorTabBar, AuxiliaryNav, BodyText, Card, Cards, Carousel, CinemaBadge, ContactCard, ContentSummary, ControlledDropdown, CreditListing, Editorial, Footer, GlobalStyles, Grid, GridItem, Header, HighlightsCarousel, HighlightsCarouselCinema, HighlightsCarouselCore, HighlightsCarouselStream, HotFilters, Icon, ImageAspectRatioWrapper, ImageWithCaption, Information, Navigation, MinimalCarousel, Overline, PageHeading, PageHeadingCompact, PageHeadingImpact, PageHeadingPanel, PageHeadingPromo, Pagination, PasswordStrength, PeopleListing, PrimaryButton, Progress, PromoWithTags, PromoWithTitle, Radio, Radio2, RadioGroup, RadioGroup2, ReadMore, RotatorButtons, StatusBanner, SearchBar, SecondaryButton, SecondaryLogo, SectionSplitter, SectionTitle, Select, Select2, Select2Async, SignUpForm, Sponsorship, StickyBar, Stepper, StreamBadge, Subtitle, TertiaryButton, ThemeProvider, TitleWithCTA, Tab, Table, TabLink, Tabs, TextArea, TextField, TextFieldLegacy, TextLink, Tickbox, Tickbox2, Timer, TypeTags, UpsellCard, UpsellSection, VideoControls, VideoWithControls } from './components';
|
|
2
|
+
import BodyContent from './components/molecules/BodyContent';
|
|
3
|
+
import Quote from './components/molecules/Quote';
|
|
2
4
|
import { devices, breakpoints } from './styles/viewports';
|
|
3
5
|
import zIndexes from './styles/zIndexes';
|
|
4
6
|
import { AspectRatio, ButtonType, CarouselType, Colors, IconNameType, IntegratedTimerProps, ITimerProps, TickboxMode, ThemeColor, ThemeType, EditorialLink, IInformationTitleProps, IInformationCTAProps } from './types';
|
|
5
7
|
import { MiniCard } from './components/molecules';
|
|
6
8
|
import { ModalWindow } from './components/organisms';
|
|
7
9
|
import AuxiliaryButton from './components/atoms/Buttons/Auxiliary/AuxiliaryButton';
|
|
8
|
-
import HarmonicThemeProvider from './styles/HarmonicThemeProvider';
|
|
10
|
+
import HarmonicThemeProvider, { useHarmonicTheme } from './styles/HarmonicThemeProvider';
|
|
9
11
|
import { HarmonicSize } from './types/typography';
|
|
10
12
|
import { HarmonicHeader, HarmonicSubtitle, BodyCopyHarmonic, HarmonicOverline, ButtonText, Caption, NavigationText } from './components/Typography';
|
|
11
|
-
export {
|
|
13
|
+
export { useHarmonicTheme };
|
|
14
|
+
export { Accordion, Accordions, AnchorBar, AnnouncementBanner, AltHeader, AnchorTabBar, AuxiliaryButton, AuxiliaryNav, AspectRatio, BodyContent, BodyText, breakpoints, ButtonType, Card, Cards, CarouselType, Carousel, CinemaBadge, Colors, ContactCard, ContentSummary, ControlledDropdown, CreditListing, devices, Editorial, EditorialLink, Footer, GlobalStyles, Grid, GridItem, HarmonicSize, HarmonicThemeProvider, Header, HighlightsCarousel, HighlightsCarouselCinema, HighlightsCarouselCore, HighlightsCarouselStream, HotFilters, Icon, IconNameType, ImageAspectRatioWrapper, ImageWithCaption, Information, IInformationCTAProps, IInformationTitleProps, ITimerProps, IntegratedTimerProps, MinimalCarousel, MiniCard, ModalWindow, Navigation, Overline, PageHeading, PageHeadingCompact, PageHeadingImpact, PageHeadingPanel, PageHeadingPromo, Pagination, PasswordStrength, PeopleListing, PrimaryButton, Progress, PromoWithTags, PromoWithTitle, Radio, Radio2, RadioGroup, RadioGroup2, ReadMore, RotatorButtons, StatusBanner, SearchBar, SecondaryButton, SecondaryLogo, SectionSplitter, SectionTitle, Select, Select2, Select2Async, SignUpForm, Sponsorship, StickyBar, Stepper, StreamBadge, Subtitle, Tab, Table, TabLink, Tabs, TertiaryButton, TextArea, TextField, TextFieldLegacy, TextLink, ThemeColor, ThemeProvider, ThemeType, TitleWithCTA, Tickbox, Tickbox2, TickboxMode, Timer, TypeTags, UpsellCard, UpsellSection, Quote, VideoControls, VideoWithControls, zIndexes, HarmonicHeader, HarmonicSubtitle, BodyCopyHarmonic, HarmonicOverline, ButtonText, Caption, NavigationText, };
|
|
@@ -1,9 +1,12 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { ThemeType } from '../../types';
|
|
3
3
|
import './theme/fonts.css';
|
|
4
|
+
export declare const DEFAULT_THEME = ThemeType.Core;
|
|
4
5
|
interface HarmonicThemeProviderProps {
|
|
5
6
|
theme: ThemeType;
|
|
6
7
|
children: React.ReactNode;
|
|
7
8
|
}
|
|
9
|
+
export declare const HarmonicThemeContext: React.Context<ThemeType>;
|
|
10
|
+
export declare const useHarmonicTheme: () => ThemeType;
|
|
8
11
|
declare const HarmonicThemeProvider: React.FC<HarmonicThemeProviderProps>;
|
|
9
12
|
export default HarmonicThemeProvider;
|
|
@@ -13,8 +13,6 @@ declare type BaseProps = {
|
|
|
13
13
|
onClick?: MouseEventHandler<HTMLAnchorElement>;
|
|
14
14
|
/** Custom CSS classes */
|
|
15
15
|
className?: string;
|
|
16
|
-
/** Styled Components theme */
|
|
17
|
-
theme?: unknown;
|
|
18
16
|
};
|
|
19
17
|
declare type IconProps = {
|
|
20
18
|
/** Icon identifier */
|
|
@@ -52,6 +50,12 @@ export declare type RotatorButtonsProps = {
|
|
|
52
50
|
onClickPrev?: () => void;
|
|
53
51
|
/** Next button click handler */
|
|
54
52
|
onClickNext?: () => void;
|
|
53
|
+
/** Show fullscreen button */
|
|
54
|
+
showFullscreen?: boolean;
|
|
55
|
+
/** Fullscreen button click handler */
|
|
56
|
+
onClickFullscreen?: () => void;
|
|
57
|
+
/** Is in fullscreen mode */
|
|
58
|
+
isFullscreen?: boolean;
|
|
55
59
|
/** Custom CSS classes */
|
|
56
60
|
className?: string;
|
|
57
61
|
};
|
|
@@ -1,9 +1,12 @@
|
|
|
1
|
-
import { StyledProps } from 'styled-components';
|
|
2
1
|
export interface IContactCardProps {
|
|
3
2
|
/**
|
|
4
|
-
*
|
|
3
|
+
* Title
|
|
5
4
|
*/
|
|
6
|
-
|
|
5
|
+
title: string;
|
|
6
|
+
/**
|
|
7
|
+
* Title suffix
|
|
8
|
+
*/
|
|
9
|
+
titleSuffix?: string;
|
|
7
10
|
/**
|
|
8
11
|
* Description
|
|
9
12
|
*/
|
|
@@ -25,24 +28,7 @@ export interface IContactCardProps {
|
|
|
25
28
|
*/
|
|
26
29
|
address?: string;
|
|
27
30
|
/**
|
|
28
|
-
*
|
|
29
|
-
*/
|
|
30
|
-
hideTopBorder?: boolean;
|
|
31
|
-
/**
|
|
32
|
-
* Set visibility of the top border
|
|
33
|
-
*/
|
|
34
|
-
hideBottomBorder?: boolean;
|
|
35
|
-
}
|
|
36
|
-
export interface IContactCardWrapperProps extends StyledProps<{
|
|
37
|
-
hideTopBorder: boolean;
|
|
38
|
-
hideBottomBorder: boolean;
|
|
39
|
-
}> {
|
|
40
|
-
/**
|
|
41
|
-
* Set visibility of the top border
|
|
42
|
-
*/
|
|
43
|
-
hideTopBorder: boolean;
|
|
44
|
-
/**
|
|
45
|
-
* Set visibility of the bottom border
|
|
31
|
+
* The component's class name
|
|
46
32
|
*/
|
|
47
|
-
|
|
33
|
+
className?: string;
|
|
48
34
|
}
|
|
@@ -5,22 +5,16 @@ import { DirectionType, IconNameType } from './iconTypes';
|
|
|
5
5
|
import { IVideoWithControlsSettings, ThemeColor, ThemeType } from './types';
|
|
6
6
|
import { HarmonicSize, HeaderHierarchy } from './typography';
|
|
7
7
|
export interface IEditorialProps {
|
|
8
|
-
/**
|
|
9
|
-
* Text placed in the editorial component
|
|
10
|
-
*/
|
|
8
|
+
/** Text placed in the editorial component */
|
|
11
9
|
text: string;
|
|
12
|
-
/**
|
|
13
|
-
* Subtitle placed in the editorial component
|
|
14
|
-
*/
|
|
10
|
+
/** Subtitle placed in the editorial component */
|
|
15
11
|
subtitle?: string;
|
|
16
|
-
/**
|
|
17
|
-
* Position of the image in the editorial component
|
|
18
|
-
*/
|
|
12
|
+
/** Position of the image in the editorial component */
|
|
19
13
|
imagePosition?: 'left' | 'right';
|
|
20
|
-
/**
|
|
21
|
-
* Image tag or component to be displayed in the editorial component with aspect ratio 1:1
|
|
22
|
-
*/
|
|
14
|
+
/** Image tag or component to be displayed in the editorial component with aspect ratio 1:1 */
|
|
23
15
|
children: ReactElement<HTMLImageElement>;
|
|
16
|
+
/** Custom CSS classes */
|
|
17
|
+
className?: string;
|
|
24
18
|
}
|
|
25
19
|
export interface IEditorialGridProps {
|
|
26
20
|
/**
|
|
@@ -156,14 +150,6 @@ export interface IThemePageHeadingProps {
|
|
|
156
150
|
* Header Hierarchy for the title. Default is h1.
|
|
157
151
|
*/
|
|
158
152
|
hierarchy: HeaderHierarchy;
|
|
159
|
-
/**
|
|
160
|
-
* Character limit for the text
|
|
161
|
-
*/
|
|
162
|
-
copyCharLimit?: number;
|
|
163
|
-
/**
|
|
164
|
-
* Character limit for the title
|
|
165
|
-
*/
|
|
166
|
-
titleCharLimit?: number;
|
|
167
153
|
/**
|
|
168
154
|
* Class name for theme styling
|
|
169
155
|
*/
|
package/dist/types/image.d.ts
CHANGED
|
@@ -38,17 +38,13 @@ export interface IImageAspectRatioWrapperProps {
|
|
|
38
38
|
alt?: string;
|
|
39
39
|
}
|
|
40
40
|
export interface IImageWithCaptionProps {
|
|
41
|
-
/**
|
|
42
|
-
* Aspect ratio of the contained image
|
|
43
|
-
*/
|
|
41
|
+
/** Aspect ratio of the contained image */
|
|
44
42
|
aspectRatio?: AspectRatio;
|
|
45
|
-
/**
|
|
46
|
-
* Image caption or credit
|
|
47
|
-
*/
|
|
43
|
+
/** Image caption or credit */
|
|
48
44
|
caption: string;
|
|
49
|
-
/**
|
|
50
|
-
|
|
51
|
-
|
|
45
|
+
/** Alternative text describing the image content for accessibility purposes. */
|
|
46
|
+
altText?: string;
|
|
47
|
+
/** Image element */
|
|
52
48
|
children: ReactElement<HTMLImageElement>;
|
|
53
49
|
}
|
|
54
50
|
export interface IImageWithCaptionWrapperProps extends StyledProps<{
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { DirectionType, IconNameType } from './iconTypes';
|
|
2
|
-
import { LinkTarget } from './types';
|
|
3
|
-
import type { ThemeChildProps } from './types';
|
|
2
|
+
import { LinkTarget, ThemeType } from './types';
|
|
4
3
|
import type { HarmonicSize } from './typography';
|
|
5
4
|
export declare const InformationCtaVariants: {
|
|
6
5
|
readonly Primary: "Primary";
|
|
@@ -9,60 +8,41 @@ export declare const InformationCtaVariants: {
|
|
|
9
8
|
readonly TextLink: "TextLink";
|
|
10
9
|
};
|
|
11
10
|
export declare type InformationCtaVariant = keyof typeof InformationCtaVariants;
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
/**
|
|
15
|
-
* Text to display on the CTA
|
|
16
|
-
*/
|
|
11
|
+
export interface IInformationCTAProps {
|
|
12
|
+
/** Text to display on the CTA */
|
|
17
13
|
text: string;
|
|
18
|
-
/**
|
|
19
|
-
* Link for the CTA
|
|
20
|
-
*/
|
|
14
|
+
/** Link for the CTA */
|
|
21
15
|
link: string;
|
|
22
|
-
/**
|
|
23
|
-
* Style of the CTA
|
|
24
|
-
*/
|
|
16
|
+
/** Style of the CTA */
|
|
25
17
|
variant?: InformationCtaVariant;
|
|
26
|
-
/**
|
|
27
|
-
* Name of the icon to be used in the button
|
|
28
|
-
*/
|
|
18
|
+
/** Name of the icon to be used in the button */
|
|
29
19
|
iconName?: IconNameType;
|
|
30
|
-
/**
|
|
31
|
-
* Direction of the icon used in the button
|
|
32
|
-
*/
|
|
20
|
+
/** Direction of the icon used in the button */
|
|
33
21
|
iconDirection?: DirectionType;
|
|
34
|
-
/**
|
|
35
|
-
* Attribute to specify where to open the link
|
|
36
|
-
*/
|
|
22
|
+
/** Attribute to specify where to open the link */
|
|
37
23
|
target?: LinkTarget;
|
|
24
|
+
/** Custom CSS classes */
|
|
25
|
+
className?: string;
|
|
38
26
|
}
|
|
39
|
-
export declare type InformationCTAWrapperProps =
|
|
27
|
+
export declare type InformationCTAWrapperProps = {
|
|
28
|
+
/** Style of the CTA */
|
|
29
|
+
variant: InformationCtaVariant;
|
|
30
|
+
/** Theme options */
|
|
31
|
+
theme?: ThemeType;
|
|
32
|
+
};
|
|
40
33
|
export interface IInformationTitleProps {
|
|
41
|
-
/**
|
|
42
|
-
* Title text to display
|
|
43
|
-
*/
|
|
34
|
+
/** Title text to display */
|
|
44
35
|
text: string;
|
|
45
|
-
/**
|
|
46
|
-
* The size of the title text
|
|
47
|
-
*/
|
|
36
|
+
/** The size of the title text */
|
|
48
37
|
textSize: HarmonicSize;
|
|
49
38
|
}
|
|
50
|
-
export interface IInformationProps
|
|
51
|
-
/**
|
|
52
|
-
* Main body text to display in the Information Component
|
|
53
|
-
*/
|
|
39
|
+
export interface IInformationProps {
|
|
40
|
+
/** Main body text to display in the Information Component */
|
|
54
41
|
body: string;
|
|
55
|
-
/**
|
|
56
|
-
* Optional CTA to display underneath the body text
|
|
57
|
-
*/
|
|
42
|
+
/** Optional CTA to display underneath the body text */
|
|
58
43
|
cta?: IInformationCTAProps;
|
|
59
|
-
/**
|
|
60
|
-
* Title options for the component
|
|
61
|
-
*/
|
|
44
|
+
/** Title options for the component */
|
|
62
45
|
title?: IInformationTitleProps;
|
|
63
|
-
/**
|
|
64
|
-
* Additional CSS class names to apply to component.
|
|
65
|
-
*/
|
|
46
|
+
/** Custom CSS classes */
|
|
66
47
|
className?: string;
|
|
67
48
|
}
|
|
68
|
-
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import React, { AnchorHTMLAttributes,
|
|
1
|
+
import React, { AnchorHTMLAttributes, MouseEventHandler, ReactNode } from 'react';
|
|
2
2
|
import { DirectionType, IconNameType } from './iconTypes';
|
|
3
3
|
import { Colors, IOptionItem, ThemeColor } from './types';
|
|
4
4
|
export interface IAccountProps {
|
|
@@ -275,26 +275,20 @@ export interface IAnchorBarAbsolutePositionParams {
|
|
|
275
275
|
topOffset: number;
|
|
276
276
|
}
|
|
277
277
|
export interface IAnchorBarProps {
|
|
278
|
-
/**
|
|
279
|
-
* Tabs displayed in the anchor bar
|
|
280
|
-
*/
|
|
278
|
+
/** Tabs displayed in the anchor bar */
|
|
281
279
|
tabs: AnchorBarTab[];
|
|
282
|
-
/**
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
onTabClick?: (e: MouseEvent, id: string) => void;
|
|
286
|
-
/**
|
|
287
|
-
* Set the id of the tab actived
|
|
288
|
-
*/
|
|
280
|
+
/** Function to be called when a tab is clicked */
|
|
281
|
+
onTabClick?: (e: React.MouseEvent<HTMLAnchorElement>, id: string) => void;
|
|
282
|
+
/** Set the id of the active tab */
|
|
289
283
|
activeTab?: string;
|
|
290
|
-
/**
|
|
291
|
-
* Only for IOS devices that do not fully support sticky position, in case a keyboard is opened on the device
|
|
292
|
-
*/
|
|
284
|
+
/** Only for IOS devices that do not fully support sticky position, in case a keyboard is opened on the device */
|
|
293
285
|
absolutePositionParams?: IAnchorBarAbsolutePositionParams;
|
|
294
|
-
/**
|
|
295
|
-
* Boolean to set bottom border
|
|
296
|
-
*/
|
|
286
|
+
/** Boolean to set bottom border */
|
|
297
287
|
bottomBorder?: boolean;
|
|
288
|
+
/** Flag indicating whether the bar should have a shadow */
|
|
289
|
+
withShadow?: boolean;
|
|
290
|
+
/** Custom CSS classes */
|
|
291
|
+
className?: string;
|
|
298
292
|
}
|
|
299
293
|
export interface ITitleCTAProps {
|
|
300
294
|
/**
|
|
@@ -331,64 +325,40 @@ export interface IAnchorTabsListProps {
|
|
|
331
325
|
hasTwoArrows: boolean;
|
|
332
326
|
}
|
|
333
327
|
export interface IAnchorTabBarBorderProps {
|
|
334
|
-
/**
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
}
|
|
339
|
-
export interface IAnchorTabArrowsBoxProps {
|
|
340
|
-
/**
|
|
341
|
-
* Boolean to determine width of the arrows container
|
|
342
|
-
*/
|
|
343
|
-
fullWidth: boolean;
|
|
328
|
+
/** Boolean to set bottom border */
|
|
329
|
+
bottomBorder?: boolean;
|
|
330
|
+
/** Flag indicating whether the anchor bar should have a shadow */
|
|
331
|
+
withShadow?: boolean;
|
|
344
332
|
}
|
|
345
333
|
export interface ITabLinkProps extends AnchorHTMLAttributes<HTMLAnchorElement> {
|
|
346
334
|
children: ReactNode;
|
|
347
|
-
/**
|
|
348
|
-
* Function to be called when a button is clicked
|
|
349
|
-
*/
|
|
335
|
+
/** Function to be called when a button is clicked */
|
|
350
336
|
onClick?: MouseEventHandler<HTMLAnchorElement>;
|
|
351
|
-
/**
|
|
352
|
-
* Name of the icon to be used in the button
|
|
353
|
-
*/
|
|
337
|
+
/** Name of the icon to be used in the button */
|
|
354
338
|
iconName?: IconNameType;
|
|
355
|
-
/**
|
|
356
|
-
* Direction of the icon used in the button
|
|
357
|
-
*/
|
|
339
|
+
/** Direction of the icon used in the button */
|
|
358
340
|
iconDirection?: DirectionType;
|
|
359
|
-
/**
|
|
360
|
-
* Color of text and icon
|
|
361
|
-
*/
|
|
341
|
+
/** Color of text and icon */
|
|
362
342
|
color?: ThemeColor;
|
|
363
|
-
/**
|
|
364
|
-
* Color of text and icon on hover
|
|
365
|
-
*/
|
|
343
|
+
/** Color of text and icon on hover */
|
|
366
344
|
hoverColor?: ThemeColor;
|
|
367
|
-
/**
|
|
368
|
-
* Set if tab is selected or not
|
|
369
|
-
*/
|
|
345
|
+
/** Set if tab is selected or not */
|
|
370
346
|
selected?: boolean;
|
|
347
|
+
/** Custom CSS classes */
|
|
348
|
+
className?: string;
|
|
371
349
|
}
|
|
372
350
|
export interface IStickyBarProps {
|
|
373
351
|
children: ReactNode;
|
|
374
|
-
/**
|
|
375
|
-
* Set columnstart in Desktop
|
|
376
|
-
*/
|
|
352
|
+
/** Set columnStart in Desktop */
|
|
377
353
|
columnStartDesktop?: number;
|
|
378
|
-
/**
|
|
379
|
-
* Set columnSpan in Desktop
|
|
380
|
-
*/
|
|
354
|
+
/** Set columnSpan in Desktop */
|
|
381
355
|
columnSpanDesktop?: number;
|
|
382
|
-
/**
|
|
383
|
-
* Set columnstart in Device
|
|
384
|
-
*/
|
|
356
|
+
/** Set columnStart in Device */
|
|
385
357
|
columnStartDevice?: number;
|
|
386
|
-
/**
|
|
387
|
-
* Set columnSpam in Device
|
|
388
|
-
*/
|
|
358
|
+
/** Set columnSpan in Device */
|
|
389
359
|
columnSpanDevice?: number;
|
|
390
|
-
/**
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
360
|
+
/** Boolean to set bottom border */
|
|
361
|
+
bottomBorder?: boolean;
|
|
362
|
+
/** Custom CSS classes */
|
|
363
|
+
className?: string;
|
|
394
364
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ReactElement } from 'react';
|
|
2
|
-
import { EditorialLink, PromoLinks } from './editorial';
|
|
2
|
+
import { EditorialLink, PromoLinks, PromoTitleHierarchy } from './editorial';
|
|
3
3
|
import { IntegratedTimerProps } from './timer';
|
|
4
4
|
import { Image } from './types';
|
|
5
5
|
export interface IPromoWithTagsProps {
|
|
@@ -15,6 +15,10 @@ export interface IPromoWithTagsProps {
|
|
|
15
15
|
* Title size
|
|
16
16
|
*/
|
|
17
17
|
titleSize?: 'small' | 'large';
|
|
18
|
+
/**
|
|
19
|
+
* Semantic level of the promo title header - h2 or h3.
|
|
20
|
+
*/
|
|
21
|
+
titleHierarchy: PromoTitleHierarchy;
|
|
18
22
|
/**
|
|
19
23
|
* Subtitle placed in the editorial component
|
|
20
24
|
*/
|
|
@@ -82,4 +86,8 @@ export interface IPromoWithTagsStyledProps {
|
|
|
82
86
|
* Sets margin for the tags container
|
|
83
87
|
*/
|
|
84
88
|
marginBottom?: number;
|
|
89
|
+
/**
|
|
90
|
+
* Sets mobile margin for the tags container
|
|
91
|
+
*/
|
|
92
|
+
mobileMarginBottom?: number;
|
|
85
93
|
}
|
package/dist/types/quote.d.ts
CHANGED
|
@@ -1,19 +1,8 @@
|
|
|
1
|
-
import { StyledProps } from 'styled-components';
|
|
2
1
|
export interface IQuoteProps {
|
|
3
|
-
/**
|
|
4
|
-
* Text placed in the Quote component
|
|
5
|
-
*/
|
|
2
|
+
/** Text placed in the Quote component */
|
|
6
3
|
text: string;
|
|
7
|
-
/**
|
|
8
|
-
* Attribution under the main text
|
|
9
|
-
*/
|
|
4
|
+
/** Attribution under the main text */
|
|
10
5
|
attribution?: string;
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
displayAttribution: boolean;
|
|
14
|
-
}> {
|
|
15
|
-
/**
|
|
16
|
-
* Set visibility of the attribution block
|
|
17
|
-
*/
|
|
18
|
-
displayAttribution: boolean;
|
|
6
|
+
/** Custom CSS classes */
|
|
7
|
+
className?: string;
|
|
19
8
|
}
|
package/dist/types/types.d.ts
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { ReactNode, AnchorHTMLAttributes, MouseEventHandler, ReactElement } from 'react';
|
|
2
2
|
import { StyledProps } from 'styled-components';
|
|
3
3
|
import { IconNameType, DirectionType } from './iconTypes';
|
|
4
|
-
import { TypographyLevel, TypographyType } from './typography';
|
|
5
4
|
import type { ExternalLink } from './links';
|
|
6
5
|
export declare enum Colors {
|
|
7
6
|
White = "white",
|
|
@@ -53,14 +52,8 @@ export declare enum ThemeType {
|
|
|
53
52
|
Cinema = "cinema",
|
|
54
53
|
Schools = "schools"
|
|
55
54
|
}
|
|
56
|
-
export declare type ThemeChildProps = {
|
|
57
|
-
className?: string;
|
|
58
|
-
theme?: ThemeType;
|
|
59
|
-
};
|
|
60
55
|
export interface IThemeProviderProps {
|
|
61
|
-
/**
|
|
62
|
-
* The theme to use for the child elements
|
|
63
|
-
*/
|
|
56
|
+
/** The theme to use for the child elements */
|
|
64
57
|
theme: ThemeType;
|
|
65
58
|
children: ReactNode;
|
|
66
59
|
}
|
|
@@ -458,10 +451,10 @@ export interface ITextLinkProps extends AnchorHTMLAttributes<HTMLAnchorElement>
|
|
|
458
451
|
textColor?: ThemeColor;
|
|
459
452
|
}
|
|
460
453
|
export interface ISectionSplitterProps {
|
|
461
|
-
/**
|
|
462
|
-
* Set the width of the Section to full
|
|
463
|
-
*/
|
|
454
|
+
/** Set the width of the Section to full */
|
|
464
455
|
fullWidth?: boolean;
|
|
456
|
+
/** Custom CSS classes */
|
|
457
|
+
className?: string;
|
|
465
458
|
}
|
|
466
459
|
export interface ITypeTagsProps {
|
|
467
460
|
/**
|
|
@@ -469,46 +462,30 @@ export interface ITypeTagsProps {
|
|
|
469
462
|
*/
|
|
470
463
|
list: string[];
|
|
471
464
|
}
|
|
472
|
-
export interface
|
|
473
|
-
/**
|
|
474
|
-
* Text placed in the TextOnly component
|
|
475
|
-
*/
|
|
465
|
+
export interface IBodyContentProps {
|
|
466
|
+
/** Text placed in the BodyContent component */
|
|
476
467
|
text: string;
|
|
477
|
-
/**
|
|
478
|
-
* Set columnstart in Desktop
|
|
479
|
-
*/
|
|
468
|
+
/** Set columnStart in Desktop */
|
|
480
469
|
columnStartDesktop?: number;
|
|
481
|
-
/**
|
|
482
|
-
* Set columnSpan in Desktop
|
|
483
|
-
*/
|
|
470
|
+
/** Set columnSpan in Desktop */
|
|
484
471
|
columnSpanDesktop?: number;
|
|
485
|
-
/**
|
|
486
|
-
* Set columnstart in Device
|
|
487
|
-
*/
|
|
472
|
+
/** Set columnStart in Device */
|
|
488
473
|
columnStartDevice?: number;
|
|
489
|
-
/**
|
|
490
|
-
* Set columnSpam in Device
|
|
491
|
-
*/
|
|
474
|
+
/** Set columnSpan in Device */
|
|
492
475
|
columnSpanDevice?: number;
|
|
476
|
+
/** Custom CSS classes */
|
|
477
|
+
className?: string;
|
|
493
478
|
}
|
|
494
479
|
export declare type SectionTitleSize = 'small' | 'large';
|
|
495
480
|
export interface ISectionTitleProps {
|
|
496
|
-
/**
|
|
497
|
-
* Title to display.
|
|
498
|
-
*/
|
|
481
|
+
/** Title to display. */
|
|
499
482
|
title: string;
|
|
500
|
-
/**
|
|
501
|
-
* Size of title to display - by default small, which renders as an H2 (and large is an H1).
|
|
502
|
-
*/
|
|
483
|
+
/** Size of title to display - by default small, which renders as an H2 (and large is an H1). */
|
|
503
484
|
size?: SectionTitleSize;
|
|
504
|
-
/**
|
|
505
|
-
* Optional description that can be rendered below the title.
|
|
506
|
-
*/
|
|
485
|
+
/** Optional description that can be rendered below the title. */
|
|
507
486
|
description?: string;
|
|
508
|
-
/**
|
|
509
|
-
|
|
510
|
-
*/
|
|
511
|
-
semanticLevel?: TypographyLevel;
|
|
487
|
+
/** Custom CSS classes */
|
|
488
|
+
className?: string;
|
|
512
489
|
}
|
|
513
490
|
export interface ILogosProps {
|
|
514
491
|
/**
|
|
@@ -531,44 +508,22 @@ export interface ILogosStyledProps extends StyledProps<any> {
|
|
|
531
508
|
fillColor?: Colors.White | Colors.Black;
|
|
532
509
|
}
|
|
533
510
|
export interface IAccordionProps {
|
|
534
|
-
/**
|
|
535
|
-
* Title to display.
|
|
536
|
-
*/
|
|
511
|
+
/** Title to display. */
|
|
537
512
|
title?: string;
|
|
538
|
-
/**
|
|
539
|
-
* The component to be wrapped into the accordion
|
|
540
|
-
*/
|
|
513
|
+
/** The component to be wrapped into the accordion */
|
|
541
514
|
children?: ReactNode;
|
|
542
|
-
/**
|
|
543
|
-
* Components wrapped into the accordion that are always visible
|
|
544
|
-
*/
|
|
545
|
-
visibleStandfirst?: ReactNode;
|
|
546
|
-
/**
|
|
547
|
-
* Set if accordions are stacked
|
|
548
|
-
*/
|
|
515
|
+
/** Set if accordions are stacked */
|
|
549
516
|
showLine?: boolean;
|
|
550
|
-
/**
|
|
551
|
-
* Set init open
|
|
552
|
-
*/
|
|
517
|
+
/** Set init open */
|
|
553
518
|
initOpen?: boolean;
|
|
554
|
-
/**
|
|
555
|
-
|
|
556
|
-
*/
|
|
557
|
-
contentType?: TypographyType;
|
|
558
|
-
/**
|
|
559
|
-
* Set display level - aesthetic
|
|
560
|
-
*/
|
|
561
|
-
displayLevel?: TypographyLevel;
|
|
562
|
-
/**
|
|
563
|
-
* Set semantic level - not to be used for aesthetic
|
|
564
|
-
*/
|
|
565
|
-
semanticLevel?: TypographyLevel;
|
|
519
|
+
/** Custom CSS classes */
|
|
520
|
+
className?: string;
|
|
566
521
|
}
|
|
567
522
|
export interface IAccordionsProps {
|
|
568
|
-
/**
|
|
569
|
-
* Array of Accordion component
|
|
570
|
-
*/
|
|
523
|
+
/** Array of Accordion component */
|
|
571
524
|
items: IAccordionProps[];
|
|
525
|
+
/** Custom CSS classes */
|
|
526
|
+
className?: string;
|
|
572
527
|
}
|
|
573
528
|
export declare const BannerVariants: {
|
|
574
529
|
readonly 'service-persistent': "service-persistent";
|
|
@@ -22,8 +22,16 @@ export interface IGenericTypographyProps<T extends HTMLElement = HTMLParagraphEl
|
|
|
22
22
|
bold?: boolean;
|
|
23
23
|
className?: string;
|
|
24
24
|
}
|
|
25
|
-
export
|
|
25
|
+
export declare type HarmonicHeaderProps = (IGenericTypographyProps<HTMLHeadingElement> & {
|
|
26
26
|
hierarchy: HeaderHierarchy;
|
|
27
|
+
tag?: never;
|
|
28
|
+
}) | (IGenericTypographyProps<HTMLHeadingElement> & {
|
|
29
|
+
tag?: React.ElementType;
|
|
30
|
+
hierarchy?: never;
|
|
31
|
+
});
|
|
32
|
+
export interface ITaggedTypographyProps extends IGenericTypographyProps {
|
|
33
|
+
/** Specifies the HTML tag for rendering typography. The default is 'p'. */
|
|
34
|
+
tag?: React.ElementType;
|
|
27
35
|
}
|
|
28
36
|
export declare type TypographyLevel = 1 | 2 | 3 | 4 | 5 | 6;
|
|
29
37
|
export declare type AltHeaderLevel = 3 | 4 | 5 | 6;
|
package/package.json
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare const TextContainer: import("styled-components").StyledComponent<"div", any, {}, never>;
|