sveltekit-ui 1.0.33 → 1.0.34

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.
@@ -4,10 +4,120 @@
4
4
  import { PUBLIC_APPLE_MAPKIT_JS_API_KEY } from "$env/static/public"
5
5
  import { deep_copy } from "$lib/client/index.js"
6
6
 
7
- let data = $state({
8
- id: "cbsemvrsoidhrzyhugue",
9
- name: "test",
10
- rows: [],
7
+ const data_init = {
8
+ id: "mtuelwvmmoscrnuwpzml",
9
+ name: "Seasons",
10
+ rows: [
11
+ {
12
+ id: "qjjfpphxkwtoriynouco",
13
+ title: "Winners at War",
14
+ winner: "Tony Vlachos",
15
+ location: "Mamanuca Islands, Fiji",
16
+ finalists: ["Tony Vlachos", "Natalie Anderson", "Michele Fitzgerald"],
17
+ jury_votes: [
18
+ {
19
+ voter: "Amber Mariano",
20
+ target: "Tony Vlachos",
21
+ },
22
+ {
23
+ voter: "Danni Boatwright",
24
+ target: "Tony Vlachos",
25
+ },
26
+ {
27
+ voter: "Ethan Zohn",
28
+ target: "Natalie Anderson",
29
+ },
30
+ {
31
+ voter: "Rob Mariano",
32
+ target: "Tony Vlachos",
33
+ },
34
+ {
35
+ voter: "Parvati Shallow",
36
+ target: "Natalie Anderson",
37
+ },
38
+ {
39
+ voter: "Yul Kwon",
40
+ target: "Tony Vlachos",
41
+ },
42
+ {
43
+ voter: "Wendell Holland",
44
+ target: "Tony Vlachos",
45
+ },
46
+ {
47
+ voter: "Adam Klein",
48
+ target: "Tony Vlachos",
49
+ },
50
+ {
51
+ voter: "Nick Wilson",
52
+ target: "Tony Vlachos",
53
+ },
54
+ {
55
+ voter: "Tyson Apostol",
56
+ target: "Natalie Anderson",
57
+ },
58
+ {
59
+ voter: "Sophie Clarke",
60
+ target: "Tony Vlachos",
61
+ },
62
+ {
63
+ voter: "Kim Spradlin-Wolfe",
64
+ target: "Tony Vlachos",
65
+ },
66
+ {
67
+ voter: "Jeremy Collins",
68
+ target: "Natalie Anderson",
69
+ },
70
+ {
71
+ voter: "Denise Stapley",
72
+ target: "Tony Vlachos",
73
+ },
74
+ {
75
+ voter: "Ben Driebergen",
76
+ target: "Tony Vlachos",
77
+ },
78
+ {
79
+ voter: "Sarah Lacina",
80
+ target: "Tony Vlachos",
81
+ },
82
+ ],
83
+ total_days: 39,
84
+ last_air_time: {
85
+ year: 2020,
86
+ month: 5,
87
+ timezone: "America/New_York",
88
+ granularity: "day",
89
+ day_of_month: 13,
90
+ },
91
+ official_urls: {
92
+ cbs: null,
93
+ wiki: "https://en.wikipedia.org/wiki/Survivor:_Winners_at_War",
94
+ },
95
+ season_number: 40,
96
+ twist_summary: "Edge of Extinction returned; players used Fire Tokens to buy advantages and items.",
97
+ first_air_time: {
98
+ year: 2020,
99
+ month: 2,
100
+ timezone: "America/New_York",
101
+ granularity: "day",
102
+ day_of_month: 12,
103
+ },
104
+ contestant_count: 20,
105
+ db_epoch_created: 1756307504,
106
+ db_epoch_updated: 1756307504,
107
+ winner_prize_usd: 2000000,
108
+ tribe_count_start: 2,
109
+ other_known_prizes: [
110
+ {
111
+ usd: 100000,
112
+ from: "CBS (runner-up prize, typical)",
113
+ },
114
+ {
115
+ usd: 35000,
116
+ from: "EW report (appearance guarantee minimum for S40 cast)",
117
+ },
118
+ ],
119
+ },
120
+ ],
11
121
  limit: 100,
12
122
  offset: 0,
13
123
  columns: {
@@ -16,7 +126,7 @@
16
126
  is_shown: true,
17
127
  alignment: "left",
18
128
  max_width: 50,
19
- min_width: 5,
129
+ min_width: 10,
20
130
  description: null,
21
131
  is_nullable: false,
22
132
  body_content: {
@@ -24,7 +134,7 @@
24
134
  children: [],
25
135
  attributes: {
26
136
  size: 10,
27
- content_from_variable_path: ["rows", ["row_i"], "id"],
137
+ content_from_variable_path: ["variables", "rows", ["row_i"], "id"],
28
138
  },
29
139
  selector_id: "hcsqz",
30
140
  },
@@ -48,21 +158,326 @@
48
158
  is_autogenerated: true,
49
159
  is_force_uniqueness: false,
50
160
  },
51
- population: {
161
+ title: {
162
+ is_fixed: false,
163
+ is_shown: true,
164
+ alignment: "left",
165
+ max_width: 30,
166
+ min_width: 20,
167
+ description: null,
168
+ is_nullable: true,
169
+ body_content: {
170
+ type_id: "base_text",
171
+ children: [],
172
+ attributes: {
173
+ size: 10,
174
+ content_from_variable_path: ["variables", "rows", ["row_i"], "title"],
175
+ },
176
+ selector_id: "uviupvsf",
177
+ },
178
+ db_data_type: {
179
+ type: "text_literal",
180
+ attributes: {},
181
+ },
182
+ is_db_column: true,
183
+ is_updatable: false,
184
+ default_value: null,
185
+ display_order: 10,
186
+ postgres_type: "text",
187
+ header_content: {
188
+ type_id: "base_text",
189
+ children: [],
190
+ attributes: {
191
+ content: "Title",
192
+ },
193
+ selector_id: "zxhefnzj",
194
+ },
195
+ is_primary_key: false,
196
+ is_autogenerated: false,
197
+ is_force_uniqueness: false,
198
+ is_use_in_short_display: false,
199
+ },
200
+ winner: {
201
+ is_fixed: false,
202
+ is_shown: true,
203
+ alignment: "left",
204
+ max_width: 30,
205
+ min_width: 20,
206
+ description: null,
207
+ is_nullable: true,
208
+ body_content: {
209
+ type_id: "base_text",
210
+ children: [],
211
+ attributes: {
212
+ size: 10,
213
+ content_from_variable_path: ["variables", "rows", ["row_i"], "winner"],
214
+ },
215
+ selector_id: "eynrnbdh",
216
+ },
217
+ db_data_type: {
218
+ type: "text_literal",
219
+ attributes: {},
220
+ },
221
+ is_db_column: true,
222
+ is_updatable: false,
223
+ default_value: null,
224
+ display_order: 7,
225
+ postgres_type: "text",
226
+ header_content: {
227
+ type_id: "base_text",
228
+ children: [],
229
+ attributes: {
230
+ content: "Winner",
231
+ },
232
+ selector_id: "anyrcgrh",
233
+ },
234
+ is_primary_key: false,
235
+ is_autogenerated: false,
236
+ is_force_uniqueness: false,
237
+ is_use_in_short_display: false,
238
+ },
239
+ location: {
52
240
  is_fixed: false,
53
241
  is_shown: true,
54
242
  alignment: "left",
55
243
  max_width: 30,
56
244
  min_width: 20,
57
- description: "population",
245
+ description: null,
246
+ is_nullable: true,
247
+ body_content: {
248
+ type_id: "base_text",
249
+ children: [],
250
+ attributes: {
251
+ size: 10,
252
+ content_from_variable_path: ["variables", "rows", ["row_i"], "location"],
253
+ },
254
+ selector_id: "vlsfsbxt",
255
+ },
256
+ db_data_type: {
257
+ type: "text_literal",
258
+ attributes: {},
259
+ },
260
+ is_db_column: true,
261
+ is_updatable: false,
262
+ default_value: null,
263
+ display_order: 12,
264
+ postgres_type: "text",
265
+ header_content: {
266
+ type_id: "base_text",
267
+ children: [],
268
+ attributes: {
269
+ content: "Location",
270
+ },
271
+ selector_id: "yjxplvnd",
272
+ },
273
+ is_primary_key: false,
274
+ is_autogenerated: false,
275
+ is_force_uniqueness: false,
276
+ is_use_in_short_display: false,
277
+ },
278
+ finalists: {
279
+ is_fixed: false,
280
+ is_shown: true,
281
+ alignment: "left",
282
+ max_width: 30,
283
+ min_width: 20,
284
+ description: null,
285
+ is_nullable: true,
286
+ body_content: {
287
+ type_id: "loop",
288
+ children: [
289
+ {
290
+ type_id: "base_text",
291
+ children: [],
292
+ attributes: {
293
+ size: 10,
294
+ content_from_variable_path: ["variables", "rows", ["row_i"], "finalists", ["loop_index"]],
295
+ },
296
+ selector_id: "ctxcqzgc",
297
+ },
298
+ ],
299
+ attributes: {
300
+ font_size: 1.2,
301
+ iter_identifier: "loop_index",
302
+ val_from_variable_path: ["variables", "rows", ["row_i"], "finalists"],
303
+ },
304
+ selector_id: "rxcsroys",
305
+ },
306
+ db_data_type: {
307
+ type: "array_uniform_literal",
308
+ items: {
309
+ type: "text_literal",
310
+ attributes: {},
311
+ },
312
+ attributes: {},
313
+ },
314
+ is_db_column: true,
315
+ is_updatable: false,
316
+ default_value: null,
317
+ display_order: 2,
318
+ postgres_type: "text[]",
319
+ header_content: {
320
+ type_id: "base_text",
321
+ children: [],
322
+ attributes: {
323
+ content: "Finalists",
324
+ },
325
+ selector_id: "xhqvqdgp",
326
+ },
327
+ is_primary_key: false,
328
+ is_autogenerated: false,
329
+ is_force_uniqueness: false,
330
+ is_use_in_short_display: false,
331
+ },
332
+ jury_votes: {
333
+ is_fixed: false,
334
+ is_shown: true,
335
+ alignment: "left",
336
+ max_width: 30,
337
+ min_width: 20,
338
+ description: null,
339
+ is_nullable: true,
340
+ body_content: {
341
+ type_id: "loop",
342
+ children: [
343
+ {
344
+ type_id: "div",
345
+ children: [
346
+ {
347
+ type_id: "base_text",
348
+ children: [],
349
+ attributes: {
350
+ font_size: 1.2,
351
+ },
352
+ selector_id: "rblutubz",
353
+ },
354
+ {
355
+ type_id: "div",
356
+ children: [
357
+ {
358
+ type_id: "base_text",
359
+ children: [],
360
+ attributes: {
361
+ content: "voter:",
362
+ font_size: 1.2,
363
+ },
364
+ selector_id: "horpveoa",
365
+ },
366
+ {
367
+ type_id: "base_text",
368
+ children: [],
369
+ attributes: {
370
+ size: 10,
371
+ content_from_variable_path: [
372
+ "variables",
373
+ "rows",
374
+ ["row_i"],
375
+ "jury_votes",
376
+ ["loop_index"],
377
+ "voter",
378
+ ],
379
+ },
380
+ selector_id: "hjpxqdzr",
381
+ },
382
+ ],
383
+ attributes: {},
384
+ selector_id: "qlhgvhzt",
385
+ },
386
+ {
387
+ type_id: "div",
388
+ children: [
389
+ {
390
+ type_id: "base_text",
391
+ children: [],
392
+ attributes: {
393
+ content: "target:",
394
+ font_size: 1.2,
395
+ },
396
+ selector_id: "krkpjykp",
397
+ },
398
+ {
399
+ type_id: "base_text",
400
+ children: [],
401
+ attributes: {
402
+ size: 10,
403
+ content_from_variable_path: [
404
+ "variables",
405
+ "rows",
406
+ ["row_i"],
407
+ "jury_votes",
408
+ ["loop_index"],
409
+ "target",
410
+ ],
411
+ },
412
+ selector_id: "gtimorzk",
413
+ },
414
+ ],
415
+ attributes: {},
416
+ selector_id: "zlyatbzg",
417
+ },
418
+ ],
419
+ attributes: {},
420
+ selector_id: "ygoqnpeo",
421
+ },
422
+ ],
423
+ attributes: {
424
+ font_size: 1.2,
425
+ iter_identifier: "loop_index",
426
+ val_from_variable_path: ["variables", "rows", ["row_i"], "jury_votes"],
427
+ },
428
+ selector_id: "lrshjoke",
429
+ },
430
+ db_data_type: {
431
+ type: "array_uniform_literal",
432
+ items: {
433
+ type: "object_literal",
434
+ attributes: {},
435
+ properties: {
436
+ voter: {
437
+ type: "text_literal",
438
+ attributes: {},
439
+ },
440
+ target: {
441
+ type: "text_literal",
442
+ attributes: {},
443
+ },
444
+ },
445
+ },
446
+ attributes: {},
447
+ },
448
+ is_db_column: true,
449
+ is_updatable: false,
450
+ default_value: null,
451
+ display_order: 6,
452
+ postgres_type: "jsonb",
453
+ header_content: {
454
+ type_id: "base_text",
455
+ children: [],
456
+ attributes: {
457
+ content: "Jury Votes",
458
+ },
459
+ selector_id: "ijivscjv",
460
+ },
461
+ is_primary_key: false,
462
+ is_autogenerated: false,
463
+ is_force_uniqueness: false,
464
+ is_use_in_short_display: false,
465
+ },
466
+ total_days: {
467
+ is_fixed: false,
468
+ is_shown: true,
469
+ alignment: "left",
470
+ max_width: 30,
471
+ min_width: 20,
472
+ description: null,
58
473
  is_nullable: true,
59
474
  body_content: {
60
475
  type_id: "number",
61
476
  children: [],
62
477
  attributes: {
63
- val_from_variable_path: ["rows", ["row_i"], "population"],
478
+ val_from_variable_path: ["variables", "rows", ["row_i"], "total_days"],
64
479
  },
65
- selector_id: "vukyefhw",
480
+ selector_id: "cxmhlsxi",
66
481
  },
67
482
  db_data_type: {
68
483
  type: "int_literal",
@@ -71,36 +486,213 @@
71
486
  is_db_column: true,
72
487
  is_updatable: false,
73
488
  default_value: null,
74
- display_order: 1,
489
+ display_order: 11,
75
490
  postgres_type: "int",
76
491
  header_content: {
77
492
  type_id: "base_text",
78
493
  children: [],
79
494
  attributes: {
80
- content: "Population",
495
+ content: "Total Days",
81
496
  },
82
- selector_id: "lpcqsjlq",
497
+ selector_id: "dyfbylhl",
83
498
  },
84
499
  is_primary_key: false,
85
500
  is_autogenerated: false,
86
501
  is_force_uniqueness: false,
87
502
  is_use_in_short_display: false,
88
503
  },
89
- us_state: {
504
+ last_air_time: {
90
505
  is_fixed: false,
91
506
  is_shown: true,
92
507
  alignment: "left",
93
508
  max_width: 30,
94
509
  min_width: 20,
95
- description: "us_state",
510
+ description: null,
96
511
  is_nullable: true,
97
512
  body_content: {
513
+ type_id: "time",
514
+ children: [],
515
+ attributes: {
516
+ format: "time_full",
517
+ text_color: null,
518
+ display_format: "calendar_date",
519
+ val_from_variable_path: ["variables", "rows", ["row_i"], "last_air_time"],
520
+ },
521
+ selector_id: "bmqrpktp",
522
+ },
523
+ db_data_type: {
524
+ type: "time_literal",
525
+ attributes: {},
526
+ },
527
+ is_db_column: true,
528
+ is_updatable: false,
529
+ default_value: null,
530
+ display_order: 14,
531
+ postgres_type: "jsonb",
532
+ header_content: {
98
533
  type_id: "base_text",
99
534
  children: [],
100
535
  attributes: {
101
- content_from_variable_path: ["rows", ["row_i"], "us_state"],
536
+ content: "Last Air Time",
102
537
  },
103
- selector_id: "kukyefhw",
538
+ selector_id: "wjpvaubt",
539
+ },
540
+ is_primary_key: false,
541
+ is_autogenerated: false,
542
+ is_force_uniqueness: false,
543
+ is_use_in_short_display: false,
544
+ },
545
+ official_urls: {
546
+ is_fixed: false,
547
+ is_shown: true,
548
+ alignment: "left",
549
+ max_width: 30,
550
+ min_width: 20,
551
+ description: null,
552
+ is_nullable: true,
553
+ body_content: {
554
+ type_id: "div",
555
+ children: [
556
+ {
557
+ type_id: "div",
558
+ children: [
559
+ {
560
+ type_id: "base_text",
561
+ children: [],
562
+ attributes: {
563
+ content: "wiki:",
564
+ font_size: 1.2,
565
+ },
566
+ selector_id: "dpnuzrlt",
567
+ },
568
+ {
569
+ type_id: "base_text",
570
+ children: [],
571
+ attributes: {
572
+ size: 10,
573
+ content_from_variable_path: ["variables", "rows", ["row_i"], "official_urls", "wiki"],
574
+ },
575
+ selector_id: "oratheqg",
576
+ },
577
+ ],
578
+ attributes: {},
579
+ selector_id: "nqihkgzq",
580
+ },
581
+ {
582
+ type_id: "div",
583
+ children: [
584
+ {
585
+ type_id: "base_text",
586
+ children: [],
587
+ attributes: {
588
+ content: "cbs:",
589
+ font_size: 1.2,
590
+ },
591
+ selector_id: "twehnbaj",
592
+ },
593
+ {
594
+ type_id: "base_text",
595
+ children: [],
596
+ attributes: {
597
+ size: 10,
598
+ content_from_variable_path: ["variables", "rows", ["row_i"], "official_urls", "cbs"],
599
+ },
600
+ selector_id: "mmcwicnd",
601
+ },
602
+ ],
603
+ attributes: {},
604
+ selector_id: "nkbowoir",
605
+ },
606
+ ],
607
+ attributes: {},
608
+ selector_id: "nslctfbt",
609
+ },
610
+ db_data_type: {
611
+ type: "object_literal",
612
+ attributes: {},
613
+ properties: {
614
+ cbs: {
615
+ type: "text_literal",
616
+ attributes: {},
617
+ },
618
+ wiki: {
619
+ type: "text_literal",
620
+ attributes: {},
621
+ },
622
+ },
623
+ },
624
+ is_db_column: true,
625
+ is_updatable: false,
626
+ default_value: null,
627
+ display_order: 3,
628
+ postgres_type: "jsonb",
629
+ header_content: {
630
+ type_id: "base_text",
631
+ children: [],
632
+ attributes: {
633
+ content: "Official Urls",
634
+ },
635
+ selector_id: "cczwknol",
636
+ },
637
+ is_primary_key: false,
638
+ is_autogenerated: false,
639
+ is_force_uniqueness: false,
640
+ is_use_in_short_display: false,
641
+ },
642
+ season_number: {
643
+ is_fixed: false,
644
+ is_shown: true,
645
+ alignment: "left",
646
+ max_width: 30,
647
+ min_width: 20,
648
+ description: null,
649
+ is_nullable: true,
650
+ body_content: {
651
+ type_id: "number",
652
+ children: [],
653
+ attributes: {
654
+ val_from_variable_path: ["variables", "rows", ["row_i"], "season_number"],
655
+ },
656
+ selector_id: "ekqcqjdv",
657
+ },
658
+ db_data_type: {
659
+ type: "int_literal",
660
+ attributes: {},
661
+ },
662
+ is_db_column: true,
663
+ is_updatable: false,
664
+ default_value: null,
665
+ display_order: 13,
666
+ postgres_type: "int",
667
+ header_content: {
668
+ type_id: "base_text",
669
+ children: [],
670
+ attributes: {
671
+ content: "Season Number",
672
+ },
673
+ selector_id: "dmjbwksh",
674
+ },
675
+ is_primary_key: false,
676
+ is_autogenerated: false,
677
+ is_force_uniqueness: false,
678
+ is_use_in_short_display: false,
679
+ },
680
+ twist_summary: {
681
+ is_fixed: false,
682
+ is_shown: true,
683
+ alignment: "left",
684
+ max_width: 30,
685
+ min_width: 20,
686
+ description: null,
687
+ is_nullable: true,
688
+ body_content: {
689
+ type_id: "base_text",
690
+ children: [],
691
+ attributes: {
692
+ size: 10,
693
+ content_from_variable_path: ["variables", "rows", ["row_i"], "twist_summary"],
694
+ },
695
+ selector_id: "mozvuckh",
104
696
  },
105
697
  db_data_type: {
106
698
  type: "text_literal",
@@ -109,15 +701,94 @@
109
701
  is_db_column: true,
110
702
  is_updatable: false,
111
703
  default_value: null,
112
- display_order: 2,
704
+ display_order: 4,
113
705
  postgres_type: "text",
114
706
  header_content: {
115
707
  type_id: "base_text",
116
708
  children: [],
117
709
  attributes: {
118
- content: "US State",
710
+ content: "Twist Summary",
119
711
  },
120
- selector_id: "lpcqsjlq",
712
+ selector_id: "dgcxkgnj",
713
+ },
714
+ is_primary_key: false,
715
+ is_autogenerated: false,
716
+ is_force_uniqueness: false,
717
+ is_use_in_short_display: false,
718
+ },
719
+ first_air_time: {
720
+ is_fixed: false,
721
+ is_shown: true,
722
+ alignment: "left",
723
+ max_width: 30,
724
+ min_width: 20,
725
+ description: null,
726
+ is_nullable: true,
727
+ body_content: {
728
+ type_id: "time",
729
+ children: [],
730
+ attributes: {
731
+ format: "time_full",
732
+ text_color: null,
733
+ display_format: "calendar_date",
734
+ val_from_variable_path: ["variables", "rows", ["row_i"], "first_air_time"],
735
+ },
736
+ selector_id: "idhynywf",
737
+ },
738
+ db_data_type: {
739
+ type: "time_literal",
740
+ attributes: {},
741
+ },
742
+ is_db_column: true,
743
+ is_updatable: false,
744
+ default_value: null,
745
+ display_order: 15,
746
+ postgres_type: "jsonb",
747
+ header_content: {
748
+ type_id: "base_text",
749
+ children: [],
750
+ attributes: {
751
+ content: "First Air Time",
752
+ },
753
+ selector_id: "kifuvhrk",
754
+ },
755
+ is_primary_key: false,
756
+ is_autogenerated: false,
757
+ is_force_uniqueness: false,
758
+ is_use_in_short_display: false,
759
+ },
760
+ contestant_count: {
761
+ is_fixed: false,
762
+ is_shown: true,
763
+ alignment: "left",
764
+ max_width: 30,
765
+ min_width: 20,
766
+ description: null,
767
+ is_nullable: true,
768
+ body_content: {
769
+ type_id: "number",
770
+ children: [],
771
+ attributes: {
772
+ val_from_variable_path: ["variables", "rows", ["row_i"], "contestant_count"],
773
+ },
774
+ selector_id: "uziyzxgd",
775
+ },
776
+ db_data_type: {
777
+ type: "int_literal",
778
+ attributes: {},
779
+ },
780
+ is_db_column: true,
781
+ is_updatable: false,
782
+ default_value: null,
783
+ display_order: 9,
784
+ postgres_type: "int",
785
+ header_content: {
786
+ type_id: "base_text",
787
+ children: [],
788
+ attributes: {
789
+ content: "Contestant Count",
790
+ },
791
+ selector_id: "fnzvbuko",
121
792
  },
122
793
  is_primary_key: false,
123
794
  is_autogenerated: false,
@@ -137,7 +808,7 @@
137
808
  children: [],
138
809
  attributes: {
139
810
  format: "epoch",
140
- val_from_variable_path: ["rows", ["row_i"], "db_epoch_created"],
811
+ val_from_variable_path: ["variables", "rows", ["row_i"], "db_epoch_created"],
141
812
  },
142
813
  selector_id: "time_urzjm",
143
814
  },
@@ -147,7 +818,7 @@
147
818
  },
148
819
  is_db_column: true,
149
820
  default_value: null,
150
- display_order: 3,
821
+ display_order: 16,
151
822
  postgres_type: "bigint",
152
823
  header_content: {
153
824
  type_id: "base_text",
@@ -174,7 +845,7 @@
174
845
  children: [],
175
846
  attributes: {
176
847
  format: "epoch",
177
- val_from_variable_path: ["rows", ["row_i"], "db_epoch_updated"],
848
+ val_from_variable_path: ["variables", "rows", ["row_i"], "db_epoch_updated"],
178
849
  },
179
850
  selector_id: "epoch_rozyy",
180
851
  },
@@ -184,7 +855,7 @@
184
855
  },
185
856
  is_db_column: true,
186
857
  default_value: null,
187
- display_order: 4,
858
+ display_order: 17,
188
859
  postgres_type: "bigint",
189
860
  header_content: {
190
861
  type_id: "base_text",
@@ -198,76 +869,496 @@
198
869
  is_autogenerated: true,
199
870
  is_force_uniqueness: false,
200
871
  },
201
- },
202
- account_id: "kmjexchofxophkkuqfvp",
203
- total_rows: 0,
204
- description: "need to make sure new loop stuff works",
205
- default_sort: null,
206
- row_input_content: null,
207
- row_searchable_content: null,
208
- })
209
-
210
- let table_manager = $state(null)
211
- let variables = $state({
212
- rows: [
213
- {
214
- id: "zuetqjdinawjrvftztif",
215
- us_state: "Ohio",
216
- population: 11700000,
217
- db_epoch_created: 1734451200,
218
- db_epoch_updated: 1734451200,
219
- },
220
- {
221
- id: "blwigkbhwbrdrpfgtjht",
222
- us_state: "California",
223
- population: 39500000,
224
- db_epoch_created: 1734451200,
225
- db_epoch_updated: 1734451200,
226
- start_time: null,
227
- },
228
- {
229
- id: "szjefrcsfaovgqgbvomk",
230
- us_state: "Texas",
231
- population: 29000000,
232
- db_epoch_created: 1734451200,
233
- db_epoch_updated: 1734451200,
234
- },
235
- {
236
- id: "idyqhgokgtootefrpjlk",
237
- us_state: "Florida",
238
- population: 21500000,
239
- db_epoch_created: 1734451200,
240
- db_epoch_updated: 1734451200,
241
- },
242
- {
243
- id: "fsbdlpaujxcbenalzxrd",
244
- us_state: "New York",
245
- population: 19400000,
246
- db_epoch_created: 1734451200,
247
- db_epoch_updated: 1734451200,
872
+ winner_prize_usd: {
873
+ is_fixed: false,
874
+ is_shown: true,
875
+ alignment: "left",
876
+ max_width: 30,
877
+ min_width: 20,
878
+ description: null,
879
+ is_nullable: true,
880
+ body_content: {
881
+ type_id: "number",
882
+ children: [],
883
+ attributes: {
884
+ val_from_variable_path: ["variables", "rows", ["row_i"], "winner_prize_usd"],
885
+ },
886
+ selector_id: "juinruym",
887
+ },
888
+ db_data_type: {
889
+ type: "bigint_literal",
890
+ attributes: {},
891
+ },
892
+ is_db_column: true,
893
+ is_updatable: false,
894
+ default_value: null,
895
+ display_order: 5,
896
+ postgres_type: "bigint",
897
+ header_content: {
898
+ type_id: "base_text",
899
+ children: [],
900
+ attributes: {
901
+ content: "Winner Prize Usd",
902
+ },
903
+ selector_id: "qmwkzdha",
904
+ },
905
+ is_primary_key: false,
906
+ is_autogenerated: false,
907
+ is_force_uniqueness: false,
908
+ is_use_in_short_display: false,
248
909
  },
249
- {
250
- id: "lgljuheyjeuhuxffxqrw",
251
- us_state: "Illinois",
252
- population: 12600000,
253
- db_epoch_created: 1734451200,
254
- db_epoch_updated: 1734451200,
910
+ tribe_count_start: {
911
+ is_fixed: false,
912
+ is_shown: true,
913
+ alignment: "left",
914
+ max_width: 30,
915
+ min_width: 20,
916
+ description: null,
917
+ is_nullable: true,
918
+ body_content: {
919
+ type_id: "number",
920
+ children: [],
921
+ attributes: {
922
+ val_from_variable_path: ["variables", "rows", ["row_i"], "tribe_count_start"],
923
+ },
924
+ selector_id: "vhnukduh",
925
+ },
926
+ db_data_type: {
927
+ type: "int_literal",
928
+ attributes: {},
929
+ },
930
+ is_db_column: true,
931
+ is_updatable: false,
932
+ default_value: null,
933
+ display_order: 8,
934
+ postgres_type: "int",
935
+ header_content: {
936
+ type_id: "base_text",
937
+ children: [],
938
+ attributes: {
939
+ content: "Tribe Count Start",
940
+ },
941
+ selector_id: "qnrqvlrf",
942
+ },
943
+ is_primary_key: false,
944
+ is_autogenerated: false,
945
+ is_force_uniqueness: false,
946
+ is_use_in_short_display: false,
255
947
  },
256
- {
257
- id: "ydhrlhktgyvjyuenxsfl",
258
- us_state: "Pennsylvania",
259
- population: 12800000,
260
- db_epoch_created: 1734451200,
261
- db_epoch_updated: 1734451200,
948
+ other_known_prizes: {
949
+ is_fixed: false,
950
+ is_shown: true,
951
+ alignment: "left",
952
+ max_width: 30,
953
+ min_width: 20,
954
+ description: null,
955
+ is_nullable: true,
956
+ body_content: {
957
+ type_id: "loop",
958
+ children: [
959
+ {
960
+ type_id: "div",
961
+ children: [
962
+ {
963
+ type_id: "base_text",
964
+ children: [],
965
+ attributes: {
966
+ font_size: 1.2,
967
+ },
968
+ selector_id: "uuhehilk",
969
+ },
970
+ {
971
+ type_id: "div",
972
+ children: [
973
+ {
974
+ type_id: "base_text",
975
+ children: [],
976
+ attributes: {
977
+ content: "from:",
978
+ font_size: 1.2,
979
+ },
980
+ selector_id: "wehczszv",
981
+ },
982
+ {
983
+ type_id: "base_text",
984
+ children: [],
985
+ attributes: {
986
+ size: 10,
987
+ content_from_variable_path: [
988
+ "variables",
989
+ "rows",
990
+ ["row_i"],
991
+ "other_known_prizes",
992
+ ["loop_index"],
993
+ "from",
994
+ ],
995
+ },
996
+ selector_id: "hhxohdjm",
997
+ },
998
+ ],
999
+ attributes: {},
1000
+ selector_id: "xwqkvxhs",
1001
+ },
1002
+ {
1003
+ type_id: "div",
1004
+ children: [
1005
+ {
1006
+ type_id: "base_text",
1007
+ children: [],
1008
+ attributes: {
1009
+ content: "usd:",
1010
+ font_size: 1.2,
1011
+ },
1012
+ selector_id: "hnnvvaop",
1013
+ },
1014
+ {
1015
+ type_id: "number",
1016
+ children: [],
1017
+ attributes: {
1018
+ val_from_variable_path: [
1019
+ "variables",
1020
+ "rows",
1021
+ ["row_i"],
1022
+ "other_known_prizes",
1023
+ ["loop_index"],
1024
+ "usd",
1025
+ ],
1026
+ },
1027
+ selector_id: "mfeexpga",
1028
+ },
1029
+ ],
1030
+ attributes: {},
1031
+ selector_id: "cpsjhamp",
1032
+ },
1033
+ ],
1034
+ attributes: {},
1035
+ selector_id: "dmxxkvku",
1036
+ },
1037
+ ],
1038
+ attributes: {
1039
+ font_size: 1.2,
1040
+ iter_identifier: "loop_index",
1041
+ val_from_variable_path: ["variables", "rows", ["row_i"], "other_known_prizes"],
1042
+ },
1043
+ selector_id: "sjarvfbv",
1044
+ },
1045
+ db_data_type: {
1046
+ type: "array_uniform_literal",
1047
+ items: {
1048
+ type: "object_literal",
1049
+ attributes: {},
1050
+ properties: {
1051
+ usd: {
1052
+ type: "bigint_literal",
1053
+ attributes: {},
1054
+ },
1055
+ from: {
1056
+ type: "text_literal",
1057
+ attributes: {},
1058
+ },
1059
+ },
1060
+ },
1061
+ attributes: {},
1062
+ },
1063
+ is_db_column: true,
1064
+ is_updatable: false,
1065
+ default_value: null,
1066
+ display_order: 1,
1067
+ postgres_type: "jsonb",
1068
+ header_content: {
1069
+ type_id: "base_text",
1070
+ children: [],
1071
+ attributes: {
1072
+ content: "Other Known Prizes",
1073
+ },
1074
+ selector_id: "hxdhyslv",
1075
+ },
1076
+ is_primary_key: false,
1077
+ is_autogenerated: false,
1078
+ is_force_uniqueness: false,
1079
+ is_use_in_short_display: false,
262
1080
  },
1081
+ },
1082
+ account_id: "ukkvrwvfuaqnotejkqua",
1083
+ total_rows: 1,
1084
+ description: null,
1085
+ default_sort: [
263
1086
  {
264
- id: "jqruaftavlvjkbzmcifm",
265
- us_state: "Georgia",
266
- population: 10700000,
267
- db_epoch_created: 1734451200,
268
- db_epoch_updated: 1734451200,
1087
+ is_ascending: false,
1088
+ variable_path: ["season_number"],
269
1089
  },
270
1090
  ],
1091
+ function_triggers: null,
1092
+ row_input_content: null,
1093
+ row_searchable_content: null,
1094
+ }
1095
+
1096
+ // const data_init2 = {
1097
+ // id: "cbsemvrsoidhrzyhugue",
1098
+ // name: "test",
1099
+ // rows: [
1100
+ // {
1101
+ // id: "zuetqjdinawjrvftztif",
1102
+ // us_state: "Ohio",
1103
+ // population: 11700000,
1104
+ // db_epoch_created: 1734451200,
1105
+ // db_epoch_updated: 1734451200,
1106
+ // },
1107
+ // {
1108
+ // id: "blwigkbhwbrdrpfgtjht",
1109
+ // us_state: "California",
1110
+ // population: 39500000,
1111
+ // db_epoch_created: 1734451200,
1112
+ // db_epoch_updated: 1734451200,
1113
+ // start_time: null,
1114
+ // },
1115
+ // {
1116
+ // id: "szjefrcsfaovgqgbvomk",
1117
+ // us_state: "Texas",
1118
+ // population: 29000000,
1119
+ // db_epoch_created: 1734451200,
1120
+ // db_epoch_updated: 1734451200,
1121
+ // },
1122
+ // {
1123
+ // id: "idyqhgokgtootefrpjlk",
1124
+ // us_state: "Florida",
1125
+ // population: 21500000,
1126
+ // db_epoch_created: 1734451200,
1127
+ // db_epoch_updated: 1734451200,
1128
+ // },
1129
+ // {
1130
+ // id: "fsbdlpaujxcbenalzxrd",
1131
+ // us_state: "New York",
1132
+ // population: 19400000,
1133
+ // db_epoch_created: 1734451200,
1134
+ // db_epoch_updated: 1734451200,
1135
+ // },
1136
+ // {
1137
+ // id: "lgljuheyjeuhuxffxqrw",
1138
+ // us_state: "Illinois",
1139
+ // population: 12600000,
1140
+ // db_epoch_created: 1734451200,
1141
+ // db_epoch_updated: 1734451200,
1142
+ // },
1143
+ // {
1144
+ // id: "ydhrlhktgyvjyuenxsfl",
1145
+ // us_state: "Pennsylvania",
1146
+ // population: 12800000,
1147
+ // db_epoch_created: 1734451200,
1148
+ // db_epoch_updated: 1734451200,
1149
+ // },
1150
+ // {
1151
+ // id: "jqruaftavlvjkbzmcifm",
1152
+ // us_state: "Georgia",
1153
+ // population: 10700000,
1154
+ // db_epoch_created: 1734451200,
1155
+ // db_epoch_updated: 1734451200,
1156
+ // },
1157
+ // ],
1158
+ // limit: 100,
1159
+ // offset: 0,
1160
+ // columns: {
1161
+ // id: {
1162
+ // is_fixed: true,
1163
+ // is_shown: true,
1164
+ // alignment: "left",
1165
+ // max_width: 50,
1166
+ // min_width: 5,
1167
+ // description: null,
1168
+ // is_nullable: false,
1169
+ // body_content: {
1170
+ // type_id: "base_text",
1171
+ // children: [],
1172
+ // attributes: {
1173
+ // size: 10,
1174
+ // content_from_variable_path: ["rows", ["row_i"], "id"],
1175
+ // },
1176
+ // selector_id: "hcsqz",
1177
+ // },
1178
+ // db_data_type: {
1179
+ // type: "text_literal",
1180
+ // attributes: {},
1181
+ // },
1182
+ // is_db_column: true,
1183
+ // default_value: null,
1184
+ // display_order: 0,
1185
+ // postgres_type: "text",
1186
+ // header_content: {
1187
+ // type_id: "base_text",
1188
+ // children: [],
1189
+ // attributes: {
1190
+ // content: "Id",
1191
+ // },
1192
+ // selector_id: "qkdcstdn",
1193
+ // },
1194
+ // is_primary_key: true,
1195
+ // is_autogenerated: true,
1196
+ // is_force_uniqueness: false,
1197
+ // },
1198
+ // population: {
1199
+ // is_fixed: false,
1200
+ // is_shown: true,
1201
+ // alignment: "left",
1202
+ // max_width: 30,
1203
+ // min_width: 20,
1204
+ // description: "population",
1205
+ // is_nullable: true,
1206
+ // body_content: {
1207
+ // type_id: "number",
1208
+ // children: [],
1209
+ // attributes: {
1210
+ // val_from_variable_path: ["rows", ["row_i"], "population"],
1211
+ // },
1212
+ // selector_id: "vukyefhw",
1213
+ // },
1214
+ // db_data_type: {
1215
+ // type: "int_literal",
1216
+ // attributes: {},
1217
+ // },
1218
+ // is_db_column: true,
1219
+ // is_updatable: false,
1220
+ // default_value: null,
1221
+ // display_order: 1,
1222
+ // postgres_type: "int",
1223
+ // header_content: {
1224
+ // type_id: "base_text",
1225
+ // children: [],
1226
+ // attributes: {
1227
+ // content: "Population",
1228
+ // },
1229
+ // selector_id: "lpcqsjlq",
1230
+ // },
1231
+ // is_primary_key: false,
1232
+ // is_autogenerated: false,
1233
+ // is_force_uniqueness: false,
1234
+ // is_use_in_short_display: false,
1235
+ // },
1236
+ // us_state: {
1237
+ // is_fixed: false,
1238
+ // is_shown: true,
1239
+ // alignment: "left",
1240
+ // max_width: 30,
1241
+ // min_width: 20,
1242
+ // description: "us_state",
1243
+ // is_nullable: true,
1244
+ // body_content: {
1245
+ // type_id: "base_text",
1246
+ // children: [],
1247
+ // attributes: {
1248
+ // content_from_variable_path: ["rows", ["row_i"], "us_state"],
1249
+ // },
1250
+ // selector_id: "kukyefhw",
1251
+ // },
1252
+ // db_data_type: {
1253
+ // type: "text_literal",
1254
+ // attributes: {},
1255
+ // },
1256
+ // is_db_column: true,
1257
+ // is_updatable: false,
1258
+ // default_value: null,
1259
+ // display_order: 2,
1260
+ // postgres_type: "text",
1261
+ // header_content: {
1262
+ // type_id: "base_text",
1263
+ // children: [],
1264
+ // attributes: {
1265
+ // content: "US State",
1266
+ // },
1267
+ // selector_id: "lpcqsjlq",
1268
+ // },
1269
+ // is_primary_key: false,
1270
+ // is_autogenerated: false,
1271
+ // is_force_uniqueness: false,
1272
+ // is_use_in_short_display: false,
1273
+ // },
1274
+ // db_epoch_created: {
1275
+ // is_fixed: false,
1276
+ // is_shown: true,
1277
+ // alignment: "left",
1278
+ // max_width: 50,
1279
+ // min_width: 20,
1280
+ // description: null,
1281
+ // is_nullable: false,
1282
+ // body_content: {
1283
+ // type_id: "time",
1284
+ // children: [],
1285
+ // attributes: {
1286
+ // format: "epoch",
1287
+ // val_from_variable_path: ["rows", ["row_i"], "db_epoch_created"],
1288
+ // },
1289
+ // selector_id: "time_urzjm",
1290
+ // },
1291
+ // db_data_type: {
1292
+ // type: "epoch_literal",
1293
+ // attributes: {},
1294
+ // },
1295
+ // is_db_column: true,
1296
+ // default_value: null,
1297
+ // display_order: 3,
1298
+ // postgres_type: "bigint",
1299
+ // header_content: {
1300
+ // type_id: "base_text",
1301
+ // children: [],
1302
+ // attributes: {
1303
+ // content: "Db Epoch Created",
1304
+ // },
1305
+ // selector_id: "pwhlofsm",
1306
+ // },
1307
+ // is_primary_key: false,
1308
+ // is_autogenerated: true,
1309
+ // is_force_uniqueness: false,
1310
+ // },
1311
+ // db_epoch_updated: {
1312
+ // is_fixed: false,
1313
+ // is_shown: true,
1314
+ // alignment: "left",
1315
+ // max_width: 50,
1316
+ // min_width: 20,
1317
+ // description: null,
1318
+ // is_nullable: false,
1319
+ // body_content: {
1320
+ // type_id: "time",
1321
+ // children: [],
1322
+ // attributes: {
1323
+ // format: "epoch",
1324
+ // val_from_variable_path: ["rows", ["row_i"], "db_epoch_updated"],
1325
+ // },
1326
+ // selector_id: "epoch_rozyy",
1327
+ // },
1328
+ // db_data_type: {
1329
+ // type: "epoch_literal",
1330
+ // attributes: {},
1331
+ // },
1332
+ // is_db_column: true,
1333
+ // default_value: null,
1334
+ // display_order: 4,
1335
+ // postgres_type: "bigint",
1336
+ // header_content: {
1337
+ // type_id: "base_text",
1338
+ // children: [],
1339
+ // attributes: {
1340
+ // content: "Db Epoch Updated",
1341
+ // },
1342
+ // selector_id: "hxuesxvx",
1343
+ // },
1344
+ // is_primary_key: false,
1345
+ // is_autogenerated: true,
1346
+ // is_force_uniqueness: false,
1347
+ // },
1348
+ // },
1349
+ // account_id: "kmjexchofxophkkuqfvp",
1350
+ // total_rows: 0,
1351
+ // description: "need to make sure new loop stuff works",
1352
+ // default_sort: null,
1353
+ // row_input_content: null,
1354
+ // row_searchable_content: null,
1355
+ // }
1356
+
1357
+ let data = $state(data_init)
1358
+
1359
+ let table_manager = $state(null)
1360
+ let variables = $state({
1361
+ rows: data?.rows,
271
1362
  })
272
1363
 
273
1364
  table_manager = create_table_advanced_manager({
@@ -276,8 +1367,8 @@
276
1367
  table_description: "This has data about uh...stuff...idk",
277
1368
  mapkit_js_token: PUBLIC_APPLE_MAPKIT_JS_API_KEY,
278
1369
  table_options: [{ key: "test", name: "Test" }],
279
- definition_stack: [{ ...variables }],
280
- rows_data_from_variable_path: ["rows"],
1370
+ definition_stack: [{ variables }],
1371
+ rows_data_from_variable_path: ["variables", "rows"],
281
1372
  row_iter_identifier: "row_i",
282
1373
  table_header_max_height: 8,
283
1374
  table_row_max_height: 8,
@@ -306,7 +1397,7 @@
306
1397
  ],
307
1398
  is_more_to_load: true,
308
1399
  on_event: async (input) => {
309
- console.log("table_on_event", { input: deep_copy(input), variables })
1400
+ console.log("table_on_event", deep_copy({ input, variables }))
310
1401
  if (input?.type == "update_row") {
311
1402
  const path_to_set = input?.path
312
1403
  let variables_loc = deep_copy(variables)