2023-12-09 15:47:03 +01:00
|
|
|
<template>
|
|
|
|
|
<div class="flex flex-col min-h-full border-t">
|
|
|
|
|
<section class="py-12 sm:py-16 bg-gray-50 border-b border-gray-200">
|
|
|
|
|
<div class="px-4 sm:px-6 lg:px-8 max-w-7xl mx-auto">
|
|
|
|
|
<div class="text-center max-w-xl mx-auto">
|
2024-04-15 19:39:03 +02:00
|
|
|
<h1
|
|
|
|
|
class="text-3xl sm:text-4xl lg:text-5xl font-bold tracking-tight text-gray-900"
|
|
|
|
|
>
|
2023-12-09 15:47:03 +01:00
|
|
|
My Form Templates
|
|
|
|
|
</h1>
|
|
|
|
|
<p class="text-gray-600 mt-4 text-lg font-normal">
|
|
|
|
|
Share your best form as templates so that others can re-use them!
|
|
|
|
|
</p>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</section>
|
|
|
|
|
|
2024-04-15 19:39:03 +02:00
|
|
|
<templates-list
|
|
|
|
|
:templates="templates"
|
|
|
|
|
:loading="loading"
|
|
|
|
|
:show-types="false"
|
|
|
|
|
:show-industries="false"
|
|
|
|
|
/>
|
2023-12-09 15:47:03 +01:00
|
|
|
</div>
|
|
|
|
|
</template>
|
|
|
|
|
|
2024-01-05 11:00:34 +01:00
|
|
|
<script setup>
|
|
|
|
|
definePageMeta({
|
2024-04-15 19:39:03 +02:00
|
|
|
middleware: "auth",
|
2024-01-05 11:00:34 +01:00
|
|
|
})
|
|
|
|
|
|
|
|
|
|
useOpnSeoMeta({
|
2024-04-15 19:39:03 +02:00
|
|
|
title: "My Templates",
|
|
|
|
|
description:
|
|
|
|
|
"Our collection of beautiful templates to create your own forms!",
|
2024-01-05 11:00:34 +01:00
|
|
|
})
|
|
|
|
|
|
2024-04-15 19:39:03 +02:00
|
|
|
const loading = ref(false)
|
|
|
|
|
const templates = ref([])
|
2024-01-05 11:00:34 +01:00
|
|
|
|
|
|
|
|
onMounted(() => {
|
|
|
|
|
loading.value = true
|
2024-04-15 19:39:03 +02:00
|
|
|
opnFetch("templates", { query: { onlymy: true } }).then((data) => {
|
2024-01-05 11:00:34 +01:00
|
|
|
loading.value = false
|
|
|
|
|
templates.value = data
|
|
|
|
|
})
|
|
|
|
|
})
|
2023-12-09 15:47:03 +01:00
|
|
|
</script>
|