forked from taeyangk0331/Profile-Autogeneration-System
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathwelcome.js
721 lines (608 loc) · 23.5 KB
/
welcome.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
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
const option = () => {
return $('#type').val();
};
const repositoryName = () => {
return $('#name').val().trim();
};
/* html and css code uploaded on Github */
const getHTML = (username, repoList, imgurl) => {
console.log("inside getHTML func");
console.log(repoList);
return `<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="style.css">
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/[email protected]/font/bootstrap-icons.css">
<link href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-Zenh87qX5JnK2Jl0vWa8Ck2rdkQ2Bzep5IDxbcnCeuOxjzrPF/et3URy9Bv1WTRi" crossorigin="anonymous">
<link rel="stylesheet" href="https://unpkg.com/github-calendar@latest/dist/github-calendar-responsive.css" />
</head>
<body>
<div id="header_wrap" class="container-sm shadow p-1 float-xl-start bg-light rounded-4">
<img src="${imgurl}" id="profile_photo">
<p><i class="bi bi-person-circle"></i> ${username}</p>
<p><a class="external text-success" href="https://github.com/${username}" target="_blank"><i class="bi bi-github"></i> My Github</a></p>
</div>
<br><br><br>
<div class="calendar">
<!-- Loading stuff -->
Loading the data just for you.
</div>
<div class="container-sm float-xl-end mt-5">
<h2>My Github Portfolio</h2>
<h3>Github Repository</h3>
<div class="m-2">
<div class="d-flex w-100 justify-content-between">
<h4 class="mb-2">${repoList[0]['reponame']}</h5>
</div>
<p class="mb-2">${repoList[0]['desc']}</p>
</div>
<div class="m-2">
<div class="d-flex w-100 justify-content-between">
<h4 class="mb-2">${repoList[1]['reponame']}</h5>
</div>
<p class="mb-2">${repoList[1]['desc']}</p>
</div>
<div class="m-2">
<div class="d-flex w-100 justify-content-between">
<h4 class="mb-2">${repoList[2]['reponame']}</h5>
</div>
<p class="mb-2">${repoList[2]['desc']}</p>
</div>
<div class="m-2">
<div class="d-flex w-100 justify-content-between">
<h4 class="mb-2">${repoList[3]['reponame']}</h5>
</div>
<p class="mb-2">${repoList[3]['desc']}</p>
</div>
<div class="m-2">
<div class="d-flex w-100 justify-content-between">
<h4 class="mb-2">${repoList[4]['reponame']}</h5>
</div>
<p class="mb-2">${repoList[4]['desc']}</p>
</div>
<br>
</div>
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.bundle.min.js" integrity="sha384-OERcA2EqjJCMA+/3y+gxIOqMEjwtxJY7qPCqsdltbNJuaOe923+mo//f6V8Qbsw3" crossorigin="anonymous"></script>
<script src="https://unpkg.com/github-calendar@latest/dist/github-calendar.min.js"></script>
</body>
<script>
GitHubCalendar(".calendar", "${username}", {
responsive: true,
tooltips: true
});
</script>
</html>
`
};
const getCSS = () => {
return `#header_wrap{
width: 450px;
margin: 100px;
}
#profile_photo {
width: 100%;
border-radius: 20px;
margin-top: 10px;
}
.container-sm {
max-width: 900px!important;
}
.container-sm.mt-5 {
margin-right: 80px;
}
.external{
text-decoration: none;
}
.calendar {
margin-top : 100px;
max-width: 60%;
float: left;
margin: 0 auto;
}
.m-2 {
border: 2px solid #eaeaea;
padding: 20px;
border-radius: 10px;
box-shadow: 5px 5px 5px 5px #eaeaea;
}`
};
/* Status codes for creating of repo */
const statusCode = (res, status, name) => {
switch (status) {
case 304:
$('#success').hide();
$('#error').text(`Error creating ${name} - Unable to modify repository. Try again later!`);
$('#error').show();
break;
case 400:
$('#success').hide();
$('#error').text(`Error creating ${name} - Bad POST request, make sure you're not overriding any existing scripts`);
$('#error').show();
break;
case 401:
$('#success').hide();
$('#error').text(`Error creating ${name} - Unauthorized access to repo. Try again later!`);
$('#error').show();
break;
case 403:
$('#success').hide();
$('#error').text(`Error creating ${name} - Forbidden access to repository. Try again later!`);
$('#error').show();
break;
case 422:
$('#success').hide();
$('#error').text(`Error creating ${name} - Unprocessable Entity. Repository may have already been created. Try Linking instead (select 2nd option).`);
$('#error').show();
break;
default:
/* Change mode type to commit */
chrome.storage.local.set({ mode_type: 'commit' }, () => {
$('#error').hide();
$('#success').html(`Successfully created <a target="blank" href="${res.html_url}">${name}</a>. Move onto next step!`);
$('#success').show();
$('#unlink').show();
/* Show new layout */
document.getElementById('hook_mode').style.display = 'none';
document.getElementById('commit_mode').style.display = 'inherit';
});
/* Set Repo Hook */
chrome.storage.local.set({ BaekjoonHub_hook: res.full_name }, () => {
console.log('Successfully set new repo hook');
});
break;
}
};
/* Interact with Github API */
const createRepo = (token, name) => {
const AUTHENTICATION_URL = 'https://api.github.com/user/repos';
let data = {
name,
private: false,
auto_init: true,
description: 'This is a auto push repository created with [GPGen](https://github.com/taeyangk0331/SKKU_OSSP_Project).',
};
data = JSON.stringify(data);
const xhr = new XMLHttpRequest();
xhr.addEventListener('readystatechange', function () {
if (xhr.readyState === 4) {
statusCode(JSON.parse(xhr.responseText), xhr.status, name);
}
});
stats = {};
stats.version = chrome.runtime.getManifest().version;
stats.submission = {};
chrome.storage.local.set({ stats });
xhr.open('POST', AUTHENTICATION_URL, true);
xhr.setRequestHeader('Authorization', `token ${token}`);
xhr.setRequestHeader('Accept', 'application/vnd.github.v3+json');
xhr.send(data);
};
const publishRepo = (token, hook) => {
const AUTHENTICATION_URL = `https://api.github.com/repos/${hook}/pages`;
let data = {
source: {
branch: 'main',
path: '/',
},
};
data = JSON.stringify(data);
const xhr = new XMLHttpRequest();
xhr.addEventListener('readystatechange', function () {
if (xhr.readyState === 4) {
statusCode(JSON.parse(xhr.responseText), xhr.status, name);
}
});
stats = {};
stats.version = chrome.runtime.getManifest().version;
stats.submission = {};
chrome.storage.local.set({ stats });
xhr.open('POST', AUTHENTICATION_URL, true);
xhr.setRequestHeader('Authorization', `token ${token}`);
xhr.setRequestHeader('Accept', 'application/vnd.github.v3+json');
xhr.send(data);
};
const getRepoDesc = async (token, hook) => {
const AUTHENTICATION_URL = `https://api.github.com/repos/${hook}`;
const xhr = new XMLHttpRequest();
xhr.addEventListener('readystatechange', function () {
if (xhr.readyState === XMLHttpRequest.DONE) {
const res = JSON.parse(xhr.responseText);
if (xhr.status === 200) {
return res.description;
}
}
});
stats = {};
stats.version = chrome.runtime.getManifest().version;
stats.submission = {};
chrome.storage.local.set({ stats });
xhr.open('GET', AUTHENTICATION_URL, true);
xhr.setRequestHeader('Authorization', `token ${token}`);
xhr.setRequestHeader('Accept', 'application/vnd.github.v3+json');
xhr.send(null);
};
const getPublishUrl = (token, hook) => {
return new Promise((resolve, reject ) => {
const AUTHENTICATION_URL = `https://api.github.com/repos/${hook}/pages`;
const xhr = new XMLHttpRequest();
xhr.addEventListener('readystatechange', function () {
if (xhr.readyState === 4) {
const res = JSON.parse(xhr.responseText);
if (xhr.status === 200) {
resolve(res.html_url);
}
}
});
stats = {};
stats.version = chrome.runtime.getManifest().version;
stats.submission = {};
chrome.storage.local.set({ stats });
xhr.open('GET', AUTHENTICATION_URL, true);
xhr.setRequestHeader('Authorization', `token ${token}`);
xhr.setRequestHeader('Accept', 'application/vnd.github.v3+json');
xhr.send(null);
});
}
const getUserInfo = (token) => {
return new Promise((resolve, reject ) => {
const AUTHENTICATION_URL = ` https://api.github.com/user`;
const xhr = new XMLHttpRequest();
xhr.addEventListener('readystatechange', function () {
if (xhr.readyState === 4) {
const res = JSON.parse(xhr.responseText);
if (xhr.status === 200) {
resolve(res);
}
}
});
stats = {};
stats.version = chrome.runtime.getManifest().version;
stats.submission = {};
chrome.storage.local.set({ stats });
xhr.open('GET', AUTHENTICATION_URL, true);
xhr.setRequestHeader('Authorization', `token ${token}`);
xhr.setRequestHeader('Accept', 'application/vnd.github.v3+json');
xhr.send(null);
});
}
/* repository list 받아오기 */
//pinned 기준 repository
async function getPinnedRepoList(name){
return new Promise((resolve, reject) => {
const AUTHENTICATION_URL = `https://github.com/${name}`;
let xmlHttp = new XMLHttpRequest();
let githubMainDocument;
let pinnedList = [];
xmlHttp.onreadystatechange = function () {
if (this.readyState === xmlHttp.DONE) {
if (this.status === 200) {
this.onload = () => {
githubMainDocument = this.responseXML;
if (githubMainDocument.querySelector('div.js-pinned-items-reorder-container')){
let tds = githubMainDocument.querySelectorAll('span.repo');
pinnedList = Array.prototype.map.call(tds, function(t) { return t.textContent.trim(); });
resolve(pinnedList);
}
else resolve(pinnedList);
}
} else {
// handle errors
console.log("error: ", this.status);
}
}
};
xmlHttp.open( "GET", AUTHENTICATION_URL);
xmlHttp.responseType = "document";
xmlHttp.send(null);
});
}
//last commit 기준 repository
async function getCommitRepoList(name, commitListLength, pinnedList){
return new Promise((resolve, reject) => {
const AUTHENTICATION_URL = `https://github.com/${name}?tab=repositories`;
let xmlHttp = new XMLHttpRequest();
let githubDocument;
let repoList;
xmlHttp.onreadystatechange = function () {
if (this.readyState === xmlHttp.DONE) {
if (this.status === 200) {
this.onload = () => {
githubDocument = this.responseXML;
let tds = githubDocument.querySelectorAll('h3.wb-break-all > a');
repoList = Array.prototype.map.call(tds, function(t) { return t.textContent.trim(); });
if(commitListLength > 0) pinnedList.forEach(pinnedElement => {
repoList = repoList.filter((item) => item != pinnedElement);
});
//console.log(repoList.slice(0, commitListLength));
resolve(repoList.slice(0, commitListLength));
}
} else {
// handle errors
console.log("error: ", this.status);
}
}
};
xmlHttp.open( "GET", AUTHENTICATION_URL);
xmlHttp.responseType = "document";
xmlHttp.send(null);
});
};
//repository 별로 description 값 전달
async function getReposDesc(username, repoList){
let token = await getToken();
return new Promise((resolve, reject) => {
let totalRepoInfo = [];
repoList.forEach((repoName, index) => {
const AUTHENTICATION_URL = `https://api.github.com/repos/${username}/${repoName}`;
const xhr = new XMLHttpRequest();
xhr.addEventListener('readystatechange', function () {
if (xhr.readyState === 4) {
const res = JSON.parse(xhr.responseText);
if (xhr.status === 200) {
console.log(res.description);
let repoInfo = {};
repoInfo["reponame"] = repoName;
repoInfo["desc"] = res.description;
totalRepoInfo.push(repoInfo);
}
}
});
stats = {};
stats.version = chrome.runtime.getManifest().version;
stats.submission = {};
chrome.storage.local.set({ stats });
xhr.open( "GET", AUTHENTICATION_URL, true);
xhr.setRequestHeader('Authorization', `token ${token}`);
xhr.setRequestHeader('Accept', 'application/vnd.github.v3+json');
xhr.send(null);
});
resolve(totalRepoInfo);
});
}
/* Status codes for linking of repo */
const linkStatusCode = (status, name) => {
let bool = false;
switch (status) {
case 301:
$('#success').hide();
$('#error').html(`Error linking <a target="blank" href="${`https://github.com/${name}`}">${name}</a> to GPGen. <br> This repository has been moved permenantly. Try creating a new one.`);
$('#error').show();
break;
case 403:
$('#success').hide();
$('#error').html(`Error linking <a target="blank" href="${`https://github.com/${name}`}">${name}</a> to GPGen. <br> Forbidden action. Please make sure you have the right access to this repository.`);
$('#error').show();
break;
case 404:
$('#success').hide();
$('#error').html(`Error linking <a target="blank" href="${`https://github.com/${name}`}">${name}</a> to GPGen. <br> Resource not found. Make sure you enter the right repository name.`);
$('#error').show();
break;
default:
bool = true;
break;
}
$('#unlink').show();
return bool;
};
/*
Method for linking hook with an existing repository
Steps:
1. Check if existing repository exists and the user has write access to it.
2. Link Hook to it (chrome Storage).
*/
const linkRepo = (token, name) => {
const AUTHENTICATION_URL = `https://api.github.com/repos/${name}`;
const xhr = new XMLHttpRequest();
xhr.addEventListener('readystatechange', function () {
if (xhr.readyState === 4) {
const res = JSON.parse(xhr.responseText);
const bool = linkStatusCode(xhr.status, name);
if (xhr.status === 200) {
// BUG FIX
if (!bool) {
// unable to gain access to repo in commit mode. Must switch to hook mode.
/* Set mode type to hook */
chrome.storage.local.set({ mode_type: 'hook' }, () => {
console.log(`Error linking ${name} to GPGen`);
});
/* Set Repo Hook to NONE */
chrome.storage.local.set({ BaekjoonHub_hook: null }, () => {
console.log('Defaulted repo hook to NONE');
});
/* Hide accordingly */
document.getElementById('hook_mode').style.display = 'inherit';
document.getElementById('commit_mode').style.display = 'none';
} else {
/* Change mode type to commit */
/* Save repo url to chrome storage */
chrome.storage.local.set({ mode_type: 'commit', repo: res.html_url }, () => {
$('#error').hide();
$('#success').html(`Successfully linked <a target="blank" href="${res.html_url}">${name}</a> to GPGen. Start <a href="https://www.acmicpc.net/">BOJ</a> now!`);
$('#success').show();
$('#unlink').show();
});
/* Set Repo Hook */
stats = {};
stats.version = chrome.runtime.getManifest().version;
stats.submission = {};
chrome.storage.local.set({ stats });
chrome.storage.local.set({ BaekjoonHub_hook: res.full_name }, () => {
console.log('Successfully set new repo hook');
/* Get problems solved count */
chrome.storage.local.get('stats', (psolved) => {
const { stats } = psolved;
});
});
/* Hide accordingly */
document.getElementById('hook_mode').style.display = 'none';
document.getElementById('commit_mode').style.display = 'inherit';
}
}
}
});
xhr.open('GET', AUTHENTICATION_URL, true);
xhr.setRequestHeader('Authorization', `token ${token}`);
xhr.setRequestHeader('Accept', 'application/vnd.github.v3+json');
xhr.send();
};
const unlinkRepo = () => {
/* Set mode type to hook */
chrome.storage.local.set({ mode_type: 'hook' }, () => {
console.log(`Unlinking repo`);
});
/* Set Repo Hook to NONE */
chrome.storage.local.set({ BaekjoonHub_hook: null }, () => {
console.log('Defaulted repo hook to NONE');
});
/* Hide accordingly */
document.getElementById('hook_mode').style.display = 'inherit';
document.getElementById('commit_mode').style.display = 'none';
};
/* Check for value of select tag, Get Started disabled by default */
$('#type').on('change', function () {
const valueSelected = this.value;
if (valueSelected) {
$('#hook_button').attr('disabled', false);
} else {
$('#hook_button').attr('disabled', true);
}
});
$('#hook_button').on('click', async () => {
/* on click should generate: 1) option 2) repository name */
if (!option()) {
$('#error').text('No option selected - Pick an option from dropdown menu below that best suits you!');
$('#error').show();
} else if (!repositoryName()) {
$('#error').text('No repository name added - Enter the name of your repository!');
$('#name').focus();
$('#error').show();
} else {
$('#error').hide();
$('#success').text('Attempting to create Hook... Please wait.');
$('#success').show();
/*
Perform processing
- step 1: Check if current stage === hook.
- step 2: store repo name as repoName in chrome storage.
- step 3: if (1), POST request to repoName (iff option = create new repo) ; else display error message.
- step 4: if proceed from 3, hide hook_mode and display commit_mode (show stats e.g: files pushed/questions-solved/leaderboard)
*/
chrome.storage.local.get('BaekjoonHub_token', (data) => {
const token = data.BaekjoonHub_token;
if (token === null || token === undefined) {
/* Not authorized yet. */
$('#error').text('Authorization error - Grant GPGen access to your GitHub account to continue (launch extension to proceed)');
$('#error').show();
$('#success').hide();
} else if (option() === 'new') {
createRepo(token, repositoryName());
} else {
chrome.storage.local.get('BaekjoonHub_username', (data2) => {
const username = data2.BaekjoonHub_username;
if (!username) {
/* Improper authorization. */
$('#error').text('Improper Authorization error - Grant GPGen access to your GitHub account to continue (launch extension to proceed)');
$('#error').show();
$('#success').hide();
} else {
linkRepo(token, `${username}/${repositoryName()}`, false);
}
});
}
});
}
});
$("#fileupload").on("click", async () => {
let htmlcode;
let repos;
let userinfo;
let token = await getToken();
let hook = await getHook();
let username = hook.split("/")[0];
let readme = "This repository is automatically generated by GPGen.";
let cm = "automatically generated by GPGen";
let cb = null;
let pinnedList = await getPinnedRepoList(username);
let commitListLength = 6 - pinnedList.length;
let commitList = await getCommitRepoList(username, commitListLength, pinnedList);
let repoNameList = pinnedList.concat(commitList);
$("#fileupload").css("color", "green");
userinfo = await getUserInfo(token);
let imgurl = userinfo.avatar_url;
const test = async() => {
const repoPromises = await getReposDesc(username, repoNameList);
repos = await repoPromises;
}
await upload(token, hook, getCSS(), readme, "style.css", cm, cb);
test();
await setTimeout(()=>{
htmlcode = getHTML(username, repos, imgurl);
console.log(htmlcode);
upload(token, hook, htmlcode, readme, "index.html", cm, cb);
}, 1000);
});
$("#deploy").on("click", async () => {
let token = await getToken();
let hook = await getHook();
publishRepo(token, hook);
$("#deploy").css("color", "green");
});
$("#geturl").on("click", async () => {
let token = await getToken();
let hook = await getHook();
let url = await getPublishUrl(token, hook);
console.log(url);
$("#display_url").text(url);
$("#display_url").attr("href", url);
$("#geturl").css("color", "green");
$("#notice_delay").text("If you get 404 error code, please wait a minute. Your site is on building.");
});
$('#unlink a').on('click', () => {
unlinkRepo();
$('#unlink').hide();
$('#success').text('Successfully unlinked your current git repo. Please create/link a new hook.');
});
/* Detect mode type */
chrome.storage.local.get('mode_type', (data) => {
const mode = data.mode_type;
if (mode && mode === 'commit') {
/* Check if still access to repo */
chrome.storage.local.get('BaekjoonHub_token', (data2) => {
const token = data2.BaekjoonHub_token;
if (token === null || token === undefined) {
/* Not authorized yet. */
$('#error').text('Authorization error - Grant GPGen access to your GitHub account to continue (click GPGen extension on the top right to proceed)');
$('#error').show();
$('#success').hide();
/* Hide accordingly */
document.getElementById('hook_mode').style.display = 'inherit';
document.getElementById('commit_mode').style.display = 'none';
} else {
/* Get access to repo */
chrome.storage.local.get('BaekjoonHub_hook', (repoName) => {
const hook = repoName.BaekjoonHub_hook;
if (!hook) {
/* Not authorized yet. */
$('#error').text('Improper Authorization error - Grant GPGen access to your GitHub account to continue (click GPGen extension on the top right to proceed)');
$('#error').show();
$('#success').hide();
/* Hide accordingly */
document.getElementById('hook_mode').style.display = 'inherit';
document.getElementById('commit_mode').style.display = 'none';
} else {
/* Username exists, at least in storage. Confirm this */
linkRepo(token, hook);
}
});
}
});
document.getElementById('hook_mode').style.display = 'none';
document.getElementById('commit_mode').style.display = 'inherit';
} else {
document.getElementById('hook_mode').style.display = 'inherit';
document.getElementById('commit_mode').style.display = 'none';
}
});