详情侧边栏收窄至 380px;分享页加载时自动打开首张照片详情

This commit is contained in:
gallery
2026-11-15 20:42:29 +08:00
parent 34e69bac61
commit c62f24bb9d
5 changed files with 23 additions and 7 deletions
+1 -1
View File
@@ -12,7 +12,7 @@ const Header = () => {
<div
className={classNames(
'sticky top-0 z-10 h-16 bg-dark-bg text-dark-text flex items-center justify-between pl-[14px] lg:pl-[281px] pr-4',
{ 'lg:mr-[404px]': pinned }
{ 'lg:mr-[364px]': pinned }
)}
>
<h1 className="mr-4 lg:mr-8 flex-shrink-0 flex items-center">
+1 -1
View File
@@ -37,7 +37,7 @@ const Layout = ({ children, title, ...otherProps }: LayoutProps) => {
</Authorized>
<div
className={`mx-6 my-3 lg:mt-5 lg:mr-16 lg:ml-[292px] ${
pinned && sidebarContent ? 'lg:pr-[420px]' : ''
pinned && sidebarContent ? 'lg:pr-[380px]' : ''
}`}
id="layout-content"
>
+1 -1
View File
@@ -11,7 +11,7 @@ const Container = styled.div`
bottom: 20px;
right: 20px;
/* Match the sidebar width */
width: 420px;
width: 380px;
/* Keep notifications above the sidebar (z-40) and modals (z-40) */
z-index: 50;
+1 -1
View File
@@ -113,7 +113,7 @@ export const Sidebar = () => {
content == null && !pinned ? 'translate-x-full' : 'translate-x-0'
} ${
pinned ? 'lg:border-l' : 'lg:shadow-separator'
} lg:w-[420px] lg:right-0 lg:top-0 lg:z-40`}
} lg:w-[380px] lg:right-0 lg:top-0 lg:z-40`}
>
{content}
<div className="h-24"></div>