Skip to content

Commit 64968dd

Browse files
committed
move locales en and en-US into the core
1 parent fe812eb commit 64968dd

15 files changed

+8
-52
lines changed

dist/plotly-locale-en-us.js

Lines changed: 0 additions & 1 deletion
This file was deleted.

dist/plotly-locale-en.js

Lines changed: 0 additions & 1 deletion
This file was deleted.

lib/index-basic.js

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,4 @@ Plotly.register([
1515
require('./pie')
1616
]);
1717

18-
// locales
19-
Plotly.register([
20-
require('./locale-en'),
21-
require('./locale-en-us')
22-
]);
23-
2418
module.exports = Plotly;

lib/index-cartesian.js

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,4 @@ Plotly.register([
2323
require('./violin')
2424
]);
2525

26-
// locales
27-
Plotly.register([
28-
require('./locale-en'),
29-
require('./locale-en-us')
30-
]);
31-
3226
module.exports = Plotly;

lib/index-finance.js

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,4 @@ Plotly.register([
1818
require('./candlestick')
1919
]);
2020

21-
// locales
22-
Plotly.register([
23-
require('./locale-en'),
24-
require('./locale-en-us')
25-
]);
26-
2721
module.exports = Plotly;

lib/index-geo.js

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,4 @@ Plotly.register([
1515
require('./choropleth')
1616
]);
1717

18-
// locales
19-
Plotly.register([
20-
require('./locale-en'),
21-
require('./locale-en-us')
22-
]);
23-
2418
module.exports = Plotly;

lib/index-gl2d.js

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,4 @@ Plotly.register([
1818
require('./parcoords')
1919
]);
2020

21-
// locales
22-
Plotly.register([
23-
require('./locale-en'),
24-
require('./locale-en-us')
25-
]);
26-
2721
module.exports = Plotly;

lib/index-gl3d.js

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,4 @@ Plotly.register([
1616
require('./mesh3d')
1717
]);
1818

19-
// locales
20-
Plotly.register([
21-
require('./locale-en'),
22-
require('./locale-en-us')
23-
]);
24-
2519
module.exports = Plotly;

lib/index-mapbox.js

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,4 @@ Plotly.register([
1414
require('./scattermapbox')
1515
]);
1616

17-
// locales
18-
Plotly.register([
19-
require('./locale-en'),
20-
require('./locale-en-us')
21-
]);
22-
2317
module.exports = Plotly;

lib/index.js

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -71,10 +71,4 @@ Plotly.register([
7171
require('./calendars')
7272
]);
7373

74-
// locales
75-
Plotly.register([
76-
require('./locale-en.js'),
77-
require('./locale-en-us.js')
78-
]);
79-
8074
module.exports = Plotly;

src/core.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,12 @@ exports.register([
6565
require('./components/rangeselector')
6666
]);
6767

68+
// locales en and en-US are required for default behavior
69+
exports.register([
70+
require('./locale-en'),
71+
require('./locale-en-US')
72+
]);
73+
6874
// plot icons
6975
exports.Icons = require('../build/ploticon');
7076

File renamed without changes.
File renamed without changes.

tasks/pull_date_format.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ var common = require('./util/common');
66
var args = process.argv.slice(2);
77
var argLocale = args[0];
88

9-
var pathToEn = path.join(constants.pathToLib, 'locale-en.js');
9+
var pathToEn = path.join(constants.pathToSrc, 'locale-en.js');
1010
var pathToWCRegions = path.join(__dirname, '../node_modules/world-calendars/dist/regional');
1111

1212
if(!argLocale) {

test/jasmine/tests/plots_test.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,7 @@ describe('Test Plots', function() {
160160
layoutOut,
161161
expected;
162162

163-
var formatObj = require('@lib/locale-en').format;
163+
var formatObj = require('@src/locale-en').format;
164164

165165
function supplyLayoutDefaults(layoutIn, layoutOut) {
166166
layoutOut._dfltTitle = {

0 commit comments

Comments
 (0)