From ce214f02a2275117aa01d13e959187ce05ae3320 Mon Sep 17 00:00:00 2001 From: Parthiv Krishnan Date: Mon, 10 Aug 2026 14:17:39 -0400 Subject: [PATCH 1/2] OCPBUGS-82108: marked strings for i18n in NetworkPolicies list page --- locales/en/plugin__networking-console-plugin.json | 3 +++ locales/es/plugin__networking-console-plugin.json | 3 +++ locales/fr/plugin__networking-console-plugin.json | 3 +++ locales/ja/plugin__networking-console-plugin.json | 3 +++ locales/ko/plugin__networking-console-plugin.json | 3 +++ locales/zh/plugin__networking-console-plugin.json | 3 +++ src/views/networkpolicies/list/NetworkPolicyList.tsx | 7 +++++++ 7 files changed, 25 insertions(+) diff --git a/locales/en/plugin__networking-console-plugin.json b/locales/en/plugin__networking-console-plugin.json index 5ae8e54d..879c5412 100644 --- a/locales/en/plugin__networking-console-plugin.json +++ b/locales/en/plugin__networking-console-plugin.json @@ -200,6 +200,7 @@ "IPAMLifecycle": "IPAMLifecycle", "IPAMLifecycle controls IP addresses management lifecycle.": "IPAMLifecycle controls IP addresses management lifecycle.", "It is not recommended to set this field without explicit need and understanding of the OVN network topology.": "It is not recommended to set this field without explicit need and understanding of the OVN network topology.", + "Items per page": "Items per page", "JoinSubnets": "JoinSubnets", "JoinSubnets are used inside the OVN network topology.": "JoinSubnets are used inside the OVN network topology.", "Key": "Key", @@ -275,6 +276,7 @@ "Not found": "Not found", "Not Receiving Traffic": "Not Receiving Traffic", "NS selector": "NS selector", + "of": "of", "Only supported when \"subnets\" are set.": "Only supported when \"subnets\" are set.", "Operator": "Operator", "operator represents a key's relationship to a set of values. Valid operators are In, NotIn, Exists and DoesNotExist.": "operator represents a key's relationship to a set of values. Valid operators are In, NotIn, Exists and DoesNotExist.", @@ -284,6 +286,7 @@ "Path that the router watches to route traffic to the service.": "Path that the router watches to route traffic to the service.", "Path type": "Path type", "Pending": "Pending", + "per page": "per page", "Percent": "Percent", "Persistent": "Persistent", "Phase": "Phase", diff --git a/locales/es/plugin__networking-console-plugin.json b/locales/es/plugin__networking-console-plugin.json index 9e24d3a5..24724b57 100644 --- a/locales/es/plugin__networking-console-plugin.json +++ b/locales/es/plugin__networking-console-plugin.json @@ -202,6 +202,7 @@ "IPAMLifecycle": "IPAMLifecycle", "IPAMLifecycle controls IP addresses management lifecycle.": "IPAMLifecycle controla el ciclo de vida de la gestión de direcciones IP.", "It is not recommended to set this field without explicit need and understanding of the OVN network topology.": "No se recomienda configurar este campo sin una necesidad explícita y sin comprender la topología de la red OVN.", + "Items per page": "", "JoinSubnets": "JoinSubnets", "JoinSubnets are used inside the OVN network topology.": "JoinSubnets se utiliza dentro de la topología de red OVN.", "Key": "Clave", @@ -277,6 +278,7 @@ "Not found": "No encontrado", "Not Receiving Traffic": "Sin recepción de tráfico", "NS selector": "Selector NS", + "of": "", "Only supported when \"subnets\" are set.": "Solo se admite cuando se configuran “subredes”.", "Operator": "Operador", "operator represents a key's relationship to a set of values. Valid operators are In, NotIn, Exists and DoesNotExist.": "El operador representa la relación de una clave con un conjunto de valores. Los operadores válidos son In, NotIn, Exists y DoesNotExist.", @@ -286,6 +288,7 @@ "Path that the router watches to route traffic to the service.": "Ruta que observa el enrutador para enrutar el tráfico al servicio.", "Path type": "Tipo de ruta", "Pending": "Pendiente", + "per page": "", "Percent": "Por ciento", "Persistent": "Persistente", "Phase": "Fase", diff --git a/locales/fr/plugin__networking-console-plugin.json b/locales/fr/plugin__networking-console-plugin.json index da93bd48..dc53cdbc 100644 --- a/locales/fr/plugin__networking-console-plugin.json +++ b/locales/fr/plugin__networking-console-plugin.json @@ -202,6 +202,7 @@ "IPAMLifecycle": "Cycle de vie IPAM", "IPAMLifecycle controls IP addresses management lifecycle.": "IPAMLifecycle contrôle le cycle de vie de la gestion des adresses IP.", "It is not recommended to set this field without explicit need and understanding of the OVN network topology.": "Il n'est pas recommandé de renseigner ce champ sans besoin explicite et sans compréhension de la topologie du réseau OVN.", + "Items per page": "", "JoinSubnets": "Joindre des sous-réseaux", "JoinSubnets are used inside the OVN network topology.": "Les sous-réseaux JoinSubnets sont utilisés au sein de la topologie du réseau OVN.", "Key": "Clé", @@ -277,6 +278,7 @@ "Not found": "Introuvable", "Not Receiving Traffic": "Aucune réception de trafic", "NS selector": "Sélecteur NS", + "of": "", "Only supported when \"subnets\" are set.": "Prise en charge uniquement lorsque les « sous-réseaux » sont définis.", "Operator": "Opérateur", "operator represents a key's relationship to a set of values. Valid operators are In, NotIn, Exists and DoesNotExist.": "L'opérateur `In` représente la relation d'une clé avec un ensemble de valeurs. Les opérateurs valides sont `In`, `NotIn`, `Exists` et `DoesNotExist`.", @@ -286,6 +288,7 @@ "Path that the router watches to route traffic to the service.": "Chemin que le routeur surveille pour acheminer le trafic vers le service.", "Path type": "Type de chemin", "Pending": "En attente", + "per page": "", "Percent": "Pourcent", "Persistent": "Persistant", "Phase": "Phase", diff --git a/locales/ja/plugin__networking-console-plugin.json b/locales/ja/plugin__networking-console-plugin.json index b6a5a790..024d2405 100644 --- a/locales/ja/plugin__networking-console-plugin.json +++ b/locales/ja/plugin__networking-console-plugin.json @@ -200,6 +200,7 @@ "IPAMLifecycle": "IPAMLifecycle", "IPAMLifecycle controls IP addresses management lifecycle.": "IPAMLifecycle は IP アドレス管理ライフサイクルを制御します。", "It is not recommended to set this field without explicit need and understanding of the OVN network topology.": "明確な必要性と OVN のネットワークトポロジーへの理解がない限り、このフィールドを設定することは推奨されません。", + "Items per page": "", "JoinSubnets": "JoinSubnets", "JoinSubnets are used inside the OVN network topology.": "JoinSubnets は、OVN ネットワークトポロジー内で使用されます。", "Key": "キー", @@ -275,6 +276,7 @@ "Not found": "見つかりません", "Not Receiving Traffic": "トラフィックは受信していません", "NS selector": "NS セレクター", + "of": "", "Only supported when \"subnets\" are set.": "\"サブネット\" が設定されている場合にのみサポートされます。", "Operator": "演算子", "operator represents a key's relationship to a set of values. Valid operators are In, NotIn, Exists and DoesNotExist.": "operator は、キーと一連の値との関係を表します。有効な演算子は、In、NotIn、Exists、および DoesNotExist です。", @@ -284,6 +286,7 @@ "Path that the router watches to route traffic to the service.": "ルーターがトラフィックをサービスにルーティングするために監視するパス。", "Path type": "パスのタイプ", "Pending": "保留中", + "per page": "", "Percent": "パーセント", "Persistent": "永続的", "Phase": "フェーズ", diff --git a/locales/ko/plugin__networking-console-plugin.json b/locales/ko/plugin__networking-console-plugin.json index df42432a..1a6f1fba 100644 --- a/locales/ko/plugin__networking-console-plugin.json +++ b/locales/ko/plugin__networking-console-plugin.json @@ -200,6 +200,7 @@ "IPAMLifecycle": "IPAMLifecycle", "IPAMLifecycle controls IP addresses management lifecycle.": "IPAMLifecycle은 IP 주소 관리 라이프사이클을 제어합니다.", "It is not recommended to set this field without explicit need and understanding of the OVN network topology.": "OVN 네트워크 토폴로지에 대한 명확한 이해와 필요성이 없는 상태에서 이 필드를 설정하지 않는 것이 좋습니다.", + "Items per page": "", "JoinSubnets": "JoinSubnets", "JoinSubnets are used inside the OVN network topology.": "JoinSubnets는 OVN 네트워크 토폴로지 내에서 사용됩니다.", "Key": "키", @@ -275,6 +276,7 @@ "Not found": "찾을 수 없음", "Not Receiving Traffic": "트래픽을 수신하지 않음", "NS selector": "NS 선택기", + "of": "", "Only supported when \"subnets\" are set.": "\"subnets\"가 설정된 경우에만 지원됩니다.", "Operator": "Operator", "operator represents a key's relationship to a set of values. Valid operators are In, NotIn, Exists and DoesNotExist.": "Operator는 값 집합에 대한 키의 관계를 나타냅니다. 유효한 연산자는 In, NotIn, Exists 및 DoesNotExist입니다.", @@ -284,6 +286,7 @@ "Path that the router watches to route traffic to the service.": "라우터가 트래픽을 서비스로 라우팅하기 위해 모니터링하는 경로입니다.", "Path type": "경로 유형", "Pending": "대기 중", + "per page": "", "Percent": "백분율", "Persistent": "영구적", "Phase": "단계", diff --git a/locales/zh/plugin__networking-console-plugin.json b/locales/zh/plugin__networking-console-plugin.json index 5a7e10cc..dbaf93b9 100644 --- a/locales/zh/plugin__networking-console-plugin.json +++ b/locales/zh/plugin__networking-console-plugin.json @@ -200,6 +200,7 @@ "IPAMLifecycle": "IPAMLifecycle", "IPAMLifecycle controls IP addresses management lifecycle.": "IPAMLifecycle 控制 IP 地址管理生命周期。", "It is not recommended to set this field without explicit need and understanding of the OVN network topology.": "不建议在没有明确需要并了解 OVN 网络拓扑的情况下设置此字段。", + "Items per page": "", "JoinSubnets": "JoinSubnets", "JoinSubnets are used inside the OVN network topology.": "JoinSubnets 在 OVN 网络拓扑中使用。", "Key": "键", @@ -275,6 +276,7 @@ "Not found": "没有找到", "Not Receiving Traffic": "非接收流量", "NS selector": "NS 选择器", + "of": "", "Only supported when \"subnets\" are set.": "仅在设置 \"subnets\" 时支持。", "Operator": "Operator", "operator represents a key's relationship to a set of values. Valid operators are In, NotIn, Exists and DoesNotExist.": "Operator 代表键与一组值的关系。有效的操作符是 In、NotIn、Exists 和 DoesNotExist。", @@ -284,6 +286,7 @@ "Path that the router watches to route traffic to the service.": "路由监视流向服务路由的路径。", "Path type": "路径类型", "Pending": "待处理", + "per page": "", "Percent": "百分比", "Persistent": "持久性", "Phase": "阶段", diff --git a/src/views/networkpolicies/list/NetworkPolicyList.tsx b/src/views/networkpolicies/list/NetworkPolicyList.tsx index 03e58d63..8eb1d700 100644 --- a/src/views/networkpolicies/list/NetworkPolicyList.tsx +++ b/src/views/networkpolicies/list/NetworkPolicyList.tsx @@ -15,6 +15,7 @@ import ListEmptyState from '@utils/components/ListEmptyState/ListEmptyState'; import { FLAGS } from '@utils/constants'; import { getNetworkPolicyDocURL } from '@utils/constants/documentation'; import { SHARED_DEFAULT_PATH_NEW_RESOURCE_FORM } from '@utils/constants/ui'; +import { useNetworkingTranslation } from '@utils/hooks/useNetworkingTranslation'; import usePagination from '@utils/hooks/usePagination/usePagination'; import { paginationDefaultValues } from '@utils/hooks/usePagination/utils/constants'; import { getResourceURL } from '@utils/resources/shared'; @@ -31,6 +32,7 @@ type NetworkPolicyListProps = { }; const NetworkPolicyList: FC = ({ namespace }) => { + const { t } = useNetworkingTranslation(); const [networkPolicies, loaded, loadError] = useK8sWatchResource< IoK8sApiNetworkingV1NetworkPolicy[] >({ @@ -96,6 +98,11 @@ const NetworkPolicyList: FC = ({ namespace }) => { page={pagination?.page} perPage={pagination?.perPage} perPageOptions={paginationDefaultValues} + titles={{ + itemsPerPage: t('Items per page'), + ofWord: t('of'), + perPageSuffix: t('per page'), + }} /> )} From 9a3e6308b6377e8f496c3ede658a6f86d7d984fb Mon Sep 17 00:00:00 2001 From: Parthiv Krishnan Date: Tue, 18 Aug 2026 12:01:13 -0400 Subject: [PATCH 2/2] fix: removed items per page title --- locales/en/plugin__networking-console-plugin.json | 1 - locales/es/plugin__networking-console-plugin.json | 1 - locales/fr/plugin__networking-console-plugin.json | 1 - locales/ja/plugin__networking-console-plugin.json | 1 - locales/ko/plugin__networking-console-plugin.json | 1 - locales/zh/plugin__networking-console-plugin.json | 1 - src/views/networkpolicies/list/NetworkPolicyList.tsx | 1 - 7 files changed, 7 deletions(-) diff --git a/locales/en/plugin__networking-console-plugin.json b/locales/en/plugin__networking-console-plugin.json index 879c5412..82905ea7 100644 --- a/locales/en/plugin__networking-console-plugin.json +++ b/locales/en/plugin__networking-console-plugin.json @@ -200,7 +200,6 @@ "IPAMLifecycle": "IPAMLifecycle", "IPAMLifecycle controls IP addresses management lifecycle.": "IPAMLifecycle controls IP addresses management lifecycle.", "It is not recommended to set this field without explicit need and understanding of the OVN network topology.": "It is not recommended to set this field without explicit need and understanding of the OVN network topology.", - "Items per page": "Items per page", "JoinSubnets": "JoinSubnets", "JoinSubnets are used inside the OVN network topology.": "JoinSubnets are used inside the OVN network topology.", "Key": "Key", diff --git a/locales/es/plugin__networking-console-plugin.json b/locales/es/plugin__networking-console-plugin.json index 24724b57..32fb6a91 100644 --- a/locales/es/plugin__networking-console-plugin.json +++ b/locales/es/plugin__networking-console-plugin.json @@ -202,7 +202,6 @@ "IPAMLifecycle": "IPAMLifecycle", "IPAMLifecycle controls IP addresses management lifecycle.": "IPAMLifecycle controla el ciclo de vida de la gestión de direcciones IP.", "It is not recommended to set this field without explicit need and understanding of the OVN network topology.": "No se recomienda configurar este campo sin una necesidad explícita y sin comprender la topología de la red OVN.", - "Items per page": "", "JoinSubnets": "JoinSubnets", "JoinSubnets are used inside the OVN network topology.": "JoinSubnets se utiliza dentro de la topología de red OVN.", "Key": "Clave", diff --git a/locales/fr/plugin__networking-console-plugin.json b/locales/fr/plugin__networking-console-plugin.json index dc53cdbc..81be2fad 100644 --- a/locales/fr/plugin__networking-console-plugin.json +++ b/locales/fr/plugin__networking-console-plugin.json @@ -202,7 +202,6 @@ "IPAMLifecycle": "Cycle de vie IPAM", "IPAMLifecycle controls IP addresses management lifecycle.": "IPAMLifecycle contrôle le cycle de vie de la gestion des adresses IP.", "It is not recommended to set this field without explicit need and understanding of the OVN network topology.": "Il n'est pas recommandé de renseigner ce champ sans besoin explicite et sans compréhension de la topologie du réseau OVN.", - "Items per page": "", "JoinSubnets": "Joindre des sous-réseaux", "JoinSubnets are used inside the OVN network topology.": "Les sous-réseaux JoinSubnets sont utilisés au sein de la topologie du réseau OVN.", "Key": "Clé", diff --git a/locales/ja/plugin__networking-console-plugin.json b/locales/ja/plugin__networking-console-plugin.json index 024d2405..c42017ff 100644 --- a/locales/ja/plugin__networking-console-plugin.json +++ b/locales/ja/plugin__networking-console-plugin.json @@ -200,7 +200,6 @@ "IPAMLifecycle": "IPAMLifecycle", "IPAMLifecycle controls IP addresses management lifecycle.": "IPAMLifecycle は IP アドレス管理ライフサイクルを制御します。", "It is not recommended to set this field without explicit need and understanding of the OVN network topology.": "明確な必要性と OVN のネットワークトポロジーへの理解がない限り、このフィールドを設定することは推奨されません。", - "Items per page": "", "JoinSubnets": "JoinSubnets", "JoinSubnets are used inside the OVN network topology.": "JoinSubnets は、OVN ネットワークトポロジー内で使用されます。", "Key": "キー", diff --git a/locales/ko/plugin__networking-console-plugin.json b/locales/ko/plugin__networking-console-plugin.json index 1a6f1fba..93678dff 100644 --- a/locales/ko/plugin__networking-console-plugin.json +++ b/locales/ko/plugin__networking-console-plugin.json @@ -200,7 +200,6 @@ "IPAMLifecycle": "IPAMLifecycle", "IPAMLifecycle controls IP addresses management lifecycle.": "IPAMLifecycle은 IP 주소 관리 라이프사이클을 제어합니다.", "It is not recommended to set this field without explicit need and understanding of the OVN network topology.": "OVN 네트워크 토폴로지에 대한 명확한 이해와 필요성이 없는 상태에서 이 필드를 설정하지 않는 것이 좋습니다.", - "Items per page": "", "JoinSubnets": "JoinSubnets", "JoinSubnets are used inside the OVN network topology.": "JoinSubnets는 OVN 네트워크 토폴로지 내에서 사용됩니다.", "Key": "키", diff --git a/locales/zh/plugin__networking-console-plugin.json b/locales/zh/plugin__networking-console-plugin.json index dbaf93b9..8c3efcab 100644 --- a/locales/zh/plugin__networking-console-plugin.json +++ b/locales/zh/plugin__networking-console-plugin.json @@ -200,7 +200,6 @@ "IPAMLifecycle": "IPAMLifecycle", "IPAMLifecycle controls IP addresses management lifecycle.": "IPAMLifecycle 控制 IP 地址管理生命周期。", "It is not recommended to set this field without explicit need and understanding of the OVN network topology.": "不建议在没有明确需要并了解 OVN 网络拓扑的情况下设置此字段。", - "Items per page": "", "JoinSubnets": "JoinSubnets", "JoinSubnets are used inside the OVN network topology.": "JoinSubnets 在 OVN 网络拓扑中使用。", "Key": "键", diff --git a/src/views/networkpolicies/list/NetworkPolicyList.tsx b/src/views/networkpolicies/list/NetworkPolicyList.tsx index 8eb1d700..23a1f391 100644 --- a/src/views/networkpolicies/list/NetworkPolicyList.tsx +++ b/src/views/networkpolicies/list/NetworkPolicyList.tsx @@ -99,7 +99,6 @@ const NetworkPolicyList: FC = ({ namespace }) => { perPage={pagination?.perPage} perPageOptions={paginationDefaultValues} titles={{ - itemsPerPage: t('Items per page'), ofWord: t('of'), perPageSuffix: t('per page'), }}