_renderSectionBugSelection()

in src/content/components/BugList/BugList.js [153:200]


  _renderSectionBugSelection(selectedBugs, totalBugs) {
    return (
      <div className={styles.editorType}>
        <div className={styles.leftEditorGroup}>
          {this.props.subtitle ? this._renderSubtitle() : null}
          {selectedBugs.length
            ? `${selectedBugs.length} bugs selected`
            : `${totalBugs.length} bugs`}
          {this.props.tickets ? (
            <span>
              {" "}
              |{" "}
              {totalBugs
                .reduce((a, b) => {
                  if (b.ticket && !a.includes(b.ticket)) {
                    a.push(b.ticket);
                  }
                  return a;
                }, [])
                .length.toString()}{" "}
              tickets
            </span>
          ) : null}
          {this.props.points ? (
            <span>
              {" "}
              |{" "}
              {totalBugs
                .reduce((a, b) => a + (parseInt(b.cf_fx_points) || 0), 0)
                .toString()}{" "}
              points
            </span>
          ) : null}
          {this.props.fileNew ? (
            <span>
              {" "}
              | <FileNewBugButton unstyled={true} params={this.props.fileNew} />
            </span>
          ) : null}
        </div>
        <div>
          {selectedBugs.length
            ? this.renderBulkEdit(selectedBugs)
            : this.renderFilters()}
        </div>
      </div>
    );
  }