wcz-layout 10.2.0 → 10.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{ChatLayout-Tpuwo8-b.mjs → ChatLayout-CkS9oyPp.mjs} +597 -293
- package/dist/ChatLayout-CkS9oyPp.mjs.map +1 -0
- package/dist/{Employee-C8xIlBxY.d.mts → ExtractFile-ClTc-e1H.d.mts} +20 -3
- package/dist/RouterListItemButton-CF-8w-08.mjs.map +1 -1
- package/dist/Translate-Ad784Dps.d.mts +24 -0
- package/dist/{Approval-D1TfISUL.mjs → Translate-BiCjnlyx.mjs} +22 -2
- package/dist/Translate-BiCjnlyx.mjs.map +1 -0
- package/dist/ai.d.mts +36 -0
- package/dist/ai.mjs +168 -0
- package/dist/ai.mjs.map +1 -0
- package/dist/auth.d.mts +4 -3
- package/dist/auth.mjs +5 -4
- package/dist/auth.mjs.map +1 -1
- package/dist/authMiddleware-D4GSt7m9.mjs +50 -0
- package/dist/authMiddleware-D4GSt7m9.mjs.map +1 -0
- package/dist/components.mjs +55 -45
- package/dist/components.mjs.map +1 -1
- package/dist/{createApi-CKgFi53y.mjs → createApi-CF4ZL82B.mjs} +3 -4
- package/dist/createApi-CF4ZL82B.mjs.map +1 -0
- package/dist/data/client.d.mts +17 -1
- package/dist/data/client.mjs +11 -5
- package/dist/data/client.mjs.map +1 -1
- package/dist/data/server.d.mts +18 -3
- package/dist/data/server.mjs +5 -5
- package/dist/{env-BwFl7nWc.mjs → env-Cddts_dn.mjs} +2 -1
- package/dist/env-Cddts_dn.mjs.map +1 -0
- package/dist/{file-X1sK4ok6.mjs → file-D4kSR_lC.mjs} +5 -6
- package/dist/file-D4kSR_lC.mjs.map +1 -0
- package/dist/{file-tkfsnk5F.mjs → file-DcwYjofa.mjs} +6 -7
- package/dist/file-DcwYjofa.mjs.map +1 -0
- package/dist/generatedChart-k7NEdi5Z.mjs.map +1 -1
- package/dist/hooks.d.mts +2 -2
- package/dist/hooks.mjs +296 -194
- package/dist/hooks.mjs.map +1 -1
- package/dist/index.mjs +224 -173
- package/dist/index.mjs.map +1 -1
- package/dist/{approval-HB2w5jzc.mjs → layout-6We_KFgN.mjs} +28 -4
- package/dist/layout-6We_KFgN.mjs.map +1 -0
- package/dist/middleware.mjs +1 -45
- package/dist/middleware.mjs.map +1 -1
- package/dist/models.d.mts +3 -3
- package/dist/models.mjs +2 -2
- package/dist/{peoplesoft-RnvfLbWH.mjs → peoplesoft-DH31FCMC.mjs} +3 -3
- package/dist/{peoplesoft-RnvfLbWH.mjs.map → peoplesoft-DH31FCMC.mjs.map} +1 -1
- package/dist/{peoplesoft-C-zPdRVj.d.mts → peoplesoft-DXukeeFr.d.mts} +2 -2
- package/dist/{providers-BfFg_3eo.mjs → providers-DOFje2P6.mjs} +7 -7
- package/dist/providers-DOFje2P6.mjs.map +1 -0
- package/dist/{tokens-C4SErO-K.mjs → tokens-DNe_Qifk.mjs} +63 -9
- package/dist/tokens-DNe_Qifk.mjs.map +1 -0
- package/dist/user-Bc2nLjAG.mjs +136 -0
- package/dist/user-Bc2nLjAG.mjs.map +1 -0
- package/dist/utils-CgabUlDD.mjs +131 -0
- package/dist/utils-CgabUlDD.mjs.map +1 -0
- package/dist/utils.d.mts +1 -10
- package/dist/utils.mjs +5 -3
- package/package.json +45 -14
- package/skills/ai/SKILL.md +108 -75
- package/skills/general/references/auth.md +7 -3
- package/skills/migrations/versions/migrate-v10-to-v11.md +4 -0
- package/skills/services/SKILL.md +41 -7
- package/skills/services/docs/approval.md +5 -0
- package/skills/services/docs/layout.md +130 -0
- package/skills/start/steps/03-apm-setup.md +8 -1
- package/dist/Approval-D1TfISUL.mjs.map +0 -1
- package/dist/ChatLayout-Tpuwo8-b.mjs.map +0 -1
- package/dist/Email-Dz5k0UWE.d.mts +0 -15
- package/dist/approval-HB2w5jzc.mjs.map +0 -1
- package/dist/createApi-CKgFi53y.mjs.map +0 -1
- package/dist/env-BwFl7nWc.mjs.map +0 -1
- package/dist/file-X1sK4ok6.mjs.map +0 -1
- package/dist/file-tkfsnk5F.mjs.map +0 -1
- package/dist/providers-BfFg_3eo.mjs.map +0 -1
- package/dist/tokens-C4SErO-K.mjs.map +0 -1
- package/dist/utils-C2MZoH9U.mjs +0 -263
- package/dist/utils-C2MZoH9U.mjs.map +0 -1
- package/dist/utils-DnMFybj3.mjs +0 -27
- package/dist/utils-DnMFybj3.mjs.map +0 -1
package/dist/utils-C2MZoH9U.mjs
DELETED
|
@@ -1,263 +0,0 @@
|
|
|
1
|
-
import { n as serverEnv } from "./env-BwFl7nWc.mjs";
|
|
2
|
-
import { queryOptions } from "@tanstack/react-query";
|
|
3
|
-
import { manifest, permissions } from "virtual:wcz-layout";
|
|
4
|
-
import { redirect } from "@tanstack/react-router";
|
|
5
|
-
import { createServerFn } from "@tanstack/react-start";
|
|
6
|
-
// src/lib/auth/offline.ts
|
|
7
|
-
/**
|
|
8
|
-
* Offline fallback for identity. The refresh token never leaves the sealed
|
|
9
|
-
* httpOnly cookie — what is cached here is only the display snapshot (user
|
|
10
|
-
* claims and avatar) so the UI and offline route permissions can still work
|
|
11
|
-
* while the server is unreachable. Server requests remain independently
|
|
12
|
-
* authorized. At-rest protection is the device's OS login and disk encryption.
|
|
13
|
-
*/
|
|
14
|
-
const OFFLINE_USER_KEY = "auth-user";
|
|
15
|
-
const OFFLINE_PHOTO_KEY = "auth-photo";
|
|
16
|
-
/** One shift — matches Intune's default offline grace period. */
|
|
17
|
-
const GRACE_PERIOD = 432e5;
|
|
18
|
-
const recall = (key) => {
|
|
19
|
-
if (typeof localStorage === "undefined") return null;
|
|
20
|
-
try {
|
|
21
|
-
const raw = localStorage.getItem(key);
|
|
22
|
-
if (!raw) return null;
|
|
23
|
-
const { value, savedAt } = JSON.parse(raw);
|
|
24
|
-
if (Date.now() - savedAt > GRACE_PERIOD) {
|
|
25
|
-
localStorage.removeItem(key);
|
|
26
|
-
return null;
|
|
27
|
-
}
|
|
28
|
-
return value;
|
|
29
|
-
} catch {
|
|
30
|
-
localStorage.removeItem(key);
|
|
31
|
-
return null;
|
|
32
|
-
}
|
|
33
|
-
};
|
|
34
|
-
const remember = (key, value) => {
|
|
35
|
-
if (typeof localStorage === "undefined") return;
|
|
36
|
-
try {
|
|
37
|
-
if (value === null || value === void 0) localStorage.removeItem(key);
|
|
38
|
-
else localStorage.setItem(key, JSON.stringify({
|
|
39
|
-
value,
|
|
40
|
-
savedAt: Date.now()
|
|
41
|
-
}));
|
|
42
|
-
} catch {}
|
|
43
|
-
};
|
|
44
|
-
const isOfflineFailure = (error) => typeof navigator !== "undefined" && !navigator.onLine || error instanceof TypeError;
|
|
45
|
-
/**
|
|
46
|
-
* Answers from the server when reachable, remembering the result; when the call
|
|
47
|
-
* has a transport failure, replays the last result instead, for up to
|
|
48
|
-
* {@link GRACE_PERIOD} since it was last confirmed.
|
|
49
|
-
*
|
|
50
|
-
* Cached values are untrusted client state. Server authorization must never
|
|
51
|
-
* depend on them.
|
|
52
|
-
*/
|
|
53
|
-
const withOfflineFallback = async (key, fetchFresh) => {
|
|
54
|
-
try {
|
|
55
|
-
const fresh = await fetchFresh();
|
|
56
|
-
remember(key, fresh);
|
|
57
|
-
return fresh;
|
|
58
|
-
} catch (error) {
|
|
59
|
-
if (!isOfflineFailure(error)) throw error;
|
|
60
|
-
return recall(key);
|
|
61
|
-
}
|
|
62
|
-
};
|
|
63
|
-
/** Drops the cached identity. Call on logout, before leaving the page. */
|
|
64
|
-
const clearSessionSnapshot = () => {
|
|
65
|
-
if (typeof localStorage === "undefined") return;
|
|
66
|
-
localStorage.removeItem(OFFLINE_USER_KEY);
|
|
67
|
-
localStorage.removeItem(OFFLINE_PHOTO_KEY);
|
|
68
|
-
localStorage.setItem("auth-logout", String(Date.now()));
|
|
69
|
-
};
|
|
70
|
-
if (typeof window !== "undefined") window.addEventListener("storage", (event) => {
|
|
71
|
-
if (event.key === "auth-logout") location.href = "/auth/logout";
|
|
72
|
-
});
|
|
73
|
-
// src/lib/auth/session.ts
|
|
74
|
-
const getAppSession = async () => {
|
|
75
|
-
const [{ getIronSession }, { getCookie, setCookie }] = await Promise.all([import("iron-session"), import("@tanstack/react-start/server")]);
|
|
76
|
-
return getIronSession({
|
|
77
|
-
read: getCookie,
|
|
78
|
-
write: setCookie
|
|
79
|
-
}, {
|
|
80
|
-
cookieName: "app-session",
|
|
81
|
-
password: serverEnv.SESSION_SECRET,
|
|
82
|
-
chunk: true,
|
|
83
|
-
cookieOptions: {
|
|
84
|
-
secure: process.env.NODE_ENV === "production",
|
|
85
|
-
sameSite: "lax",
|
|
86
|
-
httpOnly: true,
|
|
87
|
-
path: "/",
|
|
88
|
-
maxAge: void 0
|
|
89
|
-
}
|
|
90
|
-
});
|
|
91
|
-
};
|
|
92
|
-
// src/lib/auth/user.ts
|
|
93
|
-
/**
|
|
94
|
-
* Reads the signed-in user from the session cookie, or null. As a server function
|
|
95
|
-
* it runs in-process when called on the server (SSR, middleware) and as an RPC
|
|
96
|
-
* when called from the client — so it doubles as the client `queryFn`.
|
|
97
|
-
*/
|
|
98
|
-
const getSessionUser = createServerFn({ method: "GET" }).handler(async () => {
|
|
99
|
-
return (await getAppSession()).user ?? null;
|
|
100
|
-
});
|
|
101
|
-
/** The identity providers the server offers, for the login page. */
|
|
102
|
-
const getLoginProviders = createServerFn({ method: "GET" }).handler(async () => {
|
|
103
|
-
const { providers } = await import("./providers-BfFg_3eo.mjs").then((n) => n.i);
|
|
104
|
-
return providers.map(({ id, label }) => ({
|
|
105
|
-
id,
|
|
106
|
-
label
|
|
107
|
-
}));
|
|
108
|
-
});
|
|
109
|
-
/**
|
|
110
|
-
* Feeds `LoginForm`. Server config, not per-user, so it is safe to prime on the
|
|
111
|
-
* server — the `/login` route's loader does that to avoid a flash of empty card.
|
|
112
|
-
*/
|
|
113
|
-
const loginProvidersQueryOptions = queryOptions({
|
|
114
|
-
queryKey: ["auth", "providers"],
|
|
115
|
-
queryFn: () => getLoginProviders(),
|
|
116
|
-
staleTime: "static"
|
|
117
|
-
});
|
|
118
|
-
/**
|
|
119
|
-
* Client-side query for the signed-in user. Shared between `getUser` (route
|
|
120
|
-
* `beforeLoad`) and the always-mounted observer in `LayoutProvider` — the
|
|
121
|
-
* observer is what seeds the offline snapshot on the very first page load
|
|
122
|
-
* (`beforeLoad` does not re-run after SSR hydration) and what makes
|
|
123
|
-
* `refetchOnReconnect` fire once connectivity returns.
|
|
124
|
-
*/
|
|
125
|
-
const userQueryOptions = queryOptions({
|
|
126
|
-
queryKey: ["auth", "user"],
|
|
127
|
-
queryFn: () => withOfflineFallback(OFFLINE_USER_KEY, () => getSessionUser()),
|
|
128
|
-
staleTime: Infinity,
|
|
129
|
-
networkMode: "offlineFirst",
|
|
130
|
-
refetchOnReconnect: "always"
|
|
131
|
-
});
|
|
132
|
-
const getUser = ({ queryClient }) => {
|
|
133
|
-
if (import.meta.env.SSR) return getSessionUser();
|
|
134
|
-
return queryClient.ensureQueryData(userQueryOptions);
|
|
135
|
-
};
|
|
136
|
-
// src/lib/utils.ts
|
|
137
|
-
const WISTRON_PRIMARY_COLOR = "#00506E";
|
|
138
|
-
const WISTRON_SECONDARY_COLOR = "#64DC00";
|
|
139
|
-
var Platform = class {
|
|
140
|
-
static get isAndroid() {
|
|
141
|
-
return /android/i.test(this.userAgent);
|
|
142
|
-
}
|
|
143
|
-
static get isIOS() {
|
|
144
|
-
return /iPad|iPhone|iPod/.test(this.userAgent);
|
|
145
|
-
}
|
|
146
|
-
static get isWindows() {
|
|
147
|
-
return /windows/i.test(this.userAgent);
|
|
148
|
-
}
|
|
149
|
-
static get isMacOS() {
|
|
150
|
-
return /Macintosh|MacIntel|MacPPC|Mac68K/.test(this.userAgent);
|
|
151
|
-
}
|
|
152
|
-
static get userAgent() {
|
|
153
|
-
return typeof navigator === "undefined" ? "" : navigator.userAgent;
|
|
154
|
-
}
|
|
155
|
-
};
|
|
156
|
-
const rootRouteHead = (options) => ({
|
|
157
|
-
meta: [
|
|
158
|
-
{ charSet: "utf-8" },
|
|
159
|
-
{
|
|
160
|
-
name: "viewport",
|
|
161
|
-
content: "width=device-width, initial-scale=1"
|
|
162
|
-
},
|
|
163
|
-
{ title: manifest.name },
|
|
164
|
-
{
|
|
165
|
-
name: "og:type",
|
|
166
|
-
content: "website"
|
|
167
|
-
},
|
|
168
|
-
{
|
|
169
|
-
name: "og:title",
|
|
170
|
-
content: manifest.name
|
|
171
|
-
},
|
|
172
|
-
{
|
|
173
|
-
name: "og:image",
|
|
174
|
-
content: "/favicon-32x32.png"
|
|
175
|
-
}
|
|
176
|
-
],
|
|
177
|
-
links: [
|
|
178
|
-
{
|
|
179
|
-
rel: "apple-touch-icon",
|
|
180
|
-
sizes: "180x180",
|
|
181
|
-
href: "/apple-touch-icon.png"
|
|
182
|
-
},
|
|
183
|
-
{
|
|
184
|
-
rel: "icon",
|
|
185
|
-
type: "image/png",
|
|
186
|
-
sizes: "32x32",
|
|
187
|
-
href: "/favicon-32x32.png"
|
|
188
|
-
},
|
|
189
|
-
{
|
|
190
|
-
rel: "icon",
|
|
191
|
-
type: "image/png",
|
|
192
|
-
sizes: "16x16",
|
|
193
|
-
href: "/favicon-16x16.png"
|
|
194
|
-
},
|
|
195
|
-
{
|
|
196
|
-
rel: "manifest",
|
|
197
|
-
href: options?.manifest || "/manifest.json"
|
|
198
|
-
},
|
|
199
|
-
{
|
|
200
|
-
rel: "icon",
|
|
201
|
-
href: "/favicon.ico"
|
|
202
|
-
}
|
|
203
|
-
]
|
|
204
|
-
});
|
|
205
|
-
/**
|
|
206
|
-
* Route guard for `beforeLoad`. Routes are public by default; add this to close one.
|
|
207
|
-
*
|
|
208
|
-
* - `requireAuth()` — signed in with any provider. The only gate a population
|
|
209
|
-
* without permission groups (e.g. AWS users) can pass.
|
|
210
|
-
* - `requireAuth("admin")` — signed in *and* in a group listed under that key.
|
|
211
|
-
*
|
|
212
|
-
* `reloadDocument` is required: `/auth/login` is a component-less server route and
|
|
213
|
-
* must be reached with a full-document navigation. It starts the login directly when
|
|
214
|
-
* only one provider is registered, otherwise it forwards to the `/login` chooser.
|
|
215
|
-
*/
|
|
216
|
-
const requireAuth = (permissionKey) => {
|
|
217
|
-
return async ({ location, context }) => {
|
|
218
|
-
const user = await getUser({ queryClient: context.queryClient });
|
|
219
|
-
if (!user) throw redirect({
|
|
220
|
-
href: `/auth/login?returnTo=${encodeURIComponent(location.href)}`,
|
|
221
|
-
reloadDocument: true
|
|
222
|
-
});
|
|
223
|
-
if (permissionKey && !hasPermission(user, permissionKey)) throw new Error("You do not have permission to access this page.");
|
|
224
|
-
return { user };
|
|
225
|
-
};
|
|
226
|
-
};
|
|
227
|
-
const NON_PRODUCTION = /(?:^|[.-])(?:dev|qas|uat|test)(?:[.-]|$)/i;
|
|
228
|
-
/** True only for a dev/qas/uat/test domain — localhost and production are not. */
|
|
229
|
-
const isTestEnv = (origin) => NON_PRODUCTION.test((origin ?? "").split(".").slice(1).join("."));
|
|
230
|
-
const getFieldStatus = (field) => {
|
|
231
|
-
const { meta } = field.state;
|
|
232
|
-
return {
|
|
233
|
-
isTouched: meta.isTouched,
|
|
234
|
-
hasError: !!meta.errors.length,
|
|
235
|
-
helperText: meta.errors[0]?.message
|
|
236
|
-
};
|
|
237
|
-
};
|
|
238
|
-
/**
|
|
239
|
-
* Only same-origin paths are allowed, so `returnTo` cannot become an open
|
|
240
|
-
* redirect. Backslash counts as a separator too: browsers normalize `/\evil`
|
|
241
|
-
* to the protocol-relative `//evil`.
|
|
242
|
-
*/
|
|
243
|
-
const sanitizeReturnTo = (value) => value && /^\/(?![/\\])/.test(value) ? value : "/";
|
|
244
|
-
const foldForSearch = (value) => String(value ?? "").toLowerCase().normalize("NFD").replaceAll(/[\u{300}-\u{36F}]/gu, "").normalize("NFC");
|
|
245
|
-
const permissionGroups = new Set(Object.values(permissions).flat());
|
|
246
|
-
/**
|
|
247
|
-
* Maps id/access-token claims to the serializable `User`. Groups are trimmed to
|
|
248
|
-
* those named in `permissions.ts` — an unfiltered group list would blow the
|
|
249
|
-
* cookie. Cognito's claim names differ, so both are read.
|
|
250
|
-
*/
|
|
251
|
-
const buildUser = (payload, provider) => ({
|
|
252
|
-
provider,
|
|
253
|
-
name: (payload.name ?? payload["cognito:username"] ?? "").split("/")[0],
|
|
254
|
-
email: (payload.preferred_username ?? payload.email ?? "").toLowerCase(),
|
|
255
|
-
department: payload.department?.toUpperCase() || "",
|
|
256
|
-
employeeId: (payload.employeeId ?? payload["cognito:username"] ?? "").toUpperCase(),
|
|
257
|
-
companyName: payload.companyName || "",
|
|
258
|
-
groups: (payload.groups ?? payload["cognito:groups"])?.filter((group) => permissionGroups.has(group)) ?? []
|
|
259
|
-
});
|
|
260
|
-
const hasPermission = (user, key) => user ? permissions[key].some((group) => user.groups.includes(group)) : false;
|
|
261
|
-
export { OFFLINE_PHOTO_KEY as _, foldForSearch as a, isTestEnv as c, sanitizeReturnTo as d, getSessionUser as f, getAppSession as g, userQueryOptions as h, buildUser as i, requireAuth as l, loginProvidersQueryOptions as m, WISTRON_PRIMARY_COLOR as n, getFieldStatus as o, getUser as p, WISTRON_SECONDARY_COLOR as r, hasPermission as s, Platform as t, rootRouteHead as u, clearSessionSnapshot as v, withOfflineFallback as y };
|
|
262
|
-
|
|
263
|
-
//# sourceMappingURL=utils-C2MZoH9U.mjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"utils-C2MZoH9U.mjs","names":[],"sources":["../src/lib/auth/offline.ts","../src/lib/auth/session.ts","../src/lib/auth/user.ts","../src/lib/utils.ts"],"sourcesContent":["/**\n * Offline fallback for identity. The refresh token never leaves the sealed\n * httpOnly cookie — what is cached here is only the display snapshot (user\n * claims and avatar) so the UI and offline route permissions can still work\n * while the server is unreachable. Server requests remain independently\n * authorized. At-rest protection is the device's OS login and disk encryption.\n */\n\nexport const OFFLINE_USER_KEY = \"auth-user\";\nexport const OFFLINE_PHOTO_KEY = \"auth-photo\";\n\n/** One shift — matches Intune's default offline grace period. */\nconst GRACE_PERIOD = 12 * 60 * 60 * 1000;\n\ntype Cached<T> = { value: T; savedAt: number };\n\nconst recall = <T>(key: string): T | null => {\n if (typeof localStorage === \"undefined\") return null;\n try {\n const raw = localStorage.getItem(key);\n if (!raw) return null;\n const { value, savedAt } = JSON.parse(raw) as Cached<T>;\n if (Date.now() - savedAt > GRACE_PERIOD) {\n localStorage.removeItem(key);\n return null;\n }\n return value;\n } catch {\n localStorage.removeItem(key);\n return null;\n }\n};\n\nconst remember = (key: string, value: unknown): void => {\n if (typeof localStorage === \"undefined\") return;\n try {\n if (value === null || value === undefined) localStorage.removeItem(key);\n else localStorage.setItem(key, JSON.stringify({ value, savedAt: Date.now() }));\n } catch {\n // Storage full or blocked — the offline fallback is best-effort.\n }\n};\n\nconst isOfflineFailure = (error: unknown): boolean =>\n (typeof navigator !== \"undefined\" && !navigator.onLine) || error instanceof TypeError;\n\n/**\n * Answers from the server when reachable, remembering the result; when the call\n * has a transport failure, replays the last result instead, for up to\n * {@link GRACE_PERIOD} since it was last confirmed.\n *\n * Cached values are untrusted client state. Server authorization must never\n * depend on them.\n */\nexport const withOfflineFallback = async <T>(\n key: string,\n fetchFresh: () => Promise<T>,\n): Promise<T | null> => {\n try {\n const fresh = await fetchFresh();\n remember(key, fresh);\n return fresh;\n } catch (error) {\n if (!isOfflineFailure(error)) throw error;\n return recall<T>(key);\n }\n};\n\n/** Drops the cached identity. Call on logout, before leaving the page. */\nexport const clearSessionSnapshot = (): void => {\n if (typeof localStorage === \"undefined\") return;\n localStorage.removeItem(OFFLINE_USER_KEY);\n localStorage.removeItem(OFFLINE_PHOTO_KEY);\n localStorage.setItem(\"auth-logout\", String(Date.now()));\n};\n\nif (typeof window !== \"undefined\")\n window.addEventListener(\"storage\", (event) => {\n if (event.key === \"auth-logout\") location.href = \"/auth/logout\";\n });\n","import type { IronSession } from \"iron-session\";\nimport { serverEnv } from \"~/env\";\nimport type { ProviderId, User } from \"~/models/User\";\n\nexport interface AppSessionData {\n /** Which identity provider signed this user in. */\n provider?: ProviderId;\n /** The only token persisted; delegated access tokens are minted from it. */\n refreshToken?: string;\n user?: User;\n /** Transient, only between /auth/login and /auth/callback. */\n pkceVerifier?: string;\n state?: string;\n returnTo?: string;\n}\n\nexport type AppSession = IronSession<AppSessionData>;\n\nexport const getAppSession = async (): Promise<AppSession> => {\n // Dynamic import: `@tanstack/react-start/server` is the server entry and drags\n // in the SSR renderer (`react-dom/server`). Keep it out of the client graph —\n // this helper is only ever called server-side, and all callers already await it.\n const [{ getIronSession }, { getCookie, setCookie }] = await Promise.all([\n import(\"iron-session\"),\n import(\"@tanstack/react-start/server\"),\n ]);\n\n return getIronSession<AppSessionData>(\n { read: getCookie, write: setCookie },\n {\n // Not `session`: that name holds the pre-stable `useSession` seal, which\n // iron-session can't read. Users sign in once more after the upgrade.\n cookieName: \"app-session\",\n password: serverEnv.SESSION_SECRET,\n chunk: true,\n cookieOptions: {\n secure: process.env.NODE_ENV === \"production\",\n sameSite: \"lax\",\n httpOnly: true,\n path: \"/\",\n // Explicit `undefined`: browser-session cookie and a seal that never\n // expires — what `useSession` did. Omit it to fall back to iron's 14-day `ttl`.\n maxAge: undefined,\n },\n },\n );\n};\n","import { queryOptions } from \"@tanstack/react-query\";\nimport { createServerFn } from \"@tanstack/react-start\";\nimport type { QueryClientParam } from \"~/models/QueryClientParam\";\nimport type { ProviderId, User } from \"~/models/User\";\nimport { OFFLINE_USER_KEY, withOfflineFallback } from \"./offline\";\nimport { getAppSession } from \"./session\";\n\n/**\n * Reads the signed-in user from the session cookie, or null. As a server function\n * it runs in-process when called on the server (SSR, middleware) and as an RPC\n * when called from the client — so it doubles as the client `queryFn`.\n */\nexport const getSessionUser = createServerFn({ method: \"GET\" }).handler(\n async (): Promise<User | null> => {\n const session = await getAppSession();\n return session.user ?? null;\n },\n);\n\n/** The identity providers the server offers, for the login page. */\nexport const getLoginProviders = createServerFn({ method: \"GET\" }).handler(\n async (): Promise<Array<{ id: ProviderId; label: string }>> => {\n // Dynamic import: `providers` reads `serverEnv` and must not reach the client.\n const { providers } = await import(\"./providers\");\n return providers.map(({ id, label }) => ({ id, label }));\n },\n);\n\n/**\n * Feeds `LoginForm`. Server config, not per-user, so it is safe to prime on the\n * server — the `/login` route's loader does that to avoid a flash of empty card.\n */\nexport const loginProvidersQueryOptions = queryOptions({\n queryKey: [\"auth\", \"providers\"],\n queryFn: () => getLoginProviders(),\n staleTime: \"static\",\n});\n\n/**\n * Client-side query for the signed-in user. Shared between `getUser` (route\n * `beforeLoad`) and the always-mounted observer in `LayoutProvider` — the\n * observer is what seeds the offline snapshot on the very first page load\n * (`beforeLoad` does not re-run after SSR hydration) and what makes\n * `refetchOnReconnect` fire once connectivity returns.\n */\nexport const userQueryOptions = queryOptions({\n queryKey: [\"auth\", \"user\"],\n queryFn: () => withOfflineFallback(OFFLINE_USER_KEY, () => getSessionUser()),\n staleTime: Infinity,\n // Default \"online\" pauses the query (never calling queryFn) once the browser\n // reports no connection — which is exactly when the fallback is needed.\n networkMode: \"offlineFirst\",\n // Back online: re-confirm the session and re-stamp the snapshot's grace period.\n refetchOnReconnect: \"always\",\n});\n\nexport const getUser = ({ queryClient }: QueryClientParam): Promise<User | null> => {\n if (import.meta.env.SSR) return getSessionUser();\n\n return queryClient.ensureQueryData(userQueryOptions);\n};\n","import type { AnyFieldApi } from \"@tanstack/react-form\";\nimport { redirect } from \"@tanstack/react-router\";\nimport type { ParsedLocation } from \"@tanstack/react-router\";\nimport { manifest, permissions } from \"virtual:wcz-layout\";\nimport type { QueryClientParam } from \"~/models/QueryClientParam\";\nimport type { TokenPayload } from \"~/models/TokenPayload\";\nimport type { ProviderId, User } from \"~/models/User\";\nimport { getUser } from \"./auth/user\";\n\nexport const WISTRON_PRIMARY_COLOR = \"#00506E\";\nexport const WISTRON_SECONDARY_COLOR = \"#64DC00\";\n\nexport class Platform {\n static get isAndroid() {\n return /android/i.test(this.userAgent);\n }\n static get isIOS() {\n return /iPad|iPhone|iPod/.test(this.userAgent);\n }\n static get isWindows() {\n return /windows/i.test(this.userAgent);\n }\n static get isMacOS() {\n return /Macintosh|MacIntel|MacPPC|Mac68K/.test(this.userAgent);\n }\n\n private static get userAgent() {\n return typeof navigator === \"undefined\" ? \"\" : navigator.userAgent;\n }\n}\n\ninterface RootRouteHeadOptions {\n manifest?: string;\n}\n\nexport const rootRouteHead = (options?: RootRouteHeadOptions) => ({\n meta: [\n { charSet: \"utf-8\" },\n { name: \"viewport\", content: \"width=device-width, initial-scale=1\" },\n { title: manifest.name },\n { name: \"og:type\", content: \"website\" },\n { name: \"og:title\", content: manifest.name },\n { name: \"og:image\", content: \"/favicon-32x32.png\" },\n ],\n links: [\n { rel: \"apple-touch-icon\", sizes: \"180x180\", href: \"/apple-touch-icon.png\" },\n { rel: \"icon\", type: \"image/png\", sizes: \"32x32\", href: \"/favicon-32x32.png\" },\n { rel: \"icon\", type: \"image/png\", sizes: \"16x16\", href: \"/favicon-16x16.png\" },\n { rel: \"manifest\", href: options?.manifest || \"/manifest.json\" },\n { rel: \"icon\", href: \"/favicon.ico\" },\n ],\n});\n\ntype GuardArgs = { location: ParsedLocation; context: QueryClientParam };\n\n/**\n * Route guard for `beforeLoad`. Routes are public by default; add this to close one.\n *\n * - `requireAuth()` — signed in with any provider. The only gate a population\n * without permission groups (e.g. AWS users) can pass.\n * - `requireAuth(\"admin\")` — signed in *and* in a group listed under that key.\n *\n * `reloadDocument` is required: `/auth/login` is a component-less server route and\n * must be reached with a full-document navigation. It starts the login directly when\n * only one provider is registered, otherwise it forwards to the `/login` chooser.\n */\nexport const requireAuth = (permissionKey?: keyof typeof permissions) => {\n return async ({ location, context }: GuardArgs) => {\n const user = await getUser({ queryClient: context.queryClient });\n\n if (!user)\n throw redirect({\n href: `/auth/login?returnTo=${encodeURIComponent(location.href)}`,\n reloadDocument: true,\n });\n\n if (permissionKey && !hasPermission(user, permissionKey))\n throw new Error(\"You do not have permission to access this page.\");\n\n return { user };\n };\n};\n\n/* Internal Utils */\nconst NON_PRODUCTION = /(?:^|[.-])(?:dev|qas|uat|test)(?:[.-]|$)/i;\n\n/** True only for a dev/qas/uat/test domain — localhost and production are not. */\nexport const isTestEnv = (origin: string | undefined) =>\n NON_PRODUCTION.test((origin ?? \"\").split(\".\").slice(1).join(\".\"));\n\nexport type FormOmittedProps =\n | \"name\"\n | \"value\"\n | \"onChange\"\n | \"onBlur\"\n | \"error\"\n | \"helperText\"\n | \"renderInput\"\n | \"type\"\n | \"aria-label\";\n\nexport const getFieldStatus = (field: AnyFieldApi) => {\n const { meta } = field.state;\n\n const isTouched = meta.isTouched;\n const hasError = !!meta.errors.length;\n const helperText = meta.errors[0]?.message;\n\n return { isTouched, hasError, helperText };\n};\n\n/**\n * Only same-origin paths are allowed, so `returnTo` cannot become an open\n * redirect. Backslash counts as a separator too: browsers normalize `/\\evil`\n * to the protocol-relative `//evil`.\n */\nexport const sanitizeReturnTo = (value: string | null | undefined): string =>\n value && /^\\/(?![/\\\\])/.test(value) ? value : \"/\";\n\nexport const toKebabCase = (str: string): string => {\n return str\n .replaceAll(/([a-z])([A-Z])/g, \"$1-$2\")\n .replaceAll(/[\\s_]+/g, \"-\")\n .replaceAll(/[^a-zA-Z0-9-]/g, \"\")\n .toLowerCase()\n .replaceAll(/-+/g, \"-\")\n .replaceAll(/(^-|-$)/g, \"\");\n};\n\nexport const foldForSearch = (value: unknown): string =>\n String(value ?? \"\")\n .toLowerCase()\n .normalize(\"NFD\")\n .replaceAll(/[\\u{300}-\\u{36F}]/gu, \"\")\n .normalize(\"NFC\");\n\nconst permissionGroups = new Set<string>(Object.values(permissions).flat());\n\n/**\n * Maps id/access-token claims to the serializable `User`. Groups are trimmed to\n * those named in `permissions.ts` — an unfiltered group list would blow the\n * cookie. Cognito's claim names differ, so both are read.\n */\nexport const buildUser = (payload: TokenPayload, provider: ProviderId): User => ({\n provider,\n name: (payload.name ?? payload[\"cognito:username\"] ?? \"\").split(\"/\")[0],\n email: (payload.preferred_username ?? payload.email ?? \"\").toLowerCase(),\n department: payload.department?.toUpperCase() || \"\",\n employeeId: (payload.employeeId ?? payload[\"cognito:username\"] ?? \"\").toUpperCase(),\n companyName: payload.companyName || \"\",\n groups:\n (payload.groups ?? payload[\"cognito:groups\"])?.filter((group) => permissionGroups.has(group)) ??\n [],\n});\n\nexport const hasPermission = (user: User | null, key: keyof typeof permissions): boolean =>\n user ? permissions[key].some((group) => user.groups.includes(group)) : false;\n"],"mappings":";;;;;;;;;;;;;AAQA,MAAa,mBAAmB;AAChC,MAAa,oBAAoB;;AAGjC,MAAM,eAAe;AAIrB,MAAM,UAAa,QAA0B;CAC3C,IAAI,OAAO,iBAAiB,aAAa,OAAO;CAChD,IAAI;EACF,MAAM,MAAM,aAAa,QAAQ,GAAG;EACpC,IAAI,CAAC,KAAK,OAAO;EACjB,MAAM,EAAE,OAAO,YAAY,KAAK,MAAM,GAAG;EACzC,IAAI,KAAK,IAAI,IAAI,UAAU,cAAc;GACvC,aAAa,WAAW,GAAG;GAC3B,OAAO;EACT;EACA,OAAO;CACT,QAAQ;EACN,aAAa,WAAW,GAAG;EAC3B,OAAO;CACT;AACF;AAEA,MAAM,YAAY,KAAa,UAAyB;CACtD,IAAI,OAAO,iBAAiB,aAAa;CACzC,IAAI;EACF,IAAI,UAAU,QAAQ,UAAU,KAAA,GAAW,aAAa,WAAW,GAAG;OACjE,aAAa,QAAQ,KAAK,KAAK,UAAU;GAAE;GAAO,SAAS,KAAK,IAAI;EAAE,CAAC,CAAC;CAC/E,QAAQ,CAER;AACF;AAEA,MAAM,oBAAoB,UACvB,OAAO,cAAc,eAAe,CAAC,UAAU,UAAW,iBAAiB;;;;;;;;;AAU9E,MAAa,sBAAsB,OACjC,KACA,eACsB;CACtB,IAAI;EACF,MAAM,QAAQ,MAAM,WAAW;EAC/B,SAAS,KAAK,KAAK;EACnB,OAAO;CACT,SAAS,OAAO;EACd,IAAI,CAAC,iBAAiB,KAAK,GAAG,MAAM;EACpC,OAAO,OAAU,GAAG;CACtB;AACF;;AAGA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iB,MAAmB,QAC/C,OAAO,YAAY,IAAI,CAAC,MAAM,UAAU,KAAK,OAAO,SAAS,KAAK,CAAC,IAAI"}
|
package/dist/utils-DnMFybj3.mjs
DELETED
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
import i18next, { t } from "i18next";
|
|
2
|
-
import { createEnv as createEnv$1 } from "@t3-oss/env-core";
|
|
3
|
-
import { uuidv7 as uuidv7$1 } from "uuidv7";
|
|
4
|
-
// src/lib/ai/index.ts
|
|
5
|
-
/**
|
|
6
|
-
* Text adapter for the Wistron AI gateway; create it per request in a server function
|
|
7
|
-
* (`getAppToken` caches the token). Chat Completions, not Responses: the gateway load-balances
|
|
8
|
-
* Azure deployments, and Responses replays encrypted reasoning that other deployments cannot read
|
|
9
|
-
* (400 invalid_encrypted_content).
|
|
10
|
-
*/
|
|
11
|
-
const chatAdapter = async (model) => {
|
|
12
|
-
const [{ createOpenaiChatCompletions }, { getAppToken }, { serverEnv }] = await Promise.all([
|
|
13
|
-
import("@tanstack/ai-openai"),
|
|
14
|
-
import("./tokens-C4SErO-K.mjs").then((n) => n.r),
|
|
15
|
-
import("./env-BwFl7nWc.mjs").then((n) => n.t)
|
|
16
|
-
]);
|
|
17
|
-
const { AI_BASE_URL, AI_SUBSCRIPTION_KEY } = serverEnv;
|
|
18
|
-
if (!AI_BASE_URL || !AI_SUBSCRIPTION_KEY) throw new Error("chatAdapter needs AI_BASE_URL and AI_SUBSCRIPTION_KEY in the environment.");
|
|
19
|
-
return createOpenaiChatCompletions(model, await getAppToken("cognitiveServices"), {
|
|
20
|
-
baseURL: AI_BASE_URL,
|
|
21
|
-
defaultHeaders: { "Ocp-Apim-Subscription-Key": AI_SUBSCRIPTION_KEY },
|
|
22
|
-
strictFallbackWarning: false
|
|
23
|
-
});
|
|
24
|
-
};
|
|
25
|
-
export { chatAdapter as a, uuidv7$1 as i, i18next as n, t as r, createEnv$1 as t };
|
|
26
|
-
|
|
27
|
-
//# sourceMappingURL=utils-DnMFybj3.mjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"utils-DnMFybj3.mjs","names":[],"sources":["../src/lib/ai/index.ts"],"sourcesContent":["import type { OpenAIChatCompletionsTextAdapter, OpenAIChatModel } from \"@tanstack/ai-openai\";\n\n/**\n * Text adapter for the Wistron AI gateway; create it per request in a server function\n * (`getAppToken` caches the token). Chat Completions, not Responses: the gateway load-balances\n * Azure deployments, and Responses replays encrypted reasoning that other deployments cannot read\n * (400 invalid_encrypted_content).\n */\nexport const chatAdapter = async <TModel extends OpenAIChatModel>(\n model: TModel,\n): Promise<OpenAIChatCompletionsTextAdapter<TModel>> => {\n // Imported on call: `wcz-layout/utils` also loads in the browser, which must not pull in the\n // OpenAI SDK or the server-only token code.\n const [{ createOpenaiChatCompletions }, { getAppToken }, { serverEnv }] = await Promise.all([\n import(\"@tanstack/ai-openai\"),\n import(\"~/lib/auth/tokens\"),\n import(\"~/env\"),\n ]);\n const { AI_BASE_URL, AI_SUBSCRIPTION_KEY } = serverEnv;\n // Optional in the library's env, since only apps with AI features set them.\n if (!AI_BASE_URL || !AI_SUBSCRIPTION_KEY)\n throw new Error(\"chatAdapter needs AI_BASE_URL and AI_SUBSCRIPTION_KEY in the environment.\");\n\n return createOpenaiChatCompletions(model, await getAppToken(\"cognitiveServices\"), {\n baseURL: AI_BASE_URL,\n defaultHeaders: { \"Ocp-Apim-Subscription-Key\": AI_SUBSCRIPTION_KEY },\n // show_ui and ask_user take any MUI props, so they can never be strict; chat() hands the\n // adapter fresh tool objects on every model call, so the warning would repeat on each one.\n strictFallbackWarning: false,\n });\n};\n"],"mappings":";;;;;;;;;;AAQA,MAAa,cAAc,OACzB,UACsD;CAGtD,MAAM,CAAC,EAAE,+BAA+B,EAAE,eAAe,EAAE,eAAe,MAAM,QAAQ,IAAI;EAC1F,OAAO;EACP,OAAO,wBAAA,CAAA,MAAA,MAAA,EAAA,CAAA;EACP,OAAO,qBAAA,CAAA,MAAA,MAAA,EAAA,CAAA;CACT,CAAC;CACD,MAAM,EAAE,aAAa,wBAAwB;CAE7C,IAAI,CAAC,eAAe,CAAC,qBACnB,MAAM,IAAI,MAAM,2EAA2E;CAE7F,OAAO,4BAA4B,OAAO,MAAM,YAAY,mBAAmB,GAAG;EAChF,SAAS;EACT,gBAAgB,EAAE,6BAA6B,oBAAoB;EAGnE,uBAAuB;CACzB,CAAC;AACH"}
|