add linter, prettier and typescript support for jetstream (#1)

* add linter, prettier and typescript support for jetstream

* add github actions for lint, build and typecheck

* add composer install to build action

* fix composer lock

* add ext-intl and fixed php version

* fix intl php extension install

* add tip php extension to github npm build action

* fix php version to 8.3.1

* change github php base action

* fix primary button default type

* updated typescript types from Team to Organization

---------

Co-authored-by: Gregor Vostrak <gregorvostrak@Gregors-MacBook-Pro.local>
This commit is contained in:
Gregor Vostrak
2024-01-21 22:35:43 +01:00
committed by GitHub
parent 0a8d958ccc
commit 27140d4ffc
73 changed files with 4727 additions and 886 deletions

View File

@@ -1,10 +1,11 @@
<script setup>
import { useForm } from '@inertiajs/vue3';
<script setup lang="ts">
import { useForm, usePage } from '@inertiajs/vue3';
import FormSection from '@/Components/FormSection.vue';
import InputError from '@/Components/InputError.vue';
import InputLabel from '@/Components/InputLabel.vue';
import PrimaryButton from '@/Components/PrimaryButton.vue';
import TextInput from '@/Components/TextInput.vue';
import type { User } from '@/types/models';
const form = useForm({
name: '',
@@ -16,13 +17,16 @@ const createTeam = () => {
preserveScroll: true,
});
};
const page = usePage<{
auth: {
user: User;
};
}>();
</script>
<template>
<FormSection @submitted="createTeam">
<template #title>
Team Details
</template>
<template #title> Team Details</template>
<template #description>
Create a new team to collaborate with others on projects.
@@ -33,12 +37,17 @@ const createTeam = () => {
<InputLabel value="Team Owner" />
<div class="flex items-center mt-2">
<img class="object-cover w-12 h-12 rounded-full" :src="$page.props.auth.user.profile_photo_url" :alt="$page.props.auth.user.name">
<img
class="object-cover w-12 h-12 rounded-full"
:src="page.props.auth.user.profile_photo_url"
:alt="page.props.auth.user.name" />
<div class="ms-4 leading-tight">
<div class="text-gray-900 dark:text-white">{{ $page.props.auth.user.name }}</div>
<div class="text-gray-900 dark:text-white">
{{ page.props.auth.user.name }}
</div>
<div class="text-sm text-gray-700 dark:text-gray-300">
{{ $page.props.auth.user.email }}
{{ page.props.auth.user.email }}
</div>
</div>
</div>
@@ -51,14 +60,15 @@ const createTeam = () => {
v-model="form.name"
type="text"
class="block w-full mt-1"
autofocus
/>
autofocus />
<InputError :message="form.errors.name" class="mt-2" />
</div>
</template>
<template #actions>
<PrimaryButton :class="{ 'opacity-25': form.processing }" :disabled="form.processing">
<PrimaryButton
:class="{ 'opacity-25': form.processing }"
:disabled="form.processing">
Create
</PrimaryButton>
</template>