@wpmudev/shared-notifications-black-friday

v2.0.2

Published

WPMU DEV Shared Black Friday Notifications

Downloads

4

Readme

License: GPLv3 npm

Black Friday Notification

This package works as a Shared Module between WPMU DEV plugins and it allows us to notify users about Black Friday offers.

Installation

npm i @wpmudev/shared-notifications-black-friday --save-dev

Usage

Javascript Instantiation

import React from 'react';
import { NoticeBlack } from '@wpmudev/shared-notifications-black-friday';

const MyApp = () => {
    return (
        <NoticeBlack
            link="https://wpmudev.com/"
            sourceLang={
				discount: "50% Off",
				closeLabel: "Close",
				linkLabel: "See the deal"
			}
        >
            <p><strong>Black Friday Offer!</strong> Get a Pro plugin for free and much more with 50% OFF.</p>
			<p><small>*Only admin users can see this message</small></p>
        </NoticeBlack>
    );
}

Properties

| Prop Name | Type | Description | | --------- | ---- | ----------- | | link | string | Sets call to action button URL. | | sourceLang | object | Allows to translate component labels. | | onCloseClick | - | Use this property to pass a function when clicking on close button. |