@pantheon-systems/pds-toolkit-react 1.0.0-dev.165 → 1.0.0-dev.166

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.
@@ -1,25 +1,42 @@
1
- export function PantheonLogo({ colorType, displayType, isLink, subBrand, className, ...props }: {
2
- [x: string]: any;
3
- colorType?: string;
4
- displayType?: string;
5
- isLink: any;
6
- subBrand: any;
7
- className: any;
8
- }): React.JSX.Element;
9
- export namespace PantheonLogo {
10
- namespace propTypes {
11
- let colorType: PropTypes.Requireable<string>;
12
- let displayType: PropTypes.Requireable<string>;
13
- let isLink: PropTypes.Requireable<PropTypes.InferProps<{
14
- ariaLabel: PropTypes.Requireable<string>;
15
- link: PropTypes.Requireable<PropTypes.ReactNodeLike>;
16
- }>>;
17
- let subBrand: PropTypes.Requireable<PropTypes.InferProps<{
18
- link: PropTypes.Requireable<PropTypes.ReactNodeLike>;
19
- text: PropTypes.Requireable<string>;
20
- }>>;
21
- let className: PropTypes.Requireable<string>;
22
- }
1
+ import React, { ComponentPropsWithoutRef, ReactNode } from 'react';
2
+ import './pantheon-logo.css';
3
+ type SubBrand = {
4
+ /**
5
+ * Sub-brand linkContent
6
+ */
7
+ linkContent?: ReactNode;
8
+ /**
9
+ * Sub-brand label text
10
+ */
11
+ text: string;
12
+ };
13
+ /**
14
+ * Prop types for PantheonLogo
15
+ */
16
+ export interface PantheonLogoProps extends ComponentPropsWithoutRef<'div'> {
17
+ /**
18
+ * Color type. Use 'default' unless the logo is used on an approved dark background.
19
+ */
20
+ colorType?: 'default' | 'reverse';
21
+ /**
22
+ * Display type
23
+ */
24
+ displayType?: 'full' | 'icon' | 'wordmark' | 'sub-brand';
25
+ /**
26
+ * A fully-formed link element using the router of your choice. The link text will be used as the aria-label. If the logo should not be a link, set to `null`.
27
+ */
28
+ linkContent?: ReactNode;
29
+ /**
30
+ * An object containing a text string and an optional link (if the sub-brand text should be a link). Will only render if the `display-type` is set to 'sub-brand'.
31
+ */
32
+ subBrand?: SubBrand;
33
+ /**
34
+ * Additional class names
35
+ */
36
+ className?: string;
23
37
  }
24
- import React from 'react';
25
- import PropTypes from 'prop-types';
38
+ /**
39
+ * PantheonLogo UI component
40
+ */
41
+ export declare const PantheonLogo: ({ colorType, displayType, linkContent, subBrand, className, ...props }: PantheonLogoProps) => React.JSX.Element;
42
+ export {};
@@ -0,0 +1,4 @@
1
+ import React from 'react';
2
+ export declare const logoFull: React.JSX.Element;
3
+ export declare const logoIcon: React.JSX.Element;
4
+ export declare const logoWordmark: React.JSX.Element;
@@ -1,4 +1,4 @@
1
- export function Navbar({ children, colorType, containerWidth, hideBorder, hideLogo, logoDisplay, logoLabel, logoLink, logoSrc, logoSubBrand, className, ...props }: {
1
+ export function Navbar({ children, colorType, containerWidth, hideBorder, hideLogo, logoDisplay, logoLink, logoSrc, logoSubBrand, className, ...props }: {
2
2
  [x: string]: any;
3
3
  children: any;
4
4
  colorType?: string;
@@ -6,7 +6,6 @@ export function Navbar({ children, colorType, containerWidth, hideBorder, hideLo
6
6
  hideBorder: any;
7
7
  hideLogo?: boolean;
8
8
  logoDisplay?: string;
9
- logoLabel?: string;
10
9
  logoLink?: React.JSX.Element;
11
10
  logoSrc: any;
12
11
  logoSubBrand: any;
@@ -20,11 +19,10 @@ export namespace Navbar {
20
19
  export let hideBorder: PropTypes.Requireable<boolean>;
21
20
  export let hideLogo: PropTypes.Requireable<boolean>;
22
21
  export let logoDisplay: PropTypes.Requireable<string>;
23
- export let logoLabel: PropTypes.Requireable<string>;
24
22
  export let logoLink: PropTypes.Requireable<PropTypes.ReactNodeLike>;
25
23
  export let logoSrc: PropTypes.Requireable<string>;
26
24
  export let logoSubBrand: PropTypes.Requireable<PropTypes.InferProps<{
27
- link: PropTypes.Requireable<PropTypes.ReactNodeLike>;
25
+ linkContent: PropTypes.Requireable<PropTypes.ReactNodeLike>;
28
26
  text: PropTypes.Requireable<string>;
29
27
  }>>;
30
28
  export let className: PropTypes.Requireable<string>;
package/_dist/index.d.ts CHANGED
@@ -23,7 +23,6 @@ export { Navbar } from './components/navigation/Navbar/Navbar';
23
23
  export { NavMenu } from './components/navigation/NavMenu/NavMenu';
24
24
  export { NewSiteCard } from './components/cards/NewSiteCard/NewSiteCard';
25
25
  export { Pager } from './components/Pager/Pager';
26
- export { PantheonLogo } from './components/PantheonLogo/PantheonLogo';
27
26
  export { PlatformIcon } from './components/PlatformIcon/PlatformIcon';
28
27
  export { PricingCard } from './components/cards/PricingCard/PricingCard';
29
28
  export { RadioGroup } from './components/inputs/RadioGroup/RadioGroup';
@@ -72,6 +71,7 @@ export * from './components/notifications/Banner/Banner';
72
71
  export * from './components/notifications/InlineMessage/InlineMessage';
73
72
  export * from './components/notifications/SectionMessage/SectionMessage';
74
73
  export * from './components/Panel/Panel';
74
+ export * from './components/PantheonLogo/PantheonLogo';
75
75
  export * from './components/Popover/Popover';
76
76
  export * from './components/progress-indicators/ProgressBar/ProgressBar';
77
77
  export * from './components/progress-indicators/ProgressRing/ProgressRing';