Skip to content

Commit 091296c

Browse files
committed
Merge branch 'v11-prod' into v11
2 parents aa24f7c + ca1a431 commit 091296c

1 file changed

Lines changed: 10 additions & 1 deletion

File tree

apps/showcase/components/layout/sections/AppNews.tsx

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,16 @@ const announcement = News as Announcement;
1818
export default function AppNews() {
1919
const app = useApp();
2020

21-
const onClose = () => {};
21+
const onClose = () => {
22+
app.setNewsActive(false);
23+
const item = {
24+
hiddenNews: announcement.id
25+
};
26+
27+
if (!app.storageKey) return;
28+
29+
localStorage.setItem(app.storageKey, JSON.stringify(item));
30+
};
2231

2332
React.useEffect(() => {
2433
const itemString = app.storageKey ? localStorage.getItem(app.storageKey) : null;

0 commit comments

Comments
 (0)