Skip to content

Add "disabled" prop to ContentSearch #265

Description

@xavortm

Is your enhancement related to a problem? Please describe.

I want to disable the ContentSearch for card items that are part of the query loop.

Example:

<ContentSearch
	label={__('Select a Post or Page', 'project')}
	contentTypes={['post']}
	onSelectItem={(post) => setAttributes({ selectedPost: post })}
	placeholder={__('Search for a post', 'project')}
	disabled={context.queryId != null}
/>

Designs

CleanShot 2023-09-20 at 16 17 34@2x

Describe alternatives you've considered

No response

Code of Conduct

  • I agree to follow this project's Code of Conduct

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions