Skip to content

feat: add config.dashboard_cards for custom overview dashboard cards#114

Merged
eclectic-coding merged 2 commits into
mainfrom
feat/custom-dashboard-cards
Jun 7, 2026
Merged

feat: add config.dashboard_cards for custom overview dashboard cards#114
eclectic-coding merged 2 commits into
mainfrom
feat/custom-dashboard-cards

Conversation

@eclectic-coding

Copy link
Copy Markdown
Owner

Summary

  • Add config.dashboard_cards — accepts an array of { title:, link:, stats: } hashes; each entry renders a custom card on the overview dashboard after the built-in Queue, Cache, and Cable cards
  • stats is an optional lambda returning a { label => value } hash, evaluated at render time — host apps can call their own models here
  • link is an optional { label:, url: } hash rendered as the card header link
  • Custom cards get a neutral grey top-border (sqw-gem-card--custom) so they're visually distinct from the built-in coloured cards
  • Defaults to [] — no visible change when unconfigured
  • Removes the completed v2.0 milestone section from ROADMAP (both Custom nav links and Custom dashboard cards are now shipped)

Usage

SolidStackWeb.configure do |config|
  config.dashboard_cards = [
    {
      title: "My App",
      link:  { label: "View Admin", url: "/admin" },
      stats: -> { { "Users" => User.count, "Premium" => User.premium.count } }
    }
  ]
end

Test plan

  • 415 examples, 0 failures, 100% line coverage (bundle exec rake)
  • Start dummy app and verify no extra cards with default config
  • Configure a card with stats lambda and verify it renders on the dashboard

🤖 Generated with Claude Code

eclectic-coding and others added 2 commits June 7, 2026 07:02
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…_cards

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@eclectic-coding eclectic-coding merged commit 5cb9981 into main Jun 7, 2026
5 checks passed
@eclectic-coding eclectic-coding deleted the feat/custom-dashboard-cards branch June 7, 2026 11:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant