No release in over a year
Provides a timeline_molecules_tag helper to draw a vertical time line usable with vanilla CSS.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies
 Project Readme

TimelineRailsHelper

Ruby Gem Version Ruby Style Guide CircleCI

The TimelineRailsHelper provides a timeline_molecules_tag helper to draw a vertical time line usable with vanilla CSS.

See It Work

TimeLineRailsHelper

Installation

Prerequisites

  • Ruby >= 2.6

Stacks

Add this line to your application's Gemfile:

gem "timeline_rails_helper"

And then execute:

$ bundle

Or install it yourself as:

$ gem install timeline_rails_helper

Usage

QQTW (Quickest Quick-start in The West)

<div id="time_line_rails_helper">
<%= timeline_molecules_tag [{title: (DateTime.now - 3.days).strftime('%Y-%m-%d'),
body: 'This is a test'},
{title: DateTime.now.strftime('%Y-%m-%d'),
body: 'This is a test'}] %>
</div>
  1. Append the following line to your app/assets/application.scss:
@import 'timeline_rails_helper'
  1. And then append the line to your view file like below:
timeline_molecules_tag [{title: (DateTime.now - 3.days).strftime('%Y-%m-%d'),
                         body: 'This is a test'},
                        {title: DateTime.now.strftime('%Y-%m-%d'),
                         body: 'This is a test'}]

#   =>   "<div class="entries">
#           <div class="entry">
#             <div class="title ">2022-04-13</div>
#             <div class="body">This is a test</div>
#           </div>
#           <div class="entry">
#             <div class="title ">2022-04-16</div>
#             <div class="body">This is a test</div>
#           </div>
#         </div>"

Development

Test

bin/test

Changelog

TimelineRailsHelper's changelog is available here.

Contributing

Bug reports and pull requests are welcome on Github at https://github.com/smapira/timeline_rails_helper. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the code of conduct. License

License

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

Code of Conduct

Everyone interacting in the timeline_rails_helper project's codebases, issue trackers, chat rooms and mailing lists is expected to follow the code of conduct.

You may enjoy owning other libraries and my company.

Acknowledgments