diff --git a/.next/dev/cache/turbopack/23c46498/CURRENT b/.next/dev/cache/turbopack/23c46498/CURRENT index f11b5ee..c32c19f 100644 Binary files a/.next/dev/cache/turbopack/23c46498/CURRENT and b/.next/dev/cache/turbopack/23c46498/CURRENT differ diff --git a/.next/dev/cache/turbopack/23c46498/LOG b/.next/dev/cache/turbopack/23c46498/LOG index 7cfe1a6..4a78cf2 100644 --- a/.next/dev/cache/turbopack/23c46498/LOG +++ b/.next/dev/cache/turbopack/23c46498/LOG @@ -1186,3 +1186,145 @@ FAM | META SEQ | SST SEQ | RANGE 0 | 00001084 | 00001083 SST | [=======================================================================] | 3aefa6fd5cf2deb4-f42f94001fcb5351 (0 MiB, fresh) 1 | 00001085 | 00001081 SST | O | b294a4237ccef201-b294a4237ccef201 (0 MiB, fresh) 2 | 00001086 | 00001082 SST | O | b294a4237ccef201-b294a4237ccef201 (0 MiB, fresh) +Time 2026-02-27T22:23:45.7991162Z +Commit 00001092 4 keys in 7ms 458µs 700ns +FAM | META SEQ | SST SEQ | RANGE + 0 | 00001090 | 00001089 SST | [=======================================================================] | 3aefa6fd5cf2deb4-f42f94001fcb5351 (0 MiB, fresh) + 1 | 00001091 | 00001087 SST | O | 3ffdfb3b7d50fcf1-3ffdfb3b7d50fcf1 (0 MiB, fresh) + 2 | 00001092 | 00001088 SST | O | 3ffdfb3b7d50fcf1-3ffdfb3b7d50fcf1 (0 MiB, fresh) +Time 2026-02-27T22:24:07.5239402Z +Commit 00001098 4 keys in 8ms 395µs +FAM | META SEQ | SST SEQ | RANGE + 0 | 00001096 | 00001095 SST | [=======================================================================] | 3aefa6fd5cf2deb4-f42f94001fcb5351 (0 MiB, fresh) + 1 | 00001097 | 00001093 SST | O | 7c65b158fbf615ea-7c65b158fbf615ea (0 MiB, fresh) + 2 | 00001098 | 00001094 SST | O | 7c65b158fbf615ea-7c65b158fbf615ea (0 MiB, fresh) +Time 2026-02-27T22:24:51.0510773Z +Commit 00001104 4 keys in 7ms 376µs 200ns +FAM | META SEQ | SST SEQ | RANGE + 0 | 00001102 | 00001101 SST | [=======================================================================] | 3aefa6fd5cf2deb4-f42f94001fcb5351 (0 MiB, fresh) + 1 | 00001103 | 00001099 SST | O | b294a4237ccef201-b294a4237ccef201 (0 MiB, fresh) + 2 | 00001104 | 00001100 SST | O | b294a4237ccef201-b294a4237ccef201 (0 MiB, fresh) +Time 2026-02-27T22:25:32.4323043Z +Commit 00001114 42941 keys in 13ms 179µs 100ns +FAM | META SEQ | SST SEQ | RANGE + 0 | 00001110 | 00001107 SST | [=======================================================================] | 3aefa6fd5cf2deb4-f42f94001fcb5351 (0 MiB, fresh) + 4 | 00001111 | 00001108 SST | [==================================================================================================] | 000d7f96fa69734b-fff3b56bbe0e6b22 (0 MiB, fresh) + 3 | 00001112 | 00001109 SST | [==================================================================================================] | 00017186f094d99a-fffbc6360ec1e50e (0 MiB, fresh) + 2 | 00001113 | 00001105 SST | [==================================================================================================] | 000358d0de9d25d6-fff3b56bbe0e6b22 (12 MiB, fresh) + 1 | 00001114 | 00001106 SST | [==================================================================================================] | 000358d0de9d25d6-ffffc8b261a62b07 (3 MiB, fresh) +Time 2026-02-27T22:26:46.8512199Z +Commit 00001120 16 keys in 5ms 869µs 900ns +FAM | META SEQ | SST SEQ | RANGE + 0 | 00001118 | 00001117 SST | [=======================================================================] | 3aefa6fd5cf2deb4-f42f94001fcb5351 (0 MiB, fresh) + 1 | 00001119 | 00001115 SST | [===========================================================================] | 2cf8041a3c23f4e1-ef311d8b965c9633 (0 MiB, fresh) + 2 | 00001120 | 00001116 SST | [===========================================================================] | 2cf8041a3c23f4e1-ef311d8b965c9633 (0 MiB, fresh) +Time 2026-02-27T22:27:39.7821936Z +Commit 00001130 552 keys in 10ms 743µs 200ns +FAM | META SEQ | SST SEQ | RANGE + 0 | 00001126 | 00001123 SST | [=======================================================================] | 3aefa6fd5cf2deb4-f42f94001fcb5351 (0 MiB, fresh) + 1 | 00001127 | 00001121 SST | [==================================================================================================] | 0122a8bf9145a429-ffd2128295feedf0 (0 MiB, fresh) + 2 | 00001128 | 00001122 SST | [==================================================================================================] | 0122a8bf9145a429-ffcb3bca70a06a01 (1 MiB, fresh) + 3 | 00001129 | 00001124 SST | [============================] | 2ea1370e09bafd2c-7933b6079e0abaf9 (0 MiB, fresh) + 4 | 00001130 | 00001125 SST | [===============================================================================================] | 0122a8bf9145a429-f5fce8eabd38c4f6 (0 MiB, fresh) +Time 2026-02-27T22:31:41.8511869Z +Commit 00001136 4 keys in 7ms 812µs 700ns +FAM | META SEQ | SST SEQ | RANGE + 0 | 00001134 | 00001133 SST | [=======================================================================] | 3aefa6fd5cf2deb4-f42f94001fcb5351 (0 MiB, fresh) + 1 | 00001135 | 00001131 SST | O | b294a4237ccef201-b294a4237ccef201 (0 MiB, fresh) + 2 | 00001136 | 00001132 SST | O | b294a4237ccef201-b294a4237ccef201 (0 MiB, fresh) +Time 2026-02-27T22:36:39.2925341Z +Commit 00001142 4 keys in 16ms 160µs 100ns +FAM | META SEQ | SST SEQ | RANGE + 0 | 00001140 | 00001139 SST | [=======================================================================] | 3aefa6fd5cf2deb4-f42f94001fcb5351 (0 MiB, fresh) + 1 | 00001141 | 00001137 SST | O | 9c27d2b5acd6b310-9c27d2b5acd6b310 (0 MiB, fresh) + 2 | 00001142 | 00001138 SST | O | 9c27d2b5acd6b310-9c27d2b5acd6b310 (0 MiB, fresh) +Time 2026-02-27T22:38:00.0546517Z +Commit 00001152 1197 keys in 8ms 370µs 900ns +FAM | META SEQ | SST SEQ | RANGE + 0 | 00001148 | 00001145 SST | [=======================================================================] | 3aefa6fd5cf2deb4-f42f94001fcb5351 (0 MiB, fresh) + 4 | 00001149 | 00001147 SST | [===============================================================================] | 2c3f3e9b0fcf379e-f9d23da1ef17dac4 (0 MiB, fresh) + 1 | 00001150 | 00001143 SST | [==================================================================================================] | 0051cad80c47e3ca-fff3b56bbe0e6b22 (0 MiB, fresh) + 2 | 00001151 | 00001144 SST | [==================================================================================================] | 0051cad80c47e3ca-fff3b56bbe0e6b22 (1 MiB, fresh) + 3 | 00001152 | 00001146 SST | [=================================================================================================] | 0188fb9f3f3206db-fcc7ce8836ff7dad (0 MiB, fresh) +Time 2026-02-27T22:39:58.8664201Z +Commit 00001158 4 keys in 18ms 192µs 200ns +FAM | META SEQ | SST SEQ | RANGE + 0 | 00001156 | 00001155 SST | [=======================================================================] | 3aefa6fd5cf2deb4-f42f94001fcb5351 (0 MiB, fresh) + 1 | 00001157 | 00001153 SST | O | 9c27d2b5acd6b310-9c27d2b5acd6b310 (0 MiB, fresh) + 2 | 00001158 | 00001154 SST | O | 9c27d2b5acd6b310-9c27d2b5acd6b310 (0 MiB, fresh) +Time 2026-02-27T22:41:05.9449247Z +Commit 00001164 4 keys in 6ms 778µs 700ns +FAM | META SEQ | SST SEQ | RANGE + 0 | 00001162 | 00001161 SST | [=======================================================================] | 3aefa6fd5cf2deb4-f42f94001fcb5351 (0 MiB, fresh) + 1 | 00001163 | 00001159 SST | O | b294a4237ccef201-b294a4237ccef201 (0 MiB, fresh) + 2 | 00001164 | 00001160 SST | O | b294a4237ccef201-b294a4237ccef201 (0 MiB, fresh) +Time 2026-02-27T22:41:20.8865993Z +Commit 00001174 471 keys in 9ms 435µs 900ns +FAM | META SEQ | SST SEQ | RANGE + 0 | 00001170 | 00001167 SST | [=======================================================================] | 3aefa6fd5cf2deb4-f42f94001fcb5351 (0 MiB, fresh) + 1 | 00001171 | 00001166 SST | [==================================================================================================] | 02456d67aa55580e-ff244bc5fc918227 (0 MiB, fresh) + 2 | 00001172 | 00001165 SST | [=================================================================================================] | 039acc1b0fc6d7ba-ff244bc5fc918227 (0 MiB, fresh) + 4 | 00001173 | 00001169 SST | [===========================================================] | 34a53099b72e34e8-ccd9b11d9e21da11 (0 MiB, fresh) + 3 | 00001174 | 00001168 SST | [==============================================] | 79b313ed90411b52-f130d5f225ab505d (0 MiB, fresh) +Time 2026-02-27T22:41:35.3513715Z +Commit 00001180 402 keys in 7ms 47µs 800ns +FAM | META SEQ | SST SEQ | RANGE + 0 | 00001178 | 00001177 SST | [=======================================================================] | 3aefa6fd5cf2deb4-f42f94001fcb5351 (0 MiB, fresh) + 1 | 00001179 | 00001176 SST | [==================================================================================================] | 02456d67aa55580e-fde1fb32301a48a2 (0 MiB, fresh) + 2 | 00001180 | 00001175 SST | [=================================================================================================] | 033155d55f9205e6-fde1fb32301a48a2 (0 MiB, fresh) +Time 2026-02-27T22:41:51.8922682Z +Commit 00001186 113 keys in 6ms 917µs 600ns +FAM | META SEQ | SST SEQ | RANGE + 0 | 00001184 | 00001183 SST | [=======================================================================] | 3aefa6fd5cf2deb4-f42f94001fcb5351 (0 MiB, fresh) + 1 | 00001185 | 00001182 SST | [==============================================================================================] | 091a4d0e7a459a63-fd685e31821a9a2a (0 MiB, fresh) + 2 | 00001186 | 00001181 SST | [==============================================================================================] | 091a4d0e7a459a63-fd685e31821a9a2a (0 MiB, fresh) +Time 2026-02-27T22:43:41.5896953Z +Commit 00001192 4 keys in 17ms 184µs 600ns +FAM | META SEQ | SST SEQ | RANGE + 0 | 00001190 | 00001189 SST | [=======================================================================] | 3aefa6fd5cf2deb4-f42f94001fcb5351 (0 MiB, fresh) + 1 | 00001191 | 00001187 SST | O | 801410113b08be83-801410113b08be83 (0 MiB, fresh) + 2 | 00001192 | 00001188 SST | O | 801410113b08be83-801410113b08be83 (0 MiB, fresh) +Time 2026-02-27T22:43:46.0460894Z +Commit 00001198 138 keys in 7ms 734µs 500ns +FAM | META SEQ | SST SEQ | RANGE + 0 | 00001196 | 00001195 SST | [=======================================================================] | 3aefa6fd5cf2deb4-f42f94001fcb5351 (0 MiB, fresh) + 1 | 00001197 | 00001193 SST | [==============================================================================================] | 068941e9d0822cac-fa0c8e3889b99225 (0 MiB, fresh) + 2 | 00001198 | 00001194 SST | [==============================================================================================] | 079dd3476a605273-fa0c8e3889b99225 (0 MiB, fresh) +Time 2026-02-27T22:43:52.3186156Z +Commit 00001208 2850 keys in 12ms 413µs 100ns +FAM | META SEQ | SST SEQ | RANGE + 0 | 00001204 | 00001201 SST | [=======================================================================] | 3aefa6fd5cf2deb4-f42f94001fcb5351 (0 MiB, fresh) + 1 | 00001205 | 00001200 SST | [==================================================================================================] | 000d168784b3a904-ffd966598c8595fa (0 MiB, fresh) + 2 | 00001206 | 00001199 SST | [==================================================================================================] | 000d168784b3a904-ffd966598c8595fa (6 MiB, fresh) + 4 | 00001207 | 00001203 SST | [======================================================================================] | 11197b47441eeea3-ef50ee266882e5d2 (0 MiB, fresh) + 3 | 00001208 | 00001202 SST | [================================================================================] | 08f2403670664437-d8b58dce5e27a8c1 (0 MiB, fresh) +Time 2026-02-27T22:46:59.9016919Z +Commit 00001214 1167 keys in 7ms 183µs 900ns +FAM | META SEQ | SST SEQ | RANGE + 0 | 00001212 | 00001211 SST | [=======================================================================] | 3aefa6fd5cf2deb4-f42f94001fcb5351 (0 MiB, fresh) + 2 | 00001213 | 00001209 SST | [=================================================================================================] | 0315bd6ef0760e1f-ff1373558b528b52 (0 MiB, fresh) + 1 | 00001214 | 00001210 SST | [==================================================================================================] | 0013a9e4f34335e5-ffd284765f657204 (0 MiB, fresh) +Time 2026-02-27T22:47:04.8464823Z +Commit 00001220 1262 keys in 7ms 686µs 900ns +FAM | META SEQ | SST SEQ | RANGE + 0 | 00001218 | 00001217 SST | [=======================================================================] | 3aefa6fd5cf2deb4-f42f94001fcb5351 (0 MiB, fresh) + 2 | 00001219 | 00001215 SST | [=================================================================================================] | 015aa7af8c46be57-fcc735cb29041d9f (0 MiB, fresh) + 1 | 00001220 | 00001216 SST | [==================================================================================================] | 0013a9e4f34335e5-ffd284765f657204 (0 MiB, fresh) +Time 2026-02-27T22:47:07.7562717Z +Commit 00001226 153 keys in 6ms 548µs 600ns +FAM | META SEQ | SST SEQ | RANGE + 0 | 00001224 | 00001223 SST | [=======================================================================] | 3aefa6fd5cf2deb4-f42f94001fcb5351 (0 MiB, fresh) + 1 | 00001225 | 00001222 SST | [=================================================================================================] | 03b97b635740d863-ffe64bbd36bacfc8 (0 MiB, fresh) + 2 | 00001226 | 00001221 SST | [==================================================================================================] | 0145c5bca32c1494-ffe64bbd36bacfc8 (0 MiB, fresh) +Time 2026-02-27T22:47:14.3947061Z +Commit 00001232 24 keys in 6ms 166µs 500ns +FAM | META SEQ | SST SEQ | RANGE + 0 | 00001230 | 00001229 SST | [=======================================================================] | 3aefa6fd5cf2deb4-f42f94001fcb5351 (0 MiB, fresh) + 2 | 00001231 | 00001227 SST | [==========================================================================] | 069e2de91159e9cb-c5c647feca328c20 (0 MiB, fresh) + 1 | 00001232 | 00001228 SST | [==========================================================================] | 069e2de91159e9cb-c5c647feca328c20 (0 MiB, fresh) +Time 2026-02-27T22:47:26.9424667Z +Commit 00001238 38 keys in 6ms 11µs 700ns +FAM | META SEQ | SST SEQ | RANGE + 0 | 00001236 | 00001235 SST | [=======================================================================] | 3aefa6fd5cf2deb4-f42f94001fcb5351 (0 MiB, fresh) + 1 | 00001237 | 00001234 SST | [====================================================================================] | 14f643c3d8584875-ef63e6a8b41c1ab5 (0 MiB, fresh) + 2 | 00001238 | 00001233 SST | [=======================================================================] | 14f643c3d8584875-cd73069ab87dfc3d (0 MiB, fresh) diff --git a/.next/dev/prerender-manifest.json b/.next/dev/prerender-manifest.json index 1ef39a4..caa6ce7 100644 --- a/.next/dev/prerender-manifest.json +++ b/.next/dev/prerender-manifest.json @@ -4,8 +4,8 @@ "dynamicRoutes": {}, "notFoundRoutes": [], "preview": { - "previewModeId": "a5ff04373568f8dfa89f5541b80f2935", - "previewModeSigningKey": "2b0018d3eaa31eeed67538d28afe4bfa7f66d57b8a2348421bb8a3837addb402", - "previewModeEncryptionKey": "553a3f71589831fc06cdc67a076ecfc594777a8dbcadba910eef5fe42f0bcadb" + "previewModeId": "64ea03a229f653828766a3654a7623ec", + "previewModeSigningKey": "477cbefb1eecc6237c332fd49918940f0b1f05d16c6d81d9be2d54305396dfd2", + "previewModeEncryptionKey": "9891e33f98087cd438ebe3cf068e3cf30985af06afb29929d98c4209d4b3e460" } } \ No newline at end of file diff --git a/.next/dev/server/app-paths-manifest.json b/.next/dev/server/app-paths-manifest.json index 61a5ec4..1588d1c 100644 --- a/.next/dev/server/app-paths-manifest.json +++ b/.next/dev/server/app-paths-manifest.json @@ -1,12 +1,11 @@ { "/api/auth/[...nextauth]/route": "app/api/auth/[...nextauth]/route.js", - "/api/entities/route": "app/api/entities/route.js", - "/api/projects/[id]/route": "app/api/projects/[id]/route.js", + "/api/auth/register/route": "app/api/auth/register/route.js", "/api/projects/route": "app/api/projects/route.js", "/api/user/profile/route": "app/api/user/profile/route.js", "/dashboard/page": "app/dashboard/page.js", "/login/page": "app/login/page.js", "/page": "app/page.js", - "/project/[id]/page": "app/project/[id]/page.js", - "/project/[id]/world/page": "app/project/[id]/world/page.js" + "/profile/page": "app/profile/page.js", + "/signup/page": "app/signup/page.js" } \ No newline at end of file diff --git a/.next/dev/server/chunks/ssr/[root-of-the-server]__de10d535._.js b/.next/dev/server/chunks/ssr/[root-of-the-server]__de10d535._.js index 0eef08d..aa39b2c 100644 --- a/.next/dev/server/chunks/ssr/[root-of-the-server]__de10d535._.js +++ b/.next/dev/server/chunks/ssr/[root-of-the-server]__de10d535._.js @@ -52,6 +52,15 @@ const api = { }); } }, + // --- USER --- + user: { + async updateProfile (data) { + return api.request('/user/profile', { + method: 'PUT', + body: JSON.stringify(data) + }); + } + }, // --- PROJECTS --- projects: { async list () { @@ -308,12 +317,36 @@ const useAuth = ()=>{ }, [ user ]); + const updateProfile = (0, __TURBOPACK__imported__module__$5b$project$5d2f$Documents$2f$00__$2d$__projet$2f$plumeia$2f$node_modules$2f$next$2f$dist$2f$server$2f$route$2d$modules$2f$app$2d$page$2f$vendored$2f$ssr$2f$react$2e$js__$5b$app$2d$ssr$5d$__$28$ecmascript$29$__["useCallback"])(async (updates)=>{ + if (!user) return; + try { + // Unpack everything that can be updated into a flat object for the API + const apiUpdates = {}; + if (updates.name !== undefined) apiUpdates.name = updates.name; + if (updates.avatar !== undefined) apiUpdates.avatar = updates.avatar; + if (updates.bio !== undefined) apiUpdates.bio = updates.bio; + if (updates.preferences?.dailyWordGoal !== undefined) apiUpdates.dailyWordGoal = updates.preferences.dailyWordGoal; + // Make the API call to update DB + await __TURBOPACK__imported__module__$5b$project$5d2f$Documents$2f$00__$2d$__projet$2f$plumeia$2f$src$2f$lib$2f$api$2e$ts__$5b$app$2d$ssr$5d$__$28$ecmascript$29$__["default"].user.updateProfile(apiUpdates); + // Update local state + setUser((prev)=>prev ? { + ...prev, + ...updates + } : null); + } catch (err) { + console.error('Failed to update profile:', err); + throw err; + } + }, [ + user + ]); return { user, login, signup, logout, incrementUsage, + updateProfile, loading }; }; diff --git a/.next/dev/server/chunks/ssr/[root-of-the-server]__de10d535._.js.map b/.next/dev/server/chunks/ssr/[root-of-the-server]__de10d535._.js.map index e45e96a..949d47d 100644 --- a/.next/dev/server/chunks/ssr/[root-of-the-server]__de10d535._.js.map +++ b/.next/dev/server/chunks/ssr/[root-of-the-server]__de10d535._.js.map @@ -2,14 +2,14 @@ "version": 3, "sources": [], "sections": [ - {"offset": {"line": 10, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/src/lib/api.ts"],"sourcesContent":["import { BookProject, UserProfile } from './types';\r\n\r\nconst API_BASE_URL = '/api';\r\n\r\n// --- API CLIENT ---\r\n\r\nconst api = {\r\n async request(endpoint: string, options: RequestInit = {}) {\r\n const url = `${API_BASE_URL}${endpoint}`;\r\n\r\n const headers: Record = {\r\n 'Content-Type': 'application/json',\r\n ...options.headers as Record,\r\n };\r\n\r\n const response = await fetch(url, {\r\n ...options,\r\n headers,\r\n });\r\n\r\n if (!response.ok) {\r\n let errorMsg = `Error ${response.status}: ${response.statusText}`;\r\n try {\r\n const errorJson = await response.json();\r\n if (errorJson.error) errorMsg = errorJson.error;\r\n if (errorJson.message) errorMsg = errorJson.message;\r\n } catch {\r\n // Ignore json parse error\r\n }\r\n throw new Error(errorMsg);\r\n }\r\n\r\n if (response.status === 204) return null;\r\n return response.json();\r\n },\r\n\r\n // --- AUTH ---\r\n auth: {\r\n async register(email: string, password: string, name: string) {\r\n return api.request('/auth/register', {\r\n method: 'POST',\r\n body: JSON.stringify({ email, password, name }),\r\n });\r\n },\r\n },\r\n\r\n // --- PROJECTS ---\r\n projects: {\r\n async list() {\r\n return api.request('/projects');\r\n },\r\n\r\n async get(id: string) {\r\n return api.request(`/projects/${id}`);\r\n },\r\n\r\n async create(data: { title: string; author: string; settings?: any }) {\r\n return api.request('/projects', {\r\n method: 'POST',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async update(id: string, data: any) {\r\n return api.request(`/projects/${id}`, {\r\n method: 'PUT',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async delete(id: string) {\r\n return api.request(`/projects/${id}`, {\r\n method: 'DELETE',\r\n });\r\n },\r\n\r\n async syncWorkflow(id: string, data: { nodes: any[]; connections: any[] }) {\r\n return api.request(`/projects/${id}/workflow`, {\r\n method: 'PUT',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n },\r\n\r\n // --- CHAPTERS ---\r\n chapters: {\r\n async create(data: { projectId: string; title?: string; content?: string; summary?: string; orderIndex?: number }) {\r\n return api.request('/chapters', {\r\n method: 'POST',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async update(id: string, data: any) {\r\n return api.request(`/chapters/${id}`, {\r\n method: 'PUT',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async delete(id: string) {\r\n return api.request(`/chapters/${id}`, {\r\n method: 'DELETE',\r\n });\r\n },\r\n },\r\n\r\n // --- ENTITIES ---\r\n entities: {\r\n async create(data: { projectId: string; type: string; name?: string; description?: string; details?: string; attributes?: any; customValues?: any }) {\r\n return api.request('/entities', {\r\n method: 'POST',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async update(id: string, data: any) {\r\n return api.request(`/entities/${id}`, {\r\n method: 'PUT',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async delete(id: string) {\r\n return api.request(`/entities/${id}`, {\r\n method: 'DELETE',\r\n });\r\n },\r\n },\r\n\r\n // --- IDEAS ---\r\n ideas: {\r\n async create(data: { projectId: string; title?: string; description?: string; status?: string; category?: string }) {\r\n return api.request('/ideas', {\r\n method: 'POST',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async update(id: string, data: any) {\r\n return api.request(`/ideas/${id}`, {\r\n method: 'PUT',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async delete(id: string) {\r\n return api.request(`/ideas/${id}`, {\r\n method: 'DELETE',\r\n });\r\n },\r\n },\r\n\r\n // --- AI (server-side via API routes) ---\r\n ai: {\r\n async generate(project: BookProject, chapterId: string, prompt: string, user: UserProfile) {\r\n return api.request<{ text: string; type: 'draft' | 'reflection' }>('/ai/generate', {\r\n method: 'POST',\r\n body: JSON.stringify({ project, chapterId, prompt, user }),\r\n });\r\n },\r\n\r\n async transform(text: string, mode: string, context: string, user: UserProfile) {\r\n const res = await api.request<{ text: string }>('/ai/transform', {\r\n method: 'POST',\r\n body: JSON.stringify({ text, mode, context, user }),\r\n });\r\n return res.text;\r\n },\r\n },\r\n};\r\n\r\nexport default api;\r\n"],"names":[],"mappings":";;;;AAEA,MAAM,eAAe;AAErB,qBAAqB;AAErB,MAAM,MAAM;IACR,MAAM,SAAiB,QAAgB,EAAE,UAAuB,CAAC,CAAC;QAC9D,MAAM,MAAM,GAAG,eAAe,UAAU;QAExC,MAAM,UAAkC;YACpC,gBAAgB;YAChB,GAAG,QAAQ,OAAO;QACtB;QAEA,MAAM,WAAW,MAAM,MAAM,KAAK;YAC9B,GAAG,OAAO;YACV;QACJ;QAEA,IAAI,CAAC,SAAS,EAAE,EAAE;YACd,IAAI,WAAW,CAAC,MAAM,EAAE,SAAS,MAAM,CAAC,EAAE,EAAE,SAAS,UAAU,EAAE;YACjE,IAAI;gBACA,MAAM,YAAY,MAAM,S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oB,EAAE,SAAiB,EAAE,MAAc,EAAE,IAAiB;YACrF,OAAO,IAAI,OAAO,CAAiD,gBAAgB;gBAC/E,QAAQ;gBACR,MAAM,KAAK,SAAS,CAAC;oBAAE;oBAAS;oBAAW;oBAAQ;gBAAK;YAC5D;QACJ;QAEA,MAAM,WAAU,IAAY,EAAE,IAAY,EAAE,OAAe,EAAE,IAAiB;YAC1E,MAAM,MAAM,MAAM,IAAI,OAAO,CAAmB,iBAAiB;gBAC7D,QAAQ;gBACR,MAAM,KAAK,SAAS,CAAC;oBAAE;oBAAM;oBAAM;oBAAS;gBAAK;YACrD;YACA,OAAO,IAAI,IAAI;QACnB;IACJ;AACJ;uCAEe"}}, - {"offset": {"line": 178, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/src/hooks/useAuth.ts"],"sourcesContent":["'use client';\r\n\r\nimport { useState, useEffect, useCallback } from 'react';\r\nimport { signIn, signOut, useSession } from 'next-auth/react';\r\nimport { UserProfile } from '@/lib/types';\r\nimport api from '@/lib/api';\r\n\r\nexport const useAuth = () => {\r\n const { data: session, status } = useSession();\r\n const [user, setUser] = useState(null);\r\n const loading = status === 'loading';\r\n\r\n // Fetch real profile from DB when session is available\r\n useEffect(() => {\r\n if (session?.user?.id) {\r\n fetch('/api/user/profile', { cache: 'no-store' })\r\n .then(res => res.json())\r\n .then(dbUser => {\r\n const planId = dbUser.plan || 'free';\r\n const planDetails = dbUser.planDetails || {\r\n id: 'free',\r\n displayName: 'Gratuit',\r\n maxAiActions: 100,\r\n maxProjects: 3\r\n };\r\n\r\n setUser({\r\n id: dbUser.id,\r\n email: dbUser.email,\r\n name: dbUser.name || 'User',\r\n avatar: dbUser.avatar,\r\n bio: dbUser.bio,\r\n subscription: {\r\n plan: planId,\r\n planDetails: planDetails,\r\n startDate: new Date(dbUser.createdAt).getTime(),\r\n status: 'active'\r\n },\r\n usage: {\r\n aiActionsCurrent: dbUser.aiActionsUsed || 0,\r\n aiActionsLimit: planDetails.maxAiActions,\r\n projectsLimit: planDetails.maxProjects,\r\n },\r\n preferences: { theme: 'light', dailyWordGoal: dbUser.dailyWordGoal || 500, language: 'fr' },\r\n stats: {\r\n totalWordsWritten: dbUser.totalWords || 0,\r\n writingStreak: dbUser.writingStreak || 0,\r\n lastWriteDate: dbUser.lastWriteDate ? new Date(dbUser.lastWriteDate).getTime() : 0,\r\n },\r\n });\r\n })\r\n .catch(err => {\r\n console.error('Failed to fetch user profile:', err);\r\n // Fallback to session data\r\n setUser({\r\n id: session.user.id || '',\r\n email: session.user.email || '',\r\n name: session.user.name || 'User',\r\n subscription: { plan: 'free', startDate: Date.now(), status: 'active' },\r\n usage: { aiActionsCurrent: 0, aiActionsLimit: 100, projectsLimit: 3 },\r\n preferences: { theme: 'light', dailyWordGoal: 500, language: 'fr' },\r\n stats: { totalWordsWritten: 0, writingStreak: 0, lastWriteDate: 0 },\r\n });\r\n });\r\n } else if (status === 'unauthenticated') {\r\n setUser(null);\r\n }\r\n }, [session, status]);\r\n\r\n const login = useCallback(async (email: string, password: string) => {\r\n const result = await signIn('credentials', {\r\n email,\r\n password,\r\n redirect: false,\r\n });\r\n\r\n if (result?.error) {\r\n throw new Error(result.error === 'CredentialsSignin'\r\n ? 'Email ou mot de passe incorrect'\r\n : result.error\r\n );\r\n }\r\n }, []);\r\n\r\n const signup = useCallback(async (email: string, password: string, name: string) => {\r\n await api.auth.register(email, password, name);\r\n const result = await signIn('credentials', {\r\n email,\r\n password,\r\n redirect: false,\r\n });\r\n if (result?.error) {\r\n throw new Error('Compte créé mais erreur de connexion automatique');\r\n }\r\n }, []);\r\n\r\n const logout = useCallback(async () => {\r\n await signOut({ redirect: false });\r\n setUser(null);\r\n }, []);\r\n\r\n const incrementUsage = useCallback((serverCount?: number) => {\r\n if (user) {\r\n setUser({\r\n ...user,\r\n usage: {\r\n ...user.usage,\r\n aiActionsCurrent: serverCount !== undefined ? serverCount : user.usage.aiActionsCurrent + 1,\r\n },\r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C,IAAI,MAAM;YACN,QAAQ;gBACJ,GAAG,IAAI;gBACP,OAAO;oBACH,GAAG,KAAK,KAAK;oBACb,kBAAkB,gBAAgB,YAAY,cAAc,KAAK,KAAK,CAAC,gBAAgB,GAAG;gBAC9F;YACJ;QACJ;IACJ,GAAG;QAAC;KAAK;IAET,OAAO;QAAE;QAAM;QAAO;QAAQ;QAAQ;QAAgB;IAAQ;AAClE"}}, - {"offset": {"line": 323, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/src/providers/AuthProvider.tsx"],"sourcesContent":["'use client';\r\n\r\nimport React, { createContext, useContext } from 'react';\r\nimport { SessionProvider } from 'next-auth/react';\r\nimport { useAuth } from '@/hooks/useAuth';\r\n\r\nconst AuthContext = createContext(null);\r\n\r\nfunction AuthInner({ children }: { children: React.ReactNode }) {\r\n const auth = useAuth();\r\n return {children};\r\n}\r\n\r\nexport const AuthProvider: React.FC<{ children: React.ReactNode }> = ({ children }) => {\r\n return (\r\n \r\n {children}\r\n \r\n );\r\n};\r\n\r\nexport function useAuthContext() {\r\n return useContext(AuthContext);\r\n}\r\n"],"names":[],"mappings":";;;;;;;AAEA;AACA;AACA;AAJA;;;;;AAMA,MAAM,4BAAc,IAAA,kQAAa,EAAM;AAEvC,SAAS,UAAU,EAAE,QAAQ,EAAiC;IAC1D,MAAM,OAAO,IAAA,8KAAO;IACpB,qBAAO,0RAAC,YAAY,QAAQ;QAAC,OAAO;kBAAO;;;;;;AAC/C;AAEO,MAAM,eAAwD,CAAC,EAAE,QAAQ,EAAE;IAC9E,qBACI,0RAAC,oMAAe;kBACZ,cAAA,0RAAC;sBAAW;;;;;;;;;;;AAGxB;AAEO,SAAS;IACZ,OAAO,IAAA,+PAAU,EAAC;AACtB"}}, - {"offset": {"line": 372, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/node_modules/next/src/server/route-modules/app-page/module.compiled.js"],"sourcesContent":["if (process.env.NEXT_RUNTIME === 'edge') {\n module.exports = require('next/dist/server/route-modules/app-page/module.js')\n} else {\n if (process.env.__NEXT_EXPERIMENTAL_REACT) {\n if (process.env.NODE_ENV === 'development') {\n if (process.env.TURBOPACK) {\n module.exports = require('next/dist/compiled/next-server/app-page-turbo-experimental.runtime.dev.js')\n } else {\n module.exports = require('next/dist/compiled/next-server/app-page-experimental.runtime.dev.js')\n }\n } else {\n if (process.env.TURBOPACK) {\n module.exports = require('next/dist/compiled/next-server/app-page-turbo-experimental.runtime.prod.js')\n } else {\n module.exports = require('next/dist/compiled/next-server/app-page-experimental.runtime.prod.js')\n }\n }\n } else {\n if (process.env.NODE_ENV === 'development') {\n if (process.env.TURBOPACK) {\n module.exports = require('next/dist/compiled/next-server/app-page-turbo.runtime.dev.js')\n } else {\n module.exports = require('next/dist/compiled/next-server/app-page.runtime.dev.js')\n }\n } else {\n if (process.env.TURBOPACK) {\n module.exports = require('next/dist/compiled/next-server/app-page-turbo.runtime.prod.js')\n } else {\n module.exports = require('next/dist/compiled/next-server/app-page.runtime.prod.js')\n }\n }\n }\n}\n"],"names":["process","env","NEXT_RUNTIME","module","exports","require","__NEXT_EXPERIMENTAL_REACT","NODE_ENV","TURBOPACK"],"mappings":"AAAA,IAAIA,QAAQC,GAAG,CAACC,YAAY,KAAK,QAAQ;;KAElC;IACL,IAAIF,QAAQC,GAAG,CAACK,yBAAyB,EAAE;;SAcpC;QACL,IAAIN,QAAQC,GAAG,CAACM,QAAQ,KAAK,WAAe;YAC1C,IAAIP,QAAQC,GAAG,CAACO,SAAS,eAAE;gBACzBL,OAAOC,OAAO,GAAGC,QAAQ;YAC3B,OAAO;;QAGT,OAAO;;IAOT;AACF","ignoreList":[0]}}, - {"offset": {"line": 391, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/node_modules/next/src/server/route-modules/app-page/vendored/ssr/react-jsx-dev-runtime.ts"],"sourcesContent":["module.exports = (\n require('../../module.compiled') as typeof import('../../module.compiled')\n).vendored['react-ssr']!.ReactJsxDevRuntime\n"],"names":["module","exports","require","vendored","ReactJsxDevRuntime"],"mappings":"AAAAA,OAAOC,OAAO,GACZC,QAAQ,0JACRC,QAAQ,CAAC,YAAY,CAAEC,kBAAkB","ignoreList":[0]}}, - {"offset": {"line": 396, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/node_modules/next/src/server/route-modules/app-page/vendored/ssr/react.ts"],"sourcesContent":["module.exports = (\n require('../../module.compiled') as typeof import('../../module.compiled')\n).vendored['react-ssr']!.React\n"],"names":["module","exports","require","vendored","React"],"mappings":"AAAAA,OAAOC,OAAO,GACZC,QAAQ,0JACRC,QAAQ,CAAC,YAAY,CAAEC,KAAK","ignoreList":[0]}}, - {"offset": {"line": 401, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/node_modules/next/src/server/route-modules/app-page/vendored/ssr/react-jsx-runtime.ts"],"sourcesContent":["module.exports = (\n require('../../module.compiled') as typeof import('../../module.compiled')\n).vendored['react-ssr']!.ReactJsxRuntime\n"],"names":["module","exports","require","vendored","ReactJsxRuntime"],"mappings":"AAAAA,OAAOC,OAAO,GACZC,QAAQ,0JACRC,QAAQ,CAAC,YAAY,CAAEC,eAAe","ignoreList":[0]}}, - {"offset": {"line": 406, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/node_modules/%40auth/core/errors.js"],"sourcesContent":["/**\n * Base error class for all Auth.js errors.\n * It's optimized to be printed in the server logs in a nicely formatted way\n * via the [`logger.error`](https://authjs.dev/reference/core#logger) option.\n * @noInheritDoc\n */\nexport class AuthError extends Error {\n /** @internal */\n constructor(message, errorOptions) {\n if (message instanceof Error) {\n super(undefined, {\n cause: { err: message, ...message.cause, ...errorOptions },\n });\n }\n else if (typeof message === \"string\") {\n if (errorOptions instanceof Error) {\n errorOptions = { err: errorOptions, ...errorOptions.cause };\n }\n super(message, errorOptions);\n }\n else {\n super(undefined, message);\n }\n this.name = this.constructor.name;\n // @ts-expect-error https://github.com/microsoft/TypeScript/issues/3841\n this.type = this.constructor.type ?? \"AuthError\";\n // @ts-expect-error https://github.com/microsoft/TypeScript/issues/3841\n this.kind = this.constructor.kind ?? \"error\";\n Error.captureStackTrace?.(this, this.constructor);\n const url = `https://errors.authjs.dev#${this.type.toLowerCase()}`;\n this.message += `${this.message ? \". \" : \"\"}Read more at ${url}`;\n }\n}\n/**\n * Thrown when the user's sign-in attempt failed.\n * @noInheritDoc\n */\nexport class SignInError extends AuthError {\n}\n/** @internal */\nSignInError.kind = \"signIn\";\n/**\n * One of the database [`Adapter` methods](https://authjs.dev/reference/core/adapters#methods)\n * failed during execution.\n *\n * :::tip\n * If `debug: true` is set, you can check out `[auth][debug]` in the logs to learn more about the failed adapter method execution.\n * @example\n * ```sh\n * [auth][debug]: adapter_getUserByEmail\n * { \"args\": [undefined] }\n * ```\n * :::\n * @noInheritDoc\n */\nexport class AdapterError extends AuthError {\n}\nAdapterError.type = \"AdapterError\";\n/**\n * Thrown when the execution of the [`signIn` callback](https://authjs.dev/reference/core/types#signin) fails\n * or if it returns `false`.\n * @noInheritDoc\n */\nexport class AccessDenied extends AuthError {\n}\nAccessDenied.type = \"AccessDenied\";\n/**\n * This error occurs when the user cannot finish login.\n * Depending on the provider type, this could have happened for multiple reasons.\n *\n * :::tip\n * Check out `[auth][details]` in the logs to know which provider failed.\n * @example\n * ```sh\n * [auth][details]: { \"provider\": \"github\" }\n * ```\n * :::\n *\n * For an [OAuth provider](https://authjs.dev/getting-started/authentication/oauth), possible causes are:\n * - The user denied access to the application\n * - There was an error parsing the OAuth Profile:\n * Check out the provider's `profile` or `userinfo.request` method to make sure\n * it correctly fetches the user's profile.\n * - The `signIn` or `jwt` callback methods threw an uncaught error:\n * Check the callback method implementations.\n *\n * For an [Email provider](https://authjs.dev/getting-started/authentication/email), possible causes are:\n * - The provided email/token combination was invalid/missing:\n * Check if the provider's `sendVerificationRequest` method correctly sends the email.\n * - The provided email/token combination has expired:\n * Ask the user to log in again.\n * - There was an error with the database:\n * Check the database logs.\n *\n * For a [Credentials provider](https://authjs.dev/getting-started/authentication/credentials), possible causes are:\n * - The `authorize` method threw an uncaught error:\n * Check the provider's `authorize` method.\n * - The `signIn` or `jwt` callback methods threw an uncaught error:\n * Check the callback method implementations.\n *\n * :::tip\n * Check out `[auth][cause]` in the error message for more details.\n * It will show the original stack trace.\n * :::\n * @noInheritDoc\n */\nexport class CallbackRouteError extends AuthError {\n}\nCallbackRouteError.type = \"CallbackRouteError\";\n/**\n * Thrown when Auth.js is misconfigured and accidentally tried to require authentication on a custom error page.\n * To prevent an infinite loop, Auth.js will instead render its default error page.\n *\n * To fix this, make sure that the `error` page does not require authentication.\n *\n * Learn more at [Guide: Error pages](https://authjs.dev/guides/pages/error)\n * @noInheritDoc\n */\nexport class ErrorPageLoop extends AuthError {\n}\nErrorPageLoop.type = \"ErrorPageLoop\";\n/**\n * One of the [`events` methods](https://authjs.dev/reference/core/types#eventcallbacks)\n * failed during execution.\n *\n * Make sure that the `events` methods are implemented correctly and uncaught errors are handled.\n *\n * Learn more at [`events`](https://authjs.dev/reference/core/types#eventcallbacks)\n * @noInheritDoc\n */\nexport class EventError extends AuthError {\n}\nEventError.type = \"EventError\";\n/**\n * Thrown when Auth.js is unable to verify a `callbackUrl` value.\n * The browser either disabled cookies or the `callbackUrl` is not a valid URL.\n *\n * Somebody might have tried to manipulate the callback URL that Auth.js uses to redirect the user back to the configured `callbackUrl`/page.\n * This could be a malicious hacker trying to redirect the user to a phishing site.\n * To prevent this, Auth.js checks if the callback URL is valid and throws this error if it is not.\n *\n * There is no action required, but it might be an indicator that somebody is trying to attack your application.\n * @noInheritDoc\n */\nexport class InvalidCallbackUrl extends AuthError {\n}\nInvalidCallbackUrl.type = \"InvalidCallbackUrl\";\n/**\n * Can be thrown from the `authorize` callback of the Credentials provider.\n * When an error occurs during the `authorize` callback, two things can happen:\n * 1. The user is redirected to the signin page, with `error=CredentialsSignin&code=credentials` in the URL. `code` is configurable.\n * 2. If you throw this error in a framework that handles form actions server-side, this error is thrown, instead of redirecting the user, so you'll need to handle.\n * @noInheritDoc\n */\nexport class CredentialsSignin extends SignInError {\n constructor() {\n super(...arguments);\n /**\n * The error code that is set in the `code` query parameter of the redirect URL.\n *\n *\n * ⚠ NOTE: This property is going to be included in the URL, so make sure it does not hint at sensitive errors.\n *\n * The full error is always logged on the server, if you need to debug.\n *\n * Generally, we don't recommend hinting specifically if the user had either a wrong username or password specifically,\n * try rather something like \"Invalid credentials\".\n */\n this.code = \"credentials\";\n }\n}\nCredentialsSignin.type = \"CredentialsSignin\";\n/**\n * One of the configured OAuth or OIDC providers is missing the `authorization`, `token` or `userinfo`, or `issuer` configuration.\n * To perform OAuth or OIDC sign in, at least one of these endpoints is required.\n *\n * Learn more at [`OAuth2Config`](https://authjs.dev/reference/core/providers#oauth2configprofile) or [Guide: OAuth Provider](https://authjs.dev/guides/configuring-oauth-providers)\n * @noInheritDoc\n */\nexport class InvalidEndpoints extends AuthError {\n}\nInvalidEndpoints.type = \"InvalidEndpoints\";\n/**\n * Thrown when a PKCE, state or nonce OAuth check could not be performed.\n * This could happen if the OAuth provider is configured incorrectly or if the browser is blocking cookies.\n *\n * Learn more at [`checks`](https://authjs.dev/reference/core/providers#checks)\n * @noInheritDoc\n */\nexport class InvalidCheck extends AuthError {\n}\nInvalidCheck.type = \"InvalidCheck\";\n/**\n * Logged on the server when Auth.js could not decode or encode a JWT-based (`strategy: \"jwt\"`) session.\n *\n * Possible causes are either a misconfigured `secret` or a malformed JWT or `encode/decode` methods.\n *\n * :::note\n * When this error is logged, the session cookie is destroyed.\n * :::\n *\n * Learn more at [`secret`](https://authjs.dev/reference/core#secret), [`jwt.encode`](https://authjs.dev/reference/core/jwt#encode-1) or [`jwt.decode`](https://authjs.dev/reference/core/jwt#decode-2) for more information.\n * @noInheritDoc\n */\nexport class JWTSessionError extends AuthError {\n}\nJWTSessionError.type = \"JWTSessionError\";\n/**\n * Thrown if Auth.js is misconfigured. This could happen if you configured an Email provider but did not set up a database adapter,\n * or tried using a `strategy: \"database\"` session without a database adapter.\n * In both cases, make sure you either remove the configuration or add the missing adapter.\n *\n * Learn more at [Database Adapters](https://authjs.dev/getting-started/database), [Email provider](https://authjs.dev/getting-started/authentication/email) or [Concept: Database session strategy](https://authjs.dev/concepts/session-strategies#database-session)\n * @noInheritDoc\n */\nexport class MissingAdapter extends AuthError {\n}\nMissingAdapter.type = \"MissingAdapter\";\n/**\n * Thrown similarily to [`MissingAdapter`](https://authjs.dev/reference/core/errors#missingadapter), but only some required methods were missing.\n *\n * Make sure you either remove the configuration or add the missing methods to the adapter.\n *\n * Learn more at [Database Adapters](https://authjs.dev/getting-started/database)\n * @noInheritDoc\n */\nexport class MissingAdapterMethods extends AuthError {\n}\nMissingAdapterMethods.type = \"MissingAdapterMethods\";\n/**\n * Thrown when a Credentials provider is missing the `authorize` configuration.\n * To perform credentials sign in, the `authorize` method is required.\n *\n * Learn more at [Credentials provider](https://authjs.dev/getting-started/authentication/credentials)\n * @noInheritDoc\n */\nexport class MissingAuthorize extends AuthError {\n}\nMissingAuthorize.type = \"MissingAuthorize\";\n/**\n * Auth.js requires a secret or multiple secrets to be set, but none was not found. This is used to encrypt cookies, JWTs and other sensitive data.\n *\n * :::note\n * If you are using a framework like Next.js, we try to automatically infer the secret from the `AUTH_SECRET`, `AUTH_SECRET_1`, etc. environment variables.\n * Alternatively, you can also explicitly set the [`AuthConfig.secret`](https://authjs.dev/reference/core#secret) option.\n * :::\n *\n *\n * :::tip\n * To generate a random string, you can use the Auth.js CLI: `npx auth secret`\n * :::\n * @noInheritDoc\n */\nexport class MissingSecret extends AuthError {\n}\nMissingSecret.type = \"MissingSecret\";\n/**\n * Thrown when an Email address is already associated with an account\n * but the user is trying an OAuth account that is not linked to it.\n *\n * For security reasons, Auth.js does not automatically link OAuth accounts to existing accounts if the user is not signed in.\n *\n * :::tip\n * If you trust the OAuth provider to have verified the user's email address,\n * you can enable automatic account linking by setting [`allowDangerousEmailAccountLinking: true`](https://authjs.dev/reference/core/providers#allowdangerousemailaccountlinking)\n * in the provider configuration.\n * :::\n * @noInheritDoc\n */\nexport class OAuthAccountNotLinked extends SignInError {\n}\nOAuthAccountNotLinked.type = \"OAuthAccountNotLinked\";\n/**\n * Thrown when an OAuth provider returns an error during the sign in process.\n * This could happen for example if the user denied access to the application or there was a configuration error.\n *\n * For a full list of possible reasons, check out the specification [Authorization Code Grant: Error Response](https://www.rfc-editor.org/rfc/rfc6749#section-4.1.2.1)\n * @noInheritDoc\n */\nexport class OAuthCallbackError extends SignInError {\n}\nOAuthCallbackError.type = \"OAuthCallbackError\";\n/**\n * This error occurs during an OAuth sign in attempt when the provider's\n * response could not be parsed. This could for example happen if the provider's API\n * changed, or the [`OAuth2Config.profile`](https://authjs.dev/reference/core/providers#oauth2configprofile) method is not implemented correctly.\n * @noInheritDoc\n */\nexport class OAuthProfileParseError extends AuthError {\n}\nOAuthProfileParseError.type = \"OAuthProfileParseError\";\n/**\n * Logged on the server when Auth.js could not retrieve a session from the database (`strategy: \"database\"`).\n *\n * The database adapter might be misconfigured or the database is not reachable.\n *\n * Learn more at [Concept: Database session strategy](https://authjs.dev/concepts/session-strategies#database)\n * @noInheritDoc\n */\nexport class SessionTokenError extends AuthError {\n}\nSessionTokenError.type = \"SessionTokenError\";\n/**\n * Happens when login by [OAuth](https://authjs.dev/getting-started/authentication/oauth) could not be started.\n *\n * Possible causes are:\n * - The Authorization Server is not compliant with the [OAuth 2.0](https://www.ietf.org/rfc/rfc6749.html) or the [OIDC](https://openid.net/specs/openid-connect-core-1_0.html) specification.\n * Check the details in the error message.\n *\n * :::tip\n * Check out `[auth][details]` in the logs to know which provider failed.\n * @example\n * ```sh\n * [auth][details]: { \"provider\": \"github\" }\n * ```\n * :::\n * @noInheritDoc\n */\nexport class OAuthSignInError extends SignInError {\n}\nOAuthSignInError.type = \"OAuthSignInError\";\n/**\n * Happens when the login by an [Email provider](https://authjs.dev/getting-started/authentication/email) could not be started.\n *\n * Possible causes are:\n * - The email sent from the client is invalid, could not be normalized by [`EmailConfig.normalizeIdentifier`](https://authjs.dev/reference/core/providers/email#normalizeidentifier)\n * - The provided email/token combination has expired:\n * Ask the user to log in again.\n * - There was an error with the database:\n * Check the database logs.\n * @noInheritDoc\n */\nexport class EmailSignInError extends SignInError {\n}\nEmailSignInError.type = \"EmailSignInError\";\n/**\n * Represents an error that occurs during the sign-out process. This error\n * is logged when there are issues in terminating a user's session, either\n * by failing to delete the session from the database (in database session\n * strategies) or encountering issues during other parts of the sign-out\n * process, such as emitting sign-out events or clearing session cookies.\n *\n * The session cookie(s) are emptied even if this error is logged.\n * @noInheritDoc\n */\nexport class SignOutError extends AuthError {\n}\nSignOutError.type = \"SignOutError\";\n/**\n * Auth.js was requested to handle an operation that it does not support.\n *\n * See [`AuthAction`](https://authjs.dev/reference/core/types#authaction) for the supported actions.\n * @noInheritDoc\n */\nexport class UnknownAction extends AuthError {\n}\nUnknownAction.type = \"UnknownAction\";\n/**\n * Thrown when a Credentials provider is present but the JWT strategy (`strategy: \"jwt\"`) is not enabled.\n *\n * Learn more at [`strategy`](https://authjs.dev/reference/core#strategy) or [Credentials provider](https://authjs.dev/getting-started/authentication/credentials)\n * @noInheritDoc\n */\nexport class UnsupportedStrategy extends AuthError {\n}\nUnsupportedStrategy.type = \"UnsupportedStrategy\";\n/**\n * Thrown when an endpoint was incorrectly called without a provider, or with an unsupported provider.\n * @noInheritDoc\n */\nexport class InvalidProvider extends AuthError {\n}\nInvalidProvider.type = \"InvalidProvider\";\n/**\n * Thrown when the `trustHost` option was not set to `true`.\n *\n * Auth.js requires the `trustHost` option to be set to `true` since it's relying on the request headers' `host` value.\n *\n * :::note\n * Official Auth.js libraries might attempt to automatically set the `trustHost` option to `true` if the request is coming from a trusted host on a trusted platform.\n * :::\n *\n * Learn more at [`trustHost`](https://authjs.dev/reference/core#trusthost) or [Guide: Deployment](https://authjs.dev/getting-started/deployment)\n * @noInheritDoc\n */\nexport class UntrustedHost extends AuthError {\n}\nUntrustedHost.type = \"UntrustedHost\";\n/**\n * The user's email/token combination was invalid.\n * This could be because the email/token combination was not found in the database,\n * or because the token has expired. Ask the user to log in again.\n * @noInheritDoc\n */\nexport class Verification extends AuthError {\n}\nVerification.type = \"Verification\";\n/**\n * Error for missing CSRF tokens in client-side actions (`signIn`, `signOut`, `useSession#update`).\n * Thrown when actions lack the double submit cookie, essential for CSRF protection.\n *\n * CSRF ([Cross-Site Request Forgery](https://owasp.org/www-community/attacks/csrf))\n * is an attack leveraging authenticated user credentials for unauthorized actions.\n *\n * Double submit cookie pattern, a CSRF defense, requires matching values in a cookie\n * and request parameter. More on this at [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Glossary/CSRF).\n * @noInheritDoc\n */\nexport class MissingCSRF extends SignInError {\n}\nMissingCSRF.type = \"MissingCSRF\";\nconst clientErrors = new Set([\n \"CredentialsSignin\",\n \"OAuthAccountNotLinked\",\n \"OAuthCallbackError\",\n \"AccessDenied\",\n \"Verification\",\n \"MissingCSRF\",\n \"AccountNotLinked\",\n \"WebAuthnVerificationError\",\n]);\n/**\n * Used to only allow sending a certain subset of errors to the client.\n * Errors are always logged on the server, but to prevent leaking sensitive information,\n * only a subset of errors are sent to the client as-is.\n * @internal\n */\nexport function isClientError(error) {\n if (error instanceof AuthError)\n return clientErrors.has(error.type);\n return false;\n}\n/**\n * Thrown when multiple providers have `enableConditionalUI` set to `true`.\n * Only one provider can have this option enabled at a time.\n * @noInheritDoc\n */\nexport class DuplicateConditionalUI extends AuthError {\n}\nDuplicateConditionalUI.type = \"DuplicateConditionalUI\";\n/**\n * Thrown when a WebAuthn provider has `enableConditionalUI` set to `true` but no formField has `webauthn` in its autocomplete param.\n *\n * The `webauthn` autocomplete param is required for conditional UI to work.\n * @noInheritDoc\n */\nexport class MissingWebAuthnAutocomplete extends AuthError {\n}\nMissingWebAuthnAutocomplete.type = \"MissingWebAuthnAutocomplete\";\n/**\n * Thrown when a WebAuthn provider fails to verify a client response.\n * @noInheritDoc\n */\nexport class WebAuthnVerificationError extends AuthError {\n}\nWebAuthnVerificationError.type = \"WebAuthnVerificationError\";\n/**\n * Thrown when an Email address is already associated with an account\n * but the user is trying an account that is not linked to it.\n *\n * For security reasons, Auth.js does not automatically link accounts to existing accounts if the user is not signed in.\n * @noInheritDoc\n */\nexport class AccountNotLinked extends SignInError {\n}\nAccountNotLinked.type = \"AccountNotLinked\";\n/**\n * Thrown when an experimental feature is used but not enabled.\n * @noInheritDoc\n */\nexport class ExperimentalFeatureNotEnabled extends AuthError {\n}\nExperimentalFeatureNotEnabled.type = \"ExperimentalFeatureNotEnabled\";\n"],"names":[],"mappings":"AAAA;;;;;CAKC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACM,MAAM,kBAAkB;IAC3B,cAAc,GACd,YAAY,OAAO,EAAE,YAAY,CAAE;QAC/B,IAAI,mBAAmB,OAAO;YAC1B,KAAK,CAAC,WAAW;gBACb,OAAO;oBAAE,KAAK;oBAAS,GAAG,QAAQ,KAAK;oBAAE,GAAG,YAAY;gBAAC;YAC7D;QACJ,OACK,IAAI,OAAO,YAAY,UAAU;YAClC,IAAI,wBAAwB,OAAO;gBAC/B,eAAe;oBAAE,KAAK;oBAAc,GAAG,aAAa,KAAK;gBAAC;YAC9D;YACA,KAAK,CAAC,SAAS;QACnB,OACK;YACD,KAAK,CAAC,WAAW;QACrB;QACA,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,WAAW,CAAC,IAAI;QACjC,uEAAuE;QACvE,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,WAAW,CAAC,IAAI,IAAI;QACrC,uEAAuE;QACvE,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,WAAW,CAAC,IAAI,IAAI;QACrC,MAAM,iBA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GAAG;AASvB,MAAM,0BAA0B;AACvC;AACA,kBAAkB,IAAI,GAAG;AAiBlB,MAAM,yBAAyB;AACtC;AACA,iBAAiB,IAAI,GAAG;AAYjB,MAAM,yBAAyB;AACtC;AACA,iBAAiB,IAAI,GAAG;AAWjB,MAAM,qBAAqB;AAClC;AACA,aAAa,IAAI,GAAG;AAOb,MAAM,sBAAsB;AACnC;AACA,cAAc,IAAI,GAAG;AAOd,MAAM,4BAA4B;AACzC;AACA,oBAAoB,IAAI,GAAG;AAKpB,MAAM,wBAAwB;AACrC;AACA,gBAAgB,IAAI,GAAG;AAahB,MAAM,sBAAsB;AACnC;AACA,cAAc,IAAI,GAAG;AAOd,MAAM,qBAAqB;AAClC;AACA,aAAa,IAAI,GAAG;AAYb,MAAM,oBAAoB;AACjC;AACA,YAAY,IAAI,GAAG;AACnB,MAAM,eAAe,IAAI,IAAI;IACzB;IACA;IACA;IACA;IACA;IACA;IACA;IACA;CACH;AAOM,SAAS,cAAc,KAAK;IAC/B,IAAI,iBAAiB,WACjB,OAAO,aAAa,GAAG,CAAC,MAAM,IAAI;IACtC,OAAO;AACX;AAMO,MAAM,+BAA+B;AAC5C;AACA,uBAAuB,IAAI,GAAG;AAOvB,MAAM,oCAAoC;AACjD;AACA,4BAA4B,IAAI,GAAG;AAK5B,MAAM,kCAAkC;AAC/C;AACA,0BAA0B,IAAI,GAAG;AAQ1B,MAAM,yBAAyB;AACtC;AACA,iBAAiB,IAAI,GAAG;AAKjB,MAAM,sCAAsC;AACnD;AACA,8BAA8B,IAAI,GAAG","ignoreList":[0]}}, - {"offset": {"line": 645, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/node_modules/next-auth/lib/client.js"],"sourcesContent":["\"use client\";\nimport * as React from \"react\";\nimport { AuthError } from \"@auth/core/errors\";\n/** @todo */\nclass ClientFetchError extends AuthError {\n}\n/** @todo */\nexport class ClientSessionError extends AuthError {\n}\n// ------------------------ Internal ------------------------\n/**\n * If passed 'appContext' via getInitialProps() in _app.js\n * then get the req object from ctx and use that for the\n * req value to allow `fetchData` to\n * work seemlessly in getInitialProps() on server side\n * pages *and* in _app.js.\n * @internal\n */\nexport async function fetchData(path, __NEXTAUTH, logger, req = {}) {\n const url = `${apiBaseUrl(__NEXTAUTH)}/${path}`;\n try {\n const options = {\n headers: {\n \"Content-Type\": \"application/json\",\n ...(req?.headers?.cookie ? { cookie: req.headers.cookie } : {}),\n },\n };\n if (req?.body) {\n options.body = JSON.stringify(req.body);\n options.method = \"POST\";\n }\n const res = await fetch(url, options);\n const data = await res.json();\n if (!res.ok)\n throw data;\n return data;\n }\n catch (error) {\n logger.error(new ClientFetchError(error.message, error));\n return null;\n }\n}\n/** @internal */\nexport function apiBaseUrl(__NEXTAUTH) {\n if (typeof window === \"undefined\") {\n // Return absolute path when called server side\n return `${__NEXTAUTH.baseUrlServer}${__NEXTAUTH.basePathServer}`;\n }\n // Return relative path when called client side\n return __NEXTAUTH.basePath;\n}\n/** @internal */\nexport function useOnline() {\n const [isOnline, setIsOnline] = React.useState(typeof navigator !== \"undefined\" ? navigator.onLine : false);\n const setOnline = () => setIsOnline(true);\n const setOffline = () => setIsOnline(false);\n React.useEffect(() => {\n window.addEventListener(\"online\", setOnline);\n window.addEventListener(\"offline\", setOffline);\n return () => {\n window.removeEventListener(\"online\", setOnline);\n window.removeEventListener(\"offline\", setOffline);\n };\n }, []);\n return isOnline;\n}\n/**\n * Returns the number of seconds elapsed since January 1, 1970 00:00:00 UTC.\n * @internal\n */\nexport function now() {\n return Math.floor(Date.now() / 1000);\n}\n/**\n * Returns an `URL` like object to make requests/redirects from server-side\n * @internal\n */\nexport function parseUrl(url) {\n const defaultUrl = new URL(\"http://localhost:3000/api/auth\");\n if (url && !url.startsWith(\"http\")) {\n url = `https://${url}`;\n }\n const _url = new URL(url || defaultUrl);\n const path = (_url.pathname === \"/\" ? defaultUrl.pathname : _url.pathname)\n // Remove trailing slash\n .replace(/\\/$/, \"\");\n const base = `${_url.origin}${path}`;\n return {\n origin: _url.origin,\n host: _url.host,\n path,\n base,\n toString: () => base,\n };\n}\n"],"names":[],"mappings":";;;;;;;;;;;;;;AACA;AACA;AAFA;;;AAGA,UAAU,GACV,MAAM,yBAAyB,iMAAS;AACxC;AAEO,MAAM,2BAA2B,iMAAS;AACjD;AAUO,eAAe,UAAU,IAAI,EAAE,UAAU,EAAE,MAAM,EAAE,MAAM,CAAC,CAAC;IAC9D,MAAM,MAAM,GAAG,WAAW,YAAY,CAAC,EAAE,MAAM;IAC/C,IAAI;QACA,MAAM,UAAU;YACZ,SAAS;gBACL,gBAAgB;gBAChB,GAAI,KAAK,SAAS,SAAS;oBAAE,QAAQ,IAAI,OAAO,CAAC,MAAM;gBAAC,IAAI,CAAC,CAAC;YAClE;QACJ;QACA,IAAI,KAAK,MAAM;YACX,QAAQ,IAAI,GAAG,KAAK,SAAS,CAAC,IAAI,IAAI;YACtC,QAAQ,MAAM,GAAG;QACrB;QACA,MAAM,MAAM,MAAM,MAAM,KAAK;QAC7B,MAAM,OAAO,MAAM,IAAI,IAAI;QAC3B,IAAI,CAAC,IAAI,EAAE,EACP,MAAM;QACV,OAAO;IACX,EACA,OAAO,OAAO;QACV,OAAO,KAAK,CAAC,IAAI,iBAAiB,MAAM,OAAO,EAAE;QACjD,OAAO;IACX;AACJ;AAEO,SAAS,WAAW,UAAU;IACjC,wCAAmC;QAC/B,+CAA+C;QAC/C,OAAO,GAAG,WAAW,aAAa,GAAG,WAAW,cAAc,EAAE;IACpE;;;AAGJ;AAEO,SAAS;IACZ,MAAM,CAAC,UAAU,YAAY,GAAG,6PAAc,CAAC,OAAO,cAAc,cAAc,UAAU,MAAM,GAAG;IACrG,MAAM,YAAY,IAAM,YAAY;IACpC,MAAM,aAAa,IAAM,YAAY;IACrC,8PAAe,CAAC;QACZ,OAAO,gBAAgB,CAAC,UAAU;QAClC,OAAO,gBAAgB,CAAC,WAAW;QACnC,OAAO;YACH,OAAO,mBAAmB,CAAC,UAAU;YACrC,OAAO,mBAAmB,CAAC,WAAW;QAC1C;IACJ,GAAG,EAAE;IACL,OAAO;AACX;AAKO,SAAS;IACZ,OAAO,KAAK,KAAK,CAAC,KAAK,GAAG,KAAK;AACnC;AAKO,SAAS,SAAS,GAAG;IACxB,MAAM,aAAa,IAAI,IAAI;IAC3B,IAAI,OAAO,CAAC,IAAI,UAAU,CAAC,SAAS;QAChC,MAAM,CAAC,QAAQ,EAAE,KAAK;IAC1B;IACA,MAAM,OAAO,IAAI,IAAI,OAAO;IAC5B,MAAM,OAAO,CAAC,KAAK,QAAQ,KAAK,MAAM,WAAW,QAAQ,GAAG,KAAK,QAAQ,CACrE,wBAAwB;KACvB,OAAO,CAAC,OAAO;IACpB,MAAM,OAAO,GAAG,KAAK,MAAM,GAAG,MAAM;IACpC,OAAO;QACH,QAAQ,KAAK,MAAM;QACnB,MAAM,KAAK,IAAI;QACf;QACA;QACA,UAAU,IAAM;IACpB;AACJ","ignoreList":[0]}}, - {"offset": {"line": 738, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/node_modules/next-auth/react.js"],"sourcesContent":["/**\n *\n * NextAuth.js is the official integration of Auth.js for Next.js applications. It supports both\n * [Client Components](https://nextjs.org/docs/app/building-your-application/rendering/client-components) and the\n * [Pages Router](https://nextjs.org/docs/pages). It includes methods for signing in, signing out, hooks, and a React\n * Context provider to wrap your application and make session data available anywhere.\n *\n * For use in [Server Actions](https://nextjs.org/docs/app/api-reference/functions/server-actions), check out [these methods](https://authjs.dev/guides/upgrade-to-v5#methods)\n *\n * @module react\n */\n\"use client\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport * as React from \"react\";\nimport { apiBaseUrl, ClientSessionError, fetchData, now, parseUrl, useOnline, } from \"./lib/client.js\";\n// This behaviour mirrors the default behaviour for getting the site name that\n// happens server side in server/index.js\n// 1. An empty value is legitimate when the code is being invoked client side as\n// relative URLs are valid in that context and so defaults to empty.\n// 2. When invoked server side the value is picked up from an environment\n// variable and defaults to 'http://localhost:3000'.\nexport const __NEXTAUTH = {\n baseUrl: parseUrl(process.env.NEXTAUTH_URL ?? process.env.VERCEL_URL).origin,\n basePath: parseUrl(process.env.NEXTAUTH_URL).path,\n baseUrlServer: parseUrl(process.env.NEXTAUTH_URL_INTERNAL ??\n process.env.NEXTAUTH_URL ??\n process.env.VERCEL_URL).origin,\n basePathServer: parseUrl(process.env.NEXTAUTH_URL_INTERNAL ?? process.env.NEXTAUTH_URL).path,\n _lastSync: 0,\n _session: undefined,\n _getSession: () => { },\n};\n// https://github.com/nextauthjs/next-auth/pull/10762\nlet broadcastChannel = null;\nfunction getNewBroadcastChannel() {\n if (typeof BroadcastChannel === \"undefined\") {\n return {\n postMessage: () => { },\n addEventListener: () => { },\n removeEventListener: () => { },\n name: \"next-auth\",\n onmessage: null,\n onmessageerror: null,\n close: () => { },\n dispatchEvent: () => false,\n };\n }\n return new BroadcastChannel(\"next-auth\");\n}\nfunction broadcast() {\n if (broadcastChannel === null) {\n broadcastChannel = getNewBroadcastChannel();\n }\n return broadcastChannel;\n}\n// TODO:\nconst logger = {\n debug: console.debug,\n error: console.error,\n warn: console.warn,\n};\nexport const SessionContext = React.createContext?.(undefined);\n/**\n * React Hook that gives you access to the logged in user's session data and lets you modify it.\n *\n * :::info\n * `useSession` is for client-side use only and when using [Next.js App Router (`app/`)](https://nextjs.org/blog/next-13-4#nextjs-app-router) you should prefer the `auth()` export.\n * :::\n */\nexport function useSession(options) {\n if (!SessionContext) {\n throw new Error(\"React Context is unavailable in Server Components\");\n }\n // @ts-expect-error Satisfy TS if branch on line below\n const value = React.useContext(SessionContext);\n if (!value && process.env.NODE_ENV !== \"production\") {\n throw new Error(\"[next-auth]: `useSession` must be wrapped in a \");\n }\n const { required, onUnauthenticated } = options ?? {};\n const requiredAndNotLoading = required && value.status === \"unauthenticated\";\n React.useEffect(() => {\n if (requiredAndNotLoading) {\n const url = `${__NEXTAUTH.basePath}/signin?${new URLSearchParams({\n error: \"SessionRequired\",\n callbackUrl: window.location.href,\n })}`;\n if (onUnauthenticated)\n onUnauthenticated();\n else\n window.location.href = url;\n }\n }, [requiredAndNotLoading, onUnauthenticated]);\n if (requiredAndNotLoading) {\n return {\n data: value.data,\n update: value.update,\n status: \"loading\",\n };\n }\n return value;\n}\nexport async function getSession(params) {\n const session = await fetchData(\"session\", __NEXTAUTH, logger, params);\n if (params?.broadcast ?? true) {\n // https://github.com/nextauthjs/next-auth/pull/11470\n getNewBroadcastChannel().postMessage({\n event: \"session\",\n data: { trigger: \"getSession\" },\n });\n }\n return session;\n}\n/**\n * Returns the current Cross-Site Request Forgery Token (CSRF Token)\n * required to make requests that changes state. (e.g. signing in or out, or updating the session).\n *\n * [CSRF Prevention: Double Submit Cookie](https://cheatsheetseries.owasp.org/cheatsheets/Cross-Site_Request_Forgery_Prevention_Cheat_Sheet.html#double-submit-cookie)\n */\nexport async function getCsrfToken() {\n const response = await fetchData(\"csrf\", __NEXTAUTH, logger);\n return response?.csrfToken ?? \"\";\n}\nexport async function getProviders() {\n return fetchData(\"providers\", __NEXTAUTH, logger);\n}\nexport async function signIn(provider, options, authorizationParams) {\n const { callbackUrl, ...rest } = options ?? {};\n const { redirect = true, redirectTo = callbackUrl ?? window.location.href, ...signInParams } = rest;\n const baseUrl = apiBaseUrl(__NEXTAUTH);\n const providers = await getProviders();\n if (!providers) {\n const url = `${baseUrl}/error`;\n window.location.href = url;\n return; // TODO: Return error if `redirect: false`\n }\n if (!provider || !providers[provider]) {\n const url = `${baseUrl}/signin?${new URLSearchParams({\n callbackUrl: redirectTo,\n })}`;\n window.location.href = url;\n return; // TODO: Return error if `redirect: false`\n }\n const providerType = providers[provider].type;\n if (providerType === \"webauthn\") {\n // TODO: Add docs link with explanation\n throw new TypeError([\n `Provider id \"${provider}\" refers to a WebAuthn provider.`,\n 'Please use `import { signIn } from \"next-auth/webauthn\"` instead.',\n ].join(\"\\n\"));\n }\n const signInUrl = `${baseUrl}/${providerType === \"credentials\" ? \"callback\" : \"signin\"}/${provider}`;\n const csrfToken = await getCsrfToken();\n const res = await fetch(`${signInUrl}?${new URLSearchParams(authorizationParams)}`, {\n method: \"post\",\n headers: {\n \"Content-Type\": \"application/x-www-form-urlencoded\",\n \"X-Auth-Return-Redirect\": \"1\",\n },\n body: new URLSearchParams({\n ...signInParams,\n csrfToken,\n callbackUrl: redirectTo,\n }),\n });\n const data = await res.json();\n if (redirect) {\n const url = data.url ?? redirectTo;\n window.location.href = url;\n // If url contains a hash, the browser does not reload the page. We reload manually\n if (url.includes(\"#\"))\n window.location.reload();\n return;\n }\n const error = new URL(data.url).searchParams.get(\"error\") ?? undefined;\n const code = new URL(data.url).searchParams.get(\"code\") ?? undefined;\n if (res.ok) {\n await __NEXTAUTH._getSession({ event: \"storage\" });\n }\n return {\n error,\n code,\n status: res.status,\n ok: res.ok,\n url: error ? null : data.url,\n };\n}\nexport async function signOut(options) {\n const { redirect = true, redirectTo = options?.callbackUrl ?? window.location.href, } = options ?? {};\n const baseUrl = apiBaseUrl(__NEXTAUTH);\n const csrfToken = await getCsrfToken();\n const res = await fetch(`${baseUrl}/signout`, {\n method: \"post\",\n headers: {\n \"Content-Type\": \"application/x-www-form-urlencoded\",\n \"X-Auth-Return-Redirect\": \"1\",\n },\n body: new URLSearchParams({ csrfToken, callbackUrl: redirectTo }),\n });\n const data = await res.json();\n broadcast().postMessage({ event: \"session\", data: { trigger: \"signout\" } });\n if (redirect) {\n const url = data.url ?? redirectTo;\n window.location.href = url;\n // If url contains a hash, the browser does not reload the page. We reload manually\n if (url.includes(\"#\"))\n window.location.reload();\n return;\n }\n await __NEXTAUTH._getSession({ event: \"storage\" });\n return data;\n}\n/**\n * [React Context](https://react.dev/learn/passing-data-deeply-with-context) provider to wrap the app (`pages/`) to make session data available anywhere.\n *\n * When used, the session state is automatically synchronized across all open tabs/windows and they are all updated whenever they gain or lose focus\n * or the state changes (e.g. a user signs in or out) when {@link SessionProviderProps.refetchOnWindowFocus} is `true`.\n *\n * :::info\n * `SessionProvider` is for client-side use only and when using [Next.js App Router (`app/`)](https://nextjs.org/blog/next-13-4#nextjs-app-router) you should prefer the `auth()` export.\n * :::\n */\nexport function SessionProvider(props) {\n if (!SessionContext) {\n throw new Error(\"React Context is unavailable in Server Components\");\n }\n const { children, basePath, refetchInterval, refetchWhenOffline } = props;\n if (basePath)\n __NEXTAUTH.basePath = basePath;\n /**\n * If session was `null`, there was an attempt to fetch it,\n * but it failed, but we still treat it as a valid initial value.\n */\n const hasInitialSession = props.session !== undefined;\n /** If session was passed, initialize as already synced */\n __NEXTAUTH._lastSync = hasInitialSession ? now() : 0;\n const [session, setSession] = React.useState(() => {\n if (hasInitialSession)\n __NEXTAUTH._session = props.session;\n return props.session;\n });\n /** If session was passed, initialize as not loading */\n const [loading, setLoading] = React.useState(!hasInitialSession);\n React.useEffect(() => {\n __NEXTAUTH._getSession = async ({ event } = {}) => {\n try {\n const storageEvent = event === \"storage\";\n // We should always update if we don't have a client session yet\n // or if there are events from other tabs/windows\n if (storageEvent || __NEXTAUTH._session === undefined) {\n __NEXTAUTH._lastSync = now();\n __NEXTAUTH._session = await getSession({\n broadcast: !storageEvent,\n });\n setSession(__NEXTAUTH._session);\n return;\n }\n if (\n // If there is no time defined for when a session should be considered\n // stale, then it's okay to use the value we have until an event is\n // triggered which updates it\n !event ||\n // If the client doesn't have a session then we don't need to call\n // the server to check if it does (if they have signed in via another\n // tab or window that will come through as a \"stroage\" event\n // event anyway)\n __NEXTAUTH._session === null ||\n // Bail out early if the client session is not stale yet\n now() < __NEXTAUTH._lastSync) {\n return;\n }\n // An event or session staleness occurred, update the client session.\n __NEXTAUTH._lastSync = now();\n __NEXTAUTH._session = await getSession();\n setSession(__NEXTAUTH._session);\n }\n catch (error) {\n logger.error(new ClientSessionError(error.message, error));\n }\n finally {\n setLoading(false);\n }\n };\n __NEXTAUTH._getSession();\n return () => {\n __NEXTAUTH._lastSync = 0;\n __NEXTAUTH._session = undefined;\n __NEXTAUTH._getSession = () => { };\n };\n }, []);\n React.useEffect(() => {\n const handle = () => __NEXTAUTH._getSession({ event: \"storage\" });\n // Listen for storage events and update session if event fired from\n // another window (but suppress firing another event to avoid a loop)\n // Fetch new session data but tell it to not to fire another event to\n // avoid an infinite loop.\n // Note: We could pass session data through and do something like\n // `setData(message.data)` but that can cause problems depending\n // on how the session object is being used in the client; it is\n // more robust to have each window/tab fetch it's own copy of the\n // session object rather than share it across instances.\n broadcast().addEventListener(\"message\", handle);\n return () => broadcast().removeEventListener(\"message\", handle);\n }, []);\n React.useEffect(() => {\n const { refetchOnWindowFocus = true } = props;\n // Listen for when the page is visible, if the user switches tabs\n // and makes our tab visible again, re-fetch the session, but only if\n // this feature is not disabled.\n const visibilityHandler = () => {\n if (refetchOnWindowFocus && document.visibilityState === \"visible\")\n __NEXTAUTH._getSession({ event: \"visibilitychange\" });\n };\n document.addEventListener(\"visibilitychange\", visibilityHandler, false);\n return () => document.removeEventListener(\"visibilitychange\", visibilityHandler, false);\n }, [props.refetchOnWindowFocus]);\n const isOnline = useOnline();\n // TODO: Flip this behavior in next major version\n const shouldRefetch = refetchWhenOffline !== false || isOnline;\n React.useEffect(() => {\n if (refetchInterval && shouldRefetch) {\n const refetchIntervalTimer = setInterval(() => {\n if (__NEXTAUTH._session) {\n __NEXTAUTH._getSession({ event: \"poll\" });\n }\n }, refetchInterval * 1000);\n return () => clearInterval(refetchIntervalTimer);\n }\n }, [refetchInterval, shouldRefetch]);\n const value = React.useMemo(() => ({\n data: session,\n status: loading\n ? \"loading\"\n : session\n ? \"authenticated\"\n : \"unauthenticated\",\n async update(data) {\n if (loading)\n return;\n setLoading(true);\n const newSession = await fetchData(\"session\", __NEXTAUTH, logger, typeof data === \"undefined\"\n ? undefined\n : { body: { csrfToken: await getCsrfToken(), data } });\n setLoading(false);\n if (newSession) {\n setSession(newSession);\n broadcast().postMessage({\n event: \"session\",\n data: { trigger: \"getSession\" },\n });\n }\n return newSession;\n },\n }), [session, loading]);\n return (\n // @ts-expect-error\n _jsx(SessionContext.Provider, { value: value, children: children }));\n}\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;AAYA;AACA;AACA;AAdA;;;;;;;;;;CAUC,GACD;;;;AAUO,MAAM,aAAa;IACtB,SAAS,IAAA,qMAAQ,EAAC,QAAQ,GAAG,CAAC,YAAY,IAAI,QAAQ,GAAG,CAAC,UAAU,EAAE,MAAM;IAC5E,UAAU,IAAA,qMAAQ,EAAC,QAAQ,GAAG,CAAC,YAAY,EAAE,IAAI;IACjD,eAAe,IAAA,qMAAQ,EAAC,QAAQ,GAAG,CAAC,qBAAqB,IACrD,QAAQ,GAAG,CAAC,YAAY,IACxB,QAAQ,GAAG,CAAC,UAAU,EAAE,MAAM;IAClC,gBAAgB,IAAA,qMAAQ,EAAC,QAAQ,GAAG,CAAC,qBAAqB,IAAI,QAAQ,GAAG,CAAC,YAAY,EAAE,IAAI;IAC5F,WAAW;IACX,UAAU;IACV,aAAa,KAAQ;AACzB;AACA,qDAAqD;AACrD,IAAI,mBAAmB;AACvB,SAAS;IACL,IAAI,OAAO,qBAAqB,aAAa;QACzC,OAAO;YACH,aAAa,KAAQ;YACrB,kBAAkB,KAAQ;YAC1B,qBAAqB,KAAQ;YAC7B,MAAM;YACN,WAAW;YACX,gBAAgB;YAChB,OAAO,KAAQ;YACf,eAAe,IAAM;QACzB;IACJ;IACA,OAAO,IAAI,iBAAiB;AAChC;AACA,SAAS;IACL,IAAI,qBAAqB,MAAM;QAC3B,mBAAmB;IACvB;IACA,OAAO;AACX;AACA,QAAQ;AACR,MAAM,SAAS;IACX,OAAO,QAAQ,KAAK;IACpB,OAAO,QAAQ,KAAK;IACpB,MAAM,QAAQ,IAAI;AACtB;AACO,MAAM,iBAAiB,kQAAmB,GAAG;AAQ7C,SAAS,WAAW,OAAO;IAC9B,IAAI,CAAC,gBAAgB;QACjB,MAAM,IAAI,MAAM;IACpB;IACA,sDAAsD;IACtD,MAAM,QAAQ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oBACZ,WAAW;oBACX,YAAY,WAAW,CAAC;wBACpB,OAAO;wBACP,MAAM;4BAAE,SAAS;wBAAa;oBAClC;gBACJ;gBACA,OAAO;YACX;QACJ,CAAC,GAAG;QAAC;QAAS;KAAQ;IACtB,OACA,mBAAmB;IACnB,IAAA,0QAAI,EAAC,eAAe,QAAQ,EAAE;QAAE,OAAO;QAAO,UAAU;IAAS;AACrE","ignoreList":[0]}}] + {"offset": {"line": 10, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/src/lib/api.ts"],"sourcesContent":["import { BookProject, UserProfile } from './types';\r\n\r\nconst API_BASE_URL = '/api';\r\n\r\n// --- API CLIENT ---\r\n\r\nconst api = {\r\n async request(endpoint: string, options: RequestInit = {}) {\r\n const url = `${API_BASE_URL}${endpoint}`;\r\n\r\n const headers: Record = {\r\n 'Content-Type': 'application/json',\r\n ...options.headers as Record,\r\n };\r\n\r\n const response = await fetch(url, {\r\n ...options,\r\n headers,\r\n });\r\n\r\n if (!response.ok) {\r\n let errorMsg = `Error ${response.status}: ${response.statusText}`;\r\n try {\r\n const errorJson = await response.json();\r\n if (errorJson.error) errorMsg = errorJson.error;\r\n if (errorJson.message) errorMsg = errorJson.message;\r\n } catch {\r\n // Ignore json parse error\r\n }\r\n throw new Error(errorMsg);\r\n }\r\n\r\n if (response.status === 204) return null;\r\n return response.json();\r\n },\r\n\r\n // --- AUTH ---\r\n auth: {\r\n async register(email: string, password: string, name: string) {\r\n return api.request('/auth/register', {\r\n method: 'POST',\r\n body: JSON.stringify({ email, password, name }),\r\n });\r\n },\r\n },\r\n\r\n // --- USER ---\r\n user: {\r\n async updateProfile(data: any) {\r\n return api.request('/user/profile', {\r\n method: 'PUT',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n },\r\n\r\n // --- PROJECTS ---\r\n projects: {\r\n async list() {\r\n return api.request('/projects');\r\n },\r\n\r\n async get(id: string) {\r\n return api.request(`/projects/${id}`);\r\n },\r\n\r\n async create(data: { title: string; author: string; settings?: any }) {\r\n return api.request('/projects', {\r\n method: 'POST',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async update(id: string, data: any) {\r\n return api.request(`/projects/${id}`, {\r\n method: 'PUT',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async delete(id: string) {\r\n return api.request(`/projects/${id}`, {\r\n method: 'DELETE',\r\n });\r\n },\r\n\r\n async syncWorkflow(id: string, data: { nodes: any[]; connections: any[] }) {\r\n return api.request(`/projects/${id}/workflow`, {\r\n method: 'PUT',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n },\r\n\r\n // --- CHAPTERS ---\r\n chapters: {\r\n async create(data: { projectId: string; title?: string; content?: string; summary?: string; orderIndex?: number }) {\r\n return api.request('/chapters', {\r\n method: 'POST',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async update(id: string, data: any) {\r\n return api.request(`/chapters/${id}`, {\r\n method: 'PUT',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async delete(id: string) {\r\n return api.request(`/chapters/${id}`, {\r\n method: 'DELETE',\r\n });\r\n },\r\n },\r\n\r\n // --- ENTITIES ---\r\n entities: {\r\n async create(data: { projectId: string; type: string; name?: string; description?: string; details?: string; attributes?: any; customValues?: any }) {\r\n return api.request('/entities', {\r\n method: 'POST',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async update(id: string, data: any) {\r\n return api.request(`/entities/${id}`, {\r\n method: 'PUT',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async delete(id: string) {\r\n return api.request(`/entities/${id}`, {\r\n method: 'DELETE',\r\n });\r\n },\r\n },\r\n\r\n // --- IDEAS ---\r\n ideas: {\r\n async create(data: { projectId: string; title?: string; description?: string; status?: string; category?: string }) {\r\n return api.request('/ideas', {\r\n method: 'POST',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async update(id: string, data: any) {\r\n return api.request(`/ideas/${id}`, {\r\n method: 'PUT',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async delete(id: string) {\r\n return api.request(`/ideas/${id}`, {\r\n method: 'DELETE',\r\n });\r\n },\r\n },\r\n\r\n // --- AI (server-side via API routes) ---\r\n ai: {\r\n async generate(project: BookProject, chapterId: string, prompt: string, user: UserProfile) {\r\n return api.request<{ text: string; type: 'draft' | 'reflection' }>('/ai/generate', {\r\n method: 'POST',\r\n body: JSON.stringify({ project, chapterId, prompt, user }),\r\n });\r\n },\r\n\r\n async transform(text: string, mode: string, context: string, user: UserProfile) {\r\n const res = await api.request<{ text: string }>('/ai/transform', {\r\n method: 'POST',\r\n body: JSON.stringify({ text, mode, context, user }),\r\n });\r\n return res.text;\r\n },\r\n },\r\n};\r\n\r\nexport default api;\r\n"],"names":[],"mappings":";;;;AAEA,MAAM,eAAe;AAErB,qBAAqB;AAErB,MAAM,MAAM;IACR,MAAM,SAAiB,QAAgB,EAAE,UAAuB,CAAC,CAAC;QAC9D,MAAM,MAAM,GAAG,eAAe,UAAU;QAExC,MAAM,UAAkC;YACpC,gBAAgB;YAChB,GAAG,QAAQ,OAAO;QACtB;QAEA,MAAM,WAAW,MAAM,MAAM,KAAK;YAC9B,GAAG,OAAO;YACV;QACJ;QAEA,IAAI,CAAC,SAAS,EAAE,EAAE;YACd,IAAI,WAAW,CAAC,MAAM,EAAE,SAAS,MAAM,CAAC,EAAE,EAAE,SAAS,UAAU,EAAE;YACjE,IAAI;gBACA,MAAM,YAAY,MAAM,SAAS,IAAI;gBACrC,IAAI,UAAU,KAAK,EAAE,WAAW,UAAU,KAAK;gBAC/C,IAAI,UAAU,OAAO,EAAE,WAAW,UAAU,OAAO;YACvD,EAAE,OAAM;YACJ,0BAA0B;YAC9B;YACA,MAAM,IAAI,MAAM;QACpB;QAEA,IAAI,SAAS,MAAM,KAAK,KAAK,OAAO;QACpC,OAAO,SAAS,IAAI;IACxB;IAEA,eAAe;IACf,MAAM;QACF,MAAM,UAAS,KAA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;oBAAQ;gBAAK;YAC5D;QACJ;QAEA,MAAM,WAAU,IAAY,EAAE,IAAY,EAAE,OAAe,EAAE,IAAiB;YAC1E,MAAM,MAAM,MAAM,IAAI,OAAO,CAAmB,iBAAiB;gBAC7D,QAAQ;gBACR,MAAM,KAAK,SAAS,CAAC;oBAAE;oBAAM;oBAAM;oBAAS;gBAAK;YACrD;YACA,OAAO,IAAI,IAAI;QACnB;IACJ;AACJ;uCAEe"}}, + {"offset": {"line": 187, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/src/hooks/useAuth.ts"],"sourcesContent":["'use client';\r\n\r\nimport { useState, useEffect, useCallback } from 'react';\r\nimport { signIn, signOut, useSession } from 'next-auth/react';\r\nimport { UserProfile } from '@/lib/types';\r\nimport api from '@/lib/api';\r\n\r\nexport const useAuth = () => {\r\n const { data: session, status } = useSession();\r\n const [user, setUser] = useState(null);\r\n const loading = status === 'loading';\r\n\r\n // Fetch real profile from DB when session is available\r\n useEffect(() => {\r\n if (session?.user?.id) {\r\n fetch('/api/user/profile', { cache: 'no-store' })\r\n .then(res => res.json())\r\n .then(dbUser => {\r\n const planId = dbUser.plan || 'free';\r\n const planDetails = dbUser.planDetails || {\r\n id: 'free',\r\n displayName: 'Gratuit',\r\n maxAiActions: 100,\r\n maxProjects: 3\r\n };\r\n\r\n setUser({\r\n id: dbUser.id,\r\n email: dbUser.email,\r\n name: dbUser.name || 'User',\r\n avatar: dbUser.avatar,\r\n bio: dbUser.bio,\r\n subscription: {\r\n plan: planId,\r\n planDetails: planDetails,\r\n startDate: new Date(dbUser.createdAt).getTime(),\r\n status: 'active'\r\n },\r\n usage: {\r\n aiActionsCurrent: dbUser.aiActionsUsed || 0,\r\n aiActionsLimit: planDetails.maxAiActions,\r\n projectsLimit: planDetails.maxProjects,\r\n },\r\n preferences: { theme: 'light', dailyWordGoal: dbUser.dailyWordGoal || 500, language: 'fr' },\r\n stats: {\r\n totalWordsWritten: dbUser.totalWords || 0,\r\n writingStreak: dbUser.writingStreak || 0,\r\n lastWriteDate: dbUser.lastWriteDate ? new Date(dbUser.lastWriteDate).getTime() : 0,\r\n },\r\n });\r\n })\r\n .catch(err => {\r\n console.error('Failed to fetch user profile:', err);\r\n // Fallback to session data\r\n setUser({\r\n id: session.user.id || '',\r\n email: session.user.email || '',\r\n name: session.user.name || 'User',\r\n subscription: { plan: 'free', startDate: Date.now(), status: 'active' },\r\n usage: { aiActionsCurrent: 0, aiActionsLimit: 100, projectsLimit: 3 },\r\n preferences: { theme: 'light', dailyWordGoal: 500, language: 'fr' },\r\n stats: { totalWordsWritten: 0, writingStreak: 0, lastWriteDate: 0 },\r\n });\r\n });\r\n } else if (status === 'unauthenticated') {\r\n setUser(null);\r\n }\r\n }, [session, status]);\r\n\r\n const login = useCallback(async (email: string, password: string) => {\r\n const result = await signIn('credentials', {\r\n email,\r\n password,\r\n redirect: false,\r\n });\r\n\r\n if (result?.error) {\r\n throw new Error(result.error === 'CredentialsSignin'\r\n ? 'Email ou mot de passe incorrect'\r\n : result.error\r\n );\r\n }\r\n }, []);\r\n\r\n const signup = useCallback(async (email: string, password: string, name: string) => {\r\n await api.auth.register(email, password, name);\r\n const result = await signIn('credentials', {\r\n email,\r\n password,\r\n redirect: false,\r\n });\r\n if (result?.error) {\r\n throw new Error('Compte créé mais erreur de connexion automatique');\r\n }\r\n }, []);\r\n\r\n const logout = useCallback(async () => {\r\n await signOut({ redirect: false });\r\n setUser(null);\r\n }, []);\r\n\r\n const incrementUsage = useCallback((serverCount?: number) => {\r\n if (user) {\r\n setUser({\r\n ...user,\r\n usage: {\r\n ...user.usage,\r\n aiActionsCurrent: serverCount !== undefined ? serverCount : user.usage.aiActionsCurrent + 1,\r\n },\r\n });\r\n }\r\n }, [user]);\r\n\r\n const updateProfile = useCallback(async (updates: Partial) => {\r\n if (!user) return;\r\n\r\n try {\r\n // Unpack everything that can be updated into a flat object for the API\r\n const apiUpdates: any = {};\r\n if (updates.name !== undefined) apiUpdates.name = updates.name;\r\n if (updates.avatar !== undefined) apiUpdates.avatar = updates.avatar;\r\n if (updates.bio !== undefined) apiUpdates.bio = updates.bio;\r\n if (updates.preferences?.dailyWordGoal !== undefined) apiUpdates.dailyWordGoal = updates.preferences.dailyWordGoal;\r\n\r\n // Make the API call to update DB\r\n await api.user.updateProfile(apiUpdates);\r\n\r\n // Update local state\r\n setUser(prev => prev ? { ...prev, ...updates } : null);\r\n } catch (err) {\r\n console.error('Failed to update profile:', err);\r\n throw err;\r\n }\r\n }, [user]);\r\n\r\n return { user, login, signup, logout, incrementUsage, updateProfile, loading };\r\n};\r\n"],"names":[],"mappings":";;;;AAEA;AACA;AAEA;AALA;;;;AAOO,MAAM,UAAU;IACnB,MAAM,EAAE,MAAM,OAAO,EAAE,MAAM,EAAE,GAAG,IAAA,+LAAU;IAC5C,MAAM,CAAC,MAAM,QAAQ,GAAG,IAAA,6PAAQ,EAAqB;IACrD,MAAM,UAAU,WAAW;IAE3B,uDAAuD;IACvD,IAAA,8PAAS,EAAC;QACN,IAAI,SAAS,MAAM,IAAI;YACnB,MAAM,qBAAqB;gBAAE,OAAO;YAAW,GAC1C,IAAI,CAAC,CAAA,MAAO,IAAI,IAAI,IACpB,IAAI,CAAC,CAAA;gBACF,MAAM,SAAS,OAAO,IAAI,IAAI;gBAC9B,MAAM,cAAc,OAAO,WAAW,IAAI;oBACtC,IAAI;oBACJ,aAAa;oBACb,cAAc;oBACd,aAAa;gBACjB;gBAEA,QAAQ;oBACJ,IAAI,OAAO,EAAE;oBACb,OAAO,OAAO,KAAK;oBACnB,MAAM,OAAO,IAAI,IAAI;oBACrB,QAAQ,OAAO,MAAM;oBACrB,KAAK,OAAO,GAAG;oBACf,cAAc;wBACV,MAAM;wBACN,aAAa;wBACb,WAAW,IAAI,KAAK,OAAO,SAAS,EAAE,OAAO;wBAC7C,QAAQ;oBACZ;oBACA,OAAO;wBACH,kBAAkB,OAAO,aAAa,IAAI;wBAC1C,gBAAgB,Y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QAAQ;QAAgB;QAAe;IAAQ;AACjF"}}, + {"offset": {"line": 356, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/src/providers/AuthProvider.tsx"],"sourcesContent":["'use client';\r\n\r\nimport React, { createContext, useContext } from 'react';\r\nimport { SessionProvider } from 'next-auth/react';\r\nimport { useAuth } from '@/hooks/useAuth';\r\n\r\nconst AuthContext = createContext(null);\r\n\r\nfunction AuthInner({ children }: { children: React.ReactNode }) {\r\n const auth = useAuth();\r\n return {children};\r\n}\r\n\r\nexport const AuthProvider: React.FC<{ children: React.ReactNode }> = ({ children }) => {\r\n return (\r\n \r\n {children}\r\n \r\n );\r\n};\r\n\r\nexport function useAuthContext() {\r\n return useContext(AuthContext);\r\n}\r\n"],"names":[],"mappings":";;;;;;;AAEA;AACA;AACA;AAJA;;;;;AAMA,MAAM,4BAAc,IAAA,kQAAa,EAAM;AAEvC,SAAS,UAAU,EAAE,QAAQ,EAAiC;IAC1D,MAAM,OAAO,IAAA,8KAAO;IACpB,qBAAO,0RAAC,YAAY,QAAQ;QAAC,OAAO;kBAAO;;;;;;AAC/C;AAEO,MAAM,eAAwD,CAAC,EAAE,QAAQ,EAAE;IAC9E,qBACI,0RAAC,oMAAe;kBACZ,cAAA,0RAAC;sBAAW;;;;;;;;;;;AAGxB;AAEO,SAAS;IACZ,OAAO,IAAA,+PAAU,EAAC;AACtB"}}, + {"offset": {"line": 405, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/node_modules/next/src/server/route-modules/app-page/module.compiled.js"],"sourcesContent":["if (process.env.NEXT_RUNTIME === 'edge') {\n module.exports = require('next/dist/server/route-modules/app-page/module.js')\n} else {\n if (process.env.__NEXT_EXPERIMENTAL_REACT) {\n if (process.env.NODE_ENV === 'development') {\n if (process.env.TURBOPACK) {\n module.exports = require('next/dist/compiled/next-server/app-page-turbo-experimental.runtime.dev.js')\n } else {\n module.exports = require('next/dist/compiled/next-server/app-page-experimental.runtime.dev.js')\n }\n } else {\n if (process.env.TURBOPACK) {\n module.exports = require('next/dist/compiled/next-server/app-page-turbo-experimental.runtime.prod.js')\n } else {\n module.exports = require('next/dist/compiled/next-server/app-page-experimental.runtime.prod.js')\n }\n }\n } else {\n if (process.env.NODE_ENV === 'development') {\n if (process.env.TURBOPACK) {\n module.exports = require('next/dist/compiled/next-server/app-page-turbo.runtime.dev.js')\n } else {\n module.exports = require('next/dist/compiled/next-server/app-page.runtime.dev.js')\n }\n } else {\n if (process.env.TURBOPACK) {\n module.exports = require('next/dist/compiled/next-server/app-page-turbo.runtime.prod.js')\n } else {\n module.exports = require('next/dist/compiled/next-server/app-page.runtime.prod.js')\n }\n }\n }\n}\n"],"names":["process","env","NEXT_RUNTIME","module","exports","require","__NEXT_EXPERIMENTAL_REACT","NODE_ENV","TURBOPACK"],"mappings":"AAAA,IAAIA,QAAQC,GAAG,CAACC,YAAY,KAAK,QAAQ;;KAElC;IACL,IAAIF,QAAQC,GAAG,CAACK,yBAAyB,EAAE;;SAcpC;QACL,IAAIN,QAAQC,GAAG,CAACM,QAAQ,KAAK,WAAe;YAC1C,IAAIP,QAAQC,GAAG,CAACO,SAAS,eAAE;gBACzBL,OAAOC,OAAO,GAAGC,QAAQ;YAC3B,OAAO;;QAGT,OAAO;;IAOT;AACF","ignoreList":[0]}}, + {"offset": {"line": 424, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/node_modules/next/src/server/route-modules/app-page/vendored/ssr/react-jsx-dev-runtime.ts"],"sourcesContent":["module.exports = (\n require('../../module.compiled') as typeof import('../../module.compiled')\n).vendored['react-ssr']!.ReactJsxDevRuntime\n"],"names":["module","exports","require","vendored","ReactJsxDevRuntime"],"mappings":"AAAAA,OAAOC,OAAO,GACZC,QAAQ,0JACRC,QAAQ,CAAC,YAAY,CAAEC,kBAAkB","ignoreList":[0]}}, + {"offset": {"line": 429, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/node_modules/next/src/server/route-modules/app-page/vendored/ssr/react.ts"],"sourcesContent":["module.exports = (\n require('../../module.compiled') as typeof import('../../module.compiled')\n).vendored['react-ssr']!.React\n"],"names":["module","exports","require","vendored","React"],"mappings":"AAAAA,OAAOC,OAAO,GACZC,QAAQ,0JACRC,QAAQ,CAAC,YAAY,CAAEC,KAAK","ignoreList":[0]}}, + {"offset": {"line": 434, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/node_modules/next/src/server/route-modules/app-page/vendored/ssr/react-jsx-runtime.ts"],"sourcesContent":["module.exports = (\n require('../../module.compiled') as typeof import('../../module.compiled')\n).vendored['react-ssr']!.ReactJsxRuntime\n"],"names":["module","exports","require","vendored","ReactJsxRuntime"],"mappings":"AAAAA,OAAOC,OAAO,GACZC,QAAQ,0JACRC,QAAQ,CAAC,YAAY,CAAEC,eAAe","ignoreList":[0]}}, + {"offset": {"line": 439, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/node_modules/%40auth/core/errors.js"],"sourcesContent":["/**\n * Base error class for all Auth.js errors.\n * It's optimized to be printed in the server logs in a nicely formatted way\n * via the [`logger.error`](https://authjs.dev/reference/core#logger) option.\n * @noInheritDoc\n */\nexport class AuthError extends Error {\n /** @internal */\n constructor(message, errorOptions) {\n if (message instanceof Error) {\n super(undefined, {\n cause: { err: message, ...message.cause, ...errorOptions },\n });\n }\n else if (typeof message === \"string\") {\n if (errorOptions instanceof Error) {\n errorOptions = { err: errorOptions, ...errorOptions.cause };\n }\n super(message, errorOptions);\n }\n else {\n super(undefined, message);\n }\n this.name = this.constructor.name;\n // @ts-expect-error https://github.com/microsoft/TypeScript/issues/3841\n this.type = this.constructor.type ?? \"AuthError\";\n // @ts-expect-error https://github.com/microsoft/TypeScript/issues/3841\n this.kind = this.constructor.kind ?? \"error\";\n Error.captureStackTrace?.(this, this.constructor);\n const url = `https://errors.authjs.dev#${this.type.toLowerCase()}`;\n this.message += `${this.message ? \". \" : \"\"}Read more at ${url}`;\n }\n}\n/**\n * Thrown when the user's sign-in attempt failed.\n * @noInheritDoc\n */\nexport class SignInError extends AuthError {\n}\n/** @internal */\nSignInError.kind = \"signIn\";\n/**\n * One of the database [`Adapter` methods](https://authjs.dev/reference/core/adapters#methods)\n * failed during execution.\n *\n * :::tip\n * If `debug: true` is set, you can check out `[auth][debug]` in the logs to learn more about the failed adapter method execution.\n * @example\n * ```sh\n * [auth][debug]: adapter_getUserByEmail\n * { \"args\": [undefined] }\n * ```\n * :::\n * @noInheritDoc\n */\nexport class AdapterError extends AuthError {\n}\nAdapterError.type = \"AdapterError\";\n/**\n * Thrown when the execution of the [`signIn` callback](https://authjs.dev/reference/core/types#signin) fails\n * or if it returns `false`.\n * @noInheritDoc\n */\nexport class AccessDenied extends AuthError {\n}\nAccessDenied.type = \"AccessDenied\";\n/**\n * This error occurs when the user cannot finish login.\n * Depending on the provider type, this could have happened for multiple reasons.\n *\n * :::tip\n * Check out `[auth][details]` in the logs to know which provider failed.\n * @example\n * ```sh\n * [auth][details]: { \"provider\": \"github\" }\n * ```\n * :::\n *\n * For an [OAuth provider](https://authjs.dev/getting-started/authentication/oauth), possible causes are:\n * - The user denied access to the application\n * - There was an error parsing the OAuth Profile:\n * Check out the provider's `profile` or `userinfo.request` method to make sure\n * it correctly fetches the user's profile.\n * - The `signIn` or `jwt` callback methods threw an uncaught error:\n * Check the callback method implementations.\n *\n * For an [Email provider](https://authjs.dev/getting-started/authentication/email), possible causes are:\n * - The provided email/token combination was invalid/missing:\n * Check if the provider's `sendVerificationRequest` method correctly sends the email.\n * - The provided email/token combination has expired:\n * Ask the user to log in again.\n * - There was an error with the database:\n * Check the database logs.\n *\n * For a [Credentials provider](https://authjs.dev/getting-started/authentication/credentials), possible causes are:\n * - The `authorize` method threw an uncaught error:\n * Check the provider's `authorize` method.\n * - The `signIn` or `jwt` callback methods threw an uncaught error:\n * Check the callback method implementations.\n *\n * :::tip\n * Check out `[auth][cause]` in the error message for more details.\n * It will show the original stack trace.\n * :::\n * @noInheritDoc\n */\nexport class CallbackRouteError extends AuthError {\n}\nCallbackRouteError.type = \"CallbackRouteError\";\n/**\n * Thrown when Auth.js is misconfigured and accidentally tried to require authentication on a custom error page.\n * To prevent an infinite loop, Auth.js will instead render its default error page.\n *\n * To fix this, make sure that the `error` page does not require authentication.\n *\n * Learn more at [Guide: Error pages](https://authjs.dev/guides/pages/error)\n * @noInheritDoc\n */\nexport class ErrorPageLoop extends AuthError {\n}\nErrorPageLoop.type = \"ErrorPageLoop\";\n/**\n * One of the [`events` methods](https://authjs.dev/reference/core/types#eventcallbacks)\n * failed during execution.\n *\n * Make sure that the `events` methods are implemented correctly and uncaught errors are handled.\n *\n * Learn more at [`events`](https://authjs.dev/reference/core/types#eventcallbacks)\n * @noInheritDoc\n */\nexport class EventError extends AuthError {\n}\nEventError.type = \"EventError\";\n/**\n * Thrown when Auth.js is unable to verify a `callbackUrl` value.\n * The browser either disabled cookies or the `callbackUrl` is not a valid URL.\n *\n * Somebody might have tried to manipulate the callback URL that Auth.js uses to redirect the user back to the configured `callbackUrl`/page.\n * This could be a malicious hacker trying to redirect the user to a phishing site.\n * To prevent this, Auth.js checks if the callback URL is valid and throws this error if it is not.\n *\n * There is no action required, but it might be an indicator that somebody is trying to attack your application.\n * @noInheritDoc\n */\nexport class InvalidCallbackUrl extends AuthError {\n}\nInvalidCallbackUrl.type = \"InvalidCallbackUrl\";\n/**\n * Can be thrown from the `authorize` callback of the Credentials provider.\n * When an error occurs during the `authorize` callback, two things can happen:\n * 1. The user is redirected to the signin page, with `error=CredentialsSignin&code=credentials` in the URL. `code` is configurable.\n * 2. If you throw this error in a framework that handles form actions server-side, this error is thrown, instead of redirecting the user, so you'll need to handle.\n * @noInheritDoc\n */\nexport class CredentialsSignin extends SignInError {\n constructor() {\n super(...arguments);\n /**\n * The error code that is set in the `code` query parameter of the redirect URL.\n *\n *\n * ⚠ NOTE: This property is going to be included in the URL, so make sure it does not hint at sensitive errors.\n *\n * The full error is always logged on the server, if you need to debug.\n *\n * Generally, we don't recommend hinting specifically if the user had either a wrong username or password specifically,\n * try rather something like \"Invalid credentials\".\n */\n this.code = \"credentials\";\n }\n}\nCredentialsSignin.type = \"CredentialsSignin\";\n/**\n * One of the configured OAuth or OIDC providers is missing the `authorization`, `token` or `userinfo`, or `issuer` configuration.\n * To perform OAuth or OIDC sign in, at least one of these endpoints is required.\n *\n * Learn more at [`OAuth2Config`](https://authjs.dev/reference/core/providers#oauth2configprofile) or [Guide: OAuth Provider](https://authjs.dev/guides/configuring-oauth-providers)\n * @noInheritDoc\n */\nexport class InvalidEndpoints extends AuthError {\n}\nInvalidEndpoints.type = \"InvalidEndpoints\";\n/**\n * Thrown when a PKCE, state or nonce OAuth check could not be performed.\n * This could happen if the OAuth provider is configured incorrectly or if the browser is blocking cookies.\n *\n * Learn more at [`checks`](https://authjs.dev/reference/core/providers#checks)\n * @noInheritDoc\n */\nexport class InvalidCheck extends AuthError {\n}\nInvalidCheck.type = \"InvalidCheck\";\n/**\n * Logged on the server when Auth.js could not decode or encode a JWT-based (`strategy: \"jwt\"`) session.\n *\n * Possible causes are either a misconfigured `secret` or a malformed JWT or `encode/decode` methods.\n *\n * :::note\n * When this error is logged, the session cookie is destroyed.\n * :::\n *\n * Learn more at [`secret`](https://authjs.dev/reference/core#secret), [`jwt.encode`](https://authjs.dev/reference/core/jwt#encode-1) or [`jwt.decode`](https://authjs.dev/reference/core/jwt#decode-2) for more information.\n * @noInheritDoc\n */\nexport class JWTSessionError extends AuthError {\n}\nJWTSessionError.type = \"JWTSessionError\";\n/**\n * Thrown if Auth.js is misconfigured. This could happen if you configured an Email provider but did not set up a database adapter,\n * or tried using a `strategy: \"database\"` session without a database adapter.\n * In both cases, make sure you either remove the configuration or add the missing adapter.\n *\n * Learn more at [Database Adapters](https://authjs.dev/getting-started/database), [Email provider](https://authjs.dev/getting-started/authentication/email) or [Concept: Database session strategy](https://authjs.dev/concepts/session-strategies#database-session)\n * @noInheritDoc\n */\nexport class MissingAdapter extends AuthError {\n}\nMissingAdapter.type = \"MissingAdapter\";\n/**\n * Thrown similarily to [`MissingAdapter`](https://authjs.dev/reference/core/errors#missingadapter), but only some required methods were missing.\n *\n * Make sure you either remove the configuration or add the missing methods to the adapter.\n *\n * Learn more at [Database Adapters](https://authjs.dev/getting-started/database)\n * @noInheritDoc\n */\nexport class MissingAdapterMethods extends AuthError {\n}\nMissingAdapterMethods.type = \"MissingAdapterMethods\";\n/**\n * Thrown when a Credentials provider is missing the `authorize` configuration.\n * To perform credentials sign in, the `authorize` method is required.\n *\n * Learn more at [Credentials provider](https://authjs.dev/getting-started/authentication/credentials)\n * @noInheritDoc\n */\nexport class MissingAuthorize extends AuthError {\n}\nMissingAuthorize.type = \"MissingAuthorize\";\n/**\n * Auth.js requires a secret or multiple secrets to be set, but none was not found. This is used to encrypt cookies, JWTs and other sensitive data.\n *\n * :::note\n * If you are using a framework like Next.js, we try to automatically infer the secret from the `AUTH_SECRET`, `AUTH_SECRET_1`, etc. environment variables.\n * Alternatively, you can also explicitly set the [`AuthConfig.secret`](https://authjs.dev/reference/core#secret) option.\n * :::\n *\n *\n * :::tip\n * To generate a random string, you can use the Auth.js CLI: `npx auth secret`\n * :::\n * @noInheritDoc\n */\nexport class MissingSecret extends AuthError {\n}\nMissingSecret.type = \"MissingSecret\";\n/**\n * Thrown when an Email address is already associated with an account\n * but the user is trying an OAuth account that is not linked to it.\n *\n * For security reasons, Auth.js does not automatically link OAuth accounts to existing accounts if the user is not signed in.\n *\n * :::tip\n * If you trust the OAuth provider to have verified the user's email address,\n * you can enable automatic account linking by setting [`allowDangerousEmailAccountLinking: true`](https://authjs.dev/reference/core/providers#allowdangerousemailaccountlinking)\n * in the provider configuration.\n * :::\n * @noInheritDoc\n */\nexport class OAuthAccountNotLinked extends SignInError {\n}\nOAuthAccountNotLinked.type = \"OAuthAccountNotLinked\";\n/**\n * Thrown when an OAuth provider returns an error during the sign in process.\n * This could happen for example if the user denied access to the application or there was a configuration error.\n *\n * For a full list of possible reasons, check out the specification [Authorization Code Grant: Error Response](https://www.rfc-editor.org/rfc/rfc6749#section-4.1.2.1)\n * @noInheritDoc\n */\nexport class OAuthCallbackError extends SignInError {\n}\nOAuthCallbackError.type = \"OAuthCallbackError\";\n/**\n * This error occurs during an OAuth sign in attempt when the provider's\n * response could not be parsed. This could for example happen if the provider's API\n * changed, or the [`OAuth2Config.profile`](https://authjs.dev/reference/core/providers#oauth2configprofile) method is not implemented correctly.\n * @noInheritDoc\n */\nexport class OAuthProfileParseError extends AuthError {\n}\nOAuthProfileParseError.type = \"OAuthProfileParseError\";\n/**\n * Logged on the server when Auth.js could not retrieve a session from the database (`strategy: \"database\"`).\n *\n * The database adapter might be misconfigured or the database is not reachable.\n *\n * Learn more at [Concept: Database session strategy](https://authjs.dev/concepts/session-strategies#database)\n * @noInheritDoc\n */\nexport class SessionTokenError extends AuthError {\n}\nSessionTokenError.type = \"SessionTokenError\";\n/**\n * Happens when login by [OAuth](https://authjs.dev/getting-started/authentication/oauth) could not be started.\n *\n * Possible causes are:\n * - The Authorization Server is not compliant with the [OAuth 2.0](https://www.ietf.org/rfc/rfc6749.html) or the [OIDC](https://openid.net/specs/openid-connect-core-1_0.html) specification.\n * Check the details in the error message.\n *\n * :::tip\n * Check out `[auth][details]` in the logs to know which provider failed.\n * @example\n * ```sh\n * [auth][details]: { \"provider\": \"github\" }\n * ```\n * :::\n * @noInheritDoc\n */\nexport class OAuthSignInError extends SignInError {\n}\nOAuthSignInError.type = \"OAuthSignInError\";\n/**\n * Happens when the login by an [Email provider](https://authjs.dev/getting-started/authentication/email) could not be started.\n *\n * Possible causes are:\n * - The email sent from the client is invalid, could not be normalized by [`EmailConfig.normalizeIdentifier`](https://authjs.dev/reference/core/providers/email#normalizeidentifier)\n * - The provided email/token combination has expired:\n * Ask the user to log in again.\n * - There was an error with the database:\n * Check the database logs.\n * @noInheritDoc\n */\nexport class EmailSignInError extends SignInError {\n}\nEmailSignInError.type = \"EmailSignInError\";\n/**\n * Represents an error that occurs during the sign-out process. This error\n * is logged when there are issues in terminating a user's session, either\n * by failing to delete the session from the database (in database session\n * strategies) or encountering issues during other parts of the sign-out\n * process, such as emitting sign-out events or clearing session cookies.\n *\n * The session cookie(s) are emptied even if this error is logged.\n * @noInheritDoc\n */\nexport class SignOutError extends AuthError {\n}\nSignOutError.type = \"SignOutError\";\n/**\n * Auth.js was requested to handle an operation that it does not support.\n *\n * See [`AuthAction`](https://authjs.dev/reference/core/types#authaction) for the supported actions.\n * @noInheritDoc\n */\nexport class UnknownAction extends AuthError {\n}\nUnknownAction.type = \"UnknownAction\";\n/**\n * Thrown when a Credentials provider is present but the JWT strategy (`strategy: \"jwt\"`) is not enabled.\n *\n * Learn more at [`strategy`](https://authjs.dev/reference/core#strategy) or [Credentials provider](https://authjs.dev/getting-started/authentication/credentials)\n * @noInheritDoc\n */\nexport class UnsupportedStrategy extends AuthError {\n}\nUnsupportedStrategy.type = \"UnsupportedStrategy\";\n/**\n * Thrown when an endpoint was incorrectly called without a provider, or with an unsupported provider.\n * @noInheritDoc\n */\nexport class InvalidProvider extends AuthError {\n}\nInvalidProvider.type = \"InvalidProvider\";\n/**\n * Thrown when the `trustHost` option was not set to `true`.\n *\n * Auth.js requires the `trustHost` option to be set to `true` since it's relying on the request headers' `host` value.\n *\n * :::note\n * Official Auth.js libraries might attempt to automatically set the `trustHost` option to `true` if the request is coming from a trusted host on a trusted platform.\n * :::\n *\n * Learn more at [`trustHost`](https://authjs.dev/reference/core#trusthost) or [Guide: Deployment](https://authjs.dev/getting-started/deployment)\n * @noInheritDoc\n */\nexport class UntrustedHost extends AuthError {\n}\nUntrustedHost.type = \"UntrustedHost\";\n/**\n * The user's email/token combination was invalid.\n * This could be because the email/token combination was not found in the database,\n * or because the token has expired. Ask the user to log in again.\n * @noInheritDoc\n */\nexport class Verification extends AuthError {\n}\nVerification.type = \"Verification\";\n/**\n * Error for missing CSRF tokens in client-side actions (`signIn`, `signOut`, `useSession#update`).\n * Thrown when actions lack the double submit cookie, essential for CSRF protection.\n *\n * CSRF ([Cross-Site Request Forgery](https://owasp.org/www-community/attacks/csrf))\n * is an attack leveraging authenticated user credentials for unauthorized actions.\n *\n * Double submit cookie pattern, a CSRF defense, requires matching values in a cookie\n * and request parameter. More on this at [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Glossary/CSRF).\n * @noInheritDoc\n */\nexport class MissingCSRF extends SignInError {\n}\nMissingCSRF.type = \"MissingCSRF\";\nconst clientErrors = new Set([\n \"CredentialsSignin\",\n \"OAuthAccountNotLinked\",\n \"OAuthCallbackError\",\n \"AccessDenied\",\n \"Verification\",\n \"MissingCSRF\",\n \"AccountNotLinked\",\n \"WebAuthnVerificationError\",\n]);\n/**\n * Used to only allow sending a certain subset of errors to the client.\n * Errors are always logged on the server, but to prevent leaking sensitive information,\n * only a subset of errors are sent to the client as-is.\n * @internal\n */\nexport function isClientError(error) {\n if (error instanceof AuthError)\n return clientErrors.has(error.type);\n return false;\n}\n/**\n * Thrown when multiple providers have `enableConditionalUI` set to `true`.\n * Only one provider can have this option enabled at a time.\n * @noInheritDoc\n */\nexport class DuplicateConditionalUI extends AuthError {\n}\nDuplicateConditionalUI.type = \"DuplicateConditionalUI\";\n/**\n * Thrown when a WebAuthn provider has `enableConditionalUI` set to `true` but no formField has `webauthn` in its autocomplete param.\n *\n * The `webauthn` autocomplete param is required for conditional UI to work.\n * @noInheritDoc\n */\nexport class MissingWebAuthnAutocomplete extends AuthError {\n}\nMissingWebAuthnAutocomplete.type = \"MissingWebAuthnAutocomplete\";\n/**\n * Thrown when a WebAuthn provider fails to verify a client response.\n * @noInheritDoc\n */\nexport class WebAuthnVerificationError extends AuthError {\n}\nWebAuthnVerificationError.type = \"WebAuthnVerificationError\";\n/**\n * Thrown when an Email address is already associated with an account\n * but the user is trying an account that is not linked to it.\n *\n * For security reasons, Auth.js does not automatically link accounts to existing accounts if the user is not signed in.\n * @noInheritDoc\n */\nexport class AccountNotLinked extends SignInError {\n}\nAccountNotLinked.type = \"AccountNotLinked\";\n/**\n * Thrown when an experimental feature is used but not enabled.\n * @noInheritDoc\n */\nexport class ExperimentalFeatureNotEnabled extends AuthError {\n}\nExperimentalFeatureNotEnabled.type = \"ExperimentalFeatureNotEnabled\";\n"],"names":[],"mappings":"AAAA;;;;;CAKC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACM,MAAM,kBAAkB;IAC3B,cAAc,GACd,YAAY,OAAO,EAAE,YAAY,CAAE;QAC/B,IAAI,mBAAmB,OAAO;YAC1B,KAAK,CAAC,WAAW;gBACb,OAAO;oBAAE,KAAK;oBAAS,GAAG,QAAQ,KAAK;oBAAE,GAAG,YAAY;gBAAC;YAC7D;QACJ,OACK,IAAI,OAAO,YAAY,UAAU;YAClC,IAAI,wBAAwB,OAAO;gBAC/B,eAAe;oBAAE,KAAK;oBAAc,GAAG,aAAa,KAAK;gBAAC;YAC9D;YACA,KAAK,CAAC,SAAS;QACnB,OACK;YACD,KAAK,CAAC,WAAW;QACrB;QACA,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,WAAW,CAAC,IAAI;QACjC,uEAAuE;QACvE,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,WAAW,CAAC,IAAI,IAAI;QACrC,uEAAuE;QACvE,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,WAAW,CAAC,IAAI,IAAI;QACrC,MAAM,iBAAiB,GAAG,IAAI,EAAE,IAAI,CAAC,WAAW;QAChD,MAAM,MAAM,CAAC,0BAA0B,EAAE,IAAI,CAAC,IAAI,CAAC,WAAW,IAAI;QAClE,IAAI,CAAC,OAAO,IAAI,GAAG,IAAI,CAAC,OAAO,GAAG,OAAO,GAAG,aAAa,EAAE,KAAK;IACpE;AACJ;AAKO,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AM,sBAAsB;AACnC;AACA,cAAc,IAAI,GAAG;AAOd,MAAM,4BAA4B;AACzC;AACA,oBAAoB,IAAI,GAAG;AAKpB,MAAM,wBAAwB;AACrC;AACA,gBAAgB,IAAI,GAAG;AAahB,MAAM,sBAAsB;AACnC;AACA,cAAc,IAAI,GAAG;AAOd,MAAM,qBAAqB;AAClC;AACA,aAAa,IAAI,GAAG;AAYb,MAAM,oBAAoB;AACjC;AACA,YAAY,IAAI,GAAG;AACnB,MAAM,eAAe,IAAI,IAAI;IACzB;IACA;IACA;IACA;IACA;IACA;IACA;IACA;CACH;AAOM,SAAS,cAAc,KAAK;IAC/B,IAAI,iBAAiB,WACjB,OAAO,aAAa,GAAG,CAAC,MAAM,IAAI;IACtC,OAAO;AACX;AAMO,MAAM,+BAA+B;AAC5C;AACA,uBAAuB,IAAI,GAAG;AAOvB,MAAM,oCAAoC;AACjD;AACA,4BAA4B,IAAI,GAAG;AAK5B,MAAM,kCAAkC;AAC/C;AACA,0BAA0B,IAAI,GAAG;AAQ1B,MAAM,yBAAyB;AACtC;AACA,iBAAiB,IAAI,GAAG;AAKjB,MAAM,sCAAsC;AACnD;AACA,8BAA8B,IAAI,GAAG","ignoreList":[0]}}, + {"offset": {"line": 678, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/node_modules/next-auth/lib/client.js"],"sourcesContent":["\"use client\";\nimport * as React from \"react\";\nimport { AuthError } from \"@auth/core/errors\";\n/** @todo */\nclass ClientFetchError extends AuthError {\n}\n/** @todo */\nexport class ClientSessionError extends AuthError {\n}\n// ------------------------ Internal ------------------------\n/**\n * If passed 'appContext' via getInitialProps() in _app.js\n * then get the req object from ctx and use that for the\n * req value to allow `fetchData` to\n * work seemlessly in getInitialProps() on server side\n * pages *and* in _app.js.\n * @internal\n */\nexport async function fetchData(path, __NEXTAUTH, logger, req = {}) {\n const url = `${apiBaseUrl(__NEXTAUTH)}/${path}`;\n try {\n const options = {\n headers: {\n \"Content-Type\": \"application/json\",\n ...(req?.headers?.cookie ? { cookie: req.headers.cookie } : {}),\n },\n };\n if (req?.body) {\n options.body = JSON.stringify(req.body);\n options.method = \"POST\";\n }\n const res = await fetch(url, options);\n const data = await res.json();\n if (!res.ok)\n throw data;\n return data;\n }\n catch (error) {\n logger.error(new ClientFetchError(error.message, error));\n return null;\n }\n}\n/** @internal */\nexport function apiBaseUrl(__NEXTAUTH) {\n if (typeof window === \"undefined\") {\n // Return absolute path when called server side\n return `${__NEXTAUTH.baseUrlServer}${__NEXTAUTH.basePathServer}`;\n }\n // Return relative path when called client side\n return __NEXTAUTH.basePath;\n}\n/** @internal */\nexport function useOnline() {\n const [isOnline, setIsOnline] = React.useState(typeof navigator !== \"undefined\" ? navigator.onLine : false);\n const setOnline = () => setIsOnline(true);\n const setOffline = () => setIsOnline(false);\n React.useEffect(() => {\n window.addEventListener(\"online\", setOnline);\n window.addEventListener(\"offline\", setOffline);\n return () => {\n window.removeEventListener(\"online\", setOnline);\n window.removeEventListener(\"offline\", setOffline);\n };\n }, []);\n return isOnline;\n}\n/**\n * Returns the number of seconds elapsed since January 1, 1970 00:00:00 UTC.\n * @internal\n */\nexport function now() {\n return Math.floor(Date.now() / 1000);\n}\n/**\n * Returns an `URL` like object to make requests/redirects from server-side\n * @internal\n */\nexport function parseUrl(url) {\n const defaultUrl = new URL(\"http://localhost:3000/api/auth\");\n if (url && !url.startsWith(\"http\")) {\n url = `https://${url}`;\n }\n const _url = new URL(url || defaultUrl);\n const path = (_url.pathname === \"/\" ? defaultUrl.pathname : _url.pathname)\n // Remove trailing slash\n .replace(/\\/$/, \"\");\n const base = `${_url.origin}${path}`;\n return {\n origin: _url.origin,\n host: _url.host,\n path,\n base,\n toString: () => base,\n };\n}\n"],"names":[],"mappings":";;;;;;;;;;;;;;AACA;AACA;AAFA;;;AAGA,UAAU,GACV,MAAM,yBAAyB,iMAAS;AACxC;AAEO,MAAM,2BAA2B,iMAAS;AACjD;AAUO,eAAe,U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O,CAAC,IAAI,UAAU,CAAC,SAAS;QAChC,MAAM,CAAC,QAAQ,EAAE,KAAK;IAC1B;IACA,MAAM,OAAO,IAAI,IAAI,OAAO;IAC5B,MAAM,OAAO,CAAC,KAAK,QAAQ,KAAK,MAAM,WAAW,QAAQ,GAAG,KAAK,QAAQ,CACrE,wBAAwB;KACvB,OAAO,CAAC,OAAO;IACpB,MAAM,OAAO,GAAG,KAAK,MAAM,GAAG,MAAM;IACpC,OAAO;QACH,QAAQ,KAAK,MAAM;QACnB,MAAM,KAAK,IAAI;QACf;QACA;QACA,UAAU,IAAM;IACpB;AACJ","ignoreList":[0]}}, + {"offset": {"line": 771, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/node_modules/next-auth/react.js"],"sourcesContent":["/**\n *\n * NextAuth.js is the official integration of Auth.js for Next.js applications. It supports both\n * [Client Components](https://nextjs.org/docs/app/building-your-application/rendering/client-components) and the\n * [Pages Router](https://nextjs.org/docs/pages). It includes methods for signing in, signing out, hooks, and a React\n * Context provider to wrap your application and make session data available anywhere.\n *\n * For use in [Server Actions](https://nextjs.org/docs/app/api-reference/functions/server-actions), check out [these methods](https://authjs.dev/guides/upgrade-to-v5#methods)\n *\n * @module react\n */\n\"use client\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport * as React from \"react\";\nimport { apiBaseUrl, ClientSessionError, fetchData, now, parseUrl, useOnline, } from \"./lib/client.js\";\n// This behaviour mirrors the default behaviour for getting the site name that\n// happens server side in server/index.js\n// 1. An empty value is legitimate when the code is being invoked client side as\n// relative URLs are valid in that context and so defaults to empty.\n// 2. When invoked server side the value is picked up from an environment\n// variable and defaults to 'http://localhost:3000'.\nexport const __NEXTAUTH = {\n baseUrl: parseUrl(process.env.NEXTAUTH_URL ?? process.env.VERCEL_URL).origin,\n basePath: parseUrl(process.env.NEXTAUTH_URL).path,\n baseUrlServer: parseUrl(process.env.NEXTAUTH_URL_INTERNAL ??\n process.env.NEXTAUTH_URL ??\n process.env.VERCEL_URL).origin,\n basePathServer: parseUrl(process.env.NEXTAUTH_URL_INTERNAL ?? process.env.NEXTAUTH_URL).path,\n _lastSync: 0,\n _session: undefined,\n _getSession: () => { },\n};\n// https://github.com/nextauthjs/next-auth/pull/10762\nlet broadcastChannel = null;\nfunction getNewBroadcastChannel() {\n if (typeof BroadcastChannel === \"undefined\") {\n return {\n postMessage: () => { },\n addEventListener: () => { },\n removeEventListener: () => { },\n name: \"next-auth\",\n onmessage: null,\n onmessageerror: null,\n close: () => { },\n dispatchEvent: () => false,\n };\n }\n return new BroadcastChannel(\"next-auth\");\n}\nfunction broadcast() {\n if (broadcastChannel === null) {\n broadcastChannel = getNewBroadcastChannel();\n }\n return broadcastChannel;\n}\n// TODO:\nconst logger = {\n debug: console.debug,\n error: console.error,\n warn: console.warn,\n};\nexport const SessionContext = React.createContext?.(undefined);\n/**\n * React Hook that gives you access to the logged in user's session data and lets you modify it.\n *\n * :::info\n * `useSession` is for client-side use only and when using [Next.js App Router (`app/`)](https://nextjs.org/blog/next-13-4#nextjs-app-router) you should prefer the `auth()` export.\n * :::\n */\nexport function useSession(options) {\n if (!SessionContext) {\n throw new Error(\"React Context is unavailable in Server Components\");\n }\n // @ts-expect-error Satisfy TS if branch on line below\n const value = React.useContext(SessionContext);\n if (!value && process.env.NODE_ENV !== \"production\") {\n throw new Error(\"[next-auth]: `useSession` must be wrapped in a \");\n }\n const { required, onUnauthenticated } = options ?? {};\n const requiredAndNotLoading = required && value.status === \"unauthenticated\";\n React.useEffect(() => {\n if (requiredAndNotLoading) {\n const url = `${__NEXTAUTH.basePath}/signin?${new URLSearchParams({\n error: \"SessionRequired\",\n callbackUrl: window.location.href,\n })}`;\n if (onUnauthenticated)\n onUnauthenticated();\n else\n window.location.href = url;\n }\n }, [requiredAndNotLoading, onUnauthenticated]);\n if (requiredAndNotLoading) {\n return {\n data: value.data,\n update: value.update,\n status: \"loading\",\n };\n }\n return value;\n}\nexport async function getSession(params) {\n const session = await fetchData(\"session\", __NEXTAUTH, logger, params);\n if (params?.broadcast ?? true) {\n // https://github.com/nextauthjs/next-auth/pull/11470\n getNewBroadcastChannel().postMessage({\n event: \"session\",\n data: { trigger: \"getSession\" },\n });\n }\n return session;\n}\n/**\n * Returns the current Cross-Site Request Forgery Token (CSRF Token)\n * required to make requests that changes state. (e.g. signing in or out, or updating the session).\n *\n * [CSRF Prevention: Double Submit Cookie](https://cheatsheetseries.owasp.org/cheatsheets/Cross-Site_Request_Forgery_Prevention_Cheat_Sheet.html#double-submit-cookie)\n */\nexport async function getCsrfToken() {\n const response = await fetchData(\"csrf\", __NEXTAUTH, logger);\n return response?.csrfToken ?? \"\";\n}\nexport async function getProviders() {\n return fetchData(\"providers\", __NEXTAUTH, logger);\n}\nexport async function signIn(provider, options, authorizationParams) {\n const { callbackUrl, ...rest } = options ?? {};\n const { redirect = true, redirectTo = callbackUrl ?? window.location.href, ...signInParams } = rest;\n const baseUrl = apiBaseUrl(__NEXTAUTH);\n const providers = await getProviders();\n if (!providers) {\n const url = `${baseUrl}/error`;\n window.location.href = url;\n return; // TODO: Return error if `redirect: false`\n }\n if (!provider || !providers[provider]) {\n const url = `${baseUrl}/signin?${new URLSearchParams({\n callbackUrl: redirectTo,\n })}`;\n window.location.href = url;\n return; // TODO: Return error if `redirect: false`\n }\n const providerType = providers[provider].type;\n if (providerType === \"webauthn\") {\n // TODO: Add docs link with explanation\n throw new TypeError([\n `Provider id \"${provider}\" refers to a WebAuthn provider.`,\n 'Please use `import { signIn } from \"next-auth/webauthn\"` instead.',\n ].join(\"\\n\"));\n }\n const signInUrl = `${baseUrl}/${providerType === \"credentials\" ? \"callback\" : \"signin\"}/${provider}`;\n const csrfToken = await getCsrfToken();\n const res = await fetch(`${signInUrl}?${new URLSearchParams(authorizationParams)}`, {\n method: \"post\",\n headers: {\n \"Content-Type\": \"application/x-www-form-urlencoded\",\n \"X-Auth-Return-Redirect\": \"1\",\n },\n body: new URLSearchParams({\n ...signInParams,\n csrfToken,\n callbackUrl: redirectTo,\n }),\n });\n const data = await res.json();\n if (redirect) {\n const url = data.url ?? redirectTo;\n window.location.href = url;\n // If url contains a hash, the browser does not reload the page. We reload manually\n if (url.includes(\"#\"))\n window.location.reload();\n return;\n }\n const error = new URL(data.url).searchParams.get(\"error\") ?? undefined;\n const code = new URL(data.url).searchParams.get(\"code\") ?? undefined;\n if (res.ok) {\n await __NEXTAUTH._getSession({ event: \"storage\" });\n }\n return {\n error,\n code,\n status: res.status,\n ok: res.ok,\n url: error ? null : data.url,\n };\n}\nexport async function signOut(options) {\n const { redirect = true, redirectTo = options?.callbackUrl ?? window.location.href, } = options ?? {};\n const baseUrl = apiBaseUrl(__NEXTAUTH);\n const csrfToken = await getCsrfToken();\n const res = await fetch(`${baseUrl}/signout`, {\n method: \"post\",\n headers: {\n \"Content-Type\": \"application/x-www-form-urlencoded\",\n \"X-Auth-Return-Redirect\": \"1\",\n },\n body: new URLSearchParams({ csrfToken, callbackUrl: redirectTo }),\n });\n const data = await res.json();\n broadcast().postMessage({ event: \"session\", data: { trigger: \"signout\" } });\n if (redirect) {\n const url = data.url ?? redirectTo;\n window.location.href = url;\n // If url contains a hash, the browser does not reload the page. We reload manually\n if (url.includes(\"#\"))\n window.location.reload();\n return;\n }\n await __NEXTAUTH._getSession({ event: \"storage\" });\n return data;\n}\n/**\n * [React Context](https://react.dev/learn/passing-data-deeply-with-context) provider to wrap the app (`pages/`) to make session data available anywhere.\n *\n * When used, the session state is automatically synchronized across all open tabs/windows and they are all updated whenever they gain or lose focus\n * or the state changes (e.g. a user signs in or out) when {@link SessionProviderProps.refetchOnWindowFocus} is `true`.\n *\n * :::info\n * `SessionProvider` is for client-side use only and when using [Next.js App Router (`app/`)](https://nextjs.org/blog/next-13-4#nextjs-app-router) you should prefer the `auth()` export.\n * :::\n */\nexport function SessionProvider(props) {\n if (!SessionContext) {\n throw new Error(\"React Context is unavailable in Server Components\");\n }\n const { children, basePath, refetchInterval, refetchWhenOffline } = props;\n if (basePath)\n __NEXTAUTH.basePath = basePath;\n /**\n * If session was `null`, there was an attempt to fetch it,\n * but it failed, but we still treat it as a valid initial value.\n */\n const hasInitialSession = props.session !== undefined;\n /** If session was passed, initialize as already synced */\n __NEXTAUTH._lastSync = hasInitialSession ? now() : 0;\n const [session, setSession] = React.useState(() => {\n if (hasInitialSession)\n __NEXTAUTH._session = props.session;\n return props.session;\n });\n /** If session was passed, initialize as not loading */\n const [loading, setLoading] = React.useState(!hasInitialSession);\n React.useEffect(() => {\n __NEXTAUTH._getSession = async ({ event } = {}) => {\n try {\n const storageEvent = event === \"storage\";\n // We should always update if we don't have a client session yet\n // or if there are events from other tabs/windows\n if (storageEvent || __NEXTAUTH._session === undefined) {\n __NEXTAUTH._lastSync = now();\n __NEXTAUTH._session = await getSession({\n broadcast: !storageEvent,\n });\n setSession(__NEXTAUTH._session);\n return;\n }\n if (\n // If there is no time defined for when a session should be considered\n // stale, then it's okay to use the value we have until an event is\n // triggered which updates it\n !event ||\n // If the client doesn't have a session then we don't need to call\n // the server to check if it does (if they have signed in via another\n // tab or window that will come through as a \"stroage\" event\n // event anyway)\n __NEXTAUTH._session === null ||\n // Bail out early if the client session is not stale yet\n now() < __NEXTAUTH._lastSync) {\n return;\n }\n // An event or session staleness occurred, update the client session.\n __NEXTAUTH._lastSync = now();\n __NEXTAUTH._session = await getSession();\n setSession(__NEXTAUTH._session);\n }\n catch (error) {\n logger.error(new ClientSessionError(error.message, error));\n }\n finally {\n setLoading(false);\n }\n };\n __NEXTAUTH._getSession();\n return () => {\n __NEXTAUTH._lastSync = 0;\n __NEXTAUTH._session = undefined;\n __NEXTAUTH._getSession = () => { };\n };\n }, []);\n React.useEffect(() => {\n const handle = () => __NEXTAUTH._getSession({ event: \"storage\" });\n // Listen for storage events and update session if event fired from\n // another window (but suppress firing another event to avoid a loop)\n // Fetch new session data but tell it to not to fire another event to\n // avoid an infinite loop.\n // Note: We could pass session data through and do something like\n // `setData(message.data)` but that can cause problems depending\n // on how the session object is being used in the client; it is\n // more robust to have each window/tab fetch it's own copy of the\n // session object rather than share it across instances.\n broadcast().addEventListener(\"message\", handle);\n return () => broadcast().removeEventListener(\"message\", handle);\n }, []);\n React.useEffect(() => {\n const { refetchOnWindowFocus = true } = props;\n // Listen for when the page is visible, if the user switches tabs\n // and makes our tab visible again, re-fetch the session, but only if\n // this feature is not disabled.\n const visibilityHandler = () => {\n if (refetchOnWindowFocus && document.visibilityState === \"visible\")\n __NEXTAUTH._getSession({ event: \"visibilitychange\" });\n };\n document.addEventListener(\"visibilitychange\", visibilityHandler, false);\n return () => document.removeEventListener(\"visibilitychange\", visibilityHandler, false);\n }, [props.refetchOnWindowFocus]);\n const isOnline = useOnline();\n // TODO: Flip this behavior in next major version\n const shouldRefetch = refetchWhenOffline !== false || isOnline;\n React.useEffect(() => {\n if (refetchInterval && shouldRefetch) {\n const refetchIntervalTimer = setInterval(() => {\n if (__NEXTAUTH._session) {\n __NEXTAUTH._getSession({ event: \"poll\" });\n }\n }, refetchInterval * 1000);\n return () => clearInterval(refetchIntervalTimer);\n }\n }, [refetchInterval, shouldRefetch]);\n const value = React.useMemo(() => ({\n data: session,\n status: loading\n ? \"loading\"\n : session\n ? \"authenticated\"\n : \"unauthenticated\",\n async update(data) {\n if (loading)\n return;\n setLoading(true);\n const newSession = await fetchData(\"session\", __NEXTAUTH, logger, typeof data === \"undefined\"\n ? undefined\n : { body: { csrfToken: await getCsrfToken(), data } });\n setLoading(false);\n if (newSession) {\n setSession(newSession);\n broadcast().postMessage({\n event: \"session\",\n data: { trigger: \"getSession\" },\n });\n }\n return newSession;\n },\n }), [session, loading]);\n return (\n // @ts-expect-error\n _jsx(SessionContext.Provider, { value: value, children: children }));\n}\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;AAYA;AACA;AACA;AAdA;;;;;;;;;;CAUC,GACD;;;;AAUO,MAAM,aAAa;IACtB,SAAS,IAAA,qMAAQ,EAAC,QAAQ,GAAG,CAAC,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AO;QAAO,UAAU;IAAS;AACrE","ignoreList":[0]}}] } \ No newline at end of file diff --git a/.next/dev/server/next-font-manifest.js b/.next/dev/server/next-font-manifest.js index 84dff8e..ad9244d 100644 --- a/.next/dev/server/next-font-manifest.js +++ b/.next/dev/server/next-font-manifest.js @@ -1 +1 @@ -self.__NEXT_FONT_MANIFEST="{\n \"app\": {\n \"[project]/Documents/00 - projet/plumeia/src/app/dashboard/page\": [\n \"static/media/83afe278b6a6bb3c-s.p.3a6ba036.woff2\",\n \"static/media/248e1dc0efc99276-s.p.8a6b2436.woff2\"\n ],\n \"[project]/Documents/00 - projet/plumeia/src/app/login/page\": [\n \"static/media/83afe278b6a6bb3c-s.p.3a6ba036.woff2\",\n \"static/media/248e1dc0efc99276-s.p.8a6b2436.woff2\"\n ],\n \"[project]/Documents/00 - projet/plumeia/src/app/page\": [\n \"static/media/83afe278b6a6bb3c-s.p.3a6ba036.woff2\",\n \"static/media/248e1dc0efc99276-s.p.8a6b2436.woff2\"\n ],\n \"[project]/Documents/00 - projet/plumeia/src/app/project/[id]/page\": [\n \"static/media/83afe278b6a6bb3c-s.p.3a6ba036.woff2\",\n \"static/media/248e1dc0efc99276-s.p.8a6b2436.woff2\"\n ],\n \"[project]/Documents/00 - projet/plumeia/src/app/project/[id]/world/page\": [\n \"static/media/83afe278b6a6bb3c-s.p.3a6ba036.woff2\",\n \"static/media/248e1dc0efc99276-s.p.8a6b2436.woff2\"\n ]\n },\n \"appUsingSizeAdjust\": true,\n \"pages\": {},\n \"pagesUsingSizeAdjust\": false\n}" \ No newline at end of file +self.__NEXT_FONT_MANIFEST="{\n \"app\": {\n \"[project]/Documents/00 - projet/plumeia/src/app/dashboard/page\": [\n \"static/media/83afe278b6a6bb3c-s.p.3a6ba036.woff2\",\n \"static/media/248e1dc0efc99276-s.p.8a6b2436.woff2\"\n ],\n \"[project]/Documents/00 - projet/plumeia/src/app/login/page\": [\n \"static/media/83afe278b6a6bb3c-s.p.3a6ba036.woff2\",\n \"static/media/248e1dc0efc99276-s.p.8a6b2436.woff2\"\n ],\n \"[project]/Documents/00 - projet/plumeia/src/app/page\": [\n \"static/media/83afe278b6a6bb3c-s.p.3a6ba036.woff2\",\n \"static/media/248e1dc0efc99276-s.p.8a6b2436.woff2\"\n ],\n \"[project]/Documents/00 - projet/plumeia/src/app/profile/page\": [\n \"static/media/83afe278b6a6bb3c-s.p.3a6ba036.woff2\",\n \"static/media/248e1dc0efc99276-s.p.8a6b2436.woff2\"\n ],\n \"[project]/Documents/00 - projet/plumeia/src/app/signup/page\": [\n \"static/media/83afe278b6a6bb3c-s.p.3a6ba036.woff2\",\n \"static/media/248e1dc0efc99276-s.p.8a6b2436.woff2\"\n ]\n },\n \"appUsingSizeAdjust\": true,\n \"pages\": {},\n \"pagesUsingSizeAdjust\": false\n}" \ No newline at end of file diff --git a/.next/dev/server/next-font-manifest.json b/.next/dev/server/next-font-manifest.json index a382430..c9da055 100644 --- a/.next/dev/server/next-font-manifest.json +++ b/.next/dev/server/next-font-manifest.json @@ -12,11 +12,11 @@ "static/media/83afe278b6a6bb3c-s.p.3a6ba036.woff2", "static/media/248e1dc0efc99276-s.p.8a6b2436.woff2" ], - "[project]/Documents/00 - projet/plumeia/src/app/project/[id]/page": [ + "[project]/Documents/00 - projet/plumeia/src/app/profile/page": [ "static/media/83afe278b6a6bb3c-s.p.3a6ba036.woff2", "static/media/248e1dc0efc99276-s.p.8a6b2436.woff2" ], - "[project]/Documents/00 - projet/plumeia/src/app/project/[id]/world/page": [ + "[project]/Documents/00 - projet/plumeia/src/app/signup/page": [ "static/media/83afe278b6a6bb3c-s.p.3a6ba036.woff2", "static/media/248e1dc0efc99276-s.p.8a6b2436.woff2" ] diff --git a/.next/dev/static/chunks/Documents_00 - projet_plumeia_0ae2c1c3._.js b/.next/dev/static/chunks/Documents_00 - projet_plumeia_0ae2c1c3._.js index c18c235..f2f79bb 100644 --- a/.next/dev/static/chunks/Documents_00 - projet_plumeia_0ae2c1c3._.js +++ b/.next/dev/static/chunks/Documents_00 - projet_plumeia_0ae2c1c3._.js @@ -46,6 +46,15 @@ const api = { }); } }, + // --- USER --- + user: { + async updateProfile (data) { + return api.request('/user/profile', { + method: 'PUT', + body: JSON.stringify(data) + }); + } + }, // --- PROJECTS --- projects: { async list () { @@ -323,16 +332,44 @@ const useAuth = ()=>{ }["useAuth.useCallback[incrementUsage]"], [ user ]); + const updateProfile = (0, __TURBOPACK__imported__module__$5b$project$5d2f$Documents$2f$00__$2d$__projet$2f$plumeia$2f$node_modules$2f$next$2f$dist$2f$compiled$2f$react$2f$index$2e$js__$5b$app$2d$client$5d$__$28$ecmascript$29$__["useCallback"])({ + "useAuth.useCallback[updateProfile]": async (updates)=>{ + if (!user) return; + try { + // Unpack everything that can be updated into a flat object for the API + const apiUpdates = {}; + if (updates.name !== undefined) apiUpdates.name = updates.name; + if (updates.avatar !== undefined) apiUpdates.avatar = updates.avatar; + if (updates.bio !== undefined) apiUpdates.bio = updates.bio; + if (updates.preferences?.dailyWordGoal !== undefined) apiUpdates.dailyWordGoal = updates.preferences.dailyWordGoal; + // Make the API call to update DB + await __TURBOPACK__imported__module__$5b$project$5d2f$Documents$2f$00__$2d$__projet$2f$plumeia$2f$src$2f$lib$2f$api$2e$ts__$5b$app$2d$client$5d$__$28$ecmascript$29$__["default"].user.updateProfile(apiUpdates); + // Update local state + setUser({ + "useAuth.useCallback[updateProfile]": (prev)=>prev ? { + ...prev, + ...updates + } : null + }["useAuth.useCallback[updateProfile]"]); + } catch (err) { + console.error('Failed to update profile:', err); + throw err; + } + } + }["useAuth.useCallback[updateProfile]"], [ + user + ]); return { user, login, signup, logout, incrementUsage, + updateProfile, loading }; }; -_s(useAuth, "NTps7lD2LRTcy9ISlNr85D5h8IY=", false, function() { +_s(useAuth, "BDPqFrun1TL0uUzYZo247zjajj4=", false, function() { return [ __TURBOPACK__imported__module__$5b$project$5d2f$Documents$2f$00__$2d$__projet$2f$plumeia$2f$node_modules$2f$next$2d$auth$2f$react$2e$js__$5b$app$2d$client$5d$__$28$ecmascript$29$__["useSession"] ]; diff --git a/.next/dev/static/chunks/Documents_00 - projet_plumeia_0ae2c1c3._.js.map b/.next/dev/static/chunks/Documents_00 - projet_plumeia_0ae2c1c3._.js.map index 6c08750..e57fcbd 100644 --- a/.next/dev/static/chunks/Documents_00 - projet_plumeia_0ae2c1c3._.js.map +++ b/.next/dev/static/chunks/Documents_00 - projet_plumeia_0ae2c1c3._.js.map @@ -2,12 +2,12 @@ "version": 3, "sources": [], "sections": [ - {"offset": {"line": 4, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/src/lib/api.ts"],"sourcesContent":["import { BookProject, UserProfile } from './types';\r\n\r\nconst API_BASE_URL = '/api';\r\n\r\n// --- API CLIENT ---\r\n\r\nconst api = {\r\n async request(endpoint: string, options: RequestInit = {}) {\r\n const url = `${API_BASE_URL}${endpoint}`;\r\n\r\n const headers: Record = {\r\n 'Content-Type': 'application/json',\r\n ...options.headers as Record,\r\n };\r\n\r\n const response = await fetch(url, {\r\n ...options,\r\n headers,\r\n });\r\n\r\n if (!response.ok) {\r\n let errorMsg = `Error ${response.status}: ${response.statusText}`;\r\n try {\r\n const errorJson = await response.json();\r\n if (errorJson.error) errorMsg = errorJson.error;\r\n if (errorJson.message) errorMsg = errorJson.message;\r\n } catch {\r\n // Ignore json parse error\r\n }\r\n throw new Error(errorMsg);\r\n }\r\n\r\n if (response.status === 204) return null;\r\n return response.json();\r\n },\r\n\r\n // --- AUTH ---\r\n auth: {\r\n async register(email: string, password: string, name: string) {\r\n return api.request('/auth/register', {\r\n method: 'POST',\r\n body: JSON.stringify({ email, password, name }),\r\n });\r\n },\r\n },\r\n\r\n // --- PROJECTS ---\r\n projects: {\r\n async list() {\r\n return api.request('/projects');\r\n },\r\n\r\n async get(id: string) {\r\n return api.request(`/projects/${id}`);\r\n },\r\n\r\n async create(data: { title: string; author: string; settings?: any }) {\r\n return api.request('/projects', {\r\n method: 'POST',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async update(id: string, data: any) {\r\n return api.request(`/projects/${id}`, {\r\n method: 'PUT',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async delete(id: string) {\r\n return api.request(`/projects/${id}`, {\r\n method: 'DELETE',\r\n });\r\n },\r\n\r\n async syncWorkflow(id: string, data: { nodes: any[]; connections: any[] }) {\r\n return api.request(`/projects/${id}/workflow`, {\r\n method: 'PUT',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n },\r\n\r\n // --- CHAPTERS ---\r\n chapters: {\r\n async create(data: { projectId: string; title?: string; content?: string; summary?: string; orderIndex?: number }) {\r\n return api.request('/chapters', {\r\n method: 'POST',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async update(id: string, data: any) {\r\n return api.request(`/chapters/${id}`, {\r\n method: 'PUT',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async delete(id: string) {\r\n return api.request(`/chapters/${id}`, {\r\n method: 'DELETE',\r\n });\r\n },\r\n },\r\n\r\n // --- ENTITIES ---\r\n entities: {\r\n async create(data: { projectId: string; type: string; name?: string; description?: string; details?: string; attributes?: any; customValues?: any }) {\r\n return api.request('/entities', {\r\n method: 'POST',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async update(id: string, data: any) {\r\n return api.request(`/entities/${id}`, {\r\n method: 'PUT',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async delete(id: string) {\r\n return api.request(`/entities/${id}`, {\r\n method: 'DELETE',\r\n });\r\n },\r\n },\r\n\r\n // --- IDEAS ---\r\n ideas: {\r\n async create(data: { projectId: string; title?: string; description?: string; status?: string; category?: string }) {\r\n return api.request('/ideas', {\r\n method: 'POST',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async update(id: string, data: any) {\r\n return api.request(`/ideas/${id}`, {\r\n method: 'PUT',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async delete(id: string) {\r\n return api.request(`/ideas/${id}`, {\r\n method: 'DELETE',\r\n });\r\n },\r\n },\r\n\r\n // --- AI (server-side via API routes) ---\r\n ai: {\r\n async generate(project: BookProject, chapterId: string, prompt: string, user: UserProfile) {\r\n return api.request<{ text: string; type: 'draft' | 'reflection' }>('/ai/generate', {\r\n method: 'POST',\r\n body: JSON.stringify({ project, chapterId, prompt, user }),\r\n });\r\n },\r\n\r\n async transform(text: string, mode: string, context: string, user: UserProfile) {\r\n const res = await api.request<{ text: string }>('/ai/transform', {\r\n method: 'POST',\r\n body: JSON.stringify({ text, mode, context, user }),\r\n });\r\n return res.text;\r\n },\r\n },\r\n};\r\n\r\nexport default api;\r\n"],"names":[],"mappings":";;;;AAEA,MAAM,eAAe;AAErB,qBAAqB;AAErB,MAAM,MAAM;IACR,MAAM,SAAiB,QAAgB,EAAE,UAAuB,CAAC,CAAC;QAC9D,MAAM,MAAM,GAAG,eAAe,UAAU;QAExC,MAAM,UAAkC;YACpC,gBAAgB;YAChB,GAAG,QAAQ,OAAO;QACtB;QAEA,MAAM,WAAW,MAAM,MAAM,KAAK;YAC9B,GAAG,OAAO;YACV;QACJ;QAEA,IAAI,CAAC,SAAS,EAAE,EAAE;YACd,IAAI,WAAW,CAAC,MAAM,EAAE,SAAS,MAAM,CAAC,EAAE,EAAE,SAAS,UAAU,EAAE;YACjE,IAAI;gBACA,MAAM,YAAY,MAAM,SAAS,IAAI;gBACrC,IAAI,UAAU,KAAK,EAAE,WAAW,UAAU,KAAK;gBAC/C,IAAI,UAAU,OAAO,EAAE,WAAW,UAAU,OAAO;YACvD,EAAE,OAAM;YACJ,0BAA0B;YAC9B;YACA,MAAM,IAAI,MAAM;QACpB;QAEA,IAAI,SAAS,MAAM,KAAK,KAAK,OAAO;QACpC,OAAO,SAAS,IAAI;IACxB;IAEA,eAAe;IACf,MAAM;QACF,MAAM,UAAS,KAAa,EAAE,QAAgB,EAAE,IAAY;YACxD,OAAO,IAAI,OAAO,CAAC,kBAA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M;oBAAS;gBAAK;YACrD;YACA,OAAO,IAAI,IAAI;QACnB;IACJ;AACJ;uCAEe"}}, - {"offset": {"line": 175, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/src/hooks/useAuth.ts"],"sourcesContent":["'use client';\r\n\r\nimport { useState, useEffect, useCallback } from 'react';\r\nimport { signIn, signOut, useSession } from 'next-auth/react';\r\nimport { UserProfile } from '@/lib/types';\r\nimport api from '@/lib/api';\r\n\r\nexport const useAuth = () => {\r\n const { data: session, status } = useSession();\r\n const [user, setUser] = useState(null);\r\n const loading = status === 'loading';\r\n\r\n // Fetch real profile from DB when session is available\r\n useEffect(() => {\r\n if (session?.user?.id) {\r\n fetch('/api/user/profile', { cache: 'no-store' })\r\n .then(res => res.json())\r\n .then(dbUser => {\r\n const planId = dbUser.plan || 'free';\r\n const planDetails = dbUser.planDetails || {\r\n id: 'free',\r\n displayName: 'Gratuit',\r\n maxAiActions: 100,\r\n maxProjects: 3\r\n };\r\n\r\n setUser({\r\n id: dbUser.id,\r\n email: dbUser.email,\r\n name: dbUser.name || 'User',\r\n avatar: dbUser.avatar,\r\n bio: dbUser.bio,\r\n subscription: {\r\n plan: planId,\r\n planDetails: planDetails,\r\n startDate: new Date(dbUser.createdAt).getTime(),\r\n status: 'active'\r\n },\r\n usage: {\r\n aiActionsCurrent: dbUser.aiActionsUsed || 0,\r\n aiActionsLimit: planDetails.maxAiActions,\r\n projectsLimit: planDetails.maxProjects,\r\n },\r\n preferences: { theme: 'light', dailyWordGoal: dbUser.dailyWordGoal || 500, language: 'fr' },\r\n stats: {\r\n totalWordsWritten: dbUser.totalWords || 0,\r\n writingStreak: dbUser.writingStreak || 0,\r\n lastWriteDate: dbUser.lastWriteDate ? new Date(dbUser.lastWriteDate).getTime() : 0,\r\n },\r\n });\r\n })\r\n .catch(err => {\r\n console.error('Failed to fetch user profile:', err);\r\n // Fallback to session data\r\n setUser({\r\n id: session.user.id || '',\r\n email: session.user.email || '',\r\n name: session.user.name || 'User',\r\n subscription: { plan: 'free', startDate: Date.now(), status: 'active' },\r\n usage: { aiActionsCurrent: 0, aiActionsLimit: 100, projectsLimit: 3 },\r\n preferences: { theme: 'light', dailyWordGoal: 500, language: 'fr' },\r\n stats: { totalWordsWritten: 0, writingStreak: 0, lastWriteDate: 0 },\r\n });\r\n });\r\n } else if (status === 'unauthenticated') {\r\n setUser(null);\r\n }\r\n }, [session, status]);\r\n\r\n const login = useCallback(async (email: string, password: string) => {\r\n const result = await signIn('credentials', {\r\n email,\r\n password,\r\n redirect: false,\r\n });\r\n\r\n if (result?.error) {\r\n throw new Error(result.error === 'CredentialsSignin'\r\n ? 'Email ou mot de passe incorrect'\r\n : result.error\r\n );\r\n }\r\n }, []);\r\n\r\n const signup = useCallback(async (email: string, password: string, name: string) => {\r\n await api.auth.register(email, password, name);\r\n const result = await signIn('credentials', {\r\n email,\r\n password,\r\n redirect: false,\r\n });\r\n if (result?.error) {\r\n throw new Error('Compte créé mais erreur de connexion automatique');\r\n }\r\n }, []);\r\n\r\n const logout = useCallback(async () => {\r\n await signOut({ redirect: false });\r\n setUser(null);\r\n }, []);\r\n\r\n const incrementUsage = useCallback((serverCount?: number) => {\r\n if (user) {\r\n setUser({\r\n ...user,\r\n usage: {\r\n ...user.usage,\r\n aiActionsCurrent: serverCount !== undefined ? serverCount : user.usage.aiActionsCurrent + 1,\r\n },\r\n });\r\n }\r\n }, [user]);\r\n\r\n return { user, login, signup, logout, incrementUsage, loading };\r\n};\r\n"],"names":[],"mappings":";;;;AAEA;AACA;AAEA;;AALA;;;;AAOO,MAAM,UAAU;;IACnB,MAAM,EAAE,MAAM,OAAO,EAAE,MAAM,EAAE,GAAG,IAAA,kMAAU;IAC5C,MAAM,CAAC,MAAM,QAAQ,GAAG,IAAA,qNAAQ,EAAqB;IACrD,MAAM,UAAU,WAAW;IAE3B,uDAAuD;IACvD,IAAA,sNAAS;6BAAC;YACN,IAAI,SAAS,MAAM,IAAI;g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3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/src/providers/AuthProvider.tsx"],"sourcesContent":["'use client';\r\n\r\nimport React, { createContext, useContext } from 'react';\r\nimport { SessionProvider } from 'next-auth/react';\r\nimport { useAuth } from '@/hooks/useAuth';\r\n\r\nconst AuthContext = createContext(null);\r\n\r\nfunction AuthInner({ children }: { children: React.ReactNode }) {\r\n const auth = useAuth();\r\n return {children};\r\n}\r\n\r\nexport const AuthProvider: React.FC<{ children: React.ReactNode }> = ({ children }) => {\r\n return (\r\n \r\n {children}\r\n \r\n );\r\n};\r\n\r\nexport function useAuthContext() {\r\n return useContext(AuthContext);\r\n}\r\n"],"names":[],"mappings":";;;;;;;AAEA;AACA;AACA;;;AAJA;;;;AAMA,MAAM,4BAAc,IAAA,0NAAa,EAAM;AAEvC,SAAS,UAAU,EAAE,QAAQ,EAAiC;;IAC1D,MAAM,OAAO,IAAA,iLAAO;IACpB,qBAAO,yOAAC,YAAY,QAAQ;QAAC,OAAO;kBAAO;;;;;;AAC/C;GAHS;;QACQ,iLAAO;;;KADf;AAKF,MAAM,eAAwD,CAAC,EAAE,QAAQ,EAAE;IAC9E,qBACI,yOAAC,uMAAe;kBACZ,cAAA,yOAAC;sBAAW;;;;;;;;;;;AAGxB;MANa;AAQN,SAAS;;IACZ,OAAO,IAAA,uNAAU,EAAC;AACtB;IAFgB"}}, - {"offset": {"line": 412, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/node_modules/next/dist/compiled/react/cjs/react-jsx-dev-runtime.development.js"],"sourcesContent":["/**\n * @license React\n * react-jsx-dev-runtime.development.js\n *\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n\"use strict\";\n\"production\" !== process.env.NODE_ENV &&\n (function () {\n function getComponentNameFromType(type) {\n if (null == type) return null;\n if (\"function\" === typeof type)\n return type.$$typeof === REACT_CLIENT_REFERENCE\n ? null\n : type.displayName || type.name || null;\n if (\"string\" === typeof type) return type;\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n return \"Fragment\";\n case REACT_PROFILER_TYPE:\n return \"Profiler\";\n case REACT_STRICT_MODE_TYPE:\n return \"StrictMode\";\n case REACT_SUSPENSE_TYPE:\n return \"Suspense\";\n case REACT_SUSPENSE_LIST_TYPE:\n return \"SuspenseList\";\n case REACT_ACTIVITY_TYPE:\n return \"Activity\";\n case REACT_VIEW_TRANSITION_TYPE:\n return \"ViewTransition\";\n }\n if (\"object\" === typeof type)\n switch (\n (\"number\" === typeof type.tag &&\n console.error(\n \"Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue.\"\n ),\n type.$$typeof)\n ) {\n case REACT_PORTAL_TYPE:\n return \"Portal\";\n case REACT_CONTEXT_TYPE:\n return type.displayName || \"Context\";\n case REACT_CONSUMER_TYPE:\n return (type._context.displayName || \"Context\") + \".Consumer\";\n case REACT_FORWARD_REF_TYPE:\n var innerType = type.render;\n type = type.displayName;\n type ||\n ((type = innerType.displayName || innerType.name || \"\"),\n (type = \"\" !== type ? \"ForwardRef(\" + type + \")\" : \"ForwardRef\"));\n return type;\n case REACT_MEMO_TYPE:\n return (\n (innerType = type.displayName || null),\n null !== innerType\n ? innerType\n : getComponentNameFromType(type.type) || \"Memo\"\n );\n case REACT_LAZY_TYPE:\n innerType = type._payload;\n type = type._init;\n try {\n return getComponentNameFromType(type(innerType));\n } catch (x) {}\n }\n return null;\n }\n function testStringCoercion(value) {\n return \"\" + value;\n }\n function checkKeyStringCoercion(value) {\n try {\n testStringCoercion(value);\n var JSCompiler_inline_result = !1;\n } catch (e) {\n JSCompiler_inline_result = !0;\n }\n if (JSCompiler_inline_result) {\n JSCompiler_inline_result = console;\n var JSCompiler_temp_const = JSCompiler_inline_result.error;\n var JSCompiler_inline_result$jscomp$0 =\n (\"function\" === typeof Symbol &&\n Symbol.toStringTag &&\n value[Symbol.toStringTag]) ||\n value.constructor.name ||\n \"Object\";\n JSCompiler_temp_const.call(\n JSCompiler_inline_result,\n \"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.\",\n JSCompiler_inline_result$jscomp$0\n );\n return testStringCoercion(value);\n }\n }\n function getTaskName(type) {\n if (type === REACT_FRAGMENT_TYPE) return \"<>\";\n if (\n \"object\" === typeof type &&\n null !== type &&\n type.$$typeof === REACT_LAZY_TYPE\n )\n return \"<...>\";\n try {\n var name = getComponentNameFromType(type);\n return name ? \"<\" + name + \">\" : \"<...>\";\n } catch (x) {\n return \"<...>\";\n }\n }\n function getOwner() {\n var dispatcher = ReactSharedInternals.A;\n return null === dispatcher ? null : dispatcher.getOwner();\n }\n function UnknownOwner() {\n return Error(\"react-stack-top-frame\");\n }\n function hasValidKey(config) {\n if (hasOwnProperty.call(config, \"key\")) {\n var getter = Object.getOwnPropertyDescriptor(config, \"key\").get;\n if (getter && getter.isReactWarning) return !1;\n }\n return void 0 !== config.key;\n }\n function defineKeyPropWarningGetter(props, displayName) {\n function warnAboutAccessingKey() {\n specialPropKeyWarningShown ||\n ((specialPropKeyWarningShown = !0),\n console.error(\n \"%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)\",\n displayName\n ));\n }\n warnAboutAccessingKey.isReactWarning = !0;\n Object.defineProperty(props, \"key\", {\n get: warnAboutAccessingKey,\n configurable: !0\n });\n }\n function elementRefGetterWithDeprecationWarning() {\n var componentName = getComponentNameFromType(this.type);\n didWarnAboutElementRef[componentName] ||\n ((didWarnAboutElementRef[componentName] = !0),\n console.error(\n \"Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release.\"\n ));\n componentName = this.props.ref;\n return void 0 !== componentName ? componentName : null;\n }\n function ReactElement(type, key, props, owner, debugStack, debugTask) {\n var refProp = props.ref;\n type = {\n $$typeof: REACT_ELEMENT_TYPE,\n type: type,\n key: key,\n props: props,\n _owner: owner\n };\n null !== (void 0 !== refProp ? refProp : null)\n ? Object.defineProperty(type, \"ref\", {\n enumerable: !1,\n get: elementRefGetterWithDeprecationWarning\n })\n : Object.defineProperty(type, \"ref\", { enumerable: !1, value: null });\n type._store = {};\n Object.defineProperty(type._store, \"validated\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: 0\n });\n Object.defineProperty(type, \"_debugInfo\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: null\n });\n Object.defineProperty(type, \"_debugStack\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: debugStack\n });\n Object.defineProperty(type, \"_debugTask\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: debugTask\n });\n Object.freeze && (Object.freeze(type.props), Object.freeze(type));\n return type;\n }\n function jsxDEVImpl(\n type,\n config,\n maybeKey,\n isStaticChildren,\n debugStack,\n debugTask\n ) {\n var children = config.children;\n if (void 0 !== children)\n if (isStaticChildren)\n if (isArrayImpl(children)) {\n for (\n isStaticChildren = 0;\n isStaticChildren < children.length;\n isStaticChildren++\n )\n validateChildKeys(children[isStaticChildren]);\n Object.freeze && Object.freeze(children);\n } else\n console.error(\n \"React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.\"\n );\n else validateChildKeys(children);\n if (hasOwnProperty.call(config, \"key\")) {\n children = getComponentNameFromType(type);\n var keys = Object.keys(config).filter(function (k) {\n return \"key\" !== k;\n });\n isStaticChildren =\n 0 < keys.length\n ? \"{key: someKey, \" + keys.join(\": ..., \") + \": ...}\"\n : \"{key: someKey}\";\n didWarnAboutKeySpread[children + isStaticChildren] ||\n ((keys =\n 0 < keys.length ? \"{\" + keys.join(\": ..., \") + \": ...}\" : \"{}\"),\n console.error(\n 'A props object containing a \"key\" prop is being spread into JSX:\\n let props = %s;\\n <%s {...props} />\\nReact keys must be passed directly to JSX without using spread:\\n let props = %s;\\n <%s key={someKey} {...props} />',\n isStaticChildren,\n children,\n keys,\n children\n ),\n (didWarnAboutKeySpread[children + isStaticChildren] = !0));\n }\n children = null;\n void 0 !== maybeKey &&\n (checkKeyStringCoercion(maybeKey), (children = \"\" + maybeKey));\n hasValidKey(config) &&\n (checkKeyStringCoercion(config.key), (children = \"\" + config.key));\n if (\"key\" in config) {\n maybeKey = {};\n for (var propName in config)\n \"key\" !== propName && (maybeKey[propName] = config[propName]);\n } else maybeKey = config;\n children &&\n defineKeyPropWarningGetter(\n maybeKey,\n \"function\" === typeof type\n ? type.displayName || type.name || \"Unknown\"\n : type\n );\n return ReactElement(\n type,\n children,\n maybeKey,\n getOwner(),\n debugStack,\n debugTask\n );\n }\n function validateChildKeys(node) {\n isValidElement(node)\n ? node._store && (node._store.validated = 1)\n : \"object\" === typeof node &&\n null !== node &&\n node.$$typeof === REACT_LAZY_TYPE &&\n (\"fulfilled\" === node._payload.status\n ? isValidElement(node._payload.value) &&\n node._payload.value._store &&\n (node._payload.value._store.validated = 1)\n : node._store && (node._store.validated = 1));\n }\n function isValidElement(object) {\n return (\n \"object\" === typeof object &&\n null !== object &&\n object.$$typeof === REACT_ELEMENT_TYPE\n );\n }\n var React = require(\"next/dist/compiled/react\"),\n REACT_ELEMENT_TYPE = Symbol.for(\"react.transitional.element\"),\n REACT_PORTAL_TYPE = Symbol.for(\"react.portal\"),\n REACT_FRAGMENT_TYPE = Symbol.for(\"react.fragment\"),\n REACT_STRICT_MODE_TYPE = Symbol.for(\"react.strict_mode\"),\n REACT_PROFILER_TYPE = Symbol.for(\"react.profiler\"),\n REACT_CONSUMER_TYPE = Symbol.for(\"react.consumer\"),\n REACT_CONTEXT_TYPE = Symbol.for(\"react.context\"),\n REACT_FORWARD_REF_TYPE = Symbol.for(\"react.forward_ref\"),\n REACT_SUSPENSE_TYPE = Symbol.for(\"react.suspense\"),\n REACT_SUSPENSE_LIST_TYPE = Symbol.for(\"react.suspense_list\"),\n REACT_MEMO_TYPE = Symbol.for(\"react.memo\"),\n REACT_LAZY_TYPE = Symbol.for(\"react.lazy\"),\n REACT_ACTIVITY_TYPE = Symbol.for(\"react.activity\"),\n REACT_VIEW_TRANSITION_TYPE = Symbol.for(\"react.view_transition\"),\n REACT_CLIENT_REFERENCE = Symbol.for(\"react.client.reference\"),\n ReactSharedInternals =\n React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,\n hasOwnProperty = Object.prototype.hasOwnProperty,\n isArrayImpl = Array.isArray,\n createTask = console.createTask\n ? console.createTask\n : function () {\n return null;\n };\n React = {\n react_stack_bottom_frame: function (callStackForError) {\n return callStackForError();\n }\n };\n var specialPropKeyWarningShown;\n var didWarnAboutElementRef = {};\n var unknownOwnerDebugStack = React.react_stack_bottom_frame.bind(\n React,\n UnknownOwner\n )();\n var unknownOwnerDebugTask = createTask(getTaskName(UnknownOwner));\n var didWarnAboutKeySpread = {};\n exports.Fragment = REACT_FRAGMENT_TYPE;\n exports.jsxDEV = function (type, config, maybeKey, isStaticChildren) {\n var trackActualOwner =\n 1e4 > ReactSharedInternals.recentlyCreatedOwnerStacks++;\n if (trackActualOwner) {\n var previousStackTraceLimit = Error.stackTraceLimit;\n Error.stackTraceLimit = 10;\n var debugStackDEV = Error(\"react-stack-top-frame\");\n Error.stackTraceLimit = previousStackTraceLimit;\n } else debugStackDEV = unknownOwnerDebugStack;\n return jsxDEVImpl(\n type,\n config,\n maybeKey,\n isStaticChildren,\n debugStackDEV,\n trackActualOwner ? createTask(getTaskName(type)) : unknownOwnerDebugTask\n );\n };\n })();\n"],"names":[],"mappings":"AAWiB;AAXjB;;;;;;;;CAQC,GAED;AACA,oEACE,AAAC;IACC,SAAS,yBAAyB,IAAI;QACpC,IAAI,QAAQ,MAAM,OAAO;QACzB,IAAI,eAAe,OAAO,MACxB,OAAO,KAAK,QAAQ,KAAK,yBACrB,OACA,KAAK,WAAW,IAAI,KAAK,IAAI,IAAI;QACvC,IAAI,aAAa,OAAO,MAAM,OAAO;QACrC,OAAQ;YACN,KAAK;gBAC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;YACnD,MAAM,eAAe,GAAG;YACxB,IAAI,gBAAgB,MAAM;YAC1B,MAAM,eAAe,GAAG;QAC1B,OAAO,gBAAgB;QACvB,OAAO,WACL,MACA,QACA,UACA,kBACA,eACA,mBAAmB,WAAW,YAAY,SAAS;IAEvD;AACF","ignoreList":[0]}}, - {"offset": {"line": 628, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/node_modules/next/dist/compiled/react/jsx-dev-runtime.js"],"sourcesContent":["'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-jsx-dev-runtime.production.js');\n} else {\n module.exports = require('./cjs/react-jsx-dev-runtime.development.js');\n}\n"],"names":[],"mappings":"AAEI;AAFJ;AAEA;;KAEO;IACL,OAAO,OAAO;AAChB","ignoreList":[0]}}, - {"offset": {"line": 639, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/node_modules/%40auth/core/errors.js"],"sourcesContent":["/**\n * Base error class for all Auth.js errors.\n * It's optimized to be printed in the server logs in a nicely formatted way\n * via the [`logger.error`](https://authjs.dev/reference/core#logger) option.\n * @noInheritDoc\n */\nexport class AuthError extends Error {\n /** @internal */\n constructor(message, errorOptions) {\n if (message instanceof Error) {\n super(undefined, {\n cause: { err: message, ...message.cause, ...errorOptions },\n });\n }\n else if (typeof message === \"string\") {\n if (errorOptions instanceof Error) {\n errorOptions = { err: errorOptions, ...errorOptions.cause };\n }\n super(message, errorOptions);\n }\n else {\n super(undefined, message);\n }\n this.name = this.constructor.name;\n // @ts-expect-error https://github.com/microsoft/TypeScript/issues/3841\n this.type = this.constructor.type ?? \"AuthError\";\n // @ts-expect-error https://github.com/microsoft/TypeScript/issues/3841\n this.kind = this.constructor.kind ?? \"error\";\n Error.captureStackTrace?.(this, this.constructor);\n const url = `https://errors.authjs.dev#${this.type.toLowerCase()}`;\n this.message += `${this.message ? \". \" : \"\"}Read more at ${url}`;\n }\n}\n/**\n * Thrown when the user's sign-in attempt failed.\n * @noInheritDoc\n */\nexport class SignInError extends AuthError {\n}\n/** @internal */\nSignInError.kind = \"signIn\";\n/**\n * One of the database [`Adapter` methods](https://authjs.dev/reference/core/adapters#methods)\n * failed during execution.\n *\n * :::tip\n * If `debug: true` is set, you can check out `[auth][debug]` in the logs to learn more about the failed adapter method execution.\n * @example\n * ```sh\n * [auth][debug]: adapter_getUserByEmail\n * { \"args\": [undefined] }\n * ```\n * :::\n * @noInheritDoc\n */\nexport class AdapterError extends AuthError {\n}\nAdapterError.type = \"AdapterError\";\n/**\n * Thrown when the execution of the [`signIn` callback](https://authjs.dev/reference/core/types#signin) fails\n * or if it returns `false`.\n * @noInheritDoc\n */\nexport class AccessDenied extends AuthError {\n}\nAccessDenied.type = \"AccessDenied\";\n/**\n * This error occurs when the user cannot finish login.\n * Depending on the provider type, this could have happened for multiple reasons.\n *\n * :::tip\n * Check out `[auth][details]` in the logs to know which provider failed.\n * @example\n * ```sh\n * [auth][details]: { \"provider\": \"github\" }\n * ```\n * :::\n *\n * For an [OAuth provider](https://authjs.dev/getting-started/authentication/oauth), possible causes are:\n * - The user denied access to the application\n * - There was an error parsing the OAuth Profile:\n * Check out the provider's `profile` or `userinfo.request` method to make sure\n * it correctly fetches the user's profile.\n * - The `signIn` or `jwt` callback methods threw an uncaught error:\n * Check the callback method implementations.\n *\n * For an [Email provider](https://authjs.dev/getting-started/authentication/email), possible causes are:\n * - The provided email/token combination was invalid/missing:\n * Check if the provider's `sendVerificationRequest` method correctly sends the email.\n * - The provided email/token combination has expired:\n * Ask the user to log in again.\n * - There was an error with the database:\n * Check the database logs.\n *\n * For a [Credentials provider](https://authjs.dev/getting-started/authentication/credentials), possible causes are:\n * - The `authorize` method threw an uncaught error:\n * Check the provider's `authorize` method.\n * - The `signIn` or `jwt` callback methods threw an uncaught error:\n * Check the callback method implementations.\n *\n * :::tip\n * Check out `[auth][cause]` in the error message for more details.\n * It will show the original stack trace.\n * :::\n * @noInheritDoc\n */\nexport class CallbackRouteError extends AuthError {\n}\nCallbackRouteError.type = \"CallbackRouteError\";\n/**\n * Thrown when Auth.js is misconfigured and accidentally tried to require authentication on a custom error page.\n * To prevent an infinite loop, Auth.js will instead render its default error page.\n *\n * To fix this, make sure that the `error` page does not require authentication.\n *\n * Learn more at [Guide: Error pages](https://authjs.dev/guides/pages/error)\n * @noInheritDoc\n */\nexport class ErrorPageLoop extends AuthError {\n}\nErrorPageLoop.type = \"ErrorPageLoop\";\n/**\n * One of the [`events` methods](https://authjs.dev/reference/core/types#eventcallbacks)\n * failed during execution.\n *\n * Make sure that the `events` methods are implemented correctly and uncaught errors are handled.\n *\n * Learn more at [`events`](https://authjs.dev/reference/core/types#eventcallbacks)\n * @noInheritDoc\n */\nexport class EventError extends AuthError {\n}\nEventError.type = \"EventError\";\n/**\n * Thrown when Auth.js is unable to verify a `callbackUrl` value.\n * The browser either disabled cookies or the `callbackUrl` is not a valid URL.\n *\n * Somebody might have tried to manipulate the callback URL that Auth.js uses to redirect the user back to the configured `callbackUrl`/page.\n * This could be a malicious hacker trying to redirect the user to a phishing site.\n * To prevent this, Auth.js checks if the callback URL is valid and throws this error if it is not.\n *\n * There is no action required, but it might be an indicator that somebody is trying to attack your application.\n * @noInheritDoc\n */\nexport class InvalidCallbackUrl extends AuthError {\n}\nInvalidCallbackUrl.type = \"InvalidCallbackUrl\";\n/**\n * Can be thrown from the `authorize` callback of the Credentials provider.\n * When an error occurs during the `authorize` callback, two things can happen:\n * 1. The user is redirected to the signin page, with `error=CredentialsSignin&code=credentials` in the URL. `code` is configurable.\n * 2. If you throw this error in a framework that handles form actions server-side, this error is thrown, instead of redirecting the user, so you'll need to handle.\n * @noInheritDoc\n */\nexport class CredentialsSignin extends SignInError {\n constructor() {\n super(...arguments);\n /**\n * The error code that is set in the `code` query parameter of the redirect URL.\n *\n *\n * ⚠ NOTE: This property is going to be included in the URL, so make sure it does not hint at sensitive errors.\n *\n * The full error is always logged on the server, if you need to debug.\n *\n * Generally, we don't recommend hinting specifically if the user had either a wrong username or password specifically,\n * try rather something like \"Invalid credentials\".\n */\n this.code = \"credentials\";\n }\n}\nCredentialsSignin.type = \"CredentialsSignin\";\n/**\n * One of the configured OAuth or OIDC providers is missing the `authorization`, `token` or `userinfo`, or `issuer` configuration.\n * To perform OAuth or OIDC sign in, at least one of these endpoints is required.\n *\n * Learn more at [`OAuth2Config`](https://authjs.dev/reference/core/providers#oauth2configprofile) or [Guide: OAuth Provider](https://authjs.dev/guides/configuring-oauth-providers)\n * @noInheritDoc\n */\nexport class InvalidEndpoints extends AuthError {\n}\nInvalidEndpoints.type = \"InvalidEndpoints\";\n/**\n * Thrown when a PKCE, state or nonce OAuth check could not be performed.\n * This could happen if the OAuth provider is configured incorrectly or if the browser is blocking cookies.\n *\n * Learn more at [`checks`](https://authjs.dev/reference/core/providers#checks)\n * @noInheritDoc\n */\nexport class InvalidCheck extends AuthError {\n}\nInvalidCheck.type = \"InvalidCheck\";\n/**\n * Logged on the server when Auth.js could not decode or encode a JWT-based (`strategy: \"jwt\"`) session.\n *\n * Possible causes are either a misconfigured `secret` or a malformed JWT or `encode/decode` methods.\n *\n * :::note\n * When this error is logged, the session cookie is destroyed.\n * :::\n *\n * Learn more at [`secret`](https://authjs.dev/reference/core#secret), [`jwt.encode`](https://authjs.dev/reference/core/jwt#encode-1) or [`jwt.decode`](https://authjs.dev/reference/core/jwt#decode-2) for more information.\n * @noInheritDoc\n */\nexport class JWTSessionError extends AuthError {\n}\nJWTSessionError.type = \"JWTSessionError\";\n/**\n * Thrown if Auth.js is misconfigured. This could happen if you configured an Email provider but did not set up a database adapter,\n * or tried using a `strategy: \"database\"` session without a database adapter.\n * In both cases, make sure you either remove the configuration or add the missing adapter.\n *\n * Learn more at [Database Adapters](https://authjs.dev/getting-started/database), [Email provider](https://authjs.dev/getting-started/authentication/email) or [Concept: Database session strategy](https://authjs.dev/concepts/session-strategies#database-session)\n * @noInheritDoc\n */\nexport class MissingAdapter extends AuthError {\n}\nMissingAdapter.type = \"MissingAdapter\";\n/**\n * Thrown similarily to [`MissingAdapter`](https://authjs.dev/reference/core/errors#missingadapter), but only some required methods were missing.\n *\n * Make sure you either remove the configuration or add the missing methods to the adapter.\n *\n * Learn more at [Database Adapters](https://authjs.dev/getting-started/database)\n * @noInheritDoc\n */\nexport class MissingAdapterMethods extends AuthError {\n}\nMissingAdapterMethods.type = \"MissingAdapterMethods\";\n/**\n * Thrown when a Credentials provider is missing the `authorize` configuration.\n * To perform credentials sign in, the `authorize` method is required.\n *\n * Learn more at [Credentials provider](https://authjs.dev/getting-started/authentication/credentials)\n * @noInheritDoc\n */\nexport class MissingAuthorize extends AuthError {\n}\nMissingAuthorize.type = \"MissingAuthorize\";\n/**\n * Auth.js requires a secret or multiple secrets to be set, but none was not found. This is used to encrypt cookies, JWTs and other sensitive data.\n *\n * :::note\n * If you are using a framework like Next.js, we try to automatically infer the secret from the `AUTH_SECRET`, `AUTH_SECRET_1`, etc. environment variables.\n * Alternatively, you can also explicitly set the [`AuthConfig.secret`](https://authjs.dev/reference/core#secret) option.\n * :::\n *\n *\n * :::tip\n * To generate a random string, you can use the Auth.js CLI: `npx auth secret`\n * :::\n * @noInheritDoc\n */\nexport class MissingSecret extends AuthError {\n}\nMissingSecret.type = \"MissingSecret\";\n/**\n * Thrown when an Email address is already associated with an account\n * but the user is trying an OAuth account that is not linked to it.\n *\n * For security reasons, Auth.js does not automatically link OAuth accounts to existing accounts if the user is not signed in.\n *\n * :::tip\n * If you trust the OAuth provider to have verified the user's email address,\n * you can enable automatic account linking by setting [`allowDangerousEmailAccountLinking: true`](https://authjs.dev/reference/core/providers#allowdangerousemailaccountlinking)\n * in the provider configuration.\n * :::\n * @noInheritDoc\n */\nexport class OAuthAccountNotLinked extends SignInError {\n}\nOAuthAccountNotLinked.type = \"OAuthAccountNotLinked\";\n/**\n * Thrown when an OAuth provider returns an error during the sign in process.\n * This could happen for example if the user denied access to the application or there was a configuration error.\n *\n * For a full list of possible reasons, check out the specification [Authorization Code Grant: Error Response](https://www.rfc-editor.org/rfc/rfc6749#section-4.1.2.1)\n * @noInheritDoc\n */\nexport class OAuthCallbackError extends SignInError {\n}\nOAuthCallbackError.type = \"OAuthCallbackError\";\n/**\n * This error occurs during an OAuth sign in attempt when the provider's\n * response could not be parsed. This could for example happen if the provider's API\n * changed, or the [`OAuth2Config.profile`](https://authjs.dev/reference/core/providers#oauth2configprofile) method is not implemented correctly.\n * @noInheritDoc\n */\nexport class OAuthProfileParseError extends AuthError {\n}\nOAuthProfileParseError.type = \"OAuthProfileParseError\";\n/**\n * Logged on the server when Auth.js could not retrieve a session from the database (`strategy: \"database\"`).\n *\n * The database adapter might be misconfigured or the database is not reachable.\n *\n * Learn more at [Concept: Database session strategy](https://authjs.dev/concepts/session-strategies#database)\n * @noInheritDoc\n */\nexport class SessionTokenError extends AuthError {\n}\nSessionTokenError.type = \"SessionTokenError\";\n/**\n * Happens when login by [OAuth](https://authjs.dev/getting-started/authentication/oauth) could not be started.\n *\n * Possible causes are:\n * - The Authorization Server is not compliant with the [OAuth 2.0](https://www.ietf.org/rfc/rfc6749.html) or the [OIDC](https://openid.net/specs/openid-connect-core-1_0.html) specification.\n * Check the details in the error message.\n *\n * :::tip\n * Check out `[auth][details]` in the logs to know which provider failed.\n * @example\n * ```sh\n * [auth][details]: { \"provider\": \"github\" }\n * ```\n * :::\n * @noInheritDoc\n */\nexport class OAuthSignInError extends SignInError {\n}\nOAuthSignInError.type = \"OAuthSignInError\";\n/**\n * Happens when the login by an [Email provider](https://authjs.dev/getting-started/authentication/email) could not be started.\n *\n * Possible causes are:\n * - The email sent from the client is invalid, could not be normalized by [`EmailConfig.normalizeIdentifier`](https://authjs.dev/reference/core/providers/email#normalizeidentifier)\n * - The provided email/token combination has expired:\n * Ask the user to log in again.\n * - There was an error with the database:\n * Check the database logs.\n * @noInheritDoc\n */\nexport class EmailSignInError extends SignInError {\n}\nEmailSignInError.type = \"EmailSignInError\";\n/**\n * Represents an error that occurs during the sign-out process. This error\n * is logged when there are issues in terminating a user's session, either\n * by failing to delete the session from the database (in database session\n * strategies) or encountering issues during other parts of the sign-out\n * process, such as emitting sign-out events or clearing session cookies.\n *\n * The session cookie(s) are emptied even if this error is logged.\n * @noInheritDoc\n */\nexport class SignOutError extends AuthError {\n}\nSignOutError.type = \"SignOutError\";\n/**\n * Auth.js was requested to handle an operation that it does not support.\n *\n * See [`AuthAction`](https://authjs.dev/reference/core/types#authaction) for the supported actions.\n * @noInheritDoc\n */\nexport class UnknownAction extends AuthError {\n}\nUnknownAction.type = \"UnknownAction\";\n/**\n * Thrown when a Credentials provider is present but the JWT strategy (`strategy: \"jwt\"`) is not enabled.\n *\n * Learn more at [`strategy`](https://authjs.dev/reference/core#strategy) or [Credentials provider](https://authjs.dev/getting-started/authentication/credentials)\n * @noInheritDoc\n */\nexport class UnsupportedStrategy extends AuthError {\n}\nUnsupportedStrategy.type = \"UnsupportedStrategy\";\n/**\n * Thrown when an endpoint was incorrectly called without a provider, or with an unsupported provider.\n * @noInheritDoc\n */\nexport class InvalidProvider extends AuthError {\n}\nInvalidProvider.type = \"InvalidProvider\";\n/**\n * Thrown when the `trustHost` option was not set to `true`.\n *\n * Auth.js requires the `trustHost` option to be set to `true` since it's relying on the request headers' `host` value.\n *\n * :::note\n * Official Auth.js libraries might attempt to automatically set the `trustHost` option to `true` if the request is coming from a trusted host on a trusted platform.\n * :::\n *\n * Learn more at [`trustHost`](https://authjs.dev/reference/core#trusthost) or [Guide: Deployment](https://authjs.dev/getting-started/deployment)\n * @noInheritDoc\n */\nexport class UntrustedHost extends AuthError {\n}\nUntrustedHost.type = \"UntrustedHost\";\n/**\n * The user's email/token combination was invalid.\n * This could be because the email/token combination was not found in the database,\n * or because the token has expired. Ask the user to log in again.\n * @noInheritDoc\n */\nexport class Verification extends AuthError {\n}\nVerification.type = \"Verification\";\n/**\n * Error for missing CSRF tokens in client-side actions (`signIn`, `signOut`, `useSession#update`).\n * Thrown when actions lack the double submit cookie, essential for CSRF protection.\n *\n * CSRF ([Cross-Site Request Forgery](https://owasp.org/www-community/attacks/csrf))\n * is an attack leveraging authenticated user credentials for unauthorized actions.\n *\n * Double submit cookie pattern, a CSRF defense, requires matching values in a cookie\n * and request parameter. More on this at [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Glossary/CSRF).\n * @noInheritDoc\n */\nexport class MissingCSRF extends SignInError {\n}\nMissingCSRF.type = \"MissingCSRF\";\nconst clientErrors = new Set([\n \"CredentialsSignin\",\n \"OAuthAccountNotLinked\",\n \"OAuthCallbackError\",\n \"AccessDenied\",\n \"Verification\",\n \"MissingCSRF\",\n \"AccountNotLinked\",\n \"WebAuthnVerificationError\",\n]);\n/**\n * Used to only allow sending a certain subset of errors to the client.\n * Errors are always logged on the server, but to prevent leaking sensitive information,\n * only a subset of errors are sent to the client as-is.\n * @internal\n */\nexport function isClientError(error) {\n if (error instanceof AuthError)\n return clientErrors.has(error.type);\n return false;\n}\n/**\n * Thrown when multiple providers have `enableConditionalUI` set to `true`.\n * Only one provider can have this option enabled at a time.\n * @noInheritDoc\n */\nexport class DuplicateConditionalUI extends AuthError {\n}\nDuplicateConditionalUI.type = \"DuplicateConditionalUI\";\n/**\n * Thrown when a WebAuthn provider has `enableConditionalUI` set to `true` but no formField has `webauthn` in its autocomplete param.\n *\n * The `webauthn` autocomplete param is required for conditional UI to work.\n * @noInheritDoc\n */\nexport class MissingWebAuthnAutocomplete extends AuthError {\n}\nMissingWebAuthnAutocomplete.type = \"MissingWebAuthnAutocomplete\";\n/**\n * Thrown when a WebAuthn provider fails to verify a client response.\n * @noInheritDoc\n */\nexport class WebAuthnVerificationError extends AuthError {\n}\nWebAuthnVerificationError.type = \"WebAuthnVerificationError\";\n/**\n * Thrown when an Email address is already associated with an account\n * but the user is trying an account that is not linked to it.\n *\n * For security reasons, Auth.js does not automatically link accounts to existing accounts if the user is not signed in.\n * @noInheritDoc\n */\nexport class AccountNotLinked extends SignInError {\n}\nAccountNotLinked.type = \"AccountNotLinked\";\n/**\n * Thrown when an experimental feature is used but not enabled.\n * @noInheritDoc\n */\nexport class ExperimentalFeatureNotEnabled extends AuthError {\n}\nExperimentalFeatureNotEnabled.type = \"ExperimentalFeatureNotEnabled\";\n"],"names":[],"mappings":"AAAA;;;;;CAKC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACM,MAAM,kBAAkB;IAC3B,cAAc,GACd,YAAY,OAAO,EAAE,YAAY,CAAE;QAC/B,IAAI,mBAAmB,OAAO;YAC1B,KAAK,CAAC,WAAW;gBACb,OAAO;oBAAE,KAAK;oBAAS,GAAG,QAAQ,KAAK;oBAAE,GAAG,YAAY;gBAAC;YAC7D;QACJ,OACK,IAAI,OAAO,YAAY,UAAU;YAClC,IAAI,wBAAwB,OAAO;gBAC/B,eAAe;oBAAE,KAAK;oBAAc,GAAG,aAAa,KAAK;gBAAC;YAC9D;YACA,KAAK,CAAC,SAAS;QACnB,OACK;YACD,KAAK,CAAC,WAAW;QACrB;QACA,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,WAAW,CAAC,IAAI;QACjC,uEAAuE;QACvE,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,WAAW,CAAC,IAAI,IAAI;QACrC,uEAAuE;QACvE,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,WAAW,CAAC,IAAI,IAAI;QACrC,MAAM,iBAAiB,GAAG,IAAI,EAAE,IAAI,CAAC,WAAW;QAChD,MAAM,MAAM,CAAC,0BAA0B,EAAE,IAAI,CAAC,IAAI,CAAC,WAAW,IAAI;QAClE,IAAI,CAAC,OAAO,IAAI,GAAG,IAAI,CAAC,OAAO,GAAG,OAAO,GAAG,aAAa,EAAE,KAAK;IACpE;AACJ;AAKO,MAAM,oBAAoB;AACjC;AACA,cAAc,GACd,YAAY,IAAI,GAAG;AAeZ,MAAM,qBAAqB;AAClC;AACA,aAAa,IAAI,GAA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AM,wBAAwB;AACrC;AACA,gBAAgB,IAAI,GAAG;AAahB,MAAM,sBAAsB;AACnC;AACA,cAAc,IAAI,GAAG;AAOd,MAAM,qBAAqB;AAClC;AACA,aAAa,IAAI,GAAG;AAYb,MAAM,oBAAoB;AACjC;AACA,YAAY,IAAI,GAAG;AACnB,MAAM,eAAe,IAAI,IAAI;IACzB;IACA;IACA;IACA;IACA;IACA;IACA;IACA;CACH;AAOM,SAAS,cAAc,KAAK;IAC/B,IAAI,iBAAiB,WACjB,OAAO,aAAa,GAAG,CAAC,MAAM,IAAI;IACtC,OAAO;AACX;AAMO,MAAM,+BAA+B;AAC5C;AACA,uBAAuB,IAAI,GAAG;AAOvB,MAAM,oCAAoC;AACjD;AACA,4BAA4B,IAAI,GAAG;AAK5B,MAAM,kCAAkC;AAC/C;AACA,0BAA0B,IAAI,GAAG;AAQ1B,MAAM,yBAAyB;AACtC;AACA,iBAAiB,IAAI,GAAG;AAKjB,MAAM,sCAAsC;AACnD;AACA,8BAA8B,IAAI,GAAG","ignoreList":[0]}}, - {"offset": {"line": 878, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/node_modules/next-auth/lib/client.js"],"sourcesContent":["\"use client\";\nimport * as React from \"react\";\nimport { AuthError } from \"@auth/core/errors\";\n/** @todo */\nclass ClientFetchError extends AuthError {\n}\n/** @todo */\nexport class ClientSessionError extends AuthError {\n}\n// ------------------------ Internal ------------------------\n/**\n * If passed 'appContext' via getInitialProps() in _app.js\n * then get the req object from ctx and use that for the\n * req value to allow `fetchData` to\n * work seemlessly in getInitialProps() on server side\n * pages *and* in _app.js.\n * @internal\n */\nexport async function fetchData(path, __NEXTAUTH, logger, req = {}) {\n const url = `${apiBaseUrl(__NEXTAUTH)}/${path}`;\n try {\n const options = {\n headers: {\n \"Content-Type\": \"application/json\",\n ...(req?.headers?.cookie ? { cookie: req.headers.cookie } : {}),\n },\n };\n if (req?.body) {\n options.body = JSON.stringify(req.body);\n options.method = \"POST\";\n }\n const res = await fetch(url, options);\n const data = await res.json();\n if (!res.ok)\n throw data;\n return data;\n }\n catch (error) {\n logger.error(new ClientFetchError(error.message, error));\n return null;\n }\n}\n/** @internal */\nexport function apiBaseUrl(__NEXTAUTH) {\n if (typeof window === \"undefined\") {\n // Return absolute path when called server side\n return `${__NEXTAUTH.baseUrlServer}${__NEXTAUTH.basePathServer}`;\n }\n // Return relative path when called client side\n return __NEXTAUTH.basePath;\n}\n/** @internal */\nexport function useOnline() {\n const [isOnline, setIsOnline] = React.useState(typeof navigator !== \"undefined\" ? navigator.onLine : false);\n const setOnline = () => setIsOnline(true);\n const setOffline = () => setIsOnline(false);\n React.useEffect(() => {\n window.addEventListener(\"online\", setOnline);\n window.addEventListener(\"offline\", setOffline);\n return () => {\n window.removeEventListener(\"online\", setOnline);\n window.removeEventListener(\"offline\", setOffline);\n };\n }, []);\n return isOnline;\n}\n/**\n * Returns the number of seconds elapsed since January 1, 1970 00:00:00 UTC.\n * @internal\n */\nexport function now() {\n return Math.floor(Date.now() / 1000);\n}\n/**\n * Returns an `URL` like object to make requests/redirects from server-side\n * @internal\n */\nexport function parseUrl(url) {\n const defaultUrl = new URL(\"http://localhost:3000/api/auth\");\n if (url && !url.startsWith(\"http\")) {\n url = `https://${url}`;\n }\n const _url = new URL(url || defaultUrl);\n const path = (_url.pathname === \"/\" ? defaultUrl.pathname : _url.pathname)\n // Remove trailing slash\n .replace(/\\/$/, \"\");\n const base = `${_url.origin}${path}`;\n return {\n origin: _url.origin,\n host: _url.host,\n path,\n base,\n toString: () => base,\n };\n}\n"],"names":[],"mappings":";;;;;;;;;;;;;;AACA;AACA;AAFA;;;AAGA,UAAU,GACV,MAAM,yBAAyB,oMAAS;AACxC;AAEO,MAAM,2BAA2B,oMAAS;AACjD;AAUO,eAAe,UAAU,IAAI,EAAE,UAAU,EAAE,MAAM,EAAE,MAAM,CAAC,CAAC;IAC9D,MAAM,MAAM,GAAG,WAAW,YAAY,CAAC,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AM,CAAC,QAAQ,EAAE,KAAK;IAC1B;IACA,MAAM,OAAO,IAAI,IAAI,OAAO;IAC5B,MAAM,OAAO,CAAC,KAAK,QAAQ,KAAK,MAAM,WAAW,QAAQ,GAAG,KAAK,QAAQ,CACrE,wBAAwB;KACvB,OAAO,CAAC,OAAO;IACpB,MAAM,OAAO,GAAG,KAAK,MAAM,GAAG,MAAM;IACpC,OAAO;QACH,QAAQ,KAAK,MAAM;QACnB,MAAM,KAAK,IAAI;QACf;QACA;QACA,UAAU,IAAM;IACpB;AACJ","ignoreList":[0]}}, - {"offset": {"line": 975, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/node_modules/next-auth/react.js"],"sourcesContent":["/**\n *\n * NextAuth.js is the official integration of Auth.js for Next.js applications. It supports both\n * [Client Components](https://nextjs.org/docs/app/building-your-application/rendering/client-components) and the\n * [Pages Router](https://nextjs.org/docs/pages). It includes methods for signing in, signing out, hooks, and a React\n * Context provider to wrap your application and make session data available anywhere.\n *\n * For use in [Server Actions](https://nextjs.org/docs/app/api-reference/functions/server-actions), check out [these methods](https://authjs.dev/guides/upgrade-to-v5#methods)\n *\n * @module react\n */\n\"use client\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport * as React from \"react\";\nimport { apiBaseUrl, ClientSessionError, fetchData, now, parseUrl, useOnline, } from \"./lib/client.js\";\n// This behaviour mirrors the default behaviour for getting the site name that\n// happens server side in server/index.js\n// 1. An empty value is legitimate when the code is being invoked client side as\n// relative URLs are valid in that context and so defaults to empty.\n// 2. When invoked server side the value is picked up from an environment\n// variable and defaults to 'http://localhost:3000'.\nexport const __NEXTAUTH = {\n baseUrl: parseUrl(process.env.NEXTAUTH_URL ?? process.env.VERCEL_URL).origin,\n basePath: parseUrl(process.env.NEXTAUTH_URL).path,\n baseUrlServer: parseUrl(process.env.NEXTAUTH_URL_INTERNAL ??\n process.env.NEXTAUTH_URL ??\n process.env.VERCEL_URL).origin,\n basePathServer: parseUrl(process.env.NEXTAUTH_URL_INTERNAL ?? process.env.NEXTAUTH_URL).path,\n _lastSync: 0,\n _session: undefined,\n _getSession: () => { },\n};\n// https://github.com/nextauthjs/next-auth/pull/10762\nlet broadcastChannel = null;\nfunction getNewBroadcastChannel() {\n if (typeof BroadcastChannel === \"undefined\") {\n return {\n postMessage: () => { },\n addEventListener: () => { },\n removeEventListener: () => { },\n name: \"next-auth\",\n onmessage: null,\n onmessageerror: null,\n close: () => { },\n dispatchEvent: () => false,\n };\n }\n return new BroadcastChannel(\"next-auth\");\n}\nfunction broadcast() {\n if (broadcastChannel === null) {\n broadcastChannel = getNewBroadcastChannel();\n }\n return broadcastChannel;\n}\n// TODO:\nconst logger = {\n debug: console.debug,\n error: console.error,\n warn: console.warn,\n};\nexport const SessionContext = React.createContext?.(undefined);\n/**\n * React Hook that gives you access to the logged in user's session data and lets you modify it.\n *\n * :::info\n * `useSession` is for client-side use only and when using [Next.js App Router (`app/`)](https://nextjs.org/blog/next-13-4#nextjs-app-router) you should prefer the `auth()` export.\n * :::\n */\nexport function useSession(options) {\n if (!SessionContext) {\n throw new Error(\"React Context is unavailable in Server Components\");\n }\n // @ts-expect-error Satisfy TS if branch on line below\n const value = React.useContext(SessionContext);\n if (!value && process.env.NODE_ENV !== \"production\") {\n throw new Error(\"[next-auth]: `useSession` must be wrapped in a \");\n }\n const { required, onUnauthenticated } = options ?? {};\n const requiredAndNotLoading = required && value.status === \"unauthenticated\";\n React.useEffect(() => {\n if (requiredAndNotLoading) {\n const url = `${__NEXTAUTH.basePath}/signin?${new URLSearchParams({\n error: \"SessionRequired\",\n callbackUrl: window.location.href,\n })}`;\n if (onUnauthenticated)\n onUnauthenticated();\n else\n window.location.href = url;\n }\n }, [requiredAndNotLoading, onUnauthenticated]);\n if (requiredAndNotLoading) {\n return {\n data: value.data,\n update: value.update,\n status: \"loading\",\n };\n }\n return value;\n}\nexport async function getSession(params) {\n const session = await fetchData(\"session\", __NEXTAUTH, logger, params);\n if (params?.broadcast ?? true) {\n // https://github.com/nextauthjs/next-auth/pull/11470\n getNewBroadcastChannel().postMessage({\n event: \"session\",\n data: { trigger: \"getSession\" },\n });\n }\n return session;\n}\n/**\n * Returns the current Cross-Site Request Forgery Token (CSRF Token)\n * required to make requests that changes state. (e.g. signing in or out, or updating the session).\n *\n * [CSRF Prevention: Double Submit Cookie](https://cheatsheetseries.owasp.org/cheatsheets/Cross-Site_Request_Forgery_Prevention_Cheat_Sheet.html#double-submit-cookie)\n */\nexport async function getCsrfToken() {\n const response = await fetchData(\"csrf\", __NEXTAUTH, logger);\n return response?.csrfToken ?? \"\";\n}\nexport async function getProviders() {\n return fetchData(\"providers\", __NEXTAUTH, logger);\n}\nexport async function signIn(provider, options, authorizationParams) {\n const { callbackUrl, ...rest } = options ?? {};\n const { redirect = true, redirectTo = callbackUrl ?? window.location.href, ...signInParams } = rest;\n const baseUrl = apiBaseUrl(__NEXTAUTH);\n const providers = await getProviders();\n if (!providers) {\n const url = `${baseUrl}/error`;\n window.location.href = url;\n return; // TODO: Return error if `redirect: false`\n }\n if (!provider || !providers[provider]) {\n const url = `${baseUrl}/signin?${new URLSearchParams({\n callbackUrl: redirectTo,\n })}`;\n window.location.href = url;\n return; // TODO: Return error if `redirect: false`\n }\n const providerType = providers[provider].type;\n if (providerType === \"webauthn\") {\n // TODO: Add docs link with explanation\n throw new TypeError([\n `Provider id \"${provider}\" refers to a WebAuthn provider.`,\n 'Please use `import { signIn } from \"next-auth/webauthn\"` instead.',\n ].join(\"\\n\"));\n }\n const signInUrl = `${baseUrl}/${providerType === \"credentials\" ? \"callback\" : \"signin\"}/${provider}`;\n const csrfToken = await getCsrfToken();\n const res = await fetch(`${signInUrl}?${new URLSearchParams(authorizationParams)}`, {\n method: \"post\",\n headers: {\n \"Content-Type\": \"application/x-www-form-urlencoded\",\n \"X-Auth-Return-Redirect\": \"1\",\n },\n body: new URLSearchParams({\n ...signInParams,\n csrfToken,\n callbackUrl: redirectTo,\n }),\n });\n const data = await res.json();\n if (redirect) {\n const url = data.url ?? redirectTo;\n window.location.href = url;\n // If url contains a hash, the browser does not reload the page. We reload manually\n if (url.includes(\"#\"))\n window.location.reload();\n return;\n }\n const error = new URL(data.url).searchParams.get(\"error\") ?? undefined;\n const code = new URL(data.url).searchParams.get(\"code\") ?? undefined;\n if (res.ok) {\n await __NEXTAUTH._getSession({ event: \"storage\" });\n }\n return {\n error,\n code,\n status: res.status,\n ok: res.ok,\n url: error ? null : data.url,\n };\n}\nexport async function signOut(options) {\n const { redirect = true, redirectTo = options?.callbackUrl ?? window.location.href, } = options ?? {};\n const baseUrl = apiBaseUrl(__NEXTAUTH);\n const csrfToken = await getCsrfToken();\n const res = await fetch(`${baseUrl}/signout`, {\n method: \"post\",\n headers: {\n \"Content-Type\": \"application/x-www-form-urlencoded\",\n \"X-Auth-Return-Redirect\": \"1\",\n },\n body: new URLSearchParams({ csrfToken, callbackUrl: redirectTo }),\n });\n const data = await res.json();\n broadcast().postMessage({ event: \"session\", data: { trigger: \"signout\" } });\n if (redirect) {\n const url = data.url ?? redirectTo;\n window.location.href = url;\n // If url contains a hash, the browser does not reload the page. We reload manually\n if (url.includes(\"#\"))\n window.location.reload();\n return;\n }\n await __NEXTAUTH._getSession({ event: \"storage\" });\n return data;\n}\n/**\n * [React Context](https://react.dev/learn/passing-data-deeply-with-context) provider to wrap the app (`pages/`) to make session data available anywhere.\n *\n * When used, the session state is automatically synchronized across all open tabs/windows and they are all updated whenever they gain or lose focus\n * or the state changes (e.g. a user signs in or out) when {@link SessionProviderProps.refetchOnWindowFocus} is `true`.\n *\n * :::info\n * `SessionProvider` is for client-side use only and when using [Next.js App Router (`app/`)](https://nextjs.org/blog/next-13-4#nextjs-app-router) you should prefer the `auth()` export.\n * :::\n */\nexport function SessionProvider(props) {\n if (!SessionContext) {\n throw new Error(\"React Context is unavailable in Server Components\");\n }\n const { children, basePath, refetchInterval, refetchWhenOffline } = props;\n if (basePath)\n __NEXTAUTH.basePath = basePath;\n /**\n * If session was `null`, there was an attempt to fetch it,\n * but it failed, but we still treat it as a valid initial value.\n */\n const hasInitialSession = props.session !== undefined;\n /** If session was passed, initialize as already synced */\n __NEXTAUTH._lastSync = hasInitialSession ? now() : 0;\n const [session, setSession] = React.useState(() => {\n if (hasInitialSession)\n __NEXTAUTH._session = props.session;\n return props.session;\n });\n /** If session was passed, initialize as not loading */\n const [loading, setLoading] = React.useState(!hasInitialSession);\n React.useEffect(() => {\n __NEXTAUTH._getSession = async ({ event } = {}) => {\n try {\n const storageEvent = event === \"storage\";\n // We should always update if we don't have a client session yet\n // or if there are events from other tabs/windows\n if (storageEvent || __NEXTAUTH._session === undefined) {\n __NEXTAUTH._lastSync = now();\n __NEXTAUTH._session = await getSession({\n broadcast: !storageEvent,\n });\n setSession(__NEXTAUTH._session);\n return;\n }\n if (\n // If there is no time defined for when a session should be considered\n // stale, then it's okay to use the value we have until an event is\n // triggered which updates it\n !event ||\n // If the client doesn't have a session then we don't need to call\n // the server to check if it does (if they have signed in via another\n // tab or window that will come through as a \"stroage\" event\n // event anyway)\n __NEXTAUTH._session === null ||\n // Bail out early if the client session is not stale yet\n now() < __NEXTAUTH._lastSync) {\n return;\n }\n // An event or session staleness occurred, update the client session.\n __NEXTAUTH._lastSync = now();\n __NEXTAUTH._session = await getSession();\n setSession(__NEXTAUTH._session);\n }\n catch (error) {\n logger.error(new ClientSessionError(error.message, error));\n }\n finally {\n setLoading(false);\n }\n };\n __NEXTAUTH._getSession();\n return () => {\n __NEXTAUTH._lastSync = 0;\n __NEXTAUTH._session = undefined;\n __NEXTAUTH._getSession = () => { };\n };\n }, []);\n React.useEffect(() => {\n const handle = () => __NEXTAUTH._getSession({ event: \"storage\" });\n // Listen for storage events and update session if event fired from\n // another window (but suppress firing another event to avoid a loop)\n // Fetch new session data but tell it to not to fire another event to\n // avoid an infinite loop.\n // Note: We could pass session data through and do something like\n // `setData(message.data)` but that can cause problems depending\n // on how the session object is being used in the client; it is\n // more robust to have each window/tab fetch it's own copy of the\n // session object rather than share it across instances.\n broadcast().addEventListener(\"message\", handle);\n return () => broadcast().removeEventListener(\"message\", handle);\n }, []);\n React.useEffect(() => {\n const { refetchOnWindowFocus = true } = props;\n // Listen for when the page is visible, if the user switches tabs\n // and makes our tab visible again, re-fetch the session, but only if\n // this feature is not disabled.\n const visibilityHandler = () => {\n if (refetchOnWindowFocus && document.visibilityState === \"visible\")\n __NEXTAUTH._getSession({ event: \"visibilitychange\" });\n };\n document.addEventListener(\"visibilitychange\", visibilityHandler, false);\n return () => document.removeEventListener(\"visibilitychange\", visibilityHandler, false);\n }, [props.refetchOnWindowFocus]);\n const isOnline = useOnline();\n // TODO: Flip this behavior in next major version\n const shouldRefetch = refetchWhenOffline !== false || isOnline;\n React.useEffect(() => {\n if (refetchInterval && shouldRefetch) {\n const refetchIntervalTimer = setInterval(() => {\n if (__NEXTAUTH._session) {\n __NEXTAUTH._getSession({ event: \"poll\" });\n }\n }, refetchInterval * 1000);\n return () => clearInterval(refetchIntervalTimer);\n }\n }, [refetchInterval, shouldRefetch]);\n const value = React.useMemo(() => ({\n data: session,\n status: loading\n ? \"loading\"\n : session\n ? \"authenticated\"\n : \"unauthenticated\",\n async update(data) {\n if (loading)\n return;\n setLoading(true);\n const newSession = await fetchData(\"session\", __NEXTAUTH, logger, typeof data === \"undefined\"\n ? undefined\n : { body: { csrfToken: await getCsrfToken(), data } });\n setLoading(false);\n if (newSession) {\n setSession(newSession);\n broadcast().postMessage({\n event: \"session\",\n data: { trigger: \"getSession\" },\n });\n }\n return newSession;\n },\n }), [session, loading]);\n return (\n // @ts-expect-error\n _jsx(SessionContext.Provider, { value: value, children: children }));\n}\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;AAsBsB;AAVtB;AACA;AACA;AAdA;;;;;;;;;;CAUC,GACD;;;;AAUO,MAAM,aAAa;IACtB,SAAS,IAAA,wMAAQ,EAAC,uNAAO,CAAC,GAAG,CAAC,YAAY,IAAI,uNAAO,CAAC,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S;KAAQ;IACtB,OACA,mBAAmB;IACnB,IAAA,yNAAI,EAAC,eAAe,QAAQ,EAAE;QAAE,OAAO;QAAO,UAAU;IAAS;AACrE","ignoreList":[0]}}] + {"offset": {"line": 4, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/src/lib/api.ts"],"sourcesContent":["import { BookProject, UserProfile } from './types';\r\n\r\nconst API_BASE_URL = '/api';\r\n\r\n// --- API CLIENT ---\r\n\r\nconst api = {\r\n async request(endpoint: string, options: RequestInit = {}) {\r\n const url = `${API_BASE_URL}${endpoint}`;\r\n\r\n const headers: Record = {\r\n 'Content-Type': 'application/json',\r\n ...options.headers as Record,\r\n };\r\n\r\n const response = await fetch(url, {\r\n ...options,\r\n headers,\r\n });\r\n\r\n if (!response.ok) {\r\n let errorMsg = `Error ${response.status}: ${response.statusText}`;\r\n try {\r\n const errorJson = await response.json();\r\n if (errorJson.error) errorMsg = errorJson.error;\r\n if (errorJson.message) errorMsg = errorJson.message;\r\n } catch {\r\n // Ignore json parse error\r\n }\r\n throw new Error(errorMsg);\r\n }\r\n\r\n if (response.status === 204) return null;\r\n return response.json();\r\n },\r\n\r\n // --- AUTH ---\r\n auth: {\r\n async register(email: string, password: string, name: string) {\r\n return api.request('/auth/register', {\r\n method: 'POST',\r\n body: JSON.stringify({ email, password, name }),\r\n });\r\n },\r\n },\r\n\r\n // --- USER ---\r\n user: {\r\n async updateProfile(data: any) {\r\n return api.request('/user/profile', {\r\n method: 'PUT',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n },\r\n\r\n // --- PROJECTS ---\r\n projects: {\r\n async list() {\r\n return api.request('/projects');\r\n },\r\n\r\n async get(id: string) {\r\n return api.request(`/projects/${id}`);\r\n },\r\n\r\n async create(data: { title: string; author: string; settings?: any }) {\r\n return api.request('/projects', {\r\n method: 'POST',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async update(id: string, data: any) {\r\n return api.request(`/projects/${id}`, {\r\n method: 'PUT',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async delete(id: string) {\r\n return api.request(`/projects/${id}`, {\r\n method: 'DELETE',\r\n });\r\n },\r\n\r\n async syncWorkflow(id: string, data: { nodes: any[]; connections: any[] }) {\r\n return api.request(`/projects/${id}/workflow`, {\r\n method: 'PUT',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n },\r\n\r\n // --- CHAPTERS ---\r\n chapters: {\r\n async create(data: { projectId: string; title?: string; content?: string; summary?: string; orderIndex?: number }) {\r\n return api.request('/chapters', {\r\n method: 'POST',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async update(id: string, data: any) {\r\n return api.request(`/chapters/${id}`, {\r\n method: 'PUT',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async delete(id: string) {\r\n return api.request(`/chapters/${id}`, {\r\n method: 'DELETE',\r\n });\r\n },\r\n },\r\n\r\n // --- ENTITIES ---\r\n entities: {\r\n async create(data: { projectId: string; type: string; name?: string; description?: string; details?: string; attributes?: any; customValues?: any }) {\r\n return api.request('/entities', {\r\n method: 'POST',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async update(id: string, data: any) {\r\n return api.request(`/entities/${id}`, {\r\n method: 'PUT',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async delete(id: string) {\r\n return api.request(`/entities/${id}`, {\r\n method: 'DELETE',\r\n });\r\n },\r\n },\r\n\r\n // --- IDEAS ---\r\n ideas: {\r\n async create(data: { projectId: string; title?: string; description?: string; status?: string; category?: string }) {\r\n return api.request('/ideas', {\r\n method: 'POST',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async update(id: string, data: any) {\r\n return api.request(`/ideas/${id}`, {\r\n method: 'PUT',\r\n body: JSON.stringify(data),\r\n });\r\n },\r\n\r\n async delete(id: string) {\r\n return api.request(`/ideas/${id}`, {\r\n method: 'DELETE',\r\n });\r\n },\r\n },\r\n\r\n // --- AI (server-side via API routes) ---\r\n ai: {\r\n async generate(project: BookProject, chapterId: string, prompt: string, user: UserProfile) {\r\n return api.request<{ text: string; type: 'draft' | 'reflection' }>('/ai/generate', {\r\n method: 'POST',\r\n body: JSON.stringify({ project, chapterId, prompt, user }),\r\n });\r\n },\r\n\r\n async transform(text: string, mode: string, context: string, user: UserProfile) {\r\n const res = await api.request<{ text: string }>('/ai/transform', {\r\n method: 'POST',\r\n body: JSON.stringify({ text, mode, context, user }),\r\n });\r\n return res.text;\r\n },\r\n },\r\n};\r\n\r\nexport default api;\r\n"],"names":[],"mappings":";;;;AAEA,MAAM,eAAe;AAErB,qBAAqB;AAErB,MAAM,MAAM;IACR,MAAM,SAAiB,QAAgB,EAAE,UAAuB,CAAC,CAAC;QAC9D,MAAM,MAAM,GAAG,eAAe,UAAU;QAExC,MAAM,UAAkC;YACpC,gBAAgB;YAChB,GAAG,QAAQ,OAAO;QACtB;QAEA,MAAM,WAAW,MAAM,MAAM,KAAK;YAC9B,GAAG,OAAO;YACV;QACJ;QAEA,IAAI,CAAC,SAAS,EAAE,EAAE;YACd,IAAI,WAAW,CAAC,MAAM,EAAE,SAAS,MAAM,CAAC,EAAE,EAAE,SAAS,UAAU,EAAE;YACjE,IAAI;gBACA,MAAM,YAAY,MAAM,SAAS,IAAI;gBACrC,IAAI,UAAU,KAAK,EAAE,WAAW,UAAU,KAAK;gBAC/C,IAAI,UAAU,OAAO,EAAE,WAAW,UAAU,OAAO;YACvD,EAAE,OAAM;YACJ,0BAA0B;YAC9B;YACA,MAAM,IAAI,MAAM;QACpB;QAEA,IAAI,SAAS,MAAM,KAAK,KAAK,OAAO;QACpC,OAAO,SAAS,IAAI;IACxB;IAEA,eAAe;IACf,MAAM;QACF,MAAM,UAAS,KAAa,EAAE,QAAgB,EAAE,IAAY;YACxD,OAAO,IAAI,OAAO,CAAC,kBAAkB;gBACjC,QAAQ;gBACR,MAAM,KAAK,SAAS,CAAC;oBAAE;oBAAO;oBAAU;gBAAK;YAC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B;gBAC7D,QAAQ;gBACR,MAAM,KAAK,SAAS,CAAC;oBAAE;oBAAM;oBAAM;oBAAS;gBAAK;YACrD;YACA,OAAO,IAAI,IAAI;QACnB;IACJ;AACJ;uCAEe"}}, + {"offset": {"line": 184, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/src/hooks/useAuth.ts"],"sourcesContent":["'use client';\r\n\r\nimport { useState, useEffect, useCallback } from 'react';\r\nimport { signIn, signOut, useSession } from 'next-auth/react';\r\nimport { UserProfile } from '@/lib/types';\r\nimport api from '@/lib/api';\r\n\r\nexport const useAuth = () => {\r\n const { data: session, status } = useSession();\r\n const [user, setUser] = useState(null);\r\n const loading = status === 'loading';\r\n\r\n // Fetch real profile from DB when session is available\r\n useEffect(() => {\r\n if (session?.user?.id) {\r\n fetch('/api/user/profile', { cache: 'no-store' })\r\n .then(res => res.json())\r\n .then(dbUser => {\r\n const planId = dbUser.plan || 'free';\r\n const planDetails = dbUser.planDetails || {\r\n id: 'free',\r\n displayName: 'Gratuit',\r\n maxAiActions: 100,\r\n maxProjects: 3\r\n };\r\n\r\n setUser({\r\n id: dbUser.id,\r\n email: dbUser.email,\r\n name: dbUser.name || 'User',\r\n avatar: dbUser.avatar,\r\n bio: dbUser.bio,\r\n subscription: {\r\n plan: planId,\r\n planDetails: planDetails,\r\n startDate: new Date(dbUser.createdAt).getTime(),\r\n status: 'active'\r\n },\r\n usage: {\r\n aiActionsCurrent: dbUser.aiActionsUsed || 0,\r\n aiActionsLimit: planDetails.maxAiActions,\r\n projectsLimit: planDetails.maxProjects,\r\n },\r\n preferences: { theme: 'light', dailyWordGoal: dbUser.dailyWordGoal || 500, language: 'fr' },\r\n stats: {\r\n totalWordsWritten: dbUser.totalWords || 0,\r\n writingStreak: dbUser.writingStreak || 0,\r\n lastWriteDate: dbUser.lastWriteDate ? new Date(dbUser.lastWriteDate).getTime() : 0,\r\n },\r\n });\r\n })\r\n .catch(err => {\r\n console.error('Failed to fetch user profile:', err);\r\n // Fallback to session data\r\n setUser({\r\n id: session.user.id || '',\r\n email: session.user.email || '',\r\n name: session.user.name || 'User',\r\n subscription: { plan: 'free', startDate: Date.now(), status: 'active' },\r\n usage: { aiActionsCurrent: 0, aiActionsLimit: 100, projectsLimit: 3 },\r\n preferences: { theme: 'light', dailyWordGoal: 500, language: 'fr' },\r\n stats: { totalWordsWritten: 0, writingStreak: 0, lastWriteDate: 0 },\r\n });\r\n });\r\n } else if (status === 'unauthenticated') {\r\n setUser(null);\r\n }\r\n }, [session, status]);\r\n\r\n const login = useCallback(async (email: string, password: string) => {\r\n const result = await signIn('credentials', {\r\n email,\r\n password,\r\n redirect: false,\r\n });\r\n\r\n if (result?.error) {\r\n throw new Error(result.error === 'CredentialsSignin'\r\n ? 'Email ou mot de passe incorrect'\r\n : result.error\r\n );\r\n }\r\n }, []);\r\n\r\n const signup = useCallback(async (email: string, password: string, name: string) => {\r\n await api.auth.register(email, password, name);\r\n const result = await signIn('credentials', {\r\n email,\r\n password,\r\n redirect: false,\r\n });\r\n if (result?.error) {\r\n throw new Error('Compte créé mais erreur de connexion automatique');\r\n }\r\n }, []);\r\n\r\n const logout = useCallback(async () => {\r\n await signOut({ redirect: false });\r\n setUser(null);\r\n }, []);\r\n\r\n const incrementUsage = useCallback((serverCount?: number) => {\r\n if (user) {\r\n setUser({\r\n ...user,\r\n usage: {\r\n ...user.usage,\r\n aiActionsCurrent: serverCount !== undefined ? serverCount : user.usage.aiActionsCurrent + 1,\r\n },\r\n });\r\n }\r\n }, [user]);\r\n\r\n const updateProfile = useCallback(async (updates: Partial) => {\r\n if (!user) return;\r\n\r\n try {\r\n // Unpack everything that can be updated into a flat object for the API\r\n const apiUpdates: any = {};\r\n if (updates.name !== undefined) apiUpdates.name = updates.name;\r\n if (updates.avatar !== undefined) apiUpdates.avatar = updates.avatar;\r\n if (updates.bio !== undefined) apiUpdates.bio = updates.bio;\r\n if (updates.preferences?.dailyWordGoal !== undefined) apiUpdates.dailyWordGoal = updates.preferences.dailyWordGoal;\r\n\r\n // Make the API call to update DB\r\n await api.user.updateProfile(apiUpdates);\r\n\r\n // Update local state\r\n setUser(prev => prev ? { ...prev, ...updates } : null);\r\n } catch (err) {\r\n console.error('Failed to update profile:', err);\r\n throw err;\r\n }\r\n }, [user]);\r\n\r\n return { user, login, signup, logout, incrementUsage, updateProfile, loading };\r\n};\r\n"],"names":[],"mappings":";;;;AAEA;AACA;AAEA;;AALA;;;;AAOO,MAAM,UAAU;;IACnB,MAAM,EAAE,MAAM,OAAO,EAAE,MAAM,EAAE,GAAG,IAAA,kMAAU;IAC5C,MAAM,CAAC,MAAM,QAAQ,GAAG,IAAA,qNAAQ,EAAqB;IACrD,MAAM,UAAU,WAAW;IAE3B,uDAAuD;IACvD,IAAA,sNAAS;6BAAC;YACN,IAAI,SAAS,MAAM,IAAI;gBACnB,MAAM,qBAAqB;oBAAE,OAAO;gBAAW,GAC1C,IAAI;yCAAC,CAAA,MAAO,IAAI,IAAI;wCACpB,IAAI;yCAAC,CAAA;wBACF,MAAM,SAAS,OAAO,IAAI,IAAI;wBAC9B,MAAM,cAAc,OAAO,WAAW,IAAI;4BACtC,IAAI;4BACJ,aAAa;4BACb,cAAc;4BACd,aAAa;wBACjB;wBAEA,QAAQ;4BACJ,IAAI,OAAO,EAAE;4BACb,OAAO,OAAO,KAAK;4BACnB,MAAM,OAAO,IAAI,IAAI;4BACrB,QAAQ,OAAO,MAAM;4BACrB,KAAK,OAAO,GAAG;4BACf,cAAc;gCACV,MAAM;gCACN,aAAa;gCACb,WAAW,IAAI,KAAK,OAAO,SAAS,EAAE,OAAO;gCAC7C,QAAQ;4BACZ;4BACA,OAAO;gCACH,kBAAkB,OAAO,aAAa,IAAI;gCAC1C,gBAAgB,YAAY,YAAY;gCACxC,eAAe,YAAY,WAAW;4BAC1C;4BACA,aAAa;gCAAE,OAAO;gCAAS,eAAe,OAAO,aAAa,IAAI;gCAAK,UAAU;4BAAK;4BAC1F,OA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, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/src/providers/AuthProvider.tsx"],"sourcesContent":["'use client';\r\n\r\nimport React, { createContext, useContext } from 'react';\r\nimport { SessionProvider } from 'next-auth/react';\r\nimport { useAuth } from '@/hooks/useAuth';\r\n\r\nconst AuthContext = createContext(null);\r\n\r\nfunction AuthInner({ children }: { children: React.ReactNode }) {\r\n const auth = useAuth();\r\n return {children};\r\n}\r\n\r\nexport const AuthProvider: React.FC<{ children: React.ReactNode }> = ({ children }) => {\r\n return (\r\n \r\n {children}\r\n \r\n );\r\n};\r\n\r\nexport function useAuthContext() {\r\n return useContext(AuthContext);\r\n}\r\n"],"names":[],"mappings":";;;;;;;AAEA;AACA;AACA;;;AAJA;;;;AAMA,MAAM,4BAAc,IAAA,0NAAa,EAAM;AAEvC,SAAS,UAAU,EAAE,QAAQ,EAAiC;;IAC1D,MAAM,OAAO,IAAA,iLAAO;IACpB,qBAAO,yOAAC,YAAY,QAAQ;QAAC,OAAO;kBAAO;;;;;;AAC/C;GAHS;;QACQ,iLAAO;;;KADf;AAKF,MAAM,eAAwD,CAAC,EAAE,QAAQ,EAAE;IAC9E,qBACI,yOAAC,uMAAe;kBACZ,cAAA,yOAAC;sBAAW;;;;;;;;;;;AAGxB;MANa;AAQN,SAAS;;IACZ,OAAO,IAAA,uNAAU,EAAC;AACtB;IAFgB"}}, + {"offset": {"line": 449, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/node_modules/next/dist/compiled/react/cjs/react-jsx-dev-runtime.development.js"],"sourcesContent":["/**\n * @license React\n * react-jsx-dev-runtime.development.js\n *\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n\"use strict\";\n\"production\" !== process.env.NODE_ENV &&\n (function () {\n function getComponentNameFromType(type) {\n if (null == type) return null;\n if (\"function\" === typeof type)\n return type.$$typeof === REACT_CLIENT_REFERENCE\n ? null\n : type.displayName || type.name || null;\n if (\"string\" === typeof type) return type;\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n return \"Fragment\";\n case REACT_PROFILER_TYPE:\n return \"Profiler\";\n case REACT_STRICT_MODE_TYPE:\n return \"StrictMode\";\n case REACT_SUSPENSE_TYPE:\n return \"Suspense\";\n case REACT_SUSPENSE_LIST_TYPE:\n return \"SuspenseList\";\n case REACT_ACTIVITY_TYPE:\n return \"Activity\";\n case REACT_VIEW_TRANSITION_TYPE:\n return \"ViewTransition\";\n }\n if (\"object\" === typeof type)\n switch (\n (\"number\" === typeof type.tag &&\n console.error(\n \"Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue.\"\n ),\n type.$$typeof)\n ) {\n case REACT_PORTAL_TYPE:\n return \"Portal\";\n case REACT_CONTEXT_TYPE:\n return type.displayName || \"Context\";\n case REACT_CONSUMER_TYPE:\n return (type._context.displayName || \"Context\") + \".Consumer\";\n case REACT_FORWARD_REF_TYPE:\n var innerType = type.render;\n type = type.displayName;\n type ||\n ((type = innerType.displayName || innerType.name || \"\"),\n (type = \"\" !== type ? \"ForwardRef(\" + type + \")\" : \"ForwardRef\"));\n return type;\n case REACT_MEMO_TYPE:\n return (\n (innerType = type.displayName || null),\n null !== innerType\n ? innerType\n : getComponentNameFromType(type.type) || \"Memo\"\n );\n case REACT_LAZY_TYPE:\n innerType = type._payload;\n type = type._init;\n try {\n return getComponentNameFromType(type(innerType));\n } catch (x) {}\n }\n return null;\n }\n function testStringCoercion(value) {\n return \"\" + value;\n }\n function checkKeyStringCoercion(value) {\n try {\n testStringCoercion(value);\n var JSCompiler_inline_result = !1;\n } catch (e) {\n JSCompiler_inline_result = !0;\n }\n if (JSCompiler_inline_result) {\n JSCompiler_inline_result = console;\n var JSCompiler_temp_const = JSCompiler_inline_result.error;\n var JSCompiler_inline_result$jscomp$0 =\n (\"function\" === typeof Symbol &&\n Symbol.toStringTag &&\n value[Symbol.toStringTag]) ||\n value.constructor.name ||\n \"Object\";\n JSCompiler_temp_const.call(\n JSCompiler_inline_result,\n \"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.\",\n JSCompiler_inline_result$jscomp$0\n );\n return testStringCoercion(value);\n }\n }\n function getTaskName(type) {\n if (type === REACT_FRAGMENT_TYPE) return \"<>\";\n if (\n \"object\" === typeof type &&\n null !== type &&\n type.$$typeof === REACT_LAZY_TYPE\n )\n return \"<...>\";\n try {\n var name = getComponentNameFromType(type);\n return name ? \"<\" + name + \">\" : \"<...>\";\n } catch (x) {\n return \"<...>\";\n }\n }\n function getOwner() {\n var dispatcher = ReactSharedInternals.A;\n return null === dispatcher ? null : dispatcher.getOwner();\n }\n function UnknownOwner() {\n return Error(\"react-stack-top-frame\");\n }\n function hasValidKey(config) {\n if (hasOwnProperty.call(config, \"key\")) {\n var getter = Object.getOwnPropertyDescriptor(config, \"key\").get;\n if (getter && getter.isReactWarning) return !1;\n }\n return void 0 !== config.key;\n }\n function defineKeyPropWarningGetter(props, displayName) {\n function warnAboutAccessingKey() {\n specialPropKeyWarningShown ||\n ((specialPropKeyWarningShown = !0),\n console.error(\n \"%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)\",\n displayName\n ));\n }\n warnAboutAccessingKey.isReactWarning = !0;\n Object.defineProperty(props, \"key\", {\n get: warnAboutAccessingKey,\n configurable: !0\n });\n }\n function elementRefGetterWithDeprecationWarning() {\n var componentName = getComponentNameFromType(this.type);\n didWarnAboutElementRef[componentName] ||\n ((didWarnAboutElementRef[componentName] = !0),\n console.error(\n \"Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release.\"\n ));\n componentName = this.props.ref;\n return void 0 !== componentName ? componentName : null;\n }\n function ReactElement(type, key, props, owner, debugStack, debugTask) {\n var refProp = props.ref;\n type = {\n $$typeof: REACT_ELEMENT_TYPE,\n type: type,\n key: key,\n props: props,\n _owner: owner\n };\n null !== (void 0 !== refProp ? refProp : null)\n ? Object.defineProperty(type, \"ref\", {\n enumerable: !1,\n get: elementRefGetterWithDeprecationWarning\n })\n : Object.defineProperty(type, \"ref\", { enumerable: !1, value: null });\n type._store = {};\n Object.defineProperty(type._store, \"validated\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: 0\n });\n Object.defineProperty(type, \"_debugInfo\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: null\n });\n Object.defineProperty(type, \"_debugStack\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: debugStack\n });\n Object.defineProperty(type, \"_debugTask\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: debugTask\n });\n Object.freeze && (Object.freeze(type.props), Object.freeze(type));\n return type;\n }\n function jsxDEVImpl(\n type,\n config,\n maybeKey,\n isStaticChildren,\n debugStack,\n debugTask\n ) {\n var children = config.children;\n if (void 0 !== children)\n if (isStaticChildren)\n if (isArrayImpl(children)) {\n for (\n isStaticChildren = 0;\n isStaticChildren < children.length;\n isStaticChildren++\n )\n validateChildKeys(children[isStaticChildren]);\n Object.freeze && Object.freeze(children);\n } else\n console.error(\n \"React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.\"\n );\n else validateChildKeys(children);\n if (hasOwnProperty.call(config, \"key\")) {\n children = getComponentNameFromType(type);\n var keys = Object.keys(config).filter(function (k) {\n return \"key\" !== k;\n });\n isStaticChildren =\n 0 < keys.length\n ? \"{key: someKey, \" + keys.join(\": ..., \") + \": ...}\"\n : \"{key: someKey}\";\n didWarnAboutKeySpread[children + isStaticChildren] ||\n ((keys =\n 0 < keys.length ? \"{\" + keys.join(\": ..., \") + \": ...}\" : \"{}\"),\n console.error(\n 'A props object containing a \"key\" prop is being spread into JSX:\\n let props = %s;\\n <%s {...props} />\\nReact keys must be passed directly to JSX without using spread:\\n let props = %s;\\n <%s key={someKey} {...props} />',\n isStaticChildren,\n children,\n keys,\n children\n ),\n (didWarnAboutKeySpread[children + isStaticChildren] = !0));\n }\n children = null;\n void 0 !== maybeKey &&\n (checkKeyStringCoercion(maybeKey), (children = \"\" + maybeKey));\n hasValidKey(config) &&\n (checkKeyStringCoercion(config.key), (children = \"\" + config.key));\n if (\"key\" in config) {\n maybeKey = {};\n for (var propName in config)\n \"key\" !== propName && (maybeKey[propName] = config[propName]);\n } else maybeKey = config;\n children &&\n defineKeyPropWarningGetter(\n maybeKey,\n \"function\" === typeof type\n ? type.displayName || type.name || \"Unknown\"\n : type\n );\n return ReactElement(\n type,\n children,\n maybeKey,\n getOwner(),\n debugStack,\n debugTask\n );\n }\n function validateChildKeys(node) {\n isValidElement(node)\n ? node._store && (node._store.validated = 1)\n : \"object\" === typeof node &&\n null !== node &&\n node.$$typeof === REACT_LAZY_TYPE &&\n (\"fulfilled\" === node._payload.status\n ? isValidElement(node._payload.value) &&\n node._payload.value._store &&\n (node._payload.value._store.validated = 1)\n : node._store && (node._store.validated = 1));\n }\n function isValidElement(object) {\n return (\n \"object\" === typeof object &&\n null !== object &&\n object.$$typeof === REACT_ELEMENT_TYPE\n );\n }\n var React = require(\"next/dist/compiled/react\"),\n REACT_ELEMENT_TYPE = Symbol.for(\"react.transitional.element\"),\n REACT_PORTAL_TYPE = Symbol.for(\"react.portal\"),\n REACT_FRAGMENT_TYPE = Symbol.for(\"react.fragment\"),\n REACT_STRICT_MODE_TYPE = Symbol.for(\"react.strict_mode\"),\n REACT_PROFILER_TYPE = Symbol.for(\"react.profiler\"),\n REACT_CONSUMER_TYPE = Symbol.for(\"react.consumer\"),\n REACT_CONTEXT_TYPE = Symbol.for(\"react.context\"),\n REACT_FORWARD_REF_TYPE = Symbol.for(\"react.forward_ref\"),\n REACT_SUSPENSE_TYPE = Symbol.for(\"react.suspense\"),\n REACT_SUSPENSE_LIST_TYPE = Symbol.for(\"react.suspense_list\"),\n REACT_MEMO_TYPE = Symbol.for(\"react.memo\"),\n REACT_LAZY_TYPE = Symbol.for(\"react.lazy\"),\n REACT_ACTIVITY_TYPE = Symbol.for(\"react.activity\"),\n REACT_VIEW_TRANSITION_TYPE = Symbol.for(\"react.view_transition\"),\n REACT_CLIENT_REFERENCE = Symbol.for(\"react.client.reference\"),\n ReactSharedInternals =\n React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,\n hasOwnProperty = Object.prototype.hasOwnProperty,\n isArrayImpl = Array.isArray,\n createTask = console.createTask\n ? console.createTask\n : function () {\n return null;\n };\n React = {\n react_stack_bottom_frame: function (callStackForError) {\n return callStackForError();\n }\n };\n var specialPropKeyWarningShown;\n var didWarnAboutElementRef = {};\n var unknownOwnerDebugStack = React.react_stack_bottom_frame.bind(\n React,\n UnknownOwner\n )();\n var unknownOwnerDebugTask = createTask(getTaskName(UnknownOwner));\n var didWarnAboutKeySpread = {};\n exports.Fragment = REACT_FRAGMENT_TYPE;\n exports.jsxDEV = function (type, config, maybeKey, isStaticChildren) {\n var trackActualOwner =\n 1e4 > ReactSharedInternals.recentlyCreatedOwnerStacks++;\n if (trackActualOwner) {\n var previousStackTraceLimit = Error.stackTraceLimit;\n Error.stackTraceLimit = 10;\n var debugStackDEV = Error(\"react-stack-top-frame\");\n Error.stackTraceLimit = previousStackTraceLimit;\n } else debugStackDEV = unknownOwnerDebugStack;\n return jsxDEVImpl(\n type,\n config,\n maybeKey,\n isStaticChildren,\n debugStackDEV,\n trackActualOwner ? createTask(getTaskName(type)) : unknownOwnerDebugTask\n );\n };\n })();\n"],"names":[],"mappings":"AAWiB;AAXjB;;;;;;;;CAQC,GAED;AACA,oEACE,AAAC;IACC,SAAS,yBAAyB,IAAI;QACpC,IAAI,QAAQ,MAAM,OAAO;QACzB,IAAI,eAAe,OAAO,MACxB,OAAO,KAAK,QAAQ,KAAK,yBACrB,OACA,KAAK,WAAW,IAAI,KAAK,IAAI,IAAI;QACvC,IAAI,aAAa,OAAO,MAAM,OAAO;QACrC,OAAQ;YACN,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AAM,eAAe;YACnD,MAAM,eAAe,GAAG;YACxB,IAAI,gBAAgB,MAAM;YAC1B,MAAM,eAAe,GAAG;QAC1B,OAAO,gBAAgB;QACvB,OAAO,WACL,MACA,QACA,UACA,kBACA,eACA,mBAAmB,WAAW,YAAY,SAAS;IAEvD;AACF","ignoreList":[0]}}, + {"offset": {"line": 665, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/node_modules/next/dist/compiled/react/jsx-dev-runtime.js"],"sourcesContent":["'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-jsx-dev-runtime.production.js');\n} else {\n module.exports = require('./cjs/react-jsx-dev-runtime.development.js');\n}\n"],"names":[],"mappings":"AAEI;AAFJ;AAEA;;KAEO;IACL,OAAO,OAAO;AAChB","ignoreList":[0]}}, + {"offset": {"line": 676, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/node_modules/%40auth/core/errors.js"],"sourcesContent":["/**\n * Base error class for all Auth.js errors.\n * It's optimized to be printed in the server logs in a nicely formatted way\n * via the [`logger.error`](https://authjs.dev/reference/core#logger) option.\n * @noInheritDoc\n */\nexport class AuthError extends Error {\n /** @internal */\n constructor(message, errorOptions) {\n if (message instanceof Error) {\n super(undefined, {\n cause: { err: message, ...message.cause, ...errorOptions },\n });\n }\n else if (typeof message === \"string\") {\n if (errorOptions instanceof Error) {\n errorOptions = { err: errorOptions, ...errorOptions.cause };\n }\n super(message, errorOptions);\n }\n else {\n super(undefined, message);\n }\n this.name = this.constructor.name;\n // @ts-expect-error https://github.com/microsoft/TypeScript/issues/3841\n this.type = this.constructor.type ?? \"AuthError\";\n // @ts-expect-error https://github.com/microsoft/TypeScript/issues/3841\n this.kind = this.constructor.kind ?? \"error\";\n Error.captureStackTrace?.(this, this.constructor);\n const url = `https://errors.authjs.dev#${this.type.toLowerCase()}`;\n this.message += `${this.message ? \". \" : \"\"}Read more at ${url}`;\n }\n}\n/**\n * Thrown when the user's sign-in attempt failed.\n * @noInheritDoc\n */\nexport class SignInError extends AuthError {\n}\n/** @internal */\nSignInError.kind = \"signIn\";\n/**\n * One of the database [`Adapter` methods](https://authjs.dev/reference/core/adapters#methods)\n * failed during execution.\n *\n * :::tip\n * If `debug: true` is set, you can check out `[auth][debug]` in the logs to learn more about the failed adapter method execution.\n * @example\n * ```sh\n * [auth][debug]: adapter_getUserByEmail\n * { \"args\": [undefined] }\n * ```\n * :::\n * @noInheritDoc\n */\nexport class AdapterError extends AuthError {\n}\nAdapterError.type = \"AdapterError\";\n/**\n * Thrown when the execution of the [`signIn` callback](https://authjs.dev/reference/core/types#signin) fails\n * or if it returns `false`.\n * @noInheritDoc\n */\nexport class AccessDenied extends AuthError {\n}\nAccessDenied.type = \"AccessDenied\";\n/**\n * This error occurs when the user cannot finish login.\n * Depending on the provider type, this could have happened for multiple reasons.\n *\n * :::tip\n * Check out `[auth][details]` in the logs to know which provider failed.\n * @example\n * ```sh\n * [auth][details]: { \"provider\": \"github\" }\n * ```\n * :::\n *\n * For an [OAuth provider](https://authjs.dev/getting-started/authentication/oauth), possible causes are:\n * - The user denied access to the application\n * - There was an error parsing the OAuth Profile:\n * Check out the provider's `profile` or `userinfo.request` method to make sure\n * it correctly fetches the user's profile.\n * - The `signIn` or `jwt` callback methods threw an uncaught error:\n * Check the callback method implementations.\n *\n * For an [Email provider](https://authjs.dev/getting-started/authentication/email), possible causes are:\n * - The provided email/token combination was invalid/missing:\n * Check if the provider's `sendVerificationRequest` method correctly sends the email.\n * - The provided email/token combination has expired:\n * Ask the user to log in again.\n * - There was an error with the database:\n * Check the database logs.\n *\n * For a [Credentials provider](https://authjs.dev/getting-started/authentication/credentials), possible causes are:\n * - The `authorize` method threw an uncaught error:\n * Check the provider's `authorize` method.\n * - The `signIn` or `jwt` callback methods threw an uncaught error:\n * Check the callback method implementations.\n *\n * :::tip\n * Check out `[auth][cause]` in the error message for more details.\n * It will show the original stack trace.\n * :::\n * @noInheritDoc\n */\nexport class CallbackRouteError extends AuthError {\n}\nCallbackRouteError.type = \"CallbackRouteError\";\n/**\n * Thrown when Auth.js is misconfigured and accidentally tried to require authentication on a custom error page.\n * To prevent an infinite loop, Auth.js will instead render its default error page.\n *\n * To fix this, make sure that the `error` page does not require authentication.\n *\n * Learn more at [Guide: Error pages](https://authjs.dev/guides/pages/error)\n * @noInheritDoc\n */\nexport class ErrorPageLoop extends AuthError {\n}\nErrorPageLoop.type = \"ErrorPageLoop\";\n/**\n * One of the [`events` methods](https://authjs.dev/reference/core/types#eventcallbacks)\n * failed during execution.\n *\n * Make sure that the `events` methods are implemented correctly and uncaught errors are handled.\n *\n * Learn more at [`events`](https://authjs.dev/reference/core/types#eventcallbacks)\n * @noInheritDoc\n */\nexport class EventError extends AuthError {\n}\nEventError.type = \"EventError\";\n/**\n * Thrown when Auth.js is unable to verify a `callbackUrl` value.\n * The browser either disabled cookies or the `callbackUrl` is not a valid URL.\n *\n * Somebody might have tried to manipulate the callback URL that Auth.js uses to redirect the user back to the configured `callbackUrl`/page.\n * This could be a malicious hacker trying to redirect the user to a phishing site.\n * To prevent this, Auth.js checks if the callback URL is valid and throws this error if it is not.\n *\n * There is no action required, but it might be an indicator that somebody is trying to attack your application.\n * @noInheritDoc\n */\nexport class InvalidCallbackUrl extends AuthError {\n}\nInvalidCallbackUrl.type = \"InvalidCallbackUrl\";\n/**\n * Can be thrown from the `authorize` callback of the Credentials provider.\n * When an error occurs during the `authorize` callback, two things can happen:\n * 1. The user is redirected to the signin page, with `error=CredentialsSignin&code=credentials` in the URL. `code` is configurable.\n * 2. If you throw this error in a framework that handles form actions server-side, this error is thrown, instead of redirecting the user, so you'll need to handle.\n * @noInheritDoc\n */\nexport class CredentialsSignin extends SignInError {\n constructor() {\n super(...arguments);\n /**\n * The error code that is set in the `code` query parameter of the redirect URL.\n *\n *\n * ⚠ NOTE: This property is going to be included in the URL, so make sure it does not hint at sensitive errors.\n *\n * The full error is always logged on the server, if you need to debug.\n *\n * Generally, we don't recommend hinting specifically if the user had either a wrong username or password specifically,\n * try rather something like \"Invalid credentials\".\n */\n this.code = \"credentials\";\n }\n}\nCredentialsSignin.type = \"CredentialsSignin\";\n/**\n * One of the configured OAuth or OIDC providers is missing the `authorization`, `token` or `userinfo`, or `issuer` configuration.\n * To perform OAuth or OIDC sign in, at least one of these endpoints is required.\n *\n * Learn more at [`OAuth2Config`](https://authjs.dev/reference/core/providers#oauth2configprofile) or [Guide: OAuth Provider](https://authjs.dev/guides/configuring-oauth-providers)\n * @noInheritDoc\n */\nexport class InvalidEndpoints extends AuthError {\n}\nInvalidEndpoints.type = \"InvalidEndpoints\";\n/**\n * Thrown when a PKCE, state or nonce OAuth check could not be performed.\n * This could happen if the OAuth provider is configured incorrectly or if the browser is blocking cookies.\n *\n * Learn more at [`checks`](https://authjs.dev/reference/core/providers#checks)\n * @noInheritDoc\n */\nexport class InvalidCheck extends AuthError {\n}\nInvalidCheck.type = \"InvalidCheck\";\n/**\n * Logged on the server when Auth.js could not decode or encode a JWT-based (`strategy: \"jwt\"`) session.\n *\n * Possible causes are either a misconfigured `secret` or a malformed JWT or `encode/decode` methods.\n *\n * :::note\n * When this error is logged, the session cookie is destroyed.\n * :::\n *\n * Learn more at [`secret`](https://authjs.dev/reference/core#secret), [`jwt.encode`](https://authjs.dev/reference/core/jwt#encode-1) or [`jwt.decode`](https://authjs.dev/reference/core/jwt#decode-2) for more information.\n * @noInheritDoc\n */\nexport class JWTSessionError extends AuthError {\n}\nJWTSessionError.type = \"JWTSessionError\";\n/**\n * Thrown if Auth.js is misconfigured. This could happen if you configured an Email provider but did not set up a database adapter,\n * or tried using a `strategy: \"database\"` session without a database adapter.\n * In both cases, make sure you either remove the configuration or add the missing adapter.\n *\n * Learn more at [Database Adapters](https://authjs.dev/getting-started/database), [Email provider](https://authjs.dev/getting-started/authentication/email) or [Concept: Database session strategy](https://authjs.dev/concepts/session-strategies#database-session)\n * @noInheritDoc\n */\nexport class MissingAdapter extends AuthError {\n}\nMissingAdapter.type = \"MissingAdapter\";\n/**\n * Thrown similarily to [`MissingAdapter`](https://authjs.dev/reference/core/errors#missingadapter), but only some required methods were missing.\n *\n * Make sure you either remove the configuration or add the missing methods to the adapter.\n *\n * Learn more at [Database Adapters](https://authjs.dev/getting-started/database)\n * @noInheritDoc\n */\nexport class MissingAdapterMethods extends AuthError {\n}\nMissingAdapterMethods.type = \"MissingAdapterMethods\";\n/**\n * Thrown when a Credentials provider is missing the `authorize` configuration.\n * To perform credentials sign in, the `authorize` method is required.\n *\n * Learn more at [Credentials provider](https://authjs.dev/getting-started/authentication/credentials)\n * @noInheritDoc\n */\nexport class MissingAuthorize extends AuthError {\n}\nMissingAuthorize.type = \"MissingAuthorize\";\n/**\n * Auth.js requires a secret or multiple secrets to be set, but none was not found. This is used to encrypt cookies, JWTs and other sensitive data.\n *\n * :::note\n * If you are using a framework like Next.js, we try to automatically infer the secret from the `AUTH_SECRET`, `AUTH_SECRET_1`, etc. environment variables.\n * Alternatively, you can also explicitly set the [`AuthConfig.secret`](https://authjs.dev/reference/core#secret) option.\n * :::\n *\n *\n * :::tip\n * To generate a random string, you can use the Auth.js CLI: `npx auth secret`\n * :::\n * @noInheritDoc\n */\nexport class MissingSecret extends AuthError {\n}\nMissingSecret.type = \"MissingSecret\";\n/**\n * Thrown when an Email address is already associated with an account\n * but the user is trying an OAuth account that is not linked to it.\n *\n * For security reasons, Auth.js does not automatically link OAuth accounts to existing accounts if the user is not signed in.\n *\n * :::tip\n * If you trust the OAuth provider to have verified the user's email address,\n * you can enable automatic account linking by setting [`allowDangerousEmailAccountLinking: true`](https://authjs.dev/reference/core/providers#allowdangerousemailaccountlinking)\n * in the provider configuration.\n * :::\n * @noInheritDoc\n */\nexport class OAuthAccountNotLinked extends SignInError {\n}\nOAuthAccountNotLinked.type = \"OAuthAccountNotLinked\";\n/**\n * Thrown when an OAuth provider returns an error during the sign in process.\n * This could happen for example if the user denied access to the application or there was a configuration error.\n *\n * For a full list of possible reasons, check out the specification [Authorization Code Grant: Error Response](https://www.rfc-editor.org/rfc/rfc6749#section-4.1.2.1)\n * @noInheritDoc\n */\nexport class OAuthCallbackError extends SignInError {\n}\nOAuthCallbackError.type = \"OAuthCallbackError\";\n/**\n * This error occurs during an OAuth sign in attempt when the provider's\n * response could not be parsed. This could for example happen if the provider's API\n * changed, or the [`OAuth2Config.profile`](https://authjs.dev/reference/core/providers#oauth2configprofile) method is not implemented correctly.\n * @noInheritDoc\n */\nexport class OAuthProfileParseError extends AuthError {\n}\nOAuthProfileParseError.type = \"OAuthProfileParseError\";\n/**\n * Logged on the server when Auth.js could not retrieve a session from the database (`strategy: \"database\"`).\n *\n * The database adapter might be misconfigured or the database is not reachable.\n *\n * Learn more at [Concept: Database session strategy](https://authjs.dev/concepts/session-strategies#database)\n * @noInheritDoc\n */\nexport class SessionTokenError extends AuthError {\n}\nSessionTokenError.type = \"SessionTokenError\";\n/**\n * Happens when login by [OAuth](https://authjs.dev/getting-started/authentication/oauth) could not be started.\n *\n * Possible causes are:\n * - The Authorization Server is not compliant with the [OAuth 2.0](https://www.ietf.org/rfc/rfc6749.html) or the [OIDC](https://openid.net/specs/openid-connect-core-1_0.html) specification.\n * Check the details in the error message.\n *\n * :::tip\n * Check out `[auth][details]` in the logs to know which provider failed.\n * @example\n * ```sh\n * [auth][details]: { \"provider\": \"github\" }\n * ```\n * :::\n * @noInheritDoc\n */\nexport class OAuthSignInError extends SignInError {\n}\nOAuthSignInError.type = \"OAuthSignInError\";\n/**\n * Happens when the login by an [Email provider](https://authjs.dev/getting-started/authentication/email) could not be started.\n *\n * Possible causes are:\n * - The email sent from the client is invalid, could not be normalized by [`EmailConfig.normalizeIdentifier`](https://authjs.dev/reference/core/providers/email#normalizeidentifier)\n * - The provided email/token combination has expired:\n * Ask the user to log in again.\n * - There was an error with the database:\n * Check the database logs.\n * @noInheritDoc\n */\nexport class EmailSignInError extends SignInError {\n}\nEmailSignInError.type = \"EmailSignInError\";\n/**\n * Represents an error that occurs during the sign-out process. This error\n * is logged when there are issues in terminating a user's session, either\n * by failing to delete the session from the database (in database session\n * strategies) or encountering issues during other parts of the sign-out\n * process, such as emitting sign-out events or clearing session cookies.\n *\n * The session cookie(s) are emptied even if this error is logged.\n * @noInheritDoc\n */\nexport class SignOutError extends AuthError {\n}\nSignOutError.type = \"SignOutError\";\n/**\n * Auth.js was requested to handle an operation that it does not support.\n *\n * See [`AuthAction`](https://authjs.dev/reference/core/types#authaction) for the supported actions.\n * @noInheritDoc\n */\nexport class UnknownAction extends AuthError {\n}\nUnknownAction.type = \"UnknownAction\";\n/**\n * Thrown when a Credentials provider is present but the JWT strategy (`strategy: \"jwt\"`) is not enabled.\n *\n * Learn more at [`strategy`](https://authjs.dev/reference/core#strategy) or [Credentials provider](https://authjs.dev/getting-started/authentication/credentials)\n * @noInheritDoc\n */\nexport class UnsupportedStrategy extends AuthError {\n}\nUnsupportedStrategy.type = \"UnsupportedStrategy\";\n/**\n * Thrown when an endpoint was incorrectly called without a provider, or with an unsupported provider.\n * @noInheritDoc\n */\nexport class InvalidProvider extends AuthError {\n}\nInvalidProvider.type = \"InvalidProvider\";\n/**\n * Thrown when the `trustHost` option was not set to `true`.\n *\n * Auth.js requires the `trustHost` option to be set to `true` since it's relying on the request headers' `host` value.\n *\n * :::note\n * Official Auth.js libraries might attempt to automatically set the `trustHost` option to `true` if the request is coming from a trusted host on a trusted platform.\n * :::\n *\n * Learn more at [`trustHost`](https://authjs.dev/reference/core#trusthost) or [Guide: Deployment](https://authjs.dev/getting-started/deployment)\n * @noInheritDoc\n */\nexport class UntrustedHost extends AuthError {\n}\nUntrustedHost.type = \"UntrustedHost\";\n/**\n * The user's email/token combination was invalid.\n * This could be because the email/token combination was not found in the database,\n * or because the token has expired. Ask the user to log in again.\n * @noInheritDoc\n */\nexport class Verification extends AuthError {\n}\nVerification.type = \"Verification\";\n/**\n * Error for missing CSRF tokens in client-side actions (`signIn`, `signOut`, `useSession#update`).\n * Thrown when actions lack the double submit cookie, essential for CSRF protection.\n *\n * CSRF ([Cross-Site Request Forgery](https://owasp.org/www-community/attacks/csrf))\n * is an attack leveraging authenticated user credentials for unauthorized actions.\n *\n * Double submit cookie pattern, a CSRF defense, requires matching values in a cookie\n * and request parameter. More on this at [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Glossary/CSRF).\n * @noInheritDoc\n */\nexport class MissingCSRF extends SignInError {\n}\nMissingCSRF.type = \"MissingCSRF\";\nconst clientErrors = new Set([\n \"CredentialsSignin\",\n \"OAuthAccountNotLinked\",\n \"OAuthCallbackError\",\n \"AccessDenied\",\n \"Verification\",\n \"MissingCSRF\",\n \"AccountNotLinked\",\n \"WebAuthnVerificationError\",\n]);\n/**\n * Used to only allow sending a certain subset of errors to the client.\n * Errors are always logged on the server, but to prevent leaking sensitive information,\n * only a subset of errors are sent to the client as-is.\n * @internal\n */\nexport function isClientError(error) {\n if (error instanceof AuthError)\n return clientErrors.has(error.type);\n return false;\n}\n/**\n * Thrown when multiple providers have `enableConditionalUI` set to `true`.\n * Only one provider can have this option enabled at a time.\n * @noInheritDoc\n */\nexport class DuplicateConditionalUI extends AuthError {\n}\nDuplicateConditionalUI.type = \"DuplicateConditionalUI\";\n/**\n * Thrown when a WebAuthn provider has `enableConditionalUI` set to `true` but no formField has `webauthn` in its autocomplete param.\n *\n * The `webauthn` autocomplete param is required for conditional UI to work.\n * @noInheritDoc\n */\nexport class MissingWebAuthnAutocomplete extends AuthError {\n}\nMissingWebAuthnAutocomplete.type = \"MissingWebAuthnAutocomplete\";\n/**\n * Thrown when a WebAuthn provider fails to verify a client response.\n * @noInheritDoc\n */\nexport class WebAuthnVerificationError extends AuthError {\n}\nWebAuthnVerificationError.type = \"WebAuthnVerificationError\";\n/**\n * Thrown when an Email address is already associated with an account\n * but the user is trying an account that is not linked to it.\n *\n * For security reasons, Auth.js does not automatically link accounts to existing accounts if the user is not signed in.\n * @noInheritDoc\n */\nexport class AccountNotLinked extends SignInError {\n}\nAccountNotLinked.type = \"AccountNotLinked\";\n/**\n * Thrown when an experimental feature is used but not enabled.\n * @noInheritDoc\n */\nexport class ExperimentalFeatureNotEnabled extends AuthError {\n}\nExperimentalFeatureNotEnabled.type = \"ExperimentalFeatureNotEnabled\";\n"],"names":[],"mappings":"AAAA;;;;;CAKC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACM,MAAM,kBAAkB;IAC3B,cAAc,GACd,YAAY,OAAO,EAAE,YAAY,CAAE;QAC/B,IAAI,mBAAmB,OAAO;YAC1B,KAAK,CAAC,WAAW;gBACb,OAAO;oBAAE,KAAK;oBAAS,GAAG,QAAQ,KAAK;oBAAE,GAAG,YAAY;gBAAC;YAC7D;QACJ,OACK,IAAI,OAAO,YAAY,UAAU;YAClC,IAAI,wBAAwB,OAAO;gBAC/B,eAAe;oBAAE,KAAK;oBAAc,GAAG,aAAa,KAAK;gBAAC;YAC9D;YACA,KAAK,CAAC,SAAS;QACnB,OACK;YACD,KAAK,CAAC,WAAW;QACrB;QACA,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,WAAW,CAAC,IAAI;QACjC,uEAAuE;QACvE,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,WAAW,CAAC,IAAI,IAAI;QACrC,uEAAuE;QACvE,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,WAAW,CAAC,IAAI,IAAI;QACrC,MAAM,iBAAiB,GAAG,IAAI,EAAE,IAAI,CAAC,WAAW;QAChD,MAAM,MAAM,CAAC,0BAA0B,EAAE,IAAI,CAAC,IAAI,CAAC,WAAW,IAAI;QAClE,IAAI,CAAC,OAAO,IAAI,GAAG,IAAI,CAAC,OAAO,GAAG,OAAO,GAAG,aAAa,EAAE,KAAK;IACpE;AACJ;AAKO,MAAM,oBAAoB;AACjC;AACA,cAAc,GACd,YAAY,IAAI,GAAG;AAeZ,MAAM,qBAAqB;AAClC;AACA,aAAa,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AAKpB,MAAM,wBAAwB;AACrC;AACA,gBAAgB,IAAI,GAAG;AAahB,MAAM,sBAAsB;AACnC;AACA,cAAc,IAAI,GAAG;AAOd,MAAM,qBAAqB;AAClC;AACA,aAAa,IAAI,GAAG;AAYb,MAAM,oBAAoB;AACjC;AACA,YAAY,IAAI,GAAG;AACnB,MAAM,eAAe,IAAI,IAAI;IACzB;IACA;IACA;IACA;IACA;IACA;IACA;IACA;CACH;AAOM,SAAS,cAAc,KAAK;IAC/B,IAAI,iBAAiB,WACjB,OAAO,aAAa,GAAG,CAAC,MAAM,IAAI;IACtC,OAAO;AACX;AAMO,MAAM,+BAA+B;AAC5C;AACA,uBAAuB,IAAI,GAAG;AAOvB,MAAM,oCAAoC;AACjD;AACA,4BAA4B,IAAI,GAAG;AAK5B,MAAM,kCAAkC;AAC/C;AACA,0BAA0B,IAAI,GAAG;AAQ1B,MAAM,yBAAyB;AACtC;AACA,iBAAiB,IAAI,GAAG;AAKjB,MAAM,sCAAsC;AACnD;AACA,8BAA8B,IAAI,GAAG","ignoreList":[0]}}, + {"offset": {"line": 915, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/node_modules/next-auth/lib/client.js"],"sourcesContent":["\"use client\";\nimport * as React from \"react\";\nimport { AuthError } from \"@auth/core/errors\";\n/** @todo */\nclass ClientFetchError extends AuthError {\n}\n/** @todo */\nexport class ClientSessionError extends AuthError {\n}\n// ------------------------ Internal ------------------------\n/**\n * If passed 'appContext' via getInitialProps() in _app.js\n * then get the req object from ctx and use that for the\n * req value to allow `fetchData` to\n * work seemlessly in getInitialProps() on server side\n * pages *and* in _app.js.\n * @internal\n */\nexport async function fetchData(path, __NEXTAUTH, logger, req = {}) {\n const url = `${apiBaseUrl(__NEXTAUTH)}/${path}`;\n try {\n const options = {\n headers: {\n \"Content-Type\": \"application/json\",\n ...(req?.headers?.cookie ? { cookie: req.headers.cookie } : {}),\n },\n };\n if (req?.body) {\n options.body = JSON.stringify(req.body);\n options.method = \"POST\";\n }\n const res = await fetch(url, options);\n const data = await res.json();\n if (!res.ok)\n throw data;\n return data;\n }\n catch (error) {\n logger.error(new ClientFetchError(error.message, error));\n return null;\n }\n}\n/** @internal */\nexport function apiBaseUrl(__NEXTAUTH) {\n if (typeof window === \"undefined\") {\n // Return absolute path when called server side\n return `${__NEXTAUTH.baseUrlServer}${__NEXTAUTH.basePathServer}`;\n }\n // Return relative path when called client side\n return __NEXTAUTH.basePath;\n}\n/** @internal */\nexport function useOnline() {\n const [isOnline, setIsOnline] = React.useState(typeof navigator !== \"undefined\" ? navigator.onLine : false);\n const setOnline = () => setIsOnline(true);\n const setOffline = () => setIsOnline(false);\n React.useEffect(() => {\n window.addEventListener(\"online\", setOnline);\n window.addEventListener(\"offline\", setOffline);\n return () => {\n window.removeEventListener(\"online\", setOnline);\n window.removeEventListener(\"offline\", setOffline);\n };\n }, []);\n return isOnline;\n}\n/**\n * Returns the number of seconds elapsed since January 1, 1970 00:00:00 UTC.\n * @internal\n */\nexport function now() {\n return Math.floor(Date.now() / 1000);\n}\n/**\n * Returns an `URL` like object to make requests/redirects from server-side\n * @internal\n */\nexport function parseUrl(url) {\n const defaultUrl = new URL(\"http://localhost:3000/api/auth\");\n if (url && !url.startsWith(\"http\")) {\n url = `https://${url}`;\n }\n const _url = new URL(url || defaultUrl);\n const path = (_url.pathname === \"/\" ? defaultUrl.pathname : _url.pathname)\n // Remove trailing slash\n .replace(/\\/$/, \"\");\n const base = `${_url.origin}${path}`;\n return {\n origin: _url.origin,\n host: _url.host,\n path,\n base,\n toString: () => base,\n };\n}\n"],"names":[],"mappings":";;;;;;;;;;;;;;AACA;AACA;AAFA;;;AAGA,UAAU,GACV,MAAM,yBAAyB,oMAAS;AACxC;AAEO,MAAM,2BAA2B,oMAAS;AACjD;AAUO,eAAe,UAAU,IAAI,EAAE,UAAU,EAAE,MAAM,EAAE,MAAM,CAAC,CAAC;IAC9D,MAAM,MAAM,GAAG,WAAW,YA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;QAChC,MAAM,CAAC,QAAQ,EAAE,KAAK;IAC1B;IACA,MAAM,OAAO,IAAI,IAAI,OAAO;IAC5B,MAAM,OAAO,CAAC,KAAK,QAAQ,KAAK,MAAM,WAAW,QAAQ,GAAG,KAAK,QAAQ,CACrE,wBAAwB;KACvB,OAAO,CAAC,OAAO;IACpB,MAAM,OAAO,GAAG,KAAK,MAAM,GAAG,MAAM;IACpC,OAAO;QACH,QAAQ,KAAK,MAAM;QACnB,MAAM,KAAK,IAAI;QACf;QACA;QACA,UAAU,IAAM;IACpB;AACJ","ignoreList":[0]}}, + {"offset": {"line": 1012, "column": 0}, "map": {"version":3,"sources":["file:///C:/Users/streaper2/Documents/00%20-%20projet/plumeia/node_modules/next-auth/react.js"],"sourcesContent":["/**\n *\n * NextAuth.js is the official integration of Auth.js for Next.js applications. It supports both\n * [Client Components](https://nextjs.org/docs/app/building-your-application/rendering/client-components) and the\n * [Pages Router](https://nextjs.org/docs/pages). It includes methods for signing in, signing out, hooks, and a React\n * Context provider to wrap your application and make session data available anywhere.\n *\n * For use in [Server Actions](https://nextjs.org/docs/app/api-reference/functions/server-actions), check out [these methods](https://authjs.dev/guides/upgrade-to-v5#methods)\n *\n * @module react\n */\n\"use client\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport * as React from \"react\";\nimport { apiBaseUrl, ClientSessionError, fetchData, now, parseUrl, useOnline, } from \"./lib/client.js\";\n// This behaviour mirrors the default behaviour for getting the site name that\n// happens server side in server/index.js\n// 1. An empty value is legitimate when the code is being invoked client side as\n// relative URLs are valid in that context and so defaults to empty.\n// 2. When invoked server side the value is picked up from an environment\n// variable and defaults to 'http://localhost:3000'.\nexport const __NEXTAUTH = {\n baseUrl: parseUrl(process.env.NEXTAUTH_URL ?? process.env.VERCEL_URL).origin,\n basePath: parseUrl(process.env.NEXTAUTH_URL).path,\n baseUrlServer: parseUrl(process.env.NEXTAUTH_URL_INTERNAL ??\n process.env.NEXTAUTH_URL ??\n process.env.VERCEL_URL).origin,\n basePathServer: parseUrl(process.env.NEXTAUTH_URL_INTERNAL ?? process.env.NEXTAUTH_URL).path,\n _lastSync: 0,\n _session: undefined,\n _getSession: () => { },\n};\n// https://github.com/nextauthjs/next-auth/pull/10762\nlet broadcastChannel = null;\nfunction getNewBroadcastChannel() {\n if (typeof BroadcastChannel === \"undefined\") {\n return {\n postMessage: () => { },\n addEventListener: () => { },\n removeEventListener: () => { },\n name: \"next-auth\",\n onmessage: null,\n onmessageerror: null,\n close: () => { },\n dispatchEvent: () => false,\n };\n }\n return new BroadcastChannel(\"next-auth\");\n}\nfunction broadcast() {\n if (broadcastChannel === null) {\n broadcastChannel = getNewBroadcastChannel();\n }\n return broadcastChannel;\n}\n// TODO:\nconst logger = {\n debug: console.debug,\n error: console.error,\n warn: console.warn,\n};\nexport const SessionContext = React.createContext?.(undefined);\n/**\n * React Hook that gives you access to the logged in user's session data and lets you modify it.\n *\n * :::info\n * `useSession` is for client-side use only and when using [Next.js App Router (`app/`)](https://nextjs.org/blog/next-13-4#nextjs-app-router) you should prefer the `auth()` export.\n * :::\n */\nexport function useSession(options) {\n if (!SessionContext) {\n throw new Error(\"React Context is unavailable in Server Components\");\n }\n // @ts-expect-error Satisfy TS if branch on line below\n const value = React.useContext(SessionContext);\n if (!value && process.env.NODE_ENV !== \"production\") {\n throw new Error(\"[next-auth]: `useSession` must be wrapped in a \");\n }\n const { required, onUnauthenticated } = options ?? {};\n const requiredAndNotLoading = required && value.status === \"unauthenticated\";\n React.useEffect(() => {\n if (requiredAndNotLoading) {\n const url = `${__NEXTAUTH.basePath}/signin?${new URLSearchParams({\n error: \"SessionRequired\",\n callbackUrl: window.location.href,\n })}`;\n if (onUnauthenticated)\n onUnauthenticated();\n else\n window.location.href = url;\n }\n }, [requiredAndNotLoading, onUnauthenticated]);\n if (requiredAndNotLoading) {\n return {\n data: value.data,\n update: value.update,\n status: \"loading\",\n };\n }\n return value;\n}\nexport async function getSession(params) {\n const session = await fetchData(\"session\", __NEXTAUTH, logger, params);\n if (params?.broadcast ?? true) {\n // https://github.com/nextauthjs/next-auth/pull/11470\n getNewBroadcastChannel().postMessage({\n event: \"session\",\n data: { trigger: \"getSession\" },\n });\n }\n return session;\n}\n/**\n * Returns the current Cross-Site Request Forgery Token (CSRF Token)\n * required to make requests that changes state. (e.g. signing in or out, or updating the session).\n *\n * [CSRF Prevention: Double Submit Cookie](https://cheatsheetseries.owasp.org/cheatsheets/Cross-Site_Request_Forgery_Prevention_Cheat_Sheet.html#double-submit-cookie)\n */\nexport async function getCsrfToken() {\n const response = await fetchData(\"csrf\", __NEXTAUTH, logger);\n return response?.csrfToken ?? \"\";\n}\nexport async function getProviders() {\n return fetchData(\"providers\", __NEXTAUTH, logger);\n}\nexport async function signIn(provider, options, authorizationParams) {\n const { callbackUrl, ...rest } = options ?? {};\n const { redirect = true, redirectTo = callbackUrl ?? window.location.href, ...signInParams } = rest;\n const baseUrl = apiBaseUrl(__NEXTAUTH);\n const providers = await getProviders();\n if (!providers) {\n const url = `${baseUrl}/error`;\n window.location.href = url;\n return; // TODO: Return error if `redirect: false`\n }\n if (!provider || !providers[provider]) {\n const url = `${baseUrl}/signin?${new URLSearchParams({\n callbackUrl: redirectTo,\n })}`;\n window.location.href = url;\n return; // TODO: Return error if `redirect: false`\n }\n const providerType = providers[provider].type;\n if (providerType === \"webauthn\") {\n // TODO: Add docs link with explanation\n throw new TypeError([\n `Provider id \"${provider}\" refers to a WebAuthn provider.`,\n 'Please use `import { signIn } from \"next-auth/webauthn\"` instead.',\n ].join(\"\\n\"));\n }\n const signInUrl = `${baseUrl}/${providerType === \"credentials\" ? \"callback\" : \"signin\"}/${provider}`;\n const csrfToken = await getCsrfToken();\n const res = await fetch(`${signInUrl}?${new URLSearchParams(authorizationParams)}`, {\n method: \"post\",\n headers: {\n \"Content-Type\": \"application/x-www-form-urlencoded\",\n \"X-Auth-Return-Redirect\": \"1\",\n },\n body: new URLSearchParams({\n ...signInParams,\n csrfToken,\n callbackUrl: redirectTo,\n }),\n });\n const data = await res.json();\n if (redirect) {\n const url = data.url ?? redirectTo;\n window.location.href = url;\n // If url contains a hash, the browser does not reload the page. We reload manually\n if (url.includes(\"#\"))\n window.location.reload();\n return;\n }\n const error = new URL(data.url).searchParams.get(\"error\") ?? undefined;\n const code = new URL(data.url).searchParams.get(\"code\") ?? undefined;\n if (res.ok) {\n await __NEXTAUTH._getSession({ event: \"storage\" });\n }\n return {\n error,\n code,\n status: res.status,\n ok: res.ok,\n url: error ? null : data.url,\n };\n}\nexport async function signOut(options) {\n const { redirect = true, redirectTo = options?.callbackUrl ?? window.location.href, } = options ?? {};\n const baseUrl = apiBaseUrl(__NEXTAUTH);\n const csrfToken = await getCsrfToken();\n const res = await fetch(`${baseUrl}/signout`, {\n method: \"post\",\n headers: {\n \"Content-Type\": \"application/x-www-form-urlencoded\",\n \"X-Auth-Return-Redirect\": \"1\",\n },\n body: new URLSearchParams({ csrfToken, callbackUrl: redirectTo }),\n });\n const data = await res.json();\n broadcast().postMessage({ event: \"session\", data: { trigger: \"signout\" } });\n if (redirect) {\n const url = data.url ?? redirectTo;\n window.location.href = url;\n // If url contains a hash, the browser does not reload the page. We reload manually\n if (url.includes(\"#\"))\n window.location.reload();\n return;\n }\n await __NEXTAUTH._getSession({ event: \"storage\" });\n return data;\n}\n/**\n * [React Context](https://react.dev/learn/passing-data-deeply-with-context) provider to wrap the app (`pages/`) to make session data available anywhere.\n *\n * When used, the session state is automatically synchronized across all open tabs/windows and they are all updated whenever they gain or lose focus\n * or the state changes (e.g. a user signs in or out) when {@link SessionProviderProps.refetchOnWindowFocus} is `true`.\n *\n * :::info\n * `SessionProvider` is for client-side use only and when using [Next.js App Router (`app/`)](https://nextjs.org/blog/next-13-4#nextjs-app-router) you should prefer the `auth()` export.\n * :::\n */\nexport function SessionProvider(props) {\n if (!SessionContext) {\n throw new Error(\"React Context is unavailable in Server Components\");\n }\n const { children, basePath, refetchInterval, refetchWhenOffline } = props;\n if (basePath)\n __NEXTAUTH.basePath = basePath;\n /**\n * If session was `null`, there was an attempt to fetch it,\n * but it failed, but we still treat it as a valid initial value.\n */\n const hasInitialSession = props.session !== undefined;\n /** If session was passed, initialize as already synced */\n __NEXTAUTH._lastSync = hasInitialSession ? now() : 0;\n const [session, setSession] = React.useState(() => {\n if (hasInitialSession)\n __NEXTAUTH._session = props.session;\n return props.session;\n });\n /** If session was passed, initialize as not loading */\n const [loading, setLoading] = React.useState(!hasInitialSession);\n React.useEffect(() => {\n __NEXTAUTH._getSession = async ({ event } = {}) => {\n try {\n const storageEvent = event === \"storage\";\n // We should always update if we don't have a client session yet\n // or if there are events from other tabs/windows\n if (storageEvent || __NEXTAUTH._session === undefined) {\n __NEXTAUTH._lastSync = now();\n __NEXTAUTH._session = await getSession({\n broadcast: !storageEvent,\n });\n setSession(__NEXTAUTH._session);\n return;\n }\n if (\n // If there is no time defined for when a session should be considered\n // stale, then it's okay to use the value we have until an event is\n // triggered which updates it\n !event ||\n // If the client doesn't have a session then we don't need to call\n // the server to check if it does (if they have signed in via another\n // tab or window that will come through as a \"stroage\" event\n // event anyway)\n __NEXTAUTH._session === null ||\n // Bail out early if the client session is not stale yet\n now() < __NEXTAUTH._lastSync) {\n return;\n }\n // An event or session staleness occurred, update the client session.\n __NEXTAUTH._lastSync = now();\n __NEXTAUTH._session = await getSession();\n setSession(__NEXTAUTH._session);\n }\n catch (error) {\n logger.error(new ClientSessionError(error.message, error));\n }\n finally {\n setLoading(false);\n }\n };\n __NEXTAUTH._getSession();\n return () => {\n __NEXTAUTH._lastSync = 0;\n __NEXTAUTH._session = undefined;\n __NEXTAUTH._getSession = () => { };\n };\n }, []);\n React.useEffect(() => {\n const handle = () => __NEXTAUTH._getSession({ event: \"storage\" });\n // Listen for storage events and update session if event fired from\n // another window (but suppress firing another event to avoid a loop)\n // Fetch new session data but tell it to not to fire another event to\n // avoid an infinite loop.\n // Note: We could pass session data through and do something like\n // `setData(message.data)` but that can cause problems depending\n // on how the session object is being used in the client; it is\n // more robust to have each window/tab fetch it's own copy of the\n // session object rather than share it across instances.\n broadcast().addEventListener(\"message\", handle);\n return () => broadcast().removeEventListener(\"message\", handle);\n }, []);\n React.useEffect(() => {\n const { refetchOnWindowFocus = true } = props;\n // Listen for when the page is visible, if the user switches tabs\n // and makes our tab visible again, re-fetch the session, but only if\n // this feature is not disabled.\n const visibilityHandler = () => {\n if (refetchOnWindowFocus && document.visibilityState === \"visible\")\n __NEXTAUTH._getSession({ event: \"visibilitychange\" });\n };\n document.addEventListener(\"visibilitychange\", visibilityHandler, false);\n return () => document.removeEventListener(\"visibilitychange\", visibilityHandler, false);\n }, [props.refetchOnWindowFocus]);\n const isOnline = useOnline();\n // TODO: Flip this behavior in next major version\n const shouldRefetch = refetchWhenOffline !== false || isOnline;\n React.useEffect(() => {\n if (refetchInterval && shouldRefetch) {\n const refetchIntervalTimer = setInterval(() => {\n if (__NEXTAUTH._session) {\n __NEXTAUTH._getSession({ event: \"poll\" });\n }\n }, refetchInterval * 1000);\n return () => clearInterval(refetchIntervalTimer);\n }\n }, [refetchInterval, shouldRefetch]);\n const value = React.useMemo(() => ({\n data: session,\n status: loading\n ? \"loading\"\n : session\n ? \"authenticated\"\n : \"unauthenticated\",\n async update(data) {\n if (loading)\n return;\n setLoading(true);\n const newSession = await fetchData(\"session\", __NEXTAUTH, logger, typeof data === \"undefined\"\n ? undefined\n : { body: { csrfToken: await getCsrfToken(), data } });\n setLoading(false);\n if (newSession) {\n setSession(newSession);\n broadcast().postMessage({\n event: \"session\",\n data: { trigger: \"getSession\" },\n });\n }\n return newSession;\n },\n }), [session, loading]);\n return (\n // @ts-expect-error\n _jsx(SessionContext.Provider, { value: value, children: children }));\n}\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;AAsBsB;AAVtB;AACA;AACA;AAdA;;;;;;;;;;CAUC,GACD;;;;AAUO,MAAM,aAAa;IACtB,SAAS,IAAA,wMAAQ,EAAC,uNAAO,CAAC,GAAG,CAAC,YAAY,IAAI,uN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;QAAC;QAAS;KAAQ;IACtB,OACA,mBAAmB;IACnB,IAAA,yNAAI,EAAC,eAAe,QAAQ,EAAE;QAAE,OAAO;QAAO,UAAU;IAAS;AACrE","ignoreList":[0]}}] } \ No newline at end of file diff --git a/.next/dev/trace b/.next/dev/trace index 156c65a..93ec351 100644 --- a/.next/dev/trace +++ b/.next/dev/trace @@ -72,3 +72,17 @@ [{"name":"handle-request","duration":49860,"timestamp":483851008196,"id":69,"tags":{"url":"/api/projects"},"startTime":1772230396008,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":11,"timestamp":483851058152,"id":72,"parentId":69,"tags":{"url":"/api/projects","memory.rss":"564441088","memory.heapUsed":"131806656","memory.heapTotal":"143699968"},"startTime":1772230396058,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":551,"timestamp":483851059724,"id":74,"parentId":3,"tags":{"inputPage":"/api/projects/route"},"startTime":1772230396059,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":25704,"timestamp":483851059409,"id":73,"tags":{"url":"/api/projects"},"startTime":1772230396059,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":483851085137,"id":75,"parentId":73,"tags":{"url":"/api/projects","memory.rss":"565547008","memory.heapUsed":"133471584","memory.heapTotal":"143699968"},"startTime":1772230396085,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":536,"timestamp":483851086423,"id":77,"parentId":3,"tags":{"inputPage":"/api/projects/route"},"startTime":1772230396086,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":14821,"timestamp":483851086106,"id":76,"tags":{"url":"/api/projects"},"startTime":1772230396086,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":483851100949,"id":78,"parentId":76,"tags":{"url":"/api/projects","memory.rss":"567508992","memory.heapUsed":"133403592","memory.heapTotal":"153137152"},"startTime":1772230396101,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":247,"timestamp":483858611802,"id":79,"parentId":3,"tags":{"inputPage":"/project/cmm4125nw0002s0i93fuqcown"},"startTime":1772230403611,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":103,"timestamp":483858612072,"id":80,"parentId":3,"tags":{"inputPage":"/project/cmm4125nw0002s0i93fuqcown"},"startTime":1772230403612,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":335,"timestamp":483858612741,"id":81,"parentId":3,"tags":{"inputPage":"/project/cmm4125nw0002s0i93fuqcown"},"startTime":1772230403612,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":151,"timestamp":483858613101,"id":82,"parentId":3,"tags":{"inputPage":"/project/cmm4125nw0002s0i93fuqcown"},"startTime":1772230403613,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":140,"timestamp":483858614555,"id":86,"parentId":3,"tags":{"inputPage":"/api/projects/cmm4125nw0002s0i93fuqcown"},"startTime":1772230403614,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":143,"timestamp":483858614715,"id":87,"parentId":3,"tags":{"inputPage":"/api/projects/cmm4125nw0002s0i93fuqcown"},"startTime":1772230403614,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":377,"timestamp":483858615449,"id":88,"parentId":3,"tags":{"inputPage":"/api/projects/cmm4125nw0002s0i93fuqcown"},"startTime":1772230403615,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":122,"timestamp":483858615844,"id":89,"parentId":3,"tags":{"inputPage":"/api/projects/cmm4125nw0002s0i93fuqcown"},"startTime":1772230403615,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":5284,"timestamp":483858616680,"id":91,"parentId":3,"tags":{"inputPage":"/api/projects/[id]/route"},"startTime":1772230403616,"traceId":"ac832ea7e7a97813"},{"name":"compile-path","duration":34401,"timestamp":483858614415,"id":85,"tags":{"trigger":"/project/[id]"},"startTime":1772230403614,"traceId":"ac832ea7e7a97813"}] [{"name":"handle-request","duration":327206,"timestamp":483858614079,"id":83,"tags":{"url":"/project/cmm4125nw0002s0i93fuqcown?_rsc=1h1b5"},"startTime":1772230403614,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":483858941304,"id":92,"parentId":83,"tags":{"url":"/project/cmm4125nw0002s0i93fuqcown?_rsc=1h1b5","memory.rss":"639041536","memory.heapUsed":"140727312","memory.heapTotal":"158384128"},"startTime":1772230403941,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":521,"timestamp":483858988438,"id":94,"parentId":3,"tags":{"inputPage":"/api/projects/route"},"startTime":1772230403988,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":15533,"timestamp":483858988184,"id":93,"tags":{"url":"/api/projects"},"startTime":1772230403988,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":483859003743,"id":95,"parentId":93,"tags":{"url":"/api/projects","memory.rss":"656338944","memory.heapUsed":"143574792","memory.heapTotal":"158384128"},"startTime":1772230404003,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":632,"timestamp":483859004762,"id":97,"parentId":3,"tags":{"inputPage":"/api/projects/route"},"startTime":1772230404004,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":27600,"timestamp":483859004554,"id":96,"tags":{"url":"/api/projects"},"startTime":1772230404004,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":3,"timestamp":483859032191,"id":98,"parentId":96,"tags":{"url":"/api/projects","memory.rss":"659750912","memory.heapUsed":"142067184","memory.heapTotal":"161267712"},"startTime":1772230404032,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":622419,"timestamp":483858616471,"id":90,"tags":{"url":"/api/projects/cmm4125nw0002s0i93fuqcown"},"startTime":1772230403616,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":483859238916,"id":99,"parentId":90,"tags":{"url":"/api/projects/cmm4125nw0002s0i93fuqcown","memory.rss":"660803584","memory.heapUsed":"144477848","memory.heapTotal":"161411072"},"startTime":1772230404239,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":182,"timestamp":483859239638,"id":100,"parentId":3,"tags":{"inputPage":"/api/projects/cmm4125nw0002s0i93fuqcown"},"startTime":1772230404239,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":103,"timestamp":483859239839,"id":101,"parentId":3,"tags":{"inputPage":"/api/projects/cmm4125nw0002s0i93fuqcown"},"startTime":1772230404239,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":148,"timestamp":483859240292,"id":102,"parentId":3,"tags":{"inputPage":"/api/projects/cmm4125nw0002s0i93fuqcown"},"startTime":1772230404240,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":98,"timestamp":483859240455,"id":103,"parentId":3,"tags":{"inputPage":"/api/projects/cmm4125nw0002s0i93fuqcown"},"startTime":1772230404240,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":475,"timestamp":483859241083,"id":105,"parentId":3,"tags":{"inputPage":"/api/projects/[id]/route"},"startTime":1772230404241,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":25339,"timestamp":483859240896,"id":104,"tags":{"url":"/api/projects/cmm4125nw0002s0i93fuqcown"},"startTime":1772230404241,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":3,"timestamp":483859266269,"id":106,"parentId":104,"tags":{"url":"/api/projects/cmm4125nw0002s0i93fuqcown","memory.rss":"661737472","memory.heapUsed":"147099088","memory.heapTotal":"162664448"},"startTime":1772230404266,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":223,"timestamp":483863595889,"id":107,"parentId":3,"tags":{"inputPage":"/project/cmm4125nw0002s0i93fuqcown/world"},"startTime":1772230408595,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":116,"timestamp":483863596136,"id":108,"parentId":3,"tags":{"inputPage":"/project/cmm4125nw0002s0i93fuqcown/world"},"startTime":1772230408596,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":159,"timestamp":483863596663,"id":109,"parentId":3,"tags":{"inputPage":"/project/cmm4125nw0002s0i93fuqcown/world"},"startTime":1772230408596,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":106,"timestamp":483863596840,"id":110,"parentId":3,"tags":{"inputPage":"/project/cmm4125nw0002s0i93fuqcown/world"},"startTime":1772230408596,"traceId":"ac832ea7e7a97813"},{"name":"compile-path","duration":360354,"timestamp":483863597765,"id":113,"tags":{"trigger":"/project/[id]/world"},"startTime":1772230408597,"traceId":"ac832ea7e7a97813"}] [{"name":"handle-request","duration":668522,"timestamp":483863597432,"id":111,"tags":{"url":"/project/cmm4125nw0002s0i93fuqcown/world?_rsc=1mgu0"},"startTime":1772230408597,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":483864265980,"id":114,"parentId":111,"tags":{"url":"/project/cmm4125nw0002s0i93fuqcown/world?_rsc=1mgu0","memory.rss":"880676864","memory.heapUsed":"148626544","memory.heapTotal":"183623680"},"startTime":1772230409266,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":816,"timestamp":483864321981,"id":116,"parentId":3,"tags":{"inputPage":"/api/projects/route"},"startTime":1772230409322,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":36530,"timestamp":483864321743,"id":115,"tags":{"url":"/api/projects"},"startTime":1772230409321,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":3,"timestamp":483864358313,"id":117,"parentId":115,"tags":{"url":"/api/projects","memory.rss":"881725440","memory.heapUsed":"143567368","memory.heapTotal":"183611392"},"startTime":1772230409358,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":1410,"timestamp":483864359751,"id":119,"parentId":3,"tags":{"inputPage":"/api/projects/route"},"startTime":1772230409359,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":27188,"timestamp":483864359384,"id":118,"tags":{"url":"/api/projects"},"startTime":1772230409359,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":483864386598,"id":120,"parentId":118,"tags":{"url":"/api/projects","memory.rss":"881999872","memory.heapUsed":"145075560","memory.heapTotal":"183873536"},"startTime":1772230409386,"traceId":"ac832ea7e7a97813"},{"name":"compile-path","duration":83677,"timestamp":483873687248,"id":123,"tags":{"trigger":"/api/entities"},"startTime":1772230418687,"traceId":"ac832ea7e7a97813"}] +[{"name":"handle-request","duration":136169,"timestamp":483873686705,"id":121,"tags":{"url":"/api/entities"},"startTime":1772230418686,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":1,"timestamp":483873822894,"id":124,"parentId":121,"tags":{"url":"/api/entities","memory.rss":"905388032","memory.heapUsed":"139030656","memory.heapTotal":"147099648"},"startTime":1772230418823,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":491,"timestamp":483991034367,"id":126,"parentId":3,"tags":{"inputPage":"/api/projects/route"},"startTime":1772230536034,"traceId":"ac832ea7e7a97813"},{"name":"client-hmr-latency","duration":282000,"timestamp":483990736295,"id":127,"parentId":3,"tags":{"updatedModules":["[project]/Documents/00 - projet/plumeia/src/providers/ProjectProvider.tsx [app-client]"],"page":"/project/cmm4125nw0002s0i93fuqcown/world","isPageHidden":false},"startTime":1772230536081,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":52552,"timestamp":483991034149,"id":125,"tags":{"url":"/api/projects"},"startTime":1772230536034,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":483991086725,"id":128,"parentId":125,"tags":{"url":"/api/projects","memory.rss":"900661248","memory.heapUsed":"139942536","memory.heapTotal":"145002496"},"startTime":1772230536086,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":605,"timestamp":483991087761,"id":130,"parentId":3,"tags":{"inputPage":"/api/projects/route"},"startTime":1772230536087,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":18347,"timestamp":483991087572,"id":129,"tags":{"url":"/api/projects"},"startTime":1772230536087,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":3,"timestamp":483991105950,"id":131,"parentId":129,"tags":{"url":"/api/projects","memory.rss":"901009408","memory.heapUsed":"140909704","memory.heapTotal":"146313216"},"startTime":1772230536105,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":200,"timestamp":484005575198,"id":134,"parentId":3,"tags":{"inputPage":"/api/projects/cmm4125nw0002s0i93fuqcown"},"startTime":1772230550575,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":122,"timestamp":484005575422,"id":135,"parentId":3,"tags":{"inputPage":"/api/projects/cmm4125nw0002s0i93fuqcown"},"startTime":1772230550575,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":919,"timestamp":484005575038,"id":133,"parentId":3,"tags":{"inputPage":"/api/projects/route"},"startTime":1772230550575,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":183,"timestamp":484005579098,"id":136,"parentId":3,"tags":{"inputPage":"/api/projects/cmm4125nw0002s0i93fuqcown"},"startTime":1772230550579,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":103,"timestamp":484005579302,"id":137,"parentId":3,"tags":{"inputPage":"/api/projects/cmm4125nw0002s0i93fuqcown"},"startTime":1772230550579,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":644,"timestamp":484005580761,"id":139,"parentId":3,"tags":{"inputPage":"/api/projects/[id]/route"},"startTime":1772230550580,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":50112,"timestamp":484005574787,"id":132,"tags":{"url":"/api/projects"},"startTime":1772230550574,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":3,"timestamp":484005624933,"id":140,"parentId":132,"tags":{"url":"/api/projects","memory.rss":"899518464","memory.heapUsed":"142499720","memory.heapTotal":"147886080"},"startTime":1772230550624,"traceId":"ac832ea7e7a97813"},{"name":"client-hmr-latency","duration":44000,"timestamp":484005520554,"id":141,"parentId":3,"tags":{"updatedModules":["[project]/Documents/00 - projet/plumeia/src/app/project/[id]/layout.tsx [app-client]"],"page":"/project/cmm4125nw0002s0i93fuqcown/world","isPageHidden":false},"startTime":1772230550626,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":717,"timestamp":484005643935,"id":143,"parentId":3,"tags":{"inputPage":"/api/projects/route"},"startTime":1772230550643,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":75401,"timestamp":484005580519,"id":138,"tags":{"url":"/api/projects/cmm4125nw0002s0i93fuqcown"},"startTime":1772230550580,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":484005655946,"id":144,"parentId":138,"tags":{"url":"/api/projects/cmm4125nw0002s0i93fuqcown","memory.rss":"899903488","memory.heapUsed":"143564720","memory.heapTotal":"147599360"},"startTime":1772230550655,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":18524,"timestamp":484005643710,"id":142,"tags":{"url":"/api/projects"},"startTime":1772230550643,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":484005662261,"id":145,"parentId":142,"tags":{"url":"/api/projects","memory.rss":"899903488","memory.heapUsed":"143749992","memory.heapTotal":"147599360"},"startTime":1772230550662,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":491,"timestamp":484005664052,"id":147,"parentId":3,"tags":{"inputPage":"/api/projects/route"},"startTime":1772230550664,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":19820,"timestamp":484005663676,"id":146,"tags":{"url":"/api/projects"},"startTime":1772230550663,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":484005683524,"id":148,"parentId":146,"tags":{"url":"/api/projects","memory.rss":"900595712","memory.heapUsed":"144021768","memory.heapTotal":"149172224"},"startTime":1772230550683,"traceId":"ac832ea7e7a97813"},{"name":"client-hmr-latency","duration":41000,"timestamp":484031553817,"id":149,"parentId":3,"tags":{"updatedModules":["[project]/Documents/00 - projet/plumeia/src/app/project/[id]/world/page.tsx [app-client]"],"page":"/project/cmm4125nw0002s0i93fuqcown/world","isPageHidden":false},"startTime":1772230576625,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":576,"timestamp":484423089003,"id":151,"parentId":3,"tags":{"inputPage":"/api/entities/route"},"startTime":1772230968088,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":39296,"timestamp":484423088726,"id":150,"tags":{"url":"/api/entities"},"startTime":1772230968088,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":484423128054,"id":152,"parentId":150,"tags":{"url":"/api/entities","memory.rss":"938954752","memory.heapUsed":"144917520","memory.heapTotal":"149434368"},"startTime":1772230968127,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":507,"timestamp":484433534707,"id":154,"parentId":3,"tags":{"inputPage":"/api/entities/route"},"startTime":1772230978534,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":55210,"timestamp":484433534497,"id":153,"tags":{"url":"/api/entities"},"startTime":1772230978534,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":484433589730,"id":155,"parentId":153,"tags":{"url":"/api/entities","memory.rss":"955314176","memory.heapUsed":"145684376","memory.heapTotal":"151007232"},"startTime":1772230978589,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":419,"timestamp":484500505197,"id":156,"parentId":3,"tags":{"inputPage":"/project/cmm4125nw0002s0i93fuqcown"},"startTime":1772231045505,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":314,"timestamp":484500505655,"id":157,"parentId":3,"tags":{"inputPage":"/project/cmm4125nw0002s0i93fuqcown"},"startTime":1772231045505,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":281,"timestamp":484500506903,"id":158,"parentId":3,"tags":{"inputPage":"/project/cmm4125nw0002s0i93fuqcown"},"startTime":1772231045507,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":162,"timestamp":484500507212,"id":159,"parentId":3,"tags":{"inputPage":"/project/cmm4125nw0002s0i93fuqcown"},"startTime":1772231045507,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":13164,"timestamp":484500508443,"id":161,"parentId":3,"tags":{"inputPage":"/project/[id]/page"},"startTime":1772231045508,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":120360,"timestamp":484500508128,"id":160,"tags":{"url":"/project/cmm4125nw0002s0i93fuqcown?_rsc=te6sc"},"startTime":1772231045508,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":3,"timestamp":484500628523,"id":162,"parentId":160,"tags":{"url":"/project/cmm4125nw0002s0i93fuqcown?_rsc=te6sc","memory.rss":"944447488","memory.heapUsed":"148460376","memory.heapTotal":"159789056"},"startTime":1772231045628,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":970,"timestamp":484583262053,"id":164,"parentId":3,"tags":{"inputPage":"/dashboard/page"},"startTime":1772231128262,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":12626,"timestamp":484583261601,"id":163,"tags":{"url":"/dashboard?_rsc=1mgu0"},"startTime":1772231128261,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":484583274256,"id":165,"parentId":163,"tags":{"url":"/dashboard?_rsc=1mgu0","memory.rss":"947777536","memory.heapUsed":"151035696","memory.heapTotal":"160051200"},"startTime":1772231128274,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":944,"timestamp":484583310750,"id":167,"parentId":3,"tags":{"inputPage":"/api/projects/route"},"startTime":1772231128310,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":67121,"timestamp":484583310268,"id":166,"tags":{"url":"/api/projects"},"startTime":1772231128310,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":4,"timestamp":484583377425,"id":168,"parentId":166,"tags":{"url":"/api/projects","memory.rss":"949547008","memory.heapUsed":"149446632","memory.heapTotal":"155594752"},"startTime":1772231128377,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":805,"timestamp":484583378708,"id":170,"parentId":3,"tags":{"inputPage":"/api/projects/route"},"startTime":1772231128378,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":27391,"timestamp":484583378510,"id":169,"tags":{"url":"/api/projects"},"startTime":1772231128378,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":3,"timestamp":484583405934,"id":171,"parentId":169,"tags":{"url":"/api/projects","memory.rss":"949809152","memory.heapUsed":"150155328","memory.heapTotal":"154284032"},"startTime":1772231128406,"traceId":"ac832ea7e7a97813"},{"name":"compile-path","duration":142486,"timestamp":484585077589,"id":174,"tags":{"trigger":"/profile"},"startTime":1772231130077,"traceId":"ac832ea7e7a97813"}] +[{"name":"handle-request","duration":164041,"timestamp":484585077341,"id":172,"tags":{"url":"/profile?_rsc=1h1b5"},"startTime":1772231130077,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":484585241406,"id":175,"parentId":172,"tags":{"url":"/profile?_rsc=1h1b5","memory.rss":"975409152","memory.heapUsed":"153201624","memory.heapTotal":"158195712"},"startTime":1772231130241,"traceId":"ac832ea7e7a97813"},{"name":"client-hmr-latency","duration":48000,"timestamp":484712724291,"id":176,"parentId":3,"tags":{"updatedModules":["[project]/Documents/00 - projet/plumeia/src/components/UserProfileSettings.tsx [app-client]"],"page":"/profile","isPageHidden":true},"startTime":1772231257801,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":1750,"timestamp":485199626916,"id":178,"parentId":3,"tags":{"inputPage":"/dashboard/page"},"startTime":1772231744627,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":52131,"timestamp":485199626524,"id":177,"tags":{"url":"/dashboard"},"startTime":1772231744626,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485199678680,"id":179,"parentId":177,"tags":{"url":"/dashboard","memory.rss":"993296384","memory.heapUsed":"150521648","memory.heapTotal":"154742784"},"startTime":1772231744678,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":388,"timestamp":485199718050,"id":180,"parentId":3,"tags":{"inputPage":"/.well-known/appspecific/com.chrome.devtools.json"},"startTime":1772231744718,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":355,"timestamp":485199718479,"id":181,"parentId":3,"tags":{"inputPage":"/.well-known/appspecific/com.chrome.devtools.json"},"startTime":1772231744718,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":334,"timestamp":485199719597,"id":182,"parentId":3,"tags":{"inputPage":"/.well-known/appspecific/com.chrome.devtools.json"},"startTime":1772231744719,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":268,"timestamp":485199719958,"id":183,"parentId":3,"tags":{"inputPage":"/.well-known/appspecific/com.chrome.devtools.json"},"startTime":1772231744720,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":350,"timestamp":485200201708,"id":184,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231745201,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":317,"timestamp":485200202092,"id":185,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231745202,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":302,"timestamp":485200202927,"id":186,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231745203,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":275,"timestamp":485200203256,"id":187,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231745203,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":909,"timestamp":485200204539,"id":189,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772231745204,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":21876,"timestamp":485200204107,"id":188,"tags":{"url":"/api/auth/session"},"startTime":1772231745204,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":3,"timestamp":485200226016,"id":190,"parentId":188,"tags":{"url":"/api/auth/session","memory.rss":"997867520","memory.heapUsed":"152892840","memory.heapTotal":"160485376"},"startTime":1772231745226,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":240,"timestamp":485200240940,"id":191,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231745241,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":163,"timestamp":485200241213,"id":192,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231745241,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":227,"timestamp":485200242499,"id":193,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231745242,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":162,"timestamp":485200242753,"id":194,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231745242,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":1728,"timestamp":485200243532,"id":196,"parentId":3,"tags":{"inputPage":"/login/page"},"startTime":1772231745243,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":17597,"timestamp":485200243985,"id":198,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772231745244,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":2118,"timestamp":485200266248,"id":200,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772231745266,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":34417,"timestamp":485200243182,"id":195,"tags":{"url":"/login?_rsc=1h1b5"},"startTime":1772231745243,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":4,"timestamp":485200277637,"id":201,"parentId":195,"tags":{"url":"/login?_rsc=1h1b5","memory.rss":"1001193472","memory.heapUsed":"155162712","memory.heapTotal":"162058240"},"startTime":1772231745277,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":18358,"timestamp":485200265866,"id":199,"tags":{"url":"/api/auth/session"},"startTime":1772231745266,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":4,"timestamp":485200284264,"id":202,"parentId":199,"tags":{"url":"/api/auth/session","memory.rss":"1001267200","memory.heapUsed":"155823240","memory.heapTotal":"162058240"},"startTime":1772231745284,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":652,"timestamp":485200287739,"id":203,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231745287,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":292,"timestamp":485200288428,"id":204,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231745288,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":308,"timestamp":485200289874,"id":205,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231745290,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":250,"timestamp":485200290212,"id":206,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231745290,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":573,"timestamp":485200291365,"id":208,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772231745291,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":1318,"timestamp":485200297837,"id":210,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772231745298,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":17494,"timestamp":485200291085,"id":207,"tags":{"url":"/api/auth/session"},"startTime":1772231745291,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":4,"timestamp":485200308617,"id":211,"parentId":207,"tags":{"url":"/api/auth/session","memory.rss":"1003507712","memory.heapUsed":"157798416","memory.heapTotal":"167768064"},"startTime":1772231745308,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":86994,"timestamp":485200243760,"id":197,"tags":{"url":"/api/user/profile"},"startTime":1772231745243,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":3,"timestamp":485200330793,"id":212,"parentId":197,"tags":{"url":"/api/user/profile","memory.rss":"1004240896","memory.heapUsed":"158624840","memory.heapTotal":"167768064"},"startTime":1772231745330,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":52819,"timestamp":485200297349,"id":209,"tags":{"url":"/api/user/profile"},"startTime":1772231745297,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":4,"timestamp":485200350212,"id":213,"parentId":209,"tags":{"url":"/api/user/profile","memory.rss":"1004666880","memory.heapUsed":"156792320","memory.heapTotal":"168816640"},"startTime":1772231745350,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":1009,"timestamp":485200354825,"id":215,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772231745355,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":33798,"timestamp":485200354383,"id":214,"tags":{"url":"/api/user/profile"},"startTime":1772231745354,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":3,"timestamp":485200388215,"id":216,"parentId":214,"tags":{"url":"/api/user/profile","memory.rss":"1005572096","memory.heapUsed":"158466216","memory.heapTotal":"168816640"},"startTime":1772231745388,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":173,"timestamp":485225851686,"id":217,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231770851,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":106,"timestamp":485225851883,"id":218,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231770852,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":163,"timestamp":485225852278,"id":219,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231770852,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":102,"timestamp":485225852458,"id":220,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231770852,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":558,"timestamp":485225853227,"id":222,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772231770853,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":11781,"timestamp":485225853006,"id":221,"tags":{"url":"/api/auth/session"},"startTime":1772231770853,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485225864817,"id":223,"parentId":221,"tags":{"url":"/api/auth/session","memory.rss":"1009147904","memory.heapUsed":"159228432","memory.heapTotal":"169340928"},"startTime":1772231770865,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":336,"timestamp":485225876538,"id":224,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231770876,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":230,"timestamp":485225876905,"id":225,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231770877,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":137,"timestamp":485225878176,"id":228,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231770878,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":91,"timestamp":485225878330,"id":229,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231770878,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":749,"timestamp":485225878044,"id":227,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772231770878,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":624,"timestamp":485225881474,"id":231,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772231770881,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":8361,"timestamp":485225881290,"id":230,"tags":{"url":"/api/auth/session"},"startTime":1772231770881,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485225889682,"id":232,"parentId":230,"tags":{"url":"/api/auth/session","memory.rss":"1010720768","memory.heapUsed":"159589632","memory.heapTotal":"164622336"},"startTime":1772231770889,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":179,"timestamp":485225890702,"id":233,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231770890,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":97,"timestamp":485225890900,"id":234,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231770891,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":529,"timestamp":485225892059,"id":235,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231770892,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":244,"timestamp":485225892619,"id":236,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231770892,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":762,"timestamp":485225893779,"id":238,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772231770893,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":8163,"timestamp":485225893429,"id":237,"tags":{"url":"/api/auth/session"},"startTime":1772231770893,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485225901623,"id":239,"parentId":237,"tags":{"url":"/api/auth/session","memory.rss":"1011740672","memory.heapUsed":"160284560","memory.heapTotal":"166719488"},"startTime":1772231770901,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":1813,"timestamp":485225904333,"id":241,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772231770904,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":529,"timestamp":485225910990,"id":243,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772231770911,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":56438,"timestamp":485225877738,"id":226,"tags":{"url":"/api/user/profile"},"startTime":1772231770877,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":3,"timestamp":485225934218,"id":244,"parentId":226,"tags":{"url":"/api/user/profile","memory.rss":"1011765248","memory.heapUsed":"161219232","memory.heapTotal":"165408768"},"startTime":1772231770934,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":57137,"timestamp":485225903651,"id":240,"tags":{"url":"/api/user/profile"},"startTime":1772231770903,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485225960813,"id":245,"parentId":240,"tags":{"url":"/api/user/profile","memory.rss":"1011765248","memory.heapUsed":"161297848","memory.heapTotal":"165670912"},"startTime":1772231770960,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":51251,"timestamp":485225910786,"id":242,"tags":{"url":"/api/user/profile"},"startTime":1772231770910,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":9,"timestamp":485225962102,"id":246,"parentId":242,"tags":{"url":"/api/user/profile","memory.rss":"1011793920","memory.heapUsed":"161487616","memory.heapTotal":"165670912"},"startTime":1772231770962,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":766,"timestamp":485246104012,"id":248,"parentId":3,"tags":{"inputPage":"/dashboard/page"},"startTime":1772231791104,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":12452,"timestamp":485246103744,"id":247,"tags":{"url":"/dashboard?_rsc=1ls1y"},"startTime":1772231791103,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":1,"timestamp":485246116215,"id":249,"parentId":247,"tags":{"url":"/dashboard?_rsc=1ls1y","memory.rss":"1010937856","memory.heapUsed":"154494616","memory.heapTotal":"165933056"},"startTime":1772231791116,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":474,"timestamp":485246146458,"id":251,"parentId":3,"tags":{"inputPage":"/api/projects/route"},"startTime":1772231791146,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":59161,"timestamp":485246146232,"id":250,"tags":{"url":"/api/projects"},"startTime":1772231791146,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485246205414,"id":252,"parentId":250,"tags":{"url":"/api/projects","memory.rss":"1010941952","memory.heapUsed":"154878760","memory.heapTotal":"165933056"},"startTime":1772231791205,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":1053,"timestamp":485246206342,"id":254,"parentId":3,"tags":{"inputPage":"/api/projects/route"},"startTime":1772231791206,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":14433,"timestamp":485246206152,"id":253,"tags":{"url":"/api/projects"},"startTime":1772231791206,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485246220606,"id":255,"parentId":253,"tags":{"url":"/api/projects","memory.rss":"1010954240","memory.heapUsed":"155835808","memory.heapTotal":"165933056"},"startTime":1772231791220,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":13217,"timestamp":485252278196,"id":257,"parentId":3,"tags":{"inputPage":"/profile/page"},"startTime":1772231797278,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":81013,"timestamp":485252277832,"id":256,"tags":{"url":"/profile?_rsc=1h1b5"},"startTime":1772231797278,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485252358876,"id":258,"parentId":256,"tags":{"url":"/profile?_rsc=1h1b5","memory.rss":"1027133440","memory.heapUsed":"173098248","memory.heapTotal":"193380352"},"startTime":1772231797359,"traceId":"ac832ea7e7a97813"},{"name":"client-hmr-latency","duration":34000,"timestamp":485332994654,"id":259,"parentId":3,"tags":{"updatedModules":["[project]/Documents/00 - projet/plumeia/src/components/UserProfileSettings.tsx [app-client]"],"page":"/profile","isPageHidden":false},"startTime":1772231878057,"traceId":"ac832ea7e7a97813"},{"name":"client-hmr-latency","duration":36000,"timestamp":485332994762,"id":260,"parentId":3,"tags":{"updatedModules":["[project]/Documents/00 - projet/plumeia/src/components/UserProfileSettings.tsx [app-client]"],"page":"/login","isPageHidden":true},"startTime":1772231878057,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":845,"timestamp":485409219151,"id":262,"parentId":3,"tags":{"inputPage":"/dashboard/page"},"startTime":1772231954218,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":12495,"timestamp":485409218684,"id":261,"tags":{"url":"/dashboard?_rsc=1ls1y"},"startTime":1772231954218,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":1,"timestamp":485409231200,"id":263,"parentId":261,"tags":{"url":"/dashboard?_rsc=1ls1y","memory.rss":"981057536","memory.heapUsed":"163974184","memory.heapTotal":"168407040"},"startTime":1772231954230,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":1289,"timestamp":485409265291,"id":265,"parentId":3,"tags":{"inputPage":"/api/projects/route"},"startTime":1772231954265,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":50728,"timestamp":485409264808,"id":264,"tags":{"url":"/api/projects"},"startTime":1772231954264,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485409315564,"id":266,"parentId":264,"tags":{"url":"/api/projects","memory.rss":"981028864","memory.heapUsed":"164545056","memory.heapTotal":"169455616"},"startTime":1772231954315,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":1001,"timestamp":485409316413,"id":268,"parentId":3,"tags":{"inputPage":"/api/projects/route"},"startTime":1772231954316,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":21513,"timestamp":485409316238,"id":267,"tags":{"url":"/api/projects"},"startTime":1772231954316,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485409337777,"id":269,"parentId":267,"tags":{"url":"/api/projects","memory.rss":"981770240","memory.heapUsed":"165024976","memory.heapTotal":"170242048"},"startTime":1772231954337,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":808,"timestamp":485412418807,"id":271,"parentId":3,"tags":{"inputPage":"/dashboard/page"},"startTime":1772231957418,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":25358,"timestamp":485412418601,"id":270,"tags":{"url":"/dashboard"},"startTime":1772231957418,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485412443985,"id":272,"parentId":270,"tags":{"url":"/dashboard","memory.rss":"997462016","memory.heapUsed":"166936032","memory.heapTotal":"172601344"},"startTime":1772231957443,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":212,"timestamp":485412671726,"id":273,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231957671,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":111,"timestamp":485412671968,"id":274,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231957671,"traceId":"ac832ea7e7a97813"}] +[{"name":"ensure-page","duration":174,"timestamp":485412672707,"id":275,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231957672,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":106,"timestamp":485412672899,"id":276,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231957672,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":473,"timestamp":485412673665,"id":278,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772231957673,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":12574,"timestamp":485412673404,"id":277,"tags":{"url":"/api/auth/session"},"startTime":1772231957673,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":1,"timestamp":485412686002,"id":279,"parentId":277,"tags":{"url":"/api/auth/session","memory.rss":"1001037824","memory.heapUsed":"168537912","memory.heapTotal":"176508928"},"startTime":1772231957685,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":230,"timestamp":485412786023,"id":280,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231957785,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":119,"timestamp":485412786280,"id":281,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231957786,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":135,"timestamp":485412786978,"id":282,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231957786,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":103,"timestamp":485412787132,"id":283,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231957786,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":1827,"timestamp":485412787862,"id":285,"parentId":3,"tags":{"inputPage":"/login/page"},"startTime":1772231957787,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":1489,"timestamp":485412803423,"id":287,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772231957803,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":1273,"timestamp":485412811734,"id":289,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772231957811,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":33606,"timestamp":485412787426,"id":284,"tags":{"url":"/login?_rsc=1h1b5"},"startTime":1772231957787,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":3,"timestamp":485412821072,"id":290,"parentId":284,"tags":{"url":"/login?_rsc=1h1b5","memory.rss":"1004544000","memory.heapUsed":"171092152","memory.heapTotal":"182743040"},"startTime":1772231957820,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":21976,"timestamp":485412803115,"id":286,"tags":{"url":"/api/auth/session"},"startTime":1772231957802,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":3,"timestamp":485412825128,"id":291,"parentId":286,"tags":{"url":"/api/auth/session","memory.rss":"1004634112","memory.heapUsed":"171507800","memory.heapTotal":"182743040"},"startTime":1772231957824,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":616,"timestamp":485412828083,"id":292,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231957827,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":376,"timestamp":485412828739,"id":293,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231957828,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":343,"timestamp":485412831407,"id":294,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231957831,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":275,"timestamp":485412831787,"id":295,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231957831,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":645,"timestamp":485412833229,"id":297,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772231957833,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":11412,"timestamp":485412832852,"id":296,"tags":{"url":"/api/auth/session"},"startTime":1772231957832,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":3,"timestamp":485412844312,"id":298,"parentId":296,"tags":{"url":"/api/auth/session","memory.rss":"1006702592","memory.heapUsed":"173500376","memory.heapTotal":"183005184"},"startTime":1772231957844,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":39081,"timestamp":485412811368,"id":288,"tags":{"url":"/api/user/profile"},"startTime":1772231957811,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":4,"timestamp":485412850485,"id":299,"parentId":288,"tags":{"url":"/api/user/profile","memory.rss":"1007202304","memory.heapUsed":"171319112","memory.heapTotal":"184053760"},"startTime":1772231957850,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":429,"timestamp":485412864096,"id":301,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772231957863,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":834,"timestamp":485412876506,"id":303,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772231957876,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":22500,"timestamp":485412863906,"id":300,"tags":{"url":"/api/user/profile"},"startTime":1772231957863,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":1,"timestamp":485412886431,"id":304,"parentId":300,"tags":{"url":"/api/user/profile","memory.rss":"1009299456","memory.heapUsed":"174361272","memory.heapTotal":"184053760"},"startTime":1772231957886,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":34185,"timestamp":485412876131,"id":302,"tags":{"url":"/api/user/profile"},"startTime":1772231957875,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485412910344,"id":305,"parentId":302,"tags":{"url":"/api/user/profile","memory.rss":"1010081792","memory.heapUsed":"172789312","memory.heapTotal":"185102336"},"startTime":1772231957910,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":931,"timestamp":485436385791,"id":307,"parentId":3,"tags":{"inputPage":"/page"},"startTime":1772231981385,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":22460,"timestamp":485436385405,"id":306,"tags":{"url":"/"},"startTime":1772231981385,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":3,"timestamp":485436407898,"id":308,"parentId":306,"tags":{"url":"/","memory.rss":"1013895168","memory.heapUsed":"174085656","memory.heapTotal":"181432320"},"startTime":1772231981407,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":345,"timestamp":485436479375,"id":309,"parentId":3,"tags":{"inputPage":"/.well-known/appspecific/com.chrome.devtools.json"},"startTime":1772231981479,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":192,"timestamp":485436479786,"id":310,"parentId":3,"tags":{"inputPage":"/.well-known/appspecific/com.chrome.devtools.json"},"startTime":1772231981479,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":321,"timestamp":485436480448,"id":311,"parentId":3,"tags":{"inputPage":"/.well-known/appspecific/com.chrome.devtools.json"},"startTime":1772231981480,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":254,"timestamp":485436480801,"id":312,"parentId":3,"tags":{"inputPage":"/.well-known/appspecific/com.chrome.devtools.json"},"startTime":1772231981480,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":221,"timestamp":485437010446,"id":313,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231982010,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":108,"timestamp":485437010693,"id":314,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231982010,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":313,"timestamp":485437012096,"id":315,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231982011,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":217,"timestamp":485437012438,"id":316,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231982012,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":735,"timestamp":485437013559,"id":318,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772231982013,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":18886,"timestamp":485437013314,"id":317,"tags":{"url":"/api/auth/session"},"startTime":1772231982013,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485437032233,"id":319,"parentId":317,"tags":{"url":"/api/auth/session","memory.rss":"1014136832","memory.heapUsed":"170519568","memory.heapTotal":"181432320"},"startTime":1772231982032,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":2059,"timestamp":485437052994,"id":321,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772231982052,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":351,"timestamp":485437058813,"id":322,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231982058,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":249,"timestamp":485437059199,"id":323,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231982058,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":274,"timestamp":485437060761,"id":324,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231982060,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":233,"timestamp":485437061064,"id":325,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231982060,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":810,"timestamp":485437062739,"id":327,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772231982062,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":14793,"timestamp":485437062401,"id":326,"tags":{"url":"/api/auth/session"},"startTime":1772231982062,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485437077233,"id":328,"parentId":326,"tags":{"url":"/api/auth/session","memory.rss":"1015001088","memory.heapUsed":"171788648","memory.heapTotal":"183791616"},"startTime":1772231982077,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":341,"timestamp":485437078111,"id":329,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231982077,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":251,"timestamp":485437078485,"id":330,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231982078,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":417,"timestamp":485437079250,"id":331,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231982079,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":407,"timestamp":485437079725,"id":332,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231982079,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":691,"timestamp":485437081138,"id":334,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772231982080,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":1100,"timestamp":485437088482,"id":336,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772231982088,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":17389,"timestamp":485437080795,"id":333,"tags":{"url":"/api/auth/session"},"startTime":1772231982080,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":1,"timestamp":485437098213,"id":337,"parentId":333,"tags":{"url":"/api/auth/session","memory.rss":"1015058432","memory.heapUsed":"173343240","memory.heapTotal":"183791616"},"startTime":1772231982097,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":343,"timestamp":485437100287,"id":338,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231982100,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":248,"timestamp":485437100665,"id":339,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231982100,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":281,"timestamp":485437102128,"id":340,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231982101,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":241,"timestamp":485437102437,"id":341,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231982102,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":792,"timestamp":485437105797,"id":343,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772231982105,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":658,"timestamp":485437109998,"id":345,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772231982109,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":15596,"timestamp":485437105615,"id":342,"tags":{"url":"/api/auth/session"},"startTime":1772231982105,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":1,"timestamp":485437121236,"id":346,"parentId":342,"tags":{"url":"/api/auth/session","memory.rss":"1015369728","memory.heapUsed":"174357752","memory.heapTotal":"188223488"},"startTime":1772231982121,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":74076,"timestamp":485437052650,"id":320,"tags":{"url":"/api/user/profile"},"startTime":1772231982052,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":4,"timestamp":485437126764,"id":347,"parentId":320,"tags":{"url":"/api/user/profile","memory.rss":"1015369728","memory.heapUsed":"174857848","memory.heapTotal":"188223488"},"startTime":1772231982126,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":714,"timestamp":485437128021,"id":349,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772231982127,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":62494,"timestamp":485437088179,"id":335,"tags":{"url":"/api/user/profile"},"startTime":1772231982087,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485437150703,"id":350,"parentId":335,"tags":{"url":"/api/user/profile","memory.rss":"1016549376","memory.heapUsed":"176685840","memory.heapTotal":"188223488"},"startTime":1772231982150,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":23889,"timestamp":485437127717,"id":348,"tags":{"url":"/api/user/profile"},"startTime":1772231982127,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":3,"timestamp":485437151654,"id":351,"parentId":348,"tags":{"url":"/api/user/profile","memory.rss":"1016692736","memory.heapUsed":"176850208","memory.heapTotal":"188223488"},"startTime":1772231982151,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":53041,"timestamp":485437109852,"id":344,"tags":{"url":"/api/user/profile"},"startTime":1772231982109,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485437162918,"id":352,"parentId":344,"tags":{"url":"/api/user/profile","memory.rss":"1016823808","memory.heapUsed":"174778456","memory.heapTotal":"188223488"},"startTime":1772231982162,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":871,"timestamp":485439987488,"id":354,"parentId":3,"tags":{"inputPage":"/login/page"},"startTime":1772231984987,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":12412,"timestamp":485439986967,"id":353,"tags":{"url":"/login?_rsc=vusbg"},"startTime":1772231984986,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":3,"timestamp":485439999421,"id":355,"parentId":353,"tags":{"url":"/login?_rsc=vusbg","memory.rss":"1020448768","memory.heapUsed":"177247880","memory.heapTotal":"188223488"},"startTime":1772231984999,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":180,"timestamp":485447812366,"id":356,"parentId":3,"tags":{"inputPage":"/api/auth/providers"},"startTime":1772231992812,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":95,"timestamp":485447812568,"id":357,"parentId":3,"tags":{"inputPage":"/api/auth/providers"},"startTime":1772231992812,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":227,"timestamp":485447813020,"id":358,"parentId":3,"tags":{"inputPage":"/api/auth/providers"},"startTime":1772231992812,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":112,"timestamp":485447813267,"id":359,"parentId":3,"tags":{"inputPage":"/api/auth/providers"},"startTime":1772231992813,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":693,"timestamp":485447814422,"id":361,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772231992814,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":8041,"timestamp":485447814034,"id":360,"tags":{"url":"/api/auth/providers"},"startTime":1772231992813,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485447822099,"id":362,"parentId":360,"tags":{"url":"/api/auth/providers","memory.rss":"1020637184","memory.heapUsed":"177101184","memory.heapTotal":"188747776"},"startTime":1772231992821,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":221,"timestamp":485447825954,"id":363,"parentId":3,"tags":{"inputPage":"/api/auth/csrf"},"startTime":1772231992825,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":113,"timestamp":485447826196,"id":364,"parentId":3,"tags":{"inputPage":"/api/auth/csrf"},"startTime":1772231992825,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":125,"timestamp":485447826590,"id":365,"parentId":3,"tags":{"inputPage":"/api/auth/csrf"},"startTime":1772231992826,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":90,"timestamp":485447826730,"id":366,"parentId":3,"tags":{"inputPage":"/api/auth/csrf"},"startTime":1772231992826,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":433,"timestamp":485447827488,"id":368,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772231992827,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":3543,"timestamp":485447827292,"id":367,"tags":{"url":"/api/auth/csrf"},"startTime":1772231992827,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":1,"timestamp":485447830859,"id":369,"parentId":367,"tags":{"url":"/api/auth/csrf","memory.rss":"1021325312","memory.heapUsed":"178718424","memory.heapTotal":"189214720"},"startTime":1772231992830,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":329,"timestamp":485447834823,"id":370,"parentId":3,"tags":{"inputPage":"/api/auth/callback/credentials"},"startTime":1772231992834,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":241,"timestamp":485447835182,"id":371,"parentId":3,"tags":{"inputPage":"/api/auth/callback/credentials"},"startTime":1772231992834,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":151,"timestamp":485447835700,"id":372,"parentId":3,"tags":{"inputPage":"/api/auth/callback/credentials"},"startTime":1772231992835,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":105,"timestamp":485447835867,"id":373,"parentId":3,"tags":{"inputPage":"/api/auth/callback/credentials"},"startTime":1772231992835,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":433,"timestamp":485447836497,"id":375,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772231992836,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":217502,"timestamp":485447836272,"id":374,"tags":{"url":"/api/auth/callback/credentials?"},"startTime":1772231992836,"traceId":"ac832ea7e7a97813"}] +[{"name":"memory-usage","duration":1,"timestamp":485448054013,"id":376,"parentId":374,"tags":{"url":"/api/auth/callback/credentials?","memory.rss":"1022386176","memory.heapUsed":"177917264","memory.heapTotal":"185544704"},"startTime":1772231993053,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":161,"timestamp":485448058173,"id":377,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231993057,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":92,"timestamp":485448058354,"id":378,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231993058,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":119,"timestamp":485448058634,"id":379,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231993058,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":83,"timestamp":485448058767,"id":380,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772231993058,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":596,"timestamp":485448059271,"id":382,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772231993059,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":5474,"timestamp":485448059090,"id":381,"tags":{"url":"/api/auth/session"},"startTime":1772231993058,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485448064592,"id":383,"parentId":381,"tags":{"url":"/api/auth/session","memory.rss":"1022414848","memory.heapUsed":"178346760","memory.heapTotal":"186068992"},"startTime":1772231993064,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":801,"timestamp":485448069820,"id":385,"parentId":3,"tags":{"inputPage":"/dashboard/page"},"startTime":1772231993069,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":567,"timestamp":485448079093,"id":387,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772231993078,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":15105,"timestamp":485448069585,"id":384,"tags":{"url":"/dashboard?_rsc=5c339"},"startTime":1772231993069,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485448084715,"id":388,"parentId":384,"tags":{"url":"/dashboard?_rsc=5c339","memory.rss":"1022533632","memory.heapUsed":"179482368","memory.heapTotal":"187117568"},"startTime":1772231993084,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":24281,"timestamp":485448078923,"id":386,"tags":{"url":"/api/user/profile"},"startTime":1772231993078,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":4,"timestamp":485448103255,"id":389,"parentId":386,"tags":{"url":"/api/user/profile","memory.rss":"1022636032","memory.heapUsed":"180196336","memory.heapTotal":"187117568"},"startTime":1772231993103,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":488,"timestamp":485448130717,"id":391,"parentId":3,"tags":{"inputPage":"/api/projects/route"},"startTime":1772231993130,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":14670,"timestamp":485448130480,"id":390,"tags":{"url":"/api/projects"},"startTime":1772231993130,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485448145179,"id":392,"parentId":390,"tags":{"url":"/api/projects","memory.rss":"1023287296","memory.heapUsed":"180870568","memory.heapTotal":"191574016"},"startTime":1772231993144,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":475,"timestamp":485448145976,"id":394,"parentId":3,"tags":{"inputPage":"/api/projects/route"},"startTime":1772231993145,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":15887,"timestamp":485448145796,"id":393,"tags":{"url":"/api/projects"},"startTime":1772231993145,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485448161713,"id":395,"parentId":393,"tags":{"url":"/api/projects","memory.rss":"1024012288","memory.heapUsed":"182229848","memory.heapTotal":"191574016"},"startTime":1772231993161,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":477,"timestamp":485448162567,"id":397,"parentId":3,"tags":{"inputPage":"/api/projects/route"},"startTime":1772231993162,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":12589,"timestamp":485448162339,"id":396,"tags":{"url":"/api/projects"},"startTime":1772231993162,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485448174972,"id":398,"parentId":396,"tags":{"url":"/api/projects","memory.rss":"1025093632","memory.heapUsed":"181440464","memory.heapTotal":"192360448"},"startTime":1772231993174,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":13277,"timestamp":485451754860,"id":400,"parentId":3,"tags":{"inputPage":"/profile/page"},"startTime":1772231996754,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":77486,"timestamp":485451754267,"id":399,"tags":{"url":"/profile?_rsc=1h1b5"},"startTime":1772231996754,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485451831780,"id":401,"parentId":399,"tags":{"url":"/profile?_rsc=1h1b5","memory.rss":"1043460096","memory.heapUsed":"197095864","memory.heapTotal":"211664896"},"startTime":1772231996831,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":1468,"timestamp":485459557849,"id":403,"parentId":3,"tags":{"inputPage":"/dashboard/page"},"startTime":1772232004557,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":9362,"timestamp":485459557600,"id":402,"tags":{"url":"/dashboard?_rsc=1ls1y"},"startTime":1772232004557,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485459566984,"id":404,"parentId":402,"tags":{"url":"/dashboard?_rsc=1ls1y","memory.rss":"1038872576","memory.heapUsed":"190856184","memory.heapTotal":"230080512"},"startTime":1772232004566,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":558,"timestamp":485459603549,"id":406,"parentId":3,"tags":{"inputPage":"/api/projects/route"},"startTime":1772232004603,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":55918,"timestamp":485459603341,"id":405,"tags":{"url":"/api/projects"},"startTime":1772232004603,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485459659291,"id":407,"parentId":405,"tags":{"url":"/api/projects","memory.rss":"1038884864","memory.heapUsed":"192549600","memory.heapTotal":"230080512"},"startTime":1772232004659,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":576,"timestamp":485459660338,"id":409,"parentId":3,"tags":{"inputPage":"/api/projects/route"},"startTime":1772232004660,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":28249,"timestamp":485459660081,"id":408,"tags":{"url":"/api/projects"},"startTime":1772232004659,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485459688367,"id":410,"parentId":408,"tags":{"url":"/api/projects","memory.rss":"1038893056","memory.heapUsed":"193924728","memory.heapTotal":"230080512"},"startTime":1772232004688,"traceId":"ac832ea7e7a97813"},{"name":"client-hmr-latency","duration":64000,"timestamp":485532593477,"id":411,"parentId":3,"tags":{"updatedModules":["[project]/Documents/00 - projet/plumeia/src/lib/api.ts [app-client]"],"page":"/dashboard","isPageHidden":false},"startTime":1772232077686,"traceId":"ac832ea7e7a97813"},{"name":"client-hmr-latency","duration":64000,"timestamp":485532593550,"id":412,"parentId":3,"tags":{"updatedModules":["[project]/Documents/00 - projet/plumeia/src/lib/api.ts [app-client]"],"page":"/login","isPageHidden":true},"startTime":1772232077686,"traceId":"ac832ea7e7a97813"},{"name":"client-hmr-latency","duration":65000,"timestamp":485532593574,"id":413,"parentId":3,"tags":{"updatedModules":["[project]/Documents/00 - projet/plumeia/src/lib/api.ts [app-client]"],"page":"/login","isPageHidden":true},"startTime":1772232077686,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":10369,"timestamp":485532701417,"id":415,"parentId":3,"tags":{"inputPage":"/dashboard/page"},"startTime":1772232077701,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":131440,"timestamp":485532701779,"id":417,"parentId":3,"tags":{"inputPage":"/login/page"},"startTime":1772232077702,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":1848,"timestamp":485532934479,"id":419,"parentId":3,"tags":{"inputPage":"/login/page"},"startTime":1772232077934,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":258175,"timestamp":485532701618,"id":416,"tags":{"url":"/login"},"startTime":1772232077701,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485532959822,"id":420,"parentId":416,"tags":{"url":"/login","memory.rss":"1056768000","memory.heapUsed":"224056072","memory.heapTotal":"255430656"},"startTime":1772232077960,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":259305,"timestamp":485532700982,"id":414,"tags":{"url":"/dashboard"},"startTime":1772232077701,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485532960304,"id":421,"parentId":414,"tags":{"url":"/dashboard","memory.rss":"1056845824","memory.heapUsed":"224100056","memory.heapTotal":"255430656"},"startTime":1772232077960,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":26877,"timestamp":485532934196,"id":418,"tags":{"url":"/login"},"startTime":1772232077934,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":1,"timestamp":485532961087,"id":422,"parentId":418,"tags":{"url":"/login","memory.rss":"1057050624","memory.heapUsed":"224243032","memory.heapTotal":"255430656"},"startTime":1772232077961,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":410,"timestamp":485533001693,"id":423,"parentId":3,"tags":{"inputPage":"/.well-known/appspecific/com.chrome.devtools.json"},"startTime":1772232078002,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":285,"timestamp":485533002147,"id":424,"parentId":3,"tags":{"inputPage":"/.well-known/appspecific/com.chrome.devtools.json"},"startTime":1772232078002,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":167,"timestamp":485533002836,"id":425,"parentId":3,"tags":{"inputPage":"/.well-known/appspecific/com.chrome.devtools.json"},"startTime":1772232078003,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":106,"timestamp":485533003023,"id":426,"parentId":3,"tags":{"inputPage":"/.well-known/appspecific/com.chrome.devtools.json"},"startTime":1772232078003,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":196,"timestamp":485533215271,"id":427,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078215,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":135,"timestamp":485533215493,"id":428,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078215,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":146,"timestamp":485533215920,"id":429,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078216,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":93,"timestamp":485533216084,"id":430,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078216,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":490,"timestamp":485533216885,"id":432,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772232078217,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":14876,"timestamp":485533216617,"id":431,"tags":{"url":"/api/auth/session"},"startTime":1772232078216,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":3,"timestamp":485533231549,"id":433,"parentId":431,"tags":{"url":"/api/auth/session","memory.rss":"1070288896","memory.heapUsed":"225340696","memory.heapTotal":"259567616"},"startTime":1772232078231,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":556,"timestamp":485533291234,"id":435,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772232078291,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":205,"timestamp":485533296813,"id":436,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078297,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":107,"timestamp":485533297040,"id":437,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078297,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":165,"timestamp":485533298115,"id":438,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078298,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":107,"timestamp":485533298300,"id":439,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078298,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":857,"timestamp":485533300107,"id":441,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772232078300,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":9825,"timestamp":485533299906,"id":440,"tags":{"url":"/api/auth/session"},"startTime":1772232078300,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485533309758,"id":442,"parentId":440,"tags":{"url":"/api/auth/session","memory.rss":"1077518336","memory.heapUsed":"230423696","memory.heapTotal":"259567616"},"startTime":1772232078310,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":61563,"timestamp":485533290931,"id":434,"tags":{"url":"/api/user/profile"},"startTime":1772232078291,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485533352520,"id":443,"parentId":434,"tags":{"url":"/api/user/profile","memory.rss":"1082036224","memory.heapUsed":"231758352","memory.heapTotal":"259829760"},"startTime":1772232078352,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":344,"timestamp":485533364246,"id":444,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078364,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":265,"timestamp":485533364627,"id":445,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078364,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":175,"timestamp":485533365321,"id":446,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078365,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":113,"timestamp":485533365521,"id":447,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078365,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":572,"timestamp":485533366206,"id":449,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772232078366,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":6564,"timestamp":485533365971,"id":448,"tags":{"url":"/api/auth/session"},"startTime":1772232078366,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":37,"timestamp":485533372573,"id":450,"parentId":448,"tags":{"url":"/api/auth/session","memory.rss":"1083953152","memory.heapUsed":"233403704","memory.heapTotal":"260091904"},"startTime":1772232078372,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":476,"timestamp":485533377537,"id":452,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772232078377,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":25835,"timestamp":485533377299,"id":451,"tags":{"url":"/api/user/profile"},"startTime":1772232078377,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485533403166,"id":453,"parentId":451,"tags":{"url":"/api/user/profile","memory.rss":"1085550592","memory.heapUsed":"234920176","memory.heapTotal":"260354048"},"startTime":1772232078403,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":192,"timestamp":485533478256,"id":454,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078478,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":103,"timestamp":485533478472,"id":455,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078478,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":155,"timestamp":485533479183,"id":456,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078479,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":99,"timestamp":485533479357,"id":457,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078479,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":2173,"timestamp":485533480334,"id":459,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772232078480,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":4590,"timestamp":485533480814,"id":461,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772232078481,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":7211,"timestamp":485533481425,"id":463,"parentId":3,"tags":{"inputPage":"/login/page"},"startTime":1772232078481,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":25550,"timestamp":485533480965,"id":462,"tags":{"url":"/login?_rsc=1h1b5"},"startTime":1772232078481,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485533506549,"id":464,"parentId":462,"tags":{"url":"/login?_rsc=1h1b5","memory.rss":"1081790464","memory.heapUsed":"231341216","memory.heapTotal":"264163328"},"startTime":1772232078506,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":26921,"timestamp":485533480603,"id":460,"tags":{"url":"/api/auth/session"},"startTime":1772232078480,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485533507552,"id":465,"parentId":460,"tags":{"url":"/api/auth/session","memory.rss":"1081790464","memory.heapUsed":"231545120","memory.heapTotal":"264163328"},"startTime":1772232078507,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":181,"timestamp":485533509010,"id":466,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078509,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":107,"timestamp":485533509215,"id":467,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078509,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":145,"timestamp":485533509768,"id":468,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078510,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":105,"timestamp":485533509930,"id":469,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078510,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":532,"timestamp":485533510683,"id":471,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772232078511,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":9024,"timestamp":485533510420,"id":470,"tags":{"url":"/api/auth/session"},"startTime":1772232078510,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485533519476,"id":472,"parentId":470,"tags":{"url":"/api/auth/session","memory.rss":"1082245120","memory.heapUsed":"233451472","memory.heapTotal":"264425472"},"startTime":1772232078519,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":528,"timestamp":485533522587,"id":474,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772232078522,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":46491,"timestamp":485533480108,"id":458,"tags":{"url":"/api/user/profile"},"startTime":1772232078480,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":4,"timestamp":485533526635,"id":475,"parentId":458,"tags":{"url":"/api/user/profile","memory.rss":"1082933248","memory.heapUsed":"234512968","memory.heapTotal":"264687616"},"startTime":1772232078526,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":400,"timestamp":485533533311,"id":477,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772232078533,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":23213,"timestamp":485533522356,"id":473,"tags":{"url":"/api/user/profile"},"startTime":1772232078522,"traceId":"ac832ea7e7a97813"}] +[{"name":"memory-usage","duration":2,"timestamp":485533545852,"id":478,"parentId":473,"tags":{"url":"/api/user/profile","memory.rss":"1083351040","memory.heapUsed":"236620736","memory.heapTotal":"264949760"},"startTime":1772232078546,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":44415,"timestamp":485533533088,"id":476,"tags":{"url":"/api/user/profile"},"startTime":1772232078533,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485533577528,"id":479,"parentId":476,"tags":{"url":"/api/user/profile","memory.rss":"1083805696","memory.heapUsed":"237248344","memory.heapTotal":"265211904"},"startTime":1772232078577,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":408,"timestamp":485533768799,"id":480,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078769,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":181,"timestamp":485533769270,"id":481,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078769,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":145,"timestamp":485533770011,"id":482,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078770,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":108,"timestamp":485533770173,"id":483,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078770,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":541,"timestamp":485533770815,"id":485,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772232078771,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":11504,"timestamp":485533770593,"id":484,"tags":{"url":"/api/auth/session"},"startTime":1772232078770,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":1,"timestamp":485533782119,"id":486,"parentId":484,"tags":{"url":"/api/auth/session","memory.rss":"1086722048","memory.heapUsed":"231346992","memory.heapTotal":"268095488"},"startTime":1772232078782,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":167,"timestamp":485533792310,"id":487,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078792,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":99,"timestamp":485533792497,"id":488,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078792,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":114,"timestamp":485533792851,"id":489,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078793,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":89,"timestamp":485533792979,"id":490,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078793,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":565,"timestamp":485533793674,"id":492,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772232078794,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":592,"timestamp":485533798250,"id":494,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772232078798,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":9565,"timestamp":485533793458,"id":491,"tags":{"url":"/api/auth/session"},"startTime":1772232078793,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485533803053,"id":495,"parentId":491,"tags":{"url":"/api/auth/session","memory.rss":"1087483904","memory.heapUsed":"233674688","memory.heapTotal":"268095488"},"startTime":1772232078803,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":248,"timestamp":485533804266,"id":496,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078804,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":139,"timestamp":485533804542,"id":497,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078804,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":149,"timestamp":485533805235,"id":498,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078805,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":101,"timestamp":485533805401,"id":499,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078805,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":704,"timestamp":485533806710,"id":501,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772232078807,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":7764,"timestamp":485533806337,"id":500,"tags":{"url":"/api/auth/session"},"startTime":1772232078806,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":1,"timestamp":485533814125,"id":502,"parentId":500,"tags":{"url":"/api/auth/session","memory.rss":"1087827968","memory.heapUsed":"235711528","memory.heapTotal":"268619776"},"startTime":1772232078814,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":652,"timestamp":485533814419,"id":504,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772232078814,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":150,"timestamp":485533817445,"id":505,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078817,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":106,"timestamp":485533817616,"id":506,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078817,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":145,"timestamp":485533818010,"id":507,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078818,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":103,"timestamp":485533818172,"id":508,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232078818,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":522,"timestamp":485533819148,"id":510,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772232078819,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":640,"timestamp":485533824277,"id":512,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772232078824,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":30019,"timestamp":485533798060,"id":493,"tags":{"url":"/api/user/profile"},"startTime":1772232078798,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485533828105,"id":513,"parentId":493,"tags":{"url":"/api/user/profile","memory.rss":"1088552960","memory.heapUsed":"238808968","memory.heapTotal":"269144064"},"startTime":1772232078828,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":12540,"timestamp":485533818954,"id":509,"tags":{"url":"/api/auth/session"},"startTime":1772232078819,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":1,"timestamp":485533831519,"id":514,"parentId":509,"tags":{"url":"/api/auth/session","memory.rss":"1088634880","memory.heapUsed":"239579376","memory.heapTotal":"269406208"},"startTime":1772232078831,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":30300,"timestamp":485533814227,"id":503,"tags":{"url":"/api/user/profile"},"startTime":1772232078814,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485533844560,"id":515,"parentId":503,"tags":{"url":"/api/user/profile","memory.rss":"1088786432","memory.heapUsed":"240241808","memory.heapTotal":"269406208"},"startTime":1772232078844,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":26049,"timestamp":485533824071,"id":511,"tags":{"url":"/api/user/profile"},"startTime":1772232078824,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":1,"timestamp":485533850145,"id":518,"parentId":511,"tags":{"url":"/api/user/profile","memory.rss":"1088790528","memory.heapUsed":"240665224","memory.heapTotal":"269406208"},"startTime":1772232078850,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":1328,"timestamp":485533849102,"id":517,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772232078849,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":23318,"timestamp":485533848880,"id":516,"tags":{"url":"/api/user/profile"},"startTime":1772232078849,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":3,"timestamp":485533872232,"id":519,"parentId":516,"tags":{"url":"/api/user/profile","memory.rss":"1089875968","memory.heapUsed":"242043208","memory.heapTotal":"269668352"},"startTime":1772232078872,"traceId":"ac832ea7e7a97813"},{"name":"client-hmr-latency","duration":49000,"timestamp":485547182448,"id":520,"parentId":3,"tags":{"updatedModules":["[project]/Documents/00 - projet/plumeia/src/hooks/useAuth.ts [app-client]"],"page":"/login","isPageHidden":false},"startTime":1772232092244,"traceId":"ac832ea7e7a97813"},{"name":"client-hmr-latency","duration":49000,"timestamp":485547182522,"id":521,"parentId":3,"tags":{"updatedModules":["[project]/Documents/00 - projet/plumeia/src/hooks/useAuth.ts [app-client]"],"page":"/login","isPageHidden":true},"startTime":1772232092244,"traceId":"ac832ea7e7a97813"},{"name":"client-hmr-latency","duration":51000,"timestamp":485547182544,"id":522,"parentId":3,"tags":{"updatedModules":["[project]/Documents/00 - projet/plumeia/src/hooks/useAuth.ts [app-client]"],"page":"/login","isPageHidden":true},"startTime":1772232092244,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":8924,"timestamp":485547281185,"id":524,"parentId":3,"tags":{"inputPage":"/login/page"},"startTime":1772232092281,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":836,"timestamp":485547376012,"id":526,"parentId":3,"tags":{"inputPage":"/login/page"},"startTime":1772232092376,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":894,"timestamp":485547401896,"id":528,"parentId":3,"tags":{"inputPage":"/login/page"},"startTime":1772232092402,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":144438,"timestamp":485547280990,"id":523,"tags":{"url":"/login"},"startTime":1772232092281,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485547425458,"id":529,"parentId":523,"tags":{"url":"/login","memory.rss":"1124036608","memory.heapUsed":"261225688","memory.heapTotal":"291729408"},"startTime":1772232092425,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":66486,"timestamp":485547375748,"id":525,"tags":{"url":"/login"},"startTime":1772232092376,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":1,"timestamp":485547442263,"id":530,"parentId":525,"tags":{"url":"/login","memory.rss":"1117888512","memory.heapUsed":"242469376","memory.heapTotal":"294764544"},"startTime":1772232092442,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":41534,"timestamp":485547401666,"id":527,"tags":{"url":"/login"},"startTime":1772232092401,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":1,"timestamp":485547443217,"id":531,"parentId":527,"tags":{"url":"/login","memory.rss":"1118044160","memory.heapUsed":"242623920","memory.heapTotal":"294764544"},"startTime":1772232092443,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":194,"timestamp":485547501658,"id":532,"parentId":3,"tags":{"inputPage":"/.well-known/appspecific/com.chrome.devtools.json"},"startTime":1772232092501,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":105,"timestamp":485547501879,"id":533,"parentId":3,"tags":{"inputPage":"/.well-known/appspecific/com.chrome.devtools.json"},"startTime":1772232092502,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":142,"timestamp":485547502278,"id":534,"parentId":3,"tags":{"inputPage":"/.well-known/appspecific/com.chrome.devtools.json"},"startTime":1772232092502,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":97,"timestamp":485547502439,"id":535,"parentId":3,"tags":{"inputPage":"/.well-known/appspecific/com.chrome.devtools.json"},"startTime":1772232092502,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":201,"timestamp":485547623215,"id":536,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232092623,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":91,"timestamp":485547623440,"id":537,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232092623,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":157,"timestamp":485547623898,"id":538,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232092624,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":92,"timestamp":485547624075,"id":539,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232092624,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":513,"timestamp":485547624799,"id":541,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772232092625,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":10659,"timestamp":485547624525,"id":540,"tags":{"url":"/api/auth/session"},"startTime":1772232092624,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":3,"timestamp":485547635219,"id":542,"parentId":540,"tags":{"url":"/api/auth/session","memory.rss":"1125625856","memory.heapUsed":"251695776","memory.heapTotal":"295231488"},"startTime":1772232092635,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":179,"timestamp":485547635970,"id":543,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232092636,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":106,"timestamp":485547636173,"id":544,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232092636,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":171,"timestamp":485547636547,"id":545,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232092636,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":107,"timestamp":485547636734,"id":546,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232092637,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":494,"timestamp":485547637401,"id":548,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772232092637,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":5926,"timestamp":485547637196,"id":547,"tags":{"url":"/api/auth/session"},"startTime":1772232092637,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":1,"timestamp":485547643146,"id":549,"parentId":547,"tags":{"url":"/api/auth/session","memory.rss":"1125625856","memory.heapUsed":"253229152","memory.heapTotal":"295231488"},"startTime":1772232092643,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":183,"timestamp":485547670314,"id":550,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232092670,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":97,"timestamp":485547670520,"id":551,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232092670,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":120,"timestamp":485547670853,"id":552,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232092671,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":93,"timestamp":485547670989,"id":553,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232092671,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":444,"timestamp":485547671703,"id":555,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772232092672,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":6341,"timestamp":485547671486,"id":554,"tags":{"url":"/api/auth/session"},"startTime":1772232092671,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485547677855,"id":556,"parentId":554,"tags":{"url":"/api/auth/session","memory.rss":"1125810176","memory.heapUsed":"254925232","memory.heapTotal":"295231488"},"startTime":1772232092678,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":516,"timestamp":485547678180,"id":558,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772232092678,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":230,"timestamp":485547698559,"id":559,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232092698,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":162,"timestamp":485547698819,"id":560,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232092699,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":165,"timestamp":485547700215,"id":561,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232092700,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":102,"timestamp":485547700399,"id":562,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232092700,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":814,"timestamp":485547701419,"id":564,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772232092701,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":4150,"timestamp":485547707153,"id":566,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772232092707,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":15960,"timestamp":485547701223,"id":563,"tags":{"url":"/api/auth/session"},"startTime":1772232092701,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":1,"timestamp":485547717208,"id":567,"parentId":563,"tags":{"url":"/api/auth/session","memory.rss":"1120403456","memory.heapUsed":"248344224","memory.heapTotal":"295231488"},"startTime":1772232092717,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":181,"timestamp":485547722967,"id":568,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232092723,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":105,"timestamp":485547723170,"id":569,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232092723,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":130,"timestamp":485547723541,"id":570,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232092723,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":200,"timestamp":485547723686,"id":571,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232092724,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":739,"timestamp":485547725050,"id":573,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772232092725,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":638,"timestamp":485547730851,"id":575,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772232092731,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":13857,"timestamp":485547724665,"id":572,"tags":{"url":"/api/auth/session"},"startTime":1772232092724,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485547738553,"id":576,"parentId":572,"tags":{"url":"/api/auth/session","memory.rss":"1121333248","memory.heapUsed":"251453096","memory.heapTotal":"295231488"},"startTime":1772232092738,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":173,"timestamp":485547740145,"id":577,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232092740,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":106,"timestamp":485547740339,"id":578,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232092740,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":330,"timestamp":485547741750,"id":579,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232092742,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":249,"timestamp":485547742116,"id":580,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232092742,"traceId":"ac832ea7e7a97813"}] +[{"name":"ensure-page","duration":1137,"timestamp":485547744887,"id":582,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772232092745,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":3936,"timestamp":485547745368,"id":584,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772232092745,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":11396,"timestamp":485547745192,"id":583,"tags":{"url":"/api/auth/session"},"startTime":1772232092745,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":1,"timestamp":485547756614,"id":585,"parentId":583,"tags":{"url":"/api/auth/session","memory.rss":"1121595392","memory.heapUsed":"254853344","memory.heapTotal":"295231488"},"startTime":1772232092756,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":80868,"timestamp":485547677968,"id":557,"tags":{"url":"/api/user/profile"},"startTime":1772232092678,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":4,"timestamp":485547758879,"id":586,"parentId":557,"tags":{"url":"/api/user/profile","memory.rss":"1121599488","memory.heapUsed":"255171160","memory.heapTotal":"295231488"},"startTime":1772232092759,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":514,"timestamp":485547760692,"id":588,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772232092761,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":65909,"timestamp":485547706969,"id":565,"tags":{"url":"/api/user/profile"},"startTime":1772232092707,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485547772905,"id":589,"parentId":565,"tags":{"url":"/api/user/profile","memory.rss":"1123196928","memory.heapUsed":"257315040","memory.heapTotal":"295231488"},"startTime":1772232092773,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":429,"timestamp":485547776521,"id":591,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772232092776,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":25177,"timestamp":485547760492,"id":587,"tags":{"url":"/api/user/profile"},"startTime":1772232092760,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":1,"timestamp":485547785694,"id":592,"parentId":587,"tags":{"url":"/api/user/profile","memory.rss":"1123667968","memory.heapUsed":"259124384","memory.heapTotal":"295231488"},"startTime":1772232092786,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":63776,"timestamp":485547730661,"id":574,"tags":{"url":"/api/user/profile"},"startTime":1772232092730,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":3,"timestamp":485547794473,"id":593,"parentId":574,"tags":{"url":"/api/user/profile","memory.rss":"1122275328","memory.heapUsed":"252354768","memory.heapTotal":"296157184"},"startTime":1772232092794,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":55047,"timestamp":485547744656,"id":581,"tags":{"url":"/api/user/profile"},"startTime":1772232092744,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485547799738,"id":594,"parentId":581,"tags":{"url":"/api/user/profile","memory.rss":"1123205120","memory.heapUsed":"252926704","memory.heapTotal":"296157184"},"startTime":1772232092800,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":24932,"timestamp":485547776331,"id":590,"tags":{"url":"/api/user/profile"},"startTime":1772232092776,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485547801288,"id":595,"parentId":590,"tags":{"url":"/api/user/profile","memory.rss":"1123233792","memory.heapUsed":"253104496","memory.heapTotal":"296157184"},"startTime":1772232092801,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":165,"timestamp":485548221773,"id":596,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232093222,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":97,"timestamp":485548221960,"id":597,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232093222,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":120,"timestamp":485548222280,"id":598,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232093222,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":103,"timestamp":485548222415,"id":599,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232093222,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":387,"timestamp":485548223020,"id":601,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772232093223,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":8656,"timestamp":485548222834,"id":600,"tags":{"url":"/api/auth/session"},"startTime":1772232093223,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":1,"timestamp":485548231517,"id":602,"parentId":600,"tags":{"url":"/api/auth/session","memory.rss":"1128517632","memory.heapUsed":"258111864","memory.heapTotal":"296157184"},"startTime":1772232093231,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":164,"timestamp":485548253116,"id":603,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232093253,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":96,"timestamp":485548253301,"id":604,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232093253,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":149,"timestamp":485548253789,"id":605,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232093254,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":94,"timestamp":485548253956,"id":606,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232093254,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":450,"timestamp":485548254627,"id":608,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772232093254,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":662,"timestamp":485548257996,"id":610,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772232093258,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":9843,"timestamp":485548254394,"id":607,"tags":{"url":"/api/auth/session"},"startTime":1772232093254,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":1,"timestamp":485548264273,"id":611,"parentId":607,"tags":{"url":"/api/auth/session","memory.rss":"1128542208","memory.heapUsed":"260543304","memory.heapTotal":"296157184"},"startTime":1772232093264,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":185,"timestamp":485548265254,"id":612,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232093265,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":112,"timestamp":485548265463,"id":613,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232093265,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":149,"timestamp":485548266334,"id":614,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232093266,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":93,"timestamp":485548266501,"id":615,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232093266,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":489,"timestamp":485548267936,"id":617,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772232093268,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":5866,"timestamp":485548267679,"id":616,"tags":{"url":"/api/auth/session"},"startTime":1772232093268,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":1,"timestamp":485548273575,"id":618,"parentId":616,"tags":{"url":"/api/auth/session","memory.rss":"1128546304","memory.heapUsed":"262424280","memory.heapTotal":"296157184"},"startTime":1772232093273,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":169,"timestamp":485548275072,"id":621,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232093275,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":101,"timestamp":485548275266,"id":622,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232093275,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":1346,"timestamp":485548274436,"id":620,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772232093274,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":160,"timestamp":485548277927,"id":623,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232093278,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":99,"timestamp":485548278109,"id":624,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232093278,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":22761,"timestamp":485548257799,"id":609,"tags":{"url":"/api/user/profile"},"startTime":1772232093258,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":1,"timestamp":485548280588,"id":627,"parentId":609,"tags":{"url":"/api/user/profile","memory.rss":"1128550400","memory.heapUsed":"263919224","memory.heapTotal":"296157184"},"startTime":1772232093280,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":1724,"timestamp":485548279204,"id":626,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772232093279,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":618,"timestamp":485548284750,"id":629,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772232093285,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":14676,"timestamp":485548278923,"id":625,"tags":{"url":"/api/auth/session"},"startTime":1772232093279,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":1,"timestamp":485548293626,"id":630,"parentId":625,"tags":{"url":"/api/auth/session","memory.rss":"1121325056","memory.heapUsed":"257178808","memory.heapTotal":"296157184"},"startTime":1772232093293,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":29415,"timestamp":485548274244,"id":619,"tags":{"url":"/api/user/profile"},"startTime":1772232093274,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485548303689,"id":631,"parentId":619,"tags":{"url":"/api/user/profile","memory.rss":"1121329152","memory.heapUsed":"257926928","memory.heapTotal":"296157184"},"startTime":1772232093304,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":22647,"timestamp":485548284561,"id":628,"tags":{"url":"/api/user/profile"},"startTime":1772232093284,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":3,"timestamp":485548307237,"id":632,"parentId":628,"tags":{"url":"/api/user/profile","memory.rss":"1121329152","memory.heapUsed":"258089960","memory.heapTotal":"296157184"},"startTime":1772232093307,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":413,"timestamp":485548310293,"id":634,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772232093310,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":25182,"timestamp":485548310085,"id":633,"tags":{"url":"/api/user/profile"},"startTime":1772232093310,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485548335297,"id":635,"parentId":633,"tags":{"url":"/api/user/profile","memory.rss":"1121349632","memory.heapUsed":"259592520","memory.heapTotal":"296157184"},"startTime":1772232093335,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":202,"timestamp":485674116036,"id":636,"parentId":3,"tags":{"inputPage":"/api/auth/providers"},"startTime":1772232219115,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":95,"timestamp":485674116259,"id":637,"parentId":3,"tags":{"inputPage":"/api/auth/providers"},"startTime":1772232219116,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":127,"timestamp":485674116594,"id":638,"parentId":3,"tags":{"inputPage":"/api/auth/providers"},"startTime":1772232219116,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":85,"timestamp":485674116735,"id":639,"parentId":3,"tags":{"inputPage":"/api/auth/providers"},"startTime":1772232219116,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":537,"timestamp":485674117987,"id":641,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772232219117,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":9190,"timestamp":485674117738,"id":640,"tags":{"url":"/api/auth/providers"},"startTime":1772232219117,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":1,"timestamp":485674126947,"id":642,"parentId":640,"tags":{"url":"/api/auth/providers","memory.rss":"974786560","memory.heapUsed":"232613664","memory.heapTotal":"239132672"},"startTime":1772232219126,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":216,"timestamp":485674134391,"id":643,"parentId":3,"tags":{"inputPage":"/api/auth/csrf"},"startTime":1772232219134,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":103,"timestamp":485674134630,"id":644,"parentId":3,"tags":{"inputPage":"/api/auth/csrf"},"startTime":1772232219134,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":298,"timestamp":485674135216,"id":645,"parentId":3,"tags":{"inputPage":"/api/auth/csrf"},"startTime":1772232219135,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":281,"timestamp":485674135545,"id":646,"parentId":3,"tags":{"inputPage":"/api/auth/csrf"},"startTime":1772232219135,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":731,"timestamp":485674137292,"id":648,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772232219137,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":7276,"timestamp":485674136937,"id":647,"tags":{"url":"/api/auth/csrf"},"startTime":1772232219136,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":4,"timestamp":485674144253,"id":649,"parentId":647,"tags":{"url":"/api/auth/csrf","memory.rss":"973537280","memory.heapUsed":"233343800","memory.heapTotal":"239656960"},"startTime":1772232219144,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":315,"timestamp":485674147636,"id":650,"parentId":3,"tags":{"inputPage":"/api/auth/callback/credentials"},"startTime":1772232219147,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":244,"timestamp":485674147982,"id":651,"parentId":3,"tags":{"inputPage":"/api/auth/callback/credentials"},"startTime":1772232219147,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":154,"timestamp":485674148618,"id":652,"parentId":3,"tags":{"inputPage":"/api/auth/callback/credentials"},"startTime":1772232219148,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":97,"timestamp":485674148790,"id":653,"parentId":3,"tags":{"inputPage":"/api/auth/callback/credentials"},"startTime":1772232219148,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":1006,"timestamp":485674149395,"id":655,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772232219149,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":220506,"timestamp":485674149193,"id":654,"tags":{"url":"/api/auth/callback/credentials?"},"startTime":1772232219149,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":1,"timestamp":485674369725,"id":656,"parentId":654,"tags":{"url":"/api/auth/callback/credentials?","memory.rss":"974393344","memory.heapUsed":"234150448","memory.heapTotal":"240443392"},"startTime":1772232219369,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":156,"timestamp":485674374796,"id":657,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232219374,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":92,"timestamp":485674374975,"id":658,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232219374,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":270,"timestamp":485674375349,"id":659,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232219375,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":214,"timestamp":485674375646,"id":660,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232219375,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":975,"timestamp":485674376462,"id":662,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772232219376,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":6559,"timestamp":485674376282,"id":661,"tags":{"url":"/api/auth/session"},"startTime":1772232219376,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":1,"timestamp":485674382861,"id":663,"parentId":661,"tags":{"url":"/api/auth/session","memory.rss":"974553088","memory.heapUsed":"234518192","memory.heapTotal":"242278400"},"startTime":1772232219382,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":11462,"timestamp":485674387495,"id":665,"parentId":3,"tags":{"inputPage":"/dashboard/page"},"startTime":1772232219387,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":796,"timestamp":485674458796,"id":667,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772232219458,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":80357,"timestamp":485674387260,"id":664,"tags":{"url":"/dashboard?_rsc=5c339"},"startTime":1772232219387,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":9,"timestamp":485674467658,"id":668,"parentId":664,"tags":{"url":"/dashboard?_rsc=5c339","memory.rss":"1003053056","memory.heapUsed":"255716040","memory.heapTotal":"274731008"},"startTime":1772232219467,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":35615,"timestamp":485674458463,"id":666,"tags":{"url":"/api/user/profile"},"startTime":1772232219458,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":4,"timestamp":485674494123,"id":669,"parentId":666,"tags":{"url":"/api/user/profile","memory.rss":"992706560","memory.heapUsed":"236260248","memory.heapTotal":"268472320"},"startTime":1772232219493,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":1062,"timestamp":485674516582,"id":671,"parentId":3,"tags":{"inputPage":"/api/projects/route"},"startTime":1772232219516,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":24908,"timestamp":485674516384,"id":670,"tags":{"url":"/api/projects"},"startTime":1772232219516,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485674541322,"id":672,"parentId":670,"tags":{"url":"/api/projects","memory.rss":"993181696","memory.heapUsed":"237978936","memory.heapTotal":"268472320"},"startTime":1772232219541,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":494,"timestamp":485674542220,"id":674,"parentId":3,"tags":{"inputPage":"/api/projects/route"},"startTime":1772232219542,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":29176,"timestamp":485674542025,"id":673,"tags":{"url":"/api/projects"},"startTime":1772232219541,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485674571237,"id":675,"parentId":673,"tags":{"url":"/api/projects","memory.rss":"993243136","memory.heapUsed":"239322768","memory.heapTotal":"268472320"},"startTime":1772232219571,"traceId":"ac832ea7e7a97813"},{"name":"ensure-page","duration":422,"timestamp":485674572016,"id":677,"parentId":3,"tags":{"inputPage":"/api/projects/route"},"startTime":1772232219571,"traceId":"ac832ea7e7a97813"},{"name":"handle-request","duration":29095,"timestamp":485674571854,"id":676,"tags":{"url":"/api/projects"},"startTime":1772232219571,"traceId":"ac832ea7e7a97813"},{"name":"memory-usage","duration":2,"timestamp":485674600972,"id":678,"parentId":676,"tags":{"url":"/api/projects","memory.rss":"993796096","memory.heapUsed":"240915904","memory.heapTotal":"268709888"},"startTime":1772232219600,"traceId":"ac832ea7e7a97813"}] +[{"name":"hot-reloader","duration":34,"timestamp":485872766168,"id":3,"tags":{"version":"16.1.6"},"startTime":1772232417765,"traceId":"083c2d03a15572a3"},{"name":"setup-dev-bundler","duration":215203,"timestamp":485872676871,"id":2,"parentId":1,"tags":{},"startTime":1772232417676,"traceId":"083c2d03a15572a3"},{"name":"start-dev-server","duration":595594,"timestamp":485872374293,"id":1,"tags":{"cpus":"32","platform":"win32","memory.freeMem":"6663942144","memory.totalMem":"34186964992","memory.heapSizeLimit":"17143169024","memory.rss":"301711360","memory.heapTotal":"90238976","memory.heapUsed":"63624088"},"startTime":1772232417374,"traceId":"083c2d03a15572a3"},{"name":"compile-path","duration":58550,"timestamp":485876406560,"id":6,"tags":{"trigger":"/profile"},"startTime":1772232421406,"traceId":"083c2d03a15572a3"},{"name":"ensure-page","duration":59009,"timestamp":485876406372,"id":5,"parentId":3,"tags":{"inputPage":"/profile/page"},"startTime":1772232421406,"traceId":"083c2d03a15572a3"}] +[{"name":"handle-request","duration":262137,"timestamp":485876403104,"id":4,"tags":{"url":"/profile"},"startTime":1772232421402,"traceId":"083c2d03a15572a3"},{"name":"memory-usage","duration":4,"timestamp":485876665296,"id":7,"parentId":4,"tags":{"url":"/profile","memory.rss":"471646208","memory.heapUsed":"94852744","memory.heapTotal":"127197184"},"startTime":1772232421664,"traceId":"083c2d03a15572a3"},{"name":"ensure-page","duration":1048,"timestamp":485876921981,"id":8,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232421921,"traceId":"083c2d03a15572a3"},{"name":"ensure-page","duration":515,"timestamp":485876923135,"id":9,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232421922,"traceId":"083c2d03a15572a3"},{"name":"ensure-page","duration":481,"timestamp":485876924596,"id":10,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232421924,"traceId":"083c2d03a15572a3"},{"name":"ensure-page","duration":640,"timestamp":485876925199,"id":11,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232421924,"traceId":"083c2d03a15572a3"},{"name":"compile-path","duration":14137,"timestamp":485876930011,"id":14,"tags":{"trigger":"/api/auth/[...nextauth]"},"startTime":1772232421929,"traceId":"083c2d03a15572a3"}] +[{"name":"handle-request","duration":619448,"timestamp":485876928591,"id":12,"tags":{"url":"/api/auth/session"},"startTime":1772232421928,"traceId":"083c2d03a15572a3"},{"name":"memory-usage","duration":4,"timestamp":485877548099,"id":15,"parentId":12,"tags":{"url":"/api/auth/session","memory.rss":"544989184","memory.heapUsed":"104886232","memory.heapTotal":"132362240"},"startTime":1772232422547,"traceId":"083c2d03a15572a3"},{"name":"ensure-page","duration":404,"timestamp":485877558119,"id":16,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232422557,"traceId":"083c2d03a15572a3"},{"name":"ensure-page","duration":184,"timestamp":485877558555,"id":17,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232422558,"traceId":"083c2d03a15572a3"},{"name":"ensure-page","duration":359,"timestamp":485877561072,"id":18,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232422560,"traceId":"083c2d03a15572a3"},{"name":"ensure-page","duration":154,"timestamp":485877561465,"id":19,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232422561,"traceId":"083c2d03a15572a3"},{"name":"ensure-page","duration":574,"timestamp":485877564039,"id":26,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772232422563,"traceId":"083c2d03a15572a3"},{"name":"ensure-page","duration":20467,"timestamp":485877562667,"id":21,"parentId":3,"tags":{"inputPage":"/login/page"},"startTime":1772232422562,"traceId":"083c2d03a15572a3"},{"name":"compile-path","duration":51643,"timestamp":485877562714,"id":22,"tags":{"trigger":"/login"},"startTime":1772232422562,"traceId":"083c2d03a15572a3"}] +[{"name":"handle-request","duration":146072,"timestamp":485877562133,"id":20,"tags":{"url":"/login?_rsc=1ls1y"},"startTime":1772232422561,"traceId":"083c2d03a15572a3"},{"name":"memory-usage","duration":3,"timestamp":485877708232,"id":27,"parentId":20,"tags":{"url":"/login?_rsc=1ls1y","memory.rss":"573693952","memory.heapUsed":"121994664","memory.heapTotal":"147992576"},"startTime":1772232422707,"traceId":"083c2d03a15572a3"},{"name":"handle-request","duration":146374,"timestamp":485877563637,"id":25,"tags":{"url":"/api/auth/session"},"startTime":1772232422563,"traceId":"083c2d03a15572a3"},{"name":"memory-usage","duration":3,"timestamp":485877710035,"id":28,"parentId":25,"tags":{"url":"/api/auth/session","memory.rss":"574730240","memory.heapUsed":"122249176","memory.heapTotal":"147992576"},"startTime":1772232422709,"traceId":"083c2d03a15572a3"},{"name":"ensure-page","duration":588,"timestamp":485877804684,"id":30,"parentId":3,"tags":{"inputPage":"/api/user/profile/route"},"startTime":1772232422804,"traceId":"083c2d03a15572a3"},{"name":"handle-request","duration":275843,"timestamp":485877562922,"id":23,"tags":{"url":"/api/user/profile"},"startTime":1772232422562,"traceId":"083c2d03a15572a3"},{"name":"memory-usage","duration":4,"timestamp":485877838806,"id":31,"parentId":23,"tags":{"url":"/api/user/profile","memory.rss":"592932864","memory.heapUsed":"123396624","memory.heapTotal":"163504128"},"startTime":1772232422838,"traceId":"083c2d03a15572a3"},{"name":"handle-request","duration":39690,"timestamp":485877804444,"id":29,"tags":{"url":"/api/user/profile"},"startTime":1772232422804,"traceId":"083c2d03a15572a3"},{"name":"memory-usage","duration":4,"timestamp":485877844160,"id":32,"parentId":29,"tags":{"url":"/api/user/profile","memory.rss":"593088512","memory.heapUsed":"123629304","memory.heapTotal":"163504128"},"startTime":1772232422843,"traceId":"083c2d03a15572a3"},{"name":"compile-path","duration":27979,"timestamp":485880506212,"id":35,"tags":{"trigger":"/signup"},"startTime":1772232425505,"traceId":"083c2d03a15572a3"}] +[{"name":"handle-request","duration":47403,"timestamp":485880505375,"id":33,"tags":{"url":"/signup?_rsc=5c339"},"startTime":1772232425505,"traceId":"083c2d03a15572a3"},{"name":"memory-usage","duration":5,"timestamp":485880552812,"id":36,"parentId":33,"tags":{"url":"/signup?_rsc=5c339","memory.rss":"668925952","memory.heapUsed":"130348360","memory.heapTotal":"164806656"},"startTime":1772232425552,"traceId":"083c2d03a15572a3"},{"name":"compile-path","duration":15278,"timestamp":485880589300,"id":39,"tags":{"trigger":"/dashboard"},"startTime":1772232425588,"traceId":"083c2d03a15572a3"}] +[{"name":"ensure-page","duration":1954,"timestamp":485880624385,"id":41,"parentId":3,"tags":{"inputPage":"/dashboard/page"},"startTime":1772232425624,"traceId":"083c2d03a15572a3"},{"name":"handle-request","duration":56120,"timestamp":485880589028,"id":37,"tags":{"url":"/dashboard?_rsc=6k3yh"},"startTime":1772232425588,"traceId":"083c2d03a15572a3"},{"name":"memory-usage","duration":5,"timestamp":485880645175,"id":42,"parentId":37,"tags":{"url":"/dashboard?_rsc=6k3yh","memory.rss":"674729984","memory.heapUsed":"140028496","memory.heapTotal":"166633472"},"startTime":1772232425644,"traceId":"083c2d03a15572a3"},{"name":"handle-request","duration":23039,"timestamp":485880624079,"id":40,"tags":{"url":"/dashboard?_rsc=6k3yh"},"startTime":1772232425623,"traceId":"083c2d03a15572a3"},{"name":"memory-usage","duration":3,"timestamp":485880647151,"id":43,"parentId":40,"tags":{"url":"/dashboard?_rsc=6k3yh","memory.rss":"674848768","memory.heapUsed":"140221096","memory.heapTotal":"166895616"},"startTime":1772232425646,"traceId":"083c2d03a15572a3"},{"name":"compile-path","duration":5887,"timestamp":485880688436,"id":46,"tags":{"trigger":"/api/projects"},"startTime":1772232425688,"traceId":"083c2d03a15572a3"}] +[{"name":"handle-request","duration":45960,"timestamp":485880687767,"id":44,"tags":{"url":"/api/projects"},"startTime":1772232425687,"traceId":"083c2d03a15572a3"},{"name":"memory-usage","duration":4,"timestamp":485880733758,"id":47,"parentId":44,"tags":{"url":"/api/projects","memory.rss":"683155456","memory.heapUsed":"136441368","memory.heapTotal":"168345600"},"startTime":1772232425733,"traceId":"083c2d03a15572a3"},{"name":"ensure-page","duration":487,"timestamp":485880734657,"id":49,"parentId":3,"tags":{"inputPage":"/api/projects/route"},"startTime":1772232425734,"traceId":"083c2d03a15572a3"},{"name":"handle-request","duration":26225,"timestamp":485880734423,"id":48,"tags":{"url":"/api/projects"},"startTime":1772232425734,"traceId":"083c2d03a15572a3"},{"name":"memory-usage","duration":4,"timestamp":485880760675,"id":50,"parentId":48,"tags":{"url":"/api/projects","memory.rss":"683479040","memory.heapUsed":"137854632","memory.heapTotal":"168607744"},"startTime":1772232425760,"traceId":"083c2d03a15572a3"},{"name":"ensure-page","duration":626,"timestamp":485884181267,"id":51,"parentId":3,"tags":{"inputPage":"/api/auth/csrf"},"startTime":1772232429180,"traceId":"083c2d03a15572a3"},{"name":"ensure-page","duration":344,"timestamp":485884181948,"id":52,"parentId":3,"tags":{"inputPage":"/api/auth/csrf"},"startTime":1772232429181,"traceId":"083c2d03a15572a3"},{"name":"ensure-page","duration":424,"timestamp":485884184245,"id":56,"parentId":3,"tags":{"inputPage":"/api/auth/csrf"},"startTime":1772232429183,"traceId":"083c2d03a15572a3"},{"name":"ensure-page","duration":293,"timestamp":485884184702,"id":57,"parentId":3,"tags":{"inputPage":"/api/auth/csrf"},"startTime":1772232429184,"traceId":"083c2d03a15572a3"},{"name":"ensure-page","duration":583,"timestamp":485884186082,"id":59,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772232429185,"traceId":"083c2d03a15572a3"},{"name":"compile-path","duration":21030,"timestamp":485884183479,"id":55,"tags":{"trigger":"/"},"startTime":1772232429183,"traceId":"083c2d03a15572a3"}] +[{"name":"handle-request","duration":35901,"timestamp":485884185667,"id":58,"tags":{"url":"/api/auth/csrf"},"startTime":1772232429185,"traceId":"083c2d03a15572a3"},{"name":"memory-usage","duration":3,"timestamp":485884221588,"id":60,"parentId":58,"tags":{"url":"/api/auth/csrf","memory.rss":"713089024","memory.heapUsed":"145382208","memory.heapTotal":"170958848"},"startTime":1772232429221,"traceId":"083c2d03a15572a3"},{"name":"handle-request","duration":40143,"timestamp":485884182811,"id":53,"tags":{"url":"/?_rsc=1h1b5"},"startTime":1772232429182,"traceId":"083c2d03a15572a3"},{"name":"memory-usage","duration":3,"timestamp":485884222969,"id":61,"parentId":53,"tags":{"url":"/?_rsc=1h1b5","memory.rss":"713216000","memory.heapUsed":"145461296","memory.heapTotal":"170958848"},"startTime":1772232429222,"traceId":"083c2d03a15572a3"},{"name":"ensure-page","duration":174,"timestamp":485884226621,"id":62,"parentId":3,"tags":{"inputPage":"/api/auth/signout"},"startTime":1772232429226,"traceId":"083c2d03a15572a3"},{"name":"ensure-page","duration":109,"timestamp":485884226813,"id":63,"parentId":3,"tags":{"inputPage":"/api/auth/signout"},"startTime":1772232429226,"traceId":"083c2d03a15572a3"},{"name":"ensure-page","duration":162,"timestamp":485884227194,"id":64,"parentId":3,"tags":{"inputPage":"/api/auth/signout"},"startTime":1772232429226,"traceId":"083c2d03a15572a3"},{"name":"ensure-page","duration":109,"timestamp":485884227372,"id":65,"parentId":3,"tags":{"inputPage":"/api/auth/signout"},"startTime":1772232429227,"traceId":"083c2d03a15572a3"},{"name":"ensure-page","duration":389,"timestamp":485884228229,"id":67,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772232429227,"traceId":"083c2d03a15572a3"},{"name":"handle-request","duration":6343,"timestamp":485884228024,"id":66,"tags":{"url":"/api/auth/signout"},"startTime":1772232429227,"traceId":"083c2d03a15572a3"},{"name":"memory-usage","duration":7,"timestamp":485884234400,"id":68,"parentId":66,"tags":{"url":"/api/auth/signout","memory.rss":"715591680","memory.heapUsed":"147257304","memory.heapTotal":"171220992"},"startTime":1772232429234,"traceId":"083c2d03a15572a3"},{"name":"ensure-page","duration":445,"timestamp":485884269074,"id":69,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232429268,"traceId":"083c2d03a15572a3"},{"name":"ensure-page","duration":295,"timestamp":485884269556,"id":70,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232429269,"traceId":"083c2d03a15572a3"},{"name":"ensure-page","duration":366,"timestamp":485884270450,"id":71,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232429270,"traceId":"083c2d03a15572a3"},{"name":"ensure-page","duration":275,"timestamp":485884270846,"id":72,"parentId":3,"tags":{"inputPage":"/api/auth/session"},"startTime":1772232429270,"traceId":"083c2d03a15572a3"},{"name":"ensure-page","duration":865,"timestamp":485884272185,"id":74,"parentId":3,"tags":{"inputPage":"/api/auth/[...nextauth]/route"},"startTime":1772232429271,"traceId":"083c2d03a15572a3"},{"name":"handle-request","duration":10140,"timestamp":485884271739,"id":73,"tags":{"url":"/api/auth/session"},"startTime":1772232429271,"traceId":"083c2d03a15572a3"},{"name":"memory-usage","duration":7,"timestamp":485884281916,"id":75,"parentId":73,"tags":{"url":"/api/auth/session","memory.rss":"720760832","memory.heapUsed":"142152128","memory.heapTotal":"175927296"},"startTime":1772232429281,"traceId":"083c2d03a15572a3"},{"name":"ensure-page","duration":823,"timestamp":485885547208,"id":77,"parentId":3,"tags":{"inputPage":"/login/page"},"startTime":1772232430546,"traceId":"083c2d03a15572a3"},{"name":"handle-request","duration":9092,"timestamp":485885546907,"id":76,"tags":{"url":"/login?_rsc=vusbg"},"startTime":1772232430546,"traceId":"083c2d03a15572a3"},{"name":"memory-usage","duration":4,"timestamp":485885556040,"id":78,"parentId":76,"tags":{"url":"/login?_rsc=vusbg","memory.rss":"721088512","memory.heapUsed":"144550272","memory.heapTotal":"175927296"},"startTime":1772232430555,"traceId":"083c2d03a15572a3"},{"name":"ensure-page","duration":798,"timestamp":485887382123,"id":80,"parentId":3,"tags":{"inputPage":"/signup/page"},"startTime":1772232432381,"traceId":"083c2d03a15572a3"},{"name":"handle-request","duration":11302,"timestamp":485887381861,"id":79,"tags":{"url":"/signup?_rsc=5c339"},"startTime":1772232432381,"traceId":"083c2d03a15572a3"},{"name":"memory-usage","duration":3,"timestamp":485887393181,"id":81,"parentId":79,"tags":{"url":"/signup?_rsc=5c339","memory.rss":"689848320","memory.heapUsed":"136654576","memory.heapTotal":"143470592"},"startTime":1772232432392,"traceId":"083c2d03a15572a3"},{"name":"compile-path","duration":17079,"timestamp":485899607743,"id":84,"tags":{"trigger":"/api/auth/register"},"startTime":1772232444607,"traceId":"083c2d03a15572a3"}] diff --git a/prisma.config.ts b/prisma.config.ts index c08463e..f4fcb11 100644 --- a/prisma.config.ts +++ b/prisma.config.ts @@ -9,6 +9,7 @@ export default defineConfig({ schema: "prisma/schema.prisma", migrations: { path: "prisma/migrations", + seed: "tsx prisma/seed.ts", }, datasource: { url: process.env["DATABASE_URL"], diff --git a/prisma/schema.prisma b/prisma/schema.prisma index 6216c1f..cc3b07f 100644 --- a/prisma/schema.prisma +++ b/prisma/schema.prisma @@ -31,6 +31,7 @@ model User { email String @unique hashedPassword String bio String? + avatar String? // Legacy string plan (temporarily kept to avoid DB drop errors) plan String @default("free") diff --git a/prisma/seed.ts b/prisma/seed.ts index 0e8bb27..972804c 100644 --- a/prisma/seed.ts +++ b/prisma/seed.ts @@ -25,9 +25,9 @@ async function main() { displayName: 'Auteur Pro', price: 12, description: 'Pour les écrivains sérieux.', - maxProjects: -1, // -1 means unlimited - maxAiActions: 500, - features: ['500 actions IA / mois', 'Projets illimités', 'Export Word & EPUB', 'Support prioritaire'], + maxProjects: 5, // -1 means unlimited + maxAiActions: 75, + features: ['75 actions IA / mois', 'Projets illimités', 'Export Word & EPUB', 'Support prioritaire'], isPopular: true, }, { @@ -36,9 +36,9 @@ async function main() { displayName: 'Maître Plume', price: 29, description: 'Le summum de l\'écriture IA.', - maxProjects: -1, - maxAiActions: -1, // -1 means unlimited - features: ['Actions IA illimitées', 'Accès Gemini 3 Pro', 'Bible du monde avancée', 'Outils de révision avancés'], + maxProjects: 20, + maxAiActions: 250, // -1 means unlimited + features: ['250 actions IA / mois', 'Accès Gemini 3 Pro', 'Bible du monde avancée', 'Outils de révision avancés'], isPopular: false, }, ]; diff --git a/src/app/profile/page.tsx b/src/app/profile/page.tsx index eff7997..8a13475 100644 --- a/src/app/profile/page.tsx +++ b/src/app/profile/page.tsx @@ -7,7 +7,7 @@ import { useEffect } from 'react'; export default function ProfilePage() { const router = useRouter(); - const { user, loading } = useAuthContext(); + const { user, loading, updateProfile } = useAuthContext(); useEffect(() => { if (!loading && !user) { @@ -20,7 +20,13 @@ export default function ProfilePage() { return ( console.log('Profile update:', updates)} + onUpdate={async (updates) => { + try { + await updateProfile(updates); + } catch (err) { + // Handled inside updateProfile (console.error) + } + }} onBack={() => router.push('/dashboard')} /> ); diff --git a/src/components/UserProfileSettings.tsx b/src/components/UserProfileSettings.tsx index 0a64e2c..64494a3 100644 --- a/src/components/UserProfileSettings.tsx +++ b/src/components/UserProfileSettings.tsx @@ -23,15 +23,58 @@ const UserProfileSettings: React.FC = ({ user, onUpdat const [activeTab, setActiveTab] = useState<'profile' | 'preferences' | 'account'>('profile'); const [formData, setFormData] = useState({ name: user.name, + avatar: user.avatar || '', bio: user.bio || '', email: user.email, theme: user.preferences.theme, dailyWordGoal: user.preferences.dailyWordGoal }); + const fileInputRef = React.useRef(null); + + const handleImageUpload = (event: React.ChangeEvent) => { + const file = event.target.files?.[0]; + if (!file) return; + if (!file.type.startsWith('image/')) { + alert('Veuillez sélectionner une image valide.'); + return; + } + + const reader = new FileReader(); + reader.onload = (e) => { + const img = new Image(); + img.onload = () => { + const MAX_SIZE = 256; + let width = img.width; + let height = img.height; + + if (width > height && width > MAX_SIZE) { + height = Math.round((height * MAX_SIZE) / width); + width = MAX_SIZE; + } else if (height > MAX_SIZE) { + width = Math.round((width * MAX_SIZE) / height); + height = MAX_SIZE; + } + + const canvas = document.createElement('canvas'); + canvas.width = width; + canvas.height = height; + const ctx = canvas.getContext('2d'); + if (ctx) { + ctx.drawImage(img, 0, 0, width, height); + const dataUrl = canvas.toDataURL('image/jpeg', 0.8); + setFormData(prev => ({ ...prev, avatar: dataUrl })); + } + }; + img.src = e.target?.result as string; + }; + reader.readAsDataURL(file); + }; + const handleSave = () => { onUpdate({ name: formData.name, + avatar: formData.avatar, bio: formData.bio, email: formData.email, preferences: { @@ -82,11 +125,18 @@ const UserProfileSettings: React.FC = ({ user, onUpdat {activeTab === 'profile' && (
-
- Avatar - +

{user.name}

@@ -109,6 +159,7 @@ const UserProfileSettings: React.FC = ({ user, onUpdat className="w-full p-3 bg-slate-50 border border-slate-200 rounded-xl outline-none focus:ring-2 focus:ring-blue-500" />
+