refac
This commit is contained in:
@@ -240,8 +240,13 @@
|
|||||||
href="/playground"
|
href="/playground"
|
||||||
draggable="false"
|
draggable="false"
|
||||||
class="flex rounded-xl py-1.5 px-3 w-full hover:bg-gray-50 dark:hover:bg-gray-800 transition cursor-pointer select-none"
|
class="flex rounded-xl py-1.5 px-3 w-full hover:bg-gray-50 dark:hover:bg-gray-800 transition cursor-pointer select-none"
|
||||||
on:click={async () => {
|
on:click={async (e) => {
|
||||||
|
if (e.metaKey || e.ctrlKey || e.shiftKey || e.button === 1) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
e.preventDefault();
|
||||||
show = false;
|
show = false;
|
||||||
|
goto('/playground');
|
||||||
if ($mobile) {
|
if ($mobile) {
|
||||||
await tick();
|
await tick();
|
||||||
showSidebar.set(false);
|
showSidebar.set(false);
|
||||||
@@ -257,8 +262,13 @@
|
|||||||
href="/admin"
|
href="/admin"
|
||||||
draggable="false"
|
draggable="false"
|
||||||
class="flex rounded-xl py-1.5 px-3 w-full hover:bg-gray-50 dark:hover:bg-gray-800 transition cursor-pointer select-none"
|
class="flex rounded-xl py-1.5 px-3 w-full hover:bg-gray-50 dark:hover:bg-gray-800 transition cursor-pointer select-none"
|
||||||
on:click={async () => {
|
on:click={async (e) => {
|
||||||
|
if (e.metaKey || e.ctrlKey || e.shiftKey || e.button === 1) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
e.preventDefault();
|
||||||
show = false;
|
show = false;
|
||||||
|
goto('/admin');
|
||||||
if ($mobile) {
|
if ($mobile) {
|
||||||
await tick();
|
await tick();
|
||||||
showSidebar.set(false);
|
showSidebar.set(false);
|
||||||
|
|||||||
Reference in New Issue
Block a user