Sha256: d7294f15a8b843757391fe75a152be7bf6772eb878f857be6f912bb50e80b59e

Contents?: true

Size: 862 Bytes

Versions: 58

Compression:

Stored size: 862 Bytes

Contents

- date = params[:start_date].presence.try(:to_date) || Date.current

.effective__simple-calendar
  .calendar-heading.d-flex.justify-content-between.align-items-center
    .calendar-arrow
      = link_to t('simple_calendar.previous', default: 'Previous').html_safe, effective_events.events_path(start_date: date - 1.month)

    %span.calendar-title
      = t('date.month_names')[start_date.month]

    .calendar-arrow
      = link_to t('simple_calendar.next', default: 'Next').html_safe, effective_events.events_path(start_date: date + 1.month)

  %table.table.table-sm
    %thead
      %tr
        - date_range.slice(0, 7).each do |day|
          %th= t('date.abbr_day_names')[day.wday]

    %tbody
      - date_range.each_slice(7) do |week|
        %tr
          - week.each do |day|
            = capture_haml(day, sorted_events.fetch(day, []), &passed_block)

Version data entries

58 entries across 58 versions & 1 rubygems

Version Path
effective_events-0.13.1 app/views/simple_calendar/_month_calendar.html.haml
effective_events-0.13.0 app/views/simple_calendar/_month_calendar.html.haml
effective_events-0.11.3 app/views/simple_calendar/_month_calendar.html.haml
effective_events-0.11.2 app/views/simple_calendar/_month_calendar.html.haml
effective_events-0.11.1 app/views/simple_calendar/_month_calendar.html.haml
effective_events-0.11.0 app/views/simple_calendar/_month_calendar.html.haml
effective_events-0.10.2 app/views/simple_calendar/_month_calendar.html.haml
effective_events-0.10.1 app/views/simple_calendar/_month_calendar.html.haml
effective_events-0.10.0 app/views/simple_calendar/_month_calendar.html.haml
effective_events-0.9.3 app/views/simple_calendar/_month_calendar.html.haml
effective_events-0.9.2 app/views/simple_calendar/_month_calendar.html.haml
effective_events-0.9.1 app/views/simple_calendar/_month_calendar.html.haml
effective_events-0.9.0 app/views/simple_calendar/_month_calendar.html.haml
effective_events-0.8.0 app/views/simple_calendar/_month_calendar.html.haml
effective_events-0.7.4 app/views/simple_calendar/_month_calendar.html.haml
effective_events-0.7.3 app/views/simple_calendar/_month_calendar.html.haml
effective_events-0.7.2 app/views/simple_calendar/_month_calendar.html.haml
effective_events-0.7.1 app/views/simple_calendar/_month_calendar.html.haml