2019-11-24 22:56:57 +00:00
|
|
|
import { MatPaginatorIntl } from '@angular/material';
|
|
|
|
|
|
|
|
export function getPaginatorLabel(field: string) {
|
|
|
|
const appPaginator = new MatPaginatorIntl();
|
|
|
|
appPaginator.itemsPerPageLabel = field + ' per page:';
|
|
|
|
return appPaginator;
|
|
|
|
}
|
|
|
|
|
2019-11-20 05:49:11 +00:00
|
|
|
export const CURRENCY_UNITS = [ 'Sats', 'BTC' ];
|
|
|
|
export const CURRENCY_UNIT_FORMATS = { Sats: '1.0-0', BTC: '1.6-6', OTHER: '1.2-2'};
|
2019-12-23 03:07:50 +00:00
|
|
|
export const FIAT_CURRENCY_UNITS = [
|
2020-01-10 03:50:02 +00:00
|
|
|
{id: 'USD', name: 'USD'},
|
2019-12-23 03:07:50 +00:00
|
|
|
{id: 'AUD', name: 'AUD'}, {id: 'BRL', name: 'BRL'}, {id: 'CAD', name: 'CAD'},
|
|
|
|
{id: 'CHF', name: 'CHF'}, {id: 'CLP', name: 'CLP'}, {id: 'CNY', name: 'CNY'},
|
2020-01-10 03:50:02 +00:00
|
|
|
{id: 'DKK', name: 'DKK'}, {id: 'EUR', name: 'EUR'}, {id: 'GBP', name: 'GBP'},
|
|
|
|
{id: 'HKD', name: 'HKD'}, {id: 'INR', name: 'INR'}, {id: 'ISK', name: 'ISK'},
|
2019-12-23 03:07:50 +00:00
|
|
|
{id: 'JPY', name: 'JPY'}, {id: 'KRW', name: 'KRW'}, {id: 'NZD', name: 'NZD'},
|
|
|
|
{id: 'PLN', name: 'PLN'}, {id: 'RUB', name: 'RUB'}, {id: 'SEK', name: 'SEK'},
|
|
|
|
{id: 'SGD', name: 'SGD'}, {id: 'THB', name: 'THB'}, {id: 'TWD', name: 'TWD'}
|
|
|
|
];
|
2019-11-15 05:58:00 +00:00
|
|
|
|
2019-11-19 23:49:58 +00:00
|
|
|
export const TIME_UNITS = ['SECS', 'MINS', 'HOURS', 'DAYS'];
|
|
|
|
|
2019-11-21 20:33:23 +00:00
|
|
|
export const PAGE_SIZE = 10;
|
|
|
|
export const PAGE_SIZE_OPTIONS = [5, 10, 25, 100];
|
|
|
|
|
2019-11-20 05:49:11 +00:00
|
|
|
export const ADDRESS_TYPES = [
|
2020-01-04 01:06:36 +00:00
|
|
|
{ addressId: '0', addressCode: 'bech32', addressTp: 'Bech32 (P2WKH)', addressDetails: 'Pay to witness key hash'},
|
|
|
|
{ addressId: '1', addressCode: 'p2sh-segwit', addressTp: 'P2SH (NP2WKH)', addressDetails: 'Pay to nested witness key hash (default)'}
|
2019-11-20 05:49:11 +00:00
|
|
|
];
|
|
|
|
|
2019-11-21 20:33:23 +00:00
|
|
|
export const TRANS_TYPES = [
|
2019-11-23 00:46:28 +00:00
|
|
|
{id: '0', name: 'Priority (Default)'},
|
2019-11-21 20:33:23 +00:00
|
|
|
{id: '1', name: 'Target Confirmation Blocks'},
|
|
|
|
{id: '2', name: 'Fee'}
|
|
|
|
];
|
|
|
|
|
2020-01-02 23:23:47 +00:00
|
|
|
export const FEE_LIMIT_TYPES = [
|
2020-01-03 01:35:01 +00:00
|
|
|
{id: 'none', name: 'No Fee Limit', placeholder: 'No Limit'},
|
|
|
|
{id: 'fixed', name: 'Fixed (Sats)', placeholder: 'Fixed Limit in Sats'},
|
|
|
|
// {id: 'fixed_msat', name: 'Fixed in mSats'},
|
|
|
|
{id: 'percent', name: 'Percentage of Payment Amount', placeholder: 'Percentage Limit'}
|
2020-01-02 23:23:47 +00:00
|
|
|
];
|
|
|
|
|
2020-01-03 20:04:00 +00:00
|
|
|
export const FEE_RATE_TYPES = [
|
|
|
|
{ feeRateId: 'urgent', feeRateType: 'Urgent'},
|
|
|
|
{ feeRateId: 'normal', feeRateType: 'Normal'},
|
|
|
|
{ feeRateId: 'slow', feeRateType: 'Slow'},
|
|
|
|
]
|
|
|
|
|
|
|
|
|
2019-12-26 01:13:21 +00:00
|
|
|
export const NODE_SETTINGS = {
|
|
|
|
themes: [
|
2020-01-08 14:44:58 +00:00
|
|
|
{id: 'PURPLE', name: 'Diogo'},
|
|
|
|
{id: 'TEAL', name: 'My2Sats'},
|
|
|
|
{id: 'INDIGO', name: 'RTL'},
|
|
|
|
{id: 'PINK', name: 'BK'}
|
2019-12-26 01:13:21 +00:00
|
|
|
],
|
2020-01-21 03:22:03 +00:00
|
|
|
modes: [{id: 'DAY', name: 'Day'}, {id: 'NIGHT', name: 'Night'}]
|
2019-12-26 01:13:21 +00:00
|
|
|
};
|
|
|
|
|
2019-12-10 16:15:35 +00:00
|
|
|
export enum UserPersonaEnum {
|
2020-01-08 14:44:58 +00:00
|
|
|
OPERATOR = 'OPERATOR',
|
|
|
|
MERCHANT = 'MERCHANT',
|
|
|
|
ALL = 'ALL'
|
2019-12-10 16:15:35 +00:00
|
|
|
}
|
|
|
|
|
2019-11-23 00:46:28 +00:00
|
|
|
export enum AlertTypeEnum {
|
2019-11-27 00:49:44 +00:00
|
|
|
INFORMATION = 'Information',
|
|
|
|
WARNING = 'Warning',
|
2019-11-23 00:46:28 +00:00
|
|
|
ERROR = 'Error',
|
|
|
|
SUCCESS = 'Success',
|
|
|
|
CONFIRM = 'Confirm'
|
|
|
|
}
|
|
|
|
|
2019-11-14 04:09:14 +00:00
|
|
|
export enum AuthenticateWith {
|
|
|
|
TOKEN = 'TOKEN',
|
|
|
|
PASSWORD = 'PASSWORD'
|
|
|
|
}
|
|
|
|
|
2019-11-19 23:49:58 +00:00
|
|
|
export enum TimeUnitEnum {
|
|
|
|
SECS = 'SECS',
|
|
|
|
MINS = 'MINS',
|
|
|
|
HOURS = 'HOURS',
|
|
|
|
DAYS = 'DAYS'
|
|
|
|
}
|
|
|
|
|
|
|
|
export enum CurrencyUnitEnum {
|
2019-11-20 05:49:11 +00:00
|
|
|
SATS = 'Sats',
|
2019-11-19 23:49:58 +00:00
|
|
|
BTC = 'BTC',
|
|
|
|
LITOSHIS = 'LITOSHIS',
|
|
|
|
LTC = 'LTC',
|
|
|
|
OTHER = 'OTHER'
|
2019-11-14 04:09:14 +00:00
|
|
|
}
|
2019-12-02 00:22:25 +00:00
|
|
|
|
|
|
|
export enum DataTypeEnum {
|
|
|
|
ARRAY = 'ARRAY',
|
|
|
|
NUMBER = 'NUMBER',
|
|
|
|
STRING = 'STRING',
|
|
|
|
BOOLEAN = 'BOOLEAN',
|
|
|
|
PASSWORD = 'PASSWORD',
|
|
|
|
DATE = 'DATE',
|
|
|
|
DATE_TIME = 'DATE_TIME'
|
|
|
|
}
|
2019-12-13 04:01:04 +00:00
|
|
|
|
|
|
|
export enum ScreenSizeEnum {
|
|
|
|
XS = 'XS', // < 600 => mobile handsets
|
|
|
|
SM = 'SM', // 600 - 839 => tab portrait
|
|
|
|
MD = 'MD', // 840 - 1439 => tab landscape & small laptops
|
|
|
|
LG = 'LG' // >1440 => big laptops
|
|
|
|
}
|