Skip to content

Commit

Permalink
add 2023 to retired
Browse files Browse the repository at this point in the history
  • Loading branch information
DarkIntaqt committed Jan 10, 2024
1 parent 548f6a2 commit 9a6f1db
Show file tree
Hide file tree
Showing 11 changed files with 27 additions and 17 deletions.
1 change: 1 addition & 0 deletions src/config.js
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@ const config = {
"2022000": "https://cdn.darkintaqt.com/lol/static/challenges/2022seasonal.svg",
"seasonal-retired": "https://cdn.darkintaqt.com/lol/static/challenges/retired.svg",
"2023000": "https://cdn.darkintaqt.com/lol/static/challenges/2023seasonal.svg",
"2024100": "https://cdn.darkintaqt.com/lol/static/challenges/2024-1seasonal.svg",
"summonersrift": "https://lolcdn.darkintaqt.com/cdn/sr.svg",
"aram": "https://lolcdn.darkintaqt.com/cdn/ha.svg",
"bot": "https://lolcdn.darkintaqt.com/cdn/bot.png",
Expand Down
2 changes: 1 addition & 1 deletion src/css/user.module.css
Original file line number Diff line number Diff line change
Expand Up @@ -277,7 +277,7 @@ img.mclogo {
position: relative;
}

.profile.c:not(.cid0):not(.cid1):not(.cid2):not(.cid3):not(.cid4):not(.cid5):not(.cid2022000):not(.cid2023000)::before {
.profile.c:not(.cid0):not(.cid1):not(.cid2):not(.cid3):not(.cid4):not(.cid5):not(.cid2022000):not(.cid2023000):not(.cid2024100)::before {
height: 80px;
width: 80px;
margin: 30px;
Expand Down
2 changes: 1 addition & 1 deletion src/func/generateChallengeBlock.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ export default function generateObject(content, genLine = true, challengeId = -1
}

let imageurl = "https://lolcdn.darkintaqt.com/cdn/np-token" + content.id
if (content.id < 10 || content.id === 2022000 || content.id === 2023000) {
if (content.id < 10 || content.id === 2022000 || content.id === 2023000 || content.id === 2024100) {
if (content.id !== 0) {
imageurl = "https://cdn.darkintaqt.com/lol/static/challenges/" + content.translation.name.toLowerCase().replace(" ", "") + ".svg"
}
Expand Down
2 changes: 1 addition & 1 deletion src/func/showChallengePath.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export default function showChallengePath(challenges, challenge) {


// set category to parent if they are the same or parent is a key-capstone
if (category.id === 0 && parent.id !== 0 && (parent.id < 10 || parent.id === 2022000 || parent.id === 2023000)) {
if (category.id === 0 && parent.id !== 0 && (parent.id < 10 || parent.id === 2022000 || parent.id === 2023000 || parent.id === 2024100)) {
category = parent
}

Expand Down
2 changes: 1 addition & 1 deletion src/module/Challenge.js
Original file line number Diff line number Diff line change
Expand Up @@ -403,7 +403,7 @@ class Challenge extends Component {

let icon = "https://lolcdn.darkintaqt.com/cdn/np-token/" + challenge["icon_2"]

if (challenge.challenge.id < 10 || challenge.challenge.id === 2022000 || challenge.challenge.id === 2023000) {
if (challenge.challenge.id < 10 || challenge.challenge.id === 2022000 || challenge.challenge.id === 2023000 || challenge.challenge.id === 2024100) {
if (challenge.challenge.id !== 0) {
icon = "https://cdn.darkintaqt.com/lol/static/challenges/" + challenge.challenge.translation.name.toLowerCase().replace(" ", "") + ".svg"
}
Expand Down
9 changes: 6 additions & 3 deletions src/module/Challenges.js
Original file line number Diff line number Diff line change
Expand Up @@ -274,6 +274,9 @@ class Challenges extends Component {
if (parentId !== 2022000) {
continue;
}
if (parentId !== 2023000) {
continue;
}
} else {
continue;
}
Expand Down Expand Up @@ -438,9 +441,9 @@ class Challenges extends Component {
<img src={config.images["600006"]} alt="legacy" />
Legacy
</button>
<button onClick={this.changeFilter} data-id="2023000">
<img src={config.images['2023000']} alt="2023 seasonal" />
2023 Seasonal
<button onClick={this.changeFilter} data-id="2024100">
<img src={config.images['2024100']} alt="2024 seasonal split1" />
2024 Seasonal
</button>
<button onClick={this.changeFilter} data-id="seasonal-retired">
<img src={config.images['seasonal-retired']} alt="seasonal outdated" />
Expand Down
2 changes: 1 addition & 1 deletion src/module/Header-n-Footer.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ export default function HeaderNFooter() {
'Challenges.DarkIntaqt.Com' isn't endorsed by Riot Games and doesn't reflect the views or opinions of Riot Games or anyone officially involved in producing or managing Riot Games properties. Riot Games, and all associated properties are trademarks or registered trademarks of Riot Games, Inc.
<br />
<br />
&copy; 2022 - 2023 challenges.darkintaqt.com
&copy; 2022 - 2024 challenges.darkintaqt.com
</p>
<p dangerouslySetInnerHTML={
{
Expand Down
8 changes: 4 additions & 4 deletions src/module/events/Event.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ export default class generateChallengePointElement extends Component {

componentDidMount() {

get("https://challenges.darkintaqt.com/api/v5/c/?id=2023000", this.updateCompontent)
get("https://challenges.darkintaqt.com/api/v5/c/?id=2024100", this.updateCompontent)

}

Expand Down Expand Up @@ -72,12 +72,12 @@ export default class generateChallengePointElement extends Component {
}

this.setState({
content: <a href="/challenge/2023000" className={css.crystal + " CHALLENGER " + cCss.crystal} onClick={goTo} key="banner">
content: <a href="/challenge/2024100" className={css.crystal + " CHALLENGER " + cCss.crystal} onClick={goTo} key="banner">
<div className={css.group}>
<p className={css.crystalHead}>Check out the 2023 Seasonal Leaderboard</p>
<p className={css.crystalHead}>Check out the 2024 Seasonal Leaderboard</p>

<div className={css.text}>
Check the final Leaderboards for the 2023 seasonal challenges <br /><br />Just click <b>here</b> to get to the leaderboards.
Check the final Leaderboards for the 2024 seasonal challenges <br /><br />Just click <b>here</b> to get to the leaderboards.
</div>

</div>
Expand Down
6 changes: 3 additions & 3 deletions src/module/user/UserChallenges.js
Original file line number Diff line number Diff line change
Expand Up @@ -408,9 +408,9 @@ class UserChallenges extends Component {
Legacy
</button>

<button onClick={this.changeExtraFilter} id="2023000" type="category">
<img src={config.images['2023000']} alt="2023 seasonal" />
2023 Seasonal
<button onClick={this.changeExtraFilter} id="2024100" type="category">
<img src={config.images['2024100']} alt="2024 seasonal split 1" />
2024 Seasonal
</button>

<button onClick={this.changeExtraFilter} id="retired-seasonal" type="category">
Expand Down
8 changes: 7 additions & 1 deletion src/module/user/orderChallenges.js
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,9 @@ export function removeUnnecessaryChallenges(challengesArray, filters, masterOnly
if (parentId !== 2022000) {
return null
}
if (parentId !== 2023000) {
return null
}
} else {
return null
}
Expand All @@ -126,6 +129,9 @@ export function removeUnnecessaryChallenges(challengesArray, filters, masterOnly
if (parentId === 2022000) {
return null
}
if (parentId !== 2023000) {
return null
}
}

challenge.push(parentId)
Expand All @@ -134,7 +140,7 @@ export function removeUnnecessaryChallenges(challengesArray, filters, masterOnly
if (challenge[1] >= 7) {
return null;
}
if (challenge[8] === 600006 || challenge[8].parent === 2022000 || challenge[8] === 2023000) {
if (challenge[8] === 600006 || challenge[8].parent === 2022000 || challenge[8] === 2023000 || challenge[8] === 2024100) {
return null;
}

Expand Down
2 changes: 1 addition & 1 deletion src/module/user/statsCalculateTotalPoints.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ export default function statsCalculateTotalPoints(challenges) {
for (let i = 0; i < challenges.length; i++) {
const challenge = challenges[i];

if (challenge[0] > 10 && challenge[8] !== 600006 && challenge[8] !== 2022000 && challenge[8] !== 2023000 && challenge[8] !== 601000) {
if (challenge[0] > 10 && challenge[8] !== 600006 && challenge[8] !== 2022000 && challenge[8] !== 2023000 && challenge[8] !== 601000 && challenge[8] !== 2024000) {
//console.log(challenge[8]);
tiers[intToTier(challenge[1])] += 1

Expand Down

0 comments on commit 9a6f1db

Please sign in to comment.