-
Notifications
You must be signed in to change notification settings - Fork 198
Add example markdown files for collections #4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like a great start. Some comments but nothing major. Would be good to get some more inline documentation but I am fine with that being a follow-up. Thanks for getting this started!
src/content/sketches/example.mdx
Outdated
| src="https://openprocessing.org/sketch/2160959/embed/" | ||
| width="400" | ||
| height="400" | ||
| ></iframe> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we want the iframe in the body or do we just want to have those attributes in the frontmatter? I don't feel strongly but it might be useful to encourage uniformity in these. Maybe the body is an the title and license and optional description?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeah i think that's a good idea to standardize. i'll move the params for the iframe to the frontmatter and the license can be too. thanks!
| relatedExamples: z.array(z.string()).optional(), | ||
| // related_examples: z.array(reference("examples")).optional(), | ||
| relatedReferences: z.array(z.string()).optional(), | ||
| // related_references: z.array(reference("reference")).optional(), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Neat!
|
Also wanted to note that I didn't do a detailed cross-comparison with the wireframes. I suspect that more properties will emerge as the final designs are delivered. |
* Installed astro mermaid * Fixed title for mermaid by adding jsx line to print title above diagram * Trying to split single line title into three lines hoping github will understand them * This is my third attempt, trying to use a html solution without font size but rather h4<small>, because git doesnt recognize font size either * Try #4, adding a space between title and mermaid text * Revert "Installed astro mermaid" This reverts commit e32991e. * Installed astro mermaid * Removed html fix for title, and use mermaid's class chart built in title support * Removed Html Line from Main branch (unneeded for current install) * Revert "Merge branch 'main' into hien" This reverts commit 1b67d8f, reversing changes made to 4b9274c. * installed astro mermaid * removed some typo * removed some typo * The MDX file includes two Mermaid diagrams—one for light mode and one for dark—because Mermaid diagrams are rendered at build time and can’t switch themes dynamically. Each version is wrapped in its own container using a html script, and CSS rules in global.scss hide or show the appropriate diagram depending on whether the .dark-theme class is active. This ensures users always see a diagram that matches their current theme * Dark Diagram deleted and diagram set to default options * Deleted css options for the dark mode diagram * Undid unnecessary changes to these 2 files * Trying to remove changes on web_gl file * added invert filter for darkmode diagrams --------- Co-authored-by: Hien-Ly <[email protected]> Co-authored-by: Jaime Serrano Acevedo <[email protected]>
* Installed astro mermaid * Fixed title for mermaid by adding jsx line to print title above diagram * Trying to split single line title into three lines hoping github will understand them * This is my third attempt, trying to use a html solution without font size but rather h4<small>, because git doesnt recognize font size either * Try #4, adding a space between title and mermaid text * Revert "Installed astro mermaid" This reverts commit e32991e. * Installed astro mermaid * Removed html fix for title, and use mermaid's class chart built in title support * Removed Html Line from Main branch (unneeded for current install) * Revert "Merge branch 'main' into hien" This reverts commit 1b67d8f, reversing changes made to 4b9274c. * installed astro mermaid * removed some typo * removed some typo * The MDX file includes two Mermaid diagrams—one for light mode and one for dark—because Mermaid diagrams are rendered at build time and can’t switch themes dynamically. Each version is wrapped in its own container using a html script, and CSS rules in global.scss hide or show the appropriate diagram depending on whether the .dark-theme class is active. This ensures users always see a diagram that matches their current theme * Dark Diagram deleted and diagram set to default options * Deleted css options for the dark mode diagram * Undid unnecessary changes to these 2 files * Trying to remove changes on web_gl file * added invert filter for darkmode diagrams --------- Co-authored-by: Hien-Ly <[email protected]> Co-authored-by: Jaime Serrano Acevedo <[email protected]>
Adds the following content collections, along with schemas, one example entry, and very basic unstyled pages for:
/tutorials/[slug]//people//past-events/[slug]//sketches/[slug]//libraries/Other Details
I chose to make the Libraries and People collections "data" collections instead of "content" collections because there aren't individual pages for either of them and if they were MDX files the body would always be empty.
I added some shared zod types for common fields between collection schemas.
This does not address i18n at all, and we'll have to move these example entries into nested language folders when we implement i18n.
These schemas do not include fields for tags, though those are easy to add later if we want to.