Skip to content

Commit 4ac178c

Browse files
committed
Center the search control in the header
1 parent abd1050 commit 4ac178c

File tree

2 files changed

+11
-1
lines changed

2 files changed

+11
-1
lines changed

packages/starlight-theme-mtasa/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@multitheftauto/starlight-theme-mtasa",
3-
"version": "1.2.0",
3+
"version": "1.3.0",
44
"description": "Starlight theme for Multi Theft Auto",
55
"type": "module",
66
"repository": {

packages/starlight-theme-mtasa/theme.css

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,16 @@
3737
height: var(--sl-nav-height-original);
3838
}
3939

40+
/* Overwrite the template for the grid of the header, so we can move the search to the actual center. */
41+
.page > .header > .header {
42+
grid-template-columns: auto 1fr auto;
43+
}
44+
45+
/* Center the search control in the header. */
46+
.page > .header > .header div:has(site-search) {
47+
justify-content: center;
48+
}
49+
4050
/* Fix the height of the logo that depends on the original height of the header. */
4151
.page > .header > .header .site-title img {
4252
height: calc(var(--sl-nav-height-original) - 2 * var(--sl-nav-pad-y));

0 commit comments

Comments
 (0)