Compare commits

...

9 Commits

5 changed files with 38 additions and 12 deletions

View File

@ -40,7 +40,7 @@
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** [and up](https://github.com/keycloakify/keycloakify/discussions/346#discussioncomment-5889791)! 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** [and up](https://github.com/keycloakify/keycloakify/discussions/346#discussioncomment-5889791)!
## Sponsor 👼 ## Sponsor
We are exclusively sponsored by [Cloud IAM](https://cloud-iam.com/?mtm_campaign=keycloakify-deal&mtm_source=keycloakify-github), a French company offering Keycloak as a service. We are exclusively sponsored by [Cloud IAM](https://cloud-iam.com/?mtm_campaign=keycloakify-deal&mtm_source=keycloakify-github), a French company offering Keycloak as a service.
Their dedicated support helps us continue the development and maintenance of this project. Their dedicated support helps us continue the development and maintenance of this project.

View File

@ -1,6 +1,6 @@
{ {
"name": "keycloakify", "name": "keycloakify",
"version": "9.5.1", "version": "9.5.5",
"description": "Create Keycloak themes using React", "description": "Create Keycloak themes using React",
"repository": { "repository": {
"type": "git", "type": "git",

View File

@ -128,7 +128,10 @@ export function readBuildOptions(params: { processArgv: string[] }): BuildOption
}); });
} }
return resolvedViteConfig?.buildDir === undefined ? "build_keycloak" : `${resolvedViteConfig.buildDir}_keycloak`; return pathJoin(
reactAppRootDirPath,
resolvedViteConfig?.buildDir === undefined ? "build_keycloak" : `${resolvedViteConfig.buildDir}_keycloak`
);
})(), })(),
"publicDirPath": (() => { "publicDirPath": (() => {
webpack: { webpack: {

View File

@ -431,7 +431,7 @@
<#if isHash> <#if isHash>
<#if path?size gt 10> <#if path?size gt 10>
<#return "ABORT: Too many recursive calls"> <#return "ABORT: Too many recursive calls, path: " + path?join(".")>
</#if> </#if>
<#local keys = ""> <#local keys = "">
@ -489,13 +489,17 @@
!["name", "displayName", "displayNameHtml", "internationalizationEnabled", "registrationEmailAsUsername" ]?seq_contains(key) !["name", "displayName", "displayNameHtml", "internationalizationEnabled", "registrationEmailAsUsername" ]?seq_contains(key)
) || ( ) || (
"applications.ftl" == pageId && "applications.ftl" == pageId &&
are_same_path(path, ["applications", "applications", "*", "client", "realm"]) is_subpath(path, ["applications", "applications"]) &&
(
key == "realm" ||
key == "container"
)
) || ( ) || (
"applications.ftl" == pageId && are_same_path(path, ["user"]) &&
"masterAdminClient" == key key == "delegateForUpdate"
) )
> >
<#local out_seq += ["/*If you need '" + key + "' on " + pageId + ", please submit an issue to the Keycloakify repo*/"]> <#local out_seq += ["/*If you need '" + path?join(".") + "." + key + "' on " + pageId + ", please submit an issue to the Keycloakify repo*/"]>
<#continue> <#continue>
</#if> </#if>
@ -664,9 +668,9 @@
<#return "ABORT: Couldn't convert into string non hash, non method, non boolean, non enumerable object"> <#return "ABORT: Couldn't convert into string non hash, non method, non boolean, non enumerable object">
</#function> </#function>
<#function are_same_path path searchedPath> <#function is_subpath path searchedPath>
<#if path?size != searchedPath?size> <#if path?size < searchedPath?size>
<#return false> <#return false>
</#if> </#if>
@ -674,8 +678,14 @@
<#list path as property> <#list path as property>
<#if i == searchedPath?size >
<#continue>
</#if>
<#local searchedProperty=searchedPath[i]> <#local searchedProperty=searchedPath[i]>
<#local i+= 1>
<#if searchedProperty?is_string && searchedProperty == "*"> <#if searchedProperty?is_string && searchedProperty == "*">
<#continue> <#continue>
</#if> </#if>
@ -692,11 +702,13 @@
<#return false> <#return false>
</#if> </#if>
<#local i+= 1>
</#list> </#list>
<#return true> <#return true>
</#function> </#function>
<#function are_same_path path searchedPath>
<#return path?size == searchedPath?size && is_subpath(path, searchedPath)>
</#function>
</script> </script>

View File

@ -244,6 +244,17 @@ export declare namespace KcContext {
export type Terms = Common & { export type Terms = Common & {
pageId: "terms.ftl"; pageId: "terms.ftl";
//NOTE: Optional because maybe it wasn't defined in older keycloak versions.
user?: {
id: string;
username: string;
attributes: Record<string, string[]>;
email: string;
emailVerified: boolean;
firstName?: string;
lastName?: string;
markedForEviction?: boolean;
};
}; };
export type LoginDeviceVerifyUserCode = Common & { export type LoginDeviceVerifyUserCode = Common & {