File tree Expand file tree Collapse file tree 3 files changed +13
-7
lines changed
src/lib/maplibre/controls Expand file tree Collapse file tree 3 files changed +13
-7
lines changed Original file line number Diff line number Diff line change 11{
22 "name" : " @viamrobotics/prime-blocks" ,
3- "version" : " 0.1.10 " ,
3+ "version" : " 0.1.11 " ,
44 "repository" : {
55 "type" : " git" ,
66 "url" : " https://github.com/viamrobotics/prime.git" ,
Original file line number Diff line number Diff line change @@ -44,15 +44,18 @@ onMount(() => {
4444 map .off (' mousedown' , stop );
4545 };
4646});
47+
48+ const handleClick = (event : MouseEvent ) => {
49+ event .stopPropagation ();
50+ following = ! following ;
51+ onChange ?.(following );
52+ };
4753 </script >
4854
4955<Button
5056 disabled ={lng === undefined || lat === undefined }
51- on:click ={(event ) => {
52- event .stopPropagation ();
53- following = ! following ;
54- onChange ?.(following );
55- }}
57+ on:click ={handleClick }
58+ onclick ={handleClick }
5659>
5760 <Icon
5861 name ={following ? ' navigation-variant' : ' navigation-variant-outline' }
Original file line number Diff line number Diff line change @@ -20,6 +20,9 @@ const onClick = () => {
2020};
2121 </script >
2222
23- <Button on:click ={onClick }>
23+ <Button
24+ onclick ={onClick }
25+ on:click ={onClick }
26+ >
2427 {satellite ? ' Map' : ' Satellite' }
2528</Button >
You can’t perform that action at this time.
0 commit comments