Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!DOCTYPE html>
- <html lang="en">
- <head>
- <title>My Centered Tag</title>
- <meta charset="utf-8">
- <meta name="viewport" content="width=device-width, initial-scale=1">
- <style>
- html *{
- font-size: 35px !important;
- margin: 2px;
- }
- html,
- body {
- height: 100%;
- }
- @media only screen and (min-width: 600px) {
- body {
- margin-right:200px;
- margin-left:200px;
- margin-top: 0;
- }
- }
- .flex{
- display: grid;
- grid-row-gap: 1rem;
- grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
- }
- .grid{
- display: grid;
- place-items: center;
- }
- </style>
- <script>
- document.addEventListener("DOMContentLoaded", function(){
- });
- </script>
- </head>
- <body>
- <div class="grid" style="height:100%">
- <div>
- <button class="button">Button #1</button>
- <button class="button">Button #2</button>
- </div>
- </div>
- <div class="grid" style="height:100%">
- <div>
- <button class="button">Button #1</button>
- <button class="button">Button #2</button>
- </div>
- </div>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement