• Stars
    star
    126
  • Rank 282,925 (Top 6 %)
  • Language
    JavaScript
  • License
    MIT License
  • Created about 4 years ago
  • Updated over 1 year ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

react-notification-timeline is a react based component helps in managing the notification in time-based manner.

🔔 react-notification-timeline

All Contributors

react-notification-timeline is a reactjs based component helps in managing the notifications in time-based manner. It is capable of keep tracking of the incoming notifications, manage read vs unread messages and allows many more customizations.

🔥 Why do you need this?

  • 👉 Is your project is based on react js and you are looking for a time-based notification system?
  • 👉 Do you want to keep track of the notifications in timed manner and manage them ?
  • 👉 Do you want to structure the notifications in a cleaner way?
  • 👉 Do you want to manage multi-line notifications?
  • 👉 Do you limit the number of notifications you may want to see?

Then, you should give react-notification-timeline a try.

Here are some screen-shots

  • Notification Component with the unread message count

    notification
  • Notification Component with the messages as a pop-over

notification with messages

Live Demo

Netlify Status

A Live demo of the component is available here, 💻 CLICK FOR DEMO

Many Thanks to all the Stargazers who has supported this project with stars()

Stargazers repo roster for @atapas/notifyme

⚒️ How to use?

Install

You can install react-notification-timeline using npm or yarn.

npm i react-notification-timeline
yarn add react-notification-timeline

Import

Once installed, it can be imported into a react component as,

import NotifyMe from 'react-notification-timeline';

Usage

Here is an example usage,

<NotifyMe
  data={data}
  storageKey='notific_key'
  notific_key='timestamp'
  notific_value='update'
  heading='Notification Alerts'
  sortedByKey={false}
  showDate={true}
  size={64}
  color="yellow"
  markAsReadFn={() => yourOwnFunctionHandler()}
/>

Properties

CLICK ME to know the details of the properties

Property Description Required Example
theme customizing the background and foreground of the Notification and its icon No color and background color can be either in HexaCode,rgb or string name. Default is
   {
     color:"yellow",
     backgroundColor:"#282828"
   }
data Messages to show as notifications. This is expected to be an array of objects. Each of the object must have two properties.
  • timestamp: The timestamp of the time a message was generated. This must be a of a type long and represent a timestamp.
  • update: The message to show as notification.
Note: The keys names, timestamp and update can be customized as explained in other properties below.
Yes
   [
     {
       "update":"70 new employees are shifted",
       "timestamp":1596119688264
     },
     {
       "update":"Time to take a Break, TADA!!!",
       "timestamp":1596119686811
     }
   ]
heading A header message for the Notification panel. Pass a message to customize it. No Any string of your choice. Default value is, Notifications
multiLineSplitter In case a notification message has to be splitted into multiple (bullet) items, you can specify a line splitter character in-between. No Any Character like, # or a sequence of characters, #$#. Default value is, \n
notific_key Key in the data property that holds the timestamp value. Yes timestamp, attime or any string based key name in the data property.
notific_value key in the data property that holds the notification message value. Yes update, message or any string based key name in the data property.
showDate Notification message shows the date and time along with the message. Pass false for this property, if you do not want to show it. Pass true otherwise. No true or false. Default value is, false
size Size of the notification bell. Pass a Size to customize it. No Size values as, 16, 32, 48 etc. Default value is, 32
sortedByKey Pass true, if the data passed to this component is already sorted by time-based key. Pass false otherwise, the component will take care of the time based sorting. No true or false. Default value is, true
storageKey It stores the last read message key in localstorage of the browser. No Any string of your choice as a key. Default value is, notification_timeline_storage_id
markAsRead User can control the functionality of "Mark All As Read" by passing the function as prop as below markAsReadFn = {() => yourOwnFunctionHandler()} No Now "Mark All As Read" can be controlled by passing your own function as prop. Default functionality is,
  • We will clear the notification count.
  • Update the reactLocalStore with the latest notification key.
  • We will set the readIndex to 0 - which is used to highlight the unread notifications.
icon User can add custom notification Icon by passing react-feather icon as prop as below icon={IconName} //You need to import the Icon from the react-feather library No Any icon from the react-feather library default is Bell icon

🏷️ License

Copyright © 2020 by Tapas Adhikary

This project is licensed under MIT license.

Show your support

If you liked the work, please show your support by giving a Star!

Contributions

I would love to get your feedback. Please use the github issues for submitting any feedback. At the same time, please join hands in improving the component further by fixing bugs, adding features.

People contributed so far (emoji key):


Tapas Adhikary

🚇 ⚠️ 💻

NagarjunShroff

💻

Sankalpa Fernando

💻

Dony M Varkey

📖

This project follows the all-contributors specification. Contributions of any kind welcome!

More Repositories

1

html-tips-tricks

My Favorite HTML5 Tips and Tricks
HTML
309
star
2

webapis-playground

The Web APIs Playground is a project to showcase the JavaScript Web APIs with examples and demonstrations. Client-side JavaScript APIs are here to help with providing wrapper functions for many low-level tasks.
TypeScript
290
star
3

js-tips-tricks

List of JavaScript tips and tricks I am learning everyday!
JavaScript
190
star
4

promise-interview-ready

Learn JavaScript Promises in a new way. This repository contains all the source code and examples that make you ready with promises, especially for your interviews 😉.
JavaScript
178
star
5

markdown-cheatsheet

A single place for all the markdown syntaxes I have learned so far.
167
star
6

theme-builder

The theming system helps you in building a theme of your choice and apply it to test live. Why wait? Just give it a try.
JavaScript
148
star
7

html-file-upload

Useful HTML file upload tips for web developers
HTML
145
star
8

fork-me

Yeah, right. FORK ME!!! Once you fork me, I help you learn forking.
Python
113
star
9

demolab

Demolab is my fantasy project created to understand the power of JAMstack using JavaScript(Reactjs), API(Netlify and Aws) and pre-built Markup(Gatsby).
JavaScript
82
star
10

promiviz

Visualize JavaScript Promises on the browser. Visualize the JavaScript Promise APIs and learn. It is a playground to learn about promises faster, ever!
JavaScript
80
star
11

add-copyright

This is a Script to Automate adding the Copyright text to one or more source files Recursively.
JavaScript
79
star
12

js-keyevents-demo

Get to know all about the key events just with a keystroke.
JavaScript
61
star
13

learn-css-animation

Learn CSS animation with fun. It is simple, easy to use, and fun to learn.
HTML
55
star
14

nodeX

A collection of examples from Node.js modules.
JavaScript
34
star
15

princess-finder

The `princess-finder` is a fun app to use a bit of machine learning in the browser. This app was built as part of the Hashnode's #christmashackathon.
JavaScript
34
star
16

covid-19

COVID-19 World is yet another Project to build a Dashboard like app to showcase the data related to the COVID-19(Corona Virus).
JavaScript
32
star
17

model-repo

A public repository contains the best practices about creating and maintaining repositories to gain maximum engagements, contributions, and acknowledgments (like stars, sponsors).
31
star
18

js-collections-map-set

Repository to have example code to demonstrate JavaScript Map and Set data structures.
JavaScript
31
star
19

shoes

Shoes is an online shoe store built using Gatsby and Strapi
JavaScript
29
star
20

react-add-table-dynamic-row

Adding a Table row dynamically using React Hook
JavaScript
28
star
21

testimonial

Jamstack app using Gatsby, Netlify, and FaunaDB.
JavaScript
26
star
22

youtube

You can find all source code mentioned in my YouTube videos right here. Not only that, you can even request a New Video from here. Just Give it a Try.
HTML
23
star
23

flicks

Flicks is a project to showcase the integration between Gatsbyjs and HarperDB. It provides a Gatsby-based user interface pulling data from the HarperDB. So you can assume it to be a library showing information about my favorite books!
JavaScript
23
star
24

imaginary

imaginary is an image gallery built using Gatsby and Cloudinary. Follow this project to know more.
JavaScript
19
star
25

js-handbook-examples

This repository contains the list of examples I have used in various handbooks on JavaScript.
JavaScript
17
star
26

quotes

A project to demonstrate the integration of SuperTokens's Passwrodless auth and Nextjs
JavaScript
16
star
27

shopnote

shopnote is a JAMstack application that helps in creating notes with shopping items. This application is built to showcase the JAMstack concept using Fauna, Netlify Serverless Functions and GatsbyJS.
JavaScript
16
star
28

catstore

Happy Paws Cat store is a Jamstack application to showcase the integration between Netlify Functions, Stripe, and Gatsby. It does a test checkout and the app is only for learning/demo purposes.
CSS
15
star
29

js-array-sorting

Various examples of JavaScript Array Sorting with tips.
JavaScript
15
star
30

js-mtprog

Sample code for Metaprogramming in JavaScript using Proxy, Reflection, Symbol, etc.
JavaScript
14
star
31

i18n-js-npm

i18n-web is a simple tool helps in externalizing the strings in a JavaScript based Application such that, Internationalization(i18n) can be achieved easily. It has the additional capability of parameterizing the strings to get the dynamic content Internationalized.
JavaScript
14
star
32

aqi-react

aqi-react is a project created to know the Air Quality Index of various parts of the world. How about a ⭐️?
JavaScript
13
star
33

array-fill-color-cards

This project demonstrates the fill() method of JavaScript Array using color cards.
JavaScript
12
star
34

react-package-publisher

This is a project to help developers build, test and publish a react component to Node Package Magaer(npm).
JavaScript
11
star
35

flicks-admin

A project to showcase HarperDB Custom function with Recharts to create a simple dashboard.
JavaScript
10
star
36

next-starter-revue-tailwind

Create a Newsletter APP with Twitter Revue, Next.js Serverless APIs, and Tailwind CSS. The Best way to get Newsletter on your website and portfolio.
JavaScript
9
star
37

gatsby-source-harperdb

It is a Gatsbyjs plugin that allows you to use the HarperDB as the data source so that a Gatsby project can pull the data at the build time. It will help any Gatsbyjs app to create a prebuilt markup with the data from HarperDB.
JavaScript
8
star
38

atapas

This is my GitHib profile page. Feel free to check out the readme file, copy, fork, and use. You can visit it to know about the side-projects as well.
7
star
39

js-promise-example

This repository contains the example of JavaScript Promises and Operations
JavaScript
7
star
40

js-array-at-method

Project to demonstrate the usages of the JavaScript Array at(index) method.
CSS
7
star
41

react-clip-path

react-clip-path is a simple React-based package to create shapes declaratively using CSS clip-path property.
JavaScript
6
star
42

react-dynamic-import-component

This project was bootstrapped with Create React App. This is a Project to showcase how the dynamic imports, lazy and suspense works.
JavaScript
6
star
43

hobbyland

Hobby Land is a learn and do project built using tye super cool svelte. You can add and track your hobbies, edit them, and also remove them when not needed.
Svelte
6
star
44

nextjs-analytics

In this repo, we have implemented an integration with Next.JS and Quickmetrics. This is to do analytics using the Metrics created by Next.js Web Vitals.
JavaScript
6
star
45

todo-jexia-react

This is a Proof of Concept Project to use Jexia along with a React App. What Better than Creating a TODO app? How about a ⭐️?
JavaScript
5
star
46

tracker-beacon-api

Learn the Web Beacon API with examples. Try out this project to explore with hands-on.
JavaScript
5
star
47

colorpicker-pwa

A project to demonstrate PWA strategies
JavaScript
5
star
48

uc-react-gallery

A project to build interactive photo gallery using ReactJS and Uploadcare APIs. Learn image processing, face detection, object recognition, and many more.
JavaScript
5
star
49

react-redux-example

Project for explaining react-redux by example. How about a ⭐️?
JavaScript
5
star
50

horoscope-app

A new Flutter project to build an app that has basic layout, routing and server communication over REST APIs. What would be better than knowing your Horoscope in real! How about a ⭐️?
Dart
4
star
51

anchors

An app to demonstrate the HTML anchor tags and their properties.
HTML
4
star
52

jamstack-subscription-form

Let's build a subscription form with the Jamstack concept using Netlify Forms, Functions, and Fauna data-store.
HTML
4
star
53

webpack-react-starter

Project to get started with a Webpack supported development environment. React is added as a dependency already. How about a ⭐️?
JavaScript
3
star
54

font-loader

font-loader is a simple react app created using the Create React App to show case how fonts can be loaded.
JavaScript
3
star
55

js-module

JavaScript
3
star
56

theme-builder-tailwind

Create a Theme Builder using tailwindCSS
JavaScript
3
star
57

cypress-react-e-2-e

The cypress-react-e-2-e is an educational project aims to teach using Cypress end-to-end test with a ReactJS application.
JavaScript
3
star
58

ml-greenroots

ml-greenroots is a Pet project to run ML in the Browser using various libraries and frameworks available. How about a ⭐️?
JavaScript
3
star
59

test-rest-app

This is a sample sails js app which has integration with Heroku. See the website for more information.
JavaScript
3
star
60

thought-horoscope

This is a Horoscope Telling Tool Developed using NodeJS CLI(Command Line Interface) technologies. How about a ⭐️?
JavaScript
2
star
61

json-faker-server

This project showcases how to create an API server in few minutes which can provide you all that you need for building the User Interface Prototype.
JavaScript
2
star
62

nanny-plum

A Fun Project to Call Google Cloud API(Text to Speech) from Flutter. Do you know what? I have been using it at my home for a while now! How about a ⭐️?
Dart
2
star
63

nextjs-bugfender

This is a project to demonstrate Nextjs and Bugfender integration
JavaScript
2
star
64

ml-browser

This is a Project to try Machine Learning on Browser. How about a ⭐️?
HTML
1
star
65

tapasadhikary.com

This is the OLD public site for the domain tapasadhikary.com
JavaScript
1
star
66

greet-me-debugging

HTML
1
star
67

testcap

Code Testing using Jest and some examples. How about a ⭐️?
JavaScript
1
star
68

ionic-play

A sample project to demonstrate ionic slides with zoom capability. Each of the slide in the sildes got an image and some texts as sample data.
TypeScript
1
star
69

ng-auto-complete

UI Component built using Angular 5 to perform Autocomplete(Single and Multi-Select))
TypeScript
1
star
70

svelte-think

New to Svelte? Here are some examples to get started. How about a ⭐️?
HTML
1
star
71

ng-starter

A Quick start project for angular 1.x development
CSS
1
star
72

bugfender-flutter

A flutter app to integrate bugfender services. It logs all the app activities to the bugfender logs on the cloud for further assessment.
Dart
1
star
73

awesome-rest-service

This is the back-end app for the 'Full-Stack-Reborn' Project. It is hosted on Heroku. How about a ⭐️?
JavaScript
1
star
74

gatsby-all-in-one

This project has logical branches created from the tutorial https://www.gatsbyjs.org/tutorial/
JavaScript
1
star
75

code-in-react-19

A starter repository to code in React 19
JavaScript
1
star