-
Notifications
You must be signed in to change notification settings - Fork 462
Integrated tab bar UI elements #7853
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: main
Are you sure you want to change the base?
Changes from all commits
1dc578a
142dc4d
720c49d
2d169db
24eaaf4
d6bef9b
6de7b79
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,134 @@ | ||
| <template> | ||
| <!-- Help Center Popup positioned within canvas area --> | ||
| <Teleport to="#graph-canvas-container"> | ||
| <div | ||
| v-if="isHelpCenterVisible" | ||
| class="help-center-popup" | ||
| :class="{ | ||
| 'sidebar-left': | ||
| triggerLocation === 'sidebar' && sidebarLocation === 'left', | ||
| 'sidebar-right': | ||
| triggerLocation === 'sidebar' && sidebarLocation === 'right', | ||
| 'topbar-right': triggerLocation === 'topbar', | ||
| 'small-sidebar': isSmall | ||
| }" | ||
| > | ||
| <HelpCenterMenuContent @close="closeHelpCenter" /> | ||
| </div> | ||
| </Teleport> | ||
|
|
||
| <!-- Release Notification Toast positioned within canvas area --> | ||
| <Teleport to="#graph-canvas-container"> | ||
| <ReleaseNotificationToast | ||
| :class="{ | ||
| 'sidebar-left': sidebarLocation === 'left', | ||
| 'sidebar-right': sidebarLocation === 'right', | ||
| 'small-sidebar': isSmall | ||
| }" | ||
| /> | ||
| </Teleport> | ||
|
|
||
| <!-- WhatsNew Popup positioned within canvas area --> | ||
| <Teleport to="#graph-canvas-container"> | ||
| <WhatsNewPopup | ||
| :class="{ | ||
| 'sidebar-left': sidebarLocation === 'left', | ||
| 'sidebar-right': sidebarLocation === 'right', | ||
| 'small-sidebar': isSmall | ||
| }" | ||
| @whats-new-dismissed="handleWhatsNewDismissed" | ||
| /> | ||
| </Teleport> | ||
|
|
||
| <!-- Backdrop to close popup when clicking outside --> | ||
| <Teleport to="body"> | ||
| <div | ||
| v-if="isHelpCenterVisible" | ||
| class="help-center-backdrop" | ||
| @click="closeHelpCenter" | ||
| /> | ||
| </Teleport> | ||
| </template> | ||
|
|
||
| <script setup lang="ts"> | ||
| import { useHelpCenter } from '@/composables/useHelpCenter' | ||
| import ReleaseNotificationToast from '@/platform/updates/components/ReleaseNotificationToast.vue' | ||
| import WhatsNewPopup from '@/platform/updates/components/WhatsNewPopup.vue' | ||
|
|
||
| import HelpCenterMenuContent from './HelpCenterMenuContent.vue' | ||
|
|
||
| const { isSmall = false } = defineProps<{ | ||
| isSmall?: boolean | ||
| }>() | ||
|
|
||
| const { | ||
| isHelpCenterVisible, | ||
| triggerLocation, | ||
| sidebarLocation, | ||
| closeHelpCenter, | ||
| handleWhatsNewDismissed | ||
| } = useHelpCenter() | ||
| </script> | ||
|
|
||
| <style scoped> | ||
| .help-center-backdrop { | ||
| position: absolute; | ||
| top: 0; | ||
| left: 0; | ||
| right: 0; | ||
| bottom: 0; | ||
| z-index: 9999; | ||
| background: transparent; | ||
| } | ||
|
|
||
| .help-center-popup { | ||
| position: absolute; | ||
| bottom: 1rem; | ||
| z-index: 10000; | ||
| animation: slideInUp 0.2s ease-out; | ||
| pointer-events: auto; | ||
| } | ||
|
|
||
| .help-center-popup.sidebar-left { | ||
| left: 1rem; | ||
| } | ||
|
|
||
| .help-center-popup.sidebar-left.small-sidebar { | ||
| left: 1rem; | ||
| } | ||
|
|
||
| .help-center-popup.sidebar-right { | ||
| right: 1rem; | ||
| } | ||
|
|
||
| .help-center-popup.topbar-right { | ||
| top: 2rem; | ||
| right: 1rem; | ||
| bottom: auto; | ||
| animation: slideInDown 0.2s ease-out; | ||
| } | ||
|
|
||
| @keyframes slideInDown { | ||
| from { | ||
| opacity: 0; | ||
| transform: translateY(-20px); | ||
| } | ||
|
|
||
| to { | ||
| opacity: 1; | ||
| transform: translateY(0); | ||
| } | ||
| } | ||
|
|
||
| @keyframes slideInUp { | ||
| from { | ||
| opacity: 0; | ||
| transform: translateY(20px); | ||
| } | ||
|
|
||
| to { | ||
| opacity: 1; | ||
| transform: translateY(0); | ||
| } | ||
| } | ||
| </style> | ||
|
Comment on lines
+73
to
+134
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧹 Nitpick | 🔵 Trivial Consider migrating custom CSS to Tailwind utilities. Per coding guidelines, Vue components should "Use Tailwind CSS only for styling (no custom CSS)" and "Use the correct tokens from style.css in the design system package." The current implementation uses:
While animations may require CSS, the positioning and z-index could leverage Tailwind utilities or design system tokens. If Tailwind's animation utilities don't suffice, consider extracting the keyframes to a shared CSS file or using 🤖 Prompt for AI Agents |
||
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.
Backdrop should use
position: fixedinstead ofabsolute.The backdrop is teleported to
bodybut usesposition: absolute. If the body has any positioned ancestors or if the page is scrollable, the backdrop may not cover the entire viewport correctly. Usingposition: fixedensures consistent full-viewport coverage.🔎 Proposed fix
.help-center-backdrop { - position: absolute; + position: fixed; top: 0; left: 0; right: 0; bottom: 0; z-index: 9999; background: transparent; }Also applies to: 74-82
🤖 Prompt for AI Agents