diff options
author | Christopher Ng <chrng8@gmail.com> | 2022-06-08 23:55:51 +0000 |
---|---|---|
committer | Christopher Ng <chrng8@gmail.com> | 2022-06-09 00:25:13 +0000 |
commit | 0ea95c3ff603d439ed7129a775d539cc96840a2c (patch) | |
tree | 41fcaa0311e8aac5708ab2ca9a5f4da9465e4a92 /core/src/jquery/ocdialog.js | |
parent | 343eab4c969ebb6a2540e6a1ca5442d370bf6d39 (diff) | |
download | nextcloud-server-0ea95c3ff603d439ed7129a775d539cc96840a2c.tar.gz nextcloud-server-0ea95c3ff603d439ed7129a775d539cc96840a2c.zip |
Rename a11y helper function
Signed-off-by: Christopher Ng <chrng8@gmail.com>
Diffstat (limited to 'core/src/jquery/ocdialog.js')
-rw-r--r-- | core/src/jquery/ocdialog.js | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/core/src/jquery/ocdialog.js b/core/src/jquery/ocdialog.js index 31fbf3a333a..c8ea065d3c0 100644 --- a/core/src/jquery/ocdialog.js +++ b/core/src/jquery/ocdialog.js @@ -24,7 +24,7 @@ */ import $ from 'jquery' -import { isA11yClick } from '../Util/a11y' +import { isA11yActivation } from '../Util/a11y' $.widget('oc.ocdialog', { options: { @@ -61,7 +61,7 @@ $.widget('oc.ocdialog', { if (self.element.find('input').length === 1) { const $input = self.element.find('input') $input.on('keydown', function(event) { - if (isA11yClick(event)) { + if (isA11yActivation(event)) { if (self.$buttonrow) { const $button = self.$buttonrow.find('button.primary') if ($button && !$button.prop('disabled')) { @@ -158,7 +158,7 @@ $.widget('oc.ocdialog', { } self.$buttonrow.append($button) $button.on('click keydown', function(event) { - if (isA11yClick(event)) { + if (isA11yActivation(event)) { val.click.apply(self.element[0], arguments) } }) @@ -180,7 +180,7 @@ $.widget('oc.ocdialog', { const $closeButton = $('<a class="oc-dialog-close" tabindex="0"></a>') this.$dialog.prepend($closeButton) $closeButton.on('click keydown', function(event) { - if (isA11yClick(event)) { + if (isA11yActivation(event)) { self.options.closeCallback && self.options.closeCallback() self.close() } |