-
Notifications
You must be signed in to change notification settings - Fork 11
feat(legacy): 💄 add recommendation for our AI course #478
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
WIP: Needs changing main video
93e43db to
57ca4f9
Compare
bc26872 to
e44eaff
Compare
5d4477b to
6a372f4
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Copilot reviewed 5 out of 8 changed files in this pull request and generated no comments.
Files not reviewed (3)
- apps/legacy_nmit/package.json: Language not supported
- apps/legacy_nmit/pages/_document.tsx: Language not supported
- apps/legacy_nmit/pages/chapter/[post].tsx: Evaluated as low risk
Comments suppressed due to low confidence (1)
apps/legacy_nmit/pages/dashboard.tsx:49
- Ensure that the new behavior introduced by the
MissingBannercomponent is covered by tests.
<MissingBanner />
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
Copilot reviewed 8 out of 8 changed files in this pull request and generated 4 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| <p className="text-gray-600"> | ||
| <iframe className='w-full aspect-video' src="https://www.youtube.com/embed/ZXB3XTZRtdk" title="Pozvánka na AI kurz" frameBorder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" referrerPolicy="strict-origin-when-cross-origin" allowFullScreen /> | ||
| </p> |
Copilot
AI
Nov 11, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The <p> element should not contain an <iframe> as its child. According to HTML semantics, <p> elements should only contain phrasing content (inline elements), not embedded content like iframes.
Remove the <p> wrapper:
<div className="mt-4">
<iframe className='w-full aspect-video' src="https://www.youtube.com/embed/ZXB3XTZRtdk" title="Pozvánka na AI kurz" frameBorder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" referrerPolicy="strict-origin-when-cross-origin" allowFullScreen />
</div>| <p className="text-gray-600"> | |
| <iframe className='w-full aspect-video' src="https://www.youtube.com/embed/ZXB3XTZRtdk" title="Pozvánka na AI kurz" frameBorder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" referrerPolicy="strict-origin-when-cross-origin" allowFullScreen /> | |
| </p> | |
| <iframe className='w-full aspect-video' src="https://www.youtube.com/embed/ZXB3XTZRtdk" title="Pozvánka na AI kurz" frameBorder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" referrerPolicy="strict-origin-when-cross-origin" allowFullScreen /> |
| </Dialog.Close> | ||
| <Dialog.Title className="text-lg font-semibold"> | ||
| AI Kurz | ||
| </Dialog.Title> |
Copilot
AI
Nov 11, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing Dialog.Description for accessibility. Radix UI Dialog components should include a description for screen readers to properly announce the modal content.
Add a description after the title:
<Dialog.Title className="text-lg font-semibold">
AI Kurz
</Dialog.Title>
<Dialog.Description className="sr-only">
Podívejte se na naše video o AI kurzu a přihlaste se
</Dialog.Description>If you want to keep the description visible, remove sr-only class.
| </Dialog.Title> | |
| </Dialog.Title> | |
| <Dialog.Description className="sr-only"> | |
| Podívejte se na naše video o AI kurzu a přihlaste se | |
| </Dialog.Description> |
| useEffect(() => { | ||
| if (router.asPath.startsWith("/kurz-ai")) { | ||
| setTimeout(handleClose, 500) | ||
| } | ||
| }, [router.asPath]) |
Copilot
AI
Nov 11, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This useEffect has multiple issues:
- Missing cleanup for
setTimeout- can cause memory leaks and unexpected behavior - Missing
handleClosein dependency array - can lead to stale closures
Fix both issues:
useEffect(() => {
const cleanup = () => {
document.cookie = `${MODAL_COOKIE_KEY}=true; path=/; max-age=${60 * 60 * 24 * 365}; SameSite=Lax`
setIsOpen(false)
}
if (router.asPath.startsWith("/kurz-ai")) {
const timeoutId = setTimeout(cleanup, 500)
return () => clearTimeout(timeoutId)
}
}, [router.asPath])Alternatively, wrap handleClose with useCallback and include it in the dependency array.
|
|
||
| <div className="mt-4"> | ||
| <p className="text-gray-600"> | ||
| <iframe className='w-full aspect-video' src="https://www.youtube.com/embed/ZXB3XTZRtdk" title="Pozvánka na AI kurz" frameBorder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" referrerPolicy="strict-origin-when-cross-origin" allowFullScreen /> |
Copilot
AI
Nov 11, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The frameBorder attribute is deprecated in HTML5. Use the CSS border property instead or remove this attribute as modern browsers default to no border for iframes.
Replace frameBorder="0" with inline style or CSS class:
<iframe className='w-full aspect-video border-0' ... />| <iframe className='w-full aspect-video' src="https://www.youtube.com/embed/ZXB3XTZRtdk" title="Pozvánka na AI kurz" frameBorder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" referrerPolicy="strict-origin-when-cross-origin" allowFullScreen /> | |
| <iframe className='w-full aspect-video border-0' src="https://www.youtube.com/embed/ZXB3XTZRtdk" title="Pozvánka na AI kurz" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" referrerPolicy="strict-origin-when-cross-origin" allowFullScreen /> |
feat(legacy): 💄 add recommendation for our AI course
WIP: Needs changing main video
This reverts banner feature commits.