updates and rss accept headers

This commit is contained in:
ASCIIcat 2020-08-18 22:47:43 +02:00
parent 622f0b77dd
commit 734ef198d7
5 changed files with 1257 additions and 330 deletions

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1 @@
<svg aria-hidden="true" focusable="false" data-prefix="fas" data-icon="paint-brush" class="svg-inline--fa fa-paint-brush fa-w-16" role="img" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512"><path fill="currentColor" d="M167.02 309.34c-40.12 2.58-76.53 17.86-97.19 72.3-2.35 6.21-8 9.98-14.59 9.98-11.11 0-45.46-27.67-55.25-34.35C0 439.62 37.93 512 128 512c75.86 0 128-43.77 128-120.19 0-3.11-.65-6.08-.97-9.13l-88.01-73.34zM457.89 0c-15.16 0-29.37 6.71-40.21 16.45C213.27 199.05 192 203.34 192 257.09c0 13.7 3.25 26.76 8.73 38.7l63.82 53.18c7.21 1.8 14.64 3.03 22.39 3.03 62.11 0 98.11-45.47 211.16-256.46 7.38-14.35 13.9-29.85 13.9-45.99C512 20.64 486 0 457.89 0z"></path></svg>

After

Width:  |  Height:  |  Size: 687 B

View File

@ -1088,16 +1088,19 @@ function loadNews(){
const distroData = DistroManager.getDistribution()
const newsFeed = distroData.getRSS()
const newsHost = new URL(newsFeed).origin + '/'
$.ajax({
url: newsFeed,
$.ajax(newsFeed,{
accepts: {
xml: "application/rss+xml"
},
dataType: "xml",
timeout: 2500,
// url: newsFeed,
success: (data) => {
const items = $(data).find('item')
const articles = []
for(let i=0; i<items.length; i++){
// JQuery Element
const el = $(items[i])
// Resolve date.
const date = new Date(el.find('pubDate').text()).toLocaleDateString('en-US', {month: 'short', day: 'numeric', year: 'numeric', hour: 'numeric', minute: 'numeric'})
@ -1133,9 +1136,9 @@ function loadNews(){
resolve({
articles
})
},
timeout: 2500
}
}).catch(err => {
console.log(err);
resolve({
articles: null
})

View File

@ -38,6 +38,14 @@
</g>
</svg>
</a>
</div><div class="mediaContainer">
<a href="https://skins.avalonconcordia.com/" class="mediaURL" id="skinskURL">
<svg id="paint-brush-solid" class="mediaSVG" viewBox="0 0 512 512">
<g>
<path d="M167.02 309.34c-40.12 2.58-76.53 17.86-97.19 72.3-2.35 6.21-8 9.98-14.59 9.98-11.11 0-45.46-27.67-55.25-34.35C0 439.62 37.93 512 128 512c75.86 0 128-43.77 128-120.19 0-3.11-.65-6.08-.97-9.13l-88.01-73.34zM457.89 0c-15.16 0-29.37 6.71-40.21 16.45C213.27 199.05 192 203.34 192 257.09c0 13.7 3.25 26.76 8.73 38.7l63.82 53.18c7.21 1.8 14.64 3.03 22.39 3.03 62.11 0 98.11-45.47 211.16-256.46 7.38-14.35 13.9-29.85 13.9-45.99C512 20.64 486 0 457.89 0z"/>
</g>
</svg>
</a>
</div>
<!-- <div class="mediaContainer">
<a href="#" class="mediaURL" id="twitterURL" disabled>

View File

@ -1,6 +1,6 @@
{
"name": "avalonconcordialauncher",
"version": "1.0.0",
"version": "1.0.1",
"productName": "Avalon Concordia Launcher",
"description": "Modded Minecraft Launcher",
"author": "Jay aka ASCIIcat (https://github.com/ASCIIcat/)",