-
Notifications
You must be signed in to change notification settings - Fork 14
Expand file tree
/
Copy pathPreviewUpsellModal.vue
More file actions
69 lines (59 loc) · 2.47 KB
/
PreviewUpsellModal.vue
File metadata and controls
69 lines (59 loc) · 2.47 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
<script setup lang="ts">
import { Crown, X, Rocket } from 'lucide-vue-next'
const emit = defineEmits<{
(e: 'close'): void
}>()
const { message } = usePreviewReadOnly()
const config = useRuntimeConfig()
function closeModal() {
emit('close')
}
</script>
<template>
<Teleport to="body">
<div class="fixed inset-0 z-50 flex items-center justify-center p-4">
<div class="absolute inset-0 bg-black/50" @click="closeModal" />
<div class="relative w-full max-w-md rounded-xl border border-surface-200 bg-white shadow-xl dark:border-surface-800 dark:bg-surface-900">
<div class="flex items-center justify-between border-b border-surface-200 px-5 py-4 dark:border-surface-800">
<div class="flex items-center gap-2">
<Crown class="size-5 text-brand-600 dark:text-brand-400" />
<h3 class="text-lg font-semibold text-surface-900 dark:text-surface-50">Unlock full editing</h3>
</div>
<button
class="cursor-pointer text-surface-400 transition-colors hover:text-surface-600 dark:hover:text-surface-200"
@click="closeModal"
>
<X class="size-5" />
</button>
</div>
<div class="space-y-4 px-5 py-5">
<p class="text-sm text-surface-600 dark:text-surface-300">
{{ message }}
</p>
<p class="text-sm text-surface-500 dark:text-surface-400">
Want write access? Upgrade to a paid hosted plan or deploy your own Reqcore instance.
</p>
<div class="flex flex-wrap items-center gap-2">
<a
:href="config.public.hostedPlanUrl"
target="_blank"
rel="noopener noreferrer"
class="inline-flex items-center gap-2 rounded-lg bg-brand-600 px-3 py-2 text-sm font-medium text-white transition-colors hover:bg-brand-700"
>
<Rocket class="size-4" />
Upgrade to hosted plan
</a>
<a
href="https://github.com/reqcore-inc/reqcore"
target="_blank"
rel="noopener noreferrer"
class="inline-flex items-center rounded-lg border border-surface-300 px-3 py-2 text-sm font-medium text-surface-700 transition-colors hover:bg-surface-50 dark:border-surface-700 dark:text-surface-200 dark:hover:bg-surface-800"
>
Self-host on GitHub
</a>
</div>
</div>
</div>
</div>
</Teleport>
</template>