File "deactivate-plugin-checkbox.js"

Full Path: /home/fresvfqn/waterdamagerestorationandrepairsmithtown.com/wp-content/plugins/surerank/src/apps/admin-general/advanced/tools/migration/deactivate-plugin-checkbox.js
File size: 793 bytes
MIME-type: text/x-java
Charset: utf-8

import { __, sprintf } from '@wordpress/i18n';
import { Checkbox } from '@bsf/force-ui';

const DeactivatePluginCheckbox = ( { plugin, value, onChange } ) => {
	if ( ! plugin ) {
		return null;
	}
	return (
		<div className="flex items-start mt-4 bg-background-secondary p-2 rounded-md border border-solid border-border-subtle">
			<div className="mt-0.5 mr-1.5">
				<Checkbox
					checked={ value }
					size="sm"
					onChange={ onChange }
					label={ {
						heading: sprintf(
							// translators: %s is the plugin name.
							__(
								'%s will be deactivated after migration. Uncheck to keep it active.',
								'surerank'
							),
							plugin?.name || __( 'The plugin', 'surerank' )
						),
					} }
				/>
			</div>
		</div>
	);
};

export default DeactivatePluginCheckbox;