@trionesdev/antd-taro-react 0.0.2-beta.2 → 0.0.2-beta.20
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/LICENSE +21 -21
- package/dist/ActionSheet/ActionSheet.d.ts +25 -0
- package/dist/ActionSheet/ActionSheet.js +77 -0
- package/dist/ActionSheet/index.d.ts +1 -1
- package/dist/ActionSheet/index.js +1 -1
- package/dist/ActionSheet/style.scss +52 -0
- package/dist/Button/button.d.ts +2 -1
- package/dist/Button/button.js +2 -3
- package/dist/Button/style.scss +246 -231
- package/dist/Calendar/calendar-grid.d.ts +10 -9
- package/dist/Calendar/calendar-grid.js +37 -62
- package/dist/Calendar/calendar-header.d.ts +3 -2
- package/dist/Calendar/calendar-header.js +9 -6
- package/dist/Calendar/calendar-range.d.ts +4 -3
- package/dist/Calendar/calendar-range.js +22 -18
- package/dist/Calendar/calendar.d.ts +5 -4
- package/dist/Calendar/calendar.js +30 -17
- package/dist/Calendar/style.scss +88 -85
- package/dist/Calendar/touchable-calendar-grid.d.ts +6 -5
- package/dist/Calendar/touchable-calendar-grid.js +96 -95
- package/dist/CalendarDatetimePicker/CalendarDatetimePicker.d.ts +3 -2
- package/dist/CalendarDatetimePicker/CalendarDatetimePicker.js +40 -57
- package/dist/CalendarDatetimePicker/DateTimeSwitch.d.ts +3 -2
- package/dist/CalendarDatetimePicker/DateTimeSwitch.js +2 -2
- package/dist/CalendarDatetimePicker/style.scss +62 -54
- package/dist/CalendarDatetimePickerCell/CalendarDatetimePickerCell.d.ts +9 -0
- package/dist/CalendarDatetimePickerCell/CalendarDatetimePickerCell.js +60 -0
- package/dist/CalendarDatetimePickerCell/index.d.ts +3 -0
- package/dist/CalendarDatetimePickerCell/index.js +2 -0
- package/dist/CalendarPicker/{calendar-picker.js → CalendarPicker.js} +10 -6
- package/dist/CalendarPicker/{calendar-range-picker.js → CalendarRangePicker.js} +8 -6
- package/dist/CalendarPicker/index.d.ts +3 -4
- package/dist/CalendarPicker/index.js +2 -2
- package/dist/CalendarPicker/style.scss +32 -31
- package/dist/CalendarPicker/types.d.ts +8 -6
- package/dist/CalendarPicker/types.js +1 -1
- package/dist/CalendarPickerCell/CalendarPickerCell.d.ts +11 -0
- package/dist/CalendarPickerCell/CalendarPickerCell.js +54 -0
- package/dist/CalendarPickerCell/CalendarRangePickerCell.d.ts +11 -0
- package/dist/CalendarPickerCell/CalendarRangePickerCell.js +56 -0
- package/dist/CalendarPickerCell/index.d.ts +8 -0
- package/dist/CalendarPickerCell/index.js +5 -0
- package/dist/CascaderPicker/cascader-picker.d.ts +27 -0
- package/dist/CascaderPicker/cascader-picker.js +90 -0
- package/dist/CascaderPicker/index.d.ts +1 -1
- package/dist/CascaderPicker/index.js +1 -1
- package/dist/CascaderPicker/style.scss +45 -0
- package/dist/CascaderPickerCell/CascaderPickerCell.d.ts +20 -0
- package/dist/CascaderPickerCell/CascaderPickerCell.js +70 -0
- package/dist/CascaderPickerCell/index.d.ts +3 -0
- package/dist/CascaderPickerCell/index.js +2 -0
- package/dist/DatePicker/DatePicker.d.ts +18 -0
- package/dist/DatePicker/DatePicker.js +310 -0
- package/dist/DatePicker/index.d.ts +4 -0
- package/dist/DatePicker/index.js +3 -0
- package/dist/DatePicker/style.scss +41 -0
- package/dist/DatePicker/types.d.ts +1 -0
- package/dist/DatePicker/types.js +1 -0
- package/dist/DatePickerCell/DatePickerCell.d.ts +16 -0
- package/dist/DatePickerCell/DatePickerCell.js +78 -0
- package/dist/DatePickerCell/index.d.ts +3 -0
- package/dist/DatePickerCell/index.js +2 -0
- package/dist/FetchPicker/FetchPicker.d.ts +78 -0
- package/dist/FetchPicker/FetchPicker.js +310 -0
- package/dist/FetchPicker/index.d.ts +4 -0
- package/dist/FetchPicker/index.js +3 -0
- package/dist/FetchPicker/styles.scss +130 -0
- package/dist/FloatButton/FloatButton.d.ts +19 -0
- package/dist/FloatButton/FloatButton.js +60 -0
- package/dist/FloatButton/FloatButtonGroup.d.ts +21 -0
- package/dist/FloatButton/FloatButtonGroup.js +141 -0
- package/dist/FloatButton/context.d.ts +10 -0
- package/dist/FloatButton/context.js +2 -0
- package/dist/FloatButton/index.d.ts +10 -0
- package/dist/FloatButton/index.js +5 -0
- package/dist/FloatButton/style.scss +126 -0
- package/dist/Form/FormItem/form-item-content.d.ts +17 -0
- package/dist/Form/FormItem/form-item-content.js +39 -0
- package/dist/Form/FormItem/form-item-label.d.ts +13 -0
- package/dist/Form/FormItem/form-item-label.js +29 -0
- package/dist/Form/FormItem/form-item.d.ts +23 -0
- package/dist/Form/FormItem/form-item.js +77 -0
- package/dist/Form/FormItem/index.d.ts +5 -0
- package/dist/Form/FormItem/index.js +3 -0
- package/dist/Form/index.d.ts +9 -2
- package/dist/Form/index.js +5 -1
- package/dist/Form/style.scss +100 -0
- package/dist/FormCell/index.d.ts +3 -0
- package/dist/FormCell/index.js +2 -0
- package/dist/ImagesPreview/ImagesPreview.js +4 -3
- package/dist/ImagesPreview/style.scss +34 -34
- package/dist/ImagesWall/ImagesWall.js +1 -1
- package/dist/ImagesWall/style.scss +70 -70
- package/dist/Input/index.d.ts +17 -2
- package/dist/Input/index.js +13 -1
- package/dist/Input/index.scss +282 -0
- package/dist/Input/input-affix-wrapper.d.ts +13 -0
- package/dist/Input/input-affix-wrapper.js +37 -0
- package/dist/Input/input-digit.d.ts +7 -0
- package/dist/Input/input-digit.js +53 -0
- package/dist/Input/input-number.d.ts +7 -0
- package/dist/Input/input-number.js +50 -0
- package/dist/Input/input-opt.d.ts +16 -0
- package/dist/Input/input-opt.js +87 -0
- package/dist/Input/input-password.d.ts +8 -0
- package/dist/Input/input-password.js +49 -0
- package/dist/Input/input.d.ts +3 -0
- package/dist/Input/input.js +7 -0
- package/dist/Input/taro-input.d.ts +8 -0
- package/dist/Input/taro-input.js +70 -0
- package/dist/Input/textarea.d.ts +15 -0
- package/dist/Input/textarea.js +52 -0
- package/dist/Input/types.d.ts +20 -0
- package/dist/Input/types.js +2 -0
- package/dist/Loading/index.d.ts +4 -0
- package/dist/Loading/index.js +3 -0
- package/dist/Overlay/Overlay.d.ts +17 -0
- package/dist/Overlay/Overlay.js +100 -0
- package/dist/Overlay/index.d.ts +4 -0
- package/dist/Overlay/index.js +3 -0
- package/dist/Overlay/style.scss +20 -0
- package/dist/Picker/Picker.d.ts +27 -0
- package/dist/Picker/Picker.js +100 -0
- package/dist/Picker/index.d.ts +1 -1
- package/dist/Picker/index.js +1 -1
- package/dist/Picker/style.scss +41 -0
- package/dist/PickerView/PickerView.d.ts +4 -0
- package/dist/PickerView/PickerView.js +71 -0
- package/dist/PickerView/index.d.ts +2 -2
- package/dist/PickerView/index.js +1 -1
- package/dist/PickerView/style.scss +13 -0
- package/dist/PickerView/types.d.ts +15 -0
- package/dist/PickerView/types.js +1 -0
- package/dist/Popup/Popup.d.ts +48 -0
- package/dist/Popup/Popup.js +135 -0
- package/dist/Popup/index.d.ts +2 -1
- package/dist/Popup/index.js +2 -1
- package/dist/Popup/style.scss +126 -0
- package/dist/Progress/index.d.ts +1 -1
- package/dist/Progress/index.js +1 -1
- package/dist/Segmented/index.d.ts +3 -0
- package/dist/Segmented/index.js +2 -0
- package/dist/SideBar/side-bar.js +9 -8
- package/dist/SideBar/style.scss +85 -85
- package/dist/Stepper/index.d.ts +3 -0
- package/dist/Stepper/index.js +2 -0
- package/dist/Toast/Toast.d.ts +18 -0
- package/dist/Toast/Toast.js +112 -0
- package/dist/Toast/index.d.ts +1 -1
- package/dist/Toast/index.js +1 -1
- package/dist/Toast/style.scss +63 -0
- package/dist/VerificationCodeInput/index.d.ts +2 -2
- package/dist/VerificationCodeInput/index.js +1 -1
- package/dist/VerificationCodeInput/style.scss +20 -0
- package/dist/VerificationCodeInput/verification-code-input.d.ts +24 -0
- package/dist/VerificationCodeInput/verification-code-input.js +99 -0
- package/dist/index.d.ts +28 -7
- package/dist/index.js +12 -2
- package/dist/style/variable.scss +34 -1
- package/dist/types.d.ts +0 -1
- package/dist/utils/dayjs.d.ts +4 -0
- package/dist/utils/dayjs.js +42 -0
- package/package.json +25 -30
- package/readme.md +23 -23
- package/dist/Mask/index.d.ts +0 -3
- package/dist/Mask/index.js +0 -2
- package/dist/Progress/Progress.d.ts +0 -38
- package/dist/Progress/Progress.js +0 -53
- package/dist/Progress/ProgressCircle.d.ts +0 -16
- package/dist/Progress/ProgressCircle.js +0 -147
- package/dist/Progress/ProgressLine.d.ts +0 -15
- package/dist/Progress/ProgressLine.js +0 -87
- package/dist/Progress/style.scss +0 -33
- package/dist/Progress/types.d.ts +0 -4
- package/dist/Progress/types.js +0 -2
- package/dist/SpinLoading/index.d.ts +0 -3
- package/dist/SpinLoading/index.js +0 -2
- /package/dist/CalendarPicker/{calendar-picker.d.ts → CalendarPicker.d.ts} +0 -0
- /package/dist/CalendarPicker/{calendar-range-picker.d.ts → CalendarRangePicker.d.ts} +0 -0
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
@use "../style/variable" as variable;
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
$cls-prefix-form-item: 'triones-antm-form-item';
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
.#{$cls-prefix-form-item} {
|
|
8
|
+
&.h5 {
|
|
9
|
+
@include variable.h5-line-height;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
&.wx {
|
|
13
|
+
@include variable.wx-input-size;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
&-label {
|
|
17
|
+
font-size: variable.$trionesFontSize;
|
|
18
|
+
color: #6F6F6F;
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
&-wrapper {
|
|
22
|
+
//display: flex;
|
|
23
|
+
//align-items: center;
|
|
24
|
+
height: 100%;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
&-required-mark {
|
|
28
|
+
display: inline-block;
|
|
29
|
+
color: variable.$trionesColorError;
|
|
30
|
+
width: 8Px;
|
|
31
|
+
margin-left: -8Px;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
&-content {
|
|
37
|
+
|
|
38
|
+
&-end {
|
|
39
|
+
text-align: end;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
.#{$cls-prefix-form-item} {
|
|
43
|
+
&-error {
|
|
44
|
+
font-size: variable.$trionesFontSizeSm;
|
|
45
|
+
color: variable.$trionesColorError;
|
|
46
|
+
line-height: normal;
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
&-horizontal {
|
|
52
|
+
display: flex;
|
|
53
|
+
|
|
54
|
+
.#{$cls-prefix-form-item} {
|
|
55
|
+
&-label {
|
|
56
|
+
padding-block: 12Px;
|
|
57
|
+
flex-shrink: 1;
|
|
58
|
+
min-width: 0;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
&-content {
|
|
62
|
+
padding-block: 12Px;
|
|
63
|
+
flex: 1;
|
|
64
|
+
flex-shrink: 1;
|
|
65
|
+
min-width: 0;
|
|
66
|
+
|
|
67
|
+
&-end {
|
|
68
|
+
text-align: end;
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
&.#{$cls-prefix-form-item} {
|
|
74
|
+
&-start {
|
|
75
|
+
align-items: flex-start;
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
&-center {
|
|
79
|
+
//align-items: center;
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
&-vertical {
|
|
85
|
+
.#{$cls-prefix-form-item} {
|
|
86
|
+
&-label {
|
|
87
|
+
margin-bottom: 4Px;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
&-content {
|
|
91
|
+
padding-block-end: 8Px;
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
&-hidden {
|
|
98
|
+
display: none;
|
|
99
|
+
}
|
|
100
|
+
}
|
|
@@ -5,11 +5,11 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
|
|
|
5
5
|
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
6
6
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
7
7
|
import React, { useEffect } from "react";
|
|
8
|
-
import Mask from "../Mask";
|
|
9
8
|
import classNames from "classnames";
|
|
10
9
|
import "./style.scss";
|
|
11
10
|
import Swiper from "../Swiper";
|
|
12
11
|
import Image from "../Image";
|
|
12
|
+
import Overlay from "../Overlay";
|
|
13
13
|
var cls = 'triones-antm-image-preview';
|
|
14
14
|
export var ImagesPreview = function ImagesPreview(_ref) {
|
|
15
15
|
var className = _ref.className,
|
|
@@ -46,7 +46,7 @@ export var ImagesPreview = function ImagesPreview(_ref) {
|
|
|
46
46
|
}
|
|
47
47
|
setInnerActiveIndex(activeIndex);
|
|
48
48
|
}, [activeIndex]);
|
|
49
|
-
return /*#__PURE__*/React.createElement(
|
|
49
|
+
return /*#__PURE__*/React.createElement(Overlay, {
|
|
50
50
|
open: innerOpen
|
|
51
51
|
}, /*#__PURE__*/React.createElement("div", {
|
|
52
52
|
className: classNames(cls, className),
|
|
@@ -62,8 +62,9 @@ export var ImagesPreview = function ImagesPreview(_ref) {
|
|
|
62
62
|
width: '100%',
|
|
63
63
|
height: '100%'
|
|
64
64
|
}
|
|
65
|
-
}, items === null || items === void 0 ? void 0 : items.map(function (item) {
|
|
65
|
+
}, items === null || items === void 0 ? void 0 : items.map(function (item, index) {
|
|
66
66
|
return /*#__PURE__*/React.createElement(Swiper.Item, {
|
|
67
|
+
key: index,
|
|
67
68
|
style: {
|
|
68
69
|
width: '100%',
|
|
69
70
|
height: '100%',
|
|
@@ -1,34 +1,34 @@
|
|
|
1
|
-
$imagePreviewCls: 'triones-antm-image-preview';
|
|
2
|
-
|
|
3
|
-
.#{$imagePreviewCls} {
|
|
4
|
-
height: 100%;
|
|
5
|
-
width: 100%;
|
|
6
|
-
position: relative;
|
|
7
|
-
background-color: rgba(0, 0, 0, 0.8);
|
|
8
|
-
|
|
9
|
-
&-head {
|
|
10
|
-
position: fixed;
|
|
11
|
-
top: 50Px;
|
|
12
|
-
left: 0;
|
|
13
|
-
right: 0;
|
|
14
|
-
display: flex;
|
|
15
|
-
justify-content: center;
|
|
16
|
-
align-items: center;
|
|
17
|
-
color: white;
|
|
18
|
-
font-size: 14Px;
|
|
19
|
-
z-index: 1000;
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
&-content {
|
|
23
|
-
height: 100%;
|
|
24
|
-
width: 100%;
|
|
25
|
-
:global{
|
|
26
|
-
.triones-antm-image-img{
|
|
27
|
-
height: auto!important;
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
&-foot {
|
|
33
|
-
}
|
|
34
|
-
}
|
|
1
|
+
$imagePreviewCls: 'triones-antm-image-preview';
|
|
2
|
+
|
|
3
|
+
.#{$imagePreviewCls} {
|
|
4
|
+
height: 100%;
|
|
5
|
+
width: 100%;
|
|
6
|
+
position: relative;
|
|
7
|
+
background-color: rgba(0, 0, 0, 0.8);
|
|
8
|
+
|
|
9
|
+
&-head {
|
|
10
|
+
position: fixed;
|
|
11
|
+
top: 50Px;
|
|
12
|
+
left: 0;
|
|
13
|
+
right: 0;
|
|
14
|
+
display: flex;
|
|
15
|
+
justify-content: center;
|
|
16
|
+
align-items: center;
|
|
17
|
+
color: white;
|
|
18
|
+
font-size: 14Px;
|
|
19
|
+
z-index: 1000;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
&-content {
|
|
23
|
+
height: 100%;
|
|
24
|
+
width: 100%;
|
|
25
|
+
:global{
|
|
26
|
+
.triones-antm-image-img{
|
|
27
|
+
height: auto!important;
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
&-foot {
|
|
33
|
+
}
|
|
34
|
+
}
|
|
@@ -82,7 +82,7 @@ export var ImagesWall = function ImagesWall(_ref2) {
|
|
|
82
82
|
}
|
|
83
83
|
setImages(newImages || []);
|
|
84
84
|
}, [value]);
|
|
85
|
-
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(ImagesPreview, {
|
|
85
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, preview && /*#__PURE__*/React.createElement(ImagesPreview, {
|
|
86
86
|
open: imagePreviewOpen,
|
|
87
87
|
afterOpenChange: setImagePreviewOpen,
|
|
88
88
|
items: images.map(function (item) {
|
|
@@ -1,70 +1,70 @@
|
|
|
1
|
-
@use "../style/variable" as variable;
|
|
2
|
-
|
|
3
|
-
$imagesWallCls: 'triones-antm-images-wall';
|
|
4
|
-
|
|
5
|
-
.#{$imagesWallCls} {
|
|
6
|
-
display: grid;
|
|
7
|
-
grid-gap: 4PX;
|
|
8
|
-
width: 100%;
|
|
9
|
-
|
|
10
|
-
&-item {
|
|
11
|
-
aspect-ratio: 1;
|
|
12
|
-
border-radius: variable.$trionesBorderRadius;
|
|
13
|
-
overflow: hidden;
|
|
14
|
-
position: relative;
|
|
15
|
-
|
|
16
|
-
&-inner {
|
|
17
|
-
width: 100%;
|
|
18
|
-
height: 100%;
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
&-close {
|
|
22
|
-
position: absolute;
|
|
23
|
-
top: 0;
|
|
24
|
-
right: 0;
|
|
25
|
-
background-color: rgb(0 0 0 / 63%);
|
|
26
|
-
width: 20Px;
|
|
27
|
-
height: 20Px;
|
|
28
|
-
border-bottom-left-radius: variable.$trionesBorderRadius;
|
|
29
|
-
display: flex;
|
|
30
|
-
justify-content: center;
|
|
31
|
-
align-items: center;
|
|
32
|
-
|
|
33
|
-
.triones-antm-icon {
|
|
34
|
-
color: white;
|
|
35
|
-
font-size: 12Px;
|
|
36
|
-
}
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
&-input {
|
|
40
|
-
position: absolute;
|
|
41
|
-
width: 100%;
|
|
42
|
-
height: 100%;
|
|
43
|
-
top: 0;
|
|
44
|
-
left: 0;
|
|
45
|
-
margin: 0;
|
|
46
|
-
padding: 0;
|
|
47
|
-
z-index: 1;
|
|
48
|
-
opacity: 0;
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
&-image {
|
|
52
|
-
width: 100%;
|
|
53
|
-
height: 100%;
|
|
54
|
-
object-fit: cover;
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
&-upload {
|
|
59
|
-
display: flex;
|
|
60
|
-
justify-content: center;
|
|
61
|
-
align-items: center;
|
|
62
|
-
background-color: variable.$trionesColorBgTextActive;
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
&-action-sheet {
|
|
66
|
-
|
|
67
|
-
}
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
|
|
1
|
+
@use "../style/variable" as variable;
|
|
2
|
+
|
|
3
|
+
$imagesWallCls: 'triones-antm-images-wall';
|
|
4
|
+
|
|
5
|
+
.#{$imagesWallCls} {
|
|
6
|
+
display: grid;
|
|
7
|
+
grid-gap: 4PX;
|
|
8
|
+
width: 100%;
|
|
9
|
+
|
|
10
|
+
&-item {
|
|
11
|
+
aspect-ratio: 1;
|
|
12
|
+
border-radius: variable.$trionesBorderRadius;
|
|
13
|
+
overflow: hidden;
|
|
14
|
+
position: relative;
|
|
15
|
+
|
|
16
|
+
&-inner {
|
|
17
|
+
width: 100%;
|
|
18
|
+
height: 100%;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
&-close {
|
|
22
|
+
position: absolute;
|
|
23
|
+
top: 0;
|
|
24
|
+
right: 0;
|
|
25
|
+
background-color: rgb(0 0 0 / 63%);
|
|
26
|
+
width: 20Px;
|
|
27
|
+
height: 20Px;
|
|
28
|
+
border-bottom-left-radius: variable.$trionesBorderRadius;
|
|
29
|
+
display: flex;
|
|
30
|
+
justify-content: center;
|
|
31
|
+
align-items: center;
|
|
32
|
+
|
|
33
|
+
.triones-antm-icon {
|
|
34
|
+
color: white;
|
|
35
|
+
font-size: 12Px;
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
&-input {
|
|
40
|
+
position: absolute;
|
|
41
|
+
width: 100%;
|
|
42
|
+
height: 100%;
|
|
43
|
+
top: 0;
|
|
44
|
+
left: 0;
|
|
45
|
+
margin: 0;
|
|
46
|
+
padding: 0;
|
|
47
|
+
z-index: 1;
|
|
48
|
+
opacity: 0;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
&-image {
|
|
52
|
+
width: 100%;
|
|
53
|
+
height: 100%;
|
|
54
|
+
object-fit: cover;
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
&-upload {
|
|
59
|
+
display: flex;
|
|
60
|
+
justify-content: center;
|
|
61
|
+
align-items: center;
|
|
62
|
+
background-color: variable.$trionesColorBgTextActive;
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
&-action-sheet {
|
|
66
|
+
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
|
package/dist/Input/index.d.ts
CHANGED
|
@@ -1,3 +1,18 @@
|
|
|
1
|
-
import { Input
|
|
2
|
-
|
|
1
|
+
import { Input as InternalInput } from "./input";
|
|
2
|
+
import { InputDigit, InputDigitProps } from "./input-digit";
|
|
3
|
+
import { InputNumber, InputNumberProps } from "./input-number";
|
|
4
|
+
import { InputPassword, InputPasswordProps } from "./input-password";
|
|
5
|
+
import { Textarea, InputTextareaProps } from "./textarea";
|
|
6
|
+
import "./index.scss";
|
|
7
|
+
import { InputOPT, InputOPTProps } from "./input-opt";
|
|
8
|
+
import { InputProps } from "./types";
|
|
9
|
+
type CompoundedComponent = typeof InternalInput & {
|
|
10
|
+
Password: typeof InputPassword;
|
|
11
|
+
OPT: typeof InputOPT;
|
|
12
|
+
Digit: typeof InputDigit;
|
|
13
|
+
Number: typeof InputNumber;
|
|
14
|
+
Textarea: typeof Textarea;
|
|
15
|
+
};
|
|
16
|
+
declare const Input: CompoundedComponent;
|
|
17
|
+
export type { InputOPTProps, InputPasswordProps, InputProps, InputTextareaProps, InputDigitProps, InputNumberProps };
|
|
3
18
|
export default Input;
|
package/dist/Input/index.js
CHANGED
|
@@ -1,2 +1,14 @@
|
|
|
1
|
-
import { Input } from "
|
|
1
|
+
import { Input as InternalInput } from "./input";
|
|
2
|
+
import { InputDigit } from "./input-digit";
|
|
3
|
+
import { InputNumber } from "./input-number";
|
|
4
|
+
import { InputPassword } from "./input-password";
|
|
5
|
+
import { Textarea } from "./textarea";
|
|
6
|
+
import "./index.scss";
|
|
7
|
+
import { InputOPT } from "./input-opt";
|
|
8
|
+
var Input = InternalInput;
|
|
9
|
+
Input.Password = InputPassword;
|
|
10
|
+
Input.OPT = InputOPT;
|
|
11
|
+
Input.Digit = InputDigit;
|
|
12
|
+
Input.Number = InputNumber;
|
|
13
|
+
Input.Textarea = Textarea;
|
|
2
14
|
export default Input;
|
|
@@ -0,0 +1,282 @@
|
|
|
1
|
+
@use "../style/variable" as variable;
|
|
2
|
+
|
|
3
|
+
$inputCls: 'triones-antm-input';
|
|
4
|
+
$inputAffixWrapperCls: 'triones-antm-input-affix-wrapper';
|
|
5
|
+
$inputGroupWrapperCls: 'triones-antm-input-group-wrapper';
|
|
6
|
+
$inputPotCls: 'triones-antm-pot';
|
|
7
|
+
|
|
8
|
+
$inputSm: 24Px;
|
|
9
|
+
$inputMd: 32Px;
|
|
10
|
+
$inputLg: 40Px;
|
|
11
|
+
|
|
12
|
+
$placeholderColor: variable.$trionesColorTextPlaceholder;
|
|
13
|
+
|
|
14
|
+
input {
|
|
15
|
+
height: auto;
|
|
16
|
+
font-size: variable.$trionesInputInputFontSize;
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
&::placeholder {
|
|
20
|
+
font-size: variable.$trionesInputInputFontSize;
|
|
21
|
+
color: $placeholderColor
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
wx-input {
|
|
26
|
+
&::placeholder {
|
|
27
|
+
font-size: variable.$trionesInputInputFontSize;
|
|
28
|
+
color: $placeholderColor
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
.#{$inputCls} {
|
|
33
|
+
box-sizing: border-box;
|
|
34
|
+
display: inline-block;
|
|
35
|
+
position: relative;
|
|
36
|
+
width: 100%;
|
|
37
|
+
min-width: 0;
|
|
38
|
+
transition: all .2s;
|
|
39
|
+
outline: none;
|
|
40
|
+
box-shadow: none;
|
|
41
|
+
border: none;
|
|
42
|
+
border-radius: variable.$trionesBorderRadius;
|
|
43
|
+
font-size: variable.$trionesInputInputFontSize;
|
|
44
|
+
|
|
45
|
+
&-small {
|
|
46
|
+
padding: variable.$trionesInputPaddingBlockSm 0;
|
|
47
|
+
font-size: variable.$trionesInputInputFontSizeSm;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
&-large {
|
|
51
|
+
padding: variable.$trionesInputPaddingBlockLg 0;
|
|
52
|
+
font-size: variable.$trionesInputInputFontSizeLg;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
&::placeholder {
|
|
56
|
+
font-size: variable.$trionesInputInputFontSize;
|
|
57
|
+
color: $placeholderColor
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
.weui-input {
|
|
61
|
+
&::placeholder {
|
|
62
|
+
font-size: variable.$trionesInputInputFontSize;
|
|
63
|
+
color: $placeholderColor
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
|
|
69
|
+
.#{$inputAffixWrapperCls} {
|
|
70
|
+
box-sizing: border-box;
|
|
71
|
+
position: relative;
|
|
72
|
+
display: inline-flex;
|
|
73
|
+
align-items: center;
|
|
74
|
+
width: 100%;
|
|
75
|
+
min-width: 0;
|
|
76
|
+
flex-shrink: 1;
|
|
77
|
+
//line-height: variable.$trionesLineHeight;
|
|
78
|
+
//padding: variable.$trionesInputPaddingBlock 0;
|
|
79
|
+
gap: 4Px;
|
|
80
|
+
|
|
81
|
+
|
|
82
|
+
&-small {
|
|
83
|
+
padding: variable.$trionesInputPaddingBlockSm 0;
|
|
84
|
+
font-size: variable.$trionesInputInputFontSizeSm;
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
&-large {
|
|
88
|
+
padding: variable.$trionesInputPaddingBlockLg 0;
|
|
89
|
+
font-size: variable.$trionesInputInputFontSizeLg;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
|
|
93
|
+
|
|
94
|
+
.#{$inputCls} {
|
|
95
|
+
padding: 0;
|
|
96
|
+
background-color: transparent;
|
|
97
|
+
height: 100%;
|
|
98
|
+
|
|
99
|
+
|
|
100
|
+
&-prifix {}
|
|
101
|
+
|
|
102
|
+
&-suffix {
|
|
103
|
+
display: inline-flex;
|
|
104
|
+
align-items: center;
|
|
105
|
+
vertical-align: middle;
|
|
106
|
+
flex-shrink: 0;
|
|
107
|
+
row-gap: 4Px;
|
|
108
|
+
// padding-inline: 4Px;
|
|
109
|
+
line-height: normal;
|
|
110
|
+
|
|
111
|
+
.clear-icon {
|
|
112
|
+
color: rgba(0, 0, 0, 0.25);
|
|
113
|
+
|
|
114
|
+
|
|
115
|
+
&:hover {
|
|
116
|
+
color: rgba(0, 0, 0, 0.45);
|
|
117
|
+
}
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
.triones-antm-icon {
|
|
121
|
+
cursor: pointer;
|
|
122
|
+
padding-inline: 4Px;
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
taro-input-core {
|
|
128
|
+
&::placeholder {
|
|
129
|
+
font-size: variable.$trionesInputInputFontSize;
|
|
130
|
+
color: $placeholderColor
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
|
|
134
|
+
.weui-input {
|
|
135
|
+
&::placeholder {
|
|
136
|
+
font-size: variable.$trionesInputInputFontSize;
|
|
137
|
+
color: $placeholderColor
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
|
|
143
|
+
.triones-antm-icon {
|
|
144
|
+
font-size: 14Px;
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
.#{$inputCls} {
|
|
150
|
+
&-outlined {
|
|
151
|
+
border-radius: variable.$trionesBorderRadius;
|
|
152
|
+
border: 1Px solid variable.$trionesBorderColor;
|
|
153
|
+
padding-block: variable.$trionesInputPaddingBlock;
|
|
154
|
+
padding-inline: variable.$trionesInputPaddingBlock;
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
&-filled {
|
|
158
|
+
border-radius: variable.$trionesBorderRadius;
|
|
159
|
+
background-color: variable.$trionesColorFillTertiary;
|
|
160
|
+
padding-block: variable.$trionesInputPaddingBlock;
|
|
161
|
+
padding-inline: variable.$trionesInputPaddingBlock;
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
&-underlined {
|
|
165
|
+
border-bottom: 1Px solid variable.$trionesBorderColor;
|
|
166
|
+
padding-block: variable.$trionesInputPaddingBlock;
|
|
167
|
+
}
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
.#{$inputGroupWrapperCls} {}
|
|
171
|
+
|
|
172
|
+
|
|
173
|
+
.#{$inputPotCls} {
|
|
174
|
+
position: relative;
|
|
175
|
+
display: inline-flex;
|
|
176
|
+
vertical-align: middle;
|
|
177
|
+
|
|
178
|
+
&-wrapper {
|
|
179
|
+
position: relative;
|
|
180
|
+
display: inline-flex;
|
|
181
|
+
align-items: center;
|
|
182
|
+
flex-wrap: nowrap;
|
|
183
|
+
column-gap: 8Px;
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
&-input {
|
|
187
|
+
position: absolute;
|
|
188
|
+
background-color: transparent;
|
|
189
|
+
z-index: -1;
|
|
190
|
+
left: 0;
|
|
191
|
+
top: 0;
|
|
192
|
+
right: 0;
|
|
193
|
+
bottom: 0;
|
|
194
|
+
opacity: 0;
|
|
195
|
+
-moz-appearance: textfield;
|
|
196
|
+
|
|
197
|
+
&::-webkit-outer-spin-button,
|
|
198
|
+
&::-webkit-inner-spin-button {
|
|
199
|
+
-webkit-appearance: none;
|
|
200
|
+
margin: 0;
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
|
|
204
|
+
&-item {
|
|
205
|
+
text-align: center;
|
|
206
|
+
font-size: variable.$trionesInputInputFontSize;
|
|
207
|
+
height: variable.$trionesControlHeight;
|
|
208
|
+
width: variable.$trionesControlHeight;
|
|
209
|
+
display: inline-flex;
|
|
210
|
+
align-items: center;
|
|
211
|
+
justify-content: center;
|
|
212
|
+
|
|
213
|
+
&-sm {
|
|
214
|
+
width: variable.$trionesControlHeightSm;
|
|
215
|
+
height: variable.$trionesControlHeightSm;
|
|
216
|
+
}
|
|
217
|
+
|
|
218
|
+
&-lg {
|
|
219
|
+
width: variable.$trionesControlHeightLg;
|
|
220
|
+
height: variable.$trionesControlHeightLg;
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
&::placeholder {
|
|
224
|
+
font-size: variable.$trionesInputInputFontSize;
|
|
225
|
+
color: $placeholderColor
|
|
226
|
+
}
|
|
227
|
+
|
|
228
|
+
&-focus {
|
|
229
|
+
&::after {
|
|
230
|
+
content: ' ';
|
|
231
|
+
height: 100%;
|
|
232
|
+
width: 0.5Px;
|
|
233
|
+
background-color: #0a0a0a;
|
|
234
|
+
transition: transform 0.1s ease;
|
|
235
|
+
animation: blink 1s step-end infinite;
|
|
236
|
+
}
|
|
237
|
+
}
|
|
238
|
+
|
|
239
|
+
}
|
|
240
|
+
|
|
241
|
+
.#{$inputCls}-outlined {
|
|
242
|
+
font-size: variable.$trionesInputInputFontSize;
|
|
243
|
+
color: rgba(0, 0, 0, 0.88);
|
|
244
|
+
background: #ffffff;
|
|
245
|
+
border-width: 1Px;
|
|
246
|
+
border-style: solid;
|
|
247
|
+
border-color: #d9d9d9;
|
|
248
|
+
-webkit-appearance: none;
|
|
249
|
+
-moz-appearance: none;
|
|
250
|
+
appearance: none;
|
|
251
|
+
}
|
|
252
|
+
}
|
|
253
|
+
|
|
254
|
+
|
|
255
|
+
.#{$inputCls}-textarea {
|
|
256
|
+
box-sizing: border-box;
|
|
257
|
+
width: 100%;
|
|
258
|
+
outline: 0;
|
|
259
|
+
font-size: variable.$trionesInputInputFontSize;
|
|
260
|
+
|
|
261
|
+
taro-textarea-core {
|
|
262
|
+
width: 100%;
|
|
263
|
+
}
|
|
264
|
+
.taro-textarea{
|
|
265
|
+
background-color: transparent;
|
|
266
|
+
}
|
|
267
|
+
textarea {
|
|
268
|
+
padding-block: 2Px;
|
|
269
|
+
background-color: transparent;
|
|
270
|
+
&::placeholder {
|
|
271
|
+
font-size: variable.$trionesInputInputFontSize;
|
|
272
|
+
color: $placeholderColor
|
|
273
|
+
}
|
|
274
|
+
}
|
|
275
|
+
|
|
276
|
+
}
|
|
277
|
+
|
|
278
|
+
@keyframes blink {
|
|
279
|
+
50% {
|
|
280
|
+
background-color: transparent;
|
|
281
|
+
}
|
|
282
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import React, { FC, PropsWithChildren } from 'react';
|
|
2
|
+
import { variantType } from "./types";
|
|
3
|
+
export type InputAffixWrapperProps = {
|
|
4
|
+
style?: React.CSSProperties;
|
|
5
|
+
className?: string;
|
|
6
|
+
prefix?: React.ReactNode;
|
|
7
|
+
suffix?: React.ReactNode;
|
|
8
|
+
variant?: variantType;
|
|
9
|
+
allowClear?: boolean;
|
|
10
|
+
value?: any;
|
|
11
|
+
onClear?: () => void;
|
|
12
|
+
};
|
|
13
|
+
export declare const InputAffixWrapper: FC<PropsWithChildren<InputAffixWrapperProps>>;
|