Merge pull request #681 from keycloakify/keycloak-26
Update version target range
This commit is contained in:
commit
2e9da33622
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "keycloakify",
|
"name": "keycloakify",
|
||||||
"version": "11.2.8",
|
"version": "11.2.9-rc.1",
|
||||||
"description": "Framework to create custom Keycloak UIs",
|
"description": "Framework to create custom Keycloak UIs",
|
||||||
"repository": {
|
"repository": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
|
@ -52,9 +52,9 @@ export function getKeycloakVersionRangeForJar(params: {
|
|||||||
case "0.6":
|
case "0.6":
|
||||||
switch (keycloakThemeAdditionalInfoExtensionVersion) {
|
switch (keycloakThemeAdditionalInfoExtensionVersion) {
|
||||||
case null:
|
case null:
|
||||||
return undefined;
|
return "26-and-above" as const;
|
||||||
case "1.1.5":
|
case "1.1.5":
|
||||||
return "25-and-above" as const;
|
return "25" as const;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
assert<Equals<typeof keycloakAccountV1Version, never>>(false);
|
assert<Equals<typeof keycloakAccountV1Version, never>>(false);
|
||||||
@ -75,9 +75,9 @@ export function getKeycloakVersionRangeForJar(params: {
|
|||||||
}
|
}
|
||||||
switch (keycloakThemeAdditionalInfoExtensionVersion) {
|
switch (keycloakThemeAdditionalInfoExtensionVersion) {
|
||||||
case null:
|
case null:
|
||||||
return "21-and-below";
|
return "all-other-versions";
|
||||||
case "1.1.5":
|
case "1.1.5":
|
||||||
return "22-and-above";
|
return "22-to-25";
|
||||||
}
|
}
|
||||||
assert<Equals<typeof keycloakThemeAdditionalInfoExtensionVersion, never>>(
|
assert<Equals<typeof keycloakThemeAdditionalInfoExtensionVersion, never>>(
|
||||||
false
|
false
|
||||||
|
@ -235,6 +235,9 @@ function decodeHtmlEntities(htmlStr){
|
|||||||
"identityFederationEnabled",
|
"identityFederationEnabled",
|
||||||
"userManagedAccessAllowed"
|
"userManagedAccessAllowed"
|
||||||
]?seq_contains(key)
|
]?seq_contains(key)
|
||||||
|
) || (
|
||||||
|
["flowContext", "session", "realm"]?seq_contains(key) &&
|
||||||
|
areSamePath(path, ["social"])
|
||||||
)
|
)
|
||||||
>
|
>
|
||||||
<#-- <#local outSeq += ["/*" + path?join(".") + "." + key + " excluded*/"]> -->
|
<#-- <#local outSeq += ["/*" + path?join(".") + "." + key + " excluded*/"]> -->
|
||||||
|
@ -3,7 +3,7 @@ export type KeycloakVersionRange =
|
|||||||
| KeycloakVersionRange.WithoutAccountV1Theme;
|
| KeycloakVersionRange.WithoutAccountV1Theme;
|
||||||
|
|
||||||
export namespace KeycloakVersionRange {
|
export namespace KeycloakVersionRange {
|
||||||
export type WithoutAccountV1Theme = "21-and-below" | "22-and-above";
|
export type WithoutAccountV1Theme = "22-to-25" | "all-other-versions";
|
||||||
|
|
||||||
export type WithAccountV1Theme = "21-and-below" | "23" | "24" | "25-and-above";
|
export type WithAccountV1Theme = "21-and-below" | "23" | "24" | "25" | "26-and-above";
|
||||||
}
|
}
|
||||||
|
@ -25,6 +25,7 @@ import { type ThemeType } from "./constants";
|
|||||||
import { id } from "tsafe/id";
|
import { id } from "tsafe/id";
|
||||||
import chalk from "chalk";
|
import chalk from "chalk";
|
||||||
import { getProxyFetchOptions, type ProxyFetchOptions } from "../tools/fetchProxyOptions";
|
import { getProxyFetchOptions, type ProxyFetchOptions } from "../tools/fetchProxyOptions";
|
||||||
|
import { is } from "tsafe/is";
|
||||||
|
|
||||||
export type BuildContext = {
|
export type BuildContext = {
|
||||||
themeVersion: string;
|
themeVersion: string;
|
||||||
@ -276,7 +277,8 @@ export function getBuildContext(params: {
|
|||||||
"21-and-below": z.union([z.boolean(), z.string()]),
|
"21-and-below": z.union([z.boolean(), z.string()]),
|
||||||
"23": z.union([z.boolean(), z.string()]),
|
"23": z.union([z.boolean(), z.string()]),
|
||||||
"24": z.union([z.boolean(), z.string()]),
|
"24": z.union([z.boolean(), z.string()]),
|
||||||
"25-and-above": z.union([z.boolean(), z.string()])
|
"25": z.union([z.boolean(), z.string()]),
|
||||||
|
"26-and-above": z.union([z.boolean(), z.string()])
|
||||||
})
|
})
|
||||||
.optional()
|
.optional()
|
||||||
});
|
});
|
||||||
@ -297,8 +299,8 @@ export function getBuildContext(params: {
|
|||||||
]),
|
]),
|
||||||
keycloakVersionTargets: z
|
keycloakVersionTargets: z
|
||||||
.object({
|
.object({
|
||||||
"21-and-below": z.union([z.boolean(), z.string()]),
|
"22-to-25": z.union([z.boolean(), z.string()]),
|
||||||
"22-and-above": z.union([z.boolean(), z.string()])
|
"all-other-versions": z.union([z.boolean(), z.string()])
|
||||||
})
|
})
|
||||||
.optional()
|
.optional()
|
||||||
});
|
});
|
||||||
@ -766,7 +768,11 @@ export function getBuildContext(params: {
|
|||||||
return "24" as const;
|
return "24" as const;
|
||||||
}
|
}
|
||||||
|
|
||||||
return "25-and-above" as const;
|
if (buildForKeycloakMajorVersionNumber === 25) {
|
||||||
|
return "25" as const;
|
||||||
|
}
|
||||||
|
|
||||||
|
return "26-and-above" as const;
|
||||||
})();
|
})();
|
||||||
|
|
||||||
assert<
|
assert<
|
||||||
@ -779,11 +785,14 @@ export function getBuildContext(params: {
|
|||||||
return keycloakVersionRange;
|
return keycloakVersionRange;
|
||||||
} else {
|
} else {
|
||||||
const keycloakVersionRange = (() => {
|
const keycloakVersionRange = (() => {
|
||||||
if (buildForKeycloakMajorVersionNumber <= 21) {
|
if (
|
||||||
return "21-and-below" as const;
|
buildForKeycloakMajorVersionNumber <= 21 ||
|
||||||
|
buildForKeycloakMajorVersionNumber >= 26
|
||||||
|
) {
|
||||||
|
return "all-other-versions" as const;
|
||||||
}
|
}
|
||||||
|
|
||||||
return "22-and-above" as const;
|
return "22-to-25" as const;
|
||||||
})();
|
})();
|
||||||
|
|
||||||
assert<
|
assert<
|
||||||
@ -801,6 +810,12 @@ export function getBuildContext(params: {
|
|||||||
use_custom_jar_basename: {
|
use_custom_jar_basename: {
|
||||||
const { keycloakVersionTargets } = buildOptions;
|
const { keycloakVersionTargets } = buildOptions;
|
||||||
|
|
||||||
|
assert(
|
||||||
|
is<Record<KeycloakVersionRange, string | boolean>>(
|
||||||
|
keycloakVersionTargets
|
||||||
|
)
|
||||||
|
);
|
||||||
|
|
||||||
if (keycloakVersionTargets === undefined) {
|
if (keycloakVersionTargets === undefined) {
|
||||||
break use_custom_jar_basename;
|
break use_custom_jar_basename;
|
||||||
}
|
}
|
||||||
@ -845,7 +860,8 @@ export function getBuildContext(params: {
|
|||||||
"21-and-below",
|
"21-and-below",
|
||||||
"23",
|
"23",
|
||||||
"24",
|
"24",
|
||||||
"25-and-above"
|
"25",
|
||||||
|
"26-and-above"
|
||||||
] as const) {
|
] as const) {
|
||||||
assert<
|
assert<
|
||||||
Equals<
|
Equals<
|
||||||
@ -861,8 +877,8 @@ export function getBuildContext(params: {
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
for (const keycloakVersionRange of [
|
for (const keycloakVersionRange of [
|
||||||
"21-and-below",
|
"22-to-25",
|
||||||
"22-and-above"
|
"all-other-versions"
|
||||||
] as const) {
|
] as const) {
|
||||||
assert<
|
assert<
|
||||||
Equals<
|
Equals<
|
||||||
@ -888,7 +904,17 @@ export function getBuildContext(params: {
|
|||||||
const jarTargets: BuildContext["jarTargets"] = [];
|
const jarTargets: BuildContext["jarTargets"] = [];
|
||||||
|
|
||||||
for (const [keycloakVersionRange, jarNameOrBoolean] of objectEntries(
|
for (const [keycloakVersionRange, jarNameOrBoolean] of objectEntries(
|
||||||
buildOptions.keycloakVersionTargets
|
(() => {
|
||||||
|
const { keycloakVersionTargets } = buildOptions;
|
||||||
|
|
||||||
|
assert(
|
||||||
|
is<Record<KeycloakVersionRange, string | boolean>>(
|
||||||
|
keycloakVersionTargets
|
||||||
|
)
|
||||||
|
);
|
||||||
|
|
||||||
|
return keycloakVersionTargets;
|
||||||
|
})()
|
||||||
)) {
|
)) {
|
||||||
if (jarNameOrBoolean === false) {
|
if (jarNameOrBoolean === false) {
|
||||||
continue;
|
continue;
|
||||||
|
2400
src/bin/start-keycloak/myrealm-realm-26.json
Normal file
2400
src/bin/start-keycloak/myrealm-realm-26.json
Normal file
File diff suppressed because it is too large
Load Diff
Loading…
x
Reference in New Issue
Block a user