--- a/client/src/components/SlateEditor.js Thu Jun 22 11:58:27 2017 +0200
+++ b/client/src/components/SlateEditor.js Thu Jun 22 12:09:48 2017 +0200
@@ -2,11 +2,11 @@
import React from 'react'
import Portal from 'react-portal'
import { Button } from 'react-bootstrap'
-import moment from 'moment'
import Immutable from 'immutable'
import HtmlSerializer from '../HtmlSerializer'
import AnnotationPlugin from '../AnnotationPlugin'
import CategoriesTooltip from './CategoriesTooltip'
+import { now } from '../utils';
const plugins = [];
@@ -143,12 +143,12 @@
finishedAt: null
});
} else {
- Object.assign(newState, { finishedAt: moment().format('H:mm:ss') });
+ Object.assign(newState, { finishedAt: now() });
}
// Store start time once when the first character is typed
if (!isEmpty && this.state.startedAt === null) {
- Object.assign(newState, { startedAt: moment().format('H:mm:ss') });
+ Object.assign(newState, { startedAt: now() });
}
this.setState(newState)