easy3wmui 0.0.42-beta6 → 0.0.42-beta8
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/assets/index.css +5 -3
- package/assets/mFormPage.css +3 -0
- package/assets/mLogin.css +1 -0
- package/lib/Easy3wMLogin/index.js +73 -4
- package/package.json +1 -1
package/assets/index.css
CHANGED
|
@@ -30,9 +30,6 @@
|
|
|
30
30
|
:root:root .adm-text-area {
|
|
31
31
|
--font-size: var(--adm-font-size-4);
|
|
32
32
|
}
|
|
33
|
-
:root:root .adm-text-area-element {
|
|
34
|
-
border: 1px solid #d9d9d9;
|
|
35
|
-
}
|
|
36
33
|
:root:root .adm-text-area-element:focus,
|
|
37
34
|
:root:root .adm-text-area-element:hover {
|
|
38
35
|
border-color: var(--adm-color-primary);
|
|
@@ -76,6 +73,7 @@
|
|
|
76
73
|
-ms-flex-item-align: auto;
|
|
77
74
|
-ms-grid-row-align: auto;
|
|
78
75
|
align-self: auto;
|
|
76
|
+
line-height: 24px;
|
|
79
77
|
}
|
|
80
78
|
:root:root .adm-form .adm-form-footer {
|
|
81
79
|
padding: 12px;
|
|
@@ -214,6 +212,9 @@
|
|
|
214
212
|
border-bottom: var(--border-bottom);
|
|
215
213
|
margin-bottom: 12px;
|
|
216
214
|
}
|
|
215
|
+
#Easy3wMFormPage .adm-form-item-label {
|
|
216
|
+
line-height: 24px;
|
|
217
|
+
}
|
|
217
218
|
#Easy3wMFormPage .adm-list-item-content-main {
|
|
218
219
|
color: var(--adm-color-text);
|
|
219
220
|
text-align: right;
|
|
@@ -304,6 +305,7 @@
|
|
|
304
305
|
height: 40px;
|
|
305
306
|
border-radius: 4px;
|
|
306
307
|
padding: 0 12px;
|
|
308
|
+
border: 1px solid #d9d9d9;
|
|
307
309
|
}
|
|
308
310
|
#Easy3wMLogin .errorMsgReal {
|
|
309
311
|
background: #fff1f0;
|
package/assets/mFormPage.css
CHANGED
package/assets/mLogin.css
CHANGED
|
@@ -117,7 +117,13 @@ var Easy3wMLogin = function (_Component) {
|
|
|
117
117
|
form = _props.form,
|
|
118
118
|
status = _props.status,
|
|
119
119
|
submitting = _props.submitting,
|
|
120
|
-
errorMsg = _props.errorMsg
|
|
120
|
+
errorMsg = _props.errorMsg,
|
|
121
|
+
objLoginMethod = _props.objLoginMethod;
|
|
122
|
+
|
|
123
|
+
var _ref = objLoginMethod || {},
|
|
124
|
+
account = _ref.account,
|
|
125
|
+
phone = _ref.phone;
|
|
126
|
+
|
|
121
127
|
var visible = this.state.visible;
|
|
122
128
|
|
|
123
129
|
var errorMsgReal = errorMsg || '账户或密码错误';
|
|
@@ -127,9 +133,72 @@ var Easy3wMLogin = function (_Component) {
|
|
|
127
133
|
_react2['default'].createElement(
|
|
128
134
|
_tabs2['default'],
|
|
129
135
|
{ activeKey: 'account', onChange: this.onChange },
|
|
130
|
-
_react2['default'].createElement(
|
|
136
|
+
account ? _react2['default'].createElement(
|
|
137
|
+
Tab,
|
|
138
|
+
{ title: '\u8D26\u53F7\u5BC6\u7801\u767B\u5F55', key: 'account' },
|
|
139
|
+
_react2['default'].createElement(
|
|
140
|
+
_form2['default'],
|
|
141
|
+
{
|
|
142
|
+
// ref={this.formRef}
|
|
143
|
+
onFinish: this.submitAccountLogin,
|
|
144
|
+
form: form,
|
|
145
|
+
layout: 'horizontal' // 字段与
|
|
146
|
+
, name: 'login',
|
|
147
|
+
footer: // 表单尾部的内容,常常用来放置提交按钮
|
|
148
|
+
_react2['default'].createElement(
|
|
149
|
+
'div',
|
|
150
|
+
null,
|
|
151
|
+
_react2['default'].createElement(
|
|
152
|
+
_button2['default'],
|
|
153
|
+
{ color: 'primary', fill: 'solid', block: true, type: 'primary', htmlType: 'submit' },
|
|
154
|
+
'\u767B\u5F55'
|
|
155
|
+
)
|
|
156
|
+
)
|
|
157
|
+
},
|
|
158
|
+
status === 'error' && submitting === false ? _react2['default'].createElement(
|
|
159
|
+
FormItem,
|
|
160
|
+
null,
|
|
161
|
+
_react2['default'].createElement(
|
|
162
|
+
'div',
|
|
163
|
+
{ className: 'errorMsgReal' },
|
|
164
|
+
errorMsgReal
|
|
165
|
+
)
|
|
166
|
+
) : '',
|
|
167
|
+
_react2['default'].createElement(
|
|
168
|
+
FormItem,
|
|
169
|
+
{ name: 'userName', required: true },
|
|
170
|
+
_react2['default'].createElement(_input2['default'], { onClick: this.changePsmode, placeholder: '\u8BF7\u8F93\u5165\u7528\u6237\u540D' })
|
|
171
|
+
),
|
|
172
|
+
_react2['default'].createElement(
|
|
173
|
+
FormItem,
|
|
174
|
+
{
|
|
175
|
+
name: 'password',
|
|
176
|
+
required: true,
|
|
177
|
+
extra: _react2['default'].createElement(
|
|
178
|
+
_button2['default'],
|
|
179
|
+
{
|
|
180
|
+
size: 'small',
|
|
181
|
+
onClick: this.touchSetPassword,
|
|
182
|
+
htmlType: 'button'
|
|
183
|
+
},
|
|
184
|
+
visible ? _react2['default'].createElement(_antdMobileIcons.EyeOutline, null) : _react2['default'].createElement(_antdMobileIcons.EyeInvisibleOutline, null)
|
|
185
|
+
)
|
|
186
|
+
},
|
|
187
|
+
_react2['default'].createElement(_input2['default'], { placeholder: '\u8BF7\u8F93\u5165\u5BC6\u7801', type: visible ? 'text' : 'password' })
|
|
188
|
+
),
|
|
189
|
+
_react2['default'].createElement(
|
|
190
|
+
FormItem,
|
|
191
|
+
{
|
|
192
|
+
name: 'piccaptcha',
|
|
193
|
+
rules: [{ required: true, message: '请输入验证码 不区分大小写' }, { validator: this.checkCaptcha }],
|
|
194
|
+
extra: _react2['default'].createElement(_easy3wmui.Easy3wMCaptcha, { touchCaptchaResult: this.touchCaptchaResult })
|
|
195
|
+
},
|
|
196
|
+
_react2['default'].createElement(_input2['default'], { placeholder: '\u8BF7\u8F93\u5165\u9A8C\u8BC1\u7801 \u4E0D\u533A\u5206\u5927\u5C0F\u5199' })
|
|
197
|
+
)
|
|
198
|
+
)
|
|
199
|
+
) : phone ? _react2['default'].createElement(
|
|
131
200
|
Tab,
|
|
132
|
-
{ title: '\
|
|
201
|
+
{ title: '\u624B\u673A\u9A8C\u8BC1\u7801\u767B\u5F55', key: 'account' },
|
|
133
202
|
_react2['default'].createElement(
|
|
134
203
|
_form2['default'],
|
|
135
204
|
{
|
|
@@ -190,7 +259,7 @@ var Easy3wMLogin = function (_Component) {
|
|
|
190
259
|
_react2['default'].createElement(_input2['default'], { placeholder: '\u8BF7\u8F93\u5165\u9A8C\u8BC1\u7801 \u4E0D\u533A\u5206\u5927\u5C0F\u5199' })
|
|
191
260
|
)
|
|
192
261
|
)
|
|
193
|
-
)
|
|
262
|
+
) : ''
|
|
194
263
|
)
|
|
195
264
|
);
|
|
196
265
|
};
|