mirror of
https://github.com/appwrite/console.git
synced 2026-11-18 20:47:21 +00:00
Merge branch 'main' into feat-database-backups
This commit is contained in:
commit
1c7a5c3592
9 files changed
+47
-12
No files matched your search
@@ -5,6 +5,7 @@
|
||||
import EmptyDark from '$lib/images/empty-dark.svg';
|
||||
import { Heading } from '.';
|
||||
import { trackEvent } from '$lib/actions/analytics';
|
||||
import { createEventDispatcher } from 'svelte';
|
||||
|
||||
export let single = false;
|
||||
export let isCard = true;
|
||||
@@ -14,7 +15,19 @@
|
||||
export let marginTop = false;
|
||||
export let allowCreate = true;
|
||||
|
||||
const dispatch = createEventDispatcher();
|
||||
|
||||
function onClick(event) {
|
||||
if (!allowCreate) {
|
||||
return;
|
||||
}
|
||||
dispatch('click', event);
|
||||
}
|
||||
|
||||
function track() {
|
||||
if (!allowCreate) {
|
||||
return;
|
||||
}
|
||||
if (target) {
|
||||
trackEvent(`click_create_${target}`, {
|
||||
from: 'empty'
|
||||
@@ -30,8 +43,8 @@
|
||||
{#if !noMedia}
|
||||
<button
|
||||
type="button"
|
||||
on:click|preventDefault
|
||||
on:click={track}
|
||||
on:click={onClick}
|
||||
aria-label="create {target}">
|
||||
<slot name="empty-media">
|
||||
{#if $app.themeInUse === 'dark'}
|
||||
|
||||
@@ -152,7 +152,7 @@ campaigns
|
||||
})
|
||||
.set('Hacktoberfest2024', {
|
||||
template: 'card',
|
||||
title: 'Claim your $60 Hacktobefest credits.',
|
||||
title: 'Claim your $60 Hacktoberfest credits.',
|
||||
description:
|
||||
'Get $60 in Cloud credits when you upgrade or create an organization with a Pro plan'
|
||||
})
|
||||
|
||||
@@ -41,6 +41,7 @@
|
||||
{:else}
|
||||
<Empty
|
||||
single
|
||||
allowCreate={$canWriteCollections}
|
||||
href="https://appwrite.io/docs/products/databases/collections"
|
||||
target="collection"
|
||||
on:click={() => ($showCreate = true)} />
|
||||
|
||||
+3
-2
@@ -137,13 +137,14 @@
|
||||
single
|
||||
href="https://appwrite.io/docs/products/databases/collections#indexes"
|
||||
target="index"
|
||||
on:click={() => (showCreateIndex = $canWriteCollections)} />
|
||||
on:click={() => (showCreateIndex = true)} />
|
||||
{/if}
|
||||
{:else}
|
||||
<Empty
|
||||
single
|
||||
target="attribute"
|
||||
on:click={() => (showCreateDropdown = $canWriteCollections)}>
|
||||
allowCreate={$canWriteCollections}
|
||||
on:click={() => (showCreateDropdown = true)}>
|
||||
<div class="u-text-center">
|
||||
<Heading size="7" tag="h2">Create an attribute to get started.</Heading>
|
||||
<p class="body-text-2 u-bold u-margin-block-start-4">
|
||||
|
||||
@@ -139,6 +139,7 @@
|
||||
{:else}
|
||||
<Empty
|
||||
single
|
||||
allowCreate={$canWriteFunctions}
|
||||
href="https://appwrite.io/docs/products/functions"
|
||||
target="function"
|
||||
on:click={openWizard} />
|
||||
|
||||
+8
-6
@@ -389,12 +389,14 @@
|
||||
<DeploymentSource {deployment} />
|
||||
</span>
|
||||
</div>
|
||||
<div class="u-flex-vertical u-gap-8">
|
||||
<p class="u-color-text-offline">Domains</p>
|
||||
<span>
|
||||
<DeploymentDomains domain={$proxyRuleList} />
|
||||
</span>
|
||||
</div>
|
||||
{#if $proxyRuleList?.rules?.length}
|
||||
<div class="u-flex-vertical u-gap-8">
|
||||
<p class="u-color-text-offline">Domains</p>
|
||||
<span>
|
||||
<DeploymentDomains domain={$proxyRuleList} />
|
||||
</span>
|
||||
</div>
|
||||
{/if}
|
||||
<div class="u-flex-vertical u-gap-8">
|
||||
<p class="u-color-text-offline">Updated</p>
|
||||
<span>
|
||||
|
||||
@@ -119,7 +119,8 @@
|
||||
{:else}
|
||||
<Empty
|
||||
single
|
||||
on:click={() => $canWriteTopics && ($showCreate = true)}
|
||||
allowCreate={$canWriteTopics}
|
||||
on:click={() => ($showCreate = true)}
|
||||
href="https://appwrite.io/docs/products/messaging/topics"
|
||||
target="topic" />
|
||||
{/if}
|
||||
|
||||
@@ -73,5 +73,5 @@
|
||||
allowCreate={$canWriteKeys}
|
||||
href="https://appwrite.io/docs/advanced/platform/api-keys"
|
||||
target="API key"
|
||||
on:click={$canWriteKeys ? createApiKey : null} />
|
||||
on:click={createApiKey} />
|
||||
{/if}
|
||||
@@ -194,4 +194,20 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* TODO: remove this block once Pink V2 is incorporated */
|
||||
input[type='radio'],
|
||||
input[type='checkbox']:not([class='switch']),
|
||||
input[type='switchbox'] {
|
||||
.theme-dark &:not(:checked) {
|
||||
background-color: transparent; /* take whatever color is behind */
|
||||
border: 1px solid var(--color-mid-neutral-70, #56565c);
|
||||
}
|
||||
}
|
||||
|
||||
input[type='checkbox'][class='switch'] {
|
||||
.theme-dark &:not(:checked) {
|
||||
background-color: var(--color-mid-neutral-70, #56565c);
|
||||
}
|
||||
}
|
||||
</style>
|
||||
Reference in new issue
Block a user