Skip to content

Commit 9ff711e

Browse files
authored
Merge pull request #280 from CivicDataLab/d4d
D4d
2 parents f33d3cd + a3d87bf commit 9ff711e

File tree

68 files changed

+621
-876
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

68 files changed

+621
-876
lines changed

packages/opub-ui/.storybook/main.ts

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,18 @@
1-
import { dirname, join } from "path";
2-
import { StorybookConfig } from '@storybook/react-vite';
1+
import { dirname, join } from 'path';
2+
33
const turbosnap = require('vite-plugin-turbosnap');
44
const { mergeConfig } = require('vite');
55

66
const config = {
7-
stories: ['../src'],
7+
stories: ['../src', '../docs'],
88
addons: [
9-
getAbsolutePath("@storybook/addon-links"),
10-
getAbsolutePath("@storybook/addon-essentials"),
11-
getAbsolutePath("@storybook/addon-interactions"),
9+
getAbsolutePath('@storybook/addon-links'),
10+
getAbsolutePath('@storybook/addon-essentials'),
11+
getAbsolutePath('@storybook/addon-interactions'),
12+
getAbsolutePath("@storybook/addon-mdx-gfm")
1213
],
1314
framework: {
14-
name: getAbsolutePath("@storybook/react-vite"),
15+
name: getAbsolutePath('@storybook/react-vite'),
1516
options: {},
1617
},
1718
docs: {
@@ -33,5 +34,5 @@ const config = {
3334
export default config;
3435

3536
function getAbsolutePath(value: string): any {
36-
return dirname(require.resolve(join(value, "package.json")));
37+
return dirname(require.resolve(join(value, 'package.json')));
3738
}

packages/opub-ui/.storybook/preview.tsx

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,19 @@ import { Tooltip } from '../src/components/Tooltip';
77
import React from 'react';
88

99
export const parameters = {
10-
parameters: {
11-
docs: {
12-
theme: themes.light,
10+
docs: {
11+
theme: themes.light,
12+
},
13+
options: {
14+
storySort: {
15+
order: [
16+
'Guides',
17+
['Introduction'],
18+
'Foundations',
19+
'Styles',
20+
'Patterns',
21+
'components',
22+
],
1323
},
1424
},
1525
};
Lines changed: 1 addition & 0 deletions
Lines changed: 1 addition & 0 deletions
Lines changed: 1 addition & 0 deletions
Lines changed: 1 addition & 0 deletions
Lines changed: 1 addition & 0 deletions
Lines changed: 3 additions & 0 deletions
Lines changed: 1 addition & 0 deletions
Lines changed: 1 addition & 0 deletions
Lines changed: 1 addition & 0 deletions
Lines changed: 1 addition & 0 deletions
Lines changed: 1 addition & 0 deletions
Lines changed: 1 addition & 0 deletions
Lines changed: 1 addition & 0 deletions
Lines changed: 1 addition & 0 deletions

packages/opub-ui/docs/Styles/Size.mdx

Lines changed: 1 addition & 0 deletions
Lines changed: 1 addition & 0 deletions

packages/opub-ui/package.json

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -89,16 +89,17 @@
8989
"@rollup/plugin-node-resolve": "^15.0.1",
9090
"@rollup/plugin-terser": "^0.4.1",
9191
"@rollup/plugin-typescript": "8.3.3",
92-
"@storybook/addon-actions": "^7.4.6",
92+
"@storybook/addon-actions": "^7.6.4",
9393
"@storybook/addon-console": "^2.0.0",
94-
"@storybook/addon-essentials": "7.4.6",
95-
"@storybook/addon-interactions": "7.4.6",
96-
"@storybook/addon-links": "7.4.6",
97-
"@storybook/addons": "7.4.6",
98-
"@storybook/react": "7.4.6",
99-
"@storybook/react-vite": "7.4.6",
94+
"@storybook/addon-essentials": "7.6.4",
95+
"@storybook/addon-interactions": "7.6.4",
96+
"@storybook/addon-links": "7.6.4",
97+
"@storybook/addon-mdx-gfm": "^7.6.4",
98+
"@storybook/addons": "7.6.4",
99+
"@storybook/react": "7.6.4",
100+
"@storybook/react-vite": "7.6.4",
100101
"@storybook/testing-library": "^0.2.2",
101-
"@storybook/theming": "^7.4.6",
102+
"@storybook/theming": "^7.6.4",
102103
"@svgr/rollup": "^7.0.0",
103104
"@testing-library/jest-dom": "^5.16.5",
104105
"@testing-library/react": "^13.4.0",
@@ -125,7 +126,7 @@
125126
"rollup-plugin-peer-deps-external": "^2.2.4",
126127
"rollup-plugin-postcss": "^4.0.2",
127128
"rollup-plugin-visualizer": "^5.9.0",
128-
"storybook": "7.4.6",
129+
"storybook": "7.6.4",
129130
"storybook-addon-pseudo-states": "^2.1.2",
130131
"tsconfig": "*",
131132
"typescript": "^5.0.4",

packages/opub-ui/src/components/ActionList/ActionList.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ import { IconCheck, IconFileExport, IconFileImport } from '@tabler/icons-react';
99
* Reference: https://polaris.shopify.com/components/lists/action-list
1010
*/
1111
const meta = {
12-
title: 'Verified/ActionList',
12+
title: 'Components/ActionList',
1313
component: ActionList,
1414
} satisfies Meta<typeof ActionList>;
1515

packages/opub-ui/src/components/AlertDialog/AlertDialog.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import { Meta, StoryObj } from '@storybook/react';
88
* Reference: https://www.radix-ui.com/docs/primitives/components/alert-dialog
99
*/
1010
const meta = {
11-
title: 'Verified/AlertDialog',
11+
title: 'Components/AlertDialog',
1212
component: AlertDialog.Content,
1313
} satisfies Meta<typeof AlertDialog.Content>;
1414

packages/opub-ui/src/components/Avatar/Avatar.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import { Meta, StoryObj } from '@storybook/react';
88
* Reference: https://polaris.shopify.com/components/images-and-icons/avatar
99
*/
1010
const meta = {
11-
title: 'Verified/Avatar',
11+
title: 'Components/Avatar',
1212
component: Avatar,
1313
} satisfies Meta<typeof Avatar>;
1414

packages/opub-ui/src/components/Badge/Badge.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import { Meta, StoryObj } from '@storybook/react';
88
*/
99

1010
const meta = {
11-
title: 'Verified/Badge',
11+
title: 'Components/Badge',
1212
component: Badge,
1313
} satisfies Meta<typeof Badge>;
1414

packages/opub-ui/src/components/Breadcrumbs/Breadcrumbs.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import { Meta, StoryObj } from '@storybook/react';
88
*/
99

1010
const meta = {
11-
title: 'Verified/Breadcrumbs',
11+
title: 'Components/Breadcrumbs',
1212
component: Breadcrumbs,
1313
} satisfies Meta<typeof Breadcrumbs>;
1414

packages/opub-ui/src/components/Button/Button.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import { IconSelector } from '@tabler/icons-react';
1010
* Reference: https://polaris.shopify.com/components/actions/button
1111
*/
1212
const meta = {
13-
title: 'Verified/Button',
13+
title: 'Components/Button',
1414
component: Button,
1515
} satisfies Meta<typeof Button>;
1616

packages/opub-ui/src/components/ButtonGroup/ButtonGroup.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import { Meta, StoryObj } from '@storybook/react';
88
* Reference: https://polaris.shopify.com/components/actions/button-group
99
*/
1010
const meta = {
11-
title: 'Verified/ButtonGroup',
11+
title: 'Components/ButtonGroup',
1212
component: ButtonGroup,
1313
} satisfies Meta<typeof ButtonGroup>;
1414

packages/opub-ui/src/components/Calendar/Calendar.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import { useLocale } from 'react-aria';
1010
* Reference: https://react-spectrum.adobe.com/react-aria/useCalendar.html
1111
*/
1212
const meta = {
13-
title: 'Verified/Calendar',
13+
title: 'Components/Calendar',
1414
component: Calendar,
1515
} satisfies Meta<typeof Calendar>;
1616

packages/opub-ui/src/components/Checkbox/Checkbox.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import { Meta, StoryObj } from '@storybook/react';
88
* Reference: https://www.radix-ui.com/docs/primitives/components/checkbox
99
*/
1010
const meta = {
11-
title: 'Verified/Checkbox',
11+
title: 'Components/Checkbox',
1212
component: Checkbox,
1313
} satisfies Meta<typeof Checkbox>;
1414

packages/opub-ui/src/components/CheckboxGroup/CheckboxGroup.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import { Meta, StoryObj } from '@storybook/react';
77
* A Checkbox Group lets you create a list of grouped checkboxes.
88
*/
99
const meta = {
10-
title: 'Verified/CheckboxGroup',
10+
title: 'Components/CheckboxGroup',
1111
component: CheckboxGroup,
1212
} satisfies Meta<typeof CheckboxGroup>;
1313

packages/opub-ui/src/components/Combobox/Combobox.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import { Meta, StoryObj } from '@storybook/react';
77
* Reference: https://ariakit.org/examples/combobox-multiple
88
*/
99
const meta = {
10-
title: 'Verified/Combobox',
10+
title: 'Components/Combobox',
1111
component: Combobox,
1212
} satisfies Meta<typeof Combobox>;
1313

packages/opub-ui/src/components/Command/Command.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ import React from 'react';
1717
* Reference: https://ui.shadcn.com/docs/components/command
1818
*/
1919
const meta = {
20-
title: 'Verified/Command',
20+
title: 'Components/Command',
2121
component: Command,
2222
} satisfies Meta<typeof Command>;
2323

packages/opub-ui/src/components/DataTable/DataTable.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import { IconCopy, IconPencil, IconTrash } from '@tabler/icons-react';
1010
* Reference: https://tanstack.com/table/v8/docs/guide/introduction
1111
*/
1212
const meta = {
13-
title: 'Verified/DataTable',
13+
title: 'Components/DataTable',
1414
component: DataTable,
1515
} satisfies Meta<typeof DataTable>;
1616

packages/opub-ui/src/components/DateField/DateField.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import { Meta, StoryObj } from '@storybook/react';
88
* Reference: https://react-spectrum.adobe.com/react-aria/useDateField.html
99
*/
1010
const meta = {
11-
title: 'Verified/DateField',
11+
title: 'Components/DateField',
1212
component: DateField,
1313
} satisfies Meta<typeof DateField>;
1414

packages/opub-ui/src/components/DatePicker/DatePicker.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ import { Meta, StoryObj } from '@storybook/react';
99
* Reference: https://react-spectrum.adobe.com/react-aria/useDatePicker.html
1010
*/
1111
const meta = {
12-
title: 'Verified/DatePicker',
12+
title: 'Components/DatePicker',
1313
component: DatePicker,
1414
} satisfies Meta<typeof DatePicker>;
1515

packages/opub-ui/src/components/Dialog/Dialog.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import { Meta, StoryObj } from '@storybook/react';
88
* Reference: https://www.radix-ui.com/docs/primitives/components/dialog
99
*/
1010
const meta = {
11-
title: 'Verified/Dialog',
11+
title: 'Components/Dialog',
1212
component: Dialog.Content,
1313
} satisfies Meta<typeof Dialog.Content>;
1414

packages/opub-ui/src/components/Divider/Divider.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import { Meta, StoryObj } from '@storybook/react';
55
* Use to separate or group content
66
*/
77
const meta = {
8-
title: 'Verified/Divider',
8+
title: 'Components/Divider',
99
component: Divider,
1010
} satisfies Meta<typeof Divider>;
1111

packages/opub-ui/src/components/DropZone/DropZone.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ import { useCallback, useState } from 'react';
1313
* Reference: https://polaris.shopify.com/components/selection-and-input/drop-zone
1414
*/
1515
const meta = {
16-
title: 'Verified/DropZone',
16+
title: 'Components/DropZone',
1717
component: DropZone,
1818
} satisfies Meta<typeof DropZone>;
1919

packages/opub-ui/src/components/FormLayout/FormLayout.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ import { Meta, StoryObj } from '@storybook/react';
99
* Reference: https://polaris.shopify.com/components/layout-and-structure/form-layout
1010
*/
1111
const meta = {
12-
title: 'Verified/FormLayout',
12+
title: 'Components/FormLayout',
1313
component: FormLayout,
1414
} satisfies Meta<typeof FormLayout>;
1515

packages/opub-ui/src/components/Icon/Icon.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ import {
1212
* Reference: https://polaris.shopify.com/components/images-and-icons/icon
1313
*/
1414
const meta = {
15-
title: 'Verified/Icon',
15+
title: 'Components/Icon',
1616
component: Icon,
1717
} satisfies Meta<typeof Icon>;
1818

packages/opub-ui/src/components/IconButton/IconButton.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import { IconMinus, IconPlus, IconSettings } from '@tabler/icons-react';
88
* Icon Button component
99
*/
1010
const meta = {
11-
title: 'Verified/IconButton',
11+
title: 'Components/IconButton',
1212
component: IconButton,
1313

1414
argTypes: {

packages/opub-ui/src/components/InlineMessage/InlineMessage.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import { Meta, StoryObj } from '@storybook/react';
66
* An inline message lets users know when important information is available
77
*/
88
const meta = {
9-
title: 'Verified/InlineMessage',
9+
title: 'Components/InlineMessage',
1010
component: InlineMessage,
1111
} satisfies Meta<typeof InlineMessage>;
1212

packages/opub-ui/src/components/Label/Label.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import { Meta } from '@storybook/react';
77
* Reference: https://www.radix-ui.com/docs/primitives/components/label
88
*/
99
export default {
10-
title: 'Verified/Label',
10+
title: 'Components/Label',
1111
component: Label,
1212

1313
argTypes: {

packages/opub-ui/src/components/Menu/Menu.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ import {
1313
* A wrapper around Popover and ActionList Components
1414
*/
1515
const meta = {
16-
title: 'Verified/Menu',
16+
title: 'Components/Menu',
1717
component: Menu,
1818
} satisfies Meta<typeof Menu>;
1919

packages/opub-ui/src/components/Pill/Pill.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import { Meta, StoryObj } from '@storybook/react';
66
* Pill is a component that displays a short string of text, which can removed.
77
*/
88
const meta = {
9-
title: 'Verified/Pill',
9+
title: 'Components/Pill',
1010
component: Pill,
1111
} satisfies Meta<typeof Pill>;
1212

packages/opub-ui/src/components/Popover/Popover.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ import { Meta, StoryObj } from '@storybook/react';
1111
* Reference: https://www.radix-ui.com/docs/primitives/components/popover
1212
*/
1313
const meta = {
14-
title: 'Verified/Popover',
14+
title: 'Components/Popover',
1515
component: Popover.Content,
1616
argTypes: {
1717
children: {

packages/opub-ui/src/components/ProgressBar/ProgressBar.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import { Meta, StoryObj } from '@storybook/react';
88
* Reference: https://www.radix-ui.com/docs/primitives/components/progress
99
*/
1010
const meta = {
11-
title: 'Verified/ProgressBar',
11+
title: 'Components/ProgressBar',
1212
component: ProgressBar,
1313
} satisfies Meta<typeof ProgressBar>;
1414

packages/opub-ui/src/components/RadioGroup/RadioGroup.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import { Meta } from '@storybook/react';
77
* Reference: https://www.radix-ui.com/docs/primitives/components/radio-group
88
*/
99
const meta = {
10-
title: 'Verified/RadioGroup',
10+
title: 'Components/RadioGroup',
1111
component: RadioGroup,
1212
} satisfies Meta<typeof RadioGroup>;
1313

packages/opub-ui/src/components/RangeSlider/RangeSlider.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import React from 'react';
88
* Reference: https://www.radix-ui.com/docs/primitives/components/slider
99
*/
1010
const meta = {
11-
title: 'Verified/RangeSlider',
11+
title: 'Components/RangeSlider',
1212
component: RangeSlider,
1313
} satisfies Meta<typeof RangeSlider>;
1414

packages/opub-ui/src/components/ScrollArea/ScrollArea.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ import { Meta, StoryObj } from '@storybook/react';
99
* Reference: https://www.radix-ui.com/docs/primitives/components/scroll-area
1010
*/
1111
const meta = {
12-
title: 'Verified/ScrollArea',
12+
title: 'Components/ScrollArea',
1313
component: ScrollArea,
1414
} satisfies Meta<typeof ScrollArea>;
1515

0 commit comments

Comments
 (0)