Skip to content
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

Update banner spacing and add rounded corners #2117

Merged
merged 7 commits into from
May 19, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 16 additions & 10 deletions frontend/src/components/VBanner/VBanners.vue
Original file line number Diff line number Diff line change
@@ -1,14 +1,16 @@
<template>
<div>
<VMigrationNotice
v-if="shouldShowMigrationBanner"
@close="dismissBanner('cc-referral')"
/>
<VTranslationStatusBanner
v-if="shouldShowTranslationBanner"
:banner-key="translationBannerId"
@close="dismissBanner(translationBannerId)"
/>
<div v-show="showBanners" class="flex flex-col gap-2 p-2 pb-0">
<VMigrationNotice
v-if="shouldShowMigrationBanner"
@close="dismissBanner('cc-referral')"
/>
<VTranslationStatusBanner
v-if="shouldShowTranslationBanner"
:banner-key="translationBannerId"
@close="dismissBanner(translationBannerId)"
/>
</div>
</div>
</template>

Expand Down Expand Up @@ -42,11 +44,15 @@ export default defineComponent({
uiStore.dismissBanner(bannerKey)
}
const showBanners = computed(
() => shouldShowMigrationBanner.value || shouldShowTranslationBanner.value
)
return {
translationBannerId,
shouldShowMigrationBanner,
shouldShowTranslationBanner,
showBanners,
dismissBanner,
}
},
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/components/VBanner/VNotificationBanner.vue
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<template>
<section
class="flex items-center justify-between gap-x-2 px-4 py-2 md:px-7"
class="flex items-center justify-between gap-x-2 rounded-sm px-4 py-2 md:px-7"
:class="$style[variant]"
:data-testid="`banner-${id}`"
>
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/layouts/content-layout.vue
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
: 'grid-cols-1',
]"
>
<div class="header-el sticky top-0 z-40 block">
<div class="header-el sticky top-0 z-40 block bg-white">
zackkrida marked this conversation as resolved.
Show resolved Hide resolved
<VTeleportTarget name="skip-to-content" :force-destroy="true" />
<VBanners />
<template v-if="isSearchHeader">
Expand Down