Skip to content

feat: show warning on unrecognized idp group and role mapping claims #16485

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 25 commits into from
Feb 7, 2025
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
rename
  • Loading branch information
aslilac committed Feb 6, 2025
commit 97de7f4b72fb31b96de2ad0352eabaf5515d1d40
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ import { OrganizationPills } from "./OrganizationPills";

interface IdpSyncPageViewProps {
organizationSyncSettings: OrganizationSyncSettings | undefined;
fieldValues: readonly string[] | undefined;
claimFieldValues: readonly string[] | undefined;
organizations: readonly Organization[];
onSubmit: (data: OrganizationSyncSettings) => void;
onSyncFieldChange: (value: string) => void;
Expand Down Expand Up @@ -85,7 +85,7 @@ const validationSchema = Yup.object({

export const IdpOrgSyncPageView: FC<IdpSyncPageViewProps> = ({
organizationSyncSettings,
fieldValues,
claimFieldValues,
organizations,
onSubmit,
onSyncFieldChange,
Expand Down Expand Up @@ -137,7 +137,7 @@ export const IdpOrgSyncPageView: FC<IdpSyncPageViewProps> = ({
if (
event.key === "Enter" &&
inputValue &&
!fieldValues?.some((value) => value === inputValue.toLowerCase())
!claimFieldValues?.some((value) => value === inputValue.toLowerCase())
) {
event.preventDefault();
setIdpOrgName(inputValue);
Expand Down Expand Up @@ -220,10 +220,10 @@ export const IdpOrgSyncPageView: FC<IdpSyncPageViewProps> = ({
IdP organization name
</Label>

{fieldValues ? (
{claimFieldValues ? (
<Combobox
value={idpOrgName}
options={fieldValues}
options={claimFieldValues}
placeholder="Select IdP organization"
open={open}
onOpenChange={setOpen}
Expand Down Expand Up @@ -314,7 +314,7 @@ export const IdpOrgSyncPageView: FC<IdpSyncPageViewProps> = ({
idpOrg={idpOrg}
coderOrgs={getOrgNames(organizations)}
onDelete={handleDelete}
exists={fieldValues?.includes(idpOrg)}
exists={claimFieldValues?.includes(idpOrg)}
/>
))}
</IdpMappingTable>
Expand Down
Loading