From 4013af71d71dd601170edfa36ba42953626459ed Mon Sep 17 00:00:00 2001 From: john <johnbarlas39@gmail.com> Date: Thu, 12 Jan 2017 13:31:24 +0200 Subject: [PATCH] fix track changes tool names and labels --- .../elements/track_change/TrackChangeControlTool.js | 4 +--- .../elements/track_change/TrackChangePackage.js | 11 +++++++---- 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/app/components/SimpleEditor/elements/track_change/TrackChangeControlTool.js b/app/components/SimpleEditor/elements/track_change/TrackChangeControlTool.js index b594f52..f9c9d23 100644 --- a/app/components/SimpleEditor/elements/track_change/TrackChangeControlTool.js +++ b/app/components/SimpleEditor/elements/track_change/TrackChangeControlTool.js @@ -8,7 +8,6 @@ class TrackChangeControlTool extends Tool { if (trackChangesMode === true) el.addClass('track-changes-active') if (!this.canAct()) { - console.log('deffo not') el.attr('disabled', true) } return el @@ -27,9 +26,8 @@ class TrackChangeControlTool extends Tool { } canAct () { - console.log('can act?') const provider = this.context.trackChangesProvider - console.log(provider.canAct()) + // console.log('can act?', provider.canAct()) return provider.canAct() } } diff --git a/app/components/SimpleEditor/elements/track_change/TrackChangePackage.js b/app/components/SimpleEditor/elements/track_change/TrackChangePackage.js index 1be7351..ae4eef1 100644 --- a/app/components/SimpleEditor/elements/track_change/TrackChangePackage.js +++ b/app/components/SimpleEditor/elements/track_change/TrackChangePackage.js @@ -16,11 +16,11 @@ export default { config.addConverter('html', TrackChangeHTMLConverter) // TODO -- both tools should go to the same target - config.addTool('Toggle recording changes', TrackChangeControlTool, { + config.addTool('track-change-enable', TrackChangeControlTool, { target: 'track-change-enable' }) - config.addTool('Toggle tracked changes view', TrackChangeControlViewTool, { + config.addTool('track-change-toggle-view', TrackChangeControlViewTool, { target: 'track-change-toggle-view' }) @@ -30,8 +30,11 @@ export default { config.addIcon('track-change', { 'fontawesome': 'fa-eye' }) - config.addLabel('track-change', { - en: 'Track Changes' + config.addLabel('track-change-enable', { + en: 'Toggle recording changes' + }) + config.addLabel('track-change-toggle-view', { + en: 'Toggle tracked changes view' }) } } -- GitLab