PHPackages                             hawksama/hyva-product-rule-notifier - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. hawksama/hyva-product-rule-notifier

ActiveMagento2-module[Utility &amp; Helpers](/categories/utility)

hawksama/hyva-product-rule-notifier
===================================

This module enables store owners to create conditional notifications in minicart and cart page based on product attributes.

1.0.1(1y ago)232OSL-3.0PHP

Since Jan 28Pushed 1y ago2 watchersCompare

[ Source](https://github.com/Hawksama/hyva-product-rule-notifier)[ Packagist](https://packagist.org/packages/hawksama/hyva-product-rule-notifier)[ RSS](/packages/hawksama-hyva-product-rule-notifier/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (2)Dependencies (3)Versions (3)Used By (0)

Hyva Product Attribute Notifications for Magento 2
==================================================

[](#hyva-product-attribute-notifications-for-magento-2)

[![Magento 2](https://camo.githubusercontent.com/e549358abec402fe3480e111c0bc02ce1dbc928b5d158663de092b679554ca80/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4d6167656e746f2d322e342d627269676874677265656e)](https://camo.githubusercontent.com/e549358abec402fe3480e111c0bc02ce1dbc928b5d158663de092b679554ca80/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4d6167656e746f2d322e342d627269676874677265656e)[![Hyva Compatible](https://camo.githubusercontent.com/5142f5f8339be76e5ced7ef9447c11db4674e265787e33f16dc5fe9270c06819/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f487976612d5468656d65732d396366)](https://camo.githubusercontent.com/5142f5f8339be76e5ced7ef9447c11db4674e265787e33f16dc5fe9270c06819/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f487976612d5468656d65732d396366)[![License](https://camo.githubusercontent.com/448c4dd30591c22fc7a06b4220ccf26894486451767ef7d101cd8940ab8e0d71/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c6963656e73652d4d6f7a696c6c612532305075626c69632532304c6963656e7365253230322e302d626c7565)](https://camo.githubusercontent.com/448c4dd30591c22fc7a06b4220ccf26894486451767ef7d101cd8940ab8e0d71/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c6963656e73652d4d6f7a696c6c612532305075626c69632532304c6963656e7365253230322e302d626c7565)

A dynamic Magento 2 module designed for **Hyva Themes** that displays targeted notifications in the minicart and cart pages based on product attributes. Perfect for creating urgency, highlighting promotions, and enhancing customer experience.

---

🌟 Overview
----------

[](#-overview)

This module empowers merchants to create **customizable notification rules** that trigger contextual messages (ERROR, WARNING, INFORMATION, SUCCESS) when products with specific attributes are added to the cart. Features include:

- **Multi-store support**
- **Scheduled activation** (start/end dates)
- **Attribute value matching** (exact match, substring match, or numeric comparisons)
- **AlpineJS-driven logic** for seamless Hyva integration
- **Admin UI Grid &amp; Form** for easy rule management

---

🚀 Key Features
--------------

[](#-key-features)

FeatureDescription**4 Notification Types**ERROR, WARNING, INFORMATION, SUCCESS with customizable styling**Advanced Attribute Targeting**Match attributes by exact value, substring, or numeric comparisons**Time-Based Rules**Schedule notifications for specific periods**Multi-Store Ready**Configure rules per store view**Frontend Display**Notifications in minicart and cart page**Dynamic Updates**Notifications in the minicart dynamically update based on cart changes, ensuring users always see relevant information without needing to refresh the page.**Code Quality**Passes PHPStan, PHPMD, PHP\_CodeSniffer, and more---

⚙️ Configuration
----------------

[](#️-configuration)

1. **Navigate to Admin Panel**:
    `Hawksama → Product Notifications → Manage Rules`
2. **Create New Rule**:
    - Define attribute conditions based on your product attributes.
        This module supports two match types:

        - **Exact Match**: Matches the attribute value exactly.
            - Example: `certification = "organic"`
                This triggers a notification for products certified as "organic".
        - **Substring Match (LIKE)**: Matches if the attribute value contains the specified substring.
            - Example: `description LIKE "recycled"`
                This triggers a notification for products with "recycled" anywhere in their description.
        - **Numeric Comparisons**: Matches based on numeric operators (&lt;, &lt;=, &gt;, &gt;=, ==),
            - Example: `stock_status
