Show the alt-text length limit in the editor dialog
This commit is contained in:
parent
f74053b118
commit
3397b829c2
1 changed files with 3 additions and 1 deletions
|
|
@ -7,6 +7,8 @@ import { Label } from '@/components/ui/label';
|
|||
import { Textarea } from '@/components/ui/textarea';
|
||||
import type { MediaItem } from '@/types/media';
|
||||
|
||||
const MAX_ALT_TEXT_LENGTH = 2000;
|
||||
|
||||
const props = defineProps<{
|
||||
mediaItem: MediaItem | null;
|
||||
}>();
|
||||
|
|
@ -48,7 +50,7 @@ const save = () => {
|
|||
rows="4"
|
||||
data-testid="alt-text-input"
|
||||
/>
|
||||
<p class="text-right text-xs tabular-nums text-foreground/60">{{ value.length }}</p>
|
||||
<p class="text-right text-xs tabular-nums text-foreground/60">{{ value.length }} / {{ MAX_ALT_TEXT_LENGTH }}</p>
|
||||
</div>
|
||||
|
||||
<DialogFooter>
|
||||
|
|
|
|||
Loading…
Reference in a new issue