Add the auto-generated node catalog to the website's user manual (#3662)

* Generate the MVP node catalog in the manual (with some placeholders)

* Implement nearly the rest of everything

* Move to the tools directory and make it generate nicer default values

* Add category descriptions

* Organize file structure and improve type naming

* Improve book table of contents code

* Add collapsing chapter navigation to the book template

* Add to build workflow

* Clean up site structure
This commit is contained in:
Keavon Chambers
2026-01-20 22:52:03 -08:00
committed by GitHub
parent 5543afd44b
commit 7af60e02a3
61 changed files with 1131 additions and 384 deletions

View File

@@ -21,7 +21,7 @@ pub fn detect_file_type(path: &Path) -> Result<FileType, String> {
Some("svg") => Ok(FileType::Svg),
Some("png") => Ok(FileType::Png),
Some("jpg" | "jpeg") => Ok(FileType::Jpg),
_ => Err(format!("Unsupported file extension. Supported formats: .svg, .png, .jpg")),
_ => Err("Unsupported file extension. Supported formats: .svg, .png, .jpg".to_string()),
}
}
@@ -31,8 +31,7 @@ pub async fn export_document(
output_path: PathBuf,
file_type: FileType,
scale: f64,
width: Option<u32>,
height: Option<u32>,
(width, height): (Option<u32>, Option<u32>),
transparent: bool,
) -> Result<(), Box<dyn Error>> {
// Determine export format based on file type
@@ -42,10 +41,12 @@ pub async fn export_document(
};
// Create render config with export settings
let mut render_config = RenderConfig::default();
render_config.export_format = export_format;
render_config.for_export = true;
render_config.scale = scale;
let mut render_config = RenderConfig {
scale,
export_format,
for_export: true,
..Default::default()
};
// Set viewport dimensions if specified
if let (Some(w), Some(h)) = (width, height) {