@bothub-chat/ui 2.61.1-fix-select-slider-e83ea77b-36d7-4f74-9c42-fba6a4967eae → 2.61.1-fix-bugs-e66b2eca-3bb1-4291-9868-6043ab56adb6
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.
|
@@ -1 +1 @@
|
|
|
1
|
-
import{jsxs as e,jsx as t}from"react/jsx-runtime";import{useState as o,useLayoutEffect as i}from"react";import"tslib";import{IconProvider as n}from"../../../../icon/context.js";import"../../../../icon/styled.js";import"@react-spring/web";import"react-markdown";import"react-dom";import"../../../../portal/styled.js";import"../../../../tooltip/styled.js";import"../../../../tooltip/arrow/styled.js";import"../../../../../theme/index.js";import"../../../../tooltip/context.js";import{Checkbox as r}from"../../../../checkbox/index.js";import{SelectFieldCheckboxGroupOptionStyled as l,SelectFieldCheckboxGroupOptionHead as c,SelectFieldCheckboxGroupOptionHeadLeftSide as s,SelectFieldCheckboxGroupOptionHeadTextWrapper as d,SelectFieldCheckboxGroupOptionHeadText as p,SelectFieldCheckboxGroupOptionHeadCounter as
|
|
1
|
+
import{jsxs as e,jsx as t}from"react/jsx-runtime";import{useState as o,useLayoutEffect as i}from"react";import"tslib";import{IconProvider as n}from"../../../../icon/context.js";import"../../../../icon/styled.js";import"@react-spring/web";import"react-markdown";import"react-dom";import"../../../../portal/styled.js";import"../../../../tooltip/styled.js";import"../../../../tooltip/arrow/styled.js";import"../../../../../theme/index.js";import"../../../../tooltip/context.js";import{Checkbox as r}from"../../../../checkbox/index.js";import{SelectFieldCheckboxGroupOptionStyled as l,SelectFieldCheckboxGroupOptionHead as c,SelectFieldCheckboxGroupOptionHeadLeftSide as s,SelectFieldCheckboxGroupOptionHeadTextWrapper as d,SelectFieldCheckboxGroupOptionHeadText as p,SelectFieldCheckboxGroupOptionHeadCounter as a,SelectFieldCheckboxGroupOptionHeadRightSide as m,SelectFieldCheckboxGroupOptionArrow as h,SelectFieldCheckboxGroupOptionContent as f,ShowMoreButton as g}from"./styled.js";import{useTheme as y}from"../../../../../theme/hook.js";const u=({item:u,value:k,size:j,data:b,onOptionClick:v,onGroupCheckboxClick:x,icon:C,SelectFieldOptions:w})=>{var z,O;const I=y(),[F,Z]=o(!1),[$,B]=o("string"!=typeof u&&(null!==(z=u.open)&&void 0!==z&&z));let D;D="string"!=typeof u&&!!u.disabled;const G="string"!=typeof u?u.open:void 0;i(()=>{"string"!=typeof u&&B(Boolean(u.open))},[G]);const P="string"==typeof u?u:null!==(O=u.label)&&void 0!==O?O:u.value,S=b.length>5,q=F?b:b.slice(0,5),A=()=>{if(!b||0===b.length)return null;const e=b.filter(e=>"string"!=typeof e),t=e.filter(e=>"selected"in e&&!0===e.selected).length,o=e.length;return 0===t?null:t===o&&o>0?"все":t},E="string"!=typeof u&&"selected"in u&&u.selected,H="string"!=typeof u&&"checkedIcon"in u&&u.checkedIcon;return e(l,{children:[e(c,Object.assign({$disabled:D},!D&&{onClick:()=>{B(e=>!e)}},{children:[e(s,{children:["object"==typeof u&&u.icon&&t(n,{size:16,fill:I.colors.base.white,children:u.icon}),e(d,{children:[t(p,{children:P}),t(a,{children:null!==A()&&`(${A()})`})]})]}),e(m,{children:[C||t(h,{style:{transform:$?"rotateZ(180deg)":"rotateZ(0deg)"}}),t("div",{onClick:e=>{e.preventDefault(),e.stopPropagation(),null==x||x(u)},children:t(r,{displayFlex:!0,checkedIcon:H,checked:E,size:16})})]})]})),$&&e(f,{children:[t(w,{value:k,data:q,size:j,onOptionClick:v}),S&&t(g,{onClick:()=>{Z(e=>!e)},children:F?"Скрыть ":"Показать "})]})]})};export{u as SelectFieldCheckboxGroupOption};
|
package/package.json
CHANGED
|
@@ -1,71 +1,71 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "@bothub-chat/ui",
|
|
3
|
-
"version": "2.61.1-fix-
|
|
4
|
-
"description": "Bothub UI Components",
|
|
5
|
-
"keywords": [
|
|
6
|
-
"bot",
|
|
7
|
-
"chat",
|
|
8
|
-
"chatgpt",
|
|
9
|
-
"ai",
|
|
10
|
-
"react"
|
|
11
|
-
],
|
|
12
|
-
"repository": {
|
|
13
|
-
"url": "https://github.com/bothubchat/bothub.git",
|
|
14
|
-
"type": "git",
|
|
15
|
-
"directory": "./packages/ui"
|
|
16
|
-
},
|
|
17
|
-
"publishConfig": {
|
|
18
|
-
"access": "public",
|
|
19
|
-
"registry": "https://registry.npmjs.org/"
|
|
20
|
-
},
|
|
21
|
-
"author": "dev2alert <atmpotn@yandex.ru>",
|
|
22
|
-
"license": "MIT",
|
|
23
|
-
"homepage": "https://bothub.chat",
|
|
24
|
-
"files": [
|
|
25
|
-
"./dist",
|
|
26
|
-
"./fonts"
|
|
27
|
-
],
|
|
28
|
-
"type": "module",
|
|
29
|
-
"main": "./dist/index.js",
|
|
30
|
-
"module": "./dist/index.js",
|
|
31
|
-
"types": "./dist/index.d.ts",
|
|
32
|
-
"exports": {
|
|
33
|
-
".": {
|
|
34
|
-
"types": "./dist/index.d.ts",
|
|
35
|
-
"import": "./dist/index.js",
|
|
36
|
-
"default": "./dist/index.js"
|
|
37
|
-
},
|
|
38
|
-
"./components/*": "./dist/components/*",
|
|
39
|
-
"./fonts/*": "./fonts/*",
|
|
40
|
-
"./utils/*": "./dist/utils/*"
|
|
41
|
-
},
|
|
42
|
-
"sideEffects": false,
|
|
43
|
-
"resolutions": {
|
|
44
|
-
"react-helmet/react": "^19.0.0"
|
|
45
|
-
},
|
|
46
|
-
"peerDependencies": {
|
|
47
|
-
"@uidotdev/usehooks": "^2.4.1",
|
|
48
|
-
"react": "^19",
|
|
49
|
-
"react-dom": "^19",
|
|
50
|
-
"react-helmet": ">=2",
|
|
51
|
-
"styled-components": "^6.0.7"
|
|
52
|
-
},
|
|
53
|
-
"dependencies": {
|
|
54
|
-
"@dnd-kit/core": "^6.1.0",
|
|
55
|
-
"@floating-ui/react": "^0.26.16",
|
|
56
|
-
"@floating-ui/react-dom": "^2.1.0",
|
|
57
|
-
"@react-spring/web": "^10",
|
|
58
|
-
"date-fns": "^3.6.0",
|
|
59
|
-
"highlight.js": "^11.11.0",
|
|
60
|
-
"katex": "^0.16.10",
|
|
61
|
-
"marked": "^16.2.1",
|
|
62
|
-
"normalize.css": "^8.0.1",
|
|
63
|
-
"rc-slider": "^11.1.8",
|
|
64
|
-
"react-markdown": "^10.0.0",
|
|
65
|
-
"rehype-katex": "^7.0.0",
|
|
66
|
-
"remark-gfm": "^4.0.1",
|
|
67
|
-
"remark-math": "^6.0.0",
|
|
68
|
-
"tslib": "^2.6.2",
|
|
69
|
-
"unist-util-visit": "^5.0.0"
|
|
70
|
-
}
|
|
71
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "@bothub-chat/ui",
|
|
3
|
+
"version": "2.61.1-fix-bugs-e66b2eca-3bb1-4291-9868-6043ab56adb6",
|
|
4
|
+
"description": "Bothub UI Components",
|
|
5
|
+
"keywords": [
|
|
6
|
+
"bot",
|
|
7
|
+
"chat",
|
|
8
|
+
"chatgpt",
|
|
9
|
+
"ai",
|
|
10
|
+
"react"
|
|
11
|
+
],
|
|
12
|
+
"repository": {
|
|
13
|
+
"url": "https://github.com/bothubchat/bothub.git",
|
|
14
|
+
"type": "git",
|
|
15
|
+
"directory": "./packages/ui"
|
|
16
|
+
},
|
|
17
|
+
"publishConfig": {
|
|
18
|
+
"access": "public",
|
|
19
|
+
"registry": "https://registry.npmjs.org/"
|
|
20
|
+
},
|
|
21
|
+
"author": "dev2alert <atmpotn@yandex.ru>",
|
|
22
|
+
"license": "MIT",
|
|
23
|
+
"homepage": "https://bothub.chat",
|
|
24
|
+
"files": [
|
|
25
|
+
"./dist",
|
|
26
|
+
"./fonts"
|
|
27
|
+
],
|
|
28
|
+
"type": "module",
|
|
29
|
+
"main": "./dist/index.js",
|
|
30
|
+
"module": "./dist/index.js",
|
|
31
|
+
"types": "./dist/index.d.ts",
|
|
32
|
+
"exports": {
|
|
33
|
+
".": {
|
|
34
|
+
"types": "./dist/index.d.ts",
|
|
35
|
+
"import": "./dist/index.js",
|
|
36
|
+
"default": "./dist/index.js"
|
|
37
|
+
},
|
|
38
|
+
"./components/*": "./dist/components/*",
|
|
39
|
+
"./fonts/*": "./fonts/*",
|
|
40
|
+
"./utils/*": "./dist/utils/*"
|
|
41
|
+
},
|
|
42
|
+
"sideEffects": false,
|
|
43
|
+
"resolutions": {
|
|
44
|
+
"react-helmet/react": "^19.0.0"
|
|
45
|
+
},
|
|
46
|
+
"peerDependencies": {
|
|
47
|
+
"@uidotdev/usehooks": "^2.4.1",
|
|
48
|
+
"react": "^19",
|
|
49
|
+
"react-dom": "^19",
|
|
50
|
+
"react-helmet": ">=2",
|
|
51
|
+
"styled-components": "^6.0.7"
|
|
52
|
+
},
|
|
53
|
+
"dependencies": {
|
|
54
|
+
"@dnd-kit/core": "^6.1.0",
|
|
55
|
+
"@floating-ui/react": "^0.26.16",
|
|
56
|
+
"@floating-ui/react-dom": "^2.1.0",
|
|
57
|
+
"@react-spring/web": "^10",
|
|
58
|
+
"date-fns": "^3.6.0",
|
|
59
|
+
"highlight.js": "^11.11.0",
|
|
60
|
+
"katex": "^0.16.10",
|
|
61
|
+
"marked": "^16.2.1",
|
|
62
|
+
"normalize.css": "^8.0.1",
|
|
63
|
+
"rc-slider": "^11.1.8",
|
|
64
|
+
"react-markdown": "^10.0.0",
|
|
65
|
+
"rehype-katex": "^7.0.0",
|
|
66
|
+
"remark-gfm": "^4.0.1",
|
|
67
|
+
"remark-math": "^6.0.0",
|
|
68
|
+
"tslib": "^2.6.2",
|
|
69
|
+
"unist-util-visit": "^5.0.0"
|
|
70
|
+
}
|
|
71
|
+
}
|