-
Notifications
You must be signed in to change notification settings - Fork 483
Remove leading and trailing spaces from the value of the URL type input elements #572
Conversation
@FanZeros: The label(s) In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
貌似这次PR把我上次改的内容也加进去了 #568 |
可以通过如下方式优化一下commit
|
好的,按着流程做了一遍 |
.github/pull_request_template.md
Outdated
@@ -1,76 +0,0 @@ | |||
<!-- Thanks for sending a pull request! Here are some tips for you: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
你不错误的删除了这个文件,需要撤销对该文件的更改
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
好的
hi @FanZeros,你的commit message需要规范一下,我们代码审查通过后是bot自动合并,如果你的commit message不规范就需要我们手动干预才能合并,增加了工作量,建议你使用语义化的简短信息,使用英文概述此次提交所做的事情,你可以参考 halo 的历史提交信息来写 https://github.com/halo-dev/halo/commits/master |
/retitle Remove leading and trailing spaces from the value of the URL type input elements |
This reverts commit 4c16f62.
懂了,麻烦你了 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/cc @halo-dev/sig-halo-admin
/cc @halo-dev/sig-halo-admin 建议实际体验一下修改之后的输入体验。看看是否会对输入造成影响。个人认为最好的解决方式是添加表单验证规则,提示使用者不能包含前后空格,或者允许输入空格,但在提交的时候手动 trim 一下。 |
体验了下,目前没有发现会对输入造成影响。表单验证规则这一部分如果必要的话我最近会尝试一下相关实现。 |
主要考虑到使用者可能不明白为什么输入空格会没有反应,如果使用表单验证的话,可以比较直观的知道。 |
那些位置不应该包含空格的输入,感觉使用者不会特意去输入空格吧。不过你说的也很有道理 |
/ping @halo-dev/sig-halo-admin |
可以引入commitlint 配合 husky在本地提交前做校验。 |
What type of PR is this?
/kind bug
/kind optimization
What this PR does / why we need it:
对admin的部分input区域进行trim,包括地址、前缀等
避免输入部分的前后空格导致页面出错
Which issue(s) this PR fixes:
Fixes halo-dev/halo#1921
Fixes halo-dev/halo#1850
Screenshots:
Special notes for your reviewer:
Does this PR introduce a user-facing change?