Skip to content

Commit aa44d93

Browse files
committed
Lint
1 parent a8aed2a commit aa44d93

File tree

5 files changed

+137
-362
lines changed

5 files changed

+137
-362
lines changed

resources/js/components/Status/EditModal.vue

Lines changed: 30 additions & 88 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,11 @@
11
<template>
2-
<div
3-
v-if="isOpen"
4-
class="fixed inset-0 z-50 flex items-center justify-center bg-black/90"
5-
@click.self="closeModal"
6-
>
7-
<div
8-
class="bg-white dark:bg-slate-900 rounded-lg shadow-xl w-full max-w-md mx-4 max-h-[90vh] overflow-y-auto"
9-
>
10-
<div
11-
class="flex items-center justify-between p-6 border-b border-gray-200 dark:border-slate-700"
12-
>
2+
<div v-if="isOpen" class="fixed inset-0 z-50 flex items-center justify-center bg-black/90" @click.self="closeModal">
3+
<div class="bg-white dark:bg-slate-900 rounded-lg shadow-xl w-full max-w-md mx-4 max-h-[90vh] overflow-y-auto">
4+
<div class="flex items-center justify-between p-6 border-b border-gray-200 dark:border-slate-700">
135
<h2 class="text-xl font-semibold text-gray-900 dark:text-white">
146
{{ $t('post.editVideo') }}
157
</h2>
16-
<button
17-
@click="closeModal"
18-
class="text-gray-400 hover:text-gray-600 dark:hover:text-gray-300"
19-
>
8+
<button @click="closeModal" class="text-gray-400 hover:text-gray-600 dark:hover:text-gray-300">
209
<XMarkIcon class="h-6 w-6" />
2110
</button>
2211
</div>
@@ -26,40 +15,24 @@
2615
<label class="block text-sm font-medium text-gray-700 dark:text-gray-300 mb-2">
2716
{{ $t('post.caption') }}
2817
</label>
29-
<textarea
30-
v-model="formData.caption"
18+
<textarea v-model="formData.caption"
3119
class="w-full px-3 py-2 border border-gray-300 dark:border-slate-600 rounded-md shadow-sm focus:outline-none focus:ring-2 focus:ring-[#F02C56] focus:border-[#F02C56] dark:bg-slate-800 dark:text-white resize-none"
32-
rows="4"
33-
:placeholder="$t('post.writeYourCaptionDotDotDot')"
34-
maxlength="500"
35-
/>
20+
rows="4" :placeholder="$t('post.writeYourCaptionDotDotDot')" maxlength="500" />
3621
<div class="text-right text-sm text-gray-500 dark:text-gray-400 mt-1">
3722
{{ formData.caption.length }}/240
3823
</div>
3924
</div>
4025

4126
<div>
42-
<AnimatedButton
43-
@click="showAltText = !showAltText"
44-
type="button"
45-
variant="light"
46-
class="flex w-full"
47-
>
27+
<AnimatedButton @click="showAltText = !showAltText" type="button" variant="light"
28+
class="flex w-full">
4829
<div class="flex items-center gap-2 text-sm font-medium">
4930
<div>
50-
<svg
51-
:class="{ 'rotate-90': showAltText }"
52-
class="h-4 w-4 transition-transform duration-200"
53-
fill="none"
54-
viewBox="0 0 24 24"
55-
stroke="currentColor"
56-
>
57-
<path
58-
stroke-linecap="round"
59-
stroke-linejoin="round"
60-
stroke-width="2"
61-
d="M9 5l7 7-7 7"
62-
/>
31+
<svg :class="{ 'rotate-90': showAltText }"
32+
class="h-4 w-4 transition-transform duration-200" fill="none" viewBox="0 0 24 24"
33+
stroke="currentColor">
34+
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"
35+
d="M9 5l7 7-7 7" />
6336
</svg>
6437
</div>
6538
<div>
@@ -75,13 +48,9 @@
7548
<p class="text-xs text-gray-500 dark:text-gray-400">
7649
{{ $t('studio.altTextHelp') }}
7750
</p>
78-
<textarea
79-
v-model="formData.altText"
51+
<textarea v-model="formData.altText"
8052
class="w-full px-3 py-2 border border-gray-300 dark:border-slate-600 rounded-md shadow-sm focus:outline-none focus:ring-2 focus:ring-[#F02C56] focus:border-[#F02C56] dark:bg-slate-800 dark:text-white resize-none"
81-
rows="3"
82-
:placeholder="$t('studio.describeYourVideoDotDotDotAltText')"
83-
maxlength="2000"
84-
/>
53+
rows="3" :placeholder="$t('studio.describeYourVideoDotDotDotAltText')" maxlength="2000" />
8554
<div class="text-right text-sm text-gray-500 dark:text-gray-400">
8655
{{ formData.altText.length }}/2000
8756
</div>
@@ -155,10 +124,8 @@
155124
{{ $t('studio.language') }}
156125
</label>
157126
<div class="relative">
158-
<select
159-
v-model="formData.lang"
160-
class="block w-full px-4 py-2 pr-8 text-gray-700 bg-white border border-gray-300 rounded-lg shadow-sm appearance-none focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-blue-500 transition-colors"
161-
>
127+
<select v-model="formData.lang"
128+
class="block w-full px-4 py-2 pr-8 text-gray-700 bg-white border border-gray-300 rounded-lg shadow-sm appearance-none focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-blue-500 transition-colors">
162129
<option value="" disabled selected>
163130
{{ $t('studio.selectLanguage') }}
164131
</option>
@@ -167,21 +134,10 @@
167134
{{ lang.name }}
168135
</option>
169136
</select>
170-
<div
171-
class="absolute inset-y-0 right-0 flex items-center px-2 pointer-events-none"
172-
>
173-
<svg
174-
class="w-5 h-5 text-gray-400"
175-
fill="none"
176-
stroke="currentColor"
177-
viewBox="0 0 24 24"
178-
>
179-
<path
180-
stroke-linecap="round"
181-
stroke-linejoin="round"
182-
stroke-width="2"
183-
d="M19 9l-7 7-7-7"
184-
/>
137+
<div class="absolute inset-y-0 right-0 flex items-center px-2 pointer-events-none">
138+
<svg class="w-5 h-5 text-gray-400" fill="none" stroke="currentColor" viewBox="0 0 24 24">
139+
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"
140+
d="M19 9l-7 7-7-7" />
185141
</svg>
186142
</div>
187143
</div>
@@ -212,10 +168,7 @@
212168
{{ $t('studio.disclosePostContentHelp') }}
213169
</p>
214170
</div>
215-
<ToggleSwitch
216-
v-model="formData.containsAds"
217-
:disabled="formData.containsAds"
218-
/>
171+
<ToggleSwitch v-model="formData.containsAds" :disabled="formData.containsAds" />
219172
</div>
220173

221174
<div class="flex items-start justify-between gap-5">
@@ -227,10 +180,7 @@
227180
{{ $t('studio.containsAlteredContentHelp') }}
228181
</p>
229182
</div>
230-
<ToggleSwitch
231-
v-model="formData.containsAiContent"
232-
:disabled="formData.containsAiContent"
233-
/>
183+
<ToggleSwitch v-model="formData.containsAiContent" :disabled="formData.containsAiContent" />
234184
</div>
235185
</div>
236186

@@ -245,10 +195,8 @@
245195
<p class="text-sm text-red-700 dark:text-red-300 mt-1">
246196
{{ $t('post.thisActionCannotBeUndone') }}
247197
</p>
248-
<button
249-
@click="confirmDelete"
250-
class="mt-3 bg-red-600 hover:bg-red-700 text-white text-sm font-medium py-2 px-4 rounded-md transition-colors duration-200"
251-
>
198+
<button @click="confirmDelete"
199+
class="mt-3 bg-red-600 hover:bg-red-700 text-white text-sm font-medium py-2 px-4 rounded-md transition-colors duration-200">
252200
{{ $t('post.deleteVideo') }}
253201
</button>
254202
</div>
@@ -258,19 +206,13 @@
258206
</div>
259207

260208
<div
261-
class="flex items-center justify-end gap-3 px-6 py-4 border-t border-gray-200 dark:border-slate-700 bg-gray-50 dark:bg-slate-800 rounded-b-lg"
262-
>
263-
<button
264-
@click="closeModal"
265-
class="px-4 py-2 text-sm font-medium text-gray-700 dark:text-gray-300 bg-white dark:bg-slate-700 border border-gray-300 dark:border-slate-600 rounded-md hover:bg-gray-50 dark:hover:bg-slate-600 transition-colors duration-200 cursor-pointer"
266-
>
209+
class="flex items-center justify-end gap-3 px-6 py-4 border-t border-gray-200 dark:border-slate-700 bg-gray-50 dark:bg-slate-800 rounded-b-lg">
210+
<button @click="closeModal"
211+
class="px-4 py-2 text-sm font-medium text-gray-700 dark:text-gray-300 bg-white dark:bg-slate-700 border border-gray-300 dark:border-slate-600 rounded-md hover:bg-gray-50 dark:hover:bg-slate-600 transition-colors duration-200 cursor-pointer">
267212
{{ $t('common.cancel') }}
268213
</button>
269-
<button
270-
@click="saveChanges"
271-
:disabled="isSaving"
272-
class="px-4 py-2 text-sm font-medium text-white bg-[#F02C56] hover:bg-red-600 disabled:bg-red-300 disabled:cursor-not-allowed rounded-md transition-colors duration-200 flex items-center cursor-pointer"
273-
>
214+
<button @click="saveChanges" :disabled="isSaving"
215+
class="px-4 py-2 text-sm font-medium text-white bg-[#F02C56] hover:bg-red-600 disabled:bg-red-300 disabled:cursor-not-allowed rounded-md transition-colors duration-200 flex items-center cursor-pointer">
274216
<Spinner v-if="isSaving" size="sm" class="mr-2" />
275217
{{ isSaving ? $t('common.savingDotDotDot') : $t('post.saveChanges') }}
276218
</button>

0 commit comments

Comments
 (0)