floor-editor-ts 1.2.7 → 1.2.9

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.
@@ -5967,8 +5967,8 @@ if (typeof window !== "undefined") {
5967
5967
  //#region src/lib/stores/onboarding.svelte.ts
5968
5968
  var onboarding_svelte_exports = /* @__PURE__ */ __exportAll({
5969
5969
  TIP_MESSAGES: () => TIP_MESSAGES,
5970
+ activeTipState: () => activeTipState,
5970
5971
  dismissTip: () => dismissTip,
5971
- getActiveTip: () => getActiveTip,
5972
5972
  markTipSeen: () => markTipSeen,
5973
5973
  showTip: () => showTip,
5974
5974
  triggerTip: () => triggerTip
@@ -5994,26 +5994,23 @@ function markTipSeen(tipId) {
5994
5994
  seen.add(tipId);
5995
5995
  persist(seen);
5996
5996
  }
5997
- function getActiveTip() {
5998
- return get(_activeTip);
5999
- }
6000
5997
  /** Trigger a tip at a screen position. No-ops if already seen. */
6001
5998
  function triggerTip(tipId, x, y) {
6002
5999
  if (!showTip(tipId)) return;
6003
- set(_activeTip, {
6000
+ activeTipState.current = {
6004
6001
  id: tipId,
6005
6002
  x,
6006
6003
  y
6007
- }, true);
6004
+ };
6008
6005
  }
6009
6006
  /** Dismiss the current tip */
6010
6007
  function dismissTip() {
6011
- if (get(_activeTip)) {
6012
- markTipSeen(get(_activeTip).id);
6013
- set(_activeTip, null);
6008
+ if (activeTipState.current) {
6009
+ markTipSeen(activeTipState.current.id);
6010
+ activeTipState.current = null;
6014
6011
  }
6015
6012
  }
6016
- var STORAGE_KEY, TIP_MESSAGES, _activeTip;
6013
+ var STORAGE_KEY, TIP_MESSAGES, activeTipState;
6017
6014
  var init_onboarding_svelte = __esmMin((() => {
6018
6015
  init_client();
6019
6016
  STORAGE_KEY = "o3d_tips_seen";
@@ -6024,7 +6021,7 @@ var init_onboarding_svelte = __esmMin((() => {
6024
6021
  "first-export": "Your plan is ready! Try SVG for vector graphics or PDF for printing.",
6025
6022
  "first-door": "Click on a wall to place doors and windows."
6026
6023
  };
6027
- _activeTip = /* @__PURE__ */ state(null);
6024
+ activeTipState = proxy({ current: null });
6028
6025
  }));
6029
6026
  //#endregion
6030
6027
  //#region src/lib/stores/project.ts
@@ -59793,7 +59790,7 @@ function PropertiesPanel($$anchor, $$props) {
59793
59790
  updateDetectedRoom(get(selectedRoom).id, { name: rt.label });
59794
59791
  }
59795
59792
  }
59796
- let selectedRoomType = /* @__PURE__ */ user_derived(() => () => {
59793
+ let selectedRoomType = /* @__PURE__ */ user_derived(() => {
59797
59794
  if (!get(selectedRoom)) return "custom";
59798
59795
  const match = roomTypes.find((t) => t.label === get(selectedRoom).name);
59799
59796
  return match ? match.id : "custom";
@@ -60651,20 +60648,20 @@ function PropertiesPanel($$anchor, $$props) {
60651
60648
  reset(div_27);
60652
60649
  reset(div_26);
60653
60650
  reset(div_21);
60654
- template_effect(($0, $1) => {
60651
+ template_effect(($0) => {
60655
60652
  var _$$get$roomType, _$$get$color6;
60656
- if (select_4_value !== (select_4_value = $0)) {
60653
+ if (select_4_value !== (select_4_value = get(selectedRoomType))) {
60657
60654
  var _select_4$__value;
60658
- select_4.value = (_select_4$__value = select_4.__value = $0) !== null && _select_4$__value !== void 0 ? _select_4$__value : "", select_option(select_4, $0);
60655
+ select_4.value = (_select_4$__value = select_4.__value = get(selectedRoomType)) !== null && _select_4$__value !== void 0 ? _select_4$__value : "", select_option(select_4, get(selectedRoomType));
60659
60656
  }
60660
60657
  set_value(input_21, get(selectedRoom).name);
60661
60658
  if (select_5_value !== (select_5_value = (_$$get$roomType = get(selectedRoom).roomType) !== null && _$$get$roomType !== void 0 ? _$$get$roomType : "indoor")) {
60662
60659
  var _select_5$__value, _$$get$roomType2, _$$get$roomType3;
60663
60660
  select_5.value = (_select_5$__value = select_5.__value = (_$$get$roomType2 = get(selectedRoom).roomType) !== null && _$$get$roomType2 !== void 0 ? _$$get$roomType2 : "indoor") !== null && _select_5$__value !== void 0 ? _select_5$__value : "", select_option(select_5, (_$$get$roomType3 = get(selectedRoom).roomType) !== null && _$$get$roomType3 !== void 0 ? _$$get$roomType3 : "indoor");
60664
60661
  }
60665
- set_text(text_24, $1);
60662
+ set_text(text_24, $0);
60666
60663
  set_value(input_22, (_$$get$color6 = get(selectedRoom).color) !== null && _$$get$color6 !== void 0 ? _$$get$color6 : "#ffffff");
60667
- }, [() => get(selectedRoomType)(), () => formatArea(get(selectedRoom).area, get(settings).units)]);
60664
+ }, [() => formatArea(get(selectedRoom).area, get(settings).units)]);
60668
60665
  delegated("change", select_4, onRoomType);
60669
60666
  delegated("input", input_21, onRoomName);
60670
60667
  delegated("change", select_5, (e) => {
@@ -64743,9 +64740,6 @@ function FloorPlanCanvas($$anchor, $$props) {
64743
64740
  camY: get(camY)
64744
64741
  };
64745
64742
  }
64746
- canvasZoom.subscribe((v) => {
64747
- set(zoom, v, true);
64748
- });
64749
64743
  user_effect(() => {
64750
64744
  canvasZoom.set(get(zoom));
64751
64745
  });
@@ -66435,6 +66429,15 @@ function FloorPlanCanvas($$anchor, $$props) {
66435
66429
  img.src = f.backgroundImage.dataUrl;
66436
66430
  } else if (!(f === null || f === void 0 ? void 0 : f.backgroundImage)) set(bgImage, null);
66437
66431
  });
66432
+ const unsubZoom = canvasZoom.subscribe((v) => {
66433
+ set(zoom, v, true);
66434
+ });
66435
+ const unsubCamX = canvasCamX.subscribe((v) => {
66436
+ set(camX, v, true);
66437
+ });
66438
+ const unsubCamY = canvasCamY.subscribe((v) => {
66439
+ set(camY, v, true);
66440
+ });
66438
66441
  function handlePaste(e) {
66439
66442
  if (!e.clipboardData) return;
66440
66443
  if (get(clipboard) && get(clipboard).items.length > 0) return;
@@ -66477,6 +66480,9 @@ function FloorPlanCanvas($$anchor, $$props) {
66477
66480
  unsub13();
66478
66481
  unsub_multi();
66479
66482
  unsub14();
66483
+ unsubZoom();
66484
+ unsubCamX();
66485
+ unsubCamY();
66480
66486
  unsub_col();
66481
66487
  unsub_cols();
66482
66488
  unsub_layers();
@@ -66484,1112 +66490,6 @@ function FloorPlanCanvas($$anchor, $$props) {
66484
66490
  document.removeEventListener("paste", handlePaste);
66485
66491
  };
66486
66492
  });
66487
- user_effect(() => {
66488
- if (!get(currentFloor)) return;
66489
- setInterval(() => {
66490
- markDirty();
66491
- const heatmapMatrix = [
66492
- [
66493
- 0,
66494
- 0,
66495
- 0,
66496
- 0,
66497
- 0,
66498
- 0,
66499
- 0,
66500
- 0,
66501
- 0,
66502
- 0,
66503
- 0,
66504
- 0,
66505
- 0,
66506
- 0,
66507
- 0,
66508
- 0,
66509
- 0,
66510
- 0,
66511
- 0,
66512
- 0,
66513
- 0,
66514
- 0,
66515
- 0,
66516
- 0,
66517
- 0,
66518
- 0,
66519
- 0,
66520
- 0,
66521
- 0,
66522
- 0,
66523
- 0,
66524
- 0
66525
- ],
66526
- [
66527
- 0,
66528
- 0,
66529
- 0,
66530
- 0,
66531
- 0,
66532
- 0,
66533
- 0,
66534
- 0,
66535
- 0,
66536
- 0,
66537
- 0,
66538
- 0,
66539
- 0,
66540
- 0,
66541
- 0,
66542
- 0,
66543
- 0,
66544
- 0,
66545
- 0,
66546
- 0,
66547
- 0,
66548
- 0,
66549
- 0,
66550
- 0,
66551
- 0,
66552
- 0,
66553
- 0,
66554
- 0,
66555
- 0,
66556
- 0,
66557
- 0,
66558
- 0
66559
- ],
66560
- [
66561
- 0,
66562
- 0,
66563
- 0,
66564
- 0,
66565
- 0,
66566
- 0,
66567
- 0,
66568
- 0,
66569
- 0,
66570
- 0,
66571
- 0,
66572
- 0,
66573
- 0,
66574
- 0,
66575
- 0,
66576
- 0,
66577
- 0,
66578
- 0,
66579
- 0,
66580
- 0,
66581
- 0,
66582
- 0,
66583
- 0,
66584
- 0,
66585
- 0,
66586
- 0,
66587
- 0,
66588
- 0,
66589
- 0,
66590
- 0,
66591
- 0,
66592
- 0
66593
- ],
66594
- [
66595
- 0,
66596
- 0,
66597
- 0,
66598
- 0,
66599
- 0,
66600
- 0,
66601
- 0,
66602
- 0,
66603
- 0,
66604
- 0,
66605
- 0,
66606
- 0,
66607
- 0,
66608
- 0,
66609
- 0,
66610
- 0,
66611
- 0,
66612
- 0,
66613
- 0,
66614
- 0,
66615
- 0,
66616
- 0,
66617
- 0,
66618
- 0,
66619
- 0,
66620
- 0,
66621
- 0,
66622
- 0,
66623
- 0,
66624
- 0,
66625
- 0,
66626
- 0
66627
- ],
66628
- [
66629
- 0,
66630
- 0,
66631
- 0,
66632
- 0,
66633
- 0,
66634
- 0,
66635
- 0,
66636
- 0,
66637
- 0,
66638
- 0,
66639
- 0,
66640
- 0,
66641
- 0,
66642
- 0,
66643
- 0,
66644
- 0,
66645
- 0,
66646
- 0,
66647
- 0,
66648
- 0,
66649
- 0,
66650
- 0,
66651
- 0,
66652
- 0,
66653
- 0,
66654
- 0,
66655
- 0,
66656
- 0,
66657
- 0,
66658
- 0,
66659
- 0,
66660
- 0
66661
- ],
66662
- [
66663
- 0,
66664
- 0,
66665
- 0,
66666
- 0,
66667
- 0,
66668
- 0,
66669
- 0,
66670
- 0,
66671
- 0,
66672
- 0,
66673
- 0,
66674
- 0,
66675
- 0,
66676
- 0,
66677
- 0,
66678
- 0,
66679
- 0,
66680
- 0,
66681
- 0,
66682
- 0,
66683
- 0,
66684
- 0,
66685
- 0,
66686
- 0,
66687
- 0,
66688
- 0,
66689
- 0,
66690
- 0,
66691
- 0,
66692
- 0,
66693
- 0,
66694
- 0
66695
- ],
66696
- [
66697
- 0,
66698
- 0,
66699
- 0,
66700
- 0,
66701
- 0,
66702
- 0,
66703
- 0,
66704
- 0,
66705
- 0,
66706
- 0,
66707
- 0,
66708
- 0,
66709
- 0,
66710
- 0,
66711
- 0,
66712
- 0,
66713
- 0,
66714
- 0,
66715
- 0,
66716
- 0,
66717
- 0,
66718
- 0,
66719
- 0,
66720
- 0,
66721
- 0,
66722
- 0,
66723
- 0,
66724
- 0,
66725
- 0,
66726
- 0,
66727
- 0,
66728
- 0
66729
- ],
66730
- [
66731
- 0,
66732
- 0,
66733
- 0,
66734
- 0,
66735
- 0,
66736
- 0,
66737
- 0,
66738
- 0,
66739
- 0,
66740
- 0,
66741
- 0,
66742
- 0,
66743
- .3159328774204405,
66744
- 1.4656853131421907,
66745
- 2.2380465832282233,
66746
- 1.4656853131421907,
66747
- .3159328774204405,
66748
- 0,
66749
- 0,
66750
- 0,
66751
- 0,
66752
- 0,
66753
- 0,
66754
- 0,
66755
- 0,
66756
- 0,
66757
- 0,
66758
- 0,
66759
- 0,
66760
- 0,
66761
- 0,
66762
- 0
66763
- ],
66764
- [
66765
- 0,
66766
- 0,
66767
- 0,
66768
- 0,
66769
- 0,
66770
- 0,
66771
- 0,
66772
- 0,
66773
- 0,
66774
- 0,
66775
- 0,
66776
- 0,
66777
- 1.7489495878144512,
66778
- 7.010252524548629,
66779
- 10.597011258282999,
66780
- 7.010252524548629,
66781
- 1.7489495878144512,
66782
- 0,
66783
- 0,
66784
- 0,
66785
- 0,
66786
- 0,
66787
- 0,
66788
- 0,
66789
- 0,
66790
- 0,
66791
- 0,
66792
- 0,
66793
- 0,
66794
- 0,
66795
- 0,
66796
- 0
66797
- ],
66798
- [
66799
- 0,
66800
- 0,
66801
- 0,
66802
- 0,
66803
- 0,
66804
- 0,
66805
- 0,
66806
- 0,
66807
- 0,
66808
- 0,
66809
- 0,
66810
- 0,
66811
- 3.3289241086779624,
66812
- 13.46177725998435,
66813
- 20.235236701064228,
66814
- 13.590541779525635,
66815
- 3.4380594435639265,
66816
- .00915612667564332,
66817
- 0,
66818
- 0,
66819
- 0,
66820
- 0,
66821
- 0,
66822
- 0,
66823
- 0,
66824
- 0,
66825
- 0,
66826
- 0,
66827
- 0,
66828
- 0,
66829
- 0,
66830
- 0
66831
- ],
66832
- [
66833
- 0,
66834
- 0,
66835
- 0,
66836
- 0,
66837
- 0,
66838
- 0,
66839
- 0,
66840
- 0,
66841
- 0,
66842
- 0,
66843
- 0,
66844
- 0,
66845
- 3.2148496888753932,
66846
- 13.320879325153319,
66847
- 21.57578250930066,
66848
- 16.342286624307704,
66849
- 5.569414220457003,
66850
- .6079740421039851,
66851
- 0,
66852
- 0,
66853
- 0,
66854
- 0,
66855
- 0,
66856
- 0,
66857
- 0,
66858
- 0,
66859
- 0,
66860
- 0,
66861
- 0,
66862
- 0,
66863
- 0,
66864
- 0
66865
- ],
66866
- [
66867
- 0,
66868
- 0,
66869
- 0,
66870
- 0,
66871
- 0,
66872
- 0,
66873
- 0,
66874
- 0,
66875
- 0,
66876
- 0,
66877
- 0,
66878
- 0,
66879
- 1.471089931923573,
66880
- 8.2191207324426,
66881
- 17.838951126796992,
66882
- 19.032501579269645,
66883
- 10.168729572784246,
66884
- 2.183833478003975,
66885
- 0,
66886
- 0,
66887
- 0,
66888
- 0,
66889
- 0,
66890
- 0,
66891
- 0,
66892
- 0,
66893
- 0,
66894
- 0,
66895
- 0,
66896
- 0,
66897
- 0,
66898
- 0
66899
- ],
66900
- [
66901
- 0,
66902
- 0,
66903
- 0,
66904
- 0,
66905
- 0,
66906
- 0,
66907
- 0,
66908
- 0,
66909
- 0,
66910
- 0,
66911
- 0,
66912
- 0,
66913
- .30224323366570666,
66914
- 4.469359740497559,
66915
- 14.670431219686673,
66916
- 20.333387296969498,
66917
- 13.054592947321611,
66918
- 3.1902302512972374,
66919
- 0,
66920
- 0,
66921
- 0,
66922
- 0,
66923
- 0,
66924
- 0,
66925
- 0,
66926
- 0,
66927
- 0,
66928
- 0,
66929
- 0,
66930
- 0,
66931
- 0,
66932
- 0
66933
- ],
66934
- [
66935
- 0,
66936
- 0,
66937
- 0,
66938
- 0,
66939
- 0,
66940
- 0,
66941
- 0,
66942
- .8712958885928778,
66943
- 4.101109796621668,
66944
- 7.049595450791787,
66945
- 6.013717307819157,
66946
- 2.4950259463993585,
66947
- .44436828921160365,
66948
- 2.3964385376201838,
66949
- 8.995383597734405,
66950
- 13.185675552510842,
66951
- 8.716708041551543,
66952
- 2.1623510704265803,
66953
- 0,
66954
- 0,
66955
- 0,
66956
- 0,
66957
- 0,
66958
- 0,
66959
- 0,
66960
- 0,
66961
- 0,
66962
- 0,
66963
- 0,
66964
- 0,
66965
- 0,
66966
- 0
66967
- ],
66968
- [
66969
- 0,
66970
- 0,
66971
- 0,
66972
- 0,
66973
- 0,
66974
- 0,
66975
- 0,
66976
- 3.62130425013895,
66977
- 16.246445581668944,
66978
- 28.185625524032776,
66979
- 24.0135529219635,
66980
- 9.834207494427838,
66981
- 1.5755845092412992,
66982
- .7273170478700652,
66983
- 2.61589141718046,
66984
- 3.749571783336128,
66985
- 2.426392038976114,
66986
- .5824057586549773,
66987
- 0,
66988
- 0,
66989
- 0,
66990
- 0,
66991
- 0,
66992
- 0,
66993
- 0,
66994
- 0,
66995
- .5421635625869271,
66996
- 2.2065200861983407,
66997
- 3.342547381956746,
66998
- 2.2065200861983407,
66999
- .5421635625869271,
67000
- 0
67001
- ],
67002
- [
67003
- 0,
67004
- 0,
67005
- 0,
67006
- 0,
67007
- 0,
67008
- 0,
67009
- 0,
67010
- 5.549901318362378,
67011
- 24.32853931235515,
67012
- 42.36138150541803,
67013
- 35.94102328030143,
67014
- 14.818839539693103,
67015
- 2.3194161353148814,
67016
- .05101033364693949,
67017
- .16491621404182252,
67018
- .1777607033571859,
67019
- .12032812505256472,
67020
- .017569266904996134,
67021
- 0,
67022
- 0,
67023
- 0,
67024
- 0,
67025
- 0,
67026
- 0,
67027
- 0,
67028
- 0,
67029
- 2.9576258950346093,
67030
- 11.84562175292669,
67031
- 17.787556061594508,
67032
- 11.84562175292669,
67033
- 2.9576258950346093,
67034
- 0
67035
- ],
67036
- [
67037
- 0,
67038
- 0,
67039
- 0,
67040
- 0,
67041
- 0,
67042
- 0,
67043
- 0,
67044
- 3.62130425013895,
67045
- 16.246445581668944,
67046
- 28.185625524032776,
67047
- 24.0135529219635,
67048
- 9.834207494427838,
67049
- 1.5309964202520414,
67050
- 0,
67051
- 0,
67052
- 0,
67053
- 0,
67054
- 0,
67055
- 0,
67056
- 0,
67057
- 0,
67058
- 0,
67059
- 0,
67060
- 0,
67061
- 0,
67062
- 0,
67063
- 6.348491293238841,
67064
- 25.309150516517526,
67065
- 37.96250650263207,
67066
- 25.309150516517526,
67067
- 6.348491293238841,
67068
- 0
67069
- ],
67070
- [
67071
- 0,
67072
- 0,
67073
- 0,
67074
- 0,
67075
- .32082320386030533,
67076
- 1.2199857338206974,
67077
- 1.8460462046420483,
67078
- 2.1325554284523793,
67079
- 4.379383234527166,
67080
- 7.049595450791787,
67081
- 6.013717307819157,
67082
- 2.4950259463993585,
67083
- .3886331779750314,
67084
- 0,
67085
- 0,
67086
- 0,
67087
- 0,
67088
- 0,
67089
- 0,
67090
- 0,
67091
- 0,
67092
- 0,
67093
- 0,
67094
- 0,
67095
- 0,
67096
- 0,
67097
- 6.723278406098134,
67098
- 26.889274492038524,
67099
- 40.34693760289919,
67100
- 26.889274492038524,
67101
- 6.723278406098134,
67102
- 0
67103
- ],
67104
- [
67105
- 0,
67106
- 0,
67107
- 0,
67108
- 0,
67109
- 2.2804956914871695,
67110
- 8.96059158937199,
67111
- 13.408676109914708,
67112
- 8.96059158937199,
67113
- 2.2804956914871695,
67114
- 0,
67115
- 0,
67116
- 0,
67117
- 0,
67118
- 0,
67119
- 0,
67120
- 0,
67121
- 0,
67122
- 0,
67123
- 0,
67124
- 0,
67125
- 0,
67126
- 0,
67127
- 0,
67128
- 0,
67129
- 0,
67130
- 0,
67131
- 3.610311889272976,
67132
- 14.18903058720386,
67133
- 21.35656319734618,
67134
- 15.52310871608614,
67135
- 8.830853849884093,
67136
- 7.821632516665724
67137
- ],
67138
- [
67139
- 0,
67140
- 0,
67141
- 0,
67142
- 0,
67143
- 5.861518314504249,
67144
- 23.379493778146163,
67145
- 35.09863018520233,
67146
- 23.379493778146163,
67147
- 5.861518314504249,
67148
- 0,
67149
- 0,
67150
- 0,
67151
- 0,
67152
- 0,
67153
- 0,
67154
- 0,
67155
- 0,
67156
- 0,
67157
- 0,
67158
- 0,
67159
- 0,
67160
- 0,
67161
- 0,
67162
- 0,
67163
- 0,
67164
- 0,
67165
- .7400359281404749,
67166
- 3.0082191313345596,
67167
- 4.511243556428142,
67168
- 8.25225708991524,
67169
- 21.61113659978852,
67170
- 31.371979438413785
67171
- ],
67172
- [
67173
- 0,
67174
- 0,
67175
- 0,
67176
- 0,
67177
- 7.243115248642567,
67178
- 28.906850697487346,
67179
- 43.39219038599119,
67180
- 28.906850697487346,
67181
- 7.243115248642567,
67182
- 0,
67183
- 0,
67184
- 0,
67185
- 0,
67186
- 0,
67187
- 0,
67188
- 0,
67189
- 0,
67190
- 0,
67191
- 0,
67192
- 0,
67193
- 0,
67194
- 0,
67195
- 0,
67196
- 0,
67197
- 0,
67198
- 0,
67199
- 0,
67200
- 0,
67201
- 0,
67202
- 7.821632516665724,
67203
- 31.371979438413785,
67204
- 46.96473075085739
67205
- ],
67206
- [
67207
- 0,
67208
- 0,
67209
- 0,
67210
- 0,
67211
- 4.32482477999109,
67212
- 17.186780480887943,
67213
- 25.8249366255257,
67214
- 17.186780480887943,
67215
- 4.32482477999109,
67216
- 0,
67217
- 0,
67218
- 0,
67219
- 0,
67220
- 0,
67221
- 0,
67222
- 0,
67223
- 0,
67224
- 0,
67225
- 0,
67226
- 0,
67227
- 0,
67228
- 0,
67229
- 0,
67230
- 0,
67231
- 0,
67232
- 0,
67233
- 0,
67234
- 0,
67235
- 0,
67236
- 5.226011941752098,
67237
- 20.827286571029607,
67238
- 31.371979438413785
67239
- ],
67240
- [
67241
- 0,
67242
- 0,
67243
- 0,
67244
- 0,
67245
- 1.0111655316014927,
67246
- 3.9864631299897444,
67247
- 5.981469083020068,
67248
- 3.9864631299897444,
67249
- 1.0111655316014927,
67250
- 0,
67251
- 0,
67252
- 0,
67253
- 0,
67254
- 0,
67255
- 0,
67256
- 0,
67257
- 0,
67258
- 0,
67259
- 0,
67260
- 0,
67261
- 0,
67262
- 0,
67263
- 0,
67264
- 0,
67265
- 0,
67266
- 0,
67267
- 0,
67268
- 0,
67269
- 0,
67270
- 1.386066255607005,
67271
- 5.226011941752098,
67272
- 7.821632516665724
67273
- ],
67274
- [
67275
- 0,
67276
- 0,
67277
- 0,
67278
- 0,
67279
- 0,
67280
- 0,
67281
- 0,
67282
- 0,
67283
- 0,
67284
- 0,
67285
- 0,
67286
- 0,
67287
- 0,
67288
- 0,
67289
- 0,
67290
- 0,
67291
- 0,
67292
- 0,
67293
- 0,
67294
- 0,
67295
- 0,
67296
- 0,
67297
- 0,
67298
- 0,
67299
- 0,
67300
- 0,
67301
- 0,
67302
- 0,
67303
- 0,
67304
- 0,
67305
- 0,
67306
- 0
67307
- ],
67308
- [
67309
- 0,
67310
- 0,
67311
- 0,
67312
- 0,
67313
- 0,
67314
- 0,
67315
- 0,
67316
- 0,
67317
- 0,
67318
- .05458070912699062,
67319
- .15528137571229708,
67320
- .15187574183847025,
67321
- .06974200470241036,
67322
- 0,
67323
- 0,
67324
- 0,
67325
- 0,
67326
- 0,
67327
- 0,
67328
- 0,
67329
- 0,
67330
- 0,
67331
- 0,
67332
- 0,
67333
- 0,
67334
- 0,
67335
- 0,
67336
- 0,
67337
- 0,
67338
- 0,
67339
- 0,
67340
- 0
67341
- ],
67342
- [
67343
- 0,
67344
- 0,
67345
- 0,
67346
- 0,
67347
- 0,
67348
- 0,
67349
- 0,
67350
- 0,
67351
- .05458070912699062,
67352
- .2755754209878876,
67353
- .5707063337010662,
67354
- .5838714443792508,
67355
- .31029220828859827,
67356
- .06974200470241036,
67357
- 0,
67358
- 0,
67359
- 0,
67360
- 0,
67361
- .02805561155784787,
67362
- .8189018232615914,
67363
- 2.5324966794862513,
67364
- 3.4377154290206784,
67365
- 2.1308395665461624,
67366
- .4650594240098488,
67367
- 0,
67368
- 0,
67369
- 0,
67370
- 0,
67371
- 0,
67372
- 0,
67373
- 0,
67374
- 0
67375
- ],
67376
- [
67377
- 0,
67378
- 0,
67379
- 0,
67380
- 0,
67381
- 0,
67382
- 0,
67383
- 0,
67384
- 0,
67385
- .08553937100988673,
67386
- .41228986725093814,
67387
- .8529789776313961,
67388
- .8882858218170526,
67389
- .46357739910366025,
67390
- .0972950327114796,
67391
- 0,
67392
- 0,
67393
- 0,
67394
- 0,
67395
- .3532485267308754,
67396
- 3.499619222062779,
67397
- 10.427637306724009,
67398
- 13.795863309244472,
67399
- 8.56406987933662,
67400
- 2.084587966363261,
67401
- 0,
67402
- 0,
67403
- 0,
67404
- 0,
67405
- 0,
67406
- 0,
67407
- 0,
67408
- 0
67409
- ],
67410
- [
67411
- 0,
67412
- 0,
67413
- 0,
67414
- 0,
67415
- 0,
67416
- 0,
67417
- 0,
67418
- 0,
67419
- .05458070912699062,
67420
- .2755754209878876,
67421
- .5707063337010662,
67422
- .5838714443792508,
67423
- .31029220828859827,
67424
- .06974200470241036,
67425
- 0,
67426
- 0,
67427
- 0,
67428
- .049318035756509136,
67429
- 1.0607933641418696,
67430
- 6.758563725967109,
67431
- 17.660755342385897,
67432
- 21.973928874871856,
67433
- 13.201476985075344,
67434
- 3.101022144002237,
67435
- 0,
67436
- 0,
67437
- 0,
67438
- 0,
67439
- 0,
67440
- 0,
67441
- 0,
67442
- 0
67443
- ],
67444
- [
67445
- 0,
67446
- 0,
67447
- 0,
67448
- 0,
67449
- 0,
67450
- 0,
67451
- 0,
67452
- 0,
67453
- 0,
67454
- .05458070912699062,
67455
- .15528137571229708,
67456
- .15187574183847025,
67457
- .06974200470241036,
67458
- 0,
67459
- 0,
67460
- 0,
67461
- .08786109582645688,
67462
- .7046356886390628,
67463
- 3.0107989977663894,
67464
- 9.51274060076616,
67465
- 17.749511390220455,
67466
- 18.26171939391789,
67467
- 9.630263523792657,
67468
- 2.084587966363261,
67469
- 0,
67470
- 0,
67471
- 0,
67472
- 0,
67473
- 0,
67474
- 0,
67475
- 0,
67476
- 0
67477
- ],
67478
- [
67479
- 0,
67480
- 0,
67481
- 0,
67482
- 0,
67483
- 0,
67484
- 0,
67485
- 0,
67486
- 0,
67487
- 0,
67488
- 0,
67489
- 0,
67490
- 0,
67491
- 1.7382367811803743,
67492
- 6.78625235876699,
67493
- 10.215056932817292,
67494
- 7.28439193353878,
67495
- 3.243933616660711,
67496
- 3.1636969367350174,
67497
- 6.726890242944553,
67498
- 11.793933219797037,
67499
- 14.018480108478876,
67500
- 9.836469200652415,
67501
- 3.565238303086889,
67502
- .4650594240098488,
67503
- 0,
67504
- 0,
67505
- 0,
67506
- 0,
67507
- 0,
67508
- 0,
67509
- 0,
67510
- 0
67511
- ],
67512
- [
67513
- 0,
67514
- 0,
67515
- 0,
67516
- 0,
67517
- 0,
67518
- 0,
67519
- 0,
67520
- 0,
67521
- 0,
67522
- 0,
67523
- 0,
67524
- 0,
67525
- 6.6983617356443,
67526
- 26.99436500222664,
67527
- 41.353519873356255,
67528
- 29.282163948524662,
67529
- 11.3741195154941,
67530
- 7.413346519620399,
67531
- 10.283468040894338,
67532
- 11.90128859290927,
67533
- 9.570529949946668,
67534
- 4.526681935693334,
67535
- .8914940911015187,
67536
- 0,
67537
- 0,
67538
- 0,
67539
- 0,
67540
- 0,
67541
- 0,
67542
- 0,
67543
- 0,
67544
- 0
67545
- ],
67546
- [
67547
- 0,
67548
- 0,
67549
- 0,
67550
- 0,
67551
- 0,
67552
- 0,
67553
- 0,
67554
- 0,
67555
- 0,
67556
- 0,
67557
- 0,
67558
- 0,
67559
- 10.047028886051624,
67560
- 40.69152763227778,
67561
- 61.87097958316954,
67562
- 44.034938408633856,
67563
- 16.762310030892145,
67564
- 9.760527430556891,
67565
- 11.69769115898553,
67566
- 11.007073791008297,
67567
- 7.176097387403954,
67568
- 2.7361326724525514,
67569
- .505476251361877,
67570
- 0,
67571
- 0,
67572
- 0,
67573
- 0,
67574
- 0,
67575
- 0,
67576
- 0,
67577
- 0,
67578
- 0
67579
- ]
67580
- ];
67581
- set(currentFloor, {
67582
- ...get(currentFloor),
67583
- furniture: get(currentFloor).furniture.map((item) => {
67584
- if (item.catalogId === "camera") return {
67585
- ...item,
67586
- heatmapMatrix
67587
- };
67588
- return item;
67589
- })
67590
- }, true);
67591
- }, 5e3);
67592
- });
67593
66493
  /** Compute world bounding box of all elements */
67594
66494
  function getWorldBBox() {
67595
66495
  if (!get(currentFloor)) return null;
@@ -70673,11 +69573,10 @@ init_onboarding_svelte();
70673
69573
  var root_1 = /* @__PURE__ */ from_html(`<div class="fixed z-[9999] pointer-events-auto"><div><p class="mb-2"> </p> <button class="text-xs font-medium px-3 py-1 rounded-lg bg-blue-500 hover:bg-blue-400 transition-colors">Got it</button></div></div>`);
70674
69574
  function OnboardingTooltip($$anchor, $$props) {
70675
69575
  push($$props, true);
70676
- let tip = /* @__PURE__ */ user_derived(getActiveTip);
70677
69576
  let visible = /* @__PURE__ */ state(false);
70678
69577
  let autoTimer = null;
70679
69578
  user_effect(() => {
70680
- if (get(tip)) {
69579
+ if (activeTipState.current) {
70681
69580
  set(visible, false);
70682
69581
  requestAnimationFrame(() => {
70683
69582
  set(visible, true);
@@ -70697,6 +69596,7 @@ function OnboardingTooltip($$anchor, $$props) {
70697
69596
  var fragment = comment();
70698
69597
  var node = first_child(fragment);
70699
69598
  var consequent = ($$anchor) => {
69599
+ const tip = /* @__PURE__ */ user_derived(() => activeTipState.current);
70700
69600
  const msg = /* @__PURE__ */ user_derived(() => TIP_MESSAGES[get(tip).id]);
70701
69601
  const clampedX = /* @__PURE__ */ user_derived(() => Math.min(get(tip).x, (typeof window !== "undefined" ? window.innerWidth : 1200) - 320));
70702
69602
  const clampedY = /* @__PURE__ */ user_derived(() => Math.min(get(tip).y, (typeof window !== "undefined" ? window.innerHeight : 800) - 100));
@@ -70726,7 +69626,7 @@ function OnboardingTooltip($$anchor, $$props) {
70726
69626
  append($$anchor, div);
70727
69627
  };
70728
69628
  if_block(node, ($$render) => {
70729
- if (get(tip)) $$render(consequent);
69629
+ if (activeTipState.current) $$render(consequent);
70730
69630
  });
70731
69631
  append($$anchor, fragment);
70732
69632
  pop();