import { Clock } from "resium";

// 起始时间
const start = Cesium.JulianDate.fromDate(new Date());
// 结束时间
const stop = Cesium.JulianDate.addSeconds(start, 60, new Cesium.JulianDate());

function CustomClock() {
  return (
    <Clock
      multiplier={1}
      shouldAnimate={false}
      startTime={start.clone()}
      stopTime={stop.clone()}
      currentTime={start.clone()}
      clockRange={Cesium.ClockRange.LOOP_STOP}
      // onTick={(clock) => {
      //   if (!clock.shouldAnimate) return;
      // }}
      // onStop={() => {
      //   if (toolbar.showPanel === undefined)
      //     dispatch.data.updateToolbar({ showPanel: true });
      // }}
    />
  );
}

export default CustomClock;
