Skip to content

Commit

Permalink
Change from IDs to classes in quick action buttons
Browse files Browse the repository at this point in the history
  • Loading branch information
pascalwengerter committed Apr 27, 2021
1 parent 9e0f11c commit 1129851
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 2 deletions.
6 changes: 6 additions & 0 deletions changelog/unreleased/bugfix-quick-action-ids
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
Bugfix: Change quick action from IDs to classes

Quick action button IDs were repeated in every row of the file table, which isn't allowed in HTML (IDs must be unique per document).
By changing to classes, this offense was resolved.

https://github.com/owncloud/web/pull/5028
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@
<div class="uk-flex">
<oc-button
v-for="action in filteredActions"
:id="`files-quick-action-${action.id}`"
:key="action.label"
:aria-label="action.label"
:uk-tooltip="action.label"
appearance="raw"
class="oc-mr-xs"
:class="`files-quick-action-${action.id}`"
@click.stop="action.handler({ item, client: $client, store: $store })"
>
<oc-icon :name="action.icon" class="uk-flex" />
Expand Down
2 changes: 1 addition & 1 deletion tests/acceptance/pageObjects/FilesPageElement/filesRow.js
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ module.exports = {
locateStrategy: 'xpath'
},
quickAction: {
selector: '//button[@id="files-quick-action-%s"]',
selector: '//button[@class="files-quick-action-%s"]',
locateStrategy: 'xpath'
}
}
Expand Down

0 comments on commit 1129851

Please sign in to comment.