|
| 1 | +<!DOCTYPE html> |
| 2 | + |
| 3 | +<html class="shale-v1-light shale-v1-body" lang="en"> |
| 4 | + <head> |
| 5 | + <title>UTM Robotics Email Signature Generator</title> |
| 6 | + <meta viewport="width=device-width, initial-scale=1.0"> |
| 7 | + <link rel="stylesheet" href="https://logonoff.co/projects/v1/shale.css"> |
| 8 | + </head> |
| 9 | + |
| 10 | + <body class="shale-v1-container"> |
| 11 | + <h1 class="shale-v1-h3"><strong>UTM Robotics Email Signatures</strong></h1> |
| 12 | + |
| 13 | + <form id="signature-form" onsubmit="updateSignature(); return false;" class="shale-v1-card shale-v1-container" style="margin: 0;"> |
| 14 | + <div class="shale-v1-input"> |
| 15 | + <label for="name">Name</label> |
| 16 | + <input type="text" id="name" name="name" required> |
| 17 | + </div> |
| 18 | + |
| 19 | + <div class="shale-v1-input"> |
| 20 | + <label for="position">Position</label> |
| 21 | + <input type="text" id="position" name="position" required> |
| 22 | + </div> |
| 23 | + |
| 24 | + <div class="shale-v1-input"> |
| 25 | + <label for="pronouns">Pronouns</label> |
| 26 | + <input type="text" id="pronouns" name="position" placeholder="they/them"> |
| 27 | + </div> |
| 28 | + |
| 29 | + <div class="shale-v1-input"> |
| 30 | + <input type="checkbox" id="image" name="image" checked> |
| 31 | + <label for="image">Include logo?</label> |
| 32 | + </div> |
| 33 | + |
| 34 | + <div> |
| 35 | + <button class="shale-v1-button" type="submit">Generate Signature</button> |
| 36 | + </div> |
| 37 | + </form> |
| 38 | + |
| 39 | + <em>copy paste this:</em> |
| 40 | + |
| 41 | + <div style="border: black 1px solid; background: white; padding: 1rem; margin: 1rem 0;"> |
| 42 | + <div id="signature" contenteditable> |
| 43 | + <p id="robotics-signature-id"> |
| 44 | + <strong id="robotics-signature-name"></strong> |
| 45 | + <em id="robotics-signature-pronouns"></em> |
| 46 | + <br> |
| 47 | + <small><span id="robotics-signature-position"></span></small> |
| 48 | + </p> |
| 49 | + <p> |
| 50 | + <a id="robotics-signature" href="https://robotics-club.utm.utoronto.ca/"><br>UTM Robotics |
| 51 | + Club</a><br> |
| 52 | + <small>3359 Mississauga Rd, Mississauga, ON L5L 1C6</small><br> |
| 53 | + <small>Instagram: <a href="https://www.instagram.com/utm_robotics/">@utm_robotics</a></small><br> |
| 54 | + </p> |
| 55 | + </div> |
| 56 | + </div> |
| 57 | + |
| 58 | + <script> |
| 59 | + const updateSignature = () => { |
| 60 | + const name = document.getElementById('name').value; |
| 61 | + const position = document.getElementById('position').value; |
| 62 | + const pronouns = document.getElementById('pronouns').value || 'they/them'; |
| 63 | + |
| 64 | + document.getElementById('robotics-signature-name').innerText = name; |
| 65 | + document.getElementById('robotics-signature-position').innerText = position; |
| 66 | + document.getElementById('robotics-signature-pronouns').innerText = `(${pronouns})`; |
| 67 | + |
| 68 | + const imageCheckbox = document.getElementById('image'); |
| 69 | + const signatureDiv = document.getElementById('robotics-signature'); |
| 70 | + const logo = document.createElement('img'); |
| 71 | + logo.src = 'https://i.imgur.com/X4eBmI3.png'; |
| 72 | + logo.alt = 'UTM Robotics'; |
| 73 | + logo.style.width = '64px'; |
| 74 | + logo.style.height = '64px'; |
| 75 | + logo.id = 'robotics-signature-logo'; |
| 76 | + |
| 77 | + if (imageCheckbox.checked) { |
| 78 | + document.getElementById('robotics-signature-logo')?.remove(); |
| 79 | + signatureDiv.prepend(logo); |
| 80 | + } else { |
| 81 | + const existingLogo = signatureDiv.querySelector('img'); |
| 82 | + if (existingLogo) { |
| 83 | + existingLogo.remove(); |
| 84 | + } |
| 85 | + } |
| 86 | + }; |
| 87 | + </script> |
| 88 | + |
| 89 | + </body> |
| 90 | + |
| 91 | +</html> |
0 commit comments