storeSettings = new StoreSettings(); $this->cartItems = $cartItems; $this->itemCount = Arr::get($config, 'item_count') ?? 0; $this->defaultOpenCart = Arr::get($config, 'open_cart') ?? false; $this->isAdminBarEnabled = Arr::get($config, 'is_admin_bar_enabled') || is_admin_bar_showing() ?? false; $this->cartRenderer = new CartRenderer($cartItems); } public function render() { ?>
( itemCount); ?> )
get('show_cart_icon_in_body'); static $loadedOnce = false; if ($loadedOnce && !$skipIfLoaded) { return ''; } if ($showCartIconInBody !== 'yes') { return ''; } ?>
itemCount > 0) { echo esc_html($this->itemCount); } ?>