A long-lived project that still receives updates
ViewComponents based on Flowbite Design System
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
 Dependencies

Development

Runtime

>= 1.0.0
>= 5.0.0
 Project Readme

Fluxbit ViewComponents

Gem Downloads (for latest version) GitHub License GitHub last commit Gem Downloads (for latest version) Gem Total Downloads GitHub forks

Fluxbit ViewComponents is an implementation of the Fluxbit Design System using ViewComponent.

Fluxbit ViewComponents

Preview

We have a Lookbook app online to show the documentation and all the Components available in action!

Just Click here!

Usage

Render Fluxbit ViewComponents:

<%= fx_card(title: "Title") do %>
  <p>Card example</p>
<% end %>

<!-- Breadcrumb navigation -->
<%= fx_breadcrumb do |c| %>
  <% c.with_item href: "/" do %>Home<% end %>
  <% c.with_item href: "/projects" do %>Projects<% end %>
  <% c.with_item current_page: true do %>Current Page<% end %>
<% end %>

<!-- Pagination controls -->
<%= fx_pagination(page: 1, last: 10, count: 100) %>

Dependencies

Installation

Add fluxbit_view_components to your Gemfile:

bundle add fluxbit_view_components

Run installer:

bin/rails fluxbit_view_components:install

Development

To get started:

  1. Run: bundle install
  2. Run: yarn install
  3. Run: bin/dev

It will open demo app with component previews on localhost:3000. You can change components and they will be updated on page reload. Component previews located in demo/test/components/previews.

Lookbook

To run tests:

rake

Releases

The library follows semantic versioning. To draft a new release you need to run bin/release with a new version number:

bin/release VERSION

Where the VERSION is the version number you want to release. This script will update the version in the gem and push it to GitHub and Rubygems automatically.

To release a new version of npm package update the package.json file with the new version number and run:

npm run release

After that make sure to commit changes in package.json.

Documentation

For more information, check out the following resources:

  • CODE_OF_CONDUCT.md: Guidelines for contributing to this project and fostering a welcoming community.
  • CONTRIBUTING.md: Instructions on how to contribute to the project, including setting up your environment and submitting changes.
  • PULL_REQUEST_TEMPLATE.md: Template for submitting pull requests to ensure consistency and quality.

License

The gem is available as open source under the terms of the MIT License.