Skip to content

Commit

Permalink
Merge pull request #267 from tafel/master
Browse files Browse the repository at this point in the history
Better styles for scissors in HTML output
  • Loading branch information
sprain authored Nov 22, 2024
2 parents bc66bbc + 0ddff27 commit a28e081
Show file tree
Hide file tree
Showing 132 changed files with 2,023 additions and 953 deletions.
16 changes: 13 additions & 3 deletions src/PaymentPart/Output/HtmlOutput/Template/PaymentPartTemplate.php
Original file line number Diff line number Diff line change
Expand Up @@ -49,14 +49,14 @@ class PaymentPartTemplate
#qr-bill-payment-part h2 {
font-size: 8pt !important;
line-height: 11pt !important;
line-height: 11pt !important;
margin-top: 11pt !important;
color: #000 !important;
}
#qr-bill-receipt h2 {
font-size: 6pt !important;
line-height: 8pt !important;
line-height: 8pt !important;
margin-top: 8pt !important;
color: #000 !important;
}
Expand Down Expand Up @@ -179,6 +179,16 @@ class PaymentPartTemplate
margin-top: -11pt;
}
#qr-bill-scissors {
display: none;
float: right;
width: 1mm;
line-height: 1mm;
font-size: 22px;
font-weight: normal;
position: relative;
}
{{ printable-content }}
</style>
Expand All @@ -188,7 +198,7 @@ class PaymentPartTemplate
</tr>
<tr>
<td id="qr-bill-receipt">
<h1>{{ text.receipt }}</h1>
<h1>{{ text.receipt }}<span id="qr-bill-scissors">&#9986;</span></h1>
<div id="qr-bill-information-receipt">
{{ information-content-receipt }}
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,26 +35,20 @@ class PrintableStylesTemplate
left: -23mm;
}
#qr-bill-receipt:after {
transform: rotate(90deg);
#qr-bill-scissors {
display: inline-block;
content: '\\2702';
position: fixed;
font-size: 16pt;
top: 12.5mm;
left: 61.1mm;
transform: rotate(90deg);
top: 2mm;
left: 0.7mm;
}
EOT;

public const TEMPLATE_VERTICAL_SCISSORS_DOWN = <<<EOT
#qr-bill-receipt:after {
transform: rotate(-90deg);
#qr-bill-scissors {
display: inline-block;
content: '\\2702';
position: fixed;
font-size: 16pt;
top: 91.8mm;
left: 61.7mm;
transform: rotate(-90deg);
top: 80mm;
left: 1.0mm;
}
EOT;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,14 @@

#qr-bill-payment-part h2 {
font-size: 8pt !important;
line-height: 11pt !important;
line-height: 11pt !important;
margin-top: 11pt !important;
color: #000 !important;
}

#qr-bill-receipt h2 {
font-size: 6pt !important;
line-height: 8pt !important;
line-height: 8pt !important;
margin-top: 8pt !important;
color: #000 !important;
}
Expand Down Expand Up @@ -172,6 +172,16 @@
margin-top: -11pt;
}

#qr-bill-scissors {
display: none;
float: right;
width: 1mm;
line-height: 1mm;
font-size: 22px;
font-weight: normal;
position: relative;
}


</style>

Expand All @@ -181,7 +191,7 @@
</tr>
<tr>
<td id="qr-bill-receipt">
<h1>Receipt</h1>
<h1>Receipt<span id="qr-bill-scissors">&#9986;</span></h1>
<div id="qr-bill-information-receipt">
<h2>Account / Payable to</h2><p>CH44 3199 9123 0008 8901 2<br />
Thomas LeClaire<br />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,14 @@

#qr-bill-payment-part h2 {
font-size: 8pt !important;
line-height: 11pt !important;
line-height: 11pt !important;
margin-top: 11pt !important;
color: #000 !important;
}

#qr-bill-receipt h2 {
font-size: 6pt !important;
line-height: 8pt !important;
line-height: 8pt !important;
margin-top: 8pt !important;
color: #000 !important;
}
Expand Down Expand Up @@ -172,6 +172,16 @@
margin-top: -11pt;
}

#qr-bill-scissors {
display: none;
float: right;
width: 1mm;
line-height: 1mm;
font-size: 22px;
font-weight: normal;
position: relative;
}

#qr-bill-separate-info {
border-bottom: 0;
}
Expand All @@ -191,7 +201,7 @@
</tr>
<tr>
<td id="qr-bill-receipt">
<h1>Receipt</h1>
<h1>Receipt<span id="qr-bill-scissors">&#9986;</span></h1>
<div id="qr-bill-information-receipt">
<h2>Account / Payable to</h2><p>CH44 3199 9123 0008 8901 2<br />
Thomas LeClaire<br />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,14 @@

#qr-bill-payment-part h2 {
font-size: 8pt !important;
line-height: 11pt !important;
line-height: 11pt !important;
margin-top: 11pt !important;
color: #000 !important;
}

#qr-bill-receipt h2 {
font-size: 6pt !important;
line-height: 8pt !important;
line-height: 8pt !important;
margin-top: 8pt !important;
color: #000 !important;
}
Expand Down Expand Up @@ -172,6 +172,16 @@
margin-top: -11pt;
}

#qr-bill-scissors {
display: none;
float: right;
width: 1mm;
line-height: 1mm;
font-size: 22px;
font-weight: normal;
position: relative;
}

#qr-bill-separate-info {
border-bottom-style: dashed;
}
Expand All @@ -188,14 +198,11 @@
left: -23mm;
}

#qr-bill-receipt:after {
transform: rotate(90deg);
#qr-bill-scissors {
display: inline-block;
content: '\2702';
position: fixed;
font-size: 16pt;
top: 12.5mm;
left: 61.1mm;
transform: rotate(90deg);
top: 2mm;
left: 0.7mm;
}

#qr-bill-separate-info-text {
Expand All @@ -209,7 +216,7 @@
</tr>
<tr>
<td id="qr-bill-receipt">
<h1>Receipt</h1>
<h1>Receipt<span id="qr-bill-scissors">&#9986;</span></h1>
<div id="qr-bill-information-receipt">
<h2>Account / Payable to</h2><p>CH44 3199 9123 0008 8901 2<br />
Thomas LeClaire<br />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,14 @@

#qr-bill-payment-part h2 {
font-size: 8pt !important;
line-height: 11pt !important;
line-height: 11pt !important;
margin-top: 11pt !important;
color: #000 !important;
}

#qr-bill-receipt h2 {
font-size: 6pt !important;
line-height: 8pt !important;
line-height: 8pt !important;
margin-top: 8pt !important;
color: #000 !important;
}
Expand Down Expand Up @@ -172,6 +172,16 @@
margin-top: -11pt;
}

#qr-bill-scissors {
display: none;
float: right;
width: 1mm;
line-height: 1mm;
font-size: 22px;
font-weight: normal;
position: relative;
}

#qr-bill-separate-info {
border-bottom-style: dashed;
}
Expand All @@ -188,24 +198,18 @@
left: -23mm;
}

#qr-bill-receipt:after {
transform: rotate(90deg);
#qr-bill-scissors {
display: inline-block;
content: '\2702';
position: fixed;
font-size: 16pt;
top: 12.5mm;
left: 61.1mm;
transform: rotate(90deg);
top: 2mm;
left: 0.7mm;
}

#qr-bill-receipt:after {
transform: rotate(-90deg);
#qr-bill-scissors {
display: inline-block;
content: '\2702';
position: fixed;
font-size: 16pt;
top: 91.8mm;
left: 61.7mm;
transform: rotate(-90deg);
top: 80mm;
left: 1.0mm;
}

#qr-bill-separate-info-text {
Expand All @@ -219,7 +223,7 @@
</tr>
<tr>
<td id="qr-bill-receipt">
<h1>Receipt</h1>
<h1>Receipt<span id="qr-bill-scissors">&#9986;</span></h1>
<div id="qr-bill-information-receipt">
<h2>Account / Payable to</h2><p>CH44 3199 9123 0008 8901 2<br />
Thomas LeClaire<br />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,14 @@

#qr-bill-payment-part h2 {
font-size: 8pt !important;
line-height: 11pt !important;
line-height: 11pt !important;
margin-top: 11pt !important;
color: #000 !important;
}

#qr-bill-receipt h2 {
font-size: 6pt !important;
line-height: 8pt !important;
line-height: 8pt !important;
margin-top: 8pt !important;
color: #000 !important;
}
Expand Down Expand Up @@ -172,6 +172,16 @@
margin-top: -11pt;
}

#qr-bill-scissors {
display: none;
float: right;
width: 1mm;
line-height: 1mm;
font-size: 22px;
font-weight: normal;
position: relative;
}



#qr-bill-separate-info-text:before {
Expand Down Expand Up @@ -199,7 +209,7 @@
</tr>
<tr>
<td id="qr-bill-receipt">
<h1>Receipt</h1>
<h1>Receipt<span id="qr-bill-scissors">&#9986;</span></h1>
<div id="qr-bill-information-receipt">
<h2>Account / Payable to</h2><p>CH44 3199 9123 0008 8901 2<br />
Thomas LeClaire<br />
Expand Down
16 changes: 13 additions & 3 deletions tests/TestData/HtmlOutput/qr-additional-information.svg.html
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,14 @@

#qr-bill-payment-part h2 {
font-size: 8pt !important;
line-height: 11pt !important;
line-height: 11pt !important;
margin-top: 11pt !important;
color: #000 !important;
}

#qr-bill-receipt h2 {
font-size: 6pt !important;
line-height: 8pt !important;
line-height: 8pt !important;
margin-top: 8pt !important;
color: #000 !important;
}
Expand Down Expand Up @@ -172,6 +172,16 @@
margin-top: -11pt;
}

#qr-bill-scissors {
display: none;
float: right;
width: 1mm;
line-height: 1mm;
font-size: 22px;
font-weight: normal;
position: relative;
}


</style>

Expand All @@ -181,7 +191,7 @@
</tr>
<tr>
<td id="qr-bill-receipt">
<h1>Receipt</h1>
<h1>Receipt<span id="qr-bill-scissors">&#9986;</span></h1>
<div id="qr-bill-information-receipt">
<h2>Account / Payable to</h2><p>CH44 3199 9123 0008 8901 2<br />
Thomas LeClaire<br />
Expand Down
Loading

0 comments on commit a28e081

Please sign in to comment.