meowpress 0.3.0-alpha.3 → 0.3.0-alpha.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +13 -4
- package/dist/src/build.d.ts +2 -2
- package/dist/src/fonts.js +1 -1
- package/dist/src/index.d.ts +1 -1
- package/dist/src/index.js +1 -1
- package/dist/src/site.js +130 -282
- package/dist/src/theme.d.ts +12 -43
- package/dist/src/theme.js +301 -2046
- package/package.json +10 -5
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Meowpress
|
|
2
2
|
|
|
3
|
-
Meowpress builds a static blog from Markdown and MDX, with a built-in theme for posts, short notes
|
|
3
|
+
Meowpress builds a static blog from Markdown and MDX, with a built-in Journal-based theme for posts, short notes
|
|
4
4
|
and public skills. A project can supply its own theme or page map through `meowpress/build`.
|
|
5
5
|
|
|
6
6
|
## Build and preview a site
|
|
@@ -119,13 +119,16 @@ each package's weight-axis `woff2` files into `fonts/` with a content hash, puts
|
|
|
119
119
|
rules first in the theme stylesheet with each subset's `unicode-range`, and copies each license to
|
|
120
120
|
`licenses/<name>-OFL.txt`. A browser fetches only the files a page's text and families use, and
|
|
121
121
|
nothing for a family the page does not use, so a site with a theme switch pays only for the active
|
|
122
|
-
theme. The
|
|
122
|
+
theme. The built-in blog theme defaults to `blogFonts`, which shares Journal’s font list:
|
|
123
|
+
Newsreader (normal and italic), Inter,
|
|
124
|
+
and JetBrains Mono. Any other theme defaults to no fonts; set `fonts` explicitly to provide them,
|
|
125
|
+
or set `fonts: []` to omit font assets.
|
|
123
126
|
Install the listed packages in the site; nothing depends on an external font service.
|
|
124
|
-
|
|
127
|
+
The default pages need no images. The `hero`, `feed` and `about` keys of `site.images`
|
|
125
128
|
can explicitly set decorative image paths, for example `images/cover.svg`; paths are relative to the content root's `assets/`, the library handles each page depth,
|
|
126
129
|
and assets are delivered along the existing asset build flow. When no About image is set, the first letter of the site name is used.
|
|
127
130
|
Font packages resolve from the project root first, then from this package, which carries the
|
|
128
|
-
default
|
|
131
|
+
three default font families.
|
|
129
132
|
|
|
130
133
|
## Independent verification
|
|
131
134
|
|
|
@@ -133,3 +136,9 @@ Once repository dependencies are ready, run `bun run --cwd packages/meowpress te
|
|
|
133
136
|
`bun run --cwd packages/meowpress typecheck`. Tests live in `tests/unit/`; real build tests create temporary content, themes and images through the public
|
|
134
137
|
`meowpress/build` entry,
|
|
135
138
|
covering Markdown, MDX, Thought output and draft page/asset exclusion, without reading Blog content or invoking the Blog build.
|
|
139
|
+
|
|
140
|
+
After `bun run build`, run `bun run --cwd packages/meowpress test:browser` for the Journal
|
|
141
|
+
browser regressions. The fixture server builds a temporary site through `meowpress/build` and
|
|
142
|
+
cleans it up on exit. The suite covers desktop and mobile widths in light and dark schemes,
|
|
143
|
+
repeated feed and skill-browser interactions, clipboard copy, deep 404 stylesheets, no-JavaScript
|
|
144
|
+
content, and wide-content containment. Screenshots are written to `packages/meowpress/test-results/`.
|
package/dist/src/build.d.ts
CHANGED
|
@@ -15,7 +15,7 @@ export interface SiteConfig {
|
|
|
15
15
|
skillsDirectory?: string;
|
|
16
16
|
/** Static output directory for the generated site. Defaults to `dist/`. */
|
|
17
17
|
outputDirectory?: string;
|
|
18
|
-
/** Defaults to
|
|
18
|
+
/** Defaults to the Journal-based Blog theme. */
|
|
19
19
|
theme?: ThemeDefinition;
|
|
20
20
|
/** Include project `.agents/skills/` in the public build. Defaults to false. */
|
|
21
21
|
includeProjectSkills?: boolean;
|
|
@@ -37,7 +37,7 @@ export interface SiteConfig {
|
|
|
37
37
|
/** Stylesheet file name for the theme; defaults to "blog-theme.css". */
|
|
38
38
|
themeStylesheet?: string;
|
|
39
39
|
/**
|
|
40
|
-
* Web fonts the theme names, published as separate files with their licenses. Defaults to
|
|
40
|
+
* Web fonts the theme names, published as separate files with their licenses. Defaults to Journal fonts
|
|
41
41
|
* for the default Blog theme and to none for any other theme.
|
|
42
42
|
*/
|
|
43
43
|
fonts?: readonly SiteFont[];
|
package/dist/src/fonts.js
CHANGED
|
@@ -7,7 +7,7 @@ export const FONT_DIRECTORY = "fonts";
|
|
|
7
7
|
export const FONT_EXTERNAL = `./${FONT_DIRECTORY}/*`;
|
|
8
8
|
/**
|
|
9
9
|
* Resolve a package file from the site first (where a host installs its theme's fonts), then from
|
|
10
|
-
* this package (which carries the default
|
|
10
|
+
* this package (which carries the default Journal fonts).
|
|
11
11
|
*/
|
|
12
12
|
function resolveFontFile(specifier) {
|
|
13
13
|
for (const from of [process.cwd(), dirname(fileURLToPath(import.meta.url))]) {
|
package/dist/src/index.d.ts
CHANGED
|
@@ -2,6 +2,6 @@ export { collectContentAssets, collectAssetFiles, isDraftAsset, loadSection, nor
|
|
|
2
2
|
export { buildSite, meowSite, type ResolvedSiteConfig, type SiteConfig } from "./build.js";
|
|
3
3
|
export { aboutPage, agentMarkdown, homePage, listPage, llmText, postPage, skillPage, skillsIndexPage, thoughtPage, } from "./site.js";
|
|
4
4
|
export { DEFAULT_SITE, type SiteAbout, type SiteIdentity, type SiteProfileLink } from "./identity.js";
|
|
5
|
-
export { blogFonts, blogTheme
|
|
5
|
+
export { blogFonts, blogTheme } from "./theme.js";
|
|
6
6
|
export type { SiteFont } from "./fonts.js";
|
|
7
7
|
export { loadSkills, type LoadSkillsOptions, type Skill, type SkillFile, type SkillScope, } from "./skills.js";
|
package/dist/src/index.js
CHANGED
|
@@ -2,5 +2,5 @@ export { collectContentAssets, collectAssetFiles, isDraftAsset, loadSection, nor
|
|
|
2
2
|
export { buildSite, meowSite } from "./build.js";
|
|
3
3
|
export { aboutPage, agentMarkdown, homePage, listPage, llmText, postPage, skillPage, skillsIndexPage, thoughtPage, } from "./site.js";
|
|
4
4
|
export { DEFAULT_SITE } from "./identity.js";
|
|
5
|
-
export { blogFonts, blogTheme
|
|
5
|
+
export { blogFonts, blogTheme } from "./theme.js";
|
|
6
6
|
export { loadSkills, } from "./skills.js";
|