Skip to content

Commit

Permalink
Add Tarteaucitron for JS management (#205)
Browse files Browse the repository at this point in the history
  • Loading branch information
Ash-Crow authored Sep 3, 2024
1 parent 6917390 commit 9ed722f
Show file tree
Hide file tree
Showing 100 changed files with 15,476 additions and 78 deletions.
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ dist/
downloads/
eggs/
.eggs/
lib/
lib64/
parts/
sdist/
Expand Down Expand Up @@ -115,6 +114,9 @@ ENV/
env.bak/
venv.bak/

# JS stuff
node_modules/

# Spyder project settings
.spyderproject
.spyproject
Expand Down
Binary file modified content_manager/locale/fr/LC_MESSAGES/django.mo
Binary file not shown.
168 changes: 111 additions & 57 deletions content_manager/locale/fr/LC_MESSAGES/django.po
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ msgid ""
msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2024-08-27 18:47+0200\n"
"PO-Revision-Date: 2024-08-27 18:58+0200\n"
"POT-Creation-Date: 2024-09-02 19:25+0200\n"
"PO-Revision-Date: 2024-09-02 19:26+0200\n"
"Last-Translator: \n"
"Language-Team: \n"
"Language: fr\n"
Expand Down Expand Up @@ -201,7 +201,7 @@ msgstr "Badge"
#: content_manager/blocks.py:616 content_manager/blocks.py:625
#: content_manager/blocks.py:667 content_manager/blocks.py:781
#: content_manager/blocks.py:811 content_manager/blocks.py:924
#: content_manager/models.py:323
#: content_manager/models.py:341
msgid "Title"
msgstr "Titre"

Expand Down Expand Up @@ -892,67 +892,111 @@ msgstr "Page de contenu"
msgid "Tag"
msgstr "Étiquette"

#: content_manager/models.py:95
#: content_manager/models.py:65 content_manager/models.py:100
msgid "Custom scripts"
msgstr "Scripts personnalisés"

#: content_manager/models.py:70
msgid "Scripts in the <head> section"
msgstr "Scripts dans la section <head>"

#: content_manager/models.py:71
msgid "Allows for scripts to be placed in the <head> tag of the website pages."
msgstr ""
"Permet de placer des scripts à l’intérieur du tag <head> des pages du site."

#: content_manager/models.py:77
msgid "Scripts in the <body> section"
msgstr "Scripts dans la section <body>"

#: content_manager/models.py:78
msgid ""
"Allows for scripts to be placed at the end of the <body> tag of the website "
"pages."
msgstr ""
"Permet de placer des scripts à l’intérieur du tag <body> des pages du site."

#: content_manager/models.py:82
msgid "Use Tarteaucitron?"
msgstr "Utiliser Tarteaucitron ?"

#: content_manager/models.py:86
msgid ""
"See <a href=\"https://sites-faciles.beta.numerique.gouv.fr/documentation/"
"gestion-des-cookies/\">Documentation</a>"
msgstr ""
"Voir <a href=\"https://sites-faciles.beta.numerique.gouv.fr/documentation/"
"gestion-des-cookies/\">Documentation</a>"

#: content_manager/models.py:101
msgid ""
"Allows to add custom CSS and JS to the site, for example for Matomo, "
"Tarteaucitron…"
msgstr ""
"Permet d’ajouter du CSS et du JS personnalisé au site, par exemple pour "
"Matomo ou Tarteaucitron."

#: content_manager/models.py:109
msgid "Site configuration"
msgstr "Configuration du site"

#: content_manager/models.py:96
#: content_manager/models.py:110
msgid "Site configurations"
msgstr "Configurations du site"

#: content_manager/models.py:99
#: content_manager/models.py:113
msgid "Institution (header)"
msgstr "Institution (en-tête)"

#: content_manager/models.py:102
#: content_manager/models.py:117
msgid ""
"Institution brand as defined on page https://www.info.gouv.fr/marque-de-"
"letat/le-bloc-marque"
"Institution brand as defined on <a href=\"https://www.info.gouv.fr/marque-de-"
"letat/le-bloc-marque\">official page</a>."
msgstr ""
"Nom de l’institution tel que défini sur la page https://www.info.gouv.fr/"
"marque-de-letat/le-bloc-marque"
"Nom de l’institution tel que défini sur la <a href=\"https://www.info.gouv."
"fr/marque-de-letat/le-bloc-marque\">page officielle</a>."

#: content_manager/models.py:106
#: content_manager/models.py:122
msgid "Institution with line break (header)"
msgstr "Institution avec césure (en-tête)"

#: content_manager/models.py:110
#: content_manager/models.py:126
msgid "Institution brand with <br /> tags for line breaks"
msgstr "Nom de l’institution avec des <br /> pour les retours à la ligne"

#: content_manager/models.py:113
#: content_manager/models.py:129
msgid "Institution (footer)"
msgstr "Institution (pied)"

#: content_manager/models.py:120
#: content_manager/models.py:136
msgid "Institution with line break (footer)"
msgstr "Institution avec césure (pied)"

#: content_manager/models.py:127 content_manager/models.py:129
#: content_manager/models.py:143 content_manager/models.py:145
msgid "Site title"
msgstr "Titre du site"

#: content_manager/models.py:133 content_manager/models.py:135
#: content_manager/models.py:149 content_manager/models.py:151
msgid "Site tagline"
msgstr "Sous-titre du site"

#: content_manager/models.py:140
#: content_manager/models.py:156
msgid "Notice title"
msgstr "Titre du bandeau"

#: content_manager/models.py:144 content_manager/models.py:151
#: content_manager/models.py:160 content_manager/models.py:167
msgid "Can include HTML"
msgstr "Peut inclure du HTML"

#: content_manager/models.py:148
#: content_manager/models.py:164
msgid "Notice description"
msgstr "Description du bandeau"

#: content_manager/models.py:154
#: content_manager/models.py:170
msgid "Notice type"
msgstr "Type de bandeau"

#: content_manager/models.py:160
#: content_manager/models.py:177
msgid ""
"Use is strictly regulated, see <a href=\"https://www.systeme-de-"
"design.gouv.fr/composants-et-modeles/composants/bandeau-d-information-"
Expand All @@ -962,71 +1006,71 @@ msgstr ""
"systeme-de-design.gouv.fr/composants-et-modeles/composants/bandeau-d-"
"information-importante/\">documentation</a>."

#: content_manager/models.py:166
#: content_manager/models.py:184
msgid "Notice link"
msgstr "Lien du bandeau"

#: content_manager/models.py:169
#: content_manager/models.py:187
msgid "Standardized consultation link at the end of the notice."
msgstr "Lien de consultation standardisé à la fin du bandeau."

#: content_manager/models.py:173
#: content_manager/models.py:191
msgid "Notice icon class"
msgstr "Classe d’icône du bandeau"

#: content_manager/models.py:177
#: content_manager/models.py:195
msgid "For weather alerts only"
msgstr "Pour les bandeaux de vigilance météo uniquement"

#: content_manager/models.py:180
#: content_manager/models.py:198
msgid "Collapsible?"
msgstr "Refermable ?"

#: content_manager/models.py:182
#: content_manager/models.py:200
msgid "Show the BETA tag next to the title"
msgstr "Afficher la mention BETA à côté du titre"

#: content_manager/models.py:185 content_manager/models.py:359
#: content_manager/models.py:203 content_manager/models.py:377
msgid "Description"
msgstr "Description"

#: content_manager/models.py:198 content_manager/models.py:256
#: content_manager/models.py:216 content_manager/models.py:274
msgid "Operator logo"
msgstr "Logo opérateur"

#: content_manager/models.py:202
#: content_manager/models.py:220
msgid "Logo alt text"
msgstr "Alternative textuelle du logo"

#: content_manager/models.py:205
#: content_manager/models.py:223
msgid "Must contain the text present in the image."
msgstr "Doit impérativement contenir le texte présent dans l’image."

#: content_manager/models.py:208
#: content_manager/models.py:226
msgid "Width (em)"
msgstr "Largeur (em)"

#: content_manager/models.py:214
#: content_manager/models.py:232
msgid ""
"To be adjusted according to the width of the logo. Example for a "
"vertical logo: 3.5, Example for a horizontal logo: 8."
msgstr ""
"À ajuster en fonction de la largeur du logo. Exemple pour un logo vertical: "
"3.5, Exemple pour un logo horizontal: 8."

#: content_manager/models.py:223
#: content_manager/models.py:241
msgid "Newsletter description"
msgstr "Description de la lettre d’information"

#: content_manager/models.py:226
#: content_manager/models.py:244
msgid "Newsletter registration URL"
msgstr "URL d‘inscription à la lettre d’information"

#: content_manager/models.py:244
#: content_manager/models.py:262
msgid "Important notice"
msgstr "Bandeau d’information importante"

#: content_manager/models.py:246
#: content_manager/models.py:264
msgid ""
"The important notice banner should only be used for essential and temporary "
"information. (Excessive or continuous use risks “drowning” "
Expand All @@ -1036,79 +1080,79 @@ msgstr ""
"information primordiale et temporaire. (Une utilisation excessive ou "
"continue risque de “noyer” le message)"

#: content_manager/models.py:265
#: content_manager/models.py:283
msgid "Advanced settings"
msgstr "Paramètres avancés"

#: content_manager/models.py:275
#: content_manager/models.py:293
msgid "Header"
msgstr "En-tête"

#: content_manager/models.py:282
#: content_manager/models.py:300
msgid "Footer"
msgstr "Pied de page"

#: content_manager/models.py:292
#: content_manager/models.py:310
msgid "Newsletter"
msgstr "Lettre d’information"

#: content_manager/models.py:294 content_manager/models.py:340
#: content_manager/models.py:312 content_manager/models.py:358
msgid "Social media items"
msgstr "Liens de réseaux sociaux"

#: content_manager/models.py:298
#: content_manager/models.py:316
msgid "Generic"
msgstr "Génériques"

#: content_manager/models.py:299
#: content_manager/models.py:317
msgid "Brand block"
msgstr "Bloc-marque"

#: content_manager/models.py:300
#: content_manager/models.py:318
msgid "Newsletter and social media"
msgstr "Lettre d’information et réseaux sociaux"

#: content_manager/models.py:326
#: content_manager/models.py:344
msgid "URL"
msgstr "URL"

#: content_manager/models.py:330
#: content_manager/models.py:348
msgid "Icon class"
msgstr "Classe d’icône"

#: content_manager/models.py:339
#: content_manager/models.py:357
msgid "Social media item"
msgstr "Lien de réseau social"

#: content_manager/models.py:346
#: content_manager/models.py:364
msgid "Category"
msgstr "Catégorie"

#: content_manager/models.py:349
#: content_manager/models.py:367
msgid "Mega menu category"
msgstr "Catégorie de méga menu"

#: content_manager/models.py:350
#: content_manager/models.py:368
msgid "Mega menu categories"
msgstr "Catégories de méga menu"

#: content_manager/models.py:355
#: content_manager/models.py:373
msgid "Name"
msgstr "Nom"

#: content_manager/models.py:360
#: content_manager/models.py:378
msgid "Main link"
msgstr "Lien principal"

#: content_manager/models.py:370
#: content_manager/models.py:388
msgid "Categories"
msgstr "Catégories"

#: content_manager/models.py:371
#: content_manager/models.py:389
msgid "Maximum 4 categories, each with maximum 8 links."
msgstr "Maximum 4 catégories, chacune contenant maximum 8 liens."

#: content_manager/models.py:382
#: content_manager/models.py:400
msgid "Mega menu"
msgstr "Méga menu"

Expand Down Expand Up @@ -1178,3 +1222,13 @@ msgstr "Pages avec l’étiquette {tag}"
#, python-brace-format
msgid "List of pages tagged with {tag}"
msgstr "Liste de pages avec l’étiquette {tag}"

#~ msgid ""
#~ "Paste the snippets from step 3 of https://tarteaucitron.io/fr/install/ in "
#~ "the Body scripts field."
#~ msgstr ""
#~ "Coller les morceaux de code de l’étape 3 de https://tarteaucitron.io/fr/"
#~ "install/ dans le champ « Scripts dans la section <body> »"

#~ msgid "Custom scripts (CSS / JS)"
#~ msgstr "Scripts personnalisés (CSS / JS)"
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Generated by Django 5.0.8 on 2024-08-30 09:32

from django.db import migrations


class Migration(migrations.Migration):
dependencies = [
("content_manager", "0042_alter_contentpage_body"),
("wagtailcore", "0094_alter_page_locale"),
]

operations = [
migrations.RenameModel(
old_name="AnalyticsSettings",
new_name="CustomScriptsSettings",
),
]
Loading

0 comments on commit 9ed722f

Please sign in to comment.