Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@uniswap/conedison

Package Overview
Dependencies
Maintainers
18
Versions
17
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@uniswap/conedison - npm Package Compare versions

Comparing version 1.0.1 to 1.1.0

3

dist/format.d.ts

@@ -13,3 +13,4 @@ import { Currency, CurrencyAmount, Percent, Price } from '@uniswap/sdk-core';

NFTTokenFloorPrice = "nft-token-floor-price",
NFTCollectionStats = "nft-collection-stats"
NFTCollectionStats = "nft-collection-stats",
NFTTokenFloorPriceTrailingZeros = "nft-token-floor-price-trailing-zeros"
}

@@ -16,0 +17,0 @@ export declare function formatNumber(input: Nullish<number>, type?: NumberType, placeholder?: string): string;

@@ -29,2 +29,6 @@ var __read = (this && this.__read) || function (o, n) {

// https://www.notion.so/uniswaplabs/Number-standards-fbb9f533f10e4e22820722c2f66d23c0
var FIVE_DECIMALS_NO_TRAILING_ZEROS = new Intl.NumberFormat('en-US', {
notation: 'standard',
maximumFractionDigits: 5,
});
var FIVE_DECIMALS_MAX_TWO_DECIMALS_MIN = new Intl.NumberFormat('en-US', {

@@ -41,5 +45,5 @@ notation: 'standard',

});
var NO_DECIMALS = new Intl.NumberFormat('en-US', {
var THREE_DECIMALS_NO_TRAILING_ZEROS = new Intl.NumberFormat('en-US', {
notation: 'standard',
maximumFractionDigits: 0,
maximumFractionDigits: 3,
minimumFractionDigits: 0,

@@ -59,2 +63,6 @@ });

});
var TWO_DECIMALS_NO_TRAILING_ZEROS = new Intl.NumberFormat('en-US', {
notation: 'standard',
maximumFractionDigits: 2,
});
var TWO_DECIMALS = new Intl.NumberFormat('en-US', {

@@ -72,7 +80,2 @@ notation: 'standard',

});
var SHORTHAND_ONE_DECIMAL = new Intl.NumberFormat('en-US', {
notation: 'compact',
minimumFractionDigits: 1,
maximumFractionDigits: 1,
});
var SHORTHAND_TWO_DECIMALS = new Intl.NumberFormat('en-US', {

@@ -83,2 +86,10 @@ notation: 'compact',

});
var SHORTHAND_TWO_DECIMALS_NO_TRAILING_ZEROS = new Intl.NumberFormat('en-US', {
notation: 'compact',
maximumFractionDigits: 2,
});
var SHORTHAND_FIVE_DECIMALS_NO_TRAILING_ZEROS = new Intl.NumberFormat('en-US', {
notation: 'compact',
maximumFractionDigits: 5,
});
var SHORTHAND_USD_TWO_DECIMALS = new Intl.NumberFormat('en-US', {

@@ -102,2 +113,6 @@ notation: 'compact',

});
var SCIENTIFIC_SIX_DIGITS = new Intl.NumberFormat('en-US', {
notation: 'scientific',
maximumSignificantDigits: 6,
});
var SCIENTIFIC_USD = new Intl.NumberFormat('en-US', {

@@ -186,3 +201,3 @@ notation: 'scientific',

var fiatTokenQuantityFormatter = __spreadArray([{ exact: 0, formatter: '$0.00' }], __read(fiatGasPriceFormatter), false);
var ntfTokenFloorPriceFormatter = [
var ntfTokenFloorPriceFormatterTrailingZeros = [
{ exact: 0, formatter: '0' },

@@ -195,5 +210,17 @@ { upperBound: 0.001, formatter: '<0.001' },

];
var ntfTokenFloorPriceFormatter = [
{ exact: 0, formatter: '0' },
{ upperBound: 0.001, formatter: '<0.001' },
{ upperBound: 1, formatter: THREE_DECIMALS_NO_TRAILING_ZEROS },
{ upperBound: 1000, formatter: TWO_DECIMALS_NO_TRAILING_ZEROS },
{ upperBound: 1e15, formatter: SHORTHAND_TWO_DECIMALS_NO_TRAILING_ZEROS },
{ upperBound: Infinity, formatter: SCIENTIFIC },
];
var ntfCollectionStatsFormatter = [
{ upperBound: 1000, formatter: NO_DECIMALS },
{ upperBound: Infinity, formatter: SHORTHAND_ONE_DECIMAL },
{ exact: 0, formatter: '0' },
{ upperBound: 0.00001, formatter: '<0.00001' },
{ upperBound: 1, formatter: FIVE_DECIMALS_NO_TRAILING_ZEROS },
{ upperBound: 1e6, formatter: SIX_SIG_FIGS_NO_COMMAS },
{ upperBound: 1e15, formatter: SHORTHAND_FIVE_DECIMALS_NO_TRAILING_ZEROS },
{ upperBound: Infinity, formatter: SCIENTIFIC_SIX_DIGITS },
];

@@ -223,2 +250,4 @@ export var NumberType;

NumberType["NFTCollectionStats"] = "nft-collection-stats";
// nft floor price with trailing zeros
NumberType["NFTTokenFloorPriceTrailingZeros"] = "nft-token-floor-price-trailing-zeros";
})(NumberType || (NumberType = {}));

@@ -235,2 +264,3 @@ var TYPE_TO_FORMATTER_RULES = (_a = {},

_a[NumberType.NFTTokenFloorPrice] = ntfTokenFloorPriceFormatter,
_a[NumberType.NFTTokenFloorPriceTrailingZeros] = ntfTokenFloorPriceFormatterTrailingZeros,
_a[NumberType.NFTCollectionStats] = ntfCollectionStatsFormatter,

@@ -237,0 +267,0 @@ _a);

{
"name": "@uniswap/conedison",
"version": "1.0.1",
"version": "1.1.0",
"description": "Utilities for Uniswap front-end development",

@@ -5,0 +5,0 @@ "repository": "https://github.com/Uniswap/conedison",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc