test(fuc-xb): theme-scroll-header-128 acceptance\n

This commit is contained in:
hellcat committed 2026-11-05 16:20:36 +08:00
1 parent 824d0f4167
commit b91e4b82e2
5 files changed
+24 -5

No files matched your search

+1 -1
View File
@@ -6,7 +6,7 @@ import {copyText} from './clipboard.mjs?v=0.12.6';
import {createCaptcha} from './captcha.mjs?v=0.12.6';
import {showPayment,mountCard} from './payments.mjs?v=0.12.6';
import {beginPageProgress,finishPageProgress} from './progress.mjs?v=0.12.6';
import {nativeReady,prepareNativeMode,nativeMode,fillPurchaseModal,nativeHeader,nativeFooter,nativeDashboard,nativeHome,nativeAuth,nativeSecondary,paintNativeChart,paintNativeHome} from './native.mjs?v=0.12.7';
import {nativeReady,prepareNativeMode,nativeMode,fillPurchaseModal,nativeHeader,nativeFooter,nativeDashboard,nativeHome,nativeAuth,nativeSecondary,paintNativeChart,paintNativeHome} from './native.mjs?v=0.12.8';
import {escape as e, money, bytes, date, list, groupedList, periods, orderStates, soldOut, safeUrl, createApi, routeFromHash,canPurchase} from './core.mjs?v=0.12.6';
const settings = window.fucSettings || {};
const root = document.querySelector('#app');
+2 -2
View File
@@ -15,7 +15,7 @@ export async function prepareNativeMode(mode,page='') {
const palette=getPalette(),signature=key+':'+palette;
if(currentMode===signature)return;
const seq=++styleSequence;
const overrides=[['native-dark','theme/cool/assets/css/theme/dark-layout.css'],['native-bridge','bridge.css?v=0.12.6']].map(([id,path])=>{
const overrides=[['native-dark','theme/cool/assets/css/theme/dark-layout.css'],['native-bridge','bridge.css?v=0.12.8']].map(([id,path])=>{
let n=document.getElementById(id);if(n)return n;
n=document.createElement('link');n.id=id;n.rel='stylesheet';n.href=base+path;n.media='not all';
n.ready=new Promise((resolve,reject)=>{n.onload=resolve;n.onerror=()=>{n.remove();reject(Error('原版样式加载失败'));};});document.head.append(n);return n;
@@ -48,7 +48,7 @@ export function nativeMode(mode, page='') {
if((mode!=='user'||key!=='dashboard')&&chartInstance){try{chartInstance.destroy();}catch{}chartInstance=null;}
if(currentMode!==key+':'+getPalette())void prepareNativeMode(mode,page);
let dark=document.getElementById('native-dark');if(!dark){dark=document.createElement('link');dark.id='native-dark';dark.rel='stylesheet';dark.href=base+'theme/cool/assets/css/theme/dark-layout.css';document.head.append(dark);}dark.disabled=mode!=='user'||document.documentElement.dataset.color!=='dark';
let bridge=document.getElementById('native-bridge');if(!bridge){bridge=document.createElement('link');bridge.id='native-bridge';bridge.rel='stylesheet';bridge.href=base+'bridge.css?v=0.12.6';document.head.append(bridge);}
let bridge=document.getElementById('native-bridge');if(!bridge){bridge=document.createElement('link');bridge.id='native-bridge';bridge.rel='stylesheet';bridge.href=base+'bridge.css?v=0.12.8';document.head.append(bridge);}
document.body.className=mode==='home'?'native-public':mode==='auth'?'vertical-layout vertical-menu-modern 1-column navbar-floating footer-static bg-full-screen-image blank-page':`vertical-layout ${innerWidth>=1200?'vertical-menu-modern menu-expanded':'vertical-overlay-menu'} navbar-floating footer-static ${document.documentElement.dataset.color==='dark'?'dark-layout':''}`;
if(mode==='user'&&innerWidth>=1200&&localStorage.getItem('fuc_menuToggle')==='close'){document.body.classList.remove('menu-expanded');document.body.classList.add('menu-collapsed');}document.body.dataset.nativeMode=mode;document.body.dataset.menu=innerWidth>=1200?'vertical-menu-modern':'vertical-overlay-menu';document.body.classList.add(window.Pace?.running?'pace-running':'pace-done');syncNativeMenu(document);
}
+19
View File
@@ -15,3 +15,22 @@ body[data-native-mode=user] .page-wrapper{transition:300ms ease all}
/* Tabler's small negative spacing maps to a much larger Cool utility. Keep
document metadata on its own line within the approved usable legacy layout. */
body[data-native-mode=user][data-native-page=knowledge] .list-group-item .mt-n1{margin-top:0!important}
/* Keep the top bar in the page flow with the original desktop and mobile widths. */
body[data-native-mode=user] .header-navbar.floating-nav {
position: relative;
right: auto;
margin-left: auto;
}
body[data-native-mode=user] .header-navbar-shadow {
display: none;
}
html body[data-native-mode=user] .content.app-content .content-wrapper {
margin-top: 0;
}
body[data-native-mode=user] .page-wrapper {
padding-top: 1.1rem;
}
+1 -1
View File
@@ -1,7 +1,7 @@
{
"name": "Fuc",
"description": "直接复用新版FUC原始用户模板、样式、图标及素材,接入XB接口;XB管理员后台保持原样。",
"version": "0.12.7",
"version": "0.12.8",
"images": "",
"configs": [
{
+1 -1
View File
@@ -10,7 +10,7 @@
<body>
<div id="app"></div>
<script>window.fucSettings = @json(['title' => ($theme_config['brand_name'] ?? '') ?: $title, 'description' => $theme_config['tagline'] ?? $description]);</script>
<script type="module" src="/theme/{{ $theme }}/assets/app.mjs?v=0.12.7"></script>
<script type="module" src="/theme/{{ $theme }}/assets/app.mjs?v=0.12.8"></script>
</body>
</html>