index.js 3.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133
  1. "use strict";
  2. Object.defineProperty(exports, "__esModule", {
  3. value: true
  4. });
  5. exports.default = void 0;
  6. var _index = _interopRequireDefault(require("../../../_lib/buildLocalizeFn/index.js"));
  7. function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
  8. var eraValues = {
  9. narrow: ['v.Chr.', 'n.Chr.'],
  10. abbreviated: ['v.Chr.', 'n.Chr.'],
  11. wide: ['viru Christus', 'no Christus']
  12. };
  13. var quarterValues = {
  14. narrow: ['1', '2', '3', '4'],
  15. abbreviated: ['Q1', 'Q2', 'Q3', 'Q4'],
  16. wide: ['1. Quartal', '2. Quartal', '3. Quartal', '4. Quartal']
  17. };
  18. var monthValues = {
  19. narrow: ['J', 'F', 'M', 'A', 'M', 'J', 'J', 'A', 'S', 'O', 'N', 'D'],
  20. abbreviated: ['Jan', 'Feb', 'Mäe', 'Abr', 'Mee', 'Jun', 'Jul', 'Aug', 'Sep', 'Okt', 'Nov', 'Dez'],
  21. wide: ['Januar', 'Februar', 'Mäerz', 'Abrëll', 'Mee', 'Juni', 'Juli', 'August', 'September', 'Oktober', 'November', 'Dezember']
  22. };
  23. var dayValues = {
  24. narrow: ['S', 'M', 'D', 'M', 'D', 'F', 'S'],
  25. short: ['So', 'Mé', 'Dë', 'Më', 'Do', 'Fr', 'Sa'],
  26. abbreviated: ['So.', 'Mé.', 'Dë.', 'Më.', 'Do.', 'Fr.', 'Sa.'],
  27. wide: ['Sonndeg', 'Méindeg', 'Dënschdeg', 'Mëttwoch', 'Donneschdeg', 'Freideg', 'Samschdeg']
  28. };
  29. var dayPeriodValues = {
  30. narrow: {
  31. am: 'mo.',
  32. pm: 'nomë.',
  33. midnight: 'Mëtternuecht',
  34. noon: 'Mëtteg',
  35. morning: 'Moien',
  36. afternoon: 'Nomëtteg',
  37. evening: 'Owend',
  38. night: 'Nuecht'
  39. },
  40. abbreviated: {
  41. am: 'moies',
  42. pm: 'nomëttes',
  43. midnight: 'Mëtternuecht',
  44. noon: 'Mëtteg',
  45. morning: 'Moien',
  46. afternoon: 'Nomëtteg',
  47. evening: 'Owend',
  48. night: 'Nuecht'
  49. },
  50. wide: {
  51. am: 'moies',
  52. pm: 'nomëttes',
  53. midnight: 'Mëtternuecht',
  54. noon: 'Mëtteg',
  55. morning: 'Moien',
  56. afternoon: 'Nomëtteg',
  57. evening: 'Owend',
  58. night: 'Nuecht'
  59. }
  60. };
  61. var formattingDayPeriodValues = {
  62. narrow: {
  63. am: 'mo.',
  64. pm: 'nom.',
  65. midnight: 'Mëtternuecht',
  66. noon: 'mëttes',
  67. morning: 'moies',
  68. afternoon: 'nomëttes',
  69. evening: 'owes',
  70. night: 'nuets'
  71. },
  72. abbreviated: {
  73. am: 'moies',
  74. pm: 'nomëttes',
  75. midnight: 'Mëtternuecht',
  76. noon: 'mëttes',
  77. morning: 'moies',
  78. afternoon: 'nomëttes',
  79. evening: 'owes',
  80. night: 'nuets'
  81. },
  82. wide: {
  83. am: 'moies',
  84. pm: 'nomëttes',
  85. midnight: 'Mëtternuecht',
  86. noon: 'mëttes',
  87. morning: 'moies',
  88. afternoon: 'nomëttes',
  89. evening: 'owes',
  90. night: 'nuets'
  91. }
  92. };
  93. function ordinalNumber(dirtyNumber, _dirtyOptions) {
  94. var number = Number(dirtyNumber);
  95. return number + '.';
  96. }
  97. var localize = {
  98. ordinalNumber: ordinalNumber,
  99. era: (0, _index.default)({
  100. values: eraValues,
  101. defaultWidth: 'wide'
  102. }),
  103. quarter: (0, _index.default)({
  104. values: quarterValues,
  105. defaultWidth: 'wide',
  106. argumentCallback: function (quarter) {
  107. return Number(quarter) - 1;
  108. }
  109. }),
  110. month: (0, _index.default)({
  111. values: monthValues,
  112. defaultWidth: 'wide'
  113. }),
  114. day: (0, _index.default)({
  115. values: dayValues,
  116. defaultWidth: 'wide'
  117. }),
  118. dayPeriod: (0, _index.default)({
  119. values: dayPeriodValues,
  120. defaultWidth: 'wide',
  121. formattingValues: formattingDayPeriodValues,
  122. defaultFormattingWidth: 'wide'
  123. })
  124. };
  125. var _default = localize;
  126. exports.default = _default;
  127. module.exports = exports.default;