@4alldigital/foundation-ui--gamma 1.21.2 → 1.22.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/foundation-ui.css +1 -1
- package/dist/index.esm.js +177 -13
- package/dist/index.js +184 -10
- package/dist/types/fui/components/Blockquote/Blockquote.d.ts +8 -0
- package/dist/types/fui/components/Blockquote/Blockquote.stories.d.ts +6 -0
- package/dist/types/fui/components/Blockquote/Blockquote.test.d.ts +1 -0
- package/dist/types/fui/components/Blockquote/Blockquote.types.d.ts +7 -0
- package/dist/types/fui/components/Blockquote/index.d.ts +1 -0
- package/dist/types/fui/components/Button/Button.d.ts +6 -0
- package/dist/types/fui/components/Button/Button.stories.d.ts +8 -0
- package/dist/types/fui/components/Button/Button.test.d.ts +1 -0
- package/dist/types/fui/components/Button/Button.types.d.ts +20 -0
- package/dist/types/fui/components/Button/index.d.ts +1 -0
- package/dist/types/fui/components/Container/Container.d.ts +6 -0
- package/dist/types/fui/components/Container/Container.stories.d.ts +6 -0
- package/dist/types/fui/components/Container/Container.test.d.ts +1 -0
- package/dist/types/fui/components/Container/Container.types.d.ts +6 -0
- package/dist/types/fui/components/Container/index.d.ts +1 -0
- package/dist/types/fui/components/ContentPageLayout/ContentPageLayout.d.ts +3 -0
- package/dist/types/fui/components/ContentPageLayout/ContentPageLayout.stories.d.ts +6 -0
- package/dist/types/fui/components/ContentPageLayout/ContentPageLayout.test.d.ts +1 -0
- package/dist/types/fui/components/ContentPageLayout/ContentPageLayout.types.d.ts +17 -0
- package/dist/types/fui/components/ContentPageLayout/index.d.ts +1 -0
- package/dist/types/fui/components/ContentRowsLayout/ContentRowsLayout.d.ts +8 -0
- package/dist/types/fui/components/ContentRowsLayout/ContentRowsLayout.stories.d.ts +6 -0
- package/dist/types/fui/components/ContentRowsLayout/ContentRowsLayout.test.d.ts +1 -0
- package/dist/types/fui/components/ContentRowsLayout/ContentRowsLayout.types.d.ts +15 -0
- package/dist/types/fui/components/ContentRowsLayout/index.d.ts +1 -0
- package/dist/types/fui/components/Copy/Copy.d.ts +11 -0
- package/dist/types/fui/components/Copy/Copy.stories.d.ts +6 -0
- package/dist/types/fui/components/Copy/Copy.test.d.ts +1 -0
- package/dist/types/fui/components/Copy/Copy.types.d.ts +40 -0
- package/dist/types/fui/components/Copy/index.d.ts +1 -0
- package/dist/types/fui/components/Heading/Heading.d.ts +8 -0
- package/dist/types/fui/components/Heading/Heading.stories.d.ts +7 -0
- package/dist/types/fui/components/Heading/Heading.test.d.ts +1 -0
- package/dist/types/fui/components/Heading/Heading.types.d.ts +31 -0
- package/dist/types/fui/components/Heading/index.d.ts +1 -0
- package/dist/types/fui/components/Hr/Hr.d.ts +2 -0
- package/dist/types/fui/components/Hr/Hr.stories.d.ts +6 -0
- package/dist/types/fui/components/Hr/Hr.test.d.ts +1 -0
- package/dist/types/fui/components/Hr/index.d.ts +1 -0
- package/dist/types/fui/components/Icon/Icon.d.ts +12 -0
- package/dist/types/fui/components/Icon/Icon.stories.d.ts +6 -0
- package/dist/types/fui/components/Icon/Icon.test.d.ts +1 -0
- package/dist/types/fui/components/Icon/Icon.types.d.ts +7 -0
- package/dist/types/fui/components/Icon/index.d.ts +1 -0
- package/dist/types/fui/components/Image/Image.d.ts +3 -0
- package/dist/types/fui/components/Image/Image.stories.d.ts +6 -0
- package/dist/types/fui/components/Image/Image.test.d.ts +1 -0
- package/dist/types/fui/components/Image/Image.types.d.ts +16 -0
- package/dist/types/fui/components/Image/index.d.ts +1 -0
- package/dist/types/fui/components/Link/Link.d.ts +11 -0
- package/dist/types/fui/components/Link/Link.stories.d.ts +6 -0
- package/dist/types/fui/components/Link/Link.test.d.ts +1 -0
- package/dist/types/fui/components/Link/Link.types.d.ts +12 -0
- package/dist/types/fui/components/Link/index.d.ts +1 -0
- package/dist/types/fui/components/List/List.d.ts +8 -0
- package/dist/types/fui/components/List/List.stories.d.ts +6 -0
- package/dist/types/fui/components/List/List.test.d.ts +1 -0
- package/dist/types/fui/components/List/List.types.d.ts +24 -0
- package/dist/types/fui/components/List/index.d.ts +1 -0
- package/dist/types/fui/components/ListItem/ListItem.d.ts +8 -0
- package/dist/types/fui/components/ListItem/ListItem.test.d.ts +1 -0
- package/dist/types/fui/components/ListItem/ListItem.types.d.ts +7 -0
- package/dist/types/fui/components/ListItem/index.d.ts +1 -0
- package/dist/types/fui/components/Loader/Loader.d.ts +8 -0
- package/dist/types/fui/components/Loader/Loader.stories.d.ts +6 -0
- package/dist/types/fui/components/Loader/Loader.test.d.ts +1 -0
- package/dist/types/fui/components/Loader/Loader.types.d.ts +4 -0
- package/dist/types/fui/components/Loader/index.d.ts +1 -0
- package/dist/types/fui/components/Notice/Notice.d.ts +3 -0
- package/dist/types/fui/components/Notice/Notice.stories.d.ts +6 -0
- package/dist/types/fui/components/Notice/Notice.test.d.ts +1 -0
- package/dist/types/fui/components/Notice/Notice.types.d.ts +5 -0
- package/dist/types/fui/components/Notice/index.d.ts +1 -0
- package/dist/types/fui/components/index.d.ts +15 -0
- package/dist/types/fui/context/ThemeContext.d.ts +18 -0
- package/dist/types/fui/index.d.ts +1 -0
- package/dist/types/fui/setupTests.d.ts +1 -0
- package/dist/types/fui/stories/Header.d.ts +11 -0
- package/dist/types/fui/stories/Header.stories.d.ts +8 -0
- package/dist/types/fui/stories/Page.d.ts +2 -0
- package/dist/types/fui/stories/Page.stories.d.ts +8 -0
- package/package.json +2 -2
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from './Container';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export declare enum SPACING {
|
|
3
|
+
NONE = "none",
|
|
4
|
+
ATOM = "atom",
|
|
5
|
+
DEFAULT = "default",
|
|
6
|
+
ELEMENT = "element",
|
|
7
|
+
COMPONENT = "component",
|
|
8
|
+
MODULE = "module",
|
|
9
|
+
FEATURE = "feature"
|
|
10
|
+
}
|
|
11
|
+
export interface Props {
|
|
12
|
+
children: React.ReactNode;
|
|
13
|
+
narrow?: boolean;
|
|
14
|
+
flush?: boolean;
|
|
15
|
+
spacing?: SPACING;
|
|
16
|
+
className?: string;
|
|
17
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from './ContentPageLayout';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export declare enum SIZE {
|
|
3
|
+
NONE = "none",
|
|
4
|
+
ATOM = "atom",
|
|
5
|
+
DEFAULT = "default",
|
|
6
|
+
ELEMENT = "element",
|
|
7
|
+
COMPONENT = "component",
|
|
8
|
+
MODULE = "module",
|
|
9
|
+
FEATURE = "feature"
|
|
10
|
+
}
|
|
11
|
+
export interface Props {
|
|
12
|
+
className?: string;
|
|
13
|
+
children: React.ReactNode;
|
|
14
|
+
size?: SIZE;
|
|
15
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from './ContentRowsLayout';
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Align, Props, Tag } from './Copy.types';
|
|
2
|
+
declare const Copy: {
|
|
3
|
+
({ children, tag: Tag, size, align, transform, id, testID }: Props): React.ReactElement;
|
|
4
|
+
defaultProps: {
|
|
5
|
+
inverted: boolean;
|
|
6
|
+
maxLength: boolean;
|
|
7
|
+
tag: Tag;
|
|
8
|
+
align: Align;
|
|
9
|
+
};
|
|
10
|
+
};
|
|
11
|
+
export default Copy;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export declare enum Align {
|
|
3
|
+
LEFT = "left",
|
|
4
|
+
CENTER = "center",
|
|
5
|
+
RIGHT = "right",
|
|
6
|
+
JUSTIFY = "justify",
|
|
7
|
+
NOWRAP = "nowrap"
|
|
8
|
+
}
|
|
9
|
+
export declare enum Transform {
|
|
10
|
+
LOWERCASE = "lowercase",
|
|
11
|
+
UPPERCASE = "uppercase",
|
|
12
|
+
CAPITALIZE = "capitalize",
|
|
13
|
+
NORMALCASE = "normal-case"
|
|
14
|
+
}
|
|
15
|
+
export declare enum Contextual {
|
|
16
|
+
INVERTED = "inverted",
|
|
17
|
+
MUTED = "muted"
|
|
18
|
+
}
|
|
19
|
+
export declare enum Size {
|
|
20
|
+
SMALL = "small",
|
|
21
|
+
LARGE = "large",
|
|
22
|
+
INTRO = "intro"
|
|
23
|
+
}
|
|
24
|
+
export declare enum Tag {
|
|
25
|
+
P = "p",
|
|
26
|
+
DIV = "div",
|
|
27
|
+
SMALL = "small"
|
|
28
|
+
}
|
|
29
|
+
export interface Props {
|
|
30
|
+
children: string | Array<React.ReactNode> | React.ReactNode;
|
|
31
|
+
align?: Align;
|
|
32
|
+
size?: Size;
|
|
33
|
+
transform?: Transform;
|
|
34
|
+
contextual?: Contextual;
|
|
35
|
+
inverted?: boolean;
|
|
36
|
+
maxLength?: boolean;
|
|
37
|
+
tag: Tag;
|
|
38
|
+
id?: string;
|
|
39
|
+
testID?: string;
|
|
40
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from './Copy';
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from '@storybook/react';
|
|
2
|
+
import Heading from '.';
|
|
3
|
+
declare const meta: Meta<typeof Heading>;
|
|
4
|
+
type Story = StoryObj<typeof Heading>;
|
|
5
|
+
export declare const Default: Story;
|
|
6
|
+
export declare const Examples: Story;
|
|
7
|
+
export default meta;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export declare enum HeadingTag {
|
|
3
|
+
H1 = "h1",
|
|
4
|
+
H2 = "h2",
|
|
5
|
+
H3 = "h3",
|
|
6
|
+
H4 = "h4",
|
|
7
|
+
H5 = "h5"
|
|
8
|
+
}
|
|
9
|
+
export declare enum HeadingAlign {
|
|
10
|
+
LEFT = "left",
|
|
11
|
+
CENTER = "center",
|
|
12
|
+
RIGHT = "right",
|
|
13
|
+
JUSTIFY = "justify",
|
|
14
|
+
NOWRAP = "nowrap"
|
|
15
|
+
}
|
|
16
|
+
export declare enum HeadingTransform {
|
|
17
|
+
LOWERCASE = "lowercase",
|
|
18
|
+
UPPERCASE = "uppercase",
|
|
19
|
+
CAPITALIZE = "capitalize",
|
|
20
|
+
NORMAL_CASE = "normal-case"
|
|
21
|
+
}
|
|
22
|
+
export interface Props {
|
|
23
|
+
children: string | React.ReactNode;
|
|
24
|
+
tag: HeadingTag;
|
|
25
|
+
align?: HeadingAlign;
|
|
26
|
+
transform?: HeadingTransform;
|
|
27
|
+
id?: string;
|
|
28
|
+
testID?: string;
|
|
29
|
+
flush?: boolean;
|
|
30
|
+
className?: string;
|
|
31
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from './Heading';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from './Hr';
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { Props } from './Icon.types';
|
|
2
|
+
/**
|
|
3
|
+
* Icon component
|
|
4
|
+
* List of supported icons can be found at https://icon-sets.iconify.design.
|
|
5
|
+
*/
|
|
6
|
+
declare const Icon: {
|
|
7
|
+
({ name, size, color, id, testID }: Props): React.ReactElement;
|
|
8
|
+
defaultProps: {
|
|
9
|
+
size: number;
|
|
10
|
+
};
|
|
11
|
+
};
|
|
12
|
+
export default Icon;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from './Icon';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
export type Props = {
|
|
2
|
+
src: string;
|
|
3
|
+
alt: string;
|
|
4
|
+
title?: string;
|
|
5
|
+
onLoad?: () => void;
|
|
6
|
+
/** Image caption, will display as a `figure` if set. */
|
|
7
|
+
caption?: string;
|
|
8
|
+
/** Display within a `figure`. */
|
|
9
|
+
figure?: boolean;
|
|
10
|
+
/** The image will take up the entire width of the container. */
|
|
11
|
+
fluid?: boolean;
|
|
12
|
+
crossOrigin?: 'anonymous' | 'use-credentials';
|
|
13
|
+
id?: string;
|
|
14
|
+
testID?: string;
|
|
15
|
+
className?: string;
|
|
16
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from './Image';
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Props } from './Link.types';
|
|
2
|
+
declare const Link: {
|
|
3
|
+
({ href, children, onClick, history, target, id, testID, className }: Props): React.ReactElement;
|
|
4
|
+
defaultProps: {
|
|
5
|
+
href: undefined;
|
|
6
|
+
onClick: () => void;
|
|
7
|
+
history: undefined;
|
|
8
|
+
target: undefined;
|
|
9
|
+
};
|
|
10
|
+
};
|
|
11
|
+
export default Link;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { History } from 'history';
|
|
3
|
+
export interface Props {
|
|
4
|
+
href: string;
|
|
5
|
+
children: React.ReactNode;
|
|
6
|
+
history?: History;
|
|
7
|
+
target?: '_self' | '_blank' | '_parent' | '_top';
|
|
8
|
+
onClick?: React.MouseEventHandler;
|
|
9
|
+
id?: string;
|
|
10
|
+
testID?: string;
|
|
11
|
+
className?: string;
|
|
12
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from './Link';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export type VariantsTypes = 'unstyled' | 'inline' | 'small' | 'large';
|
|
3
|
+
export declare enum Variants {
|
|
4
|
+
UNSTYLED = "unstyled",
|
|
5
|
+
INLINE = "inline",
|
|
6
|
+
SMALL = "small",
|
|
7
|
+
LARGE = "large"
|
|
8
|
+
}
|
|
9
|
+
export declare enum ListTag {
|
|
10
|
+
OL = "ol",
|
|
11
|
+
UL = "ul",
|
|
12
|
+
DL = "dl",
|
|
13
|
+
DIV = "div",
|
|
14
|
+
DT = "dt",
|
|
15
|
+
DD = "dd",
|
|
16
|
+
LI = "li"
|
|
17
|
+
}
|
|
18
|
+
export type Props = {
|
|
19
|
+
variants?: Array<Variants>;
|
|
20
|
+
children: string | React.ReactNode | Array<React.ReactNode>;
|
|
21
|
+
as: ListTag;
|
|
22
|
+
id?: string;
|
|
23
|
+
testID?: string;
|
|
24
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from './List';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from './ListItem';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from './Loader';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from './Notice';
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export { default as Blockquote } from './Blockquote';
|
|
2
|
+
export { default as Button } from './Button';
|
|
3
|
+
export { default as Copy } from './Copy';
|
|
4
|
+
export { default as Hr } from './Hr';
|
|
5
|
+
export { default as Heading } from './Heading';
|
|
6
|
+
export { default as Icon } from './Icon';
|
|
7
|
+
export { default as Image } from './Image';
|
|
8
|
+
export { default as Link } from './Link';
|
|
9
|
+
export { default as List } from './List';
|
|
10
|
+
export { default as ListItem } from './ListItem';
|
|
11
|
+
export { default as Notice } from './Notice';
|
|
12
|
+
export { default as Loader } from './Loader';
|
|
13
|
+
export { default as Container } from './Container';
|
|
14
|
+
export { default as ContentPageLayout } from './ContentPageLayout';
|
|
15
|
+
export { default as ContentRowsLayout } from './ContentRowsLayout';
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
interface Brand {
|
|
3
|
+
logo: string;
|
|
4
|
+
name: string;
|
|
5
|
+
}
|
|
6
|
+
interface ThemeContextProps {
|
|
7
|
+
isDarkTheme: boolean;
|
|
8
|
+
toggleTheme: () => void;
|
|
9
|
+
brand?: Brand;
|
|
10
|
+
}
|
|
11
|
+
export declare const defaultTheme: ThemeContextProps;
|
|
12
|
+
export declare const ThemeContext: React.Context<ThemeContextProps>;
|
|
13
|
+
interface ThemeProviderProps {
|
|
14
|
+
children: React.ReactNode;
|
|
15
|
+
theme: ThemeContextProps;
|
|
16
|
+
}
|
|
17
|
+
declare const ThemeProvider: ({ children, theme }: ThemeProviderProps) => React.ReactElement;
|
|
18
|
+
export default ThemeProvider;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './components';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import '@testing-library/jest-dom';
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
type User = {
|
|
2
|
+
name: string;
|
|
3
|
+
};
|
|
4
|
+
interface HeaderProps {
|
|
5
|
+
user?: User;
|
|
6
|
+
onLogin: () => void;
|
|
7
|
+
onLogout: () => void;
|
|
8
|
+
onCreateAccount: () => void;
|
|
9
|
+
}
|
|
10
|
+
export declare const Header: ({ user, onLogin, onLogout, onCreateAccount }: HeaderProps) => import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from '@storybook/react';
|
|
2
|
+
import { Header } from './Header';
|
|
3
|
+
declare const meta: Meta<typeof Header>;
|
|
4
|
+
export default meta;
|
|
5
|
+
type Story = StoryObj<typeof Header>;
|
|
6
|
+
export declare const Default: Story;
|
|
7
|
+
export declare const LoggedIn: Story;
|
|
8
|
+
export declare const LoggedOut: Story;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from '@storybook/react';
|
|
2
|
+
import { Page } from './Page';
|
|
3
|
+
declare const meta: Meta<typeof Page>;
|
|
4
|
+
export default meta;
|
|
5
|
+
type Story = StoryObj<typeof Page>;
|
|
6
|
+
export declare const Default: Story;
|
|
7
|
+
export declare const LoggedOut: Story;
|
|
8
|
+
export declare const LoggedIn: Story;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@4alldigital/foundation-ui--gamma",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.22.1",
|
|
4
4
|
"description": "Foundation UI Component library with GAMMA theme. ",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"module": "dist/index.esm.js",
|
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
"publishConfig": {
|
|
25
25
|
"access": "public"
|
|
26
26
|
},
|
|
27
|
-
"gitHead": "
|
|
27
|
+
"gitHead": "cd3209776ac9773506e9c264f00e12225468b878",
|
|
28
28
|
"dependencies": {
|
|
29
29
|
"@headlessui/react": "^1.7.8",
|
|
30
30
|
"@heroicons/react": "^2.0.14",
|