@c-rex/components 0.0.8 → 0.0.9
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/autocomplete.cjs.js +215 -0
- package/dist/autocomplete.cjs.js.map +1 -0
- package/dist/autocomplete.d.cts +10 -0
- package/dist/autocomplete.d.ts +10 -0
- package/dist/autocomplete.esm.js +154 -0
- package/dist/autocomplete.esm.js.map +1 -0
- package/dist/blog-card.cjs.js +265 -0
- package/dist/blog-card.cjs.js.map +1 -0
- package/dist/blog-card.d.cts +19 -0
- package/dist/blog-card.d.ts +19 -0
- package/dist/blog-card.esm.js +192 -0
- package/dist/blog-card.esm.js.map +1 -0
- package/dist/blur-image.cjs.js +198 -0
- package/dist/blur-image.cjs.js.map +1 -0
- package/dist/blur-image.d.cts +7 -0
- package/dist/blur-image.d.ts +7 -0
- package/dist/blur-image.esm.js +125 -0
- package/dist/blur-image.esm.js.map +1 -0
- package/dist/breadcrumb.cjs.js +159 -0
- package/dist/breadcrumb.cjs.js.map +1 -0
- package/dist/breadcrumb.d.cts +10 -0
- package/dist/breadcrumb.d.ts +10 -0
- package/dist/breadcrumb.esm.js +98 -0
- package/dist/breadcrumb.esm.js.map +1 -0
- package/dist/empty.cjs.js +79 -0
- package/dist/empty.cjs.js.map +1 -0
- package/dist/empty.d.cts +5 -0
- package/dist/empty.d.ts +5 -0
- package/dist/empty.esm.js +18 -0
- package/dist/empty.esm.js.map +1 -0
- package/dist/navbar.cjs.js +134 -0
- package/dist/navbar.cjs.js.map +1 -0
- package/dist/navbar.d.cts +9 -0
- package/dist/navbar.d.ts +9 -0
- package/dist/navbar.esm.js +61 -0
- package/dist/navbar.esm.js.map +1 -0
- package/dist/providers/search-state-wrapper.cjs.js +113 -0
- package/dist/providers/search-state-wrapper.cjs.js.map +1 -0
- package/dist/providers/search-state-wrapper.d.cts +14 -0
- package/dist/providers/search-state-wrapper.d.ts +14 -0
- package/dist/providers/search-state-wrapper.esm.js +51 -0
- package/dist/providers/search-state-wrapper.esm.js.map +1 -0
- package/dist/result-list.cjs.js +321 -0
- package/dist/result-list.cjs.js.map +1 -0
- package/dist/result-list.d.cts +9 -0
- package/dist/result-list.d.ts +9 -0
- package/dist/result-list.esm.js +247 -0
- package/dist/result-list.esm.js.map +1 -0
- package/dist/result-view/blog-view.stories.cjs.js +372 -0
- package/dist/result-view/blog-view.stories.cjs.js.map +1 -0
- package/dist/result-view/blog-view.stories.d.cts +11 -0
- package/dist/result-view/blog-view.stories.d.ts +11 -0
- package/dist/result-view/blog-view.stories.esm.js +295 -0
- package/dist/result-view/blog-view.stories.esm.js.map +1 -0
- package/dist/result-view/blog.cjs.js +290 -0
- package/dist/result-view/blog.cjs.js.map +1 -0
- package/dist/result-view/blog.d.cts +9 -0
- package/dist/result-view/blog.d.ts +9 -0
- package/dist/result-view/blog.esm.js +220 -0
- package/dist/result-view/blog.esm.js.map +1 -0
- package/dist/result-view/table-view.stories.cjs.js +196 -0
- package/dist/result-view/table-view.stories.cjs.js.map +1 -0
- package/dist/result-view/table-view.stories.d.cts +11 -0
- package/dist/result-view/table-view.stories.d.ts +11 -0
- package/dist/result-view/table-view.stories.esm.js +131 -0
- package/dist/result-view/table-view.stories.esm.js.map +1 -0
- package/dist/result-view/table.cjs.js +116 -0
- package/dist/result-view/table.cjs.js.map +1 -0
- package/dist/result-view/table.d.cts +9 -0
- package/dist/result-view/table.d.ts +9 -0
- package/dist/result-view/table.esm.js +59 -0
- package/dist/result-view/table.esm.js.map +1 -0
- package/dist/sidebar.cjs.js +225 -0
- package/dist/sidebar.cjs.js.map +1 -0
- package/dist/sidebar.d.cts +12 -0
- package/dist/sidebar.d.ts +12 -0
- package/dist/sidebar.esm.js +164 -0
- package/dist/sidebar.esm.js.map +1 -0
- package/dist/stories/blog-card.stories.cjs.js +323 -0
- package/dist/stories/blog-card.stories.cjs.js.map +1 -0
- package/dist/stories/blog-card.stories.d.cts +9 -0
- package/dist/stories/blog-card.stories.d.ts +9 -0
- package/dist/stories/blog-card.stories.esm.js +242 -0
- package/dist/stories/blog-card.stories.esm.js.map +1 -0
- package/dist/stories/blur-image.stories.cjs.js +265 -0
- package/dist/stories/blur-image.stories.cjs.js.map +1 -0
- package/dist/stories/blur-image.stories.d.cts +37 -0
- package/dist/stories/blur-image.stories.d.ts +37 -0
- package/dist/stories/blur-image.stories.esm.js +180 -0
- package/dist/stories/blur-image.stories.esm.js.map +1 -0
- package/dist/stories/breadcrumb.stories.cjs.js +214 -0
- package/dist/stories/breadcrumb.stories.cjs.js.map +1 -0
- package/dist/stories/breadcrumb.stories.d.cts +9 -0
- package/dist/stories/breadcrumb.stories.d.ts +9 -0
- package/dist/stories/breadcrumb.stories.esm.js +145 -0
- package/dist/stories/breadcrumb.stories.esm.js.map +1 -0
- package/dist/stories/empty.stories.cjs.js +93 -0
- package/dist/stories/empty.stories.cjs.js.map +1 -0
- package/dist/stories/empty.stories.d.cts +13 -0
- package/dist/stories/empty.stories.d.ts +13 -0
- package/dist/stories/empty.stories.esm.js +28 -0
- package/dist/stories/empty.stories.esm.js.map +1 -0
- package/dist/stories/navbar.stories.cjs.js +151 -0
- package/dist/stories/navbar.stories.cjs.js.map +1 -0
- package/dist/stories/navbar.stories.d.cts +8 -0
- package/dist/stories/navbar.stories.d.ts +8 -0
- package/dist/stories/navbar.stories.esm.js +74 -0
- package/dist/stories/navbar.stories.esm.js.map +1 -0
- package/dist/stories/sidebar.stories.cjs.js +327 -0
- package/dist/stories/sidebar.stories.cjs.js.map +1 -0
- package/dist/stories/sidebar.stories.d.cts +30 -0
- package/dist/stories/sidebar.stories.d.ts +30 -0
- package/dist/stories/sidebar.stories.esm.js +258 -0
- package/dist/stories/sidebar.stories.esm.js.map +1 -0
- package/package.json +40 -27
- package/src/autocomplete.tsx +0 -113
- package/src/blog-card.tsx +0 -87
- package/src/blur-image.tsx +0 -23
- package/src/breadcrumb.tsx +0 -81
- package/src/empty.tsx +0 -13
- package/src/navbar.tsx +0 -66
- package/src/providers/search-state-wrapper.tsx +0 -21
- package/src/result-list.tsx +0 -16
- package/src/result-view/blog-view.stories.tsx +0 -58
- package/src/result-view/blog.tsx +0 -38
- package/src/result-view/table-view.stories.tsx +0 -55
- package/src/result-view/table.tsx +0 -65
- package/src/sidebar.tsx +0 -76
- package/src/stories/blog-card.stories.tsx +0 -46
- package/src/stories/blur-image.stories.tsx +0 -51
- package/src/stories/breadcrumb.stories.tsx +0 -52
- package/src/stories/empty.stories.tsx +0 -14
- package/src/stories/navbar.stories.tsx +0 -16
- package/src/stories/sidebar.stories.tsx +0 -94
|
@@ -1,51 +0,0 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from '@storybook/react';
|
|
2
|
-
import { BlurImage } from '../blur-image';
|
|
3
|
-
|
|
4
|
-
const meta = {
|
|
5
|
-
title: 'Components/BlurImage',
|
|
6
|
-
component: BlurImage,
|
|
7
|
-
tags: ['autodocs'],
|
|
8
|
-
parameters: {
|
|
9
|
-
layout: 'centered',
|
|
10
|
-
},
|
|
11
|
-
argTypes: {
|
|
12
|
-
src: { control: 'text' },
|
|
13
|
-
alt: { control: 'text' },
|
|
14
|
-
width: { control: 'number' },
|
|
15
|
-
height: { control: 'number' },
|
|
16
|
-
className: { control: 'text' },
|
|
17
|
-
},
|
|
18
|
-
} satisfies Meta<typeof BlurImage>;
|
|
19
|
-
|
|
20
|
-
export default meta;
|
|
21
|
-
type Story = StoryObj<typeof meta>;
|
|
22
|
-
|
|
23
|
-
export const Default: Story = {
|
|
24
|
-
args: {
|
|
25
|
-
src: 'https://images.pexels.com/photos/31712301/pexels-photo-31712301/free-photo-of-scenic-cycling-tour-in-andernach-fields.jpeg?auto=compress&cs=tinysrgb&w=1260&h=750&dpr=1',
|
|
26
|
-
alt: 'Sample image with blur effect',
|
|
27
|
-
width: 400,
|
|
28
|
-
height: 300,
|
|
29
|
-
className: 'rounded-lg',
|
|
30
|
-
},
|
|
31
|
-
};
|
|
32
|
-
|
|
33
|
-
export const SmallImage: Story = {
|
|
34
|
-
args: {
|
|
35
|
-
src: 'https://images.pexels.com/photos/31712301/pexels-photo-31712301/free-photo-of-scenic-cycling-tour-in-andernach-fields.jpeg?auto=compress&cs=tinysrgb&w=1260&h=750&dpr=1',
|
|
36
|
-
alt: 'Small sample image with blur effect',
|
|
37
|
-
width: 200,
|
|
38
|
-
height: 150,
|
|
39
|
-
className: 'rounded-lg',
|
|
40
|
-
},
|
|
41
|
-
};
|
|
42
|
-
|
|
43
|
-
export const RoundedImage: Story = {
|
|
44
|
-
args: {
|
|
45
|
-
src: 'https://images.pexels.com/photos/31712301/pexels-photo-31712301/free-photo-of-scenic-cycling-tour-in-andernach-fields.jpeg?auto=compress&cs=tinysrgb&w=1260&h=750&dpr=1',
|
|
46
|
-
alt: 'Rounded sample image with blur effect',
|
|
47
|
-
width: 300,
|
|
48
|
-
height: 300,
|
|
49
|
-
className: 'rounded-full',
|
|
50
|
-
},
|
|
51
|
-
};
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from '@storybook/react';
|
|
2
|
-
import { Breadcrumb } from '../breadcrumb';
|
|
3
|
-
|
|
4
|
-
const meta: Meta = {
|
|
5
|
-
title: 'Components/Breadcrumb',
|
|
6
|
-
component: Breadcrumb,
|
|
7
|
-
tags: ['autodocs'],
|
|
8
|
-
parameters: {
|
|
9
|
-
layout: 'centered',
|
|
10
|
-
}
|
|
11
|
-
} satisfies Meta;
|
|
12
|
-
|
|
13
|
-
export default meta;
|
|
14
|
-
type Story = StoryObj<typeof meta>;
|
|
15
|
-
|
|
16
|
-
const mockItems = [
|
|
17
|
-
{
|
|
18
|
-
id: 'docs',
|
|
19
|
-
label: 'Documentation',
|
|
20
|
-
link: '/docs',
|
|
21
|
-
active: false,
|
|
22
|
-
children: [],
|
|
23
|
-
},
|
|
24
|
-
{
|
|
25
|
-
id: 'components',
|
|
26
|
-
label: 'Components',
|
|
27
|
-
link: '/docs/components',
|
|
28
|
-
active: false,
|
|
29
|
-
children: [],
|
|
30
|
-
},
|
|
31
|
-
{
|
|
32
|
-
id: 'breadcrumb',
|
|
33
|
-
label: 'Breadcrumb',
|
|
34
|
-
link: '/docs/components/breadcrumb',
|
|
35
|
-
active: true,
|
|
36
|
-
children: [],
|
|
37
|
-
},
|
|
38
|
-
];
|
|
39
|
-
|
|
40
|
-
export const Default: Story = {
|
|
41
|
-
args: {
|
|
42
|
-
items: mockItems,
|
|
43
|
-
loading: false,
|
|
44
|
-
},
|
|
45
|
-
};
|
|
46
|
-
|
|
47
|
-
export const Loading: Story = {
|
|
48
|
-
args: {
|
|
49
|
-
items: [],
|
|
50
|
-
loading: true,
|
|
51
|
-
},
|
|
52
|
-
};
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from '@storybook/react';
|
|
2
|
-
import { Empty } from '../empty';
|
|
3
|
-
|
|
4
|
-
const meta = {
|
|
5
|
-
title: 'Components/Empty',
|
|
6
|
-
component: Empty,
|
|
7
|
-
tags: ['autodocs'],
|
|
8
|
-
} satisfies Meta<typeof Empty>;
|
|
9
|
-
|
|
10
|
-
export default meta;
|
|
11
|
-
type Story = StoryObj<typeof meta>;
|
|
12
|
-
|
|
13
|
-
export const Default: Story = {
|
|
14
|
-
};
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from '@storybook/react';
|
|
2
|
-
import { NavBar } from '../navbar';
|
|
3
|
-
|
|
4
|
-
const meta: Meta = {
|
|
5
|
-
title: 'Components/NavBar',
|
|
6
|
-
component: NavBar,
|
|
7
|
-
tags: ['autodocs'],
|
|
8
|
-
parameters: {
|
|
9
|
-
layout: 'padded',
|
|
10
|
-
},
|
|
11
|
-
} satisfies Meta<typeof NavBar>;
|
|
12
|
-
|
|
13
|
-
export default meta;
|
|
14
|
-
type Story = StoryObj<typeof meta>;
|
|
15
|
-
|
|
16
|
-
export const Default: Story = {}
|
|
@@ -1,94 +0,0 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from '@storybook/react';
|
|
2
|
-
import { AppSidebar } from '../sidebar';
|
|
3
|
-
import { SidebarInset, SidebarProvider, SidebarTrigger } from "@c-rex/ui/sidebar";
|
|
4
|
-
|
|
5
|
-
const meta = {
|
|
6
|
-
title: 'Components/Sidebar',
|
|
7
|
-
component: AppSidebar,
|
|
8
|
-
tags: ['autodocs'],
|
|
9
|
-
parameters: {
|
|
10
|
-
layout: 'centered',
|
|
11
|
-
},
|
|
12
|
-
argTypes: {
|
|
13
|
-
data: { control: 'object' },
|
|
14
|
-
loading: { control: 'boolean' },
|
|
15
|
-
},
|
|
16
|
-
decorators: [
|
|
17
|
-
(Story: any) => (
|
|
18
|
-
<SidebarProvider>
|
|
19
|
-
<SidebarTrigger />
|
|
20
|
-
|
|
21
|
-
<div className="flex">
|
|
22
|
-
<SidebarInset>
|
|
23
|
-
<Story />
|
|
24
|
-
</SidebarInset>
|
|
25
|
-
</div>
|
|
26
|
-
</SidebarProvider>
|
|
27
|
-
|
|
28
|
-
),
|
|
29
|
-
]
|
|
30
|
-
} satisfies Meta<typeof AppSidebar>;
|
|
31
|
-
|
|
32
|
-
export default meta;
|
|
33
|
-
type Story = StoryObj<typeof meta>;
|
|
34
|
-
|
|
35
|
-
const mockData = [
|
|
36
|
-
{
|
|
37
|
-
id: '1',
|
|
38
|
-
label: 'Getting Started',
|
|
39
|
-
link: '/docs/getting-started',
|
|
40
|
-
active: true,
|
|
41
|
-
children: [
|
|
42
|
-
{
|
|
43
|
-
id: '1-1',
|
|
44
|
-
label: 'Installation',
|
|
45
|
-
link: '/docs/getting-started/installation',
|
|
46
|
-
active: false,
|
|
47
|
-
children: [],
|
|
48
|
-
},
|
|
49
|
-
{
|
|
50
|
-
id: '1-2',
|
|
51
|
-
label: 'Configuration',
|
|
52
|
-
link: '/docs/getting-started/configuration',
|
|
53
|
-
active: false,
|
|
54
|
-
children: [],
|
|
55
|
-
},
|
|
56
|
-
],
|
|
57
|
-
},
|
|
58
|
-
{
|
|
59
|
-
id: '2',
|
|
60
|
-
label: 'Components',
|
|
61
|
-
link: '/docs/components',
|
|
62
|
-
active: false,
|
|
63
|
-
children: [
|
|
64
|
-
{
|
|
65
|
-
id: '2-1',
|
|
66
|
-
label: 'Sidebar',
|
|
67
|
-
link: '/docs/components/sidebar',
|
|
68
|
-
active: false,
|
|
69
|
-
children: [],
|
|
70
|
-
},
|
|
71
|
-
{
|
|
72
|
-
id: '2-2',
|
|
73
|
-
label: 'Navbar',
|
|
74
|
-
link: '/docs/components/navbar',
|
|
75
|
-
active: false,
|
|
76
|
-
children: [],
|
|
77
|
-
},
|
|
78
|
-
],
|
|
79
|
-
},
|
|
80
|
-
];
|
|
81
|
-
|
|
82
|
-
export const Default: Story = {
|
|
83
|
-
args: {
|
|
84
|
-
data: mockData,
|
|
85
|
-
loading: false,
|
|
86
|
-
},
|
|
87
|
-
};
|
|
88
|
-
|
|
89
|
-
export const Loading: Story = {
|
|
90
|
-
args: {
|
|
91
|
-
data: [],
|
|
92
|
-
loading: true,
|
|
93
|
-
},
|
|
94
|
-
};
|