Compare commits
9 Commits
Author | SHA1 | Date | |
---|---|---|---|
b2e9ddaa4f | |||
4338b3ecb7 | |||
0f81d9f146 | |||
9980b10a83 | |||
6bfd388827 | |||
8203ed687b | |||
f394e06e4d | |||
8db35a81da | |||
2e0ebfcf58 |
@ -41,7 +41,7 @@
|
|||||||
<img width="400" src="https://github.com/user-attachments/assets/6bf3bef9-00b0-4460-97b9-0d2da8500798">
|
<img width="400" src="https://github.com/user-attachments/assets/6bf3bef9-00b0-4460-97b9-0d2da8500798">
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
Keycloakify is fully compatible with Keycloak 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, [~~22~~](https://github.com/keycloakify/keycloakify/issues/389#issuecomment-1822509763), 23, 24, 25...[and beyond](https://github.com/keycloakify/keycloakify/discussions/346#discussioncomment-5889791)
|
Keycloakify is fully compatible with Keycloak from version 11 to 25...[and beyond](https://github.com/keycloakify/keycloakify/discussions/346#discussioncomment-5889791)
|
||||||
|
|
||||||
## Sponsors
|
## Sponsors
|
||||||
|
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "keycloakify",
|
"name": "keycloakify",
|
||||||
"version": "10.0.1",
|
"version": "10.0.5",
|
||||||
"description": "Create Keycloak themes using React",
|
"description": "Create Keycloak themes using React",
|
||||||
"repository": {
|
"repository": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
|
@ -60,14 +60,14 @@ export function updateAccountThemeImplementationInConfig(params: {
|
|||||||
{
|
{
|
||||||
const parsedPackageJson = (() => {
|
const parsedPackageJson = (() => {
|
||||||
type ParsedPackageJson = {
|
type ParsedPackageJson = {
|
||||||
keycloakify: Record<string, string>;
|
keycloakify: Record<string, unknown>;
|
||||||
};
|
};
|
||||||
|
|
||||||
const zParsedPackageJson = (() => {
|
const zParsedPackageJson = (() => {
|
||||||
type TargetType = ParsedPackageJson;
|
type TargetType = ParsedPackageJson;
|
||||||
|
|
||||||
const zTargetType = z.object({
|
const zTargetType = z.object({
|
||||||
keycloakify: z.record(z.string())
|
keycloakify: z.record(z.unknown())
|
||||||
});
|
});
|
||||||
|
|
||||||
assert<Equals<z.infer<typeof zTargetType>, TargetType>>();
|
assert<Equals<z.infer<typeof zTargetType>, TargetType>>();
|
||||||
@ -75,17 +75,22 @@ export function updateAccountThemeImplementationInConfig(params: {
|
|||||||
return id<z.ZodType<TargetType>>(zTargetType);
|
return id<z.ZodType<TargetType>>(zTargetType);
|
||||||
})();
|
})();
|
||||||
|
|
||||||
return zParsedPackageJson.parse(
|
const parsedPackageJson = JSON.parse(
|
||||||
JSON.parse(
|
fs.readFileSync(buildContext.packageJsonFilePath).toString("utf8")
|
||||||
fs
|
|
||||||
.readFileSync(buildContext.packageJsonFilePath)
|
|
||||||
.toString("utf8")
|
|
||||||
)
|
|
||||||
);
|
);
|
||||||
|
|
||||||
|
zParsedPackageJson.parse(parsedPackageJson);
|
||||||
|
|
||||||
|
return parsedPackageJson;
|
||||||
})();
|
})();
|
||||||
|
|
||||||
parsedPackageJson.keycloakify.accountThemeImplementation =
|
parsedPackageJson.keycloakify.accountThemeImplementation =
|
||||||
accountThemeType;
|
accountThemeType;
|
||||||
|
|
||||||
|
fs.writeFileSync(
|
||||||
|
buildContext.packageJsonFilePath,
|
||||||
|
Buffer.from(JSON.stringify(parsedPackageJson, undefined, 4), "utf8")
|
||||||
|
);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -30,6 +30,7 @@ export async function command(params: { cliCommandOptions: CliCommandOptions })
|
|||||||
// NOTE: This is arbitrary
|
// NOTE: This is arbitrary
|
||||||
startingFromMajor: 17,
|
startingFromMajor: 17,
|
||||||
excludeMajorVersions: [],
|
excludeMajorVersions: [],
|
||||||
|
doOmitPatch: false,
|
||||||
buildContext
|
buildContext
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -14,9 +14,10 @@ assert<BuildContext extends BuildContextLike ? true : false>();
|
|||||||
export async function promptKeycloakVersion(params: {
|
export async function promptKeycloakVersion(params: {
|
||||||
startingFromMajor: number | undefined;
|
startingFromMajor: number | undefined;
|
||||||
excludeMajorVersions: number[];
|
excludeMajorVersions: number[];
|
||||||
|
doOmitPatch: boolean;
|
||||||
buildContext: BuildContextLike;
|
buildContext: BuildContextLike;
|
||||||
}) {
|
}) {
|
||||||
const { startingFromMajor, excludeMajorVersions, buildContext } = params;
|
const { startingFromMajor, excludeMajorVersions, doOmitPatch, buildContext } = params;
|
||||||
|
|
||||||
const semVersionedTagByMajor = new Map<number, { tag: string; version: SemVer }>();
|
const semVersionedTagByMajor = new Map<number, { tag: string; version: SemVer }>();
|
||||||
|
|
||||||
@ -55,7 +56,8 @@ export async function promptKeycloakVersion(params: {
|
|||||||
});
|
});
|
||||||
|
|
||||||
const lastMajorVersions = Array.from(semVersionedTagByMajor.values()).map(
|
const lastMajorVersions = Array.from(semVersionedTagByMajor.values()).map(
|
||||||
({ version }) => `${version.major}.${version.minor}`
|
({ version }) =>
|
||||||
|
`${version.major}.${version.minor}${doOmitPatch ? "" : `.${version.patch}`}`
|
||||||
);
|
);
|
||||||
|
|
||||||
const { value } = await cliSelect<string>({
|
const { value } = await cliSelect<string>({
|
||||||
|
@ -115,6 +115,7 @@ export async function command(params: { cliCommandOptions: CliCommandOptions })
|
|||||||
const { keycloakVersion } = await promptKeycloakVersion({
|
const { keycloakVersion } = await promptKeycloakVersion({
|
||||||
startingFromMajor: 18,
|
startingFromMajor: 18,
|
||||||
excludeMajorVersions: [22],
|
excludeMajorVersions: [22],
|
||||||
|
doOmitPatch: true,
|
||||||
buildContext
|
buildContext
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -43,7 +43,7 @@ export default function Login(props: PageProps<Extract<KcContext, { pageId: "log
|
|||||||
}
|
}
|
||||||
socialProvidersNode={
|
socialProvidersNode={
|
||||||
<>
|
<>
|
||||||
{realm.password && social.providers?.length && (
|
{realm.password && social.providers !== undefined && social.providers.length !== 0 && (
|
||||||
<div id="kc-social-providers" className={kcClsx("kcFormSocialAccountSectionClass")}>
|
<div id="kc-social-providers" className={kcClsx("kcFormSocialAccountSectionClass")}>
|
||||||
<hr />
|
<hr />
|
||||||
<h2>{msg("identity-provider-login-label")}</h2>
|
<h2>{msg("identity-provider-login-label")}</h2>
|
||||||
|
@ -40,7 +40,7 @@ export default function LoginUsername(props: PageProps<Extract<KcContext, { page
|
|||||||
headerNode={msg("doLogIn")}
|
headerNode={msg("doLogIn")}
|
||||||
socialProvidersNode={
|
socialProvidersNode={
|
||||||
<>
|
<>
|
||||||
{realm.password && social.providers?.length && (
|
{realm.password && social.providers !== undefined && social.providers.length !== 0 && (
|
||||||
<div id="kc-social-providers" className={kcClsx("kcFormSocialAccountSectionClass")}>
|
<div id="kc-social-providers" className={kcClsx("kcFormSocialAccountSectionClass")}>
|
||||||
<hr />
|
<hr />
|
||||||
<h2>{msg("identity-provider-login-label")}</h2>
|
<h2>{msg("identity-provider-login-label")}</h2>
|
||||||
|
Reference in New Issue
Block a user