@royaloperahouse/harmonic 0.1.7 → 0.1.8-b

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 (60) hide show
  1. package/README.md +252 -43
  2. package/dist/components/Typography/Typography.d.ts +1 -1
  3. package/dist/components/Typography/utils.d.ts +7 -0
  4. package/dist/components/atoms/Buttons/Primary/utils.d.ts +2 -0
  5. package/dist/components/atoms/Buttons/Secondary/utils.d.ts +2 -1
  6. package/dist/components/atoms/Buttons/Tertiary/utils.d.ts +1 -1
  7. package/dist/components/index.d.ts +3 -3
  8. package/dist/components/molecules/AnnouncementBanner/AnnouncementBanner.style.d.ts +1 -1
  9. package/dist/components/molecules/Information/Information.style.d.ts +4 -10
  10. package/dist/components/molecules/Information/utils.d.ts +10 -0
  11. package/dist/components/molecules/PageHeading/Promo/Promo.d.ts +5 -0
  12. package/dist/components/molecules/PageHeading/Promo/Promo.style.d.ts +28 -0
  13. package/dist/components/molecules/PageHeading/Promo/components/Badge.d.ts +10 -0
  14. package/dist/components/molecules/PageHeading/Promo/components/Button.d.ts +10 -0
  15. package/dist/components/molecules/PageHeading/Promo/components/Image.d.ts +4 -0
  16. package/dist/components/molecules/PageHeading/Promo/index.d.ts +2 -0
  17. package/dist/components/molecules/PageHeading/index.d.ts +2 -1
  18. package/dist/components/molecules/Swipe/Swipe.d.ts +12 -0
  19. package/dist/components/molecules/Swipe/Swipe.style.d.ts +8 -0
  20. package/dist/components/molecules/Swipe/helper.d.ts +1 -0
  21. package/dist/components/molecules/Swipe/index.d.ts +2 -0
  22. package/dist/components/molecules/index.d.ts +2 -2
  23. package/dist/components/organisms/Carousels/Carousel/Carousel.d.ts +4 -0
  24. package/dist/components/organisms/Carousels/Carousel/Carousel.style.d.ts +11 -0
  25. package/dist/components/organisms/Carousels/Carousel/helper.d.ts +24 -0
  26. package/dist/components/organisms/Carousels/Carousel/index.d.ts +2 -0
  27. package/dist/components/organisms/Carousels/HighlightsCarousel/HighlightsCarousel.d.ts +4 -0
  28. package/dist/components/organisms/Carousels/HighlightsCarousel/HighlightsCarousel.style.d.ts +21 -0
  29. package/dist/components/organisms/Carousels/HighlightsCarousel/HighlightsCinema.d.ts +4 -0
  30. package/dist/components/organisms/Carousels/HighlightsCarousel/HighlightsCore.d.ts +4 -0
  31. package/dist/components/organisms/Carousels/HighlightsCarousel/HighlightsStream.d.ts +4 -0
  32. package/dist/components/organisms/Carousels/HighlightsCarousel/components/Buttons.d.ts +5 -0
  33. package/dist/components/organisms/Carousels/HighlightsCarousel/components/InfoSection.d.ts +10 -0
  34. package/dist/components/organisms/Carousels/HighlightsCarousel/components/SwipeCarousel.d.ts +12 -0
  35. package/dist/components/organisms/Carousels/HighlightsCarousel/helper.d.ts +291 -0
  36. package/dist/components/organisms/Carousels/HighlightsCarousel/index.d.ts +5 -0
  37. package/dist/components/organisms/Carousels/MinimalCarousel/MinimalCarousel.d.ts +4 -0
  38. package/dist/components/organisms/Carousels/MinimalCarousel/MinimalCarousel.style.d.ts +4 -0
  39. package/dist/components/organisms/Carousels/MinimalCarousel/index.d.ts +2 -0
  40. package/dist/components/organisms/index.d.ts +4 -1
  41. package/dist/harmonic.cjs.development.css +71 -31
  42. package/dist/harmonic.cjs.development.js +1107 -550
  43. package/dist/harmonic.cjs.development.js.map +1 -1
  44. package/dist/harmonic.cjs.production.min.js +1 -1
  45. package/dist/harmonic.cjs.production.min.js.map +1 -1
  46. package/dist/harmonic.esm.js +1120 -565
  47. package/dist/harmonic.esm.js.map +1 -1
  48. package/dist/index.d.ts +3 -3
  49. package/dist/types/buttonTypes.d.ts +6 -2
  50. package/dist/types/carousel.d.ts +64 -9
  51. package/dist/types/editorial.d.ts +15 -3
  52. package/dist/types/image.d.ts +9 -3
  53. package/dist/types/impactHeader.d.ts +52 -1
  54. package/dist/types/index.d.ts +2 -2
  55. package/dist/types/information.d.ts +11 -37
  56. package/dist/types/progress.d.ts +4 -0
  57. package/dist/types/types.d.ts +5 -1
  58. package/dist/types/typography.d.ts +11 -5
  59. package/package.json +2 -1
  60. package/README.GIT +0 -278
package/dist/index.d.ts CHANGED
@@ -1,9 +1,9 @@
1
- import { Accordion, Accordions, AnnouncementBanner, AltHeader, AnchorTabBar, AuxiliaryNav, BodyText, Card, Cards, CinemaBadge, ContactCard, ContentSummary, ControlledDropdown, CreditListing, Editorial, Footer, GlobalStyles, Grid, GridItem, Header, Icon, ImageAspectRatioWrapper, ImageWithCaption, Information, Navigation, Overline, PageHeadingCinema, PageHeadingCompact, PageHeadingCore, PageHeadingImpact, PageHeadingPanel, PageHeadingStream, Pagination, PasswordStrength, PeopleListing, PrimaryButton, Progress, PromoWithTags, PromoWithTitle, Radio, Radio2, RadioGroup, RadioGroup2, ReadMore, RotatorButtons, StatusBanner, SearchBar, SecondaryButton, SecondaryLogo, SectionSplitter, SectionTitle, Select, Select2, Select2Async, Sponsorship, StickyBar, Stepper, StreamBadge, Subtitle, TertiaryButton, TextOnly, ThemeProvider, TitleWithCTA, Tab, Table, TabLink, Tabs, TextArea, TextField, TextFieldLegacy, TextLink, Tickbox, Tickbox2, Timer, TypeTags, UpsellCard, UpsellSection, Quote, VideoControls, VideoWithControls, SignUpForm } from './components';
1
+ import { Accordion, Accordions, AnnouncementBanner, AltHeader, AnchorTabBar, AuxiliaryNav, BodyText, Card, Cards, CinemaBadge, ContactCard, ContentSummary, ControlledDropdown, CreditListing, Editorial, Footer, GlobalStyles, Grid, GridItem, Header, Icon, ImageAspectRatioWrapper, ImageWithCaption, Information, Navigation, Overline, PageHeadingCinema, PageHeadingCompact, PageHeadingCore, PageHeadingImpact, PageHeadingPanel, PageHeadingPromo, PageHeadingStream, Pagination, PasswordStrength, PeopleListing, PrimaryButton, Progress, PromoWithTags, PromoWithTitle, Radio, Radio2, RadioGroup, RadioGroup2, ReadMore, RotatorButtons, StatusBanner, SearchBar, SecondaryButton, SecondaryLogo, SectionSplitter, SectionTitle, Select, Select2, Select2Async, Sponsorship, StickyBar, Stepper, StreamBadge, Subtitle, TertiaryButton, TextOnly, ThemeProvider, TitleWithCTA, Tab, Table, TabLink, Tabs, TextArea, TextField, TextFieldLegacy, TextLink, Tickbox, Tickbox2, Timer, TypeTags, UpsellCard, UpsellSection, Quote, VideoControls, VideoWithControls, SignUpForm } from './components';
2
2
  import { devices, breakpoints } from './styles/viewports';
3
3
  import zIndexes from './styles/zIndexes';
4
- import { AspectRatio, ButtonType, CarouselType, Colors, IconNameType, IntegratedTimerProps, ITimerProps, TickboxMode, ThemeType, EditorialLink, IInformationTitleProps, IInformationCTAProps, IInformationBackgroundColour } from './types';
4
+ import { AspectRatio, ButtonType, CarouselType, Colors, IconNameType, IntegratedTimerProps, ITimerProps, TickboxMode, ThemeType, EditorialLink, IInformationTitleProps, IInformationCTAProps } from './types';
5
5
  import { MiniCard } from './components/molecules';
6
6
  import { ModalWindow } from './components/organisms';
7
7
  import AuxiliaryButton from './components/atoms/Buttons/Auxiliary/AuxiliaryButton';
8
8
  import HarmonicThemeProvider from './styles/HarmonicThemeProvider';
9
- export { Accordion, Accordions, AnnouncementBanner, AltHeader, AnchorTabBar, AuxiliaryButton, AuxiliaryNav, AspectRatio, BodyText, breakpoints, ButtonType, Card, Cards, CarouselType, CinemaBadge, Colors, ContactCard, ContentSummary, ControlledDropdown, CreditListing, devices, Editorial, EditorialLink, Footer, GlobalStyles, Grid, GridItem, HarmonicThemeProvider, Header, Icon, IconNameType, ImageAspectRatioWrapper, ImageWithCaption, Information, IInformationBackgroundColour, IInformationCTAProps, IInformationTitleProps, ITimerProps, IntegratedTimerProps, MiniCard, ModalWindow, Navigation, Overline, PageHeadingCinema, PageHeadingCompact, PageHeadingCore, PageHeadingImpact, PageHeadingPanel, PageHeadingStream, Pagination, PasswordStrength, PeopleListing, PrimaryButton, Progress, PromoWithTags, PromoWithTitle, Radio, Radio2, RadioGroup, RadioGroup2, ReadMore, RotatorButtons, StatusBanner, SearchBar, SecondaryButton, SecondaryLogo, SectionSplitter, SectionTitle, Select, Select2, Select2Async, Sponsorship, StickyBar, Stepper, StreamBadge, Subtitle, Tab, Table, TabLink, Tabs, TertiaryButton, TextArea, TextField, TextFieldLegacy, TextLink, TextOnly, ThemeProvider, ThemeType, TitleWithCTA, Tickbox, Tickbox2, TickboxMode, Timer, TypeTags, UpsellCard, UpsellSection, Quote, VideoControls, VideoWithControls, zIndexes, SignUpForm, };
9
+ export { Accordion, Accordions, AnnouncementBanner, AltHeader, AnchorTabBar, AuxiliaryButton, AuxiliaryNav, AspectRatio, BodyText, breakpoints, ButtonType, Card, Cards, CarouselType, CinemaBadge, Colors, ContactCard, ContentSummary, ControlledDropdown, CreditListing, devices, Editorial, EditorialLink, Footer, GlobalStyles, Grid, GridItem, HarmonicThemeProvider, Header, Icon, IconNameType, ImageAspectRatioWrapper, ImageWithCaption, Information, IInformationCTAProps, IInformationTitleProps, ITimerProps, IntegratedTimerProps, MiniCard, ModalWindow, Navigation, Overline, PageHeadingCinema, PageHeadingCompact, PageHeadingCore, PageHeadingImpact, PageHeadingPanel, PageHeadingPromo, PageHeadingStream, Pagination, PasswordStrength, PeopleListing, PrimaryButton, Progress, PromoWithTags, PromoWithTitle, Radio, Radio2, RadioGroup, RadioGroup2, ReadMore, RotatorButtons, StatusBanner, SearchBar, SecondaryButton, SecondaryLogo, SectionSplitter, SectionTitle, Select, Select2, Select2Async, Sponsorship, StickyBar, Stepper, StreamBadge, Subtitle, Tab, Table, TabLink, Tabs, TertiaryButton, TextArea, TextField, TextFieldLegacy, TextLink, TextOnly, ThemeProvider, ThemeType, TitleWithCTA, Tickbox, Tickbox2, TickboxMode, Timer, TypeTags, UpsellCard, UpsellSection, Quote, VideoControls, VideoWithControls, zIndexes, SignUpForm, };
@@ -29,13 +29,17 @@ declare type StyleProps = {
29
29
  backgroundColor?: ThemeColor;
30
30
  /** Border color from theme */
31
31
  borderColor?: ThemeColor;
32
+ /** Hovered color from theme */
33
+ hoveredColor?: ThemeColor;
34
+ /** Pressed element color from theme */
35
+ pressedColor?: ThemeColor;
32
36
  /** Disabled state */
33
37
  disabled?: boolean;
34
38
  };
35
39
  export declare type ButtonProps = BaseProps & IconProps & AnchorHTMLAttributes<HTMLAnchorElement>;
36
40
  export declare type AuxiliaryButtonProps = ButtonProps & Pick<StyleProps, 'textColor' | 'backgroundColor'>;
37
- export declare type PrimaryButtonProps = ButtonProps & Pick<StyleProps, 'textColor' | 'backgroundColor' | 'disabled'>;
38
- export declare type SecondaryButtonProps = ButtonProps & Pick<StyleProps, 'textColor' | 'borderColor' | 'disabled'>;
41
+ export declare type PrimaryButtonProps = ButtonProps & Pick<StyleProps, 'textColor' | 'backgroundColor' | 'hoveredColor' | 'pressedColor' | 'disabled'>;
42
+ export declare type SecondaryButtonProps = ButtonProps & Pick<StyleProps, 'textColor' | 'borderColor' | 'hoveredColor' | 'pressedColor' | 'disabled'>;
39
43
  export declare type TertiaryButtonProps = BaseProps & AnchorHTMLAttributes<HTMLAnchorElement> & Pick<StyleProps, 'textColor' | 'disabled'>;
40
44
  export declare type RotatorButtonsProps = {
41
45
  /** Enable/disable prev button */
@@ -1,9 +1,10 @@
1
1
  import { ImgHTMLAttributes, ReactElement } from 'react';
2
2
  import { ICardProps } from './card';
3
- import { EditorialLink } from './editorial';
4
3
  import { IImageWithCaptionProps } from './image';
5
4
  import { IntegratedTimerProps } from './timer';
6
5
  import { ILogosProps } from './types';
6
+ import { EditorialLink } from './editorial';
7
+ import { TypographyLevel } from './typography';
7
8
  export declare enum CarouselType {
8
9
  Image = "image",
9
10
  SmallCard = "SmallCard",
@@ -14,6 +15,10 @@ export interface ICarouselProps {
14
15
  * Carousel title
15
16
  */
16
17
  title?: string;
18
+ /**
19
+ * Carousel description
20
+ */
21
+ description?: string;
17
22
  /**
18
23
  * Carousel type.
19
24
  */
@@ -34,12 +39,20 @@ export interface ICarouselProps {
34
39
  * Defines if there should be offset added at the beginning of the container. True by default;
35
40
  */
36
41
  useOffset?: boolean;
37
- }
38
- export interface ICarouselWrapperProps {
39
42
  /**
40
- * Carousel has been activated or not
43
+ * Semantic level of the title
44
+ */
45
+ titleSemanticLevel?: TypographyLevel;
46
+ /**
47
+ * Sets infinite mode ON/OFF
41
48
  */
42
- active: boolean;
49
+ infinite?: boolean;
50
+ /**
51
+ * CSS class name
52
+ */
53
+ className?: string;
54
+ }
55
+ export interface ICarouselWrapperProps {
43
56
  /**
44
57
  * Carousel type.
45
58
  */
@@ -64,6 +77,30 @@ export interface ICarouselWrapperProps {
64
77
  export declare type HighlightsCarouselSlideImage = ImgHTMLAttributes<HTMLImageElement> & {
65
78
  key: string;
66
79
  };
80
+ interface SlideVideo {
81
+ desktop: string;
82
+ mobile: string;
83
+ }
84
+ interface SlidePoster {
85
+ desktop: string;
86
+ mobile: string;
87
+ altText: string;
88
+ }
89
+ export interface HighlightsCarouselSlideVideo {
90
+ video: SlideVideo;
91
+ poster: SlidePoster;
92
+ key: string;
93
+ autoPlay: boolean;
94
+ muted: boolean;
95
+ soundControl: boolean;
96
+ fullScreenOption: boolean;
97
+ loop: boolean;
98
+ }
99
+ export interface HighlightsCarouselVideoSlideProps {
100
+ index: number;
101
+ isCurrentSlide: boolean;
102
+ settings: HighlightsCarouselSlideVideo;
103
+ }
67
104
  export declare type HighlightsCarouselSlide = {
68
105
  /**
69
106
  * heder in info section
@@ -90,13 +127,17 @@ export declare type HighlightsCarouselSlide = {
90
127
  */
91
128
  links: EditorialLink[];
92
129
  /**
93
- * Slide image
130
+ * Slide media
94
131
  */
95
- image: HighlightsCarouselSlideImage;
132
+ mediaContent: HighlightsCarouselSlideImage | HighlightsCarouselSlideVideo;
96
133
  /**
97
134
  * Params for Timer component
98
135
  */
99
136
  timerParams?: IntegratedTimerProps;
137
+ /**
138
+ * Renders an auxiliary button when passed
139
+ */
140
+ auxiliaryCTA?: EditorialLink;
100
141
  };
101
142
  export interface IHighlightsCarouselProps {
102
143
  /**
@@ -111,9 +152,16 @@ export interface IHighlightsCarouselProps {
111
152
  * slides to be displayed in the carousel
112
153
  */
113
154
  slides: HighlightsCarouselSlide[];
155
+ /**
156
+ * Semantic level of the title
157
+ */
158
+ titleSemanticLevel?: TypographyLevel;
159
+ /**
160
+ * Additional CSS class names to apply to the navigation component.
161
+ */
162
+ className?: string;
114
163
  }
115
- export interface IHighlightsCoreCarouselProps extends Omit<IHighlightsCarouselProps, 'logo'> {
116
- }
164
+ export declare type IHighlightsCoreCarouselProps = Omit<IHighlightsCarouselProps, 'logo'>;
117
165
  export interface IHighlightsCinemaCarouselProps extends Omit<IHighlightsCarouselProps, 'logo'> {
118
166
  /**
119
167
  * Renders logo or not
@@ -126,3 +174,10 @@ export interface IHighlightsStreamCarouselProps extends Omit<IHighlightsCarousel
126
174
  */
127
175
  logo: boolean;
128
176
  }
177
+ export interface IMinimalCarouselProps {
178
+ /**
179
+ * Carousel children (only Card and ImageAspectRatioWrapper children are allowed).
180
+ */
181
+ children: ReactElement[];
182
+ }
183
+ export {};
@@ -2,7 +2,7 @@ import { AnchorHTMLAttributes, ImgHTMLAttributes, MouseEventHandler, ReactElemen
2
2
  import { StyledProps } from 'styled-components';
3
3
  import { ButtonType } from './buttonTypes';
4
4
  import { DirectionType, IconNameType } from './iconTypes';
5
- import { Colors, IVideoWithControlsSettings } from './types';
5
+ import { Colors, IVideoWithControlsSettings, ThemeColor } from './types';
6
6
  import { TypographyLevel } from './typography';
7
7
  export interface IEditorialProps {
8
8
  /**
@@ -68,11 +68,23 @@ export declare type EditorialLink = AnchorHTMLAttributes<HTMLAnchorElement> & {
68
68
  /**
69
69
  * Color of text and icon
70
70
  */
71
- color?: Colors;
71
+ textColor?: ThemeColor;
72
72
  /**
73
73
  * background color
74
74
  */
75
- bgColor?: Colors;
75
+ backgroundColor?: ThemeColor;
76
+ /**
77
+ * Border color
78
+ */
79
+ borderColor?: ThemeColor;
80
+ /**
81
+ * Hovered color
82
+ */
83
+ hoveredColor?: ThemeColor;
84
+ /**
85
+ * Pressed color
86
+ */
87
+ pressedColor?: ThemeColor;
76
88
  /**
77
89
  * type of the button to be rendered; When not passed the Primary and Tetriary are displayed by default;
78
90
  */
@@ -5,21 +5,27 @@ export declare enum AspectRatio {
5
5
  '3:4' = "3 / 4",
6
6
  '4:3' = "4 / 3",
7
7
  '8:3' = "8 / 3",
8
- '16:9' = "16 / 9"
8
+ '16:9' = "16 / 9",
9
+ '90:17' = "90 / 17",
10
+ '75:32' = "75 / 32"
9
11
  }
10
12
  export declare enum AspectRatioLegacy {
11
13
  '1 / 1' = "100",
12
14
  '3 / 4' = "133",
13
15
  '4 / 3' = "75",
14
16
  '8 / 3' = "37.5",
15
- '16 / 9' = "56.25"
17
+ '16 / 9' = "56.25",
18
+ '90 / 17' = "18.88",
19
+ '75 / 32' = "15"
16
20
  }
17
21
  export declare enum AspectRatioWidth {
18
22
  '1 / 1' = "1",
19
23
  '3 / 4' = "0.75",
20
24
  '4 / 3' = "1.33",
21
25
  '8 / 3' = "2.67",
22
- '16 / 9' = "1.78"
26
+ '16 / 9' = "1.78",
27
+ '90 / 17' = "5.29",
28
+ '75 / 32' = "2.34"
23
29
  }
24
30
  export interface IImageAspectRatioWrapperProps {
25
31
  /**
@@ -1,6 +1,6 @@
1
1
  import { ReactNode } from 'react';
2
2
  import { EditorialLink } from '../types';
3
- import { TypographyLevel } from './typography';
3
+ import { TypographyHierarchy, TypographyLevel } from './typography';
4
4
  export interface CustomSponsorImageData {
5
5
  /**
6
6
  * Source URL for Sponsorship logo
@@ -133,3 +133,54 @@ export interface IPageHeadingCompactProps {
133
133
  */
134
134
  semanticLevel?: TypographyLevel;
135
135
  }
136
+ export declare type PageHeadingPromoImageProps = {
137
+ /**
138
+ * Image url for desktops
139
+ */
140
+ desktop: string;
141
+ /**
142
+ * Image url for devices
143
+ */
144
+ mobile: string;
145
+ /**
146
+ * Alt text for the main image
147
+ */
148
+ alt: string;
149
+ };
150
+ export declare enum PageHeadingPromoBadge {
151
+ Stream = "Stream",
152
+ Cinema = "Cinema"
153
+ }
154
+ export declare type PageHeadingPromoAdditionalLink = EditorialLink & {
155
+ isTextLink?: boolean;
156
+ };
157
+ export interface IPageHeadingPromoProps {
158
+ /**
159
+ * Title text
160
+ */
161
+ title?: string;
162
+ /**
163
+ * Semantic level of the header
164
+ */
165
+ titleSemanticLevel?: TypographyHierarchy;
166
+ /**
167
+ * Boolean to show/hide sponsorship logo (default true)
168
+ */
169
+ sponsor?: boolean;
170
+ /**
171
+ * Link placed in the impact component
172
+ */
173
+ mainLink?: EditorialLink;
174
+ /**
175
+ * Link placed in the impact component
176
+ */
177
+ additionalLink?: PageHeadingPromoAdditionalLink;
178
+ /**
179
+ * Heading image
180
+ */
181
+ image: PageHeadingPromoImageProps;
182
+ /**
183
+ * Badge variant
184
+ */
185
+ badge?: PageHeadingPromoBadge;
186
+ }
@@ -11,6 +11,6 @@ import { IPageHeadingCompactProps } from './impactHeader';
11
11
  import { IntegratedTimerProps, ITimerProps } from './timer';
12
12
  import { ICreditListing } from './creditListing';
13
13
  import { ModalWindowProps } from './modalWindow';
14
- import { IInformationTitleProps, IInformationCTAProps, IInformationBackgroundColour } from './information';
15
- export { AspectRatio, ButtonType, CarouselType, Colors, EditorialLink, IconNameType, ICreditListing, IPageHeadingCompactProps, INavigationProps, INavTopProps, IntegratedTimerProps, ITimerProps, ModalWindowProps, TickboxMode, ThemeType, IInformationTitleProps, IInformationCTAProps, IInformationBackgroundColour, };
14
+ import { IInformationTitleProps, IInformationCTAProps } from './information';
15
+ export { AspectRatio, ButtonType, CarouselType, Colors, EditorialLink, IconNameType, ICreditListing, IPageHeadingCompactProps, INavigationProps, INavTopProps, IntegratedTimerProps, ITimerProps, ModalWindowProps, TickboxMode, ThemeType, IInformationTitleProps, IInformationCTAProps, };
16
16
  export type { FooterData };
@@ -1,27 +1,13 @@
1
1
  import { DirectionType, IconNameType } from './iconTypes';
2
2
  import { LinkTarget } from './types';
3
- export declare enum IInformationCtaVariant {
4
- Primary = "Primary",
5
- Secondary = "Secondary",
6
- Tertiary = "Tertiary",
7
- TextLink = "TextLink"
8
- }
9
- export declare enum IInformationCtaTheme {
10
- Cinema = "Cinema",
11
- Core = "Core",
12
- Stream = "Stream"
13
- }
14
- export declare enum IInformationTitleVariant {
15
- Header = "Header",
16
- AltHeader = "AltHeader"
17
- }
18
- export declare enum IInformationBackgroundColour {
19
- Cinema = "cinema",
20
- Core = "core",
21
- Stream = "stream",
22
- White = "white"
23
- }
24
- export declare type TitleTextSize = 3 | 4 | 5 | 6;
3
+ import type { HarmonicSize } from './typography';
4
+ export declare const InformationCtaVariants: {
5
+ readonly Primary: "Primary";
6
+ readonly Secondary: "Secondary";
7
+ readonly Tertiary: "Tertiary";
8
+ readonly TextLink: "TextLink";
9
+ };
10
+ export declare type InformationCtaVariant = keyof typeof InformationCtaVariants;
25
11
  export interface IInformationCTAProps {
26
12
  /**
27
13
  * Text to display on the CTA
@@ -35,11 +21,7 @@ export interface IInformationCTAProps {
35
21
  * Style of the CTA. Choices are "Primary" (solid button background), "Secondary" (transparent button background)
36
22
  * or "Tertiary" (text only)
37
23
  */
38
- variant?: IInformationCtaVariant;
39
- /**
40
- * Flag to decide whether to adjust the CTA colours for display on coloured backgrounds
41
- */
42
- infoThemed: boolean;
24
+ variant?: InformationCtaVariant;
43
25
  /**
44
26
  * Name of the icon to be used in the button
45
27
  */
@@ -58,14 +40,10 @@ export interface IInformationTitleProps {
58
40
  * Title text to display
59
41
  */
60
42
  text: string;
61
- /**
62
- * Title typography type. Choices are Heading or AltHeader
63
- */
64
- variant: IInformationTitleVariant;
65
43
  /**
66
44
  * The size of the title text
67
45
  */
68
- textSize: TitleTextSize;
46
+ textSize: HarmonicSize;
69
47
  }
70
48
  export interface IInformationProps {
71
49
  /**
@@ -79,11 +57,7 @@ export interface IInformationProps {
79
57
  /**
80
58
  * Title options for the component
81
59
  */
82
- title: IInformationTitleProps;
83
- /**
84
- * Background Colour. Choices: None, Core, Cinema, Stream
85
- */
86
- background?: IInformationBackgroundColour;
60
+ title?: IInformationTitleProps;
87
61
  /**
88
62
  * Additional CSS class names to apply to component.
89
63
  */
@@ -30,4 +30,8 @@ export interface IProgressProps {
30
30
  * Number of the steps
31
31
  */
32
32
  steps?: IProgressSteps;
33
+ /**
34
+ * The presence of a shadow under the progress bar
35
+ */
36
+ shadow?: boolean;
33
37
  }
@@ -52,6 +52,10 @@ export declare enum ThemeType {
52
52
  Cinema = "cinema",
53
53
  Schools = "schools"
54
54
  }
55
+ export declare type ThemeChildProps = {
56
+ className?: string;
57
+ theme?: ThemeType;
58
+ };
55
59
  export interface IThemeProviderProps {
56
60
  /**
57
61
  * The theme to use for the child elements
@@ -424,7 +428,7 @@ export interface ITextLinkProps extends AnchorHTMLAttributes<HTMLAnchorElement>
424
428
  /**
425
429
  * Color of text and icon
426
430
  */
427
- color?: Colors;
431
+ textColor?: ThemeColor;
428
432
  }
429
433
  export interface ISectionSplitterProps {
430
434
  /**
@@ -1,9 +1,14 @@
1
1
  import { ReactNode } from 'react';
2
2
  import { StyledProps } from 'styled-components';
3
- export declare type HarmonicSize = 'small' | 'medium' | 'large';
4
- export declare type HarmonicColors = 'primary' | 'black' | 'white' | 'red' | 'grey';
5
- export interface IGenericTypographyProps {
6
- children: ReactNode;
3
+ export declare const HarmonicSizes: {
4
+ readonly Small: "small";
5
+ readonly Medium: "medium";
6
+ readonly Large: "large";
7
+ };
8
+ export declare type HarmonicSize = (typeof HarmonicSizes)[keyof typeof HarmonicSizes];
9
+ export declare type HarmonicColors = 'primary' | 'black' | 'white' | 'red' | 'grey' | 'inherit';
10
+ export interface IGenericTypographyProps<T extends HTMLElement = HTMLParagraphElement> extends React.HTMLAttributes<T> {
11
+ children?: ReactNode;
7
12
  size?: HarmonicSize;
8
13
  serif?: boolean;
9
14
  color?: HarmonicColors;
@@ -11,8 +16,9 @@ export interface IGenericTypographyProps {
11
16
  bold?: boolean;
12
17
  className?: string;
13
18
  }
19
+ export declare type TypographyHierarchy = 'h1' | 'h2' | 'h3';
14
20
  export interface IHarmonicHeaderProps extends IGenericTypographyProps {
15
- hierarchy: 'h1' | 'h2' | 'h3';
21
+ hierarchy: TypographyHierarchy;
16
22
  }
17
23
  export declare type TypographyLevel = 1 | 2 | 3 | 4 | 5 | 6;
18
24
  export declare type AltHeaderLevel = 3 | 4 | 5 | 6;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@royaloperahouse/harmonic",
3
- "version": "0.1.7",
3
+ "version": "0.1.8-b",
4
4
  "author": "Royal Opera House",
5
5
  "license": "MIT",
6
6
  "main": "dist/index.js",
@@ -88,6 +88,7 @@
88
88
  "@types/react-modal": "^3.16.3",
89
89
  "@types/react-select": "^5.0.1",
90
90
  "@types/react-test-renderer": "^17.0.1",
91
+ "@types/resize-observer-browser": "^0.1.11",
91
92
  "@types/styled-components": "5.1.26",
92
93
  "@types/testing-library__jest-dom": "^5.9.1",
93
94
  "@typescript-eslint/eslint-plugin": "^5.0.0",