@royaloperahouse/harmonic 0.11.0-j → 0.11.0-k
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/molecules/PageHeading/Promo/Promo.d.ts +1 -2
- package/dist/components/organisms/AnchorTabBar/AnchorTabBar.style.d.ts +8 -3
- package/dist/harmonic.cjs.development.css +3 -0
- package/dist/harmonic.cjs.development.js +224 -182
- 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 +240 -199
- package/dist/harmonic.esm.js.map +1 -1
- package/dist/index.d.ts +2 -1
- package/dist/styles/HarmonicThemeProvider/HarmonicThemeProvider.d.ts +3 -0
- package/dist/styles/HarmonicThemeProvider/index.d.ts +2 -1
- package/dist/types/creditListing.d.ts +1 -1
- package/dist/types/impactHeader.d.ts +2 -0
- package/dist/types/information.d.ts +23 -43
- package/dist/types/navigation.d.ts +21 -43
- package/dist/types/types.d.ts +1 -7
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -6,7 +6,8 @@ import { AspectRatio, ButtonType, CarouselType, Colors, IconNameType, Integrated
|
|
|
6
6
|
import { MiniCard } from './components/molecules';
|
|
7
7
|
import { ModalWindow } from './components/organisms';
|
|
8
8
|
import AuxiliaryButton from './components/atoms/Buttons/Auxiliary/AuxiliaryButton';
|
|
9
|
-
import HarmonicThemeProvider from './styles/HarmonicThemeProvider';
|
|
9
|
+
import HarmonicThemeProvider, { useHarmonicTheme } from './styles/HarmonicThemeProvider';
|
|
10
10
|
import { HarmonicSize } from './types/typography';
|
|
11
11
|
import { HarmonicHeader, HarmonicSubtitle, BodyCopyHarmonic, HarmonicOverline, ButtonText, Caption, NavigationText } from './components/Typography';
|
|
12
|
+
export { useHarmonicTheme };
|
|
12
13
|
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, };
|
|
@@ -2,9 +2,12 @@ import React from 'react';
|
|
|
2
2
|
import { ThemeType } from '../../types';
|
|
3
3
|
import './theme/fonts.css';
|
|
4
4
|
import './theme/typography.css';
|
|
5
|
+
export declare const DEFAULT_THEME = ThemeType.Core;
|
|
5
6
|
interface HarmonicThemeProviderProps {
|
|
6
7
|
theme: ThemeType;
|
|
7
8
|
children: React.ReactNode;
|
|
8
9
|
}
|
|
10
|
+
export declare const HarmonicThemeContext: React.Context<ThemeType>;
|
|
11
|
+
export declare const useHarmonicTheme: () => ThemeType;
|
|
9
12
|
declare const HarmonicThemeProvider: React.FC<HarmonicThemeProviderProps>;
|
|
10
13
|
export default HarmonicThemeProvider;
|
|
@@ -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 {};
|
|
@@ -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
|
-
* Function to be called when a tab is clicked
|
|
284
|
-
*/
|
|
280
|
+
/** Function to be called when a tab is clicked */
|
|
285
281
|
onTabClick?: (e: MouseEvent, id: string) => void;
|
|
286
|
-
/**
|
|
287
|
-
* Set the id of the tab actived
|
|
288
|
-
*/
|
|
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,43 +325,27 @@ 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;
|
package/dist/types/types.d.ts
CHANGED
|
@@ -53,14 +53,8 @@ export declare enum ThemeType {
|
|
|
53
53
|
Cinema = "cinema",
|
|
54
54
|
Schools = "schools"
|
|
55
55
|
}
|
|
56
|
-
export declare type ThemeChildProps = {
|
|
57
|
-
className?: string;
|
|
58
|
-
theme?: ThemeType;
|
|
59
|
-
};
|
|
60
56
|
export interface IThemeProviderProps {
|
|
61
|
-
/**
|
|
62
|
-
* The theme to use for the child elements
|
|
63
|
-
*/
|
|
57
|
+
/** The theme to use for the child elements */
|
|
64
58
|
theme: ThemeType;
|
|
65
59
|
children: ReactNode;
|
|
66
60
|
}
|