« Modèle:Accueil/header/styles.css » : différence entre les versions
De Infothèque
Autres actions
< Modèle:Accueil | header
Logo responsive + style recherche InputBox (Infothèque) Balise : Révoqué |
Retire pointer-events (non supporté par TemplateStyles) (Infothèque) Balise : Révoqué |
||
| Ligne 51 : | Ligne 51 : | ||
/* Barre de recherche : générée par <inputbox type=search>, un vrai | /* Barre de recherche : générée par <inputbox type=search>, un vrai | ||
* champ de recherche MediaWiki (suggestions en direct | * champ de recherche MediaWiki (Entrée = recherche fonctionnelle), | ||
* la | * stylée pour retrouver l'apparence de la version précédente | ||
* (icône à gauche, texte, pilule blanche). Les suggestions en | |||
* direct dépendent d'un souci côté Citizen indépendant de ce | |||
* fichier (la recherche native du menu n'en affiche pas non plus | |||
* actuellement) — à traiter séparément côté serveur. */ | |||
.ith-home-search { | .ith-home-search { | ||
box-sizing: border-box; | box-sizing: border-box; | ||
position: relative; | |||
margin: 8px auto 32px auto; | margin: 8px auto 32px auto; | ||
max-width: 1100px; | max-width: 1100px; | ||
padding: | padding: 16px 24px 16px 52px; | ||
border: 1px solid #c9ced6; | border: 1px solid #c9ced6; | ||
border-radius: 18px; | border-radius: 18px; | ||
background-color: #ffffff; | background-color: #ffffff; | ||
box-shadow: 0 2px 10px rgba(0, 0, 0, 0.12); | box-shadow: 0 2px 10px rgba(0, 0, 0, 0.12); | ||
} | |||
.ith-home-search::before { | |||
content: "🔎"; | |||
position: absolute; | |||
left: 20px; | |||
top: 50%; | |||
transform: translateY(-50%); | |||
font-size: 20px; | |||
} | } | ||
.ith-home-search .mw-inputbox-form { | .ith-home-search .mw-inputbox-form { | ||
display: | display: block; | ||
} | } | ||
.ith-home-search input.mw-searchInput { | .ith-home-search input.mw-searchInput { | ||
box-sizing: border-box; | box-sizing: border-box; | ||
width: 100%; | width: 100%; | ||
| Ligne 80 : | Ligne 91 : | ||
font-weight: 700; | font-weight: 700; | ||
color: #1f2328; | color: #1f2328; | ||
padding: | padding: 4px; | ||
} | } | ||
/* Les boutons natifs restent présents (Entrée déclenche la | |||
* recherche via le premier bouton submit du formulaire) mais sont | |||
* masqués visuellement — l'icône ci-dessus suffit. */ | |||
.ith-home-search input[name="go"], | |||
.ith-home-search input[name="fulltext"] { | .ith-home-search input[name="fulltext"] { | ||
position: absolute; | |||
width: 1px; | |||
height: 1px; | |||
padding: 0; | |||
margin: -1px; | |||
overflow: hidden; | |||
clip: rect(0, 0, 0, 0); | |||
border: 0; | |||
} | } | ||
| Ligne 113 : | Ligne 118 : | ||
@media (max-width: 700px) { | @media (max-width: 700px) { | ||
.ith-home-search { padding: | .ith-home-search { padding: 12px 16px 12px 44px; } | ||
.ith-home-search::before { left: 16px; font-size: 17px; } | |||
.ith-home-search input.mw-searchInput { font-size: 15px; } | .ith-home-search input.mw-searchInput { font-size: 15px; } | ||
} | } | ||
Version du 12 août 2026 à 11:35
/* ============================================================
* Infothèque — Accueil : header (logo, titre, recherche)
* À coller dans : Modèle:Accueil/header/styles.css
*
* Ce bloc repose directement sur le fond d'écran de la page
* d'accueil (pas de carte derrière) — couleur de texte forcée en
* sombre et légère ombre portée, pour rester lisible quel que soit
* le thème jour/nuit du site (le fond Clouds est clair).
*
* La barre de recherche fait la même largeur que la grille de
* tuiles en dessous (1100px, cf. Modèle:Accueil/tiles/styles.css)
* pour former une colonne alignée.
* ============================================================ */
.ith-home-logo {
margin: 44px auto 8px auto;
text-align: center;
}
.ith-home-logo img {
max-width: 100%;
height: auto;
}
@media (max-width: 700px) {
.ith-home-logo { margin-top: 28px; }
.ith-home-logo img { width: 100px; }
}
@media (max-width: 420px) {
.ith-home-logo img { width: 80px; }
}
.ith-home-title {
text-align: center;
font-size: 2.4em;
font-weight: 800;
letter-spacing: 0.04em;
line-height: 1.1;
color: #1f2328;
text-shadow: 0 1px 3px rgba(255, 255, 255, 0.7);
}
.ith-home-subtitle {
text-align: center;
font-size: 0.95em;
color: #3f4147;
margin: 8px 0 24px 0;
text-shadow: 0 1px 3px rgba(255, 255, 255, 0.7);
}
/* Barre de recherche : générée par <inputbox type=search>, un vrai
* champ de recherche MediaWiki (Entrée = recherche fonctionnelle),
* stylée pour retrouver l'apparence de la version précédente
* (icône à gauche, texte, pilule blanche). Les suggestions en
* direct dépendent d'un souci côté Citizen indépendant de ce
* fichier (la recherche native du menu n'en affiche pas non plus
* actuellement) — à traiter séparément côté serveur. */
.ith-home-search {
box-sizing: border-box;
position: relative;
margin: 8px auto 32px auto;
max-width: 1100px;
padding: 16px 24px 16px 52px;
border: 1px solid #c9ced6;
border-radius: 18px;
background-color: #ffffff;
box-shadow: 0 2px 10px rgba(0, 0, 0, 0.12);
}
.ith-home-search::before {
content: "🔎";
position: absolute;
left: 20px;
top: 50%;
transform: translateY(-50%);
font-size: 20px;
}
.ith-home-search .mw-inputbox-form {
display: block;
}
.ith-home-search input.mw-searchInput {
box-sizing: border-box;
width: 100%;
border: none;
outline: none;
background: transparent;
font-size: 18px;
font-weight: 700;
color: #1f2328;
padding: 4px;
}
/* Les boutons natifs restent présents (Entrée déclenche la
* recherche via le premier bouton submit du formulaire) mais sont
* masqués visuellement — l'icône ci-dessus suffit. */
.ith-home-search input[name="go"],
.ith-home-search input[name="fulltext"] {
position: absolute;
width: 1px;
height: 1px;
padding: 0;
margin: -1px;
overflow: hidden;
clip: rect(0, 0, 0, 0);
border: 0;
}
@media (max-width: 700px) {
.ith-home-title { font-size: 1.6em; }
}
@media (max-width: 1140px) {
.ith-home-search { max-width: 92%; }
}
@media (max-width: 700px) {
.ith-home-search { padding: 12px 16px 12px 44px; }
.ith-home-search::before { left: 16px; font-size: 17px; }
.ith-home-search input.mw-searchInput { font-size: 15px; }
}