Skip to content

Commit

Permalink
Allow double-clicking anywhere on the table row
Browse files Browse the repository at this point in the history
Resolves #14379
  • Loading branch information
brandonkelly committed May 14, 2024
1 parent aa4d6db commit 43fb8d8
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 9 deletions.
1 change: 1 addition & 0 deletions CHANGELOG-WIP.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

### Content Management
- It’s now possible to edit assets’ alternative text from the Assets index page. ([#14893](https://github.com/craftcms/cms/discussions/14893))
- Double-clicking anywhere within a table row on an element index page will now open the element’s editor slideout. ([#14379](https://github.com/craftcms/cms/discussions/14379))
- Element index checkboxes no longer have a lag when deselected, except within element selection modals. ([#14896](https://github.com/craftcms/cms/issues/14896))
- Improved mobile styling. ([#14910](https://github.com/craftcms/cms/pull/14910))
- Improved the look of slideouts.
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.

10 changes: 3 additions & 7 deletions src/web/assets/cp/src/js/BaseElementIndexView.js
Original file line number Diff line number Diff line change
Expand Up @@ -92,13 +92,9 @@ Craft.BaseElementIndexView = Garnish.Base.extend(
}

const $target = $(ev.target);
var $element;

if ($target.hasClass('element')) {
$element = $target;
} else {
$element = $target.closest('.element');

let $element = $target.closest('.element');
if (!$element.length) {
$element = $target.closest('tr').find('.element:first');
if (!$element.length) {
return;
}
Expand Down

0 comments on commit 43fb8d8

Please sign in to comment.