@dtjoy/dt-design 1.0.0 → 1.0.2

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.
Files changed (161) hide show
  1. package/esm/_util/gapSize.d.ts +3 -0
  2. package/esm/_util/gapSize.js +10 -0
  3. package/esm/_util/hooks/index.d.ts +1 -0
  4. package/esm/_util/hooks/index.js +1 -0
  5. package/esm/_util/hooks/useOrientation.d.ts +2 -0
  6. package/esm/_util/hooks/useOrientation.js +19 -0
  7. package/esm/_util/isNonNullable.d.ts +2 -0
  8. package/esm/_util/isNonNullable.js +4 -0
  9. package/esm/_util/type.d.ts +2 -1
  10. package/esm/blockHeader/index.d.ts +1 -1
  11. package/esm/blockHeader/index.js +13 -10
  12. package/esm/blockHeader/style/index.d.ts +2 -0
  13. package/esm/blockHeader/style/index.js +2 -0
  14. package/esm/blockHeader/{style.less → style/index.less} +143 -141
  15. package/esm/button/index.d.ts +10 -0
  16. package/esm/button/index.js +29 -0
  17. package/esm/button/style/index.d.ts +2 -0
  18. package/esm/button/style/index.js +2 -0
  19. package/esm/button/style/index.less +134 -0
  20. package/esm/button/style/mixin.less +47 -0
  21. package/esm/collapsible/index.d.ts +97 -0
  22. package/esm/collapsible/index.js +234 -0
  23. package/esm/collapsible/style/index.d.ts +1 -0
  24. package/esm/collapsible/style/index.js +1 -0
  25. package/esm/collapsible/style/index.less +24 -0
  26. package/esm/collapsibleActionItems/index.d.ts +24 -0
  27. package/esm/collapsibleActionItems/index.js +74 -0
  28. package/esm/collapsibleActionItems/style/index.d.ts +2 -0
  29. package/esm/collapsibleActionItems/style/index.js +2 -0
  30. package/esm/collapsibleActionItems/style/index.less +7 -0
  31. package/esm/flex/index.d.ts +7 -0
  32. package/esm/flex/index.js +62 -0
  33. package/esm/flex/interface.d.ts +16 -0
  34. package/esm/flex/interface.js +1 -0
  35. package/esm/flex/style/index.d.ts +2 -0
  36. package/esm/flex/style/index.js +2 -0
  37. package/esm/flex/style/index.less +77 -0
  38. package/esm/flex/utils.d.ts +7 -0
  39. package/esm/flex/utils.js +33 -0
  40. package/esm/index.d.ts +10 -1
  41. package/esm/index.js +8 -7
  42. package/esm/resize/index.d.ts +8 -0
  43. package/esm/resize/index.js +29 -0
  44. package/esm/splitter/Panel.d.ts +7 -0
  45. package/esm/splitter/Panel.js +38 -0
  46. package/esm/splitter/SplitBar.d.ts +24 -0
  47. package/esm/splitter/SplitBar.js +185 -0
  48. package/esm/splitter/Splitter.d.ts +5 -0
  49. package/esm/splitter/Splitter.js +215 -0
  50. package/esm/splitter/hooks/sizeUtil.d.ts +3 -0
  51. package/esm/splitter/hooks/sizeUtil.js +63 -0
  52. package/esm/splitter/hooks/useItems.d.ts +14 -0
  53. package/esm/splitter/hooks/useItems.js +44 -0
  54. package/esm/splitter/hooks/useResizable.d.ts +10 -0
  55. package/esm/splitter/hooks/useResizable.js +73 -0
  56. package/esm/splitter/hooks/useResize.d.ts +6 -0
  57. package/esm/splitter/hooks/useResize.js +158 -0
  58. package/esm/splitter/hooks/useSizes.d.ts +4 -0
  59. package/esm/splitter/hooks/useSizes.js +80 -0
  60. package/esm/splitter/index.d.ts +8 -0
  61. package/esm/splitter/index.js +5 -0
  62. package/esm/splitter/interface.d.ts +68 -0
  63. package/esm/splitter/interface.js +1 -0
  64. package/esm/splitter/style/index.d.ts +2 -0
  65. package/esm/splitter/style/index.js +2 -0
  66. package/esm/splitter/style/index.less +312 -0
  67. package/esm/statusTag/index.d.ts +28 -0
  68. package/esm/statusTag/index.js +122 -0
  69. package/esm/statusTag/style/index.d.ts +2 -0
  70. package/esm/statusTag/style/index.js +2 -0
  71. package/esm/statusTag/style/index.less +70 -0
  72. package/esm/statusTag/style/mixin.less +39 -0
  73. package/esm/style/index.d.ts +1 -0
  74. package/esm/style/index.js +1 -0
  75. package/esm/style/index.less +1 -0
  76. package/esm/style/mixins/index.less +0 -0
  77. package/esm/style/themes/index.less +2 -0
  78. package/esm/style/themes/variable.less +1 -0
  79. package/lib/_util/gapSize.d.ts +3 -0
  80. package/lib/_util/gapSize.js +17 -0
  81. package/lib/_util/hooks/index.d.ts +1 -0
  82. package/lib/_util/hooks/index.js +16 -0
  83. package/lib/_util/hooks/useOrientation.d.ts +2 -0
  84. package/lib/_util/hooks/useOrientation.js +26 -0
  85. package/lib/_util/isNonNullable.d.ts +2 -0
  86. package/lib/_util/isNonNullable.js +10 -0
  87. package/lib/_util/type.d.ts +2 -1
  88. package/lib/blockHeader/index.d.ts +1 -1
  89. package/lib/blockHeader/index.js +13 -11
  90. package/lib/blockHeader/style/index.d.ts +2 -0
  91. package/lib/blockHeader/style/index.js +4 -0
  92. package/lib/blockHeader/{style.less → style/index.less} +143 -141
  93. package/lib/button/index.d.ts +10 -0
  94. package/lib/button/index.js +33 -0
  95. package/lib/button/style/index.d.ts +2 -0
  96. package/lib/button/style/index.js +4 -0
  97. package/lib/button/style/index.less +134 -0
  98. package/lib/button/style/mixin.less +47 -0
  99. package/lib/collapsible/index.d.ts +97 -0
  100. package/lib/collapsible/index.js +199 -0
  101. package/lib/collapsible/style/index.d.ts +1 -0
  102. package/lib/collapsible/style/index.js +3 -0
  103. package/lib/collapsible/style/index.less +24 -0
  104. package/lib/collapsibleActionItems/index.d.ts +24 -0
  105. package/lib/collapsibleActionItems/index.js +68 -0
  106. package/lib/collapsibleActionItems/style/index.d.ts +2 -0
  107. package/lib/collapsibleActionItems/style/index.js +4 -0
  108. package/lib/collapsibleActionItems/style/index.less +7 -0
  109. package/lib/flex/index.d.ts +7 -0
  110. package/lib/flex/index.js +60 -0
  111. package/lib/flex/interface.d.ts +16 -0
  112. package/lib/flex/interface.js +5 -0
  113. package/lib/flex/style/index.d.ts +2 -0
  114. package/lib/flex/style/index.js +4 -0
  115. package/lib/flex/style/index.less +77 -0
  116. package/lib/flex/utils.d.ts +7 -0
  117. package/lib/flex/utils.js +39 -0
  118. package/lib/index.d.ts +10 -1
  119. package/lib/index.js +72 -1
  120. package/lib/resize/index.d.ts +8 -0
  121. package/lib/resize/index.js +38 -0
  122. package/lib/splitter/Panel.d.ts +7 -0
  123. package/lib/splitter/Panel.js +44 -0
  124. package/lib/splitter/SplitBar.d.ts +24 -0
  125. package/lib/splitter/SplitBar.js +179 -0
  126. package/lib/splitter/Splitter.d.ts +5 -0
  127. package/lib/splitter/Splitter.js +202 -0
  128. package/lib/splitter/hooks/sizeUtil.d.ts +3 -0
  129. package/lib/splitter/hooks/sizeUtil.js +56 -0
  130. package/lib/splitter/hooks/useItems.d.ts +14 -0
  131. package/lib/splitter/hooks/useItems.js +46 -0
  132. package/lib/splitter/hooks/useResizable.d.ts +10 -0
  133. package/lib/splitter/hooks/useResizable.js +83 -0
  134. package/lib/splitter/hooks/useResize.d.ts +6 -0
  135. package/lib/splitter/hooks/useResize.js +142 -0
  136. package/lib/splitter/hooks/useSizes.d.ts +4 -0
  137. package/lib/splitter/hooks/useSizes.js +62 -0
  138. package/lib/splitter/index.d.ts +8 -0
  139. package/lib/splitter/index.js +12 -0
  140. package/lib/splitter/interface.d.ts +68 -0
  141. package/lib/splitter/interface.js +5 -0
  142. package/lib/splitter/style/index.d.ts +2 -0
  143. package/lib/splitter/style/index.js +4 -0
  144. package/lib/splitter/style/index.less +312 -0
  145. package/lib/statusTag/index.d.ts +28 -0
  146. package/lib/statusTag/index.js +125 -0
  147. package/lib/statusTag/style/index.d.ts +2 -0
  148. package/lib/statusTag/style/index.js +4 -0
  149. package/lib/statusTag/style/index.less +70 -0
  150. package/lib/statusTag/style/mixin.less +39 -0
  151. package/lib/style/index.d.ts +1 -0
  152. package/lib/style/index.js +3 -0
  153. package/lib/style/index.less +1 -0
  154. package/lib/style/mixins/index.less +0 -0
  155. package/lib/style/themes/index.less +2 -0
  156. package/lib/style/themes/variable.less +1 -0
  157. package/package.json +142 -141
  158. package/esm/styles/entry.less +0 -6
  159. package/esm/styles/variables.less +0 -1
  160. package/lib/styles/entry.less +0 -6
  161. package/lib/styles/variables.less +0 -1
package/package.json CHANGED
@@ -1,147 +1,148 @@
1
1
  {
2
- "name": "@dtjoy/dt-design",
3
- "version": "1.0.0",
4
- "description": "react-component",
5
- "repository": "https://github.com/ZhaoFxxkSky/dt-design",
6
- "main": "lib/index.js",
7
- "module": "esm/index.js",
8
- "types": "esm/index.d.ts",
9
- "scripts": {
10
- "start": "npm run dev",
11
- "dev": "dumi dev",
12
- "build": "father build",
13
- "build:watch": "father dev",
14
- "test": "jest",
15
- "docs:build": "dumi build",
16
- "prepare": "husky install && dumi setup",
17
- "doctor": "father doctor",
18
- "lint": "npm run lint:es && npm run lint:css",
19
- "lint:es-fix": "eslint \"src/**/*.{js,jsx,ts,tsx}\" \".dumi/**/*.{js,jsx,ts,tsx}\" --fix",
20
- "lint:css-fix": "stylelint \"src/**/*.{css,less,scss}\" \".dumi/**/*.{css,less,scss}\" --fix",
21
- "lint:css": "stylelint \"src/**/*.{css,less,scss}\" \".dumi/**/*.{css,less,scss}\"",
22
- "lint:es": "eslint \"src/**/*.{js,jsx,ts,tsx}\" \".dumi/**/*.{js,jsx,ts,tsx}\"",
23
- "prepublishOnly": "npm run build",
24
- "deploy": "npm run docs:build && gh-pages -d docs-dist",
25
- "release": "./scripts/release.sh"
26
- },
27
- "author": {
28
- "name": "夕颜",
29
- "email": "wx-zhaog@dtjoy.com",
30
- "url": "https://github.com/ZhaoFxxkSky/dt-design"
31
- },
32
- "license": "MIT",
33
- "files": [
34
- "lib",
35
- "esm"
36
- ],
37
- "sideEffects": [
38
- "lib/*",
39
- "*.scss",
40
- "*.less"
41
- ],
42
- "keywords": [
43
- "react",
44
- "react-component",
45
- "ui-library",
46
- "typescript",
47
- "ant-design"
48
- ],
49
- "commitlint": {
50
- "extends": [
51
- "@commitlint/config-conventional"
52
- ]
53
- },
54
- "lint-staged": {
55
- "*.{md,json}": [
56
- "prettier --write --no-error-on-unmatched-pattern"
2
+ "name": "@dtjoy/dt-design",
3
+ "version": "1.0.2",
4
+ "description": "react-component",
5
+ "repository": "https://github.com/ZhaoFxxkSky/dt-design",
6
+ "main": "lib/index.js",
7
+ "module": "esm/index.js",
8
+ "types": "esm/index.d.ts",
9
+ "scripts": {
10
+ "start": "npm run dev",
11
+ "dev": "dumi dev",
12
+ "build": "father build",
13
+ "build:watch": "father dev",
14
+ "test": "jest",
15
+ "docs:build": "dumi build",
16
+ "prepare": "husky install && dumi setup",
17
+ "doctor": "father doctor",
18
+ "lint": "npm run lint:es && npm run lint:css",
19
+ "lint:es-fix": "eslint \"src/**/*.{js,jsx,ts,tsx}\" \".dumi/**/*.{js,jsx,ts,tsx}\" --fix",
20
+ "lint:css-fix": "stylelint \"src/**/*.{css,less,scss}\" \".dumi/**/*.{css,less,scss}\" --fix",
21
+ "lint:css": "stylelint \"src/**/*.{css,less,scss}\" \".dumi/**/*.{css,less,scss}\"",
22
+ "lint:es": "eslint \"src/**/*.{js,jsx,ts,tsx}\" \".dumi/**/*.{js,jsx,ts,tsx}\"",
23
+ "prepublishOnly": "npm run build",
24
+ "deploy": "npm run docs:build && gh-pages -d docs-dist",
25
+ "release": "./scripts/release.sh"
26
+ },
27
+ "author": {
28
+ "name": "夕颜",
29
+ "email": "wx-zhaog@dtjoy.com",
30
+ "url": "https://github.com/ZhaoFxxkSky/dt-design"
31
+ },
32
+ "license": "MIT",
33
+ "files": [
34
+ "lib",
35
+ "esm"
57
36
  ],
58
- "*.{css,scss}": [
59
- "stylelint --fix"
37
+ "sideEffects": [
38
+ "esm/**/style/*",
39
+ "lib/**/style/*",
40
+ "*.less",
41
+ "**/style/*"
60
42
  ],
61
- "*.{js,jsx}": [
62
- "eslint --fix",
63
- "prettier --write"
43
+ "keywords": [
44
+ "react",
45
+ "react-component",
46
+ "ui-library",
47
+ "typescript",
48
+ "ant-design"
64
49
  ],
65
- "*.{ts,tsx}": [
66
- "eslint --fix",
67
- "prettier --parser=typescript --write"
68
- ]
69
- },
70
- "publishConfig": {
71
- "access": "public"
72
- },
73
- "peerDependencies": {
74
- "react": ">=16.9.0",
75
- "react-dom": ">=16.9.0"
76
- },
77
- "devDependencies": {
78
- "@commitlint/cli": "^17.1.2",
79
- "@commitlint/config-conventional": "^17.1.0",
80
- "@faker-js/faker": "^7.6.0",
81
- "@testing-library/jest-dom": "^5.16.5",
82
- "@testing-library/react": "^13.4.0",
83
- "@testing-library/react-hooks": "^8.0.1",
84
- "@testing-library/user-event": "^14.4.3",
85
- "@types/jest": "^29.2.3",
86
- "@types/lodash-es": "^4.17.12",
87
- "@types/node": "^24.3.1",
88
- "@types/react": "^18.0.0",
89
- "@types/react-resizable": "^3.0.8",
90
- "@types/react-syntax-highlighter": "~15.5.13",
91
- "@types/shortid": "^0.0.31",
92
- "@types/showdown": "^1.9.0",
93
- "@types/testing-library__jest-dom": "^5.14.5",
94
- "ant-design-testing": "^1.1.0",
95
- "babel-plugin-import": "^1.13.8",
96
- "cz-conventional-changelog": "^3.3.0",
97
- "dumi": "^2.2.12",
98
- "eslint": "^8.23.0",
99
- "father": "~4.1.0",
100
- "gh-pages": "^4.0.0",
101
- "husky": "^8.0.1",
102
- "jest": "^29.3.1",
103
- "jest-environment-jsdom": "^29.3.1",
104
- "ko-lint-config": "2.2.21",
105
- "lint-staged": "^13.0.3",
106
- "prettier": "^2.7.1",
107
- "rc-motion": "2.6.2",
108
- "rc-util": "^5.44.4",
109
- "react": "^18.0.0",
110
- "react-dom": "^18.0.0",
111
- "react-test-renderer": "^18.2.0",
112
- "resize-observer-polyfill": "^1.5.1",
113
- "standard-version": "^9.5.0",
114
- "stylelint": "^14.9.1",
115
- "ts-jest": "^29.0.3",
116
- "typescript": "~4.5.2"
117
- },
118
- "dependencies": {
119
- "@dtinsight/dt-utils": "^1.3.1",
120
- "@dtinsight/react-icons": "^1.0.0",
121
- "@handsontable/react": "2.1.0",
122
- "antd": "4.24.16",
123
- "classnames": "^2.2.6",
124
- "handsontable": "6.2.2",
125
- "highlight.js": "^10.5.0",
126
- "immer": "~10.1.1",
127
- "lodash-es": "^4.17.21",
128
- "rc-drawer": "~5.1.0",
129
- "rc-resize-observer": "^1.4.3",
130
- "rc-virtual-list": "^3.4.13",
131
- "react-draggable": "~4.4.6",
132
- "react-markdown": "~8.0.6",
133
- "react-resizable": "^3.0.5",
134
- "react-syntax-highlighter": "~15.5.0",
135
- "remark-gfm": "~3.0.1",
136
- "shortid": "^2.2.16",
137
- "showdown": "^1.9.0"
138
- },
139
- "config": {
140
- "commitizen": {
141
- "path": "./node_modules/cz-conventional-changelog"
50
+ "commitlint": {
51
+ "extends": [
52
+ "@commitlint/config-conventional"
53
+ ]
54
+ },
55
+ "lint-staged": {
56
+ "*.{md,json}": [
57
+ "prettier --write --no-error-on-unmatched-pattern"
58
+ ],
59
+ "*.{css,scss}": [
60
+ "stylelint --fix"
61
+ ],
62
+ "*.{js,jsx}": [
63
+ "eslint --fix",
64
+ "prettier --write"
65
+ ],
66
+ "*.{ts,tsx}": [
67
+ "eslint --fix",
68
+ "prettier --parser=typescript --write"
69
+ ]
70
+ },
71
+ "publishConfig": {
72
+ "access": "public"
73
+ },
74
+ "peerDependencies": {
75
+ "react": ">=16.9.0",
76
+ "react-dom": ">=16.9.0"
77
+ },
78
+ "devDependencies": {
79
+ "@commitlint/cli": "^17.1.2",
80
+ "@commitlint/config-conventional": "^17.1.0",
81
+ "@faker-js/faker": "^7.6.0",
82
+ "@testing-library/jest-dom": "^5.16.5",
83
+ "@testing-library/react": "^13.4.0",
84
+ "@testing-library/react-hooks": "^8.0.1",
85
+ "@testing-library/user-event": "^14.4.3",
86
+ "@types/jest": "^29.2.3",
87
+ "@types/lodash-es": "^4.17.12",
88
+ "@types/node": "^24.3.1",
89
+ "@types/react": "^18.0.0",
90
+ "@types/react-resizable": "^3.0.8",
91
+ "@types/react-syntax-highlighter": "~15.5.13",
92
+ "@types/shortid": "^0.0.31",
93
+ "@types/showdown": "^1.9.0",
94
+ "@types/testing-library__jest-dom": "^5.14.5",
95
+ "ant-design-testing": "^1.1.0",
96
+ "babel-plugin-import": "^1.13.8",
97
+ "cz-conventional-changelog": "^3.3.0",
98
+ "dumi": "^2.2.12",
99
+ "eslint": "^8.23.0",
100
+ "father": "~4.1.0",
101
+ "gh-pages": "^4.0.0",
102
+ "husky": "^8.0.1",
103
+ "jest": "^29.3.1",
104
+ "jest-environment-jsdom": "^29.3.1",
105
+ "ko-lint-config": "2.2.21",
106
+ "lint-staged": "^13.0.3",
107
+ "prettier": "^2.7.1",
108
+ "rc-motion": "2.6.2",
109
+ "rc-util": "^5.44.4",
110
+ "react": "^18.0.0",
111
+ "react-dom": "^18.0.0",
112
+ "react-test-renderer": "^18.2.0",
113
+ "resize-observer-polyfill": "^1.5.1",
114
+ "standard-version": "^9.5.0",
115
+ "stylelint": "^14.9.1",
116
+ "ts-jest": "^29.0.3",
117
+ "typescript": "~4.5.2"
118
+ },
119
+ "dependencies": {
120
+ "@dtinsight/dt-utils": "^1.3.1",
121
+ "@dtinsight/react-icons": "^1.0.0",
122
+ "@handsontable/react": "2.1.0",
123
+ "antd": "4.24.16",
124
+ "classnames": "^2.2.6",
125
+ "handsontable": "6.2.2",
126
+ "highlight.js": "^10.5.0",
127
+ "immer": "~10.1.1",
128
+ "lodash-es": "^4.17.21",
129
+ "rc-drawer": "~5.1.0",
130
+ "rc-resize-observer": "^1.4.3",
131
+ "rc-virtual-list": "^3.4.13",
132
+ "react-draggable": "~4.4.6",
133
+ "react-markdown": "~8.0.6",
134
+ "react-resizable": "^3.0.5",
135
+ "react-syntax-highlighter": "~15.5.0",
136
+ "remark-gfm": "~3.0.1",
137
+ "shortid": "^2.2.16",
138
+ "showdown": "^1.9.0"
139
+ },
140
+ "config": {
141
+ "commitizen": {
142
+ "path": "./node_modules/cz-conventional-changelog"
143
+ }
144
+ },
145
+ "resolutions": {
146
+ "rc-motion": "2.6.2"
142
147
  }
143
- },
144
- "resolutions": {
145
- "rc-motion": "2.6.2"
146
- }
147
148
  }
@@ -1,6 +0,0 @@
1
- @import "~antd/es/style/themes/default.less";
2
- @import "./variables.less";
3
-
4
- * {
5
- background: red;
6
- }
@@ -1 +0,0 @@
1
- @primary-color: red;
@@ -1,6 +0,0 @@
1
- @import "~antd/es/style/themes/default.less";
2
- @import "./variables.less";
3
-
4
- * {
5
- background: red;
6
- }
@@ -1 +0,0 @@
1
- @primary-color: red;