ui: fixes

This commit is contained in:
Andras Bacsai
2022-08-10 08:54:26 +00:00
parent a19803e08a
commit 91d135bff8
43 changed files with 559 additions and 893 deletions

View File

@@ -78,7 +78,6 @@
import '../tailwind.css';
import Cookies from 'js-cookie';
import { fade } from 'svelte/transition';
import { SvelteToast } from '@zerodevx/svelte-toast';
import { navigating, page } from '$app/stores';
import { get } from '$lib/api';
@@ -112,7 +111,6 @@
{/if}
</svelte:head>
<Toasts />
<!-- <SvelteToast options={{ intro: { y: -64 }, duration: 3000, pausable: true }} /> -->
{#if $navigating}
<div out:fade={{ delay: 100 }}>
<PageLoader />
@@ -128,10 +126,10 @@
<a
sveltekit:prefetch
href="/"
class="icons tooltip-right bg-coolgray-200 hover:text-white"
class="icons tooltip tooltip-right bg-coolgray-200 hover:text-white"
class:text-white={$page.url.pathname === '/'}
class:bg-coolgray-500={$page.url.pathname === '/'}
data-tooltip="Dashboard"
data-tip="Dashboard"
>
<svg
xmlns="http://www.w3.org/2000/svg"
@@ -155,12 +153,12 @@
<a
sveltekit:prefetch
href="/applications"
class="icons tooltip-green-500 tooltip-right bg-coolgray-200 hover:text-green-500"
class:text-green-500={$page.url.pathname.startsWith('/applications') ||
class="icons tooltip tooltip-right bg-coolgray-200"
class:text-applications={$page.url.pathname.startsWith('/applications') ||
$page.url.pathname.startsWith('/new/application')}
class:bg-coolgray-500={$page.url.pathname.startsWith('/applications') ||
$page.url.pathname.startsWith('/new/application')}
data-tooltip="Applications"
data-tip="Applications"
>
<svg
xmlns="http://www.w3.org/2000/svg"
@@ -183,12 +181,12 @@
<a
sveltekit:prefetch
href="/sources"
class="icons tooltip-orange-500 tooltip-right bg-coolgray-200 hover:text-orange-500"
class:text-orange-500={$page.url.pathname.startsWith('/sources') ||
class="icons tooltip tooltip-right bg-coolgray-200"
class:text-sources={$page.url.pathname.startsWith('/sources') ||
$page.url.pathname.startsWith('/new/source')}
class:bg-coolgray-500={$page.url.pathname.startsWith('/sources') ||
$page.url.pathname.startsWith('/new/source')}
data-tooltip="Git Sources"
data-tip="Git Sources"
>
<svg
xmlns="http://www.w3.org/2000/svg"
@@ -212,12 +210,12 @@
<a
sveltekit:prefetch
href="/destinations"
class="icons tooltip-sky-500 tooltip-right bg-coolgray-200 hover:text-sky-500"
class:text-sky-500={$page.url.pathname.startsWith('/destinations') ||
class="icons tooltip tooltip-right bg-coolgray-200"
class:text-destinations={$page.url.pathname.startsWith('/destinations') ||
$page.url.pathname.startsWith('/new/destination')}
class:bg-coolgray-500={$page.url.pathname.startsWith('/destinations') ||
$page.url.pathname.startsWith('/new/destination')}
data-tooltip="Destinations"
data-tip="Destinations"
>
<svg
xmlns="http://www.w3.org/2000/svg"
@@ -247,12 +245,12 @@
<a
sveltekit:prefetch
href="/databases"
class="icons tooltip-purple-500 tooltip-right bg-coolgray-200 hover:text-purple-500"
class:text-purple-500={$page.url.pathname.startsWith('/databases') ||
class="icons tooltip tooltip-right bg-coolgray-200"
class:text-databases={$page.url.pathname.startsWith('/databases') ||
$page.url.pathname.startsWith('/new/database')}
class:bg-coolgray-500={$page.url.pathname.startsWith('/databases') ||
$page.url.pathname.startsWith('/new/database')}
data-tooltip="Databases"
data-tip="Databases"
>
<svg
xmlns="http://www.w3.org/2000/svg"
@@ -273,12 +271,12 @@
<a
sveltekit:prefetch
href="/services"
class="icons tooltip-pink-500 tooltip-right bg-coolgray-200 hover:text-pink-500"
class:text-pink-500={$page.url.pathname.startsWith('/services') ||
class="icons tooltip tooltip-right bg-coolgray-200"
class:text-services={$page.url.pathname.startsWith('/services') ||
$page.url.pathname.startsWith('/new/service')}
class:bg-coolgray-500={$page.url.pathname.startsWith('/services') ||
$page.url.pathname.startsWith('/new/service')}
data-tooltip="Services"
data-tip="Services"
>
<svg
xmlns="http://www.w3.org/2000/svg"
@@ -302,10 +300,10 @@
<a
sveltekit:prefetch
href="/iam"
class="icons tooltip-fuchsia-500 tooltip-right bg-coolgray-200 hover:text-fuchsia-500"
class:text-fuchsia-500={$page.url.pathname.startsWith('/iam')}
class="icons tooltip tooltip-right bg-coolgray-200"
class:text-iam={$page.url.pathname.startsWith('/iam')}
class:bg-coolgray-500={$page.url.pathname.startsWith('/iam')}
data-tooltip="IAM"
data-tip="IAM"
><svg
xmlns="http://www.w3.org/2000/svg"
class="h-8 w-8"
@@ -326,10 +324,10 @@
<a
sveltekit:prefetch
href={$appSession.teamId === '0' ? '/settings/global' : '/settings/ssh-keys'}
class="icons tooltip-yellow-500 tooltip-right bg-coolgray-200 hover:text-yellow-500"
class:text-yellow-500={$page.url.pathname.startsWith('/settings')}
class="icons tooltip tooltip-right bg-coolgray-200"
class:text-settings={$page.url.pathname.startsWith('/settings')}
class:bg-coolgray-500={$page.url.pathname.startsWith('/settings')}
data-tooltip="Settings"
data-tip="Settings"
>
<svg
xmlns="http://www.w3.org/2000/svg"
@@ -350,8 +348,8 @@
</a>
<div
class="icons tooltip-red-500 tooltip-right bg-coolgray-200 hover:text-red-500"
data-tooltip="Logout"
class="icons tooltip tooltip-right bg-coolgray-200 hover:text-error"
data-tip="Logout"
on:click={logout}
>
<svg