mirror of
https://github.com/Foundryborne/daggerheart.git
synced 2026-01-12 03:31:07 +01:00
* new style for character sheets * Added nowrap on level label --------- Co-authored-by: WBHarry <williambjrklund@gmail.com>
This commit is contained in:
parent
f133b3b966
commit
56c4a2805f
42 changed files with 2399 additions and 110 deletions
|
|
@ -13,10 +13,43 @@ export default class RegisterHandlebarsHelpers {
|
|||
signedNumber: this.signedNumber,
|
||||
length: this.length,
|
||||
switch: this.switch,
|
||||
case: this.case
|
||||
case: this.case,
|
||||
eq: this.eq,
|
||||
ne: this.ne,
|
||||
lt: this.lt,
|
||||
gt: this.gt,
|
||||
lte: this.lte,
|
||||
gte: this.gte,
|
||||
and: this.and,
|
||||
or: this.or
|
||||
});
|
||||
}
|
||||
|
||||
static eq(v1, v2) {
|
||||
return v1 === v2;
|
||||
}
|
||||
static ne(v1, v2) {
|
||||
return v1 !== v2;
|
||||
}
|
||||
static lt(v1, v2) {
|
||||
return v1 < v2;
|
||||
}
|
||||
static gt(v1, v2) {
|
||||
return v1 > v2;
|
||||
}
|
||||
static lte(v1, v2) {
|
||||
return v1 <= v2;
|
||||
}
|
||||
static gte(v1, v2) {
|
||||
return v1 >= v2;
|
||||
}
|
||||
static and() {
|
||||
return Array.prototype.every.call(arguments, Boolean);
|
||||
}
|
||||
static or() {
|
||||
return Array.prototype.slice.call(arguments, 0, -1).some(Boolean);
|
||||
}
|
||||
|
||||
static times(nr, block) {
|
||||
var accum = '';
|
||||
for (var i = 0; i < nr; ++i) accum += block.fn(i);
|
||||
|
|
@ -101,7 +134,7 @@ export default class RegisterHandlebarsHelpers {
|
|||
}
|
||||
|
||||
static debug(a) {
|
||||
console.log(JSON.stringify(a));
|
||||
console.log(a);
|
||||
return a;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue