- Fix "Cannot set properties of undefined (setting '_class')" after adding a person on a server page: kept Overview/People tabs are taken out before dom.content() wipes their LuCI registry - No portal links while the personal portal is off - "Off" disguise writes a plain WireGuard config (no neutral Jc..H4 lines) - Setup wizard: Settings-style groups, portal off by default, "Internet like a home device" switch; no "Link path" (server ids are picked by the router) - Server ids and imported section names may not contain dashes - Health: Cloudflare-proxied endpoint and portal address are not warnings - Themes other than Outline: solid menus, drawer, palette, toasts and tooltips (Bootstrap colour tokens as fallbacks), custom select chevron - Server section tabs scroll sideways instead of wrapping; centred empty People list; wider search; "1 device" in the palette - lint-ucode: exported functions must end with "};"
This commit is contained in:
1 parent
a3910f8b97
commit
d0955e44b8
13 files changed
+168
-112
No files matched your search
@@ -231,6 +231,16 @@ function free_ifname(m) {
|
||||
return 'dawnx';
|
||||
}
|
||||
|
||||
/** A free server id: home, then server2, server3, … (never a person, device or service id). */
|
||||
function free_server_id(m) {
|
||||
let taken = (id) => m.servers[id] || m.people[id] || m.devices[id] || m.services[id] || index([ 'settings', 'api', 'assets', 'cgi-bin' ], id) >= 0;
|
||||
if (!taken('home'))
|
||||
return 'home';
|
||||
for (let n = 2; ; n++)
|
||||
if (!taken(`server${n}`))
|
||||
return `server${n}`;
|
||||
}
|
||||
|
||||
function setup_defaults(a) {
|
||||
let m = core.load();
|
||||
let taken = ops.used_subnets(null);
|
||||
@@ -258,7 +268,7 @@ function setup_defaults(a) {
|
||||
host = live.iface_status('wan')?.['ipv4-address']?.[0]?.address ?? '';
|
||||
}
|
||||
return {
|
||||
id: length(m.servers) ? `server${length(m.servers) + 1}` : 'home',
|
||||
id: free_server_id(m),
|
||||
name: length(m.servers) ? `Server ${length(m.servers) + 1}` : 'Home',
|
||||
ifname: free_ifname(m),
|
||||
port: free_port(m),
|
||||
|
||||
Reference in new issue
Block a user