@openui-xio/stage-ui 0.0.2

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.
Files changed (41) hide show
  1. package/.storybook/main.ts +47 -0
  2. package/.storybook/preview.ts +15 -0
  3. package/CHANGELOG.md +13 -0
  4. package/LICENSE +661 -0
  5. package/README.md +13 -0
  6. package/package.json +57 -0
  7. package/postcss.config.cjs +5 -0
  8. package/postcss.config.js +5 -0
  9. package/src/components/accordion.tsx +56 -0
  10. package/src/components/button.tsx +41 -0
  11. package/src/components/checkbox.tsx +22 -0
  12. package/src/components/field.tsx +13 -0
  13. package/src/components/index.ts +21 -0
  14. package/src/components/menu.tsx +133 -0
  15. package/src/components/switch.tsx +17 -0
  16. package/src/lib/shared-styles.ts +5 -0
  17. package/src/lib/utils.ts +7 -0
  18. package/src/stories/Accordion.stories.tsx +39 -0
  19. package/src/stories/Button.stories.ts +39 -0
  20. package/src/stories/Checkbox.stories.ts +30 -0
  21. package/src/stories/Configure.mdx +364 -0
  22. package/src/stories/Switch.stories.ts +30 -0
  23. package/src/stories/assets/accessibility.png +0 -0
  24. package/src/stories/assets/accessibility.svg +1 -0
  25. package/src/stories/assets/addon-library.png +0 -0
  26. package/src/stories/assets/assets.png +0 -0
  27. package/src/stories/assets/avif-test-image.avif +0 -0
  28. package/src/stories/assets/context.png +0 -0
  29. package/src/stories/assets/discord.svg +1 -0
  30. package/src/stories/assets/docs.png +0 -0
  31. package/src/stories/assets/figma-plugin.png +0 -0
  32. package/src/stories/assets/github.svg +1 -0
  33. package/src/stories/assets/share.png +0 -0
  34. package/src/stories/assets/styling.png +0 -0
  35. package/src/stories/assets/testing.png +0 -0
  36. package/src/stories/assets/theming.png +0 -0
  37. package/src/stories/assets/tutorials.svg +1 -0
  38. package/src/stories/assets/youtube.svg +1 -0
  39. package/src/style.css +103 -0
  40. package/tailwind.config.ts +11 -0
  41. package/tsconfig.json +15 -0
@@ -0,0 +1,47 @@
1
+ import type { StorybookConfig } from '@storybook/react-vite';
2
+ import path, { join, dirname } from 'node:path';
3
+
4
+ /**
5
+ * This function is used to resolve the absolute path of a package.
6
+ * It is needed in projects that use Yarn PnP or are set up within a monorepo.
7
+ */
8
+ function getAbsolutePath(value: string): any {
9
+ return dirname(require.resolve(join(value, 'package.json')));
10
+ }
11
+ const config: StorybookConfig = {
12
+ stories: ['../src/**/*.mdx', '../src/**/*.stories.@(js|jsx|mjs|ts|tsx)'],
13
+ addons: [
14
+ getAbsolutePath('@storybook/addon-docs'),
15
+ getAbsolutePath('@storybook/addon-onboarding'),
16
+ ],
17
+ framework: {
18
+ name: getAbsolutePath('@storybook/react-vite'),
19
+ options: {},
20
+ },
21
+ async viteFinal(config) {
22
+ const { default: tailwindcss } = await import('@tailwindcss/vite');
23
+ const { mergeConfig } = await import('vite');
24
+ return mergeConfig(config, {
25
+ plugins: [tailwindcss()],
26
+ resolve: {
27
+ alias: {
28
+ '@': path.resolve(__dirname, '../src'),
29
+ },
30
+ },
31
+ });
32
+ },
33
+ previewHead: (head) => `
34
+ ${head}
35
+ <link rel="preconnect" href="https://fonts.googleapis.com">
36
+ <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
37
+ <link href="https://fonts.googleapis.com/css2?family=Geist:wght@100..900&display=swap" rel="stylesheet">
38
+ <style>
39
+ :root {
40
+ font-family: 'Geist', sans-serif;
41
+ font-optical-sizing: auto;
42
+ font-style: normal;
43
+ }
44
+ </style>
45
+ `,
46
+ };
47
+ export default config;
@@ -0,0 +1,15 @@
1
+ import type { Preview } from '@storybook/react-vite';
2
+ import '../src/style.css';
3
+
4
+ const preview: Preview = {
5
+ parameters: {
6
+ controls: {
7
+ matchers: {
8
+ color: /(background|color)$/i,
9
+ date: /Date$/i,
10
+ },
11
+ },
12
+ },
13
+ };
14
+
15
+ export default preview;
package/CHANGELOG.md ADDED
@@ -0,0 +1,13 @@
1
+ # @openui-xio/stage-ui
2
+
3
+ ## 0.0.2
4
+
5
+ ### Patch Changes
6
+
7
+ - 9494e75: chore: Update repository and prepare for release.
8
+
9
+ ## 0.0.1
10
+
11
+ ### Initial Release
12
+
13
+ Internal UI component library for the OpenUI toolbar, built with Tailwind CSS and Base UI.