Skip to content

Commit

Permalink
Merge pull request #17439 from Jir4/fix-tabindex
Browse files Browse the repository at this point in the history
Enable tabindex recompute on preview button while insert new rows
  • Loading branch information
MauricioFauth committed Mar 16, 2022
2 parents 0c7cab4 + 57ad99b commit 39fac83
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion libraries/classes/InsertEdit.php
Expand Up @@ -1976,7 +1976,8 @@ private function getSubmitAndResetButtonForActionsPanel($tabindex, $tabindex_for
)
. '</td>'
. '<td colspan="3" class="right vmiddle">'
. '<input type="button" class="btn btn-secondary preview_sql" value="' . __('Preview SQL') . '"'
. '<input type="button" class="btn btn-secondary preview_sql control_at_footer"'
. ' value="' . __('Preview SQL') . '"'
. ' tabindex="' . ($tabindex + $tabindex_for_value + 6) . '">'
. '<input type="reset" class="btn btn-secondary control_at_footer" value="' . __('Reset') . '"'
. ' tabindex="' . ($tabindex + $tabindex_for_value + 7) . '">'
Expand Down
2 changes: 1 addition & 1 deletion test/classes/InsertEditTest.php
Expand Up @@ -2484,7 +2484,7 @@ public function testGetSubmitAndResetButtonForActionsPanel(): void
);

$this->assertStringContainsString(
'<input type="button" class="btn btn-secondary preview_sql" value="Preview SQL" '
'<input type="button" class="btn btn-secondary preview_sql control_at_footer" value="Preview SQL" '
. 'tabindex="7">',
$result
);
Expand Down

0 comments on commit 39fac83

Please sign in to comment.