/    Sign up×
Community /Pin to ProfileBookmark

making border-spacing opaque

I have a page where I am making a table with a fixed thead section and the rest of the table scrollable. It works, but there is a small issue with border-spacing between table cells. I am not changing the value, so it remains set to the default of 2px. However, when the lower section of the table scrolls up, you can see it as it passes through the transparent border-spacing. How do I go about making the spacing opaque so what’s behind it is no longer visible?

Also, when I scroll the table up, the thead section moves up one pixel-row. It is supposed to be fixed, so I don’t know what’s causing that to happen either. The border-collapse and table-layout properties had no effect, which is why they are commented out. There is no specific html code to show, since the css operates directly on the table and thead tags.

`
table {
margin:auto;
/* border-collapse:separate;
table-layout:fixed;*/
}

/* freeze panes */
/*
rows */
thead {
position:sticky;
top:0;
min-height:48px;
height:48px;
z-index:50;
background-color:white;
}
`

to post a comment
CSS

0Be the first to comment 😎

×

Success!

Help @WayneCa spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 6.17,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @nearjob,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,
)...