Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bugfix] Fix that we have to click twice to close gyp-closable after click in wrapped component #262

Merged
merged 1 commit into from
Mar 20, 2020

Conversation

chenesan
Copy link
Contributor

@chenesan chenesan commented Mar 19, 2020

Purpose

修正在 <SelectRow> 開啟選項的 popover 並在裡面點選後,在外面按一下不會關掉 popover 的問題,必須按兩下。

這是因為修正了 #250 後,改變了 DOM 的結構讓 gyp-closable 不再是 WrappedComponent 的父元素,卻忘了拿掉原本在 <WrappedComponent> 內部點擊、觸發 gyp-closable click event handler 時不要執行 onClose 的機制。現在在 <WrappedComponent> 內點擊本來就不會觸發 gyp-closable 的 click handler,所以也不用額外這樣做。

實作上就是拿掉 closablethis.insideClick 變數。

Changes

  • 拿掉 closable 裡面的 this.insideClick

Risk

所有使用 <Popover> 的 component(在 gypcrete 裡面只有 <SelectRow>)

TODOs

  • Describe what should be done outside of this PR
  • Maybe in other PRs or some manual actions.

@chenesan chenesan marked this pull request as ready for review March 19, 2020 08:42
@chenesan chenesan self-assigned this Mar 19, 2020
@chenesan chenesan added the bug label Mar 19, 2020
Copy link
Member

@kyoyadmoon kyoyadmoon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍

@chenesan chenesan merged commit e2044c4 into develop Mar 20, 2020
@chenesan chenesan deleted the bugfix/fix-select-row-close-need-dbclick branch March 20, 2020 06:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants