tvuikit 0.1.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 +30 -0
- package/dist/assets/checkbutton.d.ts +12 -0
- package/dist/assets/checker.svg.d.ts +8 -0
- package/dist/assets/round.svg.d.ts +8 -0
- package/dist/components/active/active.d.ts +8 -0
- package/dist/components/active/index.d.ts +1 -0
- package/dist/components/background/background.d.ts +7 -0
- package/dist/components/background/index.d.ts +1 -0
- package/dist/components/background/index.stories.d.ts +7 -0
- package/dist/components/background/story.d.ts +6 -0
- package/dist/components/button/button.d.ts +8 -0
- package/dist/components/button/index.d.ts +1 -0
- package/dist/components/button/index.stories.d.ts +11 -0
- package/dist/components/button/story.d.ts +8 -0
- package/dist/components/checkbox/checkbox.d.ts +5 -0
- package/dist/components/checkbox/index.d.ts +1 -0
- package/dist/components/checkbox/index.stories.d.ts +7 -0
- package/dist/components/checkbox/story.d.ts +5 -0
- package/dist/components/guideline/button.d.ts +2 -0
- package/dist/components/guideline/checkbox.d.ts +1 -0
- package/dist/components/guideline/index.d.ts +2 -0
- package/dist/components/guideline/index.stories.d.ts +7 -0
- package/dist/components/guideline/radio.d.ts +1 -0
- package/dist/components/guideline/story.d.ts +1 -0
- package/dist/components/guideline/switch.d.ts +1 -0
- package/dist/components/guideline/text.d.ts +2 -0
- package/dist/components/index.d.ts +9 -0
- package/dist/components/input/index.d.ts +2 -0
- package/dist/components/input/index.stories.d.ts +7 -0
- package/dist/components/input/input.d.ts +5 -0
- package/dist/components/input/story.d.ts +1 -0
- package/dist/components/input/textarea.d.ts +5 -0
- package/dist/components/modal/index.d.ts +1 -0
- package/dist/components/modal/modal.d.ts +9 -0
- package/dist/components/radio/index.d.ts +1 -0
- package/dist/components/radio/index.stories.d.ts +7 -0
- package/dist/components/radio/radio.d.ts +5 -0
- package/dist/components/radio/story.d.ts +5 -0
- package/dist/components/switch/index.d.ts +1 -0
- package/dist/components/switch/index.stories.d.ts +7 -0
- package/dist/components/switch/story.d.ts +5 -0
- package/dist/components/switch/switch.d.ts +11 -0
- package/dist/components/wrapper/index.d.ts +1 -0
- package/dist/components/wrapper/wrapper.d.ts +7 -0
- package/dist/index.d.ts +2 -0
- package/dist/sigeev-ui-kit.es.js +1024 -0
- package/dist/sigeev-ui-kit.umd.js +42 -0
- package/dist/tvuikit.es.d.ts +1 -0
- package/dist/variables/colors/background.d.ts +5 -0
- package/dist/variables/colors/button.d.ts +7 -0
- package/dist/variables/colors/foreground.d.ts +7 -0
- package/dist/variables/colors/index.d.ts +3 -0
- package/dist/variables/fonts/index.d.ts +1 -0
- package/dist/variables/fonts/size.d.ts +18 -0
- package/dist/variables/index.d.ts +2 -0
- package/package.json +64 -0
package/README.md
ADDED
|
@@ -0,0 +1,30 @@
|
|
|
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/README.md) uses [Babel](https://babeljs.io/) for Fast Refresh
|
|
8
|
+
- [@vitejs/plugin-react-swc](https://github.com/vitejs/vite-plugin-react-swc) uses [SWC](https://swc.rs/) for Fast Refresh
|
|
9
|
+
|
|
10
|
+
## Expanding the ESLint configuration
|
|
11
|
+
|
|
12
|
+
If you are developing a production application, we recommend updating the configuration to enable type aware lint rules:
|
|
13
|
+
|
|
14
|
+
- Configure the top-level `parserOptions` property like this:
|
|
15
|
+
|
|
16
|
+
```js
|
|
17
|
+
export default {
|
|
18
|
+
// other rules...
|
|
19
|
+
parserOptions: {
|
|
20
|
+
ecmaVersion: "latest",
|
|
21
|
+
sourceType: "module",
|
|
22
|
+
project: ["./tsconfig.json", "./tsconfig.node.json"],
|
|
23
|
+
tsconfigRootDir: __dirname,
|
|
24
|
+
},
|
|
25
|
+
};
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
- Replace `plugin:@typescript-eslint/recommended` to `plugin:@typescript-eslint/recommended-type-checked` or `plugin:@typescript-eslint/strict-type-checked`
|
|
29
|
+
- Optionally add `plugin:@typescript-eslint/stylistic-type-checked`
|
|
30
|
+
- Install [eslint-plugin-react](https://github.com/jsx-eslint/eslint-plugin-react) and add `plugin:react/recommended` & `plugin:react/jsx-runtime` to the `extends` list
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { DetailedHTMLProps, HTMLAttributes } from 'react';
|
|
2
|
+
|
|
3
|
+
type DivProps = DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>;
|
|
4
|
+
export type CheckbuttonProps = {
|
|
5
|
+
inputName?: string;
|
|
6
|
+
inputId?: string;
|
|
7
|
+
size?: number;
|
|
8
|
+
checked?: boolean;
|
|
9
|
+
type: "checkbox" | "radio";
|
|
10
|
+
} & DivProps;
|
|
11
|
+
export declare const Checkbutton: ({ inputName, inputId, className, style, onClick, size, checked, type, ...props }: CheckbuttonProps) => import("react/jsx-runtime").JSX.Element;
|
|
12
|
+
export default Checkbutton;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Ref } from 'react';
|
|
2
|
+
|
|
3
|
+
export type CheckmarkProps = {
|
|
4
|
+
size: number | string;
|
|
5
|
+
ref: Ref<SVGSVGElement | null>;
|
|
6
|
+
className: string;
|
|
7
|
+
};
|
|
8
|
+
export declare const Checkmark: ({ size, ref, className }: CheckmarkProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './active';
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { DetailedHTMLProps, HTMLAttributes } from 'react';
|
|
2
|
+
|
|
3
|
+
export type BackgroundProps = {
|
|
4
|
+
imageVar: string;
|
|
5
|
+
} & DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>;
|
|
6
|
+
export declare const Background: ({ style, imageVar, className, ...props }: BackgroundProps) => import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
export default Background;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './background';
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { ButtonHTMLAttributes, DetailedHTMLProps, ReactNode } from 'react';
|
|
2
|
+
import { BUTTONS } from '../../variables/colors';
|
|
3
|
+
|
|
4
|
+
export type ButtonProps = {
|
|
5
|
+
children: ReactNode;
|
|
6
|
+
variant?: keyof typeof BUTTONS;
|
|
7
|
+
} & DetailedHTMLProps<ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>;
|
|
8
|
+
export declare const Button: ({ variant, children, className, ...props }: ButtonProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './button';
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Meta, StoryObj } from '@storybook/react-vite';
|
|
2
|
+
import { Page } from './story';
|
|
3
|
+
|
|
4
|
+
declare const meta: Meta<typeof Page>;
|
|
5
|
+
type Story = StoryObj<typeof Page>;
|
|
6
|
+
export declare const Default: Story;
|
|
7
|
+
export declare const Primary: Story;
|
|
8
|
+
export declare const Danger: Story;
|
|
9
|
+
export declare const Secondary: Story;
|
|
10
|
+
export declare const Tetriary: Story;
|
|
11
|
+
export default meta;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { BUTTONS } from '../../variables/colors';
|
|
3
|
+
|
|
4
|
+
export type PageProps = {
|
|
5
|
+
buttonChildren: ReactNode;
|
|
6
|
+
buttonType: keyof typeof BUTTONS;
|
|
7
|
+
};
|
|
8
|
+
export declare const Page: ({ buttonChildren: children, buttonType: type, }: PageProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './checkbox';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const Checkbox: () => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const Radio: () => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const Page: () => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const Switch: () => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export * from './button';
|
|
2
|
+
export * from './background';
|
|
3
|
+
export * from './input';
|
|
4
|
+
export * from './wrapper';
|
|
5
|
+
export * from './modal';
|
|
6
|
+
export * from './active';
|
|
7
|
+
export * from './checkbox';
|
|
8
|
+
export * from './switch';
|
|
9
|
+
export * as Guildline from './guideline';
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { DetailedHTMLProps, InputHTMLAttributes } from 'react';
|
|
2
|
+
|
|
3
|
+
export type InputProps = DetailedHTMLProps<InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>;
|
|
4
|
+
export declare const Input: ({ className, ...props }: InputProps) => import("react/jsx-runtime").JSX.Element;
|
|
5
|
+
export default Input;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const Page: () => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { DetailedHTMLProps, TextareaHTMLAttributes } from 'react';
|
|
2
|
+
|
|
3
|
+
export type TextareaProps = DetailedHTMLProps<TextareaHTMLAttributes<HTMLTextAreaElement>, HTMLTextAreaElement>;
|
|
4
|
+
export declare const Textarea: ({ className, ...props }: TextareaProps) => import("react/jsx-runtime").JSX.Element;
|
|
5
|
+
export default Textarea;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './modal';
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { DetailedHTMLProps, HTMLAttributes, Key } from 'react';
|
|
2
|
+
|
|
3
|
+
export type ModalProps = {
|
|
4
|
+
container: Element | DocumentFragment;
|
|
5
|
+
portalKey?: Key | null;
|
|
6
|
+
zIndex?: number;
|
|
7
|
+
} & DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>;
|
|
8
|
+
export declare const Modal: ({ container, children, portalKey, className, zIndex, style, ...props }: ModalProps) => import('react').ReactPortal;
|
|
9
|
+
export default Modal;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './radio';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './switch';
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { DetailedHTMLProps, HTMLAttributes } from 'react';
|
|
2
|
+
|
|
3
|
+
export type RadiocheckboxProps = {
|
|
4
|
+
inputName?: string;
|
|
5
|
+
inputId?: string;
|
|
6
|
+
radioSize?: number;
|
|
7
|
+
dangerousDisableError?: boolean;
|
|
8
|
+
checked?: boolean;
|
|
9
|
+
} & DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>;
|
|
10
|
+
export declare const Switch: ({ inputId, inputName, dangerousDisableError, style, className, onClick, radioSize, checked, ...props }: RadiocheckboxProps) => import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
export default Switch;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './wrapper';
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { DetailedHTMLProps, HTMLAttributes } from 'react';
|
|
2
|
+
|
|
3
|
+
export type WrapperProps = {
|
|
4
|
+
flexDirection?: "col" | "row";
|
|
5
|
+
} & DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>;
|
|
6
|
+
export declare const Wrapper: ({ flexDirection, className, ...props }: WrapperProps) => import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
export default Wrapper;
|
package/dist/index.d.ts
ADDED