- In file '/angular/demo{#}/src/assets/sass/style.angular.scss' comment the next rows [8, 9]:
// @import "./core/vendors/plugins/prismjs";
// @import "./core/vendors/plugins/formvalidation";
-
Add 'rtl.config.js' file into project (path should be: '/angular/demo{#}/rtl.config.js').
-
In file 'package.json' add the next 'devDependencies':
"@types/sass-loader": "8.0.3",
"css-loader": "6.7.1",
"del": "6.0.0",
"mini-css-extract-plugin": "2.6.1",
"sass-loader": "13.0.2",
"webpack": "5.74.0",
"webpack-cli": "4.10.0"
- In file 'package.json' add the next scripts command:
"rtl": "webpack --config=rtl.config.js"
-
Find and replace next attributes in the project:
data-kt-menu-placement="bottom-start" => data-kt-menu-placement="bottom-end"
data-kt-menu-placement="right-start" => data-kt-menu-placement="left-start"
-
Run:
yarn install
- In file '/angular/demo{#}/src/index.html' change 'body' tag:
<body root id="kt_body" class="mat-typography" direction="rtl" dir="rtl" style="direction: rtl">
- Run:
yarn run rtl
- In file '/angular/demo{#}/src/styles.scss' file change RTL import to the LTL one (row 2):
/* You can add global styles to this file, and also import other style files */
// @import "./assets/sass/style.scss";
// Replace above style with this css file to enable RTL styles
// @import './assets/sass/plugins.scss';
@import "./assets/css/style.rtl.css";
@import "./assets/sass/style.angular.scss";
- Run:
ng serve
@ADNANALK can you please explain more