mirror of
https://github.com/d0zingcat/NotionNext.git
synced 2026-05-14 07:26:52 +00:00
fukasawa 主题微调
This commit is contained in:
@@ -70,8 +70,8 @@ function AsideLeft(props) {
|
||||
}
|
||||
}, [isCollapsed])
|
||||
|
||||
const isReverse = siteConfig('LAYOUT_SIDEBAR_REVERSE')
|
||||
const position = useMemo(() => {
|
||||
const isReverse = JSON.parse(siteConfig('LAYOUT_SIDEBAR_REVERSE'))
|
||||
if (isCollapsed) {
|
||||
if (isReverse) {
|
||||
return 'right-2'
|
||||
|
||||
@@ -7,9 +7,11 @@ export const MenuItemDrop = ({ link }) => {
|
||||
|
||||
return (
|
||||
<li
|
||||
onMouseOver={() => changeShow(true)}
|
||||
onMouseOver={() => {
|
||||
changeShow(true)
|
||||
}}
|
||||
onMouseOut={() => changeShow(false)}
|
||||
className='relative py-1 duration-500 justify-between text-gray-500 dark:text-gray-300 hover:text-black hover:underline cursor-pointer flex flex-nowrap items-center '>
|
||||
className='relative py-1 mb-1.5 duration-500 justify-between text-gray-500 dark:text-gray-300 hover:text-black hover:underline cursor-pointer flex flex-nowrap items-center '>
|
||||
{!hasSubMenu && (
|
||||
<Link
|
||||
href={link?.href}
|
||||
@@ -33,7 +35,7 @@ export const MenuItemDrop = ({ link }) => {
|
||||
{hasSubMenu && (
|
||||
<div className='text-right'>
|
||||
<i
|
||||
className={`px-2 fas fa-chevron-right duration-500 transition-all ${show ? ' rotate-180' : ''}`}></i>
|
||||
className={`px-2 fas fa-chevron-left duration-500 transition-all ${show ? ' rotate-180' : ''}`}></i>
|
||||
</div>
|
||||
)}
|
||||
</div>
|
||||
@@ -42,7 +44,7 @@ export const MenuItemDrop = ({ link }) => {
|
||||
{/* 子菜单 */}
|
||||
{hasSubMenu && (
|
||||
<ul
|
||||
className={`${show ? 'visible opacity-100 left-52' : 'invisible opacity-0 left-40'} z-20 py-1 absolute right-0 top-0 w-full border-gray-100 bg-white dark:bg-black dark:border-gray-800 transition-all duration-300 drop-shadow-lg `}>
|
||||
className={`${show ? 'visible opacity-100 left-72' : 'invisible opacity-0 left-80'} z-20 p-2 absolute right-0 top-0 w-full border-gray-100 bg-white dark:bg-black dark:border-gray-800 transition-all duration-300 drop-shadow-lg `}>
|
||||
{link?.subMenus?.map((sLink, index) => {
|
||||
return (
|
||||
<li key={index}>
|
||||
|
||||
@@ -28,11 +28,6 @@ export const MenuList = props => {
|
||||
name: locale.NAV.ARCHIVE,
|
||||
href: '/archive',
|
||||
show: siteConfig('FUKASAWA_MENU_ARCHIVE', null, CONFIG)
|
||||
},
|
||||
{
|
||||
name: locale.NAV.SEARCH,
|
||||
href: '/search',
|
||||
show: siteConfig('FUKASAWA_MENU_SEARCH', null, CONFIG)
|
||||
}
|
||||
]
|
||||
|
||||
|
||||
@@ -10,11 +10,9 @@ const CONFIG = {
|
||||
FUKASAWA_MENU_CATEGORY: true, // 显示分类
|
||||
FUKASAWA_MENU_TAG: true, // 显示标签
|
||||
FUKASAWA_MENU_ARCHIVE: true, // 显示归档
|
||||
FUKASAWA_MENU_SEARCH: false, // 显示搜索
|
||||
|
||||
FUKASAWA_SIDEBAR_COLLAPSE_BUTTON: true, // 侧边栏折叠按钮
|
||||
FUKASAWA_SIDEBAR_COLLAPSE_SATUS_DEFAULT: false, // 侧边栏默认折叠收起
|
||||
FUKASAWA_SIDEBAR_COLLAPSE_ON_SCROLL: false // 侧边栏滚动时折叠 仅文章阅读页有效
|
||||
|
||||
}
|
||||
export default CONFIG
|
||||
|
||||
Reference in New Issue
Block a user