@nutui/nutui-react 2.7.1 → 2.7.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.
@@ -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
+ }
@@ -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
  }