Merge branch 'main' into profile

This commit is contained in:
Torsten Dittmann
2022-09-09 15:09:16 +02:00
committed by GitHub
8 changed files with 69 additions and 38 deletions
+14 -14
View File
@@ -9,8 +9,8 @@
"version": "0.0.1",
"dependencies": {
"@aw-labs/appwrite-console": "^1.0.0-0",
"@aw-labs/icons": "0.0.0-53",
"@aw-labs/ui": "0.0.0-53",
"@aw-labs/icons": "0.0.0-54",
"@aw-labs/ui": "0.0.0-54",
"echarts": "^5.3.3",
"tippy.js": "^6.3.7",
"web-vitals": "^2.1.4"
@@ -77,14 +77,14 @@
}
},
"node_modules/@aw-labs/icons": {
"version": "0.0.0-53",
"resolved": "https://registry.npmjs.org/@aw-labs/icons/-/icons-0.0.0-53.tgz",
"integrity": "sha512-9UhHTGajh2HJun2uYbcMyxRtPsgIQ5CXf8mn/sCiRyZJIw5FYtuxTSkP/35hv2zJsVq/mY09HvfdX3w4XVKItg=="
"version": "0.0.0-54",
"resolved": "https://registry.npmjs.org/@aw-labs/icons/-/icons-0.0.0-54.tgz",
"integrity": "sha512-lk+uikRag3Y5Rm4Ys5lHBhknhCVpA/oTaIBBDgB6nidqtJdqLpa+Nur4BdsBXOEZTlo2yOiWU2NNAl6ZzUzFGQ=="
},
"node_modules/@aw-labs/ui": {
"version": "0.0.0-53",
"resolved": "https://registry.npmjs.org/@aw-labs/ui/-/ui-0.0.0-53.tgz",
"integrity": "sha512-5ftq05SZ9lVdXGHgHIyxwtGznfKsCa1fKPpZhS+279IUTIB+H7GIq0g2U2EzRBj7ht0PXNZJNO4n9hO2ItDJwA==",
"version": "0.0.0-54",
"resolved": "https://registry.npmjs.org/@aw-labs/ui/-/ui-0.0.0-54.tgz",
"integrity": "sha512-1Dj216qPaVKdBScW+1XIp6IOVBdcv/kYjiWO4YiFtoQ/IaayoSO6njlAPTwyQzclmX5A/9suEGadOVa3NZqbgQ==",
"dependencies": {
"@aw-labs/icons": "*"
}
@@ -7698,14 +7698,14 @@
}
},
"@aw-labs/icons": {
"version": "0.0.0-53",
"resolved": "https://registry.npmjs.org/@aw-labs/icons/-/icons-0.0.0-53.tgz",
"integrity": "sha512-9UhHTGajh2HJun2uYbcMyxRtPsgIQ5CXf8mn/sCiRyZJIw5FYtuxTSkP/35hv2zJsVq/mY09HvfdX3w4XVKItg=="
"version": "0.0.0-54",
"resolved": "https://registry.npmjs.org/@aw-labs/icons/-/icons-0.0.0-54.tgz",
"integrity": "sha512-lk+uikRag3Y5Rm4Ys5lHBhknhCVpA/oTaIBBDgB6nidqtJdqLpa+Nur4BdsBXOEZTlo2yOiWU2NNAl6ZzUzFGQ=="
},
"@aw-labs/ui": {
"version": "0.0.0-53",
"resolved": "https://registry.npmjs.org/@aw-labs/ui/-/ui-0.0.0-53.tgz",
"integrity": "sha512-5ftq05SZ9lVdXGHgHIyxwtGznfKsCa1fKPpZhS+279IUTIB+H7GIq0g2U2EzRBj7ht0PXNZJNO4n9hO2ItDJwA==",
"version": "0.0.0-54",
"resolved": "https://registry.npmjs.org/@aw-labs/ui/-/ui-0.0.0-54.tgz",
"integrity": "sha512-1Dj216qPaVKdBScW+1XIp6IOVBdcv/kYjiWO4YiFtoQ/IaayoSO6njlAPTwyQzclmX5A/9suEGadOVa3NZqbgQ==",
"requires": {
"@aw-labs/icons": "*"
}
+2 -2
View File
@@ -19,8 +19,8 @@
},
"dependencies": {
"@aw-labs/appwrite-console": "^1.0.0-0",
"@aw-labs/icons": "0.0.0-53",
"@aw-labs/ui": "0.0.0-53",
"@aw-labs/icons": "0.0.0-54",
"@aw-labs/ui": "0.0.0-54",
"echarts": "^5.3.3",
"tippy.js": "^6.3.7",
"web-vitals": "^2.1.4"
+15 -8
View File
@@ -4,16 +4,23 @@
<a class="card" {href}>
<div class="grid-item-1">
<div class="eyebrow-heading-3"><slot name="eyebrow" /></div>
<h2 class="heading-level-6"><slot name="title" /></h2>
<div class="status">
<div class="grid-item-1-start-start">
<div class="eyebrow-heading-3"><slot name="eyebrow" /></div>
<h2 class="heading-level-6"><slot name="title" /></h2>
</div>
<div class="grid-item-1-start-end">
<slot name="status" />
</div>
<div class="options">
<slot />
<div class="grid-item-1-end-start">
<div class="u-flex u-gap-16 u-flex-wrap">
<slot />
</div>
</div>
<div class="grid-item-1-end-end">
<ul class="icons u-flex u-gap-8">
<slot name="icons" />
</ul>
</div>
<ul class="icons u-flex u-gap-8">
<slot name="icons" />
</ul>
</div>
</a>
+15 -8
View File
@@ -10,6 +10,7 @@
export let error: string = null;
export let closable = true;
let alert: HTMLElement;
const dispatch = createEventDispatcher();
const transitionFly: FlyParams = {
duration: 150,
@@ -48,6 +49,10 @@
document.body.classList.remove('u-overflow-hidden');
}
}
$: if (error) {
alert?.scrollIntoView({ behavior: 'smooth', block: 'start', inline: 'nearest' });
}
</script>
<svelte:window on:keydown={handleKeydown} />
@@ -81,14 +86,16 @@
</header>
<div class="modal-content">
{#if error}
<Alert
dismissible
type="warning"
on:dismiss={() => {
error = null;
}}>
{error}
</Alert>
<div bind:this={alert}>
<Alert
dismissible
type="warning"
on:dismiss={() => {
error = null;
}}>
{error}
</Alert>
</div>
{/if}
<slot />
</div>
+2 -2
View File
@@ -4,8 +4,8 @@
</script>
{#if $notifications}
<section class="toaster">
<ul class="toaster-list">
<section>
<ul class="u-flex u-flex-vertical u-gap-16">
{#each $notifications as notification (notification.id)}
<Notification
type={notification.type}
+17 -2
View File
@@ -15,10 +15,12 @@
import { base } from '$app/paths';
import { user } from '$lib/stores/user';
import { goto } from '$app/navigation';
import { browser } from '$app/env';
export let isOpen = false;
export let showSideNavigation = false;
let y: number;
let tabsList: HTMLUListElement;
let showLeft = false;
let showRight = false;
@@ -84,9 +86,21 @@
}
};
};
const toggleMenu = () => {
y = 0;
isOpen = !isOpen;
if (browser) {
if (isOpen) {
document.body.classList.add('u-overflow-hidden');
} else {
document.body.classList.remove('u-overflow-hidden');
}
}
};
</script>
<svelte:window on:resize={throttle(onScroll, 25)} />
<svelte:window bind:scrollY={y} on:resize={throttle(onScroll, 25)} />
<main
class:grid-with-side={showSideNavigation}
@@ -94,9 +108,10 @@
class:is-open={isOpen}>
<header class="main-header">
<button
class:u-hide={!showSideNavigation}
class="icon-button is-no-desktop"
aria-label="Open Menu"
on:click={() => (isOpen = !isOpen)}>
on:click={toggleMenu}>
<span class:icon-x={isOpen} class:icon-menu={!isOpen} aria-hidden="true" />
</button>
<slot name="header" />
+3 -1
View File
@@ -50,4 +50,6 @@
<footer class="main-footer" />
</Shell>
<Create bind:show={$newOrgModal} closable={!!$organizationList?.total} />
{#if $newOrgModal}
<Create bind:show={$newOrgModal} closable={!!$organizationList?.total} />
{/if}
@@ -20,7 +20,7 @@
afterNavigate(handle);
async function handle(event = null) {
if ($organization.$id !== organizationId) {
if ($organization?.$id !== organizationId) {
await organization.load(organizationId);
await memberList.load(organizationId, '', 12, 0);
}