vault sync 2024-01-02 16:37:45

This commit is contained in:
Peaceultime 2024-01-02 16:37:46 +01:00
parent 6ef41c3508
commit a7fc44db8c
7 changed files with 0 additions and 235 deletions

View File

@ -1,73 +0,0 @@
import { QuartzConfig } from "./quartz/cfg"
import * as Plugin from "./quartz/plugins"
const config: QuartzConfig = {
configuration: {
pageTitle: "Prototype Aspect",
enableSPA: false,
enablePopovers: true,
analytics: null,
baseUrl: "static.peaceultime.com/obsidian",
ignorePatterns: ["private", "templates", ".obsidian"],
defaultDateType: "created",
theme: {
typography: {
header: "Schibsted Grotesk",
body: "Source Sans Pro",
code: "IBM Plex Mono",
},
colors: {
lightMode: {
light: "#faf8f8",
lightgray: "#e5e5e5",
gray: "#b8b8b8",
darkgray: "#4e4e4e",
dark: "#2b2b2b",
secondary: "#284b63",
tertiary: "#84a59d",
highlight: "rgba(143, 159, 169, 0.15)",
},
darkMode: {
light: "#161618",
lightgray: "#393639",
gray: "#646464",
darkgray: "#d4d4d4",
dark: "#ebebec",
secondary: "#7b97aa",
tertiary: "#84a59d",
highlight: "rgba(143, 159, 169, 0.15)",
},
},
},
},
plugins: {
transformers: [
Plugin.FrontMatter(),
Plugin.TableOfContents(),
Plugin.CreatedModifiedDate({
priority: ["frontmatter", "filesystem"], // you can add 'git' here for last modified from Git but this makes the build slower
}),
Plugin.SyntaxHighlighting(),
Plugin.Comments(),
Plugin.ObsidianFlavoredMarkdown({ enableInHtmlEmbed: false }),
Plugin.GitHubFlavoredMarkdown(),
Plugin.CrawlLinks({ markdownLinkResolution: "absolute" }),
Plugin.Latex({ renderEngine: "katex" }),
Plugin.Description(),
],
filters: [Plugin.RemoveDrafts()],
emitters: [
Plugin.AliasRedirects(),
Plugin.ComponentResources({ fontOrigin: "googleFonts" }),
Plugin.ContentPage(),
Plugin.FolderPage(),
Plugin.TagPage(),
Plugin.ContentIndex(),
Plugin.Assets(),
Plugin.Static(),
Plugin.NotFoundPage(),
],
},
}
export default config

View File

@ -1,44 +0,0 @@
import { PageLayout, SharedLayout } from "./quartz/cfg"
import * as Component from "./quartz/components"
// components shared across all pages
export const sharedPageComponents: SharedLayout = {
head: Component.Head(),
header: [],
footer: Component.Footer({
links: null,
}),
}
// components for pages that display a single page (e.g. a single note)
export const defaultContentPageLayout: PageLayout = {
beforeBody: [
Component.Breadcrumbs(),
Component.ArticleTitle(),
Component.ContentMeta(),
],
left: [
Component.PageTitle(),
Component.MobileOnly(Component.Spacer()),
Component.Search(),
Component.Darkmode(),
Component.DesktopOnly(Component.Explorer()),
],
right: [
Component.Graph(),
Component.DesktopOnly(Component.TableOfContents()),
Component.Backlinks(),
],
}
// components for pages that display lists of pages (e.g. tags or folders)
export const defaultListPageLayout: PageLayout = {
beforeBody: [Component.ArticleTitle()],
left: [
Component.PageTitle(),
Component.MobileOnly(Component.Spacer()),
Component.Search(),
Component.Darkmode(),
],
right: [],
}

View File

@ -1,45 +0,0 @@
import { QuartzTransformerPlugin } from "../types"
import { Root } from "mdast"
import { Element, Root as HtmlRoot } from "hast"
import { ReplaceFunction, findAndReplace as mdastFindReplace } from "mdast-util-find-and-replace"
import { PluggableList } from "unified"
const commentRegex = /%%(.+?)%%/gs
export const Comments: QuartzTransformerPlugin<undefined> = () => {
return {
name: "Comments",
markdownPlugins() {
const plugins: PluggableList = []
// regex replacements
plugins.push(() => {
return (tree: Root) => {
const replacements: [RegExp, string | ReplaceFunction][] = []
replacements.push([
commentRegex,
(_value: string, ..._capture: string[]) => {
const [inner] = _capture
return {
type: "html",
value: `<span class="text-comment">${inner}</span>`,
}
},
])
mdastFindReplace(tree, replacements)
}
})
return plugins
},
}
}
declare module "vfile" {
interface DataMap {
blocks: Record<string, Element>
htmlAst: HtmlRoot
}
}

View File

@ -1,12 +0,0 @@
export { FrontMatter } from "./frontmatter"
export { Comments } from "./comments"
export { GitHubFlavoredMarkdown } from "./gfm"
export { CreatedModifiedDate } from "./lastmod"
export { Latex } from "./latex"
export { Description } from "./description"
export { CrawlLinks } from "./links"
export { ObsidianFlavoredMarkdown } from "./ofm"
export { OxHugoFlavouredMarkdown } from "./oxhugofm"
export { SyntaxHighlighting } from "./syntax"
export { TableOfContents } from "./toc"
export { HardLineBreaks } from "./linebreaks"

View File

@ -1,8 +0,0 @@
@use "./base.scss";
// put your custom CSS here!
.text-comment
{
color: gray;
font-size: 0.8em;
}

View File

@ -1,52 +0,0 @@
name: Build Quartz site
on:
push:
branches:
- master
permissions:
contents: read
pages: write
id-token: write
jobs:
build:
runs-on: ubuntu-22.04
steps:
- name: "Fetching Quartz"
uses: actions/checkout@v3
with:
repository: 'jackyzha0/quartz'
path: 'quartz'
github-server-url: 'https://github.com'
token: ${{ secrets.GH_PAT }}
- name: "Checkout"
uses: actions/checkout@v3
with:
path: 'quartz/content'
fetch-depth: 0 # Fetch all history for git info
- name: "Install Node"
uses: actions/setup-node@v3
with:
node-version: 18.14
- name: Install Dependencies
run: npm ci
working-directory: ./quartz
- name: Copying config
run: cp -r content/.github/quartz/* .
working-directory: ./quartz
- name: Build Quartz
run: npx quartz build
working-directory: ./quartz
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: output
path: ./quartz/public

View File

@ -1 +0,0 @@
Testing the homepage