[go: nahoru, domu]

Skip to content

Commit

Permalink
readme
Browse files Browse the repository at this point in the history
  • Loading branch information
tangly1024 committed Oct 18, 2023
1 parent ad45072 commit a84c719
Show file tree
Hide file tree
Showing 6 changed files with 17 additions and 22 deletions.
7 changes: 0 additions & 7 deletions next.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -90,13 +90,6 @@ module.exports = withBundleAnalyzer({
// 'react-dom': 'preact/compat'
// })
// }

// 排除所有后缀名为 .md 的文件的编译
config.module.rules.push({
test: /\.md$/,
use: 'raw-loader'
});

// 动态主题:添加 resolve.alias 配置,将动态路径映射到实际路径
config.resolve.alias['@theme-components'] = path.resolve(__dirname, 'themes', THEME)
return config
Expand Down
7 changes: 0 additions & 7 deletions themes/heo/README.md

This file was deleted.

2 changes: 1 addition & 1 deletion themes/heo/components/MenuListTop.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ export const MenuListTop = (props) => {

return (<>
<nav id='nav-mobile' className='leading-8 justify-center font-light w-full flex'>
{links?.map(link => link && link.show && <MenuItemDrop key={link?.id} link={link} />)}
{links?.map((link, index) => link && link.show && <MenuItemDrop key={index} link={link} />)}
</nav>
</>)
}
9 changes: 8 additions & 1 deletion themes/heo/index.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
import CONFIG from './config'
/**
* HEO 主题说明
* > 主题设计者 [张洪](https://zhheo.com/)
* > 主题开发者 [tangly1024](https://github.com/tangly1024)
* 1. 开启方式 在blog.config.js 将主题配置为 `HEO`
* 2. 更多说明参考此[文档](https://docs.tangly1024.com/article/notionnext-heo)
*/

import CONFIG from './config'
import CommonHead from '@/components/CommonHead'
import { useEffect, useState } from 'react'
import Footer from './components/Footer'
Expand Down
5 changes: 0 additions & 5 deletions themes/nav/README.md

This file was deleted.

9 changes: 8 additions & 1 deletion themes/nav/index.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
'use client'

/**
* # NAV 主题说明
* 主题开发者 [emengweb](https://github.com/emengweb)
* 开启方式 在blog.config.js 将主题配置为 `NAV`
*/

import CONFIG from './config'
import { useEffect, useState, createContext, useContext } from 'react'
import Footer from './components/Footer'
Expand Down Expand Up @@ -54,6 +60,7 @@ const LayoutBase = (props) => {

let links = customMenu

// 默认使用自定义菜单,否则将遍历所有的category生成菜单
if (!CONFIG.USE_CUSTOM_MENU) {
links = categoryOptions && categoryOptions?.map(c => {
return { id: c.name, title: `# ${c.name}`, to: `/category/${c.name}`, show: true }
Expand All @@ -79,7 +86,7 @@ const LayoutBase = (props) => {
{/* 左侧推拉抽屉 */}
<div className={'font-sans hidden md:block dark:border-transparent relative z-10 mx-4 w-52 max-h-full pb-44'}>

<div className='main-menu z-20 mt-20 pl-9 pr-7 pb-5 sticky pt-1 top-0 overflow-y-scroll h-fit max-h-full scroll-hidden bg-white dark:bg-neutral-800 rounded-xl '>
<div className='main-menu z-20 pl-9 pr-7 pb-5 sticky pt-1 top-20 overflow-y-scroll h-fit max-h-full scroll-hidden bg-white dark:bg-neutral-800 rounded-xl '>
{/* 嵌入 */}
{slotLeft}

Expand Down

0 comments on commit a84c719

Please sign in to comment.