f210d9b749
* feat(projects): add project regions, default to null * feat(multiregion): add projectRegion Db client lookup logic * feat(multiregion): add project region repositories and caching * feat(multiRegion): db initialization and get project db client * feat(docker-compose): add second db for regions testing * feat(multiRegion): initialize region with pubs and subs working * fix(multiRegion): get region client even if it was registered in another pod * feat(workspaces): create workspace resolver split * feat: update server region metadata * feat(projects): rewrite project creation * feat(multiRegion): getRegionDb * fix(workspaces): get projects now can retur null * feat(multiRegion): make local multi region DB-s work * feat: set d efault workspace region * CR changes * tests * feat(multiRegion): bind region properly * fe update * test fixes * feat(multiRegion): automatically create aiven extras plugin * ci(postgres): use published postgres with aiven extras * fix(multiRegion): roll back the aiven extras migration, there is a better way * tests fix * fix(billing): we do not need to add a seat, if the workspace is on a plan, but has no sub --------- Co-authored-by: Kristaps Fabians Geikins <fabis94@live.com>
55 lines
1.3 KiB
Vue
55 lines
1.3 KiB
Vue
<template>
|
|
<div class="flex flex-col">
|
|
<div
|
|
class="flex flex-col md:flex-row gap-3 md:gap-0 justify-between"
|
|
:class="{ 'md:items-center': subheading }"
|
|
>
|
|
<h2 v-if="subheading" class="text-heading-lg">{{ title }}</h2>
|
|
<h1 v-else class="text-heading-xl hidden md:block">
|
|
{{ title }}
|
|
</h1>
|
|
<div v-if="buttons.length > 0" class="flex flex-wrap gap-2">
|
|
<FormButton
|
|
v-for="(button, index) in buttons"
|
|
:key="index"
|
|
v-bind="button.props"
|
|
class="shrink-0 whitespace-nowrap"
|
|
@click="($event) => button.onClick?.($event)"
|
|
>
|
|
{{ button.label }}
|
|
</FormButton>
|
|
</div>
|
|
</div>
|
|
<p v-if="text" class="text-body-xs text-foreground-2 pt-1">
|
|
{{ text }}
|
|
</p>
|
|
<hr v-if="!subheading && !hideDivider" class="my-6 border-outline-2" />
|
|
<slot />
|
|
</div>
|
|
</template>
|
|
|
|
<script lang="ts" setup>
|
|
import type { FormButton } from '@speckle/ui-components'
|
|
|
|
type FormButtonProps = InstanceType<typeof FormButton>['$props']
|
|
|
|
interface Button {
|
|
label: string
|
|
props: Record<string, unknown> & FormButtonProps
|
|
onClick?: (e: MouseEvent) => void
|
|
}
|
|
|
|
withDefaults(
|
|
defineProps<{
|
|
title: string
|
|
text?: string
|
|
buttons?: Button[]
|
|
subheading?: boolean
|
|
hideDivider?: boolean
|
|
}>(),
|
|
{
|
|
buttons: () => []
|
|
}
|
|
)
|
|
</script>
|