Lanna Desk: logo, a public page at /, the back office at /desk, full sign-out
Logo: a Lanna gable whose crossed kalae horns stand over a desk, gold on navy, with "Lanna Desk" and "Visas · stays · contracts" in Sarabun drawn as outlines. static/brand/ has the mark, the logo for light and for dark backgrounds and a one-color version; scripts/gen_logo.py makes them, the favicon and the header's mark from forms/fonts/Sarabun-Bold/SemiBold (SIL Open Font License, next to the Regular already there). `/` is now lannadesk.com's public page (templates/landing.html, static/landing.css): what Lanna Desk takes care of, how a client starts (write, open the link, sign first, we keep the dates), how the data is kept, contact@lannadesk.com and "Staff sign-in". It needs no session and shows no records. The back office's first page, the deadlines, moves to `/desk` (web::HOME): the header, the nav, the filter, the login's default target and the messages' links follow. Signing out now ends the session at id.cnx.network too. Kanidm names no end_session_endpoint, but its GET /ui/logout ends the session and clears its cookies (SameSite=Lax, so they come along on a top-level navigation). The logout form may only lead to this site (CSP form-action 'self'), so /signed-out sends the browser on with a refresh and offers the link as well; providers that are not Kanidm keep the old page. Checks: fmt, clippy, 109 unit and 57 integration tests (the public page open and free of records, /desk behind the sign-in, the sign-out page leading to the provider); the page at 1280 and 390 px; the header's mark in both themes; the style check on the README, PLAN and the page.
This commit is contained in:
1 parent
e5e30c977c
commit
eafe918bcc
22 files changed
+639
-44
No files matched your search
@@ -27,7 +27,7 @@ use crate::{companies, countries, dates, records};
|
||||
|
||||
use super::people::{PersonView, load_person};
|
||||
use super::records::options;
|
||||
use super::{AppState, Res, message, not_found_page, page};
|
||||
use super::{AppState, HOME, Res, message, not_found_page, page};
|
||||
|
||||
/// The largest file taken.
|
||||
pub const FILE_LIMIT: usize = 20 * 1024 * 1024;
|
||||
@@ -502,7 +502,7 @@ fn files_off(st: &AppState) -> Response {
|
||||
"Documents are switched off",
|
||||
"This server has no files directory and file key (VISA_FILES_DIR, VISA_FILES_KEY_FILE), \
|
||||
so it neither takes nor shows documents.",
|
||||
("/", "Open the app"),
|
||||
(HOME, "Open the app"),
|
||||
)
|
||||
}
|
||||
|
||||
@@ -517,7 +517,7 @@ fn too_large(st: &AppState) -> Response {
|
||||
FILE_LIMIT / (1024 * 1024),
|
||||
UPLOAD_LIMIT / (1024 * 1024)
|
||||
),
|
||||
("/", "Open the app"),
|
||||
(HOME, "Open the app"),
|
||||
)
|
||||
}
|
||||
|
||||
@@ -531,7 +531,7 @@ fn broken_upload(st: &AppState, e: &MultipartError) -> Response {
|
||||
StatusCode::BAD_REQUEST,
|
||||
"The upload was cut short",
|
||||
"The files did not arrive whole. Go back and send them again.",
|
||||
("/", "Open the app"),
|
||||
(HOME, "Open the app"),
|
||||
)
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user