Browse Source

Fixed missing aria-label locales

zhixin 3 years ago
parent
commit
9405d5a5bb
2 changed files with 3 additions and 3 deletions
  1. 1 1
      src/bootstrap-table.js
  2. 2 2
      src/extensions/export/bootstrap-table-export.js

+ 1 - 1
src/bootstrap-table.js

@@ -637,7 +637,7 @@ class BootstrapTable {
 
           html.push(`<div class="keep-open ${this.constants.classes.buttonsDropdown}" title="${opts.formatColumns()}">
             <button class="${this.constants.buttonsClass} dropdown-toggle" type="button" ${this.constants.dataToggle}="dropdown"
-            aria-label="Columns" title="${opts.formatColumns()}">
+            aria-label="${opts.formatColumns()}" title="${opts.formatColumns()}">
             ${opts.showButtonIcons ? Utils.sprintf(this.constants.html.icon, opts.iconsPrefix, opts.icons.columns) : ''}
             ${opts.showButtonText ? opts.formatColumns() : ''}
             ${this.constants.html.dropdownCaret}

+ 2 - 2
src/extensions/export/bootstrap-table-export.js

@@ -99,7 +99,7 @@ $.BootstrapTable = class extends $.BootstrapTable {
                   <div class="export ${this.constants.classes.buttonsDropdown}"
                   data-type="${exportTypes[0]}">
                   <button class="${this.constants.buttonsClass}"
-                  aria-label="Export"
+                  aria-label="${o.formatExport()}"
                   type="button"
                   title="${o.formatExport()}">
                   ${o.showButtonIcons ? Utils.sprintf(this.constants.html.icon, o.iconsPrefix, o.icons.export) : ''}
@@ -114,7 +114,7 @@ $.BootstrapTable = class extends $.BootstrapTable {
               html.push(`
                 <div class="export ${this.constants.classes.buttonsDropdown}">
                 <button class="${this.constants.buttonsClass} dropdown-toggle"
-                aria-label="Export"
+                aria-label="${o.formatExport()}"
                 ${this.constants.dataToggle}="dropdown"
                 type="button"
                 title="${o.formatExport()}">