diff --git a/lacommunaute/pages/urls.py b/lacommunaute/pages/urls.py index a18ea282e..e017aaa73 100644 --- a/lacommunaute/pages/urls.py +++ b/lacommunaute/pages/urls.py @@ -15,6 +15,7 @@ urlpatterns = [ path("", views.HomeView.as_view(), name="home"), + path("ws/", views.HomeWithSearchView.as_view(), name="home_with_search"), path("accessibilite/", views.accessibilite, name="accessibilite"), path("mentions-legales/", views.mentions_legales, name="mentions_legales"), path("politique-de-confidentialite/", views.politique_de_confidentialite, name="politique_de_confidentialite"), diff --git a/lacommunaute/pages/views.py b/lacommunaute/pages/views.py index a2894c0d2..99da260bc 100644 --- a/lacommunaute/pages/views.py +++ b/lacommunaute/pages/views.py @@ -38,6 +38,17 @@ def get_context_data(self, **kwargs: Any) -> dict[str, Any]: return context +class HomeWithSearchView(TemplateView): + template_name = "pages/home_with_search.html" + + def get_context_data(self, **kwargs: Any) -> dict[str, Any]: + context = super().get_context_data(**kwargs) + context["forums_category"] = Forum.objects.filter(kind=ForumKind.PUBLIC_FORUM, parent__type=1).order_by( + "-updated" + )[:4] + return context + + def accessibilite(request): return render(request, "pages/accessibilite.html") diff --git a/lacommunaute/static/images/illustration-01.png b/lacommunaute/static/images/illustration-01.png new file mode 100644 index 000000000..43b8e91db Binary files /dev/null and b/lacommunaute/static/images/illustration-01.png differ diff --git a/lacommunaute/static/images/search-bg-left.png b/lacommunaute/static/images/search-bg-left.png new file mode 100644 index 000000000..d44051abd Binary files /dev/null and b/lacommunaute/static/images/search-bg-left.png differ diff --git a/lacommunaute/static/images/search-bg-right.png b/lacommunaute/static/images/search-bg-right.png new file mode 100644 index 000000000..72ebaa801 Binary files /dev/null and b/lacommunaute/static/images/search-bg-right.png differ diff --git a/lacommunaute/static/stylesheets/itou_communaute.scss b/lacommunaute/static/stylesheets/itou_communaute.scss index 3819a8b04..abe71e7d5 100644 --- a/lacommunaute/static/stylesheets/itou_communaute.scss +++ b/lacommunaute/static/stylesheets/itou_communaute.scss @@ -40,7 +40,7 @@ border-radius: 50%; overflow: hidden; - > img { + >img { width: 100%; height: auto; object-fit: cover; @@ -110,7 +110,7 @@ span.highlighted { .input-group-rounded-pill { border-radius: 50rem !important; - > input { + >input { border-top-left-radius: 50rem !important; border-bottom-left-radius: 50rem !important; } @@ -162,13 +162,13 @@ span.highlighted { } } - > div { + >div { padding: 16px 8px; margin: 0; margin-bottom: 8px; min-height: 140px; - > span { + >span { display: block; } @@ -188,7 +188,7 @@ span.highlighted { } .definition { - > div { + >div { padding: 16px 8px 0 16px; margin-bottom: 8px; @@ -209,7 +209,7 @@ span.highlighted { padding-top: 40%; } - > iframe { + >iframe { position: absolute; top: 0; left: 0; @@ -222,3 +222,44 @@ span.highlighted { .rating .ri-star-fill { color: rgb(254, 208, 0); } + +.s-home-search { + background-position: center left, center right; + background-repeat: no-repeat; + background-color: var(--bs-communaute); + background-image: url(../images/search-bg-left.png), + url(../images/search-bg-right.png); +} + +.s-home-search__row { + display: flex; + align-content: center; + min-height: 23rem; +} + +.s-home-search__form { + background-color: var(--bs-white); + padding: 1rem; + border-radius: 8px; +} + +.s-home-search__form .input-group-text, +.s-home-search__form .form-control { + border-color: var(--bs-white) !important; +} + + +.s-home-search__form .input-group-text { + padding-left: 8px; + padding-right: 8px; +} + +@media only screen and (max-width: 992px) { + .s-home-search { + background-image: none; + } + + .s-home-search__row { + min-height: initial; + } +} diff --git a/lacommunaute/templates/pages/home_with_search.html b/lacommunaute/templates/pages/home_with_search.html new file mode 100644 index 000000000..5784c51b4 --- /dev/null +++ b/lacommunaute/templates/pages/home_with_search.html @@ -0,0 +1,97 @@ +{% extends "layouts/base.html" %} +{% load static %} +{% load i18n %} +{% load date_filters %} +{% block title %}Accueil{{ block.super }}{% endblock %} +{% block meta_description %} + Entraide, information et apprentissage pour les professionnels de l'Insertion par l'Activité Economique. Améliorer sa pratique professionnelle d’accompagnateurs de personnes éloignées de l’emploi. +{% endblock meta_description %} +{% block body_class %}p-home{% endblock %} +{% block content %} + +
+
+
+
+
+

Je veux poser une question

+
+
+
+
+

Je veux réaliser un diagnostic

+
+
+
+
+

Je veux chercher un emploi inclusif

+
+
+
+
+
+
+
+
+
+

Les dernières fiches pratiques mises à jour

+
+
+
+
+
+ +
+
+
+
+ +
+
+
+
+
+{% endblock %} diff --git a/locale/fr/LC_MESSAGES/django.mo b/locale/fr/LC_MESSAGES/django.mo index c6d3c6715..c23627143 100644 Binary files a/locale/fr/LC_MESSAGES/django.mo and b/locale/fr/LC_MESSAGES/django.mo differ diff --git a/locale/fr/LC_MESSAGES/django.po b/locale/fr/LC_MESSAGES/django.po index e54c001c0..5e3a4ad88 100644 --- a/locale/fr/LC_MESSAGES/django.po +++ b/locale/fr/LC_MESSAGES/django.po @@ -212,6 +212,9 @@ msgstr "Rechercher" msgid "Search in" msgstr "Rechercher dans" +msgid "Search in forum" +msgstr "Rechercher dans la communauté" + #: lacommunaute/templates/machina/board_base.html:28 msgid "Advanced search" msgstr "Recherche avancée" @@ -980,19 +983,19 @@ msgid "Discussion area" msgstr "Espace d'échanges" msgid "Documents" -msgstr "Documentation" +msgstr "Fiches pratiques" msgid "See all questions" msgstr "Voir toutes les questions" msgid "See all docs" -msgstr "Voir toute la documentation" +msgstr "Voir toute les fiches pratiques" msgid "See all news" msgstr "Voir toutes les actualités" msgid "New topic on doc" -msgstr "Poser une question sur cette documentation" +msgstr "Poser une question sur cette fiche" msgid "Cancel" msgstr "Annuler"