The transition to the block hyperlink on the center of the screen?

When you click on the link https://site.ru/main/#firstblock
the browser immediately scrolls to the first block, but only the very top border. I want to become the center of the screen, how to do it?
April 7th 20 at 15:43
1 answer
April 7th 20 at 15:45
put the link to the anchor where you want to stay
well, I ordered first block. only a very short block and stopped at its upper edge and it turns out that at the center of another unit. anyways not nice - Lyric.Rueck commented on April 7th 20 at 15:48
I don't see the code, and referring you threw on the locale - Fae_Berni commented on April 7th 20 at 15:51
@Lura, https://codepen.io/Kiara.Kloc/pen/OJVXxEm to play
create the blocks, throw the anchor and see where the screen flies - Fae_Berni commented on April 7th 20 at 15:54

Find more questions by tags CSSHTML