Prettier: switch to trailing coma: none
This commit is contained in:
@ -14,6 +14,6 @@ generateKeycloakThemeResources({
|
||||
"extraPages": ["my-custom-page.ftl"],
|
||||
"extraThemeProperties": ["env=test"],
|
||||
"isStandalone": true,
|
||||
"urlPathname": "/keycloakify-demo-app/",
|
||||
},
|
||||
"urlPathname": "/keycloakify-demo-app/"
|
||||
}
|
||||
});
|
||||
|
@ -11,7 +11,7 @@ const binDirPath = pathJoin(getProjectRoot(), "dist_test", "bin");
|
||||
st.execSyncTrace(
|
||||
//`node ${pathJoin(binDirPath, "build-keycloak-theme")} --external-assets`,
|
||||
`node ${pathJoin(binDirPath, "build-keycloak-theme")}`,
|
||||
{ "cwd": sampleReactProjectDirPath },
|
||||
{ "cwd": sampleReactProjectDirPath }
|
||||
);
|
||||
|
||||
st.execSyncTrace(`node ${pathJoin(binDirPath, "download-builtin-keycloak-theme")}`, { "cwd": sampleReactProjectDirPath });
|
||||
|
@ -37,8 +37,8 @@ import { assetIsSameCode } from "../tools/assertIsSameCode";
|
||||
const { fixedJsCode } = replaceImportsFromStaticInJsCode({
|
||||
"jsCode": jsCodeUntransformed,
|
||||
"buildOptions": {
|
||||
"isStandalone": true,
|
||||
},
|
||||
"isStandalone": true
|
||||
}
|
||||
});
|
||||
|
||||
const fixedJsCodeExpected = `
|
||||
@ -91,8 +91,8 @@ import { assetIsSameCode } from "../tools/assertIsSameCode";
|
||||
"jsCode": jsCodeUntransformed,
|
||||
"buildOptions": {
|
||||
"isStandalone": false,
|
||||
"urlOrigin": "https://demo-app.keycloakify.dev",
|
||||
},
|
||||
"urlOrigin": "https://demo-app.keycloakify.dev"
|
||||
}
|
||||
});
|
||||
|
||||
const fixedJsCodeExpected = `
|
||||
@ -156,7 +156,7 @@ import { assetIsSameCode } from "../tools/assertIsSameCode";
|
||||
.my-div {
|
||||
background-image: url(/static/media/something.svg);
|
||||
}
|
||||
`,
|
||||
`
|
||||
});
|
||||
|
||||
const fixedCssCodeExpected = `
|
||||
@ -177,7 +177,7 @@ import { assetIsSameCode } from "../tools/assertIsSameCode";
|
||||
|
||||
const cssGlobalsToDefineExpected = {
|
||||
"url1f9ef5a892c104c": "url(/logo192.png) no-repeat center center",
|
||||
"urldd75cab58377c19": "url(/static/media/something.svg)",
|
||||
"urldd75cab58377c19": "url(/static/media/something.svg)"
|
||||
};
|
||||
|
||||
assert(same(cssGlobalsToDefine, cssGlobalsToDefineExpected));
|
||||
@ -185,8 +185,8 @@ import { assetIsSameCode } from "../tools/assertIsSameCode";
|
||||
const { cssCodeToPrependInHead } = generateCssCodeToDefineGlobals({
|
||||
cssGlobalsToDefine,
|
||||
"buildOptions": {
|
||||
"urlPathname": undefined,
|
||||
},
|
||||
"urlPathname": undefined
|
||||
}
|
||||
});
|
||||
|
||||
const cssCodeToPrependInHeadExpected = `
|
||||
@ -213,7 +213,7 @@ import { assetIsSameCode } from "../tools/assertIsSameCode";
|
||||
.my-div {
|
||||
background-image: url(/x/y/z/static/media/something.svg);
|
||||
}
|
||||
`,
|
||||
`
|
||||
});
|
||||
|
||||
const fixedCssCodeExpected = `
|
||||
@ -234,7 +234,7 @@ import { assetIsSameCode } from "../tools/assertIsSameCode";
|
||||
|
||||
const cssGlobalsToDefineExpected = {
|
||||
"urlf8277cddaa2be78": "url(/x/y/z/logo192.png) no-repeat center center",
|
||||
"url8bdc0887b97ac9a": "url(/x/y/z/static/media/something.svg)",
|
||||
"url8bdc0887b97ac9a": "url(/x/y/z/static/media/something.svg)"
|
||||
};
|
||||
|
||||
assert(same(cssGlobalsToDefine, cssGlobalsToDefineExpected));
|
||||
@ -242,8 +242,8 @@ import { assetIsSameCode } from "../tools/assertIsSameCode";
|
||||
const { cssCodeToPrependInHead } = generateCssCodeToDefineGlobals({
|
||||
cssGlobalsToDefine,
|
||||
"buildOptions": {
|
||||
"urlPathname": "/x/y/z/",
|
||||
},
|
||||
"urlPathname": "/x/y/z/"
|
||||
}
|
||||
});
|
||||
|
||||
const cssCodeToPrependInHeadExpected = `
|
||||
@ -293,8 +293,8 @@ import { assetIsSameCode } from "../tools/assertIsSameCode";
|
||||
cssCode,
|
||||
"buildOptions": {
|
||||
"isStandalone": true,
|
||||
"urlPathname": undefined,
|
||||
},
|
||||
"urlPathname": undefined
|
||||
}
|
||||
});
|
||||
|
||||
const fixedCssCodeExpected = `
|
||||
@ -341,8 +341,8 @@ import { assetIsSameCode } from "../tools/assertIsSameCode";
|
||||
"buildOptions": {
|
||||
"isStandalone": false,
|
||||
"urlOrigin": "https://demo-app.keycloakify.dev",
|
||||
"urlPathname": undefined,
|
||||
},
|
||||
"urlPathname": undefined
|
||||
}
|
||||
});
|
||||
|
||||
const fixedCssCodeExpected = `
|
||||
@ -421,8 +421,8 @@ import { assetIsSameCode } from "../tools/assertIsSameCode";
|
||||
cssCode,
|
||||
"buildOptions": {
|
||||
"isStandalone": true,
|
||||
"urlPathname": "/x/y/z/",
|
||||
},
|
||||
"urlPathname": "/x/y/z/"
|
||||
}
|
||||
});
|
||||
|
||||
const fixedCssCodeExpected = `
|
||||
@ -469,8 +469,8 @@ import { assetIsSameCode } from "../tools/assertIsSameCode";
|
||||
"buildOptions": {
|
||||
"isStandalone": false,
|
||||
"urlOrigin": "https://demo-app.keycloakify.dev",
|
||||
"urlPathname": "/x/y/z/",
|
||||
},
|
||||
"urlPathname": "/x/y/z/"
|
||||
}
|
||||
});
|
||||
|
||||
const fixedCssCodeExpected = `
|
||||
|
@ -7,6 +7,6 @@ export const sampleReactProjectDirPath = pathJoin(getProjectRoot(), "sample_reac
|
||||
export function setupSampleReactProject() {
|
||||
downloadAndUnzip({
|
||||
"url": "https://github.com/garronej/keycloakify/releases/download/v0.0.1/sample_build_dir_and_package_json.zip",
|
||||
"destDirPath": sampleReactProjectDirPath,
|
||||
"destDirPath": sampleReactProjectDirPath
|
||||
});
|
||||
}
|
||||
|
@ -40,21 +40,21 @@ import { deepClone } from "../../lib/tools/deepClone";
|
||||
"mockData": [
|
||||
{
|
||||
"pageId": "login.ftl",
|
||||
"realm": { displayName },
|
||||
"realm": { displayName }
|
||||
},
|
||||
{
|
||||
"pageId": "info.ftl",
|
||||
aNonStandardValue1,
|
||||
aNonStandardValue1
|
||||
},
|
||||
{
|
||||
"pageId": "register.ftl",
|
||||
authorizedMailDomains,
|
||||
authorizedMailDomains
|
||||
},
|
||||
{
|
||||
"pageId": "my-extra-page-2.ftl",
|
||||
aNonStandardValue2,
|
||||
},
|
||||
],
|
||||
aNonStandardValue2
|
||||
}
|
||||
]
|
||||
});
|
||||
|
||||
return { kcContext };
|
||||
@ -79,8 +79,8 @@ import { deepClone } from "../../lib/tools/deepClone";
|
||||
mock.realm.displayName = displayName;
|
||||
|
||||
return mock;
|
||||
})(),
|
||||
),
|
||||
})()
|
||||
)
|
||||
);
|
||||
|
||||
console.log(`PASS ${pageId}`);
|
||||
@ -113,8 +113,8 @@ import { deepClone } from "../../lib/tools/deepClone";
|
||||
Object.assign(mock, { aNonStandardValue1 });
|
||||
|
||||
return mock;
|
||||
})(),
|
||||
),
|
||||
})()
|
||||
)
|
||||
);
|
||||
|
||||
console.log(`PASS ${pageId}`);
|
||||
@ -147,8 +147,8 @@ import { deepClone } from "../../lib/tools/deepClone";
|
||||
Object.assign(mock, { authorizedMailDomains });
|
||||
|
||||
return mock;
|
||||
})(),
|
||||
),
|
||||
})()
|
||||
)
|
||||
);
|
||||
|
||||
console.log(`PASS ${pageId}`);
|
||||
@ -182,8 +182,8 @@ import { deepClone } from "../../lib/tools/deepClone";
|
||||
Object.assign(mock, { pageId, aNonStandardValue2 });
|
||||
|
||||
return mock;
|
||||
})(),
|
||||
),
|
||||
})()
|
||||
)
|
||||
);
|
||||
|
||||
console.log(`PASS ${pageId}`);
|
||||
@ -209,8 +209,8 @@ import { deepClone } from "../../lib/tools/deepClone";
|
||||
Object.assign(mock, { pageId });
|
||||
|
||||
return mock;
|
||||
})(),
|
||||
),
|
||||
})()
|
||||
)
|
||||
);
|
||||
|
||||
console.log(`PASS ${pageId}`);
|
||||
@ -221,7 +221,7 @@ import { deepClone } from "../../lib/tools/deepClone";
|
||||
const pageId = "login.ftl";
|
||||
|
||||
const { kcContext } = getKcContext({
|
||||
"mockPageId": pageId,
|
||||
"mockPageId": pageId
|
||||
});
|
||||
|
||||
assert<Equals<typeof kcContext, KcContextBase | undefined>>();
|
||||
|
Reference in New Issue
Block a user