🐝 Fix: [web]:修复手机端点击跳转失败,以及书签输入字符数限制

This commit is contained in:
fanxb 2019-11-20 22:46:41 +08:00
parent c08ed759b0
commit c2b7f6f01c
2 changed files with 4 additions and 4 deletions

View File

@ -171,7 +171,7 @@ class Search extends React.Component {
onChange={this.contentChange.bind(this)} onChange={this.contentChange.bind(this)}
onKeyDown={this.keyUp.bind(this)} onKeyDown={this.keyUp.bind(this)}
onFocus={() => this.setState({ isFocus: true })} onFocus={() => this.setState({ isFocus: true })}
onBlur={() => setTimeout(() => this.setState({ isFocus: false }), 200)} onBlur={() => setTimeout(() => this.setState({ isFocus: false }), 600)}
/> />
{this.renderResults()} {this.renderResults()}
</div> </div>

View File

@ -21,8 +21,8 @@ function mapDispatchToProps(dispatch) {
const reg = { const reg = {
name: { name: {
reg: /^.{1,40}$/, reg: /^.{1,200}$/,
text: "名称字符数为1-40" text: "名称字符数为1-200"
}, },
url: { url: {
reg: /^.{1,5000}$/, reg: /^.{1,5000}$/,
@ -69,7 +69,7 @@ class AddModal extends React.Component {
changeValue(e) { changeValue(e) {
const name = e.target.name; const name = e.target.name;
const value = e.target.value.trim(); const value = e.target.value
this.checkValue(name, value); this.checkValue(name, value);
this.setState({ [name]: value }); this.setState({ [name]: value });
} }