blob: ac7f8052ce629844dfd8c31a0b64dc253ac6d2e2 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
import React from "react";
interface AnnouncementProps {
message: string;
backgroundColor?: string;
textColor?: string;
}
const Announcement: React.FC<AnnouncementProps> = ({
message,
backgroundColor = "#f8d7da",
textColor = "#721c24",
}) => {
return (
<div
className={`p-4 rounded-lg text-center font-bold`}
style={{
backgroundColor,
color: textColor,
}}
>
{message}
</div>
);
};
export default Announcement;
|