Skip to content

Commit 70753dc

Browse files
committed
fix: fix aggregate date config
1 parent 7c28c28 commit 70753dc

File tree

2 files changed

+11
-3
lines changed

2 files changed

+11
-3
lines changed

apps/frontend/src/lib/components/blocks/aggregate/aggregate.svelte

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,12 @@
5959
$: isPending = $getAggregate.isPending
6060
</script>
6161

62-
<div class={cn("flex h-full w-full items-center justify-center rounded-lg bg-white p-6", $$restProps.class)}>
62+
<div
63+
class={cn(
64+
"flex h-full w-full items-center justify-center rounded-lg bg-white px-6 py-20 text-base",
65+
$$restProps.class,
66+
)}
67+
>
6368
{#if !isValid}
6469
<Tooltip.Root>
6570
<Tooltip.Trigger>
@@ -83,6 +88,6 @@
8388
</div>
8489
</div>
8590
{:else if $value}
86-
<span class="text-8xl font-bold">{$value}</span>
91+
<span class="text-[2rem] font-bold">{$value}</span>
8792
{/if}
8893
</div>

apps/frontend/src/lib/components/blocks/aggregate/config/aggregate-config.svelte

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,10 @@
105105
<Tabs.Content value="count"></Tabs.Content>
106106
<Tabs.Content value="aggregate" class="space-y-2">
107107
{#if widget.item.type === "aggregate" && widget.item.aggregate.type !== "count"}
108-
<AggregateTypePicker bind:value={widget.item.aggregate.type} />
108+
<AggregateTypePicker
109+
bind:value={widget.item.aggregate.type}
110+
onValueChange={() => (widget.item.aggregate.config.field = undefined)}
111+
/>
109112
<FieldPicker
110113
bind:value={widget.item.aggregate.config.field}
111114
class="w-full flex-1"

0 commit comments

Comments
 (0)