@zendeskgarden/react-chrome 8.47.0 → 8.48.1
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/dist/index.cjs.js +314 -280
- package/dist/index.esm.js +177 -142
- package/dist/typings/elements/Chrome.d.ts +2 -3
- package/dist/typings/elements/SkipNav.d.ts +1 -2
- package/dist/typings/elements/body/Body.d.ts +3 -4
- package/dist/typings/elements/header/Header.d.ts +6 -3
- package/dist/typings/elements/header/HeaderItem.d.ts +15 -4
- package/dist/typings/elements/header/HeaderItemIcon.d.ts +3 -3
- package/dist/typings/elements/header/HeaderItemText.d.ts +6 -3
- package/dist/typings/elements/header/HeaderItemWrapper.d.ts +10 -3
- package/dist/typings/elements/nav/Nav.d.ts +1 -2
- package/dist/typings/elements/nav/NavItem.d.ts +1 -2
- package/dist/typings/elements/nav/NavItemIcon.d.ts +3 -3
- package/dist/typings/elements/nav/NavItemText.d.ts +6 -3
- package/dist/typings/elements/sheet/Sheet.d.ts +17 -19
- package/dist/typings/elements/sheet/components/Body.d.ts +4 -1
- package/dist/typings/elements/sheet/components/Close.d.ts +4 -1
- package/dist/typings/elements/sheet/components/Description.d.ts +4 -1
- package/dist/typings/elements/sheet/components/Footer.d.ts +9 -3
- package/dist/typings/elements/sheet/components/FooterItem.d.ts +4 -1
- package/dist/typings/elements/sheet/components/Header.d.ts +4 -1
- package/dist/typings/elements/sheet/components/Title.d.ts +4 -1
- package/dist/typings/elements/subnav/CollapsibleSubNavItem.d.ts +1 -1
- package/dist/typings/elements/subnav/SubNavItem.d.ts +3 -4
- package/dist/typings/elements/subnav/SubNavItemText.d.ts +9 -3
- package/dist/typings/index.d.ts +17 -1
- package/dist/typings/styled/header/StyledBaseHeaderItem.d.ts +0 -3
- package/dist/typings/styled/header/StyledHeader.d.ts +0 -1
- package/dist/typings/styled/header/StyledHeaderItemText.d.ts +0 -1
- package/dist/typings/styled/header/StyledLogoHeaderItem.d.ts +0 -5
- package/dist/typings/styled/nav/StyledNavItemText.d.ts +0 -2
- package/dist/typings/styled/sheet/StyledSheetClose.d.ts +5 -0
- package/dist/typings/styled/sheet/StyledSheetHeader.d.ts +4 -1
- package/dist/typings/styled/subnav/StyledSubNavItemText.d.ts +0 -4
- package/dist/typings/utils/useSheetContext.d.ts +2 -0
- package/package.json +4 -4
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
7
|
import React, { HTMLAttributes } from 'react';
|
|
8
|
-
interface IChromeProps extends HTMLAttributes<HTMLDivElement> {
|
|
8
|
+
export interface IChromeProps extends HTMLAttributes<HTMLDivElement> {
|
|
9
9
|
/** Applies a custom hue to the chrome navigation */
|
|
10
10
|
hue?: string;
|
|
11
11
|
/** Prevents fixed positioning from being applied to the `<html>` element */
|
|
@@ -14,5 +14,4 @@ interface IChromeProps extends HTMLAttributes<HTMLDivElement> {
|
|
|
14
14
|
/**
|
|
15
15
|
* @extends HTMLAttributes<HTMLDivElement>
|
|
16
16
|
*/
|
|
17
|
-
declare const Chrome: React.ForwardRefExoticComponent<IChromeProps & React.RefAttributes<HTMLDivElement>>;
|
|
18
|
-
export default Chrome;
|
|
17
|
+
export declare const Chrome: React.ForwardRefExoticComponent<IChromeProps & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
7
|
import React, { AnchorHTMLAttributes } from 'react';
|
|
8
|
-
interface ISkipNavProps extends AnchorHTMLAttributes<HTMLAnchorElement> {
|
|
8
|
+
export interface ISkipNavProps extends AnchorHTMLAttributes<HTMLAnchorElement> {
|
|
9
9
|
/** Sets the ID of the element to navigate to */
|
|
10
10
|
targetId: string;
|
|
11
11
|
/** Sets the `z-index` of the element */
|
|
@@ -15,4 +15,3 @@ interface ISkipNavProps extends AnchorHTMLAttributes<HTMLAnchorElement> {
|
|
|
15
15
|
* @extends AnchorHTMLAttributes<HTMLAnchorElement>
|
|
16
16
|
*/
|
|
17
17
|
export declare const SkipNav: React.ForwardRefExoticComponent<ISkipNavProps & React.RefAttributes<HTMLAnchorElement>>;
|
|
18
|
-
export {};
|
|
@@ -4,13 +4,12 @@
|
|
|
4
4
|
* Use of this source code is governed under the Apache License, Version 2.0
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
|
-
import React from 'react';
|
|
8
|
-
interface IBodyProps {
|
|
7
|
+
import React, { HTMLAttributes } from 'react';
|
|
8
|
+
export interface IBodyProps extends HTMLAttributes<HTMLDivElement> {
|
|
9
9
|
/** Adjusts the body content height to allow space for a footer component */
|
|
10
10
|
hasFooter?: boolean;
|
|
11
11
|
}
|
|
12
12
|
/**
|
|
13
13
|
* @extends HTMLAttributes<HTMLDivElement>
|
|
14
14
|
*/
|
|
15
|
-
export declare const Body: React.ForwardRefExoticComponent<IBodyProps & React.
|
|
16
|
-
export {};
|
|
15
|
+
export declare const Body: React.ForwardRefExoticComponent<IBodyProps & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -4,9 +4,12 @@
|
|
|
4
4
|
* Use of this source code is governed under the Apache License, Version 2.0
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
|
-
import React from 'react';
|
|
8
|
-
|
|
7
|
+
import React, { HTMLAttributes } from 'react';
|
|
8
|
+
export interface IHeaderProps extends HTMLAttributes<HTMLElement> {
|
|
9
|
+
/** Displays logo for standlone usage */
|
|
10
|
+
isStandalone?: boolean;
|
|
11
|
+
}
|
|
9
12
|
/**
|
|
10
13
|
* @extends HTMLAttributes<HTMLElement>
|
|
11
14
|
*/
|
|
12
|
-
export declare const Header: React.ForwardRefExoticComponent<
|
|
15
|
+
export declare const Header: React.ForwardRefExoticComponent<IHeaderProps & React.RefAttributes<HTMLElement>>;
|
|
@@ -5,13 +5,24 @@
|
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
7
|
import React, { ButtonHTMLAttributes } from 'react';
|
|
8
|
-
import {
|
|
9
|
-
interface
|
|
8
|
+
import { PRODUCT } from '../../utils/types';
|
|
9
|
+
export interface IHeaderItemProps extends ButtonHTMLAttributes<HTMLButtonElement> {
|
|
10
|
+
/** Maximizes the width of a flex item in the header */
|
|
11
|
+
maxX?: boolean;
|
|
12
|
+
/** Maximizes the height of the item (i.e. contains a search input) */
|
|
13
|
+
maxY?: boolean;
|
|
14
|
+
/** Rounds the border radius of the item */
|
|
15
|
+
isRound?: boolean;
|
|
16
|
+
/**
|
|
17
|
+
* Applies a
|
|
18
|
+
* [brand color](/design/color#brand-colors)
|
|
19
|
+
* to the product logo
|
|
20
|
+
*/
|
|
21
|
+
product?: PRODUCT;
|
|
10
22
|
/** Applies header logo styles to the item */
|
|
11
23
|
hasLogo?: boolean;
|
|
12
24
|
}
|
|
13
25
|
/**
|
|
14
26
|
* @extends ButtonHTMLAttributes<HTMLButtonElement>
|
|
15
27
|
*/
|
|
16
|
-
export declare const HeaderItem: React.ForwardRefExoticComponent<
|
|
17
|
-
export {};
|
|
28
|
+
export declare const HeaderItem: React.ForwardRefExoticComponent<IHeaderItemProps & React.RefAttributes<HTMLButtonElement>>;
|
|
@@ -4,8 +4,8 @@
|
|
|
4
4
|
* Use of this source code is governed under the Apache License, Version 2.0
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
|
-
import
|
|
7
|
+
import { HTMLAttributes, PropsWithChildren } from 'react';
|
|
8
8
|
/**
|
|
9
|
-
* @extends HTMLAttributes<
|
|
9
|
+
* @extends HTMLAttributes<HTMLElement>
|
|
10
10
|
*/
|
|
11
|
-
export declare const HeaderItemIcon:
|
|
11
|
+
export declare const HeaderItemIcon: ({ children, ...props }: PropsWithChildren<HTMLAttributes<HTMLElement>>) => JSX.Element | null;
|
|
@@ -4,9 +4,12 @@
|
|
|
4
4
|
* Use of this source code is governed under the Apache License, Version 2.0
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
|
-
import React from 'react';
|
|
8
|
-
|
|
7
|
+
import React, { HTMLAttributes } from 'react';
|
|
8
|
+
export interface IHeaderItemTextProps extends HTMLAttributes<HTMLElement> {
|
|
9
|
+
/** Hides item text. Text remains accessible to screen readers. */
|
|
10
|
+
isClipped?: boolean;
|
|
11
|
+
}
|
|
9
12
|
/**
|
|
10
13
|
* @extends HTMLAttributes<HTMLSpanElement>
|
|
11
14
|
*/
|
|
12
|
-
export declare const HeaderItemText: React.ForwardRefExoticComponent<
|
|
15
|
+
export declare const HeaderItemText: React.ForwardRefExoticComponent<IHeaderItemTextProps & React.RefAttributes<HTMLElement>>;
|
|
@@ -4,9 +4,16 @@
|
|
|
4
4
|
* Use of this source code is governed under the Apache License, Version 2.0
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
|
-
import React from 'react';
|
|
8
|
-
|
|
7
|
+
import React, { HTMLAttributes } from 'react';
|
|
8
|
+
export interface IHeaderItemWrapperProps extends HTMLAttributes<HTMLDivElement> {
|
|
9
|
+
/** Maximizes the width of a flex item in the header */
|
|
10
|
+
maxX?: boolean;
|
|
11
|
+
/** Maximizes the height of the item (i.e. contains a search input) */
|
|
12
|
+
maxY?: boolean;
|
|
13
|
+
/** Rounds the border radius of the item */
|
|
14
|
+
isRound?: boolean;
|
|
15
|
+
}
|
|
9
16
|
/**
|
|
10
17
|
* @extends HTMLAttributes<HTMLDivElement>
|
|
11
18
|
*/
|
|
12
|
-
export declare const HeaderItemWrapper: React.ForwardRefExoticComponent<
|
|
19
|
+
export declare const HeaderItemWrapper: React.ForwardRefExoticComponent<IHeaderItemWrapperProps & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
7
|
import React, { HTMLAttributes } from 'react';
|
|
8
|
-
interface INavProps extends HTMLAttributes<HTMLElement> {
|
|
8
|
+
export interface INavProps extends HTMLAttributes<HTMLElement> {
|
|
9
9
|
/** Expands the nav area to display the item text */
|
|
10
10
|
isExpanded?: boolean;
|
|
11
11
|
}
|
|
@@ -13,4 +13,3 @@ interface INavProps extends HTMLAttributes<HTMLElement> {
|
|
|
13
13
|
* @extends HTMLAttributes<HTMLElement>
|
|
14
14
|
*/
|
|
15
15
|
export declare const Nav: React.ForwardRefExoticComponent<INavProps & React.RefAttributes<HTMLElement>>;
|
|
16
|
-
export {};
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
*/
|
|
7
7
|
import React, { ButtonHTMLAttributes } from 'react';
|
|
8
8
|
import { PRODUCT } from '../../utils/types';
|
|
9
|
-
interface INavItemProps extends ButtonHTMLAttributes<HTMLButtonElement> {
|
|
9
|
+
export interface INavItemProps extends ButtonHTMLAttributes<HTMLButtonElement> {
|
|
10
10
|
/** Applies a product-specific color palette */
|
|
11
11
|
product?: PRODUCT;
|
|
12
12
|
/** Indicates that the item is current in the nav */
|
|
@@ -20,4 +20,3 @@ interface INavItemProps extends ButtonHTMLAttributes<HTMLButtonElement> {
|
|
|
20
20
|
* @extends ButtonHTMLAttributes<HTMLButtonElement>
|
|
21
21
|
*/
|
|
22
22
|
export declare const NavItem: React.ForwardRefExoticComponent<INavItemProps & React.RefAttributes<HTMLButtonElement>>;
|
|
23
|
-
export {};
|
|
@@ -4,8 +4,8 @@
|
|
|
4
4
|
* Use of this source code is governed under the Apache License, Version 2.0
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
|
-
import
|
|
7
|
+
import { HTMLAttributes, PropsWithChildren } from 'react';
|
|
8
8
|
/**
|
|
9
|
-
* @extends HTMLAttributes<
|
|
9
|
+
* @extends HTMLAttributes<HTMLElement>
|
|
10
10
|
*/
|
|
11
|
-
export declare const NavItemIcon:
|
|
11
|
+
export declare const NavItemIcon: ({ children, ...props }: PropsWithChildren<HTMLAttributes<HTMLElement>>) => JSX.Element | null;
|
|
@@ -4,9 +4,12 @@
|
|
|
4
4
|
* Use of this source code is governed under the Apache License, Version 2.0
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
|
-
import React from 'react';
|
|
8
|
-
|
|
7
|
+
import React, { HTMLAttributes } from 'react';
|
|
8
|
+
export interface INavItemTextProps extends HTMLAttributes<HTMLSpanElement> {
|
|
9
|
+
/** Wraps overflow item text instead of truncating long strings with an ellipsis **/
|
|
10
|
+
isWrapped?: boolean;
|
|
11
|
+
}
|
|
9
12
|
/**
|
|
10
13
|
* @extends HTMLAttributes<HTMLSpanElement>
|
|
11
14
|
*/
|
|
12
|
-
export declare const NavItemText: React.ForwardRefExoticComponent<
|
|
15
|
+
export declare const NavItemText: React.ForwardRefExoticComponent<INavItemTextProps & React.RefAttributes<HTMLElement>>;
|
|
@@ -4,23 +4,14 @@
|
|
|
4
4
|
* Use of this source code is governed under the Apache License, Version 2.0
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
|
-
import { HTMLAttributes
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
interface IStaticSheetExport<T, P> extends ForwardRefExoticComponent<PropsWithoutRef<P> & RefAttributes<T>> {
|
|
16
|
-
Title: typeof SheetTitle;
|
|
17
|
-
Description: typeof SheetDescription;
|
|
18
|
-
Header: typeof SheetHeader;
|
|
19
|
-
Body: typeof SheetBody;
|
|
20
|
-
Footer: typeof SheetFooter;
|
|
21
|
-
FooterItem: typeof SheetFooterItem;
|
|
22
|
-
Close: typeof SheetClose;
|
|
23
|
-
}
|
|
7
|
+
import React, { HTMLAttributes } from 'react';
|
|
8
|
+
import { Title } from './components/Title';
|
|
9
|
+
import { Description } from './components/Description';
|
|
10
|
+
import { Header } from './components/Header';
|
|
11
|
+
import { Body } from './components/Body';
|
|
12
|
+
import { Footer } from './components/Footer';
|
|
13
|
+
import { FooterItem } from './components/FooterItem';
|
|
14
|
+
import { Close } from './components/Close';
|
|
24
15
|
export interface ISheetProps extends HTMLAttributes<HTMLElement> {
|
|
25
16
|
/** Opens the Sheet **/
|
|
26
17
|
isOpen?: boolean;
|
|
@@ -38,5 +29,12 @@ export interface ISheetProps extends HTMLAttributes<HTMLElement> {
|
|
|
38
29
|
/**
|
|
39
30
|
* @extends HTMLAttributes<HTMLElement>
|
|
40
31
|
*/
|
|
41
|
-
export declare const Sheet:
|
|
42
|
-
|
|
32
|
+
export declare const Sheet: React.ForwardRefExoticComponent<ISheetProps & React.RefAttributes<HTMLElement>> & {
|
|
33
|
+
Body: typeof Body;
|
|
34
|
+
Close: typeof Close;
|
|
35
|
+
Description: typeof Description;
|
|
36
|
+
Footer: typeof Footer;
|
|
37
|
+
FooterItem: typeof FooterItem;
|
|
38
|
+
Header: typeof Header;
|
|
39
|
+
Title: typeof Title;
|
|
40
|
+
};
|
|
@@ -5,4 +5,7 @@
|
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
7
|
import React from 'react';
|
|
8
|
-
|
|
8
|
+
/**
|
|
9
|
+
* @extends HTMLAttributes<HTMLDivElement>
|
|
10
|
+
*/
|
|
11
|
+
export declare const Body: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -5,4 +5,7 @@
|
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
7
|
import React from 'react';
|
|
8
|
-
|
|
8
|
+
/**
|
|
9
|
+
* @extends ButtonHTMLAttributes<HTMLButtonElement>
|
|
10
|
+
*/
|
|
11
|
+
export declare const Close: React.ForwardRefExoticComponent<React.ButtonHTMLAttributes<HTMLButtonElement> & React.RefAttributes<HTMLButtonElement>>;
|
|
@@ -5,4 +5,7 @@
|
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
7
|
import React from 'react';
|
|
8
|
-
|
|
8
|
+
/**
|
|
9
|
+
* @extends HTMLAttributes<HTMLDivElement>
|
|
10
|
+
*/
|
|
11
|
+
export declare const Description: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -4,6 +4,12 @@
|
|
|
4
4
|
* Use of this source code is governed under the Apache License, Version 2.0
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
|
-
import React from 'react';
|
|
8
|
-
|
|
9
|
-
|
|
7
|
+
import React, { HTMLAttributes } from 'react';
|
|
8
|
+
export interface ISheetFooterProps extends HTMLAttributes<HTMLElement> {
|
|
9
|
+
/** Sets the footer padding to half the standard and centers the elements */
|
|
10
|
+
isCompact?: boolean;
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* @extends HTMLAttributes<HTMLElement>
|
|
14
|
+
*/
|
|
15
|
+
export declare const Footer: React.ForwardRefExoticComponent<ISheetFooterProps & React.RefAttributes<HTMLElement>>;
|
|
@@ -5,4 +5,7 @@
|
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
7
|
import React from 'react';
|
|
8
|
-
|
|
8
|
+
/**
|
|
9
|
+
* @extends HTMLAttributes<HTMLDivElement>
|
|
10
|
+
*/
|
|
11
|
+
export declare const FooterItem: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -5,4 +5,7 @@
|
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
7
|
import React from 'react';
|
|
8
|
-
|
|
8
|
+
/**
|
|
9
|
+
* @extends HTMLAttributes<HTMLElement>
|
|
10
|
+
*/
|
|
11
|
+
export declare const Header: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLElement> & React.RefAttributes<HTMLElement>>;
|
|
@@ -5,4 +5,7 @@
|
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
7
|
import React from 'react';
|
|
8
|
-
|
|
8
|
+
/**
|
|
9
|
+
* @extends HTMLAttributes<HTMLDivElement>
|
|
10
|
+
*/
|
|
11
|
+
export declare const Title: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -18,6 +18,6 @@ export interface ICollapsibleSubNavItemProps extends Omit<ButtonHTMLAttributes<H
|
|
|
18
18
|
onChange?: (isExpanded: boolean) => void;
|
|
19
19
|
}
|
|
20
20
|
/**
|
|
21
|
-
* @extends
|
|
21
|
+
* @extends ButtonHTMLAttributes<HTMLButtonElement>
|
|
22
22
|
*/
|
|
23
23
|
export declare const CollapsibleSubNavItem: React.ForwardRefExoticComponent<ICollapsibleSubNavItemProps & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -4,13 +4,12 @@
|
|
|
4
4
|
* Use of this source code is governed under the Apache License, Version 2.0
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
|
-
import React from 'react';
|
|
8
|
-
interface ISubNavItemProps {
|
|
7
|
+
import React, { ButtonHTMLAttributes } from 'react';
|
|
8
|
+
export interface ISubNavItemProps extends ButtonHTMLAttributes<HTMLButtonElement> {
|
|
9
9
|
/** Indicates that the item is current in the subnav */
|
|
10
10
|
isCurrent?: boolean;
|
|
11
11
|
}
|
|
12
12
|
/**
|
|
13
13
|
* @extends ButtonHTMLAttributes<HTMLButtonElement>
|
|
14
14
|
*/
|
|
15
|
-
export declare const SubNavItem: React.ForwardRefExoticComponent<ISubNavItemProps & React.
|
|
16
|
-
export {};
|
|
15
|
+
export declare const SubNavItem: React.ForwardRefExoticComponent<ISubNavItemProps & React.RefAttributes<HTMLButtonElement>>;
|
|
@@ -4,9 +4,15 @@
|
|
|
4
4
|
* Use of this source code is governed under the Apache License, Version 2.0
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
|
-
import React from 'react';
|
|
8
|
-
|
|
7
|
+
import React, { HTMLAttributes } from 'react';
|
|
8
|
+
export interface ISubNavItemTextProps extends HTMLAttributes<HTMLSpanElement> {
|
|
9
|
+
/**
|
|
10
|
+
* Wraps overflow item text instead of truncating long strings with an ellipsis.
|
|
11
|
+
* Use when `max-width` styling is applied to the subnav container.
|
|
12
|
+
**/
|
|
13
|
+
isWrapped?: boolean;
|
|
14
|
+
}
|
|
9
15
|
/**
|
|
10
16
|
* @extends HTMLAttributes<HTMLSpanElement>
|
|
11
17
|
*/
|
|
12
|
-
export declare const SubNavItemText: React.ForwardRefExoticComponent<
|
|
18
|
+
export declare const SubNavItemText: React.ForwardRefExoticComponent<ISubNavItemTextProps & React.RefAttributes<HTMLElement>>;
|
package/dist/typings/index.d.ts
CHANGED
|
@@ -4,25 +4,41 @@
|
|
|
4
4
|
* Use of this source code is governed under the Apache License, Version 2.0
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
|
-
export {
|
|
7
|
+
export { Chrome } from './elements/Chrome';
|
|
8
|
+
export type { IChromeProps } from './elements/Chrome';
|
|
8
9
|
export { SkipNav } from './elements/SkipNav';
|
|
10
|
+
export type { ISkipNavProps } from './elements/SkipNav';
|
|
9
11
|
export { Body } from './elements/body/Body';
|
|
12
|
+
export type { IBodyProps } from './elements/body/Body';
|
|
10
13
|
export { Content } from './elements/body/Content';
|
|
11
14
|
export { Main } from './elements/body/Main';
|
|
12
15
|
export { Sidebar } from './elements/body/Sidebar';
|
|
13
16
|
export { Header } from './elements/header/Header';
|
|
17
|
+
export type { IHeaderProps } from './elements/header/Header';
|
|
14
18
|
export { HeaderItem } from './elements/header/HeaderItem';
|
|
19
|
+
export type { IHeaderItemProps } from './elements/header/HeaderItem';
|
|
15
20
|
export { HeaderItemIcon } from './elements/header/HeaderItemIcon';
|
|
16
21
|
export { HeaderItemText } from './elements/header/HeaderItemText';
|
|
22
|
+
export type { IHeaderItemTextProps } from './elements/header/HeaderItemText';
|
|
17
23
|
export { HeaderItemWrapper } from './elements/header/HeaderItemWrapper';
|
|
24
|
+
export type { IHeaderItemWrapperProps } from './elements/header/HeaderItemWrapper';
|
|
18
25
|
export { Footer } from './elements/footer/Footer';
|
|
19
26
|
export { FooterItem } from './elements/footer/FooterItem';
|
|
20
27
|
export { Nav } from './elements/nav/Nav';
|
|
28
|
+
export type { INavProps } from './elements/nav/Nav';
|
|
21
29
|
export { NavItem } from './elements/nav/NavItem';
|
|
30
|
+
export type { INavItemProps } from './elements/nav/NavItem';
|
|
22
31
|
export { NavItemIcon } from './elements/nav/NavItemIcon';
|
|
23
32
|
export { NavItemText } from './elements/nav/NavItemText';
|
|
33
|
+
export type { INavItemTextProps } from './elements/nav/NavItemText';
|
|
24
34
|
export { SubNav } from './elements/subnav/SubNav';
|
|
25
35
|
export { SubNavItem } from './elements/subnav/SubNavItem';
|
|
36
|
+
export type { ISubNavItemProps } from './elements/subnav/SubNavItem';
|
|
26
37
|
export { SubNavItemText } from './elements/subnav/SubNavItemText';
|
|
38
|
+
export type { ISubNavItemTextProps } from './elements/subnav/SubNavItemText';
|
|
27
39
|
export { CollapsibleSubNavItem } from './elements/subnav/CollapsibleSubNavItem';
|
|
40
|
+
export type { ICollapsibleSubNavItemProps } from './elements/subnav/CollapsibleSubNavItem';
|
|
28
41
|
export { Sheet } from './elements/sheet/Sheet';
|
|
42
|
+
export type { ISheetProps } from './elements/sheet/Sheet';
|
|
43
|
+
export type { ISheetFooterProps } from './elements/sheet/components/Footer';
|
|
44
|
+
export { PRODUCT, PRODUCTS } from './utils/types';
|
|
@@ -6,11 +6,8 @@
|
|
|
6
6
|
*/
|
|
7
7
|
import { ThemeProps, DefaultTheme } from 'styled-components';
|
|
8
8
|
export interface IStyledBaseHeaderItemProps {
|
|
9
|
-
/** Maximizes the width of a flex item in the header */
|
|
10
9
|
maxX?: boolean;
|
|
11
|
-
/** Maximizes the height of the item (i.e. contains a search input) */
|
|
12
10
|
maxY?: boolean;
|
|
13
|
-
/** Rounds the border radius of the item */
|
|
14
11
|
isRound?: boolean;
|
|
15
12
|
}
|
|
16
13
|
export declare const getHeaderItemSize: (props: ThemeProps<DefaultTheme>) => string;
|
|
@@ -6,7 +6,6 @@
|
|
|
6
6
|
*/
|
|
7
7
|
import { ThemeProps, DefaultTheme } from 'styled-components';
|
|
8
8
|
export interface IStyledHeaderProps {
|
|
9
|
-
/** Displays logo for standlone usage */
|
|
10
9
|
isStandalone?: boolean;
|
|
11
10
|
}
|
|
12
11
|
export declare const getHeaderHeight: (props: ThemeProps<DefaultTheme>) => string;
|
|
@@ -5,7 +5,6 @@
|
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
7
|
export interface IStyledHeaderItemTextProps {
|
|
8
|
-
/** Hides item text. Text remains accessible to screen readers. */
|
|
9
8
|
isClipped?: boolean;
|
|
10
9
|
}
|
|
11
10
|
export declare const clippedStyling: import("styled-components").FlattenSimpleInterpolation;
|
|
@@ -5,9 +5,7 @@
|
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
7
|
export interface IStyledNavItemTextProps {
|
|
8
|
-
/** Wraps overflow item text instead of truncating long strings with an ellipsis **/
|
|
9
8
|
isWrapped?: boolean;
|
|
10
|
-
/** Reveals item text */
|
|
11
9
|
isExpanded?: boolean;
|
|
12
10
|
}
|
|
13
11
|
export declare const StyledNavItemText: import("styled-components").StyledComponent<"span", import("styled-components").DefaultTheme, IStyledNavItemTextProps, never>;
|
|
@@ -5,6 +5,11 @@
|
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
7
|
import { ThemeProps, DefaultTheme } from 'styled-components';
|
|
8
|
+
export declare const baseMultipliers: {
|
|
9
|
+
top: number;
|
|
10
|
+
side: number;
|
|
11
|
+
size: number;
|
|
12
|
+
};
|
|
8
13
|
export declare const StyledSheetClose: import("styled-components").StyledComponent<"button", DefaultTheme, {
|
|
9
14
|
'data-garden-id': string;
|
|
10
15
|
'data-garden-version': string;
|
|
@@ -5,7 +5,10 @@
|
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
7
|
import { ThemeProps, DefaultTheme } from 'styled-components';
|
|
8
|
+
export interface IStyledSheetHeaderProps {
|
|
9
|
+
isCloseButtonPresent?: boolean;
|
|
10
|
+
}
|
|
8
11
|
export declare const StyledSheetHeader: import("styled-components").StyledComponent<"header", DefaultTheme, {
|
|
9
12
|
'data-garden-id': string;
|
|
10
13
|
'data-garden-version': string;
|
|
11
|
-
} & ThemeProps<DefaultTheme>, "data-garden-id" | "data-garden-version">;
|
|
14
|
+
} & IStyledSheetHeaderProps & ThemeProps<DefaultTheme>, "data-garden-id" | "data-garden-version">;
|
|
@@ -6,10 +6,6 @@
|
|
|
6
6
|
*/
|
|
7
7
|
import { DefaultTheme } from 'styled-components';
|
|
8
8
|
export interface IStyledSubNavItemTextProps {
|
|
9
|
-
/**
|
|
10
|
-
* Wraps overflow item text instead of truncating long strings with an ellipsis.
|
|
11
|
-
* Use when `max-width` styling is applied to the subnav container.
|
|
12
|
-
**/
|
|
13
9
|
isWrapped?: boolean;
|
|
14
10
|
}
|
|
15
11
|
export declare const StyledSubNavItemText: import("styled-components").StyledComponent<"span", DefaultTheme, IStyledSubNavItemTextProps, never>;
|
|
@@ -8,6 +8,8 @@
|
|
|
8
8
|
export interface ISheetContext {
|
|
9
9
|
titleId?: string;
|
|
10
10
|
descriptionId?: string;
|
|
11
|
+
isCloseButtonPresent?: boolean;
|
|
12
|
+
setCloseButtonPresent: (isPresent: boolean) => void;
|
|
11
13
|
}
|
|
12
14
|
export declare const SheetContext: import("react").Context<ISheetContext>;
|
|
13
15
|
export declare const useSheetContext: () => ISheetContext;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zendeskgarden/react-chrome",
|
|
3
|
-
"version": "8.
|
|
3
|
+
"version": "8.48.1",
|
|
4
4
|
"description": "Components relating to Chrome within the Garden Design System.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"author": "Zendesk Garden <garden@zendesk.com>",
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
"types": "dist/typings/index.d.ts",
|
|
23
23
|
"dependencies": {
|
|
24
24
|
"@zendeskgarden/container-accordion": "^1.0.3",
|
|
25
|
-
"@zendeskgarden/container-utilities": "^0.
|
|
25
|
+
"@zendeskgarden/container-utilities": "^0.7.0",
|
|
26
26
|
"dom-helpers": "^5.2.1",
|
|
27
27
|
"polished": "^4.0.0",
|
|
28
28
|
"prop-types": "^15.5.7",
|
|
@@ -35,7 +35,7 @@
|
|
|
35
35
|
"styled-components": "^4.2.0 || ^5.0.0"
|
|
36
36
|
},
|
|
37
37
|
"devDependencies": {
|
|
38
|
-
"@zendeskgarden/react-theming": "^8.
|
|
38
|
+
"@zendeskgarden/react-theming": "^8.48.1",
|
|
39
39
|
"@zendeskgarden/svg-icons": "6.30.2"
|
|
40
40
|
},
|
|
41
41
|
"keywords": [
|
|
@@ -48,5 +48,5 @@
|
|
|
48
48
|
"access": "public"
|
|
49
49
|
},
|
|
50
50
|
"zendeskgarden:src": "src/index.ts",
|
|
51
|
-
"gitHead": "
|
|
51
|
+
"gitHead": "82c621bfbc943904baa6647a2f5e89d3271d7edf"
|
|
52
52
|
}
|