Sha256: 2feb84f62b69610e06ffd6bd6f425266ed7a9652052e2c765c51b4a41f0d93e2

Contents?: true

Size: 1.4 KB

Versions: 405

Compression:

Stored size: 1.4 KB

Contents

<%= content_tag(:div,
    id: object.id,
    data: object.data,
    class: object.classname) do %>
  <%
    # convert deprecated prop values
    size = object.size
    size = "sm" if object.size == "xs"
    size = "md" if object.size == "lg"
  %>
  <% if size == "md" %>
    <% if object.show_icon %>
      <%= pb_rails("body", props: { color: "light", tag: "span"}) do %>
        <%= pb_rails("icon", props: { icon: "clock", fixed_width: true }) %>
      <% end %>
    <% end %>
    <%= pb_rails("body", props: { tag: "span", text: object.format_time_string, classname: "pb_time" }) %>
    <% if object.show_timezone %>
      <%= pb_rails("body", props: { color: "light", tag: "span", text: object.pb_date_time.to_timezone.upcase }) %>
    <% end %>
  <% else %>
    <% if object.show_icon %>
      <%= pb_rails("body", props: { color: "light", tag: "span"}) do %>
        <%= pb_rails("icon", props: { icon: "clock", fixed_width: true, size: "sm" }) %>
      <% end %>
    <% end %>
    
    <%= pb_rails("caption", props: { color: "light", tag: "span", text: object.format_time_string }) do %>
      <%= content_tag(:time, datetime: object.pb_date_time.to_iso) do %>
        <%= object.format_time_string %>
        <% if object.show_timezone %>
          <span class="pb_time_timezone">
            <%= object.pb_date_time.to_timezone.upcase %>
          </span>
        <% end %>
      <% end %>
    <% end %>
  <% end %>
<% end %>

Version data entries

405 entries across 405 versions & 1 rubygems

Version Path
playbook_ui-12.24.0.pre.alpha.play824753 app/pb_kits/playbook/pb_time/time.html.erb
playbook_ui-12.24.0.pre.alpha.PLAY603datepickerquickpickinputpresetdropdown752 app/pb_kits/playbook/pb_time/time.html.erb
playbook_ui-12.24.0.pre.alpha.play824751 app/pb_kits/playbook/pb_time/time.html.erb
playbook_ui-12.24.0.pre.alpha.railsmultilevelimprovements749 app/pb_kits/playbook/pb_time/time.html.erb
playbook_ui-12.24.0.pre.alpha.play824745 app/pb_kits/playbook/pb_time/time.html.erb
playbook_ui-12.24.0.pre.alpha.railsmultilevelimprovements742 app/pb_kits/playbook/pb_time/time.html.erb
playbook_ui-12.24.0.pre.alpha.railsmultilevelimprovements741 app/pb_kits/playbook/pb_time/time.html.erb
playbook_ui-12.24.0.pre.alpha.railsmultilevelimprovements739 app/pb_kits/playbook/pb_time/time.html.erb
playbook_ui-12.24.0.pre.alpha.play824733 app/pb_kits/playbook/pb_time/time.html.erb
playbook_ui-12.24.0.pre.alpha.play833boldoptionfortitle2and3721 app/pb_kits/playbook/pb_time/time.html.erb
playbook_ui-12.24.0.pre.alpha.alphatestforselfhostfak720 app/pb_kits/playbook/pb_time/time.html.erb
playbook_ui-12.24.0.pre.alpha.play833boldoptionfortitle2and3719 app/pb_kits/playbook/pb_time/time.html.erb
playbook_ui-12.24.0.pre.alpha.play833boldoptionfortitle2and3717 app/pb_kits/playbook/pb_time/time.html.erb
playbook_ui-12.24.0 app/pb_kits/playbook/pb_time/time.html.erb
playbook_ui-12.23.0.pre.alpha.movemarkdown712 app/pb_kits/playbook/pb_time/time.html.erb
playbook_ui-12.23.0.pre.alpha.movemarkdown708 app/pb_kits/playbook/pb_time/time.html.erb
playbook_ui-12.23.0.pre.alpha.play698responsivespacingglobalprop703 app/pb_kits/playbook/pb_time/time.html.erb
playbook_ui-12.23.0.pre.alpha.play698responsivespacingglobalprop701 app/pb_kits/playbook/pb_time/time.html.erb
playbook_ui-12.23.0 app/pb_kits/playbook/pb_time/time.html.erb
playbook_ui-12.22.0.pre.alpha.PLAY603datepickerquickpickinputpresetdropdown696 app/pb_kits/playbook/pb_time/time.html.erb