@ubie/vitals-ui-consumer 0.0.1
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/.storybook/main.ts +14 -0
- package/.storybook/preview.tsx +25 -0
- package/.storybook/vitest.setup.ts +7 -0
- package/dist/chunk-DKo7XVKm.mjs +33 -0
- package/dist/index.d.mts +1720 -0
- package/dist/index.d.mts.map +1 -0
- package/dist/index.mjs +10594 -0
- package/dist/index.mjs.map +1 -0
- package/dist/style.css +2299 -0
- package/package.json +47 -0
- package/src/components/Accordion/Accordion.module.css +75 -0
- package/src/components/Accordion/Accordion.spec.tsx +18 -0
- package/src/components/Accordion/Accordion.stories.tsx +61 -0
- package/src/components/Accordion/Accordion.tsx +89 -0
- package/src/components/ActionHalfModal/ActionHalfModal.module.css +180 -0
- package/src/components/ActionHalfModal/ActionHalfModal.spec.tsx +57 -0
- package/src/components/ActionHalfModal/ActionHalfModal.stories.tsx +469 -0
- package/src/components/ActionHalfModal/ActionHalfModal.tsx +269 -0
- package/src/components/ActionModal/ActionModal.module.css +145 -0
- package/src/components/ActionModal/ActionModal.spec.tsx +57 -0
- package/src/components/ActionModal/ActionModal.stories.tsx +302 -0
- package/src/components/ActionModal/ActionModal.tsx +232 -0
- package/src/components/Bold/Bold.module.css +4 -0
- package/src/components/Bold/Bold.spec.tsx +24 -0
- package/src/components/Bold/Bold.stories.tsx +54 -0
- package/src/components/Bold/Bold.tsx +31 -0
- package/src/components/Box/Box.module.css +46 -0
- package/src/components/Box/Box.spec.tsx +188 -0
- package/src/components/Box/Box.tsx +242 -0
- package/src/components/Button/Button.module.css +261 -0
- package/src/components/Button/Button.spec.tsx +82 -0
- package/src/components/Button/Button.tsx +99 -0
- package/src/components/Button/ButtonTypes.ts +107 -0
- package/src/components/Button/LinkButton.spec.tsx +86 -0
- package/src/components/Button/LinkButton.tsx +80 -0
- package/src/components/Button/VariantIcon.tsx +20 -0
- package/src/components/Button/useIcon.tsx +16 -0
- package/src/components/ButtonCard/ButtonCard.module.css +35 -0
- package/src/components/ButtonCard/ButtonCard.spec.tsx +18 -0
- package/src/components/ButtonCard/ButtonCard.stories.tsx +54 -0
- package/src/components/ButtonCard/ButtonCard.tsx +18 -0
- package/src/components/Center/Center.module.css +19 -0
- package/src/components/Center/Center.spec.tsx +143 -0
- package/src/components/Center/Center.tsx +108 -0
- package/src/components/Checkbox/Checkbox.module.css +124 -0
- package/src/components/Checkbox/Checkbox.spec.tsx +17 -0
- package/src/components/Checkbox/Checkbox.stories.tsx +213 -0
- package/src/components/Checkbox/Checkbox.tsx +50 -0
- package/src/components/CheckboxCard/CheckboxCard.module.css +102 -0
- package/src/components/CheckboxCard/CheckboxCard.spec.tsx +16 -0
- package/src/components/CheckboxCard/CheckboxCard.stories.tsx +205 -0
- package/src/components/CheckboxCard/CheckboxCard.tsx +53 -0
- package/src/components/CheckboxGroup/CheckboxGroup.module.css +16 -0
- package/src/components/CheckboxGroup/CheckboxGroup.spec.tsx +17 -0
- package/src/components/CheckboxGroup/CheckboxGroup.tsx +64 -0
- package/src/components/Color/Color.module.css +3 -0
- package/src/components/Color/Color.spec.tsx +24 -0
- package/src/components/Color/Color.stories.tsx +71 -0
- package/src/components/Color/Color.tsx +28 -0
- package/src/components/Divider/Divider.module.css +9 -0
- package/src/components/Divider/Divider.spec.tsx +42 -0
- package/src/components/Divider/Divider.stories.tsx +77 -0
- package/src/components/Divider/Divider.tsx +49 -0
- package/src/components/ErrorMessage/ErrorMessage.module.css +8 -0
- package/src/components/ErrorMessage/ErrorMessage.spec.tsx +12 -0
- package/src/components/ErrorMessage/ErrorMessage.tsx +20 -0
- package/src/components/Flex/Flex.module.css +24 -0
- package/src/components/Flex/Flex.spec.tsx +188 -0
- package/src/components/Flex/Flex.tsx +173 -0
- package/src/components/FlexItem/FlexItem.module.css +14 -0
- package/src/components/FlexItem/FlexItem.spec.tsx +84 -0
- package/src/components/FlexItem/FlexItem.tsx +106 -0
- package/src/components/Heading/Heading.module.css +131 -0
- package/src/components/Heading/Heading.tsx +86 -0
- package/src/components/HelperMessage/HelperMessage.module.css +8 -0
- package/src/components/HelperMessage/HelperMessage.tsx +15 -0
- package/src/components/Icon/Icon.module.css +6 -0
- package/src/components/Icon/Icon.spec.tsx +24 -0
- package/src/components/Icon/Icon.stories.tsx +100 -0
- package/src/components/Icon/Icon.tsx +101 -0
- package/src/components/Input/Input.module.css +51 -0
- package/src/components/Input/Input.spec.tsx +14 -0
- package/src/components/Input/Input.tsx +27 -0
- package/src/components/Label/Label.module.css +14 -0
- package/src/components/Label/Label.tsx +39 -0
- package/src/components/LinkCard/LinkCard.module.css +72 -0
- package/src/components/LinkCard/LinkCard.tsx +96 -0
- package/src/components/MessageHalfModal/MessageHalfModal.module.css +181 -0
- package/src/components/MessageHalfModal/MessageHalfModal.spec.tsx +73 -0
- package/src/components/MessageHalfModal/MessageHalfModal.stories.tsx +242 -0
- package/src/components/MessageHalfModal/MessageHalfModal.tsx +194 -0
- package/src/components/MessageModal/MessageModal.module.css +149 -0
- package/src/components/MessageModal/MessageModal.spec.tsx +57 -0
- package/src/components/MessageModal/MessageModal.stories.tsx +223 -0
- package/src/components/MessageModal/MessageModal.tsx +178 -0
- package/src/components/Pre/Pre.module.css +8 -0
- package/src/components/Pre/Pre.spec.tsx +11 -0
- package/src/components/Pre/Pre.stories.tsx +76 -0
- package/src/components/Pre/Pre.tsx +40 -0
- package/src/components/RadioButton/RadioButton.module.css +92 -0
- package/src/components/RadioButton/RadioButton.spec.tsx +25 -0
- package/src/components/RadioButton/RadioButton.tsx +55 -0
- package/src/components/RadioCard/RadioCard.module.css +109 -0
- package/src/components/RadioCard/RadioCard.tsx +61 -0
- package/src/components/RadioGroup/RadioGroup.module.css +16 -0
- package/src/components/RadioGroup/RadioGroup.spec.tsx +17 -0
- package/src/components/RadioGroup/RadioGroup.tsx +60 -0
- package/src/components/Select/Select.module.css +70 -0
- package/src/components/Select/Select.spec.tsx +12 -0
- package/src/components/Select/Select.tsx +56 -0
- package/src/components/Stack/Stack.module.css +10 -0
- package/src/components/Stack/Stack.spec.tsx +177 -0
- package/src/components/Stack/Stack.tsx +151 -0
- package/src/components/Stepper/Stepper.module.css +137 -0
- package/src/components/Stepper/Stepper.spec.tsx +198 -0
- package/src/components/Stepper/Stepper.stories.tsx +192 -0
- package/src/components/Stepper/Stepper.tsx +70 -0
- package/src/components/Stepper/StepperItem.tsx +113 -0
- package/src/components/Text/Text.module.css +168 -0
- package/src/components/Text/Text.tsx +192 -0
- package/src/components/TextArea/TextArea.module.css +46 -0
- package/src/components/TextArea/TextArea.spec.tsx +13 -0
- package/src/components/TextArea/TextArea.tsx +29 -0
- package/src/components/Toggle/Toggle.module.css +71 -0
- package/src/components/Toggle/Toggle.spec.tsx +21 -0
- package/src/components/Toggle/Toggle.tsx +56 -0
- package/src/font.ts +2 -0
- package/src/hooks/useScrollable.ts +58 -0
- package/src/icons/AppleIcon.tsx +14 -0
- package/src/icons/GoogleIcon.tsx +27 -0
- package/src/icons/LINEIcon.tsx +16 -0
- package/src/index.ts +35 -0
- package/src/sharedComponents/RequiredLabel/RequiredLabel.module.css +10 -0
- package/src/sharedComponents/RequiredLabel/RequiredLabel.tsx +8 -0
- package/src/sharedComponents/VisuallyHidden/VisuallyHidden.module.css +15 -0
- package/src/sharedComponents/VisuallyHidden/VisuallyHidden.tsx +22 -0
- package/src/stories/Accordion.stories.portable.ts +4 -0
- package/src/stories/Box.stories.tsx +474 -0
- package/src/stories/Button.stories.tsx +262 -0
- package/src/stories/Center.stories.tsx +126 -0
- package/src/stories/ErrorMessage.stories.tsx +19 -0
- package/src/stories/Flex.stories.tsx +345 -0
- package/src/stories/Form.stories.tsx +83 -0
- package/src/stories/Heading.stories.tsx +263 -0
- package/src/stories/HelperMessage.stories.tsx +22 -0
- package/src/stories/Input.stories.tsx +145 -0
- package/src/stories/Label.stories.tsx +32 -0
- package/src/stories/LinkButton.stories.tsx +207 -0
- package/src/stories/LinkCard.stories.tsx +90 -0
- package/src/stories/RadioButton.stories.tsx +168 -0
- package/src/stories/RadioCard.stories.tsx +236 -0
- package/src/stories/Select.stories.tsx +97 -0
- package/src/stories/Stack.stories.tsx +167 -0
- package/src/stories/Text.stories.tsx +396 -0
- package/src/stories/TextArea.stories.tsx +49 -0
- package/src/stories/Toggle.stories.tsx +30 -0
- package/src/test/vitest-jest-dom.d.ts +12 -0
- package/src/types/attributes.ts +6 -0
- package/src/types/global.d.ts +11 -0
- package/src/types/icon.ts +3 -0
- package/src/types/style.ts +254 -0
- package/src/utils/component.ts +8 -0
- package/src/utils/style.spec.ts +57 -0
- package/src/utils/style.ts +387 -0
- package/src/utils/types.ts +8 -0
- package/tsconfig.json +18 -0
- package/tsconfig.spec-lint.tsbuildinfo +1 -0
- package/tsconfig.tsbuildinfo +1 -0
- package/vite.config.ts +50 -0
- package/vitest.shims.d.ts +1 -0
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { StorybookConfig } from "@storybook/react-vite";
|
|
2
|
+
|
|
3
|
+
const config: StorybookConfig = {
|
|
4
|
+
stories: ["../src/**/*.mdx", "../src/**/*.stories.@(js|jsx|mjs|ts|tsx)"],
|
|
5
|
+
addons: [
|
|
6
|
+
"@chromatic-com/storybook",
|
|
7
|
+
"@storybook/addon-vitest",
|
|
8
|
+
"@storybook/addon-a11y",
|
|
9
|
+
"@storybook/addon-docs",
|
|
10
|
+
"@storybook/addon-onboarding",
|
|
11
|
+
],
|
|
12
|
+
framework: "@storybook/react-vite",
|
|
13
|
+
};
|
|
14
|
+
export default config;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import type { Preview } from "@storybook/react-vite";
|
|
3
|
+
import "@ubie/vitals-token-consumer/css";
|
|
4
|
+
|
|
5
|
+
const preview: Preview = {
|
|
6
|
+
parameters: {
|
|
7
|
+
controls: {
|
|
8
|
+
matchers: {
|
|
9
|
+
color: /(background|color)$/i,
|
|
10
|
+
date: /Date$/i,
|
|
11
|
+
},
|
|
12
|
+
},
|
|
13
|
+
|
|
14
|
+
a11y: {
|
|
15
|
+
// 'todo' - show a11y violations in the test UI only
|
|
16
|
+
// 'error' - fail CI on a11y violations
|
|
17
|
+
// 'off' - skip a11y checks entirely
|
|
18
|
+
test: "todo",
|
|
19
|
+
},
|
|
20
|
+
},
|
|
21
|
+
|
|
22
|
+
decorators: [(Story) => <Story />],
|
|
23
|
+
};
|
|
24
|
+
|
|
25
|
+
export default preview;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import * as a11yAddonAnnotations from "@storybook/addon-a11y/preview";
|
|
2
|
+
import { setProjectAnnotations } from "@storybook/react-vite";
|
|
3
|
+
import * as projectAnnotations from "./preview";
|
|
4
|
+
|
|
5
|
+
// This is an important step to apply the right configuration when testing your stories.
|
|
6
|
+
// More info at: https://storybook.js.org/docs/api/portable-stories/portable-stories-vitest#setprojectannotations
|
|
7
|
+
setProjectAnnotations([a11yAddonAnnotations, projectAnnotations]);
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
//#region \0rolldown/runtime.js
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __commonJSMin = (cb, mod) => () => (mod || cb((mod = { exports: {} }).exports, mod), mod.exports);
|
|
9
|
+
var __exportAll = (all, no_symbols) => {
|
|
10
|
+
let target = {};
|
|
11
|
+
for (var name in all) __defProp(target, name, {
|
|
12
|
+
get: all[name],
|
|
13
|
+
enumerable: true
|
|
14
|
+
});
|
|
15
|
+
if (!no_symbols) __defProp(target, Symbol.toStringTag, { value: "Module" });
|
|
16
|
+
return target;
|
|
17
|
+
};
|
|
18
|
+
var __copyProps = (to, from, except, desc) => {
|
|
19
|
+
if (from && typeof from === "object" || typeof from === "function") for (var keys = __getOwnPropNames(from), i = 0, n = keys.length, key; i < n; i++) {
|
|
20
|
+
key = keys[i];
|
|
21
|
+
if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
22
|
+
get: ((k) => from[k]).bind(null, key),
|
|
23
|
+
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
24
|
+
});
|
|
25
|
+
}
|
|
26
|
+
return to;
|
|
27
|
+
};
|
|
28
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
|
|
29
|
+
value: mod,
|
|
30
|
+
enumerable: true
|
|
31
|
+
}) : target, mod));
|
|
32
|
+
//#endregion
|
|
33
|
+
export { __exportAll as n, __toESM as r, __commonJSMin as t };
|