main repo

This commit is contained in:
Basilosaurusrex
2025-11-24 18:09:40 +01:00
parent b636ee5e70
commit f027651f9b
34146 changed files with 4436636 additions and 0 deletions

View File

@@ -0,0 +1,2 @@
import type { FormatDistanceFn } from "../../types.js";
export declare const formatDistance: FormatDistanceFn;

View File

@@ -0,0 +1,2 @@
import type { FormatDistanceFn } from "../../types.js";
export declare const formatDistance: FormatDistanceFn;

200
node_modules/date-fns/locale/de/_lib/formatDistance.js generated vendored Normal file
View File

@@ -0,0 +1,200 @@
"use strict";
exports.formatDistance = void 0;
const formatDistanceLocale = {
lessThanXSeconds: {
standalone: {
one: "weniger als 1 Sekunde",
other: "weniger als {{count}} Sekunden",
},
withPreposition: {
one: "weniger als 1 Sekunde",
other: "weniger als {{count}} Sekunden",
},
},
xSeconds: {
standalone: {
one: "1 Sekunde",
other: "{{count}} Sekunden",
},
withPreposition: {
one: "1 Sekunde",
other: "{{count}} Sekunden",
},
},
halfAMinute: {
standalone: "eine halbe Minute",
withPreposition: "einer halben Minute",
},
lessThanXMinutes: {
standalone: {
one: "weniger als 1 Minute",
other: "weniger als {{count}} Minuten",
},
withPreposition: {
one: "weniger als 1 Minute",
other: "weniger als {{count}} Minuten",
},
},
xMinutes: {
standalone: {
one: "1 Minute",
other: "{{count}} Minuten",
},
withPreposition: {
one: "1 Minute",
other: "{{count}} Minuten",
},
},
aboutXHours: {
standalone: {
one: "etwa 1 Stunde",
other: "etwa {{count}} Stunden",
},
withPreposition: {
one: "etwa 1 Stunde",
other: "etwa {{count}} Stunden",
},
},
xHours: {
standalone: {
one: "1 Stunde",
other: "{{count}} Stunden",
},
withPreposition: {
one: "1 Stunde",
other: "{{count}} Stunden",
},
},
xDays: {
standalone: {
one: "1 Tag",
other: "{{count}} Tage",
},
withPreposition: {
one: "1 Tag",
other: "{{count}} Tagen",
},
},
aboutXWeeks: {
standalone: {
one: "etwa 1 Woche",
other: "etwa {{count}} Wochen",
},
withPreposition: {
one: "etwa 1 Woche",
other: "etwa {{count}} Wochen",
},
},
xWeeks: {
standalone: {
one: "1 Woche",
other: "{{count}} Wochen",
},
withPreposition: {
one: "1 Woche",
other: "{{count}} Wochen",
},
},
aboutXMonths: {
standalone: {
one: "etwa 1 Monat",
other: "etwa {{count}} Monate",
},
withPreposition: {
one: "etwa 1 Monat",
other: "etwa {{count}} Monaten",
},
},
xMonths: {
standalone: {
one: "1 Monat",
other: "{{count}} Monate",
},
withPreposition: {
one: "1 Monat",
other: "{{count}} Monaten",
},
},
aboutXYears: {
standalone: {
one: "etwa 1 Jahr",
other: "etwa {{count}} Jahre",
},
withPreposition: {
one: "etwa 1 Jahr",
other: "etwa {{count}} Jahren",
},
},
xYears: {
standalone: {
one: "1 Jahr",
other: "{{count}} Jahre",
},
withPreposition: {
one: "1 Jahr",
other: "{{count}} Jahren",
},
},
overXYears: {
standalone: {
one: "mehr als 1 Jahr",
other: "mehr als {{count}} Jahre",
},
withPreposition: {
one: "mehr als 1 Jahr",
other: "mehr als {{count}} Jahren",
},
},
almostXYears: {
standalone: {
one: "fast 1 Jahr",
other: "fast {{count}} Jahre",
},
withPreposition: {
one: "fast 1 Jahr",
other: "fast {{count}} Jahren",
},
},
};
const formatDistance = (token, count, options) => {
let result;
const tokenValue = options?.addSuffix
? formatDistanceLocale[token].withPreposition
: formatDistanceLocale[token].standalone;
if (typeof tokenValue === "string") {
result = tokenValue;
} else if (count === 1) {
result = tokenValue.one;
} else {
result = tokenValue.other.replace("{{count}}", String(count));
}
if (options?.addSuffix) {
if (options.comparison && options.comparison > 0) {
return "in " + result;
} else {
return "vor " + result;
}
}
return result;
};
exports.formatDistance = formatDistance;

196
node_modules/date-fns/locale/de/_lib/formatDistance.mjs generated vendored Normal file
View File

@@ -0,0 +1,196 @@
const formatDistanceLocale = {
lessThanXSeconds: {
standalone: {
one: "weniger als 1 Sekunde",
other: "weniger als {{count}} Sekunden",
},
withPreposition: {
one: "weniger als 1 Sekunde",
other: "weniger als {{count}} Sekunden",
},
},
xSeconds: {
standalone: {
one: "1 Sekunde",
other: "{{count}} Sekunden",
},
withPreposition: {
one: "1 Sekunde",
other: "{{count}} Sekunden",
},
},
halfAMinute: {
standalone: "eine halbe Minute",
withPreposition: "einer halben Minute",
},
lessThanXMinutes: {
standalone: {
one: "weniger als 1 Minute",
other: "weniger als {{count}} Minuten",
},
withPreposition: {
one: "weniger als 1 Minute",
other: "weniger als {{count}} Minuten",
},
},
xMinutes: {
standalone: {
one: "1 Minute",
other: "{{count}} Minuten",
},
withPreposition: {
one: "1 Minute",
other: "{{count}} Minuten",
},
},
aboutXHours: {
standalone: {
one: "etwa 1 Stunde",
other: "etwa {{count}} Stunden",
},
withPreposition: {
one: "etwa 1 Stunde",
other: "etwa {{count}} Stunden",
},
},
xHours: {
standalone: {
one: "1 Stunde",
other: "{{count}} Stunden",
},
withPreposition: {
one: "1 Stunde",
other: "{{count}} Stunden",
},
},
xDays: {
standalone: {
one: "1 Tag",
other: "{{count}} Tage",
},
withPreposition: {
one: "1 Tag",
other: "{{count}} Tagen",
},
},
aboutXWeeks: {
standalone: {
one: "etwa 1 Woche",
other: "etwa {{count}} Wochen",
},
withPreposition: {
one: "etwa 1 Woche",
other: "etwa {{count}} Wochen",
},
},
xWeeks: {
standalone: {
one: "1 Woche",
other: "{{count}} Wochen",
},
withPreposition: {
one: "1 Woche",
other: "{{count}} Wochen",
},
},
aboutXMonths: {
standalone: {
one: "etwa 1 Monat",
other: "etwa {{count}} Monate",
},
withPreposition: {
one: "etwa 1 Monat",
other: "etwa {{count}} Monaten",
},
},
xMonths: {
standalone: {
one: "1 Monat",
other: "{{count}} Monate",
},
withPreposition: {
one: "1 Monat",
other: "{{count}} Monaten",
},
},
aboutXYears: {
standalone: {
one: "etwa 1 Jahr",
other: "etwa {{count}} Jahre",
},
withPreposition: {
one: "etwa 1 Jahr",
other: "etwa {{count}} Jahren",
},
},
xYears: {
standalone: {
one: "1 Jahr",
other: "{{count}} Jahre",
},
withPreposition: {
one: "1 Jahr",
other: "{{count}} Jahren",
},
},
overXYears: {
standalone: {
one: "mehr als 1 Jahr",
other: "mehr als {{count}} Jahre",
},
withPreposition: {
one: "mehr als 1 Jahr",
other: "mehr als {{count}} Jahren",
},
},
almostXYears: {
standalone: {
one: "fast 1 Jahr",
other: "fast {{count}} Jahre",
},
withPreposition: {
one: "fast 1 Jahr",
other: "fast {{count}} Jahren",
},
},
};
export const formatDistance = (token, count, options) => {
let result;
const tokenValue = options?.addSuffix
? formatDistanceLocale[token].withPreposition
: formatDistanceLocale[token].standalone;
if (typeof tokenValue === "string") {
result = tokenValue;
} else if (count === 1) {
result = tokenValue.one;
} else {
result = tokenValue.other.replace("{{count}}", String(count));
}
if (options?.addSuffix) {
if (options.comparison && options.comparison > 0) {
return "in " + result;
} else {
return "vor " + result;
}
}
return result;
};

View File

@@ -0,0 +1,2 @@
import type { FormatLong } from "../../types.js";
export declare const formatLong: FormatLong;

2
node_modules/date-fns/locale/de/_lib/formatLong.d.ts generated vendored Normal file
View File

@@ -0,0 +1,2 @@
import type { FormatLong } from "../../types.js";
export declare const formatLong: FormatLong;

42
node_modules/date-fns/locale/de/_lib/formatLong.js generated vendored Normal file
View File

@@ -0,0 +1,42 @@
"use strict";
exports.formatLong = void 0;
var _index = require("../../_lib/buildFormatLongFn.js");
// DIN 5008: https://de.wikipedia.org/wiki/Datumsformat#DIN_5008
const dateFormats = {
full: "EEEE, do MMMM y", // Montag, 7. Januar 2018
long: "do MMMM y", // 7. Januar 2018
medium: "do MMM y", // 7. Jan. 2018
short: "dd.MM.y", // 07.01.2018
};
const timeFormats = {
full: "HH:mm:ss zzzz",
long: "HH:mm:ss z",
medium: "HH:mm:ss",
short: "HH:mm",
};
const dateTimeFormats = {
full: "{{date}} 'um' {{time}}",
long: "{{date}} 'um' {{time}}",
medium: "{{date}} {{time}}",
short: "{{date}} {{time}}",
};
const formatLong = (exports.formatLong = {
date: (0, _index.buildFormatLongFn)({
formats: dateFormats,
defaultWidth: "full",
}),
time: (0, _index.buildFormatLongFn)({
formats: timeFormats,
defaultWidth: "full",
}),
dateTime: (0, _index.buildFormatLongFn)({
formats: dateTimeFormats,
defaultWidth: "full",
}),
});

40
node_modules/date-fns/locale/de/_lib/formatLong.mjs generated vendored Normal file
View File

@@ -0,0 +1,40 @@
import { buildFormatLongFn } from "../../_lib/buildFormatLongFn.mjs";
// DIN 5008: https://de.wikipedia.org/wiki/Datumsformat#DIN_5008
const dateFormats = {
full: "EEEE, do MMMM y", // Montag, 7. Januar 2018
long: "do MMMM y", // 7. Januar 2018
medium: "do MMM y", // 7. Jan. 2018
short: "dd.MM.y", // 07.01.2018
};
const timeFormats = {
full: "HH:mm:ss zzzz",
long: "HH:mm:ss z",
medium: "HH:mm:ss",
short: "HH:mm",
};
const dateTimeFormats = {
full: "{{date}} 'um' {{time}}",
long: "{{date}} 'um' {{time}}",
medium: "{{date}} {{time}}",
short: "{{date}} {{time}}",
};
export const formatLong = {
date: buildFormatLongFn({
formats: dateFormats,
defaultWidth: "full",
}),
time: buildFormatLongFn({
formats: timeFormats,
defaultWidth: "full",
}),
dateTime: buildFormatLongFn({
formats: dateTimeFormats,
defaultWidth: "full",
}),
};

View File

@@ -0,0 +1,2 @@
import type { FormatRelativeFn } from "../../types.js";
export declare const formatRelative: FormatRelativeFn;

View File

@@ -0,0 +1,2 @@
import type { FormatRelativeFn } from "../../types.js";
export declare const formatRelative: FormatRelativeFn;

15
node_modules/date-fns/locale/de/_lib/formatRelative.js generated vendored Normal file
View File

@@ -0,0 +1,15 @@
"use strict";
exports.formatRelative = void 0;
const formatRelativeLocale = {
lastWeek: "'letzten' eeee 'um' p",
yesterday: "'gestern um' p",
today: "'heute um' p",
tomorrow: "'morgen um' p",
nextWeek: "eeee 'um' p",
other: "P",
};
const formatRelative = (token, _date, _baseDate, _options) =>
formatRelativeLocale[token];
exports.formatRelative = formatRelative;

View File

@@ -0,0 +1,11 @@
const formatRelativeLocale = {
lastWeek: "'letzten' eeee 'um' p",
yesterday: "'gestern um' p",
today: "'heute um' p",
tomorrow: "'morgen um' p",
nextWeek: "eeee 'um' p",
other: "P",
};
export const formatRelative = (token, _date, _baseDate, _options) =>
formatRelativeLocale[token];

2
node_modules/date-fns/locale/de/_lib/localize.d.mts generated vendored Normal file
View File

@@ -0,0 +1,2 @@
import type { Localize } from "../../types.js";
export declare const localize: Localize;

2
node_modules/date-fns/locale/de/_lib/localize.d.ts generated vendored Normal file
View File

@@ -0,0 +1,2 @@
import type { Localize } from "../../types.js";
export declare const localize: Localize;

193
node_modules/date-fns/locale/de/_lib/localize.js generated vendored Normal file
View File

@@ -0,0 +1,193 @@
"use strict";
exports.localize = void 0;
var _index = require("../../_lib/buildLocalizeFn.js");
const eraValues = {
narrow: ["v.Chr.", "n.Chr."],
abbreviated: ["v.Chr.", "n.Chr."],
wide: ["vor Christus", "nach Christus"],
};
const quarterValues = {
narrow: ["1", "2", "3", "4"],
abbreviated: ["Q1", "Q2", "Q3", "Q4"],
wide: ["1. Quartal", "2. Quartal", "3. Quartal", "4. Quartal"],
};
// Note: in German, the names of days of the week and months are capitalized.
// If you are making a new locale based on this one, check if the same is true for the language you're working on.
// Generally, formatted dates should look like they are in the middle of a sentence,
// e.g. in Spanish language the weekdays and months should be in the lowercase.
const monthValues = {
narrow: ["J", "F", "M", "A", "M", "J", "J", "A", "S", "O", "N", "D"],
abbreviated: [
"Jan",
"Feb",
"Mär",
"Apr",
"Mai",
"Jun",
"Jul",
"Aug",
"Sep",
"Okt",
"Nov",
"Dez",
],
wide: [
"Januar",
"Februar",
"März",
"April",
"Mai",
"Juni",
"Juli",
"August",
"September",
"Oktober",
"November",
"Dezember",
],
};
// https://st.unicode.org/cldr-apps/v#/de/Gregorian/
const formattingMonthValues = {
narrow: monthValues.narrow,
abbreviated: [
"Jan.",
"Feb.",
"März",
"Apr.",
"Mai",
"Juni",
"Juli",
"Aug.",
"Sep.",
"Okt.",
"Nov.",
"Dez.",
],
wide: monthValues.wide,
};
const dayValues = {
narrow: ["S", "M", "D", "M", "D", "F", "S"],
short: ["So", "Mo", "Di", "Mi", "Do", "Fr", "Sa"],
abbreviated: ["So.", "Mo.", "Di.", "Mi.", "Do.", "Fr.", "Sa."],
wide: [
"Sonntag",
"Montag",
"Dienstag",
"Mittwoch",
"Donnerstag",
"Freitag",
"Samstag",
],
};
// https://www.unicode.org/cldr/charts/32/summary/de.html#1881
const dayPeriodValues = {
narrow: {
am: "vm.",
pm: "nm.",
midnight: "Mitternacht",
noon: "Mittag",
morning: "Morgen",
afternoon: "Nachm.",
evening: "Abend",
night: "Nacht",
},
abbreviated: {
am: "vorm.",
pm: "nachm.",
midnight: "Mitternacht",
noon: "Mittag",
morning: "Morgen",
afternoon: "Nachmittag",
evening: "Abend",
night: "Nacht",
},
wide: {
am: "vormittags",
pm: "nachmittags",
midnight: "Mitternacht",
noon: "Mittag",
morning: "Morgen",
afternoon: "Nachmittag",
evening: "Abend",
night: "Nacht",
},
};
const formattingDayPeriodValues = {
narrow: {
am: "vm.",
pm: "nm.",
midnight: "Mitternacht",
noon: "Mittag",
morning: "morgens",
afternoon: "nachm.",
evening: "abends",
night: "nachts",
},
abbreviated: {
am: "vorm.",
pm: "nachm.",
midnight: "Mitternacht",
noon: "Mittag",
morning: "morgens",
afternoon: "nachmittags",
evening: "abends",
night: "nachts",
},
wide: {
am: "vormittags",
pm: "nachmittags",
midnight: "Mitternacht",
noon: "Mittag",
morning: "morgens",
afternoon: "nachmittags",
evening: "abends",
night: "nachts",
},
};
const ordinalNumber = (dirtyNumber) => {
const number = Number(dirtyNumber);
return number + ".";
};
const localize = (exports.localize = {
ordinalNumber,
era: (0, _index.buildLocalizeFn)({
values: eraValues,
defaultWidth: "wide",
}),
quarter: (0, _index.buildLocalizeFn)({
values: quarterValues,
defaultWidth: "wide",
argumentCallback: (quarter) => quarter - 1,
}),
month: (0, _index.buildLocalizeFn)({
values: monthValues,
formattingValues: formattingMonthValues,
defaultWidth: "wide",
}),
day: (0, _index.buildLocalizeFn)({
values: dayValues,
defaultWidth: "wide",
}),
dayPeriod: (0, _index.buildLocalizeFn)({
values: dayPeriodValues,
defaultWidth: "wide",
formattingValues: formattingDayPeriodValues,
defaultFormattingWidth: "wide",
}),
});

191
node_modules/date-fns/locale/de/_lib/localize.mjs generated vendored Normal file
View File

@@ -0,0 +1,191 @@
import { buildLocalizeFn } from "../../_lib/buildLocalizeFn.mjs";
const eraValues = {
narrow: ["v.Chr.", "n.Chr."],
abbreviated: ["v.Chr.", "n.Chr."],
wide: ["vor Christus", "nach Christus"],
};
const quarterValues = {
narrow: ["1", "2", "3", "4"],
abbreviated: ["Q1", "Q2", "Q3", "Q4"],
wide: ["1. Quartal", "2. Quartal", "3. Quartal", "4. Quartal"],
};
// Note: in German, the names of days of the week and months are capitalized.
// If you are making a new locale based on this one, check if the same is true for the language you're working on.
// Generally, formatted dates should look like they are in the middle of a sentence,
// e.g. in Spanish language the weekdays and months should be in the lowercase.
const monthValues = {
narrow: ["J", "F", "M", "A", "M", "J", "J", "A", "S", "O", "N", "D"],
abbreviated: [
"Jan",
"Feb",
"Mär",
"Apr",
"Mai",
"Jun",
"Jul",
"Aug",
"Sep",
"Okt",
"Nov",
"Dez",
],
wide: [
"Januar",
"Februar",
"März",
"April",
"Mai",
"Juni",
"Juli",
"August",
"September",
"Oktober",
"November",
"Dezember",
],
};
// https://st.unicode.org/cldr-apps/v#/de/Gregorian/
const formattingMonthValues = {
narrow: monthValues.narrow,
abbreviated: [
"Jan.",
"Feb.",
"März",
"Apr.",
"Mai",
"Juni",
"Juli",
"Aug.",
"Sep.",
"Okt.",
"Nov.",
"Dez.",
],
wide: monthValues.wide,
};
const dayValues = {
narrow: ["S", "M", "D", "M", "D", "F", "S"],
short: ["So", "Mo", "Di", "Mi", "Do", "Fr", "Sa"],
abbreviated: ["So.", "Mo.", "Di.", "Mi.", "Do.", "Fr.", "Sa."],
wide: [
"Sonntag",
"Montag",
"Dienstag",
"Mittwoch",
"Donnerstag",
"Freitag",
"Samstag",
],
};
// https://www.unicode.org/cldr/charts/32/summary/de.html#1881
const dayPeriodValues = {
narrow: {
am: "vm.",
pm: "nm.",
midnight: "Mitternacht",
noon: "Mittag",
morning: "Morgen",
afternoon: "Nachm.",
evening: "Abend",
night: "Nacht",
},
abbreviated: {
am: "vorm.",
pm: "nachm.",
midnight: "Mitternacht",
noon: "Mittag",
morning: "Morgen",
afternoon: "Nachmittag",
evening: "Abend",
night: "Nacht",
},
wide: {
am: "vormittags",
pm: "nachmittags",
midnight: "Mitternacht",
noon: "Mittag",
morning: "Morgen",
afternoon: "Nachmittag",
evening: "Abend",
night: "Nacht",
},
};
const formattingDayPeriodValues = {
narrow: {
am: "vm.",
pm: "nm.",
midnight: "Mitternacht",
noon: "Mittag",
morning: "morgens",
afternoon: "nachm.",
evening: "abends",
night: "nachts",
},
abbreviated: {
am: "vorm.",
pm: "nachm.",
midnight: "Mitternacht",
noon: "Mittag",
morning: "morgens",
afternoon: "nachmittags",
evening: "abends",
night: "nachts",
},
wide: {
am: "vormittags",
pm: "nachmittags",
midnight: "Mitternacht",
noon: "Mittag",
morning: "morgens",
afternoon: "nachmittags",
evening: "abends",
night: "nachts",
},
};
const ordinalNumber = (dirtyNumber) => {
const number = Number(dirtyNumber);
return number + ".";
};
export const localize = {
ordinalNumber,
era: buildLocalizeFn({
values: eraValues,
defaultWidth: "wide",
}),
quarter: buildLocalizeFn({
values: quarterValues,
defaultWidth: "wide",
argumentCallback: (quarter) => quarter - 1,
}),
month: buildLocalizeFn({
values: monthValues,
formattingValues: formattingMonthValues,
defaultWidth: "wide",
}),
day: buildLocalizeFn({
values: dayValues,
defaultWidth: "wide",
}),
dayPeriod: buildLocalizeFn({
values: dayPeriodValues,
defaultWidth: "wide",
formattingValues: formattingDayPeriodValues,
defaultFormattingWidth: "wide",
}),
};

2
node_modules/date-fns/locale/de/_lib/match.d.mts generated vendored Normal file
View File

@@ -0,0 +1,2 @@
import type { Match } from "../../types.js";
export declare const match: Match;

2
node_modules/date-fns/locale/de/_lib/match.d.ts generated vendored Normal file
View File

@@ -0,0 +1,2 @@
import type { Match } from "../../types.js";
export declare const match: Match;

137
node_modules/date-fns/locale/de/_lib/match.js generated vendored Normal file
View File

@@ -0,0 +1,137 @@
"use strict";
exports.match = void 0;
var _index = require("../../_lib/buildMatchFn.js");
var _index2 = require("../../_lib/buildMatchPatternFn.js");
const matchOrdinalNumberPattern = /^(\d+)(\.)?/i;
const parseOrdinalNumberPattern = /\d+/i;
const matchEraPatterns = {
narrow: /^(v\.? ?Chr\.?|n\.? ?Chr\.?)/i,
abbreviated: /^(v\.? ?Chr\.?|n\.? ?Chr\.?)/i,
wide: /^(vor Christus|vor unserer Zeitrechnung|nach Christus|unserer Zeitrechnung)/i,
};
const parseEraPatterns = {
any: [/^v/i, /^n/i],
};
const matchQuarterPatterns = {
narrow: /^[1234]/i,
abbreviated: /^q[1234]/i,
wide: /^[1234](\.)? Quartal/i,
};
const parseQuarterPatterns = {
any: [/1/i, /2/i, /3/i, /4/i],
};
const matchMonthPatterns = {
narrow: /^[jfmasond]/i,
abbreviated:
/^(j[aä]n|feb|mär[z]?|apr|mai|jun[i]?|jul[i]?|aug|sep|okt|nov|dez)\.?/i,
wide: /^(januar|februar|märz|april|mai|juni|juli|august|september|oktober|november|dezember)/i,
};
const parseMonthPatterns = {
narrow: [
/^j/i,
/^f/i,
/^m/i,
/^a/i,
/^m/i,
/^j/i,
/^j/i,
/^a/i,
/^s/i,
/^o/i,
/^n/i,
/^d/i,
],
any: [
/^j[aä]/i,
/^f/i,
/^mär/i,
/^ap/i,
/^mai/i,
/^jun/i,
/^jul/i,
/^au/i,
/^s/i,
/^o/i,
/^n/i,
/^d/i,
],
};
const matchDayPatterns = {
narrow: /^[smdmf]/i,
short: /^(so|mo|di|mi|do|fr|sa)/i,
abbreviated: /^(son?|mon?|die?|mit?|don?|fre?|sam?)\.?/i,
wide: /^(sonntag|montag|dienstag|mittwoch|donnerstag|freitag|samstag)/i,
};
const parseDayPatterns = {
any: [/^so/i, /^mo/i, /^di/i, /^mi/i, /^do/i, /^f/i, /^sa/i],
};
const matchDayPeriodPatterns = {
narrow: /^(vm\.?|nm\.?|Mitternacht|Mittag|morgens|nachm\.?|abends|nachts)/i,
abbreviated:
/^(vorm\.?|nachm\.?|Mitternacht|Mittag|morgens|nachm\.?|abends|nachts)/i,
wide: /^(vormittags|nachmittags|Mitternacht|Mittag|morgens|nachmittags|abends|nachts)/i,
};
const parseDayPeriodPatterns = {
any: {
am: /^v/i,
pm: /^n/i,
midnight: /^Mitte/i,
noon: /^Mitta/i,
morning: /morgens/i,
afternoon: /nachmittags/i, // will never be matched. Afternoon is matched by `pm`
evening: /abends/i,
night: /nachts/i, // will never be matched. Night is matched by `pm`
},
};
const match = (exports.match = {
ordinalNumber: (0, _index2.buildMatchPatternFn)({
matchPattern: matchOrdinalNumberPattern,
parsePattern: parseOrdinalNumberPattern,
valueCallback: (value) => parseInt(value),
}),
era: (0, _index.buildMatchFn)({
matchPatterns: matchEraPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseEraPatterns,
defaultParseWidth: "any",
}),
quarter: (0, _index.buildMatchFn)({
matchPatterns: matchQuarterPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseQuarterPatterns,
defaultParseWidth: "any",
valueCallback: (index) => index + 1,
}),
month: (0, _index.buildMatchFn)({
matchPatterns: matchMonthPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseMonthPatterns,
defaultParseWidth: "any",
}),
day: (0, _index.buildMatchFn)({
matchPatterns: matchDayPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseDayPatterns,
defaultParseWidth: "any",
}),
dayPeriod: (0, _index.buildMatchFn)({
matchPatterns: matchDayPeriodPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseDayPeriodPatterns,
defaultParseWidth: "any",
}),
});

134
node_modules/date-fns/locale/de/_lib/match.mjs generated vendored Normal file
View File

@@ -0,0 +1,134 @@
import { buildMatchFn } from "../../_lib/buildMatchFn.mjs";
import { buildMatchPatternFn } from "../../_lib/buildMatchPatternFn.mjs";
const matchOrdinalNumberPattern = /^(\d+)(\.)?/i;
const parseOrdinalNumberPattern = /\d+/i;
const matchEraPatterns = {
narrow: /^(v\.? ?Chr\.?|n\.? ?Chr\.?)/i,
abbreviated: /^(v\.? ?Chr\.?|n\.? ?Chr\.?)/i,
wide: /^(vor Christus|vor unserer Zeitrechnung|nach Christus|unserer Zeitrechnung)/i,
};
const parseEraPatterns = {
any: [/^v/i, /^n/i],
};
const matchQuarterPatterns = {
narrow: /^[1234]/i,
abbreviated: /^q[1234]/i,
wide: /^[1234](\.)? Quartal/i,
};
const parseQuarterPatterns = {
any: [/1/i, /2/i, /3/i, /4/i],
};
const matchMonthPatterns = {
narrow: /^[jfmasond]/i,
abbreviated:
/^(j[aä]n|feb|mär[z]?|apr|mai|jun[i]?|jul[i]?|aug|sep|okt|nov|dez)\.?/i,
wide: /^(januar|februar|märz|april|mai|juni|juli|august|september|oktober|november|dezember)/i,
};
const parseMonthPatterns = {
narrow: [
/^j/i,
/^f/i,
/^m/i,
/^a/i,
/^m/i,
/^j/i,
/^j/i,
/^a/i,
/^s/i,
/^o/i,
/^n/i,
/^d/i,
],
any: [
/^j[aä]/i,
/^f/i,
/^mär/i,
/^ap/i,
/^mai/i,
/^jun/i,
/^jul/i,
/^au/i,
/^s/i,
/^o/i,
/^n/i,
/^d/i,
],
};
const matchDayPatterns = {
narrow: /^[smdmf]/i,
short: /^(so|mo|di|mi|do|fr|sa)/i,
abbreviated: /^(son?|mon?|die?|mit?|don?|fre?|sam?)\.?/i,
wide: /^(sonntag|montag|dienstag|mittwoch|donnerstag|freitag|samstag)/i,
};
const parseDayPatterns = {
any: [/^so/i, /^mo/i, /^di/i, /^mi/i, /^do/i, /^f/i, /^sa/i],
};
const matchDayPeriodPatterns = {
narrow: /^(vm\.?|nm\.?|Mitternacht|Mittag|morgens|nachm\.?|abends|nachts)/i,
abbreviated:
/^(vorm\.?|nachm\.?|Mitternacht|Mittag|morgens|nachm\.?|abends|nachts)/i,
wide: /^(vormittags|nachmittags|Mitternacht|Mittag|morgens|nachmittags|abends|nachts)/i,
};
const parseDayPeriodPatterns = {
any: {
am: /^v/i,
pm: /^n/i,
midnight: /^Mitte/i,
noon: /^Mitta/i,
morning: /morgens/i,
afternoon: /nachmittags/i, // will never be matched. Afternoon is matched by `pm`
evening: /abends/i,
night: /nachts/i, // will never be matched. Night is matched by `pm`
},
};
export const match = {
ordinalNumber: buildMatchPatternFn({
matchPattern: matchOrdinalNumberPattern,
parsePattern: parseOrdinalNumberPattern,
valueCallback: (value) => parseInt(value),
}),
era: buildMatchFn({
matchPatterns: matchEraPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseEraPatterns,
defaultParseWidth: "any",
}),
quarter: buildMatchFn({
matchPatterns: matchQuarterPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseQuarterPatterns,
defaultParseWidth: "any",
valueCallback: (index) => index + 1,
}),
month: buildMatchFn({
matchPatterns: matchMonthPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseMonthPatterns,
defaultParseWidth: "any",
}),
day: buildMatchFn({
matchPatterns: matchDayPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseDayPatterns,
defaultParseWidth: "any",
}),
dayPeriod: buildMatchFn({
matchPatterns: matchDayPeriodPatterns,
defaultMatchWidth: "wide",
parsePatterns: parseDayPeriodPatterns,
defaultParseWidth: "any",
}),
};