You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix: catch invalid Google Charts format patterns and show i18n error (#1272)
Wrap gv.NumberFormat/DateFormat construction in a try/catch to prevent
uncaught 'Too many percent/permill' errors from invalid ICU patterns.
Show a localised error message inline below the format input field and
clear it automatically when the pattern becomes valid.
'select_columns' => esc_html__( 'Please select a few columns to include in the chart.', 'visualizer' ),
883
-
'save_settings' => __( 'You have modified the chart\'s settings. To modify the source/data again, you must save this chart and reopen it for editing. If you continue without saving the chart, you may lose your changes.', 'visualizer' ),
884
-
'copied' => __( 'The data has been copied to your clipboard. Hit Ctrl-V/Cmd-V in your spreadsheet editor to paste the data.', 'visualizer' ),
879
+
'invalid_source' => esc_html__( 'You have entered an invalid URL. Please provide a valid URL.', 'visualizer' ),
'select_columns' => esc_html__( 'Please select a few columns to include in the chart.', 'visualizer' ),
883
+
'save_settings' => __( 'You have modified the chart\'s settings. To modify the source/data again, you must save this chart and reopen it for editing. If you continue without saving the chart, you may lose your changes.', 'visualizer' ),
884
+
'copied' => __( 'The data has been copied to your clipboard. Hit Ctrl-V/Cmd-V in your spreadsheet editor to paste the data.', 'visualizer' ),
885
+
'invalid_format' => esc_html__( 'This format pattern is not supported in the series settings field. Use the Manual Configuration option instead.', 'visualizer' ),
885
886
),
886
887
'charts' => array(
887
888
'canvas' => $data,
@@ -1405,7 +1406,8 @@ private function _handleDataPage() {
1405
1406
array(
1406
1407
'l10n' => array(
1407
1408
'invalid_source' => esc_html__( 'You have entered an invalid URL. Please provide a valid URL.', 'visualizer' ),
'invalid_format' => esc_html__( 'This format pattern is not supported in the series settings field. To display percentages, use the Manual Configuration option instead.', 'visualizer' ),
0 commit comments