Skip to content

Commit

Permalink
Merge pull request #90 from newfold-labs/fix/fix-skip404-settings-screen
Browse files Browse the repository at this point in the history
Fix Skip 404 settings appearance
  • Loading branch information
arunshenoy99 authored Jan 28, 2025
2 parents 3a07340 + ee14c9c commit a475e2d
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 7 deletions.
2 changes: 1 addition & 1 deletion components/performance/defaultText.js
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ const defaultText = {
'wp-module-performance'
),
skip404OptionLabel: __(
'Skip 404 Handling For Static Files',
'Enable Skip 404 Handling For Static Files',
'wp-module-performance'
),
skip404NoticeTitle: __( 'Skip 404 saved', 'wp-module-performance' ),
Expand Down
10 changes: 4 additions & 6 deletions components/skip404/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import apiFetch from '@wordpress/api-fetch';

// Newfold
import { Checkbox, Container } from '@newfold/ui-component-library';
import { ToggleField, Container } from '@newfold/ui-component-library';
import { NewfoldRuntime } from '@newfold/wp-module-runtime';

const Skip404 = ( { methods, constants } ) => {
Expand Down Expand Up @@ -53,13 +53,11 @@ const Skip404 = ( { methods, constants } ) => {
title={ constants.text.skip404Title }
description={ constants.text.skip404Description }
>
<Checkbox
<ToggleField
id="skip-404"
name="skip-404"
onChange={ handleSkip404Change }
value={ skip404 }
checked={ skip404 }
label={ constants.text.skip404OptionLabel }
checked={ skip404 }
onChange={ () => handleSkip404Change( skip404, setSkip404 ) }
/>
</Container.SettingsField>
);
Expand Down

0 comments on commit a475e2d

Please sign in to comment.