Bolding no js message, fixing settheme and setLang on login event.

This commit is contained in:
Dessalines 2020-09-15 08:20:19 -05:00
parent 3399d976ce
commit a7d0f27b80
2 changed files with 3 additions and 1 deletions

View File

@ -100,7 +100,7 @@ server.get('/*', async (req, res) => {
<body ${helmet.bodyAttributes.toString()}>
<noscript>
<div class="alert alert-danger rounded-0" role="alert">
Javascript is disabled. Actions will not work.
<b>Javascript is disabled. Actions will not work.</b>
</div>
</noscript>

View File

@ -419,6 +419,8 @@ export class Navbar extends Component<NavbarProps, NavbarState> {
// This is only called on a successful login
let data = res.data as GetSiteResponse;
UserService.Instance.user = data.my_user;
setTheme(UserService.Instance.user.theme);
i18n.changeLanguage(getLanguage());
this.state.isLoggedIn = true;
this.setState(this.state);
} else if (res.op == UserOperation.CreateComment) {