@thegeem/protocol 0.1.14 → 0.1.15

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/index.cjs CHANGED
@@ -134,7 +134,11 @@ var ClientMsg = import_zod.z.discriminatedUnion("t", [
134
134
  // moderation
135
135
  // Report another player in the room (App Store 1.2 UGC — display names). Available in lobby or
136
136
  // game. The server records reporter/reported/room context; `reason` is an optional free-text note.
137
- import_zod.z.object({ t: import_zod.z.literal("report"), playerId: PlayerId, reason: import_zod.z.string().max(500).optional() })
137
+ import_zod.z.object({ t: import_zod.z.literal("report"), playerId: PlayerId, reason: import_zod.z.string().max(500).optional() }),
138
+ // Report the CURRENT question as bad (wrong answer / typo / offensive). The relay resolves WHICH
139
+ // question from its authoritative room state — the client never sees the question id (anti-cheat),
140
+ // so it only sends an optional `reason`. Only meaningful while a question is on screen.
141
+ import_zod.z.object({ t: import_zod.z.literal("reportQuestion"), reason: import_zod.z.string().max(500).optional() })
138
142
  ]);
139
143
  // Annotate the CommonJS export names for ESM import in node:
140
144
  0 && (module.exports = {
package/dist/index.d.cts CHANGED
@@ -387,6 +387,15 @@ declare const ClientMsg: z.ZodDiscriminatedUnion<"t", [z.ZodObject<{
387
387
  t: "report";
388
388
  playerId: string;
389
389
  reason?: string | undefined;
390
+ }>, z.ZodObject<{
391
+ t: z.ZodLiteral<"reportQuestion">;
392
+ reason: z.ZodOptional<z.ZodString>;
393
+ }, "strip", z.ZodTypeAny, {
394
+ t: "reportQuestion";
395
+ reason?: string | undefined;
396
+ }, {
397
+ t: "reportQuestion";
398
+ reason?: string | undefined;
390
399
  }>]>;
391
400
  type ClientMsg = z.infer<typeof ClientMsg>;
392
401
  /** A player's privacy-safe avatar (emoji + circle color) for in-room display. */
package/dist/index.d.ts CHANGED
@@ -387,6 +387,15 @@ declare const ClientMsg: z.ZodDiscriminatedUnion<"t", [z.ZodObject<{
387
387
  t: "report";
388
388
  playerId: string;
389
389
  reason?: string | undefined;
390
+ }>, z.ZodObject<{
391
+ t: z.ZodLiteral<"reportQuestion">;
392
+ reason: z.ZodOptional<z.ZodString>;
393
+ }, "strip", z.ZodTypeAny, {
394
+ t: "reportQuestion";
395
+ reason?: string | undefined;
396
+ }, {
397
+ t: "reportQuestion";
398
+ reason?: string | undefined;
390
399
  }>]>;
391
400
  type ClientMsg = z.infer<typeof ClientMsg>;
392
401
  /** A player's privacy-safe avatar (emoji + circle color) for in-room display. */
package/dist/index.js CHANGED
@@ -103,7 +103,11 @@ var ClientMsg = z.discriminatedUnion("t", [
103
103
  // moderation
104
104
  // Report another player in the room (App Store 1.2 UGC — display names). Available in lobby or
105
105
  // game. The server records reporter/reported/room context; `reason` is an optional free-text note.
106
- z.object({ t: z.literal("report"), playerId: PlayerId, reason: z.string().max(500).optional() })
106
+ z.object({ t: z.literal("report"), playerId: PlayerId, reason: z.string().max(500).optional() }),
107
+ // Report the CURRENT question as bad (wrong answer / typo / offensive). The relay resolves WHICH
108
+ // question from its authoritative room state — the client never sees the question id (anti-cheat),
109
+ // so it only sends an optional `reason`. Only meaningful while a question is on screen.
110
+ z.object({ t: z.literal("reportQuestion"), reason: z.string().max(500).optional() })
107
111
  ]);
108
112
  export {
109
113
  ClientMsg,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@thegeem/protocol",
3
- "version": "0.1.14",
3
+ "version": "0.1.15",
4
4
  "description": "Geem's wire protocol — shared zod schemas + TypeScript types for talking to the Geem game server over Socket.IO. The source of truth all clients implement against.",
5
5
  "license": "UNLICENSED",
6
6
  "homepage": "https://geem.tv",