@transferwise/components 0.0.0-experimental-fdcd4f0 → 0.0.0-experimental-d05391d

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +1 @@
1
- .tw-stepper{padding-bottom:24px;width:100%}@media only screen and (max-width:575px){.tw-stepper{padding-bottom:0}}.tw-stepper__step{list-style-type:none;position:absolute;top:0}.tw-stepper__step--active .tw-stepper__step-label{color:#37517e;color:var(--color-content-primary);cursor:default;font-weight:600}.np-theme-personal .tw-stepper__step--active~li:not(.tw-stepper__step--has-tooltip:hover) .tw-stepper__step-label:not(:active,:focus){opacity:.45}.tw-stepper__step--clickable .tw-stepper__step-label{border-radius:2px;color:#0097c7;color:var(--color-content-accent);line-height:0;transition:color .15s ease-in-out}.np-theme-personal .tw-stepper__step--clickable .tw-stepper__step-label{color:#5d7079;color:var(--color-content-secondary);top:0}.tw-stepper__step--has-tooltip:hover{cursor:pointer}@media screen and (min-width:576px) and (max-width:991px){.tw-stepper__step:first-child .tooltip-inner{transform:translateX(calc(50% - 32px))}.tw-stepper__step:last-child .tooltip-inner{transform:translateX(calc(-50% + 32px))}}.tw-stepper__step-label{color:#5d7079;color:var(--color-content-secondary);font-weight:600;font-weight:var(--font-weight-semi-bold);position:absolute;top:0;transform:translateX(-50%);transition:color .6s ease-in-out;white-space:nowrap}[dir=rtl] .tw-stepper__step-label{transform:translateX(50%)}.tw-stepper .tooltip{top:24px!important;white-space:nowrap}.tw-stepper .tooltip .tooltip-inner{max-width:100%}.tw-stepper .tw-tooltip-container{display:block}.tw-stepper-steps{padding:0;position:relative}[dir=rtl] .tw-stepper-steps{padding:0}.progress-bar{-webkit-backface-visibility:hidden;background-color:var(--color-interactive-primary);border-bottom-left-radius:1px;border-top-left-radius:1px;float:left;height:100%;transition:width .6s ease-in-out;will-change:width}[dir=rtl] .progress-bar{float:right}.progress-bar:after{border-radius:4px;content:"";float:right;height:8px;margin-right:-4px;margin-top:-3px;width:8px}[dir=rtl] .progress-bar:after{float:left;margin-left:-4px;margin-right:0}.btn-unstyled{background:none;border:none;display:block;margin:0;padding:0}
1
+ .tw-stepper{padding-bottom:24px;width:100%}@media only screen and (max-width:575px){.tw-stepper{padding-bottom:0}}.tw-stepper__step{list-style-type:none;position:absolute;top:0}.tw-stepper__step--active .tw-stepper__step-label{color:#37517e;color:var(--color-content-primary);cursor:default}.tw-stepper__step--clickable .tw-stepper__step-label{border-radius:2px;color:#0097c7;color:var(--color-content-accent);line-height:0;transition:color .15s ease-in-out}.np-theme-personal .tw-stepper__step--clickable .tw-stepper__step-label{color:#5d7079;color:var(--color-content-secondary);top:0}.tw-stepper__step--has-tooltip{cursor:pointer}@media screen and (min-width:576px) and (max-width:991px){.tw-stepper__step:first-child .tooltip-inner{transform:translateX(calc(50% - 32px))}.tw-stepper__step:last-child .tooltip-inner{transform:translateX(calc(-50% + 32px))}}.tw-stepper__step-label{color:#5d7079;color:var(--color-content-secondary);position:absolute;top:0;transform:translateX(-50%);transition:color .6s ease-in-out;white-space:nowrap}[dir=rtl] .tw-stepper__step-label{transform:translateX(50%)}.tw-stepper .tooltip{top:24px!important;white-space:nowrap}.tw-stepper .tooltip .tooltip-inner{max-width:100%}.tw-stepper .tw-tooltip-container{display:block}.tw-stepper-steps{padding:0;position:relative}[dir=rtl] .tw-stepper-steps{padding:0}.progress-bar{-webkit-backface-visibility:hidden;background-color:var(--color-interactive-primary);border-bottom-left-radius:1px;border-top-left-radius:1px;float:left;height:100%;transition:width .6s ease-in-out;will-change:width}[dir=rtl] .progress-bar{float:right}.progress-bar:after{border-radius:4px;content:"";float:right;height:8px;margin-right:-4px;margin-top:-3px;width:8px}[dir=rtl] .progress-bar:after{float:left;margin-left:-4px;margin-right:0}.btn-unstyled{background:none;border:none;display:block;margin:0;padding:0}
@@ -19,13 +19,6 @@
19
19
  .tw-stepper__step-label {
20
20
  cursor: default;
21
21
  color: var(--color-content-primary);
22
- font-weight: 600;
23
- }
24
-
25
- .np-theme-personal & ~ li:not(.tw-stepper__step--has-tooltip:hover) {
26
- .tw-stepper__step-label:not(:active,:focus) {
27
- opacity: 0.45;
28
- }
29
22
  }
30
23
  }
31
24
 
@@ -41,7 +34,7 @@
41
34
  }
42
35
  }
43
36
 
44
- &--has-tooltip:hover {
37
+ &--has-tooltip {
45
38
  cursor: pointer;
46
39
  }
47
40
 
@@ -62,7 +55,6 @@
62
55
  color: var(--color-content-secondary);
63
56
  transition: color 0.6s ease-in-out;
64
57
  white-space: nowrap;
65
- font-weight: var(--font-weight-semi-bold);
66
58
  .translateX(-50%);
67
59
  }
68
60
 
@@ -1,6 +1,6 @@
1
1
  import { shallow } from 'enzyme';
2
2
 
3
- import { Tooltip, Body } from '..';
3
+ import { Tooltip } from '..';
4
4
 
5
5
  import Stepper from './Stepper';
6
6
 
@@ -57,7 +57,7 @@ describe('Stepper', () => {
57
57
  steps(5);
58
58
  [0, 1, 2, 3, 4].forEach((label, index) => {
59
59
  expect(
60
- component.find('.tw-stepper__step').at(index).find(Body).props().children,
60
+ component.find('.tw-stepper__step').at(index).find('span').props().children,
61
61
  ).toStrictEqual(`${label}`);
62
62
  });
63
63
  });
@@ -173,7 +173,7 @@ describe('Stepper', () => {
173
173
  const firstStepHoverLabel = step(0).children();
174
174
  expect(firstStepHoverLabel.type()).toBe(Tooltip);
175
175
  expect(firstStepHoverLabel.children().render().text()).toStrictEqual('label');
176
- expect(step(1).find(Body).props().children).toStrictEqual('label 2');
176
+ expect(step(1).find('span').props().children).toStrictEqual('label 2');
177
177
  });
178
178
 
179
179
  it('renders jsx', () => {
@@ -203,7 +203,7 @@ describe('Stepper', () => {
203
203
  steps: [{ hoverLabel: 'hover', label: 'label' }, { label: 'label 2' }],
204
204
  });
205
205
  const firstStepHoverLabel = step(0).children();
206
- expect(firstStepHoverLabel.type()).toBe(Body);
206
+ expect(firstStepHoverLabel.type()).toBe('span');
207
207
  expect(firstStepHoverLabel.props().children).toStrictEqual('label');
208
208
  expect(step(1).children().props().children).toStrictEqual('label 2');
209
209
  });
@@ -1,7 +1,6 @@
1
1
  import classNames from 'classnames';
2
2
  import * as React from 'react';
3
3
 
4
- import Body from '../body/Body';
5
4
  import { Position } from '../common';
6
5
  import { useDirection } from '../common/hooks';
7
6
  import Tooltip from '../tooltip';
@@ -49,9 +48,7 @@ const Stepper = ({ steps, activeStep = 0, className }: StepperProps) => {
49
48
  <small>{step.label}</small>
50
49
  </button>
51
50
  ) : (
52
- <Body as="span" className="tw-stepper__step-label small">
53
- {step.label}
54
- </Body>
51
+ <span className="tw-stepper__step-label">{step.label}</span>
55
52
  );
56
53
  return (
57
54
  <li
@@ -59,7 +56,7 @@ const Stepper = ({ steps, activeStep = 0, className }: StepperProps) => {
59
56
  className={classNames(
60
57
  'hidden-xs',
61
58
  'tw-stepper__step',
62
- active && 'tw-stepper__step--active',
59
+ active ? 'np-text-body-default-bold tw-stepper__step--active' : 'np-text-body-default',
63
60
  clickable && 'tw-stepper__step--clickable',
64
61
  step.hoverLabel && 'tw-stepper__step--has-tooltip',
65
62
  )}