From 66bc8ceddd69d4f9bf6b854ec38054fdacb6aa1d Mon Sep 17 00:00:00 2001
From: Geido <60598000+geido@users.noreply.github.com>
Date: Fri, 28 Jun 2024 16:19:58 +0200
Subject: [PATCH] chore(Table): Add aria-label to Table page size selector
(#29391)
---
.../src/DataTable/components/SelectPageSize.tsx | 7 ++++++-
.../plugins/plugin-chart-table/src/TableChart.tsx | 9 +++++++--
2 files changed, 13 insertions(+), 3 deletions(-)
diff --git a/superset-frontend/plugins/plugin-chart-table/src/DataTable/components/SelectPageSize.tsx b/superset-frontend/plugins/plugin-chart-table/src/DataTable/components/SelectPageSize.tsx
index d97d6411b78..02052f10304 100644
--- a/superset-frontend/plugins/plugin-chart-table/src/DataTable/components/SelectPageSize.tsx
+++ b/superset-frontend/plugins/plugin-chart-table/src/DataTable/components/SelectPageSize.tsx
@@ -48,8 +48,13 @@ function DefaultSelectRenderer({
const [size, text] = Array.isArray(option)
? option
: [option, option];
+ const sizeLabel = size === 0 ? t('all') : size;
return (
-
);
diff --git a/superset-frontend/plugins/plugin-chart-table/src/TableChart.tsx b/superset-frontend/plugins/plugin-chart-table/src/TableChart.tsx
index 37bdbed9d1c..a87371f440f 100644
--- a/superset-frontend/plugins/plugin-chart-table/src/TableChart.tsx
+++ b/superset-frontend/plugins/plugin-chart-table/src/TableChart.tsx
@@ -181,10 +181,10 @@ function SearchInput({ count, value, onChange }: SearchInputProps) {
{t('Search')}{' '}
@@ -211,8 +211,13 @@ function SelectPageSize({
const [size, text] = Array.isArray(option)
? option
: [option, option];
+ const sizeLabel = size === 0 ? t('all') : size;
return (
-
);