@financial-times/dotcom-ui-shell 7.3.0 → 7.3.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (32) hide show
  1. package/dist/node/components/Content.d.ts +6 -0
  2. package/dist/node/components/DocumentHead.d.ts +36 -0
  3. package/dist/node/components/GTMBody.d.ts +11 -0
  4. package/dist/node/components/GTMHead.d.ts +11 -0
  5. package/dist/node/components/LinkedData.d.ts +13 -0
  6. package/dist/node/components/OpenGraph.d.ts +12 -0
  7. package/dist/node/components/ResourceHints.d.ts +11 -0
  8. package/dist/node/components/Shell.d.ts +29 -0
  9. package/dist/node/components/StyleSheets.d.ts +14 -0
  10. package/dist/node/index.d.ts +1 -0
  11. package/dist/node/lib/flattenOpenGraphData.d.ts +4 -0
  12. package/dist/node/lib/formatAttributeNames.d.ts +4 -0
  13. package/dist/node/lib/getResourceType.d.ts +2 -0
  14. package/dist/node/lib/imageServiceIconURL.d.ts +2 -0
  15. package/dist/node/lib/loadAsyncStylesheets.d.ts +2 -0
  16. package/dist/tsconfig.tsbuildinfo +2370 -0
  17. package/package.json +11 -9
  18. package/src/components/Content.tsx +0 -25
  19. package/src/components/DocumentHead.tsx +0 -103
  20. package/src/components/GTMBody.tsx +0 -29
  21. package/src/components/GTMHead.tsx +0 -23
  22. package/src/components/LinkedData.tsx +0 -38
  23. package/src/components/OpenGraph.tsx +0 -20
  24. package/src/components/ResourceHints.tsx +0 -63
  25. package/src/components/Shell.tsx +0 -97
  26. package/src/components/StyleSheets.tsx +0 -35
  27. package/src/index.ts +0 -1
  28. package/src/lib/flattenOpenGraphData.ts +0 -24
  29. package/src/lib/formatAttributeNames.ts +0 -36
  30. package/src/lib/getResourceType.ts +0 -34
  31. package/src/lib/imageServiceIconURL.ts +0 -24
  32. package/src/lib/loadAsyncStylesheets.ts +0 -27
@@ -0,0 +1,6 @@
1
+ import React from 'react';
2
+ export declare type TContentProps = {
3
+ contents?: string | React.ReactNode;
4
+ };
5
+ declare function Content({ contents }: TContentProps): JSX.Element;
6
+ export default Content;
@@ -0,0 +1,36 @@
1
+ import React from 'react';
2
+ import { TOpenGraphProps } from './OpenGraph';
3
+ import { TLinkedDataProps } from './LinkedData';
4
+ export declare type TDocumentHeadProps = TOpenGraphProps & TLinkedDataProps & {
5
+ description?: string;
6
+ facebookPage?: string;
7
+ googleSiteVerification?: string;
8
+ metaTags?: Array<{
9
+ [key: string]: any;
10
+ }>;
11
+ pageTitle: string;
12
+ robots?: string;
13
+ siteTitle?: string;
14
+ twitterSite?: string;
15
+ canonicalURL?: string;
16
+ manifestFile?: string;
17
+ additionalMetadata?: React.ReactNode;
18
+ showSmartBanner?: boolean;
19
+ };
20
+ declare const DocumentHead: {
21
+ (props: TDocumentHeadProps): JSX.Element;
22
+ defaultProps: {
23
+ description: string;
24
+ facebookPage: string;
25
+ googleSiteVerification: string;
26
+ metaTags: any[];
27
+ jsonLd: any[];
28
+ robots: string;
29
+ siteTitle: string;
30
+ twitterSite: string;
31
+ manifestFile: string;
32
+ additionalMetadata: any;
33
+ showSmartBanner: boolean;
34
+ };
35
+ };
36
+ export default DocumentHead;
@@ -0,0 +1,11 @@
1
+ /// <reference types="react" />
2
+ import { TFlagsData } from '@financial-times/dotcom-ui-flags/src/types';
3
+ declare const GTMBody: {
4
+ ({ flags }: {
5
+ flags: TFlagsData;
6
+ }): JSX.Element;
7
+ defaultProps: {
8
+ flags: {};
9
+ };
10
+ };
11
+ export default GTMBody;
@@ -0,0 +1,11 @@
1
+ /// <reference types="react" />
2
+ import { TFlagsData } from '@financial-times/dotcom-ui-flags/src/types';
3
+ declare const GTMHead: {
4
+ ({ flags }: {
5
+ flags: TFlagsData;
6
+ }): JSX.Element;
7
+ defaultProps: {
8
+ flags: {};
9
+ };
10
+ };
11
+ export default GTMHead;
@@ -0,0 +1,13 @@
1
+ /// <reference types="react" />
2
+ export declare type TLinkedDataProps = {
3
+ jsonLd?: {
4
+ [key: string]: any;
5
+ };
6
+ };
7
+ declare const LinkedData: {
8
+ ({ jsonLd }: TLinkedDataProps): JSX.Element;
9
+ defaultProps: {
10
+ jsonLd: any[];
11
+ };
12
+ };
13
+ export default LinkedData;
@@ -0,0 +1,12 @@
1
+ /// <reference types="react" />
2
+ import { TOpenGraphData } from '../lib/flattenOpenGraphData';
3
+ export declare type TOpenGraphProps = {
4
+ openGraph?: TOpenGraphData;
5
+ };
6
+ declare const OpenGraph: {
7
+ ({ openGraph }: TOpenGraphProps): JSX.Element;
8
+ defaultProps: {
9
+ openGraph: {};
10
+ };
11
+ };
12
+ export default OpenGraph;
@@ -0,0 +1,11 @@
1
+ /// <reference types="react" />
2
+ export declare type TResourceHintsProps = {
3
+ resourceHints?: string[];
4
+ };
5
+ declare const ResourceHints: {
6
+ (props: TResourceHintsProps): JSX.Element;
7
+ defaultProps: {
8
+ resourceHints: any[];
9
+ };
10
+ };
11
+ export default ResourceHints;
@@ -0,0 +1,29 @@
1
+ /// <reference types="react" />
2
+ import Content, { TContentProps } from './Content';
3
+ import DocumentHead, { TDocumentHeadProps } from './DocumentHead';
4
+ import { TStylesheetProps } from './StyleSheets';
5
+ import ResourceHints, { TResourceHintsProps } from './ResourceHints';
6
+ import { TAppContextProps } from '@financial-times/dotcom-ui-app-context';
7
+ import { TFlagsEmbedProps } from '@financial-times/dotcom-ui-flags';
8
+ import { TAttributeData } from '../lib/formatAttributeNames';
9
+ declare type TShellProps = TDocumentHeadProps & TAppContextProps & TStylesheetProps & TResourceHintsProps & TContentProps & TFlagsEmbedProps & {
10
+ scripts?: string[];
11
+ children?: any;
12
+ initialProps?: any;
13
+ bodyAttributes?: TAttributeData;
14
+ htmlAttributes?: TAttributeData;
15
+ };
16
+ declare function Shell(props: TShellProps): JSX.Element;
17
+ declare namespace Shell {
18
+ var defaultProps: {
19
+ scripts: any[];
20
+ stylesheets: any[];
21
+ asyncStylesheets: any[];
22
+ resourceHints: any[];
23
+ htmlAttributes: {};
24
+ bodyAttributes: {};
25
+ };
26
+ }
27
+ export { Shell };
28
+ export type { TShellProps };
29
+ export { DocumentHead, ResourceHints, Content };
@@ -0,0 +1,14 @@
1
+ /// <reference types="react" />
2
+ export declare type TStylesheetProps = {
3
+ criticalStyles?: string;
4
+ stylesheets?: string[];
5
+ asyncStylesheets?: string[];
6
+ };
7
+ declare const Stylesheets: {
8
+ ({ criticalStyles, stylesheets, asyncStylesheets }: TStylesheetProps): JSX.Element;
9
+ defaultProps: {
10
+ stylesheets: any[];
11
+ asyncStylesheets: any[];
12
+ };
13
+ };
14
+ export default Stylesheets;
@@ -0,0 +1 @@
1
+ export * from './components/Shell';
@@ -0,0 +1,4 @@
1
+ export declare type TOpenGraphData = {
2
+ [key: string]: any | any[] | TOpenGraphData;
3
+ };
4
+ export default function flattenData(data: TOpenGraphData, prefix?: string): Array<string[]>;
@@ -0,0 +1,4 @@
1
+ export declare type TAttributeData = {
2
+ [key: string]: string | number | boolean;
3
+ };
4
+ export default function formatAttributeNames(data?: TAttributeData): {};
@@ -0,0 +1,2 @@
1
+ declare const _default: (file: string) => string;
2
+ export default _default;
@@ -0,0 +1,2 @@
1
+ declare function imageServiceIconURL(image: string, size: number, format?: string): string;
2
+ export default imageServiceIconURL;
@@ -0,0 +1,2 @@
1
+ declare const _default: string;
2
+ export default _default;