forked from kmhcreative/Share-on-Mastodon-Easily
-
Notifications
You must be signed in to change notification settings - Fork 0
/
some.js
270 lines (265 loc) · 46.2 KB
/
some.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
/* Share On Mastodon Easily
========================
Script URI: https://github.com/kmhcreative/Share-on-Mastodon-Easily/
Description: Makes sharing to Mastodon instances as easy as any other social media platform.
Version: 1.4
Author: K.M. Hansen <[email protected]>
Author URI: http://www.kmhcreative.com
License: GPLv3
License URI: http://www.gnu.org/licenses/gpl-3.0.html
HOW TO USE THIS SCRIPT
-----------------------
See README.md file or visit https://www.kmhcreative.com/share-on-mastodon-easily-script/
*/
var some = some || {}; // to prevent name collisions
/* Settings */
some['settings'] = {
queryobj : '.mastodon',// query to find mastodon share elements
titletoo : true, // whether to include the page title and URL
rememberme : true, // whether to offer to remember instance or not
skipdialog : true, // whether to skip the instance dialog if remembered
openapopup : true, // whether to open in a pop-up window, false opens in new tab
};
some['text'] = {
'heading' : "Share on Mastodon",
'label' : "Your instance URL",
'checkbox': "Remember my instance on this website",
'close' : "Close",
'share' : "Share!",
'whatis' : "What is Mastodon?",
'link1' : "https://joinmastodon.org",
'github' : "Mastodon on GitHub",
'link2' : "https://github.com/mastodon/mastodon"
};
// if this script is also styling the share button
some['logo'] = { // SVG Mastodon icons/logos using the file names from joinmastodon.org
'black' : '<svg width="74" height="79" viewBox="0 0 74 79" fill="black" xmlns="http://www.w3.org/2000/svg"><path d="M73.7014 17.4323C72.5616 9.05152 65.1774 2.4469 56.424 1.1671C54.9472 0.950843 49.3518 0.163818 36.3901 0.163818H36.2933C23.3281 0.163818 20.5465 0.950843 19.0697 1.1671C10.56 2.41145 2.78877 8.34604 0.903306 16.826C-0.00357854 21.0022 -0.100361 25.6322 0.068112 29.8793C0.308275 35.9699 0.354874 42.0498 0.91406 48.1156C1.30064 52.1448 1.97502 56.1419 2.93215 60.0769C4.72441 67.3445 11.9795 73.3925 19.0876 75.86C26.6979 78.4332 34.8821 78.8603 42.724 77.0937C43.5866 76.8952 44.4398 76.6647 45.2833 76.4024C47.1867 75.8033 49.4199 75.1332 51.0616 73.9562C51.0841 73.9397 51.1026 73.9184 51.1156 73.8938C51.1286 73.8693 51.1359 73.8421 51.1368 73.8144V67.9366C51.1364 67.9107 51.1302 67.8852 51.1186 67.862C51.1069 67.8388 51.0902 67.8184 51.0695 67.8025C51.0489 67.7865 51.0249 67.7753 50.9994 67.7696C50.9738 67.764 50.9473 67.7641 50.9218 67.7699C45.8976 68.9569 40.7491 69.5519 35.5836 69.5425C26.694 69.5425 24.3031 65.3699 23.6184 63.6327C23.0681 62.1314 22.7186 60.5654 22.5789 58.9744C22.5775 58.9477 22.5825 58.921 22.5934 58.8965C22.6043 58.8721 22.621 58.8505 22.6419 58.8336C22.6629 58.8167 22.6876 58.8049 22.714 58.7992C22.7404 58.7934 22.7678 58.794 22.794 58.8007C27.7345 59.9796 32.799 60.5746 37.8813 60.5733C39.1036 60.5733 40.3223 60.5733 41.5447 60.5414C46.6562 60.3996 52.0437 60.1408 57.0728 59.1694C57.1983 59.1446 57.3237 59.1233 57.4313 59.0914C65.3638 57.5847 72.9128 52.8555 73.6799 40.8799C73.7086 40.4084 73.7803 35.9415 73.7803 35.4523C73.7839 33.7896 74.3216 23.6576 73.7014 17.4323ZM61.4925 47.3144H53.1514V27.107C53.1514 22.8528 51.3591 20.6832 47.7136 20.6832C43.7061 20.6832 41.6988 23.2499 41.6988 28.3194V39.3803H33.4078V28.3194C33.4078 23.2499 31.3969 20.6832 27.3894 20.6832C23.7654 20.6832 21.9552 22.8528 21.9516 27.107V47.3144H13.6176V26.4937C13.6176 22.2395 14.7157 18.8598 16.9118 16.3545C19.1772 13.8552 22.1488 12.5719 25.8373 12.5719C30.1064 12.5719 33.3325 14.1955 35.4832 17.4394L37.5587 20.8853L39.6377 17.4394C41.7884 14.1955 45.0145 12.5719 49.2765 12.5719C52.9614 12.5719 55.9329 13.8552 58.2055 16.3545C60.4017 18.8574 61.4997 22.2371 61.4997 26.4937L61.4925 47.3144Z" fill="inherit"/></svg>',
'full-black' : '<svg width="313" height="80" viewBox="0 0 313 80" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M72.9455 17.5328C71.8169 9.0343 64.5038 2.32556 55.846 1.03496C54.3811 0.815795 48.8453 0.012207 36.0206 0.012207H35.9245C23.0879 0.012207 20.338 0.815795 18.873 1.03496C10.4433 2.30121 2.75813 8.31595 0.884866 16.924C-0.00373551 21.1611 -0.0998005 25.8609 0.0683132 30.1711C0.308475 36.3563 0.356508 42.5171 0.908881 48.678C1.29314 52.769 1.95359 56.8235 2.90223 60.817C4.67943 68.1954 11.8603 74.3319 18.8971 76.8279C26.4261 79.4335 34.5317 79.8717 42.2888 78.0819C43.1414 77.875 43.982 77.6437 44.8226 77.3757C46.7079 76.767 48.9173 76.0852 50.5504 74.892C50.5745 74.8798 50.5865 74.8554 50.5985 74.8311C50.6105 74.8067 50.6225 74.7824 50.6225 74.7458V68.7798C50.6225 68.7798 50.6225 68.7311 50.5985 68.7068C50.5985 68.6824 50.5745 68.6581 50.5504 68.6459C50.5264 68.6337 50.5024 68.6215 50.4785 68.6094C50.4543 68.6094 50.4304 68.6094 50.4064 68.6094C45.4349 69.8148 40.3316 70.4236 35.2281 70.4113C26.4261 70.4113 24.0605 66.1742 23.3881 64.421C22.8477 62.8991 22.4995 61.304 22.3554 59.6968C22.3554 59.6725 22.3554 59.6481 22.3674 59.6238C22.3674 59.5995 22.3914 59.5751 22.4155 59.5629C22.4394 59.5508 22.4634 59.5385 22.4874 59.5264H22.5715C27.4588 60.7196 32.4782 61.3284 37.5096 61.3284C38.7225 61.3284 39.9232 61.3284 41.1361 61.2919C46.1915 61.1457 51.5232 60.89 56.5065 59.9038C56.6265 59.8795 56.7587 59.8551 56.8667 59.8308C64.7201 58.2967 72.1891 53.4995 72.9455 41.3483C72.9697 40.8735 73.0417 36.332 73.0417 35.8449C73.0417 34.1525 73.582 23.8763 72.9576 17.5573L72.9455 17.5328Z" fill="white"/><path d="M14.8143 22.2813C14.8143 19.7975 16.7717 17.8008 19.1973 17.8008C21.623 17.8008 23.5802 19.8097 23.5802 22.2813C23.5802 24.753 21.623 26.7619 19.1973 26.7619C16.7717 26.7619 14.8143 24.753 14.8143 22.2813Z" fill="black"/><path d="M80.0185 26.141V46.742H72.0331V26.7498C72.0331 22.537 70.304 20.4062 66.8336 20.4062C63.003 20.4062 61.0697 22.951 61.0697 27.9551V38.9009H53.1444V27.9551C53.1444 22.9265 51.2351 20.4062 47.3804 20.4062C43.9222 20.4062 42.1809 22.537 42.1809 26.7498V46.7299H34.2075V26.141C34.2075 21.9404 35.2522 18.5921 37.3536 16.1083C39.5271 13.6245 42.373 12.3704 45.8914 12.3704C49.9742 12.3704 53.0723 13.9775 55.1137 17.1919L57.1071 20.6011L59.1004 17.1919C61.1417 13.9898 64.2279 12.3704 68.3226 12.3704C71.841 12.3704 74.6869 13.6367 76.8604 16.1083C78.9618 18.5921 80.0065 21.916 80.0065 26.141H80.0185ZM107.493 36.3806C109.15 34.5907 109.931 32.3748 109.931 29.6718C109.931 26.9689 109.138 24.7286 107.493 23.024C105.908 21.2342 103.891 20.3819 101.453 20.3819C99.0153 20.3819 97.01 21.2342 95.413 23.024C93.8279 24.7286 93.0354 26.9689 93.0354 29.6718C93.0354 32.3748 93.8279 34.6151 95.413 36.3806C96.998 38.0851 99.0153 38.9497 101.453 38.9497C103.891 38.9497 105.896 38.0974 107.493 36.3806ZM109.931 13.1983H117.796V46.1455H109.931V42.2614C107.553 45.4879 104.263 47.083 99.9881 47.083C95.7132 47.083 92.4229 45.4392 89.5049 42.0788C86.635 38.7184 85.1821 34.5664 85.1821 29.6962C85.1821 24.826 86.647 20.7349 89.5049 17.3745C92.4349 14.0141 95.9173 12.3096 99.9881 12.3096C104.059 12.3096 107.553 13.8924 109.931 17.1067V13.2227V13.1983ZM144.262 29.051C146.58 30.8407 147.733 33.3368 147.673 36.4902C147.673 39.8506 146.52 42.4928 144.142 44.3191C141.765 46.1089 138.894 47.022 135.412 47.022C129.132 47.022 124.869 44.38 122.611 39.1932L129.433 35.0413C130.344 37.866 132.35 39.3271 135.412 39.3271C138.222 39.3271 139.615 38.414 139.615 36.5023C139.615 35.1144 137.789 33.8603 134.067 32.8862C132.662 32.4965 131.498 32.0948 130.597 31.7661C129.311 31.2426 128.219 30.6459 127.306 29.9154C125.049 28.1256 123.897 25.7635 123.897 22.7318C123.897 19.5053 124.989 16.9362 127.186 15.0856C129.445 13.174 132.193 12.2607 135.484 12.2607C140.731 12.2607 144.562 14.5619 147.072 19.2374L140.371 23.1822C139.399 20.9419 137.741 19.8218 135.484 19.8218C133.106 19.8218 131.953 20.7349 131.953 22.5248C131.953 23.9128 133.779 25.1669 137.501 26.141C140.371 26.7985 142.628 27.7846 144.262 29.051H144.274H144.262ZM169.263 21.3559H162.37V35.0657C162.37 36.7093 162.983 37.7077 164.147 38.1583C165 38.487 166.705 38.5478 169.275 38.4261V46.1332C163.979 46.7907 160.137 46.255 157.88 44.4895C155.622 42.7849 154.529 39.6072 154.529 35.0778V21.3559H149.233V13.1861H154.529V6.53829L162.394 3.96923V13.1983H169.287V21.3682H169.275L169.263 21.3559ZM194.336 36.1858C195.921 34.4813 196.713 32.3018 196.713 29.6597C196.713 27.0176 195.921 24.8626 194.336 23.1335C192.738 21.429 190.793 20.5645 188.416 20.5645C186.038 20.5645 184.093 21.4169 182.495 23.1335C180.971 24.9234 180.178 27.0785 180.178 29.6597C180.178 32.2409 180.971 34.396 182.495 36.1858C184.081 37.8904 186.038 38.7548 188.416 38.7548C190.793 38.7548 192.738 37.9026 194.336 36.1858ZM176.961 42.0422C173.85 38.6818 172.325 34.603 172.325 29.6597C172.325 24.7164 173.85 20.6985 176.961 17.3381C180.07 13.9775 183.913 12.273 188.416 12.273C192.918 12.273 196.774 13.9775 199.872 17.3381C202.97 20.6985 204.567 24.8503 204.567 29.6597C204.567 34.469 202.97 38.6818 199.872 42.0422C196.761 45.4027 192.979 47.0464 188.416 47.0464C183.853 47.0464 180.058 45.4027 176.961 42.0422ZM230.864 36.3685C232.449 34.5786 233.242 32.3627 233.242 29.6597C233.242 26.9568 232.449 24.7164 230.864 23.0118C229.28 21.222 227.263 20.3698 224.824 20.3698C222.387 20.3698 220.369 21.222 218.725 23.0118C217.139 24.7164 216.347 26.9568 216.347 29.6597C216.347 32.3627 217.139 34.603 218.725 36.3685C220.381 38.073 222.447 38.9375 224.824 38.9375C227.203 38.9375 229.268 38.0851 230.864 36.3685ZM233.242 0H241.107V46.1332H233.242V42.2492C230.925 45.4758 227.634 47.0707 223.36 47.0707C219.085 47.0707 215.747 45.4271 212.804 42.0665C209.934 38.7061 208.482 34.5543 208.482 29.6841C208.482 24.8139 209.946 20.7228 212.804 17.3624C215.722 14.0019 219.264 12.2973 223.36 12.2973C227.454 12.2973 230.925 13.8801 233.242 17.0945V0.0121756V0ZM268.738 36.1492C270.323 34.4447 271.116 32.2653 271.116 29.6232C271.116 26.9811 270.323 24.826 268.738 23.0971C267.153 21.3925 265.208 20.5281 262.818 20.5281C260.429 20.5281 258.496 21.3803 256.898 23.0971C255.373 24.8869 254.58 27.0419 254.58 29.6232C254.58 32.2044 255.373 34.3594 256.898 36.1492C258.484 37.8539 260.441 38.7184 262.818 38.7184C265.196 38.7184 267.141 37.866 268.738 36.1492ZM251.362 42.0057C248.265 38.6452 246.727 34.5664 246.727 29.6232C246.727 24.6799 248.253 20.6619 251.362 17.3015C254.472 13.9411 258.315 12.2364 262.818 12.2364C267.321 12.2364 271.176 13.9411 274.274 17.3015C277.383 20.6619 278.969 24.8139 278.969 29.6232C278.969 34.4326 277.383 38.6452 274.274 42.0057C271.164 45.3662 267.381 47.0099 262.818 47.0099C258.255 47.0099 254.46 45.3662 251.362 42.0057ZM313 25.861V46.0967H305.135V26.9202C305.135 24.7407 304.594 23.0971 303.478 21.8552C302.445 20.7349 300.98 20.1505 299.094 20.1505C294.652 20.1505 292.394 22.8535 292.394 28.3204V46.1089H284.529V13.1861H292.394V16.8875C294.279 13.7949 297.281 12.273 301.472 12.273C304.822 12.273 307.572 13.454 309.71 15.8891C311.908 18.3242 313 21.6239 313 25.8974" fill="black"/></svg>',
'full-white' : '<svg width="313" height="80" viewBox="0 0 313 80" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M72.9455 17.5324C71.8169 9.03393 64.5038 2.32519 55.846 1.03459C54.3811 0.815429 48.8453 0.0118408 36.0206 0.0118408H35.9245C23.0879 0.0118408 20.338 0.815429 18.873 1.03459C10.4433 2.30085 2.75813 8.31558 0.884866 16.9237C-0.00373551 21.1608 -0.0998005 25.8606 0.0683132 30.1707C0.308475 36.3559 0.356508 42.5167 0.908881 48.6776C1.29314 52.7686 1.95359 56.8231 2.90223 60.8166C4.67943 68.195 11.8603 74.3316 18.8971 76.8275C26.4261 79.4331 34.5317 79.8714 42.2888 78.0815C43.1414 77.8746 43.982 77.6433 44.8226 77.3754C46.7079 76.7666 48.9173 76.0848 50.5504 74.8916C50.5745 74.8794 50.5865 74.8551 50.5985 74.8307C50.6105 74.8064 50.6225 74.782 50.6225 74.7455V68.7794C50.6225 68.7794 50.6225 68.7308 50.5985 68.7064C50.5985 68.6821 50.5745 68.6577 50.5504 68.6455C50.5264 68.6334 50.5024 68.6211 50.4785 68.609C50.4543 68.609 50.4304 68.609 50.4064 68.609C45.4349 69.8144 40.3316 70.4232 35.2281 70.411C26.4261 70.411 24.0605 66.1739 23.3881 64.4206C22.8477 62.8987 22.4995 61.3036 22.3554 59.6965C22.3554 59.6721 22.3554 59.6478 22.3674 59.6234C22.3674 59.5991 22.3914 59.5747 22.4155 59.5625C22.4394 59.5504 22.4634 59.5382 22.4874 59.5261H22.5715C27.4588 60.7192 32.4782 61.328 37.5096 61.328C38.7225 61.328 39.9232 61.328 41.1361 61.2915C46.1915 61.1453 51.5232 60.8897 56.5065 59.9035C56.6265 59.8791 56.7587 59.8548 56.8667 59.8304C64.7201 58.2963 72.1891 53.4991 72.9455 41.3479C72.9697 40.8731 73.0417 36.3316 73.0417 35.8446C73.0417 34.1521 73.582 23.876 72.9576 17.5569L72.9455 17.5324Z" fill="black"/><path d="M14.8143 22.2813C14.8143 19.7975 16.7717 17.8008 19.1973 17.8008C21.623 17.8008 23.5802 19.8097 23.5802 22.2813C23.5802 24.753 21.623 26.7619 19.1973 26.7619C16.7717 26.7619 14.8143 24.753 14.8143 22.2813Z" fill="white"/><path d="M80.0185 26.141V46.742H72.0331V26.7498C72.0331 22.537 70.304 20.4062 66.8336 20.4062C63.003 20.4062 61.0697 22.951 61.0697 27.9551V38.9009H53.1444V27.9551C53.1444 22.9265 51.2351 20.4062 47.3804 20.4062C43.9222 20.4062 42.1809 22.537 42.1809 26.7498V46.7299H34.2075V26.141C34.2075 21.9404 35.2522 18.5921 37.3536 16.1083C39.5271 13.6245 42.373 12.3704 45.8914 12.3704C49.9742 12.3704 53.0723 13.9775 55.1137 17.1919L57.1071 20.6011L59.1004 17.1919C61.1417 13.9898 64.2279 12.3704 68.3226 12.3704C71.841 12.3704 74.6869 13.6367 76.8604 16.1083C78.9618 18.5921 80.0065 21.916 80.0065 26.141H80.0185ZM107.493 36.3806C109.15 34.5907 109.931 32.3748 109.931 29.6718C109.931 26.9689 109.138 24.7286 107.493 23.024C105.908 21.2342 103.891 20.3819 101.453 20.3819C99.0153 20.3819 97.01 21.2342 95.413 23.024C93.8279 24.7286 93.0354 26.9689 93.0354 29.6718C93.0354 32.3748 93.8279 34.6151 95.413 36.3806C96.998 38.0851 99.0153 38.9497 101.453 38.9497C103.891 38.9497 105.896 38.0974 107.493 36.3806ZM109.931 13.1983H117.796V46.1455H109.931V42.2614C107.553 45.4879 104.263 47.083 99.9881 47.083C95.7132 47.083 92.4229 45.4392 89.5049 42.0788C86.635 38.7184 85.1821 34.5664 85.1821 29.6962C85.1821 24.826 86.647 20.7349 89.5049 17.3745C92.4349 14.0141 95.9173 12.3096 99.9881 12.3096C104.059 12.3096 107.553 13.8924 109.931 17.1067V13.2227V13.1983ZM144.262 29.051C146.58 30.8407 147.733 33.3368 147.673 36.4902C147.673 39.8506 146.52 42.4928 144.142 44.3191C141.765 46.1089 138.894 47.022 135.412 47.022C129.132 47.022 124.869 44.38 122.611 39.1932L129.433 35.0413C130.344 37.866 132.35 39.3271 135.412 39.3271C138.222 39.3271 139.615 38.414 139.615 36.5023C139.615 35.1144 137.789 33.8603 134.067 32.8862C132.662 32.4965 131.498 32.0948 130.597 31.7661C129.311 31.2426 128.219 30.6459 127.306 29.9154C125.049 28.1256 123.897 25.7635 123.897 22.7318C123.897 19.5053 124.989 16.9362 127.186 15.0856C129.445 13.174 132.193 12.2607 135.484 12.2607C140.731 12.2607 144.562 14.5619 147.072 19.2374L140.371 23.1822C139.399 20.9419 137.741 19.8218 135.484 19.8218C133.106 19.8218 131.953 20.7349 131.953 22.5248C131.953 23.9128 133.779 25.1669 137.501 26.141C140.371 26.7985 142.628 27.7846 144.262 29.051H144.274H144.262ZM169.263 21.3559H162.37V35.0657C162.37 36.7093 162.983 37.7077 164.147 38.1583C165 38.487 166.705 38.5478 169.275 38.4261V46.1332C163.979 46.7907 160.137 46.255 157.88 44.4895C155.622 42.7849 154.529 39.6072 154.529 35.0778V21.3559H149.233V13.1861H154.529V6.53829L162.394 3.96923V13.1983H169.287V21.3682H169.275L169.263 21.3559ZM194.336 36.1858C195.921 34.4813 196.713 32.3018 196.713 29.6597C196.713 27.0176 195.921 24.8626 194.336 23.1335C192.738 21.429 190.793 20.5645 188.416 20.5645C186.038 20.5645 184.093 21.4169 182.495 23.1335C180.971 24.9234 180.178 27.0785 180.178 29.6597C180.178 32.2409 180.971 34.396 182.495 36.1858C184.081 37.8904 186.038 38.7548 188.416 38.7548C190.793 38.7548 192.738 37.9026 194.336 36.1858ZM176.961 42.0422C173.85 38.6818 172.325 34.603 172.325 29.6597C172.325 24.7164 173.85 20.6985 176.961 17.3381C180.07 13.9775 183.913 12.273 188.416 12.273C192.918 12.273 196.774 13.9775 199.872 17.3381C202.97 20.6985 204.567 24.8503 204.567 29.6597C204.567 34.469 202.97 38.6818 199.872 42.0422C196.761 45.4027 192.979 47.0464 188.416 47.0464C183.853 47.0464 180.058 45.4027 176.961 42.0422ZM230.864 36.3685C232.449 34.5786 233.242 32.3627 233.242 29.6597C233.242 26.9568 232.449 24.7164 230.864 23.0118C229.28 21.222 227.263 20.3698 224.824 20.3698C222.387 20.3698 220.369 21.222 218.725 23.0118C217.139 24.7164 216.347 26.9568 216.347 29.6597C216.347 32.3627 217.139 34.603 218.725 36.3685C220.381 38.073 222.447 38.9375 224.824 38.9375C227.203 38.9375 229.268 38.0851 230.864 36.3685ZM233.242 0H241.107V46.1332H233.242V42.2492C230.925 45.4758 227.634 47.0707 223.36 47.0707C219.085 47.0707 215.747 45.4271 212.804 42.0665C209.934 38.7061 208.482 34.5543 208.482 29.6841C208.482 24.8139 209.946 20.7228 212.804 17.3624C215.722 14.0019 219.264 12.2973 223.36 12.2973C227.454 12.2973 230.925 13.8801 233.242 17.0945V0.0121756V0ZM268.738 36.1492C270.323 34.4447 271.116 32.2653 271.116 29.6232C271.116 26.9811 270.323 24.826 268.738 23.0971C267.153 21.3925 265.208 20.5281 262.818 20.5281C260.429 20.5281 258.496 21.3803 256.898 23.0971C255.373 24.8869 254.58 27.0419 254.58 29.6232C254.58 32.2044 255.373 34.3594 256.898 36.1492C258.484 37.8539 260.441 38.7184 262.818 38.7184C265.196 38.7184 267.141 37.866 268.738 36.1492ZM251.362 42.0057C248.265 38.6452 246.727 34.5664 246.727 29.6232C246.727 24.6799 248.253 20.6619 251.362 17.3015C254.472 13.9411 258.315 12.2364 262.818 12.2364C267.321 12.2364 271.176 13.9411 274.274 17.3015C277.383 20.6619 278.969 24.8139 278.969 29.6232C278.969 34.4326 277.383 38.6452 274.274 42.0057C271.164 45.3662 267.381 47.0099 262.818 47.0099C258.255 47.0099 254.46 45.3662 251.362 42.0057ZM313 25.861V46.0967H305.135V26.9202C305.135 24.7407 304.594 23.0971 303.478 21.8552C302.445 20.7349 300.98 20.1505 299.094 20.1505C294.652 20.1505 292.394 22.8535 292.394 28.3204V46.1089H284.529V13.1861H292.394V16.8875C294.279 13.7949 297.281 12.273 301.472 12.273C304.822 12.273 307.572 13.454 309.71 15.8891C311.908 18.3242 313 21.6239 313 25.8974" fill="white"/></svg>',
'purple' : '<svg width="75" height="79" viewBox="0 0 75 79" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M73.8393 17.4898C72.6973 9.00165 65.2994 2.31235 56.5296 1.01614C55.05 0.797115 49.4441 0 36.4582 0H36.3612C23.3717 0 20.585 0.797115 19.1054 1.01614C10.5798 2.27644 2.79399 8.28712 0.904997 16.8758C-0.00358524 21.1056 -0.100549 25.7949 0.0682394 30.0965C0.308852 36.2651 0.355538 42.423 0.91577 48.5665C1.30307 52.6474 1.97872 56.6957 2.93763 60.6812C4.73325 68.042 12.0019 74.1676 19.1233 76.6666C26.7478 79.2728 34.9474 79.7055 42.8039 77.9162C43.6682 77.7151 44.5217 77.4817 45.3645 77.216C47.275 76.6092 49.5123 75.9305 51.1571 74.7385C51.1797 74.7217 51.1982 74.7001 51.2112 74.6753C51.2243 74.6504 51.2316 74.6229 51.2325 74.5948V68.6416C51.2321 68.6154 51.2259 68.5896 51.2142 68.5661C51.2025 68.5426 51.1858 68.522 51.1651 68.5058C51.1444 68.4896 51.1204 68.4783 51.0948 68.4726C51.0692 68.4669 51.0426 68.467 51.0171 68.4729C45.9835 69.675 40.8254 70.2777 35.6502 70.2682C26.7439 70.2682 24.3486 66.042 23.6626 64.2826C23.1113 62.762 22.7612 61.1759 22.6212 59.5646C22.6197 59.5375 22.6247 59.5105 22.6357 59.4857C22.6466 59.4609 22.6633 59.4391 22.6843 59.422C22.7053 59.4048 22.73 59.3929 22.7565 59.3871C22.783 59.3813 22.8104 59.3818 22.8367 59.3886C27.7864 60.5826 32.8604 61.1853 37.9522 61.1839C39.1768 61.1839 40.3978 61.1839 41.6224 61.1516C46.7435 61.008 52.1411 60.7459 57.1796 59.7621C57.3053 59.7369 57.431 59.7154 57.5387 59.6831C65.4861 58.157 73.0493 53.3672 73.8178 41.2381C73.8465 40.7606 73.9184 36.2364 73.9184 35.7409C73.9219 34.0569 74.4606 23.7949 73.8393 17.4898Z" fill="url(#paint0_linear_549_34)"/><path d="M61.2484 27.0263V48.114H52.8916V27.6475C52.8916 23.3388 51.096 21.1413 47.4437 21.1413C43.4287 21.1413 41.4177 23.7409 41.4177 28.8755V40.0782H33.1111V28.8755C33.1111 23.7409 31.0965 21.1413 27.0815 21.1413C23.4507 21.1413 21.6371 23.3388 21.6371 27.6475V48.114H13.2839V27.0263C13.2839 22.7176 14.384 19.2946 16.5843 16.7572C18.8539 14.2258 21.8311 12.926 25.5264 12.926C29.8036 12.926 33.0357 14.5705 35.1905 17.8559L37.2698 21.346L39.3527 17.8559C41.5074 14.5705 44.7395 12.926 49.0095 12.926C52.7013 12.926 55.6784 14.2258 57.9553 16.7572C60.1531 19.2922 61.2508 22.7152 61.2484 27.0263Z" fill="white"/><defs><linearGradient id="paint0_linear_549_34" x1="37.0692" y1="0" x2="37.0692" y2="79" gradientUnits="userSpaceOnUse"><stop stop-color="#6364FF"/><stop offset="1" stop-color="#563ACC"/></linearGradient></defs></svg>',
'white' : '<svg width="74" height="79" viewBox="0 0 74 79" fill="white" xmlns="http://www.w3.org/2000/svg"><path d="M73.7014 17.9592C72.5616 9.62034 65.1774 3.04876 56.424 1.77536C54.9472 1.56019 49.3517 0.7771 36.3901 0.7771H36.2933C23.3281 0.7771 20.5465 1.56019 19.0697 1.77536C10.56 3.01348 2.78877 8.91838 0.903306 17.356C-0.00357857 21.5113 -0.100361 26.1181 0.068112 30.3439C0.308275 36.404 0.354874 42.4535 0.91406 48.489C1.30064 52.498 1.97502 56.4751 2.93215 60.3905C4.72441 67.6217 11.9795 73.6395 19.0876 76.0945C26.6979 78.6548 34.8821 79.0799 42.724 77.3221C43.5866 77.1245 44.4398 76.8953 45.2833 76.6342C47.1867 76.0381 49.4199 75.3714 51.0616 74.2003C51.0841 74.1839 51.1026 74.1627 51.1156 74.1382C51.1286 74.1138 51.1359 74.0868 51.1368 74.0592V68.2108C51.1364 68.185 51.1302 68.1596 51.1185 68.1365C51.1069 68.1134 51.0902 68.0932 51.0695 68.0773C51.0489 68.0614 51.0249 68.0503 50.9994 68.0447C50.9738 68.0391 50.9473 68.0392 50.9218 68.045C45.8976 69.226 40.7491 69.818 35.5836 69.8087C26.694 69.8087 24.3031 65.6569 23.6184 63.9285C23.0681 62.4347 22.7186 60.8764 22.5789 59.2934C22.5775 59.2669 22.5825 59.2403 22.5934 59.216C22.6043 59.1916 22.621 59.1702 22.6419 59.1533C22.6629 59.1365 22.6876 59.1248 22.714 59.1191C22.7404 59.1134 22.7678 59.1139 22.794 59.1206C27.7345 60.2936 32.799 60.8856 37.8813 60.8843C39.1036 60.8843 40.3223 60.8843 41.5447 60.8526C46.6562 60.7115 52.0437 60.454 57.0728 59.4874C57.1983 59.4628 57.3237 59.4416 57.4313 59.4098C65.3638 57.9107 72.9128 53.2051 73.6799 41.2895C73.7086 40.8204 73.7803 36.3758 73.7803 35.889C73.7839 34.2347 74.3216 24.1533 73.7014 17.9592ZM61.4925 47.6918H53.1514V27.5855C53.1514 23.3526 51.3591 21.1938 47.7136 21.1938C43.7061 21.1938 41.6988 23.7476 41.6988 28.7919V39.7974H33.4078V28.7919C33.4078 23.7476 31.3969 21.1938 27.3894 21.1938C23.7654 21.1938 21.9552 23.3526 21.9516 27.5855V47.6918H13.6176V26.9752C13.6176 22.7423 14.7157 19.3795 16.9118 16.8868C19.1772 14.4 22.1488 13.1231 25.8373 13.1231C30.1064 13.1231 33.3325 14.7386 35.4832 17.9662L37.5587 21.3949L39.6377 17.9662C41.7884 14.7386 45.0145 13.1231 49.2765 13.1231C52.9614 13.1231 55.9329 14.4 58.2055 16.8868C60.4017 19.3772 61.4997 22.74 61.4997 26.9752L61.4925 47.6918Z" fill="inherit"/></svg>',
'wordmark-black-text' : '<svg width="314" height="80" viewBox="0 0 314 80" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M73.4455 17.6962C72.3169 9.19775 65.0038 2.48901 56.346 1.19841C54.8811 0.979247 49.3453 0.175659 36.5206 0.175659H36.4245C23.5879 0.175659 20.838 0.979247 19.373 1.19841C10.9433 2.46467 3.25813 8.4794 1.38487 17.0875C0.496264 21.3246 0.400199 26.0244 0.568313 30.3345C0.808475 36.5198 0.856508 42.6805 1.40888 48.8414C1.79314 52.9325 2.45359 56.9869 3.40223 60.9804C5.17943 68.3588 12.3603 74.4954 19.3971 76.9914C26.9261 79.5969 35.0317 80.0352 42.7888 78.2453C43.6414 78.0385 44.482 77.8071 45.3226 77.5392C47.2079 76.9304 49.4173 76.2486 51.0504 75.0555C51.0745 75.0432 51.0865 75.0189 51.0985 74.9945C51.1105 74.9702 51.1225 74.9458 51.1225 74.9093V68.9433C51.1225 68.9433 51.1225 68.8946 51.0985 68.8702C51.0985 68.8459 51.0745 68.8215 51.0504 68.8093C51.0264 68.7972 51.0024 68.785 50.9785 68.7728C50.9543 68.7728 50.9304 68.7728 50.9064 68.7728C45.9349 69.9783 40.8316 70.587 35.7281 70.5748C26.9261 70.5748 24.5605 66.3377 23.8881 64.5844C23.3477 63.0625 22.9995 61.4675 22.8554 59.8603C22.8554 59.8359 22.8554 59.8116 22.8674 59.7873C22.8674 59.7629 22.8914 59.7386 22.9155 59.7263C22.9394 59.7142 22.9634 59.702 22.9874 59.6899H23.0715C27.9588 60.883 32.9782 61.4918 38.0096 61.4918C39.2225 61.4918 40.4232 61.4918 41.6361 61.4554C46.6915 61.3092 52.0232 61.0535 57.0065 60.0673C57.1265 60.0429 57.2587 60.0186 57.3667 59.9943C65.2201 58.4601 72.6891 53.6629 73.4455 41.5117C73.4697 41.0369 73.5417 36.4954 73.5417 36.0084C73.5417 34.3159 74.082 24.0398 73.4576 17.7207L73.4455 17.6962Z" fill="url(#paint0_linear_612_176)"/><path d="M15.3145 22.4452C15.3145 19.9613 17.2718 17.9646 19.6974 17.9646C22.1231 17.9646 24.0803 19.9735 24.0803 22.4452C24.0803 24.9168 22.1231 26.9257 19.6974 26.9257C17.2718 26.9257 15.3145 24.9168 15.3145 22.4452Z" fill="white"/><path d="M80.5188 26.3048V46.9058H72.5334V26.9136C72.5334 22.7008 70.8042 20.57 67.3338 20.57C63.5033 20.57 61.5699 23.1148 61.5699 28.1189V39.0647H53.6446V28.1189C53.6446 23.0904 51.7353 20.57 47.8807 20.57C44.4224 20.57 42.6811 22.7008 42.6811 26.9136V46.8937H34.7078V26.3048C34.7078 22.1042 35.7525 18.7559 37.8539 16.2721C40.0274 13.7883 42.8733 12.5342 46.3916 12.5342C50.4744 12.5342 53.5725 14.1413 55.614 17.3557L57.6073 20.7649L59.6007 17.3557C61.642 14.1536 64.7281 12.5342 68.8229 12.5342C72.3412 12.5342 75.1872 13.8005 77.3607 16.2721C79.4621 18.7559 80.5068 22.0798 80.5068 26.3048H80.5188ZM107.993 36.5444C109.65 34.7546 110.431 32.5386 110.431 29.8357C110.431 27.1327 109.638 24.8924 107.993 23.1879C106.408 21.398 104.391 20.5457 101.953 20.5457C99.5156 20.5457 97.5102 21.398 95.9132 23.1879C94.3281 24.8924 93.5356 27.1327 93.5356 29.8357C93.5356 32.5386 94.3281 34.7789 95.9132 36.5444C97.4982 38.2489 99.5156 39.1135 101.953 39.1135C104.391 39.1135 106.396 38.2612 107.993 36.5444ZM110.431 13.3622H118.296V46.3093H110.431V42.4253C108.053 45.6517 104.763 47.2468 100.488 47.2468C96.2134 47.2468 92.9232 45.603 90.0052 42.2426C87.1353 38.8822 85.6823 34.7302 85.6823 29.86C85.6823 24.9898 87.1472 20.8988 90.0052 17.5383C92.9352 14.1779 96.4176 12.4734 100.488 12.4734C104.559 12.4734 108.053 14.0562 110.431 17.2705V13.3865V13.3622ZM144.762 29.2148C147.08 31.0045 148.233 33.5006 148.173 36.654C148.173 40.0144 147.02 42.6566 144.642 44.4829C142.265 46.2727 139.394 47.1858 135.912 47.1858C129.632 47.1858 125.369 44.5438 123.111 39.357L129.933 35.2051C130.844 38.0298 132.851 39.4909 135.912 39.4909C138.722 39.4909 140.115 38.5778 140.115 36.6661C140.115 35.2782 138.289 34.0241 134.567 33.05C133.162 32.6604 131.998 32.2586 131.097 31.9299C129.812 31.4064 128.719 30.8097 127.806 30.0792C125.549 28.2894 124.397 25.9273 124.397 22.8956C124.397 19.6691 125.489 17.1 127.687 15.2494C129.945 13.3378 132.694 12.4246 135.984 12.4246C141.231 12.4246 145.062 14.7258 147.572 19.4012L140.872 23.346C139.899 21.1058 138.241 19.9856 135.984 19.9856C133.606 19.9856 132.454 20.8988 132.454 22.6886C132.454 24.0767 134.279 25.3308 138.002 26.3048C140.872 26.9623 143.129 27.9485 144.762 29.2148H144.774H144.762ZM169.764 21.5198H162.87V35.2295C162.87 36.8731 163.483 37.8715 164.648 38.3221C165.5 38.6508 167.206 38.7116 169.776 38.5899V46.2971C164.48 46.9545 160.637 46.4188 158.38 44.6533C156.122 42.9487 155.029 39.771 155.029 35.2416V21.5198H149.733V13.3499H155.029V6.7021L162.894 4.13305V13.3622H169.788V21.532H169.776L169.764 21.5198ZM194.836 36.3496C196.422 34.6451 197.213 32.4656 197.213 29.8236C197.213 27.1814 196.422 25.0264 194.836 23.2974C193.239 21.5928 191.293 20.7283 188.916 20.7283C186.538 20.7283 184.593 21.5807 182.996 23.2974C181.471 25.0872 180.678 27.2423 180.678 29.8236C180.678 32.4047 181.471 34.5598 182.996 36.3496C184.581 38.0542 186.538 38.9186 188.916 38.9186C191.293 38.9186 193.239 38.0664 194.836 36.3496ZM177.461 42.206C174.35 38.8456 172.826 34.7668 172.826 29.8236C172.826 24.8802 174.35 20.8623 177.461 17.5019C180.571 14.1413 184.413 12.4368 188.916 12.4368C193.419 12.4368 197.274 14.1413 200.372 17.5019C203.47 20.8623 205.067 25.0141 205.067 29.8236C205.067 34.6328 203.47 38.8456 200.372 42.206C197.261 45.5666 193.48 47.2102 188.916 47.2102C184.353 47.2102 180.559 45.5666 177.461 42.206ZM231.364 36.5323C232.95 34.7425 233.742 32.5265 233.742 29.8236C233.742 27.1206 232.95 24.8802 231.364 23.1756C229.78 21.3858 227.763 20.5336 225.325 20.5336C222.888 20.5336 220.869 21.3858 219.225 23.1756C217.64 24.8802 216.847 27.1206 216.847 29.8236C216.847 32.5265 217.64 34.7668 219.225 36.5323C220.881 38.2368 222.948 39.1013 225.325 39.1013C227.703 39.1013 229.768 38.249 231.364 36.5323ZM233.742 0.163818H241.607V46.2971H233.742V42.413C231.425 45.6396 228.135 47.2345 223.86 47.2345C219.585 47.2345 216.247 45.5909 213.304 42.2304C210.434 38.8699 208.982 34.7181 208.982 29.8479C208.982 24.9777 210.446 20.8867 213.304 17.5262C216.222 14.1657 219.765 12.4611 223.86 12.4611C227.955 12.4611 231.425 14.044 233.742 17.2583V0.175994V0.163818ZM269.238 36.313C270.823 34.6085 271.616 32.4291 271.616 29.787C271.616 27.1449 270.823 24.9898 269.238 23.2609C267.654 21.5563 265.708 20.6919 263.318 20.6919C260.929 20.6919 258.996 21.5441 257.399 23.2609C255.873 25.0507 255.08 27.2057 255.08 29.787C255.08 32.3682 255.873 34.5232 257.399 36.313C258.984 38.0177 260.941 38.8822 263.318 38.8822C265.696 38.8822 267.642 38.0298 269.238 36.313ZM251.863 42.1696C248.765 38.809 247.227 34.7302 247.227 29.787C247.227 24.8437 248.753 20.8257 251.863 17.4653C254.972 14.1049 258.815 12.4002 263.318 12.4002C267.822 12.4002 271.676 14.1049 274.774 17.4653C277.884 20.8257 279.469 24.9777 279.469 29.787C279.469 34.5964 277.884 38.809 274.774 42.1696C271.664 45.53 267.882 47.1737 263.318 47.1737C258.755 47.1737 254.96 45.53 251.863 42.1696ZM313.5 26.0248V46.2605H305.635V27.084C305.635 24.9045 305.094 23.2609 303.978 22.019C302.945 20.8988 301.48 20.3144 299.594 20.3144C295.152 20.3144 292.894 23.0173 292.894 28.4842V46.2727H285.029V13.3499H292.894V17.0513C294.779 13.9587 297.781 12.4368 301.973 12.4368C305.322 12.4368 308.072 13.6179 310.211 16.0529C312.408 18.4881 313.5 21.7877 313.5 26.0612" fill="black"/><defs><linearGradient id="paint0_linear_612_176" x1="37.121" y1="0.175659" x2="37.121" y2="79.3169" gradientUnits="userSpaceOnUse"><stop stop-color="#6364FF"/><stop offset="1" stop-color="#563ACC"/></linearGradient></defs></svg>',
'wordmark-white-text' : '<svg width="313" height="81" viewBox="0 0 313 81" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M72.9455 18.4505C71.8169 9.95203 64.5038 3.24329 55.846 1.95268C54.3811 1.73352 48.8453 0.929932 36.0206 0.929932H35.9245C23.0879 0.929932 20.338 1.73352 18.873 1.95268C10.4433 3.21894 2.75813 9.23367 0.884866 17.8418C-0.00373551 22.0789 -0.0998005 26.7787 0.0683132 31.0888C0.308475 37.274 0.356508 43.4348 0.908881 49.5957C1.29314 53.6867 1.95359 57.7412 2.90223 61.7347C4.67943 69.1131 11.8603 75.2497 18.8971 77.7456C26.4261 80.3512 34.5317 80.7894 42.2888 78.9996C43.1414 78.7927 43.982 78.5614 44.8226 78.2935C46.7079 77.6847 48.9173 77.0029 50.5504 75.8097C50.5745 75.7975 50.5865 75.7732 50.5985 75.7488C50.6105 75.7245 50.6225 75.7001 50.6225 75.6635V69.6975C50.6225 69.6975 50.6225 69.6488 50.5985 69.6245C50.5985 69.6002 50.5745 69.5758 50.5504 69.5636C50.5264 69.5515 50.5024 69.5392 50.4785 69.5271C50.4543 69.5271 50.4304 69.5271 50.4064 69.5271C45.4349 70.7325 40.3316 71.3413 35.2281 71.3291C26.4261 71.3291 24.0605 67.0919 23.3881 65.3387C22.8477 63.8168 22.4995 62.2217 22.3554 60.6146C22.3554 60.5902 22.3554 60.5659 22.3674 60.5415C22.3674 60.5172 22.3914 60.4928 22.4155 60.4806C22.4394 60.4685 22.4634 60.4563 22.4874 60.4441H22.5715C27.4588 61.6373 32.4782 62.2461 37.5096 62.2461C38.7225 62.2461 39.9232 62.2461 41.1361 62.2096C46.1915 62.0634 51.5232 61.8077 56.5065 60.8216C56.6265 60.7972 56.7587 60.7729 56.8667 60.7485C64.7201 59.2144 72.1891 54.4172 72.9455 42.266C72.9697 41.7912 73.0417 37.2497 73.0417 36.7627C73.0417 35.0702 73.582 24.7941 72.9576 18.475L72.9455 18.4505Z" fill="url(#paint0_linear_539_135)"/><path d="M14.8143 23.1993C14.8143 20.7155 16.7717 18.7188 19.1973 18.7188C21.623 18.7188 23.5802 20.7277 23.5802 23.1993C23.5802 25.6709 21.623 27.6799 19.1973 27.6799C16.7717 27.6799 14.8143 25.6709 14.8143 23.1993Z" fill="white"/><path d="M80.0185 27.059V47.66H72.0331V27.6677C72.0331 23.455 70.304 21.3242 66.8336 21.3242C63.003 21.3242 61.0697 23.869 61.0697 28.873V39.8189H53.1444V28.873C53.1444 23.8445 51.2351 21.3242 47.3804 21.3242C43.9222 21.3242 42.1809 23.455 42.1809 27.6677V47.6479H34.2075V27.059C34.2075 22.8583 35.2522 19.51 37.3536 17.0263C39.5271 14.5424 42.373 13.2883 45.8914 13.2883C49.9742 13.2883 53.0723 14.8955 55.1137 18.1098L57.1071 21.5191L59.1004 18.1098C61.1417 14.9077 64.2279 13.2883 68.3226 13.2883C71.841 13.2883 74.6869 14.5547 76.8604 17.0263C78.9618 19.51 80.0065 22.834 80.0065 27.059H80.0185ZM107.493 37.2985C109.15 35.5087 109.931 33.2928 109.931 30.5898C109.931 27.8868 109.138 25.6466 107.493 23.942C105.908 22.1522 103.891 21.2998 101.453 21.2998C99.0153 21.2998 97.01 22.1522 95.413 23.942C93.8279 25.6466 93.0354 27.8868 93.0354 30.5898C93.0354 33.2928 93.8279 35.5331 95.413 37.2985C96.998 39.0031 99.0153 39.8677 101.453 39.8677C103.891 39.8677 105.896 39.0153 107.493 37.2985ZM109.931 14.1163H117.796V47.0634H109.931V43.1794C107.553 46.4059 104.263 48.0009 99.9881 48.0009C95.7132 48.0009 92.4229 46.3572 89.5049 42.9967C86.635 39.6363 85.1821 35.4844 85.1821 30.6142C85.1821 25.7439 86.647 21.6529 89.5049 18.2925C92.4349 14.9321 95.9173 13.2275 99.9881 13.2275C104.059 13.2275 107.553 14.8103 109.931 18.0247V14.1407V14.1163ZM144.262 29.9689C146.58 31.7586 147.733 34.2547 147.673 37.4082C147.673 40.7686 146.52 43.4107 144.142 45.237C141.765 47.0269 138.894 47.94 135.412 47.94C129.132 47.94 124.869 45.298 122.611 40.1111L129.433 35.9593C130.344 38.784 132.35 40.2451 135.412 40.2451C138.222 40.2451 139.615 39.3319 139.615 37.4203C139.615 36.0323 137.789 34.7782 134.067 33.8042C132.662 33.4145 131.498 33.0127 130.597 32.684C129.311 32.1605 128.219 31.5639 127.306 30.8334C125.049 29.0436 123.897 26.6814 123.897 23.6497C123.897 20.4233 124.989 17.8542 127.186 16.0035C129.445 14.092 132.193 13.1787 135.484 13.1787C140.731 13.1787 144.562 15.4799 147.072 20.1554L140.371 24.1002C139.399 21.8599 137.741 20.7398 135.484 20.7398C133.106 20.7398 131.953 21.6529 131.953 23.4427C131.953 24.8308 133.779 26.0849 137.501 27.059C140.371 27.7164 142.628 28.7026 144.262 29.9689H144.274H144.262ZM169.263 22.2739H162.37V35.9836C162.37 37.6273 162.983 38.6257 164.147 39.0763C165 39.405 166.705 39.4658 169.275 39.3441V47.0512C163.979 47.7087 160.137 47.1729 157.88 45.4075C155.622 43.7029 154.529 40.5251 154.529 35.9958V22.2739H149.233V14.1041H154.529V7.45625L162.394 4.8872V14.1163H169.287V22.2861H169.275L169.263 22.2739ZM194.336 37.1038C195.921 35.3992 196.713 33.2197 196.713 30.5777C196.713 27.9355 195.921 25.7805 194.336 24.0515C192.738 22.347 190.793 21.4825 188.416 21.4825C186.038 21.4825 184.093 22.3348 182.495 24.0515C180.971 25.8413 180.178 27.9965 180.178 30.5777C180.178 33.1588 180.971 35.314 182.495 37.1038C184.081 38.8083 186.038 39.6728 188.416 39.6728C190.793 39.6728 192.738 38.8206 194.336 37.1038ZM176.961 42.9602C173.85 39.5998 172.325 35.521 172.325 30.5777C172.325 25.6343 173.85 21.6165 176.961 18.256C180.07 14.8955 183.913 13.1909 188.416 13.1909C192.918 13.1909 196.774 14.8955 199.872 18.256C202.97 21.6165 204.567 25.7683 204.567 30.5777C204.567 35.387 202.97 39.5998 199.872 42.9602C196.761 46.3207 192.979 47.9643 188.416 47.9643C183.853 47.9643 180.058 46.3207 176.961 42.9602ZM230.864 37.2864C232.449 35.4966 233.242 33.2807 233.242 30.5777C233.242 27.8747 232.449 25.6343 230.864 23.9298C229.28 22.1399 227.263 21.2877 224.824 21.2877C222.387 21.2877 220.369 22.1399 218.725 23.9298C217.139 25.6343 216.347 27.8747 216.347 30.5777C216.347 33.2807 217.139 35.521 218.725 37.2864C220.381 38.991 222.447 39.8554 224.824 39.8554C227.203 39.8554 229.268 39.0031 230.864 37.2864ZM233.242 0.917969H241.107V47.0512H233.242V43.1672C230.925 46.3937 227.634 47.9887 223.36 47.9887C219.085 47.9887 215.747 46.3451 212.804 42.9845C209.934 39.6241 208.482 35.4723 208.482 30.602C208.482 25.7318 209.946 21.6408 212.804 18.2804C215.722 14.9198 219.264 13.2153 223.36 13.2153C227.454 13.2153 230.925 14.7981 233.242 18.0125V0.930144V0.917969ZM268.738 37.0672C270.323 35.3626 271.116 33.1833 271.116 30.5411C271.116 27.8991 270.323 25.7439 268.738 24.015C267.153 22.3105 265.208 21.446 262.818 21.446C260.429 21.446 258.496 22.2983 256.898 24.015C255.373 25.8049 254.58 27.9599 254.58 30.5411C254.58 33.1224 255.373 35.2774 256.898 37.0672C258.484 38.7719 260.441 39.6363 262.818 39.6363C265.196 39.6363 267.141 38.784 268.738 37.0672ZM251.362 42.9237C248.265 39.5632 246.727 35.4844 246.727 30.5411C246.727 25.5979 248.253 21.5799 251.362 18.2195C254.472 14.859 258.315 13.1544 262.818 13.1544C267.321 13.1544 271.176 14.859 274.274 18.2195C277.383 21.5799 278.969 25.7318 278.969 30.5411C278.969 35.3505 277.383 39.5632 274.274 42.9237C271.164 46.2841 267.381 47.9279 262.818 47.9279C258.255 47.9279 254.46 46.2841 251.362 42.9237ZM313 26.7789V47.0146H305.135V27.8382C305.135 25.6587 304.594 24.015 303.478 22.7732C302.445 21.6529 300.98 21.0685 299.094 21.0685C294.652 21.0685 292.394 23.7715 292.394 29.2383V47.0269H284.529V14.1041H292.394V17.8055C294.279 14.7128 297.281 13.1909 301.472 13.1909C304.822 13.1909 307.572 14.372 309.71 16.8071C311.908 19.2422 313 22.5418 313 26.8154" fill="white"/><defs><linearGradient id="paint0_linear_539_135" x1="36.621" y1="0.929932" x2="36.621" y2="80.0712" gradientUnits="userSpaceOnUse"><stop stop-color="#6364FF"/><stop offset="1" stop-color="#563ACC"/></linearGradient></defs></svg>'
};
some['color'] = { // main color, rollover color, text color (taken from joinmastodon.org examples)
'black' : ['#000000','#333333','#ffffff'],
'white' : ['#ffffff','#f6f6f6','#000000'],
'midnight' : ['#17063b','#000000','#ffffff'],
'blurple' : ['#6364ff','#563acc','#000000'],
'darkblue' : ['#2f0c7a','#17063b','#ffffff'],
'lightblue': ['#858afa','#6364ff','#000000']
};
some['window'] = null; // used to track if pop-up is closed or not
// Find Share Buttons/Links and attach event listeners
some['action'] = function(){
some['buttons'] = document.querySelectorAll(some.settings.queryobj);
var logo = color = size = ''; // in case this script is also styling buttons
for (var b=0; b < some.buttons.length; b++){
// if this button has already been modified by this script
if (some.buttons[b].getAttribute('data-mod')){
continue; // skip this one
}
// see if this actually has an href or not
if (some.buttons[b].hasAttribute('href') && (some.buttons[b].href.startsWith("https://") || some.buttons[b].href.startsWith("http://")) ){
var url = some.buttons[b].href;
} else {
var url = window.location.href;
}
/* If this script is also styling the buttons
get the data attributes from the element.
Note that this does not error check against
bad color combinations like black on black
*/
if (some.buttons[b].hasAttribute('data-style')){
// default configuration for icon and word buttons
if (some.buttons[b].getAttribute('data-style') == 'icon'){
logo = 'white';
color = 'blurple';
size = 48;
} else if (some.buttons[b].getAttribute('data-style') == 'word'){
logo = 'full-white';
color = 'blurple';
size = 32;
} else {
// invalid type, do nothing
console.error('Mastodon share button '+b+' data-style value is invalid');
}
} else {
// custom user configuration (NOTE: Does not prevent bad color combos!)
if (some.buttons[b].hasAttribute('data-logo')){
logo = some.buttons[b].getAttribute('data-logo');
if (!logo in some['logo']){
logo = '';
console.error('Mastodon share button '+b+' data-logo value is invalid');
};
};
if (some.buttons[b].hasAttribute('data-color')){
color = some.buttons[b].getAttribute('data-color');
if (!color in some['color']){
color = '';
console.error('Mastodon share button '+b+' data-color value is invalid');
}
};
if (some.buttons[b].hasAttribute('data-size')){
size = some.buttons[b].getAttribute('data-size');
// size needs to be a number
if (isNaN(size)){
size = '';
console.error('Mastodon share button '+b+' data-size value is invalid, must be a number');
}
};
};
console.log ('logo = '+logo+'; color = '+color+'; size='+size);
if (logo && color && size) { // all three must be defined
/* How I got proper sizing:
=========================
joinmastodon.org says to give their logo 36px of "room to breathe" at full size.
This calculates the logo height and spacing based on a given button height.
*/
var button_height = size+'px';
var button_width = "auto";
var logo_height = Math.round(size*.52);
var spacing = Math.round( (size-logo_height)/2 );
var radius = Math.round(spacing/2);
var font_color= some['color'][color][2];
if (logo == "black" || logo == "white" || logo == "purple"){ // icon only
button_width = button_height;
}
var button_style = 'display: inline-block;height: '+button_height+';width: '+button_width+';border-radius: '+spacing+'px;padding: '+spacing+'px;font-size: 0px;color: transparent;background-color:'+some['color'][color][0]+';border:none;box-sizing:border-box;cursor:pointer;';
some.buttons[b].style = button_style+some.buttons[b].getAttribute('style'); // preserve any existing inline styles (assume they may be overrides)
// use immediate-invoked function expression to capture color var on this loop
some.buttons[b].addEventListener('mouseover',function(rollover){
return function(){
event.preventDefault();
this.style.backgroundColor = rollover;
event.stopImmediatePropagation();
}
}(some['color'][color][1]));
some.buttons[b].addEventListener('mouseout',function(rollback){
return function(){
event.preventDefault();
this.style.backgroundColor = rollback;
event.stopImmediatePropagation();
}
}(some['color'][color][0]));
// inject logo SVG and set height with inline style
some.buttons[b].innerHTML = some['logo'][logo].replace('<svg ','<svg style="height:'+logo_height+'px;width:auto;" ');
logo = color = size = ''; // reset for next go-round
}
// if script runs again do not mod this button
some.buttons[b].setAttribute('data-mod','complete');
// add our event listener
some.buttons[b].addEventListener('click',function(){
event.preventDefault(); // prevent normal link action
some.share(url);
event.stopImmediatePropagation(); // prevent multi-fire bubbling
});
}
};
// Do the sharing bit...
some['share'] = function(url){
// Get current page URL if none was sent to function
if (!url){
url = window.location.href;
}
// If get Title Too is set
if (some.settings.titletoo){
var title = document.querySelectorAll('meta[property="og:title"]')[0];
if (!title){
var title = document.getElementsByTagName('title')[0].innerHTML;
} else {
title = title.getAttribute("content");
}
var link = encodeURIComponent(title+'\n\n'+url);
} else {
var title = '';
var link = encodeURIComponent(url);
}
// Close any existing Mastodon Share Window
if (some.window && !some.window.closed){
some.window.close();
}
// Create New Share Window or Tab
if (some.settings.openapopup){
var params = 'height=488,width=440';
} else {
var params = '';
}
some.window = window.open('','some.window', params); // size assumes people are logged into Mastodon
// Build Dialog if necessary or skip it
if (!localStorage['some_mastodon_instance'] || some.setting.skipdialog == false){
var instance = localStorage['some_mastodon_instance'];
if (!instance){ instance = "https://";}
some.window.document.body.innerHTML = ''; // prevent appends
var html = '<!DOCTYPE html>'+
'<html lang="en-US">'+
'<head><title>'+some.text.heading+'</title>'+
'<style>'+
'body{max-width:450px;padding:0px 20px;margin:0px auto;background-color:#1f232b;font-family:roboto,Arial,sans-serif;font-size:13px;color:#9baec8;}'+
'h1 {font-size:24px;line-height:1.48;font-weight:600;color:#d9e1e8;padding-bottom:35px;border-bottom:1px solid #303643;text-align:center;}'+
'svg{height:42px;vertical-align:middle;margin-right:10px;}'+
'strong {color:#d9e1e8;font-weight:500}'+
'textarea,input[type="text"] {box-sizing:border-box;resize:vertical;padding:10px;outline:0;width:100%;border:1px solid #282c37;border-radius:4px;background:#131419;color:#d9e1e8;transition:background-color 300ms ease,border 300ms ease;}'+
'textarea:focus,input:focus{background-color:#1d1f26;border:1px solid #2b90d9;}'+
'button {display: block;width:45%;border: 0;border-radius: 4px;background: #595aff;color: #fff;font-size: 18px;line-height: inherit;height: auto;padding: 10px;text-decoration: none;text-transform: uppercase;text-align: center;box-sizing: border-box;cursor: pointer;font-weight: 500;outline: 0;margin: 50px 0px;}'+
'#close {float:left;background:#df405a;}'+
'#close:hover{background:#e3566d;}'+
'#share {float:right;background:#595aff;}'+
'#share:hover{background:#6364ff;}'+
'footer {border-top:1px solid #303643;padding:1rem 0;width:100%;display:flex;flex-direction:row;align-items:center;justify-content:center;flex-wrap:wrap;}'+
'form::after{content:\'\';clear:both;display:block;}'+
'footer section {margin:.5rem 1rem;}'+
'a {color:#9baec8;}'+
'</style>'+
'<scri'+'pt>'+
'function shareIt(){'+
' var title = "'+title+'";'+
' var new_instance = document.getElementById("instance").value;'+
' if (!new_instance.startsWith("https://") && !new_instance.startsWith("http://")){'+
' new_instance = "https://"+new_instance;'+
' }'+
' if (!new_instance.endsWith("/")){'+
' new_instance = new_instance + "/";'+
' }';
if (some.settings.rememberme){
html += ' if (document.getElementById("remember").checked){'+
' localStorage["some_mastodon_instance"] = new_instance;'+
' }';
}
html += ' window.location = new_instance+"share?text='+link+'";'+
'}'+
'</scr'+'ipt>'+
'</head>'+
'<body>'+
'<h1>'+some['logo']['wordmark-white-text']+'<br/>'+some.text.heading+'</h1>'+
'<form>'+
'<p><label for="instance">'+some.text.label+':</label>'+
'<input type="text" id="instance" value="'+instance+'" required /><br/>';
if (some.settings.rememberme){
html += '<input type="checkbox" id="remember"/> '+some.text.checkbox+'</p>';
}
html += '<button id="close" onclick="self.close();">'+some.text.close+'</button>'+
'<button id="share" onclick="event.preventDefault();shareIt();">'+some.text.share+'</button>'+
'</form>'+
'<footer>'+
'<section><a href="'+some.text.link1+'" target="_blank">'+some.text.whatis+'</a></section>'+
'<section><a href="'+some.text.link2+'" target="_blank">'+some.text.github+'</a></section>'+
'</footer>'+
'</body></html>';
// write HTML into popup dialog
some.window.document.write(html);
} else {
var instance = localStorage['some_mastodon_instance'];
// check that stored instance has protocol
if (!instance.startsWith("https://") && !instance.startsWith("http://")){
instance = "https://"+instance;
}
// fix trailing slash
if (!instance.endsWith("/")){
instance = instance + "/";
}
// Send pop-up window directly to instance login or publish
some.window.location = instance+"share?text="+link;
}
};
window.addEventListener("load", function(){some.action();});