diginet-core-ui 1.4.20-beta.1 → 1.4.21
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/components/form-control/calendar/function.js +1 -1
- package/components/form-control/number-input/index2.js +1 -4
- package/components/index.js +1 -1
- package/components/tab/tab-container.js +1 -3
- package/components/tab/tab.js +1 -3
- package/global/index.js +0 -4
- package/package.json +33 -64
- package/readme.md +1022 -880
- package/components/form-control/time-picker/v2/index.js +0 -784
|
@@ -655,7 +655,7 @@ const renderNavigator = (className, refs, dbLeftFn, leftFn, rightFn, dbRightFn,
|
|
|
655
655
|
color: 'primary',
|
|
656
656
|
type: 'h3',
|
|
657
657
|
ref: refs.content,
|
|
658
|
-
format: ['
|
|
658
|
+
format: ['lowercase']
|
|
659
659
|
}))), jsx("div", {
|
|
660
660
|
className: className.navigator.around
|
|
661
661
|
}, jsx(ButtonIcon, {
|
|
@@ -49,7 +49,7 @@ const NumberInput = /*#__PURE__*/forwardRef((inProps, reference) => {
|
|
|
49
49
|
labelProps,
|
|
50
50
|
max: maxProp,
|
|
51
51
|
maxDigit,
|
|
52
|
-
min
|
|
52
|
+
min,
|
|
53
53
|
nonStyle,
|
|
54
54
|
onBlur,
|
|
55
55
|
onChange,
|
|
@@ -69,12 +69,9 @@ const NumberInput = /*#__PURE__*/forwardRef((inProps, reference) => {
|
|
|
69
69
|
viewType
|
|
70
70
|
} = props;
|
|
71
71
|
let max = maxProp;
|
|
72
|
-
let min = minProp;
|
|
73
72
|
let thousandSymbol = thousandSeparator;
|
|
74
73
|
let decimalSymbol = decimalSymbolProp;
|
|
75
74
|
let valueProps = valueProp;
|
|
76
|
-
if (!min && min !== 0) min = -Infinity;
|
|
77
|
-
if (!max && max !== 0) max = Infinity;
|
|
78
75
|
const pos = useRef(null);
|
|
79
76
|
const ref = useRef(null);
|
|
80
77
|
const globalRef = useRef({});
|
package/components/index.js
CHANGED
|
@@ -66,7 +66,7 @@ export { default as Checkbox } from "./form-control/checkbox";
|
|
|
66
66
|
export { default as DatePicker } from "./form-control/date-picker";
|
|
67
67
|
export { default as DatePickerV2 } from "./form-control/date-picker";
|
|
68
68
|
export { default as DateRangePicker } from "./form-control/date-range-picker";
|
|
69
|
-
export { default as TimePicker } from "./form-control/time-picker
|
|
69
|
+
export { default as TimePicker } from "./form-control/time-picker";
|
|
70
70
|
export { default as Dropdown } from "./form-control/dropdown";
|
|
71
71
|
export { default as DropdownBox } from "./form-control/dropdown-box";
|
|
72
72
|
export { default as FormGroup } from "./form-control/form-group";
|
|
@@ -12,7 +12,6 @@ const TabContainer = /*#__PURE__*/memo( /*#__PURE__*/forwardRef(({
|
|
|
12
12
|
className,
|
|
13
13
|
direction,
|
|
14
14
|
level,
|
|
15
|
-
onChange,
|
|
16
15
|
style,
|
|
17
16
|
tabIndex,
|
|
18
17
|
width,
|
|
@@ -51,8 +50,7 @@ const TabContainer = /*#__PURE__*/memo( /*#__PURE__*/forwardRef(({
|
|
|
51
50
|
value: {
|
|
52
51
|
tabIndexState,
|
|
53
52
|
setTabIndexState,
|
|
54
|
-
direction
|
|
55
|
-
onChange
|
|
53
|
+
direction
|
|
56
54
|
}
|
|
57
55
|
}, React.Children.map(children, child => child && /*#__PURE__*/React.cloneElement(child, {
|
|
58
56
|
level
|
package/components/tab/tab.js
CHANGED
|
@@ -28,8 +28,7 @@ const TabItem = /*#__PURE__*/memo( /*#__PURE__*/forwardRef(({
|
|
|
28
28
|
const {
|
|
29
29
|
tabIndexState,
|
|
30
30
|
setTabIndexState,
|
|
31
|
-
direction
|
|
32
|
-
onChange
|
|
31
|
+
direction
|
|
33
32
|
} = useContext(TabContext);
|
|
34
33
|
if (!reference) reference = useRef(null);
|
|
35
34
|
const ref = useRef(null);
|
|
@@ -46,7 +45,6 @@ const TabItem = /*#__PURE__*/memo( /*#__PURE__*/forwardRef(({
|
|
|
46
45
|
if (disabled) return;
|
|
47
46
|
rippleRef.current.start(e);
|
|
48
47
|
onClick ? onClick(e, index) : setTabIndexState(index);
|
|
49
|
-
onChange === null || onChange === void 0 ? void 0 : onChange(e, index);
|
|
50
48
|
};
|
|
51
49
|
useImperativeHandle(reference, () => {
|
|
52
50
|
const currentRef = ref.current || {};
|
package/global/index.js
CHANGED
|
@@ -58,8 +58,6 @@ const globalObject = {
|
|
|
58
58
|
day: 'ngày',
|
|
59
59
|
month: 'tháng',
|
|
60
60
|
year: 'năm',
|
|
61
|
-
save: 'Lưu',
|
|
62
|
-
now: 'Hiện tại',
|
|
63
61
|
// Localize
|
|
64
62
|
selectAll: 'Chọn tất cả',
|
|
65
63
|
thisFieldIsRequired: 'Trường này bắt buộc nhập',
|
|
@@ -133,8 +131,6 @@ const globalObject = {
|
|
|
133
131
|
day: 'day',
|
|
134
132
|
month: 'month',
|
|
135
133
|
year: 'year',
|
|
136
|
-
save: 'Save',
|
|
137
|
-
now: 'Now',
|
|
138
134
|
// Localize
|
|
139
135
|
selectAll: 'Select all',
|
|
140
136
|
thisFieldIsRequired: 'This field is required',
|
package/package.json
CHANGED
|
@@ -1,75 +1,44 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "diginet-core-ui",
|
|
3
|
-
"version": "1.4.
|
|
4
|
-
"description": "",
|
|
3
|
+
"version": "1.4.21",
|
|
4
|
+
"description": "The DigiNet core ui",
|
|
5
|
+
"homepage": "https://diginet.com.vn",
|
|
5
6
|
"main": "index.js",
|
|
6
|
-
"license": "UNLICENSED",
|
|
7
7
|
"scripts": {
|
|
8
|
-
"start": "
|
|
9
|
-
"start
|
|
10
|
-
"build
|
|
11
|
-
"
|
|
12
|
-
"
|
|
13
|
-
"build:darwin:linux:default": "rm -rf dist && npm run compile && sass --style=compressed src/scss:dist/css && cp -rf src/assets dist/assets",
|
|
14
|
-
"compile": "babel src --out-dir dist --ignore **/*.stories.js",
|
|
15
|
-
"pack": "npm run build && cp *.md dist/ && npm run version:bump --silent && npm run version:add --silent && cd dist && npm pack",
|
|
16
|
-
"production-keep-version": "npm run build && cp *.md dist/ && cp package.json dist/ && cd dist && npm publish",
|
|
17
|
-
"beta": "npm run build && cp *.md dist/ && cp package.json dist/ && cd dist && npm publish --tag beta",
|
|
18
|
-
"production": "npm run build && cp *.md dist/ && npm run version:bump --silent && npm run version:add --silent && cd dist && npm publish",
|
|
19
|
-
"version:add": "run-script-os",
|
|
20
|
-
"version:add:windows": "cat package.json.tmp | sed \"s/0.0.0/%npm_package_version%/g\" > dist/package.json",
|
|
21
|
-
"version:add:darwin:linux:default": "VERSION=$(npm run version:extract --silent) && cat package.json.tmp | sed \"s/0.0.0/${VERSION}/g\" > dist/package.json",
|
|
22
|
-
"version:bump": "npm version patch --no-git-tag-version --silent",
|
|
23
|
-
"version:extract": "cat package.json | grep version | head -1 | awk -F: '{ print $2 }' | sed 's/[\",]//g' | tr -d '[[:space:]]'",
|
|
24
|
-
"test": "echo \"Error: no test specified\" && exit 1",
|
|
25
|
-
"lint": "eslint --fix --config .eslintrc.js \"**/*.js\"",
|
|
26
|
-
"eslint-test": "onchange \"src/**/*.{js,jsx,json}\" -- eslint . --fix",
|
|
27
|
-
"test-storybook": "test-storybook --url http://localhost:9050"
|
|
8
|
+
"start-js": "react-scripts start --max_old_space_size=4096",
|
|
9
|
+
"start": "npx npm-run-all -p start-js",
|
|
10
|
+
"build": "GENERATE_SOURCEMAP=false && react-scripts build --env=production --max_old_space_size=8192",
|
|
11
|
+
"eject": "react-scripts eject",
|
|
12
|
+
"test": "echo \"Error: no test specified\" && exit 1"
|
|
28
13
|
},
|
|
29
14
|
"dependencies": {
|
|
30
15
|
"@emotion/core": "^10.0.35",
|
|
16
|
+
"prop-types": "^15.7.2",
|
|
31
17
|
"@emotion/css": "^11.11.0",
|
|
32
|
-
"@emotion/react": "^11.10.6"
|
|
33
|
-
"babel-plugin-module-resolver": "^4.1.0",
|
|
34
|
-
"prop-types": "^15.7.2"
|
|
18
|
+
"@emotion/react": "^11.10.6"
|
|
35
19
|
},
|
|
36
|
-
"
|
|
37
|
-
"
|
|
38
|
-
|
|
39
|
-
"git add"
|
|
40
|
-
]
|
|
20
|
+
"repository": {
|
|
21
|
+
"type": "git",
|
|
22
|
+
"url": "git+https://diginetvn@bitbucket.org/diginetvn/diginet-core-ui.git"
|
|
41
23
|
},
|
|
42
|
-
"
|
|
43
|
-
"
|
|
44
|
-
"
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
"husky": "^7.0.4",
|
|
63
|
-
"jest": "^27.5.1",
|
|
64
|
-
"lint-staged": "^12.1.2",
|
|
65
|
-
"mkdirp": "^1.0.4",
|
|
66
|
-
"npm-run-all": "^4.1.5",
|
|
67
|
-
"onchange": "^7.1.0",
|
|
68
|
-
"postcss-flexbugs-fixes": "^5.0.2",
|
|
69
|
-
"react": "^17.0.1",
|
|
70
|
-
"react-dom": "^17.0.1",
|
|
71
|
-
"rimraf": "^3.0.2",
|
|
72
|
-
"run-script-os": "^1.1.6",
|
|
73
|
-
"sass": "1.58.3"
|
|
74
|
-
}
|
|
24
|
+
"keywords": [
|
|
25
|
+
"core ui",
|
|
26
|
+
"diginet"
|
|
27
|
+
],
|
|
28
|
+
"author": "rocachien",
|
|
29
|
+
"contributors": [
|
|
30
|
+
{
|
|
31
|
+
"name": "Chien Do",
|
|
32
|
+
"email": "rocachien@gmail.com"
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
"name": "Nhat Tran",
|
|
36
|
+
"email": "tranminhnhat1005@gmail.com"
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
"name": "Thuan Nguyen",
|
|
40
|
+
"email": "nt.thuan.hutech@gmail.com"
|
|
41
|
+
}
|
|
42
|
+
],
|
|
43
|
+
"license": "MIT"
|
|
75
44
|
}
|