10000 chore: remove blur from boverlay in cases where its not allowed by br… by VividLemon · Pull Request #2712 · bootstrap-vue-next/bootstrap-vue-next · GitHub
[go: up one dir, main page]

Skip to content

chore: remove blur from boverlay in cases where its not allowed by br… #2712

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

Merged
merged 2 commits into from
May 26, 2025
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
15 changes: 9 additions & 6 deletions apps/docs/src/docs/components/overlay.md
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ Control the opacity of the backdrop via the `opacity` prop (opacity values can r
</div>
{{ opacity.toFixed(2) }}
<div>
<label for="bg-blur">Blur</label>
<label for="bg-blur">Blur (does not work if variant is anything other than 'transparent' or 'white' or if bgColor is defined)</label>
<BFormSelect id="bg-blur" v-model="blur" :options="blurs" />
</div>
</div>
Expand Down Expand Up @@ -144,7 +144,10 @@ Control the opacity of the backdrop via the `opacity` prop (opacity values can r
{{ opacity.toFixed(2) }}

<div>
<label for="bg-blur">Blur</label>
<label for="bg-blur"
>Blur (does not work if variant is anything other than 'transparent' or 'white' or if
bgColor is defined)</label
>
<BFormSelect id="bg-blur" v-model="blur" :options="blurs" />
</div>
</div>
Expand Down Expand Up @@ -183,10 +186,10 @@ const variants = [
'danger',
'warning',
'info',
]
] as const
const blurs = [{text: 'None', value: ''}, '1px', '2px', '5px', '0.5em', '1rem']

const variant = ref('light')
const variant = ref<(typeof variants)[number]>('light')
const opacity = ref(0.85)
const blur = ref('2px')
</script>
Expand Down Expand Up @@ -934,7 +937,6 @@ import {ref, nextTick} from 'vue';
const showOverlayEx1 = ref(false)
const showRoundedEx = ref(false)

const variant = ref('light')
const opacity = ref(0.85)
const blur = ref('2px')
const variants = [
Expand All @@ -948,7 +950,8 @@ const variants = [
'danger',
'warning',
'info',
]
] as const
const variant = ref('light')
const blurs = [
{ text: 'None', value: '' },
'1px',
Expand Down
6 changes: 6 additions & 0 deletions apps/docs/src/docs/migration-guide.md
Original file line number Diff line number Diff line change
Expand Up @@ -587,6 +587,12 @@ The `type` prop is deprecated. Use the the `v-b-color-mode` directive or `useCol

See [Show and Hide](#show-and-hide) shared properties.

### BOverlay

<NotYetDocumented type="component"/>

prop `blur` does not work when the prop `bgColor` is defined. It also will not work if the prop `variant` is anything other than `white` or `transparent`. This overcomes a browser change.

### BPagination

See [Show and Hide](#show-and-hide) shared properties.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,10 @@ const blurStyles = computed(() => ({
...positionStyles,
opacity: props.opacity,
backgroundColor: props.bgColor || undefined,
backdropFilter: props.blur ? `blur(${props.blur})` : undefined,
backdropFilter:
props.blur && !props.bgColor && (props.variant === 'white' || props.variant === 'transparent')
? `blur(${props.blur})`
: undefined,
}))

const spinWrapperStyles = computed(() =>
Expand Down
0