@peripheries/core 0.3.0 → 0.4.0
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/README.md +1 -1
- package/index.css +1 -1
- package/index.js +454 -352
- package/package.json +1 -1
- package/types/core/display/DataTable/DataTable.d.ts +2 -1
- package/types/core/feedback/EmptyState/EmptyState.d.ts +9 -0
- package/types/core/page/ListRow/ListRow.d.ts +13 -0
- package/types/core/page/PageHead/PageHead.d.ts +10 -0
- package/types/index.core.d.ts +3 -0
package/package.json
CHANGED
|
@@ -10,7 +10,7 @@ export interface DataTableColumn {
|
|
|
10
10
|
minWidth?: number;
|
|
11
11
|
format?: DataTableColumnFormat;
|
|
12
12
|
}
|
|
13
|
-
export type DataTableColumnFormat = 'date' | 'datetime';
|
|
13
|
+
export type DataTableColumnFormat = 'date' | 'datetime' | 'raw';
|
|
14
14
|
export interface DataTableCell {
|
|
15
15
|
value: FormattableValue | ReactNode;
|
|
16
16
|
tone?: Tone | string;
|
|
@@ -29,4 +29,5 @@ export interface DataTableProps {
|
|
|
29
29
|
className?: string;
|
|
30
30
|
style?: CSSProperties;
|
|
31
31
|
}
|
|
32
|
+
export declare function asWords(value: string): string;
|
|
32
33
|
export declare function DataTable({ title, subtitle, columns, rows, className, style }: DataTableProps): ReactElement;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { ReactNode, CSSProperties } from 'react';
|
|
2
|
+
export interface EmptyStateProps {
|
|
3
|
+
message: string;
|
|
4
|
+
title?: string;
|
|
5
|
+
action?: ReactNode;
|
|
6
|
+
className?: string;
|
|
7
|
+
style?: CSSProperties;
|
|
8
|
+
}
|
|
9
|
+
export declare function EmptyState({ message, title, action, className, ...rest }: EmptyStateProps): import("react").JSX.Element;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { ReactNode, CSSProperties } from 'react';
|
|
2
|
+
import { type PressProps } from '../../actions/_shared/press';
|
|
3
|
+
export interface ListRowProps extends Pick<PressProps, 'href' | 'navigate' | 'onClick'> {
|
|
4
|
+
title: ReactNode;
|
|
5
|
+
meta?: ReactNode;
|
|
6
|
+
leading?: ReactNode;
|
|
7
|
+
value?: ReactNode;
|
|
8
|
+
trailing?: ReactNode;
|
|
9
|
+
as?: 'li' | 'div';
|
|
10
|
+
className?: string;
|
|
11
|
+
style?: CSSProperties;
|
|
12
|
+
}
|
|
13
|
+
export declare function ListRow({ title, meta, leading, value, trailing, href, navigate, onClick, as, className, ...rest }: ListRowProps): import("react").JSX.Element;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { ReactNode, CSSProperties } from 'react';
|
|
2
|
+
export interface PageHeadProps {
|
|
3
|
+
title: string;
|
|
4
|
+
eyebrow?: string;
|
|
5
|
+
intro?: ReactNode;
|
|
6
|
+
actions?: ReactNode;
|
|
7
|
+
className?: string;
|
|
8
|
+
style?: CSSProperties;
|
|
9
|
+
}
|
|
10
|
+
export declare function PageHead({ title, eyebrow, intro, actions, className, ...rest }: PageHeadProps): import("react").JSX.Element;
|
package/types/index.core.d.ts
CHANGED
|
@@ -8,7 +8,9 @@ export { Inline } from './core/Inline/Inline';
|
|
|
8
8
|
export { Show } from './core/Show/Show';
|
|
9
9
|
export { Spacer } from './core/Spacer/Spacer';
|
|
10
10
|
export { Stack } from './core/Stack/Stack';
|
|
11
|
+
export { ListRow, type ListRowProps } from './core/page/ListRow/ListRow';
|
|
11
12
|
export { PageFrame, type PageFrameProps } from './core/page/PageFrame/PageFrame';
|
|
13
|
+
export { PageHead, type PageHeadProps } from './core/page/PageHead/PageHead';
|
|
12
14
|
export { RuleSection, type RuleSectionProps } from './core/page/RuleSection/RuleSection';
|
|
13
15
|
export { UnderlinedAction, type UnderlinedActionProps } from './core/page/UnderlinedAction/UnderlinedAction';
|
|
14
16
|
export { Avatar, initialsOf, type AvatarProps } from './core/text/Avatar/Avatar';
|
|
@@ -29,6 +31,7 @@ export { TextArea, type TextAreaProps } from './core/forms/TextArea/TextArea';
|
|
|
29
31
|
export { TextField, toNumber, type TextFieldProps, type TextFieldType } from './core/forms/TextField/TextField';
|
|
30
32
|
export type { ChoiceOption, FieldProps } from './core/forms/_shared/field';
|
|
31
33
|
export { Badge, type BadgeProps } from './core/feedback/Badge/Badge';
|
|
34
|
+
export { EmptyState, type EmptyStateProps } from './core/feedback/EmptyState/EmptyState';
|
|
32
35
|
export { Notice, type NoticeProps } from './core/feedback/Notice/Notice';
|
|
33
36
|
export { Progress, type ProgressProps } from './core/feedback/Progress/Progress';
|
|
34
37
|
export { Skeleton, type SkeletonProps } from './core/feedback/Skeleton/Skeleton';
|