mirror of
https://github.com/zitadel/zitadel.git
synced 2025-12-11 19:52:18 +00:00
idp components
This commit is contained in:
2
.gitignore
vendored
2
.gitignore
vendored
@@ -17,3 +17,5 @@ packages/zitadel-server/src/app/proto
|
||||
packages/zitadel-client/src/app/proto
|
||||
.vscode
|
||||
.idea
|
||||
.vercel
|
||||
.env*.local
|
||||
|
||||
@@ -50,19 +50,49 @@ export async function SignInWithIDP(props: SignInWithIDPProps) {
|
||||
identityProviders.map((idp, i) => {
|
||||
switch (idp.type) {
|
||||
case IdentityProviderType.IDENTITY_PROVIDER_TYPE_GITHUB:
|
||||
return <SignInWithGithub key={`idp-${i}`}></SignInWithGithub>;
|
||||
return (
|
||||
<SignInWithGithub
|
||||
key={`idp-${i}`}
|
||||
name={idp.name}
|
||||
></SignInWithGithub>
|
||||
);
|
||||
case IdentityProviderType.IDENTITY_PROVIDER_TYPE_GITHUB_ES:
|
||||
return <SignInWithGithub key={`idp-${i}`}></SignInWithGithub>;
|
||||
return (
|
||||
<SignInWithGithub
|
||||
key={`idp-${i}`}
|
||||
name={idp.name}
|
||||
></SignInWithGithub>
|
||||
);
|
||||
case IdentityProviderType.IDENTITY_PROVIDER_TYPE_AZURE_AD:
|
||||
return <SignInWithAzureAD key={`idp-${i}`}></SignInWithAzureAD>;
|
||||
return (
|
||||
<SignInWithAzureAD
|
||||
key={`idp-${i}`}
|
||||
name={idp.name}
|
||||
></SignInWithAzureAD>
|
||||
);
|
||||
case IdentityProviderType.IDENTITY_PROVIDER_TYPE_GOOGLE:
|
||||
return <SignInWithGoogle key={`idp-${i}`}></SignInWithGoogle>;
|
||||
return (
|
||||
<SignInWithGoogle
|
||||
key={`idp-${i}`}
|
||||
name={idp.name}
|
||||
></SignInWithGoogle>
|
||||
);
|
||||
case IdentityProviderType.IDENTITY_PROVIDER_TYPE_GITLAB:
|
||||
return <SignInWithGitlab key={`idp-${i}`}></SignInWithGitlab>;
|
||||
return (
|
||||
<SignInWithGitlab
|
||||
key={`idp-${i}`}
|
||||
name={idp.name}
|
||||
></SignInWithGitlab>
|
||||
);
|
||||
case IdentityProviderType.IDENTITY_PROVIDER_TYPE_GITLAB_SELF_HOSTED:
|
||||
return <SignInWithGitlab key={`idp-${i}`}></SignInWithGitlab>;
|
||||
return (
|
||||
<SignInWithGitlab
|
||||
key={`idp-${i}`}
|
||||
name={idp.name}
|
||||
></SignInWithGitlab>
|
||||
);
|
||||
default:
|
||||
return <div></div>;
|
||||
return <div>{idp.name}</div>;
|
||||
}
|
||||
})}
|
||||
{props.children}
|
||||
|
||||
@@ -1,12 +1,9 @@
|
||||
{
|
||||
"extends": [
|
||||
"//"
|
||||
],
|
||||
"extends": ["//"],
|
||||
"pipeline": {
|
||||
"build": {
|
||||
"outputs": [
|
||||
"dist/**"
|
||||
]
|
||||
"outputs": ["dist/**"],
|
||||
"dependsOn": ["@zitadel/react#build"]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
export interface SignInWithIdentityProviderProps {
|
||||
children?: React.ReactNode;
|
||||
name?: string;
|
||||
}
|
||||
|
||||
@@ -32,7 +32,9 @@ export function SignInWithAzureAD(props: SignInWithAzureADProps) {
|
||||
/>
|
||||
</svg>
|
||||
</div>
|
||||
<span className="ztdl-ml-4">Sign in with AzureAD</span>
|
||||
<span className="ztdl-ml-4">
|
||||
{props.name ? props.name : "Sign in with AzureAD"}
|
||||
</span>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
import * as React from "react";
|
||||
import { SignInWithIdentityProviderProps } from "./SignInWith";
|
||||
|
||||
export interface SignInWithGithubProps
|
||||
@@ -33,7 +32,9 @@ export function SignInWithGithub(props: SignInWithGithubProps) {
|
||||
/>
|
||||
</svg>
|
||||
</div>
|
||||
<span className="ztdl-ml-4">Sign in with Github</span>
|
||||
<span className="ztdl-ml-4">
|
||||
{props.name ? props.name : "Sign in with Github"}
|
||||
</span>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -32,7 +32,9 @@ export function SignInWithGitlab(props: SignInWithGitlabProps) {
|
||||
/>
|
||||
</svg>
|
||||
</div>
|
||||
<span className="ztdl-ml-4">Sign in with Gitlab</span>
|
||||
<span className="ztdl-ml-4">
|
||||
{props.name ? props.name : "Sign in with Gitlab"}
|
||||
</span>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
import * as React from "react";
|
||||
import { SignInWithIdentityProviderProps } from "./SignInWith";
|
||||
|
||||
export interface SignInWithGoogleProps
|
||||
@@ -49,7 +48,9 @@ export function SignInWithGoogle(props: SignInWithGoogleProps) {
|
||||
/>
|
||||
</svg>
|
||||
</div>
|
||||
<span className="ztdl-ml-4">Sign in with Google</span>
|
||||
<span className="ztdl-ml-4">
|
||||
{props.name ? props.name : "Sign in with Google"}
|
||||
</span>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -1,12 +1,8 @@
|
||||
{
|
||||
"extends": [
|
||||
"//"
|
||||
],
|
||||
"extends": ["//"],
|
||||
"pipeline": {
|
||||
"build": {
|
||||
"outputs": [
|
||||
"dist/**"
|
||||
]
|
||||
"outputs": ["dist/**"]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
3470
pnpm-lock.yaml
generated
3470
pnpm-lock.yaml
generated
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user