UNPKG

angular-pipes

Version:
19 lines (18 loc) 617 B
import { PipeTransform } from '@angular/core'; export declare type ByteUnit = 'B' | 'kB' | 'KB' | 'MB' | 'GB' | 'TB'; export declare class BytesPipe implements PipeTransform { static formats: { [key: string]: { max: number; prev?: ByteUnit; }; }; transform(input: any, decimal?: number, from?: ByteUnit, to?: ByteUnit): any; static formatResult(result: number, unit: string): string; static calculateResult(format: { max: number; prev?: ByteUnit; }, bytes: number): number; } export declare class NgBytesPipeModule { }