= provide(:title, "Settings")

.row
  .col-sm-offset-3.col-sm-6

    h2 Settings

    .well
      = gravatar_for(current_user, size: 48)
      p = link_to "Update picture", "http://gravatar.com/emails"
      p = render 'shared/social_connect'

    = simple_form_for(resource, as: resource_name, url: registration_path(resource_name), html: { method: :put }) do |f|
      = f.error_notification
      .form-inputs
        = f.input :email, required: true, autofocus: true
        - if devise_mapping.confirmable? && resource.pending_reconfirmation?
          p
            | Currently waiting confirmation for:
            = resource.unconfirmed_email

        -# If user do not have a password, it means this user is
        -# registered with a social account. So password is irrelevant.
        - if current_user.password.present?
          = f.input :password, autocomplete: "off", hint: "leave it blank if you don't want to change it", required: false
          = f.input :password_confirmation, required: false
          = f.input :current_password, hint: "we need your current password to confirm your changes", required: true
      .form-group
        = f.button :submit, "Update"

    hr

    h3
      | Cancel my account
    p
      | Unhappy?
      = link_to "Cancel my account", registration_path(resource_name), data: { confirm: "Are you sure?" }, method: :delete
    = link_to "Back", :back

Remove password fields from settings form

= provide(:title, "Settings")

.row
  .col-sm-offset-3.col-sm-6

    h2 Settings

    .well
      = gravatar_for(current_user, size: 48)
      p = link_to "Update picture", "http://gravatar.com/emails"
      p = render 'shared/social_connect'

    = simple_form_for(resource, as: resource_name, url: registration_path(resource_name), html: { method: :put }) do |f|
      = f.error_notification
      .form-inputs
        = f.input :email, required: true, autofocus: true
        - if devise_mapping.confirmable? && resource.pending_reconfirmation?
          p
            | Currently waiting confirmation for:
            = resource.unconfirmed_email

      .form-group
        = f.button :submit, "Update"

    hr

    h3
      | Cancel my account
    p
      | Unhappy?
      = link_to "Cancel my account", registration_path(resource_name), data: { confirm: "Are you sure?" }, method: :delete
    = link_to "Back", :back


header
  h1
    = link_to 'Rails Girls Summer of Code', root_path

  nav.top
    ul
      /li = link_to 'Apply now',    apply_path
      li = link_to 'Activity',     root_path,  class: params[:controller] == 'activities' ? 'active' : ''
      li = link_to 'Teams',        teams_path, class: params[:controller] == 'teams' ? 'active' : ''
      li = link_to 'Participants', users_path, class: params[:controller] == 'users' ? 'active' : ''
      li = link_to 'Conferences',  conferences_path,  class: params[:controller] == 'conferences' ? 'active' : ''
      li = link_to 'Help',         page_path('help'), class: params[:page] == 'help' ? 'active' : ''
      - if signed_in? && current_user.roles.includes?('reviewer')
        li = link_to 'Applications', applications_path
      li = link_to 'Home →'.html_safe, 'http://railsgirlssummerofcode.org'

  nav.user
    - if signed_in?
      = "Signed in as #{link_to h(current_user.name), current_user} · ".html_safe
      = link_to "Sign out", sign_out_path, method: :delete
    - else
      = link_to icon('github', 'Sign in with GitHub'), user_omniauth_authorize_path(:github)

Add job offers to main nav

header
  h1
    = link_to 'Rails Girls Summer of Code', root_path

  nav.top
    ul
      /li = link_to 'Apply now',    apply_path
      li = link_to 'Activity',     root_path,  class: params[:controller] == 'activities' ? 'active' : ''
      li = link_to 'Teams',        teams_path, class: params[:controller] == 'teams' ? 'active' : ''
      li = link_to 'Participants', users_path, class: params[:controller] == 'users' ? 'active' : ''
      li = link_to 'Conferences',  conferences_path,  class: params[:controller] == 'conferences' ? 'active' : ''
      li = link_to 'Jobs',   job_offers_path,   class: params[:controller] == 'job_offers' ? 'active' : ''
      li = link_to 'Help',         page_path('help'), class: params[:page] == 'help' ? 'active' : ''
      - if signed_in? && current_user.roles.includes?('reviewer')
        li = link_to 'Applications', applications_path
      li = link_to 'Home →'.html_safe, 'http://railsgirlssummerofcode.org'

  nav.user
    - if signed_in?
      = "Signed in as #{link_to h(current_user.name), current_user} · ".html_safe
      = link_to "Sign out", sign_out_path, method: :delete
    - else
      = link_to icon('github', 'Sign in with GitHub'), user_omniauth_authorize_path(:github)


= f.button :submit, value: t(".save"), data: { disable_with: t(".save_disable_with") }
|
= f.button :submit,
          as: :ssdsdsd,
           name: "signoff",
           value: t(".signoff"),
           data: { disable_with: t(".signoff_disable_with") }
- if policy(session).destroy?
  |
  = link_to("Delete", patient_hd_session_path(patient, session),
            data: { confirm: t(".delete_confirmation") },
            method: :delete,
            class: "button alert")
|
span= " or "
= link_to "cancel", back_path

Make the HD Session Save button grey

= f.button :submit,
            value: t(".save"),
            data: { disable_with: t(".save_disable_with") },
            class: "button secondary"
|
= f.button :submit,
          as: :ssdsdsd,
           name: "signoff",
           value: t(".signoff"),
           data: { disable_with: t(".signoff_disable_with") }
- if policy(session).destroy?
  |
  = link_to("Delete", patient_hd_session_path(patient, session),
            data: { confirm: t(".delete_confirmation") },
            method: :delete,
            class: "button alert")
|
span= " or "
= link_to "cancel", back_path


- if tmpl = admin_partial_name(form_builder)
  = render tmpl
- else
  = admin_form_for resource do |f|
    - form_builder.fields.each do |node|
      - if node.group?
        - if node.localized?
          = f.locale_tabs do |l|
            - node.fields.each do |field|
              - field.options[:as] = :editor if !field.options.key?(:as) && field.name.to_s =~ /description|content|body/
              = f.render_dsl_node field, locale: l
        - else
          = input_set node.title, node.options do
            - node.fields.each do |field|
              = f.render_dsl_node field
      - else
        = f.render_dsl_node node

    - if f.object.respond_to?(:fileupload_guid) && f.object.new_record?
      = f.hidden_field :fileupload_guid

    = f.save_buttons

  - if settings[:comments]
    = admin_comments

  - if settings[:history] && settings[:history][:sidebar]
    .sidebar.abs_bar.well.well-small
      label.do_toggle.label.label-large= t 'admin.actions.history.title'
      table.table.table-striped
        thead
          tr
            th= Track.han(:created_at)
            th= Track.han(:user)
        tbody
          - resource.tracks.recently.each do |a|
            tr
              td= l(a.created_at, format: :short)
              td= auto_show_link a.user

Add capture_block input via template

- if tmpl = admin_partial_name(form_builder)
  = render tmpl
- else
  = admin_form_for resource do |f|
    - form_builder.fields.each do |node|
      - if node.group?
        - if node.localized?
          = f.locale_tabs do |l|
            - node.fields.each do |field|
              - field.options[:as] = :editor if !field.options.key?(:as) && field.name.to_s =~ /description|content|body/
              = f.render_dsl_node field, locale: l
        - else
          = input_set node.title, node.options do
            - node.fields.each do |field|
              - if field.block && field.options[:as] == :capture_block
                = instance_exec(f, &field.block)
              - else
                = f.render_dsl_node field
      - else
        = f.render_dsl_node node

    - if f.object.respond_to?(:fileupload_guid) && f.object.new_record?
      = f.hidden_field :fileupload_guid

    = f.save_buttons

  - if settings[:comments]
    = admin_comments

  - if settings[:history] && settings[:history][:sidebar]
    .sidebar.abs_bar.well.well-small
      label.do_toggle.label.label-large= t 'admin.actions.history.title'
      table.table.table-striped
        thead
          tr
            th= Track.han(:created_at)
            th= Track.han(:user)
        tbody
          - resource.tracks.recently.each do |a|
            tr
              td= l(a.created_at, format: :short)
              td= auto_show_link a.user


doctype 5
html
  head
    title= "Billy - #{title}"
    = stylesheet_link_tag "application", :media => "all"
    = javascript_include_tag "application"
    = csrf_meta_tags
  body
    .container
      .navbar.navbar-inverse
        .navbar-inner

          .container
            = link_to "Billy", root_path, :class => 'brand'
            = render '/layouts/nav'
      header
        = render '/layouts/balance'

        - if title && !@hide_title
          h1 = title
      - flash.each do |name, msg|
        div class="alert alert-#{name == :notice ? 'success' : 'error'}"
          button type="button" class="close" data-dismiss="alert" ×
          = msg

      = yield

Remove balance from application layout

doctype 5
html
  head
    title= "Billy - #{title}"
    = stylesheet_link_tag "application", :media => "all"
    = javascript_include_tag "application"
    = csrf_meta_tags
  body
    .container
      .navbar.navbar-inverse
        .navbar-inner

          .container
            = link_to "Billy", root_path, :class => 'brand'
            = render '/layouts/nav'
      header
        = yield :header_top

        - if title && !@hide_title
          h1 = title
      - flash.each do |name, msg|
        div class="alert alert-#{name == :notice ? 'success' : 'error'}"
          button type="button" class="close" data-dismiss="alert" ×
          = msg

      = yield


= row(label: 'file.name', value: file.name)
= row(label: 'file.path', value: file.path)
= row(label: 'file.file_type', value: link_to_if(policy(file).show?, file.file_type, file.file_type))
= row(label: 'file.role', value: file.role? ? t("files.roles.#{file.role}") : '')
= row(label: 'file.hidden', value: file.hidden)
= row(label: 'file.read_only', value: file.read_only)
- if file.teacher_defined_assessment?
  = row(label: 'file.feedback_message', value: render_markdown(file.feedback_message), class: 'm-0')
  = row(label: 'file.weight', value: file.weight)
= row(label: 'file.content', value: file.native_file? ? link_to_if(policy(file).show?, file.native_file.file.filename, file.native_file.url) : code_tag(file.content))

Use file type for exercise show (highlight.js)

= row(label: 'file.name', value: file.name)
= row(label: 'file.path', value: file.path)
= row(label: 'file.file_type', value: link_to_if(policy(file).show?, file.file_type, file.file_type))
= row(label: 'file.role', value: file.role? ? t("files.roles.#{file.role}") : '')
= row(label: 'file.hidden', value: file.hidden)
= row(label: 'file.read_only', value: file.read_only)
- if file.teacher_defined_assessment?
  = row(label: 'file.feedback_message', value: render_markdown(file.feedback_message), class: 'm-0')
  = row(label: 'file.weight', value: file.weight)
= row(label: 'file.content', value: file.native_file? ? link_to_if(policy(file).show?, file.native_file.file.filename, file.native_file.url) : code_tag(file.content, file.file_type.programming_language))


.Panel
  .u-defaultThenLargeMargin
  .ContentFormatter.ContentFormatter--center
    .cs-Gallery
      - %w(america html jobs programadores zuckerberg ironman trabalho ruby).each do |name|
        .cs-Gallery-cell
          img.cs-Gallery-image(
            src="#{image_path("case-studies/creators-school/gallery/#{name}.png")}"
            srcset="#{image_path("case-studies/creators-school/gallery/#{name}.png")} 300w, #{image_path("case-studies/creators-school/gallery/#{name}@2x.png")} 600w"
            sizes="300px"
          )
  .u-defaultThenLargeMargin

Fix cs galery on safari

.Panel
  .u-defaultThenLargeMargin
  .ContentFormatter.ContentFormatter--centerHorizontally
    .cs-Gallery
      - %w(america html jobs programadores zuckerberg ironman trabalho ruby).each do |name|
        .cs-Gallery-cell
          img.cs-Gallery-image(
            src="#{image_path("case-studies/creators-school/gallery/#{name}.png")}"
            srcset="#{image_path("case-studies/creators-school/gallery/#{name}.png")} 300w, #{image_path("case-studies/creators-school/gallery/#{name}@2x.png")} 600w"
            sizes="300px"
          )
  .u-defaultThenLargeMargin


.columns
  .one-fourth.column
    = avatar(@user, size: 230)
    h2 = @user.name
  .three-fourths.column
    .pb-3.clearfix
      a.btn.btn-primary.float-right href="#{style_path(@conn, :new, @user.name)}" = gettext "New tweak"
    = if Enum.count(@styles) == 0 do
      .blankslate
        span.mega-octicon.octicon-pencil
        h3 = gettext "This is where your tweaks will be listed"
        p = gettext "Click \"New tweak\" above to get started!"
    - else
      h3 = gettext "Styles"
      = render_many(@styles, AtomStyleTweaks.StyleView, "table_row.html", conn: @conn)

Remove new tweak button from user show page when current user isn't user shown

.columns
  .one-fourth.column
    = avatar(@user, size: 230)
    h2 = @user.name
  .three-fourths.column
    = if !is_nil(@current_user) && @current_user.name == @user.name do
      .pb-3.clearfix
        a.btn.btn-primary.float-right href="#{style_path(@conn, :new, @user.name)}" = gettext "New tweak"
    = if Enum.count(@styles) == 0 do
      .blankslate
        span.mega-octicon.octicon-pencil
        h3 = gettext "This is where your tweaks will be listed"
        p = gettext "Click \"New tweak\" above to get started!"
    - else
      h3 = gettext "Styles"
      = render_many(@styles, AtomStyleTweaks.StyleView, "table_row.html", conn: @conn)


div
  header.group.page-header.page-header-wider
    div
      h1 Winners’ Resources

  .article-container.article-container-wider
    article.group role="article"
      .inner
        p Here you can download Queen’s Award for Enterprise resources for use in your websites and advertising materials. The Winners’ Manual provides more detailed information on where and how you are allowed to use these resources.

        br

        h2 Download the logo to embed on your website

        section.attachment.embedded
          .attachment-thumb
            = link_to image_path("queens-awards-emblem.png"), class: "thumbnail", target: "_blank"
              = image_tag "queens-awards-emblem-thumbnail.png"
          .attachment-details
            h2.title
              = link_to "Queen's Award Emblem", image_path("queens-awards-emblem.png"), target: "_blank"
            p.metadata
              span.type PNG

        footer
          nav.pagination aria-label="Pagination" role="navigation"
            ul.group
              li.previous.previous-alternate
                = link_to dashboard_path
                  span.pagination-label Back

COPY Winner's QAE logo -> emblem

div
  header.group.page-header.page-header-wider
    div
      h1 Winners’ Resources

  .article-container.article-container-wider
    article.group role="article"
      .inner
        p Here you can download Queen’s Award for Enterprise resources for use in your websites and advertising materials. The Winners’ Manual provides more detailed information on where and how you are allowed to use these resources.

        br

        h2 Download the emblem to embed on your website

        section.attachment.embedded
          .attachment-thumb
            = link_to image_path("queens-awards-emblem.png"), class: "thumbnail", target: "_blank"
              = image_tag "queens-awards-emblem-thumbnail.png"
          .attachment-details
            h2.title
              = link_to "Queen's Award Emblem", image_path("queens-awards-emblem.png"), target: "_blank"
            p.metadata
              span.type PNG

        footer
          nav.pagination aria-label="Pagination" role="navigation"
            ul.group
              li.previous.previous-alternate
                = link_to dashboard_path
                  span.pagination-label Back


article.page
  header.page__title
    h1 the electronic music producer workshop
  main.page__content
    .left style="float: left; width: 50%"
      = image_tag 'workshop.png'
    .right style="float: right; width: 49%; margin-left: 10px"
      p Have you been working on new music, and want to get feedback on your latest work in progress? Can't seem to get that one snare/kick just right, and want love another set of ears on it? Stuck on a mix? Looking for new ideas/sounds to jump start your next project? Curious about what other local artists are working on?
      h2 we want to help
      p We here at brother.ly would like to provide this producer workshop as an outlet for just such interests. Modeled off of a classic writers workshop, this new monthly gathering is an opportunity for you to bring your new music / ideas / questions to a group of other producers and musicians.
      h2 every month
      p This workshop will begin as a monthly event. So even if you can't make this one, keep your eyes peeled for more! Check our Facebook page for updates.

Add link to FB page

article.page
  header.page__title
    h1 the electronic music producer workshop
  main.page__content
    .left style="float: left; width: 50%"
      = image_tag 'workshop.png'
    .right style="float: right; width: 49%; margin-left: 10px"
      p Have you been working on new music, and want to get feedback on your latest work in progress? Can't seem to get that one snare/kick just right, and want love another set of ears on it? Stuck on a mix? Looking for new ideas/sounds to jump start your next project? Curious about what other local artists are working on?
      h2 we want to help
      p We here at brother.ly would like to provide this producer workshop as an outlet for just such interests. Modeled off of a classic writers workshop, this new monthly gathering is an opportunity for you to bring your new music / ideas / questions to a group of other producers and musicians.
      h2 every month
      p This workshop will begin as a monthly event. So even if you can't make this one, keep your eyes peeled for more!
      p
        a href="http://facebook.com/brotherlyparty"
          Check our Facebook page for updates.


.form-element.form-group.clearfix
  - case element.data_type
  - when 'text'
    input.form-control placeholder=element.label
    .control-bar
      = link_to edit_form_form_element_path(form, element), remote: true do
        small
          span.glyphicon.glyphicon-edit
      = link_to form_form_element_path(form, element),
        { method: :delete,
          remote: true,
          data: { confirm: t('common.confirm') } } do
        small
          span.glyphicon.glyphicon-remove

  - when 'checkbox'
    = check_box_tag element.name
    '
    = element.label

Add remove link for all form elements

.form-element.form-group.clearfix
  - case element.data_type
  - when 'text'
    input.form-control placeholder=element.label

  - when 'checkbox'
    = check_box_tag element.name
    '
    = element.label

  .control-bar
    = link_to form_form_element_path(form, element),
      { method: :delete,
        remote: true,
        data: { confirm: t('common.confirm') } } do
      small
        span.glyphicon.glyphicon-remove


footer
  hr
  .row
    .col-sm-8.col-sm-offset-2
      .pull-right © 2014 Code for Atlanta

= javascript_include_tag "application"
= yield :bottom_js

Update the footer with the social media buttons and Code of Conduct link.

footer
  hr
  .row
    .col-sm-8.col-sm-offset-2

      = link_to "http://www.facebook.com/codeforatlanta", target: "_blank" do
        i.fa.fa-facebook.fa-3x.social
      = link_to "http://www.twitter.com/codeforatlanta", target: "_blank" do
        i.fa.fa-twitter.fa-3x.social
      = link_to "http://www.github.com/codeforatlanta", target: "_blank" do
        i.fa.fa-github.fa-3x.social

      .pull-right
        a href=conduct_path Code of Conduct

        '  | © 2014 Code for Atlanta

= javascript_include_tag "application"
= yield :bottom_js


.columns
  .one-fourth.column
    = avatar(@user, size: 230)
    h2 = @user.name
  .three-fourths.column
    = if !is_nil(@current_user) && @current_user.name == @user.name do
      .pb-3.clearfix
        a.btn.btn-primary.float-right href="#{style_path(@conn, :new, @user.name)}" = gettext "New tweak"
    = if Enum.count(@styles) == 0 do
      .blankslate
        span.mega-octicon.octicon-pencil
        h3 = gettext "This is where your tweaks will be listed"
        p = gettext "Click \"New tweak\" to get started!"
    - else
      h3 = gettext "Styles"
      = render_many(@styles, AtomStyleTweaks.StyleView, "table_row.html", conn: @conn)

Add staff badge to show user page

.columns
  .one-fourth.column
    = avatar(@user, size: 230)
    h2.d-inline-block = @user.name
    = if @user.site_admin do
      span.state.bg-blue.d-inline-block.mt-1.float-right
        = gettext "Staff"
  .three-fourths.column
    = if !is_nil(@current_user) && @current_user.name == @user.name do
      .pb-3.clearfix
        a.btn.btn-primary.float-right href="#{style_path(@conn, :new, @user.name)}" = gettext "New tweak"
    = if Enum.count(@styles) == 0 do
      .blankslate
        span.mega-octicon.octicon-pencil
        h3 = gettext "This is where your tweaks will be listed"
        p = gettext "Click \"New tweak\" to get started!"
    - else
      h3 = gettext "Styles"
      = render_many(@styles, AtomStyleTweaks.StyleView, "table_row.html", conn: @conn)


#image_widget_form.form-group
  = label_tag 'widgets[image][image_url]', 'Image URL:', class: 'control-label col-lg-2'
  .col-lg-10
    = text_field_tag 'widgets[image][image_url]', options['image_url'], class: 'form-control'
    = hidden_field_tag 'widgets[image][widget_type]', WidgetType.find_by(:widget_name => 'image').id
    = file_field_tag 'widgets[image][image_upload]'

Add image cropper fields to image widget form.

#image_widget_form.form-group
  = label_tag 'widgets[image][image_url]', 'Image URL:', class: 'control-label col-lg-2'
  .col-lg-10
    = text_field_tag 'widgets[image][image_url]', options['image_url'], class: 'form-control'
    = hidden_field_tag 'widgets[image][widget_type]', WidgetType.find_by(:widget_name => 'image').id
    = file_field_tag 'widgets[image][image_upload]'
    #image_container
      #image_preview
        = image_tag(options['image_url'], :id=>'image', :class=>"img-responsive center-block", :alt=>"")
      div
        input type="hidden" name="image_x" id="image_x"
        input type="hidden" name="image_y" id="image_y"
        input type="hidden" name="image_width" id="image_width"
        input type="hidden" name="image_height" id="image_height"


/ Footer comments box
/ two states, shown and hidden (maybe eventually)

#commenting-app ng-controller="CommentsAppCtrl"

  #comments_full.wrap.container-fluid ng-show="mode == 'full'" commented-scroll-to="max" ng-controller="CommentsCtrl"
    ul
      li.comment.row-fluid ng-repeat="comment in comments" id="comment-{{comment.id}}"
        .span12
          p {{comment.name}}: {{comment.text}}

  .states-container ng-switch="mode"

    .wrap.container-fluid ng-switch-when="small"
      form.form-inline novalidate="true" name="userNameForm" ng-submit="startCommenting()" ng-controller="UserFormController"
        label for="name" Name:
        input type="text" name="name" ng-model="comment.name" required="true"
        input type="submit" value="Start Commenting!"

    .wrap.container-fluid ng-switch-when="full"
      form.form-inline ng-submit="postMessage()"
        label for="text" Message:
        input type="text" name="text" ng-model="comment.text"
        input type="submit" value="Transmit"

        input type="button" value="Change Username" ng-click="switchModes('small')"

Add a few css classes to make the form more bootstrapy

/ Footer comments box
/ two states, shown and hidden (maybe eventually)

#commenting-app ng-controller="CommentsAppCtrl"

  #comments_full.wrap.container-fluid ng-show="mode == 'full'" commented-scroll-to="max" ng-controller="CommentsCtrl"
    ul
      li.comment.row-fluid ng-repeat="comment in comments" id="comment-{{comment.id}}"
        .span12
          p {{comment.name}}: {{comment.text}}

  .states-container ng-switch="mode"

    .wrap.container-fluid ng-switch-when="small"
      form.form-inline novalidate="true" name="userNameForm" ng-submit="startCommenting()" ng-controller="UserFormController"
        input.input-small type="text" name="name" ng-model="comment.name" required="true" placeholder="Username"
        input.btn type="submit" value="Start Commenting!"

    .wrap.container-fluid ng-switch-when="full"
      form.form-inline ng-submit="postMessage()"
        input.input-small type="text" name="text" ng-model="comment.text" placeholder="Type your comment here"
        input.btn type="submit" value="Transmit"

        input.btn type="button" value="Change Username" ng-click="switchModes('small')"


= render @post

- content_for :sidebar
  h2 Latest Articles
  ul
    - @latest_posts.each do |post|
      li = link_to post

  h2 Latest in #{@post.column}
  ul
    - @latest_in_col.each do |post|
      li = link_to post

Fix article post sidebar links

= render @post

- content_for :sidebar
  h2 Latest Articles
  ul
    - @latest_posts.each do |post|
      li = link_to post.headline, post

  h2 Latest in #{@post.column}
  ul
    - @latest_in_col.each do |post|
      li = link_to post.headline, post


- content_for(:header) do
  h2
    | 404
    small Not Found
article
  p Those splits either never existed or were deleted.
  p If you have reason to believe this is a mistake, please
    a<> href="mailto:qhiiyr@gmail.com" email me
    this URL and why you think so.

Fix message for 404 page

- content_for(:header) do
  h2
    | 404
    small Not Found
article
  p Those splits either never existed or were deleted.
  p
    | If you have reason to believe this is a mistake, please
    a<> href="mailto:qhiiyr@gmail.com" email me
    | this URL and why you think so.


h1 Posts

#posts.container

- content_for :scripts do
  coffee:
    $ ->
      new PostsApp.PostsView
      PostsApp.router = new PostsApp.Router
      Backbone.history.start()

  javascript:
    PostsApp.publisher = #{current_user.is_publisher}

Fix the publisher issue on backend

h1 Posts

#posts.container

- content_for :scripts do
  coffee:
    $ ->
      new PostsApp.PostsView
      PostsApp.router = new PostsApp.Router
      Backbone.history.start()

  javascript:
    PostsApp.publisher = #{current_user.is_publisher?}


.panel.panel-default
  .panel-heading#appraisal-form-secondary-heading role="tab"
    h4.panel-title
      a data-toggle="collapse" data-parent="#panel-assessment" href="#section-appraisal-form-secondary" aria-expanded="true" aria-controls="section-appraisal-form-secondary"
        ' Appraisal Form (Secondary)
        small
          ' Updated by Admin User - 28/09/15 at 08:03
  #section-appraisal-form-secondary.section-appraisal-form.section-appraisal-form-secondary.panel-collapse.collapse.in role="tabpanel" aria-labelledby="appraisal-form-secondary-heading"
    .panel-body
      = simple_form_for([namespace_name, secondary_assessment], remote: true) do |f|
        = f.hidden_field :form_answer_id
        = render_section(resource, f)
        = f.submit :add, class: "if-js-hide"
      - unless secondary_assessment.submitted?
        = form_tag(url_for([namespace_name, :assessment_submissions]), remote: true, authenticity_token: true, class: "submit-assessment", "data-type" => "json")
          = hidden_field_tag :assessment_id, secondary_assessment.id
          = submit_tag "Submit Case Assessment"
          .feedbackHolder
      - else
        span Assessment Submitted

Add timestamp for second appraisal form

.panel.panel-default
  .panel-heading#appraisal-form-secondary-heading role="tab"
    h4.panel-title
      a data-toggle="collapse" data-parent="#panel-assessment" href="#section-appraisal-form-secondary" aria-expanded="true" aria-controls="section-appraisal-form-secondary"
        ' Appraisal Form (Secondary)
        small
          = secondary_assessment.last_editor_info
  #section-appraisal-form-secondary.section-appraisal-form.section-appraisal-form-secondary.panel-collapse.collapse.in role="tabpanel" aria-labelledby="appraisal-form-secondary-heading"
    .panel-body
      = simple_form_for([namespace_name, secondary_assessment], remote: true) do |f|
        = f.hidden_field :form_answer_id
        = render_section(resource, f)
        = f.submit :add, class: "if-js-hide"
      - unless secondary_assessment.submitted?
        = form_tag(url_for([namespace_name, :assessment_submissions]), remote: true, authenticity_token: true, class: "submit-assessment", "data-type" => "json")
          = hidden_field_tag :assessment_id, secondary_assessment.id
          = submit_tag "Submit Case Assessment"
          .feedbackHolder
      - else
        span Assessment Submitted


- content_for(:title) { User.model_name.human(count: 2) }
section.container
  header.row
    .col-sm-12
      h2
        = User.model_name.human(count: 2)
  .users
    .row
      .col-sm-12
        table
          thead
            tr
              th = User.human_attribute_name(:name)
              th = User.human_attribute_name(:email)
              th.roles_column = User.human_attribute_name(:roles)
          tbody#user_table
            = render @users
    .row
      .col-sm-4.col-sm-offset-4.text-center#pagination
        = paginate @users, remote: true

Fix paging styles in user administation

- content_for(:title) { User.model_name.human(count: 2) }
section.container
  header.row
    .col-sm-12
      h2
        = User.model_name.human(count: 2)
  .users
    .row
      .col-sm-12
        table
          thead
            tr
              th = User.human_attribute_name(:name)
              th = User.human_attribute_name(:email)
              th.roles_column = User.human_attribute_name(:roles)
          tbody#user_table
            = render @users
    .row
      .col-sm-12.text-center#pagination
        = paginate @users, remote: true


p style=("margin-left: #{indent * 10}px;")
  =comment.body
-comment.children.each do |c|
  =render 'view', comment: c, indent: indent += 1

Correct comment nesting indentation in comment view

p style=("margin-left: #{indent * 15}px;")
  =comment.body
-comment.children.each do |c|
  =render 'view', comment: c, indent: indent + 1


doctype html
html[lang="en"]
head
  css:
    body { margin: 20px }
    .content {
      background-color: #ddd;
      padding: 20px;
      width: #{params[:width] || 960}px;
    }
    p { font-family: serif; font-size: 16px }
body
  div.content
    = yield

Fix markup of example embed page


- contribution = @notification.contribution
p Olá, #{contribution.user.decorate.display_name}!
p Seu apoio para o projeto #{link_to(contribution.project.name, project_by_slug_url(permalink: contribution.project.permalink))} foi confirmado com sucesso.
- if contribution.project.thank_you.present?
  p= contribution.project.thank_you.gsub('\n', '
')
p Até o momento você e outras #{contribution.project.total_contributions} pessoas estão tornando esse projeto uma realidade.
p Esse e-mail serve como um recibo provisório da sua contribuição.
= render partial: 'contribution_data', locals: {contribution: contribution}

Update `confirm contribution` email template

- contribution = @notification.contribution
p Olá, #{contribution.user.decorate.display_name}!
p Seu apoio para o projeto #{link_to(contribution.project.name, project_by_slug_url(permalink: contribution.project.permalink))} foi confirmado com sucesso.
- if contribution.project.thank_you.present?
  p= contribution.project.thank_you.gsub('\n', '
')
p Até o momento você e outros #{contribution.project.total_contributions} apoiadores estão tornando esse projeto uma realidade.
p Esse e-mail serve como um recibo provisório da sua contribuição.
= render partial: 'contribution_data', locals: {contribution: contribution}


= div_for(current_course) do
  h1
    = format_inline_text(current_course.title)

  - unless current_course_user
    = render partial: 'course/user_registrations/registration'

  - unless current_course.user?(current_user)
    h2 = t('.description')
    = format_html(current_course.description)

    h2 = t('.instructors')
    #users-container
      = render partial: 'layouts/user',
               collection: current_course.managers.includes(:user).map(&:user)

  - if current_course.user?(current_user) || can?(:manage, current_course)
    - if @currently_active_announcements && !@currently_active_announcements.empty?
      h2 = t('.announcements')
      div.message-holder
        = render partial: @currently_active_announcements,
                 spacer_template: 'announcements/announcement_spacer'

    - if @todos && !@todos.empty?
      h2 = t('.pending_tasks')
      table.table.table-hover.pending-tasks
        thead
          tr
            th = t('.pending_tasks_title')
            th.text-center = t('.pending_tasks_start_at')
            th.text-center = t('.pending_tasks_end_at')
            th
        tbody
          = render @todos

    - if @activity_feeds && !@activity_feeds.empty?
      h2 = t('.activities')
      div.message-holder
        - @activity_feeds.each do |notification|
          - if notification.activity.object
            = render partial: notification_view_path(notification),
                     locals: { notification: notification }

Hide phantom staff from instructor container on course show page.

= div_for(current_course) do
  h1
    = format_inline_text(current_course.title)

  - unless current_course_user
    = render partial: 'course/user_registrations/registration'

  - unless current_course.user?(current_user)
    h2 = t('.description')
    = format_html(current_course.description)

    h2 = t('.instructors')
    #users-container
      = render partial: 'layouts/user',
               collection: current_course.managers.without_phantom_users.includes(:user).map(&:user)

  - if current_course.user?(current_user) || can?(:manage, current_course)
    - if @currently_active_announcements && !@currently_active_announcements.empty?
      h2 = t('.announcements')
      div.message-holder
        = render partial: @currently_active_announcements,
                 spacer_template: 'announcements/announcement_spacer'

    - if @todos && !@todos.empty?
      h2 = t('.pending_tasks')
      table.table.table-hover.pending-tasks
        thead
          tr
            th = t('.pending_tasks_title')
            th.text-center = t('.pending_tasks_start_at')
            th.text-center = t('.pending_tasks_end_at')
            th
        tbody
          = render @todos

    - if @activity_feeds && !@activity_feeds.empty?
      h2 = t('.activities')
      div.message-holder
        - @activity_feeds.each do |notification|
          - if notification.activity.object
            = render partial: notification_view_path(notification),
                     locals: { notification: notification }


doctype html
html lang=I18n.locale
  head
    title Mnemosyne
    meta charset="utf-8"
    meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"
    = javascript_pack_tag 'main'
    = stylesheet_pack_tag 'main', media: 'all'
    = csrf_meta_tags
  body
    header#header
      nav
        = link_to root_url, class: 'brand' do
          = 'Mnemosyne'

        ul
          li=link_to 'APM', platform_traces_path(@platform)
          li=link_to 'Errors', platform_errors_path(@platform)
    = yield

Prepare for APM index page

doctype html
html lang=I18n.locale
  head
    title Mnemosyne
    meta charset="utf-8"
    meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"
    = javascript_pack_tag 'main'
    = stylesheet_pack_tag 'main', media: 'all'
    = csrf_meta_tags
  body
    header#header
      nav
        = link_to root_url, class: 'brand' do
          = 'Mnemosyne'

        ul
          li=link_to 'APM', platform_path(@platform)
          li=link_to 'Traces', platform_traces_path(@platform)
          li=link_to 'Errors', platform_errors_path(@platform)
    = yield


article.session
  h6 = link_to agenda.subject, agenda.speakers.first
  p
    = agenda_speaker_links(agenda.speakers)
  p
    / TODO: Improve translation display
    - if agenda.language.present?
      - if agenda.translated_language.present?
        span.session__badge.badge.text-bg-primary
          | #{agenda.language} → #{agenda.translated_language}
      - else
        span.session__badge.badge.text-bg-primary = agenda.language
  p
    - agenda.tags.each do |tag|
      span.session__badge.badge.badge-pink.px-2.py-1 = tag.name

Fix language badge not display correctly

article.session
  h6 = link_to agenda.subject, agenda.speakers.first
  p
    = agenda_speaker_links(agenda.speakers)
  p
    / TODO: Improve translation display
    - if agenda.language.present?
      - if agenda.translated_language.present?
        span.session__badge.badge.bg-primary
          | #{agenda.language} → #{agenda.translated_language}
      - else
        span.session__badge.badge.bg-primary = agenda.language
  p
    - agenda.tags.each do |tag|
      span.session__badge.badge.badge-pink.px-2.py-1 = tag.name


#header
  .main-area
    .cell
      .logo Cloudless Box
      .author
        = 'by '
        a href='https://github.com/karolsluszniak' Karol Sluszniak

      .lead
        .line One Chef cookbook to rule all your webservers.
        .line One webserver to rule many webapps.
        .line One way ticket out of Heroku.
        .line One hour to get started.

      .actions
        a.learn-more href='#intro' Learn more
        a href='https://github.com/karolsluszniak/cloudless-box' target='_blank' Visit on GitHub
        a href='https://supermarket.chef.io/cookbooks/cloudless-box' target='_blank' Chef Supermarket

Update website with new main site link

#header
  .main-area
    .cell
      .logo Cloudless Box
      .author
        = 'by '
        a href='https://cloudless.pl' Karol Sluszniak

      .lead
        .line One Chef cookbook to rule all your webservers.
        .line One webserver to rule many webapps.
        .line One way ticket out of Heroku.
        .line One hour to get started.

      .actions
        a href='#intro' Learn more
        a href='https://github.com/karolsluszniak/cloudless-box' target='_blank' Visit on GitHub
        a href='https://supermarket.chef.io/cookbooks/cloudless-box' target='_blank' Chef Supermarket


- if style == 'source'
  ac:structured-macro ac:name="code"
    - if (confluence_supported_lang "#{source_lang}")
      ac:parameter ac:name="language" #{source_lang}
    - if title?
      ac:parameter ac:name="title" #{title}
    - if attr? :linenums
      ac:parameter ac:name="linenumbers" true
    - if attr? :start
      ac:parameter ac:name="firstline" =(attr :start)
    ac:plain-text-body
      <![CDATA[#{content}]]>
- else
  ac:structured-macro ac:name="noformat"
    - if title?
      ac:parameter ac:name="title" #{title}
    ac:plain-text-body
      <![CDATA[#{content}]]>

Support for collapsable code blocks - added `collapse` attribute that would render code blocks as "collapsed" by default

- if style == 'source'
  ac:structured-macro ac:name="code"
    - if (confluence_supported_lang "#{source_lang}")
      ac:parameter ac:name="language" #{source_lang}
    - if title?
      ac:parameter ac:name="title" #{title}
    - if attr? :linenums
      ac:parameter ac:name="linenumbers" true
    - if attr? :start
      ac:parameter ac:name="firstline" =(attr :start)
    - if attr? :collapse
      ac:parameter ac:name="collapse" =(attr :collapse)
    ac:plain-text-body
      <![CDATA[#{content}]]>
- else
  ac:structured-macro ac:name="noformat"
    - if title?
      ac:parameter ac:name="title" #{title}
    ac:plain-text-body
      <![CDATA[#{content}]]>


= div_for(question) do
  div.pull-right
    div.btn-group
      = edit_button(edit_path)
      = delete_button(delete_path)
  h4 = format_inline_text(question.display_title)
  = format_html(question.description)

Fix styling where question buttons are not aligned with empty descriptions

= div_for(question, class: ['clearfix']) do
  div.pull-right
    div.btn-group
      = edit_button(edit_path)
      = delete_button(delete_path)
  h4 = format_inline_text(question.display_title)
  = format_html(question.description)


= render layout: "renalware/patients/layout", locals: { title: "Archived Pathology Results" } do
  p #{number_of_records} archived results displayed. Hover over row header for investigation name.
  table#observations
    - rows.each do |row|
      - header, *values = row
      tr class= header.html_class title= header.title
        td
          = header
        - values.each do |cell|
          td= cell

Add message for no path. results

= render layout: "renalware/patients/layout", locals: { title: "Archived Pathology Results" } do
  - if rows.present?
    p #{number_of_records} archived results displayed. Hover over row header for investigation name.
    table#observations
      - rows.each do |row|
        - header, *values = row
        tr class= header.html_class title= header.title
          td
            = header
          - values.each do |cell|
            td= cell
  - else
    p No results available for this patient.


- contribution = @notification.contribution
|Projeto: #{contribution.project.name}
br/
|Chave do apoio: #{contribution.key}
br/
|ID meio de pagamento: #{contribution.payment_id}
br/
br/
|Esse apoio recebeu uma notificação de cancelamento após já ter recebido uma notificação de confirmação.
br/
|Verifique no site do meio de pagamento o real status da transação e, se o apoio constar como confirmado, confirme-o no site do Catarse (adm/contributions)

Fix company name in email

- contribution = @notification.contribution
- company_name = CatarseSettings[:company_name]

|Projeto: #{contribution.project.name}
br/
|Chave do apoio: #{contribution.key}
br/
|ID meio de pagamento: #{contribution.payment_id}
br/
br/
|Esse apoio recebeu uma notificação de cancelamento após já ter recebido uma notificação de confirmação.
br/
|Verifique no site do meio de pagamento o real status da transação e, se o apoio constar como confirmado, confirme-o no site da #{company_name} (adm/contributions)


= render layout: "renalware/patients/layout", locals: { title: "HD Summary" } do
  .row
    .medium-6.columns
      = render "renalware/hd/profiles/summary", profile: profile
    .medium-6.columns
      = render "renalware/hd/accesses/summary", access: access
    .medium-6.columns
      = render "renalware/hd/preference_sets/summary", preference_set: preference_set
  .row
    .medium-12.columns
      = render "renalware/hd/dry_weights/list", dry_weights: dry_weights
  .row
    .medium-12.columns
      = render "renalware/hd/sessions/list", sessions: sessions

Move Dry weights table above sessions on HD Summary

= render layout: "renalware/patients/layout", locals: { title: "HD Summary" } do
  .row
    .medium-6.columns
      = render "renalware/hd/profiles/summary", profile: profile
    .medium-6.columns
      = render "renalware/hd/preference_sets/summary", preference_set: preference_set
    .medium-6.columns
      = render "renalware/hd/accesses/summary", access: access
  .row
    .medium-6.columns
      = render "renalware/hd/dry_weights/list", dry_weights: dry_weights
  .row
    .medium-12.columns
      = render "renalware/hd/sessions/list", sessions: sessions


- if @resource.name.present?
  p Greetings, #{@resource.name}!
- else
  p Greetings
p Forgot your password? No worries! You can reset your password here:
p
  strong = link_to 'Reset my password', edit_password_url(@resource, reset_password_token: @token)
p If you run into any other problems, please #{mail_to('howdy@neighbor.ly', 'drop us a line')}.
p
  | All the best,
  br
  | The #{Configuration[:company_name]} Team

Change text of reset password instructions mail

p Greetings,

p Forgot your password? No worries, you can reset it here:

p
  strong = link_to 'Reset my password', edit_password_url(@resource, reset_password_token: @token)

p
  | All the best,
  br
  | The #{Configuration[:company_name]} Team


.backer
  - if backer.anonymous
    img src="/assets/user.png" class="backer_avatar"
    .back_info
      p#text
        em.anon=" #{t('.anonymous_backer')}"
      p#confirmed
        = backer.confirmed_at
      p#backed= t('.anonymous_description')
  - else
    a href=user_path(backer.user)
      img src=backer.user.display_image class="backer_avatar #{backer.user.profile_type}"
    .back_info[class=backer.user.profile_type]
      p#text
        a href=user_path(backer.user)
         = backer.user.short_name
      p#confirmed
        = l backer.confirmed_at, format: :short
      p#backed
        = backer.user.backs_text
  - if current_user and (current_user == @project.user or current_user.admin)
    .clearfix
    .reward
      =
      .value = backer.display_value
      - if backer.reward
        .user_reward
          = backer.reward.display_minimum
          |  -
          = backer.reward.medium_description
      - else
        |
        = t('.no_reward')
      - if backer.user.email
        .user_email = mail_to backer.user.email
      - else
        |
        = t('not_informed')
  - if backer.short_note.present?
    .short_note.clearfix
      p = backer.short_note

  .clear

Remove confirmed at from backers list

.backer
  - if backer.anonymous
    img src="/assets/user.png" class="backer_avatar"
    .back_info
      p#text
        em.anon=" #{t('.anonymous_backer')}"
      p#confirmed
        = backer.confirmed_at
      p#backed= t('.anonymous_description')
  - else
    a href=user_path(backer.user)
      img src=backer.user.display_image class="backer_avatar #{backer.user.profile_type}"
    .back_info[class=backer.user.profile_type]
      p#text
        a href=user_path(backer.user)
         = backer.user.short_name
      p#backed
        = backer.user.backs_text
  - if current_user and (current_user == @project.user or current_user.admin)
    .clearfix
    .reward
      =
      .value = backer.display_value
      - if backer.reward
        .user_reward
          = backer.reward.display_minimum
          |  -
          = backer.reward.medium_description
      - else
        |
        = t('.no_reward')
      - if backer.user.email
        .user_email = mail_to backer.user.email
      - else
        |
        = t('not_informed')
  - if backer.short_note.present?
    .short_note.clearfix
      p = backer.short_note

  .clear


- if @eligibility.answers && @eligibility.answers.any?
  .previous-answers
    .done-questions
      article
        table
          thead
            tr
              th.previous-answers-title colspan="2"
                ' Your eligibility answers so far
              /th.link-right.restart
                = link_to "Start again", eligibility_path
          tbody
            - @eligibility.sorted_answers.each do |question, answer|
              - if question.to_sym != step
                tr.section
                  td.previous-question-title
                    = Eligibility::Basic.label(question)
                  td.previous-question-body
                    - if Eligibility::Basic.boolean_question?(question)
                      = @eligibility.public_send("#{question}?") ? 'Yes' : 'No'
                    - else
                      = Eligibility::Basic.enumerized_attributes[question].find_value(answer).text
                  td.link-right
                    - unless admin_in_read_only_mode?
                      = link_to wizard_path(question) do
                        ' Change
                        span.visuallyhidden
                          = ' answer to' + Eligibility::Basic.label(question)

Hide the previous questions for first question

- if @eligibility.answers && @eligibility.answers.any?
  - unless @eligibility.sorted_answers.first.first.to_sym == step
    .previous-answers
      .done-questions
        article
          table
            thead
              tr
                th.previous-answers-title colspan="2"
                  ' Your eligibility answers so far
                /th.link-right.restart
                  = link_to "Start again", eligibility_path
            tbody
              - @eligibility.sorted_answers.each do |question, answer|
                - if question.to_sym != step
                  tr.section
                    td.previous-question-title
                      = Eligibility::Basic.label(question)
                    td.previous-question-body
                      - if Eligibility::Basic.boolean_question?(question)
                        = @eligibility.public_send("#{question}?") ? 'Yes' : 'No'
                      - else
                        = Eligibility::Basic.enumerized_attributes[question].find_value(answer).text
                    td.link-right
                      - unless admin_in_read_only_mode?
                        = link_to wizard_path(question) do
                          ' Change
                          span.visuallyhidden
                            = ' answer to' + Eligibility::Basic.label(question)


- assessment = submission.assessment
= content_tag_for(:tr, submission) do
  td = link_to_course_user(submission.course_user)
  td = link_to(format_inline_text(assessment.title),
               course_assessment_path(current_course, assessment))
  td = format_datetime(submission.submitted_at) if submission.submitted_at
  td = submission.workflow_state.capitalize
  - if submission.graded?
    td = submission.grade.to_i.to_s + ' / ' + assessment.maximum_grade.to_s
  - else
    td = '-- / ' + assessment.maximum_grade.to_s
  td
    - button_class = ['btn', 'btn-block']
    - link_path = edit_course_assessment_submission_path(current_course, assessment, submission)
    - if current_course_user.staff? && submission.submitted?
      = link_to(t('.grade'), link_path, class: button_class + ['btn-info'])
    - else
      = link_to(t('.view'), link_path, class: button_class + ['btn-primary'])
  td

Check the presence of current_course_user

- assessment = submission.assessment
= content_tag_for(:tr, submission) do
  td = link_to_course_user(submission.course_user)
  td = link_to(format_inline_text(assessment.title),
               course_assessment_path(current_course, assessment))
  td = format_datetime(submission.submitted_at) if submission.submitted_at
  td = submission.workflow_state.capitalize
  - if submission.graded?
    td = submission.grade.to_i.to_s + ' / ' + assessment.maximum_grade.to_s
  - else
    td = '-- / ' + assessment.maximum_grade.to_s
  td
    - button_class = ['btn', 'btn-block']
    - link_path = edit_course_assessment_submission_path(current_course, assessment, submission)
    - if current_course_user && current_course_user.staff? && submission.submitted?
      = link_to(t('.grade'), link_path, class: button_class + ['btn-info'])
    - else
      = link_to(t('.view'), link_path, class: button_class + ['btn-primary'])
  td


- sect0 = section_level == 0
= html_tag_if !sect0, :section, :class=>["sect#{section_level}", role]
  *{:tag=>"h#{section_level + 1}", :id=>id, :class=>('sect0' if sect0)}
    - if id && (document.attr? :sectanchors)
      a.anchor href="##{id}"
      =section_title
    - elsif id && (document.attr? :sectlinks)
      a.link href="##{id}" =section_title
    - else
      =section_title
  =content

Allow sectanchors & sectlinks to be used in tandem

- sect0 = section_level == 0
= html_tag_if !sect0, :section, :class=>["sect#{section_level}", role]
  *{:tag=>"h#{section_level + 1}", :id=>id, :class=>('sect0' if sect0)}
    - if id
      - if document.attr? :sectanchors
        a.anchor href="##{id}"
      - if document.attr? :sectlinks
        a.link href="##{id}" =section_title
      - else
        =section_title
    - else
      =section_title
  =content


= simple_form_for @search, url: "#", method: :get, as: :search, html: { class: "search-form" } do |f|
  .row
    .col-md-9.col-sm-8
      = render 'admin/users/navigation'

    .col-md-3.col-sm-4.col-xs-12.pull-right.text-right
      = link_to public_send("new_admin_#{controller_name.singularize}_path"), class: 'new-user btn btn-secondary btn-md' do
        = "+ Add #{controller_name == "users" ? "applicant" : controller_name.singularize}"
  .clear

  br

  .row
    .col-md-4.col-sm-5.col-xs-12
      .form-group.search-input
        = f.input :query, label: false, input_html: { class: "form-control", placeholder: "Search...", type: "search" }
        = submit_tag :submit, class: 'search-submit'
  .clear

  - if @search.query?
    .well.search-text
      p
        = "Search results for '#{@search.query}'"
        small
          = link_to "(Clear search)", [:admin, controller_name], class: "btn btn-link"

  = render 'list', resources: @resources, f: f

  .row
    .col-xs-12.text-right
      = paginate @resources
      .clear

Move the add user button lower

= simple_form_for @search, url: "#", method: :get, as: :search, html: { class: "search-form" } do |f|
  .row
    .col-md-9.col-sm-8
      = render 'admin/users/navigation'
  .clear

  br

  .row
    .col-md-4.col-sm-5.col-xs-12
      .form-group.search-input
        = f.input :query, label: false, input_html: { class: "form-control", placeholder: "Search...", type: "search" }
        = submit_tag :submit, class: 'search-submit'

    .col-md-3.col-sm-4.col-xs-12.pull-right.text-right
      = link_to public_send("new_admin_#{controller_name.singularize}_path"), class: 'new-user btn btn-secondary btn-md' do
        = "+ Add #{controller_name == "users" ? "applicant" : controller_name.singularize}"
  .clear

  - if @search.query?
    .well.search-text
      p
        = "Search results for '#{@search.query}'"
        small
          = link_to "(Clear search)", [:admin, controller_name], class: "btn btn-link"

  = render 'list', resources: @resources, f: f

  .row
    .col-xs-12.text-right
      = paginate @resources
      .clear


.tab-subnavigation-wrapper
  .container
    ul
      li= active_link_to 'Common Core Standards', teachers_progress_reports_standards_classrooms_path
      li= active_link_to 'Activities', teachers_progress_reports_activity_sessions_path
= premium_bar

Add Concepts link to progress reports subnav

.tab-subnavigation-wrapper
  .container
    ul
      li= active_link_to 'Common Core Standards', teachers_progress_reports_standards_classrooms_path
      li= active_link_to 'Activities', teachers_progress_reports_activity_sessions_path
      li= active_link_to 'Concepts', teachers_progress_reports_concepts_students_path
= premium_bar


head

  meta charset="utf-8"

  = display_meta_tags

  meta http-equiv="X-UA-Compatible"  content="IE=edge,chrome=1"

  meta name="viewport" content="width=device-width" initial-scale="1.0" maximum-scale="1.0"

  - if Setting['advanced.facebook_app_id']
    meta property="fb:app_id" content="#{ Setting['advanced.facebook_app_id'] }"

  -# = csrf_meta_tag

  = auto_discovery_link_tag :atom, notes_url(:atom), title: Setting['channel.name']

  = stylesheet_link_tag 'application'

  = javascript_include_tag 'application'

  script src='//maps.google.com/maps/api/js?v=3.5&sensor=false'
  script src='//google-maps-utility-library-v3.googlecode.com/svn/tags/markerclustererplus/2.0.14/src/markerclusterer_packed.js'

Add media: all to stylesheet tag

head

  meta charset="utf-8"

  = display_meta_tags

  meta http-equiv="X-UA-Compatible"  content="IE=edge,chrome=1"

  meta name="viewport" content="width=device-width" initial-scale="1.0" maximum-scale="1.0"

  - if Setting['advanced.facebook_app_id']
    meta property="fb:app_id" content="#{ Setting['advanced.facebook_app_id'] }"

  -# = csrf_meta_tag

  = auto_discovery_link_tag :atom, notes_url(:atom), title: Setting['channel.name']

  = stylesheet_link_tag 'application', media: 'all'

  = javascript_include_tag 'application'

  script src='//maps.google.com/maps/api/js?v=3.5&sensor=false'
  script src='//google-maps-utility-library-v3.googlecode.com/svn/tags/markerclustererplus/2.0.14/src/markerclusterer_packed.js'


.article-container.article-container-wider.step-article.step-error
  article.group role="article"
    .inner
      .application-notice.help-notice
        p Your application/nomination failed to submit because you’ve left some mandatory questions unanswered. These will be flagged in red on the sidebar. Once they are all completed, you’ll be able to submit your application/nomination.

COPY tweak application fail message

.article-container.article-container-wider.step-article.step-error
  article.group role="article"
    .inner
      .application-notice.help-notice
        p
          ' Your
          - if @form_answer.award_type == "promotion"
           ' nomination
          - else
            ' application
          ' failed to submit because you’ve left some mandatory questions unanswered. These will be flagged in red on the sidebar. Once they are all completed, you’ll be able to submit your
          - if @form_answer.award_type == "promotion"
           ' nomination
          - else
            ' application
          ' .


doctype html
html[lang="en"]
  head
    meta[charset="utf-8"]
    meta[name="viewport" content="width=device-width, initial-scale=1.0"]
    title
      = content_for?(:title) ? yield(:title) : "Fee remission staff app"
    = stylesheet_link_tag    "application"
    = javascript_include_tag "vendor/modernizr"
    = javascript_include_tag "application"
    = yield(:javascript) if content_for?(:javascript)
    = csrf_meta_tags
  body
    .contain-to-grid
      nav.top-bar(data-topbar)
        ul.title-area
          li.name
            h1 =link_to 'Help with fees', root_url
          li.toggle-topbar.menu-icon
            a href="#"
              span
        section.top-bar-section
          -if !current_page?(new_user_session_path)
            ul.right
                li
                  - if user_signed_in?
                    .inline
                      = "Welcome #{current_user.name}"
                      = link_to "Sign out", destroy_user_session_path, :method => :delete
                  - else
                    = link_to 'Sign in', new_user_session_path
    =render 'layouts/toolbar'
    .row
      .large-12.columns
        - flash.each do |key, value|
          .alert-box class="#{key}" data-alert=''
            |#{value}
            = link_to '×'.html_safe, '#', class: 'close'
    .row
      .large-12.columns
        = yield

Hide menu on sign-in page

doctype html
html[lang="en"]
  head
    meta[charset="utf-8"]
    meta[name="viewport" content="width=device-width, initial-scale=1.0"]
    title
      = content_for?(:title) ? yield(:title) : "Fee remission staff app"
    = stylesheet_link_tag    "application"
    = javascript_include_tag "vendor/modernizr"
    = javascript_include_tag "application"
    = yield(:javascript) if content_for?(:javascript)
    = csrf_meta_tags
  body
    .contain-to-grid
      nav.top-bar(data-topbar)
        ul.title-area
          li.name
            h1 =link_to 'Help with fees', root_url
          -if !current_page?(new_user_session_path)
            li.toggle-topbar.menu-icon
              a href="#"
                span
        -if !current_page?(new_user_session_path)
          section.top-bar-section
            ul.right
                li
                  - if user_signed_in?
                    .inline
                      = "Welcome #{current_user.name}"
                      = link_to "Sign out", destroy_user_session_path, :method => :delete
                  - else
                    = link_to 'Sign in', new_user_session_path
    =render 'layouts/toolbar'
    .row
      .large-12.columns
        - flash.each do |key, value|
          .alert-box class="#{key}" data-alert=''
            |#{value}
            = link_to '×'.html_safe, '#', class: 'close'
    .row
      .large-12.columns
        = yield


.span8
  .stat
    .value {{postsCount}}
    .title Posts
  .stat
    .title Following
    .value {{followingsCount}}
  .stat
    .title Followed by
    .value {{followersCount}}

Align stats with bio text on profile

.span2
.span6.no-offset
  .stat
    .value {{postsCount}}
    .title Posts
  .stat
    .title Following
    .value {{followingsCount}}
  .stat
    .title Followed by
    .value {{followersCount}}


.Panel.Panel--easymoneyGradient
  .Panel.Panel--easymoneyMapaMundi.cs-Panel--easymoneyPlug
    .Panel-backgroundImage
    .Panel-content
      .GridCell.GridCell--alignCenter
        .GridCell-content
          .ContentFormatter.ContentFormatter--centerHorizontally
            h1.Heading.Heading--brandLarge.u-defaultMargin
              span.Heading-light> Crafting
              span.Heading-highlight
                | easy.money
            = link_to "See Making Of easy.money", '/case-studies/easy-money', class: 'ButtonPrimary'

Fix Creators School plug for Easy Money case study.

.Panel.Panel--easymoneyGradient.Panel--easymoneyMapaMundi.cs-Panel--easymoneyPlug
  .Panel-backgroundImage
  .Panel-content
    .GridCell.GridCell--alignCenter
      .GridCell-content
        .ContentFormatter.ContentFormatter--centerHorizontally
          h1.Heading.Heading--brandLarge.u-defaultMargin
            span.Heading-light> Crafting
            span.Heading-highlight
              | easy.money
          = link_to "See Making Of easy.money", '/case-studies/easy-money', class: 'ButtonPrimary'


.comable-page
  .comable-main-fixed-top
    .comable-page-heading
      ul.pull-right.list-inline
        li
          = link_to_save

      h1.page-header
        ol.breadcrumb
          li>
            = link_to Comable::Apartment.t(:tenants), comable_apartment.tenants_path
          li>
            = link_to @tenant.name, comable_apartment.tenant_path(@tenant)
          li
            = link_to Comable::Apartment.t(:users), comable_apartment.tenant_users_path(@tenant)
          li.active
            = @user.human_id
            - if @user.bill_full_name
              small<
                = Comable.t('honorific', name: @user.bill_full_name)

  .comable-page-body
    section
      = render 'form'

Add the button to destroy a user

.comable-page
  .comable-main-fixed-top
    .comable-page-heading
      ul.pull-right.list-inline
        li
          = link_to_save

      h1.page-header
        ol.breadcrumb
          li>
            = link_to Comable::Apartment.t(:tenants), comable_apartment.tenants_path
          li>
            = link_to @tenant.name, comable_apartment.tenant_path(@tenant)
          li
            = link_to Comable::Apartment.t(:users), comable_apartment.tenant_users_path(@tenant)
          li.active
            = @user.human_id
            - if @user.bill_full_name
              small<
                = Comable.t('honorific', name: @user.bill_full_name)

  .comable-page-body
    = render 'form'
    hr
    .panel.panel-danger
      .panel-heading type="button" data-toggle="collapse" data-target="#comable-danger"
        strong
          span.fa.fa-angle-down>
          = Comable::Apartment.t(:destroy)
      #comable-danger.collapse
        .panel-body
          p
            = Comable::Apartment.t(:confirmation_before_destroy)
          = link_to Comable::Apartment.t(:destroy), comable_apartment.tenant_user_path(@tenant, @user), method: :delete, class: 'btn btn-danger'


= simple_form_for [current_course, @video] do |f|
  = f.error_notification
  = f.input :title
  = f.input :description, as: :text
  = f.input :url, placeholder: t('.url_placeholder')
  = f.input :start_at, as: :bootstrap_date_time
  = f.input :published, as: :boolean

  = f.button :submit

Set the default date for new video

= simple_form_for [current_course, @video] do |f|
  = f.error_notification
  = f.input :title
  = f.input :description, as: :text
  = f.input :url, placeholder: t('.url_placeholder')
  = f.input :start_at,
            as: :bootstrap_date_time,
            input_html: { value: f.object.start_at || Date.today }
  = f.input :published, as: :boolean

  = f.button :submit


h1= Quiz

- unless current_user.guest?
  p
    ' #{t(".welcome")}
    strong= current_user.name
  p
    = link_to t(".sign_out"), signout_path, method: :post

  = button_to join_rooms_path do
    = t('home.play')

- else
  p= t(".sign_in")
  ul
    li= link_to "Facebook", signin_path(:facebook)
    li= link_to "Twitter", signin_path(:twitter)
    li= link_to "VK", signin_path(:vkontakte)

Revert "Show botton "play" only for signed users."

h1= Quiz

- unless current_user.guest?
  p
    ' #{t(".welcome")}
    strong= current_user.name
  p
    = link_to t(".sign_out"), signout_path, method: :post
- else
  p= t(".sign_in")
  ul
    li= link_to "Facebook", signin_path(:facebook)
    li= link_to "Twitter", signin_path(:twitter)
    li= link_to "VK", signin_path(:vkontakte)

= button_to join_rooms_path do
  = t('home.play')


#toolbar
  a href=wiki_link_edit()
    i class="fa fa-pencil-square" aria-hidden="true"
  a href=wiki_link_create()
    i class="fa fa-plus-square" aria-hidden="true"
  / include _searchbox.html
  <input dir="auto" style="position: relative; vertical-align: top;" spellcheck="false" autocomplete="off" class="searchbox__input aa-input" id="doc-search" name="search" placeholder="Search in the doc" required="required" type="search">
    i class="fa fa-navicon" aria-hidden="true"

Test for dropdown list button.

#toolbar
  a href=wiki_link_edit()
    i class="fa fa-pencil-square" aria-hidden="true"
  a href=wiki_link_create()
    i class="fa fa-plus-square" aria-hidden="true"
    i class="fa fa-navicon" aria-hidden="true"
  / include _searchbox.html
  <input dir="auto" style="position: relative; vertical-align: top;" spellcheck="false" autocomplete="off" class="searchbox__input aa-input" id="doc-search" name="search" placeholder="Search in the doc" required="required" type="search">
    i class="fa fa-navicon" aria-hidden="true"


header#header.contain-to-grid.fixed
  nav.top-bar
    ul.title-area
      / Title Area
      li.name
        h1: a href="/"
          b Ruby
          i Daily

      / Remove the class "menu-icon" to get rid of menu icon. Take out "Menu" to just have icon alone
      li.toggle-topbar.menu-icon
        a href="#": span Menu
    section.top-bar-section
      / Left Nav Section
      ul.left
        li: a href="//paper.rubydaily.org" PAPER
        li: a href="//stream.rubydaily.org" STREAM
      ul.right
        li: form#search method="GET" action="//stream.rubydaily.org/search"
          .row.collapse
            .small-11.columns
              input#q type="search" name="q" placeholder="Search..."
            .small-1.column
        li: a.submit href="//stream.rubydaily.org/submit"
          i.icon-pencil
          | SUBMIT

Fix search field length for mobile devices

header#header.contain-to-grid.fixed
  nav.top-bar
    ul.title-area
      / Title Area
      li.name
        h1: a href="/"
          b Ruby
          i Daily

      / Remove the class "menu-icon" to get rid of menu icon. Take out "Menu" to just have icon alone
      li.toggle-topbar.menu-icon
        a href="#": span Menu
    section.top-bar-section
      / Left Nav Section
      ul.left
        li: a href="//paper.rubydaily.org" PAPER
        li: a href="//stream.rubydaily.org" STREAM
      ul.right
        li: form#search method="GET" action="//stream.rubydaily.org/search"
          .row.collapse
            .small-12.large-11.columns
              input#q type="search" name="q" placeholder="Search..."
            .large-1.column
        li: a.submit href="//stream.rubydaily.org/submit"
          i.icon-pencil
          | SUBMIT


.footer-full-signature-text.fontsize-small #{t('layouts.footer.titles.about')}
a.zendesk_widget.link-footer href="#{CatarseSettings[:zendesk_url]}/account/dropboxes/#{CatarseSettings[:zendesk_dropbox_id]}"  #{t('layouts.footer.links.contact')}
a.link-footer href="http://crowdfunding.catarse.me/nossa-taxa?ref=ctrse_footer"
  | Nossa taxa
  span.badge.badge-success Novidade
a.link-footer href="#{press_url}"  #{t('layouts.footer.links.press')}
a.link-footer href="#{CatarseSettings[:faq_url]}"  #{t('layouts.footer.links.help_support')}
a.link-footer href="#{guides_url}"  #{t('layouts.footer.links.guides')}
a.link-footer href="http://pesquisa.catarse.me/"  #{t('layouts.footer.links.crowdfunding_stats')}
a.link-footer href="#{terms_of_use_path}"  #{t('layouts.footer.links.terms')}
a.link-footer href="#{privacy_policy_path}"  #{t('layouts.footer.links.privacy')}

Include 2016 in footer about

.footer-full-signature-text.fontsize-small #{t('layouts.footer.titles.about')}
a.zendesk_widget.link-footer href="#{CatarseSettings[:zendesk_url]}/account/dropboxes/#{CatarseSettings[:zendesk_dropbox_id]}"  #{t('layouts.footer.links.contact')}
a.link-footer href="http://ano.catarse.me/2016?ref=ctrse_footer"
  | 2016 no Catarse
  span.badge.badge-success Novidade
a.link-footer href="http://crowdfunding.catarse.me/paratodos?ref=ctrse_footer"
  | Como funciona
a.link-footer href="#{press_url}"  #{t('layouts.footer.links.press')}
a.link-footer href="#{CatarseSettings[:faq_url]}"  #{t('layouts.footer.links.help_support')}
a.link-footer href="#{guides_url}"  #{t('layouts.footer.links.guides')}
a.link-footer href="http://pesquisa.catarse.me/"  #{t('layouts.footer.links.crowdfunding_stats')}
a.link-footer href="#{terms_of_use_path}"  #{t('layouts.footer.links.terms')}
a.link-footer href="#{privacy_policy_path}"  #{t('layouts.footer.links.privacy')}


| Hi, #{@user.display_name},
br/
br/

| #{@asker.display_name} has a question for you regarding your project on Neighbor.ly. Simply reply to this email to contact #{mail_to @asker.email, @asker.display_name} directly.
br/
br/
strong Question:
= simple_format(@question)
br/
br/
| Tip: To answer general questions, be sure to check out the #{link_to 'FAQ tool', project_url(@project, anchor: 'project_faqs')}. Answering common questions here will help users understand your project better and will lessen the need to contact you directly.
br/
br/
| High Fives,
br/
| The #{::Configuration[:company_name]} Team

Fix faq url on question email

| Hi, #{@user.display_name},
br/
br/

| #{@asker.display_name} has a question for you regarding your project on Neighbor.ly. Simply reply to this email to contact #{mail_to @asker.email, @asker.display_name} directly.
br/
br/
strong Question:
= simple_format(@question)
br/
br/
| Tip: To answer general questions, be sure to check out the #{link_to 'FAQ tool', project_faqs_url(@project)}. Answering common questions here will help users understand your project better and will lessen the need to contact you directly.
br/
br/
| High Fives,
br/
| The #{::Configuration[:company_name]} Team


- provide(:page_content_class, "multi-page page-account")

- content_for :breadcrumbs do
  li = link_to "Account details", correspondent_details_account_path

header.page-header.group.page-header-over-sidebar
  div
    h1
      ' Account details

.steps-progress-container
  .steps-progress-content
    header.page-header.group
      div
        h2
          ' Collaborators

    .article-container
      article.group role="article"
        .inner
          h2
            ' Add new collaborator

          = render "form"

  = render "accounts/steps_progress_bar"

COPY Fix add collaborator title

- provide(:page_content_class, "multi-page page-account")

- content_for :breadcrumbs do
  li = link_to "Account details", correspondent_details_account_path

header.page-header.group.page-header-over-sidebar
  div
    h1
      ' Account details

.steps-progress-container
  .steps-progress-content
    header.page-header.group
      div
        h2
          ' Add new collaborator

    .article-container
      article.group role="article"
        .inner
          = render "form"

  = render "accounts/steps_progress_bar"


.events-index
  .page-header
    h1
      small.pull-right
        = link_to new_event_path, 'Добавить', class: 'btn btn-success'
        = link_to events_path(format: :ics), title: 'iCalendar feed', class: "color-rosewood no-underline" do
          i.fa.fa-calendar>
        = link_to events_path(format: :atom), title: 'Atom feed', class: "color-rosewood no-underline" do
          i.fa.fa-rss-square<

      = Event.model_name.human(count: 2)

  ul.nav.nav-pills role="tablist"
    li.active role="presentation" class="active"
      a href="#future_events" data-toggle="pill" = t('.future_events')
    li role="presentation"
      a href="#past_events" data-toggle="pill" = t('.past_events')
  br

  .tab-content
    #future_events.tab-pane.active role="tabpanel"
      .events = render @events
    #past_events.tab-pane role="tabpanel"
      .events = render @past_events

Fix add new event button

.events-index
  .page-header
    h1
      small.pull-right
        a.btn.btn-success> href=new_event_path Добавить
        = link_to events_path(format: :ics), title: 'iCalendar feed', class: "color-rosewood no-underline" do
          i.fa.fa-calendar>
        = link_to events_path(format: :atom), title: 'Atom feed', class: "color-rosewood no-underline" do
          i.fa.fa-rss-square<

      = Event.model_name.human(count: 2)

  ul.nav.nav-pills role="tablist"
    li.active role="presentation" class="active"
      a href="#future_events" data-toggle="pill" = t('.future_events')
    li role="presentation"
      a href="#past_events" data-toggle="pill" = t('.past_events')
  br

  .tab-content
    #future_events.tab-pane.active role="tabpanel"
      .events = render @events
    #past_events.tab-pane role="tabpanel"
      .events = render @past_events


- if item.time_for(course_user).is_a? Course::PersonalTime and item.time_for(course_user).fixed?
  span title=t('course.lesson_plan.items.fixed_desc')
    = fa_icon 'lock'
=< format_datetime(item.time_for(course_user)[attribute], datetime_format)
- if item.time_for(course_user)[attribute] != item.reference_time_for(course_user)[attribute]
  br
  strike
    = t('course.lesson_plan.items.ref')
    = format_datetime(item.reference_time_for(course_user)[attribute], datetime_format)

Store query result in variables to reduce N+1

- effective_time = item.time_for(course_user)
- reference_time = item.reference_time_for(course_user)
- if effective_time.is_a? Course::PersonalTime and effective_time.fixed?
  span title=t('course.lesson_plan.items.fixed_desc')
    = fa_icon 'lock'
=< format_datetime(effective_time[attribute], datetime_format)
- if effective_time[attribute] != reference_time[attribute]
  br
  strike
    = t('course.lesson_plan.items.ref')
    = format_datetime(reference_time[attribute], datetime_format)


- title @game.name
.container
  h2 = content_for(:title)
  h5 a speedgame
  = render partial: 'shared/alerts'
.container
  - @game.categories.each do |category|
    - cache [:category_portrait, :v1, {category: category}] do
      .well.col-xl-2.col-lg-3.col-md-4.col-sm-5 style="margin: .5em;"
        a href=category_path(@game, category)
          h4 = category.name
        small
          = render partial: 'shared/time', locals: {time: category.best_known_run.time, show_milliseconds: false}
          | best on record

Fix a bug that caused some game pages to 500

- title @game.name
.container
  h2 = content_for(:title)
  h5 a speedgame
  = render partial: 'shared/alerts'
.container
  - @game.categories.each do |category|
    - cache [:category_portrait, :v1, {category: category}] do
      - if category.best_known_run
        .well.col-xl-2.col-lg-3.col-md-4.col-sm-5 style="margin: .5em;"
          a href=category_path(@game, category)
            h4 = category.name
          small
            = render partial: 'shared/time', locals: {time: category.best_known_run.time, show_milliseconds: false}
            | best on record


fieldset.hd-dry_weights.simple.simple-table
  legend
    span.title= t(".title")
    - unless dry_weights.empty?
      span.actions.action-buttons
        = link_to t(".edit"), new_patient_hd_dry_weight_path(@patient), class: "button small slimline"
        |
        = link_to t(".view_all"), patient_hd_dry_weights_path(@patient), class: "button small slimline"

- if dry_weights.empty?
  .call-to-action
    = link_to new_patient_hd_dry_weight_path(@patient) do
      i.fa.fa-plus-circle
      =t(".add_dry_weight")
- else

  table.auto-layout
    thead
      th.col-width-date= t(".date")
      th.col-width-small= t(".weight")
      th= t(".assessor")
    tbody
      - dry_weights.each do |dry_weight|
        = render "renalware/hd/dry_weights/row", dry_weight: dry_weight

Fix layout issue in dryweights fieldset in HD Summary


- content_for(:title, "Bourbon Documentation | #{version}")
- content_for(:preferred_path, "docs/#{version}")

section
  .container
    ul
      - versions.each do |version|
        li
          = link_to version, "/docs/#{version}"
    nav
      ol
        - version.doc_items.each do |item|
          li
            = link_to "##{item.context.name}" do
              code
                = item.context.name

    - version.doc_items.each do |item|
      article.doc-item id="#{item.context.name}"
        = partial "partials/doc_item_header", locals: { item: item }
        - if item.parameter.present?
          = partial "partials/doc_item_arguments", locals: { item: item }
        - if item.example.present?
          = partial "partials/doc_item_example", locals: { item: item }

Remove versions nav for now

- content_for(:title, "Bourbon Documentation | #{version}")
- content_for(:preferred_path, "docs/#{version}")

section
  .container
    nav
      ol
        - version.doc_items.each do |item|
          li
            = link_to "##{item.context.name}" do
              code
                = item.context.name

    - version.doc_items.each do |item|
      article.doc-item id="#{item.context.name}"
        = partial "partials/doc_item_header", locals: { item: item }
        - if item.parameter.present?
          = partial "partials/doc_item_arguments", locals: { item: item }
        - if item.example.present?
          = partial "partials/doc_item_example", locals: { item: item }


.comable-page
  .comable-page-heading
    ul.pull-right.list-inline
      li
        = link_to Comable.t('admin.actions.new'), comable.new_admin_tracker_path, class: 'btn btn-default'

    h1.page-header
      = Comable.t('admin.nav.tracker')
      small<
        | #{@trackers.total_count} #{Comable.t('admin.results')}

  .comable-page-body
    - if @trackers.empty?
      = Comable.t('admin.not_found')
    - else
      table.table.table-striped
        thead
          th
            = @trackers.klass.human_attribute_name(:name)
          th
            = @trackers.klass.human_attribute_name(:tracker_id)
          th
            = @trackers.klass.human_attribute_name(:place)
        tbody
          - @trackers.each do |tracker|
            tr
              td
                = link_to tracker.name, comable.admin_tracker_path(tracker)
                - unless tracker.activate_flag
                  span.fa.fa-eye-slash.text-muted<
              td
                = tracker.tracker_id
              td
                = tracker.place

      .text-center
        = paginate @trackers, theme: :comable_backend

Improve the display name for the tracker place

.comable-page
  .comable-page-heading
    ul.pull-right.list-inline
      li
        = link_to Comable.t('admin.actions.new'), comable.new_admin_tracker_path, class: 'btn btn-default'

    h1.page-header
      = Comable.t('admin.nav.tracker')
      small<
        | #{@trackers.total_count} #{Comable.t('admin.results')}

  .comable-page-body
    - if @trackers.empty?
      = Comable.t('admin.not_found')
    - else
      table.table.table-striped
        thead
          th
            = @trackers.klass.human_attribute_name(:name)
          th
            = @trackers.klass.human_attribute_name(:tracker_id)
          th
            = @trackers.klass.human_attribute_name(:place)
        tbody
          - @trackers.each do |tracker|
            tr
              td
                = link_to tracker.name, comable.admin_tracker_path(tracker)
                - unless tracker.activate_flag
                  span.fa.fa-eye-slash.text-muted<
              td
                = tracker.tracker_id
              td
                = tracker.place.text

      .text-center
        = paginate @trackers, theme: :comable_backend


- add_breadcrumb :invitations
= page_header

= render partial: 'tabs'

- accepted_course_users = @course_users.each.select { |user| !user.invited? }.size
- progress = accepted_course_users * 100 / [@course_users.length, 1].max
div.progress
  div.progress-bar role='progressbar' aria-valuenow=progress aria-valuemin='0' aria-valuemax='100' style="width: #{progress}%"
    span
      = t('.progress', accepted: accepted_course_users, total: @course_users.size)

= simple_format t('.manual_acceptance')

table.table.table-striped
  thead
    th = t('common.name')
    th = t('common.email')
    th = t('.invitation_code')
    th = t('.status')
    th
  tbody
    - @course_users.each do |course_user|
      = content_tag_for(:tr, course_user)
        th = course_user.name
        td = course_user.invitation.user_email.email
        td = course_user.invitation.invitation_key
        td = course_user.invited? ? t('course.users.status.invited') : t('course.users.status.accepted')
        td

Use display_progress_bar for existing course registration progress

- add_breadcrumb :invitations
= page_header

= render partial: 'tabs'

- accepted_course_users = @course_users.each.select { |user| !user.invited? }.size
- progress = accepted_course_users * 100 / [@course_users.length, 1].max
= display_progress_bar progress, [] do
  = t('.progress', accepted: accepted_course_users, total: @course_users.size)

= simple_format t('.manual_acceptance')

table.table.table-striped
  thead
    th = t('common.name')
    th = t('common.email')
    th = t('.invitation_code')
    th = t('.status')
    th
  tbody
    - @course_users.each do |course_user|
      = content_tag_for(:tr, course_user)
        th = course_user.name
        td = course_user.invitation.user_email.email
        td = course_user.invitation.invitation_key
        td = course_user.invited? ? t('course.users.status.invited') : t('course.users.status.accepted')
        td


.bg-inverse
  .container
    nav.navbar.navbar-toggleable-md.navbar-inverse.bg-inverse.mb-4
      button.navbar-toggler.navbar-toggler-right aria-controls="navbarCollapse" aria-expanded="false" aria-label=("Toggle navigation") data-target="#navbarCollapse" data-toggle="collapse" type="button"
        span.navbar-toggler-icon
      a.navbar-brand href="/"
        = ENV["SITE_NAME"] || "Corporate Tool"
      #navbarCollapse.collapse.navbar-collapse
        ul.navbar-nav.mr-auto
          li.nav-item class=active_if("welcome")
            a.nav-link href=root_path
              | Home
          li.nav-item class=active_if("pages/new")
            a.nav-link href=new_page_path New Page
          li.nav-item class=active_if("gists/new")
            a.nav-link href=new_gist_path New Gist
        ul.navbar-nav.pull-right
          li.nav-item
            a.dropdown-item href=signout_path
          li.nav-item.dropdown
            a#dropdown02.nav-link  aria-expanded="false" aria-haspopup="true" data-toggle="dropdown" href=signout_path
              img.avatar title="Signed in as #{current_user.name}" src=avatar_path(current_user)
            .dropdown-menu aria-labelledby="dropdown02"
              a.dropdown-item href=signout_path Sign Out
              a.dropdown-item href=profile_path Profile

Remove redundant (and hidden) signout link

.bg-inverse
  .container
    nav.navbar.navbar-toggleable-md.navbar-inverse.bg-inverse.mb-4
      button.navbar-toggler.navbar-toggler-right aria-controls="navbarCollapse" aria-expanded="false" aria-label=("Toggle navigation") data-target="#navbarCollapse" data-toggle="collapse" type="button"
        span.navbar-toggler-icon
      a.navbar-brand href="/"
        = ENV["SITE_NAME"] || "Corporate Tool"
      #navbarCollapse.collapse.navbar-collapse
        ul.navbar-nav.mr-auto
          li.nav-item class=active_if("welcome")
            a.nav-link href=root_path
              | Home
          li.nav-item class=active_if("pages/new")
            a.nav-link href=new_page_path New Page
          li.nav-item class=active_if("gists/new")
            a.nav-link href=new_gist_path New Gist
        ul.navbar-nav.pull-right
          li.nav-item.dropdown
            a#dropdown02.nav-link  aria-expanded="false" aria-haspopup="true" data-toggle="dropdown" href=signout_path
              img.avatar title="Signed in as #{current_user.name}" src=avatar_path(current_user)
            .dropdown-menu aria-labelledby="dropdown02"
              a.dropdown-item href=signout_path Sign Out
              a.dropdown-item href=profile_path Profile


doctype html
html
  head
    title Nochat
    = stylesheet_link_tag "application", media: "all"
    = javascript_include_tag "application"
    = csrf_meta_tags
  body
    header
      - flash.each do |name, msg|
        = content_tag :div, msg, class: "flash_#{name}"
    = yield

Add sign in and out links

doctype html
html
  head
    title Nochat
    = stylesheet_link_tag "application", media: "all"
    = javascript_include_tag "application"
    = csrf_meta_tags
  body
    header
      - if user_signed_in?
        = link_to('Sign out', destroy_user_session_path, method: :delete)
      - else
        = link_to('Sign in', new_user_session_path)

      - flash.each do |name, msg|
        = content_tag :div, msg, class: "flash_#{name}"
    = yield


- content_for(:title) { "#{@word.title}" }

.markdown
  .page-header
    h1 = @word.title
  .row
    .col-md-9.col-xs12
      = raw markdown(add_word_link(@word.body))
    .col-md-3.col-xs12
      = raw toc(@word.body)
      = link_to('Edit', edit_word_path(@word), class: 'btn btn-default') if user_signed_in?

- if has_version?(@word)
  ul.pull-right.pagination.versions-nav
    li = link_to 0, word_path(@word)
    - @word.versions.each do |v|
      li = link_to (v.index + 1), word_version_path(@word, v)

Hide TOC at small device

- content_for(:title) { "#{@word.title}" }

.markdown
  .page-header
    h1 = @word.title
  .row
    .col-md-9.col-xs12
      = raw markdown(add_word_link(@word.body))
    .col-md-3.col-xs12
      .hidden-xs.hidden-sm
        = raw toc(@word.body)
      = link_to('Edit', edit_word_path(@word), class: 'btn btn-default') if user_signed_in?

- if has_version?(@word)
  ul.pull-right.pagination.versions-nav
    li = link_to 0, word_path(@word)
    - @word.versions.each do |v|
      li = link_to (v.index + 1), word_version_path(@word, v)


= page_header
- if current_course_user&.my_students&.any?
  ul.nav.nav-tabs.tab-header role="tab-list"
    li role="presentation"
      a href="#my-students" aria-controls="my-students" role="tab" data-toggle="tab"
        = t('.my_students_tab')
    li role="presentation"
      a href="#all-students" aria-controls="all-students" role="tab" data-toggle="tab"
        = t('.all_students_tab')

  div.tab-content
    div.tab-pane.fade role="tabpanel" id="my-students"
      = render 'table', students: current_course_user.my_students
    div.tab-pane.fade role="tabpanel" id="all-students"
      = render 'course_student_statistics', students: @students, phantom_students: @phantom_students
- else
  = render 'course_student_statistics', students: @students, phantom_students: @phantom_students

Fix student statistics for my students

= page_header
- if current_course_user&.my_students&.any?
  ul.nav.nav-tabs.tab-header role="tab-list"
    li role="presentation"
      a href="#my-students" aria-controls="my-students" role="tab" data-toggle="tab"
        = t('.my_students_tab')
    li role="presentation"
      a href="#all-students" aria-controls="all-students" role="tab" data-toggle="tab"
        = t('.all_students_tab')

  div.tab-content
    div.tab-pane.fade role="tabpanel" id="my-students"
      = render 'course_student_statistics',
               students: @students & current_course_user.my_students,
               phantom_students: @phantom_students & current_course_user.my_students
    div.tab-pane.fade role="tabpanel" id="all-students"
      = render 'course_student_statistics',
               students: @students,
               phantom_students: @phantom_students
- else
  = render 'course_student_statistics', students: @students, phantom_students: @phantom_students


- provide(:page_content_class, "multi-page page-landing")

.article-related-positioning-container
  header.page-header.group
    div
      h1
        ' Sign-up complete

  .article-container.group
    article.group role="article"
      .inner
        header
          h1 You now have a Queen’s Awards for Enterprise account.

        p
          ' To proceed, you first need to confirm your email address by clicking the link in the email we’ve sent you. If you can’t find the confirmation email, check your junk folder too.

        p
          = link_to "After confirming your email address, Sign in your account.", new_user_session_path

COPY Post sign up page

- provide(:page_content_class, "multi-page page-landing")

.article-related-positioning-container
  header.page-header.group
    div
      h1
        ' Sign-up complete

  .article-container.group
    article.group role="article"
      .inner
        header
          h1 You now have a Queen’s Awards for Enterprise account.

        p
          ' To proceed, go to your email account and click the link in the email we’ve just sent you. If you can’t find the confirmation email, check your junk folder too.

        p
          = link_to "After confirming your email address, Sign in your account.", new_user_session_path


h1 Homepage
table border="1"
  thead
    tr
      th Title
      th Type
      th Content
      th Author
      th Published At
      th Tags
  tbody
    - @literature.each do |literature|
      tr
        td = link_to literature.title, literature
        td = literature.type
        td = truncate literature.content
        td = literature.author_name
        td = literature.published_at
        td = render literature.tags

Add link to author in literature index.

h1 Homepage
table border="1"
  thead
    tr
      th Title
      th Type
      th Content
      th Author
      th Published At
      th Tags
  tbody
    - @literature.each do |literature|
      tr
        td = link_to literature.title, literature
        td = literature.type
        td = truncate literature.content
        td = link_to literature.author_name, literature.author
        td = literature.published_at
        td = render literature.tags


table(cellpadding="0" cellspacing="0" border="0" width="100%")
  tr
    td
      h1(style="font-size:28px;margin-top:20px;margin-bottom:10px") Daily botnbot budget report
      ul
        - @context.budgets.each do |budget|
          li
            = "#{budget.page}/#{budget.label} (budget: #{budget.budget}) was"
            - if budget.news == "bad"
              span(style="color:green") = budget.before_value
              = "and is now"
              span(style="color:red") = budget.value
            - else
              span(style="color:red") = budget.before_value
              = "and is now"
              span(style="color:green") = budget.value
            - if budget.delta > 0
              = "(#{budget.delta}% increase)."
            - else
              = "(#{-budget.delta}% decrease)."

Fix : add spacing between values

table(cellpadding="0" cellspacing="0" border="0" width="100%")
  tr
    td
      h1(style="font-size:28px;margin-top:20px;margin-bottom:10px") Daily botnbot budget report
      ul
        - @context.budgets.each do |budget|
          li
            = "#{budget.page}/#{budget.label} (budget: #{budget.budget}) was "
            - if budget.news == "bad"
              span(style="color:green") = budget.before_value
              = " and is now "
              span(style="color:red") = budget.value
            - else
              span(style="color:red") = budget.before_value
              = " and is now "
              span(style="color:green") = budget.value
            - if budget.delta > 0
              = " (#{budget.delta}% increase)."
            - else
              = " (#{-budget.delta}% decrease)."


.row
  .col-md-4.col-md-offset-4
    h3 Войти

    = form_for(resource, as: resource_name, url: session_path(resource_name)) do |f|
      = f.email_field :email, :autofocus => true, :class => 'form-control', :placeholder => 'Email'

      br

      = f.password_field :password, :autocomplete => 'off', :class => 'form-control', :placeholder => 'Пароль'

      br

      .checkbox
        label
          | Запомнить меня

          = f.check_box :remember_me

      div
        = f.submit 'Войти', :class => 'btn btn-success'

        .pull-right = link_to 'Забыли ваш пароль?', new_password_path(resource_name), :class => 'btn btn-default'

Fix sign in form markup

.row
  .col-md-4.col-md-offset-4
    h3 Войти

    = form_for(resource, as: resource_name, url: session_path(resource_name)) do |f|
      = f.email_field :email, :autofocus => true, :class => 'form-control', :placeholder => 'Email'

      br

      = f.password_field :password, :autocomplete => 'off', :class => 'form-control', :placeholder => 'Пароль'

      br

      .checkbox
        label
          = f.check_box :remember_me

          | Запомнить меня

      div
        = f.submit 'Войти', :class => 'btn btn-success'

        .pull-right = link_to 'Забыли ваш пароль?', new_password_path(resource_name), :class => 'btn btn-default'


h1 Conference Calendar
p#loadingMessage Loading the calendar please wait...
div#calendarContainer

Add View as List link to Calendar

h1 Conference Calendar
p#loadingMessage Loading the calendar please wait...
p = link_to "View as list", conferences_path
br
div#calendarContainer


- post = @object
- annotation = post.topic.actable
- answer = annotation.file.answer
- assessment = answer.question.assessment
- question = answer.question
- course = answer.course
- host = course.instance.host

- message.subject = t('.subject', course: course.title, topic: "#{assessment.title}: #{question.display_title}")
- step = assessment.questions.index(question) + 1

= simple_format(t('.message',
                  topic: link_to("#{assessment.title}: #{answer.question.display_title}",
                                  edit_course_assessment_submission_url(course, assessment, answer.submission,
                                                                        step: step, host: host)),
                                  post: post.text,
                                  post_author: post.creator.name))

Fix bug where course could not be obtained from programming answer

- post = @object
- annotation = post.topic.actable
- answer = annotation.file.answer
- assessment = answer.question.assessment
- question = answer.question
- course = assessment.course
- host = course.instance.host

- message.subject = t('.subject', course: course.title, topic: "#{assessment.title}: #{question.display_title}")
- step = assessment.questions.index(question) + 1

= simple_format(t('.message',
                  topic: link_to("#{assessment.title}: #{answer.question.display_title}",
                                  edit_course_assessment_submission_url(course, assessment, answer.submission,
                                                                        step: step, host: host)),
                                  post: post.text,
                                  post_author: post.creator.name))


= render layout: "layout", locals: { user: user, title: "User Dashboard" } do
  h4 Dashboard Content Coming soon

Add username to dashboard title

= render layout: "layout", locals: { user: user, title: "#{user.username}'s Dashboard" } do
  h4 Dashboard Content Coming soon


- if current_user.nil?
  - content_for(:head) do
    sass:
      nav, .breadcrumb, #alerts, #footer
       visibility: hidden
      #carbonads-holder
        display: none
= render template: 'layouts/application'
- if current_user.nil?
  footer.fixed-bottom.text-secondary.ml-auto.mr-0 style='text-align: right'
    => icon('fas', 'envelope')
    a> href='mailto:hi@splits.io' hi@splits.io
    ' /
    => icon('fab', 'twitter')
    a> href='https://twitter.com/splitsio' @splitsio

Fix nav hiding while logged out & not on homepage

- if current_user.nil? && action_name == 'index'
  - content_for(:head) do
    sass:
      nav, .breadcrumb, #alerts, #footer
       visibility: hidden
      #carbonads-holder
        display: none
= render template: 'layouts/application'
- if current_user.nil? && action_name == 'index'
  footer.fixed-bottom.text-secondary.ml-auto.mr-0 style='text-align: right'
    => icon('fas', 'envelope')
    a> href='mailto:hi@splits.io' hi@splits.io
    ' /
    => icon('fab', 'twitter')
    a> href='https://twitter.com/splitsio' @splitsio