some migrations have empty name (#34288)
fixes: #33309 Signed-off-by: Erik Jan de Wit <erikjan.dewit@gmail.com>
This commit is contained in:
parent
65f4ea9c8c
commit
b47a8b3f05
1 changed files with 5 additions and 5 deletions
|
@ -20,7 +20,7 @@ type DataType = RequiredActionProviderRepresentation &
|
||||||
};
|
};
|
||||||
|
|
||||||
type Row = {
|
type Row = {
|
||||||
name: string;
|
name?: string;
|
||||||
enabled: boolean;
|
enabled: boolean;
|
||||||
defaultAction: boolean;
|
defaultAction: boolean;
|
||||||
data: DataType;
|
data: DataType;
|
||||||
|
@ -173,14 +173,14 @@ export const RequiredActions = () => {
|
||||||
displayKey: "enabled",
|
displayKey: "enabled",
|
||||||
cellRenderer: (row) => (
|
cellRenderer: (row) => (
|
||||||
<Switch
|
<Switch
|
||||||
id={`enable-${toKey(row.name)}`}
|
id={`enable-${toKey(row.name || "")}`}
|
||||||
label={t("on")}
|
label={t("on")}
|
||||||
labelOff={t("off")}
|
labelOff={t("off")}
|
||||||
isChecked={row.enabled}
|
isChecked={row.enabled}
|
||||||
onChange={() => {
|
onChange={() => {
|
||||||
updateAction(row.data, "enabled");
|
updateAction(row.data, "enabled");
|
||||||
}}
|
}}
|
||||||
aria-label={toKey(row.name)}
|
aria-label={row.name}
|
||||||
/>
|
/>
|
||||||
),
|
),
|
||||||
width: 20,
|
width: 20,
|
||||||
|
@ -191,7 +191,7 @@ export const RequiredActions = () => {
|
||||||
thTooltipText: "authDefaultActionTooltip",
|
thTooltipText: "authDefaultActionTooltip",
|
||||||
cellRenderer: (row) => (
|
cellRenderer: (row) => (
|
||||||
<Switch
|
<Switch
|
||||||
id={`default-${toKey(row.name)}`}
|
id={`default-${toKey(row.name || "")}`}
|
||||||
label={t("on")}
|
label={t("on")}
|
||||||
isDisabled={!row.enabled}
|
isDisabled={!row.enabled}
|
||||||
labelOff={!row.enabled ? t("disabledOff") : t("off")}
|
labelOff={!row.enabled ? t("disabledOff") : t("off")}
|
||||||
|
@ -199,7 +199,7 @@ export const RequiredActions = () => {
|
||||||
onChange={() => {
|
onChange={() => {
|
||||||
updateAction(row.data, "defaultAction");
|
updateAction(row.data, "defaultAction");
|
||||||
}}
|
}}
|
||||||
aria-label={toKey(row.name)}
|
aria-label={row.name}
|
||||||
/>
|
/>
|
||||||
),
|
),
|
||||||
width: 20,
|
width: 20,
|
||||||
|
|
Loading…
Reference in a new issue