Skip to content

Commit

Permalink
ui team form updates
Browse files Browse the repository at this point in the history
  • Loading branch information
alnutile committed Jun 26, 2024
1 parent cc510f6 commit 17f49b7
Show file tree
Hide file tree
Showing 7 changed files with 21 additions and 20 deletions.
2 changes: 0 additions & 2 deletions app/Jobs/ProcessFileJob.php
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,6 @@ public function handle(): void
ProcessTextFilesJob::class,
],
'finally' => [
SummarizeDocumentJob::class,
TagDocumentJob::class,
DocumentProcessingCompleteJob::class,
],
],
Expand Down
1 change: 1 addition & 0 deletions app/Jobs/ProcessTextFilesJob.php
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ public function handle(): void

$document->update([
'summary' => $content,
'original_content' => $content,
]);

$jobs = [];
Expand Down
2 changes: 1 addition & 1 deletion resources/js/Components/ActionSection.vue
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import SectionTitle from './SectionTitle.vue';
</SectionTitle>

<div class="mt-5 md:mt-0 md:col-span-2">
<div class="px-4 py-5 sm:p-6 bg-white shadow sm:rounded-lg">
<div class="px-4 py-5 sm:p-6 border-secondary border bg-neutral shadow sm:rounded-lg">
<slot name="content" />
</div>
</div>
Expand Down
4 changes: 3 additions & 1 deletion resources/js/Pages/Collection/Components/Documents.vue
Original file line number Diff line number Diff line change
Expand Up @@ -312,7 +312,9 @@ const toggleAll = () => {
</div>
<Teleport to="body">

<ShowDocument :document="document" :open="showDocumentSlideOut"
<ShowDocument
v-if="showDocumentSlideOut"
:document="document" :open="showDocumentSlideOut"
@closing="closeDocument" />
</Teleport>

Expand Down
2 changes: 1 addition & 1 deletion resources/js/Pages/Teams/Partials/DeleteTeamForm.vue
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ const deleteTeam = () => {
</template>

<template #content>
<div class="max-w-xl text-sm text-gray-600">
<div class="max-w-xl text-sm">
Once a team is deleted, all of its resources and data will be permanently deleted. Before deleting this team, please download any data or information regarding this team that you wish to retain.
</div>

Expand Down
26 changes: 13 additions & 13 deletions resources/js/Pages/Teams/Partials/TeamMemberManager.vue
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ const displayableRole = (role) => {

<template #form>
<div class="col-span-6">
<div class="max-w-xl text-sm text-gray-600">
<div class="max-w-xl text-sm">
Please provide the email address of the person you would like to add to this team.
</div>
</div>
Expand All @@ -131,29 +131,29 @@ const displayableRole = (role) => {
<InputLabel for="roles" value="Role" />
<InputError :message="addTeamMemberForm.errors.role" class="mt-2" />

<div class="relative z-0 mt-1 border border-gray-200 rounded-lg cursor-pointer">
<div class="relative z-0 mt-1 border border-secondary rounded-lg cursor-pointer">
<button
v-for="(role, i) in availableRoles"
:key="role.key"
type="button"
class="relative px-4 py-3 inline-flex w-full rounded-lg focus:z-10 focus:outline-none focus:border-indigo-500 focus:ring-2 focus:ring-indigo-500"
:class="{'border-t border-gray-200 focus:border-none rounded-t-none': i > 0, 'rounded-b-none': i != Object.keys(availableRoles).length - 1}"
class="relative px-4 py-3 inline-flex w-full rounded-lg focus:z-10 focus:outline-none focus:border-pink-500 focus:ring-2 focus:ring-pink-400"
:class="{'border-t border-secondary focus:border-none rounded-t-none': i > 0, 'rounded-b-none': i != Object.keys(availableRoles).length - 1}"
@click="addTeamMemberForm.role = role.key"
>
<div :class="{'opacity-50': addTeamMemberForm.role && addTeamMemberForm.role != role.key}">
<!-- Role Name -->
<div class="flex items-center">
<div class="text-sm text-gray-600" :class="{'font-semibold': addTeamMemberForm.role == role.key}">
<div class="text-sm" :class="{'font-semibold': addTeamMemberForm.role == role.key}">
{{ role.name }}
</div>

<svg v-if="addTeamMemberForm.role == role.key" class="ms-2 h-5 w-5 text-green-400" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor">
<svg v-if="addTeamMemberForm.role == role.key" class="ms-2 h-5 w-5 text-success" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor">
<path stroke-linecap="round" stroke-linejoin="round" d="M9 12.75L11.25 15 15 9.75M21 12a9 9 0 11-18 0 9 9 0 0118 0z" />
</svg>
</div>

<!-- Role Description -->
<div class="mt-2 text-xs text-gray-600 text-start">
<div class="mt-2 text-xs text-start">
{{ role.description }}
</div>
</div>
Expand Down Expand Up @@ -191,15 +191,15 @@ const displayableRole = (role) => {
<template #content>
<div class="space-y-6">
<div v-for="invitation in team.team_invitations" :key="invitation.id" class="flex items-center justify-between">
<div class="text-gray-600">
<div class="text-primary">
{{ invitation.email }}
</div>

<div class="flex items-center">
<!-- Cancel Team Invitation -->
<button
v-if="userPermissions.canRemoveTeamMembers"
class="cursor-pointer ms-6 text-sm text-red-500 focus:outline-none"
class="cursor-pointer ms-6 text-sm text-warning focus:outline-none"
@click="cancelTeamInvitation(invitation)"
>
Cancel
Expand Down Expand Up @@ -239,20 +239,20 @@ const displayableRole = (role) => {
<!-- Manage Team Member Role -->
<button
v-if="userPermissions.canUpdateTeamMembers && availableRoles.length"
class="ms-2 text-sm text-gray-400 underline"
class="ms-2 text-sm underline"
@click="manageRole(user)"
>
{{ displayableRole(user.membership.role) }}
</button>

<div v-else-if="availableRoles.length" class="ms-2 text-sm text-gray-400">
<div v-else-if="availableRoles.length" class="ms-2 text-sm">
{{ displayableRole(user.membership.role) }}
</div>

<!-- Leave Team -->
<button
v-if="$page.props.auth.user.id === user.id"
class="cursor-pointer ms-6 text-sm text-red-500"
class="cursor-pointer ms-6 text-sm text-danger"
@click="confirmLeavingTeam"
>
Leave
Expand All @@ -261,7 +261,7 @@ const displayableRole = (role) => {
<!-- Remove Team Member -->
<button
v-else-if="userPermissions.canRemoveTeamMembers"
class="cursor-pointer ms-6 text-sm text-red-500"
class="cursor-pointer ms-6 text-sm text-dangers"
@click="confirmTeamMemberRemoval(user)"
>
Remove
Expand Down
4 changes: 2 additions & 2 deletions resources/js/Pages/Teams/Partials/UpdateTeamNameForm.vue
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@ const updateTeamName = () => {
<img class="w-12 h-12 rounded-full object-cover" :src="team.owner.profile_photo_url" :alt="team.owner.name">

<div class="ms-4 leading-tight">
<div class="text-gray-900">{{ team.owner.name }}</div>
<div class="text-gray-700 text-sm">
<div class="text-base">{{ team.owner.name }}</div>
<div class="text-secondary text-sm">
{{ team.owner.email }}
</div>
</div>
Expand Down

0 comments on commit 17f49b7

Please sign in to comment.