docs(nx-dev): enable WebinarNotifier and update webinar details (#29591)
Re-enabled the `WebinarNotifier` component in the app layout and updated the webinar date and localStorage key to reflect the new event on January 22, 2025.
This commit is contained in:
parent
9dbebbee20
commit
bbbfd9f43b
@ -106,7 +106,7 @@ export default function CustomApp({
|
|||||||
</Link>
|
</Link>
|
||||||
<Component {...pageProps} />
|
<Component {...pageProps} />
|
||||||
{/* <LiveStreamNotifier /> */}
|
{/* <LiveStreamNotifier /> */}
|
||||||
{/*<WebinarNotifier />*/}
|
<WebinarNotifier />
|
||||||
|
|
||||||
{/* Global Site Tag (gtag.js) - Google Analytics */}
|
{/* Global Site Tag (gtag.js) - Google Analytics */}
|
||||||
<Script
|
<Script
|
||||||
|
|||||||
@ -1,22 +1,17 @@
|
|||||||
'use client';
|
'use client';
|
||||||
|
|
||||||
import { useState, useEffect, ReactElement } from 'react';
|
import { MouseEvent, ReactElement, useEffect, useState } from 'react';
|
||||||
import { motion } from 'framer-motion';
|
import { motion } from 'framer-motion';
|
||||||
import { MonorepoWorldIcon } from '@nx/nx-dev/ui-icons';
|
|
||||||
import { ButtonLink } from './button';
|
|
||||||
import {
|
import {
|
||||||
PlayIcon,
|
|
||||||
XMarkIcon,
|
|
||||||
ChatBubbleLeftRightIcon,
|
|
||||||
VideoCameraIcon,
|
|
||||||
MegaphoneIcon,
|
MegaphoneIcon,
|
||||||
|
VideoCameraIcon,
|
||||||
|
XMarkIcon,
|
||||||
} from '@heroicons/react/24/outline';
|
} from '@heroicons/react/24/outline';
|
||||||
import { sendCustomEvent } from '@nx/nx-dev/feature-analytics';
|
|
||||||
|
|
||||||
export function WebinarNotifier(): ReactElement | null {
|
export function WebinarNotifier(): ReactElement | null {
|
||||||
const [isMounted, setIsMounted] = useState(false);
|
const [isMounted, setIsMounted] = useState(false);
|
||||||
const [isVisible, setIsVisible] = useState<boolean>(true);
|
const [isVisible, setIsVisible] = useState<boolean>(true);
|
||||||
const localStorageKey = 'webinar-december-10-2024--notifier-closed';
|
const localStorageKey = 'webinar-january-22-2025--notifier-closed';
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
setIsMounted(true);
|
setIsMounted(true);
|
||||||
@ -26,7 +21,7 @@ export function WebinarNotifier(): ReactElement | null {
|
|||||||
}
|
}
|
||||||
}, []);
|
}, []);
|
||||||
|
|
||||||
const closeNotifier = (e: React.MouseEvent) => {
|
const closeNotifier = (e: MouseEvent) => {
|
||||||
e.stopPropagation();
|
e.stopPropagation();
|
||||||
setIsVisible(false);
|
setIsVisible(false);
|
||||||
localStorage.setItem(localStorageKey, 'true');
|
localStorage.setItem(localStorageKey, 'true');
|
||||||
@ -66,7 +61,7 @@ export function WebinarNotifier(): ReactElement | null {
|
|||||||
aria-hidden="true"
|
aria-hidden="true"
|
||||||
className="size-8 flex-shrink-0"
|
className="size-8 flex-shrink-0"
|
||||||
/>
|
/>
|
||||||
<span>Join our webinar + live Q&A on Dec 10th</span>
|
<span>Join our webinar + live Q&A on January 22nd</span>
|
||||||
</motion.h3>
|
</motion.h3>
|
||||||
<motion.div key="live-event" className="mt-4 space-y-4">
|
<motion.div key="live-event" className="mt-4 space-y-4">
|
||||||
<p className="mb-2 text-sm">
|
<p className="mb-2 text-sm">
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user