diff --git a/.storybook/main.js b/.storybook/main.js index d33953e7..49d4ca27 100644 --- a/.storybook/main.js +++ b/.storybook/main.js @@ -9,5 +9,5 @@ module.exports = { core: { builder: "webpack5" }, - staticDirs: ["./static", "../dist/public"] + staticDirs: ["./static", "../dist/res/public"] }; diff --git a/scripts/build/createAccountV1Dir.ts b/scripts/build/createAccountV1Dir.ts index b58435b2..e00333c9 100644 --- a/scripts/build/createAccountV1Dir.ts +++ b/scripts/build/createAccountV1Dir.ts @@ -13,7 +13,12 @@ export async function createAccountV1Dir() { keycloakVersion: KEYCLOAK_VERSION.FOR_ACCOUNT_MULTI_PAGE }); - const destDirPath = pathJoin(getThisCodebaseRootDirPath(), "dist", "account-v1"); + const destDirPath = pathJoin( + getThisCodebaseRootDirPath(), + "dist", + "res", + "account-v1" + ); await fsPr.rm(destDirPath, { recursive: true, force: true }); diff --git a/scripts/build/createPublicDotKeycloakifyDir.ts b/scripts/build/createPublicDotKeycloakifyDir.ts index 262c4f44..13044a96 100644 --- a/scripts/build/createPublicDotKeycloakifyDir.ts +++ b/scripts/build/createPublicDotKeycloakifyDir.ts @@ -28,6 +28,7 @@ export async function createPublicDotKeycloakifyDir() { const destDirPath = pathJoin( getThisCodebaseRootDirPath(), "dist", + "res", "public", WELL_KNOWN_DIRECTORY_BASE_NAME.DOT_KEYCLOAKIFY, themeType diff --git a/src/bin/initialize-email-theme.ts b/src/bin/initialize-email-theme.ts index 14b601ed..f2520645 100644 --- a/src/bin/initialize-email-theme.ts +++ b/src/bin/initialize-email-theme.ts @@ -67,7 +67,10 @@ export async function command(params: { cliCommandOptions: CliCommandOptions }) fs.writeFileSync( themePropertyFilePath, Buffer.from( - `parent=base\n${fs.readFileSync(themePropertyFilePath).toString("utf8")}`, + [ + `parent=base`, + fs.readFileSync(themePropertyFilePath).toString("utf8") + ].join("\n"), "utf8" ) ); diff --git a/src/bin/keycloakify/generateResources/generateResourcesForMainTheme.ts b/src/bin/keycloakify/generateResources/generateResourcesForMainTheme.ts index fc0c772c..2f1a8115 100644 --- a/src/bin/keycloakify/generateResources/generateResourcesForMainTheme.ts +++ b/src/bin/keycloakify/generateResources/generateResourcesForMainTheme.ts @@ -310,7 +310,7 @@ export async function generateResourcesForMainTheme(params: { } transformCodebase({ - srcDirPath: pathJoin(getThisCodebaseRootDirPath(), "account-v1"), + srcDirPath: pathJoin(getThisCodebaseRootDirPath(), "res", "account-v1"), destDirPath: pathJoin(resourcesDirPath, "theme", "account-v1", "account") }); } diff --git a/src/bin/shared/copyKeycloakResourcesToPublic.ts b/src/bin/shared/copyKeycloakResourcesToPublic.ts index e4233c9e..e9a90762 100644 --- a/src/bin/shared/copyKeycloakResourcesToPublic.ts +++ b/src/bin/shared/copyKeycloakResourcesToPublic.ts @@ -65,6 +65,7 @@ export function copyKeycloakResourcesToPublic(params: { transformCodebase({ srcDirPath: pathJoin( getThisCodebaseRootDirPath(), + "res", "public", WELL_KNOWN_DIRECTORY_BASE_NAME.DOT_KEYCLOAKIFY ),