Changes for page LSS-P - Mechanical
Last modified by Eric Nantel on 2024/07/03 09:43
Change comment: There is no comment for this version
Summary
-
Page properties (1 modified, 0 added, 0 removed)
Details
- Page properties
-
- Content
-
... ... @@ -15,64 +15,62 @@ 15 15 16 16 /* Media query for mobile devices */ 17 17 @media only screen and (max-width: 600px) { 18 - /* Stackthe tablecolumnsvertically */19 - td { 18 + /* Remove the table's default styles */ 19 + table, thead, tbody, th, td, tr { 20 20 display: block; 21 21 } 22 22 23 - /* Add spacing between stacked columns */ 24 - td:not(:first-child) { 25 - margin-top: 10px; 23 + /* Hide table headers (th) */ 24 + thead tr { 25 + position: absolute; 26 + top: -9999px; 27 + left: -9999px; 26 26 } 27 27 28 - /* Hide table headers (th) */ 29 - th { 30 - display: none; 30 + td { 31 + border: none; 32 + position: relative; 33 + padding-left: 50%; 31 31 } 35 + 36 + /* Add a background color to the table rows */ 37 + tr { 38 + margin-bottom: 20px; 39 + } 40 + 41 + /* Display the data in each cell */ 42 + td:before { 43 + position: absolute; 44 + top: 6px; 45 + left: 6px; 46 + width: 45%; 47 + padding-right: 10px; 48 + white-space: nowrap; 49 + } 32 32 } 33 33 </style> 34 34 </head> 35 35 <body> 36 36 <table> 55 + <thead> 56 + <tr> 57 + <th>Name</th> 58 + <th>Age</th> 59 + <th>Email</th> 60 + </tr> 61 + </thead> 37 37 <tbody> 38 38 <tr> 39 - <td> 40 - <table> 41 - <thead> 42 - <tr> 43 - <th>Column 1</th> 44 - </tr> 45 - </thead> 46 - <tbody> 47 - <tr> 48 - <td>Data 1</td> 49 - </tr> 50 - <tr> 51 - <td>Data 3</td> 52 - </tr> 53 - <!-- Add more rows as needed --> 54 - </tbody> 55 - </table> 56 - </td> 57 - <td> 58 - <table> 59 - <thead> 60 - <tr> 61 - <th>Column 2</th> 62 - </tr> 63 - </thead> 64 - <tbody> 65 - <tr> 66 - <td>Data 2</td> 67 - </tr> 68 - <tr> 69 - <td>Data 4</td> 70 - </tr> 71 - <!-- Add more rows as needed --> 72 - </tbody> 73 - </table> 74 - </td> 64 + <td>John Doe</td> 65 + <td>25</td> 66 + <td>[email protected]</td> 75 75 </tr> 68 + <tr> 69 + <td>Jane Smith</td> 70 + <td>30</td> 71 + <td>[email protected]</td> 72 + </tr> 73 + <!-- Add more rows as needed --> 76 76 </tbody> 77 77 </table> 78 78 </body>