Skip to content

Commit

Permalink
Adapt #14357 for element select inputs
Browse files Browse the repository at this point in the history
[ci skip]
  • Loading branch information
brandonkelly committed Feb 13, 2024
1 parent 5eb5a45 commit bbb43b8
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 2 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
- Fixed a bug where read/write splitting was always getting disabled for GraphQL POST requests. ([#14324](https://github.com/craftcms/cms/issues/14324))
- Fixed a bug where GraphQL schema edit pages could include empty category headings.
- Fixed a bug where asset slideouts weren’t showing validation errors on the Filename field. ([#14329](https://github.com/craftcms/cms/issues/14329))
- Fixed a bug where element slideouts would open when long-pressing on an element’s “Remove” button within an element select input.

## 4.7.2.1 - 2024-02-08

Expand Down
2 changes: 1 addition & 1 deletion src/web/assets/cp/dist/cp.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion src/web/assets/cp/dist/cp.js.map

Large diffs are not rendered by default.

5 changes: 5 additions & 0 deletions src/web/assets/cp/src/js/BaseElementSelectInput.js
Original file line number Diff line number Diff line change
Expand Up @@ -273,6 +273,11 @@ Craft.BaseElementSelectInput = Garnish.Base.extend(

if (this.settings.editable) {
this._handleShowElementEditor = (ev) => {
// don't open the edit slideout if we are tapholding to drag
if (ev.type === 'taphold' && ev.target.nodeName === 'BUTTON') {
return;
}

var $element = $(ev.currentTarget);
if (
Garnish.hasAttr($element, 'data-editable') &&
Expand Down

0 comments on commit bbb43b8

Please sign in to comment.