Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,6 @@ describe( 'SettingsCard', () => {
'comments',
'json-api',
'photon',
'google-fonts',
],
allCardsForNonAdmin = [ 'post-by-email' ];

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@ describe( 'SettingsGroup', () => {
'comments',
'json-api',
'photon',
'google-fonts',
],
allGroupsForNonAdmin = [ 'post-by-email' ];

Expand Down
1 change: 0 additions & 1 deletion projects/plugins/jetpack/_inc/client/writing/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,6 @@ export class Writing extends React.Component {
'carousel',
'copy-post',
'custom-css',
'google-fonts',
'latex',
'masterbar',
'markdown',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -107,16 +107,14 @@ class ThemeEnhancements extends React.Component {

render() {
const foundInfiniteScroll = this.props.isModuleFound( 'infinite-scroll' ),
foundCustomCSS = this.props.isModuleFound( 'custom-css' ),
foundGoogleFonts = this.props.isModuleFound( 'google-fonts' );
foundCustomCSS = this.props.isModuleFound( 'custom-css' );

if ( ! foundInfiniteScroll && ! foundCustomCSS && ! foundGoogleFonts ) {
if ( ! foundInfiniteScroll && ! foundCustomCSS ) {
return null;
}

const infScr = this.props.getModule( 'infinite-scroll' );
const customCSS = this.props.getModule( 'custom-css' );
const googleFonts = this.props.getModule( 'google-fonts' );

const infiniteScrollDisabledByOverride =
'inactive' === this.props.getModuleOverride( 'infinite-scroll' );
Expand Down Expand Up @@ -216,27 +214,6 @@ class ThemeEnhancements extends React.Component {
</ModuleToggle>
</SettingsGroup>
) }
{ foundGoogleFonts && this.props.isWebfontsSupported && (
<SettingsGroup
module={ { module: googleFonts.module } }
support={ {
text: googleFonts.description,
link: getRedirectUrl( 'jetpack-support-google-fonts' ),
} }
>
<ModuleToggle
slug="google-fonts"
activated={ !! this.props.getOptionValue( 'google-fonts' ) }
toggling={ this.props.isSavingAnyOption( [ 'google-fonts' ] ) }
disabled={ this.props.isSavingAnyOption( [ 'google-fonts' ] ) }
toggleModule={ this.props.toggleModuleNow }
>
<span className="jp-form-toggle-explanation">
{ __( 'Use Google Fonts in your block enabled theme', 'jetpack' ) }
</span>
</ModuleToggle>
</SettingsGroup>
) }
</SettingsCard>
);
}
Expand All @@ -247,6 +224,5 @@ export default connect( state => {
module: module_name => getModule( state, module_name ),
isInfiniteScrollSupported: currentThemeSupports( state, 'infinite-scroll' ),
isModuleFound: module_name => isModuleFound( state, module_name ),
isWebfontsSupported: currentThemeSupports( state, 'webfonts' ),
};
} )( withModuleSettingsFormHelpers( ThemeEnhancements ) );
4 changes: 4 additions & 0 deletions projects/plugins/jetpack/changelog/update-google-fonts-beta
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Significance: patch
Type: other

Google Fonts: mark the feature as Beta, and remove toggle from dashboard.
4 changes: 2 additions & 2 deletions projects/plugins/jetpack/modules/google-fonts.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php
/**
* Module Name: Google Fonts
* Module Description: A selection of Google fonts for block enabled themes.
* Module Name: Google Fonts (Beta)
* Module Description: A selection of Google fonts for block enabled themes. This feature is still being developed.
* Sort Order: 1
* Recommendation Order: 2
* First Introduced: 10.8.0
Expand Down
2 changes: 1 addition & 1 deletion projects/plugins/jetpack/modules/module-info.php
Original file line number Diff line number Diff line change
Expand Up @@ -886,6 +886,6 @@ function jetpack_google_fonts_more_link() {
* Google Fonts description.
*/
function jetpack_more_info_google_fonts() {
esc_html_e( 'A selection of Google fonts for block enabled themes.', 'jetpack' );
esc_html_e( 'A selection of Google fonts for block enabled themes. This feature is still being developed.', 'jetpack' );
}
add_action( 'jetpack_module_more_info_google-fonts', 'jetpack_more_info_google_fonts' );