+ {showToolbar && (
+
+
+
+
+ )}
- {
- _columns.map((column: PickerColumnItem, index: number) => renderColumnItem(column, index))
- }
+ {_columns.map((column: PickerColumnItem, index: number) =>
+ renderColumnItem(column, index)
+ )}
diff --git a/src/components/PickerColumn.tsx b/src/components/PickerColumn.tsx
index 9bed78799..d4a70e97c 100644
--- a/src/components/PickerColumn.tsx
+++ b/src/components/PickerColumn.tsx
@@ -33,7 +33,7 @@ export interface PickerColumnItem {
index?: number,
confirm?: boolean
) => void;
-};
+}
export interface PickerColumnProps extends PickerColumnItem, ThemeProps {}
@@ -64,7 +64,7 @@ function getElementTranslateY(element: HTMLElement | null) {
function isOptionDisabled(option: PickerOption) {
return isObject(option) && option.disabled;
}
-
+
const PickerColumn = forwardRef<{}, PickerColumnProps>((props, ref) => {
const {
visibleItemCount = 5,
@@ -132,11 +132,9 @@ const PickerColumn = forwardRef<{}, PickerColumnProps>((props, ref) => {
updateState({index});
if (emitChange && props.onChange) {
- requestAnimationFrame(
- () => {
- props.onChange?.(options[index], index, confirm);
- }
- );
+ requestAnimationFrame(() => {
+ props.onChange?.(options[index], index, confirm);
+ });
// setTimeout(() => {
// props.onChange?.(options[index], index, confirm);
// }, 0);
@@ -301,7 +299,7 @@ const PickerColumn = forwardRef<{}, PickerColumnProps>((props, ref) => {
onClickItem(index);
}
};
-
+
const childData = {
className: 'text-ellipsis',
children: text
@@ -357,23 +355,23 @@ const PickerColumn = forwardRef<{}, PickerColumnProps>((props, ref) => {
transitionProperty: state.duration ? 'all' : 'none'
};
return (
-
+ {renderOptions()}
+
+
);
});
@@ -389,4 +387,3 @@ export default themeable(
value: 'onChange'
})
);
-
diff --git a/src/components/PopUp.tsx b/src/components/PopUp.tsx
index 78ca819f7..958075df8 100644
--- a/src/components/PopUp.tsx
+++ b/src/components/PopUp.tsx
@@ -13,8 +13,7 @@ import Transition, {
ENTERING
} from 'react-transition-group/Transition';
import Portal from 'react-overlays/Portal';
-import { Icon } from './icons';
-
+import {Icon} from './icons';
export interface PopUpPorps {
className?: string;
@@ -46,12 +45,10 @@ export class PopUp extends React.PureComponent