appscms-tools-theme 1.8.2 → 1.8.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (103) hide show
  1. checksums.yaml +4 -4
  2. data/LICENSE.txt +21 -21
  3. data/README.md +50 -50
  4. data/_data/about/en/about.json +16 -16
  5. data/_data/blog/alertbar.yml +3 -3
  6. data/_data/blog/authors.yml +11 -11
  7. data/_data/blog/blog.yml +3 -3
  8. data/_data/blog/nav.json +13 -13
  9. data/_data/blog/share.yml +28 -28
  10. data/_data/contact/en/contact.json +38 -38
  11. data/_data/disclaimer/en/disclaimer.json +37 -37
  12. data/_data/download/en/download.json +35 -35
  13. data/_data/feature/en/split-pdf.json +115 -115
  14. data/_data/feature/hi/compress-pdf.json +81 -81
  15. data/_data/feature/tr/compress-pdf.json +80 -80
  16. data/_data/fileinfo/en/fileinfo.json +14 -14
  17. data/_data/files/.gitignore +4 -4
  18. data/_data/files/en/3gp.json +144 -144
  19. data/_data/files/en/acc.json +25 -25
  20. data/_data/files/en/aff.json +65 -65
  21. data/_data/files/en/cr2.json +169 -169
  22. data/_data/files/en/dvd.json +25 -25
  23. data/_data/files/en/mov.json +146 -146
  24. data/_data/files/en/ogg.json +163 -163
  25. data/_data/files/en/vmv.json +47 -47
  26. data/_data/footer/en/data.json +72 -72
  27. data/_data/footer/hi/data.json +68 -68
  28. data/_data/footer/networksites.json +15 -15
  29. data/_data/header/en/data.json +134 -134
  30. data/_data/header/hi/data.json +144 -144
  31. data/_data/home/en/en.json +282 -282
  32. data/_data/home/hi/hi.json +86 -86
  33. data/_data/languagesupport/compress-pdf-langs.json +11 -11
  34. data/_data/languagesupport/index-langs.json +13 -13
  35. data/_data/privacy/en/privacyPolicy.json +265 -265
  36. data/_data/termAndCondition/en/termAndCondition.json +358 -358
  37. data/_includes/Rating/rating.html +92 -92
  38. data/_includes/Rating/structureddata.html +53 -53
  39. data/_includes/Usp/usp.html +86 -86
  40. data/_includes/adsense/adsense.html +7 -7
  41. data/_includes/alternates/alternates.html +45 -45
  42. data/_includes/author_bio.html +16 -16
  43. data/_includes/cssfile/links.html +11 -11
  44. data/_includes/custom-head.html +33 -33
  45. data/_includes/customblog/recentposts.html +46 -46
  46. data/_includes/customblog/relatedposts.html +174 -174
  47. data/_includes/disqus_comments.html +10 -10
  48. data/_includes/dropdown/langdropdown.html +22 -22
  49. data/_includes/feature.html +37 -37
  50. data/_includes/fileformat/comparisonfiles.html +151 -151
  51. data/_includes/fileformat/fileformatdetail.html +101 -101
  52. data/_includes/fileformat/fileinfoformat.html +93 -93
  53. data/_includes/footer/index.html +249 -249
  54. data/_includes/google-analytics.html +22 -22
  55. data/_includes/header/blogHeader.html +29 -29
  56. data/_includes/header/index.html +95 -95
  57. data/_includes/languages/languages.html +61 -33
  58. data/_includes/monumetric/monumetric.html +60 -60
  59. data/_includes/nofiletransfer/nofiletransfer.html +38 -38
  60. data/_includes/paginationBlogPage.html +34 -34
  61. data/_includes/paginationPostPage.html +14 -14
  62. data/_includes/postauthorbio.html +17 -17
  63. data/_includes/postbox.html +31 -31
  64. data/_includes/script.html +27 -26
  65. data/_includes/section/alertbar.html +11 -11
  66. data/_includes/section/count.html +23 -23
  67. data/_includes/section/recent_posts.html +46 -46
  68. data/_includes/section/related_categories_post.html +173 -173
  69. data/_includes/share/socialshare.html +20 -20
  70. data/_includes/staticfooter.html +55 -55
  71. data/_layouts/aboutUs.html +24 -24
  72. data/_layouts/blog.html +70 -70
  73. data/_layouts/categories.html +25 -25
  74. data/_layouts/contactUs.html +78 -78
  75. data/_layouts/default.html +1 -1
  76. data/_layouts/disclaimer.html +78 -78
  77. data/_layouts/download.html +285 -280
  78. data/_layouts/feature.html +209 -209
  79. data/_layouts/fileInfo.html +39 -39
  80. data/_layouts/help.html +23 -23
  81. data/_layouts/home.html +208 -208
  82. data/_layouts/page.html +5 -5
  83. data/_layouts/post.html +144 -144
  84. data/_layouts/privacyPolicy.html +402 -402
  85. data/_layouts/termAndCondition.html +406 -406
  86. data/assets/cross.svg +4 -4
  87. data/assets/css/blog.css +491 -491
  88. data/assets/css/bootstrap.min.css +6 -6
  89. data/assets/css/tools.css +1260 -1212
  90. data/assets/facebook.svg +4 -4
  91. data/assets/images/safevideoconverter.svg +23 -23
  92. data/assets/instagram.svg +4 -4
  93. data/assets/js/TopScroll.js +8 -8
  94. data/assets/js/googledrive.js +155 -155
  95. data/assets/js/manifest.json +16 -16
  96. data/assets/js/multiselect.js +157 -157
  97. data/assets/linkdin.svg +4 -4
  98. data/assets/pdf.svg +20 -20
  99. data/assets/secure.svg +43 -43
  100. data/assets/star.svg +4 -4
  101. data/assets/twitter.svg +4 -4
  102. data/assets/youtube.svg +4 -4
  103. metadata +2 -2
data/assets/facebook.svg CHANGED
@@ -1,5 +1,5 @@
1
- <svg viewBox="0 0 24 24" fill="#000000" xmlns="http://www.w3.org/2000/svg">
2
- <path
3
- d="M18 4.63h-2.397c-1.69 0-2.182.65-2.182 1.897v2.52h4.395l-.584 3.901H13.42V23H8.81V12.948H5V9.047h3.81V6.175C8.81 2.897 11.117 1 14.559 1c1.444 0 2.612.054 3.442.135v3.496z">
4
- </path>
1
+ <svg viewBox="0 0 24 24" fill="#000000" xmlns="http://www.w3.org/2000/svg">
2
+ <path
3
+ d="M18 4.63h-2.397c-1.69 0-2.182.65-2.182 1.897v2.52h4.395l-.584 3.901H13.42V23H8.81V12.948H5V9.047h3.81V6.175C8.81 2.897 11.117 1 14.559 1c1.444 0 2.612.054 3.442.135v3.496z">
4
+ </path>
5
5
  </svg>
@@ -1,23 +1,23 @@
1
- <svg width="28" height="36" viewBox="0 0 27 36" fill="none" xmlns="http://www.w3.org/2000/svg">
2
- <g filter="url(#filter0_d)">
3
- <path d="M13.4999 33.5323C13.3311 33.5323 13.196 33.495 13.0274 33.4576C5.36632 31.0357 0 23.2117 0 14.3817V5.58884C0 4.76905 0.506357 4.0239 1.21499 3.80035L13.0364 0.0717211C13.3394 -0.023907 13.6605 -0.023907 13.9636 0.0717211L25.785 3.80035C26.4936 4.0239 27 4.76905 27 5.58884V14.3817C27 23.2117 21.6337 31.0357 13.9726 33.4576C13.8036 33.495 13.6685 33.5323 13.4999 33.5323Z" fill="url(#paint0_angular)"/>
4
- <path d="M13.0815 0.214774L13.0815 0.214764C13.3551 0.128414 13.6448 0.128409 13.9185 0.214769L13.9185 0.214774L25.7399 3.9434C26.3778 4.14464 26.85 4.8254 26.85 5.58884V14.3817C26.85 23.1521 21.5215 30.9105 13.9337 33.3126C13.91 33.3179 13.8875 33.323 13.8658 33.3279C13.7283 33.3591 13.6261 33.3823 13.4999 33.3823C13.3734 33.3823 13.2711 33.359 13.1335 33.3278C13.112 33.3229 13.0897 33.3178 13.0664 33.3126C5.47851 30.9106 0.15 23.1522 0.15 14.3817V5.58884C0.15 4.82541 0.622175 4.14465 1.26011 3.9434C1.26011 3.9434 1.26011 3.9434 1.26012 3.9434L13.0815 0.214774Z" stroke="#5E5E5E" stroke-width="0.3"/>
5
- </g>
6
- <path d="M8.59927 15.0607C8.75728 15.2974 9.02148 15.4348 9.29895 15.4348C9.35349 15.4348 9.40853 15.4295 9.46336 15.4187C9.79721 15.3522 10.0583 15.0912 10.1246 14.7573L11.0622 10.0436C11.1057 9.82462 11.0606 9.59735 10.9365 9.41174C10.8125 9.22613 10.6198 9.09738 10.4009 9.05384L5.68724 8.11622C5.35313 8.04971 5.01226 8.19108 4.82322 8.47412C4.63407 8.75716 4.63407 9.12631 4.82322 9.40935L6.42124 11.8009C5.17805 13.3819 4.5 15.3312 4.5 17.3588C4.5 20.9376 6.61944 24.1762 9.89946 25.6094C10.0092 25.6573 10.1235 25.6801 10.236 25.6801C10.5604 25.6801 10.8695 25.4914 11.0077 25.1752C11.1938 24.7492 10.9994 24.253 10.5735 24.0669C7.90668 22.9016 6.18345 20.2685 6.18345 17.3588C6.18345 15.8985 6.61625 14.4884 7.41742 13.292L8.59927 15.0607Z" fill="#5286FA"/>
7
- <path d="M20.5793 22.9163C21.8221 21.3353 22.5 19.3862 22.5 17.3589C22.5 13.7801 20.3806 10.5415 17.1005 9.1082C16.6746 8.92212 16.1784 9.11652 15.9922 9.54245C15.8061 9.96839 16.0005 10.4646 16.4265 10.6508C19.0933 11.8161 20.8165 14.4492 20.8165 17.3589C20.8165 18.8189 20.3838 20.2289 19.5829 21.4252L18.4012 19.6568C18.2121 19.3737 17.8712 19.2323 17.5372 19.2989C17.2033 19.3653 16.9423 19.6263 16.8759 19.9601L15.9382 24.6739C15.8947 24.8928 15.9398 25.1201 16.0639 25.3057C16.1879 25.4913 16.3806 25.62 16.5996 25.6636L21.3134 26.6011C21.3682 26.612 21.4232 26.6173 21.4777 26.6173C21.4861 26.6173 21.4945 26.6172 21.5029 26.617C21.9565 26.6042 22.3204 26.2324 22.3204 25.7757C22.3204 25.588 22.2589 25.4147 22.1551 25.2747L20.5793 22.9163Z" fill="#5286FA"/>
8
- <defs>
9
- <filter id="filter0_d" x="0" y="0" width="27" height="35.5323" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
10
- <feFlood flood-opacity="0" result="BackgroundImageFix"/>
11
- <feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0"/>
12
- <feOffset dy="2"/>
13
- <feColorMatrix type="matrix" values="0 0 0 0 0.795833 0 0 0 0 0.795833 0 0 0 0 0.795833 0 0 0 0.16 0"/>
14
- <feBlend mode="normal" in2="BackgroundImageFix" result="effect1_dropShadow"/>
15
- <feBlend mode="normal" in="SourceGraphic" in2="effect1_dropShadow" result="shape"/>
16
- </filter>
17
- <radialGradient id="paint0_angular" cx="0" cy="0" r="1" gradientUnits="userSpaceOnUse" gradientTransform="translate(13.5 16.7661) rotate(-136.42) scale(18.6357 11.5741)">
18
- <stop offset="0.18409" stop-color="white"/>
19
- <stop offset="0.493462" stop-color="#B5B5B5" stop-opacity="0.23"/>
20
- <stop offset="0.813285" stop-color="white" stop-opacity="0.73749"/>
21
- </radialGradient>
22
- </defs>
23
- </svg>
1
+ <svg width="28" height="36" viewBox="0 0 27 36" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <g filter="url(#filter0_d)">
3
+ <path d="M13.4999 33.5323C13.3311 33.5323 13.196 33.495 13.0274 33.4576C5.36632 31.0357 0 23.2117 0 14.3817V5.58884C0 4.76905 0.506357 4.0239 1.21499 3.80035L13.0364 0.0717211C13.3394 -0.023907 13.6605 -0.023907 13.9636 0.0717211L25.785 3.80035C26.4936 4.0239 27 4.76905 27 5.58884V14.3817C27 23.2117 21.6337 31.0357 13.9726 33.4576C13.8036 33.495 13.6685 33.5323 13.4999 33.5323Z" fill="url(#paint0_angular)"/>
4
+ <path d="M13.0815 0.214774L13.0815 0.214764C13.3551 0.128414 13.6448 0.128409 13.9185 0.214769L13.9185 0.214774L25.7399 3.9434C26.3778 4.14464 26.85 4.8254 26.85 5.58884V14.3817C26.85 23.1521 21.5215 30.9105 13.9337 33.3126C13.91 33.3179 13.8875 33.323 13.8658 33.3279C13.7283 33.3591 13.6261 33.3823 13.4999 33.3823C13.3734 33.3823 13.2711 33.359 13.1335 33.3278C13.112 33.3229 13.0897 33.3178 13.0664 33.3126C5.47851 30.9106 0.15 23.1522 0.15 14.3817V5.58884C0.15 4.82541 0.622175 4.14465 1.26011 3.9434C1.26011 3.9434 1.26011 3.9434 1.26012 3.9434L13.0815 0.214774Z" stroke="#5E5E5E" stroke-width="0.3"/>
5
+ </g>
6
+ <path d="M8.59927 15.0607C8.75728 15.2974 9.02148 15.4348 9.29895 15.4348C9.35349 15.4348 9.40853 15.4295 9.46336 15.4187C9.79721 15.3522 10.0583 15.0912 10.1246 14.7573L11.0622 10.0436C11.1057 9.82462 11.0606 9.59735 10.9365 9.41174C10.8125 9.22613 10.6198 9.09738 10.4009 9.05384L5.68724 8.11622C5.35313 8.04971 5.01226 8.19108 4.82322 8.47412C4.63407 8.75716 4.63407 9.12631 4.82322 9.40935L6.42124 11.8009C5.17805 13.3819 4.5 15.3312 4.5 17.3588C4.5 20.9376 6.61944 24.1762 9.89946 25.6094C10.0092 25.6573 10.1235 25.6801 10.236 25.6801C10.5604 25.6801 10.8695 25.4914 11.0077 25.1752C11.1938 24.7492 10.9994 24.253 10.5735 24.0669C7.90668 22.9016 6.18345 20.2685 6.18345 17.3588C6.18345 15.8985 6.61625 14.4884 7.41742 13.292L8.59927 15.0607Z" fill="#5286FA"/>
7
+ <path d="M20.5793 22.9163C21.8221 21.3353 22.5 19.3862 22.5 17.3589C22.5 13.7801 20.3806 10.5415 17.1005 9.1082C16.6746 8.92212 16.1784 9.11652 15.9922 9.54245C15.8061 9.96839 16.0005 10.4646 16.4265 10.6508C19.0933 11.8161 20.8165 14.4492 20.8165 17.3589C20.8165 18.8189 20.3838 20.2289 19.5829 21.4252L18.4012 19.6568C18.2121 19.3737 17.8712 19.2323 17.5372 19.2989C17.2033 19.3653 16.9423 19.6263 16.8759 19.9601L15.9382 24.6739C15.8947 24.8928 15.9398 25.1201 16.0639 25.3057C16.1879 25.4913 16.3806 25.62 16.5996 25.6636L21.3134 26.6011C21.3682 26.612 21.4232 26.6173 21.4777 26.6173C21.4861 26.6173 21.4945 26.6172 21.5029 26.617C21.9565 26.6042 22.3204 26.2324 22.3204 25.7757C22.3204 25.588 22.2589 25.4147 22.1551 25.2747L20.5793 22.9163Z" fill="#5286FA"/>
8
+ <defs>
9
+ <filter id="filter0_d" x="0" y="0" width="27" height="35.5323" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
10
+ <feFlood flood-opacity="0" result="BackgroundImageFix"/>
11
+ <feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0"/>
12
+ <feOffset dy="2"/>
13
+ <feColorMatrix type="matrix" values="0 0 0 0 0.795833 0 0 0 0 0.795833 0 0 0 0 0.795833 0 0 0 0.16 0"/>
14
+ <feBlend mode="normal" in2="BackgroundImageFix" result="effect1_dropShadow"/>
15
+ <feBlend mode="normal" in="SourceGraphic" in2="effect1_dropShadow" result="shape"/>
16
+ </filter>
17
+ <radialGradient id="paint0_angular" cx="0" cy="0" r="1" gradientUnits="userSpaceOnUse" gradientTransform="translate(13.5 16.7661) rotate(-136.42) scale(18.6357 11.5741)">
18
+ <stop offset="0.18409" stop-color="white"/>
19
+ <stop offset="0.493462" stop-color="#B5B5B5" stop-opacity="0.23"/>
20
+ <stop offset="0.813285" stop-color="white" stop-opacity="0.73749"/>
21
+ </radialGradient>
22
+ </defs>
23
+ </svg>
data/assets/instagram.svg CHANGED
@@ -1,5 +1,5 @@
1
- <svg viewBox="0 0 24 24" fill="#000000" xmlns="http://www.w3.org/2000/svg">
2
- <path
3
- d="M12 2.982c2.937 0 3.285.011 4.445.064 1.072.05 1.655.228 2.043.379.513.2.88.438 1.264.823.385.385.624.751.823 1.265.15.387.33.97.379 2.042.053 1.16.064 1.508.064 4.445 0 2.937-.011 3.285-.064 4.445-.05 1.072-.228 1.655-.379 2.043-.2.513-.438.88-.823 1.264a3.408 3.408 0 01-1.264.823c-.388.15-.97.33-2.043.379-1.16.053-1.508.064-4.445.064-2.937 0-3.285-.011-4.445-.064-1.072-.049-1.655-.228-2.042-.379-.514-.2-.88-.438-1.265-.823a3.408 3.408 0 01-.823-1.264c-.15-.388-.33-.97-.379-2.043-.053-1.16-.064-1.508-.064-4.445 0-2.937.011-3.285.064-4.445.049-1.072.228-1.655.379-2.042.2-.514.438-.88.823-1.265a3.408 3.408 0 011.265-.823c.387-.15.97-.33 2.042-.379 1.16-.053 1.508-.064 4.445-.064zM12 1c-2.987 0-3.362.013-4.535.066-1.171.054-1.97.24-2.67.512a5.392 5.392 0 00-1.949 1.268 5.392 5.392 0 00-1.269 1.949c-.271.7-.457 1.499-.51 2.67C1.012 8.638 1 9.013 1 12c0 2.988.013 3.362.066 4.535.054 1.171.24 1.97.511 2.67a5.392 5.392 0 001.27 1.949 5.392 5.392 0 001.948 1.268c.7.273 1.499.458 2.67.512C8.638 22.987 9.013 23 12 23s3.362-.013 4.535-.066c1.171-.054 1.97-.24 2.67-.512a5.391 5.391 0 001.949-1.268 5.391 5.391 0 001.268-1.948c.272-.7.458-1.5.512-2.67.053-1.174.066-1.549.066-4.536 0-2.987-.013-3.362-.066-4.535-.054-1.171-.24-1.97-.512-2.67a5.39 5.39 0 00-1.268-1.949 5.391 5.391 0 00-1.949-1.268c-.7-.272-1.499-.458-2.67-.512C15.362 1.013 14.987 1 12 1zm0 5.351a5.649 5.649 0 100 11.298A5.649 5.649 0 0012 6.35zm0 9.316a3.667 3.667 0 110-7.334 3.667 3.667 0 010 7.334zm7.192-9.539a1.32 1.32 0 11-2.64 0 1.32 1.32 0 012.64 0z">
4
- </path>
1
+ <svg viewBox="0 0 24 24" fill="#000000" xmlns="http://www.w3.org/2000/svg">
2
+ <path
3
+ d="M12 2.982c2.937 0 3.285.011 4.445.064 1.072.05 1.655.228 2.043.379.513.2.88.438 1.264.823.385.385.624.751.823 1.265.15.387.33.97.379 2.042.053 1.16.064 1.508.064 4.445 0 2.937-.011 3.285-.064 4.445-.05 1.072-.228 1.655-.379 2.043-.2.513-.438.88-.823 1.264a3.408 3.408 0 01-1.264.823c-.388.15-.97.33-2.043.379-1.16.053-1.508.064-4.445.064-2.937 0-3.285-.011-4.445-.064-1.072-.049-1.655-.228-2.042-.379-.514-.2-.88-.438-1.265-.823a3.408 3.408 0 01-.823-1.264c-.15-.388-.33-.97-.379-2.043-.053-1.16-.064-1.508-.064-4.445 0-2.937.011-3.285.064-4.445.049-1.072.228-1.655.379-2.042.2-.514.438-.88.823-1.265a3.408 3.408 0 011.265-.823c.387-.15.97-.33 2.042-.379 1.16-.053 1.508-.064 4.445-.064zM12 1c-2.987 0-3.362.013-4.535.066-1.171.054-1.97.24-2.67.512a5.392 5.392 0 00-1.949 1.268 5.392 5.392 0 00-1.269 1.949c-.271.7-.457 1.499-.51 2.67C1.012 8.638 1 9.013 1 12c0 2.988.013 3.362.066 4.535.054 1.171.24 1.97.511 2.67a5.392 5.392 0 001.27 1.949 5.392 5.392 0 001.948 1.268c.7.273 1.499.458 2.67.512C8.638 22.987 9.013 23 12 23s3.362-.013 4.535-.066c1.171-.054 1.97-.24 2.67-.512a5.391 5.391 0 001.949-1.268 5.391 5.391 0 001.268-1.948c.272-.7.458-1.5.512-2.67.053-1.174.066-1.549.066-4.536 0-2.987-.013-3.362-.066-4.535-.054-1.171-.24-1.97-.512-2.67a5.39 5.39 0 00-1.268-1.949 5.391 5.391 0 00-1.949-1.268c-.7-.272-1.499-.458-2.67-.512C15.362 1.013 14.987 1 12 1zm0 5.351a5.649 5.649 0 100 11.298A5.649 5.649 0 0012 6.35zm0 9.316a3.667 3.667 0 110-7.334 3.667 3.667 0 010 7.334zm7.192-9.539a1.32 1.32 0 11-2.64 0 1.32 1.32 0 012.64 0z">
4
+ </path>
5
5
  </svg>
@@ -1,8 +1,8 @@
1
- const alertbar = document.querySelector('.alertbar')
2
- window.addEventListener('scroll', () => {
3
- if (pageYOffset > 200) {
4
- alertbar.style.display = 'block'
5
- } else {
6
- alertbar.style.display = 'none'
7
- }
8
- })
1
+ const alertbar = document.querySelector('.alertbar')
2
+ window.addEventListener('scroll', () => {
3
+ if (pageYOffset > 200) {
4
+ alertbar.style.display = 'block'
5
+ } else {
6
+ alertbar.style.display = 'none'
7
+ }
8
+ })
@@ -1,156 +1,156 @@
1
- ---
2
- ---
3
-
4
- const addScripts=()=>{
5
- const scripts=document.getElementsByTagName('script')
6
- const check= Array.from(scripts).find(item=>item.src==='https://www.dropbox.com/static/api/2/dropins.js')
7
- if(!check){
8
- const dropboxscript = document.createElement('script')
9
- dropboxscript.src = 'https://www.dropbox.com/static/api/2/dropins.js'
10
- dropboxscript.crossOrigin = 'anonymous'
11
- dropboxscript.dataset.appKey = '{{site.dropboxapikey}}'
12
- dropboxscript.id='dropboxjs'
13
- document.head.append(dropboxscript)
14
- }
15
- const checkgooglescript= Array.from(scripts).find(item=>item.src==='https://apis.google.com/js/api.js')
16
- if(!checkgooglescript){
17
- const googlescript = document.createElement('script')
18
- googlescript.src = 'https://apis.google.com/js/api.js'
19
- googlescript.crossOrigin = 'anonymous'
20
- document.head.append(googlescript)
21
- }
22
- }
23
- const developerKey = '{{site.developerKey}}'
24
- const clientId ='{{site.clientId}}'
25
- const appId = '{{site.appId}}'
26
- const scope = [
27
- 'https://www.googleapis.com/auth/drive.file',
28
- 'https://www.googleapis.com/auth/drive.appdata',
29
- ]
30
- let pickerApiLoaded = false
31
- let oauthToken
32
- const loadPicker = () => {
33
- gapi.load('auth', { callback: onAuthApiLoad })
34
- gapi.load('picker', { callback: onPickerApiLoad })
35
- }
36
- const onAuthApiLoad = () => {
37
- window.gapi.auth.authorize(
38
- {
39
- client_id: clientId,
40
- scope: scope,
41
- immediate: false,
42
- },
43
- handleAuthResult
44
- )
45
- }
46
- let onPickerApiLoad = () => {
47
- pickerApiLoaded = true
48
- createPicker()
49
- }
50
- const handleAuthResult = (authResult) => {
51
- if (authResult && !authResult.error) {
52
- oauthToken = authResult.access_token
53
- createPicker()
54
- }
55
- }
56
- const createPicker = () => {
57
- if (pickerApiLoaded && oauthToken) {
58
- const view = new google.picker.View(google.picker.ViewId.DOCS)
59
- view.setMimeTypes(mimeTypes)
60
- const picker = new google.picker.PickerBuilder()
61
- .enableFeature(google.picker.Feature.NAV_HIDDEN)
62
- .enableFeature(google.picker.Feature.MULTISELECT_ENABLED)
63
- .setAppId(appId)
64
- .setOAuthToken(oauthToken)
65
- .addView(view)
66
- .addView(new google.picker.DocsUploadView())
67
- .setDeveloperKey(developerKey)
68
- .setCallback(pickerCallback)
69
- .build()
70
- picker.setVisible(true)
71
- }
72
- }
73
- const pickerCallback = async (data) => {
74
- if (data.action == google.picker.Action.PICKED) {
75
- showLoader()
76
- const res = await fetch(
77
- `https://www.googleapis.com/drive/v3/files/${data.docs[0].id}?alt=media`,
78
- {
79
- headers: {
80
- Authorization: `Bearer ${oauthToken}`,
81
- },
82
- }
83
- ).then((res) => res.blob())
84
- let metadata = {
85
- type: data.docs[0].mimeType,
86
- }
87
- let file = new File([res], data.docs[0].name, metadata)
88
- closeLoader()
89
- getFile(file)
90
- }
91
- }
92
- function chooseFromDropbox() {
93
- Dropbox.choose({
94
- success: async (files) => {
95
- if (files.length < 0) {
96
- return
97
- }
98
- var file = files[0]
99
- const url = new URL(file.link)
100
- showLoader()
101
- const response = await fetch(url).then((res) => res.blob())
102
- let metadata = {
103
- type: response.type,
104
- }
105
- let newFile = new File([response], file.name, metadata)
106
- closeLoader()
107
- getDropBoxFile(newFile)
108
- },
109
- cancel: function () {},
110
- linkType: 'direct',
111
- multiselect: false,
112
- extensions: [...filemimes],
113
- folderselect: false,
114
- })
115
- }
116
-
117
- const fileupload=(file)=>{
118
- gapi.load('auth', {'callback': onAuthLoad});
119
- }
120
- const onAuthLoad=()=> {
121
- window.gapi.auth.authorize(
122
- {
123
- 'client_id': clientId,
124
- 'scope': scope,
125
- 'immediate': false
126
- },
127
- handleAuth);
128
- }
129
- const handleAuth=(authResult)=> {
130
- if (authResult && !authResult.error) {
131
- showuploadloading()
132
- var formData = new FormData();
133
- const fileToUpload = file
134
- var metadata = {
135
- name: fileToUpload.name,
136
- mimeType: fileToUpload.type
137
- };
138
- formData.append( "metadata", new Blob( [JSON.stringify( metadata )], {type: "application/json"} ));
139
- formData.append( "file", fileToUpload );
140
- fetch( "https://www.googleapis.com/upload/drive/v3/files?uploadType=multipart", {
141
- method: "POST",
142
- headers: new Headers({ "Authorization": "Bearer " + gapi.auth.getToken().access_token }),
143
- body: formData
144
- }).then( function( response ){
145
- stopuploadloading()
146
- return response.json();
147
-
148
- }).then( function( value ){
149
- stopuploadloading()
150
- showmessage()
151
- });
152
- }
153
- }
154
-
155
-
1
+ ---
2
+ ---
3
+
4
+ const addScripts=()=>{
5
+ const scripts=document.getElementsByTagName('script')
6
+ const check= Array.from(scripts).find(item=>item.src==='https://www.dropbox.com/static/api/2/dropins.js')
7
+ if(!check){
8
+ const dropboxscript = document.createElement('script')
9
+ dropboxscript.src = 'https://www.dropbox.com/static/api/2/dropins.js'
10
+ dropboxscript.crossOrigin = 'anonymous'
11
+ dropboxscript.dataset.appKey = '{{site.dropboxapikey}}'
12
+ dropboxscript.id='dropboxjs'
13
+ document.head.append(dropboxscript)
14
+ }
15
+ const checkgooglescript= Array.from(scripts).find(item=>item.src==='https://apis.google.com/js/api.js')
16
+ if(!checkgooglescript){
17
+ const googlescript = document.createElement('script')
18
+ googlescript.src = 'https://apis.google.com/js/api.js'
19
+ googlescript.crossOrigin = 'anonymous'
20
+ document.head.append(googlescript)
21
+ }
22
+ }
23
+ const developerKey = '{{site.developerKey}}'
24
+ const clientId ='{{site.clientId}}'
25
+ const appId = '{{site.appId}}'
26
+ const scope = [
27
+ 'https://www.googleapis.com/auth/drive.file',
28
+ 'https://www.googleapis.com/auth/drive.appdata',
29
+ ]
30
+ let pickerApiLoaded = false
31
+ let oauthToken
32
+ const loadPicker = () => {
33
+ gapi.load('auth', { callback: onAuthApiLoad })
34
+ gapi.load('picker', { callback: onPickerApiLoad })
35
+ }
36
+ const onAuthApiLoad = () => {
37
+ window.gapi.auth.authorize(
38
+ {
39
+ client_id: clientId,
40
+ scope: scope,
41
+ immediate: false,
42
+ },
43
+ handleAuthResult
44
+ )
45
+ }
46
+ let onPickerApiLoad = () => {
47
+ pickerApiLoaded = true
48
+ createPicker()
49
+ }
50
+ const handleAuthResult = (authResult) => {
51
+ if (authResult && !authResult.error) {
52
+ oauthToken = authResult.access_token
53
+ createPicker()
54
+ }
55
+ }
56
+ const createPicker = () => {
57
+ if (pickerApiLoaded && oauthToken) {
58
+ const view = new google.picker.View(google.picker.ViewId.DOCS)
59
+ view.setMimeTypes(mimeTypes)
60
+ const picker = new google.picker.PickerBuilder()
61
+ .enableFeature(google.picker.Feature.NAV_HIDDEN)
62
+ .enableFeature(google.picker.Feature.MULTISELECT_ENABLED)
63
+ .setAppId(appId)
64
+ .setOAuthToken(oauthToken)
65
+ .addView(view)
66
+ .addView(new google.picker.DocsUploadView())
67
+ .setDeveloperKey(developerKey)
68
+ .setCallback(pickerCallback)
69
+ .build()
70
+ picker.setVisible(true)
71
+ }
72
+ }
73
+ const pickerCallback = async (data) => {
74
+ if (data.action == google.picker.Action.PICKED) {
75
+ showLoader()
76
+ const res = await fetch(
77
+ `https://www.googleapis.com/drive/v3/files/${data.docs[0].id}?alt=media`,
78
+ {
79
+ headers: {
80
+ Authorization: `Bearer ${oauthToken}`,
81
+ },
82
+ }
83
+ ).then((res) => res.blob())
84
+ let metadata = {
85
+ type: data.docs[0].mimeType,
86
+ }
87
+ let file = new File([res], data.docs[0].name, metadata)
88
+ closeLoader()
89
+ getFile(file)
90
+ }
91
+ }
92
+ function chooseFromDropbox() {
93
+ Dropbox.choose({
94
+ success: async (files) => {
95
+ if (files.length < 0) {
96
+ return
97
+ }
98
+ var file = files[0]
99
+ const url = new URL(file.link)
100
+ showLoader()
101
+ const response = await fetch(url).then((res) => res.blob())
102
+ let metadata = {
103
+ type: response.type,
104
+ }
105
+ let newFile = new File([response], file.name, metadata)
106
+ closeLoader()
107
+ getDropBoxFile(newFile)
108
+ },
109
+ cancel: function () {},
110
+ linkType: 'direct',
111
+ multiselect: false,
112
+ extensions: [...filemimes],
113
+ folderselect: false,
114
+ })
115
+ }
116
+
117
+ const fileupload=(file)=>{
118
+ gapi.load('auth', {'callback': onAuthLoad});
119
+ }
120
+ const onAuthLoad=()=> {
121
+ window.gapi.auth.authorize(
122
+ {
123
+ 'client_id': clientId,
124
+ 'scope': scope,
125
+ 'immediate': false
126
+ },
127
+ handleAuth);
128
+ }
129
+ const handleAuth=(authResult)=> {
130
+ if (authResult && !authResult.error) {
131
+ showuploadloading()
132
+ var formData = new FormData();
133
+ const fileToUpload = file
134
+ var metadata = {
135
+ name: fileToUpload.name,
136
+ mimeType: fileToUpload.type
137
+ };
138
+ formData.append( "metadata", new Blob( [JSON.stringify( metadata )], {type: "application/json"} ));
139
+ formData.append( "file", fileToUpload );
140
+ fetch( "https://www.googleapis.com/upload/drive/v3/files?uploadType=multipart", {
141
+ method: "POST",
142
+ headers: new Headers({ "Authorization": "Bearer " + gapi.auth.getToken().access_token }),
143
+ body: formData
144
+ }).then( function( response ){
145
+ stopuploadloading()
146
+ return response.json();
147
+
148
+ }).then( function( value ){
149
+ stopuploadloading()
150
+ showmessage()
151
+ });
152
+ }
153
+ }
154
+
155
+
156
156
 
@@ -1,17 +1,17 @@
1
- ---
2
- ---
3
- {
4
- "short_name": "{{site.name}}",
5
- "name": "{{site.name}}",
6
- "icons": [
7
- {
8
- "src": "{{site.pwalogo}}",
9
- "type": "image/png",
10
- "sizes": "1024x1024"
11
- }
12
- ],
13
- "start_url": "/",
14
- "display": "standalone",
15
- "theme_color": "#000000",
16
- "background_color": "#ffffff"
1
+ ---
2
+ ---
3
+ {
4
+ "short_name": "{{site.name}}",
5
+ "name": "{{site.name}}",
6
+ "icons": [
7
+ {
8
+ "src": "{{site.pwalogo}}",
9
+ "type": "image/png",
10
+ "sizes": "1024x1024"
11
+ }
12
+ ],
13
+ "start_url": "/",
14
+ "display": "standalone",
15
+ "theme_color": "#000000",
16
+ "background_color": "#ffffff"
17
17
  }