@escalated-dev/escalated 0.2.1 → 0.3.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (33) hide show
  1. package/package.json +1 -1
  2. package/src/components/ActivityTimeline.vue +8 -4
  3. package/src/components/AssigneeSelect.vue +6 -2
  4. package/src/components/AttachmentList.vue +9 -3
  5. package/src/components/EscalatedLayout.vue +219 -213
  6. package/src/components/FileDropzone.vue +9 -4
  7. package/src/components/PriorityBadge.vue +20 -2
  8. package/src/components/ReplyComposer.vue +52 -3
  9. package/src/components/ReplyThread.vue +14 -6
  10. package/src/components/SlaTimer.vue +12 -6
  11. package/src/components/StatsCard.vue +26 -6
  12. package/src/components/StatusBadge.vue +24 -2
  13. package/src/components/TagSelect.vue +8 -4
  14. package/src/components/TicketFilters.vue +17 -11
  15. package/src/components/TicketList.vue +45 -2
  16. package/src/components/TicketSidebar.vue +21 -14
  17. package/src/pages/Admin/CannedResponses/Index.vue +29 -17
  18. package/src/pages/Admin/Departments/Form.vue +12 -11
  19. package/src/pages/Admin/Departments/Index.vue +26 -18
  20. package/src/pages/Admin/EscalationRules/Form.vue +21 -20
  21. package/src/pages/Admin/EscalationRules/Index.vue +26 -18
  22. package/src/pages/Admin/Reports.vue +30 -16
  23. package/src/pages/Admin/Settings.vue +260 -0
  24. package/src/pages/Admin/SlaPolicies/Form.vue +21 -20
  25. package/src/pages/Admin/SlaPolicies/Index.vue +28 -20
  26. package/src/pages/Admin/Tags/Index.vue +48 -23
  27. package/src/pages/Admin/Tickets/Index.vue +22 -0
  28. package/src/pages/Admin/Tickets/Show.vue +109 -0
  29. package/src/pages/Agent/Dashboard.vue +37 -25
  30. package/src/pages/Agent/TicketShow.vue +12 -12
  31. package/src/pages/Customer/Show.vue +2 -2
  32. package/src/pages/Guest/Create.vue +97 -0
  33. package/src/pages/Guest/Show.vue +86 -0
@@ -25,47 +25,48 @@ function submit() {
25
25
 
26
26
  <template>
27
27
  <EscalatedLayout :title="policy ? 'Edit SLA Policy' : 'New SLA Policy'">
28
- <form @submit.prevent="submit" class="mx-auto max-w-lg space-y-4 rounded-lg border border-gray-200 bg-white p-6">
28
+ <form @submit.prevent="submit" class="mx-auto max-w-lg space-y-5 rounded-xl border border-white/[0.06] bg-neutral-900/60 p-6">
29
29
  <div>
30
- <label class="block text-sm font-medium text-gray-700">Name</label>
31
- <input v-model="form.name" type="text" required class="mt-1 w-full rounded-lg border-gray-300 shadow-sm" />
30
+ <label class="block text-sm font-medium text-neutral-300">Name</label>
31
+ <input v-model="form.name" type="text" required class="mt-1 w-full rounded-lg border border-white/10 bg-neutral-950 px-3 py-2 text-sm text-neutral-200 focus:border-white/20 focus:outline-none focus:ring-1 focus:ring-white/10" />
32
32
  </div>
33
33
  <div>
34
- <label class="block text-sm font-medium text-gray-700">Description</label>
35
- <textarea v-model="form.description" rows="2" class="mt-1 w-full rounded-lg border-gray-300 shadow-sm"></textarea>
34
+ <label class="block text-sm font-medium text-neutral-300">Description</label>
35
+ <textarea v-model="form.description" rows="2" class="mt-1 w-full rounded-lg border border-white/10 bg-neutral-950 px-3 py-2 text-sm text-neutral-200 focus:border-white/20 focus:outline-none focus:ring-1 focus:ring-white/10"></textarea>
36
36
  </div>
37
37
  <div>
38
- <h3 class="mb-2 text-sm font-medium text-gray-700">First Response Hours (by priority)</h3>
39
- <div class="grid grid-cols-2 gap-2">
38
+ <h3 class="mb-2 text-sm font-medium text-neutral-300">First Response Hours (by priority)</h3>
39
+ <div class="grid grid-cols-2 gap-3">
40
40
  <div v-for="p in priorities" :key="p">
41
- <label class="text-xs capitalize text-gray-500">{{ p }}</label>
42
- <input v-model.number="form.first_response_hours[p]" type="number" step="0.5" min="0" class="w-full rounded border-gray-300 text-sm" />
41
+ <label class="text-xs capitalize text-neutral-400">{{ p }}</label>
42
+ <input v-model.number="form.first_response_hours[p]" type="number" step="0.5" min="0" class="w-full rounded-lg border border-white/10 bg-neutral-950 px-2 py-1.5 text-sm text-neutral-200 focus:border-white/20 focus:outline-none focus:ring-1 focus:ring-white/10" />
43
43
  </div>
44
44
  </div>
45
45
  </div>
46
46
  <div>
47
- <h3 class="mb-2 text-sm font-medium text-gray-700">Resolution Hours (by priority)</h3>
48
- <div class="grid grid-cols-2 gap-2">
47
+ <h3 class="mb-2 text-sm font-medium text-neutral-300">Resolution Hours (by priority)</h3>
48
+ <div class="grid grid-cols-2 gap-3">
49
49
  <div v-for="p in priorities" :key="p">
50
- <label class="text-xs capitalize text-gray-500">{{ p }}</label>
51
- <input v-model.number="form.resolution_hours[p]" type="number" step="0.5" min="0" class="w-full rounded border-gray-300 text-sm" />
50
+ <label class="text-xs capitalize text-neutral-400">{{ p }}</label>
51
+ <input v-model.number="form.resolution_hours[p]" type="number" step="0.5" min="0" class="w-full rounded-lg border border-white/10 bg-neutral-950 px-2 py-1.5 text-sm text-neutral-200 focus:border-white/20 focus:outline-none focus:ring-1 focus:ring-white/10" />
52
52
  </div>
53
53
  </div>
54
54
  </div>
55
55
  <label class="flex items-center gap-2">
56
- <input v-model="form.business_hours_only" type="checkbox" class="rounded border-gray-300" />
57
- <span class="text-sm text-gray-700">Business hours only</span>
56
+ <input v-model="form.business_hours_only" type="checkbox" class="rounded border-white/20 bg-neutral-900 text-white focus:ring-white/10" />
57
+ <span class="text-sm text-neutral-300">Business hours only</span>
58
58
  </label>
59
59
  <label class="flex items-center gap-2">
60
- <input v-model="form.is_default" type="checkbox" class="rounded border-gray-300" />
61
- <span class="text-sm text-gray-700">Default policy</span>
60
+ <input v-model="form.is_default" type="checkbox" class="rounded border-white/20 bg-neutral-900 text-white focus:ring-white/10" />
61
+ <span class="text-sm text-neutral-300">Default policy</span>
62
62
  </label>
63
63
  <label class="flex items-center gap-2">
64
- <input v-model="form.is_active" type="checkbox" class="rounded border-gray-300" />
65
- <span class="text-sm text-gray-700">Active</span>
64
+ <input v-model="form.is_active" type="checkbox" class="rounded border-white/20 bg-neutral-900 text-white focus:ring-white/10" />
65
+ <span class="text-sm text-neutral-300">Active</span>
66
66
  </label>
67
67
  <div class="flex justify-end">
68
- <button type="submit" :disabled="form.processing" class="rounded-lg bg-indigo-600 px-4 py-2 text-sm font-medium text-white hover:bg-indigo-700 disabled:opacity-50">
68
+ <button type="submit" :disabled="form.processing"
69
+ class="rounded-lg bg-gradient-to-r from-cyan-500 to-violet-500 px-5 py-2 text-sm font-medium text-white shadow-lg shadow-black/20 transition-all hover:from-cyan-400 hover:to-violet-400 disabled:opacity-50">
69
70
  {{ policy ? 'Update' : 'Create' }}
70
71
  </button>
71
72
  </div>
@@ -14,34 +14,42 @@ function destroy(id) {
14
14
  <template>
15
15
  <EscalatedLayout title="SLA Policies">
16
16
  <div class="mb-4 flex justify-end">
17
- <Link :href="route('escalated.admin.sla-policies.create')" class="rounded-lg bg-indigo-600 px-4 py-2 text-sm font-medium text-white hover:bg-indigo-700">
17
+ <Link :href="route('escalated.admin.sla-policies.create')"
18
+ class="rounded-lg bg-gradient-to-r from-cyan-500 to-violet-500 px-4 py-2 text-sm font-medium text-white shadow-lg shadow-black/20 transition-all hover:from-cyan-400 hover:to-violet-400">
18
19
  Add Policy
19
20
  </Link>
20
21
  </div>
21
- <div class="overflow-hidden rounded-lg border border-gray-200 bg-white">
22
- <table class="min-w-full divide-y divide-gray-200">
23
- <thead class="bg-gray-50">
24
- <tr>
25
- <th class="px-4 py-3 text-left text-xs font-medium uppercase text-gray-500">Name</th>
26
- <th class="px-4 py-3 text-left text-xs font-medium uppercase text-gray-500">Default</th>
27
- <th class="px-4 py-3 text-left text-xs font-medium uppercase text-gray-500">Business Hours</th>
28
- <th class="px-4 py-3 text-left text-xs font-medium uppercase text-gray-500">Tickets</th>
29
- <th class="px-4 py-3 text-left text-xs font-medium uppercase text-gray-500">Active</th>
30
- <th class="px-4 py-3 text-right text-xs font-medium uppercase text-gray-500">Actions</th>
22
+ <div class="overflow-hidden rounded-xl border border-white/[0.06] bg-neutral-900/60">
23
+ <table class="min-w-full divide-y divide-white/[0.06]">
24
+ <thead>
25
+ <tr class="bg-white/[0.02]">
26
+ <th class="px-4 py-3 text-left text-[11px] font-semibold uppercase tracking-wider text-neutral-500">Name</th>
27
+ <th class="px-4 py-3 text-left text-[11px] font-semibold uppercase tracking-wider text-neutral-500">Default</th>
28
+ <th class="px-4 py-3 text-left text-[11px] font-semibold uppercase tracking-wider text-neutral-500">Business Hours</th>
29
+ <th class="px-4 py-3 text-left text-[11px] font-semibold uppercase tracking-wider text-neutral-500">Tickets</th>
30
+ <th class="px-4 py-3 text-left text-[11px] font-semibold uppercase tracking-wider text-neutral-500">Active</th>
31
+ <th class="px-4 py-3 text-right text-[11px] font-semibold uppercase tracking-wider text-neutral-500">Actions</th>
31
32
  </tr>
32
33
  </thead>
33
- <tbody class="divide-y divide-gray-200">
34
- <tr v-for="policy in policies" :key="policy.id">
35
- <td class="px-4 py-3 text-sm font-medium text-gray-900">{{ policy.name }}</td>
36
- <td class="px-4 py-3 text-sm">{{ policy.is_default ? 'Yes' : 'No' }}</td>
37
- <td class="px-4 py-3 text-sm">{{ policy.business_hours_only ? 'Yes' : 'No' }}</td>
38
- <td class="px-4 py-3 text-sm text-gray-500">{{ policy.tickets_count }}</td>
34
+ <tbody class="divide-y divide-white/[0.04]">
35
+ <tr v-if="!policies?.length">
36
+ <td colspan="6" class="px-4 py-12 text-center">
37
+ <svg class="mx-auto mb-3 h-8 w-8 text-neutral-700" fill="none" stroke="currentColor" stroke-width="1.5" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" d="M12 6v6h4.5m4.5 0a9 9 0 11-18 0 9 9 0 0118 0z" /></svg>
38
+ <p class="text-sm text-neutral-500">No SLA policies yet</p>
39
+ <p class="mt-1 text-xs text-neutral-600">Define response and resolution time targets</p>
40
+ </td>
41
+ </tr>
42
+ <tr v-for="policy in policies" :key="policy.id" class="transition-colors hover:bg-white/[0.03]">
43
+ <td class="px-4 py-3 text-sm font-medium text-neutral-200">{{ policy.name }}</td>
44
+ <td class="px-4 py-3 text-sm text-neutral-400">{{ policy.is_default ? 'Yes' : 'No' }}</td>
45
+ <td class="px-4 py-3 text-sm text-neutral-400">{{ policy.business_hours_only ? 'Yes' : 'No' }}</td>
46
+ <td class="px-4 py-3 text-sm text-neutral-400">{{ policy.tickets_count }}</td>
39
47
  <td class="px-4 py-3 text-sm">
40
- <span :class="policy.is_active ? 'text-green-600' : 'text-gray-400'">{{ policy.is_active ? 'Yes' : 'No' }}</span>
48
+ <span :class="policy.is_active ? 'text-emerald-400' : 'text-neutral-500'">{{ policy.is_active ? 'Yes' : 'No' }}</span>
41
49
  </td>
42
50
  <td class="px-4 py-3 text-right text-sm">
43
- <Link :href="route('escalated.admin.sla-policies.edit', policy.id)" class="text-indigo-600 hover:text-indigo-900">Edit</Link>
44
- <button @click="destroy(policy.id)" class="ml-3 text-red-600 hover:text-red-900">Delete</button>
51
+ <Link :href="route('escalated.admin.sla-policies.edit', policy.id)" class="text-neutral-300 hover:text-white">Edit</Link>
52
+ <button @click="destroy(policy.id)" class="ml-3 text-rose-400 hover:text-rose-300">Delete</button>
45
53
  </td>
46
54
  </tr>
47
55
  </tbody>
@@ -8,7 +8,7 @@ defineProps({ tags: Array });
8
8
  const showForm = ref(false);
9
9
  const editingTag = ref(null);
10
10
 
11
- const form = useForm({ name: '', color: '#6B7280' });
11
+ const form = useForm({ name: '', color: '#06b6d4' });
12
12
 
13
13
  function createTag() {
14
14
  form.post(route('escalated.admin.tags.store'), {
@@ -38,39 +38,64 @@ function destroy(id) {
38
38
  <template>
39
39
  <EscalatedLayout title="Tags">
40
40
  <div class="mb-4 flex justify-end">
41
- <button @click="showForm = !showForm" class="rounded-lg bg-indigo-600 px-4 py-2 text-sm font-medium text-white hover:bg-indigo-700">
41
+ <button @click="showForm = !showForm"
42
+ :class="showForm
43
+ ? 'rounded-lg border border-white/10 bg-white/[0.03] px-4 py-2 text-sm font-medium text-neutral-300 transition-colors hover:bg-white/[0.06]'
44
+ : 'rounded-lg bg-gradient-to-r from-cyan-500 to-violet-500 px-4 py-2 text-sm font-medium text-white shadow-lg shadow-black/20 transition-all hover:from-cyan-400 hover:to-violet-400'">
42
45
  {{ showForm ? 'Cancel' : 'Add Tag' }}
43
46
  </button>
44
47
  </div>
45
- <form v-if="showForm" @submit.prevent="createTag" class="mb-6 flex items-end gap-3 rounded-lg border border-gray-200 bg-white p-4">
48
+ <form v-if="showForm" @submit.prevent="createTag" class="mb-6 flex items-end gap-3 rounded-xl border border-white/[0.06] bg-neutral-900/60 p-4">
46
49
  <div>
47
- <label class="block text-sm font-medium text-gray-700">Name</label>
48
- <input v-model="form.name" type="text" required class="mt-1 rounded-lg border-gray-300 shadow-sm" />
50
+ <label class="block text-sm font-medium text-neutral-300">Name</label>
51
+ <input v-model="form.name" type="text" required class="mt-1 rounded-lg border border-white/10 bg-neutral-950 px-3 py-2 text-sm text-neutral-200 focus:border-white/20 focus:outline-none focus:ring-1 focus:ring-white/10" />
49
52
  </div>
50
53
  <div>
51
- <label class="block text-sm font-medium text-gray-700">Color</label>
52
- <input v-model="form.color" type="color" class="mt-1 h-10 w-16 rounded border-gray-300" />
54
+ <label class="block text-sm font-medium text-neutral-300">Color</label>
55
+ <input v-model="form.color" type="color" class="mt-1 h-10 w-16 rounded-lg border border-white/10 bg-neutral-950" />
53
56
  </div>
54
- <button type="submit" :disabled="form.processing" class="rounded-lg bg-indigo-600 px-4 py-2 text-sm font-medium text-white hover:bg-indigo-700">Create</button>
57
+ <button type="submit" :disabled="form.processing"
58
+ class="rounded-lg bg-gradient-to-r from-cyan-500 to-violet-500 px-4 py-2 text-sm font-medium text-white shadow-lg shadow-black/20 transition-all hover:from-cyan-400 hover:to-violet-400 disabled:opacity-50">
59
+ Create
60
+ </button>
55
61
  </form>
56
- <div class="overflow-hidden rounded-lg border border-gray-200 bg-white">
57
- <table class="min-w-full divide-y divide-gray-200">
58
- <thead class="bg-gray-50">
59
- <tr>
60
- <th class="px-4 py-3 text-left text-xs font-medium uppercase text-gray-500">Color</th>
61
- <th class="px-4 py-3 text-left text-xs font-medium uppercase text-gray-500">Name</th>
62
- <th class="px-4 py-3 text-left text-xs font-medium uppercase text-gray-500">Tickets</th>
63
- <th class="px-4 py-3 text-right text-xs font-medium uppercase text-gray-500">Actions</th>
62
+ <div class="overflow-hidden rounded-xl border border-white/[0.06] bg-neutral-900/60">
63
+ <table class="min-w-full divide-y divide-white/[0.06]">
64
+ <thead>
65
+ <tr class="bg-white/[0.02]">
66
+ <th class="px-4 py-3 text-left text-[11px] font-semibold uppercase tracking-wider text-neutral-500">Color</th>
67
+ <th class="px-4 py-3 text-left text-[11px] font-semibold uppercase tracking-wider text-neutral-500">Name</th>
68
+ <th class="px-4 py-3 text-left text-[11px] font-semibold uppercase tracking-wider text-neutral-500">Tickets</th>
69
+ <th class="px-4 py-3 text-right text-[11px] font-semibold uppercase tracking-wider text-neutral-500">Actions</th>
64
70
  </tr>
65
71
  </thead>
66
- <tbody class="divide-y divide-gray-200">
67
- <tr v-for="tag in tags" :key="tag.id">
68
- <td class="px-4 py-3"><span class="inline-block h-4 w-4 rounded-full" :style="{ backgroundColor: tag.color }"></span></td>
69
- <td class="px-4 py-3 text-sm font-medium text-gray-900">{{ tag.name }}</td>
70
- <td class="px-4 py-3 text-sm text-gray-500">{{ tag.tickets_count }}</td>
72
+ <tbody class="divide-y divide-white/[0.04]">
73
+ <tr v-if="!tags?.length">
74
+ <td colspan="4" class="px-4 py-12 text-center">
75
+ <svg class="mx-auto mb-3 h-8 w-8 text-neutral-700" fill="none" stroke="currentColor" stroke-width="1.5" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" d="M9.568 3H5.25A2.25 2.25 0 003 5.25v4.318c0 .597.237 1.17.659 1.591l9.581 9.581c.699.699 1.78.872 2.607.33a18.095 18.095 0 005.223-5.223c.542-.827.369-1.908-.33-2.607L11.16 3.66A2.25 2.25 0 009.568 3z M6 6h.008v.008H6V6z" /></svg>
76
+ <p class="text-sm text-neutral-500">No tags yet</p>
77
+ <p class="mt-1 text-xs text-neutral-600">Create tags to categorize and filter tickets</p>
78
+ </td>
79
+ </tr>
80
+ <tr v-for="tag in tags" :key="tag.id" class="transition-colors hover:bg-white/[0.03]">
81
+ <td class="px-4 py-3">
82
+ <span class="inline-block h-4 w-4 rounded-full ring-1 ring-white/10" :style="{ backgroundColor: tag.color }"></span>
83
+ </td>
84
+ <td class="px-4 py-3 text-sm font-medium text-neutral-200">
85
+ <template v-if="editingTag === tag.id">
86
+ <form @submit.prevent="updateTag(tag.id)" class="flex items-center gap-2">
87
+ <input v-model="form.name" type="text" required class="rounded-lg border border-white/10 bg-neutral-950 px-2 py-1 text-sm text-neutral-200 focus:border-white/20 focus:outline-none focus:ring-1 focus:ring-white/10" />
88
+ <input v-model="form.color" type="color" class="h-8 w-10 rounded border border-white/10 bg-neutral-950" />
89
+ <button type="submit" class="text-sm text-neutral-300 hover:text-white">Save</button>
90
+ <button type="button" @click="editingTag = null" class="text-sm text-neutral-400 hover:text-neutral-300">Cancel</button>
91
+ </form>
92
+ </template>
93
+ <template v-else>{{ tag.name }}</template>
94
+ </td>
95
+ <td class="px-4 py-3 text-sm text-neutral-400">{{ tag.tickets_count }}</td>
71
96
  <td class="px-4 py-3 text-right text-sm">
72
- <button @click="startEdit(tag)" class="text-indigo-600 hover:text-indigo-900">Edit</button>
73
- <button @click="destroy(tag.id)" class="ml-3 text-red-600 hover:text-red-900">Delete</button>
97
+ <button @click="startEdit(tag)" class="text-neutral-300 hover:text-white">Edit</button>
98
+ <button @click="destroy(tag.id)" class="ml-3 text-rose-400 hover:text-rose-300">Delete</button>
74
99
  </td>
75
100
  </tr>
76
101
  </tbody>
@@ -0,0 +1,22 @@
1
+ <script setup>
2
+ import EscalatedLayout from '../../../components/EscalatedLayout.vue';
3
+ import TicketList from '../../../components/TicketList.vue';
4
+ import TicketFilters from '../../../components/TicketFilters.vue';
5
+
6
+ defineProps({
7
+ tickets: Object,
8
+ filters: Object,
9
+ departments: Array,
10
+ tags: Array,
11
+ agents: Array,
12
+ });
13
+ </script>
14
+
15
+ <template>
16
+ <EscalatedLayout title="All Tickets">
17
+ <div class="mb-6">
18
+ <TicketFilters :filters="filters" :route="route('escalated.admin.tickets.index')" :departments="departments" :tags="tags" show-assignee />
19
+ </div>
20
+ <TicketList :tickets="tickets" route-prefix="escalated.admin.tickets" show-assignee />
21
+ </EscalatedLayout>
22
+ </template>
@@ -0,0 +1,109 @@
1
+ <script setup>
2
+ import EscalatedLayout from '../../../components/EscalatedLayout.vue';
3
+ import StatusBadge from '../../../components/StatusBadge.vue';
4
+ import PriorityBadge from '../../../components/PriorityBadge.vue';
5
+ import ReplyThread from '../../../components/ReplyThread.vue';
6
+ import ReplyComposer from '../../../components/ReplyComposer.vue';
7
+ import TicketSidebar from '../../../components/TicketSidebar.vue';
8
+ import AttachmentList from '../../../components/AttachmentList.vue';
9
+ import { router, useForm, usePage } from '@inertiajs/vue3';
10
+ import { ref } from 'vue';
11
+
12
+ const props = defineProps({
13
+ ticket: Object,
14
+ departments: Array,
15
+ tags: Array,
16
+ cannedResponses: Array,
17
+ agents: Array,
18
+ });
19
+
20
+ const page = usePage();
21
+ const activeTab = ref('reply');
22
+
23
+ const statusForm = useForm({ status: '' });
24
+ const priorityForm = useForm({ priority: '' });
25
+ const assignForm = useForm({ agent_id: '' });
26
+
27
+ function changeStatus(status) {
28
+ statusForm.status = status;
29
+ statusForm.post(route('escalated.admin.tickets.status', props.ticket.reference), { preserveScroll: true });
30
+ }
31
+
32
+ function changePriority(priority) {
33
+ priorityForm.priority = priority;
34
+ priorityForm.post(route('escalated.admin.tickets.priority', props.ticket.reference), { preserveScroll: true });
35
+ }
36
+
37
+ function assignToMe() {
38
+ assignForm.agent_id = page.props.auth.user.id;
39
+ assignForm.post(route('escalated.admin.tickets.assign', props.ticket.reference), { preserveScroll: true });
40
+ }
41
+ </script>
42
+
43
+ <template>
44
+ <EscalatedLayout :title="ticket.subject">
45
+ <div class="mb-5 flex flex-wrap items-center gap-3">
46
+ <span class="text-sm font-mono font-medium text-white">{{ ticket.reference }}</span>
47
+ <StatusBadge :status="ticket.status" />
48
+ <PriorityBadge :priority="ticket.priority" />
49
+ <span class="text-sm text-neutral-500">by {{ ticket.requester?.name }}</span>
50
+ <div class="ml-auto flex gap-2">
51
+ <button v-if="!ticket.assigned_to" @click="assignToMe"
52
+ class="rounded-lg bg-gradient-to-r from-cyan-500 to-violet-500 px-3 py-1.5 text-sm font-medium text-white shadow-lg shadow-black/20 transition-all hover:from-cyan-400 hover:to-violet-400">
53
+ Assign to Me
54
+ </button>
55
+ <select @change="changeStatus($event.target.value); $event.target.value = ''"
56
+ class="rounded-lg border border-white/10 bg-neutral-950 px-3 py-1.5 text-sm text-neutral-200 focus:border-white/20 focus:outline-none focus:ring-1 focus:ring-white/10">
57
+ <option value="">Change Status...</option>
58
+ <option value="in_progress">In Progress</option>
59
+ <option value="waiting_on_customer">Waiting on Customer</option>
60
+ <option value="resolved">Resolved</option>
61
+ <option value="closed">Closed</option>
62
+ </select>
63
+ <select @change="changePriority($event.target.value); $event.target.value = ''"
64
+ class="rounded-lg border border-white/10 bg-neutral-950 px-3 py-1.5 text-sm text-neutral-200 focus:border-white/20 focus:outline-none focus:ring-1 focus:ring-white/10">
65
+ <option value="">Change Priority...</option>
66
+ <option value="low">Low</option>
67
+ <option value="medium">Medium</option>
68
+ <option value="high">High</option>
69
+ <option value="urgent">Urgent</option>
70
+ <option value="critical">Critical</option>
71
+ </select>
72
+ </div>
73
+ </div>
74
+ <div class="grid grid-cols-1 gap-6 lg:grid-cols-3">
75
+ <div class="lg:col-span-2 space-y-6">
76
+ <div class="rounded-xl border border-white/[0.06] bg-neutral-900/60 p-5">
77
+ <p class="whitespace-pre-wrap text-sm text-neutral-300">{{ ticket.description }}</p>
78
+ <AttachmentList v-if="ticket.attachments?.length" :attachments="ticket.attachments" class="mt-3" />
79
+ </div>
80
+ <div>
81
+ <div class="mb-4 flex gap-4 border-b border-white/[0.06]">
82
+ <button @click="activeTab = 'reply'"
83
+ :class="['pb-2 text-sm font-medium transition-colors', activeTab === 'reply' ? 'border-b-2 border-cyan-500 text-white' : 'text-neutral-500 hover:text-neutral-300']">
84
+ Reply
85
+ </button>
86
+ <button @click="activeTab = 'note'"
87
+ :class="['pb-2 text-sm font-medium transition-colors', activeTab === 'note' ? 'border-b-2 border-amber-500 text-amber-400' : 'text-neutral-500 hover:text-neutral-300']">
88
+ Internal Note
89
+ </button>
90
+ </div>
91
+ <ReplyComposer v-if="activeTab === 'reply'"
92
+ :action="route('escalated.admin.tickets.reply', ticket.reference)"
93
+ :canned-responses="cannedResponses" />
94
+ <ReplyComposer v-else
95
+ :action="route('escalated.admin.tickets.note', ticket.reference)"
96
+ placeholder="Write an internal note..."
97
+ submit-label="Add Note" />
98
+ </div>
99
+ <div>
100
+ <h2 class="mb-4 text-lg font-semibold text-neutral-200">Conversation</h2>
101
+ <ReplyThread :replies="ticket.replies || []" :current-user-id="page.props.auth?.user?.id" />
102
+ </div>
103
+ </div>
104
+ <div>
105
+ <TicketSidebar :ticket="ticket" :tags="tags" :departments="departments" />
106
+ </div>
107
+ </div>
108
+ </EscalatedLayout>
109
+ </template>
@@ -1,7 +1,6 @@
1
1
  <script setup>
2
2
  import EscalatedLayout from '../../components/EscalatedLayout.vue';
3
3
  import StatsCard from '../../components/StatsCard.vue';
4
- import TicketList from '../../components/TicketList.vue';
5
4
 
6
5
  defineProps({
7
6
  stats: Object,
@@ -12,37 +11,50 @@ defineProps({
12
11
  <template>
13
12
  <EscalatedLayout title="Agent Dashboard">
14
13
  <div class="mb-8 grid grid-cols-2 gap-4 md:grid-cols-5">
15
- <StatsCard title="Open Tickets" :value="stats.open" color="indigo" />
16
- <StatsCard title="My Assigned" :value="stats.my_assigned" color="indigo" />
17
- <StatsCard title="Unassigned" :value="stats.unassigned" color="yellow" />
18
- <StatsCard title="SLA Breached" :value="stats.sla_breached" color="red" />
19
- <StatsCard title="Resolved Today" :value="stats.resolved_today" color="green" />
14
+ <StatsCard label="Open Tickets" :value="stats.open" color="cyan" />
15
+ <StatsCard label="My Assigned" :value="stats.my_assigned" color="violet" />
16
+ <StatsCard label="Unassigned" :value="stats.unassigned" color="amber" />
17
+ <StatsCard label="SLA Breached" :value="stats.sla_breached" color="red" />
18
+ <StatsCard label="Resolved Today" :value="stats.resolved_today" color="green" />
20
19
  </div>
21
- <h2 class="mb-4 text-lg font-semibold text-gray-900">Recent Tickets</h2>
22
- <div class="overflow-hidden rounded-lg border border-gray-200 bg-white">
23
- <table class="min-w-full divide-y divide-gray-200">
24
- <thead class="bg-gray-50">
25
- <tr>
26
- <th class="px-4 py-3 text-left text-xs font-medium uppercase text-gray-500">Reference</th>
27
- <th class="px-4 py-3 text-left text-xs font-medium uppercase text-gray-500">Subject</th>
28
- <th class="px-4 py-3 text-left text-xs font-medium uppercase text-gray-500">Requester</th>
29
- <th class="px-4 py-3 text-left text-xs font-medium uppercase text-gray-500">Status</th>
30
- <th class="px-4 py-3 text-left text-xs font-medium uppercase text-gray-500">Priority</th>
31
- <th class="px-4 py-3 text-left text-xs font-medium uppercase text-gray-500">Assignee</th>
20
+ <h2 class="mb-4 text-lg font-semibold text-neutral-200">Recent Tickets</h2>
21
+ <div class="overflow-hidden rounded-xl border border-white/[0.06] bg-neutral-900/60">
22
+ <table class="min-w-full divide-y divide-white/[0.06]">
23
+ <thead>
24
+ <tr class="bg-white/[0.02]">
25
+ <th class="px-4 py-3 text-left text-[11px] font-semibold uppercase tracking-wider text-neutral-500">Reference</th>
26
+ <th class="px-4 py-3 text-left text-[11px] font-semibold uppercase tracking-wider text-neutral-500">Subject</th>
27
+ <th class="px-4 py-3 text-left text-[11px] font-semibold uppercase tracking-wider text-neutral-500">Requester</th>
28
+ <th class="px-4 py-3 text-left text-[11px] font-semibold uppercase tracking-wider text-neutral-500">Status</th>
29
+ <th class="px-4 py-3 text-left text-[11px] font-semibold uppercase tracking-wider text-neutral-500">Priority</th>
30
+ <th class="px-4 py-3 text-left text-[11px] font-semibold uppercase tracking-wider text-neutral-500">Assignee</th>
32
31
  </tr>
33
32
  </thead>
34
- <tbody class="divide-y divide-gray-200">
35
- <tr v-for="ticket in recentTickets" :key="ticket.id" class="hover:bg-gray-50">
33
+ <tbody class="divide-y divide-white/[0.04]">
34
+ <tr v-for="ticket in recentTickets" :key="ticket.id" class="transition-colors hover:bg-white/[0.03]">
36
35
  <td class="px-4 py-3 text-sm">
37
- <a :href="route('escalated.agent.tickets.show', ticket.reference)" class="font-medium text-indigo-600 hover:text-indigo-900">{{ ticket.reference }}</a>
36
+ <a :href="route('escalated.agent.tickets.show', ticket.reference)" class="font-medium text-neutral-300 hover:text-white">{{ ticket.reference }}</a>
38
37
  </td>
39
- <td class="px-4 py-3 text-sm text-gray-900">{{ ticket.subject }}</td>
40
- <td class="px-4 py-3 text-sm text-gray-500">{{ ticket.requester?.name }}</td>
38
+ <td class="px-4 py-3 text-sm text-neutral-200">{{ ticket.subject }}</td>
39
+ <td class="px-4 py-3 text-sm text-neutral-400">{{ ticket.requester?.name }}</td>
41
40
  <td class="px-4 py-3 text-sm">
42
- <span :class="['inline-flex rounded-full px-2 py-0.5 text-xs font-medium', { 'bg-blue-100 text-blue-800': ticket.status === 'open', 'bg-green-100 text-green-800': ticket.status === 'resolved', 'bg-red-100 text-red-800': ticket.status === 'escalated' }]">{{ ticket.status }}</span>
41
+ <span :class="[
42
+ 'inline-flex rounded-full px-2 py-0.5 text-xs font-medium ring-1',
43
+ {
44
+ 'bg-cyan-500/10 text-white ring-cyan-500/20': ticket.status === 'open',
45
+ 'bg-blue-500/10 text-blue-400 ring-blue-500/20': ticket.status === 'in_progress',
46
+ 'bg-emerald-500/10 text-emerald-400 ring-emerald-500/20': ticket.status === 'resolved',
47
+ 'bg-rose-500/10 text-rose-400 ring-rose-500/20': ticket.status === 'escalated',
48
+ 'bg-amber-500/10 text-amber-400 ring-amber-500/20': ticket.status === 'waiting_on_customer',
49
+ 'bg-gray-500/10 text-neutral-400 ring-gray-500/20': ticket.status === 'closed',
50
+ }
51
+ ]">{{ ticket.status }}</span>
43
52
  </td>
44
- <td class="px-4 py-3 text-sm text-gray-500">{{ ticket.priority }}</td>
45
- <td class="px-4 py-3 text-sm text-gray-500">{{ ticket.assignee?.name || 'Unassigned' }}</td>
53
+ <td class="px-4 py-3 text-sm capitalize text-neutral-400">{{ ticket.priority }}</td>
54
+ <td class="px-4 py-3 text-sm text-neutral-400">{{ ticket.assignee?.name || 'Unassigned' }}</td>
55
+ </tr>
56
+ <tr v-if="!recentTickets?.length">
57
+ <td colspan="6" class="px-4 py-8 text-center text-sm text-neutral-500">No recent tickets</td>
46
58
  </tr>
47
59
  </tbody>
48
60
  </table>
@@ -41,18 +41,18 @@ function assignToMe() {
41
41
 
42
42
  <template>
43
43
  <EscalatedLayout :title="ticket.subject">
44
- <div class="mb-4 flex flex-wrap items-center gap-3">
45
- <span class="text-sm font-medium text-gray-500">{{ ticket.reference }}</span>
44
+ <div class="mb-5 flex flex-wrap items-center gap-3">
45
+ <span class="text-sm font-mono font-medium text-white">{{ ticket.reference }}</span>
46
46
  <StatusBadge :status="ticket.status" />
47
47
  <PriorityBadge :priority="ticket.priority" />
48
- <span class="text-sm text-gray-500">by {{ ticket.requester?.name }}</span>
48
+ <span class="text-sm text-neutral-500">by {{ ticket.requester?.name }}</span>
49
49
  <div class="ml-auto flex gap-2">
50
50
  <button v-if="!ticket.assigned_to" @click="assignToMe"
51
- class="rounded-lg bg-indigo-600 px-3 py-1.5 text-sm text-white hover:bg-indigo-700">
51
+ class="rounded-lg bg-gradient-to-r from-cyan-500 to-violet-500 px-3 py-1.5 text-sm font-medium text-white shadow-lg shadow-black/20 transition-all hover:from-cyan-400 hover:to-violet-400">
52
52
  Assign to Me
53
53
  </button>
54
54
  <select @change="changeStatus($event.target.value); $event.target.value = ''"
55
- class="rounded-lg border-gray-300 text-sm">
55
+ class="rounded-lg border border-white/10 bg-neutral-950 px-3 py-1.5 text-sm text-neutral-200 focus:border-white/20 focus:outline-none focus:ring-1 focus:ring-white/10">
56
56
  <option value="">Change Status...</option>
57
57
  <option value="in_progress">In Progress</option>
58
58
  <option value="waiting_on_customer">Waiting on Customer</option>
@@ -60,7 +60,7 @@ function assignToMe() {
60
60
  <option value="closed">Closed</option>
61
61
  </select>
62
62
  <select @change="changePriority($event.target.value); $event.target.value = ''"
63
- class="rounded-lg border-gray-300 text-sm">
63
+ class="rounded-lg border border-white/10 bg-neutral-950 px-3 py-1.5 text-sm text-neutral-200 focus:border-white/20 focus:outline-none focus:ring-1 focus:ring-white/10">
64
64
  <option value="">Change Priority...</option>
65
65
  <option value="low">Low</option>
66
66
  <option value="medium">Medium</option>
@@ -72,18 +72,18 @@ function assignToMe() {
72
72
  </div>
73
73
  <div class="grid grid-cols-1 gap-6 lg:grid-cols-3">
74
74
  <div class="lg:col-span-2 space-y-6">
75
- <div class="rounded-lg border border-gray-200 bg-white p-4">
76
- <p class="whitespace-pre-wrap text-sm text-gray-700">{{ ticket.description }}</p>
75
+ <div class="rounded-xl border border-white/[0.06] bg-neutral-900/60 p-5">
76
+ <p class="whitespace-pre-wrap text-sm text-neutral-300">{{ ticket.description }}</p>
77
77
  <AttachmentList v-if="ticket.attachments?.length" :attachments="ticket.attachments" class="mt-3" />
78
78
  </div>
79
79
  <div>
80
- <div class="mb-4 flex gap-4 border-b border-gray-200">
80
+ <div class="mb-4 flex gap-4 border-b border-white/[0.06]">
81
81
  <button @click="activeTab = 'reply'"
82
- :class="['pb-2 text-sm font-medium', activeTab === 'reply' ? 'border-b-2 border-indigo-500 text-indigo-600' : 'text-gray-500']">
82
+ :class="['pb-2 text-sm font-medium transition-colors', activeTab === 'reply' ? 'border-b-2 border-cyan-500 text-white' : 'text-neutral-500 hover:text-neutral-300']">
83
83
  Reply
84
84
  </button>
85
85
  <button @click="activeTab = 'note'"
86
- :class="['pb-2 text-sm font-medium', activeTab === 'note' ? 'border-b-2 border-yellow-500 text-yellow-600' : 'text-gray-500']">
86
+ :class="['pb-2 text-sm font-medium transition-colors', activeTab === 'note' ? 'border-b-2 border-amber-500 text-amber-400' : 'text-neutral-500 hover:text-neutral-300']">
87
87
  Internal Note
88
88
  </button>
89
89
  </div>
@@ -96,7 +96,7 @@ function assignToMe() {
96
96
  submit-label="Add Note" />
97
97
  </div>
98
98
  <div>
99
- <h2 class="mb-4 text-lg font-semibold text-gray-900">Conversation</h2>
99
+ <h2 class="mb-4 text-lg font-semibold text-neutral-200">Conversation</h2>
100
100
  <ReplyThread :replies="ticket.replies || []" :current-user-id="page.props.auth?.user?.id" />
101
101
  </div>
102
102
  </div>
@@ -22,10 +22,10 @@ function reopenTicket() {
22
22
  <template>
23
23
  <EscalatedLayout :title="ticket.subject">
24
24
  <div class="mb-4 flex flex-wrap items-center gap-3">
25
- <span class="text-sm font-medium text-gray-500">{{ ticket.reference }}</span>
25
+ <span class="text-sm font-medium text-neutral-500">{{ ticket.reference }}</span>
26
26
  <StatusBadge :status="ticket.status" />
27
27
  <PriorityBadge :priority="ticket.priority" />
28
- <span v-if="ticket.department" class="text-sm text-gray-500">{{ ticket.department.name }}</span>
28
+ <span v-if="ticket.department" class="text-sm text-neutral-500">{{ ticket.department.name }}</span>
29
29
  <div class="ml-auto flex gap-2">
30
30
  <button v-if="ticket.status === 'resolved' || ticket.status === 'closed'"
31
31
  @click="reopenTicket"