Update Luxon, remove workaround
This commit is contained in:
parent
667bec2263
commit
7f61a0cb06
Binary file not shown.
10
package.json
10
package.json
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "doomsday",
|
"name": "doomsday",
|
||||||
"version": "1.4.1",
|
"version": "1.4.2",
|
||||||
"description": "Test your mastery of Conway's Doomsday rule.",
|
"description": "Test your mastery of Conway's Doomsday rule.",
|
||||||
"author": "Florine W. Dekker",
|
"author": "Florine W. Dekker",
|
||||||
"browser": "dist/bundle.js",
|
"browser": "dist/bundle.js",
|
||||||
|
@ -16,13 +16,13 @@
|
||||||
"deploy": "grunt deploy"
|
"deploy": "grunt deploy"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"luxon": "^2.3.1"
|
"luxon": "^2.3.2"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@types/luxon": "^2.3.1",
|
"@types/luxon": "^2.3.1",
|
||||||
"grunt": "^1.4.1",
|
"grunt": "^1.5.2",
|
||||||
"grunt-cli": "^1.4.3",
|
"grunt-cli": "^1.4.3",
|
||||||
"grunt-contrib-clean": "^2.0.0",
|
"grunt-contrib-clean": "^2.0.1",
|
||||||
"grunt-contrib-copy": "^1.0.0",
|
"grunt-contrib-copy": "^1.0.0",
|
||||||
"grunt-contrib-watch": "^1.1.0",
|
"grunt-contrib-watch": "^1.1.0",
|
||||||
"grunt-focus": "^1.0.0",
|
"grunt-focus": "^1.0.0",
|
||||||
|
@ -30,7 +30,7 @@
|
||||||
"grunt-webpack": "^5.0.0",
|
"grunt-webpack": "^5.0.0",
|
||||||
"ts-loader": "^9.2.8",
|
"ts-loader": "^9.2.8",
|
||||||
"typescript": "^4.6.3",
|
"typescript": "^4.6.3",
|
||||||
"webpack": "^5.70.0",
|
"webpack": "^5.72.0",
|
||||||
"webpack-cli": "^4.9.2"
|
"webpack-cli": "^4.9.2"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -285,8 +285,7 @@ class DoomsdayDate {
|
||||||
* @return the day of the week of the anchor of this `DoomsdayDate`'s century
|
* @return the day of the week of the anchor of this `DoomsdayDate`'s century
|
||||||
*/
|
*/
|
||||||
getCenturyAnchorString(): string {
|
getCenturyAnchorString(): string {
|
||||||
// TODO: Support BCE years
|
return this.date.set({year: this.getCentury() * 100, month: 4, day: 4}).setLocale("en-US").weekdayLong;
|
||||||
return this.date.set({year: (this.getCentury() + 4) * 100, month: 4, day: 4}).setLocale("en-US").weekdayLong;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -295,8 +294,7 @@ class DoomsdayDate {
|
||||||
* @return the day of the week of the anchor day of this `DoomsdayDate`'s year
|
* @return the day of the week of the anchor day of this `DoomsdayDate`'s year
|
||||||
*/
|
*/
|
||||||
getYearAnchorString(): string {
|
getYearAnchorString(): string {
|
||||||
// TODO: Support BCE years
|
return this.date.set({month: 4, day: 4}).setLocale("en-US").weekdayLong;
|
||||||
return this.date.set({year: this.date.year + 400, day: 4, month: 4}).setLocale("en-US").weekdayLong;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -305,8 +303,7 @@ class DoomsdayDate {
|
||||||
* @return the day of the week of this `DoomsdayDate`
|
* @return the day of the week of this `DoomsdayDate`
|
||||||
*/
|
*/
|
||||||
getWeekdayString(): string {
|
getWeekdayString(): string {
|
||||||
// TODO: Support BCE years
|
return this.date.setLocale("en-US").weekdayLong;
|
||||||
return this.date.set({year: this.date.year + 400}).setLocale("en-US").weekdayLong;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue