timepiece/node_modules/date-fns/locale/tr/_lib/localize.mjs

165 lines
3.0 KiB
JavaScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

import { buildLocalizeFn } from "../../_lib/buildLocalizeFn.mjs";
const eraValues = {
narrow: ["MÖ", "MS"],
abbreviated: ["MÖ", "MS"],
wide: ["Milattan Önce", "Milattan Sonra"],
};
const quarterValues = {
narrow: ["1", "2", "3", "4"],
abbreviated: ["1Ç", "2Ç", "3Ç", "4Ç"],
wide: ["İlk çeyrek", "İkinci Çeyrek", "Üçüncü çeyrek", "Son çeyrek"],
};
const monthValues = {
narrow: ["O", "Ş", "M", "N", "M", "H", "T", "A", "E", "E", "K", "A"],
abbreviated: [
"Oca",
"Şub",
"Mar",
"Nis",
"May",
"Haz",
"Tem",
"Ağu",
"Eyl",
"Eki",
"Kas",
"Ara",
],
wide: [
"Ocak",
"Şubat",
"Mart",
"Nisan",
"Mayıs",
"Haziran",
"Temmuz",
"Ağustos",
"Eylül",
"Ekim",
"Kasım",
"Aralık",
],
};
const dayValues = {
narrow: ["P", "P", "S", "Ç", "P", "C", "C"],
short: ["Pz", "Pt", "Sa", "Ça", "Pe", "Cu", "Ct"],
abbreviated: ["Paz", "Pzt", "Sal", "Çar", "Per", "Cum", "Cts"],
wide: [
"Pazar",
"Pazartesi",
"Salı",
"Çarşamba",
"Perşembe",
"Cuma",
"Cumartesi",
],
};
const dayPeriodValues = {
narrow: {
am: "öö",
pm: "ös",
midnight: "gy",
noon: "ö",
morning: "sa",
afternoon: "ös",
evening: "ak",
night: "ge",
},
abbreviated: {
am: "ÖÖ",
pm: "ÖS",
midnight: "gece yarısı",
noon: "öğle",
morning: "sabah",
afternoon: "öğleden sonra",
evening: "akşam",
night: "gece",
},
wide: {
am: "Ö.Ö.",
pm: "Ö.S.",
midnight: "gece yarısı",
noon: "öğle",
morning: "sabah",
afternoon: "öğleden sonra",
evening: "akşam",
night: "gece",
},
};
const formattingDayPeriodValues = {
narrow: {
am: "öö",
pm: "ös",
midnight: "gy",
noon: "ö",
morning: "sa",
afternoon: "ös",
evening: "ak",
night: "ge",
},
abbreviated: {
am: "ÖÖ",
pm: "ÖS",
midnight: "gece yarısı",
noon: "öğlen",
morning: "sabahleyin",
afternoon: "öğleden sonra",
evening: "akşamleyin",
night: "geceleyin",
},
wide: {
am: "ö.ö.",
pm: "ö.s.",
midnight: "gece yarısı",
noon: "öğlen",
morning: "sabahleyin",
afternoon: "öğleden sonra",
evening: "akşamleyin",
night: "geceleyin",
},
};
const ordinalNumber = (dirtyNumber, _options) => {
const number = Number(dirtyNumber);
return number + ".";
};
export const localize = {
ordinalNumber,
era: buildLocalizeFn({
values: eraValues,
defaultWidth: "wide",
}),
quarter: buildLocalizeFn({
values: quarterValues,
defaultWidth: "wide",
argumentCallback: (quarter) => Number(quarter) - 1,
}),
month: buildLocalizeFn({
values: monthValues,
defaultWidth: "wide",
}),
day: buildLocalizeFn({
values: dayValues,
defaultWidth: "wide",
}),
dayPeriod: buildLocalizeFn({
values: dayPeriodValues,
defaultWidth: "wide",
formattingValues: formattingDayPeriodValues,
defaultFormattingWidth: "wide",
}),
};