@domino-sdk/relay 0.6.0 → 0.7.0
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/authoring.d.ts +7 -2
- package/dist/authoring.js +2 -2
- package/dist/browser.d.ts +67 -42
- package/dist/browser.js +4 -4
- package/dist/{chunk-PLO5PPLU.js → chunk-36LZ3IOO.js} +1 -1
- package/dist/{chunk-MXK7KEDA.js → chunk-6QUCADMF.js} +13 -1
- package/dist/{chunk-CCLIDCUU.js → chunk-LXLNC4CN.js} +178 -169
- package/dist/{chunk-UIC6OF3C.js → chunk-TYVT5BPZ.js} +1 -1
- package/dist/index.d.ts +192 -94
- package/dist/index.js +6 -4
- package/dist/portal-proxy.js +2 -2
- package/dist/schema.d.ts +30 -0
- package/dist/schema.js +1 -1
- package/dist/{settings-BrC6C9yl.d.ts → settings-CU_oBcx0.d.ts} +13 -0
- package/package.json +1 -1
package/dist/authoring.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { O as Observation, D as DiscordMember, a as DiscordMessage, W as WalletConnection, S as SolanaBalance, o as observationTriggerSchema, B as Budget, I as IntegrationProvider } from './settings-
|
|
2
|
-
export { d as defineLeaderboard, b as defineReferral, c as discord, s as settings } from './settings-
|
|
1
|
+
import { O as Observation, D as DiscordMember, a as DiscordMessage, W as WalletConnection, S as SolanaBalance, o as observationTriggerSchema, B as Budget, I as IntegrationProvider } from './settings-CU_oBcx0.js';
|
|
2
|
+
export { d as defineLeaderboard, b as defineReferral, c as discord, s as settings } from './settings-CU_oBcx0.js';
|
|
3
3
|
import { z } from 'zod';
|
|
4
4
|
import { PhotoResult, rewardSchema, triggerSchema, QuestPresentation, QuizEvidence, Decision, TieredRewardDefinition } from './schema.js';
|
|
5
5
|
|
|
@@ -229,6 +229,11 @@ declare function defineQuest<T extends Record<string, z.ZodType>, const G extend
|
|
|
229
229
|
};
|
|
230
230
|
integrations: "discord"[];
|
|
231
231
|
fields: Record<string, {
|
|
232
|
+
kind: "point-ledger";
|
|
233
|
+
default: string;
|
|
234
|
+
label: string;
|
|
235
|
+
description?: string | undefined;
|
|
236
|
+
} | {
|
|
232
237
|
kind: "datetime";
|
|
233
238
|
default: string;
|
|
234
239
|
label: string;
|
package/dist/authoring.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
defineLeaderboard,
|
|
3
3
|
defineReferral
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-TYVT5BPZ.js";
|
|
5
5
|
import {
|
|
6
6
|
budgetSchema,
|
|
7
7
|
decisionSchema,
|
|
@@ -16,7 +16,7 @@ import {
|
|
|
16
16
|
settings,
|
|
17
17
|
tierRewardSchema,
|
|
18
18
|
tieredRewardDefinitionSchema
|
|
19
|
-
} from "./chunk-
|
|
19
|
+
} from "./chunk-6QUCADMF.js";
|
|
20
20
|
|
|
21
21
|
// src/authoring.ts
|
|
22
22
|
import { z } from "zod";
|
package/dist/browser.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { SubmitInput, ReviewListOptions, MemberListOptions, ReleaseInput, beginHandoverSchema } from './schema.js';
|
|
2
2
|
import { SubmissionStore, createRelayClient, QuestView, QuestController, ProgressObservation, questExperienceSchema, ProgressObserver, ExchangeInput, PhotoSubmission, QuizSubmission, ClaimSubmission } from './index.js';
|
|
3
|
-
import { r as referralAcceptSchema, L as LeaderboardQuery, w as walletChallengeInputSchema, e as walletProofSchema, A as AuthProvider } from './settings-
|
|
3
|
+
import { r as referralAcceptSchema, L as LeaderboardQuery, w as walletChallengeInputSchema, e as walletProofSchema, A as AuthProvider } from './settings-CU_oBcx0.js';
|
|
4
4
|
import * as zod from 'zod';
|
|
5
5
|
|
|
6
6
|
/** Browser client with durable submission recovery; safe to construct during SSR. */
|
|
@@ -336,7 +336,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
336
336
|
} | undefined;
|
|
337
337
|
} | undefined;
|
|
338
338
|
};
|
|
339
|
-
connections: ("
|
|
339
|
+
connections: ("discord" | "google" | "apple" | "x")[];
|
|
340
340
|
trigger: {
|
|
341
341
|
kind: "manual";
|
|
342
342
|
input: "quiz" | "photo" | "none";
|
|
@@ -395,7 +395,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
395
395
|
quest: string;
|
|
396
396
|
member: string;
|
|
397
397
|
evidence: string | null;
|
|
398
|
-
status: "
|
|
398
|
+
status: "queued" | "evaluating" | "accepted" | "rejected" | "needs-review" | "failed";
|
|
399
399
|
reason: string | null;
|
|
400
400
|
retries: number;
|
|
401
401
|
generation: number;
|
|
@@ -437,7 +437,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
437
437
|
} | undefined;
|
|
438
438
|
} | null;
|
|
439
439
|
release: string;
|
|
440
|
-
interaction: "
|
|
440
|
+
interaction: "staff" | "quiz" | "photo" | "automatic" | "claim";
|
|
441
441
|
lifecycle: "active" | "paused" | "archived";
|
|
442
442
|
rewards: {
|
|
443
443
|
label: string;
|
|
@@ -449,7 +449,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
449
449
|
quest: string;
|
|
450
450
|
member: string;
|
|
451
451
|
evidence: string | null;
|
|
452
|
-
status: "
|
|
452
|
+
status: "queued" | "evaluating" | "accepted" | "rejected" | "needs-review" | "failed";
|
|
453
453
|
reason: string | null;
|
|
454
454
|
retries: number;
|
|
455
455
|
generation: number;
|
|
@@ -515,7 +515,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
515
515
|
} | undefined;
|
|
516
516
|
} | undefined;
|
|
517
517
|
};
|
|
518
|
-
connections: ("
|
|
518
|
+
connections: ("discord" | "google" | "apple" | "x")[];
|
|
519
519
|
trigger: {
|
|
520
520
|
kind: "manual";
|
|
521
521
|
input: "quiz" | "photo" | "none";
|
|
@@ -574,7 +574,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
574
574
|
quest: string;
|
|
575
575
|
member: string;
|
|
576
576
|
evidence: string | null;
|
|
577
|
-
status: "
|
|
577
|
+
status: "queued" | "evaluating" | "accepted" | "rejected" | "needs-review" | "failed";
|
|
578
578
|
reason: string | null;
|
|
579
579
|
retries: number;
|
|
580
580
|
generation: number;
|
|
@@ -616,7 +616,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
616
616
|
} | undefined;
|
|
617
617
|
} | null;
|
|
618
618
|
release: string;
|
|
619
|
-
interaction: "
|
|
619
|
+
interaction: "staff" | "quiz" | "photo" | "automatic" | "claim";
|
|
620
620
|
lifecycle: "active" | "paused" | "archived";
|
|
621
621
|
rewards: {
|
|
622
622
|
label: string;
|
|
@@ -648,7 +648,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
648
648
|
} | undefined;
|
|
649
649
|
} | undefined;
|
|
650
650
|
};
|
|
651
|
-
connections: ("
|
|
651
|
+
connections: ("discord" | "google" | "apple" | "x")[];
|
|
652
652
|
trigger: {
|
|
653
653
|
kind: "manual";
|
|
654
654
|
input: "quiz" | "photo" | "none";
|
|
@@ -707,7 +707,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
707
707
|
quest: string;
|
|
708
708
|
member: string;
|
|
709
709
|
evidence: string | null;
|
|
710
|
-
status: "
|
|
710
|
+
status: "queued" | "evaluating" | "accepted" | "rejected" | "needs-review" | "failed";
|
|
711
711
|
reason: string | null;
|
|
712
712
|
retries: number;
|
|
713
713
|
generation: number;
|
|
@@ -749,7 +749,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
749
749
|
} | undefined;
|
|
750
750
|
} | null;
|
|
751
751
|
release: string;
|
|
752
|
-
interaction: "
|
|
752
|
+
interaction: "staff" | "quiz" | "photo" | "automatic" | "claim";
|
|
753
753
|
lifecycle: "active" | "paused" | "archived";
|
|
754
754
|
rewards: {
|
|
755
755
|
label: string;
|
|
@@ -783,7 +783,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
783
783
|
} | undefined;
|
|
784
784
|
} | undefined;
|
|
785
785
|
};
|
|
786
|
-
connections: ("
|
|
786
|
+
connections: ("discord" | "google" | "apple" | "x")[];
|
|
787
787
|
trigger: {
|
|
788
788
|
kind: "manual";
|
|
789
789
|
input: "quiz" | "photo" | "none";
|
|
@@ -842,7 +842,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
842
842
|
quest: string;
|
|
843
843
|
member: string;
|
|
844
844
|
evidence: string | null;
|
|
845
|
-
status: "
|
|
845
|
+
status: "queued" | "evaluating" | "accepted" | "rejected" | "needs-review" | "failed";
|
|
846
846
|
reason: string | null;
|
|
847
847
|
retries: number;
|
|
848
848
|
generation: number;
|
|
@@ -884,7 +884,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
884
884
|
} | undefined;
|
|
885
885
|
} | null;
|
|
886
886
|
release: string;
|
|
887
|
-
interaction: "
|
|
887
|
+
interaction: "staff" | "quiz" | "photo" | "automatic" | "claim";
|
|
888
888
|
lifecycle: "active" | "paused" | "archived";
|
|
889
889
|
rewards: {
|
|
890
890
|
label: string;
|
|
@@ -921,7 +921,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
921
921
|
auth: {
|
|
922
922
|
providers: () => Promise<{
|
|
923
923
|
providers: {
|
|
924
|
-
provider: "
|
|
924
|
+
provider: "discord" | "google" | "apple" | "x";
|
|
925
925
|
configured: boolean;
|
|
926
926
|
}[];
|
|
927
927
|
email: boolean;
|
|
@@ -951,7 +951,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
951
951
|
expiresAt: number;
|
|
952
952
|
}>;
|
|
953
953
|
accounts: () => Promise<{
|
|
954
|
-
provider: "
|
|
954
|
+
provider: "discord" | "google" | "apple" | "x";
|
|
955
955
|
configured: boolean;
|
|
956
956
|
status: "disconnected" | "connected" | "reconnect";
|
|
957
957
|
subject: string | null;
|
|
@@ -1042,7 +1042,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
1042
1042
|
quest: string;
|
|
1043
1043
|
member: string;
|
|
1044
1044
|
evidence: string | null;
|
|
1045
|
-
status: "
|
|
1045
|
+
status: "queued" | "evaluating" | "accepted" | "rejected" | "needs-review" | "failed";
|
|
1046
1046
|
reason: string | null;
|
|
1047
1047
|
retries: number;
|
|
1048
1048
|
generation: number;
|
|
@@ -1108,7 +1108,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
1108
1108
|
} | undefined;
|
|
1109
1109
|
} | undefined;
|
|
1110
1110
|
};
|
|
1111
|
-
connections: ("
|
|
1111
|
+
connections: ("discord" | "google" | "apple" | "x")[];
|
|
1112
1112
|
trigger: {
|
|
1113
1113
|
kind: "manual";
|
|
1114
1114
|
input: "quiz" | "photo" | "none";
|
|
@@ -1167,7 +1167,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
1167
1167
|
quest: string;
|
|
1168
1168
|
member: string;
|
|
1169
1169
|
evidence: string | null;
|
|
1170
|
-
status: "
|
|
1170
|
+
status: "queued" | "evaluating" | "accepted" | "rejected" | "needs-review" | "failed";
|
|
1171
1171
|
reason: string | null;
|
|
1172
1172
|
retries: number;
|
|
1173
1173
|
generation: number;
|
|
@@ -1313,7 +1313,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
1313
1313
|
quest: string;
|
|
1314
1314
|
member: string;
|
|
1315
1315
|
evidence: string | null;
|
|
1316
|
-
status: "
|
|
1316
|
+
status: "queued" | "evaluating" | "accepted" | "rejected" | "needs-review" | "failed";
|
|
1317
1317
|
reason: string | null;
|
|
1318
1318
|
retries: number;
|
|
1319
1319
|
generation: number;
|
|
@@ -1372,7 +1372,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
1372
1372
|
quest: string;
|
|
1373
1373
|
member: string;
|
|
1374
1374
|
evidence: string | null;
|
|
1375
|
-
status: "
|
|
1375
|
+
status: "queued" | "evaluating" | "accepted" | "rejected" | "needs-review" | "failed";
|
|
1376
1376
|
reason: string | null;
|
|
1377
1377
|
retries: number;
|
|
1378
1378
|
generation: number;
|
|
@@ -1447,7 +1447,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
1447
1447
|
code: string;
|
|
1448
1448
|
definition: {
|
|
1449
1449
|
quest: string;
|
|
1450
|
-
runtimeVersion:
|
|
1450
|
+
runtimeVersion: 2 | 1;
|
|
1451
1451
|
title: string;
|
|
1452
1452
|
presentation: {
|
|
1453
1453
|
quiz?: {
|
|
@@ -1471,6 +1471,11 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
1471
1471
|
};
|
|
1472
1472
|
integrations: "discord"[];
|
|
1473
1473
|
fields: Record<string, {
|
|
1474
|
+
kind: "point-ledger";
|
|
1475
|
+
default: string;
|
|
1476
|
+
label: string;
|
|
1477
|
+
description?: string | undefined;
|
|
1478
|
+
} | {
|
|
1474
1479
|
kind: "datetime";
|
|
1475
1480
|
default: string;
|
|
1476
1481
|
label: string;
|
|
@@ -1589,8 +1594,8 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
1589
1594
|
visibility: "visible" | "hidden";
|
|
1590
1595
|
budgets: {
|
|
1591
1596
|
id: string;
|
|
1592
|
-
scope: "
|
|
1593
|
-
period: "
|
|
1597
|
+
scope: "project" | "member";
|
|
1598
|
+
period: "day" | "lifetime";
|
|
1594
1599
|
limit: number;
|
|
1595
1600
|
cost: number | {
|
|
1596
1601
|
balance: string;
|
|
@@ -1602,7 +1607,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
1602
1607
|
code: string;
|
|
1603
1608
|
definition: {
|
|
1604
1609
|
quest: string;
|
|
1605
|
-
runtimeVersion:
|
|
1610
|
+
runtimeVersion: 2 | 1;
|
|
1606
1611
|
title: string;
|
|
1607
1612
|
presentation: {
|
|
1608
1613
|
quiz?: {
|
|
@@ -1626,6 +1631,11 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
1626
1631
|
};
|
|
1627
1632
|
integrations: "discord"[];
|
|
1628
1633
|
fields: Record<string, {
|
|
1634
|
+
kind: "point-ledger";
|
|
1635
|
+
default: string;
|
|
1636
|
+
label: string;
|
|
1637
|
+
description?: string | undefined;
|
|
1638
|
+
} | {
|
|
1629
1639
|
kind: "datetime";
|
|
1630
1640
|
default: string;
|
|
1631
1641
|
label: string;
|
|
@@ -1744,8 +1754,8 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
1744
1754
|
visibility: "visible" | "hidden";
|
|
1745
1755
|
budgets: {
|
|
1746
1756
|
id: string;
|
|
1747
|
-
scope: "
|
|
1748
|
-
period: "
|
|
1757
|
+
scope: "project" | "member";
|
|
1758
|
+
period: "day" | "lifetime";
|
|
1749
1759
|
limit: number;
|
|
1750
1760
|
cost: number | {
|
|
1751
1761
|
balance: string;
|
|
@@ -1756,7 +1766,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
1756
1766
|
snapshot: () => Promise<{
|
|
1757
1767
|
releases: {
|
|
1758
1768
|
quest: string;
|
|
1759
|
-
runtimeVersion:
|
|
1769
|
+
runtimeVersion: 2 | 1;
|
|
1760
1770
|
title: string;
|
|
1761
1771
|
presentation: {
|
|
1762
1772
|
quiz?: {
|
|
@@ -1780,6 +1790,11 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
1780
1790
|
};
|
|
1781
1791
|
integrations: "discord"[];
|
|
1782
1792
|
fields: Record<string, {
|
|
1793
|
+
kind: "point-ledger";
|
|
1794
|
+
default: string;
|
|
1795
|
+
label: string;
|
|
1796
|
+
description?: string | undefined;
|
|
1797
|
+
} | {
|
|
1783
1798
|
kind: "datetime";
|
|
1784
1799
|
default: string;
|
|
1785
1800
|
label: string;
|
|
@@ -1898,8 +1913,8 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
1898
1913
|
visibility: "visible" | "hidden";
|
|
1899
1914
|
budgets: {
|
|
1900
1915
|
id: string;
|
|
1901
|
-
scope: "
|
|
1902
|
-
period: "
|
|
1916
|
+
scope: "project" | "member";
|
|
1917
|
+
period: "day" | "lifetime";
|
|
1903
1918
|
limit: number;
|
|
1904
1919
|
cost: number | {
|
|
1905
1920
|
balance: string;
|
|
@@ -2025,7 +2040,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
2025
2040
|
quest: string;
|
|
2026
2041
|
member: string;
|
|
2027
2042
|
evidence: string | null;
|
|
2028
|
-
status: "
|
|
2043
|
+
status: "queued" | "evaluating" | "accepted" | "rejected" | "needs-review" | "failed";
|
|
2029
2044
|
reason: string | null;
|
|
2030
2045
|
retries: number;
|
|
2031
2046
|
generation: number;
|
|
@@ -2084,7 +2099,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
2084
2099
|
}>;
|
|
2085
2100
|
publish: (release: ReleaseInput) => Promise<{
|
|
2086
2101
|
quest: string;
|
|
2087
|
-
runtimeVersion:
|
|
2102
|
+
runtimeVersion: 2 | 1;
|
|
2088
2103
|
title: string;
|
|
2089
2104
|
presentation: {
|
|
2090
2105
|
quiz?: {
|
|
@@ -2108,6 +2123,11 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
2108
2123
|
};
|
|
2109
2124
|
integrations: "discord"[];
|
|
2110
2125
|
fields: Record<string, {
|
|
2126
|
+
kind: "point-ledger";
|
|
2127
|
+
default: string;
|
|
2128
|
+
label: string;
|
|
2129
|
+
description?: string | undefined;
|
|
2130
|
+
} | {
|
|
2111
2131
|
kind: "datetime";
|
|
2112
2132
|
default: string;
|
|
2113
2133
|
label: string;
|
|
@@ -2226,8 +2246,8 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
2226
2246
|
visibility: "visible" | "hidden";
|
|
2227
2247
|
budgets: {
|
|
2228
2248
|
id: string;
|
|
2229
|
-
scope: "
|
|
2230
|
-
period: "
|
|
2249
|
+
scope: "project" | "member";
|
|
2250
|
+
period: "day" | "lifetime";
|
|
2231
2251
|
limit: number;
|
|
2232
2252
|
cost: number | {
|
|
2233
2253
|
balance: string;
|
|
@@ -2266,7 +2286,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
2266
2286
|
}>;
|
|
2267
2287
|
publishBatch: (releases: ReleaseInput[]) => Promise<{
|
|
2268
2288
|
quest: string;
|
|
2269
|
-
runtimeVersion:
|
|
2289
|
+
runtimeVersion: 2 | 1;
|
|
2270
2290
|
title: string;
|
|
2271
2291
|
presentation: {
|
|
2272
2292
|
quiz?: {
|
|
@@ -2290,6 +2310,11 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
2290
2310
|
};
|
|
2291
2311
|
integrations: "discord"[];
|
|
2292
2312
|
fields: Record<string, {
|
|
2313
|
+
kind: "point-ledger";
|
|
2314
|
+
default: string;
|
|
2315
|
+
label: string;
|
|
2316
|
+
description?: string | undefined;
|
|
2317
|
+
} | {
|
|
2293
2318
|
kind: "datetime";
|
|
2294
2319
|
default: string;
|
|
2295
2320
|
label: string;
|
|
@@ -2408,8 +2433,8 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
2408
2433
|
visibility: "visible" | "hidden";
|
|
2409
2434
|
budgets: {
|
|
2410
2435
|
id: string;
|
|
2411
|
-
scope: "
|
|
2412
|
-
period: "
|
|
2436
|
+
scope: "project" | "member";
|
|
2437
|
+
period: "day" | "lifetime";
|
|
2413
2438
|
limit: number;
|
|
2414
2439
|
cost: number | {
|
|
2415
2440
|
balance: string;
|
|
@@ -2471,7 +2496,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
2471
2496
|
} | undefined;
|
|
2472
2497
|
} | undefined;
|
|
2473
2498
|
};
|
|
2474
|
-
connections: ("
|
|
2499
|
+
connections: ("discord" | "google" | "apple" | "x")[];
|
|
2475
2500
|
trigger: {
|
|
2476
2501
|
kind: "manual";
|
|
2477
2502
|
input: "quiz" | "photo" | "none";
|
|
@@ -2530,7 +2555,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
2530
2555
|
quest: string;
|
|
2531
2556
|
member: string;
|
|
2532
2557
|
evidence: string | null;
|
|
2533
|
-
status: "
|
|
2558
|
+
status: "queued" | "evaluating" | "accepted" | "rejected" | "needs-review" | "failed";
|
|
2534
2559
|
reason: string | null;
|
|
2535
2560
|
retries: number;
|
|
2536
2561
|
generation: number;
|
|
@@ -2820,7 +2845,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
2820
2845
|
quest: string;
|
|
2821
2846
|
member: string;
|
|
2822
2847
|
evidence: string | null;
|
|
2823
|
-
status: "
|
|
2848
|
+
status: "queued" | "evaluating" | "accepted" | "rejected" | "needs-review" | "failed";
|
|
2824
2849
|
reason: string | null;
|
|
2825
2850
|
retries: number;
|
|
2826
2851
|
generation: number;
|
|
@@ -2867,7 +2892,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
2867
2892
|
quest: string;
|
|
2868
2893
|
member: string;
|
|
2869
2894
|
evidence: string | null;
|
|
2870
|
-
status: "
|
|
2895
|
+
status: "queued" | "evaluating" | "accepted" | "rejected" | "needs-review" | "failed";
|
|
2871
2896
|
reason: string | null;
|
|
2872
2897
|
retries: number;
|
|
2873
2898
|
generation: number;
|
|
@@ -2919,7 +2944,7 @@ declare function createBrowserRelayClient(options: Parameters<typeof createRelay
|
|
|
2919
2944
|
quest: string;
|
|
2920
2945
|
member: string;
|
|
2921
2946
|
evidence: string | null;
|
|
2922
|
-
status: "
|
|
2947
|
+
status: "queued" | "evaluating" | "accepted" | "rejected" | "needs-review" | "failed";
|
|
2923
2948
|
reason: string | null;
|
|
2924
2949
|
retries: number;
|
|
2925
2950
|
generation: number;
|
package/dist/browser.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import {
|
|
2
2
|
createRelayClient
|
|
3
|
-
} from "./chunk-
|
|
4
|
-
import "./chunk-
|
|
5
|
-
import "./chunk-
|
|
6
|
-
import "./chunk-
|
|
3
|
+
} from "./chunk-LXLNC4CN.js";
|
|
4
|
+
import "./chunk-TYVT5BPZ.js";
|
|
5
|
+
import "./chunk-36LZ3IOO.js";
|
|
6
|
+
import "./chunk-6QUCADMF.js";
|
|
7
7
|
|
|
8
8
|
// src/browser.ts
|
|
9
9
|
function createBrowserRelayClient(options) {
|
|
@@ -193,6 +193,7 @@ var instant = z7.iso.datetime({ offset: true }).transform((value) => new Date(va
|
|
|
193
193
|
var resourceId = z7.union([z7.literal(""), z7.string().regex(/^\S{1,200}$/)]);
|
|
194
194
|
var base = { label: z7.string().min(1), description: z7.string().optional() };
|
|
195
195
|
var settingFieldSchema = z7.discriminatedUnion("kind", [
|
|
196
|
+
z7.object({ ...base, kind: z7.literal("point-ledger"), default: identifier }).strict(),
|
|
196
197
|
z7.object({ ...base, kind: z7.literal("datetime"), default: instant }).strict(),
|
|
197
198
|
z7.object({
|
|
198
199
|
...base,
|
|
@@ -233,6 +234,14 @@ var settingsValuesSchema = z7.record(
|
|
|
233
234
|
z7.union([z7.string(), z7.number().finite(), z7.boolean(), quizContentSchema])
|
|
234
235
|
);
|
|
235
236
|
var settings = {
|
|
237
|
+
pointLedger(options) {
|
|
238
|
+
const field = {
|
|
239
|
+
...options,
|
|
240
|
+
kind: "point-ledger",
|
|
241
|
+
default: identifier.parse(options.default)
|
|
242
|
+
};
|
|
243
|
+
return identifier.default(field.default).meta(field);
|
|
244
|
+
},
|
|
236
245
|
datetime(options) {
|
|
237
246
|
const field = {
|
|
238
247
|
...options,
|
|
@@ -281,6 +290,9 @@ function parseSettings(fields, input) {
|
|
|
281
290
|
const shape = {};
|
|
282
291
|
for (const [key, field] of Object.entries(fields)) {
|
|
283
292
|
switch (field.kind) {
|
|
293
|
+
case "point-ledger":
|
|
294
|
+
shape[key] = identifier.default(field.default);
|
|
295
|
+
break;
|
|
284
296
|
case "datetime":
|
|
285
297
|
shape[key] = instant.default(field.default);
|
|
286
298
|
break;
|
|
@@ -310,7 +322,7 @@ function missingResourceSettings(fields, values) {
|
|
|
310
322
|
return Object.entries(fields).filter(([key, field]) => field.kind === "resource" && !values[key]).map(([key]) => key);
|
|
311
323
|
}
|
|
312
324
|
function compatibleSettingKinds(previous, next) {
|
|
313
|
-
return previous.kind === next.kind || previous.kind === "text" && (next.kind === "resource" || next.kind === "datetime");
|
|
325
|
+
return previous.kind === next.kind || previous.kind === "text" && (next.kind === "resource" || next.kind === "datetime" || next.kind === "point-ledger");
|
|
314
326
|
}
|
|
315
327
|
|
|
316
328
|
// src/schema.ts
|