Sha256: 5840f3389163e2c210f269b1e0837e25013a7bd69a9738aed9a84459970e37c7

Contents?: true

Size: 1.68 KB

Versions: 5

Compression:

Stored size: 1.68 KB

Contents

br
= pb_rails("vertical_nav", props: {title: "Principles", link: principles_path}) do
  - principles_active = (controller_name == 'pages' && action_name == 'principles') ? true : false
  - guides_active = (controller_name == 'guides' && action_name == 'create_kit') ? true : false
  - use_nitro_active = (controller_name == 'guides' && action_name == 'use_nitro') ? true : false
  = pb_rails("vertical_nav/item", props: { text: "Getting Started", link: principles_path, active: principles_active })
  //= pb_rails("vertical_nav/item", props: { text: "Using in Nitro", link: guides_use_in_nitro_path, active: use_nitro_active })
  = pb_rails("vertical_nav/item", props: { text: "Creating Kits", link: guides_path, active: guides_active })

br
= pb_rails("vertical_nav", props: {title: "Kits", link: kits_path}) do
  - all_active = (controller_name == 'pages' && action_name == 'kits') ? true : false
  = pb_rails("vertical_nav/item", props: { text: "All", link: kits_path, active: all_active })

  - MENU["kits"].sort.each do |link|
    - active = !@kit.nil? && @kit == link ? true : false
    = pb_rails("vertical_nav/item", props: { text: pb_title(link), link: kit_show_path(link), active: active })

br

// TODO: Clean up after merge
= pb_rails("vertical_nav", props: {title: "Tokens", link: utilities_path}) do
  - color_active = (controller_name == 'pages' && action_name == 'utilities') ? true : false
  = pb_rails("vertical_nav/item", props: { text: "Colors", link: utilities_path, active: color_active })
  - spacing_active = (controller_name == 'pages' && action_name == 'tokens') ? true : false
  = pb_rails("vertical_nav/item", props: { text: "Spacing", link: tokens_path, active: spacing_active })

br
br

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
playbook_ui-2.7.2 app/views/layouts/playbook/_sidebar.html.slim
playbook_ui-2.7.1 app/views/layouts/playbook/_sidebar.html.slim
playbook_ui-2.7.0 app/views/layouts/playbook/_sidebar.html.slim
playbook_ui-2.6.0 app/views/layouts/playbook/_sidebar.html.slim
playbook_ui-2.5.0 app/views/layouts/playbook/_sidebar.html.slim