Automattic\WooCommerce\Admin\Features\OnboardingTasks\Tasks
CustomizeStore::possibly_remove_unwanted_ui_elements()
Runs script and add styles to remove unwanted elements and hide scrollbar when users are viewing with ?cys-hide-admin-bar=true.
Method of the class: CustomizeStore{}
No Hooks.
Return
null
. Nothing (null).
Usage
$CustomizeStore = new CustomizeStore(); $CustomizeStore->possibly_remove_unwanted_ui_elements();
CustomizeStore::possibly_remove_unwanted_ui_elements() CustomizeStore::possibly remove unwanted ui elements code WC 9.7.1
public function possibly_remove_unwanted_ui_elements() { if ( isset( $_GET['cys-hide-admin-bar'] ) ) { // @phpcs:ignore echo ' <style type="text/css"> body { overflow: hidden; } </style>'; } }