UNPKG

@nesto-software/moment-holiday-germany

Version:

The german locale for moment-holiday.

38 lines 1.86 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); const moment_holiday_core_1 = require("@nesto-software/moment-holiday-core"); const url = require("url"); const common_state_holiday_definitions_1 = require("./common-state-holiday-definitions"); const holiday_names_1 = require("./holiday-names"); class MVStateLocale extends moment_holiday_core_1.AbstractLocale { constructor() { super(...arguments); this.legislation = new moment_holiday_core_1.Legislation("Gesetz über Sonn- und Feiertage", // tslint:disable-next-line:max-line-length url.parse("http://www.landesrecht-mv.de/jportal/portal/page/bsmvprod.psml?showdoccase=1&doc.id=jlr-FTGMVrahmen&doc.part=X&doc.origin=bs&st=lr"), "§2 Abs. 1"); } getHolidayDefinitions() { return common_state_holiday_definitions_1.COMMON_STATE_HOLIDAY_DEFINITIONS(this.legislation).concat([ { name: holiday_names_1.HolidayName.REFORMATIONSTAG, date: new moment_holiday_core_1.RecurringDate(31, 9), tags: [ new moment_holiday_core_1.TypeTag(moment_holiday_core_1.TypeTagValue.PUBLIC), new moment_holiday_core_1.LegislationTag(this.legislation), ], }, { name: holiday_names_1.HolidayName.WELTFRAUENTAG, date: moment_holiday_core_1.NonRecurringDate.forPredicate(8, 2, (year) => { return year > 2022; }), tags: [ new moment_holiday_core_1.TypeTag(moment_holiday_core_1.TypeTagValue.PUBLIC), new moment_holiday_core_1.LegislationTag(this.legislation), ], }, ]); } } exports.MVStateLocale = MVStateLocale; //# sourceMappingURL=mv.state-locale.js.map