How to render graphics when you switch tabs?

Good afternoon. I can not solve the problem.
The page includes three tabs. Each tab will display your graph with the data. Charts are built using the library The problem is that when the page loads, it displays only the graph on the active tab when you switch to other tabs there, all the graphics disappear.
How can I make to display all the graphs?
Thanks in advance for your help.
This is a link to the code files
Thanks for the solution. There was a second question.
And how can you make so that when active, for example the second tab, after the page refreshes, she remained active and did not go back to the which spelled checked ?
September 19th 19 at 12:10
1 answer
September 19th 19 at 12:12
The fastest way to do this is to transfer some of the styles for the scripts, that is, to first otrisovka the canvas, and then it disappeared. For example, if you transfer these styles in the last closing script tag, then everything will work:

section#content4 {
 display: none;
 padding: 0px;
 background: #fff;
 border-top: 5px solid #fff;

#tab1:checked ~ #content1,
#tab2:checked ~ #content2,
#tab3:checked ~ #content3,
#tab4:checked ~ #content4 {
 display: block;
Thank you, it works - alfredo.Emard73 commented on September 19th 19 at 12:15

Find more questions by tags HTMLCSS