$ show bionic-gpt/daisy-rsx
This repository is a Rust workspace that provides two main libraries: `daisy_rsx`, a collection of reusable UI components for the Dioxus framework styled with DaisyUI, and `ssg_whiz`, a static site generation framework that renders Dioxus components to HTML, processes markdown with syntax highlighting, and supports blog, documentation, and marketing layouts. The workspace also includes an example site that demonstrates the full pipeline from content to deployed static output. The code is well-structured with enums for styling, SSR rendering, and a build pipeline that includes image resizing and diagram generation. While `daisy_rsx` components are standalone and readily reusable across projects, `ssg_whiz` is more opinionated and tightly integrated into the workspace, limiting reuse without additional decoupling.
The LLM identified 2 files worth highlighting for reuse:
A Dioxus component that renders user or team avatars using either an image URL or SVG fallbacks with deterministic background colors derived from the first letter of the name. It applies a hash of the character to select from an array of DaisyUI theme color pairs, avoiding external dependencies. The component handles size variants, type distinction (user vs. team), and degrades gracefully. This module is self-contained (only depends on Dioxus) and can be extracted into any Dioxus project with minimal changes.
A pure function `markdown_to_html` that converts Markdown to HTML with syntax highlighting for fenced code blocks. It uses `pulldown-cmark` for parsing (tables, footnotes, strikethrough, tasklists) and `syntect` with the base16-ocean.dark theme for code blocks. The function is entirely self-contained, with lazy-loaded syntax sets and theme, and no internal dependencies on the rest of the workspace. It can be extracted and reused in any Rust project requiring Markdown rendering with highlighted code blocks.