コード例 #1
0
ファイル: questions.js プロジェクト: aq/metabase
 message: (undo) => // eslint-disable-line react/display-name
     <div className="flex flex-column">
         <div>
             { undo.count + " " + inflect(null, undo.count, "question was", "questions were") + " " + type }
             { undo.count === 1 && collection &&
                 <span> to the <Link className="link" to={Urls.collection(collection)}>{collection.name}</Link> collection.</span>
             }
         </div>
     </div>,
コード例 #2
0
ファイル: Dimension.js プロジェクト: matias-gilbert/metabase
 subTriggerDisplayName(): string {
     if (this._args[0] === "num-bins") {
         return `${this._args[1]} ${inflect("bins", this._args[1])}`;
     } else if (this._args[0] === "bin-width") {
         const binWidth = this._args[1];
         const units = this.field().isCoordinate() ? "°" : "";
         return `${binWidth}${units}`;
     } else {
         return "Auto binned";
     }
 }