From e397bc884be7491a724a7060fa198ef35125f75b Mon Sep 17 00:00:00 2001 From: Andy Burke Date: Wed, 23 Jul 2025 13:01:52 -0700 Subject: [PATCH] refactor: fix password auth refactor: move tabs around --- deno.json | 2 +- deno.lock | 17 ++++++++--------- models/password_entry.ts | 1 - public/api/auth/index.ts | 2 +- public/api/users/index.ts | 5 ++--- public/tabs/calendar/README.md | 3 +++ public/tabs/{ => calendar}/calendar.html | 4 +++- public/tabs/exchange/README.md | 3 +++ public/tabs/{ => exchange}/exchange.html | 4 +++- public/tabs/home/README.md | 3 +++ public/tabs/{ => home}/home.html | 4 +++- public/tabs/{ => profile}/profile.html | 0 public/tabs/resources/README.md | 3 +++ public/tabs/{ => resources}/resources.html | 2 +- public/tabs/tabs.html | 12 ++++++------ public/tabs/work/README.md | 8 ++++++++ public/tabs/{ => work}/work.html | 2 +- 17 files changed, 49 insertions(+), 26 deletions(-) create mode 100644 public/tabs/calendar/README.md rename public/tabs/{ => calendar}/calendar.html (79%) create mode 100644 public/tabs/exchange/README.md rename public/tabs/{ => exchange}/exchange.html (79%) create mode 100644 public/tabs/home/README.md rename public/tabs/{ => home}/home.html (79%) rename public/tabs/{ => profile}/profile.html (100%) create mode 100644 public/tabs/resources/README.md rename public/tabs/{ => resources}/resources.html (81%) create mode 100644 public/tabs/work/README.md rename public/tabs/{ => work}/work.html (79%) diff --git a/deno.json b/deno.json index cba7534..ba22be8 100644 --- a/deno.json +++ b/deno.json @@ -34,7 +34,7 @@ "imports": { "@andyburke/fsdb": "jsr:@andyburke/fsdb@^1.0.0", "@andyburke/lurid": "jsr:@andyburke/lurid@^0.2.0", - "@andyburke/serverus": "jsr:@andyburke/serverus@^0.7.1", + "@andyburke/serverus": "jsr:@andyburke/serverus@^0.9.3", "@da/bcrypt": "jsr:@da/bcrypt@^1.0.1", "@std/assert": "jsr:@std/assert@^1.0.13", "@std/encoding": "jsr:@std/encoding@^1.0.10", diff --git a/deno.lock b/deno.lock index b048ed6..9ea7877 100644 --- a/deno.lock +++ b/deno.lock @@ -4,8 +4,7 @@ "jsr:@andyburke/fsdb@1": "1.0.0", "jsr:@andyburke/lurid@*": "0.2.0", "jsr:@andyburke/lurid@0.2": "0.2.0", - "jsr:@andyburke/serverus@*": "0.7.1", - "jsr:@andyburke/serverus@~0.7.1": "0.7.1", + "jsr:@andyburke/serverus@~0.9.3": "0.9.3", "jsr:@da/bcrypt@^1.0.1": "1.0.1", "jsr:@std/assert@*": "1.0.13", "jsr:@std/assert@^1.0.13": "1.0.13", @@ -52,16 +51,16 @@ "jsr:@std/cli@^1.0.19" ] }, - "@andyburke/serverus@0.7.1": { - "integrity": "750b5d425a3b147efb551fbbc564b0c1428e5a8b94959bd77e95936bab78040d", + "@andyburke/serverus@0.9.3": { + "integrity": "fb72135b96e9700f6b4959d9fcbcbf8dfeef9ed97cd510709c59304d7fef59d5", "dependencies": [ "jsr:@std/async", - "jsr:@std/cli@^1.0.19", + "jsr:@std/cli@^1.0.20", "jsr:@std/fmt@^1.0.6", - "jsr:@std/fs@^1.0.14", - "jsr:@std/http@^1.0.13", + "jsr:@std/fs@^1.0.19", + "jsr:@std/http@^1.0.19", "jsr:@std/media-types", - "jsr:@std/path@^1.0.8" + "jsr:@std/path@^1.1.1" ] }, "@da/bcrypt@1.0.1": { @@ -207,7 +206,7 @@ "dependencies": [ "jsr:@andyburke/fsdb@1", "jsr:@andyburke/lurid@0.2", - "jsr:@andyburke/serverus@~0.7.1", + "jsr:@andyburke/serverus@~0.9.3", "jsr:@da/bcrypt@^1.0.1", "jsr:@std/assert@^1.0.13", "jsr:@std/encoding@^1.0.10", diff --git a/models/password_entry.ts b/models/password_entry.ts index 873cd10..2e3040c 100644 --- a/models/password_entry.ts +++ b/models/password_entry.ts @@ -3,7 +3,6 @@ import { FSDB_COLLECTION } from 'jsr:@andyburke/fsdb'; export type PASSWORD_ENTRY = { user_id: string; hash: string; - salt: string; timestamps: { created: string; updated: string; diff --git a/public/api/auth/index.ts b/public/api/auth/index.ts index edd0657..05a97ae 100644 --- a/public/api/auth/index.ts +++ b/public/api/auth/index.ts @@ -79,7 +79,7 @@ export async function POST(req: Request, meta: Record): Promise): Promise
Calendar
-
This is the calendar tab.
+
+ +
diff --git a/public/tabs/exchange/README.md b/public/tabs/exchange/README.md new file mode 100644 index 0000000..85c08cd --- /dev/null +++ b/public/tabs/exchange/README.md @@ -0,0 +1,3 @@ +# exchange + +The exchange should help people find goods and trade. diff --git a/public/tabs/exchange.html b/public/tabs/exchange/exchange.html similarity index 79% rename from public/tabs/exchange.html rename to public/tabs/exchange/exchange.html index 1ac4c81..f31ae26 100644 --- a/public/tabs/exchange.html +++ b/public/tabs/exchange/exchange.html @@ -10,5 +10,7 @@ >
Exchange
-
This is the exchange tab.
+
+ +
diff --git a/public/tabs/home/README.md b/public/tabs/home/README.md new file mode 100644 index 0000000..d02c6f8 --- /dev/null +++ b/public/tabs/home/README.md @@ -0,0 +1,3 @@ +# Home + +This tab should show notifications and an overview. diff --git a/public/tabs/home.html b/public/tabs/home/home.html similarity index 79% rename from public/tabs/home.html rename to public/tabs/home/home.html index d5c960f..b0cae4f 100644 --- a/public/tabs/home.html +++ b/public/tabs/home/home.html @@ -11,5 +11,7 @@
Home
-
This is the home tab.
+
+ +
diff --git a/public/tabs/profile.html b/public/tabs/profile/profile.html similarity index 100% rename from public/tabs/profile.html rename to public/tabs/profile/profile.html diff --git a/public/tabs/resources/README.md b/public/tabs/resources/README.md new file mode 100644 index 0000000..2771877 --- /dev/null +++ b/public/tabs/resources/README.md @@ -0,0 +1,3 @@ +# Resources + +Resources should be a wiki for organizing community knowledge. diff --git a/public/tabs/resources.html b/public/tabs/resources/resources.html similarity index 81% rename from public/tabs/resources.html rename to public/tabs/resources/resources.html index fe05b70..61f7b6c 100644 --- a/public/tabs/resources.html +++ b/public/tabs/resources/resources.html @@ -10,5 +10,5 @@ >
Resources
-
This is the resources tab.
+
diff --git a/public/tabs/tabs.html b/public/tabs/tabs.html index f989e11..60718af 100644 --- a/public/tabs/tabs.html +++ b/public/tabs/tabs.html @@ -126,11 +126,11 @@
- + - - - - - + + + + +
diff --git a/public/tabs/work/README.md b/public/tabs/work/README.md new file mode 100644 index 0000000..074ed25 --- /dev/null +++ b/public/tabs/work/README.md @@ -0,0 +1,8 @@ +# Work + +This tab should help people find and list work, but without being shitty: + + - Make requirements favor users + - Salary required + - Location required + - Discussions available on listings without poster's control diff --git a/public/tabs/work.html b/public/tabs/work/work.html similarity index 79% rename from public/tabs/work.html rename to public/tabs/work/work.html index 5b97336..1eed2c9 100644 --- a/public/tabs/work.html +++ b/public/tabs/work/work.html @@ -10,5 +10,5 @@ >
Work
-
This is the work tab.
+