diff options
Diffstat (limited to 'print')
| -rw-r--r-- | print/resources/inkstitch-logo.svg | 125 | ||||
| -rw-r--r-- | print/resources/inkstitch.js | 173 | ||||
| -rw-r--r-- | print/resources/style.css | 139 | ||||
| -rw-r--r-- | print/templates/custom-page.html | 40 | ||||
| -rw-r--r-- | print/templates/index.html | 19 | ||||
| -rw-r--r-- | print/templates/operator_overview.html | 7 | ||||
| -rw-r--r-- | print/templates/print_detail.html | 5 | ||||
| -rw-r--r-- | print/templates/print_overview.html | 5 | ||||
| -rw-r--r-- | print/templates/ui.html | 67 | ||||
| -rw-r--r-- | print/templates/ui_svg_action_buttons.html | 9 |
10 files changed, 391 insertions, 198 deletions
diff --git a/print/resources/inkstitch-logo.svg b/print/resources/inkstitch-logo.svg index d9a298cf..138318b9 100644 --- a/print/resources/inkstitch-logo.svg +++ b/print/resources/inkstitch-logo.svg @@ -1,27 +1,98 @@ -<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
-<!-- Creator: CorelDRAW X7 -->
-<svg xmlns="http://www.w3.org/2000/svg" xml:space="preserve" width="99.9999mm" height="96.4295mm" version="1.1" style="shape-rendering:geometricPrecision; text-rendering:geometricPrecision; image-rendering:optimizeQuality; fill-rule:evenodd; clip-rule:evenodd"
-viewBox="0 0 15109 14570"
- xmlns:xlink="http://www.w3.org/1999/xlink">
- <defs>
- <style type="text/css">
- <![CDATA[
- .fil0 {fill:none}
- .fil3 {fill:black}
- .fil1 {fill:#003399}
- .fil4 {fill:gray}
- .fil2 {fill:white}
- ]]>
- </style>
- </defs>
- <g id="Layer_x0020_1">
- <metadata id="CorelCorpID_0Corel-Layer"/>
- <rect class="fil0" width="15109" height="14570"/>
- <path class="fil1" d="M9857 7480l0 -51c0,-15 12,-27 27,-27l295 0c15,0 27,12 27,27l0 51c0,15 -12,28 -27,28l-295 0c-15,0 -27,-13 -27,-28zm2819 -1566c10,66 67,116 135,116l0 0c75,0 137,-61 137,-137l0 -144c0,-37 18,-68 49,-88 32,-19 69,-20 101,-2 83,43 138,125 138,232l0 2788c0,147 -121,268 -268,268l-292 0 0 443c0,1659 -1357,3016 -3016,3016l-4210 0c-1659,0 -3017,-1357 -3017,-3016l0 -402 -286 0c-151,0 -274,-123 -274,-273l0 -2778c0,-150 123,-273 274,-273l286 0 0 -484c0,-1659 1358,-3016 3017,-3016l4210 0c1659,0 3016,1357 3016,3016l0 734zm-10456 1686l107 0c43,0 81,21 106,52l0 170c-25,32 -63,52 -106,52l-107 0c-75,0 -136,-62 -136,-137l0 0c0,-75 61,-137 136,-137zm54 710c75,0 136,61 136,136 0,76 -61,137 -136,137 -76,0 -137,-61 -137,-137 0,-75 61,-136 137,-136zm10515 -710l107 0c75,0 137,62 137,137l0 0c0,75 -62,137 -137,137l-107 0c-47,0 -88,-24 -113,-61l0 -152c25,-36 66,-61 113,-61zm54 711c75,0 135,60 135,135 0,75 -60,136 -135,136 -75,0 -136,-61 -136,-136 0,-75 61,-135 136,-135zm-1957 -838c-676,154 -776,166 -1566,74l-1848 18c-374,4 -659,116 -1029,116l-2070 0 -138 -75 0 -302 138 -75 2070 0c370,0 655,111 1029,115l1848 19c790,-92 890,-80 1566,73 9,2 15,10 15,19 0,9 -6,16 -15,18zm-6324 -832l0 -2163 516 0 0 2163 -516 0zm1562 0l0 -2234 50 0 1347 1263 0 -1192 477 0 0 2246 -45 0 -1352 -1263 0 1180 -477 0zm2865 0l0 -2163 510 0 0 941 715 -941 614 0 -816 1029 881 1134 -624 0 -770 -996 0 996 -510 0zm-4809 2781c86,52 160,89 220,111 60,21 119,31 177,31 57,0 104,-13 139,-38 35,-26 53,-58 53,-98 0,-57 -63,-122 -188,-193 -20,-12 -36,-21 -46,-27l-95 -54c-92,-52 -161,-111 -205,-177 -45,-66 -67,-140 -67,-223 0,-113 43,-206 128,-278 85,-72 195,-108 330,-108 50,0 103,5 161,17 58,12 123,30 194,54l0 329c-68,-43 -132,-75 -193,-98 -61,-23 -112,-35 -155,-35 -47,0 -84,10 -111,30 -27,21 -41,48 -41,83 0,24 8,47 25,68 16,22 40,41 72,58l165 91c137,76 230,147 277,211 48,65 72,141 72,230 0,136 -47,247 -140,331 -93,84 -217,126 -371,126 -52,0 -109,-5 -171,-16 -61,-11 -128,-28 -202,-51l-28 -374zm1440 396l0 -1110 -445 0 0 -293 1224 0 0 293 -444 0 0 1110 -335 0zm986 0l0 -1403 335 0 0 1403 -335 0zm989 0l0 -1110 -446 0 0 -293 1225 0 0 293 -444 0 0 1110 -335 0zm1983 -959c-60,-63 -122,-109 -184,-139 -62,-30 -128,-45 -196,-45 -119,0 -216,41 -291,122 -76,82 -113,188 -113,316 0,128 37,232 112,312 75,79 172,119 292,119 71,0 142,-14 213,-44 70,-30 141,-74 211,-134l-22 373c-60,40 -125,71 -196,92 -72,22 -146,32 -223,32 -82,0 -161,-12 -237,-38 -76,-26 -146,-64 -209,-115 -91,-71 -160,-157 -208,-259 -48,-102 -72,-214 -72,-335 0,-104 18,-201 53,-292 36,-91 87,-171 155,-241 68,-70 147,-123 237,-160 90,-37 184,-55 283,-55 79,0 154,10 226,33 72,21 140,55 205,99l-36 359zm261 959l0 -1403 331 0 0 515 541 0 0 -515 329 0 0 1403 -329 0 0 -589 -541 0 0 589 -331 0zm-4389 -7142c-1376,0 -2504,1128 -2504,2504l0 4210c0,1376 1128,2504 2504,2504l4210 0c1376,0 2504,-1128 2504,-2504l0 -4210c0,-1376 -1128,-2504 -2504,-2504l-4210 0z"/>
- <path class="fil2" d="M5450 2676c-1376,0 -2504,1128 -2504,2504l0 4210c0,1376 1128,2504 2504,2504l4210 0c1376,0 2504,-1128 2504,-2504l0 -4210c0,-1376 -1128,-2504 -2504,-2504l-4210 0z"/>
- <path class="fil3" d="M9839 9818l0 -1403 331 0 0 515 541 0 0 -515 329 0 0 1403 -329 0 0 -589 -541 0 0 589 -331 0zm-261 -959c-60,-63 -122,-109 -184,-139 -62,-30 -128,-45 -196,-45 -119,0 -216,41 -291,122 -76,82 -113,188 -113,316 0,128 37,232 112,312 75,79 172,119 292,119 71,0 142,-14 213,-44 70,-30 141,-74 211,-134l-22 373c-60,40 -125,71 -196,92 -72,22 -146,32 -223,32 -82,0 -161,-12 -237,-38 -76,-26 -146,-64 -209,-115 -91,-71 -160,-157 -208,-259 -48,-102 -72,-214 -72,-335 0,-104 18,-201 53,-292 36,-91 87,-171 155,-241 68,-70 147,-123 237,-160 90,-37 184,-55 283,-55 79,0 154,10 226,33 72,21 140,55 205,99l-36 359zm-1983 959l0 -1110 -446 0 0 -293 1225 0 0 293 -444 0 0 1110 -335 0zm-989 0l0 -1403 335 0 0 1403 -335 0zm-986 0l0 -1110 -445 0 0 -293 1224 0 0 293 -444 0 0 1110 -335 0zm-1440 -396c86,52 160,89 220,111 60,21 119,31 177,31 57,0 104,-13 139,-38 35,-26 53,-58 53,-98 0,-57 -63,-122 -188,-193 -20,-12 -36,-21 -46,-27l-95 -54c-92,-52 -161,-111 -205,-177 -45,-66 -67,-140 -67,-223 0,-113 43,-206 128,-278 85,-72 195,-108 330,-108 50,0 103,5 161,17 58,12 123,30 194,54l0 329c-68,-43 -132,-75 -193,-98 -61,-23 -112,-35 -155,-35 -47,0 -84,10 -111,30 -27,21 -41,48 -41,83 0,24 8,47 25,68 16,22 40,41 72,58l165 91c137,76 230,147 277,211 48,65 72,141 72,230 0,136 -47,247 -140,331 -93,84 -217,126 -371,126 -52,0 -109,-5 -171,-16 -61,-11 -128,-28 -202,-51l-28 -374z"/>
- <path class="fil3" d="M8989 6641l0 -2163 510 0 0 941 715 -941 614 0 -816 1029 881 1134 -624 0 -770 -996 0 996 -510 0zm-2865 0l0 -2234 50 0 1347 1263 0 -1192 477 0 0 2246 -45 0 -1352 -1263 0 1180 -477 0zm-1562 0l0 -2163 516 0 0 2163 -516 0z"/>
- <path class="fil4" d="M10886 7473c-676,154 -776,166 -1566,74l-1848 18c-374,4 -659,116 -1029,116l-2070 0 -138 -75 0 -302 138 -75 2070 0c370,0 655,111 1029,115l1848 19c790,-92 890,-80 1566,73 9,2 15,10 15,19 0,9 -6,16 -15,18zm-1029 7l0 -51c0,-15 12,-27 27,-27l295 0c15,0 27,12 27,27l0 51c0,15 -12,28 -27,28l-295 0c-15,0 -27,-13 -27,-28z"/>
- </g>
-</svg>
+<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Creator: CorelDRAW X7 --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + xml:space="preserve" + width="75.204422mm" + height="67.78524mm" + version="1.1" + style="clip-rule:evenodd;fill-rule:evenodd;image-rendering:optimizeQuality;shape-rendering:geometricPrecision;text-rendering:geometricPrecision" + viewBox="0 0 11362.647 10242" + id="svg20" + sodipodi:docname="inkstitch-logo.svg" + inkscape:version="0.92.4 (unknown)"><metadata + id="metadata24"><rdf:RDF><cc:Work + rdf:about=""><dc:format>image/svg+xml</dc:format><dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /><dc:title></dc:title></cc:Work></rdf:RDF></metadata><sodipodi:namedview + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1" + objecttolerance="10" + gridtolerance="10" + guidetolerance="10" + inkscape:pageopacity="0" + inkscape:pageshadow="2" + inkscape:window-width="1918" + inkscape:window-height="973" + id="namedview22" + showgrid="false" + fit-margin-top="0" + fit-margin-left="0" + fit-margin-right="0" + fit-margin-bottom="0" + inkscape:zoom="0.647537" + inkscape:cx="145.20721" + inkscape:cy="128.09809" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1" + inkscape:current-layer="Layer_x0020_1" /> + <defs + id="defs4"> + <style + type="text/css" + id="style2"> + <![CDATA[ + .fil0 {fill:none} + .fil3 {fill:black} + .fil1 {fill:#003399} + .fil4 {fill:gray} + .fil2 {fill:white} + ]]> + </style> + </defs> + <g + id="Layer_x0020_1" + transform="translate(-1873.2349,-2164)"> + <metadata + id="CorelCorpID_0Corel-Layer" /> + + <path + class="fil1" + d="m 9857,7480 v -51 c 0,-15 12,-27 27,-27 h 295 c 15,0 27,12 27,27 v 51 c 0,15 -12,28 -27,28 h -295 c -15,0 -27,-13 -27,-28 z m 2819,-1566 c 10,66 67,116 135,116 v 0 c 75,0 137,-61 137,-137 v -144 c 0,-37 18,-68 49,-88 32,-19 69,-20 101,-2 83,43 138,125 138,232 v 2788 c 0,147 -121,268 -268,268 h -292 v 443 c 0,1659 -1357,3016 -3016,3016 H 5450 c -1659,0 -3017,-1357 -3017,-3016 v -402 h -286 c -151,0 -274,-123 -274,-273 V 5937 c 0,-150 123,-273 274,-273 h 286 v -484 c 0,-1659 1358,-3016 3017,-3016 h 4210 c 1659,0 3016,1357 3016,3016 z M 2220,7600 h 107 c 43,0 81,21 106,52 v 170 c -25,32 -63,52 -106,52 h -107 c -75,0 -136,-62 -136,-137 v 0 c 0,-75 61,-137 136,-137 z m 54,710 c 75,0 136,61 136,136 0,76 -61,137 -136,137 -76,0 -137,-61 -137,-137 0,-75 61,-136 137,-136 z m 10515,-710 h 107 c 75,0 137,62 137,137 v 0 c 0,75 -62,137 -137,137 h -107 c -47,0 -88,-24 -113,-61 v -152 c 25,-36 66,-61 113,-61 z m 54,711 c 75,0 135,60 135,135 0,75 -60,136 -135,136 -75,0 -136,-61 -136,-136 0,-75 61,-135 136,-135 z m -1957,-838 c -676,154 -776,166 -1566,74 l -1848,18 c -374,4 -659,116 -1029,116 H 4373 l -138,-75 v -302 l 138,-75 h 2070 c 370,0 655,111 1029,115 l 1848,19 c 790,-92 890,-80 1566,73 9,2 15,10 15,19 0,9 -6,16 -15,18 z M 4562,6641 V 4478 h 516 v 2163 z m 1562,0 V 4407 h 50 L 7521,5670 V 4478 h 477 v 2246 h -45 L 6601,5461 v 1180 z m 2865,0 V 4478 h 510 v 941 l 715,-941 h 614 l -816,1029 881,1134 h -624 l -770,-996 v 996 z M 4180,9422 c 86,52 160,89 220,111 60,21 119,31 177,31 57,0 104,-13 139,-38 35,-26 53,-58 53,-98 0,-57 -63,-122 -188,-193 -20,-12 -36,-21 -46,-27 l -95,-54 c -92,-52 -161,-111 -205,-177 -45,-66 -67,-140 -67,-223 0,-113 43,-206 128,-278 85,-72 195,-108 330,-108 50,0 103,5 161,17 58,12 123,30 194,54 v 329 c -68,-43 -132,-75 -193,-98 -61,-23 -112,-35 -155,-35 -47,0 -84,10 -111,30 -27,21 -41,48 -41,83 0,24 8,47 25,68 16,22 40,41 72,58 l 165,91 c 137,76 230,147 277,211 48,65 72,141 72,230 0,136 -47,247 -140,331 -93,84 -217,126 -371,126 -52,0 -109,-5 -171,-16 -61,-11 -128,-28 -202,-51 z m 1440,396 V 8708 h -445 v -293 h 1224 v 293 h -444 v 1110 z m 986,0 V 8415 h 335 v 1403 z m 989,0 V 8708 h -446 v -293 h 1225 v 293 h -444 v 1110 z m 1983,-959 c -60,-63 -122,-109 -184,-139 -62,-30 -128,-45 -196,-45 -119,0 -216,41 -291,122 -76,82 -113,188 -113,316 0,128 37,232 112,312 75,79 172,119 292,119 71,0 142,-14 213,-44 70,-30 141,-74 211,-134 l -22,373 c -60,40 -125,71 -196,92 -72,22 -146,32 -223,32 -82,0 -161,-12 -237,-38 -76,-26 -146,-64 -209,-115 -91,-71 -160,-157 -208,-259 -48,-102 -72,-214 -72,-335 0,-104 18,-201 53,-292 36,-91 87,-171 155,-241 68,-70 147,-123 237,-160 90,-37 184,-55 283,-55 79,0 154,10 226,33 72,21 140,55 205,99 z m 261,959 V 8415 h 331 v 515 h 541 v -515 h 329 v 1403 h -329 v -589 h -541 v 589 z M 5450,2676 c -1376,0 -2504,1128 -2504,2504 v 4210 c 0,1376 1128,2504 2504,2504 h 4210 c 1376,0 2504,-1128 2504,-2504 V 5180 c 0,-1376 -1128,-2504 -2504,-2504 z" + id="path9" + inkscape:connector-curvature="0" + style="fill:#003399" /> + <path + class="fil2" + d="m 5450,2676 c -1376,0 -2504,1128 -2504,2504 v 4210 c 0,1376 1128,2504 2504,2504 h 4210 c 1376,0 2504,-1128 2504,-2504 V 5180 c 0,-1376 -1128,-2504 -2504,-2504 z" + id="path11" + inkscape:connector-curvature="0" + style="fill:#ffffff" /> + <path + class="fil3" + d="M 9839,9818 V 8415 h 331 v 515 h 541 v -515 h 329 v 1403 h -329 v -589 h -541 v 589 z m -261,-959 c -60,-63 -122,-109 -184,-139 -62,-30 -128,-45 -196,-45 -119,0 -216,41 -291,122 -76,82 -113,188 -113,316 0,128 37,232 112,312 75,79 172,119 292,119 71,0 142,-14 213,-44 70,-30 141,-74 211,-134 l -22,373 c -60,40 -125,71 -196,92 -72,22 -146,32 -223,32 -82,0 -161,-12 -237,-38 -76,-26 -146,-64 -209,-115 -91,-71 -160,-157 -208,-259 -48,-102 -72,-214 -72,-335 0,-104 18,-201 53,-292 36,-91 87,-171 155,-241 68,-70 147,-123 237,-160 90,-37 184,-55 283,-55 79,0 154,10 226,33 72,21 140,55 205,99 z M 7595,9818 V 8708 h -446 v -293 h 1225 v 293 h -444 v 1110 z m -989,0 V 8415 h 335 v 1403 z m -986,0 V 8708 h -445 v -293 h 1224 v 293 H 5955 V 9818 Z M 4180,9422 c 86,52 160,89 220,111 60,21 119,31 177,31 57,0 104,-13 139,-38 35,-26 53,-58 53,-98 0,-57 -63,-122 -188,-193 -20,-12 -36,-21 -46,-27 l -95,-54 c -92,-52 -161,-111 -205,-177 -45,-66 -67,-140 -67,-223 0,-113 43,-206 128,-278 85,-72 195,-108 330,-108 50,0 103,5 161,17 58,12 123,30 194,54 v 329 c -68,-43 -132,-75 -193,-98 -61,-23 -112,-35 -155,-35 -47,0 -84,10 -111,30 -27,21 -41,48 -41,83 0,24 8,47 25,68 16,22 40,41 72,58 l 165,91 c 137,76 230,147 277,211 48,65 72,141 72,230 0,136 -47,247 -140,331 -93,84 -217,126 -371,126 -52,0 -109,-5 -171,-16 -61,-11 -128,-28 -202,-51 z" + id="path13" + inkscape:connector-curvature="0" + style="fill:#000000" /> + <path + class="fil3" + d="M 8989,6641 V 4478 h 510 v 941 l 715,-941 h 614 l -816,1029 881,1134 h -624 l -770,-996 v 996 z m -2865,0 V 4407 h 50 L 7521,5670 V 4478 h 477 v 2246 h -45 L 6601,5461 v 1180 z m -1562,0 V 4478 h 516 v 2163 z" + id="path15" + inkscape:connector-curvature="0" + style="fill:#000000" /> + <path + class="fil4" + d="m 10886,7473 c -676,154 -776,166 -1566,74 l -1848,18 c -374,4 -659,116 -1029,116 H 4373 l -138,-75 v -302 l 138,-75 h 2070 c 370,0 655,111 1029,115 l 1848,19 c 790,-92 890,-80 1566,73 9,2 15,10 15,19 0,9 -6,16 -15,18 z m -1029,7 v -51 c 0,-15 12,-27 27,-27 h 295 c 15,0 27,12 27,27 v 51 c 0,15 -12,28 -27,28 h -295 c -15,0 -27,-13 -27,-28 z" + id="path17" + inkscape:connector-curvature="0" + style="fill:#808080" /> + </g> +</svg>
\ No newline at end of file diff --git a/print/resources/inkstitch.js b/print/resources/inkstitch.js index ac8c72b4..86bc213e 100644 --- a/print/resources/inkstitch.js +++ b/print/resources/inkstitch.js @@ -285,7 +285,7 @@ $(function() { /* Contendeditable Fields */ - $('body').on('focusout', '[contenteditable="true"]:not(.footer-info)', function() { + $('body').on('focusout', '[contenteditable="true"]:not(.info-text)', function() { /* change svg scale */ var content = $(this).text(); var field_name = $(this).attr('data-field-name'); @@ -324,8 +324,10 @@ $(function() { } else if (item.is('figure.inksimulation')) { setSVGTransform(item, value); } else if (item.is('div.footer-info')) { - $('#footer-info-text').html(value); - item.html(value); + $('#footer-info-text').html($.parseHTML(value)); + item.html($.parseHTML(value)); + } else if (item.is('#custom-page-content')) { + $('#custom-page-content').html($.parseHTML(value)); } else { item.text(value); } @@ -339,7 +341,7 @@ $(function() { }, 500); }); - $('body').on('keypress', '[contenteditable="true"]:not(#footer-info-text)', function(e) { + $('body').on('keypress', '[contenteditable="true"]:not(.info-text)', function(e) { if (e.which == 13) { // pressing enter defocuses the element this.blur(); @@ -360,8 +362,8 @@ $(function() { } }); - $('#footer-info-text[contenteditable="true"]').focusout(function() { - updateFooter(); + $('.info-text[contenteditable="true"]').focusout(function() { + updateEditableText($(this)); }); /* Settings Bar */ @@ -415,119 +417,141 @@ $(function() { }); // Footer - function getEditMode(){ - return $('#switch-mode').prop('checked'); + function getEditMode(element){ + return element.closest('fieldset').find('.switch-mode').prop('checked'); } - $('#switch-mode').change(function() { - var editMode = getEditMode(); + $('.switch-mode').change(function() { + var element = $(this); + var info_text = element.closest('fieldset').find('.info-text'); + var editMode = getEditMode(element); if (editMode) { - $('#footer-info-text').text( $('#footer-info-text' ).html()); - $('#tool-bar .edit-only').prop("disabled", true); + info_text.text( info_text.html() ); + element.closest('.tool-bar').find('.tb-button.edit-only').prop("disabled", true); } else { - $('#footer-info-text').css('display', 'block'); - var sourceText = $('#footer-info-text').text(); - $('#footer-info-text').html( sourceText ); - $('#tool-bar .tb-button.edit-only').prop('disabled', false); + info_text.css('display', 'block'); + var sourceText = info_text.text(); + info_text.html( $.parseHTML(sourceText) ); + element.closest('.tool-bar').find('.tb-button.edit-only').prop('disabled', false); } }); - function updateFooter() { - var editMode = getEditMode(); - var footerText = ''; + function updateEditableText(element) { + var editMode = getEditMode(element); + var info_text = element.closest('fieldset').find('.info-text'); + var editableText = ''; + if (editMode) { - footerText = $('#footer-info-text' ).text(); + editableText = info_text.text(); + } else { + editableText = info_text.html(); + } + + if(info_text.is('#footer-info-text')) { + $('div.footer-info').html($.parseHTML(editableText)); + $.postJSON('/settings/footer-info', {value: editableText}); } else { - footerText = $('#footer-info-text').html(); + $.postJSON('/settings/custom-page-content', {value: editableText}); } - $('.footer-info').html(footerText); - var content = $('.footer-info').html(); - $.postJSON('/settings/footer-info', {value: content}); } function formatText(selection, value) { - var htmlMode = getEditMode(); - if(!htmlMode) { if(window.getSelection().toString()){ document.execCommand(selection, false, value); - updateFooter(); } - } } - $('#tb-bold').click(function(selection) { - formatText('bold'); + $('.tb-bold').click(function() { + if(!getEditMode($(this))) { + formatText('bold'); + updateEditableText($(this)); + } }); - $('#tb-italic').click(function() { - formatText('italic'); + $('.tb-italic').click(function() { + if(!getEditMode($(this))) { + formatText('italic'); + updateEditableText($(this)); + } }); - $('#tb-underline').click(function() { - formatText('underline'); + $('.tb-underline').click(function() { + if(!getEditMode($(this))) { + formatText('underline'); + updateEditableText($(this)); + } }); - $('#tb-remove').click(function() { - formatText('removeFormat'); + $('.tb-remove').click(function() { + if(!getEditMode($(this))) { + formatText('removeFormat'); + updateEditableText($(this)); + } }); - $('#tb-hyperlink').click(function() { - formatText('createlink', 'tempurl'); - $('#footer-url').css('display', 'block'); + $('.tb-hyperlink').click(function() { + if(!getEditMode($(this))) { + formatText('createlink', 'tempurl'); + updateEditableText($(this)); + $(this).closest('.tool-bar').children('.url-window').css('display', 'block'); + } }); - $('#url-ok').click(function() { - var link = $('#footer-link').val(); - $('#footer-info-text a[href="tempurl"]').attr('href', link); - $('#footer-link').val('https://'); - $('#footer-url').css('display', 'none'); - updateFooter(); + $('.url-ok').click(function() { + var link = $(this).closest('.tool-bar').find('.user-url').val(); + $(this).closest('fieldset').find('.info-text').find('a[href="tempurl"]').attr('href', link); + $('.user-url').val('https://'); + $('.url-window').css('display', 'none'); + updateEditableText($(this)); }); - $('#url-cancel').click(function() { - $('#footer-info-text a[href="tempurl"]').contents().unwrap(); - $('#footer-link').val('https://'); - $('#footer-url').css('display', 'none'); - updateFooter(); + $('.url-cancel').click(function() { + $(this).closest('fieldset').find('.info-text').find('a[href="tempurl"]').contents().unwrap(); + $('.user-url').val('https://'); + $('.url-window').css('display', 'none'); + updateEditableText($(this)); }); - $('#tb-mail').click(function() { - formatText('createlink', 'tempurl'); - $('#footer-email').css('display', 'block'); + $('.tb-mail').click(function() { + if(!getEditMode($(this))) { + formatText('createlink', 'tempurl'); + updateEditableText($(this)); + $(this).closest('.tool-bar').find('.mail-window').css('display', 'block'); + } }); - $('#mail-ok').click(function() { - var link = 'mailto:' + $('#footer-mail').val(); - $('#footer-info-text a[href="tempurl"]').attr('href', link); - $('#footer-mail').val('@'); - $('#footer-email').css('display', 'none'); - updateFooter(); + $('.mail-ok').click(function() { + var link = 'mailto:' + $(this).closest('.tool-bar').find('.user-mail').val(); + $(this).closest('fieldset').find('.info-text').find('a[href="tempurl"]').attr('href', link); + $('.user-mail').val('@'); + $('.mail-window').css('display', 'none'); + updateEditableText($(this)); }); - $('#mail-cancel').click(function() { - $('#footer-info-text a[href="tempurl"]').contents().unwrap(); - $('#footer-mail').val('@'); - $('#footer-email').css('display', 'none'); - updateFooter(); + $('.mail-cancel').click(function() { + $(this).closest('fieldset').find('.info-text').find('a[href="tempurl"]').contents().unwrap(); + $('.user-mail').val('@'); + $('.mail-window').css('display', 'none'); + updateEditableText($(this)); }); - $('#tb-reset').click(function() { - $('#footer-reset').css('display', 'block'); + $('.tb-reset').click(function() { + $(this).closest('.tool-bar').find('.reset-window').css('display', 'block'); }); - $('#reset-ok').click(function() { - var htmlMode = getEditMode(); + $('.reset-ok').click(function() { + var htmlMode = getEditMode($(this)); if(!htmlMode) { - $('#footer-info-text').html($('#footer-info-original').html()); + $(this).closest('fieldset').find('.info-text').html($(this).closest('.tool-bar').find('.original-info').html()); } else { - $('#footer-info-text').text($('#footer-info-original').html()); + $(this).closest('fieldset').find('.info-text').text($(this).closest('.tool-bar').find('.original-info').html()); } - $('#footer-reset').css('display', 'none'); - updateFooter(); + $('.reset-window').css('display', 'none'); + updateEditableText($(this)); }); - $('#reset-cancel').click(function() { - $('#footer-reset').css('display', 'none'); + $('.reset-cancel').click(function() { + $('.reset-window').css('display', 'none'); }); $('body').on("click", ".edit-footer-link", function() { @@ -713,6 +737,7 @@ $(function() { settings["operator-overview"] = $("[data-field-name='operator-overview']").is(':checked'); settings["operator-detailedview"] = $("[data-field-name='operator-detailedview']").is(':checked'); settings["operator-detailedview-thumbnail-size"] = $("[data-field-name='operator-detailedview-thumbnail-size']").val(); + settings["custom-page"] = $("[data-field-name='custom-page']").is(':checked'); settings["paper-size"] = $('select#printing-size').find(':selected').val(); var logo = $("figure.brandlogo img").attr('src'); diff --git a/print/resources/style.css b/print/resources/style.css index f697c7dc..9ffff07d 100644 --- a/print/resources/style.css +++ b/print/resources/style.css @@ -66,30 +66,6 @@ body { position: relative; } -/* Printing Size */ - .page.a4 { - width: 205mm; - height: 292mm; - padding: 15mm; - } - - .page.client-overview.a4 header, .page.operator-overview.a4 header { - height: 50mm; - flex-direction: row; - } - - .page.client-overview.a4 div.job-details, .page.operator-overview.a4 div.job-details { - width: 100%; - } - - .page.client-overview.a4 .client-overview-main figure.inksimulation { - height: 150mm; - } - - .page.client-overview.a4 figure.brandlogo, .page.operator-overview.a4 figure.brandlogo { - margin: -6mm 2.5mm; - } - /* Settings */ .ui { @@ -289,7 +265,7 @@ body { position: relative; } - #footer-info-text { + .info-text { width: 100%; min-height: 5em; border: 1px solid darkgrey; @@ -298,23 +274,25 @@ body { background: white; } - #tool-bar .tb-button { - border: 1px solid darkgrey; + .tb-button { + border: 1px solid darkgrey !important; border-bottom: none; margin-bottom: -0.2em; - cursor: pointer; - color: #413232; height: 2.2em; vertical-align: top; + padding: 5px; + cursor: pointer; + background: white; + color: black; } - #tool-bar .tb-button:disabled { - background: #eaeaea; - color: white; - cursor: auto; + .tb-button:disabled { + background: #eaeaea !important; + color: white !important; + cursor: auto !important; } - #edit-mode { + .edit-mode { display: inline; position: relative; border: 1px solid darkgray; @@ -322,18 +300,18 @@ body { vertical-align: top; } - #edit-mode input { + .edit-mode input { visibility: hidden; } - #edit-mode label { + .edit-mode label { cursor: pointer; vertical-align: middle; background: white; color: #413232; } - #edit-mode label:after { + .edit-mode label:after { opacity: 0.1; content: ''; position: absolute; @@ -348,21 +326,21 @@ body { transform: rotate(-45deg); } - #edit-mode label:hover::after { + .edit-mode label:hover::after { opacity: 0.5; } - #edit-mode input[type=checkbox]:checked + label:after { + .edit-mode input[type=checkbox]:checked + label:after { opacity: 1; } - #edit-mode span { + .edit-mode span { margin-left: 1em; } - div#footer-url, div#footer-email, div#footer-reset { + div.tb-popup { display: none; - position: absolute; + position: absolute !important; background: white; border: 1px solid black; padding: 5mm; @@ -371,7 +349,7 @@ body { z-index: 10; } - div#footer-info-original { + div.original-info { visibility: hidden; width: 0; height: 0; @@ -418,7 +396,6 @@ body { /* Header */ - header { width: 100%; height: 40mm; @@ -434,13 +411,11 @@ body { figure.brandlogo { height: 30mm; width: 30mm; - margin: 2.5mm; + margin: 0 4mm 0 0; } figure.brandlogo label { display: block; - width: 100%; - height: 100%; text-align: center; position: relative; } @@ -472,13 +447,6 @@ body { cursor: pointer; } - .operator-detailedview figure.brandlogo { - height: 20mm; - width: 30mm; - margin: 0 2.5mm; - text-align: left; - } - .operator-detailedview figure.brandlogo img { max-width: 30mm; max-height: 20mm; @@ -488,7 +456,7 @@ body { display: flex; display: -webkit-flex; /* old webkit */ display: -ms-flexbox; /* IE 10 */ - width: calc(100% - 50mm); + width: calc(100% - 40mm); height: 50%; flex-grow: 1; } @@ -515,6 +483,10 @@ body { padding-top: 6mm; } + .operator-overview figure.inksimulation { + height: 210mm; + } + .operator-overview div.job-details, .client-overview div.job-details { padding-top: 2mm; } @@ -904,6 +876,11 @@ body { .opd-color-block.large { display: block; margin: 5mm 0; + font-size: 14pt; + } + + .opd-color-block.large .operator-colorswatch { + font-size: 8pt; } .opd-color-block.large:first-child { @@ -987,6 +964,23 @@ body { display: none; } +/* Custom information sheet */ + .custom-page header { + height: 30mm; + } + + .custom-page main { + height: 230mm + } + #custom-page-tool-bar { + margin-bottom: 0.5em; + } + + #custom-page-content { + height: 200mm; + overflow-y: hidden; + text-align: left; + } /* Color Swatch Logic */ /* reference : http://jsfiddle.net/jrulle/btg63ezy/3/ */ @@ -1120,7 +1114,33 @@ body { height: calc(100% / 5); width: calc(100% / 12); } - + + +/* Print Size A4 */ + + .page.a4 { + width: 210mm; + height: 296mm; + padding: 15mm; + } + + .page.client-overview.a4 header, .page.operator-overview.a4 header { + height: 50mm; + flex-direction: row; + } + + .page.client-overview.a4 div.job-details, .page.operator-overview.a4 div.job-details { + width: 100%; + } + + .page.client-overview.a4 .client-overview-main figure.inksimulation { + height: 150mm; + } + + .page.client-overview.a4 figure.brandlogo, .page.operator-overview.a4 figure.brandlogo { + margin: 0 4mm -2mm 0; + } + @media screen { .page { margin-top: 20mm !important; @@ -1153,8 +1173,11 @@ body { .ui, #settings-ui, #errors, - span.logo-instructions { - display: none; + span.logo-instructions, + #custom-page-tool-bar, + #custom-page-content, + .notice--warning { + display: none !important; } .header-field:not(:empty)::before { diff --git a/print/templates/custom-page.html b/print/templates/custom-page.html new file mode 100644 index 00000000..1ed15dae --- /dev/null +++ b/print/templates/custom-page.html @@ -0,0 +1,40 @@ + <header> + {% include 'headline.html' %} + </header> + <main> + <fieldset id="edit-custom-page"> + <div id="custom-page-tool-bar" class="tool-bar"> + <button id="custom-page-bold" class="tb-button tb-bold ff-serif edit-only" title="Bold"><b>B</b></button> + <button id="custom-page-italic" class="tb-button tb-italic ff-serif edit-only" title="Italic"><i>I</i></button> + <button id="custom-page-underline" class="tb-button tb-underline ff-serif edit-only" title="Underline"><u>U</u></button> + <button id="custom-page-remove" class="tb-button tb-remove ff-serif edit-only" title="Remove formatting"> + <u style="vertical-align: super; font-size: 60%;">A</u> + <span style="vertical-align: sub; font-size: 80%;">A</span> + </button> + <button id="custom-page-hyperlink" class="tb-button tb-hyperlink edit-only" title="Hyperlink">☍</button> + <button id="custom-page-mail" class="tb-button tb-mail edit-only" title="E-Mail">✉</button> + <button id="custom-page-reset" class="tb-button tb-reset" title="Reset text">↺</button> + <p id="custom-page-edit-mode" class="edit-mode"> + <input type="checkbox" id="custom-page-switch-mode" class="switch-mode" name="custom-page-switch-mode" /> + <label for="custom-page-switch-mode">{{ ('Show HTML') }}</label> + </p> + <div id="custom-page-url" class="tb-popup url-window"> + <p>{{ _("Enter URL") }}: <input type="text" id="custom-page-link" class="user-url" name="custom-page-link" value="https://" /></p> + <p><button id="custom-page-url-ok" class="url-ok">{{ _("OK") }}</button> <button id="custom-page-url-cancel" class="url-cancel">{{ _("Cancel") }}</button></p> + </div> + <div id="custom-page-email" class="tb-popup mail-window"> + <p>{{ _("Enter E-Mail") }}: <input type="text" id="custom-page-mail" class="user-mail" name="custom-page-mail" value="@" /></p> + <p><button id="custom-page-mail-ok" class="mail-ok">{{ _("OK") }}</button> <button id="custom-page-mail-cancel" class="mail-cancel">{{ _("Cancel") }}</button></p> + </div> + <div id="custom-page-info-original" class="original-info"><b>{{ _("Custom Information Sheet") }}</b></div> + <div id="custom-page-reset" class="tb-popup reset-window"> + <p>{{ _("This will reset your custom text to the default.") }}</p> + <p>{{ _("All changes will be lost.") }}</p> + <p><button id="custom-page-reset-ok" class="reset-ok">{{ _("OK") }}</button> <button id="custom-page-reset-cancel" class="reset-cancel">{{ _("Cancel") }}</button></p> + </div> + </div> + <div id="custom-page-content" class="info-text" contenteditable="true" data-field-name="custom-page-content">{{ _("Custom Information Sheet") }}</div> + <p class="notice--warning"><b>Note</b>: If you are using Firefox, use visible URLs. Links will not be printed to PDF with this browser.</p> + </fieldset> + </main> + {% include 'footer.html' %} diff --git a/print/templates/index.html b/print/templates/index.html index c7fa5d74..d0ab848f 100644 --- a/print/templates/index.html +++ b/print/templates/index.html @@ -9,22 +9,23 @@ </head> <body> {% include 'ui.html' %} - {# client overview #} - <div class="page client-overview" style="display: {{ 'block' if view.client_overview else 'none' }}">{% include 'print_overview.html' %}</div> + <div class="page client-overview" style="display: {{ 'block' if view.client_overview else 'none' }}">{% include 'print_overview.html' %}</div> {# client detailedview #} - {% set printview = 'detailedview' %} - {% for color_block in color_blocks %} - {% set outer_loop = loop %} - <div class="page client-detailedview" style="display: {{ 'block' if view.client_detailedview else 'none' }}">{% include 'print_detail.html' %}</div> - {% endfor %} + {% set printview = 'detailedview' %} + {% for color_block in color_blocks %} + {% set outer_loop = loop %} + <div class="page client-detailedview" style="display: {{ 'block' if view.client_detailedview else 'none' }}">{% include 'print_detail.html' %}</div> + {% endfor %} {# operator overview #} - <div class="page operator-overview" style="display: {{ 'block' if view.operator_overview else 'none' }}">{% include 'operator_overview.html' %}</div> + <div class="page operator-overview" style="display: {{ 'block' if view.operator_overview else 'none' }}">{% include 'operator_overview.html' %}</div> {# operator detailed view #} - {% include 'operator_detailedview.html' %} + {% include 'operator_detailedview.html' %} +{# custom pages #} + <div class="page custom-page" style="display: {{ 'block' if view.custom_page else 'none' }}">{% include 'custom-page.html' %}</div> </body> </html> diff --git a/print/templates/operator_overview.html b/print/templates/operator_overview.html index 8f70b4f0..71c5ea2e 100644 --- a/print/templates/operator_overview.html +++ b/print/templates/operator_overview.html @@ -25,9 +25,12 @@ </div> </header> <main> - <figure class="inksimulation operator" data-field-name="operator-overview-transform" style="height: 210mm;" title="{{ _('Ctrl + Scroll to Zoom') }}"> + <figure class="inksimulation operator" data-field-name="operator-overview-transform" title="{{ _('Ctrl + Scroll to Zoom') }}"> {{ svg_overview|replace("<li>", "")|replace("</li>", "")|safe }} - {% include 'ui_svg_action_buttons.html' %} + {% with %} + {% set realistic_id='realistic-operator-overview' %} + {% include 'ui_svg_action_buttons.html' with context %} + {% endwith %} </figure> </main> {% include 'footer.html' %} diff --git a/print/templates/print_detail.html b/print/templates/print_detail.html index 0dca4978..f076fc04 100644 --- a/print/templates/print_detail.html +++ b/print/templates/print_detail.html @@ -17,7 +17,10 @@ <main> <figure class="inksimulation" data-field-name="client-detail-transform-block{{ loop.index0 }}" title="{{ _('Ctrl + Scroll to Zoom') }}"> {{color_block.svg_preview|replace("<li>", "")|replace("</li>", "")|safe}} - {% include 'ui_svg_action_buttons.html' %} + {% with %} + {% set loop_index=loop.index0 %} + {% include 'ui_svg_action_buttons.html' with context %} + {% endwith %} </figure> <div class="color-palette detailed"> {% include 'color_swatch.html' %} diff --git a/print/templates/print_overview.html b/print/templates/print_overview.html index d5111562..34478438 100644 --- a/print/templates/print_overview.html +++ b/print/templates/print_overview.html @@ -27,7 +27,10 @@ <main class="client-overview-main"> <figure class="inksimulation" data-field-name="client-overview-transform" title="{{ _('Ctrl + Scroll to Zoom') }}"> {{ svg_overview|replace("<li>", "")|replace("</li>", "")|safe }} - {% include 'ui_svg_action_buttons.html' %} + {% with %} + {% set realistic_id='realistic-client-overview' %} + {% include 'ui_svg_action_buttons.html' with context %} + {% endwith %} </figure> <div class="color-palette"> diff --git a/print/templates/ui.html b/print/templates/ui.html index 71908b52..23e39145 100644 --- a/print/templates/ui.html +++ b/print/templates/ui.html @@ -36,11 +36,30 @@ </fieldset> <fieldset> <legend>{{ _('Print Layouts') }}</legend> - <p><input type="checkbox" class="view" id="client-overview" data-field-name="client-overview" /><label for="client-overview">{{ _('Client Overview') }}</label></p> - <p><input type="checkbox" class="view" id="client-detailedview" data-field-name="client-detailedview" /><label for="client-detailedview">{{ _('Client Detailed View') }}</label></p> - <p><input type="checkbox" class="view" id="operator-overview" data-field-name="operator-overview" CHECKED /><label for="operator-overview">{{ _('Operator Overview') }}</label></p> - <p><input type="checkbox" class="view" id="operator-detailedview" data-field-name="operator-detailedview" CHECKED /><label for="operator-detailedview">{{ _('Operator Detailed View') }}</label></p> - <p style="text-indent: 1.5em;">{{ _('Thumbnail size') }}: <input type="range" min="15" max="110" value="15" step="5" id="operator-detailedview-thumbnail-size" data-field-name="operator-detailedview-thumbnail-size" style="vertical-align: middle;"> <span id="display-thumbnail-size">15mm</span></p> + <p> + <input type="checkbox" class="view" id="client-overview" data-field-name="client-overview" /> + <label for="client-overview">{{ _('Client Overview') }}</label> + </p> + <p> + <input type="checkbox" class="view" id="client-detailedview" data-field-name="client-detailedview" /> + <label for="client-detailedview">{{ _('Client Detailed View') }}</label> + </p> + <p> + <input type="checkbox" class="view" id="operator-overview" data-field-name="operator-overview" CHECKED /> + <label for="operator-overview">{{ _('Operator Overview') }}</label> + </p> + <p> + <input type="checkbox" class="view" id="operator-detailedview" data-field-name="operator-detailedview" CHECKED /> + <label for="operator-detailedview">{{ _('Operator Detailed View') }}</label> + </p> + <p style="text-indent: 1.5em;">{{ _('Thumbnail size') }}: + <input type="range" min="15" max="110" value="15" step="5" id="operator-detailedview-thumbnail-size" data-field-name="operator-detailedview-thumbnail-size" style="vertical-align: middle;" /> + <span id="display-thumbnail-size">15mm</span> + </p> + <p> + <input type="checkbox" class="view" id="custom-page" data-field-name="custom-page" /> + <label for="custom-page">{{ _('Custom information sheet') }}</label> + </p> </fieldset> <button class="save-settings" title="{{ _("Includes these Page Setup, estimated time settings and also the icon.") }}">{{ _("Save as defaults") }}</button> </fieldset> @@ -58,31 +77,31 @@ </fieldset> <fieldset id="edit-footer"> <legend>{{ _('Footer: Operator contact information') }}</legend> - <div id="tool-bar"> - <button id="tb-bold" class="tb-button ff-serif edit-only" title="Bold"><b>B</b></button> - <button id="tb-italic" class="tb-button ff-serif edit-only" title="Italic"><i>I</i></button> - <button id="tb-underline" class="tb-button ff-serif edit-only" title="Underline"><u>U</u></button> - <button id="tb-remove" class="tb-button ff-serif edit-only" title="Remove formatting"><u style="vertical-align: super; font-size: 60%;">A</u><span style="vertical-align: sub; font-size: 80%;">A</span></button> - <button id="tb-hyperlink" class="tb-button edit-only" title="Hyperlink">☍</button> - <button id="tb-mail" class="tb-button edit-only" title="E-Mail">✉</button> - <button id="tb-reset" class="tb-button" title="Reset text">↺</button> - <p id="edit-mode"><input type="checkbox" id="switch-mode" name="switch-mode" /> <label for="switch-mode">{{ ('Show HTML') }}</label></p> - <div id="footer-url"> - <p>{{ _("Enter URL") }}: <input type="text" id="footer-link" name="footer-link" value="https://" /></p> - <p><button id="url-ok">{{ _("OK") }}</button> <button id="url-cancel">{{ _("Cancel") }}</button></p> + <div id="tool-bar" class="tool-bar"> + <button id="tb-bold" class="tb-button tb-bold ff-serif edit-only" title="Bold"><b>B</b></button> + <button id="tb-italic" class="tb-button tb-italic ff-serif edit-only" title="Italic"><i>I</i></button> + <button id="tb-underline" class="tb-button tb-underline ff-serif edit-only" title="Underline"><u>U</u></button> + <button id="tb-remove" class="tb-button tb-remove ff-serif edit-only" title="Remove formatting"><u style="vertical-align: super; font-size: 60%;">A</u><span style="vertical-align: sub; font-size: 80%;">A</span></button> + <button id="tb-hyperlink" class="tb-button tb-hyperlink edit-only" title="Hyperlink">☍</button> + <button id="tb-mail" class="tb-button tb-mail edit-only" title="E-Mail">✉</button> + <button id="tb-reset" class="tb-button tb-reset" title="Reset text">↺</button> + <p id="edit-mode" class="edit-mode"><input type="checkbox" id="switch-mode" class="switch-mode" name="switch-mode" /> <label for="switch-mode">{{ ('Show HTML') }}</label></p> + <div id="footer-url" class="tb-popup url-window"> + <p>{{ _("Enter URL") }}: <input type="text" id="footer-link" class="user-url" name="footer-link" value="https://" /></p> + <p><button id="url-ok" class="url-ok">{{ _("OK") }}</button> <button id="url-cancel" class="url-cancel">{{ _("Cancel") }}</button></p> </div> - <div id="footer-email"> - <p>{{ _("Enter E-Mail") }}: <input type="text" id="footer-mail" name="footer-mail" value="@" /></p> - <p><button id="mail-ok">{{ _("OK") }}</button> <button id="mail-cancel">{{ _("Cancel") }}</button></p> + <div id="footer-email" class="tb-popup mail-window"> + <p>{{ _("Enter E-Mail") }}: <input type="text" id="footer-mail" class="user-mail" name="footer-mail" value="@" /></p> + <p><button id="mail-ok" class="mail-ok">{{ _("OK") }}</button> <button id="mail-cancel" class="mail-cancel">{{ _("Cancel") }}</button></p> </div> - <div id="footer-info-original">{{ _("Proudly generated with") }} <a href="http://inkstitch.org/" target="_blank">Ink/Stitch</a></div> - <div id="footer-reset"> + <div id="footer-info-original" class="original-info">{{ _("Proudly generated with") }} <a href="http://inkstitch.org/" target="_blank">Ink/Stitch</a></div> + <div id="footer-reset" class="tb-popup reset-window"> <p>{{ _("This will reset your custom text to the default.") }}</p> <p>{{ _("All changes will be lost.") }}</p> - <p><button id="reset-ok">{{ _("OK") }}</button> <button id="reset-cancel">{{ _("Cancel") }}</button></p> + <p><button id="reset-ok" class="reset-ok">{{ _("OK") }}</button> <button id="reset-cancel" class="reset-cancel">{{ _("Cancel") }}</button></p> </div> </div> - <div id="footer-info-text" contenteditable="true"><div>{{ _("Proudly generated with") }} <a href="http://inkstitch.org/" target="_blank">Ink/Stitch</a></div></div> + <div id="footer-info-text" class="info-text" contenteditable="true"><div>{{ _("Proudly generated with") }} <a href="http://inkstitch.org/" target="_blank">Ink/Stitch</a></div></div> <p class="notice--warning"><b>Note</b>: If you are using Firefox, use visible URLs. Links will not be printed to PDF with this browser.</p> </fieldset> <button class="save-settings" title="{{ _('Includes these Page Setup, estimated time settings and also the icon.') }}">{{ _("Save as defaults") }}</button> diff --git a/print/templates/ui_svg_action_buttons.html b/print/templates/ui_svg_action_buttons.html index c111d634..6b199383 100644 --- a/print/templates/ui_svg_action_buttons.html +++ b/print/templates/ui_svg_action_buttons.html @@ -4,7 +4,12 @@ <button class="svg-full">100%</button> <button class="svg-apply">{{ _('Apply to all') }}</button> <button class="svg-realistic"> - <input type="checkbox" id="realistic-operator-overview" data-field-name="overview" class="realistic" /> - <label for="realistic-operator-overview" class="realistic">{{ _('Realistic') }}</label> + {% if loop_index is defined %} + <input type="checkbox" id="realistic-color-block-{{ loop_index }}" data-field-name="block{{ loop_index }}" class="realistic" /> + <label for="realistic-color-block-{{ loop_index }}" class="realistic">{{ _('Realistic') }}</label> + {% else %} + <input type="checkbox" id="{{ realistic_id }}" data-field-name="overview" class="realistic" /> + <label for="{{ realistic_id }}" class="realistic">{{ _('Realistic') }}</label> + {% endif %} </button> </div> |
