Hidden Menu,Grok,Premium subscription,Verified Orgs,other,Explore,Notifications,Messages,Communities,Bookmarks,Right Column, Muted Account Notices and Customizable Settings
< Feedback on X/Twitter Clean menu and sidebar (Supports multiple language)
if (settings.useLargerCSS) { // 计算左侧边栏宽度,使整体布局居中 const sidebarWidth = Math.max(68, Math.floor((window.innerWidth - settings.cssWidth) / 2) - 20); cssRules += `.r-1ye8kvj { max-width: ${settings.cssWidth}px !important; }`; cssRules += '.r-10f7w94 { margin-right: 0px !important; }'; // 动态计算左侧边栏宽度,使整体布局居中 cssRules += `.css-175oi2r.r-1f2l425.r-13qz1uu.r-417010.r-18u37iz > header { max-width: ${sidebarWidth}px !important; }`; // 添加主容器居中样式 cssRules += '.css-175oi2r.r-aqfbo4.r-gtdqiz.r-1gn8etr.r-1g40b8q { justify-content: center !important; }'; }===反正 AI 告诉我,这么搞就能让页面居中了.博主,要不你再优化一下
جاۋاب قايتۇرۇش ئۈچۈن كىرىش.
if (settings.useLargerCSS) {
// 计算左侧边栏宽度,使整体布局居中
const sidebarWidth = Math.max(68, Math.floor((window.innerWidth - settings.cssWidth) / 2) - 20);
cssRules += `.r-1ye8kvj { max-width: ${settings.cssWidth}px !important; }`;
cssRules += '.r-10f7w94 { margin-right: 0px !important; }';
// 动态计算左侧边栏宽度,使整体布局居中
cssRules += `.css-175oi2r.r-1f2l425.r-13qz1uu.r-417010.r-18u37iz > header { max-width: ${sidebarWidth}px !important; }`;
// 添加主容器居中样式
cssRules += '.css-175oi2r.r-aqfbo4.r-gtdqiz.r-1gn8etr.r-1g40b8q { justify-content: center !important; }';
}
===
反正 AI 告诉我,这么搞就能让页面居中了.
博主,要不你再优化一下