Bolding no js message, fixing settheme and setLang on login event.
authorDessalines <tyhou13@gmx.com>
Tue, 15 Sep 2020 13:20:19 +0000 (08:20 -0500)
committerDessalines <tyhou13@gmx.com>
Tue, 15 Sep 2020 13:20:19 +0000 (08:20 -0500)
src/server/index.tsx
src/shared/components/navbar.tsx

index 1c04ed5d61dc2dfc07be4e4a370ff65daa2644b5..b7577cade269ec41bbca2cdf4575e258d42d8460 100644 (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>
             
index 1d3ef8338c5f7909a44488aa7e5a8712a6190260..bf2b48b495bc706025b1b4ef29558aab7083a0e2 100644 (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) {