import React from 'react'; import { Duration } from 'luxon'; import styles from './time.module.css'; import { PlayerContext } from 'App/components/Session/playerContext'; import { observer } from 'mobx-react-lite'; const Time = ({ time, isCustom, format = 'm:ss', }) => (
{ Duration.fromMillis(time).toFormat(format) }
) Time.displayName = "Time"; const ReduxTime = observer(({ format, name, isCustom }) => { const { store } = React.useContext(PlayerContext) const time = store.get()[name] return