@ramme-io/shared 3.4.0 → 3.5.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/index.cjs +40 -2
- package/dist/index.d.cts +220 -5
- package/dist/index.d.ts +220 -5
- package/dist/index.js +36 -2
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -120,6 +120,8 @@ __export(index_exports, {
|
|
|
120
120
|
EventSourceSchema: () => EventSourceSchema,
|
|
121
121
|
FIRMWARE_UPDATE_ATTEMPTS: () => FIRMWARE_UPDATE_ATTEMPTS,
|
|
122
122
|
FIRMWARE_UPDATE_PREFIX: () => FIRMWARE_UPDATE_PREFIX,
|
|
123
|
+
FULL_COLOUR_FRAME_MAX: () => FULL_COLOUR_FRAME_MAX,
|
|
124
|
+
FULL_RENDITION: () => FULL_RENDITION,
|
|
123
125
|
FieldSchema: () => FieldSchema,
|
|
124
126
|
FirmwareUpdateSchema: () => FirmwareUpdateSchema,
|
|
125
127
|
FloraTelemetrySchema: () => FloraTelemetrySchema,
|
|
@@ -144,6 +146,8 @@ __export(index_exports, {
|
|
|
144
146
|
PageSectionSchema: () => PageSectionSchema,
|
|
145
147
|
PaginatedEntityEventsSchema: () => PaginatedEntityEventsSchema,
|
|
146
148
|
PairCodeSchema: () => PairCodeSchema,
|
|
149
|
+
PhotoCropSchema: () => PhotoCropSchema,
|
|
150
|
+
PhotoFullSchema: () => PhotoFullSchema,
|
|
147
151
|
PhotoSummarySchema: () => PhotoSummarySchema,
|
|
148
152
|
PhotoUploadSchema: () => PhotoUploadSchema,
|
|
149
153
|
ProvisioningStateSchema: () => ProvisioningStateSchema,
|
|
@@ -753,6 +757,7 @@ var AssetHashSchema = import_zod6.z.string().regex(/^[0-9a-f]{64}$/, "a lowercas
|
|
|
753
757
|
var IMAGE_MAX_DRAWN = { width: 304, height: 224 };
|
|
754
758
|
var IMAGE_MAX_SCALE = 8;
|
|
755
759
|
var RETRO_RENDITION = { width: 76, height: 56, scale: 4, colors: 16 };
|
|
760
|
+
var FULL_RENDITION = { width: 304, height: 224, quality: 0.82, maxBytes: 48e3 };
|
|
756
761
|
var SPR_FORMAT = {
|
|
757
762
|
/** "RSPR". */
|
|
758
763
|
magic: [82, 83, 80, 82],
|
|
@@ -771,6 +776,12 @@ var AppImageSchema = import_zod6.z.object({
|
|
|
771
776
|
width: import_zod6.z.number().int().min(1).max(IMAGE_MAX_DRAWN.width),
|
|
772
777
|
height: import_zod6.z.number().int().min(1).max(IMAGE_MAX_DRAWN.height),
|
|
773
778
|
scale: import_zod6.z.number().int().min(1).max(IMAGE_MAX_SCALE).default(1),
|
|
779
|
+
/**
|
|
780
|
+
* What kind of file `asset` names: `spr`, the palette file the retro look
|
|
781
|
+
* uses, or `jpeg`, the full-colour rendition (drawn at scale 1). Absent means
|
|
782
|
+
* `spr`, which is every image block written before full colour existed.
|
|
783
|
+
*/
|
|
784
|
+
format: import_zod6.z.enum(["spr", "jpeg"]).default("spr"),
|
|
774
785
|
align: AppAlignSchema.default("start"),
|
|
775
786
|
/** Drawn only when this is false, or absent. */
|
|
776
787
|
hideWhen: AppConditionSchema.optional()
|
|
@@ -826,6 +837,14 @@ var AppDocumentSchema = import_zod6.z.object({
|
|
|
826
837
|
const b = block;
|
|
827
838
|
if (b?.type !== "image" || !b.width || !b.height) return;
|
|
828
839
|
const scale = b.scale ?? 1;
|
|
840
|
+
if (b.format === "jpeg" && scale !== 1) {
|
|
841
|
+
ctx.addIssue({
|
|
842
|
+
code: import_zod6.z.ZodIssueCode.custom,
|
|
843
|
+
path: [...path, "scale"],
|
|
844
|
+
message: "A jpeg image is drawn at scale 1; make the file the size it should appear."
|
|
845
|
+
});
|
|
846
|
+
return;
|
|
847
|
+
}
|
|
829
848
|
const w = b.width * scale;
|
|
830
849
|
const h = b.height * scale;
|
|
831
850
|
if (w <= IMAGE_MAX_DRAWN.width && h <= IMAGE_MAX_DRAWN.height) return;
|
|
@@ -854,10 +873,22 @@ var ORIGINAL_MAX_SIDE = 3072;
|
|
|
854
873
|
var ORIGINAL_MAX_BYTES = 3e6;
|
|
855
874
|
var PHOTOS_PER_ACCOUNT = 50;
|
|
856
875
|
var PHOTO_UPLOADS_PER_HOUR = 30;
|
|
876
|
+
var PhotoCropSchema = import_zod7.z.object({
|
|
877
|
+
x: import_zod7.z.number().min(0).max(1),
|
|
878
|
+
y: import_zod7.z.number().min(0).max(1),
|
|
879
|
+
w: import_zod7.z.number().gt(0).max(1),
|
|
880
|
+
h: import_zod7.z.number().gt(0).max(1),
|
|
881
|
+
mirror: import_zod7.z.boolean().default(false)
|
|
882
|
+
});
|
|
857
883
|
var PhotoUploadSchema = import_zod7.z.object({
|
|
858
884
|
rendition: import_zod7.z.string().min(4),
|
|
859
|
-
original: import_zod7.z.string().min(4)
|
|
885
|
+
original: import_zod7.z.string().min(4),
|
|
886
|
+
/** The full-colour rendition (FULL_RENDITION), base64 JPEG. Optional for older clients. */
|
|
887
|
+
full: import_zod7.z.string().min(4).optional(),
|
|
888
|
+
crop: PhotoCropSchema.optional()
|
|
860
889
|
});
|
|
890
|
+
var PhotoFullSchema = import_zod7.z.object({ full: import_zod7.z.string().min(4) });
|
|
891
|
+
var FULL_COLOUR_FRAME_MAX = 4;
|
|
861
892
|
var PhotoSummarySchema = import_zod7.z.object({
|
|
862
893
|
hash: AssetHashSchema,
|
|
863
894
|
/** The rendition's own pixels. */
|
|
@@ -867,7 +898,10 @@ var PhotoSummarySchema = import_zod7.z.object({
|
|
|
867
898
|
originalWidth: import_zod7.z.number().int().positive(),
|
|
868
899
|
originalHeight: import_zod7.z.number().int().positive(),
|
|
869
900
|
originalBytes: import_zod7.z.number().int().positive(),
|
|
870
|
-
uploadedAt: import_zod7.z.number().int()
|
|
901
|
+
uploadedAt: import_zod7.z.number().int(),
|
|
902
|
+
/** The full-colour rendition, when one has been made. Its own hash names it. */
|
|
903
|
+
full: import_zod7.z.object({ hash: AssetHashSchema, bytes: import_zod7.z.number().int().positive() }).optional(),
|
|
904
|
+
crop: PhotoCropSchema.optional()
|
|
871
905
|
});
|
|
872
906
|
|
|
873
907
|
// src/apps/delivery.ts
|
|
@@ -2006,6 +2040,8 @@ var EXCLUDED_SOURCES = {
|
|
|
2006
2040
|
EventSourceSchema,
|
|
2007
2041
|
FIRMWARE_UPDATE_ATTEMPTS,
|
|
2008
2042
|
FIRMWARE_UPDATE_PREFIX,
|
|
2043
|
+
FULL_COLOUR_FRAME_MAX,
|
|
2044
|
+
FULL_RENDITION,
|
|
2009
2045
|
FieldSchema,
|
|
2010
2046
|
FirmwareUpdateSchema,
|
|
2011
2047
|
FloraTelemetrySchema,
|
|
@@ -2030,6 +2066,8 @@ var EXCLUDED_SOURCES = {
|
|
|
2030
2066
|
PageSectionSchema,
|
|
2031
2067
|
PaginatedEntityEventsSchema,
|
|
2032
2068
|
PairCodeSchema,
|
|
2069
|
+
PhotoCropSchema,
|
|
2070
|
+
PhotoFullSchema,
|
|
2033
2071
|
PhotoSummarySchema,
|
|
2034
2072
|
PhotoUploadSchema,
|
|
2035
2073
|
ProvisioningStateSchema,
|
package/dist/index.d.cts
CHANGED
|
@@ -4418,6 +4418,21 @@ declare const RETRO_RENDITION: {
|
|
|
4418
4418
|
readonly scale: 4;
|
|
4419
4419
|
readonly colors: 16;
|
|
4420
4420
|
};
|
|
4421
|
+
/**
|
|
4422
|
+
* The full-colour rendition, added on 2026-10-14 at the owner's request as the
|
|
4423
|
+
* photo frame's default: the picture at the drawable area's own size, as a
|
|
4424
|
+
* baseline JPEG, drawn 1:1. About 20-25KB, so a CYD's photo storage holds a
|
|
4425
|
+
* handful — FULL_COLOUR_FRAME_MAX in ./photos.ts. Retro stays for the toy look.
|
|
4426
|
+
*
|
|
4427
|
+
* Baseline, never progressive: the board's decoder (TJpgDec, inside
|
|
4428
|
+
* LovyanGFX) reads baseline only, and a canvas encodes baseline anyway.
|
|
4429
|
+
*/
|
|
4430
|
+
declare const FULL_RENDITION: {
|
|
4431
|
+
readonly width: 304;
|
|
4432
|
+
readonly height: 224;
|
|
4433
|
+
readonly quality: 0.82;
|
|
4434
|
+
readonly maxBytes: 48000;
|
|
4435
|
+
};
|
|
4421
4436
|
/** The `.spr` file format, version 1. Little-endian, as both boards are. */
|
|
4422
4437
|
declare const SPR_FORMAT: {
|
|
4423
4438
|
/** "RSPR". */
|
|
@@ -4438,6 +4453,12 @@ declare const AppImageSchema: z.ZodObject<{
|
|
|
4438
4453
|
width: z.ZodNumber;
|
|
4439
4454
|
height: z.ZodNumber;
|
|
4440
4455
|
scale: z.ZodDefault<z.ZodNumber>;
|
|
4456
|
+
/**
|
|
4457
|
+
* What kind of file `asset` names: `spr`, the palette file the retro look
|
|
4458
|
+
* uses, or `jpeg`, the full-colour rendition (drawn at scale 1). Absent means
|
|
4459
|
+
* `spr`, which is every image block written before full colour existed.
|
|
4460
|
+
*/
|
|
4461
|
+
format: z.ZodDefault<z.ZodEnum<["spr", "jpeg"]>>;
|
|
4441
4462
|
align: z.ZodDefault<z.ZodEnum<["start", "center", "end"]>>;
|
|
4442
4463
|
/** Drawn only when this is false, or absent. */
|
|
4443
4464
|
hideWhen: z.ZodOptional<z.ZodObject<{
|
|
@@ -4485,6 +4506,7 @@ declare const AppImageSchema: z.ZodObject<{
|
|
|
4485
4506
|
height: number;
|
|
4486
4507
|
asset: string;
|
|
4487
4508
|
scale: number;
|
|
4509
|
+
format: "spr" | "jpeg";
|
|
4488
4510
|
hideWhen?: {
|
|
4489
4511
|
value: {
|
|
4490
4512
|
literal: number;
|
|
@@ -4512,6 +4534,7 @@ declare const AppImageSchema: z.ZodObject<{
|
|
|
4512
4534
|
than: string | number | boolean;
|
|
4513
4535
|
} | undefined;
|
|
4514
4536
|
scale?: number | undefined;
|
|
4537
|
+
format?: "spr" | "jpeg" | undefined;
|
|
4515
4538
|
}>;
|
|
4516
4539
|
/** Everything that draws itself without holding children. */
|
|
4517
4540
|
declare const AppLeafSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
|
|
@@ -6065,6 +6088,12 @@ declare const AppLeafSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
|
|
|
6065
6088
|
width: z.ZodNumber;
|
|
6066
6089
|
height: z.ZodNumber;
|
|
6067
6090
|
scale: z.ZodDefault<z.ZodNumber>;
|
|
6091
|
+
/**
|
|
6092
|
+
* What kind of file `asset` names: `spr`, the palette file the retro look
|
|
6093
|
+
* uses, or `jpeg`, the full-colour rendition (drawn at scale 1). Absent means
|
|
6094
|
+
* `spr`, which is every image block written before full colour existed.
|
|
6095
|
+
*/
|
|
6096
|
+
format: z.ZodDefault<z.ZodEnum<["spr", "jpeg"]>>;
|
|
6068
6097
|
align: z.ZodDefault<z.ZodEnum<["start", "center", "end"]>>;
|
|
6069
6098
|
/** Drawn only when this is false, or absent. */
|
|
6070
6099
|
hideWhen: z.ZodOptional<z.ZodObject<{
|
|
@@ -6112,6 +6141,7 @@ declare const AppLeafSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
|
|
|
6112
6141
|
height: number;
|
|
6113
6142
|
asset: string;
|
|
6114
6143
|
scale: number;
|
|
6144
|
+
format: "spr" | "jpeg";
|
|
6115
6145
|
hideWhen?: {
|
|
6116
6146
|
value: {
|
|
6117
6147
|
literal: number;
|
|
@@ -6139,6 +6169,7 @@ declare const AppLeafSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
|
|
|
6139
6169
|
than: string | number | boolean;
|
|
6140
6170
|
} | undefined;
|
|
6141
6171
|
scale?: number | undefined;
|
|
6172
|
+
format?: "spr" | "jpeg" | undefined;
|
|
6142
6173
|
}>]>;
|
|
6143
6174
|
/**
|
|
6144
6175
|
* The only container, and the second and final level of the tree.
|
|
@@ -7702,6 +7733,12 @@ declare const AppGroupSchema: z.ZodObject<{
|
|
|
7702
7733
|
width: z.ZodNumber;
|
|
7703
7734
|
height: z.ZodNumber;
|
|
7704
7735
|
scale: z.ZodDefault<z.ZodNumber>;
|
|
7736
|
+
/**
|
|
7737
|
+
* What kind of file `asset` names: `spr`, the palette file the retro look
|
|
7738
|
+
* uses, or `jpeg`, the full-colour rendition (drawn at scale 1). Absent means
|
|
7739
|
+
* `spr`, which is every image block written before full colour existed.
|
|
7740
|
+
*/
|
|
7741
|
+
format: z.ZodDefault<z.ZodEnum<["spr", "jpeg"]>>;
|
|
7705
7742
|
align: z.ZodDefault<z.ZodEnum<["start", "center", "end"]>>;
|
|
7706
7743
|
/** Drawn only when this is false, or absent. */
|
|
7707
7744
|
hideWhen: z.ZodOptional<z.ZodObject<{
|
|
@@ -7749,6 +7786,7 @@ declare const AppGroupSchema: z.ZodObject<{
|
|
|
7749
7786
|
height: number;
|
|
7750
7787
|
asset: string;
|
|
7751
7788
|
scale: number;
|
|
7789
|
+
format: "spr" | "jpeg";
|
|
7752
7790
|
hideWhen?: {
|
|
7753
7791
|
value: {
|
|
7754
7792
|
literal: number;
|
|
@@ -7776,6 +7814,7 @@ declare const AppGroupSchema: z.ZodObject<{
|
|
|
7776
7814
|
than: string | number | boolean;
|
|
7777
7815
|
} | undefined;
|
|
7778
7816
|
scale?: number | undefined;
|
|
7817
|
+
format?: "spr" | "jpeg" | undefined;
|
|
7779
7818
|
}>]>, "many">;
|
|
7780
7819
|
}, "strip", z.ZodTypeAny, {
|
|
7781
7820
|
type: "group";
|
|
@@ -8050,6 +8089,7 @@ declare const AppGroupSchema: z.ZodObject<{
|
|
|
8050
8089
|
height: number;
|
|
8051
8090
|
asset: string;
|
|
8052
8091
|
scale: number;
|
|
8092
|
+
format: "spr" | "jpeg";
|
|
8053
8093
|
hideWhen?: {
|
|
8054
8094
|
value: {
|
|
8055
8095
|
literal: number;
|
|
@@ -8342,6 +8382,7 @@ declare const AppGroupSchema: z.ZodObject<{
|
|
|
8342
8382
|
than: string | number | boolean;
|
|
8343
8383
|
} | undefined;
|
|
8344
8384
|
scale?: number | undefined;
|
|
8385
|
+
format?: "spr" | "jpeg" | undefined;
|
|
8345
8386
|
})[];
|
|
8346
8387
|
align?: "start" | "center" | "end" | undefined;
|
|
8347
8388
|
gap?: number | undefined;
|
|
@@ -9898,6 +9939,12 @@ declare const AppBlockSchema: z.ZodUnion<[z.ZodDiscriminatedUnion<"type", [z.Zod
|
|
|
9898
9939
|
width: z.ZodNumber;
|
|
9899
9940
|
height: z.ZodNumber;
|
|
9900
9941
|
scale: z.ZodDefault<z.ZodNumber>;
|
|
9942
|
+
/**
|
|
9943
|
+
* What kind of file `asset` names: `spr`, the palette file the retro look
|
|
9944
|
+
* uses, or `jpeg`, the full-colour rendition (drawn at scale 1). Absent means
|
|
9945
|
+
* `spr`, which is every image block written before full colour existed.
|
|
9946
|
+
*/
|
|
9947
|
+
format: z.ZodDefault<z.ZodEnum<["spr", "jpeg"]>>;
|
|
9901
9948
|
align: z.ZodDefault<z.ZodEnum<["start", "center", "end"]>>;
|
|
9902
9949
|
/** Drawn only when this is false, or absent. */
|
|
9903
9950
|
hideWhen: z.ZodOptional<z.ZodObject<{
|
|
@@ -9945,6 +9992,7 @@ declare const AppBlockSchema: z.ZodUnion<[z.ZodDiscriminatedUnion<"type", [z.Zod
|
|
|
9945
9992
|
height: number;
|
|
9946
9993
|
asset: string;
|
|
9947
9994
|
scale: number;
|
|
9995
|
+
format: "spr" | "jpeg";
|
|
9948
9996
|
hideWhen?: {
|
|
9949
9997
|
value: {
|
|
9950
9998
|
literal: number;
|
|
@@ -9972,6 +10020,7 @@ declare const AppBlockSchema: z.ZodUnion<[z.ZodDiscriminatedUnion<"type", [z.Zod
|
|
|
9972
10020
|
than: string | number | boolean;
|
|
9973
10021
|
} | undefined;
|
|
9974
10022
|
scale?: number | undefined;
|
|
10023
|
+
format?: "spr" | "jpeg" | undefined;
|
|
9975
10024
|
}>]>, z.ZodObject<{
|
|
9976
10025
|
type: z.ZodLiteral<"group">;
|
|
9977
10026
|
direction: z.ZodEnum<["row", "stack"]>;
|
|
@@ -11528,6 +11577,12 @@ declare const AppBlockSchema: z.ZodUnion<[z.ZodDiscriminatedUnion<"type", [z.Zod
|
|
|
11528
11577
|
width: z.ZodNumber;
|
|
11529
11578
|
height: z.ZodNumber;
|
|
11530
11579
|
scale: z.ZodDefault<z.ZodNumber>;
|
|
11580
|
+
/**
|
|
11581
|
+
* What kind of file `asset` names: `spr`, the palette file the retro look
|
|
11582
|
+
* uses, or `jpeg`, the full-colour rendition (drawn at scale 1). Absent means
|
|
11583
|
+
* `spr`, which is every image block written before full colour existed.
|
|
11584
|
+
*/
|
|
11585
|
+
format: z.ZodDefault<z.ZodEnum<["spr", "jpeg"]>>;
|
|
11531
11586
|
align: z.ZodDefault<z.ZodEnum<["start", "center", "end"]>>;
|
|
11532
11587
|
/** Drawn only when this is false, or absent. */
|
|
11533
11588
|
hideWhen: z.ZodOptional<z.ZodObject<{
|
|
@@ -11575,6 +11630,7 @@ declare const AppBlockSchema: z.ZodUnion<[z.ZodDiscriminatedUnion<"type", [z.Zod
|
|
|
11575
11630
|
height: number;
|
|
11576
11631
|
asset: string;
|
|
11577
11632
|
scale: number;
|
|
11633
|
+
format: "spr" | "jpeg";
|
|
11578
11634
|
hideWhen?: {
|
|
11579
11635
|
value: {
|
|
11580
11636
|
literal: number;
|
|
@@ -11602,6 +11658,7 @@ declare const AppBlockSchema: z.ZodUnion<[z.ZodDiscriminatedUnion<"type", [z.Zod
|
|
|
11602
11658
|
than: string | number | boolean;
|
|
11603
11659
|
} | undefined;
|
|
11604
11660
|
scale?: number | undefined;
|
|
11661
|
+
format?: "spr" | "jpeg" | undefined;
|
|
11605
11662
|
}>]>, "many">;
|
|
11606
11663
|
}, "strip", z.ZodTypeAny, {
|
|
11607
11664
|
type: "group";
|
|
@@ -11876,6 +11933,7 @@ declare const AppBlockSchema: z.ZodUnion<[z.ZodDiscriminatedUnion<"type", [z.Zod
|
|
|
11876
11933
|
height: number;
|
|
11877
11934
|
asset: string;
|
|
11878
11935
|
scale: number;
|
|
11936
|
+
format: "spr" | "jpeg";
|
|
11879
11937
|
hideWhen?: {
|
|
11880
11938
|
value: {
|
|
11881
11939
|
literal: number;
|
|
@@ -12168,6 +12226,7 @@ declare const AppBlockSchema: z.ZodUnion<[z.ZodDiscriminatedUnion<"type", [z.Zod
|
|
|
12168
12226
|
than: string | number | boolean;
|
|
12169
12227
|
} | undefined;
|
|
12170
12228
|
scale?: number | undefined;
|
|
12229
|
+
format?: "spr" | "jpeg" | undefined;
|
|
12171
12230
|
})[];
|
|
12172
12231
|
align?: "start" | "center" | "end" | undefined;
|
|
12173
12232
|
gap?: number | undefined;
|
|
@@ -13821,6 +13880,12 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
13821
13880
|
width: z.ZodNumber;
|
|
13822
13881
|
height: z.ZodNumber;
|
|
13823
13882
|
scale: z.ZodDefault<z.ZodNumber>;
|
|
13883
|
+
/**
|
|
13884
|
+
* What kind of file `asset` names: `spr`, the palette file the retro look
|
|
13885
|
+
* uses, or `jpeg`, the full-colour rendition (drawn at scale 1). Absent means
|
|
13886
|
+
* `spr`, which is every image block written before full colour existed.
|
|
13887
|
+
*/
|
|
13888
|
+
format: z.ZodDefault<z.ZodEnum<["spr", "jpeg"]>>;
|
|
13824
13889
|
align: z.ZodDefault<z.ZodEnum<["start", "center", "end"]>>;
|
|
13825
13890
|
/** Drawn only when this is false, or absent. */
|
|
13826
13891
|
hideWhen: z.ZodOptional<z.ZodObject<{
|
|
@@ -13868,6 +13933,7 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
13868
13933
|
height: number;
|
|
13869
13934
|
asset: string;
|
|
13870
13935
|
scale: number;
|
|
13936
|
+
format: "spr" | "jpeg";
|
|
13871
13937
|
hideWhen?: {
|
|
13872
13938
|
value: {
|
|
13873
13939
|
literal: number;
|
|
@@ -13895,6 +13961,7 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
13895
13961
|
than: string | number | boolean;
|
|
13896
13962
|
} | undefined;
|
|
13897
13963
|
scale?: number | undefined;
|
|
13964
|
+
format?: "spr" | "jpeg" | undefined;
|
|
13898
13965
|
}>]>, z.ZodObject<{
|
|
13899
13966
|
type: z.ZodLiteral<"group">;
|
|
13900
13967
|
direction: z.ZodEnum<["row", "stack"]>;
|
|
@@ -15451,6 +15518,12 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
15451
15518
|
width: z.ZodNumber;
|
|
15452
15519
|
height: z.ZodNumber;
|
|
15453
15520
|
scale: z.ZodDefault<z.ZodNumber>;
|
|
15521
|
+
/**
|
|
15522
|
+
* What kind of file `asset` names: `spr`, the palette file the retro look
|
|
15523
|
+
* uses, or `jpeg`, the full-colour rendition (drawn at scale 1). Absent means
|
|
15524
|
+
* `spr`, which is every image block written before full colour existed.
|
|
15525
|
+
*/
|
|
15526
|
+
format: z.ZodDefault<z.ZodEnum<["spr", "jpeg"]>>;
|
|
15454
15527
|
align: z.ZodDefault<z.ZodEnum<["start", "center", "end"]>>;
|
|
15455
15528
|
/** Drawn only when this is false, or absent. */
|
|
15456
15529
|
hideWhen: z.ZodOptional<z.ZodObject<{
|
|
@@ -15498,6 +15571,7 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
15498
15571
|
height: number;
|
|
15499
15572
|
asset: string;
|
|
15500
15573
|
scale: number;
|
|
15574
|
+
format: "spr" | "jpeg";
|
|
15501
15575
|
hideWhen?: {
|
|
15502
15576
|
value: {
|
|
15503
15577
|
literal: number;
|
|
@@ -15525,6 +15599,7 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
15525
15599
|
than: string | number | boolean;
|
|
15526
15600
|
} | undefined;
|
|
15527
15601
|
scale?: number | undefined;
|
|
15602
|
+
format?: "spr" | "jpeg" | undefined;
|
|
15528
15603
|
}>]>, "many">;
|
|
15529
15604
|
}, "strip", z.ZodTypeAny, {
|
|
15530
15605
|
type: "group";
|
|
@@ -15799,6 +15874,7 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
15799
15874
|
height: number;
|
|
15800
15875
|
asset: string;
|
|
15801
15876
|
scale: number;
|
|
15877
|
+
format: "spr" | "jpeg";
|
|
15802
15878
|
hideWhen?: {
|
|
15803
15879
|
value: {
|
|
15804
15880
|
literal: number;
|
|
@@ -16091,6 +16167,7 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
16091
16167
|
than: string | number | boolean;
|
|
16092
16168
|
} | undefined;
|
|
16093
16169
|
scale?: number | undefined;
|
|
16170
|
+
format?: "spr" | "jpeg" | undefined;
|
|
16094
16171
|
})[];
|
|
16095
16172
|
align?: "start" | "center" | "end" | undefined;
|
|
16096
16173
|
gap?: number | undefined;
|
|
@@ -16366,6 +16443,7 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
16366
16443
|
height: number;
|
|
16367
16444
|
asset: string;
|
|
16368
16445
|
scale: number;
|
|
16446
|
+
format: "spr" | "jpeg";
|
|
16369
16447
|
hideWhen?: {
|
|
16370
16448
|
value: {
|
|
16371
16449
|
literal: number;
|
|
@@ -16649,6 +16727,7 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
16649
16727
|
height: number;
|
|
16650
16728
|
asset: string;
|
|
16651
16729
|
scale: number;
|
|
16730
|
+
format: "spr" | "jpeg";
|
|
16652
16731
|
hideWhen?: {
|
|
16653
16732
|
value: {
|
|
16654
16733
|
literal: number;
|
|
@@ -16968,6 +17047,7 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
16968
17047
|
than: string | number | boolean;
|
|
16969
17048
|
} | undefined;
|
|
16970
17049
|
scale?: number | undefined;
|
|
17050
|
+
format?: "spr" | "jpeg" | undefined;
|
|
16971
17051
|
} | {
|
|
16972
17052
|
type: "group";
|
|
16973
17053
|
direction: "stack" | "row";
|
|
@@ -17249,6 +17329,7 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
17249
17329
|
than: string | number | boolean;
|
|
17250
17330
|
} | undefined;
|
|
17251
17331
|
scale?: number | undefined;
|
|
17332
|
+
format?: "spr" | "jpeg" | undefined;
|
|
17252
17333
|
})[];
|
|
17253
17334
|
align?: "start" | "center" | "end" | undefined;
|
|
17254
17335
|
gap?: number | undefined;
|
|
@@ -17550,6 +17631,7 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
17550
17631
|
height: number;
|
|
17551
17632
|
asset: string;
|
|
17552
17633
|
scale: number;
|
|
17634
|
+
format: "spr" | "jpeg";
|
|
17553
17635
|
hideWhen?: {
|
|
17554
17636
|
value: {
|
|
17555
17637
|
literal: number;
|
|
@@ -17833,6 +17915,7 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
17833
17915
|
height: number;
|
|
17834
17916
|
asset: string;
|
|
17835
17917
|
scale: number;
|
|
17918
|
+
format: "spr" | "jpeg";
|
|
17836
17919
|
hideWhen?: {
|
|
17837
17920
|
value: {
|
|
17838
17921
|
literal: number;
|
|
@@ -18152,6 +18235,7 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
18152
18235
|
than: string | number | boolean;
|
|
18153
18236
|
} | undefined;
|
|
18154
18237
|
scale?: number | undefined;
|
|
18238
|
+
format?: "spr" | "jpeg" | undefined;
|
|
18155
18239
|
} | {
|
|
18156
18240
|
type: "group";
|
|
18157
18241
|
direction: "stack" | "row";
|
|
@@ -18433,6 +18517,7 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
18433
18517
|
than: string | number | boolean;
|
|
18434
18518
|
} | undefined;
|
|
18435
18519
|
scale?: number | undefined;
|
|
18520
|
+
format?: "spr" | "jpeg" | undefined;
|
|
18436
18521
|
})[];
|
|
18437
18522
|
align?: "start" | "center" | "end" | undefined;
|
|
18438
18523
|
gap?: number | undefined;
|
|
@@ -18516,16 +18601,93 @@ declare const PHOTOS_PER_ACCOUNT = 50;
|
|
|
18516
18601
|
/** Uploads per account per hour. Generous for a person; a wall for a script. */
|
|
18517
18602
|
declare const PHOTO_UPLOADS_PER_HOUR = 30;
|
|
18518
18603
|
/** What the Studio sends: both files, base64. */
|
|
18604
|
+
/**
|
|
18605
|
+
* Where in the original the board's picture was cropped from, as fractions of
|
|
18606
|
+
* its width and height, and whether it was mirrored. Kept so a rendition made
|
|
18607
|
+
* later from the original — full colour for a photo first saved retro — frames
|
|
18608
|
+
* the picture the way its owner chose. Photos saved before this existed have
|
|
18609
|
+
* none and are centred.
|
|
18610
|
+
*/
|
|
18611
|
+
declare const PhotoCropSchema: z.ZodObject<{
|
|
18612
|
+
x: z.ZodNumber;
|
|
18613
|
+
y: z.ZodNumber;
|
|
18614
|
+
w: z.ZodNumber;
|
|
18615
|
+
h: z.ZodNumber;
|
|
18616
|
+
mirror: z.ZodDefault<z.ZodBoolean>;
|
|
18617
|
+
}, "strip", z.ZodTypeAny, {
|
|
18618
|
+
x: number;
|
|
18619
|
+
y: number;
|
|
18620
|
+
w: number;
|
|
18621
|
+
h: number;
|
|
18622
|
+
mirror: boolean;
|
|
18623
|
+
}, {
|
|
18624
|
+
x: number;
|
|
18625
|
+
y: number;
|
|
18626
|
+
w: number;
|
|
18627
|
+
h: number;
|
|
18628
|
+
mirror?: boolean | undefined;
|
|
18629
|
+
}>;
|
|
18519
18630
|
declare const PhotoUploadSchema: z.ZodObject<{
|
|
18520
18631
|
rendition: z.ZodString;
|
|
18521
18632
|
original: z.ZodString;
|
|
18633
|
+
/** The full-colour rendition (FULL_RENDITION), base64 JPEG. Optional for older clients. */
|
|
18634
|
+
full: z.ZodOptional<z.ZodString>;
|
|
18635
|
+
crop: z.ZodOptional<z.ZodObject<{
|
|
18636
|
+
x: z.ZodNumber;
|
|
18637
|
+
y: z.ZodNumber;
|
|
18638
|
+
w: z.ZodNumber;
|
|
18639
|
+
h: z.ZodNumber;
|
|
18640
|
+
mirror: z.ZodDefault<z.ZodBoolean>;
|
|
18641
|
+
}, "strip", z.ZodTypeAny, {
|
|
18642
|
+
x: number;
|
|
18643
|
+
y: number;
|
|
18644
|
+
w: number;
|
|
18645
|
+
h: number;
|
|
18646
|
+
mirror: boolean;
|
|
18647
|
+
}, {
|
|
18648
|
+
x: number;
|
|
18649
|
+
y: number;
|
|
18650
|
+
w: number;
|
|
18651
|
+
h: number;
|
|
18652
|
+
mirror?: boolean | undefined;
|
|
18653
|
+
}>>;
|
|
18522
18654
|
}, "strip", z.ZodTypeAny, {
|
|
18523
18655
|
rendition: string;
|
|
18524
18656
|
original: string;
|
|
18657
|
+
full?: string | undefined;
|
|
18658
|
+
crop?: {
|
|
18659
|
+
x: number;
|
|
18660
|
+
y: number;
|
|
18661
|
+
w: number;
|
|
18662
|
+
h: number;
|
|
18663
|
+
mirror: boolean;
|
|
18664
|
+
} | undefined;
|
|
18525
18665
|
}, {
|
|
18526
18666
|
rendition: string;
|
|
18527
18667
|
original: string;
|
|
18668
|
+
full?: string | undefined;
|
|
18669
|
+
crop?: {
|
|
18670
|
+
x: number;
|
|
18671
|
+
y: number;
|
|
18672
|
+
w: number;
|
|
18673
|
+
h: number;
|
|
18674
|
+
mirror?: boolean | undefined;
|
|
18675
|
+
} | undefined;
|
|
18528
18676
|
}>;
|
|
18677
|
+
/** Adding a full-colour rendition to a photo saved without one. */
|
|
18678
|
+
declare const PhotoFullSchema: z.ZodObject<{
|
|
18679
|
+
full: z.ZodString;
|
|
18680
|
+
}, "strip", z.ZodTypeAny, {
|
|
18681
|
+
full: string;
|
|
18682
|
+
}, {
|
|
18683
|
+
full: string;
|
|
18684
|
+
}>;
|
|
18685
|
+
/**
|
|
18686
|
+
* How many photos a full-colour photo frame holds. A CYD keeps about 128KB of
|
|
18687
|
+
* photos and a full-colour one is 20-25KB, against ~2KB retro — so four, where
|
|
18688
|
+
* retro allows PHOTO_FRAME_MAX in the Studio's settings.
|
|
18689
|
+
*/
|
|
18690
|
+
declare const FULL_COLOUR_FRAME_MAX = 4;
|
|
18529
18691
|
/** One photo, as its owner sees it in a list. Never the bytes. */
|
|
18530
18692
|
declare const PhotoSummarySchema: z.ZodObject<{
|
|
18531
18693
|
hash: z.ZodString;
|
|
@@ -18537,6 +18699,36 @@ declare const PhotoSummarySchema: z.ZodObject<{
|
|
|
18537
18699
|
originalHeight: z.ZodNumber;
|
|
18538
18700
|
originalBytes: z.ZodNumber;
|
|
18539
18701
|
uploadedAt: z.ZodNumber;
|
|
18702
|
+
/** The full-colour rendition, when one has been made. Its own hash names it. */
|
|
18703
|
+
full: z.ZodOptional<z.ZodObject<{
|
|
18704
|
+
hash: z.ZodString;
|
|
18705
|
+
bytes: z.ZodNumber;
|
|
18706
|
+
}, "strip", z.ZodTypeAny, {
|
|
18707
|
+
hash: string;
|
|
18708
|
+
bytes: number;
|
|
18709
|
+
}, {
|
|
18710
|
+
hash: string;
|
|
18711
|
+
bytes: number;
|
|
18712
|
+
}>>;
|
|
18713
|
+
crop: z.ZodOptional<z.ZodObject<{
|
|
18714
|
+
x: z.ZodNumber;
|
|
18715
|
+
y: z.ZodNumber;
|
|
18716
|
+
w: z.ZodNumber;
|
|
18717
|
+
h: z.ZodNumber;
|
|
18718
|
+
mirror: z.ZodDefault<z.ZodBoolean>;
|
|
18719
|
+
}, "strip", z.ZodTypeAny, {
|
|
18720
|
+
x: number;
|
|
18721
|
+
y: number;
|
|
18722
|
+
w: number;
|
|
18723
|
+
h: number;
|
|
18724
|
+
mirror: boolean;
|
|
18725
|
+
}, {
|
|
18726
|
+
x: number;
|
|
18727
|
+
y: number;
|
|
18728
|
+
w: number;
|
|
18729
|
+
h: number;
|
|
18730
|
+
mirror?: boolean | undefined;
|
|
18731
|
+
}>>;
|
|
18540
18732
|
}, "strip", z.ZodTypeAny, {
|
|
18541
18733
|
width: number;
|
|
18542
18734
|
height: number;
|
|
@@ -18546,6 +18738,17 @@ declare const PhotoSummarySchema: z.ZodObject<{
|
|
|
18546
18738
|
originalHeight: number;
|
|
18547
18739
|
originalBytes: number;
|
|
18548
18740
|
uploadedAt: number;
|
|
18741
|
+
full?: {
|
|
18742
|
+
hash: string;
|
|
18743
|
+
bytes: number;
|
|
18744
|
+
} | undefined;
|
|
18745
|
+
crop?: {
|
|
18746
|
+
x: number;
|
|
18747
|
+
y: number;
|
|
18748
|
+
w: number;
|
|
18749
|
+
h: number;
|
|
18750
|
+
mirror: boolean;
|
|
18751
|
+
} | undefined;
|
|
18549
18752
|
}, {
|
|
18550
18753
|
width: number;
|
|
18551
18754
|
height: number;
|
|
@@ -18555,9 +18758,21 @@ declare const PhotoSummarySchema: z.ZodObject<{
|
|
|
18555
18758
|
originalHeight: number;
|
|
18556
18759
|
originalBytes: number;
|
|
18557
18760
|
uploadedAt: number;
|
|
18761
|
+
full?: {
|
|
18762
|
+
hash: string;
|
|
18763
|
+
bytes: number;
|
|
18764
|
+
} | undefined;
|
|
18765
|
+
crop?: {
|
|
18766
|
+
x: number;
|
|
18767
|
+
y: number;
|
|
18768
|
+
w: number;
|
|
18769
|
+
h: number;
|
|
18770
|
+
mirror?: boolean | undefined;
|
|
18771
|
+
} | undefined;
|
|
18558
18772
|
}>;
|
|
18559
18773
|
type PhotoUpload = z.infer<typeof PhotoUploadSchema>;
|
|
18560
18774
|
type PhotoSummary = z.infer<typeof PhotoSummarySchema>;
|
|
18775
|
+
type PhotoCrop = z.infer<typeof PhotoCropSchema>;
|
|
18561
18776
|
|
|
18562
18777
|
/**
|
|
18563
18778
|
* @file delivery.ts
|
|
@@ -18839,15 +19054,15 @@ declare const FirmwareUpdateSchema: z.ZodObject<{
|
|
|
18839
19054
|
requestedAt: z.ZodNumber;
|
|
18840
19055
|
}, "strip", z.ZodTypeAny, {
|
|
18841
19056
|
version: string;
|
|
19057
|
+
bytes: number;
|
|
18842
19058
|
url: string;
|
|
18843
19059
|
sha256: string;
|
|
18844
|
-
bytes: number;
|
|
18845
19060
|
requestedAt: number;
|
|
18846
19061
|
}, {
|
|
18847
19062
|
version: string;
|
|
19063
|
+
bytes: number;
|
|
18848
19064
|
url: string;
|
|
18849
19065
|
sha256: string;
|
|
18850
|
-
bytes: number;
|
|
18851
19066
|
requestedAt: number;
|
|
18852
19067
|
}>;
|
|
18853
19068
|
type FirmwareUpdate = z.infer<typeof FirmwareUpdateSchema>;
|
|
@@ -19868,14 +20083,14 @@ declare const ThemeTokensSchema: z.ZodObject<{
|
|
|
19868
20083
|
primary: string;
|
|
19869
20084
|
neutral: string;
|
|
19870
20085
|
destructive: string;
|
|
19871
|
-
radius: "sm" | "lg" | "
|
|
20086
|
+
radius: "sm" | "lg" | "full" | "none" | "md";
|
|
19872
20087
|
}, {
|
|
19873
20088
|
warning: string;
|
|
19874
20089
|
success: string;
|
|
19875
20090
|
primary: string;
|
|
19876
20091
|
neutral: string;
|
|
19877
20092
|
destructive: string;
|
|
19878
|
-
radius: "sm" | "lg" | "
|
|
20093
|
+
radius: "sm" | "lg" | "full" | "none" | "md";
|
|
19879
20094
|
}>;
|
|
19880
20095
|
type ThemeTokens = z.infer<typeof ThemeTokensSchema>;
|
|
19881
20096
|
declare const DEFAULT_THEME_TOKENS: ThemeTokens;
|
|
@@ -21026,4 +21241,4 @@ declare const DEFAULT_HORIZON_QUARTERS = 5;
|
|
|
21026
21241
|
*/
|
|
21027
21242
|
declare const EXCLUDED_SOURCES: Record<string, string>;
|
|
21028
21243
|
|
|
21029
|
-
export { ACCESS_REQUEST_TTL_SECONDS, ACCOUNT_TTL_SECONDS, type AIKeyManifest, AIKeyManifestSchema, type AITheme, AIThemeSchema, AI_ROSTER, AI_TOOLS, APP_DOCUMENT_EDIT_PREFIX, APP_DOCUMENT_SYSTEM_PROMPT, ASSISTANT_MODEL, ASSISTANT_PROVIDER, type AccessRequest, type AccessRequestRecord, AccessRequestRecordSchema, AccessRequestSchema, type AccessRequestStatus, AccessRequestStatusSchema, type AccountId, AccountIdSchema, type AccountRecord, AccountRecordSchema, type AccountRole, AccountRoleSchema, type AccountStatus, AccountStatusSchema, type ActionDefinition, ActionSchema, type AgentRoleConfig, type AgentRoleKey, AircraftAppConfigSchema, type AppAlign, AppAlignSchema, AppBarSchema, type AppBinding, AppBindingSchema, type AppBlock, AppBlockSchema, type AppColor, AppColorSchema, type AppColorToken, AppColorTokenSchema, type AppCompute, AppComputeSchema, type AppCondition, AppConditionSchema, AppDialSchema, type AppDocument, AppDocumentSchema, type AppGroup, AppGroupSchema, type AppImage, AppImageSchema, type AppLeaf, AppLeafSchema, type AppOperand, AppOperandSchema, AppRgbSchema, type AppScreenSize, AppScreenSizeSchema, AppSignalSchema, type AppSource, AppSourceSchema, AppSparklineSchema, type AppSpecification, AppSpecificationSchema, AppSpriteSchema, AppStatusSchema, type AppStyleRule, AppStyleRuleSchema, AppTextSchema, type AppTextSize, AppTextSizeSchema, type ArchitectureReferenceParams, AssetHashSchema, AuthStrategySchema, type Block, BlockSchema, schema as Bodewell, CLAIMED_DEVICE_TTL_SECONDS, ClockAppConfigSchema, type CompanyNewsParams, type CompanyProfileParams, type CounterpartyGraphParams, type CounterpartyNode, CounterpartyNodeSchema, type CounterpartyResolution, CounterpartyResolutionSchema, type CounterpartyType, CounterpartyTypeSchema, DEFAULT_CHAT_MODEL, DEFAULT_DEVICE_CONFIG, DEFAULT_HORIZON_QUARTERS, DEFAULT_PRO_MODEL, DEFAULT_SCHEMA_MODEL, DEFAULT_THEME_TOKENS, DEVICE_AP_SSID_PREFIX, DEVICE_ENDPOINTS, DEVICE_FRESH_MS, DEVICE_GLYPHS, DEVICE_LABEL_MAX, DEVICE_PALETTE, DEVICE_STALE_MS, DEVICE_TIMEZONES, DEVICE_TIMEZONE_FALLBACK, DEVICE_TTL_SECONDS, DEVICE_UNKNOWN_GLYPH, DEVICE_VITALS_FIELDS, type DailyPricePoint, DailyPricePointSchema, type DeliveredApp, DeliveredAppSchema, type DeviceAppId, DeviceAppIdSchema, DeviceAppsSchema, type DeviceConfig, DeviceConfigSchema, DeviceDisplayConfigSchema, type DeviceGlyph, type DeviceId, DeviceIdSchema, type DeviceKind, DeviceKindSchema, type DeviceRecord, DeviceRecordSchema, type DeviceRegistration, DeviceRegistrationSchema, type DeviceSeen, DeviceSeenSchema, type DeviceStatus, DeviceStatusSchema, DeviceThemeSchema, type DeviceTimeZone, type DeviceVitals, DeviceVitalsSchema, type DivergenceMetric, DivergenceMetricSchema, type DivergenceMetricsParams, EVENT_KIND_LABELS, EXCLUDED_SOURCES, type EntityDefinition, type EntityEvent, type EntityEventDensity, type EntityEventDensityBucket, EntityEventDensityBucketSchema, EntityEventDensitySchema, type EntityEventFacet, EntityEventFacetSchema, type EntityEventFacets, EntityEventFacetsSchema, type EntityEventKind, EntityEventKindSchema, EntityEventSchema, type EntityPriceSeries, EntityPriceSeriesSchema, EntitySchema, type EventBucketSize, EventBucketSizeSchema, type EventSource, EventSourceSchema, FIRMWARE_UPDATE_ATTEMPTS, FIRMWARE_UPDATE_PREFIX, type FieldDefinition, FieldSchema, type FirmwareUpdate, FirmwareUpdateSchema, type FloraTelemetry, FloraTelemetrySchema, GENESIS_LIBRARY_CONTEXT, GENESIS_VALID_COMPONENTS, type GenesisComponentType, IMAGE_MAX_DRAWN, IMAGE_MAX_SCALE, IMPACT_FLAG_THRESHOLD, INVITE_TTL_SECONDS, type ImpactScale, ImpactScaleSchema, type InviteRecord, InviteRecordSchema, type LiveQuoteParams, MAX_PASSWORD_LENGTH, MIN_PASSWORD_LENGTH, type NonPublicEntity, NonPublicEntitySchema, ORIGINAL_MAX_BYTES, ORIGINAL_MAX_SIDE, type OwnedSendRequest, OwnedSendRequestSchema, PHOTOS_PER_ACCOUNT, PHOTO_UPLOADS_PER_HOUR, PROVIDER_DEFAULT_MODEL, type PageDefinition, PageSchema, type PageSection, PageSectionSchema, type PaginatedEntityEvents, PaginatedEntityEventsSchema, type PairCode, PairCodeSchema, type PhotoSummary, PhotoSummarySchema, type PhotoUpload, PhotoUploadSchema, type ProviderDefaultModelKey, type ProvisioningState, ProvisioningStateSchema, type PublicAccount, PublicAccountSchema, RETRO_RENDITION, type RelationshipEdge, RelationshipEdgeSchema, type RelationshipEdgeType, RelationshipEdgeTypeSchema, type ResourceDefinition, ResourceSchema, SCRYPT_PARAMS, SENTIMENT_NEUTRAL, SESSION_COOKIE_NAME, SESSION_TTL_SECONDS, SIGNAL_DOMAINS, SIGNAL_KINDS, SIGNAL_KIND_LABELS, SIGNAL_SOURCES, SPRITE_MAX_BASE64, SPRITE_MAX_ROW_BYTES, SPRITE_MAX_SIDE, SPR_FORMAT, SPR_MAX_BYTES, type ScryptHash, ScryptHashSchema, type SendRequest, SendRequestSchema, SensorAppConfigSchema, type SessionRecord, SessionRecordSchema, type Signal, type SignalArray, SignalArraySchema, type SignalDefinition, type SignalDomain, type SignalKind, SignalKindSchema, type SignalPacket, SignalPacketSchema, SignalSchema, type SignalSource, SignalSourceSchema, type SignalWeight, SignalWeightSchema, type StockChartParams, THEME_PRESETS, THEME_SYSTEM_PROMPT, type TelemetryGraphParams, type ThemeFonts, ThemeFontsSchema, type ThemeOverrides, ThemeOverridesSchema, type ThemePreset, type ThemeTokens, ThemeTokensSchema, type TimestampPrecision, TimestampPrecisionSchema, type ToolCall, type ToolDefinition, TriggerSchema, type User, UserSchema, type VitalSource, VitalSourceSchema, WeatherAppConfigSchema, type WorkflowDefinition, WorkflowSchema, architectureReferenceParameters, companyNewsParameters, companyProfileParameters, counterpartyGraphParameters, divergenceMetricsParameters, liveQuoteParameters, stockChartParameters, telemetryGraphParameters };
|
|
21244
|
+
export { ACCESS_REQUEST_TTL_SECONDS, ACCOUNT_TTL_SECONDS, type AIKeyManifest, AIKeyManifestSchema, type AITheme, AIThemeSchema, AI_ROSTER, AI_TOOLS, APP_DOCUMENT_EDIT_PREFIX, APP_DOCUMENT_SYSTEM_PROMPT, ASSISTANT_MODEL, ASSISTANT_PROVIDER, type AccessRequest, type AccessRequestRecord, AccessRequestRecordSchema, AccessRequestSchema, type AccessRequestStatus, AccessRequestStatusSchema, type AccountId, AccountIdSchema, type AccountRecord, AccountRecordSchema, type AccountRole, AccountRoleSchema, type AccountStatus, AccountStatusSchema, type ActionDefinition, ActionSchema, type AgentRoleConfig, type AgentRoleKey, AircraftAppConfigSchema, type AppAlign, AppAlignSchema, AppBarSchema, type AppBinding, AppBindingSchema, type AppBlock, AppBlockSchema, type AppColor, AppColorSchema, type AppColorToken, AppColorTokenSchema, type AppCompute, AppComputeSchema, type AppCondition, AppConditionSchema, AppDialSchema, type AppDocument, AppDocumentSchema, type AppGroup, AppGroupSchema, type AppImage, AppImageSchema, type AppLeaf, AppLeafSchema, type AppOperand, AppOperandSchema, AppRgbSchema, type AppScreenSize, AppScreenSizeSchema, AppSignalSchema, type AppSource, AppSourceSchema, AppSparklineSchema, type AppSpecification, AppSpecificationSchema, AppSpriteSchema, AppStatusSchema, type AppStyleRule, AppStyleRuleSchema, AppTextSchema, type AppTextSize, AppTextSizeSchema, type ArchitectureReferenceParams, AssetHashSchema, AuthStrategySchema, type Block, BlockSchema, schema as Bodewell, CLAIMED_DEVICE_TTL_SECONDS, ClockAppConfigSchema, type CompanyNewsParams, type CompanyProfileParams, type CounterpartyGraphParams, type CounterpartyNode, CounterpartyNodeSchema, type CounterpartyResolution, CounterpartyResolutionSchema, type CounterpartyType, CounterpartyTypeSchema, DEFAULT_CHAT_MODEL, DEFAULT_DEVICE_CONFIG, DEFAULT_HORIZON_QUARTERS, DEFAULT_PRO_MODEL, DEFAULT_SCHEMA_MODEL, DEFAULT_THEME_TOKENS, DEVICE_AP_SSID_PREFIX, DEVICE_ENDPOINTS, DEVICE_FRESH_MS, DEVICE_GLYPHS, DEVICE_LABEL_MAX, DEVICE_PALETTE, DEVICE_STALE_MS, DEVICE_TIMEZONES, DEVICE_TIMEZONE_FALLBACK, DEVICE_TTL_SECONDS, DEVICE_UNKNOWN_GLYPH, DEVICE_VITALS_FIELDS, type DailyPricePoint, DailyPricePointSchema, type DeliveredApp, DeliveredAppSchema, type DeviceAppId, DeviceAppIdSchema, DeviceAppsSchema, type DeviceConfig, DeviceConfigSchema, DeviceDisplayConfigSchema, type DeviceGlyph, type DeviceId, DeviceIdSchema, type DeviceKind, DeviceKindSchema, type DeviceRecord, DeviceRecordSchema, type DeviceRegistration, DeviceRegistrationSchema, type DeviceSeen, DeviceSeenSchema, type DeviceStatus, DeviceStatusSchema, DeviceThemeSchema, type DeviceTimeZone, type DeviceVitals, DeviceVitalsSchema, type DivergenceMetric, DivergenceMetricSchema, type DivergenceMetricsParams, EVENT_KIND_LABELS, EXCLUDED_SOURCES, type EntityDefinition, type EntityEvent, type EntityEventDensity, type EntityEventDensityBucket, EntityEventDensityBucketSchema, EntityEventDensitySchema, type EntityEventFacet, EntityEventFacetSchema, type EntityEventFacets, EntityEventFacetsSchema, type EntityEventKind, EntityEventKindSchema, EntityEventSchema, type EntityPriceSeries, EntityPriceSeriesSchema, EntitySchema, type EventBucketSize, EventBucketSizeSchema, type EventSource, EventSourceSchema, FIRMWARE_UPDATE_ATTEMPTS, FIRMWARE_UPDATE_PREFIX, FULL_COLOUR_FRAME_MAX, FULL_RENDITION, type FieldDefinition, FieldSchema, type FirmwareUpdate, FirmwareUpdateSchema, type FloraTelemetry, FloraTelemetrySchema, GENESIS_LIBRARY_CONTEXT, GENESIS_VALID_COMPONENTS, type GenesisComponentType, IMAGE_MAX_DRAWN, IMAGE_MAX_SCALE, IMPACT_FLAG_THRESHOLD, INVITE_TTL_SECONDS, type ImpactScale, ImpactScaleSchema, type InviteRecord, InviteRecordSchema, type LiveQuoteParams, MAX_PASSWORD_LENGTH, MIN_PASSWORD_LENGTH, type NonPublicEntity, NonPublicEntitySchema, ORIGINAL_MAX_BYTES, ORIGINAL_MAX_SIDE, type OwnedSendRequest, OwnedSendRequestSchema, PHOTOS_PER_ACCOUNT, PHOTO_UPLOADS_PER_HOUR, PROVIDER_DEFAULT_MODEL, type PageDefinition, PageSchema, type PageSection, PageSectionSchema, type PaginatedEntityEvents, PaginatedEntityEventsSchema, type PairCode, PairCodeSchema, type PhotoCrop, PhotoCropSchema, PhotoFullSchema, type PhotoSummary, PhotoSummarySchema, type PhotoUpload, PhotoUploadSchema, type ProviderDefaultModelKey, type ProvisioningState, ProvisioningStateSchema, type PublicAccount, PublicAccountSchema, RETRO_RENDITION, type RelationshipEdge, RelationshipEdgeSchema, type RelationshipEdgeType, RelationshipEdgeTypeSchema, type ResourceDefinition, ResourceSchema, SCRYPT_PARAMS, SENTIMENT_NEUTRAL, SESSION_COOKIE_NAME, SESSION_TTL_SECONDS, SIGNAL_DOMAINS, SIGNAL_KINDS, SIGNAL_KIND_LABELS, SIGNAL_SOURCES, SPRITE_MAX_BASE64, SPRITE_MAX_ROW_BYTES, SPRITE_MAX_SIDE, SPR_FORMAT, SPR_MAX_BYTES, type ScryptHash, ScryptHashSchema, type SendRequest, SendRequestSchema, SensorAppConfigSchema, type SessionRecord, SessionRecordSchema, type Signal, type SignalArray, SignalArraySchema, type SignalDefinition, type SignalDomain, type SignalKind, SignalKindSchema, type SignalPacket, SignalPacketSchema, SignalSchema, type SignalSource, SignalSourceSchema, type SignalWeight, SignalWeightSchema, type StockChartParams, THEME_PRESETS, THEME_SYSTEM_PROMPT, type TelemetryGraphParams, type ThemeFonts, ThemeFontsSchema, type ThemeOverrides, ThemeOverridesSchema, type ThemePreset, type ThemeTokens, ThemeTokensSchema, type TimestampPrecision, TimestampPrecisionSchema, type ToolCall, type ToolDefinition, TriggerSchema, type User, UserSchema, type VitalSource, VitalSourceSchema, WeatherAppConfigSchema, type WorkflowDefinition, WorkflowSchema, architectureReferenceParameters, companyNewsParameters, companyProfileParameters, counterpartyGraphParameters, divergenceMetricsParameters, liveQuoteParameters, stockChartParameters, telemetryGraphParameters };
|
package/dist/index.d.ts
CHANGED
|
@@ -4418,6 +4418,21 @@ declare const RETRO_RENDITION: {
|
|
|
4418
4418
|
readonly scale: 4;
|
|
4419
4419
|
readonly colors: 16;
|
|
4420
4420
|
};
|
|
4421
|
+
/**
|
|
4422
|
+
* The full-colour rendition, added on 2026-10-14 at the owner's request as the
|
|
4423
|
+
* photo frame's default: the picture at the drawable area's own size, as a
|
|
4424
|
+
* baseline JPEG, drawn 1:1. About 20-25KB, so a CYD's photo storage holds a
|
|
4425
|
+
* handful — FULL_COLOUR_FRAME_MAX in ./photos.ts. Retro stays for the toy look.
|
|
4426
|
+
*
|
|
4427
|
+
* Baseline, never progressive: the board's decoder (TJpgDec, inside
|
|
4428
|
+
* LovyanGFX) reads baseline only, and a canvas encodes baseline anyway.
|
|
4429
|
+
*/
|
|
4430
|
+
declare const FULL_RENDITION: {
|
|
4431
|
+
readonly width: 304;
|
|
4432
|
+
readonly height: 224;
|
|
4433
|
+
readonly quality: 0.82;
|
|
4434
|
+
readonly maxBytes: 48000;
|
|
4435
|
+
};
|
|
4421
4436
|
/** The `.spr` file format, version 1. Little-endian, as both boards are. */
|
|
4422
4437
|
declare const SPR_FORMAT: {
|
|
4423
4438
|
/** "RSPR". */
|
|
@@ -4438,6 +4453,12 @@ declare const AppImageSchema: z.ZodObject<{
|
|
|
4438
4453
|
width: z.ZodNumber;
|
|
4439
4454
|
height: z.ZodNumber;
|
|
4440
4455
|
scale: z.ZodDefault<z.ZodNumber>;
|
|
4456
|
+
/**
|
|
4457
|
+
* What kind of file `asset` names: `spr`, the palette file the retro look
|
|
4458
|
+
* uses, or `jpeg`, the full-colour rendition (drawn at scale 1). Absent means
|
|
4459
|
+
* `spr`, which is every image block written before full colour existed.
|
|
4460
|
+
*/
|
|
4461
|
+
format: z.ZodDefault<z.ZodEnum<["spr", "jpeg"]>>;
|
|
4441
4462
|
align: z.ZodDefault<z.ZodEnum<["start", "center", "end"]>>;
|
|
4442
4463
|
/** Drawn only when this is false, or absent. */
|
|
4443
4464
|
hideWhen: z.ZodOptional<z.ZodObject<{
|
|
@@ -4485,6 +4506,7 @@ declare const AppImageSchema: z.ZodObject<{
|
|
|
4485
4506
|
height: number;
|
|
4486
4507
|
asset: string;
|
|
4487
4508
|
scale: number;
|
|
4509
|
+
format: "spr" | "jpeg";
|
|
4488
4510
|
hideWhen?: {
|
|
4489
4511
|
value: {
|
|
4490
4512
|
literal: number;
|
|
@@ -4512,6 +4534,7 @@ declare const AppImageSchema: z.ZodObject<{
|
|
|
4512
4534
|
than: string | number | boolean;
|
|
4513
4535
|
} | undefined;
|
|
4514
4536
|
scale?: number | undefined;
|
|
4537
|
+
format?: "spr" | "jpeg" | undefined;
|
|
4515
4538
|
}>;
|
|
4516
4539
|
/** Everything that draws itself without holding children. */
|
|
4517
4540
|
declare const AppLeafSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
|
|
@@ -6065,6 +6088,12 @@ declare const AppLeafSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
|
|
|
6065
6088
|
width: z.ZodNumber;
|
|
6066
6089
|
height: z.ZodNumber;
|
|
6067
6090
|
scale: z.ZodDefault<z.ZodNumber>;
|
|
6091
|
+
/**
|
|
6092
|
+
* What kind of file `asset` names: `spr`, the palette file the retro look
|
|
6093
|
+
* uses, or `jpeg`, the full-colour rendition (drawn at scale 1). Absent means
|
|
6094
|
+
* `spr`, which is every image block written before full colour existed.
|
|
6095
|
+
*/
|
|
6096
|
+
format: z.ZodDefault<z.ZodEnum<["spr", "jpeg"]>>;
|
|
6068
6097
|
align: z.ZodDefault<z.ZodEnum<["start", "center", "end"]>>;
|
|
6069
6098
|
/** Drawn only when this is false, or absent. */
|
|
6070
6099
|
hideWhen: z.ZodOptional<z.ZodObject<{
|
|
@@ -6112,6 +6141,7 @@ declare const AppLeafSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
|
|
|
6112
6141
|
height: number;
|
|
6113
6142
|
asset: string;
|
|
6114
6143
|
scale: number;
|
|
6144
|
+
format: "spr" | "jpeg";
|
|
6115
6145
|
hideWhen?: {
|
|
6116
6146
|
value: {
|
|
6117
6147
|
literal: number;
|
|
@@ -6139,6 +6169,7 @@ declare const AppLeafSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
|
|
|
6139
6169
|
than: string | number | boolean;
|
|
6140
6170
|
} | undefined;
|
|
6141
6171
|
scale?: number | undefined;
|
|
6172
|
+
format?: "spr" | "jpeg" | undefined;
|
|
6142
6173
|
}>]>;
|
|
6143
6174
|
/**
|
|
6144
6175
|
* The only container, and the second and final level of the tree.
|
|
@@ -7702,6 +7733,12 @@ declare const AppGroupSchema: z.ZodObject<{
|
|
|
7702
7733
|
width: z.ZodNumber;
|
|
7703
7734
|
height: z.ZodNumber;
|
|
7704
7735
|
scale: z.ZodDefault<z.ZodNumber>;
|
|
7736
|
+
/**
|
|
7737
|
+
* What kind of file `asset` names: `spr`, the palette file the retro look
|
|
7738
|
+
* uses, or `jpeg`, the full-colour rendition (drawn at scale 1). Absent means
|
|
7739
|
+
* `spr`, which is every image block written before full colour existed.
|
|
7740
|
+
*/
|
|
7741
|
+
format: z.ZodDefault<z.ZodEnum<["spr", "jpeg"]>>;
|
|
7705
7742
|
align: z.ZodDefault<z.ZodEnum<["start", "center", "end"]>>;
|
|
7706
7743
|
/** Drawn only when this is false, or absent. */
|
|
7707
7744
|
hideWhen: z.ZodOptional<z.ZodObject<{
|
|
@@ -7749,6 +7786,7 @@ declare const AppGroupSchema: z.ZodObject<{
|
|
|
7749
7786
|
height: number;
|
|
7750
7787
|
asset: string;
|
|
7751
7788
|
scale: number;
|
|
7789
|
+
format: "spr" | "jpeg";
|
|
7752
7790
|
hideWhen?: {
|
|
7753
7791
|
value: {
|
|
7754
7792
|
literal: number;
|
|
@@ -7776,6 +7814,7 @@ declare const AppGroupSchema: z.ZodObject<{
|
|
|
7776
7814
|
than: string | number | boolean;
|
|
7777
7815
|
} | undefined;
|
|
7778
7816
|
scale?: number | undefined;
|
|
7817
|
+
format?: "spr" | "jpeg" | undefined;
|
|
7779
7818
|
}>]>, "many">;
|
|
7780
7819
|
}, "strip", z.ZodTypeAny, {
|
|
7781
7820
|
type: "group";
|
|
@@ -8050,6 +8089,7 @@ declare const AppGroupSchema: z.ZodObject<{
|
|
|
8050
8089
|
height: number;
|
|
8051
8090
|
asset: string;
|
|
8052
8091
|
scale: number;
|
|
8092
|
+
format: "spr" | "jpeg";
|
|
8053
8093
|
hideWhen?: {
|
|
8054
8094
|
value: {
|
|
8055
8095
|
literal: number;
|
|
@@ -8342,6 +8382,7 @@ declare const AppGroupSchema: z.ZodObject<{
|
|
|
8342
8382
|
than: string | number | boolean;
|
|
8343
8383
|
} | undefined;
|
|
8344
8384
|
scale?: number | undefined;
|
|
8385
|
+
format?: "spr" | "jpeg" | undefined;
|
|
8345
8386
|
})[];
|
|
8346
8387
|
align?: "start" | "center" | "end" | undefined;
|
|
8347
8388
|
gap?: number | undefined;
|
|
@@ -9898,6 +9939,12 @@ declare const AppBlockSchema: z.ZodUnion<[z.ZodDiscriminatedUnion<"type", [z.Zod
|
|
|
9898
9939
|
width: z.ZodNumber;
|
|
9899
9940
|
height: z.ZodNumber;
|
|
9900
9941
|
scale: z.ZodDefault<z.ZodNumber>;
|
|
9942
|
+
/**
|
|
9943
|
+
* What kind of file `asset` names: `spr`, the palette file the retro look
|
|
9944
|
+
* uses, or `jpeg`, the full-colour rendition (drawn at scale 1). Absent means
|
|
9945
|
+
* `spr`, which is every image block written before full colour existed.
|
|
9946
|
+
*/
|
|
9947
|
+
format: z.ZodDefault<z.ZodEnum<["spr", "jpeg"]>>;
|
|
9901
9948
|
align: z.ZodDefault<z.ZodEnum<["start", "center", "end"]>>;
|
|
9902
9949
|
/** Drawn only when this is false, or absent. */
|
|
9903
9950
|
hideWhen: z.ZodOptional<z.ZodObject<{
|
|
@@ -9945,6 +9992,7 @@ declare const AppBlockSchema: z.ZodUnion<[z.ZodDiscriminatedUnion<"type", [z.Zod
|
|
|
9945
9992
|
height: number;
|
|
9946
9993
|
asset: string;
|
|
9947
9994
|
scale: number;
|
|
9995
|
+
format: "spr" | "jpeg";
|
|
9948
9996
|
hideWhen?: {
|
|
9949
9997
|
value: {
|
|
9950
9998
|
literal: number;
|
|
@@ -9972,6 +10020,7 @@ declare const AppBlockSchema: z.ZodUnion<[z.ZodDiscriminatedUnion<"type", [z.Zod
|
|
|
9972
10020
|
than: string | number | boolean;
|
|
9973
10021
|
} | undefined;
|
|
9974
10022
|
scale?: number | undefined;
|
|
10023
|
+
format?: "spr" | "jpeg" | undefined;
|
|
9975
10024
|
}>]>, z.ZodObject<{
|
|
9976
10025
|
type: z.ZodLiteral<"group">;
|
|
9977
10026
|
direction: z.ZodEnum<["row", "stack"]>;
|
|
@@ -11528,6 +11577,12 @@ declare const AppBlockSchema: z.ZodUnion<[z.ZodDiscriminatedUnion<"type", [z.Zod
|
|
|
11528
11577
|
width: z.ZodNumber;
|
|
11529
11578
|
height: z.ZodNumber;
|
|
11530
11579
|
scale: z.ZodDefault<z.ZodNumber>;
|
|
11580
|
+
/**
|
|
11581
|
+
* What kind of file `asset` names: `spr`, the palette file the retro look
|
|
11582
|
+
* uses, or `jpeg`, the full-colour rendition (drawn at scale 1). Absent means
|
|
11583
|
+
* `spr`, which is every image block written before full colour existed.
|
|
11584
|
+
*/
|
|
11585
|
+
format: z.ZodDefault<z.ZodEnum<["spr", "jpeg"]>>;
|
|
11531
11586
|
align: z.ZodDefault<z.ZodEnum<["start", "center", "end"]>>;
|
|
11532
11587
|
/** Drawn only when this is false, or absent. */
|
|
11533
11588
|
hideWhen: z.ZodOptional<z.ZodObject<{
|
|
@@ -11575,6 +11630,7 @@ declare const AppBlockSchema: z.ZodUnion<[z.ZodDiscriminatedUnion<"type", [z.Zod
|
|
|
11575
11630
|
height: number;
|
|
11576
11631
|
asset: string;
|
|
11577
11632
|
scale: number;
|
|
11633
|
+
format: "spr" | "jpeg";
|
|
11578
11634
|
hideWhen?: {
|
|
11579
11635
|
value: {
|
|
11580
11636
|
literal: number;
|
|
@@ -11602,6 +11658,7 @@ declare const AppBlockSchema: z.ZodUnion<[z.ZodDiscriminatedUnion<"type", [z.Zod
|
|
|
11602
11658
|
than: string | number | boolean;
|
|
11603
11659
|
} | undefined;
|
|
11604
11660
|
scale?: number | undefined;
|
|
11661
|
+
format?: "spr" | "jpeg" | undefined;
|
|
11605
11662
|
}>]>, "many">;
|
|
11606
11663
|
}, "strip", z.ZodTypeAny, {
|
|
11607
11664
|
type: "group";
|
|
@@ -11876,6 +11933,7 @@ declare const AppBlockSchema: z.ZodUnion<[z.ZodDiscriminatedUnion<"type", [z.Zod
|
|
|
11876
11933
|
height: number;
|
|
11877
11934
|
asset: string;
|
|
11878
11935
|
scale: number;
|
|
11936
|
+
format: "spr" | "jpeg";
|
|
11879
11937
|
hideWhen?: {
|
|
11880
11938
|
value: {
|
|
11881
11939
|
literal: number;
|
|
@@ -12168,6 +12226,7 @@ declare const AppBlockSchema: z.ZodUnion<[z.ZodDiscriminatedUnion<"type", [z.Zod
|
|
|
12168
12226
|
than: string | number | boolean;
|
|
12169
12227
|
} | undefined;
|
|
12170
12228
|
scale?: number | undefined;
|
|
12229
|
+
format?: "spr" | "jpeg" | undefined;
|
|
12171
12230
|
})[];
|
|
12172
12231
|
align?: "start" | "center" | "end" | undefined;
|
|
12173
12232
|
gap?: number | undefined;
|
|
@@ -13821,6 +13880,12 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
13821
13880
|
width: z.ZodNumber;
|
|
13822
13881
|
height: z.ZodNumber;
|
|
13823
13882
|
scale: z.ZodDefault<z.ZodNumber>;
|
|
13883
|
+
/**
|
|
13884
|
+
* What kind of file `asset` names: `spr`, the palette file the retro look
|
|
13885
|
+
* uses, or `jpeg`, the full-colour rendition (drawn at scale 1). Absent means
|
|
13886
|
+
* `spr`, which is every image block written before full colour existed.
|
|
13887
|
+
*/
|
|
13888
|
+
format: z.ZodDefault<z.ZodEnum<["spr", "jpeg"]>>;
|
|
13824
13889
|
align: z.ZodDefault<z.ZodEnum<["start", "center", "end"]>>;
|
|
13825
13890
|
/** Drawn only when this is false, or absent. */
|
|
13826
13891
|
hideWhen: z.ZodOptional<z.ZodObject<{
|
|
@@ -13868,6 +13933,7 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
13868
13933
|
height: number;
|
|
13869
13934
|
asset: string;
|
|
13870
13935
|
scale: number;
|
|
13936
|
+
format: "spr" | "jpeg";
|
|
13871
13937
|
hideWhen?: {
|
|
13872
13938
|
value: {
|
|
13873
13939
|
literal: number;
|
|
@@ -13895,6 +13961,7 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
13895
13961
|
than: string | number | boolean;
|
|
13896
13962
|
} | undefined;
|
|
13897
13963
|
scale?: number | undefined;
|
|
13964
|
+
format?: "spr" | "jpeg" | undefined;
|
|
13898
13965
|
}>]>, z.ZodObject<{
|
|
13899
13966
|
type: z.ZodLiteral<"group">;
|
|
13900
13967
|
direction: z.ZodEnum<["row", "stack"]>;
|
|
@@ -15451,6 +15518,12 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
15451
15518
|
width: z.ZodNumber;
|
|
15452
15519
|
height: z.ZodNumber;
|
|
15453
15520
|
scale: z.ZodDefault<z.ZodNumber>;
|
|
15521
|
+
/**
|
|
15522
|
+
* What kind of file `asset` names: `spr`, the palette file the retro look
|
|
15523
|
+
* uses, or `jpeg`, the full-colour rendition (drawn at scale 1). Absent means
|
|
15524
|
+
* `spr`, which is every image block written before full colour existed.
|
|
15525
|
+
*/
|
|
15526
|
+
format: z.ZodDefault<z.ZodEnum<["spr", "jpeg"]>>;
|
|
15454
15527
|
align: z.ZodDefault<z.ZodEnum<["start", "center", "end"]>>;
|
|
15455
15528
|
/** Drawn only when this is false, or absent. */
|
|
15456
15529
|
hideWhen: z.ZodOptional<z.ZodObject<{
|
|
@@ -15498,6 +15571,7 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
15498
15571
|
height: number;
|
|
15499
15572
|
asset: string;
|
|
15500
15573
|
scale: number;
|
|
15574
|
+
format: "spr" | "jpeg";
|
|
15501
15575
|
hideWhen?: {
|
|
15502
15576
|
value: {
|
|
15503
15577
|
literal: number;
|
|
@@ -15525,6 +15599,7 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
15525
15599
|
than: string | number | boolean;
|
|
15526
15600
|
} | undefined;
|
|
15527
15601
|
scale?: number | undefined;
|
|
15602
|
+
format?: "spr" | "jpeg" | undefined;
|
|
15528
15603
|
}>]>, "many">;
|
|
15529
15604
|
}, "strip", z.ZodTypeAny, {
|
|
15530
15605
|
type: "group";
|
|
@@ -15799,6 +15874,7 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
15799
15874
|
height: number;
|
|
15800
15875
|
asset: string;
|
|
15801
15876
|
scale: number;
|
|
15877
|
+
format: "spr" | "jpeg";
|
|
15802
15878
|
hideWhen?: {
|
|
15803
15879
|
value: {
|
|
15804
15880
|
literal: number;
|
|
@@ -16091,6 +16167,7 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
16091
16167
|
than: string | number | boolean;
|
|
16092
16168
|
} | undefined;
|
|
16093
16169
|
scale?: number | undefined;
|
|
16170
|
+
format?: "spr" | "jpeg" | undefined;
|
|
16094
16171
|
})[];
|
|
16095
16172
|
align?: "start" | "center" | "end" | undefined;
|
|
16096
16173
|
gap?: number | undefined;
|
|
@@ -16366,6 +16443,7 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
16366
16443
|
height: number;
|
|
16367
16444
|
asset: string;
|
|
16368
16445
|
scale: number;
|
|
16446
|
+
format: "spr" | "jpeg";
|
|
16369
16447
|
hideWhen?: {
|
|
16370
16448
|
value: {
|
|
16371
16449
|
literal: number;
|
|
@@ -16649,6 +16727,7 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
16649
16727
|
height: number;
|
|
16650
16728
|
asset: string;
|
|
16651
16729
|
scale: number;
|
|
16730
|
+
format: "spr" | "jpeg";
|
|
16652
16731
|
hideWhen?: {
|
|
16653
16732
|
value: {
|
|
16654
16733
|
literal: number;
|
|
@@ -16968,6 +17047,7 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
16968
17047
|
than: string | number | boolean;
|
|
16969
17048
|
} | undefined;
|
|
16970
17049
|
scale?: number | undefined;
|
|
17050
|
+
format?: "spr" | "jpeg" | undefined;
|
|
16971
17051
|
} | {
|
|
16972
17052
|
type: "group";
|
|
16973
17053
|
direction: "stack" | "row";
|
|
@@ -17249,6 +17329,7 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
17249
17329
|
than: string | number | boolean;
|
|
17250
17330
|
} | undefined;
|
|
17251
17331
|
scale?: number | undefined;
|
|
17332
|
+
format?: "spr" | "jpeg" | undefined;
|
|
17252
17333
|
})[];
|
|
17253
17334
|
align?: "start" | "center" | "end" | undefined;
|
|
17254
17335
|
gap?: number | undefined;
|
|
@@ -17550,6 +17631,7 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
17550
17631
|
height: number;
|
|
17551
17632
|
asset: string;
|
|
17552
17633
|
scale: number;
|
|
17634
|
+
format: "spr" | "jpeg";
|
|
17553
17635
|
hideWhen?: {
|
|
17554
17636
|
value: {
|
|
17555
17637
|
literal: number;
|
|
@@ -17833,6 +17915,7 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
17833
17915
|
height: number;
|
|
17834
17916
|
asset: string;
|
|
17835
17917
|
scale: number;
|
|
17918
|
+
format: "spr" | "jpeg";
|
|
17836
17919
|
hideWhen?: {
|
|
17837
17920
|
value: {
|
|
17838
17921
|
literal: number;
|
|
@@ -18152,6 +18235,7 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
18152
18235
|
than: string | number | boolean;
|
|
18153
18236
|
} | undefined;
|
|
18154
18237
|
scale?: number | undefined;
|
|
18238
|
+
format?: "spr" | "jpeg" | undefined;
|
|
18155
18239
|
} | {
|
|
18156
18240
|
type: "group";
|
|
18157
18241
|
direction: "stack" | "row";
|
|
@@ -18433,6 +18517,7 @@ declare const AppDocumentSchema: z.ZodEffects<z.ZodObject<{
|
|
|
18433
18517
|
than: string | number | boolean;
|
|
18434
18518
|
} | undefined;
|
|
18435
18519
|
scale?: number | undefined;
|
|
18520
|
+
format?: "spr" | "jpeg" | undefined;
|
|
18436
18521
|
})[];
|
|
18437
18522
|
align?: "start" | "center" | "end" | undefined;
|
|
18438
18523
|
gap?: number | undefined;
|
|
@@ -18516,16 +18601,93 @@ declare const PHOTOS_PER_ACCOUNT = 50;
|
|
|
18516
18601
|
/** Uploads per account per hour. Generous for a person; a wall for a script. */
|
|
18517
18602
|
declare const PHOTO_UPLOADS_PER_HOUR = 30;
|
|
18518
18603
|
/** What the Studio sends: both files, base64. */
|
|
18604
|
+
/**
|
|
18605
|
+
* Where in the original the board's picture was cropped from, as fractions of
|
|
18606
|
+
* its width and height, and whether it was mirrored. Kept so a rendition made
|
|
18607
|
+
* later from the original — full colour for a photo first saved retro — frames
|
|
18608
|
+
* the picture the way its owner chose. Photos saved before this existed have
|
|
18609
|
+
* none and are centred.
|
|
18610
|
+
*/
|
|
18611
|
+
declare const PhotoCropSchema: z.ZodObject<{
|
|
18612
|
+
x: z.ZodNumber;
|
|
18613
|
+
y: z.ZodNumber;
|
|
18614
|
+
w: z.ZodNumber;
|
|
18615
|
+
h: z.ZodNumber;
|
|
18616
|
+
mirror: z.ZodDefault<z.ZodBoolean>;
|
|
18617
|
+
}, "strip", z.ZodTypeAny, {
|
|
18618
|
+
x: number;
|
|
18619
|
+
y: number;
|
|
18620
|
+
w: number;
|
|
18621
|
+
h: number;
|
|
18622
|
+
mirror: boolean;
|
|
18623
|
+
}, {
|
|
18624
|
+
x: number;
|
|
18625
|
+
y: number;
|
|
18626
|
+
w: number;
|
|
18627
|
+
h: number;
|
|
18628
|
+
mirror?: boolean | undefined;
|
|
18629
|
+
}>;
|
|
18519
18630
|
declare const PhotoUploadSchema: z.ZodObject<{
|
|
18520
18631
|
rendition: z.ZodString;
|
|
18521
18632
|
original: z.ZodString;
|
|
18633
|
+
/** The full-colour rendition (FULL_RENDITION), base64 JPEG. Optional for older clients. */
|
|
18634
|
+
full: z.ZodOptional<z.ZodString>;
|
|
18635
|
+
crop: z.ZodOptional<z.ZodObject<{
|
|
18636
|
+
x: z.ZodNumber;
|
|
18637
|
+
y: z.ZodNumber;
|
|
18638
|
+
w: z.ZodNumber;
|
|
18639
|
+
h: z.ZodNumber;
|
|
18640
|
+
mirror: z.ZodDefault<z.ZodBoolean>;
|
|
18641
|
+
}, "strip", z.ZodTypeAny, {
|
|
18642
|
+
x: number;
|
|
18643
|
+
y: number;
|
|
18644
|
+
w: number;
|
|
18645
|
+
h: number;
|
|
18646
|
+
mirror: boolean;
|
|
18647
|
+
}, {
|
|
18648
|
+
x: number;
|
|
18649
|
+
y: number;
|
|
18650
|
+
w: number;
|
|
18651
|
+
h: number;
|
|
18652
|
+
mirror?: boolean | undefined;
|
|
18653
|
+
}>>;
|
|
18522
18654
|
}, "strip", z.ZodTypeAny, {
|
|
18523
18655
|
rendition: string;
|
|
18524
18656
|
original: string;
|
|
18657
|
+
full?: string | undefined;
|
|
18658
|
+
crop?: {
|
|
18659
|
+
x: number;
|
|
18660
|
+
y: number;
|
|
18661
|
+
w: number;
|
|
18662
|
+
h: number;
|
|
18663
|
+
mirror: boolean;
|
|
18664
|
+
} | undefined;
|
|
18525
18665
|
}, {
|
|
18526
18666
|
rendition: string;
|
|
18527
18667
|
original: string;
|
|
18668
|
+
full?: string | undefined;
|
|
18669
|
+
crop?: {
|
|
18670
|
+
x: number;
|
|
18671
|
+
y: number;
|
|
18672
|
+
w: number;
|
|
18673
|
+
h: number;
|
|
18674
|
+
mirror?: boolean | undefined;
|
|
18675
|
+
} | undefined;
|
|
18528
18676
|
}>;
|
|
18677
|
+
/** Adding a full-colour rendition to a photo saved without one. */
|
|
18678
|
+
declare const PhotoFullSchema: z.ZodObject<{
|
|
18679
|
+
full: z.ZodString;
|
|
18680
|
+
}, "strip", z.ZodTypeAny, {
|
|
18681
|
+
full: string;
|
|
18682
|
+
}, {
|
|
18683
|
+
full: string;
|
|
18684
|
+
}>;
|
|
18685
|
+
/**
|
|
18686
|
+
* How many photos a full-colour photo frame holds. A CYD keeps about 128KB of
|
|
18687
|
+
* photos and a full-colour one is 20-25KB, against ~2KB retro — so four, where
|
|
18688
|
+
* retro allows PHOTO_FRAME_MAX in the Studio's settings.
|
|
18689
|
+
*/
|
|
18690
|
+
declare const FULL_COLOUR_FRAME_MAX = 4;
|
|
18529
18691
|
/** One photo, as its owner sees it in a list. Never the bytes. */
|
|
18530
18692
|
declare const PhotoSummarySchema: z.ZodObject<{
|
|
18531
18693
|
hash: z.ZodString;
|
|
@@ -18537,6 +18699,36 @@ declare const PhotoSummarySchema: z.ZodObject<{
|
|
|
18537
18699
|
originalHeight: z.ZodNumber;
|
|
18538
18700
|
originalBytes: z.ZodNumber;
|
|
18539
18701
|
uploadedAt: z.ZodNumber;
|
|
18702
|
+
/** The full-colour rendition, when one has been made. Its own hash names it. */
|
|
18703
|
+
full: z.ZodOptional<z.ZodObject<{
|
|
18704
|
+
hash: z.ZodString;
|
|
18705
|
+
bytes: z.ZodNumber;
|
|
18706
|
+
}, "strip", z.ZodTypeAny, {
|
|
18707
|
+
hash: string;
|
|
18708
|
+
bytes: number;
|
|
18709
|
+
}, {
|
|
18710
|
+
hash: string;
|
|
18711
|
+
bytes: number;
|
|
18712
|
+
}>>;
|
|
18713
|
+
crop: z.ZodOptional<z.ZodObject<{
|
|
18714
|
+
x: z.ZodNumber;
|
|
18715
|
+
y: z.ZodNumber;
|
|
18716
|
+
w: z.ZodNumber;
|
|
18717
|
+
h: z.ZodNumber;
|
|
18718
|
+
mirror: z.ZodDefault<z.ZodBoolean>;
|
|
18719
|
+
}, "strip", z.ZodTypeAny, {
|
|
18720
|
+
x: number;
|
|
18721
|
+
y: number;
|
|
18722
|
+
w: number;
|
|
18723
|
+
h: number;
|
|
18724
|
+
mirror: boolean;
|
|
18725
|
+
}, {
|
|
18726
|
+
x: number;
|
|
18727
|
+
y: number;
|
|
18728
|
+
w: number;
|
|
18729
|
+
h: number;
|
|
18730
|
+
mirror?: boolean | undefined;
|
|
18731
|
+
}>>;
|
|
18540
18732
|
}, "strip", z.ZodTypeAny, {
|
|
18541
18733
|
width: number;
|
|
18542
18734
|
height: number;
|
|
@@ -18546,6 +18738,17 @@ declare const PhotoSummarySchema: z.ZodObject<{
|
|
|
18546
18738
|
originalHeight: number;
|
|
18547
18739
|
originalBytes: number;
|
|
18548
18740
|
uploadedAt: number;
|
|
18741
|
+
full?: {
|
|
18742
|
+
hash: string;
|
|
18743
|
+
bytes: number;
|
|
18744
|
+
} | undefined;
|
|
18745
|
+
crop?: {
|
|
18746
|
+
x: number;
|
|
18747
|
+
y: number;
|
|
18748
|
+
w: number;
|
|
18749
|
+
h: number;
|
|
18750
|
+
mirror: boolean;
|
|
18751
|
+
} | undefined;
|
|
18549
18752
|
}, {
|
|
18550
18753
|
width: number;
|
|
18551
18754
|
height: number;
|
|
@@ -18555,9 +18758,21 @@ declare const PhotoSummarySchema: z.ZodObject<{
|
|
|
18555
18758
|
originalHeight: number;
|
|
18556
18759
|
originalBytes: number;
|
|
18557
18760
|
uploadedAt: number;
|
|
18761
|
+
full?: {
|
|
18762
|
+
hash: string;
|
|
18763
|
+
bytes: number;
|
|
18764
|
+
} | undefined;
|
|
18765
|
+
crop?: {
|
|
18766
|
+
x: number;
|
|
18767
|
+
y: number;
|
|
18768
|
+
w: number;
|
|
18769
|
+
h: number;
|
|
18770
|
+
mirror?: boolean | undefined;
|
|
18771
|
+
} | undefined;
|
|
18558
18772
|
}>;
|
|
18559
18773
|
type PhotoUpload = z.infer<typeof PhotoUploadSchema>;
|
|
18560
18774
|
type PhotoSummary = z.infer<typeof PhotoSummarySchema>;
|
|
18775
|
+
type PhotoCrop = z.infer<typeof PhotoCropSchema>;
|
|
18561
18776
|
|
|
18562
18777
|
/**
|
|
18563
18778
|
* @file delivery.ts
|
|
@@ -18839,15 +19054,15 @@ declare const FirmwareUpdateSchema: z.ZodObject<{
|
|
|
18839
19054
|
requestedAt: z.ZodNumber;
|
|
18840
19055
|
}, "strip", z.ZodTypeAny, {
|
|
18841
19056
|
version: string;
|
|
19057
|
+
bytes: number;
|
|
18842
19058
|
url: string;
|
|
18843
19059
|
sha256: string;
|
|
18844
|
-
bytes: number;
|
|
18845
19060
|
requestedAt: number;
|
|
18846
19061
|
}, {
|
|
18847
19062
|
version: string;
|
|
19063
|
+
bytes: number;
|
|
18848
19064
|
url: string;
|
|
18849
19065
|
sha256: string;
|
|
18850
|
-
bytes: number;
|
|
18851
19066
|
requestedAt: number;
|
|
18852
19067
|
}>;
|
|
18853
19068
|
type FirmwareUpdate = z.infer<typeof FirmwareUpdateSchema>;
|
|
@@ -19868,14 +20083,14 @@ declare const ThemeTokensSchema: z.ZodObject<{
|
|
|
19868
20083
|
primary: string;
|
|
19869
20084
|
neutral: string;
|
|
19870
20085
|
destructive: string;
|
|
19871
|
-
radius: "sm" | "lg" | "
|
|
20086
|
+
radius: "sm" | "lg" | "full" | "none" | "md";
|
|
19872
20087
|
}, {
|
|
19873
20088
|
warning: string;
|
|
19874
20089
|
success: string;
|
|
19875
20090
|
primary: string;
|
|
19876
20091
|
neutral: string;
|
|
19877
20092
|
destructive: string;
|
|
19878
|
-
radius: "sm" | "lg" | "
|
|
20093
|
+
radius: "sm" | "lg" | "full" | "none" | "md";
|
|
19879
20094
|
}>;
|
|
19880
20095
|
type ThemeTokens = z.infer<typeof ThemeTokensSchema>;
|
|
19881
20096
|
declare const DEFAULT_THEME_TOKENS: ThemeTokens;
|
|
@@ -21026,4 +21241,4 @@ declare const DEFAULT_HORIZON_QUARTERS = 5;
|
|
|
21026
21241
|
*/
|
|
21027
21242
|
declare const EXCLUDED_SOURCES: Record<string, string>;
|
|
21028
21243
|
|
|
21029
|
-
export { ACCESS_REQUEST_TTL_SECONDS, ACCOUNT_TTL_SECONDS, type AIKeyManifest, AIKeyManifestSchema, type AITheme, AIThemeSchema, AI_ROSTER, AI_TOOLS, APP_DOCUMENT_EDIT_PREFIX, APP_DOCUMENT_SYSTEM_PROMPT, ASSISTANT_MODEL, ASSISTANT_PROVIDER, type AccessRequest, type AccessRequestRecord, AccessRequestRecordSchema, AccessRequestSchema, type AccessRequestStatus, AccessRequestStatusSchema, type AccountId, AccountIdSchema, type AccountRecord, AccountRecordSchema, type AccountRole, AccountRoleSchema, type AccountStatus, AccountStatusSchema, type ActionDefinition, ActionSchema, type AgentRoleConfig, type AgentRoleKey, AircraftAppConfigSchema, type AppAlign, AppAlignSchema, AppBarSchema, type AppBinding, AppBindingSchema, type AppBlock, AppBlockSchema, type AppColor, AppColorSchema, type AppColorToken, AppColorTokenSchema, type AppCompute, AppComputeSchema, type AppCondition, AppConditionSchema, AppDialSchema, type AppDocument, AppDocumentSchema, type AppGroup, AppGroupSchema, type AppImage, AppImageSchema, type AppLeaf, AppLeafSchema, type AppOperand, AppOperandSchema, AppRgbSchema, type AppScreenSize, AppScreenSizeSchema, AppSignalSchema, type AppSource, AppSourceSchema, AppSparklineSchema, type AppSpecification, AppSpecificationSchema, AppSpriteSchema, AppStatusSchema, type AppStyleRule, AppStyleRuleSchema, AppTextSchema, type AppTextSize, AppTextSizeSchema, type ArchitectureReferenceParams, AssetHashSchema, AuthStrategySchema, type Block, BlockSchema, schema as Bodewell, CLAIMED_DEVICE_TTL_SECONDS, ClockAppConfigSchema, type CompanyNewsParams, type CompanyProfileParams, type CounterpartyGraphParams, type CounterpartyNode, CounterpartyNodeSchema, type CounterpartyResolution, CounterpartyResolutionSchema, type CounterpartyType, CounterpartyTypeSchema, DEFAULT_CHAT_MODEL, DEFAULT_DEVICE_CONFIG, DEFAULT_HORIZON_QUARTERS, DEFAULT_PRO_MODEL, DEFAULT_SCHEMA_MODEL, DEFAULT_THEME_TOKENS, DEVICE_AP_SSID_PREFIX, DEVICE_ENDPOINTS, DEVICE_FRESH_MS, DEVICE_GLYPHS, DEVICE_LABEL_MAX, DEVICE_PALETTE, DEVICE_STALE_MS, DEVICE_TIMEZONES, DEVICE_TIMEZONE_FALLBACK, DEVICE_TTL_SECONDS, DEVICE_UNKNOWN_GLYPH, DEVICE_VITALS_FIELDS, type DailyPricePoint, DailyPricePointSchema, type DeliveredApp, DeliveredAppSchema, type DeviceAppId, DeviceAppIdSchema, DeviceAppsSchema, type DeviceConfig, DeviceConfigSchema, DeviceDisplayConfigSchema, type DeviceGlyph, type DeviceId, DeviceIdSchema, type DeviceKind, DeviceKindSchema, type DeviceRecord, DeviceRecordSchema, type DeviceRegistration, DeviceRegistrationSchema, type DeviceSeen, DeviceSeenSchema, type DeviceStatus, DeviceStatusSchema, DeviceThemeSchema, type DeviceTimeZone, type DeviceVitals, DeviceVitalsSchema, type DivergenceMetric, DivergenceMetricSchema, type DivergenceMetricsParams, EVENT_KIND_LABELS, EXCLUDED_SOURCES, type EntityDefinition, type EntityEvent, type EntityEventDensity, type EntityEventDensityBucket, EntityEventDensityBucketSchema, EntityEventDensitySchema, type EntityEventFacet, EntityEventFacetSchema, type EntityEventFacets, EntityEventFacetsSchema, type EntityEventKind, EntityEventKindSchema, EntityEventSchema, type EntityPriceSeries, EntityPriceSeriesSchema, EntitySchema, type EventBucketSize, EventBucketSizeSchema, type EventSource, EventSourceSchema, FIRMWARE_UPDATE_ATTEMPTS, FIRMWARE_UPDATE_PREFIX, type FieldDefinition, FieldSchema, type FirmwareUpdate, FirmwareUpdateSchema, type FloraTelemetry, FloraTelemetrySchema, GENESIS_LIBRARY_CONTEXT, GENESIS_VALID_COMPONENTS, type GenesisComponentType, IMAGE_MAX_DRAWN, IMAGE_MAX_SCALE, IMPACT_FLAG_THRESHOLD, INVITE_TTL_SECONDS, type ImpactScale, ImpactScaleSchema, type InviteRecord, InviteRecordSchema, type LiveQuoteParams, MAX_PASSWORD_LENGTH, MIN_PASSWORD_LENGTH, type NonPublicEntity, NonPublicEntitySchema, ORIGINAL_MAX_BYTES, ORIGINAL_MAX_SIDE, type OwnedSendRequest, OwnedSendRequestSchema, PHOTOS_PER_ACCOUNT, PHOTO_UPLOADS_PER_HOUR, PROVIDER_DEFAULT_MODEL, type PageDefinition, PageSchema, type PageSection, PageSectionSchema, type PaginatedEntityEvents, PaginatedEntityEventsSchema, type PairCode, PairCodeSchema, type PhotoSummary, PhotoSummarySchema, type PhotoUpload, PhotoUploadSchema, type ProviderDefaultModelKey, type ProvisioningState, ProvisioningStateSchema, type PublicAccount, PublicAccountSchema, RETRO_RENDITION, type RelationshipEdge, RelationshipEdgeSchema, type RelationshipEdgeType, RelationshipEdgeTypeSchema, type ResourceDefinition, ResourceSchema, SCRYPT_PARAMS, SENTIMENT_NEUTRAL, SESSION_COOKIE_NAME, SESSION_TTL_SECONDS, SIGNAL_DOMAINS, SIGNAL_KINDS, SIGNAL_KIND_LABELS, SIGNAL_SOURCES, SPRITE_MAX_BASE64, SPRITE_MAX_ROW_BYTES, SPRITE_MAX_SIDE, SPR_FORMAT, SPR_MAX_BYTES, type ScryptHash, ScryptHashSchema, type SendRequest, SendRequestSchema, SensorAppConfigSchema, type SessionRecord, SessionRecordSchema, type Signal, type SignalArray, SignalArraySchema, type SignalDefinition, type SignalDomain, type SignalKind, SignalKindSchema, type SignalPacket, SignalPacketSchema, SignalSchema, type SignalSource, SignalSourceSchema, type SignalWeight, SignalWeightSchema, type StockChartParams, THEME_PRESETS, THEME_SYSTEM_PROMPT, type TelemetryGraphParams, type ThemeFonts, ThemeFontsSchema, type ThemeOverrides, ThemeOverridesSchema, type ThemePreset, type ThemeTokens, ThemeTokensSchema, type TimestampPrecision, TimestampPrecisionSchema, type ToolCall, type ToolDefinition, TriggerSchema, type User, UserSchema, type VitalSource, VitalSourceSchema, WeatherAppConfigSchema, type WorkflowDefinition, WorkflowSchema, architectureReferenceParameters, companyNewsParameters, companyProfileParameters, counterpartyGraphParameters, divergenceMetricsParameters, liveQuoteParameters, stockChartParameters, telemetryGraphParameters };
|
|
21244
|
+
export { ACCESS_REQUEST_TTL_SECONDS, ACCOUNT_TTL_SECONDS, type AIKeyManifest, AIKeyManifestSchema, type AITheme, AIThemeSchema, AI_ROSTER, AI_TOOLS, APP_DOCUMENT_EDIT_PREFIX, APP_DOCUMENT_SYSTEM_PROMPT, ASSISTANT_MODEL, ASSISTANT_PROVIDER, type AccessRequest, type AccessRequestRecord, AccessRequestRecordSchema, AccessRequestSchema, type AccessRequestStatus, AccessRequestStatusSchema, type AccountId, AccountIdSchema, type AccountRecord, AccountRecordSchema, type AccountRole, AccountRoleSchema, type AccountStatus, AccountStatusSchema, type ActionDefinition, ActionSchema, type AgentRoleConfig, type AgentRoleKey, AircraftAppConfigSchema, type AppAlign, AppAlignSchema, AppBarSchema, type AppBinding, AppBindingSchema, type AppBlock, AppBlockSchema, type AppColor, AppColorSchema, type AppColorToken, AppColorTokenSchema, type AppCompute, AppComputeSchema, type AppCondition, AppConditionSchema, AppDialSchema, type AppDocument, AppDocumentSchema, type AppGroup, AppGroupSchema, type AppImage, AppImageSchema, type AppLeaf, AppLeafSchema, type AppOperand, AppOperandSchema, AppRgbSchema, type AppScreenSize, AppScreenSizeSchema, AppSignalSchema, type AppSource, AppSourceSchema, AppSparklineSchema, type AppSpecification, AppSpecificationSchema, AppSpriteSchema, AppStatusSchema, type AppStyleRule, AppStyleRuleSchema, AppTextSchema, type AppTextSize, AppTextSizeSchema, type ArchitectureReferenceParams, AssetHashSchema, AuthStrategySchema, type Block, BlockSchema, schema as Bodewell, CLAIMED_DEVICE_TTL_SECONDS, ClockAppConfigSchema, type CompanyNewsParams, type CompanyProfileParams, type CounterpartyGraphParams, type CounterpartyNode, CounterpartyNodeSchema, type CounterpartyResolution, CounterpartyResolutionSchema, type CounterpartyType, CounterpartyTypeSchema, DEFAULT_CHAT_MODEL, DEFAULT_DEVICE_CONFIG, DEFAULT_HORIZON_QUARTERS, DEFAULT_PRO_MODEL, DEFAULT_SCHEMA_MODEL, DEFAULT_THEME_TOKENS, DEVICE_AP_SSID_PREFIX, DEVICE_ENDPOINTS, DEVICE_FRESH_MS, DEVICE_GLYPHS, DEVICE_LABEL_MAX, DEVICE_PALETTE, DEVICE_STALE_MS, DEVICE_TIMEZONES, DEVICE_TIMEZONE_FALLBACK, DEVICE_TTL_SECONDS, DEVICE_UNKNOWN_GLYPH, DEVICE_VITALS_FIELDS, type DailyPricePoint, DailyPricePointSchema, type DeliveredApp, DeliveredAppSchema, type DeviceAppId, DeviceAppIdSchema, DeviceAppsSchema, type DeviceConfig, DeviceConfigSchema, DeviceDisplayConfigSchema, type DeviceGlyph, type DeviceId, DeviceIdSchema, type DeviceKind, DeviceKindSchema, type DeviceRecord, DeviceRecordSchema, type DeviceRegistration, DeviceRegistrationSchema, type DeviceSeen, DeviceSeenSchema, type DeviceStatus, DeviceStatusSchema, DeviceThemeSchema, type DeviceTimeZone, type DeviceVitals, DeviceVitalsSchema, type DivergenceMetric, DivergenceMetricSchema, type DivergenceMetricsParams, EVENT_KIND_LABELS, EXCLUDED_SOURCES, type EntityDefinition, type EntityEvent, type EntityEventDensity, type EntityEventDensityBucket, EntityEventDensityBucketSchema, EntityEventDensitySchema, type EntityEventFacet, EntityEventFacetSchema, type EntityEventFacets, EntityEventFacetsSchema, type EntityEventKind, EntityEventKindSchema, EntityEventSchema, type EntityPriceSeries, EntityPriceSeriesSchema, EntitySchema, type EventBucketSize, EventBucketSizeSchema, type EventSource, EventSourceSchema, FIRMWARE_UPDATE_ATTEMPTS, FIRMWARE_UPDATE_PREFIX, FULL_COLOUR_FRAME_MAX, FULL_RENDITION, type FieldDefinition, FieldSchema, type FirmwareUpdate, FirmwareUpdateSchema, type FloraTelemetry, FloraTelemetrySchema, GENESIS_LIBRARY_CONTEXT, GENESIS_VALID_COMPONENTS, type GenesisComponentType, IMAGE_MAX_DRAWN, IMAGE_MAX_SCALE, IMPACT_FLAG_THRESHOLD, INVITE_TTL_SECONDS, type ImpactScale, ImpactScaleSchema, type InviteRecord, InviteRecordSchema, type LiveQuoteParams, MAX_PASSWORD_LENGTH, MIN_PASSWORD_LENGTH, type NonPublicEntity, NonPublicEntitySchema, ORIGINAL_MAX_BYTES, ORIGINAL_MAX_SIDE, type OwnedSendRequest, OwnedSendRequestSchema, PHOTOS_PER_ACCOUNT, PHOTO_UPLOADS_PER_HOUR, PROVIDER_DEFAULT_MODEL, type PageDefinition, PageSchema, type PageSection, PageSectionSchema, type PaginatedEntityEvents, PaginatedEntityEventsSchema, type PairCode, PairCodeSchema, type PhotoCrop, PhotoCropSchema, PhotoFullSchema, type PhotoSummary, PhotoSummarySchema, type PhotoUpload, PhotoUploadSchema, type ProviderDefaultModelKey, type ProvisioningState, ProvisioningStateSchema, type PublicAccount, PublicAccountSchema, RETRO_RENDITION, type RelationshipEdge, RelationshipEdgeSchema, type RelationshipEdgeType, RelationshipEdgeTypeSchema, type ResourceDefinition, ResourceSchema, SCRYPT_PARAMS, SENTIMENT_NEUTRAL, SESSION_COOKIE_NAME, SESSION_TTL_SECONDS, SIGNAL_DOMAINS, SIGNAL_KINDS, SIGNAL_KIND_LABELS, SIGNAL_SOURCES, SPRITE_MAX_BASE64, SPRITE_MAX_ROW_BYTES, SPRITE_MAX_SIDE, SPR_FORMAT, SPR_MAX_BYTES, type ScryptHash, ScryptHashSchema, type SendRequest, SendRequestSchema, SensorAppConfigSchema, type SessionRecord, SessionRecordSchema, type Signal, type SignalArray, SignalArraySchema, type SignalDefinition, type SignalDomain, type SignalKind, SignalKindSchema, type SignalPacket, SignalPacketSchema, SignalSchema, type SignalSource, SignalSourceSchema, type SignalWeight, SignalWeightSchema, type StockChartParams, THEME_PRESETS, THEME_SYSTEM_PROMPT, type TelemetryGraphParams, type ThemeFonts, ThemeFontsSchema, type ThemeOverrides, ThemeOverridesSchema, type ThemePreset, type ThemeTokens, ThemeTokensSchema, type TimestampPrecision, TimestampPrecisionSchema, type ToolCall, type ToolDefinition, TriggerSchema, type User, UserSchema, type VitalSource, VitalSourceSchema, WeatherAppConfigSchema, type WorkflowDefinition, WorkflowSchema, architectureReferenceParameters, companyNewsParameters, companyProfileParameters, counterpartyGraphParameters, divergenceMetricsParameters, liveQuoteParameters, stockChartParameters, telemetryGraphParameters };
|
package/dist/index.js
CHANGED
|
@@ -560,6 +560,7 @@ var AssetHashSchema = z6.string().regex(/^[0-9a-f]{64}$/, "a lowercase hex SHA-2
|
|
|
560
560
|
var IMAGE_MAX_DRAWN = { width: 304, height: 224 };
|
|
561
561
|
var IMAGE_MAX_SCALE = 8;
|
|
562
562
|
var RETRO_RENDITION = { width: 76, height: 56, scale: 4, colors: 16 };
|
|
563
|
+
var FULL_RENDITION = { width: 304, height: 224, quality: 0.82, maxBytes: 48e3 };
|
|
563
564
|
var SPR_FORMAT = {
|
|
564
565
|
/** "RSPR". */
|
|
565
566
|
magic: [82, 83, 80, 82],
|
|
@@ -578,6 +579,12 @@ var AppImageSchema = z6.object({
|
|
|
578
579
|
width: z6.number().int().min(1).max(IMAGE_MAX_DRAWN.width),
|
|
579
580
|
height: z6.number().int().min(1).max(IMAGE_MAX_DRAWN.height),
|
|
580
581
|
scale: z6.number().int().min(1).max(IMAGE_MAX_SCALE).default(1),
|
|
582
|
+
/**
|
|
583
|
+
* What kind of file `asset` names: `spr`, the palette file the retro look
|
|
584
|
+
* uses, or `jpeg`, the full-colour rendition (drawn at scale 1). Absent means
|
|
585
|
+
* `spr`, which is every image block written before full colour existed.
|
|
586
|
+
*/
|
|
587
|
+
format: z6.enum(["spr", "jpeg"]).default("spr"),
|
|
581
588
|
align: AppAlignSchema.default("start"),
|
|
582
589
|
/** Drawn only when this is false, or absent. */
|
|
583
590
|
hideWhen: AppConditionSchema.optional()
|
|
@@ -633,6 +640,14 @@ var AppDocumentSchema = z6.object({
|
|
|
633
640
|
const b = block;
|
|
634
641
|
if (b?.type !== "image" || !b.width || !b.height) return;
|
|
635
642
|
const scale = b.scale ?? 1;
|
|
643
|
+
if (b.format === "jpeg" && scale !== 1) {
|
|
644
|
+
ctx.addIssue({
|
|
645
|
+
code: z6.ZodIssueCode.custom,
|
|
646
|
+
path: [...path, "scale"],
|
|
647
|
+
message: "A jpeg image is drawn at scale 1; make the file the size it should appear."
|
|
648
|
+
});
|
|
649
|
+
return;
|
|
650
|
+
}
|
|
636
651
|
const w = b.width * scale;
|
|
637
652
|
const h = b.height * scale;
|
|
638
653
|
if (w <= IMAGE_MAX_DRAWN.width && h <= IMAGE_MAX_DRAWN.height) return;
|
|
@@ -661,10 +676,22 @@ var ORIGINAL_MAX_SIDE = 3072;
|
|
|
661
676
|
var ORIGINAL_MAX_BYTES = 3e6;
|
|
662
677
|
var PHOTOS_PER_ACCOUNT = 50;
|
|
663
678
|
var PHOTO_UPLOADS_PER_HOUR = 30;
|
|
679
|
+
var PhotoCropSchema = z7.object({
|
|
680
|
+
x: z7.number().min(0).max(1),
|
|
681
|
+
y: z7.number().min(0).max(1),
|
|
682
|
+
w: z7.number().gt(0).max(1),
|
|
683
|
+
h: z7.number().gt(0).max(1),
|
|
684
|
+
mirror: z7.boolean().default(false)
|
|
685
|
+
});
|
|
664
686
|
var PhotoUploadSchema = z7.object({
|
|
665
687
|
rendition: z7.string().min(4),
|
|
666
|
-
original: z7.string().min(4)
|
|
688
|
+
original: z7.string().min(4),
|
|
689
|
+
/** The full-colour rendition (FULL_RENDITION), base64 JPEG. Optional for older clients. */
|
|
690
|
+
full: z7.string().min(4).optional(),
|
|
691
|
+
crop: PhotoCropSchema.optional()
|
|
667
692
|
});
|
|
693
|
+
var PhotoFullSchema = z7.object({ full: z7.string().min(4) });
|
|
694
|
+
var FULL_COLOUR_FRAME_MAX = 4;
|
|
668
695
|
var PhotoSummarySchema = z7.object({
|
|
669
696
|
hash: AssetHashSchema,
|
|
670
697
|
/** The rendition's own pixels. */
|
|
@@ -674,7 +701,10 @@ var PhotoSummarySchema = z7.object({
|
|
|
674
701
|
originalWidth: z7.number().int().positive(),
|
|
675
702
|
originalHeight: z7.number().int().positive(),
|
|
676
703
|
originalBytes: z7.number().int().positive(),
|
|
677
|
-
uploadedAt: z7.number().int()
|
|
704
|
+
uploadedAt: z7.number().int(),
|
|
705
|
+
/** The full-colour rendition, when one has been made. Its own hash names it. */
|
|
706
|
+
full: z7.object({ hash: AssetHashSchema, bytes: z7.number().int().positive() }).optional(),
|
|
707
|
+
crop: PhotoCropSchema.optional()
|
|
678
708
|
});
|
|
679
709
|
|
|
680
710
|
// src/apps/delivery.ts
|
|
@@ -1812,6 +1842,8 @@ export {
|
|
|
1812
1842
|
EventSourceSchema,
|
|
1813
1843
|
FIRMWARE_UPDATE_ATTEMPTS,
|
|
1814
1844
|
FIRMWARE_UPDATE_PREFIX,
|
|
1845
|
+
FULL_COLOUR_FRAME_MAX,
|
|
1846
|
+
FULL_RENDITION,
|
|
1815
1847
|
FieldSchema,
|
|
1816
1848
|
FirmwareUpdateSchema,
|
|
1817
1849
|
FloraTelemetrySchema,
|
|
@@ -1836,6 +1868,8 @@ export {
|
|
|
1836
1868
|
PageSectionSchema,
|
|
1837
1869
|
PaginatedEntityEventsSchema,
|
|
1838
1870
|
PairCodeSchema,
|
|
1871
|
+
PhotoCropSchema,
|
|
1872
|
+
PhotoFullSchema,
|
|
1839
1873
|
PhotoSummarySchema,
|
|
1840
1874
|
PhotoUploadSchema,
|
|
1841
1875
|
ProvisioningStateSchema,
|