Template:CreateHub/styles.css: Difference between revisions
Appearance
No edit summary |
No edit summary |
||
| Line 1: | Line 1: | ||
/* | /* Center the pair horizontally */ | ||
.creation-row { | .creation-row { | ||
display: flex; | display: flex; | ||
| Line 6: | Line 6: | ||
} | } | ||
/* Make the | /* Make the inputbox output act as a flex row */ | ||
.creation-row .mw-inputbox-centered { | .creation-row .mw-inputbox-centered { | ||
display: flex; | display: flex; | ||
| Line 12: | Line 12: | ||
} | } | ||
.creation-row . | .creation-row .mw-inputbox-centered form { | ||
display: flex; | display: flex; | ||
align-items: center; | align-items: center; | ||
| Line 18: | Line 18: | ||
} | } | ||
/* | /* Fixed, matching size */ | ||
.creation-row | .creation-row input[type="text"], | ||
.creation-row | .creation-row input[type="submit"] { | ||
width: 260px | width: 260px; | ||
height: 40px | height: 40px; | ||
box-sizing: border-box; | box-sizing: border-box; | ||
} | } | ||
/* --- | /* --- Text input styling --- */ | ||
.creation-row | .creation-row input[type="text"] { | ||
border: 1.5px solid #000 | border: 1.5px solid #000; | ||
border-radius: 2px | border-radius: 2px; | ||
background: #fff | background: #fff; | ||
font-size: 0.95rem | font-size: 0.95rem; | ||
text-align: center | text-align: center; | ||
font-style: italic | font-style: italic; | ||
} | } | ||
.creation-row | .creation-row input[type="text"]::placeholder { | ||
text-align: center; | text-align: center; | ||
color: #777; | color: #777; | ||
| Line 42: | Line 42: | ||
} | } | ||
/* --- | /* --- Submit button: nuke default styles, rebuild --- */ | ||
.creation-row | .creation-row input[type="submit"] { | ||
border: 1.5px solid #000 | all: unset; /* remove MediaWiki/UA styles */ | ||
border-radius: 2px | box-sizing: border-box; | ||
background: transparent | display: inline-block; | ||
color: #000 | width: 260px; | ||
font-weight: 600 | height: 40px; | ||
font-size: 0.95rem | |||
text-align: center | border: 1.5px solid #000; | ||
border-radius: 2px; | |||
background: transparent; | |||
color: #000; | |||
font-weight: 600; | |||
font-size: 0.95rem; | |||
text-align: center; | |||
cursor: pointer; | cursor: pointer; | ||
| Line 61: | Line 66: | ||
/* Hover (enabled only) */ | /* Hover (enabled only) */ | ||
.creation-row | .creation-row input[type="submit"]:hover:not(:disabled) { | ||
background-color: #f2f2f2 | background-color: #f2f2f2; | ||
transform: translateY(-1px); | transform: translateY(-1px); | ||
} | } | ||
/* Active | /* Active */ | ||
.creation-row | .creation-row input[type="submit"]:active:not(:disabled) { | ||
transform: translateY(0); | transform: translateY(0); | ||
} | } | ||
/* Disabled | /* Disabled state */ | ||
.creation-row | .creation-row input[type="submit"]:disabled { | ||
background-color: #f5f5f5 | background-color: #f5f5f5; | ||
border-color: #ccc | border-color: #ccc; | ||
color: #888 | color: #888; | ||
cursor: not-allowed; | cursor: not-allowed; | ||
} | } | ||
Revision as of 14:38, 13 November 2025
/* Center the pair horizontally */
.creation-row {
display: flex;
justify-content: center;
margin: 0.75rem 0;
}
/* Make the inputbox output act as a flex row */
.creation-row .mw-inputbox-centered {
display: flex;
justify-content: center;
}
.creation-row .mw-inputbox-centered form {
display: flex;
align-items: center;
gap: 1rem;
}
/* Fixed, matching size */
.creation-row input[type="text"],
.creation-row input[type="submit"] {
width: 260px;
height: 40px;
box-sizing: border-box;
}
/* --- Text input styling --- */
.creation-row input[type="text"] {
border: 1.5px solid #000;
border-radius: 2px;
background: #fff;
font-size: 0.95rem;
text-align: center;
font-style: italic;
}
.creation-row input[type="text"]::placeholder {
text-align: center;
color: #777;
font-style: italic;
}
/* --- Submit button: nuke default styles, rebuild --- */
.creation-row input[type="submit"] {
all: unset; /* remove MediaWiki/UA styles */
box-sizing: border-box;
display: inline-block;
width: 260px;
height: 40px;
border: 1.5px solid #000;
border-radius: 2px;
background: transparent;
color: #000;
font-weight: 600;
font-size: 0.95rem;
text-align: center;
cursor: pointer;
transition:
background-color 0.2s ease,
transform 0.15s ease,
border-color 0.15s ease;
}
/* Hover (enabled only) */
.creation-row input[type="submit"]:hover:not(:disabled) {
background-color: #f2f2f2;
transform: translateY(-1px);
}
/* Active */
.creation-row input[type="submit"]:active:not(:disabled) {
transform: translateY(0);
}
/* Disabled state */
.creation-row input[type="submit"]:disabled {
background-color: #f5f5f5;
border-color: #ccc;
color: #888;
cursor: not-allowed;
}