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.

Suggestion: allow to set custom focus colors for series

See original GitHub issue

Hi! What do you think about to allow to set series focus color? Currently focus behavior just change alpha of series color, but if I want to make focus behavior a little different (e.g. B&W vs Colored, or a bit darken unfocused lines) I should change colors of series manually and call .redraw(). I suggest just add property focusStroke/focusFill/... for series for custom focus colors.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:11 (11 by maintainers)

github_iconTop GitHub Comments

1reaction
leeoniyacommented, Jan 11, 2021

here’s the path of least resistance, i think:

add a ._focus property to each series that gets toggled here:

https://github.com/leeoniya/uPlot/blob/e870fc16cef352fb283a050957ec08374e21a47f/src/uPlot.js#L1854-L1856

then each series can implement dynamic styling by checking that property.

e.g.

https://github.com/leeoniya/uPlot/blob/e870fc16cef352fb283a050957ec08374e21a47f/demos/gradient-fill.html#L73-L81

can you try this route and see how it works out?

0reactions
zefirkacommented, Mar 12, 2021

@leeoniya Ok, thanks for mention!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Set up a Focus on iPhone - Apple Support
Choose a color and an icon to represent your Focus, then tap Next. Tap Customize Focus, then set up the options for your...
Read more >
iOS 15: How to Customize a Focus - MacRumors
If you want to customize a Focus that's already set up, you can do so by going into Settings -> Focus and selecting...
Read more >
Set Up These 6 Focus Modes to Make the Most of iOS 15
Through custom or suggested Focus modes, your iPhone can help you achieve your goals instead of distracting you from them.
Read more >
A guide to designing accessible, WCAG-compliant focus ...
A guide to designing accessible, WCAG-compliant focus indicators. Published on 13 Aug, 2021 | Last updated on 05 Sep, ...
Read more >
How to set up and use Focus modes on iOS 16 - Computerworld
Apple has packed all the Focus creation tools into one very busy page. To understand the controls on the page, we'll create a...
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