main
Last change
on this file was 0c6b92a, checked in by stefan toskovski <stefantoska84@…>, 5 weeks ago |
Pred finalna verzija
|
-
Property mode
set to
100644
|
File size:
379 bytes
|
Line | |
---|
1 | import React from "react";
|
---|
2 | import PropTypes from "prop-types";
|
---|
3 | import styles from "./Toast.module.css";
|
---|
4 |
|
---|
5 | const Toast = ({ message, type, onClose }) => {
|
---|
6 | return (
|
---|
7 | <div
|
---|
8 | className={`${styles.toast} ${type === 1 ? styles.success : styles.error}`}
|
---|
9 | onClick={onClose}
|
---|
10 | >
|
---|
11 | {message}
|
---|
12 | </div>
|
---|
13 | );
|
---|
14 | };
|
---|
15 |
|
---|
16 |
|
---|
17 |
|
---|
18 | export default Toast;
|
---|
Note:
See
TracBrowser
for help on using the repository browser.