fix #4276 キャッシュクリアのキャンセル時にツールバーの背景が白くなる問題を修正#4330
Open
teratai3 wants to merge 1 commit intobaserproject:5.2.xfrom
Open
fix #4276 キャッシュクリアのキャンセル時にツールバーの背景が白くなる問題を修正#4330teratai3 wants to merge 1 commit intobaserproject:5.2.xfrom
teratai3 wants to merge 1 commit intobaserproject:5.2.xfrom
Conversation
onclick の return false により defaultPrevented が true になるケース(confirm ダイアログでキャンセル)を e.isDefaultPrevented() で検出し、active クラスの付与をスキップするよう修正
Contributor
Author
|
4系も同じ問題があるため、こちらの修正内容が問題なくマージされたら4系も対応予定です。 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
#4276 の対応です。
修正内容
fixedMenu.jsのクリックハンドラーにe.isDefaultPrevented()チェックを追加。return falseによりdefaultPrevented = true→active付与をスキップ(白背景が出なくなる)defaultPrevented = false→activeを付与してからページ遷移事前準備
/baser/admin/baser-core/sites/indexにアクセスし新規追加からサイトを登録しておく(ToolMenuの動作にも影響するため)
MRで確認してほしいこと
#ToolMenuの動作#UserMenuの動作ヘッダーメニューのキャッシュクリアボタンを押しダイアログの以下の挙動を確認してください
OKの場合
キャンセルの場合
※ キャンセル時のフォーカスの背景色に関しては解除することもできますが、現状が自然な挙動と感じたため、本タスクでは修正していません。
備考
isDefaultPreventedメソッドのドキュメント
https://api.jquery.com/event.isDefaultPrevented/