-
Notifications
You must be signed in to change notification settings - Fork 0
Create a new Theme
To create a new theme you need to clone one of the following repository, open a terminal and cd forgerock-openbanking-ui
:
https://github.com/OpenBankingToolkit/openbanking-analytics https://github.com/OpenBankingToolkit/openbanking-aspsp https://github.com/OpenBankingToolkit/openbanking-directory https://github.com/OpenBankingToolkit/openbanking-common https://github.com/OpenBankingToolkit/openbanking-tpp
Once you are on forgerock-openbanking-ui
, install the dependencies:
npm ci
then you will be able to call ./node_modules/.bin/openbanking-ui-cli
CLI. (you could also install it globally npm i @forgerock/openbanking-ui-cli -g
)
openbanking-ui-cli addTheme --name <themeName>
This will create all the necessary angular.json configuration and create a new folder customers/<themeName>
with all the necessary files to compile.
Go to https://openbankingtoolkit.github.io/openbanking-ui-customization/
Open the sidenav by clicking this button:
Upload the icon, logo and favicon with drag and drop (SVG only):
Select the 4 palettes by using default ones or by selecting colors one by one using the following tool:
Once you are happy with the result, click the export
button to get the JSON export.
Run the following command to apply the customization:
openbanking-ui-cli addTheme --name <themeName> --customization <pathToCustomizationJson>
Automated tasks:
- angular.json config
- sass/_variables.scss
- assets/logos/icon.svg
- assets/logos/logo.svg
- [] assets/favicons (go to https://realfavicongenerator.net/ and download the result)
- [] assets/slashscreen.css (change background/throbber color manually)
- [] build-settings.js (change
<Name>
and<description>
manually) - [] deployment-settings.js (change
<Name>
and<description>
manually)
If you want to see the result locally before committing the result. Add the following config in angular.json
and replace <themeName>
, <appName>
and <clusterName>
. See example: ui-integ-hl
"<clusterName>-<themeName>": {
"stylePreprocessorOptions": {
"includePaths": [
"customers/<themeName>/apps/<appName>/scss",
"customers/<themeName>/scss",
"utils/scss",
"projects/<appName>/src/scss"
]
},
"fileReplacements": [
{
"replace": "projects/<appName>/src/environments/environment.ts",
"with": "projects/<appName>/src/environments/environment.<clusterName>.ts"
},
{
"replace": "projects/<appName>/src/assets/logos/icon.svg",
"with": "customers/<themeName>/assets/logos/icon.svg"
},
{
"replace": "projects/<appName>/src/assets/logos/logo.svg",
"with": "customers/<themeName>/assets/logos/logo.svg"
},
{
"replace": "projects/<appName>/src/assets/splashscreen.css",
"with": "customers/<themeName>/assets/splashscreen.css"
}
]
},
Then when using ng serve
use --browserTarget <appName>:build:<clusterName>-<themeName>
. See serve.ui-integ.analytics.hl.client
task in angular.json
add the new customer to all build.<appName>.all
scripts with -c <themeName>
option