Extract vendored dioxus-primitives components into their own crate
All checks were successful
CI / check (pull_request) Successful in 15m54s
CI / test (pull_request) Successful in 10m5s
CI / audit (pull_request) Successful in 27s

crates/web/src/components/ was a byte-for-byte copy of the
DioxusLabs/components "preview" registry (a shadcn-style copy-into-
your-project source, not something published as a dependency). Move it
wholesale into a new feedsignal-dioxus-components crate so it reads as
vendored code we depend on rather than application source, and future
app-specific styling should layer on via the class/attributes props
each component already accepts instead of editing the vendored files.

No component logic changed — this is a pure move plus import-path
updates in the four app files that consumed it.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
Austin Schaefer 2026-09-15 11:31:27 +02:00
parent b50b7e61cb
commit 3dcf404b26
37 changed files with 40 additions and 11 deletions

11
Cargo.lock generated
View file

@ -1603,6 +1603,15 @@ dependencies = [
"uuid", "uuid",
] ]
[[package]]
name = "feedsignal-dioxus-components"
version = "0.1.0"
dependencies = [
"dioxus",
"dioxus-icons",
"dioxus-primitives",
]
[[package]] [[package]]
name = "feedsignal-feeds" name = "feedsignal-feeds"
version = "0.1.0" version = "0.1.0"
@ -1633,10 +1642,10 @@ dependencies = [
"anyhow", "anyhow",
"chrono", "chrono",
"dioxus", "dioxus",
"dioxus-icons",
"dioxus-primitives", "dioxus-primitives",
"feedsignal-core", "feedsignal-core",
"feedsignal-db", "feedsignal-db",
"feedsignal-dioxus-components",
"feedsignal-feeds", "feedsignal-feeds",
"feedsignal-llm", "feedsignal-llm",
"serde", "serde",

View file

@ -3,6 +3,7 @@ resolver = "2"
members = [ members = [
"crates/core", "crates/core",
"crates/db", "crates/db",
"crates/dioxus-components",
"crates/feeds", "crates/feeds",
"crates/llm", "crates/llm",
"crates/web", "crates/web",
@ -31,5 +32,6 @@ libsqlite3-sys = { version = "0.30", features = ["bundled"] }
feedsignal-core = { path = "crates/core" } feedsignal-core = { path = "crates/core" }
feedsignal-db = { path = "crates/db" } feedsignal-db = { path = "crates/db" }
feedsignal-dioxus-components = { path = "crates/dioxus-components" }
feedsignal-feeds = { path = "crates/feeds" } feedsignal-feeds = { path = "crates/feeds" }
feedsignal-llm = { path = "crates/llm" } feedsignal-llm = { path = "crates/llm" }

View file

@ -0,0 +1,10 @@
[package]
name = "feedsignal-dioxus-components"
version.workspace = true
edition.workspace = true
license.workspace = true
[dependencies]
dioxus = "0.7"
dioxus-primitives = { git = "https://github.com/DioxusLabs/components", version = "0.0.1", default-features = false }
dioxus-icons = { version = "0.1.0", default-features = false }

View file

@ -0,0 +1,9 @@
// Vendored copies of the dioxus-primitives component registry
// (https://github.com/DioxusLabs/components, preview/src/components).
// That registry is a "copy this source into your project" style
// collection, not a published crate — so these files are pulled in
// verbatim rather than depended on directly. Don't edit component
// internals for app-specific needs; layer overrides on via the `class`/
// `attributes` props each component already accepts.
mod components;
pub use components::*;

View file

@ -24,7 +24,7 @@ chrono = { workspace = true, optional = true }
serde_json = { workspace = true, optional = true } serde_json = { workspace = true, optional = true }
tokio-cron-scheduler = { version = "0.13", optional = true } tokio-cron-scheduler = { version = "0.13", optional = true }
dioxus-primitives = { git = "https://github.com/DioxusLabs/components", version = "0.0.1", default-features = false } dioxus-primitives = { git = "https://github.com/DioxusLabs/components", version = "0.0.1", default-features = false }
dioxus-icons = { version = "0.1.0", default-features = false } feedsignal-dioxus-components.workspace = true
[features] [features]
default = ["web"] default = ["web"]

View file

@ -1,9 +1,9 @@
use super::handlers::score_percent; use super::handlers::score_percent;
use crate::api; use crate::api;
use crate::api::ArticleView; use crate::api::ArticleView;
use crate::components::badge::{Badge, BadgeVariant};
use crate::components::button::{Button, ButtonSize, ButtonVariant};
use dioxus::prelude::*; use dioxus::prelude::*;
use feedsignal_dioxus_components::badge::{Badge, BadgeVariant};
use feedsignal_dioxus_components::button::{Button, ButtonSize, ButtonVariant};
#[component] #[component]
pub fn ArticleRow(article: ArticleView) -> Element { pub fn ArticleRow(article: ArticleView) -> Element {

View file

@ -3,13 +3,13 @@ mod handlers;
mod subscribe_form; mod subscribe_form;
use crate::api; use crate::api;
use crate::components::scroll_area::ScrollArea; use article_row::ArticleRow;
use crate::components::sidebar::{ use dioxus::prelude::*;
use feedsignal_dioxus_components::scroll_area::ScrollArea;
use feedsignal_dioxus_components::sidebar::{
Sidebar, SidebarContent, SidebarGroup, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, Sidebar, SidebarContent, SidebarGroup, SidebarGroupContent, SidebarGroupLabel, SidebarHeader,
SidebarInset, SidebarMenu, SidebarMenuButton, SidebarMenuItem, SidebarProvider, SidebarTrigger, SidebarInset, SidebarMenu, SidebarMenuButton, SidebarMenuItem, SidebarProvider, SidebarTrigger,
}; };
use article_row::ArticleRow;
use dioxus::prelude::*;
use subscribe_form::SubscribeForm; use subscribe_form::SubscribeForm;
#[component] #[component]

View file

@ -1,8 +1,8 @@
use super::handlers::{normalize_feed_url, resolve_submit_outcome, SubmitOutcome}; use super::handlers::{normalize_feed_url, resolve_submit_outcome, SubmitOutcome};
use crate::api; use crate::api;
use crate::components::button::{Button, ButtonVariant};
use crate::components::input::Input;
use dioxus::prelude::*; use dioxus::prelude::*;
use feedsignal_dioxus_components::button::{Button, ButtonVariant};
use feedsignal_dioxus_components::input::Input;
/// Form for manually subscribing to a feed by URL. Fetches the feed /// Form for manually subscribing to a feed by URL. Fetches the feed
/// immediately on submit (rather than waiting for the next scheduled poll) /// immediately on submit (rather than waiting for the next scheduled poll)

View file

@ -1,6 +1,5 @@
mod api; mod api;
mod app; mod app;
mod components;
#[cfg(feature = "server")] #[cfg(feature = "server")]
mod server; mod server;