Skip to content
This repository has been archived by the owner on Apr 27, 2022. It is now read-only.

Releases: klarna/ui

Add legal variation of Link - Fix Loader in Safari

17 Oct 14:25
Compare
Choose a tag to compare

Add legal variation of Link βœ¨πŸ”—

screen shot 2016-10-17 at 14 47 04

Fix Loader in Safari

screen shot 2016-10-17 at 15 13 10

Add Tertiary Button - Make Checklist gray

14 Oct 13:43
Compare
Choose a tag to compare

Added Tertiary Button ✨

by @Nevon

(the gifs are a little messy. This is the first try :) )

Regular

tertiary

Small

tertiary-small

Big
tertiary-big

Dynamic styling

tertiary-dynamic-styling

Loading

tertiary-loading

Disabled
screen shot 2016-10-14 at 15 34 12

With price
tertiary-price

Make the Checklist gray

by @Nevon

Regular
screen shot 2016-10-14 at 15 03 44

Dynamic styled
screen shot 2016-10-14 at 15 00 39

Several small fixes

14 Oct 09:53
Compare
Choose a tag to compare

Change style of selected/hovered value in Selector.Options

13 Oct 12:22
Compare
Choose a tag to compare

An image is worth more or less 953.6423 words they say.

screen shot 2016-10-13 at 14 16 32

Fix icon button clickable area

12 Oct 13:52
Compare
Choose a tag to compare
  • Extra props passed to IconButton components are now spread in the root <div>, not in the <svg>, meaning it's possible to target the whole icon and the onClick event is captured for the whole area.
  • IconButton's className props are now also incorporated in the wrapping <div>, so className style overrides can affect the whole component.

Thanks @jonotrujillo for the fix.

Make all customizable components Themeable by default 🌈

12 Oct 11:53
Compare
Choose a tag to compare

tl;dr: you don't need the Themeable version of the component anymore, the plain component is now already themeable.


What this means is that if at any point in the React tree there is a <Theme> component with customizations, components will pick the data from the React.context and the customize themselves, either via the props accepted in the customize prop (for Button, Checklist, Dropdown, Field, Installments and Switch) or via style.

If you are using a Themeable version of a component, such as:

import * as ThemeableButton from '@klarna/ui/themeable/Button'

you should start requiring the plain version instead:

import * as Button from '@klarna/ui/Button'

Until v2, the @klarna/ui/themeable/<component> entrypoints will be kept for compatibility, but components required that way will throw a deprecation warning.

Improve template Wrapper

11 Oct 13:24
Compare
Choose a tag to compare

Add

  • Adding an onClose handler will cause the Wrapper to render the close button in the upper right corner
  • Adding an onBack handler will cause the Wrapper to render the back button in the upper left corner
  • Now any extra prop passed to the Wrapper will be spread in the <Dialog.Overlay> root component. This means that for example setting an id (<Wrapper id='hola'>) will work.
  • Wrapper also supports the className