From 3832c86847dbccd94c39e64da4d272cb95570bc7 Mon Sep 17 00:00:00 2001 From: prabhav5112 Date: Wed, 20 Sep 2023 22:23:28 +0530 Subject: [PATCH] Add total completion badge --- badge.png | Bin 0 -> 3826 bytes script.js | 22 ++++++++++++++++++---- 2 files changed, 18 insertions(+), 4 deletions(-) create mode 100644 badge.png diff --git a/badge.png b/badge.png new file mode 100644 index 0000000000000000000000000000000000000000..6ebea22403e22c628d3f14d4f456c715990ea5c8 GIT binary patch literal 3826 zcmVVw>+N&nbrhK7d8mqRxx z5}sfMZBisdG8X^abtN1OJS`N_(a~F5TdROMV`F2KZ!ttfL{B>! zhh;5nY;4EJ$1E%?V@e?w78WZY4yvlEJ3Bj)l9EnNPIh*7dTTuG({>gS2%VjsA0HpM zxVRn`3aFM;x1w80KqTD5ZB&8bm=T^njl7Wc9{(w8uwawGV|TAGPX|K)D~_K9r;NJjtw4Yx@|K~!jgy;})e z;>r>=KmsHXjO?O<;=%lU)}G{r;zmNsys_dNLsiRF+WQ~7!L|3R!C9v)UJHLy=$j5q|l%L7yMp0o2v??iv1I z>@^yD_`}`V?)4S^aP<3cfv#K`x->nTh}R5!d{y~=?COsI$gypvh?w?q;ENyMZu`mw zjN2>M+ArOq-|v-E2#xTma))1J{Jl+Uu58 zu9>Fm9rv1jpN{YMo4sStRZU>J-(NiA>)=M&iR}O@p_~iB%^r zcD13rF2k5F$LTDQ{X!o9%PgkcAYD(JF1(Qh`_O>RLyl8FWh&nftelmmvY$c8mz>!v zo7ziV&KNhHB<_Ao-t*+{!M4uFNm?MQ@END%d{X$P`WE^9c6)5t#`>S@?iccxZbCMq9`b`V?)SJ2f%n-{~_17J0H!5{)1 zEie4t#@s4Su(?*LmP*0GK83N9O51@k#kL{SMlVYSVf&}{MqZP(Z zr-@6o>UFZaj`$}ExZ{9#p2|>1p1a$OT~W9~jqZ=bQ7xUFU=T8ajgxFx_58xu3=hw3 zrd(BZGP4)$Wa)JA2FJ$P-SAb(2baAkz=5`#y$v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CjpR;Wxf}-WhD&?uxkT!#6qTl^!*d?SqgGNkV*+F!Kcf=;{&3jr z)z-CN%~Y+|91i<^%KwG2w#&RpV1KzO4xUw)THOHEN+_ebz$7yHePF1a#+GF*l|j|c zw?;U2KY_{Aaq^)0rV44LfS)}>0+G#4o^EcQp5`h#iFWOBxy_>*!=Ar?e0;ormI`FY zDUH71ZE&TS-iRRZco%Ac-b=!$ZM$u@Z5*^+;^*|X*nE*M7Lk^k0!CTtZRdYiu)&o?Z)+t*cZB%~aiv1tt%k*(!H zpaed`F10_%!s%`(mCdlW%%+ZOgjDW`pXqdqT23IwGDr+*cW6)CZ6DyFSiH}!9(9iq zIqVYJ93hY2{^m2>dDVK(YDZUbVI>$uO>$-=xciD>J%VmrBN4oSa-)@Y&lHjb_)gHz zbj1}P3VEdVBzjwCJ8U>xeAenhU2#R9^Qc&)JbJM89~#`QUrC32eZilF;zq05HP!Lr z#CACaQQViKWph@TZel>3s7jAKZxi4|Gk(1LIYN}MZe@$v$^E3D29JDGH6<+3NCmeF zpVQBLDX%o9wh8c@L{_dic)(rU|C9}7q?=N4pXsp>51>e`@j5HPsVa|!aixM`JzKQK z_mBLBh`$iJqx&ee2()l+1h_R8uXLvir{v(_TKp&nzI$(tpXBvzmhF#mWt*N1Zw>4UmO=(kFG56ZlXCmT=CH`t&v&W*Teb%- z&(3z$bplc~5gf0%1(py+rRCmwLzWfJ0V8hn}3)Z21>WcX$9zS)yiWL%6 z-EmeVg(51AjAU2&H^?=rj$u9G1}psOo<$Y^=D*oOfpy)Z`$R+`fH_5O@V1ppZy`YG z>3_S?J0$MGe=Wm~@J)i31m~*=1%#Z(xbBx!c3H%TB-A1MGHGqLNm%GvVOKh}IG0-! oqTgN^S1Y&X-zUb!?N&zrA0ZZFA-VIDq5uE@07*qoM6N<$f*-(%-~a#s literal 0 HcmV?d00001 diff --git a/script.js b/script.js index da093d6..2fafc8b 100644 --- a/script.js +++ b/script.js @@ -41,10 +41,11 @@ document.addEventListener('DOMContentLoaded', function () { row.innerHTML = ` ${index + 1} ${data.name} + ${data.redemptionStatus} ${data.coursesCompleted} ${data.skillBadges} ${data.genAIGames} - ${data.redemptionStatus} + `; tableBody.appendChild(row); }); @@ -64,17 +65,30 @@ document.addEventListener('DOMContentLoaded', function () { function renderTable(data) { tableBody.innerHTML = ''; data.forEach((data, index) => { + if (data.coursesCompleted + data.skillBadges + data.genAIGames == 9){ const row = document.createElement('tr'); row.innerHTML = ` - ${index + 1} + ${data.name} - ${data.redemptionStatus} ${data.coursesCompleted} ${data.skillBadges} ${data.genAIGames} - + ${data.redemptionStatus} `; tableBody.appendChild(row); + } + else { + const row = document.createElement('tr'); + row.innerHTML = ` + ${index + 1} + ${data.name} + ${data.coursesCompleted} + ${data.skillBadges} + ${data.genAIGames} + ${data.redemptionStatus} + `; + tableBody.appendChild(row); + } }); } })