Skip to content

Commit

Permalink
Adjust the info-icon color
Browse files Browse the repository at this point in the history
  • Loading branch information
hypest committed Nov 7, 2019
1 parent e863087 commit 92d7e71
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
6 changes: 5 additions & 1 deletion packages/block-library/src/missing/edit.native.js
Expand Up @@ -31,6 +31,8 @@ export class UnsupportedBlockEdit extends Component {
}

renderHelpIcon() {
const infoIconStyle = this.props.getStylesFromColorScheme( styles.infoIcon, styles.infoIconDark );

return (
<TouchableWithoutFeedback
accessibilityLabel={ __( 'Help icon' ) }
Expand All @@ -43,6 +45,7 @@ export class UnsupportedBlockEdit extends Component {
className="unsupported-icon-help"
label={ __( 'Help icon' ) }
icon="editor-help"
color={ infoIconStyle.color }
/>
</View>
</TouchableWithoutFeedback>
Expand All @@ -54,6 +57,7 @@ export class UnsupportedBlockEdit extends Component {
const infoTextStyle = getStylesFromColorScheme( styles.infoText, styles.infoTextDark );
const infoTitleStyle = getStylesFromColorScheme( styles.infoTitle, styles.infoTitleDark );
const infoDescriptionStyle = getStylesFromColorScheme( styles.infoDescription, styles.infoDescriptionDark );
const infoIconStyle = getStylesFromColorScheme( styles.infoIcon, styles.infoIconDark );

// translators: %s: Name of the block
const titleFormat = Platform.OS === 'android' ? __( '\'%s\' isn\'t yet supported on WordPress for Android' ) :
Expand All @@ -70,7 +74,7 @@ export class UnsupportedBlockEdit extends Component {
onClose={ this.toggleSheet.bind( this ) }
>
<View style={ styles.infoContainer } >
<Icon icon="editor-help" style={ styles.infoIcon } size={ styles.infoIcon.size } />
<Icon icon="editor-help" color={ infoIconStyle.color } size={ styles.infoIcon.size } />
<Text style={ [ infoTextStyle, infoTitleStyle ] }>
{ infoTitle }
</Text>
Expand Down
5 changes: 5 additions & 0 deletions packages/block-library/src/missing/style.native.scss
Expand Up @@ -31,6 +31,11 @@
height: 36;
padding-top: 8;
padding-bottom: 8;
color: $gray-darken-20;
}

.infoIconDark {
color: $gray-20;
}

.infoText {
Expand Down

0 comments on commit 92d7e71

Please sign in to comment.