« Modèle:IconButton/styles.css » : différence entre les versions
De Nefald
Autres actions
Création |
m taille icone et position |
||
| Ligne 40 : | Ligne 40 : | ||
} | } | ||
/* Conteneur d'image | /* Conteneur d'image - prend tout l'espace */ | ||
.icon-button .mw-file-description { | .icon-button .mw-file-description { | ||
display: flex; | display: flex !important; | ||
align-items: center; | align-items: center; | ||
justify-content: center; | justify-content: center; | ||
width: | width: 100% !important; | ||
height: | height: 100% !important; | ||
margin: 0; | margin: 0 !important; | ||
padding: 8px; | |||
box-sizing: border-box; | |||
} | } | ||
/* Image responsive */ | /* Image responsive - remplit le conteneur */ | ||
.icon-button img { | .icon-button img { | ||
max-width: 100%; | max-width: 100% !important; | ||
max-height: 100%; | max-height: 100% !important; | ||
width: auto !important; | width: auto !important; | ||
height: auto !important; | height: auto !important; | ||
object-fit: contain; | object-fit: contain; | ||
filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.2)); | filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.2)); | ||
} | |||
/* Masquer l'icône de lien externe */ | |||
.icon-button a.external::after { | |||
display: none !important; | |||
} | } | ||
| Ligne 77 : | Ligne 83 : | ||
.icon-button--snapchat { background: #fffc00; } | .icon-button--snapchat { background: #fffc00; } | ||
.icon-button--pinterest { background: #e60023; } | .icon-button--pinterest { background: #e60023; } | ||
.icon-button--telegram { background: #26a5e4; } | |||
.icon-button--whatsapp { background: #25d366; } | .icon-button--whatsapp { background: #25d366; } | ||
.icon-button--signal { background: #3a76f0; } | .icon-button--signal { background: #3a76f0; } | ||
/* | /* PLATEFORMES TECH */ | ||
.icon-button--github { background: #181717; } | .icon-button--github { background: #181717; } | ||
.icon-button--gitlab { background: #fc6d26; } | .icon-button--gitlab { background: #fc6d26; } | ||
.icon-button--stackoverflow { background: #f48024; } | .icon-button--stackoverflow { background: #f48024; } | ||
.icon-button--dev { background: #0a0a0a; } | |||
.icon-button--medium { background: #000000; } | |||
.icon-button--substack { background: #ff6719; } | |||
.icon-button--hashnode { background: #2962ff; } | |||
/* | /* GAMING */ | ||
.icon-button-- | .icon-button--steam { background: #171a21; } | ||
.icon-button-- | .icon-button--epicgames { background: #313131; } | ||
.icon-button-- | .icon-button--playstation { background: #003087; } | ||
.icon-button--xbox { background: #107c10; } | |||
.icon-button--nintendo { background: #e60012; } | |||
.icon-button-- | |||
.icon-button-- | |||
/* | /* MUSIQUE/VIDÉO */ | ||
.icon-button-- | .icon-button--spotify { background: #1db954; } | ||
.icon-button-- | .icon-button--soundcloud { background: #ff5500; } | ||
.icon-button-- | .icon-button--applemusic { background: #fa243c; } | ||
.icon-button-- | .icon-button--deezer { background: #00c7f2; } | ||
.icon-button--vimeo { background: #1ab7ea; } | |||
.icon-button--dailymotion { background: #0066dc; } | |||
/* | /* OUTILS PRO */ | ||
.icon-button-- | .icon-button--slack { background: #4a154b; } | ||
.icon-button-- | .icon-button--notion { background: #000000; } | ||
.icon-button-- | .icon-button--trello { background: #0052cc; } | ||
.icon-button-- | .icon-button--asana { background: #f06a6a; } | ||
.icon-button--jira { background: #0052cc; } | |||
/* COULEURS | /* COULEURS GÉNÉRIQUES */ | ||
.icon-button--primary | .icon-button--primary, .icon-button--blue { background: #3366cc; } | ||
.icon-button--blue { background: #3366cc; } | .icon-button--secondary, .icon-button--gray, .icon-button--grey { background: #72777d; } | ||
.icon-button--secondary | .icon-button--success, .icon-button--green { background: #14866d; } | ||
.icon-button--gray | .icon-button--danger, .icon-button--red { background: #d73333; } | ||
.icon-button--grey { background: # | .icon-button--warning, .icon-button--yellow { background: #fc3; } | ||
.icon-button--success | .icon-button--info, .icon-button--cyan { background: #00b8d4; } | ||
.icon-button--green { background: #14866d; } | .icon-button--purple, .icon-button--violet { background: #6f42c1; } | ||
.icon-button--danger | |||
.icon-button--red { background: #d73333; } | |||
.icon-button--warning | |||
.icon-button--yellow { background: #fc3; } | |||
.icon-button--info | |||
.icon-button--cyan { background: #00b8d4; } | |||
.icon-button--purple | |||
.icon-button--violet { background: #6f42c1; } | |||
.icon-button--pink { background: #d63384; } | .icon-button--pink { background: #d63384; } | ||
.icon-button--orange { background: #fd7e14; } | .icon-button--orange { background: #fd7e14; } | ||
Version du 6 février 2026 à 06:23
/* ============================================
ICON BUTTON - Boutons icônes compacts
============================================ */
.icon-button {
width: 48px;
height: 48px;
border-radius: 8px;
overflow: hidden;
transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
position: relative;
background: #6c757d;
display: inline-flex;
align-items: center;
justify-content: center;
margin: 4px;
vertical-align: middle;
}
.icon-button:hover {
transform: translateY(-2px) scale(1.05);
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}
.icon-button a {
display: flex !important;
align-items: center;
justify-content: center;
width: 100%;
height: 100%;
padding: 0;
color: transparent !important;
text-decoration: none !important;
}
.icon-button a:hover,
.icon-button a:visited {
color: transparent !important;
}
/* Conteneur d'image - prend tout l'espace */
.icon-button .mw-file-description {
display: flex !important;
align-items: center;
justify-content: center;
width: 100% !important;
height: 100% !important;
margin: 0 !important;
padding: 8px;
box-sizing: border-box;
}
/* Image responsive - remplit le conteneur */
.icon-button img {
max-width: 100% !important;
max-height: 100% !important;
width: auto !important;
height: auto !important;
object-fit: contain;
filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.2));
}
/* Masquer l'icône de lien externe */
.icon-button a.external::after {
display: none !important;
}
/* ========== COULEURS PRÉDÉFINIES ========== */
/* RÉSEAUX SOCIAUX */
.icon-button--discord { background: #5865f2; }
.icon-button--twitter { background: #1da1f2; }
.icon-button--x { background: #000000; }
.icon-button--mastodon { background: #6364ff; }
.icon-button--facebook { background: #1877f2; }
.icon-button--instagram { background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%); }
.icon-button--youtube { background: #ff0000; }
.icon-button--twitch { background: #9146ff; }
.icon-button--tiktok { background: #000000; }
.icon-button--linkedin { background: #0a66c2; }
.icon-button--reddit { background: #ff4500; }
.icon-button--snapchat { background: #fffc00; }
.icon-button--pinterest { background: #e60023; }
.icon-button--telegram { background: #26a5e4; }
.icon-button--whatsapp { background: #25d366; }
.icon-button--signal { background: #3a76f0; }
/* PLATEFORMES TECH */
.icon-button--github { background: #181717; }
.icon-button--gitlab { background: #fc6d26; }
.icon-button--stackoverflow { background: #f48024; }
.icon-button--dev { background: #0a0a0a; }
.icon-button--medium { background: #000000; }
.icon-button--substack { background: #ff6719; }
.icon-button--hashnode { background: #2962ff; }
/* GAMING */
.icon-button--steam { background: #171a21; }
.icon-button--epicgames { background: #313131; }
.icon-button--playstation { background: #003087; }
.icon-button--xbox { background: #107c10; }
.icon-button--nintendo { background: #e60012; }
/* MUSIQUE/VIDÉO */
.icon-button--spotify { background: #1db954; }
.icon-button--soundcloud { background: #ff5500; }
.icon-button--applemusic { background: #fa243c; }
.icon-button--deezer { background: #00c7f2; }
.icon-button--vimeo { background: #1ab7ea; }
.icon-button--dailymotion { background: #0066dc; }
/* OUTILS PRO */
.icon-button--slack { background: #4a154b; }
.icon-button--notion { background: #000000; }
.icon-button--trello { background: #0052cc; }
.icon-button--asana { background: #f06a6a; }
.icon-button--jira { background: #0052cc; }
/* COULEURS GÉNÉRIQUES */
.icon-button--primary, .icon-button--blue { background: #3366cc; }
.icon-button--secondary, .icon-button--gray, .icon-button--grey { background: #72777d; }
.icon-button--success, .icon-button--green { background: #14866d; }
.icon-button--danger, .icon-button--red { background: #d73333; }
.icon-button--warning, .icon-button--yellow { background: #fc3; }
.icon-button--info, .icon-button--cyan { background: #00b8d4; }
.icon-button--purple, .icon-button--violet { background: #6f42c1; }
.icon-button--pink { background: #d63384; }
.icon-button--orange { background: #fd7e14; }
.icon-button--teal { background: #20c997; }
.icon-button--indigo { background: #6610f2; }
.icon-button--black { background: #000; }
.icon-button--white { background: #fff; }
.icon-button--light { background: #f8f9fa; }
.icon-button--dark { background: #343a40; }