Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[5.x] Improve the dynamic upload folder help text #10903

Merged
merged 4 commits into from
Oct 21, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<div
v-if="hasPendingDynamicFolder"
class="py-3 px-4 text-sm w-full rounded-md border border-dashed text-gray-700 dark:text-dark-175 dark:border-dark-200"
v-html="__('statamic::fieldtypes.assets.dynamic_folder_pending', {field: `<code>${config.dynamic}</code>`})"
v-html="pendingText"
/>

<uploader
Expand Down Expand Up @@ -438,6 +438,12 @@ export default {
return ! this.hasPendingDynamicFolder;
},

pendingText() {
return this.config.dynamic === 'id'
? __('statamic::fieldtypes.assets.dynamic_folder_pending_save')
: __('statamic::fieldtypes.assets.dynamic_folder_pending_field', {field: `<code>${this.config.dynamic}</code>`});
}

},

events: {
Expand Down
2 changes: 1 addition & 1 deletion resources/lang/de/fieldtypes.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
'assets.config.restrict' => 'Verhindern, dass Benutzer:innen zu anderen Ordnern navigieren können.',
'assets.config.show_filename' => 'Dateiname neben dem Vorschaubild anzeigen.',
'assets.config.show_set_alt' => 'Einen Link zum Erfassen des Alt-Texts bei allen Bildern anzeigen.',
'assets.dynamic_folder_pending' => 'Dieser Upload-Ordner wird verfügbar sein, sobald :field festgelegt ist.',
'assets.dynamic_folder_pending_field' => 'Dieser Upload-Ordner wird verfügbar sein, sobald :field festgelegt ist.',
'assets.title' => 'Dateien',
'bard.config.allow_source' => 'Ermöglicht beim Schreiben das Anzeigen des HTML-Quellcodes.',
'bard.config.always_show_set_button' => 'Ermöglicht das ständige Anzeigen des „Set hinzufügen“-Buttons.',
Expand Down
2 changes: 1 addition & 1 deletion resources/lang/de_CH/fieldtypes.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
'assets.config.restrict' => 'Verhindern, dass Benutzer:innen zu anderen Ordnern navigieren können.',
'assets.config.show_filename' => 'Dateiname neben dem Vorschaubild anzeigen.',
'assets.config.show_set_alt' => 'Einen Link zum Erfassen des Alt-Texts bei allen Bildern anzeigen.',
'assets.dynamic_folder_pending' => 'Dieser Upload-Ordner wird verfügbar sein, sobald :field festgelegt ist.',
'assets.dynamic_folder_pending_field' => 'Dieser Upload-Ordner wird verfügbar sein, sobald :field festgelegt ist.',
'assets.title' => 'Dateien',
'bard.config.allow_source' => 'Ermöglicht beim Schreiben das Anzeigen des HTML-Quellcodes.',
'bard.config.always_show_set_button' => 'Ermöglicht das ständige Anzeigen des «Set hinzufügen»-Buttons.',
Expand Down
3 changes: 2 additions & 1 deletion resources/lang/en/fieldtypes.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@
'assets.config.show_filename' => 'Show the filename next to the preview image.',
'assets.config.show_set_alt' => 'Show a link to set the Alt Text of any images.',
'assets.config.query_scopes' => 'Choose which query scopes should be applied when retrieving selectable assets.',
'assets.dynamic_folder_pending' => 'This upload folder will be available once :field is set.',
'assets.dynamic_folder_pending_field' => 'This field will be available once :field is set.',
'assets.dynamic_folder_pending_save' => 'This field will be available after saving.',
'assets.title' => 'Assets',
'bard.config.allow_source' => 'Enable to view the HTML source code while writing.',
'bard.config.always_show_set_button' => 'Enable to always show the "Add Set" button.',
Expand Down
2 changes: 1 addition & 1 deletion resources/lang/fr/fieldtypes.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
'assets.config.restrict' => 'Empêchez les utilisateurs de naviguer vers d’autres dossiers.',
'assets.config.show_filename' => 'Affichez le nom du fichier à côté de l’image de prévisualisation.',
'assets.config.show_set_alt' => 'Affichez un lien afin de définir le texte alternatif pour n’importe quelle image.',
'assets.dynamic_folder_pending' => 'Ce dossier de téléchargement sera disponible dès que :field sera défini.',
'assets.dynamic_folder_pending_field' => 'Ce dossier de téléchargement sera disponible dès que :field sera défini.',
'assets.title' => 'Assets',
'bard.config.allow_source' => 'Activez l’option pour afficher le code source HTML pendant l’écriture.',
'bard.config.always_show_set_button' => 'Activez l’option pour toujours afficher le bouton "Ajouter un ensemble".',
Expand Down
Loading