Truncate filter label if it's too long to fit
Differential Revision: D7144192 fbshipit-source-id: 4001930b194421682fa9bdc9b097434910f339b6
This commit is contained in:
parent
34b8876ac6
commit
f7343576fc
|
@ -25,7 +25,7 @@ const defaultOptions = {
|
|||
const truncate = function(
|
||||
str: ?string,
|
||||
maxChars: number,
|
||||
options: truncateOptions
|
||||
options?: truncateOptions
|
||||
): ?string {
|
||||
options = Object.assign({}, defaultOptions, options);
|
||||
if (str && str.length &&
|
||||
|
|
Loading…
Reference in New Issue