How to use the babel/constants/componentNames/ComponentNames.GALLERY function in babel

To help you get started, we’ve selected a few babel examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github Esri / storymap-crowdsource / src / app / controllers / layouts / sidePanel / SidePanelController.babel.js View on Github external
if (isMobile) {
                AppActions.showComponent(componentNames.MAP);
              } else {
                AppActions.showComponent([componentNames.MAP,componentNames.GALLERY]);
              }
            }
            break;
        }

      });
    } else if (isMobile && visibleComponents.indexOf(componentNames.MAP) >= 0 && visibleComponents.indexOf(componentNames.GALLERY) >= 0) {
      this.prevVisibleComponents = [].concat(this.visibleComponents);
      this.visibleComponents = [].concat(visibleComponents);

      this.showMap(options);
      AppActions.hideComponent(componentNames.GALLERY);
    } else if (!isMobile &&
      ((visibleComponents.indexOf(componentNames.MAP) >= 0 && visibleComponents.indexOf(componentNames.GALLERY) < 0) ||
      (visibleComponents.indexOf(componentNames.MAP) < 0 && visibleComponents.indexOf(componentNames.GALLERY) >= 0))) {
      AppActions.showComponent([componentNames.MAP,componentNames.GALLERY]);
    }

  }
github Esri / storymap-crowdsource / src / app / controllers / layouts / stacked / StackedController.babel.js View on Github external
adds.forEach((component) => {

        switch (component) {
          case componentNames.INTRO:
            this.showIntro(options);
            MapActions.selectFeature(false);
            AppActions.hideComponent([componentNames.MAP,componentNames.GALLERY,componentNames.SELECTED_SHARES]);
            break;
          case componentNames.MAP:
            this.showMap(options);
            AppActions.hideComponent([componentNames.INTRO,componentNames.GALLERY]);
            break;
          case componentNames.GALLERY:
            if (this.visibleComponents.indexOf(componentNames.CONTRIBUTE) < 0) {
              this.showGallery(options);
              AppActions.hideComponent([componentNames.INTRO,componentNames.MAP]);
            } else {
              AppActions.hideComponent(componentNames.GALLERY);
            }
            break;
        }

      });
github Esri / storymap-crowdsource / src / app / components / crowdsource / builder / Builder.babel.js View on Github external
render() {
    const builderClasses = Helper.classnames('crowdsource-builder');

    return (
      <div>
        { this.props.loading.data ?  0 }
          saving={this.props.saving}
          displayReviewDropdown={this.props.visibleComponents.indexOf(componentNames.MAP) &gt;= 0 || this.props.visibleComponents.indexOf(componentNames.GALLERY) &gt;= 0}
          reviewSelection={this.props.review.selection}
          changeReviewSelection={this.props.changeReviewableSelection}
          settingsAction={this.props.toggleComponent.bind(this,componentNames.SIDE_PANEL_SETTINGS)}
          shareAction={this.props.showComponent.bind(this,componentNames.APP_SHARING)}
          helpAction={this.props.toggleComponent.bind(this,componentNames.SIDE_PANEL_HELP)} /&gt;
        : null }
        
          { this.props.activeDialog === 'layoutScratch' ? this.getSettingsModal('layout') : null }
          { this.props.activeDialog === 'betaMessage' ? this.getSettingsModal('betaMessage') : null }
          { this.props.activeDialog === 'itemNameScratch' ? this.getSettingsModal('itemNames') : null }
          { this.props.activeDialog === 'savingFromScratch' ?  : null }
        </div>
github Esri / storymap-crowdsource / src / app / controllers / layouts / sidePanel / SidePanelController.babel.js View on Github external
removes.forEach((component) =&gt; {

        switch (component) {
          case componentNames.INTRO:
            this.hideIntro(options);
            if (this.visibleComponents.indexOf(componentNames.MAP) &lt; 0 &amp;&amp; this.visibleComponents.indexOf(componentNames.GALLERY) &lt; 0 ) {
              if (isMobile) {
                AppActions.showComponent(componentNames.MAP);
              } else {
                AppActions.showComponent([componentNames.MAP,componentNames.GALLERY]);
              }
            }
            break;
        }

      });
    } else if (isMobile &amp;&amp; visibleComponents.indexOf(componentNames.MAP) &gt;= 0 &amp;&amp; visibleComponents.indexOf(componentNames.GALLERY) &gt;= 0) {
github Esri / storymap-crowdsource / src / app / controllers / layouts / stacked / StackedController.babel.js View on Github external
switch (component) {
          case componentNames.INTRO:
            this.showIntro(options);
            MapActions.selectFeature(false);
            AppActions.hideComponent([componentNames.MAP,componentNames.GALLERY,componentNames.SELECTED_SHARES]);
            break;
          case componentNames.MAP:
            this.showMap(options);
            AppActions.hideComponent([componentNames.INTRO,componentNames.GALLERY]);
            break;
          case componentNames.GALLERY:
            if (this.visibleComponents.indexOf(componentNames.CONTRIBUTE) &lt; 0) {
              this.showGallery(options);
              AppActions.hideComponent([componentNames.INTRO,componentNames.MAP]);
            } else {
              AppActions.hideComponent(componentNames.GALLERY);
            }
            break;
        }

      });
github Esri / storymap-crowdsource / src / app / controllers / layouts / stacked / StackedController.babel.js View on Github external
removes.forEach((component) =&gt; {

        switch (component) {
          case componentNames.INTRO:
            this.hideIntro(options);
            if (this.visibleComponents.indexOf(componentNames.MAP) &lt; 0 &amp;&amp; this.visibleComponents.indexOf(componentNames.GALLERY) &lt; 0 ) {
              AppActions.showComponent(componentNames.MAP);
            }
            break;
        }

      });
    }
github Esri / storymap-crowdsource / src / app / controllers / layouts / sidePanel / SidePanelController.babel.js View on Github external
switch (component) {
          case componentNames.INTRO:
            this.showIntro(options);
            MapActions.selectFeature(false);
            AppActions.hideComponent([componentNames.MAP,componentNames.GALLERY,componentNames.SELECTED_SHARES]);
            break;
          case componentNames.MAP:
            this.showMap(options);
            const hideComponents = [componentNames.INTRO];
            const showComponents = [];

            if (isMobile) {
              hideComponents.push(componentNames.GALLERY);
            } else {
              showComponents.push(componentNames.GALLERY);
            }
            AppActions.hideComponent(hideComponents);
            if (showComponents.length &gt; 0) {
              AppActions.showComponent(showComponents);
            }
            break;
          case componentNames.GALLERY:
            if (this.visibleComponents.indexOf(componentNames.CONTRIBUTE) &lt; 0) {
              this.showGallery(options);
              const hideComponents = [componentNames.INTRO];
              const showComponents = [];

              if (isMobile) {
                hideComponents.push(componentNames.MAP);
              } else {
                showComponents.push(componentNames.MAP);
github Esri / storymap-crowdsource / src / app / controllers / layouts / sidePanel / SidePanelController.babel.js View on Github external
removes.forEach((component) =&gt; {

        switch (component) {
          case componentNames.INTRO:
            this.hideIntro(options);
            if (this.visibleComponents.indexOf(componentNames.MAP) &lt; 0 &amp;&amp; this.visibleComponents.indexOf(componentNames.GALLERY) &lt; 0 ) {
              if (isMobile) {
                AppActions.showComponent(componentNames.MAP);
              } else {
                AppActions.showComponent([componentNames.MAP,componentNames.GALLERY]);
              }
            }
            break;
        }

      });
    } else if (isMobile &amp;&amp; visibleComponents.indexOf(componentNames.MAP) &gt;= 0 &amp;&amp; visibleComponents.indexOf(componentNames.GALLERY) &gt;= 0) {
github Esri / storymap-crowdsource / src / app / controllers / layouts / sidePanel / SidePanelController.babel.js View on Github external
case componentNames.MAP:
            this.showMap(options);
            const hideComponents = [componentNames.INTRO];
            const showComponents = [];

            if (isMobile) {
              hideComponents.push(componentNames.GALLERY);
            } else {
              showComponents.push(componentNames.GALLERY);
            }
            AppActions.hideComponent(hideComponents);
            if (showComponents.length &gt; 0) {
              AppActions.showComponent(showComponents);
            }
            break;
          case componentNames.GALLERY:
            if (this.visibleComponents.indexOf(componentNames.CONTRIBUTE) &lt; 0) {
              this.showGallery(options);
              const hideComponents = [componentNames.INTRO];
              const showComponents = [];

              if (isMobile) {
                hideComponents.push(componentNames.MAP);
              } else {
                showComponents.push(componentNames.MAP);
              }
              AppActions.hideComponent(hideComponents);
              if (showComponents.length &gt; 0) {
                AppActions.showComponent(showComponents);
              }
            } else {
              AppActions.hideComponent(componentNames.GALLERY);