Skip to content

Instantly share code, notes, and snippets.

@everlof
Last active September 15, 2018 11:36
Show Gist options
  • Save everlof/275783ccc73608e5f46200ad434d6925 to your computer and use it in GitHub Desktop.
Save everlof/275783ccc73608e5f46200ad434d6925 to your computer and use it in GitHub Desktop.
<html>
<head>
<meta charset="UTF-8" />
<style>
html{font-family: Avenir-Book;}
h1{font-size: 16px;}
@page {size: A3; margin: 0mm 0mm 0mm 0mm;}
@media print {
.month{
page-break-after: always;
}
}
.header{-webkit-print-color-adjust: exact;height: 30%;background-color: red !important;}
.content{-webkit-print-color-adjust: exact;height: 70%;background-color: blue !important;}
table{table-layout: fixed;height: 100%;width: 100%;}
.header h1{color: #74cc82;position: relative;transform: translateY(-50%);-webkit-transform: translateY(-50%);top: 50%;font-size: 1200%;}
tr{height: 40px;}
th{font-size: 175%;}
td{font-size: 400%;text-align: center;}
th, td{color: #1a4567;}
td:last-child, th:last-child{color: #74cc82;}
</style>
</head>
<body>
<div class="month" style="background-color: red;" >
<div class="header" >
<h1 align="center" >
Janvier
</h1>
</div>
<div class="content" >
<table>
<tr>
<th>L</th>
<th>M</th>
<th>M</th>
<th>J</th>
<th>V</th>
<th>S</th>
<th>D</th>
</tr>
<tr>
<td>1</td>
<td>2</td>
<td>3</td>
<td>4</td>
<td>5</td>
<td>6</td>
<td>7</td>
</tr>
<tr>
<td>8</td>
<td>9</td>
<td>10</td>
<td>11</td>
<td>12</td>
<td>13</td>
<td>14</td>
</tr>
<tr>
<td>15</td>
<td>16</td>
<td>17</td>
<td>18</td>
<td>19</td>
<td>20</td>
<td>21</td>
</tr>
<tr>
<td>22</td>
<td>23</td>
<td>24</td>
<td>25</td>
<td>26</td>
<td>27</td>
<td>28</td>
</tr>
<tr>
<td>29</td>
<td>30
</td>
<td>31</td>
<td></td>
<td></td>
<td></td>
<td></td>
</tr>
</table>
</div>
</div>
<div class="month" style="background-color: red;" >
<div class="header" >
<h1 align="center" >
Janvier
</h1>
</div>
<div class="content" >
<table>
<tr>
<th>L</th>
<th>M</th>
<th>M</th>
<th>J</th>
<th>V</th>
<th>S</th>
<th>D</th>
</tr>
<tr>
<td>1</td>
<td>2</td>
<td>3</td>
<td>4</td>
<td>5</td>
<td>6</td>
<td>7</td>
</tr>
<tr>
<td>8</td>
<td>9</td>
<td>10</td>
<td>11</td>
<td>12</td>
<td>13</td>
<td>14</td>
</tr>
<tr>
<td>15</td>
<td>16</td>
<td>17</td>
<td>18</td>
<td>19</td>
<td>20</td>
<td>21</td>
</tr>
<tr>
<td>22</td>
<td>23</td>
<td>24</td>
<td>25</td>
<td>26</td>
<td>27</td>
<td>28</td>
</tr>
<tr>
<td>29</td>
<td>30
</td>
<td>31</td>
<td></td>
<td></td>
<td></td>
<td></td>
</tr>
</table>
</div>
</div>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment