mirror of
https://github.com/alkimake/paperclip.git
synced 2026-06-15 10:30:37 +09:00
feat(inbox): add operator search and keyboard controls
Co-Authored-By: Paperclip <noreply@paperclip.ing>
This commit is contained in:
parent
36376968af
commit
3ab7d52f00
25 changed files with 1340 additions and 114 deletions
|
|
@ -21,7 +21,11 @@ export function instanceSettingsRoutes(db: Db) {
|
|||
const svc = instanceSettingsService(db);
|
||||
|
||||
router.get("/instance/settings/general", async (req, res) => {
|
||||
assertCanManageInstanceSettings(req);
|
||||
// General settings (e.g. keyboardShortcuts) are readable by any
|
||||
// authenticated board user. Only PATCH requires instance-admin.
|
||||
if (req.actor.type !== "board") {
|
||||
throw forbidden("Board access required");
|
||||
}
|
||||
res.json(await svc.getGeneral());
|
||||
});
|
||||
|
||||
|
|
@ -56,7 +60,11 @@ export function instanceSettingsRoutes(db: Db) {
|
|||
);
|
||||
|
||||
router.get("/instance/settings/experimental", async (req, res) => {
|
||||
assertCanManageInstanceSettings(req);
|
||||
// Experimental settings are readable by any authenticated board user.
|
||||
// Only PATCH requires instance-admin.
|
||||
if (req.actor.type !== "board") {
|
||||
throw forbidden("Board access required");
|
||||
}
|
||||
res.json(await svc.getExperimental());
|
||||
});
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue