@transferwise/components 0.0.0-experimental-1319ded → 0.0.0-experimental-fcfae09

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.
@@ -5,7 +5,6 @@ export type DateLookupSize = "sm" | "md" | "lg";
5
5
  export type DateLookupMonthFormat = "long" | "short";
6
6
 
7
7
  export interface DateLookupProps {
8
- id?: string;
9
8
  value?: Date;
10
9
  min?: Date;
11
10
  max?: Date;
@@ -1 +1 @@
1
- {"version":3,"file":"DateLookup.d.ts","sourceRoot":"","sources":["../../../src/dateLookup/DateLookup.js"],"names":[],"mappings":";AAoBA;IAoBE;;;;;;aAqBC;IApCD,wBAaC;IAjBD,wCAAsB;IAEtB,yCAAuB;IAIrB;;;;;;;;;;MAUC;IA0BH,6CAMC;IAFC,uCAAyE;IAI3E,6BAGC;IAED,iBAOE;IAEF,oBAME;IAEF,kBAME;IAEF,oCA6CE;IAEF,wEAmBE;IAEF,+DAOE;IAEF,gCAIE;IAEF,yBAA+C;IAE/C,2BAAmD;IAEnD,0BAAiD;IAEjD,sDAME;IAEF;;;eAEE;IAEF,+CA8BE;IAEF,wBAGE;IAEF,sCAqCC;CACF"}
1
+ {"version":3,"file":"DateLookup.d.ts","sourceRoot":"","sources":["../../../src/dateLookup/DateLookup.js"],"names":[],"mappings":";AAoBA;IAoBE;;;;;;aAqBC;IApCD,wBAaC;IAjBD,wCAAsB;IAEtB,yCAAuB;IAIrB;;;;;;;;;;MAUC;IA0BH,6CAMC;IAFC,uCAAyE;IAI3E,6BAGC;IAED,iBAOE;IAEF,oBAME;IAEF,kBAME;IAEF,oCA6CE;IAEF,wEAmBE;IAEF,+DAOE;IAEF,gCAIE;IAEF,yBAA+C;IAE/C,2BAAmD;IAEnD,0BAAiD;IAEjD,sDAME;IAEF;;;eAEE;IAEF,+CA8BE;IAEF,wBAGE;IAEF,sCAoCC;CACF"}
@@ -1 +1 @@
1
- {"version":3,"file":"SlidingPanel.d.ts","sourceRoot":"","sources":["../../../src/slidingPanel/SlidingPanel.js"],"names":[],"mappings":"AAMA,iCAAkC;;AAElC,0GA2CE"}
1
+ {"version":3,"file":"SlidingPanel.d.ts","sourceRoot":"","sources":["../../../src/slidingPanel/SlidingPanel.js"],"names":[],"mappings":"AAMA,iCAAkC;;AAElC,0GA4CE"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@transferwise/components",
3
- "version": "0.0.0-experimental-1319ded",
3
+ "version": "0.0.0-experimental-fcfae09",
4
4
  "description": "Neptune React components",
5
5
  "license": "Apache-2.0",
6
6
  "repository": {
@@ -253,7 +253,6 @@ class DateLookup extends PureComponent {
253
253
  return (
254
254
  <div // eslint-disable-line jsx-a11y/no-static-element-interactions
255
255
  ref={this.element}
256
- id={this.props.id}
257
256
  aria-labelledby={ariaLabelledBy}
258
257
  className="input-group"
259
258
  onKeyDown={this.handleKeyDown}
@@ -278,7 +277,6 @@ class DateLookup extends PureComponent {
278
277
  }
279
278
 
280
279
  DateLookup.propTypes = {
281
- id: PropTypes.string,
282
280
  value: PropTypes.instanceOf(Date),
283
281
  min: PropTypes.instanceOf(Date),
284
282
  max: PropTypes.instanceOf(Date),
@@ -295,7 +293,6 @@ DateLookup.propTypes = {
295
293
  };
296
294
 
297
295
  DateLookup.defaultProps = {
298
- id: null,
299
296
  value: null,
300
297
  min: null,
301
298
  max: null,
@@ -25,14 +25,12 @@ export const Basic = () => {
25
25
  const monthFormat = select('monthFormat', ['long', 'short']);
26
26
  const placeholder = text('placeholder', 'placeholder');
27
27
  const size = select('size', Object.values(Size), Size.MEDIUM);
28
- const id = text('id', 'date-lookup');
29
28
 
30
29
  const clearable = boolean('clearable', false);
31
30
 
32
31
  return (
33
32
  <DateLookup
34
33
  disabled={disabled}
35
- id={id}
36
34
  label={label}
37
35
  min={thePast}
38
36
  monthFormat={monthFormat}
@@ -83,7 +81,6 @@ export const RightAligned = () => {
83
81
  </div>
84
82
  <div className="col-xs-6">
85
83
  <DateLookup
86
- id="right-aligned"
87
84
  disabled={disabled}
88
85
  label={label}
89
86
  min={new Date(minvalue)}
@@ -37,7 +37,6 @@ describe('DateLookup view', () => {
37
37
  placeholder: 'Asd..',
38
38
  label: 'Date..',
39
39
  onChange: jest.fn(),
40
- id: '123456',
41
40
  };
42
41
  component = shallow(<DateLookup {...props} />);
43
42
  });
@@ -46,10 +45,6 @@ describe('DateLookup view', () => {
46
45
  expect(dateTrigger()).toHaveLength(1);
47
46
  });
48
47
 
49
- it('passes id to the component', () => {
50
- expect(component.prop('id')).toBe('123456');
51
- });
52
-
53
48
  it('passes props forward to open button', () => {
54
49
  expect(+dateTrigger().prop('selectedDate')).toBe(+date);
55
50
  expect(dateTrigger().prop('size')).toBe('lg');
@@ -25,6 +25,7 @@ const SlidingPanel = forwardRef(
25
25
  return (
26
26
  <CSSTransition
27
27
  {...rest}
28
+ key={`sliding-panel--open-${position}`}
28
29
  nodeRef={localReference}
29
30
  in={open}
30
31
  // Wait for animation to finish before unmount.