simple_calendar 2.2.7 → 2.4.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +5 -5
- data/.github/FUNDING.yml +12 -0
- data/.github/workflows/ci.yml +43 -0
- data/Appraisals +11 -0
- data/CHANGELOG.md +22 -0
- data/Gemfile +3 -0
- data/README.md +68 -31
- data/Rakefile +1 -1
- data/app/views/simple_calendar/_calendar.html.erb +3 -3
- data/app/views/simple_calendar/_month_calendar.html.erb +3 -3
- data/app/views/simple_calendar/_week_calendar.html.erb +8 -8
- data/gemfiles/rails_6.gemfile +9 -0
- data/gemfiles/rails_6.gemfile.lock +195 -0
- data/gemfiles/rails_6_1.gemfile +9 -0
- data/gemfiles/rails_6_1.gemfile.lock +198 -0
- data/gemfiles/rails_master.gemfile +9 -0
- data/gemfiles/rails_master.gemfile.lock +207 -0
- data/lib/generators/simple_calendar/views_generator.rb +2 -2
- data/lib/simple_calendar/calendar.rb +61 -61
- data/lib/simple_calendar/month_calendar.rb +3 -6
- data/lib/simple_calendar/railtie.rb +3 -1
- data/lib/simple_calendar/version.rb +1 -1
- data/lib/simple_calendar/view_helpers.rb +6 -6
- data/lib/simple_calendar/week_calendar.rb +6 -8
- data/simple_calendar.gemspec +12 -13
- data/spec/calendar_spec.rb +84 -52
- data/spec/calendars/month_calendar_spec.rb +22 -4
- data/spec/simple_calendar_spec.rb +4 -4
- data/spec/spec_helper.rb +53 -53
- data/spec/support/fake_event.rb +9 -0
- data/spec/support/view_context.rb +20 -0
- data/spec/views_generators_spec.rb +3 -3
- metadata +21 -8
- data/.travis.yml +0 -4
    
        checksums.yaml
    CHANGED
    
    | @@ -1,7 +1,7 @@ | |
| 1 1 | 
             
            ---
         | 
| 2 | 
            -
             | 
| 3 | 
            -
              metadata.gz:  | 
| 4 | 
            -
              data.tar.gz:  | 
| 2 | 
            +
            SHA256:
         | 
| 3 | 
            +
              metadata.gz: e36ddb5bf4d84867961f50a904b50fbf62ce6f3b296504e2d1f9307c60371938
         | 
| 4 | 
            +
              data.tar.gz: f8c1c02a8f5f009950049035d26741104e2cd99d5edfee97f0270eb730670520
         | 
| 5 5 | 
             
            SHA512:
         | 
| 6 | 
            -
              metadata.gz:  | 
| 7 | 
            -
              data.tar.gz:  | 
| 6 | 
            +
              metadata.gz: 9b4bf518dae5f8cb63e83746e34eda30bbe460c2d7a9f5743e9fd7fd1ac822e8d1b7af43466ed7d29a1d41e57327c8a95c5b05b39af50ebfb5d40d8726373237
         | 
| 7 | 
            +
              data.tar.gz: dafcf5f2db9dd69202084a6233a2a3a0354f36565ba27f7551d38185ad8d50053dc6f5f4d12ee14fcda1e510ea9a68d202d40d073c4c2cd4f330c714a2477aa9
         | 
    
        data/.github/FUNDING.yml
    ADDED
    
    | @@ -0,0 +1,12 @@ | |
| 1 | 
            +
            # These are supported funding model platforms
         | 
| 2 | 
            +
             | 
| 3 | 
            +
            github: [excid3] # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
         | 
| 4 | 
            +
            patreon: # Replace with a single Patreon username
         | 
| 5 | 
            +
            open_collective: # Replace with a single Open Collective username
         | 
| 6 | 
            +
            ko_fi: # Replace with a single Ko-fi username
         | 
| 7 | 
            +
            tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
         | 
| 8 | 
            +
            community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
         | 
| 9 | 
            +
            liberapay: # Replace with a single Liberapay username
         | 
| 10 | 
            +
            issuehunt: # Replace with a single IssueHunt username
         | 
| 11 | 
            +
            otechie: # Replace with a single Otechie username
         | 
| 12 | 
            +
            custom: # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2']
         | 
| @@ -0,0 +1,43 @@ | |
| 1 | 
            +
            name: Tests
         | 
| 2 | 
            +
             | 
| 3 | 
            +
            on:
         | 
| 4 | 
            +
              pull_request:
         | 
| 5 | 
            +
                branches:
         | 
| 6 | 
            +
                  - '*'
         | 
| 7 | 
            +
              push:
         | 
| 8 | 
            +
                branches:
         | 
| 9 | 
            +
                  - master
         | 
| 10 | 
            +
            jobs:
         | 
| 11 | 
            +
              tests:
         | 
| 12 | 
            +
                runs-on: ubuntu-latest
         | 
| 13 | 
            +
                strategy:
         | 
| 14 | 
            +
                  matrix:
         | 
| 15 | 
            +
                    ruby: [ '2.6', '2.7', '3.0']
         | 
| 16 | 
            +
                    gemfile:
         | 
| 17 | 
            +
                      - rails_6
         | 
| 18 | 
            +
                      - rails_6_1
         | 
| 19 | 
            +
                      - rails_master
         | 
| 20 | 
            +
                env:
         | 
| 21 | 
            +
                  BUNDLE_GEMFILE: ${{ github.workspace }}/gemfiles/${{ matrix.gemfile }}.gemfile
         | 
| 22 | 
            +
                  BUNDLE_PATH_RELATIVE_TO_CWD: true
         | 
| 23 | 
            +
             | 
| 24 | 
            +
                steps:
         | 
| 25 | 
            +
                  - uses: actions/checkout@master
         | 
| 26 | 
            +
             | 
| 27 | 
            +
                  - name: Set up Ruby
         | 
| 28 | 
            +
                    uses: ruby/setup-ruby@v1
         | 
| 29 | 
            +
                    with:
         | 
| 30 | 
            +
                      ruby-version: ${{ matrix.ruby }}
         | 
| 31 | 
            +
                      bundler: default
         | 
| 32 | 
            +
                      bundler-cache: true
         | 
| 33 | 
            +
             | 
| 34 | 
            +
                  - name: StandardRb check
         | 
| 35 | 
            +
                    run: bundle exec standardrb
         | 
| 36 | 
            +
             | 
| 37 | 
            +
                  - name: Run tests
         | 
| 38 | 
            +
                    env:
         | 
| 39 | 
            +
                      DATABASE_URL: "sqlite3:noticed_test"
         | 
| 40 | 
            +
                      RAILS_ENV: test
         | 
| 41 | 
            +
                    run: |
         | 
| 42 | 
            +
                      bundle exec rails db:test:prepare
         | 
| 43 | 
            +
                      bundle exec rails test
         | 
    
        data/Appraisals
    ADDED
    
    
    
        data/CHANGELOG.md
    ADDED
    
    | @@ -0,0 +1,22 @@ | |
| 1 | 
            +
            ### 2.4.3
         | 
| 2 | 
            +
             | 
| 3 | 
            +
            * Fix deprecation warnings - @mbobin
         | 
| 4 | 
            +
             | 
| 5 | 
            +
            ### 2.4.2
         | 
| 6 | 
            +
             | 
| 7 | 
            +
            * Translation improvements - @fwolfst
         | 
| 8 | 
            +
             | 
| 9 | 
            +
            ### 2.4.1
         | 
| 10 | 
            +
             | 
| 11 | 
            +
            * [FIX] Use iso8601 format for start_date links in the header. Fixes any
         | 
| 12 | 
            +
              customization to the Rails default date format that might cause the
         | 
| 13 | 
            +
              parser to fail parsing that with `to_date`
         | 
| 14 | 
            +
             | 
| 15 | 
            +
            ### 2.4.0
         | 
| 16 | 
            +
             | 
| 17 | 
            +
            * [BREAKING] Fixes Rails 4.2 by changing `block` to `passed_block`. A
         | 
| 18 | 
            +
              security fix in Rails makes `block` a reserved local name that we can
         | 
| 19 | 
            +
              no longer use.
         | 
| 20 | 
            +
             | 
| 21 | 
            +
              **Upgrading**: If you've customized the simple_calendar views, rename
         | 
| 22 | 
            +
              `block` to `passed_block`. Without this, calendar dates will be empty.
         | 
    
        data/Gemfile
    CHANGED
    
    
    
        data/README.md
    CHANGED
    
    | @@ -1,16 +1,17 @@ | |
| 1 | 
            -
             | 
| 1 | 
            +
            # Simple Calendar
         | 
| 2 2 |  | 
| 3 | 
            -
             | 
| 4 | 
            -
            ===============
         | 
| 3 | 
            +
            ### 📆 A calendar for your Ruby on Rails app.
         | 
| 5 4 |  | 
| 6 | 
            -
             | 
| 7 | 
            -
             | 
| 5 | 
            +
            [](https://github.com/excid3/simple_calendar/actions) [](https://badge.fury.io/rb/simple_calendar)
         | 
| 6 | 
            +
             | 
| 7 | 
            +
            Simple Calendar is designed to do one thing really really well: render a calendar. 
         | 
| 8 | 
            +
             | 
| 9 | 
            +
            It lets you render a calendar of any size. Maybe you want a
         | 
| 8 10 | 
             
            day view, a 4 day agenda, a week view, a month view, or a 6 week
         | 
| 9 11 | 
             
            calendar. You can do all of that with the new gem, just give it a range
         | 
| 10 12 | 
             
            of dates to render.
         | 
| 11 13 |  | 
| 12 | 
            -
            It doesn't depend on any ORM so you're free to use it with ActiveRecord,
         | 
| 13 | 
            -
            Mongoid, any other ORM, or pure Ruby objects.
         | 
| 14 | 
            +
            It doesn't depend on any ORM so you're free to use it with ActiveRecord, Mongoid, any other ORM, or pure Ruby objects.
         | 
| 14 15 |  | 
| 15 16 | 
             
            Thanks to all contributors for your wonderful help!
         | 
| 16 17 |  | 
| @@ -21,9 +22,26 @@ Installation | |
| 21 22 |  | 
| 22 23 | 
             
            Just add this into your Gemfile followed by a bundle install:
         | 
| 23 24 | 
             
            ```ruby
         | 
| 24 | 
            -
            gem "simple_calendar", "~> 2. | 
| 25 | 
            +
            gem "simple_calendar", "~> 2.4"
         | 
| 25 26 | 
             
            ```
         | 
| 26 27 |  | 
| 28 | 
            +
            If you're using Bootstrap, the calendar should already have a border and
         | 
| 29 | 
            +
            nice spacing for days.
         | 
| 30 | 
            +
             | 
| 31 | 
            +
            Optionally, you can include the default stylesheet for the calendar in
         | 
| 32 | 
            +
            your `app/assets/stylesheets/application.css` file:
         | 
| 33 | 
            +
             | 
| 34 | 
            +
            ```scss
         | 
| 35 | 
            +
            *= require simple_calendar
         | 
| 36 | 
            +
            ```
         | 
| 37 | 
            +
             | 
| 38 | 
            +
            or in your SCSS `app/assets/stylesheets/application.scss` file:
         | 
| 39 | 
            +
             | 
| 40 | 
            +
            ```scss
         | 
| 41 | 
            +
            @import "simple_calendar";
         | 
| 42 | 
            +
            ```
         | 
| 43 | 
            +
             | 
| 44 | 
            +
             | 
| 27 45 | 
             
            Usage
         | 
| 28 46 | 
             
            -----
         | 
| 29 47 |  | 
| @@ -52,7 +70,7 @@ To show the day of the month instead of the date, use `<%= date.day %>` | |
| 52 70 | 
             
            You can generate a week calendar with the `week_calendar` method.
         | 
| 53 71 |  | 
| 54 72 | 
             
            ```erb
         | 
| 55 | 
            -
            <%= week_calendar | 
| 73 | 
            +
            <%= week_calendar(number_of_weeks: 2) do |date| %>
         | 
| 56 74 | 
             
              <%= date %>
         | 
| 57 75 | 
             
            <% end %>
         | 
| 58 76 | 
             
            ```
         | 
| @@ -64,7 +82,7 @@ Setting `number_of_weeks` is optional and defaults to 1. | |
| 64 82 | 
             
            You can generate calendars of any length by passing in the number of days you want to render.
         | 
| 65 83 |  | 
| 66 84 | 
             
            ```erb
         | 
| 67 | 
            -
            <%= calendar | 
| 85 | 
            +
            <%= calendar(number_of_days: 4) do |date| %>
         | 
| 68 86 | 
             
              <%= date %>
         | 
| 69 87 | 
             
            <% end %>
         | 
| 70 88 | 
             
            ```
         | 
| @@ -77,7 +95,7 @@ You can pass in `start_date_param` to change the name of the parameter | |
| 77 95 | 
             
            in the URL for the current calendar view.
         | 
| 78 96 |  | 
| 79 97 | 
             
            ```erb
         | 
| 80 | 
            -
            <%= calendar | 
| 98 | 
            +
            <%= calendar(start_date_param: :my_date) do |date| %>
         | 
| 81 99 | 
             
              <%= date %>
         | 
| 82 100 | 
             
            <% end %>
         | 
| 83 101 | 
             
            ```
         | 
| @@ -87,12 +105,37 @@ in the URL for the current calendar view. | |
| 87 105 | 
             
            You can set a different partial name for calendars by passing the partial path.
         | 
| 88 106 |  | 
| 89 107 | 
             
            ```erb
         | 
| 90 | 
            -
            <%= calendar | 
| 108 | 
            +
            <%= calendar(partial: 'products/calendar') do |date| %>
         | 
| 91 109 | 
             
              <%= date %>
         | 
| 92 110 | 
             
            <% end %>
         | 
| 93 111 | 
             
            ```
         | 
| 94 112 |  | 
| 95 | 
            -
             | 
| 113 | 
            +
            ### Internationalization (I18n)
         | 
| 114 | 
            +
             | 
| 115 | 
            +
            The default views are prepared to do translation lookups for month names and weekdays.
         | 
| 116 | 
            +
             | 
| 117 | 
            +
            To profit from that, you can take advantage of the [`rails-i18n`](https://github.com/svenfuchs/rails-i18n/) gem which comes with translations for many languages already.
         | 
| 118 | 
            +
             | 
| 119 | 
            +
            In a Rails 6 app, the configuration could look like the following:
         | 
| 120 | 
            +
             | 
| 121 | 
            +
              * Add `gem 'rails-i18n'` to your `Gemfile` and run `bundle`.
         | 
| 122 | 
            +
              * Define the available and default locale e.g. in `config/application.rb`:
         | 
| 123 | 
            +
            ```ruby  
         | 
| 124 | 
            +
            # config/application.rb
         | 
| 125 | 
            +
            config.i18n.available_locales = [:en, :de, :fr]
         | 
| 126 | 
            +
            config.i18n.default_locale = :en
         | 
| 127 | 
            +
            ```
         | 
| 128 | 
            +
              * Define the following translation keys:
         | 
| 129 | 
            +
            ```yaml
         | 
| 130 | 
            +
            # e.g. config/locales/de.yml
         | 
| 131 | 
            +
            de:
         | 
| 132 | 
            +
              simple_calendar:
         | 
| 133 | 
            +
                previous: "<<"
         | 
| 134 | 
            +
                next: ">>"
         | 
| 135 | 
            +
                week: Woche
         | 
| 136 | 
            +
            ```
         | 
| 137 | 
            +
                   
         | 
| 138 | 
            +
            See the [Rails I18n Guide](https://guides.rubyonrails.org/i18n.html) for further information.
         | 
| 96 139 |  | 
| 97 140 | 
             
            ## Rendering Events
         | 
| 98 141 |  | 
| @@ -112,7 +155,7 @@ $ rails g scaffold Meeting name start_time:datetime | |
| 112 155 | 
             
            $ rails g scaffold Meeting name start_time:datetime end_time:datetime
         | 
| 113 156 | 
             
            ```
         | 
| 114 157 |  | 
| 115 | 
            -
            By default it uses `start_time` as the attribute name. | 
| 158 | 
            +
            By default it uses `start_time` as the attribute name.
         | 
| 116 159 | 
             
            **If you'd like to use another attribute other than start_time, just
         | 
| 117 160 | 
             
            pass it in as the `attribute`**
         | 
| 118 161 |  | 
| @@ -152,7 +195,9 @@ We'll just load up all the meetings for this example. | |
| 152 195 |  | 
| 153 196 | 
             
            ```ruby
         | 
| 154 197 | 
             
            def index
         | 
| 155 | 
            -
               | 
| 198 | 
            +
              # Scope your query to the dates being shown:
         | 
| 199 | 
            +
              start_date = params.fetch(:start_date, Date.today).to_date
         | 
| 200 | 
            +
              @meetings = Meeting.where(starts_at: start_date.beginning_of_month.beginning_of_week..start_date.end_of_month.end_of_week)
         | 
| 156 201 | 
             
            end
         | 
| 157 202 | 
             
            ```
         | 
| 158 203 |  | 
| @@ -160,7 +205,7 @@ Then in your view, you can pass in the `events` option to render. The | |
| 160 205 | 
             
            meetings will automatically be filtered out by day for you.
         | 
| 161 206 |  | 
| 162 207 | 
             
            ```erb
         | 
| 163 | 
            -
            <%= month_calendar | 
| 208 | 
            +
            <%= month_calendar(events: @meetings) do |date, meetings| %>
         | 
| 164 209 | 
             
              <%= date %>
         | 
| 165 210 |  | 
| 166 211 | 
             
              <% meetings.each do |meeting| %>
         | 
| @@ -197,7 +242,7 @@ edit to your heart's desire. | |
| 197 242 | 
             
            Setting `Time.zone` will make sure the calendar start days are correctly computed
         | 
| 198 243 | 
             
            in the right timezone. You can set this globally in your `application.rb` file or
         | 
| 199 244 | 
             
            if you have a User model with a time_zone attribute, you can set it on every request by using
         | 
| 200 | 
            -
            a  | 
| 245 | 
            +
            a before_action like the following example.
         | 
| 201 246 |  | 
| 202 247 | 
             
            This code example uses [Devise](https://github.com/plataformatec/devise)'s
         | 
| 203 248 | 
             
            `current_user` and `user_signed_in?` methods to retrieve the user's timezone and set it for the duration of the request.
         | 
| @@ -206,7 +251,7 @@ using some other method of authentication. | |
| 206 251 |  | 
| 207 252 | 
             
            ```ruby
         | 
| 208 253 | 
             
            class ApplicationController < ActionController::Base
         | 
| 209 | 
            -
               | 
| 254 | 
            +
              before_action :set_time_zone, if: :user_signed_in?
         | 
| 210 255 |  | 
| 211 256 | 
             
              private
         | 
| 212 257 |  | 
| @@ -226,7 +271,7 @@ config.time_zone = 'Central Time (US & Canada)' | |
| 226 271 | 
             
            ### Beginning Of Week
         | 
| 227 272 |  | 
| 228 273 | 
             
            You can also change the beginning day of the week by setting
         | 
| 229 | 
            -
            `Date.beginning_of_week` in a ` | 
| 274 | 
            +
            `Date.beginning_of_week` in a `before_action` just like in the previous
         | 
| 230 275 | 
             
            example. If you want to set this globally, you can put this line in
         | 
| 231 276 | 
             
            `config/application.rb`:
         | 
| 232 277 |  | 
| @@ -234,18 +279,6 @@ example. If you want to set this globally, you can put this line in | |
| 234 279 | 
             
            config.beginning_of_week = :sunday
         | 
| 235 280 | 
             
            ```
         | 
| 236 281 |  | 
| 237 | 
            -
            ### Default Stylesheet
         | 
| 238 | 
            -
             | 
| 239 | 
            -
            If you're using Bootstrap, the calendar should already have a border and
         | 
| 240 | 
            -
            nice spacing for days.
         | 
| 241 | 
            -
             | 
| 242 | 
            -
            Optionally, you can include the default stylesheet for the calendar in
         | 
| 243 | 
            -
            your `app/assets/stylesheets/application.css` file:
         | 
| 244 | 
            -
             | 
| 245 | 
            -
            ```scss
         | 
| 246 | 
            -
            *= require simple_calendar
         | 
| 247 | 
            -
            ```
         | 
| 248 | 
            -
             | 
| 249 282 | 
             
            ### Custom CSS Classes
         | 
| 250 283 |  | 
| 251 284 | 
             
            Setting classes on the table and elements are pretty easy.
         | 
| @@ -387,6 +420,10 @@ Chris Oliver <chris@gorails.com> | |
| 387 420 |  | 
| 388 421 | 
             
            [@excid3](https://twitter.com/excid3)
         | 
| 389 422 |  | 
| 423 | 
            +
            ## License
         | 
| 424 | 
            +
             | 
| 425 | 
            +
            Simple Calendar is licensed under the [MIT License](LICENSE.txt).
         | 
| 426 | 
            +
             | 
| 390 427 | 
             
            ## Support
         | 
| 391 428 |  | 
| 392 429 | 
             
            Need help
         | 
    
        data/Rakefile
    CHANGED
    
    
| @@ -19,10 +19,10 @@ | |
| 19 19 | 
             
                    <%= content_tag :tr, class: calendar.tr_classes_for(week) do %>
         | 
| 20 20 | 
             
                      <% week.each do |day| %>
         | 
| 21 21 | 
             
                        <%= content_tag :td, class: calendar.td_classes_for(day) do %>
         | 
| 22 | 
            -
                          <% if defined?(Haml) && respond_to?(:block_is_haml?) && block_is_haml?( | 
| 23 | 
            -
                            <% capture_haml(day, sorted_events.fetch(day, []), & | 
| 22 | 
            +
                          <% if defined?(Haml) && respond_to?(:block_is_haml?) && block_is_haml?(passed_block) %>
         | 
| 23 | 
            +
                            <% capture_haml(day, sorted_events.fetch(day, []), &passed_block) %>
         | 
| 24 24 | 
             
                          <% else %>
         | 
| 25 | 
            -
                            <%  | 
| 25 | 
            +
                            <% passed_block.call day, sorted_events.fetch(day, []) %>
         | 
| 26 26 | 
             
                          <% end %>
         | 
| 27 27 | 
             
                        <% end %>
         | 
| 28 28 | 
             
                      <% end %>
         | 
| @@ -19,10 +19,10 @@ | |
| 19 19 | 
             
                    <tr>
         | 
| 20 20 | 
             
                      <% week.each do |day| %>
         | 
| 21 21 | 
             
                        <%= content_tag :td, class: calendar.td_classes_for(day) do %>
         | 
| 22 | 
            -
                          <% if defined?(Haml) && respond_to?(:block_is_haml?) && block_is_haml?( | 
| 23 | 
            -
                            <% capture_haml(day, sorted_events.fetch(day, []), & | 
| 22 | 
            +
                          <% if defined?(Haml) && respond_to?(:block_is_haml?) && block_is_haml?(passed_block) %>
         | 
| 23 | 
            +
                            <% capture_haml(day, sorted_events.fetch(day, []), &passed_block) %>
         | 
| 24 24 | 
             
                          <% else %>
         | 
| 25 | 
            -
                            <%  | 
| 25 | 
            +
                            <% passed_block.call day, sorted_events.fetch(day, []) %>
         | 
| 26 26 | 
             
                          <% end %>
         | 
| 27 27 | 
             
                        <% end %>
         | 
| 28 28 | 
             
                      <% end %>
         | 
| @@ -2,11 +2,11 @@ | |
| 2 2 | 
             
              <div class="calendar-heading">
         | 
| 3 3 | 
             
                <%= link_to t('simple_calendar.previous', default: 'Previous'), calendar.url_for_previous_view %>
         | 
| 4 4 | 
             
                <% if calendar.number_of_weeks == 1 %>
         | 
| 5 | 
            -
                  <span class="calendar-title" | 
| 6 | 
            -
                <%else%>
         | 
| 7 | 
            -
             | 
| 8 | 
            -
                <%end%>
         | 
| 9 | 
            -
             | 
| 5 | 
            +
                  <span class="calendar-title"><%= t('simple_calendar.week', default: 'Week') %> <%= calendar.week_number %></span>
         | 
| 6 | 
            +
                <% else %>
         | 
| 7 | 
            +
                  <span class="calendar-title"><%= t('simple_calendar.week', default: 'Week') %> <%= calendar.week_number %> - <%= calendar.end_week %></span>
         | 
| 8 | 
            +
                <% end %>
         | 
| 9 | 
            +
                <%= link_to t('simple_calendar.next', default: 'Next'), calendar.url_for_next_view %>
         | 
| 10 10 | 
             
              </div>
         | 
| 11 11 |  | 
| 12 12 | 
             
              <table class="table table-striped">
         | 
| @@ -23,10 +23,10 @@ | |
| 23 23 | 
             
                    <tr>
         | 
| 24 24 | 
             
                      <% week.each do |day| %>
         | 
| 25 25 | 
             
                        <%= content_tag :td, class: calendar.td_classes_for(day) do %>
         | 
| 26 | 
            -
                          <% if defined?(Haml) && respond_to?(:block_is_haml?) && block_is_haml?( | 
| 27 | 
            -
                            <% capture_haml(day, sorted_events.fetch(day, []), & | 
| 26 | 
            +
                          <% if defined?(Haml) && respond_to?(:block_is_haml?) && block_is_haml?(passed_block) %>
         | 
| 27 | 
            +
                            <% capture_haml(day, sorted_events.fetch(day, []), &passed_block) %>
         | 
| 28 28 | 
             
                          <% else %>
         | 
| 29 | 
            -
                            <%  | 
| 29 | 
            +
                            <% passed_block.call day, sorted_events.fetch(day, []) %>
         | 
| 30 30 | 
             
                          <% end %>
         | 
| 31 31 | 
             
                        <% end %>
         | 
| 32 32 | 
             
                      <% end %>
         | 
| @@ -0,0 +1,195 @@ | |
| 1 | 
            +
            PATH
         | 
| 2 | 
            +
              remote: ..
         | 
| 3 | 
            +
              specs:
         | 
| 4 | 
            +
                simple_calendar (2.4.3)
         | 
| 5 | 
            +
                  rails (>= 3.0)
         | 
| 6 | 
            +
             | 
| 7 | 
            +
            GEM
         | 
| 8 | 
            +
              remote: http://rubygems.org/
         | 
| 9 | 
            +
              specs:
         | 
| 10 | 
            +
                actioncable (6.0.3.7)
         | 
| 11 | 
            +
                  actionpack (= 6.0.3.7)
         | 
| 12 | 
            +
                  nio4r (~> 2.0)
         | 
| 13 | 
            +
                  websocket-driver (>= 0.6.1)
         | 
| 14 | 
            +
                actionmailbox (6.0.3.7)
         | 
| 15 | 
            +
                  actionpack (= 6.0.3.7)
         | 
| 16 | 
            +
                  activejob (= 6.0.3.7)
         | 
| 17 | 
            +
                  activerecord (= 6.0.3.7)
         | 
| 18 | 
            +
                  activestorage (= 6.0.3.7)
         | 
| 19 | 
            +
                  activesupport (= 6.0.3.7)
         | 
| 20 | 
            +
                  mail (>= 2.7.1)
         | 
| 21 | 
            +
                actionmailer (6.0.3.7)
         | 
| 22 | 
            +
                  actionpack (= 6.0.3.7)
         | 
| 23 | 
            +
                  actionview (= 6.0.3.7)
         | 
| 24 | 
            +
                  activejob (= 6.0.3.7)
         | 
| 25 | 
            +
                  mail (~> 2.5, >= 2.5.4)
         | 
| 26 | 
            +
                  rails-dom-testing (~> 2.0)
         | 
| 27 | 
            +
                actionpack (6.0.3.7)
         | 
| 28 | 
            +
                  actionview (= 6.0.3.7)
         | 
| 29 | 
            +
                  activesupport (= 6.0.3.7)
         | 
| 30 | 
            +
                  rack (~> 2.0, >= 2.0.8)
         | 
| 31 | 
            +
                  rack-test (>= 0.6.3)
         | 
| 32 | 
            +
                  rails-dom-testing (~> 2.0)
         | 
| 33 | 
            +
                  rails-html-sanitizer (~> 1.0, >= 1.2.0)
         | 
| 34 | 
            +
                actiontext (6.0.3.7)
         | 
| 35 | 
            +
                  actionpack (= 6.0.3.7)
         | 
| 36 | 
            +
                  activerecord (= 6.0.3.7)
         | 
| 37 | 
            +
                  activestorage (= 6.0.3.7)
         | 
| 38 | 
            +
                  activesupport (= 6.0.3.7)
         | 
| 39 | 
            +
                  nokogiri (>= 1.8.5)
         | 
| 40 | 
            +
                actionview (6.0.3.7)
         | 
| 41 | 
            +
                  activesupport (= 6.0.3.7)
         | 
| 42 | 
            +
                  builder (~> 3.1)
         | 
| 43 | 
            +
                  erubi (~> 1.4)
         | 
| 44 | 
            +
                  rails-dom-testing (~> 2.0)
         | 
| 45 | 
            +
                  rails-html-sanitizer (~> 1.1, >= 1.2.0)
         | 
| 46 | 
            +
                activejob (6.0.3.7)
         | 
| 47 | 
            +
                  activesupport (= 6.0.3.7)
         | 
| 48 | 
            +
                  globalid (>= 0.3.6)
         | 
| 49 | 
            +
                activemodel (6.0.3.7)
         | 
| 50 | 
            +
                  activesupport (= 6.0.3.7)
         | 
| 51 | 
            +
                activerecord (6.0.3.7)
         | 
| 52 | 
            +
                  activemodel (= 6.0.3.7)
         | 
| 53 | 
            +
                  activesupport (= 6.0.3.7)
         | 
| 54 | 
            +
                activestorage (6.0.3.7)
         | 
| 55 | 
            +
                  actionpack (= 6.0.3.7)
         | 
| 56 | 
            +
                  activejob (= 6.0.3.7)
         | 
| 57 | 
            +
                  activerecord (= 6.0.3.7)
         | 
| 58 | 
            +
                  marcel (~> 1.0.0)
         | 
| 59 | 
            +
                activesupport (6.0.3.7)
         | 
| 60 | 
            +
                  concurrent-ruby (~> 1.0, >= 1.0.2)
         | 
| 61 | 
            +
                  i18n (>= 0.7, < 2)
         | 
| 62 | 
            +
                  minitest (~> 5.1)
         | 
| 63 | 
            +
                  tzinfo (~> 1.1)
         | 
| 64 | 
            +
                  zeitwerk (~> 2.2, >= 2.2.2)
         | 
| 65 | 
            +
                appraisal (2.4.0)
         | 
| 66 | 
            +
                  bundler
         | 
| 67 | 
            +
                  rake
         | 
| 68 | 
            +
                  thor (>= 0.14.0)
         | 
| 69 | 
            +
                ast (2.4.2)
         | 
| 70 | 
            +
                builder (3.2.4)
         | 
| 71 | 
            +
                concurrent-ruby (1.1.8)
         | 
| 72 | 
            +
                crass (1.0.6)
         | 
| 73 | 
            +
                diff-lcs (1.4.4)
         | 
| 74 | 
            +
                erubi (1.10.0)
         | 
| 75 | 
            +
                globalid (0.4.2)
         | 
| 76 | 
            +
                  activesupport (>= 4.2.0)
         | 
| 77 | 
            +
                i18n (1.8.10)
         | 
| 78 | 
            +
                  concurrent-ruby (~> 1.0)
         | 
| 79 | 
            +
                loofah (2.9.1)
         | 
| 80 | 
            +
                  crass (~> 1.0.2)
         | 
| 81 | 
            +
                  nokogiri (>= 1.5.9)
         | 
| 82 | 
            +
                mail (2.7.1)
         | 
| 83 | 
            +
                  mini_mime (>= 0.1.1)
         | 
| 84 | 
            +
                marcel (1.0.1)
         | 
| 85 | 
            +
                method_source (1.0.0)
         | 
| 86 | 
            +
                mini_mime (1.1.0)
         | 
| 87 | 
            +
                mini_portile2 (2.5.1)
         | 
| 88 | 
            +
                minitest (5.14.4)
         | 
| 89 | 
            +
                nio4r (2.5.7)
         | 
| 90 | 
            +
                nokogiri (1.11.3)
         | 
| 91 | 
            +
                  mini_portile2 (~> 2.5.0)
         | 
| 92 | 
            +
                  racc (~> 1.4)
         | 
| 93 | 
            +
                nokogiri (1.11.3-x86_64-darwin)
         | 
| 94 | 
            +
                  racc (~> 1.4)
         | 
| 95 | 
            +
                nokogiri (1.11.3-x86_64-linux)
         | 
| 96 | 
            +
                  racc (~> 1.4)
         | 
| 97 | 
            +
                parallel (1.20.1)
         | 
| 98 | 
            +
                parser (3.0.1.1)
         | 
| 99 | 
            +
                  ast (~> 2.4.1)
         | 
| 100 | 
            +
                racc (1.5.2)
         | 
| 101 | 
            +
                rack (2.2.3)
         | 
| 102 | 
            +
                rack-test (1.1.0)
         | 
| 103 | 
            +
                  rack (>= 1.0, < 3)
         | 
| 104 | 
            +
                rails (6.0.3.7)
         | 
| 105 | 
            +
                  actioncable (= 6.0.3.7)
         | 
| 106 | 
            +
                  actionmailbox (= 6.0.3.7)
         | 
| 107 | 
            +
                  actionmailer (= 6.0.3.7)
         | 
| 108 | 
            +
                  actionpack (= 6.0.3.7)
         | 
| 109 | 
            +
                  actiontext (= 6.0.3.7)
         | 
| 110 | 
            +
                  actionview (= 6.0.3.7)
         | 
| 111 | 
            +
                  activejob (= 6.0.3.7)
         | 
| 112 | 
            +
                  activemodel (= 6.0.3.7)
         | 
| 113 | 
            +
                  activerecord (= 6.0.3.7)
         | 
| 114 | 
            +
                  activestorage (= 6.0.3.7)
         | 
| 115 | 
            +
                  activesupport (= 6.0.3.7)
         | 
| 116 | 
            +
                  bundler (>= 1.3.0)
         | 
| 117 | 
            +
                  railties (= 6.0.3.7)
         | 
| 118 | 
            +
                  sprockets-rails (>= 2.0.0)
         | 
| 119 | 
            +
                rails-dom-testing (2.0.3)
         | 
| 120 | 
            +
                  activesupport (>= 4.2.0)
         | 
| 121 | 
            +
                  nokogiri (>= 1.6)
         | 
| 122 | 
            +
                rails-html-sanitizer (1.3.0)
         | 
| 123 | 
            +
                  loofah (~> 2.3)
         | 
| 124 | 
            +
                railties (6.0.3.7)
         | 
| 125 | 
            +
                  actionpack (= 6.0.3.7)
         | 
| 126 | 
            +
                  activesupport (= 6.0.3.7)
         | 
| 127 | 
            +
                  method_source
         | 
| 128 | 
            +
                  rake (>= 0.8.7)
         | 
| 129 | 
            +
                  thor (>= 0.20.3, < 2.0)
         | 
| 130 | 
            +
                rainbow (3.0.0)
         | 
| 131 | 
            +
                rake (13.0.3)
         | 
| 132 | 
            +
                regexp_parser (2.1.1)
         | 
| 133 | 
            +
                rexml (3.2.5)
         | 
| 134 | 
            +
                rspec (3.10.0)
         | 
| 135 | 
            +
                  rspec-core (~> 3.10.0)
         | 
| 136 | 
            +
                  rspec-expectations (~> 3.10.0)
         | 
| 137 | 
            +
                  rspec-mocks (~> 3.10.0)
         | 
| 138 | 
            +
                rspec-core (3.10.1)
         | 
| 139 | 
            +
                  rspec-support (~> 3.10.0)
         | 
| 140 | 
            +
                rspec-expectations (3.10.1)
         | 
| 141 | 
            +
                  diff-lcs (>= 1.2.0, < 2.0)
         | 
| 142 | 
            +
                  rspec-support (~> 3.10.0)
         | 
| 143 | 
            +
                rspec-mocks (3.10.2)
         | 
| 144 | 
            +
                  diff-lcs (>= 1.2.0, < 2.0)
         | 
| 145 | 
            +
                  rspec-support (~> 3.10.0)
         | 
| 146 | 
            +
                rspec-support (3.10.2)
         | 
| 147 | 
            +
                rubocop (1.14.0)
         | 
| 148 | 
            +
                  parallel (~> 1.10)
         | 
| 149 | 
            +
                  parser (>= 3.0.0.0)
         | 
| 150 | 
            +
                  rainbow (>= 2.2.2, < 4.0)
         | 
| 151 | 
            +
                  regexp_parser (>= 1.8, < 3.0)
         | 
| 152 | 
            +
                  rexml
         | 
| 153 | 
            +
                  rubocop-ast (>= 1.5.0, < 2.0)
         | 
| 154 | 
            +
                  ruby-progressbar (~> 1.7)
         | 
| 155 | 
            +
                  unicode-display_width (>= 1.4.0, < 3.0)
         | 
| 156 | 
            +
                rubocop-ast (1.5.0)
         | 
| 157 | 
            +
                  parser (>= 3.0.1.1)
         | 
| 158 | 
            +
                rubocop-performance (1.11.2)
         | 
| 159 | 
            +
                  rubocop (>= 1.7.0, < 2.0)
         | 
| 160 | 
            +
                  rubocop-ast (>= 0.4.0)
         | 
| 161 | 
            +
                ruby-progressbar (1.11.0)
         | 
| 162 | 
            +
                sprockets (4.0.2)
         | 
| 163 | 
            +
                  concurrent-ruby (~> 1.0)
         | 
| 164 | 
            +
                  rack (> 1, < 3)
         | 
| 165 | 
            +
                sprockets-rails (3.2.2)
         | 
| 166 | 
            +
                  actionpack (>= 4.0)
         | 
| 167 | 
            +
                  activesupport (>= 4.0)
         | 
| 168 | 
            +
                  sprockets (>= 3.0.0)
         | 
| 169 | 
            +
                standard (1.1.1)
         | 
| 170 | 
            +
                  rubocop (= 1.14.0)
         | 
| 171 | 
            +
                  rubocop-performance (= 1.11.2)
         | 
| 172 | 
            +
                thor (1.1.0)
         | 
| 173 | 
            +
                thread_safe (0.3.6)
         | 
| 174 | 
            +
                tzinfo (1.2.9)
         | 
| 175 | 
            +
                  thread_safe (~> 0.1)
         | 
| 176 | 
            +
                unicode-display_width (2.0.0)
         | 
| 177 | 
            +
                websocket-driver (0.7.3)
         | 
| 178 | 
            +
                  websocket-extensions (>= 0.1.0)
         | 
| 179 | 
            +
                websocket-extensions (0.1.5)
         | 
| 180 | 
            +
                zeitwerk (2.4.2)
         | 
| 181 | 
            +
             | 
| 182 | 
            +
            PLATFORMS
         | 
| 183 | 
            +
              ruby
         | 
| 184 | 
            +
              x86_64-darwin-20
         | 
| 185 | 
            +
              x86_64-linux
         | 
| 186 | 
            +
             | 
| 187 | 
            +
            DEPENDENCIES
         | 
| 188 | 
            +
              appraisal
         | 
| 189 | 
            +
              rails (~> 6.0.0)
         | 
| 190 | 
            +
              rspec
         | 
| 191 | 
            +
              simple_calendar!
         | 
| 192 | 
            +
              standard
         | 
| 193 | 
            +
             | 
| 194 | 
            +
            BUNDLED WITH
         | 
| 195 | 
            +
               2.2.20
         |