Variants and sizes

  • k-iconbtn: plain, no fill, for app bars, rows and toolbars.
  • k-iconbtn--tonal: a container fill for a little weight: "Edit payment".
  • k-iconbtn--ink: the strong icon action: "Add something" in a compact bar.
  • k-iconbtn--outline: a 1px outline ring: "Previous day", "Next day".
  • k-iconbtn--sm: 32px, for dense web toolbars only.
  • Toggle: any variant with aria-pressed.

States

  • Hover and pressed: the state layer at state-hover (8%) and state-pressed (12%).
  • Focus: the 2px focus-ring, 2px outside the circle.
  • Toggle on, aria-pressed="true": an ink fill, an on-ink icon, and the icon filled with k-icon--fill. The shape changes from outlined to filled, so the state is not told by colour alone. Toggle off, aria-pressed="false": the variant's rest look with an outlined icon.
  • Disabled: there is none. When the action cannot run, leave the button out, or use a Button that can say why.

Do and don’t

Do

  • Name the object: "Edit payment", not "Edit".

  • Fill the icon only when a toggle is on.

Don’t

  • Use the small size on phones.

  • Swap the icon or the name when a toggle flips.

  • Invent a symbol for an action that has none: write a Button.

What you provide

  • Icon name: search, edit, add, chevron_right, more_vert, notifications.
  • Accessible name.
  • Variant and size.
  • The press handler and, for a toggle, the pressed state.
  • On the web, the tooltip text: the name.