keycloak-scim/js/apps/account-ui/pom.xml

133 lines
5.4 KiB
XML
Raw Normal View History

<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<artifactId>keycloak-js-parent</artifactId>
<groupId>org.keycloak</groupId>
<version>999.0.0-SNAPSHOT</version>
<relativePath>../../pom.xml</relativePath>
</parent>
<artifactId>keycloak-account-ui</artifactId>
<name>Keycloak Account UI</name>
<description>The user inferface to manage an account on the Keycloak server.</description>
<build>
<resources>
<resource>
<directory>maven-resources</directory>
</resource>
<resource>
<directory>dist</directory>
<targetPath>theme/keycloak.v3/account/resources</targetPath>
<excludes>
<exclude>index.html</exclude>
</excludes>
</resource>
</resources>
<plugins>
<plugin>
<groupId>com.github.eirslett</groupId>
<artifactId>frontend-maven-plugin</artifactId>
<executions>
<execution>
2023-05-05 16:03:24 +00:00
<id>run-build</id>
<goals>
2023-05-05 16:03:24 +00:00
<goal>pnpm</goal>
</goals>
<configuration>
2023-05-05 16:03:24 +00:00
<arguments>run build</arguments>
</configuration>
</execution>
</executions>
<configuration>
2023-05-05 16:03:24 +00:00
<installDirectory>../..</installDirectory>
</configuration>
</plugin>
<plugin>
<groupId>com.google.code.maven-replacer-plugin</groupId>
<artifactId>maven-replacer-plugin</artifactId>
<executions>
<execution>
<phase>process-resources</phase>
<goals>
<goal>replace</goal>
</goals>
</execution>
</executions>
<configuration>
<file>dist/index.html</file>
<outputFile>target/classes/theme/keycloak.v3/account/index.ftl</outputFile>
<regex>false</regex>
<replacements>
<replacement>
<token>src="./</token>
<value>src="${resourceUrl}/</value>
</replacement>
<replacement>
<token>href="./</token>
<value>href="${resourceUrl}/</value>
</replacement>
<replacement>
<token><![CDATA[<link rel="icon" type="image/svg+xml" href="${resourceUrl}/favicon.svg" />]]></token>
<value xml:space="preserve"><![CDATA[<link rel="icon" type="${properties.favIconType!"image/svg+xml"}" href="${resourceUrl}${properties.favIcon!"/favicon.svg"}" />]]></value>
</replacement>
<replacement>
<token><![CDATA[<title>Keycloak account console</title>]]></token>
<value xml:space="preserve"><![CDATA[<title>${properties.title!"Keycloak account console"}</title>]]></value>
</replacement>
<replacement>
<token><![CDATA[</body>]]></token>
<value xml:space="preserve">
<![CDATA[
<script id="environment" type="application/json">
{
"authUrl": "${authUrl}",
"isRunningAsTheme": true,
"realm": "${realm.name}",
"resourceUrl": "${resourceUrl}",
"logo": "${properties.logo!""}",
"logoUrl": "${properties.logoUrl!""}",
"features": {
"isRegistrationEmailAsUsername": ${realm.registrationEmailAsUsername?c},
"isEditUserNameAllowed": ${realm.editUsernameAllowed?c},
"isInternationalizationEnabled": ${realm.isInternationalizationEnabled()?c},
"isLinkedAccountsEnabled": ${realm.identityFederationEnabled?c},
"isEventsEnabled": ${isEventsEnabled?c},
"isMyResourcesEnabled": ${(realm.userManagedAccessAllowed && isAuthorizationEnabled)?c},
"isTotpConfigured": ${isTotpConfigured?c},
"deleteAccountAllowed": ${deleteAccountAllowed?c},
"updateEmailFeatureEnabled": ${updateEmailFeatureEnabled?c},
"updateEmailActionEnabled": ${updateEmailActionEnabled?c},
"isViewGroupsEnabled": ${isViewGroupsEnabled?c}
}
}
</script>
</body>
]]>
</value>
</replacement>
<replacement>
<token><![CDATA[</head>]]></token>
<value xml:space="preserve">
<![CDATA[
<#if properties.styles?has_content>
<#list properties.styles?split(' ') as style>
<link href="${resourceUrl}/${style}" rel="stylesheet"/>
</#list>
</#if>
</head>
]]>
</value>
</replacement>
</replacements>
</configuration>
</plugin>
</plugins>
</build>
</project>