@notionhq/custom-blocks-host 0.3.7 → 0.3.8

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.
@@ -387,6 +387,30 @@ export declare const notionPagePropertyValueSchema: v.VariantSchema<"type", [v.O
387
387
  readonly id: v.StringSchema<undefined>;
388
388
  readonly type: v.LiteralSchema<"last_visited_time", undefined>;
389
389
  readonly last_visited_time: v.NullableSchema<v.StringSchema<undefined>, undefined>;
390
+ }, undefined>, v.ObjectSchema<{
391
+ readonly id: v.StringSchema<undefined>;
392
+ readonly type: v.LiteralSchema<"unique_id", undefined>;
393
+ readonly unique_id: v.StringSchema<undefined>;
394
+ }, undefined>, v.ObjectSchema<{
395
+ readonly id: v.StringSchema<undefined>;
396
+ readonly type: v.LiteralSchema<"button", undefined>;
397
+ readonly button: v.StringSchema<undefined>;
398
+ }, undefined>, v.ObjectSchema<{
399
+ readonly id: v.StringSchema<undefined>;
400
+ readonly type: v.LiteralSchema<"formula", undefined>;
401
+ readonly formula: v.StringSchema<undefined>;
402
+ }, undefined>, v.ObjectSchema<{
403
+ readonly id: v.StringSchema<undefined>;
404
+ readonly type: v.LiteralSchema<"location", undefined>;
405
+ readonly location: v.StringSchema<undefined>;
406
+ }, undefined>, v.ObjectSchema<{
407
+ readonly id: v.StringSchema<undefined>;
408
+ readonly type: v.LiteralSchema<"rollup", undefined>;
409
+ readonly rollup: v.StringSchema<undefined>;
410
+ }, undefined>, v.ObjectSchema<{
411
+ readonly id: v.StringSchema<undefined>;
412
+ readonly type: v.LiteralSchema<"verification", undefined>;
413
+ readonly verification: v.StringSchema<undefined>;
390
414
  }, undefined>], undefined>;
391
415
  export type NotionPagePropertyValue = v.InferOutput<typeof notionPagePropertyValueSchema>;
392
416
  export declare const notionPagePropertyWriteMapSchema: v.RecordSchema<v.StringSchema<undefined>, v.VariantSchema<"type", [v.ObjectSchema<{
@@ -579,6 +603,30 @@ export declare const notionPagePropertyWriteMapSchema: v.RecordSchema<v.StringSc
579
603
  readonly id: v.StringSchema<undefined>;
580
604
  readonly type: v.LiteralSchema<"last_visited_time", undefined>;
581
605
  readonly last_visited_time: v.NullableSchema<v.StringSchema<undefined>, undefined>;
606
+ }, undefined>, v.ObjectSchema<{
607
+ readonly id: v.StringSchema<undefined>;
608
+ readonly type: v.LiteralSchema<"unique_id", undefined>;
609
+ readonly unique_id: v.StringSchema<undefined>;
610
+ }, undefined>, v.ObjectSchema<{
611
+ readonly id: v.StringSchema<undefined>;
612
+ readonly type: v.LiteralSchema<"button", undefined>;
613
+ readonly button: v.StringSchema<undefined>;
614
+ }, undefined>, v.ObjectSchema<{
615
+ readonly id: v.StringSchema<undefined>;
616
+ readonly type: v.LiteralSchema<"formula", undefined>;
617
+ readonly formula: v.StringSchema<undefined>;
618
+ }, undefined>, v.ObjectSchema<{
619
+ readonly id: v.StringSchema<undefined>;
620
+ readonly type: v.LiteralSchema<"location", undefined>;
621
+ readonly location: v.StringSchema<undefined>;
622
+ }, undefined>, v.ObjectSchema<{
623
+ readonly id: v.StringSchema<undefined>;
624
+ readonly type: v.LiteralSchema<"rollup", undefined>;
625
+ readonly rollup: v.StringSchema<undefined>;
626
+ }, undefined>, v.ObjectSchema<{
627
+ readonly id: v.StringSchema<undefined>;
628
+ readonly type: v.LiteralSchema<"verification", undefined>;
629
+ readonly verification: v.StringSchema<undefined>;
582
630
  }, undefined>], undefined>, undefined>;
583
631
  export declare const notionPagePropertyReadMapSchema: v.RecordSchema<v.StringSchema<undefined>, v.NullableSchema<v.VariantSchema<"type", [v.ObjectSchema<{
584
632
  readonly id: v.StringSchema<undefined>;
@@ -770,6 +818,30 @@ export declare const notionPagePropertyReadMapSchema: v.RecordSchema<v.StringSch
770
818
  readonly id: v.StringSchema<undefined>;
771
819
  readonly type: v.LiteralSchema<"last_visited_time", undefined>;
772
820
  readonly last_visited_time: v.NullableSchema<v.StringSchema<undefined>, undefined>;
821
+ }, undefined>, v.ObjectSchema<{
822
+ readonly id: v.StringSchema<undefined>;
823
+ readonly type: v.LiteralSchema<"unique_id", undefined>;
824
+ readonly unique_id: v.StringSchema<undefined>;
825
+ }, undefined>, v.ObjectSchema<{
826
+ readonly id: v.StringSchema<undefined>;
827
+ readonly type: v.LiteralSchema<"button", undefined>;
828
+ readonly button: v.StringSchema<undefined>;
829
+ }, undefined>, v.ObjectSchema<{
830
+ readonly id: v.StringSchema<undefined>;
831
+ readonly type: v.LiteralSchema<"formula", undefined>;
832
+ readonly formula: v.StringSchema<undefined>;
833
+ }, undefined>, v.ObjectSchema<{
834
+ readonly id: v.StringSchema<undefined>;
835
+ readonly type: v.LiteralSchema<"location", undefined>;
836
+ readonly location: v.StringSchema<undefined>;
837
+ }, undefined>, v.ObjectSchema<{
838
+ readonly id: v.StringSchema<undefined>;
839
+ readonly type: v.LiteralSchema<"rollup", undefined>;
840
+ readonly rollup: v.StringSchema<undefined>;
841
+ }, undefined>, v.ObjectSchema<{
842
+ readonly id: v.StringSchema<undefined>;
843
+ readonly type: v.LiteralSchema<"verification", undefined>;
844
+ readonly verification: v.StringSchema<undefined>;
773
845
  }, undefined>], undefined>, undefined>, undefined>;
774
846
  export type NotionPagePropertyReadMap = v.InferOutput<typeof notionPagePropertyReadMapSchema>;
775
847
  export type NotionPagePropertyWriteMap = v.InferInput<typeof notionPagePropertyWriteMapSchema>;
@@ -987,6 +1059,30 @@ export declare const notionPageDataSchema: v.ObjectSchema<{
987
1059
  readonly id: v.StringSchema<undefined>;
988
1060
  readonly type: v.LiteralSchema<"last_visited_time", undefined>;
989
1061
  readonly last_visited_time: v.NullableSchema<v.StringSchema<undefined>, undefined>;
1062
+ }, undefined>, v.ObjectSchema<{
1063
+ readonly id: v.StringSchema<undefined>;
1064
+ readonly type: v.LiteralSchema<"unique_id", undefined>;
1065
+ readonly unique_id: v.StringSchema<undefined>;
1066
+ }, undefined>, v.ObjectSchema<{
1067
+ readonly id: v.StringSchema<undefined>;
1068
+ readonly type: v.LiteralSchema<"button", undefined>;
1069
+ readonly button: v.StringSchema<undefined>;
1070
+ }, undefined>, v.ObjectSchema<{
1071
+ readonly id: v.StringSchema<undefined>;
1072
+ readonly type: v.LiteralSchema<"formula", undefined>;
1073
+ readonly formula: v.StringSchema<undefined>;
1074
+ }, undefined>, v.ObjectSchema<{
1075
+ readonly id: v.StringSchema<undefined>;
1076
+ readonly type: v.LiteralSchema<"location", undefined>;
1077
+ readonly location: v.StringSchema<undefined>;
1078
+ }, undefined>, v.ObjectSchema<{
1079
+ readonly id: v.StringSchema<undefined>;
1080
+ readonly type: v.LiteralSchema<"rollup", undefined>;
1081
+ readonly rollup: v.StringSchema<undefined>;
1082
+ }, undefined>, v.ObjectSchema<{
1083
+ readonly id: v.StringSchema<undefined>;
1084
+ readonly type: v.LiteralSchema<"verification", undefined>;
1085
+ readonly verification: v.StringSchema<undefined>;
990
1086
  }, undefined>], undefined>, undefined>, undefined>;
991
1087
  readonly created_by: v.OptionalSchema<v.NullableSchema<v.ObjectSchema<{
992
1088
  readonly id: v.StringSchema<undefined>;
@@ -1254,6 +1350,30 @@ export declare const legacyNotionPageSchema: v.ObjectSchema<{
1254
1350
  readonly id: v.StringSchema<undefined>;
1255
1351
  readonly type: v.LiteralSchema<"last_visited_time", undefined>;
1256
1352
  readonly last_visited_time: v.NullableSchema<v.StringSchema<undefined>, undefined>;
1353
+ }, undefined>, v.ObjectSchema<{
1354
+ readonly id: v.StringSchema<undefined>;
1355
+ readonly type: v.LiteralSchema<"unique_id", undefined>;
1356
+ readonly unique_id: v.StringSchema<undefined>;
1357
+ }, undefined>, v.ObjectSchema<{
1358
+ readonly id: v.StringSchema<undefined>;
1359
+ readonly type: v.LiteralSchema<"button", undefined>;
1360
+ readonly button: v.StringSchema<undefined>;
1361
+ }, undefined>, v.ObjectSchema<{
1362
+ readonly id: v.StringSchema<undefined>;
1363
+ readonly type: v.LiteralSchema<"formula", undefined>;
1364
+ readonly formula: v.StringSchema<undefined>;
1365
+ }, undefined>, v.ObjectSchema<{
1366
+ readonly id: v.StringSchema<undefined>;
1367
+ readonly type: v.LiteralSchema<"location", undefined>;
1368
+ readonly location: v.StringSchema<undefined>;
1369
+ }, undefined>, v.ObjectSchema<{
1370
+ readonly id: v.StringSchema<undefined>;
1371
+ readonly type: v.LiteralSchema<"rollup", undefined>;
1372
+ readonly rollup: v.StringSchema<undefined>;
1373
+ }, undefined>, v.ObjectSchema<{
1374
+ readonly id: v.StringSchema<undefined>;
1375
+ readonly type: v.LiteralSchema<"verification", undefined>;
1376
+ readonly verification: v.StringSchema<undefined>;
1257
1377
  }, undefined>], undefined>, undefined>;
1258
1378
  readonly created_time: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
1259
1379
  readonly last_edited_time: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
@@ -245,6 +245,36 @@ export const notionPagePropertyValueSchema = v.variant("type", [
245
245
  type: v.literal("last_visited_time"),
246
246
  last_visited_time: nullableStringSchema,
247
247
  }),
248
+ v.object({
249
+ ...pagePropertyBaseSchema,
250
+ type: v.literal("unique_id"),
251
+ unique_id: v.string(),
252
+ }),
253
+ v.object({
254
+ ...pagePropertyBaseSchema,
255
+ type: v.literal("button"),
256
+ button: v.string(),
257
+ }),
258
+ v.object({
259
+ ...pagePropertyBaseSchema,
260
+ type: v.literal("formula"),
261
+ formula: v.string(),
262
+ }),
263
+ v.object({
264
+ ...pagePropertyBaseSchema,
265
+ type: v.literal("location"),
266
+ location: v.string(),
267
+ }),
268
+ v.object({
269
+ ...pagePropertyBaseSchema,
270
+ type: v.literal("rollup"),
271
+ rollup: v.string(),
272
+ }),
273
+ v.object({
274
+ ...pagePropertyBaseSchema,
275
+ type: v.literal("verification"),
276
+ verification: v.string(),
277
+ }),
248
278
  ]);
249
279
  export const notionPagePropertyWriteMapSchema = v.record(v.string(), notionPagePropertyValueSchema);
250
280
  export const notionPagePropertyReadMapSchema = v.record(v.string(), v.nullable(notionPagePropertyValueSchema));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@notionhq/custom-blocks-host",
3
- "version": "0.3.7",
3
+ "version": "0.3.8",
4
4
  "description": "Reusable host runtime for Notion custom blocks.",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -119,6 +119,18 @@ function toLegacyProperty(
119
119
  return property.relation.map(page => ({ id: page.id, table: "block" }))
120
120
  case "files":
121
121
  return property.files.map(file => file.name).join(",")
122
+ case "unique_id":
123
+ return property.unique_id
124
+ case "button":
125
+ return property.button
126
+ case "formula":
127
+ return property.formula
128
+ case "location":
129
+ return property.location
130
+ case "rollup":
131
+ return property.rollup
132
+ case "verification":
133
+ return property.verification
122
134
  case "place":
123
135
  return ""
124
136
  case "created_time":