@propellerads/empty-state 4.0.1 → 5.0.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 +89 -11
- package/dist/index.css +1 -0
- package/dist/index.d.ts +61 -8
- package/dist/index.js +58 -25
- package/dist/index.js.map +1 -1
- package/package.json +25 -10
package/README.md
CHANGED
|
@@ -1,6 +1,13 @@
|
|
|
1
1
|
# EmptyState
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
What a page shows when there is nothing to show yet: a picture, a line that says
|
|
4
|
+
what is missing, a sentence on what happens next, and what to do about it.
|
|
5
|
+
|
|
6
|
+
Version 5 is built the way [Button](../Button/README.md) is: one stylesheet,
|
|
7
|
+
variants picked by [class-variance-authority](https://cva.style/), every colour,
|
|
8
|
+
gap, corner and font from [@propellerads/tokens](../Tokens/README.md). The parts
|
|
9
|
+
follow [shadcn's Empty](https://ui.shadcn.com/docs/components/base/empty).
|
|
10
|
+
|
|
4
11
|

|
|
5
12
|
|
|
6
13
|
[NPM](https://www.npmjs.com/package/@propellerads/empty-state) |
|
|
@@ -8,18 +15,89 @@
|
|
|
8
15
|
|
|
9
16
|
## Installation
|
|
10
17
|
|
|
11
|
-
|
|
18
|
+
```sh
|
|
19
|
+
bun add @propellerads/empty-state
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
The built entry imports its own stylesheet. The tokens are the app's:
|
|
23
|
+
|
|
24
|
+
```ts
|
|
25
|
+
import '@propellerads/tokens/common.css';
|
|
26
|
+
import '@propellerads/tokens/propellerads.css'; // or monetag / propush / zeydoo
|
|
27
|
+
```
|
|
12
28
|
|
|
13
|
-
|
|
29
|
+
## Use
|
|
14
30
|
|
|
15
|
-
|
|
16
|
-
|
|
31
|
+
```tsx
|
|
32
|
+
import Empty, {EmptyContent, EmptyDescription, EmptyHeader, EmptyMedia, EmptyTitle} from '@propellerads/empty-state';
|
|
17
33
|
|
|
34
|
+
<Empty variant="outline">
|
|
35
|
+
<EmptyHeader>
|
|
36
|
+
<EmptyMedia variant="icon"><FolderIcon /></EmptyMedia>
|
|
37
|
+
<EmptyTitle render={<h2 />}>No projects yet</EmptyTitle>
|
|
38
|
+
<EmptyDescription>Get started by creating your first project.</EmptyDescription>
|
|
39
|
+
</EmptyHeader>
|
|
40
|
+
<EmptyContent>
|
|
41
|
+
<Button>Create project</Button>
|
|
42
|
+
</EmptyContent>
|
|
43
|
+
</Empty>
|
|
18
44
|
```
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
45
|
+
|
|
46
|
+
## Moving from v4
|
|
47
|
+
|
|
48
|
+
v4 had one component with four slots. Each slot is a part now:
|
|
49
|
+
|
|
50
|
+
```tsx
|
|
51
|
+
// v4
|
|
52
|
+
<EmptyState icon={icon} title={title} description={description} actions={actions} />
|
|
53
|
+
|
|
54
|
+
// v5
|
|
55
|
+
<Empty>
|
|
56
|
+
<EmptyHeader>
|
|
57
|
+
<EmptyMedia>{icon}</EmptyMedia>
|
|
58
|
+
<EmptyTitle>{title}</EmptyTitle>
|
|
59
|
+
<EmptyDescription>{description}</EmptyDescription>
|
|
60
|
+
</EmptyHeader>
|
|
61
|
+
<EmptyContent>{actions}</EmptyContent>
|
|
62
|
+
</Empty>
|
|
25
63
|
```
|
|
64
|
+
|
|
65
|
+
A title that was `<Title type={TitleType.H2}>…</Title>` becomes the text alone:
|
|
66
|
+
`EmptyTitle` sets the size, and it follows the theme where the old `Title` does
|
|
67
|
+
not.
|
|
68
|
+
|
|
69
|
+
## Parts
|
|
70
|
+
|
|
71
|
+
| Part | What it does |
|
|
72
|
+
|--------------------|-------------------------------------------------------------------------------------|
|
|
73
|
+
| `Empty` | The block. Centred, `--space-24` between header and actions, `--space-24` padding (`--space-40` from 769px). `variant`: `plain`, `outline` (dashed `--color-rich`), `muted` (`--color-quiet-bg`) |
|
|
74
|
+
| `EmptyHeader` | Picture, title and description, `--space-8` apart, at most 384px wide |
|
|
75
|
+
| `EmptyMedia` | The picture. `default` shows it as given: an icon, an avatar. `variant="icon"` puts an icon on a 40px quiet square and sizes it to 24px. `variant="illustration"` is a 144px square an `<img>` or an `<svg>` fills, keeping its proportions |
|
|
76
|
+
| `EmptyTitle` | `--font-h3`. `render={<h2 />}` makes it a heading of the page |
|
|
77
|
+
| `EmptyDescription` | `--font-paragraph`, `--color-quiet-text`. A link inside is underlined and turns `--color-action` under the pointer |
|
|
78
|
+
| `EmptyContent` | The actions, stacked and centred, `--space-16` apart. Put a pair that belongs side by side in a row of its own |
|
|
79
|
+
|
|
80
|
+
Every part takes the props of its `<div>` — `className`, `id`, `data-*`. `emptyVariants` and
|
|
81
|
+
`emptyMediaVariants` return the class names for markup that is not the
|
|
82
|
+
component.
|
|
83
|
+
|
|
84
|
+
The readable width is an override point:
|
|
85
|
+
|
|
86
|
+
```css
|
|
87
|
+
.payouts .empty { --empty-max-width: 480px; }
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
So is the size of the illustration:
|
|
91
|
+
|
|
92
|
+
```css
|
|
93
|
+
.payouts .empty__media--illustration { --empty-illustration-size: 120px; }
|
|
94
|
+
```
|
|
95
|
+
|
|
96
|
+
## Screenshots
|
|
97
|
+
|
|
98
|
+
The Storybook story at 2×: the playground, then Default, Outline, Muted,
|
|
99
|
+
Avatar, Illustration and Heading.
|
|
100
|
+
|
|
101
|
+
| Light | Dark |
|
|
102
|
+
|---|---|
|
|
103
|
+
| <img src="screenshots/empty-state-light.png" width="420"> | <img src="screenshots/empty-state-dark.png" width="420"> |
|
package/dist/index.css
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.empty{--empty-max-width:384px;box-sizing:border-box;justify-content:center;align-items:center;gap:var(--space-24);min-width:0;padding:var(--space-24);border-radius:var(--radius-16);color:var(--color-dark-inversion);font:var(--font-text);font-family:var(--font-family);text-align:center;text-wrap:balance;flex-direction:column;flex:1;display:flex}@media (width>=769px){.empty{padding:var(--space-40)}}.empty--outline{border:var(--space-1) dashed var(--color-rich)}.empty--muted{background-color:var(--color-quiet-bg)}.empty__header{max-width:var(--empty-max-width);align-items:center;gap:var(--space-8);flex-direction:column;display:flex}.empty__media{flex:none;justify-content:center;align-items:center;margin-block-end:var(--space-8);display:flex}.empty__media svg{pointer-events:none;flex:none}.empty__media--icon{width:var(--space-40);height:var(--space-40);border-radius:var(--radius-8);background-color:var(--color-quiet-bg);color:var(--color-dark-inversion)}.empty__media--icon svg{width:var(--space-24);height:var(--space-24)}.empty--muted .empty__media--icon{background-color:var(--color-light-inversion)}.empty__media--illustration{--empty-illustration-size:144px;width:var(--empty-illustration-size);height:var(--empty-illustration-size)}.empty__media--illustration>*{object-fit:contain;width:100%;height:100%}.empty__title{margin:var(--space-0);font:var(--font-h3);font-family:var(--font-family)}.empty__description{margin:var(--space-0);color:var(--color-quiet-text);font:var(--font-paragraph);font-family:var(--font-family)}.empty__description a{color:inherit;text-underline-offset:var(--space-4);transition:color var(--duration-200) var(--ease-flat);text-decoration:underline}.empty__description a:hover{color:var(--color-action)}.empty__content{width:100%;min-width:0;max-width:var(--empty-max-width);align-items:center;gap:var(--space-16);flex-direction:column;display:flex}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,13 +1,66 @@
|
|
|
1
|
+
import * as react from 'react';
|
|
2
|
+
import { ComponentPropsWithRef } from 'react';
|
|
1
3
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
-
import {
|
|
4
|
+
import { useRender } from '@base-ui-components/react/use-render';
|
|
5
|
+
import * as class_variance_authority_types from 'class-variance-authority/types';
|
|
3
6
|
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
7
|
+
/** How the block is set off from the page. */
|
|
8
|
+
declare const EmptyVariant: {
|
|
9
|
+
/** Nothing around it: the block stands on whatever is behind it. */
|
|
10
|
+
readonly Plain: "plain";
|
|
11
|
+
/** A dashed contour: a place that is waiting to be filled — a list, a drop zone. */
|
|
12
|
+
readonly Outline: "outline";
|
|
13
|
+
/** A quiet pad: an empty panel inside a page that is otherwise full. */
|
|
14
|
+
readonly Muted: "muted";
|
|
9
15
|
};
|
|
16
|
+
type EmptyVariant = (typeof EmptyVariant)[keyof typeof EmptyVariant];
|
|
17
|
+
/** How the picture above the title is drawn. */
|
|
18
|
+
declare const EmptyMediaVariant: {
|
|
19
|
+
/** As given: an illustration, an avatar, an icon at its own size. */
|
|
20
|
+
readonly Default: "default";
|
|
21
|
+
/** An icon on a 40px quiet square, sized to 24px. */
|
|
22
|
+
readonly Icon: "icon";
|
|
23
|
+
/** A 144px picture — an image or an SVG — fitted to the square. */
|
|
24
|
+
readonly Illustration: "illustration";
|
|
25
|
+
};
|
|
26
|
+
type EmptyMediaVariant = (typeof EmptyMediaVariant)[keyof typeof EmptyMediaVariant];
|
|
27
|
+
type EmptyProps = ComponentPropsWithRef<'div'> & {
|
|
28
|
+
/** @default 'plain' */
|
|
29
|
+
variant?: EmptyVariant;
|
|
30
|
+
};
|
|
31
|
+
type EmptyHeaderProps = ComponentPropsWithRef<'div'>;
|
|
32
|
+
type EmptyMediaProps = ComponentPropsWithRef<'div'> & {
|
|
33
|
+
/** @default 'default' */
|
|
34
|
+
variant?: EmptyMediaVariant;
|
|
35
|
+
};
|
|
36
|
+
/** `render` swaps the element: `render={<h2 />}` makes the title a heading of the page. */
|
|
37
|
+
type EmptyTitleProps = useRender.ComponentProps<'div'>;
|
|
38
|
+
type EmptyDescriptionProps = ComponentPropsWithRef<'div'>;
|
|
39
|
+
type EmptyContentProps = ComponentPropsWithRef<'div'>;
|
|
40
|
+
|
|
41
|
+
/**
|
|
42
|
+
* The class names the stylesheet defines. Exported so that a page can give its
|
|
43
|
+
* own markup the look without rendering the component.
|
|
44
|
+
*/
|
|
45
|
+
declare const emptyVariants: (props?: ({
|
|
46
|
+
variant?: "plain" | "outline" | "muted" | null | undefined;
|
|
47
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
48
|
+
declare const emptyMediaVariants: (props?: ({
|
|
49
|
+
variant?: "default" | "icon" | "illustration" | null | undefined;
|
|
50
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
10
51
|
|
|
11
|
-
|
|
52
|
+
/** The block. Centres what is inside it. */
|
|
53
|
+
declare const Empty: ({ variant, className, ...props }: EmptyProps) => react_jsx_runtime.JSX.Element;
|
|
54
|
+
/** The picture, the title and the description, held together at a readable width. */
|
|
55
|
+
declare const EmptyHeader: ({ className, ...props }: EmptyHeaderProps) => react_jsx_runtime.JSX.Element;
|
|
56
|
+
/** The picture above the title. */
|
|
57
|
+
declare const EmptyMedia: ({ variant, className, ...props }: EmptyMediaProps) => react_jsx_runtime.JSX.Element;
|
|
58
|
+
/** The line that says what is missing. */
|
|
59
|
+
declare const EmptyTitle: ({ className, render, ref, ...props }: EmptyTitleProps) => react.ReactElement<unknown, string | react.JSXElementConstructor<any>>;
|
|
60
|
+
/** What happens next, in a sentence. A link inside it is underlined. */
|
|
61
|
+
declare const EmptyDescription: ({ className, ...props }: EmptyDescriptionProps) => react_jsx_runtime.JSX.Element;
|
|
62
|
+
/** What to do about it: a button, a pair of them, a field. */
|
|
63
|
+
declare const EmptyContent: ({ className, ...props }: EmptyContentProps) => react_jsx_runtime.JSX.Element;
|
|
12
64
|
|
|
13
|
-
export {
|
|
65
|
+
export { Empty, EmptyContent, EmptyDescription, EmptyHeader, EmptyMedia, EmptyMediaVariant, EmptyTitle, EmptyVariant, Empty as default, emptyMediaVariants, emptyVariants };
|
|
66
|
+
export type { EmptyContentProps, EmptyDescriptionProps, EmptyHeaderProps, EmptyMediaProps, EmptyProps, EmptyTitleProps };
|
package/dist/index.js
CHANGED
|
@@ -1,25 +1,58 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import t from "
|
|
3
|
-
import {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
1
|
+
import { mergeProps as e } from "@base-ui-components/react/merge-props";
|
|
2
|
+
import { useRender as t } from "@base-ui-components/react/use-render";
|
|
3
|
+
import { clsx as n } from "clsx";
|
|
4
|
+
import { cva as r } from "class-variance-authority";
|
|
5
|
+
import { jsx as i } from "react/jsx-runtime";
|
|
6
|
+
import './index.css';//#region src/cn.ts
|
|
7
|
+
var a = (...e) => n(e), o = {
|
|
8
|
+
Plain: "plain",
|
|
9
|
+
Outline: "outline",
|
|
10
|
+
Muted: "muted"
|
|
11
|
+
}, s = {
|
|
12
|
+
Default: "default",
|
|
13
|
+
Icon: "icon",
|
|
14
|
+
Illustration: "illustration"
|
|
15
|
+
}, c = r("empty", {
|
|
16
|
+
variants: { variant: {
|
|
17
|
+
plain: "",
|
|
18
|
+
outline: "empty--outline",
|
|
19
|
+
muted: "empty--muted"
|
|
20
|
+
} },
|
|
21
|
+
defaultVariants: { variant: "plain" }
|
|
22
|
+
}), l = r("empty__media", {
|
|
23
|
+
variants: { variant: {
|
|
24
|
+
default: "",
|
|
25
|
+
icon: "empty__media--icon",
|
|
26
|
+
illustration: "empty__media--illustration"
|
|
27
|
+
} },
|
|
28
|
+
defaultVariants: { variant: "default" }
|
|
29
|
+
}), u = ({ variant: e = o.Plain, className: t, ...n }) => /* @__PURE__ */ i("div", {
|
|
30
|
+
...n,
|
|
31
|
+
"data-variant": e,
|
|
32
|
+
className: a(c({ variant: e }), t)
|
|
33
|
+
}), d = ({ className: e, ...t }) => /* @__PURE__ */ i("div", {
|
|
34
|
+
...t,
|
|
35
|
+
className: a("empty__header", e)
|
|
36
|
+
}), f = ({ variant: e = s.Default, className: t, ...n }) => /* @__PURE__ */ i("div", {
|
|
37
|
+
...n,
|
|
38
|
+
"data-variant": e,
|
|
39
|
+
className: a(l({ variant: e }), t)
|
|
40
|
+
}), p = ({ className: n, render: r, ref: i, ...a }) => t({
|
|
41
|
+
defaultTagName: "div",
|
|
42
|
+
render: r,
|
|
43
|
+
ref: i,
|
|
44
|
+
props: e({ className: "empty__title" }, {
|
|
45
|
+
...a,
|
|
46
|
+
className: n
|
|
47
|
+
})
|
|
48
|
+
}), m = ({ className: e, ...t }) => /* @__PURE__ */ i("div", {
|
|
49
|
+
...t,
|
|
50
|
+
className: a("empty__description", e)
|
|
51
|
+
}), h = ({ className: e, ...t }) => /* @__PURE__ */ i("div", {
|
|
52
|
+
...t,
|
|
53
|
+
className: a("empty__content", e)
|
|
54
|
+
});
|
|
55
|
+
//#endregion
|
|
56
|
+
export { u as Empty, u as default, h as EmptyContent, m as EmptyDescription, d as EmptyHeader, f as EmptyMedia, s as EmptyMediaVariant, p as EmptyTitle, o as EmptyVariant, l as emptyMediaVariants, c as emptyVariants };
|
|
57
|
+
|
|
58
|
+
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../src/
|
|
1
|
+
{"version":3,"file":"index.js","names":[],"sources":["../src/cn.ts","../src/types.ts","../src/variants.ts","../src/index.tsx"],"sourcesContent":["import {type ClassValue, clsx} from 'clsx';\n\n/**\n * Joins class names. There is no tailwind-merge here on purpose: the empty state\n * ships its own stylesheet instead of utility classes, so there is nothing to\n * deduplicate.\n */\nconst cn = (...inputs: ClassValue[]): string => clsx(inputs);\n\nexport {cn};\n","import type {useRender} from '@base-ui-components/react/use-render';\nimport type {ComponentPropsWithRef} from 'react';\n\n/** How the block is set off from the page. */\nexport const EmptyVariant = {\n /** Nothing around it: the block stands on whatever is behind it. */\n Plain: 'plain',\n /** A dashed contour: a place that is waiting to be filled — a list, a drop zone. */\n Outline: 'outline',\n /** A quiet pad: an empty panel inside a page that is otherwise full. */\n Muted: 'muted',\n} as const;\nexport type EmptyVariant = (typeof EmptyVariant)[keyof typeof EmptyVariant];\n\n/** How the picture above the title is drawn. */\nexport const EmptyMediaVariant = {\n /** As given: an illustration, an avatar, an icon at its own size. */\n Default: 'default',\n /** An icon on a 40px quiet square, sized to 24px. */\n Icon: 'icon',\n /** A 144px picture — an image or an SVG — fitted to the square. */\n Illustration: 'illustration',\n} as const;\nexport type EmptyMediaVariant = (typeof EmptyMediaVariant)[keyof typeof EmptyMediaVariant];\n\nexport type EmptyProps = ComponentPropsWithRef<'div'> & {\n /** @default 'plain' */\n variant?: EmptyVariant;\n};\n\nexport type EmptyHeaderProps = ComponentPropsWithRef<'div'>;\n\nexport type EmptyMediaProps = ComponentPropsWithRef<'div'> & {\n /** @default 'default' */\n variant?: EmptyMediaVariant;\n};\n\n/** `render` swaps the element: `render={<h2 />}` makes the title a heading of the page. */\nexport type EmptyTitleProps = useRender.ComponentProps<'div'>;\n\nexport type EmptyDescriptionProps = ComponentPropsWithRef<'div'>;\n\nexport type EmptyContentProps = ComponentPropsWithRef<'div'>;\n","import {cva} from 'class-variance-authority';\n\n/**\n * The class names the stylesheet defines. Exported so that a page can give its\n * own markup the look without rendering the component.\n */\nconst emptyVariants = cva('empty', {\n variants: {\n variant: {\n plain: '',\n outline: 'empty--outline',\n muted: 'empty--muted',\n },\n },\n defaultVariants: {\n variant: 'plain',\n },\n});\n\nconst emptyMediaVariants = cva('empty__media', {\n variants: {\n variant: {\n default: '',\n icon: 'empty__media--icon',\n illustration: 'empty__media--illustration',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n});\n\nexport {emptyMediaVariants, emptyVariants};\n","import {mergeProps} from '@base-ui-components/react/merge-props';\nimport {useRender} from '@base-ui-components/react/use-render';\nimport './empty-state.css';\nimport {cn} from './cn';\nimport {\n type EmptyContentProps,\n type EmptyDescriptionProps,\n type EmptyHeaderProps,\n type EmptyMediaProps,\n EmptyMediaVariant,\n type EmptyProps,\n type EmptyTitleProps,\n EmptyVariant,\n} from './types';\nimport {emptyMediaVariants, emptyVariants} from './variants';\n\n/*\n * The parts follow shadcn's Empty: the block, the header holding the picture,\n * the title and the description, and the actions under it.\n */\n\n/** The block. Centres what is inside it. */\nconst Empty = ({variant = EmptyVariant.Plain, className, ...props}: EmptyProps) => (\n <div {...props} data-variant={variant} className={cn(emptyVariants({variant}), className)} />\n);\n\n/** The picture, the title and the description, held together at a readable width. */\nconst EmptyHeader = ({className, ...props}: EmptyHeaderProps) => (\n <div {...props} className={cn('empty__header', className)} />\n);\n\n/** The picture above the title. */\nconst EmptyMedia = ({variant = EmptyMediaVariant.Default, className, ...props}: EmptyMediaProps) => (\n <div {...props} data-variant={variant} className={cn(emptyMediaVariants({variant}), className)} />\n);\n\n/** The line that says what is missing. */\nconst EmptyTitle = ({className, render, ref, ...props}: EmptyTitleProps) =>\n useRender({\n defaultTagName: 'div',\n render,\n ref,\n props: mergeProps<'div'>({className: 'empty__title'}, {...props, className}),\n });\n\n/** What happens next, in a sentence. A link inside it is underlined. */\nconst EmptyDescription = ({className, ...props}: EmptyDescriptionProps) => (\n <div {...props} className={cn('empty__description', className)} />\n);\n\n/** What to do about it: a button, a pair of them, a field. */\nconst EmptyContent = ({className, ...props}: EmptyContentProps) => (\n <div {...props} className={cn('empty__content', className)} />\n);\n\nexport default Empty;\n\nexport type {EmptyContentProps, EmptyDescriptionProps, EmptyHeaderProps, EmptyMediaProps, EmptyProps, EmptyTitleProps};\nexport {\n Empty,\n EmptyContent,\n EmptyDescription,\n EmptyHeader,\n EmptyMedia,\n EmptyMediaVariant,\n EmptyTitle,\n EmptyVariant,\n emptyMediaVariants,\n emptyVariants,\n};\n"],"mappings":";;;;;;AAOA,IAAM,KAAM,GAAG,MAAiC,EAAK,EAAO,ECH/C,IAAe;CAE1B,OAAO;CAEP,SAAS;CAET,OAAO;CACR,EAIY,IAAoB;CAE/B,SAAS;CAET,MAAM;CAEN,cAAc;CACf,EChBK,IAAgB,EAAI,SAAS;CACjC,UAAU,EACR,SAAS;EACP,OAAO;EACP,SAAS;EACT,OAAO;EACR,EACF;CACD,iBAAiB,EACf,SAAS,SACV;CACF,CAAC,EAEI,IAAqB,EAAI,gBAAgB;CAC7C,UAAU,EACR,SAAS;EACP,SAAS;EACT,MAAM;EACN,cAAc;EACf,EACF;CACD,iBAAiB,EACf,SAAS,WACV;CACF,CAAC,ECRI,KAAS,EAAC,aAAU,EAAa,OAAO,cAAW,GAAG,QAC1D,kBAAC,OAAD;CAAK,GAAI;CAAO,gBAAc;CAAS,WAAW,EAAG,EAAc,EAAC,YAAQ,CAAC,EAAE,EAAU;CAAI,CAAA,EAIzF,KAAe,EAAC,cAAW,GAAG,QAClC,kBAAC,OAAD;CAAK,GAAI;CAAO,WAAW,EAAG,iBAAiB,EAAU;CAAI,CAAA,EAIzD,KAAc,EAAC,aAAU,EAAkB,SAAS,cAAW,GAAG,QACtE,kBAAC,OAAD;CAAK,GAAI;CAAO,gBAAc;CAAS,WAAW,EAAG,EAAmB,EAAC,YAAQ,CAAC,EAAE,EAAU;CAAI,CAAA,EAI9F,KAAc,EAAC,cAAW,WAAQ,QAAK,GAAG,QAC9C,EAAU;CACR,gBAAgB;CAChB;CACA;CACA,OAAO,EAAkB,EAAC,WAAW,gBAAe,EAAE;EAAC,GAAG;EAAO;EAAU,CAAC;CAC7E,CAAC,EAGE,KAAoB,EAAC,cAAW,GAAG,QACvC,kBAAC,OAAD;CAAK,GAAI;CAAO,WAAW,EAAG,sBAAsB,EAAU;CAAI,CAAA,EAI9D,KAAgB,EAAC,cAAW,GAAG,QACnC,kBAAC,OAAD;CAAK,GAAI;CAAO,WAAW,EAAG,kBAAkB,EAAU;CAAI,CAAA"}
|
package/package.json
CHANGED
|
@@ -1,14 +1,19 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@propellerads/empty-state",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "5.0.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"types": "dist/index.d.ts",
|
|
6
|
+
"style": "dist/index.css",
|
|
6
7
|
"exports": {
|
|
7
8
|
".": {
|
|
8
9
|
"types": "./dist/index.d.ts",
|
|
9
10
|
"import": "./dist/index.js"
|
|
10
|
-
}
|
|
11
|
+
},
|
|
12
|
+
"./index.css": "./dist/index.css"
|
|
11
13
|
},
|
|
14
|
+
"sideEffects": [
|
|
15
|
+
"**/*.css"
|
|
16
|
+
],
|
|
12
17
|
"files": [
|
|
13
18
|
"dist"
|
|
14
19
|
],
|
|
@@ -19,23 +24,33 @@
|
|
|
19
24
|
"url": "https://github.com/propellerads/ui-components/issues"
|
|
20
25
|
},
|
|
21
26
|
"scripts": {
|
|
22
|
-
"build": "tsc && vite build && rollup -c rollup.dts.config.mjs"
|
|
27
|
+
"build": "tsc && vite build && bunx rollup -c rollup.dts.config.mjs"
|
|
23
28
|
},
|
|
24
29
|
"homepage": "https://github.com/propellerads/ui-components#readme",
|
|
25
30
|
"private": false,
|
|
26
31
|
"dependencies": {
|
|
27
|
-
"@
|
|
32
|
+
"@base-ui-components/react": "1.0.0-rc.0",
|
|
33
|
+
"class-variance-authority": "^0.7.1",
|
|
34
|
+
"clsx": "^2.1.1"
|
|
28
35
|
},
|
|
29
36
|
"peerDependencies": {
|
|
37
|
+
"@propellerads/tokens": ">=0.2.0",
|
|
30
38
|
"react": "^18.0.0 || ^19.0.0",
|
|
31
|
-
"
|
|
39
|
+
"react-dom": "^18.0.0 || ^19.0.0"
|
|
40
|
+
},
|
|
41
|
+
"peerDependenciesMeta": {
|
|
42
|
+
"@propellerads/tokens": {
|
|
43
|
+
"optional": true
|
|
44
|
+
}
|
|
32
45
|
},
|
|
33
46
|
"devDependencies": {
|
|
47
|
+
"@propellerads/tokens": "workspace:^",
|
|
34
48
|
"@types/react": "^19.2.14",
|
|
35
|
-
"@vitejs/plugin-react": "^
|
|
36
|
-
"rollup": "^4.
|
|
37
|
-
"rollup-plugin-dts": "^6.
|
|
38
|
-
"typescript": "^
|
|
39
|
-
"vite": "^
|
|
49
|
+
"@vitejs/plugin-react": "^6.0.1",
|
|
50
|
+
"rollup": "^4.60.3",
|
|
51
|
+
"rollup-plugin-dts": "^6.4.1",
|
|
52
|
+
"typescript": "^6.0.3",
|
|
53
|
+
"vite": "^8.0.10",
|
|
54
|
+
"vite-plugin-lib-inject-css": "^2.2.2"
|
|
40
55
|
}
|
|
41
56
|
}
|