Improve OnboardingFlow API and typescript types

This commit is contained in:
fragosti
2018-05-24 11:24:10 -07:00
parent d057b77dc5
commit f8f8bd95ca
4 changed files with 27 additions and 14 deletions

View File

@@ -1,6 +1,6 @@
import * as _ from 'lodash';
import * as React from 'react';
import Joyride, { Step, StyleOptions } from 'react-joyride';
import Joyride, { CallbackData, Step, StyleOptions } from 'react-joyride';
import { zIndex } from 'ts/utils/style';
@@ -30,8 +30,8 @@ export class OnboardingFlow extends React.Component<OnboardingFlowProps> {
);
}
private _handleChange(options: any): void {
switch (options.action) {
private _handleChange(data: CallbackData): void {
switch (data.action) {
case 'close':
this.props.onClose();
}