This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export function shortenNumber([number], { maxChars = DEFAULT_MAX_CHARS } = {}) { | |
if (isNaN(number)) { | |
return '--'; | |
} | |
if (isNone(maxChars)) { | |
maxChars = DEFAULT_MAX_CHARS; | |
} | |
let comma = format(','); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
get messagingBanner() { | |
let { messagesAllotted, customersAllotted, messagesSent, totalCustomerCount, highWatermarkCustomersTotal } = | |
this.usageMetrics; | |
// Show banner only if user is not on trial plan | |
if (!this.billing.billingInfo?.trial) { | |
let customersCount = this.account.current.planIncludeChurn ? highWatermarkCustomersTotal : totalCustomerCount; | |
let messagesExceeded = false; | |
let limitBannerData = {}; | |
if (messagesAllotted < messagesSent) { | |
messagesExceeded = true; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
newItems = [ | |
{ | |
network: "facebook", | |
text: "post number 1", | |
}, | |
{ | |
network: "twitter", | |
text: "some twitter text", | |
}, | |
{ |