@nutui/nutui-react-taro 2.7.1 → 2.7.3

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 (47) hide show
  1. package/CHANGELOG.md +36 -10
  2. package/dist/esm/Animate/style/style.css +1 -1
  3. package/dist/esm/Elevator.js +1 -1
  4. package/dist/esm/Empty.js +1 -1
  5. package/dist/esm/Form/style/style.css +1 -1
  6. package/dist/esm/Form.js +6 -5
  7. package/dist/esm/FormItem/style/style.css +1 -1
  8. package/dist/esm/FormItem.js +1 -1
  9. package/dist/esm/Popover/style/style.css +1 -1
  10. package/dist/esm/Table/style/style.css +1 -1
  11. package/dist/esm/Tour/style/style.css +1 -1
  12. package/dist/esm/Uploader/style/style.css +1 -1
  13. package/dist/esm/Uploader.js +1 -1
  14. package/dist/esm/{elevator.taro-Bsc8PcT0.js → elevator.taro-C0Gs93x7.js} +5 -3
  15. package/dist/esm/{empty.taro-Dt07kty5.js → empty.taro-DhCHSdca.js} +9 -1
  16. package/dist/esm/{formitem.taro-CEWRz5EJ.js → formitem.taro-CU6rrcJD.js} +105 -47
  17. package/dist/esm/nutui-react.es.js +4 -4
  18. package/dist/esm/{uploader.taro-CceZ5Y4t.js → uploader.taro-C3hV5Aih.js} +3 -1
  19. package/dist/locales/base.js +1 -1
  20. package/dist/locales/en-US.js +1 -1
  21. package/dist/locales/id-ID.js +1 -1
  22. package/dist/locales/tr-TR.js +1 -1
  23. package/dist/locales/zh-CN.js +1 -1
  24. package/dist/locales/zh-TW.js +1 -1
  25. package/dist/locales/zh-UG.js +1 -1
  26. package/dist/nutui.react.es.js +247 -148
  27. package/dist/nutui.react.umd.js +246 -147
  28. package/dist/packages/animate/animate.scss +0 -3
  29. package/dist/packages/form/form.scss +0 -68
  30. package/dist/packages/formitem/formitem.scss +90 -21
  31. package/dist/packages/popover/popover.scss +16 -11
  32. package/dist/packages/table/table.scss +1 -0
  33. package/dist/packages/uploader/uploader.scss +2 -1
  34. package/dist/style.css +1 -1
  35. package/dist/styles/variables.scss +1 -0
  36. package/dist/types/packages/configprovider/types.d.ts +1 -1
  37. package/dist/types/packages/empty/types.d.ts +10 -1
  38. package/dist/types/packages/empty/utils.d.ts +2 -0
  39. package/dist/types/packages/form/form.d.ts +2 -0
  40. package/dist/types/packages/form/form.taro.d.ts +10 -0
  41. package/dist/types/packages/form/types.d.ts +2 -1
  42. package/dist/types/packages/formitem/formitem.d.ts +1 -0
  43. package/dist/types/packages/formitem/formitem.taro.d.ts +1 -0
  44. package/dist/types/packages/video/video.d.ts +6 -2
  45. package/dist/types/utils/merge.d.ts +1 -0
  46. package/dist/types/utils/to-array.d.ts +1 -0
  47. package/package.json +1 -1
@@ -1,68 +0,0 @@
1
-
2
- .form-layout-right .nut-form-item-label {
3
- text-align: right;
4
- padding-right: 24px;
5
- white-space: nowrap;
6
- }
7
-
8
- .form-layout-left .nut-form-item-label {
9
- position: relative;
10
- text-align: left;
11
- padding-left: 12px;
12
- white-space: nowrap;
13
-
14
- .required {
15
- display: block;
16
- line-height: 1.5;
17
- position: absolute;
18
- left: 0.1em;
19
- }
20
- }
21
-
22
- .form-layout-top .nut-form-item {
23
- flex-direction: column;
24
- align-items: flex-start;
25
- white-space: nowrap;
26
- }
27
-
28
- .form-layout-top .nut-form-item-label {
29
- padding-bottom: 4px;
30
- display: block;
31
- padding-right: 24px;
32
- }
33
-
34
- .form-layout-top .nut-form-item-body {
35
- margin-left: 0;
36
- width: 100%;
37
- }
38
-
39
- [dir='rtl'] .form-layout-right .nut-form-item-label,
40
- .nut-rtl .form-layout-right .nut-form-item-label {
41
- text-align: left;
42
- padding-right: 0;
43
- padding-left: 24px;
44
- }
45
-
46
- [dir='rtl'] .form-layout-left .nut-form-item-label,
47
- .nut-rtl .form-layout-left .nut-form-item-label {
48
- text-align: right;
49
- padding-left: 0;
50
- padding-right: 12px;
51
-
52
- .required {
53
- left: auto;
54
- right: 0.1em;
55
- }
56
- }
57
-
58
- [dir='rtl'] .form-layout-top .nut-form-item-label,
59
- .nut-rtl .form-layout-top .nut-form-item-label {
60
- padding-right: 0;
61
- padding-left: 24px;
62
- }
63
-
64
- [dir='rtl'] .form-layout-top .nut-form-item-body,
65
- .nut-rtl .form-layout-top .nut-form-item-body {
66
- margin-left: 0;
67
- margin-right: 0;
68
- }
@@ -1,38 +1,38 @@
1
1
  .nut-form-item {
2
2
  display: flex;
3
3
 
4
- &.error {
5
- &.line {
6
- &::before {
7
- border-bottom: 1px solid $form-item-error-line-color;
8
- transform: scaleX(1);
9
- transition: transform 200ms cubic-bezier(0, 0, 0.2, 1) 0ms;
10
- }
11
- }
4
+ &-disabled {
5
+ opacity: 0.4;
6
+ pointer-events: none;
12
7
  }
13
8
 
14
9
  &-label {
10
+ display: flex;
11
+ flex-direction: row;
15
12
  font-size: $form-item-label-font-size;
16
13
  font-weight: normal;
17
14
  width: $form-item-label-width;
18
15
  margin-right: $form-item-label-margin-right;
19
- flex: none !important;
20
- display: inline-block !important;
16
+ flex: 0 0 auto;
21
17
  word-wrap: break-word;
22
18
  text-align: $form-item-label-text-align;
23
-
24
- .required {
25
- &::before {
26
- content: '*';
27
- color: $form-item-required-color;
28
- margin-right: $form-item-required-margin-right;
29
- }
30
- }
31
19
  }
32
20
 
21
+ &-label-required {
22
+ color: $form-item-required-color;
23
+ margin-right: $form-item-required-margin-right;
24
+ display: block;
25
+ position: absolute;
26
+ left: -0.8em;
27
+ }
28
+ .nut-form-item-labeltxt {
29
+ font-size: 12px;
30
+ height: 10px;
31
+ position: relative;
32
+ }
33
33
  &-body {
34
34
  flex: 1;
35
- display: flex !important;
35
+ display: flex;
36
36
  flex-direction: column;
37
37
 
38
38
  &-slots {
@@ -59,8 +59,7 @@
59
59
  }
60
60
 
61
61
  .nut-textarea {
62
- padding: 0 !important;
63
-
62
+ padding: 0;
64
63
  .nut-textarea-textarea {
65
64
  font: inherit;
66
65
  text-align: $form-item-body-input-text-align;
@@ -75,6 +74,7 @@
75
74
  }
76
75
  }
77
76
  }
77
+
78
78
  [dir='rtl'] .nut-form-item,
79
79
  .nut-rtl .nut-form-item {
80
80
  &-label {
@@ -108,3 +108,72 @@
108
108
  text-align: right;
109
109
  }
110
110
  }
111
+
112
+ /* position */
113
+
114
+ .nut-form-item-label-right {
115
+ justify-content: flex-end;
116
+ padding-right: 24px;
117
+ white-space: nowrap;
118
+ }
119
+
120
+ .nut-form-item-label-left {
121
+ position: relative;
122
+ padding-left: 12px;
123
+ white-space: nowrap;
124
+ }
125
+
126
+ .nut-form-item-label-left-required {
127
+ display: block;
128
+ line-height: 1.5;
129
+ position: absolute;
130
+ left: 0.1em;
131
+ }
132
+
133
+ .nut-form-item-top {
134
+ flex-direction: column;
135
+ align-items: flex-start;
136
+ white-space: nowrap;
137
+ }
138
+
139
+ .nut-form-item-label-top {
140
+ display: block;
141
+ padding-bottom: 4px;
142
+ padding-right: 24px;
143
+ }
144
+
145
+ .nut-form-item-body-top {
146
+ margin-left: 0;
147
+ width: 100%;
148
+ }
149
+
150
+ [dir='rtl'] .form-layout-right .nut-form-item-label,
151
+ .nut-rtl .form-layout-right .nut-form-item-label {
152
+ text-align: left;
153
+ padding-right: 0;
154
+ padding-left: 24px;
155
+ }
156
+
157
+ [dir='rtl'] .form-layout-left .nut-form-item-label,
158
+ .nut-rtl .form-layout-left .nut-form-item-label {
159
+ text-align: right;
160
+ padding-left: 0;
161
+ padding-right: 12px;
162
+
163
+ .required {
164
+ left: auto;
165
+ right: 0.1em;
166
+ }
167
+ }
168
+
169
+ [dir='rtl'] .form-layout-top .nut-form-item-label,
170
+ .nut-rtl .form-layout-top .nut-form-item-label {
171
+ padding-right: 0;
172
+ padding-left: 24px;
173
+ }
174
+
175
+ [dir='rtl'] .form-layout-top .nut-form-item-body,
176
+ .nut-rtl .form-layout-top .nut-form-item-body {
177
+ margin-left: 0;
178
+ margin-right: 0;
179
+ }
@@ -94,18 +94,14 @@
94
94
  justify-content: center;
95
95
  padding: $popover-menu-item-padding;
96
96
  border-bottom: 1px solid $popover-divider-color;
97
+ max-width: $popover-menu-item-width;
98
+ word-wrap: break-word;
97
99
 
98
100
  &:last-child {
99
101
  margin-bottom: 0px;
100
102
  border-bottom: none;
101
103
  }
102
104
 
103
- // &:hover:not(:only-child) {
104
- // cursor: pointer;
105
- // color: $popover-hover-text-color;
106
- // background-color: $popover-hover-background-color;
107
- // }
108
-
109
105
  &:hover:nth-of-type(2) {
110
106
  border-radius: 8px 8px 0px 0px;
111
107
  }
@@ -129,9 +125,10 @@
129
125
  }
130
126
 
131
127
  &-name {
132
- width: 100%;
128
+ width: calc(100% - 34px);
133
129
  word-break: keep-all;
134
130
  margin: 0 6px 0 4px;
131
+ flex: 1;
135
132
  }
136
133
 
137
134
  &-action-icon {
@@ -171,7 +168,6 @@
171
168
 
172
169
  &-top-start {
173
170
  left: 0;
174
-
175
171
  .nut-popover-arrow-top-start {
176
172
  left: 16px;
177
173
  transform: translateX(0%);
@@ -187,7 +183,6 @@
187
183
 
188
184
  &-bottom-end {
189
185
  right: 0;
190
-
191
186
  .nut-popover-arrow-bottom-end {
192
187
  right: 16px;
193
188
  transform: translateX(0%);
@@ -196,7 +191,6 @@
196
191
 
197
192
  &-bottom-start {
198
193
  left: 0;
199
-
200
194
  .nut-popover-arrow-bottom-start {
201
195
  left: 16px;
202
196
  transform: translateX(0%);
@@ -226,7 +220,18 @@
226
220
  color: $popover-content-background-color;
227
221
 
228
222
  .nut-popover-arrow {
229
- border-bottom-color: $popover-text-color;
223
+ &-top {
224
+ border-top-color: $popover-text-color;
225
+ }
226
+ &-bottom {
227
+ border-bottom-color: $popover-text-color;
228
+ }
229
+ &-left {
230
+ border-left-color: $popover-text-color;
231
+ }
232
+ &-right {
233
+ border-right-color: $popover-text-color;
234
+ }
230
235
  }
231
236
 
232
237
  .nut-popover-content {
@@ -74,6 +74,7 @@
74
74
  &.nut-table-fixed-left,
75
75
  &.nut-table-fixed-right {
76
76
  z-index: 4;
77
+ background-color: #fff;
77
78
  }
78
79
 
79
80
  &:last-child {
@@ -177,7 +177,8 @@
177
177
  display: flex;
178
178
  justify-content: center;
179
179
  align-items: center;
180
- height: 100%;
180
+ width: $uploader-image-width;
181
+ height: $uploader-image-height;
181
182
  position: initial;
182
183
  border-radius: $uploader-image-border-radius;
183
184
  }