Skip to content
This repository was archived by the owner on Feb 23, 2024. It is now read-only.

Commit 43d6b86

Browse files
committed
Make Product Categories List links unclickable in the editor (#4339)
1 parent fa17c47 commit 43d6b86

File tree

1 file changed

+13
-6
lines changed
  • assets/js/blocks/product-categories

1 file changed

+13
-6
lines changed

assets/js/blocks/product-categories/block.js

Lines changed: 13 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,12 @@ import { __ } from '@wordpress/i18n';
55
import { InspectorControls } from '@wordpress/block-editor';
66
import ServerSideRender from '@wordpress/server-side-render';
77
import PropTypes from 'prop-types';
8-
import { PanelBody, ToggleControl, Placeholder } from '@wordpress/components';
8+
import {
9+
Disabled,
10+
PanelBody,
11+
ToggleControl,
12+
Placeholder,
13+
} from '@wordpress/components';
914
import { Icon, list } from '@woocommerce/icons';
1015
import ToggleButtonControl from '@woocommerce/editor-components/toggle-button-control';
1116

@@ -181,11 +186,13 @@ const ProductCategoriesBlock = ( { attributes, setAttributes, name } ) => {
181186
return (
182187
<>
183188
{ getInspectorControls() }
184-
<ServerSideRender
185-
block={ name }
186-
attributes={ attributes }
187-
EmptyResponsePlaceholder={ EmptyPlaceholder }
188-
/>
189+
<Disabled>
190+
<ServerSideRender
191+
block={ name }
192+
attributes={ attributes }
193+
EmptyResponsePlaceholder={ EmptyPlaceholder }
194+
/>
195+
</Disabled>
189196
</>
190197
);
191198
};

0 commit comments

Comments
 (0)