Skip to content

Kepler.gl is a powerful open source geospatial analysis tool for large-scale data sets.

[Feat] fixed augumented numeric formats with ~ (#1369)

Valentine Panchin2ea82debf7d1
diff --git a/src/constants/tooltip.js b/src/constants/tooltip.js
index 163642c6a..60b934a74 100644
--- a/src/constants/tooltip.js
+++ b/src/constants/tooltip.js
@@ -45,7 +45,7 @@ export const TOOLTIP_FORMATS = {
DECIMAL_SHORT_COMMA: {
id: 'DECIMAL_SHORT_COMMA',
label: '12.3k',
- format: '.3s',
+ format: '.3~s',
type: TOOLTIP_FORMAT_TYPES.DECIMAL
},
DECIMAL_PERCENT_FULL_1: {
@@ -63,7 +63,7 @@ export const TOOLTIP_FORMATS = {
DECIMAL_PRECENT_REGULAR: {
id: 'DECIMAL_PRECENT_REGULAR',
label: '12.345 → 12.35%',
- format: '%',
+ format: '~%',
type: TOOLTIP_FORMAT_TYPES.PERCENTAGE
},
DECIMAL_DECIMAL_FIXED_2: {
diff --git a/test/node/utils/data-utils-test.js b/test/node/utils/data-utils-test.js
index cc01976e9..6e98c7aff 100644
--- a/test/node/utils/data-utils-test.js
+++ b/test/node/utils/data-utils-test.js
@@ -123,7 +123,7 @@ test('dataUtils -> getFormatter', t => {
assert: [134, '100']
},
{
- input: ['%'],
+ input: ['~%'],
assert: ['12.345', '12.35%']
},
{