Skip to content

Commit

Permalink
Fix translations
Browse files Browse the repository at this point in the history
  • Loading branch information
tiritibambix committed Jan 12, 2025
1 parent af3ee45 commit 4d14ab6
Show file tree
Hide file tree
Showing 3 changed files with 132 additions and 52 deletions.
47 changes: 46 additions & 1 deletion messages.pot
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ msgid ""
msgstr ""
"Project-Id-Version: 1.0\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2025-01-12 16:55+0100\n"
"POT-Creation-Date: 2025-01-12 17:10+0100\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <[email protected]>\n"
Expand Down Expand Up @@ -109,6 +109,9 @@ msgstr ""
msgid "Convert to format:"
msgstr ""

msgid "Convert all to format:"
msgstr ""

msgid "Best for transparency"
msgstr ""

Expand All @@ -130,6 +133,48 @@ msgstr ""
msgid "Resize"
msgstr ""

msgid "Batch Resize"
msgstr ""

msgid "Resize All"
msgstr ""

msgid "Resize Options"
msgstr ""

msgid "Keep Original Formats"
msgstr ""

msgid "Recommended Formats"
msgstr ""

msgid "Other Compatible Formats"
msgstr ""

msgid "Your batch contains:"
msgstr ""

msgid "Images with transparency"
msgstr ""

msgid "Photographic images"
msgstr ""

msgid "Graphic images"
msgstr ""

msgid "Details for each image:"
msgstr ""

msgid "Contains transparency"
msgstr ""

msgid "Photographic image"
msgstr ""

msgid "Graphic image"
msgstr ""

msgid "Image processed successfully: %(filename)s"
msgstr ""

Expand Down
70 changes: 30 additions & 40 deletions templates/resize_batch.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Resize Batch</title>
<title>{{ _('Batch Resize') }}</title>
<style>
:root {
--clr-primary-a0: #808080;
Expand Down Expand Up @@ -140,77 +140,67 @@
</head>
<body>
<div class="container">
<h1>Resize Batch</h1>
<h1>{{ _('Batch Resize') }}</h1>
<form action="/resize_batch" method="post">
<input type="hidden" name="filenames" value="{{ ','.join(files) }}">
<fieldset>
<legend>Resize Options</legend>
<legend>{{ _('Resize Options') }}</legend>
<div class="form-group">
<label for="batch_width">Width:</label>
<input type="text" name="width" id="batch_width" placeholder="Enter width">
<label for="batch_width">{{ _('Width:') }}</label>
<input type="text" name="width" id="batch_width" placeholder="{{ _('Enter width') }}">
</div>
<div class="form-group">
<label for="batch_height">Height:</label>
<input type="text" name="height" id="batch_height" placeholder="Enter height">
<label for="batch_height">{{ _('Height:') }}</label>
<input type="text" name="height" id="batch_height" placeholder="{{ _('Enter height') }}">
</div>
<div class="form-group">
<label>
<input type="checkbox" name="keep_ratio" id="batch_keep_ratio"> Keep Aspect Ratio
<input type="checkbox" name="keep_ratio" id="batch_keep_ratio"> {{ _('Keep Aspect Ratio') }}
</label>
</div>
</fieldset>

<fieldset>
<legend>Resize by Percentage</legend>
<legend>{{ _('Resize by Percentage') }}</legend>
<div class="form-group">
<label for="batch_percentage">Percentage:</label>
<input type="text" name="percentage" id="batch_percentage" placeholder="Enter percentage (1-100)">
<label for="batch_percentage">{{ _('Percentage:') }}</label>
<input type="text" name="percentage" id="batch_percentage" placeholder="{{ _('Enter percentage (1-100)') }}">
</div>
</fieldset>

<fieldset>
<legend>Additional Options</legend>
<legend>{{ _('Additional Options') }}</legend>
<div class="form-group">
<label for="quality">Quality (1-100):</label>
<label for="quality">{{ _('Quality (1-100):') }}</label>
<input type="text" name="quality" id="quality" value="100">
</div>
<div class="form-group">
<label for="format">Convert all to format:</label>
<label for="format">{{ _('Convert all to format:') }}</label>
<select name="format" id="format">
<option value="">Keep Original Formats</option>
<option value="">{{ _('Keep Original Formats') }}</option>
{% if formats.recommended %}
<optgroup label="Recommended Formats">
<optgroup label="{{ _('Recommended Formats') }}">
{% for fmt in formats.recommended %}
<option value="{{ fmt|lower }}">{{ fmt }}
{% if batch_info %}
{% if (batch_info.has_transparency and fmt in ['PNG', 'WebP', 'AVIF']) %}
(Best for transparency)
({{ _('Best for transparency') }})
{% endif %}
{% if (batch_info.has_photos and fmt in ['JPEG', 'WebP', 'AVIF']) %}
(Best for photos)
({{ _('Best for photos') }})
{% endif %}
{% if (batch_info.has_graphics and fmt in ['PNG', 'GIF', 'WebP']) %}
(Best for graphics)
({{ _('Best for graphics') }})
{% endif %}
{% endif %}
</option>
{% endfor %}
</optgroup>
{% endif %}
{% if formats.compatible %}
<optgroup label="Other Compatible Formats">
<optgroup label="{{ _('Other Compatible Formats') }}">
{% for fmt in formats.compatible %}
<option value="{{ fmt|lower }}">{{ fmt }}
{% if batch_info %}
{% if (batch_info.has_transparency and fmt == 'GIF') %}
(Limited transparency support)
{% elif batch_info.has_photos %}
(Less efficient for photos)
{% elif batch_info.has_graphics %}
(Basic support)
{% endif %}
{% endif %}
</option>
<option value="{{ fmt|lower }}">{{ fmt }}</option>
{% endfor %}
</optgroup>
{% endif %}
Expand All @@ -219,16 +209,16 @@ <h1>Resize Batch</h1>
{% if batch_info %}
<div class="batch-info">
<small>
Your batch contains:
{{ _('Your batch contains:') }}
<ul>
{% if batch_info.has_transparency %}
<li>Images with transparency</li>
<li>{{ _('Images with transparency') }}</li>
{% endif %}
{% if batch_info.has_photos %}
<li>Photographic images</li>
<li>{{ _('Photographic images') }}</li>
{% endif %}
{% if batch_info.has_graphics %}
<li>Graphic images</li>
<li>{{ _('Graphic images') }}</li>
{% endif %}
</ul>
</small>
Expand All @@ -238,17 +228,17 @@ <h1>Resize Batch</h1>
{% if image_types %}
<div class="images-info">
<small>
Details for each image:
{{ _('Details for each image:') }}
<ul>
{% for img in image_types %}
<li>{{ img.filename }}:
{% if img.type.has_transparency %}
Contains transparency,
{{ _('Contains transparency') }},
{% endif %}
{% if img.type.is_photo %}
Photographic image
{{ _('Photographic image') }}
{% else %}
Graphic image
{{ _('Graphic image') }}
{% endif %}
</li>
{% endfor %}
Expand All @@ -258,7 +248,7 @@ <h1>Resize Batch</h1>
{% endif %}
</fieldset>

<button type="submit">Resize Batch</button>
<button type="submit">{{ _('Resize All') }}</button>
</form>
</div>
<script>
Expand Down
67 changes: 56 additions & 11 deletions translations/fr/LC_MESSAGES/messages.po
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ msgid ""
msgstr ""
"Project-Id-Version: 1.0\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2025-01-12 16:55+0100\n"
"PO-Revision-Date: 2025-01-12 16:55+0100\n"
"POT-Creation-Date: 2025-01-12 17:10+0100\n"
"PO-Revision-Date: 2025-01-12 17:10+0100\n"
"Last-Translator: ImaGUIck Team\n"
"Language: fr\n"
"Language-Team: French\n"
Expand Down Expand Up @@ -51,15 +51,6 @@ msgstr "Formats recommandés"
msgid "Other compatible formats"
msgstr "Autres formats compatibles"

msgid "Best for transparency"
msgstr "Idéal pour la transparence"

msgid "Best for photos"
msgstr "Idéal pour les photos"

msgid "Best for graphics"
msgstr "Idéal pour les graphiques"

msgid "Language"
msgstr "Langue"

Expand Down Expand Up @@ -120,6 +111,18 @@ msgstr "Qualité (1-100) :"
msgid "Convert to format:"
msgstr "Convertir au format :"

msgid "Convert all to format:"
msgstr "Convertir tous au format :"

msgid "Best for transparency"
msgstr "Idéal pour la transparence"

msgid "Best for photos"
msgstr "Idéal pour les photos"

msgid "Best for graphics"
msgstr "Idéal pour les graphiques"

msgid "This image contains transparency."
msgstr "Cette image contient de la transparence."

Expand All @@ -132,6 +135,48 @@ msgstr "Cette image semble être un graphique."
msgid "Resize"
msgstr "Redimensionner"

msgid "Batch Resize"
msgstr "Redimensionnement par lot"

msgid "Resize All"
msgstr "Tout redimensionner"

msgid "Resize Options"
msgstr "Options de redimensionnement"

msgid "Keep Original Formats"
msgstr "Conserver les formats d'origine"

msgid "Recommended Formats"
msgstr "Formats recommandés"

msgid "Other Compatible Formats"
msgstr "Autres formats compatibles"

msgid "Your batch contains:"
msgstr "Votre lot contient :"

msgid "Images with transparency"
msgstr "Images avec transparence"

msgid "Photographic images"
msgstr "Images photographiques"

msgid "Graphic images"
msgstr "Images graphiques"

msgid "Details for each image:"
msgstr "Détails pour chaque image :"

msgid "Contains transparency"
msgstr "Contient de la transparence"

msgid "Photographic image"
msgstr "Image photographique"

msgid "Graphic image"
msgstr "Image graphique"

msgid "Image processed successfully: %(filename)s"
msgstr "Image traitée avec succès : %(filename)s"

Expand Down

0 comments on commit 4d14ab6

Please sign in to comment.