@pup_roko/ui-kit 1.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 +73 -0
- package/dist/index.d.ts +45 -0
- package/dist/index.js +2 -0
- package/dist/index.js.map +1 -0
- package/dist/types/components/Buttons/vit-button.d.ts +9 -0
- package/dist/types/components/Cards/vit-card.d.ts +7 -0
- package/dist/types/components/GreyScreen/greyScreen.d.ts +8 -0
- package/dist/types/components/Header/vitHeader.d.ts +8 -0
- package/dist/types/components/Inputs/vitInputFilter.d.ts +9 -0
- package/dist/types/components/Pills/vit-pill.d.ts +7 -0
- package/dist/types/components/index.d.ts +6 -0
- package/dist/types/index.d.ts +1 -0
- package/package.json +53 -0
package/README.md
ADDED
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
# React + TypeScript + Vite
|
|
2
|
+
|
|
3
|
+
This template provides a minimal setup to get React working in Vite with HMR and some ESLint rules.
|
|
4
|
+
|
|
5
|
+
Currently, two official plugins are available:
|
|
6
|
+
|
|
7
|
+
- [@vitejs/plugin-react](https://github.com/vitejs/vite-plugin-react/blob/main/packages/plugin-react) uses [Babel](https://babeljs.io/) (or [oxc](https://oxc.rs) when used in [rolldown-vite](https://vite.dev/guide/rolldown)) for Fast Refresh
|
|
8
|
+
- [@vitejs/plugin-react-swc](https://github.com/vitejs/vite-plugin-react/blob/main/packages/plugin-react-swc) uses [SWC](https://swc.rs/) for Fast Refresh
|
|
9
|
+
|
|
10
|
+
## React Compiler
|
|
11
|
+
|
|
12
|
+
The React Compiler is not enabled on this template because of its impact on dev & build performances. To add it, see [this documentation](https://react.dev/learn/react-compiler/installation).
|
|
13
|
+
|
|
14
|
+
## Expanding the ESLint configuration
|
|
15
|
+
|
|
16
|
+
If you are developing a production application, we recommend updating the configuration to enable type-aware lint rules:
|
|
17
|
+
|
|
18
|
+
```js
|
|
19
|
+
export default defineConfig([
|
|
20
|
+
globalIgnores(['dist']),
|
|
21
|
+
{
|
|
22
|
+
files: ['**/*.{ts,tsx}'],
|
|
23
|
+
extends: [
|
|
24
|
+
// Other configs...
|
|
25
|
+
|
|
26
|
+
// Remove tseslint.configs.recommended and replace with this
|
|
27
|
+
tseslint.configs.recommendedTypeChecked,
|
|
28
|
+
// Alternatively, use this for stricter rules
|
|
29
|
+
tseslint.configs.strictTypeChecked,
|
|
30
|
+
// Optionally, add this for stylistic rules
|
|
31
|
+
tseslint.configs.stylisticTypeChecked,
|
|
32
|
+
|
|
33
|
+
// Other configs...
|
|
34
|
+
],
|
|
35
|
+
languageOptions: {
|
|
36
|
+
parserOptions: {
|
|
37
|
+
project: ['./tsconfig.node.json', './tsconfig.app.json'],
|
|
38
|
+
tsconfigRootDir: import.meta.dirname,
|
|
39
|
+
},
|
|
40
|
+
// other options...
|
|
41
|
+
},
|
|
42
|
+
},
|
|
43
|
+
])
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
You can also install [eslint-plugin-react-x](https://github.com/Rel1cx/eslint-react/tree/main/packages/plugins/eslint-plugin-react-x) and [eslint-plugin-react-dom](https://github.com/Rel1cx/eslint-react/tree/main/packages/plugins/eslint-plugin-react-dom) for React-specific lint rules:
|
|
47
|
+
|
|
48
|
+
```js
|
|
49
|
+
// eslint.config.js
|
|
50
|
+
import reactX from 'eslint-plugin-react-x'
|
|
51
|
+
import reactDom from 'eslint-plugin-react-dom'
|
|
52
|
+
|
|
53
|
+
export default defineConfig([
|
|
54
|
+
globalIgnores(['dist']),
|
|
55
|
+
{
|
|
56
|
+
files: ['**/*.{ts,tsx}'],
|
|
57
|
+
extends: [
|
|
58
|
+
// Other configs...
|
|
59
|
+
// Enable lint rules for React
|
|
60
|
+
reactX.configs['recommended-typescript'],
|
|
61
|
+
// Enable lint rules for React DOM
|
|
62
|
+
reactDom.configs.recommended,
|
|
63
|
+
],
|
|
64
|
+
languageOptions: {
|
|
65
|
+
parserOptions: {
|
|
66
|
+
project: ['./tsconfig.node.json', './tsconfig.app.json'],
|
|
67
|
+
tsconfigRootDir: import.meta.dirname,
|
|
68
|
+
},
|
|
69
|
+
// other options...
|
|
70
|
+
},
|
|
71
|
+
},
|
|
72
|
+
])
|
|
73
|
+
```
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import React$1 from 'react';
|
|
3
|
+
|
|
4
|
+
type ButtonProps = {
|
|
5
|
+
vitClass?: string;
|
|
6
|
+
svgUrl?: string;
|
|
7
|
+
disabled?: boolean;
|
|
8
|
+
children?: React.ReactNode;
|
|
9
|
+
};
|
|
10
|
+
declare const vitButton: ({ vitClass, svgUrl, disabled, children }: ButtonProps) => react_jsx_runtime.JSX.Element;
|
|
11
|
+
|
|
12
|
+
type InputFilterProps = {
|
|
13
|
+
vitClass?: string;
|
|
14
|
+
svgUrl?: string;
|
|
15
|
+
disabled?: boolean;
|
|
16
|
+
maxLength?: number;
|
|
17
|
+
};
|
|
18
|
+
declare const vitInputFilter: ({ vitClass, svgUrl, disabled, maxLength }: InputFilterProps) => react_jsx_runtime.JSX.Element;
|
|
19
|
+
|
|
20
|
+
type CardProps = {
|
|
21
|
+
vitClass?: string;
|
|
22
|
+
children: React.ReactNode;
|
|
23
|
+
};
|
|
24
|
+
declare const vitCard: ({ vitClass, children }: CardProps) => react_jsx_runtime.JSX.Element;
|
|
25
|
+
|
|
26
|
+
type PillProps = {
|
|
27
|
+
children: React.ReactNode;
|
|
28
|
+
vitClass?: string;
|
|
29
|
+
};
|
|
30
|
+
declare const vitPill: ({ children, vitClass }: PillProps) => react_jsx_runtime.JSX.Element;
|
|
31
|
+
|
|
32
|
+
type HeaderProps = {
|
|
33
|
+
children?: React$1.ReactNode;
|
|
34
|
+
vitClass?: string;
|
|
35
|
+
};
|
|
36
|
+
declare const vitHeader: ({ children, vitClass }: HeaderProps) => react_jsx_runtime.JSX.Element;
|
|
37
|
+
|
|
38
|
+
type GreyScreenProps = {
|
|
39
|
+
children?: React.ReactNode;
|
|
40
|
+
vitClass?: string;
|
|
41
|
+
shown?: boolean;
|
|
42
|
+
};
|
|
43
|
+
declare const vitGreyScreen: ({ children, vitClass, shown }: GreyScreenProps) => false | react_jsx_runtime.JSX.Element;
|
|
44
|
+
|
|
45
|
+
export { vitButton, vitCard, vitGreyScreen, vitHeader, vitInputFilter, vitPill };
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{jsxs as n,jsx as d,Fragment as o}from"react/jsx-runtime";function i(n,d){void 0===d&&(d={});var o=d.insertAt;if(n&&"undefined"!=typeof document){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css","top"===o&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=n:r.appendChild(document.createTextNode(n))}}i('* {\n box-sizing: border-box;\n margin: 0;\n padding: 0;\n font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;\n color: #222222;\n}\n\nh1, h2, h3, h4 {\n font-family: "Georgia", serif;\n font-weight: 600;\n line-height: 1.2;\n margin-bottom: 8px;\n}\n\nh1 {\n font-size: 24px;\n}\n\nh2 {\n font-size: 20px;\n}\n\nh3 {\n font-size: 18px;\n}\n\nh4 {\n font-size: 16px;\n}\n\np {\n font-size: 14px;\n line-height: 1.5;\n margin-bottom: 16px;\n}\n\na {\n color: #0099aa;\n text-decoration: none;\n}\na:hover {\n text-decoration: underline;\n}\n\nstrong, b {\n font-weight: 600;\n}\n\n.xs {\n padding: 4px;\n}\n\n.sm {\n padding: 8px;\n}\n\n.md {\n padding: 16px;\n}\n\n.lg {\n padding: 24px;\n}\n\n.xl {\n padding: 32px;\n}\n\n.xxl {\n padding: 48px;\n}\n\n.info {\n color: #ffddff;\n background-color: #770077;\n}\n\n.success {\n color: #ddffdd;\n background-color: #007700;\n}\n\n.warning {\n color: #ffffdd;\n background-color: #777700;\n}\n\n.alert {\n color: #ffddaa;\n background-color: #bb7700;\n}\n\n.error {\n color: #ffdddd;\n background-color: #770000;\n}\n\n.info-inverted {\n color: #770077;\n background-color: #ffddff;\n}\n\n.success-inverted {\n color: #007700;\n background-color: #ddffdd;\n}\n\n.warning-inverted {\n color: #777700;\n background-color: #ffffdd;\n}\n\n.alert-inverted {\n color: #bb7700;\n background-color: #ffddaa;\n}\n\n.error-inverted {\n color: #770000;\n background-color: #ffdddd;\n}\n\n.body-container {\n max-width: 100%;\n margin: 0 auto;\n padding: 0 8px;\n}\n@media screen and (max-width: 648px) {\n .body-container {\n max-width: 600px;\n padding: 0 8px;\n }\n}\n@media screen and (min-width: 649px) and (max-width: 1024px) {\n .body-container {\n max-width: 900px;\n padding: 0 8px;\n }\n}\n@media screen and (min-width: 1025px) {\n .body-container {\n max-width: 1200px;\n padding: 0 8px;\n }\n}\n\nbutton {\n border: none;\n border-radius: 4px;\n padding: 8px;\n font-size: 14px;\n font-weight: 600;\n cursor: pointer;\n display: flex;\n align-items: center;\n}\nbutton:hover:not(:disabled) {\n opacity: 0.8;\n}\nbutton:disabled {\n background-color: #dddddd;\n color: #888888;\n cursor: not-allowed;\n}\nbutton img {\n width: 20px;\n height: 20px;\n margin-right: 4px;\n filter: brightness(100%) saturate(100%) invert(100%);\n opacity: 0.8;\n}\nbutton :where(*) {\n color: inherit;\n}');const r=({vitClass:o="",svgUrl:i="src/assets/images/health-cross.svg",disabled:r=!1,children:e=null})=>n("button",{className:`${o} ${r?"disabled":""}`,disabled:r,children:[d("img",{src:i,alt:"icon"}),e]});i('* {\n box-sizing: border-box;\n margin: 0;\n padding: 0;\n font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;\n color: #222222;\n}\n\nh1, h2, h3, h4 {\n font-family: "Georgia", serif;\n font-weight: 600;\n line-height: 1.2;\n margin-bottom: 8px;\n}\n\nh1 {\n font-size: 24px;\n}\n\nh2 {\n font-size: 20px;\n}\n\nh3 {\n font-size: 18px;\n}\n\nh4 {\n font-size: 16px;\n}\n\np {\n font-size: 14px;\n line-height: 1.5;\n margin-bottom: 16px;\n}\n\na {\n color: #0099aa;\n text-decoration: none;\n}\na:hover {\n text-decoration: underline;\n}\n\nstrong, b {\n font-weight: 600;\n}\n\n.xs {\n padding: 4px;\n}\n\n.sm {\n padding: 8px;\n}\n\n.md {\n padding: 16px;\n}\n\n.lg {\n padding: 24px;\n}\n\n.xl {\n padding: 32px;\n}\n\n.xxl {\n padding: 48px;\n}\n\n.info {\n color: #ffddff;\n background-color: #770077;\n}\n\n.success {\n color: #ddffdd;\n background-color: #007700;\n}\n\n.warning {\n color: #ffffdd;\n background-color: #777700;\n}\n\n.alert {\n color: #ffddaa;\n background-color: #bb7700;\n}\n\n.error {\n color: #ffdddd;\n background-color: #770000;\n}\n\n.info-inverted {\n color: #770077;\n background-color: #ffddff;\n}\n\n.success-inverted {\n color: #007700;\n background-color: #ddffdd;\n}\n\n.warning-inverted {\n color: #777700;\n background-color: #ffffdd;\n}\n\n.alert-inverted {\n color: #bb7700;\n background-color: #ffddaa;\n}\n\n.error-inverted {\n color: #770000;\n background-color: #ffdddd;\n}\n\n.body-container {\n max-width: 100%;\n margin: 0 auto;\n padding: 0 8px;\n}\n@media screen and (max-width: 648px) {\n .body-container {\n max-width: 600px;\n padding: 0 8px;\n }\n}\n@media screen and (min-width: 649px) and (max-width: 1024px) {\n .body-container {\n max-width: 900px;\n padding: 0 8px;\n }\n}\n@media screen and (min-width: 1025px) {\n .body-container {\n max-width: 1200px;\n padding: 0 8px;\n }\n}\n\n.filter {\n border: 1px solid #888888;\n background-color: #dddddd;\n opacity: 0.8;\n border-radius: 16px;\n padding: 8px;\n font-size: 14px;\n font-weight: 600;\n cursor: pointer;\n display: flex;\n align-items: center;\n width: fit-content;\n}\n.filter:hover:not(:disabled) {\n opacity: 1;\n}\n.filter:disabled {\n cursor: not-allowed;\n}\n.filter img {\n width: 20px;\n height: 20px;\n margin-right: 4px;\n filter: brightness(100%) saturate(100%) invert(100%);\n opacity: 0.8;\n}\n.filter input {\n border: none;\n border-radius: 2px;\n background-color: transparent;\n padding: 4px;\n}\n.filter :where(*) {\n color: inherit;\n}');const e=({vitClass:o="info",svgUrl:i="src/assets/images/looking-glass.svg",disabled:r,maxLength:e=100})=>n("div",{className:`filter ${o}`,children:[d("img",{src:i,alt:"icon"}),d("input",{type:"text",disabled:r,maxLength:e})]});i('* {\n box-sizing: border-box;\n margin: 0;\n padding: 0;\n font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;\n color: #222222;\n}\n\nh1, h2, h3, h4 {\n font-family: "Georgia", serif;\n font-weight: 600;\n line-height: 1.2;\n margin-bottom: 8px;\n}\n\nh1 {\n font-size: 24px;\n}\n\nh2 {\n font-size: 20px;\n}\n\nh3 {\n font-size: 18px;\n}\n\nh4 {\n font-size: 16px;\n}\n\np {\n font-size: 14px;\n line-height: 1.5;\n margin-bottom: 16px;\n}\n\na {\n color: #0099aa;\n text-decoration: none;\n}\na:hover {\n text-decoration: underline;\n}\n\nstrong, b {\n font-weight: 600;\n}\n\n.xs {\n padding: 4px;\n}\n\n.sm {\n padding: 8px;\n}\n\n.md {\n padding: 16px;\n}\n\n.lg {\n padding: 24px;\n}\n\n.xl {\n padding: 32px;\n}\n\n.xxl {\n padding: 48px;\n}\n\n.info {\n color: #ffddff;\n background-color: #770077;\n}\n\n.success {\n color: #ddffdd;\n background-color: #007700;\n}\n\n.warning {\n color: #ffffdd;\n background-color: #777700;\n}\n\n.alert {\n color: #ffddaa;\n background-color: #bb7700;\n}\n\n.error {\n color: #ffdddd;\n background-color: #770000;\n}\n\n.info-inverted {\n color: #770077;\n background-color: #ffddff;\n}\n\n.success-inverted {\n color: #007700;\n background-color: #ddffdd;\n}\n\n.warning-inverted {\n color: #777700;\n background-color: #ffffdd;\n}\n\n.alert-inverted {\n color: #bb7700;\n background-color: #ffddaa;\n}\n\n.error-inverted {\n color: #770000;\n background-color: #ffdddd;\n}\n\n.body-container {\n max-width: 100%;\n margin: 0 auto;\n padding: 0 8px;\n}\n@media screen and (max-width: 648px) {\n .body-container {\n max-width: 600px;\n padding: 0 8px;\n }\n}\n@media screen and (min-width: 649px) and (max-width: 1024px) {\n .body-container {\n max-width: 900px;\n padding: 0 8px;\n }\n}\n@media screen and (min-width: 1025px) {\n .body-container {\n max-width: 1200px;\n padding: 0 8px;\n }\n}\n\n.card {\n border: none;\n border-radius: 16px;\n padding: 16px;\n display: flex;\n}\n.card :where(*) {\n color: inherit;\n}');const a=({vitClass:n="info",children:i=d("div",{})})=>d(o,{children:d("article",{className:`card ${n}`,children:i})});i('* {\n box-sizing: border-box;\n margin: 0;\n padding: 0;\n font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;\n color: #222222;\n}\n\nh1, h2, h3, h4 {\n font-family: "Georgia", serif;\n font-weight: 600;\n line-height: 1.2;\n margin-bottom: 8px;\n}\n\nh1 {\n font-size: 24px;\n}\n\nh2 {\n font-size: 20px;\n}\n\nh3 {\n font-size: 18px;\n}\n\nh4 {\n font-size: 16px;\n}\n\np {\n font-size: 14px;\n line-height: 1.5;\n margin-bottom: 16px;\n}\n\na {\n color: #0099aa;\n text-decoration: none;\n}\na:hover {\n text-decoration: underline;\n}\n\nstrong, b {\n font-weight: 600;\n}\n\n.xs {\n padding: 4px;\n}\n\n.sm {\n padding: 8px;\n}\n\n.md {\n padding: 16px;\n}\n\n.lg {\n padding: 24px;\n}\n\n.xl {\n padding: 32px;\n}\n\n.xxl {\n padding: 48px;\n}\n\n.info {\n color: #ffddff;\n background-color: #770077;\n}\n\n.success {\n color: #ddffdd;\n background-color: #007700;\n}\n\n.warning {\n color: #ffffdd;\n background-color: #777700;\n}\n\n.alert {\n color: #ffddaa;\n background-color: #bb7700;\n}\n\n.error {\n color: #ffdddd;\n background-color: #770000;\n}\n\n.info-inverted {\n color: #770077;\n background-color: #ffddff;\n}\n\n.success-inverted {\n color: #007700;\n background-color: #ddffdd;\n}\n\n.warning-inverted {\n color: #777700;\n background-color: #ffffdd;\n}\n\n.alert-inverted {\n color: #bb7700;\n background-color: #ffddaa;\n}\n\n.error-inverted {\n color: #770000;\n background-color: #ffdddd;\n}\n\n.body-container {\n max-width: 100%;\n margin: 0 auto;\n padding: 0 8px;\n}\n@media screen and (max-width: 648px) {\n .body-container {\n max-width: 600px;\n padding: 0 8px;\n }\n}\n@media screen and (min-width: 649px) and (max-width: 1024px) {\n .body-container {\n max-width: 900px;\n padding: 0 8px;\n }\n}\n@media screen and (min-width: 1025px) {\n .body-container {\n max-width: 1200px;\n padding: 0 8px;\n }\n}\n\n.pill {\n display: flex;\n width: fit-content;\n font-size: 14px;\n padding: 8px 16px;\n border-radius: 24px;\n}');const t=({children:n,vitClass:o="info"})=>d("div",{className:`pill ${o}`,children:n});i('* {\n box-sizing: border-box;\n margin: 0;\n padding: 0;\n font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;\n color: #222222;\n}\n\nh1, h2, h3, h4 {\n font-family: "Georgia", serif;\n font-weight: 600;\n line-height: 1.2;\n margin-bottom: 8px;\n}\n\nh1 {\n font-size: 24px;\n}\n\nh2 {\n font-size: 20px;\n}\n\nh3 {\n font-size: 18px;\n}\n\nh4 {\n font-size: 16px;\n}\n\np {\n font-size: 14px;\n line-height: 1.5;\n margin-bottom: 16px;\n}\n\na {\n color: #0099aa;\n text-decoration: none;\n}\na:hover {\n text-decoration: underline;\n}\n\nstrong, b {\n font-weight: 600;\n}\n\n.xs {\n padding: 4px;\n}\n\n.sm {\n padding: 8px;\n}\n\n.md {\n padding: 16px;\n}\n\n.lg {\n padding: 24px;\n}\n\n.xl {\n padding: 32px;\n}\n\n.xxl {\n padding: 48px;\n}\n\n.info {\n color: #ffddff;\n background-color: #770077;\n}\n\n.success {\n color: #ddffdd;\n background-color: #007700;\n}\n\n.warning {\n color: #ffffdd;\n background-color: #777700;\n}\n\n.alert {\n color: #ffddaa;\n background-color: #bb7700;\n}\n\n.error {\n color: #ffdddd;\n background-color: #770000;\n}\n\n.info-inverted {\n color: #770077;\n background-color: #ffddff;\n}\n\n.success-inverted {\n color: #007700;\n background-color: #ddffdd;\n}\n\n.warning-inverted {\n color: #777700;\n background-color: #ffffdd;\n}\n\n.alert-inverted {\n color: #bb7700;\n background-color: #ffddaa;\n}\n\n.error-inverted {\n color: #770000;\n background-color: #ffdddd;\n}\n\n.body-container {\n max-width: 100%;\n margin: 0 auto;\n padding: 0 8px;\n}\n@media screen and (max-width: 648px) {\n .body-container {\n max-width: 600px;\n padding: 0 8px;\n }\n}\n@media screen and (min-width: 649px) and (max-width: 1024px) {\n .body-container {\n max-width: 900px;\n padding: 0 8px;\n }\n}\n@media screen and (min-width: 1025px) {\n .body-container {\n max-width: 1200px;\n padding: 0 8px;\n }\n}\n\n.header {\n position: fixed;\n top: 0;\n left: 0;\n width: 100%;\n z-index: 10;\n display: flex;\n align-items: center;\n justify-content: space-between;\n padding: 16px;\n}\n.header section {\n display: flex;\n gap: 16px;\n justify-content: left;\n width: 100%;\n}\n.header :where(*) {\n color: inherit;\n}');const c=({children:n=d("div",{}),vitClass:i="info md"})=>d(o,{children:d("header",{className:`header ${i}`,children:d("section",{className:"body-container",children:n})})});i('* {\n box-sizing: border-box;\n margin: 0;\n padding: 0;\n font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;\n color: #222222;\n}\n\nh1, h2, h3, h4 {\n font-family: "Georgia", serif;\n font-weight: 600;\n line-height: 1.2;\n margin-bottom: 8px;\n}\n\nh1 {\n font-size: 24px;\n}\n\nh2 {\n font-size: 20px;\n}\n\nh3 {\n font-size: 18px;\n}\n\nh4 {\n font-size: 16px;\n}\n\np {\n font-size: 14px;\n line-height: 1.5;\n margin-bottom: 16px;\n}\n\na {\n color: #0099aa;\n text-decoration: none;\n}\na:hover {\n text-decoration: underline;\n}\n\nstrong, b {\n font-weight: 600;\n}\n\n.xs {\n padding: 4px;\n}\n\n.sm {\n padding: 8px;\n}\n\n.md {\n padding: 16px;\n}\n\n.lg {\n padding: 24px;\n}\n\n.xl {\n padding: 32px;\n}\n\n.xxl {\n padding: 48px;\n}\n\n.info {\n color: #ffddff;\n background-color: #770077;\n}\n\n.success {\n color: #ddffdd;\n background-color: #007700;\n}\n\n.warning {\n color: #ffffdd;\n background-color: #777700;\n}\n\n.alert {\n color: #ffddaa;\n background-color: #bb7700;\n}\n\n.error {\n color: #ffdddd;\n background-color: #770000;\n}\n\n.info-inverted {\n color: #770077;\n background-color: #ffddff;\n}\n\n.success-inverted {\n color: #007700;\n background-color: #ddffdd;\n}\n\n.warning-inverted {\n color: #777700;\n background-color: #ffffdd;\n}\n\n.alert-inverted {\n color: #bb7700;\n background-color: #ffddaa;\n}\n\n.error-inverted {\n color: #770000;\n background-color: #ffdddd;\n}\n\n.body-container {\n max-width: 100%;\n margin: 0 auto;\n padding: 0 8px;\n}\n@media screen and (max-width: 648px) {\n .body-container {\n max-width: 600px;\n padding: 0 8px;\n }\n}\n@media screen and (min-width: 649px) and (max-width: 1024px) {\n .body-container {\n max-width: 900px;\n padding: 0 8px;\n }\n}\n@media screen and (min-width: 1025px) {\n .body-container {\n max-width: 1200px;\n padding: 0 8px;\n }\n}\n\n.grey-screen {\n position: fixed;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n background-color: rgba(0, 0, 0, 0.5);\n display: flex;\n justify-content: center;\n align-items: center;\n z-index: 20;\n}');const l=({children:n,vitClass:o,shown:i=!1})=>i&&d("div",{className:`grey-screen ${o}`,children:n});export{r as vitButton,a as vitCard,l as vitGreyScreen,c as vitHeader,e as vitInputFilter,t as vitPill};
|
|
2
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../node_modules/style-inject/dist/style-inject.es.js","../src/components/Buttons/vit-button.tsx","../src/components/Inputs/vitInputFilter.tsx","../src/components/Cards/vit-card.tsx","../src/components/Pills/vit-pill.tsx","../src/components/Header/vitHeader.tsx","../src/components/GreyScreen/greyScreen.tsx"],"sourcesContent":["function styleInject(css, ref) {\n if ( ref === void 0 ) ref = {};\n var insertAt = ref.insertAt;\n\n if (!css || typeof document === 'undefined') { return; }\n\n var head = document.head || document.getElementsByTagName('head')[0];\n var style = document.createElement('style');\n style.type = 'text/css';\n\n if (insertAt === 'top') {\n if (head.firstChild) {\n head.insertBefore(style, head.firstChild);\n } else {\n head.appendChild(style);\n }\n } else {\n head.appendChild(style);\n }\n\n if (style.styleSheet) {\n style.styleSheet.cssText = css;\n } else {\n style.appendChild(document.createTextNode(css));\n }\n}\n\nexport default styleInject;\n",null,null,null,null,null,null],"names":["styleInject","css","ref","insertAt","document","head","getElementsByTagName","style","createElement","type","firstChild","insertBefore","appendChild","styleSheet","cssText","createTextNode","vitButton","vitClass","svgUrl","disabled","children","_jsxs","className","_jsx","src","alt","vitInputFilter","maxLength","vitCard","_Fragment","vitPill","vitHeader","vitGreyScreen","shown"],"mappings":"gEAAA,SAASA,EAAYC,EAAKC,YACnBA,IAAiBA,EAAM,CAAA,GAC5B,IAAIC,EAAWD,EAAIC,SAEnB,GAAKF,GAA2B,oBAAbG,SAAnB,CAEA,IAAIC,EAAOD,SAASC,MAAQD,SAASE,qBAAqB,QAAQ,GAC9DC,EAAQH,SAASI,cAAc,SACnCD,EAAME,KAAO,WAEI,QAAbN,GACEE,EAAKK,WACPL,EAAKM,aAAaJ,EAAOF,EAAKK,YAKhCL,EAAKO,YAAYL,GAGfA,EAAMM,WACRN,EAAMM,WAAWC,QAAUb,EAE3BM,EAAMK,YAAYR,SAASW,eAAed,GAnBW,CAqBzD,s4EChBA,MAAMe,EAAY,EACdC,WAAW,GACXC,SAAS,qCACTC,YAAW,EACXC,WAAW,QAGPC,EAAA,SAAA,CAAQC,UAAW,GAAGL,KAAYE,EAAW,WAAa,KAAMA,SAAUA,EAAQC,SAAA,CAC9EG,EAAA,MAAA,CAAKC,IAAKN,EAAQO,IAAI,SACpBL,+hFCTd,MAAMM,EAAiB,EACrBT,WAAW,OACXC,SAAS,sCACTC,WACAQ,YAAY,OAGRN,EAAA,MAAA,CAAKC,UAAW,UAAUL,IAAUG,SAAA,CAClCG,EAAA,MAAA,CAAKC,IAAKN,EAAQO,IAAI,SACtBF,EAAA,QAAA,CAAOd,KAAK,OAAOU,SAAUA,EAAUQ,UAAWA,mhECX1D,MAAMC,EAAU,EAAGX,WAAS,OAASG,WAAWG,EAAA,MAAA,CAAA,MAG5CA,EAAAM,EAAA,CAAAT,SACEG,EAAA,UAAA,CAASD,UAAW,QAAQL,IAAUG,SACnCA,ugECLT,MAAMU,EAAU,EAAGV,WAAUH,WAAW,UAEpCM,EAAA,MAAA,CAAKD,UAAW,QAAQL,IAAUG,SAC/BA,itECFP,MAAMW,EAAY,EAAEX,WAASG,EAAA,MAAA,IAAQN,WAAS,aAExCM,EAAAM,EAAA,CAAAT,SACEG,EAAA,SAAA,CAAQD,UAAW,UAAUL,IAAUG,SACrCG,aAASD,UAAU,iBAAgBF,SAChCA,gnECLb,MAAMY,EAAgB,EAAGZ,WAAUH,WAAUgB,SAAQ,KAEjDA,GACAV,EAAA,MAAA,CAAKD,UAAW,eAAeL,IAAUG,SACtCA","x_google_ignoreList":[0]}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import './button.scss';
|
|
2
|
+
type ButtonProps = {
|
|
3
|
+
vitClass?: string;
|
|
4
|
+
svgUrl?: string;
|
|
5
|
+
disabled?: boolean;
|
|
6
|
+
children?: React.ReactNode;
|
|
7
|
+
};
|
|
8
|
+
declare const vitButton: ({ vitClass, svgUrl, disabled, children }: ButtonProps) => import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
export { vitButton };
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import './greyScreen.scss';
|
|
2
|
+
type GreyScreenProps = {
|
|
3
|
+
children?: React.ReactNode;
|
|
4
|
+
vitClass?: string;
|
|
5
|
+
shown?: boolean;
|
|
6
|
+
};
|
|
7
|
+
declare const vitGreyScreen: ({ children, vitClass, shown }: GreyScreenProps) => false | import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
export { vitGreyScreen };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import './filter.scss';
|
|
2
|
+
type InputFilterProps = {
|
|
3
|
+
vitClass?: string;
|
|
4
|
+
svgUrl?: string;
|
|
5
|
+
disabled?: boolean;
|
|
6
|
+
maxLength?: number;
|
|
7
|
+
};
|
|
8
|
+
declare const vitInputFilter: ({ vitClass, svgUrl, disabled, maxLength }: InputFilterProps) => import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
export { vitInputFilter };
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
export { vitButton } from './Buttons/vit-button';
|
|
2
|
+
export { vitInputFilter } from './Inputs/vitInputFilter';
|
|
3
|
+
export { vitCard } from './Cards/vit-card';
|
|
4
|
+
export { vitPill } from './Pills/vit-pill';
|
|
5
|
+
export { vitHeader } from './Header/vitHeader';
|
|
6
|
+
export { vitGreyScreen } from './GreyScreen/greyScreen';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './components';
|
package/package.json
ADDED
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@pup_roko/ui-kit",
|
|
3
|
+
"private": false,
|
|
4
|
+
"version": "1.0.0",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"main": "dist/index.js",
|
|
7
|
+
"module": "dist/index.js",
|
|
8
|
+
"files": [
|
|
9
|
+
"dist"
|
|
10
|
+
],
|
|
11
|
+
"types": "dist/index.d.ts",
|
|
12
|
+
"scripts": {
|
|
13
|
+
"start": "rollup -c --bundleConfigAsCjs",
|
|
14
|
+
"storybook": "storybook dev -p 6006",
|
|
15
|
+
"build-storybook": "storybook build"
|
|
16
|
+
},
|
|
17
|
+
"devDependencies": {
|
|
18
|
+
"@chromatic-com/storybook": "^5.0.0",
|
|
19
|
+
"@rollup/plugin-commonjs": "^29.0.0",
|
|
20
|
+
"@rollup/plugin-node-resolve": "^16.0.3",
|
|
21
|
+
"@rollup/plugin-terser": "^0.4.4",
|
|
22
|
+
"@rollup/plugin-typescript": "^12.3.0",
|
|
23
|
+
"@storybook/addon-a11y": "^10.2.0",
|
|
24
|
+
"@storybook/addon-docs": "^10.2.0",
|
|
25
|
+
"@storybook/addon-vitest": "^10.2.0",
|
|
26
|
+
"@storybook/react-vite": "^10.2.0",
|
|
27
|
+
"@types/node": "^24.10.9",
|
|
28
|
+
"@types/react": "^19.2.5",
|
|
29
|
+
"@types/react-dom": "^19.2.3",
|
|
30
|
+
"@types/rollup-plugin-peer-deps-external": "^2.2.6",
|
|
31
|
+
"@vitejs/plugin-react": "^5.1.1",
|
|
32
|
+
"@vitest/browser-playwright": "^4.0.18",
|
|
33
|
+
"@vitest/coverage-v8": "^4.0.18",
|
|
34
|
+
"globals": "^16.5.0",
|
|
35
|
+
"playwright": "^1.57.0",
|
|
36
|
+
"react": "^19.2.0",
|
|
37
|
+
"react-dom": "^19.2.0",
|
|
38
|
+
"rollup": "^4.57.1",
|
|
39
|
+
"rollup-plugin-dts": "^6.3.0",
|
|
40
|
+
"rollup-plugin-peer-deps-external": "^2.2.4",
|
|
41
|
+
"rollup-plugin-postcss": "^4.0.2",
|
|
42
|
+
"sass-embedded": "^1.97.3",
|
|
43
|
+
"storybook": "^10.2.0",
|
|
44
|
+
"tslib": "^2.8.1",
|
|
45
|
+
"typescript": "~5.9.3",
|
|
46
|
+
"vite": "^7.3.1",
|
|
47
|
+
"vitest": "^4.0.18"
|
|
48
|
+
},
|
|
49
|
+
"peerDependencies": {
|
|
50
|
+
"react": "^19.2.0",
|
|
51
|
+
"react-dom": "^19.2.0"
|
|
52
|
+
}
|
|
53
|
+
}
|