Files
raucao 13e02168c9 Add name onboarding and inline name editing
Ask for the user's name on first launch through a /welcome route, store it in the preferences namespace via a user service, and redirect between welcome and the dashboard based on whether a name exists. Replace the hardcoded greeting name and make it editable in place, with save/cancel handling and a first-run prompt matching the dashboard style.
2026-11-07 13:14:23 +04:00

21 lines
606 B
JavaScript

import EmberRouter from '@embroider/router';
import config from 'dashtab/config/environment';
import { canUseExtensionAuth } from './utils/extension';
export default class Router extends EmberRouter {
// Extension pages are served as `index.html`, which history mode would try to
// read as a route, so skip URL syncing there.
location = canUseExtensionAuth() ? 'none' : config.locationType;
rootURL = config.rootURL;
}
Router.map(function () {
this.route('welcome');
this.route('auth', function () {
this.route('discourse', function () {
this.route('callback');
});
});
});