mirror of
https://github.com/ourongxing/newsnow.git
synced 2025-01-19 03:09:14 +08:00
fx: keep navbar always centered
This commit is contained in:
parent
cc1aee2ae8
commit
884d55d71d
@ -51,7 +51,7 @@ function Refresh() {
|
||||
export function Header() {
|
||||
return (
|
||||
<>
|
||||
<span className="flex">
|
||||
<span className="flex justify-self-start">
|
||||
<Link to="/" className="flex gap-2 items-center">
|
||||
<div className="h-10 w-10 bg-cover" title="logo" style={{ backgroundImage: "url(/icon.svg)" }} />
|
||||
<span className="text-2xl font-brand line-height-none!">
|
||||
@ -66,10 +66,12 @@ export function Header() {
|
||||
{`v${Version}`}
|
||||
</a>
|
||||
</span>
|
||||
<span className="hidden md:inline-block">
|
||||
<NavBar />
|
||||
<span className="justify-self-center">
|
||||
<span className="hidden md:(inline-block)">
|
||||
<NavBar />
|
||||
</span>
|
||||
</span>
|
||||
<span className="flex gap-2 items-center text-xl text-primary-600 dark:text-primary">
|
||||
<span className="justify-self-end flex gap-2 items-center text-xl text-primary-600 dark:text-primary">
|
||||
<GoTop />
|
||||
<Refresh />
|
||||
<Menu />
|
||||
|
@ -47,11 +47,15 @@ function RootComponent() {
|
||||
"lg:(px-24)",
|
||||
])}
|
||||
>
|
||||
<header className={clsx([
|
||||
"flex justify-between items-center py-4 px-5",
|
||||
"lg:(py-6)",
|
||||
"sticky top-0 z-10 backdrop-blur-md",
|
||||
])}
|
||||
<header
|
||||
className={clsx([
|
||||
"grid items-center py-4 px-5",
|
||||
"lg:(py-6)",
|
||||
"sticky top-0 z-10 backdrop-blur-md",
|
||||
])}
|
||||
style={{
|
||||
gridTemplateColumns: "50px auto 50px",
|
||||
}}
|
||||
>
|
||||
<Header />
|
||||
</header>
|
||||
|
Loading…
x
Reference in New Issue
Block a user