diff --git a/packages/ui/src/DateRanger/Ranger.tsx b/packages/ui/src/DateRanger/Ranger.tsx index efe3184ff..546034c2c 100644 --- a/packages/ui/src/DateRanger/Ranger.tsx +++ b/packages/ui/src/DateRanger/Ranger.tsx @@ -350,7 +350,11 @@ const Ranger = React.forwardRef((props: DateRangerProps, ref) => { style={rest.style} > -
+
{ > {/* @ts-ignore */} { style={{ paddingInline: 8, borderInlineStart: 0, - borderRadius: 0, + borderTopLeftRadius: 0, + borderBottomLeftRadius: 0, }} onMouseEnter={() => setBackRadioFocused(true)} onMouseLeave={() => setBackRadioFocused(false)} @@ -526,7 +531,12 @@ const Ranger = React.forwardRef((props: DateRangerProps, ref) => { > { if (startTime && endTime) { diff --git a/packages/ui/src/DateRanger/demo/updateCurrentTime.tsx b/packages/ui/src/DateRanger/demo/updateCurrentTime.tsx index 7ba807c61..8dabdc190 100644 --- a/packages/ui/src/DateRanger/demo/updateCurrentTime.tsx +++ b/packages/ui/src/DateRanger/demo/updateCurrentTime.tsx @@ -10,6 +10,7 @@ type TimeRangeRef = { export default () => { const ref = useRef(); const [timeRange, setTimeRange] = useState([]); + const format = 'YYYY-MM-DD HH:mm:ss'; return (
@@ -19,17 +20,14 @@ export default () => { ref.current.updateCurrentTime(); }} > - 更新最新时间 + 从外部更新时间 {timeRange.length && ( - {`${dayjs(timeRange[0]).format('YYYY-MM-DD HH:mm:ss')} ~ ${dayjs(timeRange[1]).format( - 'YYYY-MM-DD HH:mm:ss' - )}`} + {`${dayjs(timeRange[0]).format(format)} ~ ${dayjs(timeRange[1]).format(format)}`} )} - - + ## API