diff --git a/src/annotator/config/index.js b/src/annotator/config/index.js index 0878067854c..33e37ea5ff5 100644 --- a/src/annotator/config/index.js +++ b/src/annotator/config/index.js @@ -23,6 +23,7 @@ function configFrom(window_) { disableToolbarHighlightsBtn: settings.hostPageSetting('disableToolbarHighlightsBtn'), disableToolbarNewNoteBtn: settings.hostPageSetting('disableToolbarNewNoteBtn'), disableBucketBar: settings.hostPageSetting('disableBucketBar'), + enableCleanOnboardingTheme: settings.hostPageSetting('enableCleanOnboardingTheme'), enableExperimentalNewNoteButton: settings.hostPageSetting('enableExperimentalNewNoteButton'), enableSidebarDropShadow: settings.hostPageSetting('enableSidebarDropShadow'), theme: settings.hostPageSetting('theme'), diff --git a/src/images/icons/cursor.svg b/src/images/icons/cursor.svg new file mode 100644 index 00000000000..bd20c653a9a --- /dev/null +++ b/src/images/icons/cursor.svg @@ -0,0 +1,14 @@ + + \ No newline at end of file diff --git a/src/sidebar/components/sidebar-tutorial.js b/src/sidebar/components/sidebar-tutorial.js index 65a0659b11e..a5940819e3f 100644 --- a/src/sidebar/components/sidebar-tutorial.js +++ b/src/sidebar/components/sidebar-tutorial.js @@ -1,7 +1,9 @@ 'use strict'; // @ngInject -function SidebarTutorialController(session) { +function SidebarTutorialController(session, settings) { + this.cleanOnboardingThemeEnabled = settings.enableCleanOnboardingTheme; + this.showSidebarTutorial = function () { if (session.state.preferences) { if (session.state.preferences.show_sidebar_tutorial) { diff --git a/src/sidebar/components/svg-icon.js b/src/sidebar/components/svg-icon.js index 056adbd5db0..e9cf6f7ab46 100644 --- a/src/sidebar/components/svg-icon.js +++ b/src/sidebar/components/svg-icon.js @@ -11,6 +11,7 @@ // The list of supported icons var icons = { refresh: require('../../images/icons/refresh.svg'), + cursor: require('../../images/icons/cursor.svg'), }; // @ngInject diff --git a/src/sidebar/components/test/sidebar-tutorial-test.js b/src/sidebar/components/test/sidebar-tutorial-test.js index b42d542d4ec..3d14050b3cd 100644 --- a/src/sidebar/components/test/sidebar-tutorial-test.js +++ b/src/sidebar/components/test/sidebar-tutorial-test.js @@ -5,6 +5,8 @@ var Controller = require('../sidebar-tutorial').controller; describe('SidebarTutorialController', function () { describe('showSidebarTutorial', function () { + var settings = { enableCleanOnboardingTheme: true }; + it('returns true if show_sidebar_tutorial is true', function () { var session = { state: { @@ -13,7 +15,7 @@ describe('SidebarTutorialController', function () { }, }, }; - var controller = new Controller(session); + var controller = new Controller(session, settings); var result = controller.showSidebarTutorial(); @@ -28,7 +30,7 @@ describe('SidebarTutorialController', function () { }, }, }; - var controller = new Controller(session); + var controller = new Controller(session, settings); var result = controller.showSidebarTutorial(); @@ -37,7 +39,7 @@ describe('SidebarTutorialController', function () { it('returns false if show_sidebar_tutorial is missing', function () { var session = {state: {preferences: {}}}; - var controller = new Controller(session); + var controller = new Controller(session, settings); var result = controller.showSidebarTutorial(); @@ -46,7 +48,7 @@ describe('SidebarTutorialController', function () { it('returns false if session.state is {}', function () { var session = {state: {}}; - var controller = new Controller(session); + var controller = new Controller(session, settings); var result = controller.showSidebarTutorial(); diff --git a/src/sidebar/host-config.js b/src/sidebar/host-config.js index 5b36bcb1985..dd6c5980fa7 100644 --- a/src/sidebar/host-config.js +++ b/src/sidebar/host-config.js @@ -35,6 +35,9 @@ function hostPageConfig(window) { // This should be removed once new note button is enabled for everybody. 'enableExperimentalNewNoteButton', + // New onboarding theme override. + 'enableCleanOnboardingTheme', + // OAuth feature flag override. // This should be removed once OAuth is enabled for first party accounts. 'oauthEnabled', diff --git a/src/sidebar/templates/sidebar-tutorial.html b/src/sidebar/templates/sidebar-tutorial.html index 2f220438303..2eab78591d4 100644 --- a/src/sidebar/templates/sidebar-tutorial.html +++ b/src/sidebar/templates/sidebar-tutorial.html @@ -1,4 +1,4 @@ -