Inline output of some html widgets unreadable with dark theme


#1

I use formattable a lot for the nice html tables (I think this is what an html widget is?) but when I am using a dark theme the inline output text seems to get converted to a light color without the background getting converted to dark:

This isn’t much of an issue for me since I usually go through and pipe (then?) all the outputs to formattable once my analysis is done, but the Using Theme with Preview reminded me of it and I thought it might be helpful to have this pointed out too. I think I remember it affecting another widget too but for the life of me, I can’t remember which.


#2

Thanks for the feedback! For what it’s worth, in Notebook mode, RStudio presents tables in a paginated tabular view, and this should respect the current theme:

Is this alternate presentation a suitable replacement, or are you using some features specific to formattable()?


#3

Oh yeah, this works the same way with .Rmd and I absolutely love it! (I really need to spend some time reading up on .Rmd vs notebooks) It works flawlessly for interactive analysis. I usually add formattable at the end so I can format things nicely for whoever I am sending the report to, so that’s where it comes into play opposed to during the analysis. As I said it’s super minor since I only see if it I go to update something interactively after my initial creation of the report.


#4

@kevinushey Just to let you know the WILDEST thing I just came across.

If you go to the line directly following one of these outputs and press return, then it magically makes the colors click into place:

then go to line 119 and press return:

Pressing return on line 120 will have no effect :joy:. I can not stop cracking up at this, probably my favorite workaround of all time.

Again, nothing that is likely worth dedicating resources too, but the concept that hitting enter in just the right place somehow fixes my issue was so funny that I had to share it with someone :smile: