Skip to content

Commit

Permalink
[RNMobile] Retrieve translation of color settings strings (#38026)
Browse files Browse the repository at this point in the history
* Translate color settings strings

* Update react-native-editor changelog
  • Loading branch information
fluiddot authored Jan 19, 2022
1 parent a31cf5f commit e0b385f
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
11 changes: 8 additions & 3 deletions packages/components/src/mobile/color-settings/utils.native.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,16 @@
/**
* WordPress dependencies
*/
import { __ } from '@wordpress/i18n';

const gradients = {
linear: 'linear-gradient',
radial: 'radial-gradient',
};

const gradientOptions = [
{ label: 'Linear', value: gradients.linear },
{ label: 'Radial', value: gradients.radial },
{ label: __( 'Linear' ), value: gradients.linear },
{ label: __( 'Radial' ), value: gradients.radial },
];

const getGradientType = ( color ) => {
Expand All @@ -23,7 +28,7 @@ export const colorsUtils = {
picker: 'Picker',
palette: 'Palette',
},
segments: [ 'Solid', 'Gradient' ],
segments: [ __( 'Solid' ), __( 'Gradient' ) ],
gradients,
gradientOptions,
getGradientType,
Expand Down
1 change: 1 addition & 0 deletions packages/react-native-editor/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ For each user feature we should also add a importance categorization label to i
- [*] [Image block] Fix missing translations [#37956]
- [*] Fix cut-off setting labels by properly wrapping the text [#37993]
- [*] Highlight text: fix applying formatting for non-selected text [#37915]
- [*] Fix missing translations of color settings [#38026]

## 1.69.0

Expand Down

0 comments on commit e0b385f

Please sign in to comment.