Skip to content
This repository has been archived by the owner on Nov 25, 2020. It is now read-only.

Commit

Permalink
Add setting to disable the Welcome Tour. Fix #1350
Browse files Browse the repository at this point in the history
  • Loading branch information
cdujeu committed May 18, 2017
1 parent 0247df0 commit 33e1e67
Show file tree
Hide file tree
Showing 9 changed files with 17 additions and 2 deletions.
Expand Up @@ -136,6 +136,7 @@ let AltDashboard = React.createClass({
}

const guiPrefs = this.props.pydio.user ? this.props.pydio.user.getPreference('gui_preferences', true) : [];
const wTourEnabled = this.props.pydio.getPluginConfigs('gui.ajax').get('ENABLE_WELCOME_TOUR');

let mainClasses = ['vertical_layout', 'vertical_fit', 'react-fs-template', 'user-dashboard-template'];
if(this.state.drawerOpen){
Expand All @@ -145,7 +146,7 @@ let AltDashboard = React.createClass({
return (

<div className={mainClasses.join(' ')} onTouchTap={this.closeDrawer}>
{!guiPrefs['WelcomeComponent.Pydio8.TourGuide.Welcome'] && <WelcomeTour ref="welcome" pydio={this.props.pydio}/>}
{wTourEnabled && !guiPrefs['WelcomeComponent.Pydio8.TourGuide.Welcome'] && <WelcomeTour ref="welcome" pydio={this.props.pydio}/>}
<LeftPanel
className="left-panel"
pydio={pydio}
Expand Down
1 change: 1 addition & 0 deletions core/src/plugins/gui.ajax/manifest.xml
Expand Up @@ -56,6 +56,7 @@
</client_settings>
<server_settings>
<global_param name="GUI_THEME" group="CONF_MESSAGE[Main Options]" type="select" choices="material|Material" label="CONF_MESSAGE[Theme]" description="CONF_MESSAGE[Theme used for display]" mandatory="true" default="material"/>
<global_param name="ENABLE_WELCOME_TOUR" group="CONF_MESSAGE[Main Options]" type="boolean" expose="true" label="CONF_MESSAGE[Enable Welcome Tour]" description="CONF_MESSAGE[Enable the small tour triggered at first visit]" default="true"/>
<global_param name="CUSTOM_WELCOME_MESSAGE" group="CONF_MESSAGE[Login Screen]" type="string" label="CONF_MESSAGE[Welcome Message]" description="CONF_MESSAGE[An additionnal message displayed in the start up screen]" mandatory="false" default="Welcome to Pydio"/>
<global_param name="CUSTOM_ICON_ONLY" group="CONF_MESSAGE[Login Screen]" type="boolean" label="CONF_MESSAGE[Icon Only]" description="CONF_MESSAGE[Skip the title, only display an image]" mandatory="false" default="true"/>
<global_param name="CUSTOM_ICON_BINARY" group="CONF_MESSAGE[Login Screen]" type="image" label="CONF_MESSAGE[Custom Icon]" description="CONF_MESSAGE[URI to a custom image to be used as start up logo]"
Expand Down
2 changes: 2 additions & 0 deletions core/src/plugins/gui.ajax/res/i18n/conf/de.php
Expand Up @@ -113,4 +113,6 @@
"Show the palette on the interface to change the interface colors and logos. Make sure to reload the interface if you toggle this option." => "Palette anzeigen, um die Farben der Oberfläche und Logos zu ändern. Nach dem Ändern der Einstellung muss die Seite neu geladen werden.",
"Use configured branding" => "Konfiguriertes Branding verwenden",
"Override default styles and colors with the options defined in the branding tool. Make sure to reload the interface if you toggle this option." => "Die konfigurierten Farben verwenden. Nach dem Ändern der Einstellung muss die Seite neu geladen werden.",
"Enable Welcome Tour" => "Enable Welcome Tour",
"Enable the small tour triggered at first visit" => "Enable the small tour triggered at first visit",
);
2 changes: 2 additions & 0 deletions core/src/plugins/gui.ajax/res/i18n/conf/en.php
Expand Up @@ -107,4 +107,6 @@
"Show the palette on the interface to change the interface colors and logos. Make sure to reload the interface if you toggle this option." => "Show the palette on the interface to change the interface colors and logos. Make sure to reload the interface if you toggle this option.",
"Use configured branding" => "Use configured branding",
"Override default styles and colors with the options defined in the branding tool. Make sure to reload the interface if you toggle this option." => "Override default styles and colors with the options defined in the branding tool. Make sure to reload the interface if you toggle this option.",
"Enable Welcome Tour" => "Enable Welcome Tour",
"Enable the small tour triggered at first visit" => "Enable the small tour triggered at first visit",
);
2 changes: 2 additions & 0 deletions core/src/plugins/gui.ajax/res/i18n/conf/es.php
Expand Up @@ -107,4 +107,6 @@
"Show the palette on the interface to change the interface colors and logos. Make sure to reload the interface if you toggle this option." => "Muestra la paleta para cambiar los colores de la interfaz y logos. Recargar la interfaz después de activar esta opción.",
"Use configured branding" => "Usa el estilo configurado",
"Override default styles and colors with the options defined in the branding tool. Make sure to reload the interface if you toggle this option." => "Sobreescribe los estilos y colores por defecto por los definidos en la herramienta de estilo. Recargar la interfaz después de activar esta opción.",
"Enable Welcome Tour" => "Enable Welcome Tour",
"Enable the small tour triggered at first visit" => "Enable the small tour triggered at first visit",
);
2 changes: 2 additions & 0 deletions core/src/plugins/gui.ajax/res/i18n/conf/fr.php
Expand Up @@ -107,4 +107,6 @@
"Show the palette on the interface to change the interface colors and logos. Make sure to reload the interface if you toggle this option." => "Afficher la palette sur l'interface permettant de modifier les couleurs et les logos. Recharger complètement la fenêtre après changement de cette option.",
"Use configured branding" => "Utiliser le branding configuré",
"Override default styles and colors with the options defined in the branding tool. Make sure to reload the interface if you toggle this option." => "Utiliser les logos et couleurs définis et sauvés lors de l'utilisation de l'outil de branding. Recharger complètement la fenêtre après changement de cette option.",
"Enable Welcome Tour" => "Activer le guide de bienvenue",
"Enable the small tour triggered at first visit" => "Présenter un petit tour de l'interface à l'utilisateur à la première connexion.",
);
2 changes: 2 additions & 0 deletions core/src/plugins/gui.ajax/res/i18n/conf/it.php
Expand Up @@ -107,4 +107,6 @@
"Show the palette on the interface to change the interface colors and logos. Make sure to reload the interface if you toggle this option." => "Show the palette on the interface to change the interface colors and logos. Make sure to reload the interface if you toggle this option.",
"Use configured branding" => "Use configured branding",
"Override default styles and colors with the options defined in the branding tool. Make sure to reload the interface if you toggle this option." => "Override default styles and colors with the options defined in the branding tool. Make sure to reload the interface if you toggle this option.",
"Enable Welcome Tour" => "Enable Welcome Tour",
"Enable the small tour triggered at first visit" => "Enable the small tour triggered at first visit",
);
2 changes: 2 additions & 0 deletions core/src/plugins/gui.ajax/res/i18n/conf/pt.php
Expand Up @@ -107,4 +107,6 @@
"Show the palette on the interface to change the interface colors and logos. Make sure to reload the interface if you toggle this option." => "Show the palette on the interface to change the interface colors and logos. Make sure to reload the interface if you toggle this option.",
"Use configured branding" => "Use configured branding",
"Override default styles and colors with the options defined in the branding tool. Make sure to reload the interface if you toggle this option." => "Override default styles and colors with the options defined in the branding tool. Make sure to reload the interface if you toggle this option.",
"Enable Welcome Tour" => "Enable Welcome Tour",
"Enable the small tour triggered at first visit" => "Enable the small tour triggered at first visit",
);
Expand Up @@ -163,14 +163,15 @@ let FSTemplate = React.createClass({
}

const guiPrefs = this.props.pydio.user ? this.props.pydio.user.getPreference('gui_preferences', true) : [];
const wTourEnabled = this.props.pydio.getPluginConfigs('gui.ajax').get('ENABLE_WELCOME_TOUR');
const inboxWorkspace = this.props.pydio.user && this.props.pydio.user.activeRepository === 'inbox';

// Making sure we only pass the style to the parent element
const {style, ...props} = this.props

return ( connectDropTarget(
<div style={style} className={classes.join(' ')} onTouchTap={this.closeDrawer} onContextMenu={this.props.onContextMenu}>
{!guiPrefs['WelcomeComponent.Pydio8.TourGuide.FSTemplate'] && <WelcomeTour ref="welcome" pydio={this.props.pydio}/>}
{wTourEnabled && !guiPrefs['WelcomeComponent.Pydio8.TourGuide.FSTemplate'] && <WelcomeTour ref="welcome" pydio={this.props.pydio}/>}
<LeftPanel className="left-panel" pydio={props.pydio}/>
<div className="desktop-container vertical_layout vertical_fit">
<MaterialUI.Paper zDepth={1} style={styles.appBarStyle} rounded={false}>
Expand Down

0 comments on commit 33e1e67

Please sign in to comment.