_testbrief.html 7.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449
  1. <div class="page grid" orientation="portrait" size="A4">
  2. <span class="falzmarke-oben">––</span>
  3. <span class="falzmarke-unten">––</span>
  4. <div class="seitenlogo">
  5. <img src="daten/logo_seite_dummy.svg" height="160px" alt="traeger_logo" />
  6. </div>
  7. <div class="header">
  8. <img class="logo" src="daten/top_dummy.svg" alt="Briefkopf" />
  9. <hr class="hr-rot hr" />
  10. </div>
  11. <div class="main">
  12. <div class="sidebar">
  13. <div class="sidebar-oben">
  14. Somewhere 12<br />12345 Nowhere
  15. <div class="voffset-1"></div>
  16. Telefon 0123 1412617<br />Telefax 0122 14214270<br />us@thisaddress.de<br />www.thisaddress.de
  17. <div class="voffset-1"></div>
  18. Bürozeiten:<br />Mo. und Do.<br />07:15 – 12:30 Uhr<br />13:30 – 15:30 Uhr<br />Di., Mi. und Fr.<br />07:15 – 13:30 Uhr
  19. <div class="voffset-1"></div>
  20. {(new Date().toLocaleDateString('de', {day: '2-digit', month: '2-digit', year: 'numeric'}))}<br />
  21. <slot name="kuerzel"></slot>
  22. </div>
  23. <div class="sidebar-unten">
  24. Important stuff:
  25. <div class="voffset-1"></div>
  26. <b>This here</b><br />Foo<br />Bar
  27. <div class="voffset-1"></div>
  28. <b>That</b><br />Hoo<br />Haaaaaaaaa<br />jOOOOOOOO<br />weeeeeee waaaa<br />wuuu
  29. <div class="voffset-1"></div>
  30. <b>gggggggg</b><br />wedwedwae wedw wdweewe
  31. <div class="voffset-1"></div>
  32. <b>wedwedwedwed</b><br />dwedwefffff/<br />Hewq)wedwef
  33. <div class="voffset-1"></div>
  34. <b>Weitere Informationen:</b><br />www.thisaddress.de
  35. </div>
  36. </div>
  37. <div class="links">
  38. <div class="absender">
  39. Me somewhere<br /><b>at this place</b>· Postfach 123 456 · 12345 Nowhere
  40. </div>
  41. <div class="anschrift">
  42. <slot name="anschrift"></slot>
  43. </div>
  44. <div class="anschreiben">
  45. <slot></slot>
  46. </div>
  47. </div>
  48. </div>
  49. </div>
  50. <style>
  51. .page {
  52. font-size: 1.2em;
  53. line-height: 1.5;
  54. font-weight: normal;
  55. font-family: "Tex Gyre Heros";
  56. color: #333;
  57. position: relative;
  58. padding: 0;
  59. display: block;
  60. }
  61. .grid {
  62. display: grid;
  63. align-content: stretch;
  64. grid-template-rows: 35mm auto;
  65. grid-template-areas:
  66. "header"
  67. "main";
  68. }
  69. .header {
  70. display: grid;
  71. grid-area: header;
  72. align-self: start;
  73. margin-left: 24.1mm;
  74. margin-right: 8.1mm;
  75. grid-template-columns: auto;
  76. grid-template-rows: auto;
  77. grid-template-areas:
  78. "logo"
  79. "hr";
  80. }
  81. .logo {
  82. justify-content: end;
  83. margin-top: 10mm;
  84. grid-area: logo;
  85. margin-left: auto;
  86. height: 20mm;
  87. }
  88. .hr {
  89. grid-area: hr;
  90. align-self: end;
  91. }
  92. .main {
  93. grid-area: main;
  94. align-content: stretch;
  95. display: grid;
  96. grid-template-columns: 2fr 1fr;
  97. height: 100%;
  98. grid-template-areas:
  99. "links sidebar";
  100. }
  101. .links {
  102. display: grid;
  103. grid-area: links;
  104. grid-template-rows: 10mm 40mm auto;
  105. margin-bottom: 10mm;
  106. grid-template-areas:
  107. "absender"
  108. "anschrift"
  109. "anschreiben";
  110. }
  111. .absender {
  112. grid-area: absender;
  113. font-size: 7.5pt;
  114. margin-left: 20mm;
  115. }
  116. .anschrift {
  117. grid-area: anschrift;
  118. font-size: 11pt;
  119. margin-left: 25mm;
  120. }
  121. .anschreiben {
  122. grid-area: anschreiben;
  123. font-size: 11pt;
  124. margin-left: 25mm;
  125. width: 115mm;
  126. }
  127. .sidebar {
  128. display: grid;
  129. margin-right: 8.1mm;
  130. justify-self: end;
  131. grid-area: sidebar;
  132. margin-bottom: 10mm;
  133. grid-template-rows: auto;
  134. grid-template-areas:
  135. "sidebar-oben"
  136. "sidebar-unten";
  137. }
  138. .sidebar-oben {
  139. grid-area: sidebar-oben;
  140. align-self: start;
  141. }
  142. .sidebar-unten {
  143. grid-area: sidebar-unten;
  144. align-self: end;
  145. }
  146. .flex-grid {
  147. display: flex;
  148. }
  149. .col {
  150. flex: 1;
  151. }
  152. .col-2 {
  153. flex: 2;
  154. }
  155. @import url(normalize.css);
  156. @font-face {
  157. font-family: 'TeX Gyre Heros';
  158. src: url("texgyreheros-regular-webfont.woff") format("woff");
  159. font-style: normal;
  160. }
  161. @font-face {
  162. font-family: 'TeX Gyre Heros';
  163. src: url("texgyreheros-bold-webfont.woff") format("woff");
  164. font-style: normal;
  165. font-weight: bold;
  166. }
  167. @font-face {
  168. font-family: 'TeX Gyre Heros';
  169. src: url("texgyreheros-italic-webfont.woff") format("woff");
  170. font-style: italic;
  171. }
  172. @font-face {
  173. font-family: 'TeX Gyre Heros';
  174. src: url("texgyreheros-bolditalic-webfont.woff") format("woff");
  175. font-style: italic;
  176. font-weight: bold;
  177. }
  178. @media print {
  179. * {
  180. -webkit-print-color-adjust: exact;
  181. }
  182. .page {
  183. page-break-after: always;
  184. page-break-inside: avoid;
  185. margin: 0;
  186. }
  187. }
  188. /*
  189. Da *named pages*, also z.B. @page a3landscape noch nicht von Chrome
  190. unterstützt werden, gilt vorerst die Standard-Einstellung von A4 Portrait.
  191. Um andere Formate zu erzeugen, muss die Größe in den svelte-Koponenten
  192. als setup-Einstellung hinterlegt werden. Oder man verwendet ein besonderes CSS
  193. mit der anderen Einstellung.
  194. Dazu bitte ein @import 'nicht_a4_portrait.css' verwenden. Svelte ignoriert sonst
  195. die in den <style> tags hinterlegten @... Anweisungen.
  196. Link: https://www.w3.org/TR/css3-page/#using-named-pages
  197. */
  198. .page[size="A4"][orientation="portrait"] {
  199. page: a4portrait;
  200. width: 210mm;
  201. height: 296.8mm;
  202. }
  203. @page a4portrait {
  204. margin: 0;
  205. size: A4 portrait;
  206. }
  207. .page[size="A4"][orientation="landscape"] {
  208. page: a4landscape;
  209. width: 296.8mm;
  210. height: 210mm;
  211. }
  212. @page a4landscape {
  213. margin: 0;
  214. size: A4 landscape;
  215. }
  216. .page[size="A3"][orientation="portrait"] {
  217. page: a3portrait;
  218. width: 296.8mm;
  219. height: 420mm;
  220. }
  221. @page a3portrait {
  222. margin: 0;
  223. size: A3 portrait;
  224. }
  225. .page[size="A3"][orientation="landscape"] {
  226. page: a3landscape;
  227. width: 420mm;
  228. height: 296.8mm;
  229. }
  230. @page a3landscape {
  231. margin: 0;
  232. size: A3 landscape;
  233. }
  234. .page[size="A5"][orientation="portrait"] {
  235. page: a5portrait;
  236. width: 148mm;
  237. height: 210mm;
  238. }
  239. @page a5portrait {
  240. margin: 0;
  241. size: A5 portrait;
  242. }
  243. .page[size="A5"][orientation="landscape"] {
  244. page: a5landscape;
  245. width: 210mm;
  246. height: 148mm;
  247. }
  248. @page a5landscape {
  249. margin: 0;
  250. size: A5 landscape;
  251. }
  252. @media screen {
  253. .page {
  254. border: 1px solid black;
  255. box-shadow: 5px 5px 4px 0 silver;
  256. }
  257. }
  258. svelte {
  259. font-size: 62.5%;
  260. }
  261. /* Typography */
  262. h1, h2, h3, h4, h5, h6 {
  263. margin-top: 0;
  264. margin-bottom: 0;
  265. font-weight: 400;
  266. }
  267. h1 {
  268. font-size: 4.0em;
  269. line-height: 1.2;
  270. letter-spacing: -.1em;
  271. }
  272. h2 {
  273. font-size: 3.6em;
  274. line-height: 1.25;
  275. letter-spacing: -.1em;
  276. }
  277. h3 {
  278. font-size: 3.0em;
  279. line-height: 1.3;
  280. letter-spacing: -.1em;
  281. }
  282. h4 {
  283. font-size: 2.4em;
  284. line-height: 1.35;
  285. letter-spacing: -.08em;
  286. }
  287. h5 {
  288. font-size: 1.8em;
  289. line-height: 1.5;
  290. letter-spacing: -.05em;
  291. }
  292. h6 {
  293. font-size: 1.5em;
  294. line-height: 1.6;
  295. letter-spacing: 0;
  296. }
  297. p {
  298. margin-top: 0;
  299. }
  300. .voffset-halb {
  301. margin-top: 0.5em;
  302. }
  303. .voffset-1 {
  304. margin-top: 1em;
  305. }
  306. .voffset-2 {
  307. margin-top: 2em;
  308. }
  309. .voffset-3 {
  310. margin-top: 3em;
  311. }
  312. .voffset-4 {
  313. margin-top: 4em;
  314. }
  315. .voffset-5 {
  316. margin-top: 5em;
  317. }
  318. .voffset-6 {
  319. margin-top: 6em;
  320. }
  321. .voffset-7 {
  322. margin-top: 7em;
  323. }
  324. .voffset-8 {
  325. margin-top: 8em;
  326. }
  327. .voffset-9 {
  328. margin-top: 9em;
  329. }
  330. .voffset-10 {
  331. margin-top: 10em;
  332. }
  333. .voffset-11 {
  334. margin-top: 11em;
  335. }
  336. .voffset-12 {
  337. margin-top: 12em;
  338. }
  339. .voffset-13 {
  340. margin-top: 13em;
  341. }
  342. .voffset-14 {
  343. margin-top: 14em;
  344. }
  345. .voffset-15 {
  346. margin-top: 15em;
  347. }
  348. .voffset-16 {
  349. margin-top: 16em;
  350. }
  351. .voffset-17 {
  352. margin-top: 17em;
  353. }
  354. .voffset-18 {
  355. margin-top: 18em;
  356. }
  357. .voffset-19 {
  358. margin-top: 19em;
  359. }
  360. .voffset-20 {
  361. margin-top: 20em;
  362. }
  363. .text-center {
  364. text-align: center !important;
  365. }
  366. hr {
  367. border: 0;
  368. border-top: 1px solid #eee;
  369. border-color: #000;
  370. height: 1px;
  371. margin: 3px 0;
  372. }
  373. .hr-rot {
  374. border-color: #ff2700;
  375. margin: 8px 0;
  376. }
  377. .hr-grau {
  378. border-color: #646464 !important;
  379. }
  380. .falzmarke-oben {
  381. position: absolute;
  382. top: 105mm;
  383. left: 10mm;
  384. }
  385. .falzmarke-unten {
  386. position: absolute;
  387. top: 210mm;
  388. left: 10mm;
  389. }
  390. </style>