fix: countdown remove cloneElement
parent
e249b085d2
commit
e5f0a5f7e1
|
@ -2,6 +2,7 @@ import PropTypes from '../_util/vue-types';
|
||||||
import defaultLocaleData from './default';
|
import defaultLocaleData from './default';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
name: 'LocaleReceiver',
|
||||||
props: {
|
props: {
|
||||||
componentName: PropTypes.string.def('global'),
|
componentName: PropTypes.string.def('global'),
|
||||||
defaultLocale: PropTypes.oneOfType([PropTypes.object, PropTypes.func]),
|
defaultLocale: PropTypes.oneOfType([PropTypes.object, PropTypes.func]),
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
import * as moment from 'moment';
|
import * as moment from 'moment';
|
||||||
import interopDefault from '../_util/interopDefault';
|
import interopDefault from '../_util/interopDefault';
|
||||||
import { cloneElement } from '../_util/vnode';
|
|
||||||
import { initDefaultProps, getListeners } from '../_util/props-util';
|
import { initDefaultProps, getListeners } from '../_util/props-util';
|
||||||
import Statistic, { StatisticProps } from './Statistic';
|
import Statistic, { StatisticProps } from './Statistic';
|
||||||
import { formatCountdown } from './utils';
|
import { formatCountdown } from './utils';
|
||||||
|
@ -70,13 +69,7 @@ export default {
|
||||||
return formatCountdown(value, { ...config, format });
|
return formatCountdown(value, { ...config, format });
|
||||||
},
|
},
|
||||||
|
|
||||||
// Countdown do not need display the timestamp
|
valueRenderHtml: node => node,
|
||||||
valueRenderHtml: node =>
|
|
||||||
cloneElement(node, {
|
|
||||||
props: {
|
|
||||||
title: undefined,
|
|
||||||
},
|
|
||||||
}),
|
|
||||||
},
|
},
|
||||||
|
|
||||||
render() {
|
render() {
|
||||||
|
|
Loading…
Reference in New Issue