question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Adaptive color not working

See original GitHub issue

I’ve forked the hosted example and changed the scrollable area to have a black background. I’ve also changed the --focus-primary var to black. https://codesandbox.io/s/bold-sun-lx1im?file=/public/index.html

The focus ring should be adapting and showing a visible focus ring in this case right? At the moment it’s still just creating a black focus ring.

Issue Analytics

  • State:open
  • Created 2 years ago
  • Comments:7

github_iconTop GitHub Comments

1reaction
faultyservercommented, Oct 8, 2021

@Thisisjuke I think the behavior you’re seeing there, where the ring “detaches” from the element that it’s supposed to be tracking, is likely because you’re missing a FocusRingScope on the inside of the scrolling component. Without that, the ring renderer doesn’t think that anything is moving when you scroll, so you get this static-looking ring while everything else moves.

Something like:

<ScrollingContainer ref={scrollingRef}>
  <FocusRingScope containerRef={scrollingRef}>
    {...yourScrollableChildren}
  </FocusRingScope>
</ScrollingContainer>

should make the rings track the elements properly.

To your original question, if you want to just disable the ring while the scrolling happens, you can also pass the disabled prop to the FocusRing around the element itself, which will prevent it from rendering at all when set.

We will probably add some flexibility for being able to inject a “best color selector” function or the like in the future, but hopefully one or both of those solutions is sufficient for your use case.

0reactions
Thisisjukecommented, Jan 13, 2022

@faultyserver @dougmacknz Hello, there is a PR open since Dec 2, 2021. Can we have a status on this PR please ?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Armoury Crate Not Picking Up Adaptive Color : r/ASUS - Reddit
I am trying to use the Adaptive Color setting to have everything match my Wallpaper Engine ... Armoury Crate is not changing the...
Read more >
[ASUS Aura Creator] Aura Creator FAQ | Official Support
Aura Creator will get one color from the selected area as the “Adaptive Color” - you can decide to show the average color...
Read more >
Pixel 6 Adaptive color quit working after March update
After updating my Pixel 6 in late March both adaptive color and boosted color quit working. Colors appear washed out especially in the ......
Read more >
Turn On Adaptive Color on Your Echo Show - Amazon.com
Say, "Go to settings," or swipe down from the top of the screen and select Settings. Select Display. Use the switch to turn...
Read more >
Flutter Switch.Adaptive() not applying color to the cupertino ...
SwitchListTile.adaptive( value: false, activeColor: Colors.green, onChanged: (bool value) {}, title: Text( 'Vegetarian', style: TextStyle( ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found