커밋메시지 적기도 귀찮다
This commit is contained in:
+1
-1
@@ -17,7 +17,7 @@ const config: QuartzConfig = {
|
|||||||
},
|
},
|
||||||
locale: "en-US",
|
locale: "en-US",
|
||||||
baseUrl: "kui-white-smith.duckdns.org",
|
baseUrl: "kui-white-smith.duckdns.org",
|
||||||
ignorePatterns: ["private", "templates", ".obsidian", "template","extra"],
|
ignorePatterns: ["private", "templates", ".obsidian", "00.Extra", "99.Template"],
|
||||||
defaultDateType: "modified",
|
defaultDateType: "modified",
|
||||||
theme: {
|
theme: {
|
||||||
fontOrigin: "googleFonts",
|
fontOrigin: "googleFonts",
|
||||||
|
|||||||
+26
-12
@@ -40,17 +40,24 @@ export const defaultContentPageLayout: PageLayout = {
|
|||||||
}),
|
}),
|
||||||
Component.Explorer({
|
Component.Explorer({
|
||||||
filterFn: (node) => {
|
filterFn: (node) => {
|
||||||
// 1. 탐색기에서 아예 빼버릴 단어들 (대소문자 무관)
|
// 1. 숨기고 싶은 키워드 (index.md의 title에 적은 것과 폴더명 모두 포함)
|
||||||
const omitWords = ["extra", "template", "note", "volume"]
|
const omitWords = ["extra", "template", "note", "volume"]
|
||||||
|
|
||||||
// 파일(페이지)은 필터링하지 않고 보여줍니다.
|
// 파일(페이지)은 기본적으로 보여줍니다.
|
||||||
if (node.file) return true
|
if (node.file) return true
|
||||||
|
|
||||||
// 폴더 이름이 존재하면 소문자로 변환
|
// 2. node가 가진 다양한 이름 속성들을 싹 다 긁어모읍니다.
|
||||||
const folderName = node.name?.toLowerCase() ?? ""
|
const namesToCheck = [
|
||||||
|
node.name,
|
||||||
|
node.displayName,
|
||||||
|
node.file?.frontmatter?.title // index.md가 있다면 그 안의 title까지
|
||||||
|
]
|
||||||
|
|
||||||
// 2. 폴더 이름에 omitWords 중 하나라도 포함되어 있으면 숨깁니다 (false 반환)
|
// 3. 하나라도 omitWords에 포함되어 있는지 확인합니다.
|
||||||
const shouldOmit = omitWords.some(word => folderName.includes(word))
|
const shouldOmit = namesToCheck.some(name => {
|
||||||
|
const lowerName = name?.toLowerCase() ?? ""
|
||||||
|
return omitWords.some(word => lowerName.includes(word))
|
||||||
|
})
|
||||||
|
|
||||||
return !shouldOmit
|
return !shouldOmit
|
||||||
},
|
},
|
||||||
@@ -80,17 +87,24 @@ export const defaultListPageLayout: PageLayout = {
|
|||||||
}),
|
}),
|
||||||
Component.Explorer({
|
Component.Explorer({
|
||||||
filterFn: (node) => {
|
filterFn: (node) => {
|
||||||
// 1. 탐색기에서 아예 빼버릴 단어들 (대소문자 무관)
|
// 1. 숨기고 싶은 키워드 (index.md의 title에 적은 것과 폴더명 모두 포함)
|
||||||
const omitWords = ["extra", "template", "note", "volume"]
|
const omitWords = ["extra", "template", "note", "volume"]
|
||||||
|
|
||||||
// 파일(페이지)은 필터링하지 않고 보여줍니다.
|
// 파일(페이지)은 기본적으로 보여줍니다.
|
||||||
if (node.file) return true
|
if (node.file) return true
|
||||||
|
|
||||||
// 폴더 이름이 존재하면 소문자로 변환
|
// 2. node가 가진 다양한 이름 속성들을 싹 다 긁어모읍니다.
|
||||||
const folderName = node.name?.toLowerCase() ?? ""
|
const namesToCheck = [
|
||||||
|
node.name,
|
||||||
|
node.displayName,
|
||||||
|
node.file?.frontmatter?.title // index.md가 있다면 그 안의 title까지
|
||||||
|
]
|
||||||
|
|
||||||
// 2. 폴더 이름에 omitWords 중 하나라도 포함되어 있으면 숨깁니다 (false 반환)
|
// 3. 하나라도 omitWords에 포함되어 있는지 확인합니다.
|
||||||
const shouldOmit = omitWords.some(word => folderName.includes(word))
|
const shouldOmit = namesToCheck.some(name => {
|
||||||
|
const lowerName = name?.toLowerCase() ?? ""
|
||||||
|
return omitWords.some(word => lowerName.includes(word))
|
||||||
|
})
|
||||||
|
|
||||||
return !shouldOmit
|
return !shouldOmit
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user