Compare commits

..

No commits in common. "a572f8e70123aab0e9547cd0aa807968ef7260df" and "bf5aa870abb8ca748f38a4bcf1529d9a7f47176d" have entirely different histories.

9 changed files with 31 additions and 45 deletions

View File

@ -29,7 +29,6 @@ This part of the configuration concerns anything that can affect the whole site.
- `{ provider: 'plausible' }` (managed) or `{ provider: 'plausible', host: '<your-plausible-host>' }` (self-hosted): use [Plausible](https://plausible.io/);
- `{ provider: 'umami', host: '<your-umami-host>', websiteId: '<your-umami-website-id>' }`: use [Umami](https://umami.is/);
- `{ provider: 'goatcounter', websiteId: 'my-goatcounter-id' }` (managed) or `{ provider: 'goatcounter', websiteId: 'my-goatcounter-id', host: 'my-goatcounter-domain.com', scriptSrc: 'https://my-url.to/counter.js' }` (self-hosted) use [GoatCounter](https://goatcounter.com)
- `{ provider: 'posthog', apiKey: '<your-posthog-project-apiKey>', host: '<your-posthog-host>' }`: use [Posthog](https://posthog.com/);
- `locale`: used for [[i18n]] and date formatting
- `baseUrl`: this is used for sitemaps and RSS feeds that require an absolute URL to know where the canonical 'home' of your site lives. This is normally the deployed URL of your site (e.g. `quartz.jzhao.xyz` for this site). Do not include the protocol (i.e. `https://`) or any leading or trailing slashes.
- This should also include the subpath if you are [[hosting]] on GitHub pages without a custom domain. For example, if my repository is `jackyzha0/quartz`, GitHub pages would deploy to `https://jackyzha0.github.io/quartz` and the `baseUrl` would be `jackyzha0.github.io/quartz`.

View File

@ -8,7 +8,7 @@ This plugin emits a `CNAME` record that points your subdomain to the default dom
If you want to use a custom domain name like `quartz.example.com` for the site, then this is needed.
See [[hosting|Hosting]] for more information.
See [[Hosting]] for more information.
> [!note]
> For information on how to add, remove or configure plugins, see the [[configuration#Plugins|Configuration]] page.

24
package-lock.json generated
View File

@ -33,7 +33,7 @@
"mdast-util-to-string": "^4.0.0",
"micromorph": "^0.4.5",
"preact": "^10.20.1",
"preact-render-to-string": "^6.4.2",
"preact-render-to-string": "^6.4.0",
"pretty-bytes": "^6.1.1",
"pretty-time": "^1.1.0",
"reading-time": "^1.5.0",
@ -62,7 +62,7 @@
"unified": "^11.0.4",
"unist-util-visit": "^5.0.0",
"vfile": "^6.0.1",
"workerpool": "^9.1.1",
"workerpool": "^9.1.0",
"ws": "^8.15.1",
"yargs": "^17.7.2"
},
@ -74,7 +74,7 @@
"@types/d3": "^7.4.3",
"@types/hast": "^3.0.4",
"@types/js-yaml": "^4.0.9",
"@types/node": "^20.12.5",
"@types/node": "^20.11.29",
"@types/pretty-time": "^1.1.5",
"@types/source-map-support": "^0.5.10",
"@types/ws": "^8.5.10",
@ -1170,9 +1170,9 @@
}
},
"node_modules/@types/node": {
"version": "20.12.5",
"resolved": "https://registry.npmjs.org/@types/node/-/node-20.12.5.tgz",
"integrity": "sha512-BD+BjQ9LS/D8ST9p5uqBxghlN+S42iuNxjsUGjeZobe/ciXzk2qb1B6IXc6AnRLS+yFJRpN2IPEHMzwspfDJNw==",
"version": "20.11.29",
"resolved": "https://registry.npmjs.org/@types/node/-/node-20.11.29.tgz",
"integrity": "sha512-P99thMkD/1YkCvAtOd6/zGedKNA0p2fj4ZpjCzcNiSCBWgm3cNRTBfa/qjFnsKkkojxu4vVLtWpesnZ9+ap+gA==",
"dev": true,
"dependencies": {
"undici-types": "~5.26.4"
@ -4705,9 +4705,9 @@
}
},
"node_modules/preact-render-to-string": {
"version": "6.4.2",
"resolved": "https://registry.npmjs.org/preact-render-to-string/-/preact-render-to-string-6.4.2.tgz",
"integrity": "sha512-Sio5SvlyZSAXHuvnMgYzVQd67lNIuQe4uSjJ+2gfpJNC6L8zoHQR5xV7B/EjIqrAYWVyJ2eACkTCxVrIzZi6Vw==",
"version": "6.4.0",
"resolved": "https://registry.npmjs.org/preact-render-to-string/-/preact-render-to-string-6.4.0.tgz",
"integrity": "sha512-pzDwezZaLbK371OiJjXDsZJwVOALzFX5M1wEh2Kr0pEApq5AV6bRH/DFbA/zNA7Lck/duyREPQLLvzu2G6hEQQ==",
"dependencies": {
"pretty-format": "^3.8.0"
},
@ -6325,9 +6325,9 @@
"integrity": "sha512-Gd9+TUn5nXdwj/hFsPVx5cuHHiF5Bwuc30jZ4+ronF1qHK5O7HD0sgmXWSEgwKquT3ClLoKPVbO6qGwVwLzvAw=="
},
"node_modules/workerpool": {
"version": "9.1.1",
"resolved": "https://registry.npmjs.org/workerpool/-/workerpool-9.1.1.tgz",
"integrity": "sha512-EFoFTSEo9m4V4wNrwzVRjxnf/E/oBpOzcI/R5CIugJhl9RsCiq525rszo4AtqcjQQoqFdu2E3H82AnbtpaQHvg=="
"version": "9.1.0",
"resolved": "https://registry.npmjs.org/workerpool/-/workerpool-9.1.0.tgz",
"integrity": "sha512-+wRWfm9yyJghvXLSHMQj3WXDxHbibHAQmRrWbqKBfy0RjftZNeQaW+Std5bSYc83ydkrxoPTPOWVlXUR9RWJdQ=="
},
"node_modules/wrap-ansi": {
"version": "8.1.0",

View File

@ -12,7 +12,6 @@
"url": "https://github.com/jackyzha0/quartz.git"
},
"scripts": {
"quartz": "./quartz/bootstrap-cli.mjs",
"docs": "npx quartz build --serve -d docs",
"check": "tsc --noEmit && npx prettier . --check",
"format": "npx prettier . --write",
@ -59,7 +58,7 @@
"mdast-util-to-string": "^4.0.0",
"micromorph": "^0.4.5",
"preact": "^10.20.1",
"preact-render-to-string": "^6.4.2",
"preact-render-to-string": "^6.4.0",
"pretty-bytes": "^6.1.1",
"pretty-time": "^1.1.0",
"reading-time": "^1.5.0",
@ -88,7 +87,7 @@
"unified": "^11.0.4",
"unist-util-visit": "^5.0.0",
"vfile": "^6.0.1",
"workerpool": "^9.1.1",
"workerpool": "^9.1.0",
"ws": "^8.15.1",
"yargs": "^17.7.2"
},
@ -97,7 +96,7 @@
"@types/d3": "^7.4.3",
"@types/hast": "^3.0.4",
"@types/js-yaml": "^4.0.9",
"@types/node": "^20.12.5",
"@types/node": "^20.11.29",
"@types/pretty-time": "^1.1.5",
"@types/source-map-support": "^0.5.10",
"@types/ws": "^8.5.10",

View File

@ -15,7 +15,7 @@ const config: QuartzConfig = {
provider: "plausible",
},
locale: "en-US",
baseUrl: "jp.marchal.dev",
baseUrl: "jpg.marchal.dev",
ignorePatterns: ["private", "templates", ".obsidian"],
defaultDateType: "created",
theme: {

View File

@ -25,11 +25,6 @@ export type Analytics =
host?: string
scriptSrc?: string
}
| {
provider: "posthog"
apiKey: string
host?: string
}
export interface GlobalConfiguration {
pageTitle: string

View File

@ -69,7 +69,7 @@ export default {
folderContent: {
folder: "Arquivo",
itemsUnderFolder: ({ count }) =>
count === 1 ? "1 item neste arquivo." : `${count} items neste arquivo.`,
count === 1 ? "1 item mneste arquivo." : `${count} items neste arquivo.`,
},
tagContent: {
tag: "Tag",

View File

@ -129,13 +129,6 @@ function addGlobalPageResources(ctx: BuildCtx, componentResources: ComponentReso
"https://${cfg.analytics.websiteId}.${cfg.analytics.host ?? "goatcounter.com"}/count")
document.head.appendChild(goatcounterScript)
`)
} else if (cfg.analytics?.provider === "posthog") {
componentResources.afterDOMLoaded.push(`
const posthogScript = document.createElement("script")
posthogScript.innerHTML= \`!function(t,e){var o,n,p,r;e.__SV||(window.posthog=e,e._i=[],e.init=function(i,s,a){function g(t,e){var o=e.split(".");2==o.length&&(t=t[o[0]],e=o[1]),t[e]=function(){t.push([e].concat(Array.prototype.slice.call(arguments,0)))}}(p=t.createElement("script")).type="text/javascript",p.async=!0,p.src=s.api_host+"/static/array.js",(r=t.getElementsByTagName("script")[0]).parentNode.insertBefore(p,r);var u=e;for(void 0!==a?u=e[a]=[]:a="posthog",u.people=u.people||[],u.toString=function(t){var e="posthog";return"posthog"!==a&&(e+="."+a),t||(e+=" (stub)"),e},u.people.toString=function(){return u.toString(1)+".people (stub)"},o="capture identify alias people.set people.set_once set_config register register_once unregister opt_out_capturing has_opted_out_capturing opt_in_capturing reset isFeatureEnabled onFeatureFlags getFeatureFlag getFeatureFlagPayload reloadFeatureFlags group updateEarlyAccessFeatureEnrollment getEarlyAccessFeatures getActiveMatchingSurveys getSurveys onSessionId".split(" "),n=0;n<o.length;n++)g(u,o[n]);e._i.push([i,s,a])},e.__SV=1)}(document,window.posthog||[]);
posthog.init('${cfg.analytics.apiKey}',{api_host:'${cfg.analytics.host ?? "https://app.posthog.com"}'})\`
document.head.appendChild(posthogScript)
`)
}
if (cfg.enableSPA) {

View File

@ -143,19 +143,6 @@ footer {
margin-top: 0.5rem;
}
.usage .p {
margin:0;
}
.usage .box {
border: 1px solid var(--darkgray);
border-radius: 0.5rem;
padding: 0.2rem 0.3rem 0.2rem 0.3rem;
display: inline-block;
width: fit-content;
margin: 0.2rem;
}
.usage .left {
padding-right: 1.7rem;
@ -168,6 +155,19 @@ footer {
border-width: 0 2px;
}
.usage .left .box {
border: 1px solid var(--darkgray);
border-radius: 0.5rem;
padding: 0.2rem 0.3rem 0.2rem 0.3rem;
display: inline-block;
width: fit-content;
margin: 0.2rem;
}
.usage .left p {
margin:0;
}
.usage .right {
padding-left: 1rem;
}