kamotive_ui 2.3.26 → 3.6.26
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/dist/components/AttachedFilesPreview/AttachedFilesPreview.d.ts +1 -0
- package/dist/components/AttachedFilesPreview/AttachedFilesPreview.js +4 -4
- package/dist/components/Breadcrumb/Breadcrumb.js +4 -4
- package/dist/components/Breadcrumbs/Breadcrumbs.js +10 -4
- package/dist/components/Button/Button.d.ts +1 -1
- package/dist/components/Button/Button.js +11 -10
- package/dist/components/Button/Button.module.css +2 -1
- package/dist/components/Checkbox/Checkbox.js +4 -4
- package/dist/components/ColorPicker/ColorPicker.js +9 -8
- package/dist/components/Comment/Comment.js +13 -13
- package/dist/components/DateInput/DateInput.js +20 -19
- package/dist/components/Dialog/Dialog.js +5 -5
- package/dist/components/Dropdown/Dropdown.d.ts +3 -2
- package/dist/components/Dropdown/Dropdown.js +142 -53
- package/dist/components/Dropdown/Dropdown.module.css +25 -4
- package/dist/components/FileAttach/FileAttach.js +4 -4
- package/dist/components/FileItem/FileItem.js +8 -8
- package/dist/components/FileListAttached/FileListAtta/321/201hed.js +5 -5
- package/dist/components/FileLoader/FileLoader.js +119 -119
- package/dist/components/IconButton/IconButton.js +5 -2
- package/dist/components/Input/Input.js +6 -6
- package/dist/components/Link/Link.js +5 -5
- package/dist/components/List/List.js +13 -11
- package/dist/components/ListItem/ListItem.js +8 -8
- package/dist/components/ProgressBar/ProgressBar.js +4 -4
- package/dist/components/ProgressLoader/ProgressLoader.js +4 -4
- package/dist/components/RadioButton/RadioButton.js +4 -4
- package/dist/components/SettingTag/SettingTag.js +4 -4
- package/dist/components/Snackbar/Snackbar.js +7 -7
- package/dist/components/Spinner/Spinner.js +3 -3
- package/dist/components/Tab/Tab.js +3 -3
- package/dist/components/TableFilterSidebar/TableFilterSidebar.js +11 -11
- package/dist/components/Tabs/Tabs.js +14 -8
- package/dist/components/Tag/Tag.js +7 -7
- package/dist/components/TextEditor/TextEditor.js +179 -578
- package/dist/components/TextEditor/TextEditor.module.css +8 -7
- package/dist/components/ToggleButton/ToggleButton.js +4 -4
- package/dist/components/Tooltip/Tooltip.js +4 -4
- package/dist/components/Typography/Typography.js +2 -2
- package/dist/fonts/Montserrat-Bold.woff2 +0 -0
- package/dist/fonts/Montserrat-Italic.woff2 +0 -0
- package/dist/fonts/Montserrat-Light.woff2 +0 -0
- package/dist/fonts/Montserrat-Medium.woff2 +0 -0
- package/dist/fonts/Montserrat-MediumItalic.woff2 +0 -0
- package/dist/fonts/Montserrat-Regular.woff2 +0 -0
- package/dist/fonts/Montserrat-SemiBold.woff2 +0 -0
- package/dist/fonts/Montserrat-SemiBoldItalic.woff2 +0 -0
- package/dist/fonts/OpenSans-Bold.woff2 +0 -0
- package/dist/fonts/OpenSans-BoldItalic.woff2 +0 -0
- package/dist/fonts/OpenSans-Italic.woff2 +0 -0
- package/dist/fonts/OpenSans-Italic_1.woff2 +0 -0
- package/dist/fonts/OpenSans-Light.woff2 +0 -0
- package/dist/fonts/OpenSans-LightItalic.woff2 +0 -0
- package/dist/fonts/OpenSans-Medium.woff2 +0 -0
- package/dist/fonts/OpenSans-MediumItalic.woff2 +0 -0
- package/dist/fonts/OpenSans-Regular.woff2 +0 -0
- package/dist/fonts/OpenSans-Regular_1.woff2 +0 -0
- package/dist/fonts/OpenSans-SemiBold.woff2 +0 -0
- package/dist/fonts/OpenSans-SemiBoldItalic.woff2 +0 -0
- package/dist/fonts.scss +144 -0
- package/dist/index.d.ts +0 -2
- package/dist/index.js +0 -2
- package/dist/types/global.d.ts +26 -0
- package/dist/types/index.d.ts +56 -14
- package/dist/types/pell.d.ts +29 -0
- package/dist/{colors.css → variables.scss} +34 -0
- package/package.json +6 -1
- package/dist/components/Checkbox/Checkbox.stories.d.ts +0 -66
- package/dist/components/Checkbox/Checkbox.stories.js +0 -75
- package/dist/fonts.css +0 -37
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
declare module 'pell' {
|
|
2
|
+
interface PellAction {
|
|
3
|
+
name: string;
|
|
4
|
+
icon: string;
|
|
5
|
+
title: string;
|
|
6
|
+
result: () => void;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
interface PellOptions {
|
|
10
|
+
element: HTMLElement;
|
|
11
|
+
onChange: (html: string) => void;
|
|
12
|
+
defaultParagraphSeparator?: string;
|
|
13
|
+
actions?: Array<string | PellAction>;
|
|
14
|
+
classes?: {
|
|
15
|
+
actionbar?: string;
|
|
16
|
+
button?: string;
|
|
17
|
+
content?: string;
|
|
18
|
+
selected?: string;
|
|
19
|
+
};
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
interface PellEditor {
|
|
23
|
+
content: HTMLElement;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
export function init(options: PellOptions): PellEditor;
|
|
27
|
+
export function exec(command: string, value?: string): void;
|
|
28
|
+
}
|
|
29
|
+
|
|
@@ -1,4 +1,38 @@
|
|
|
1
1
|
:root {
|
|
2
|
+
//Шрифты
|
|
3
|
+
--font-family-headers: 'Montserrat', sans-serif;
|
|
4
|
+
--font-family-content: 'Open Sans', sans-serif;
|
|
5
|
+
|
|
6
|
+
--font-size-48: 48px;
|
|
7
|
+
--font-size-36: 36px;
|
|
8
|
+
--font-size-24: 24px;
|
|
9
|
+
--font-size-20: 20px;
|
|
10
|
+
--font-size-18: 18px;
|
|
11
|
+
--font-size-16: 16px;
|
|
12
|
+
--font-size-14: 14px;
|
|
13
|
+
--font-size-12: 12px;
|
|
14
|
+
--font-size-10: 10px;
|
|
15
|
+
|
|
16
|
+
--lineHeight-48: 56px;
|
|
17
|
+
--lineHeight-36: 42px;
|
|
18
|
+
--lineHeight-24: 32px;
|
|
19
|
+
--lineHeight-20: 28px;
|
|
20
|
+
--lineHeight-18: 24px;
|
|
21
|
+
--lineHeight-16: 22px;
|
|
22
|
+
--lineHeight-14: 18px;
|
|
23
|
+
--lineHeight-12: 16px;
|
|
24
|
+
--lineHeight-10: 14px;
|
|
25
|
+
|
|
26
|
+
--font-weight-bold: 700;
|
|
27
|
+
--font-weight-semiBold: 600;
|
|
28
|
+
--font-weight-medium: 500;
|
|
29
|
+
--font-weight-regular: 400;
|
|
30
|
+
--font-weight-light: 300;
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
--letterSpacing: 0em;
|
|
34
|
+
|
|
35
|
+
//Цвета
|
|
2
36
|
--white: #ffffff;
|
|
3
37
|
|
|
4
38
|
--grey-medium: #aeaeb2;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "kamotive_ui",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "03.6.26",
|
|
4
4
|
"main": "dist/index.js",
|
|
5
5
|
"types": "dist/index.d.ts",
|
|
6
6
|
"files": [
|
|
@@ -20,6 +20,10 @@
|
|
|
20
20
|
"license": "ISC",
|
|
21
21
|
"description": "Библиотека UI-компонентов для использования в приложении",
|
|
22
22
|
"dependencies": {
|
|
23
|
+
"@tiptap/extension-history": "^3.20.4",
|
|
24
|
+
"@tiptap/extension-underline": "^3.20.4",
|
|
25
|
+
"@tiptap/react": "^3.20.4",
|
|
26
|
+
"@tiptap/starter-kit": "^3.20.4",
|
|
23
27
|
"@uiw/react-color": "^2.3.4",
|
|
24
28
|
"classnames": "^2.5.1",
|
|
25
29
|
"clsx": "^2.1.1",
|
|
@@ -46,6 +50,7 @@
|
|
|
46
50
|
"eslint-plugin-react": "^7.37.2",
|
|
47
51
|
"globals": "^15.13.0",
|
|
48
52
|
"prettier": "^3.4.2",
|
|
53
|
+
"sass-embedded": "^1.100.0",
|
|
49
54
|
"storybook": "^8.4.7",
|
|
50
55
|
"typescript": "^5.7.2",
|
|
51
56
|
"typescript-eslint": "^8.18.0",
|
|
@@ -1,66 +0,0 @@
|
|
|
1
|
-
import { ChangeEventHandler } from 'react';
|
|
2
|
-
import type { Meta } from '@storybook/react';
|
|
3
|
-
export interface CheckboxProps {
|
|
4
|
-
/** Идентификатор */
|
|
5
|
-
checked?: boolean;
|
|
6
|
-
/** Обработчик изменения состояния */
|
|
7
|
-
onChange?: ChangeEventHandler<HTMLInputElement>;
|
|
8
|
-
/** Заблокированный чекбокс */
|
|
9
|
-
disabled?: boolean;
|
|
10
|
-
/** Размер чекбокса */
|
|
11
|
-
size?: 'sm' | 'md';
|
|
12
|
-
/** Текст лейбла */
|
|
13
|
-
label?: string;
|
|
14
|
-
}
|
|
15
|
-
declare const meta: Meta<CheckboxProps>;
|
|
16
|
-
export default meta;
|
|
17
|
-
export declare const CheckboxOff: {
|
|
18
|
-
(argTypes: CheckboxProps): JSX.Element;
|
|
19
|
-
storyName: string;
|
|
20
|
-
};
|
|
21
|
-
export declare const CheckboxLabel: {
|
|
22
|
-
(argTypes: CheckboxProps): JSX.Element;
|
|
23
|
-
storyName: string;
|
|
24
|
-
args: {
|
|
25
|
-
label: string;
|
|
26
|
-
};
|
|
27
|
-
};
|
|
28
|
-
export declare const CheckboxChecked: {
|
|
29
|
-
(argTypes: CheckboxProps): JSX.Element;
|
|
30
|
-
storyName: string;
|
|
31
|
-
args: {
|
|
32
|
-
checked: boolean;
|
|
33
|
-
disabled: boolean;
|
|
34
|
-
};
|
|
35
|
-
};
|
|
36
|
-
export declare const CheckboxDisabled: {
|
|
37
|
-
(argTypes: CheckboxProps): JSX.Element;
|
|
38
|
-
storyName: string;
|
|
39
|
-
args: {
|
|
40
|
-
checked: boolean;
|
|
41
|
-
disabled: boolean;
|
|
42
|
-
};
|
|
43
|
-
};
|
|
44
|
-
export declare const CheckboxCheckedDisabled: {
|
|
45
|
-
(argTypes: CheckboxProps): JSX.Element;
|
|
46
|
-
storyName: string;
|
|
47
|
-
args: {
|
|
48
|
-
checked: boolean;
|
|
49
|
-
disabled: boolean;
|
|
50
|
-
};
|
|
51
|
-
};
|
|
52
|
-
export declare const CheckboxCustomColor: {
|
|
53
|
-
(argTypes: CheckboxProps): JSX.Element;
|
|
54
|
-
storyName: string;
|
|
55
|
-
args: {
|
|
56
|
-
color: string;
|
|
57
|
-
};
|
|
58
|
-
};
|
|
59
|
-
export declare const CheckboxCustomColorFilled: {
|
|
60
|
-
(argTypes: CheckboxProps): JSX.Element;
|
|
61
|
-
storyName: string;
|
|
62
|
-
args: {
|
|
63
|
-
color: string;
|
|
64
|
-
filled: boolean;
|
|
65
|
-
};
|
|
66
|
-
};
|
|
@@ -1,75 +0,0 @@
|
|
|
1
|
-
import React, { useState } from 'react';
|
|
2
|
-
import { Checkbox } from './Checkbox';
|
|
3
|
-
const meta = {
|
|
4
|
-
component: Checkbox,
|
|
5
|
-
parameters: {
|
|
6
|
-
layout: 'centered',
|
|
7
|
-
},
|
|
8
|
-
tags: ['autodocs'],
|
|
9
|
-
decorators: [
|
|
10
|
-
(Story) => (React.createElement("div", { style: {
|
|
11
|
-
backgroundColor: 'var(--white)',
|
|
12
|
-
padding: '30px',
|
|
13
|
-
borderRadius: '10px',
|
|
14
|
-
width: '900px'
|
|
15
|
-
} },
|
|
16
|
-
React.createElement(Story, null))),
|
|
17
|
-
],
|
|
18
|
-
args: {
|
|
19
|
-
size: 'sm',
|
|
20
|
-
disabled: false,
|
|
21
|
-
},
|
|
22
|
-
argTypes: {
|
|
23
|
-
size: {
|
|
24
|
-
description: 'Свойство, позволяющее регулировать размер чекбокса',
|
|
25
|
-
control: { type: 'radio' },
|
|
26
|
-
options: ['sm', 'md'],
|
|
27
|
-
},
|
|
28
|
-
disabled: { description: 'Устанавливает атрибут disabled', control: { type: 'boolean' } },
|
|
29
|
-
checked: { description: 'Задаёт включённое состояние для компонента' },
|
|
30
|
-
label: { description: 'Текст лейбла чекбокса', type: 'string' },
|
|
31
|
-
},
|
|
32
|
-
};
|
|
33
|
-
export default meta;
|
|
34
|
-
export const CheckboxOff = (argTypes) => {
|
|
35
|
-
const [checked, setChecked] = useState(false);
|
|
36
|
-
const handleChange = () => {
|
|
37
|
-
setChecked(prev => !prev);
|
|
38
|
-
};
|
|
39
|
-
return (React.createElement(Checkbox, Object.assign({ checked: checked, onChange: handleChange }, argTypes)));
|
|
40
|
-
};
|
|
41
|
-
CheckboxOff.storyName = 'Checkbox по умолчанию';
|
|
42
|
-
export const CheckboxLabel = (argTypes) => React.createElement(Checkbox, Object.assign({}, argTypes));
|
|
43
|
-
CheckboxLabel.storyName = 'Checkbox c label';
|
|
44
|
-
CheckboxLabel.args = {
|
|
45
|
-
label: 'Чекбокс',
|
|
46
|
-
};
|
|
47
|
-
export const CheckboxChecked = (argTypes) => React.createElement(Checkbox, Object.assign({}, argTypes));
|
|
48
|
-
CheckboxChecked.storyName = 'Checkbox выбран';
|
|
49
|
-
CheckboxChecked.args = {
|
|
50
|
-
checked: true,
|
|
51
|
-
disabled: false,
|
|
52
|
-
};
|
|
53
|
-
export const CheckboxDisabled = (argTypes) => React.createElement(Checkbox, Object.assign({}, argTypes));
|
|
54
|
-
CheckboxDisabled.storyName = 'Checkbox заблокирован';
|
|
55
|
-
CheckboxDisabled.args = {
|
|
56
|
-
checked: false,
|
|
57
|
-
disabled: true,
|
|
58
|
-
};
|
|
59
|
-
export const CheckboxCheckedDisabled = (argTypes) => React.createElement(Checkbox, Object.assign({}, argTypes));
|
|
60
|
-
CheckboxCheckedDisabled.storyName = 'Checkbox выбран и заблокирован';
|
|
61
|
-
CheckboxCheckedDisabled.args = {
|
|
62
|
-
checked: true,
|
|
63
|
-
disabled: true,
|
|
64
|
-
};
|
|
65
|
-
export const CheckboxCustomColor = (argTypes) => React.createElement(Checkbox, Object.assign({}, argTypes));
|
|
66
|
-
CheckboxCustomColor.storyName = 'Checkbox с кастомным цветом';
|
|
67
|
-
CheckboxCustomColor.args = {
|
|
68
|
-
color: 'red',
|
|
69
|
-
};
|
|
70
|
-
export const CheckboxCustomColorFilled = (argTypes) => React.createElement(Checkbox, Object.assign({}, argTypes));
|
|
71
|
-
CheckboxCustomColorFilled.storyName = 'Checkbox с кастомным цветом заполненный';
|
|
72
|
-
CheckboxCustomColorFilled.args = {
|
|
73
|
-
color: 'red',
|
|
74
|
-
filled: true,
|
|
75
|
-
};
|
package/dist/fonts.css
DELETED
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
@import url('https://fonts.googleapis.com/css2?family=Montserrat:ital,wght@0,100..900;1,100..900&display=swap');
|
|
2
|
-
@import url('https://fonts.googleapis.com/css2?family=Open+Sans:ital,wght@0,300..800;1,300..800&display=swap');
|
|
3
|
-
:root {
|
|
4
|
-
--font-family-headers: 'Montserrat', sans-serif;
|
|
5
|
-
--font-family-content: 'Open Sans', sans-serif;
|
|
6
|
-
|
|
7
|
-
--font-size-48: 48px;
|
|
8
|
-
--font-size-36: 36px;
|
|
9
|
-
--font-size-24: 24px;
|
|
10
|
-
--font-size-20: 20px;
|
|
11
|
-
--font-size-18: 18px;
|
|
12
|
-
--font-size-16: 16px;
|
|
13
|
-
--font-size-14: 14px;
|
|
14
|
-
--font-size-12: 12px;
|
|
15
|
-
--font-size-10: 10px;
|
|
16
|
-
|
|
17
|
-
--lineHeight-48: 56px;
|
|
18
|
-
--lineHeight-36: 42px;
|
|
19
|
-
--lineHeight-24: 32px;
|
|
20
|
-
--lineHeight-20: 28px;
|
|
21
|
-
--lineHeight-18: 24px;
|
|
22
|
-
--lineHeight-16: 22px;
|
|
23
|
-
--lineHeight-14: 18px;
|
|
24
|
-
--lineHeight-12: 16px;
|
|
25
|
-
--lineHeight-10: 14px;
|
|
26
|
-
|
|
27
|
-
--font-weight-black: 900;
|
|
28
|
-
--font-weight-extraBold: 800;
|
|
29
|
-
--font-weight-bold: 700;
|
|
30
|
-
--font-weight-semiBold: 600;
|
|
31
|
-
--font-weight-medium: 500;
|
|
32
|
-
--font-weight-regular: 400;
|
|
33
|
-
--font-weight-light: 300;
|
|
34
|
-
--font-weight-extraLight: 200;
|
|
35
|
-
|
|
36
|
-
--letterSpacing: 0em;
|
|
37
|
-
}
|