Base

  • Colors
  • Icons
  • Logos
  • Shadows and Elevations
  • Spacing
  • Typography

Components

  • Accordion
  • Avatars
  • Badges
  • Buttons
  • Cards
  • Character Counter
  • Device Type Icons
  • Draggables
  • Dropdowns
  • Droppables
  • Expandable image
  • Filters
  • Gallery card
  • Icon Button
  • Indicators
  • Lightbox image
  • Lists
  • Loading
  • Messages
  • Pictogram
  • Poster Play
  • Progress bar
  • QR Code
  • Rating stars
  • Row Selector
  • Segmented Controls
  • Sentiment
  • Split View
  • Tables
  • Tags
  • Tester vitals
  • Toggle button
  • Typeahead

Form

  • Checkbox
  • Combobox
  • Form Rule
  • Hint
  • Input
  • Input Title
  • Label
  • Multi-select List
  • Search
  • Select
  • Single-select List
  • Sliders
  • Switch
  • Text Area

Layout

  • Containers
  • Layers
  • Layout
  • Split Layout
  • Wrappers

Navigation

  • Context Switcher
  • Nav bar
  • Navigation
  • Pagination
  • Sidebar Navigation
  • Step Navigation
  • Tabs

Overlay

  • Banners
  • Bulk Selector
  • Modals
  • Popovers
  • Toast
  • Tooltips
  • User Notifications

Patterns

  • Full Page Message
  • Question card & Group Questions Container

Visualizations

  • Data Colors

Nav bar

These components are located near the top of views and help orient customers when they arrive to new pages.

Nav Bar

Back Create reel Messages
4/5 Sessions 1 Unwatched
Expand Copy
<tk-nav-bar>
  <tk-nav-bar-body class="nav-bar__body">
    <tk-button role="link" type="outline" aria-label="Back to highlight reels" class="mr-3x">
        <tk-icon-arrow variant="line" rotate="90"></tk-icon-arrow>
        Back
    </tk-button>
    <tk-nav-bar-title nav-bar-title="Study name" slot="nav-bar-body__title" alignment="auto">
    </tk-nav-bar-title>
    <tk-nav-bar-actions position="bottom" class="nav-bar__actions">
      <tk-button>
        Create reel
      </tk-button>
    </tk-nav-bar-actions>
    <tk-nav-bar-separator></tk-nav-bar-separator>
  </tk-nav-bar-body>
  <a href="/navigation/navbar/" class="mr-md-2x nav-bar__logo">
    <tk-logo-usertesting-logomark></tk-logo-usertesting-logomark>
    <span class="sr-only">UserTesting logo</span>
  </a>
  <tk-nav-bar-control class="nav-bar__control">
    <tk-nav-bar-control-item class="mr-2x">
      <tk-dropdown avatar-type="muted" trigger-type="avatar" full-height="true" trigger-text="SB">
        <tk-dropdown-item>
          <button class="dropdown__link" type="button">
            Settings
          </button>
        </tk-dropdown-item>
        <tk-dropdown-item>
          <a class="dropdown__link" href="#">
            Messages
          </a>
        </tk-dropdown-item>
      </tk-dropdown>
    </tk-nav-bar-control-item>
  </tk-nav-bar-control>
  <tk-nav-bar-subnav class="nav-bar__subnav">
    <div class="l-flex l-v-center">
      <span class="mr-3x">4/5 Sessions</span>
      <tk-badge type="info" size="small">1 Unwatched</tk-badge>
    </div>
    <tk-tabs-container>
      <tk-tabs position="left">
        <tk-tab-button is-active="" tab-title="Tests" badge-text="5"></tk-tab-button>
        <tk-tab-button tab-title="Sessions"></tk-tab-button>
        <tk-tab-button tab-title="Metrics"></tk-tab-button>
        <tk-tab-button tab-title="Summary"></tk-tab-button>
      </tk-tabs>
    </tk-tabs-container>
  </tk-nav-bar-subnav>
</tk-nav-bar>

Description

This component is a flexible container and located near the top of views to help orient customers when they arrive at new pages. See full page examples here.

This element should have the attribute class="nav-bar__logo". If the logo is wrapped inside a link or button, you should apply the class to that element. Utility class mr-md-2x covers horizontal spacing on medium viewports. There is no need for multiple logos to accommodate responsive behavior; use a viewport-specific layout until classes instead.

This element should have the attribute class="nav-bar__control" applied to it.

The element should have the attribute class="nav-bar__body" applied to it. It should also be a direct descendant of tk-nav-bar and a parent of .nav-bar__navigation and tk-nav-bar-title.

The element should have the attribute class="nav-bar__navigation". If a button can be used, use tk-button. Slotted contents of tk-button are styled as flex items out-of-the-box, so there is no need for wrapping icon and text with class="l-flex".

The element should have the attribute slot="nav-bar-body__title". It should also be a direct descendant of .nav-bar__body.

The element should have attribute class="nav-bar__actions". It should be a direct descendant of .nav-bar__body. You can create spacing between action items by using util classes.

The element should have attribute class="nav-bar__subnav". It should be a direct descendant of tk-nav-bar.

tk-nav-bar-body

Slots

Slot Description
"nav-bar-body__title" Displays the title. Pass renamable prop optionally along with renameConfig for rename functionality

tk-nav-bar-title

Properties

Property Attribute Description Type Default
alignment alignment Displays title aligned in center "auto" | "center" 'auto'
navBarTitle nav-bar-title The text shown as the title of the nav bar. string undefined
renamable renamable Set this to render the title as a button which can be clicked to trigger renaming. boolean false
renameConfig Displays hint text if set. Set the status to apply error styling to the input and hint text. { hintText?: string; maxLength?: number; placeholder?: string; status?: "error" | "ready"; } undefined
renameVisible rename-visible Set this to true to toggle the component in its renaming state. boolean false

Events

Event Description Type
renameSubmit Emitted whenever the rename input is blurred, enter or esc is pressed. CustomEvent<any>
renameValueChanged Emitted whenever the value changes on the rename input. CustomEvent<any>

tk-nav-bar-actions

Properties

Property Attribute Description Type Default
position position "auto" | "bottom" 'bottom'