ActionPopover bug
orzhtml opened this issue · 1 comments
orzhtml commented
ActionPopoverItem.js
第 15 行 title 类型支持 element
static propTypes = {
...TouchableOpacity.propTypes,
title: PropTypes.oneOfType([PropTypes.element, PropTypes.string, PropTypes.number]),
leftSeparator: PropTypes.bool,
rightSeparator: PropTypes.bool,
};
ActionPopoverView.js
第 18 行 title 类型只支持 string
static propTypes = {
...Overlay.PopoverView.propTypes,
items: PropTypes.arrayOf(PropTypes.shape({
title: PropTypes.string,
onPress: PropTypes.func,
})).isRequired,
};
正确应该将:
ActionPopoverView.js 第 18 行 title
修改为:
title: PropTypes.oneOfType([PropTypes.element, PropTypes.string, PropTypes.number]),
static propTypes = {
...Overlay.PopoverView.propTypes,
items: PropTypes.arrayOf(PropTypes.shape({
title: PropTypes.oneOfType([PropTypes.element, PropTypes.string, PropTypes.number]),
onPress: PropTypes.func,
})).isRequired,
};
希望作者有空就修复这个小问题