Skip to content

Commit

Permalink
fix: Remove brightness filter on secondary footer logos
Browse files Browse the repository at this point in the history
We had previously done this thinking that it would be generic to all partners, but it is specific to some. We're also adding css classes to better control these elements on the partner side.
  • Loading branch information
JF-Cozy committed Jul 30, 2024
1 parent 1f18b18 commit 763eed2
Showing 1 changed file with 7 additions and 11 deletions.
18 changes: 7 additions & 11 deletions src/components/FooterLogo/FooterLogo.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { useCozyTheme } from 'cozy-ui/transpiled/react/providers/CozyTheme'

export const FooterLogo = () => {
const client = useClient()
const { type, variant } = useCozyTheme()
const { type } = useCozyTheme()
const rootURL = client.getStackClient().uri

const contextQuery = buildContextQuery()
Expand All @@ -25,13 +25,15 @@ export const FooterLogo = () => {
<footer>
<Divider />
<div className="u-flex">
<div className="u-flex u-mh-auto u-maw-100 u-flex-items-center">
<div
className={`u-flex u-mh-auto u-maw-100 u-flex-items-center home-footer-logo-${type}`}
>
{hasMain ? (
<img
key={main.src}
src={`${rootURL}/assets${main.src}`}
alt={main.alt}
className="u-ph-1 u-pv-1 u-mah-3"
className={`u-ph-1 u-pv-1 u-mah-3 home-footer-logo-${type}--primary`}
/>
) : null}
{hasMain && hasSecondaries ? (
Expand All @@ -46,14 +48,8 @@ export const FooterLogo = () => {
key={src}
src={`${rootURL}/assets${src}`}
alt={alt}
className="u-ph-1 u-mah-3"
style={{
objectFit: 'contain',
filter:
type === 'dark' && variant === 'normal'
? 'brightness(10)'
: undefined
}}
className={`u-ph-1 u-mah-3 home-footer-logo-${type}--secondary`}
style={{ objectFit: 'contain' }}
/>
))}
</div>
Expand Down

0 comments on commit 763eed2

Please sign in to comment.