- Update MUI v4 to v5

- Remove the SCSS dependency completely and use MUI for theming.
- Update - date-fns, @date-io, notistack. Remove - popper.js, sass-loader.
- Cleanup webpack config.
- Port PSQL tool to use MUI themes instead of SCSS theme.
- Theme change will reflect realtime without refreshing pgAdmin.
This commit is contained in:
Yogesh Mahajan
2024-04-09 08:21:14 +05:30
committed by GitHub
parent edec9adbfb
commit 102e0a9839
193 changed files with 3110 additions and 5313 deletions

View File

@@ -101,18 +101,21 @@ def panel(trans_id):
data = _get_database_role(params['sid'], params['did'])
params = {
'sid': params['sid'],
'db': underscore_escape(data['db_name']),
'server_type': params['server_type'],
'is_enable': config.ENABLE_PSQL,
'title': underscore_unescape(params['title']),
'theme': params['theme'],
'o_db_name': underscore_escape(data['db_name']),
'role': underscore_escape(data['role']),
'platform': _platform
}
set_env_variables(is_win=_platform == 'win32')
return render_template('editor_template.html',
sid=params['sid'],
db=underscore_escape(data['db_name']),
server_type=params['server_type'],
is_enable=config.ENABLE_PSQL,
title=underscore_unescape(params['title']),
theme=params['theme'],
o_db_name=underscore_escape(data['db_name']),
role=underscore_escape(data['role']),
platform=_platform
)
return render_template("psql/index.html",
params=json.dumps(params))
def set_env_variables(is_win=False):