cdn.js 22 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806
  1. (() => {
  2. var _window$dateFns;function _typeof(o) {"@babel/helpers - typeof";return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) {return typeof o;} : function (o) {return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o;}, _typeof(o);}function ownKeys(e, r) {var t = Object.keys(e);if (Object.getOwnPropertySymbols) {var o = Object.getOwnPropertySymbols(e);r && (o = o.filter(function (r) {return Object.getOwnPropertyDescriptor(e, r).enumerable;})), t.push.apply(t, o);}return t;}function _objectSpread(e) {for (var r = 1; r < arguments.length; r++) {var t = null != arguments[r] ? arguments[r] : {};r % 2 ? ownKeys(Object(t), !0).forEach(function (r) {_defineProperty(e, r, t[r]);}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) {Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r));});}return e;}function _defineProperty(obj, key, value) {key = _toPropertyKey(key);if (key in obj) {Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true });} else {obj[key] = value;}return obj;}function _toPropertyKey(t) {var i = _toPrimitive(t, "string");return "symbol" == _typeof(i) ? i : String(i);}function _toPrimitive(t, r) {if ("object" != _typeof(t) || !t) return t;var e = t[Symbol.toPrimitive];if (void 0 !== e) {var i = e.call(t, r || "default");if ("object" != _typeof(i)) return i;throw new TypeError("@@toPrimitive must return a primitive value.");}return ("string" === r ? String : Number)(t);}var __defProp = Object.defineProperty;
  3. var __export = function __export(target, all) {
  4. for (var name in all)
  5. __defProp(target, name, {
  6. get: all[name],
  7. enumerable: true,
  8. configurable: true,
  9. set: function set(newValue) {return all[name] = function () {return newValue;};}
  10. });
  11. };
  12. // lib/locale/sl/_lib/formatDistance.js
  13. function isPluralType(val) {
  14. return val.one !== undefined;
  15. }
  16. function getFormFromCount(count) {
  17. switch (count % 100) {
  18. case 1:
  19. return "one";
  20. case 2:
  21. return "two";
  22. case 3:
  23. case 4:
  24. return "few";
  25. default:
  26. return "other";
  27. }
  28. }
  29. var formatDistanceLocale = {
  30. lessThanXSeconds: {
  31. present: {
  32. one: "manj kot {{count}} sekunda",
  33. two: "manj kot {{count}} sekundi",
  34. few: "manj kot {{count}} sekunde",
  35. other: "manj kot {{count}} sekund"
  36. },
  37. past: {
  38. one: "manj kot {{count}} sekundo",
  39. two: "manj kot {{count}} sekundama",
  40. few: "manj kot {{count}} sekundami",
  41. other: "manj kot {{count}} sekundami"
  42. },
  43. future: {
  44. one: "manj kot {{count}} sekundo",
  45. two: "manj kot {{count}} sekundi",
  46. few: "manj kot {{count}} sekunde",
  47. other: "manj kot {{count}} sekund"
  48. }
  49. },
  50. xSeconds: {
  51. present: {
  52. one: "{{count}} sekunda",
  53. two: "{{count}} sekundi",
  54. few: "{{count}} sekunde",
  55. other: "{{count}} sekund"
  56. },
  57. past: {
  58. one: "{{count}} sekundo",
  59. two: "{{count}} sekundama",
  60. few: "{{count}} sekundami",
  61. other: "{{count}} sekundami"
  62. },
  63. future: {
  64. one: "{{count}} sekundo",
  65. two: "{{count}} sekundi",
  66. few: "{{count}} sekunde",
  67. other: "{{count}} sekund"
  68. }
  69. },
  70. halfAMinute: "pol minute",
  71. lessThanXMinutes: {
  72. present: {
  73. one: "manj kot {{count}} minuta",
  74. two: "manj kot {{count}} minuti",
  75. few: "manj kot {{count}} minute",
  76. other: "manj kot {{count}} minut"
  77. },
  78. past: {
  79. one: "manj kot {{count}} minuto",
  80. two: "manj kot {{count}} minutama",
  81. few: "manj kot {{count}} minutami",
  82. other: "manj kot {{count}} minutami"
  83. },
  84. future: {
  85. one: "manj kot {{count}} minuto",
  86. two: "manj kot {{count}} minuti",
  87. few: "manj kot {{count}} minute",
  88. other: "manj kot {{count}} minut"
  89. }
  90. },
  91. xMinutes: {
  92. present: {
  93. one: "{{count}} minuta",
  94. two: "{{count}} minuti",
  95. few: "{{count}} minute",
  96. other: "{{count}} minut"
  97. },
  98. past: {
  99. one: "{{count}} minuto",
  100. two: "{{count}} minutama",
  101. few: "{{count}} minutami",
  102. other: "{{count}} minutami"
  103. },
  104. future: {
  105. one: "{{count}} minuto",
  106. two: "{{count}} minuti",
  107. few: "{{count}} minute",
  108. other: "{{count}} minut"
  109. }
  110. },
  111. aboutXHours: {
  112. present: {
  113. one: "pribli\u017Eno {{count}} ura",
  114. two: "pribli\u017Eno {{count}} uri",
  115. few: "pribli\u017Eno {{count}} ure",
  116. other: "pribli\u017Eno {{count}} ur"
  117. },
  118. past: {
  119. one: "pribli\u017Eno {{count}} uro",
  120. two: "pribli\u017Eno {{count}} urama",
  121. few: "pribli\u017Eno {{count}} urami",
  122. other: "pribli\u017Eno {{count}} urami"
  123. },
  124. future: {
  125. one: "pribli\u017Eno {{count}} uro",
  126. two: "pribli\u017Eno {{count}} uri",
  127. few: "pribli\u017Eno {{count}} ure",
  128. other: "pribli\u017Eno {{count}} ur"
  129. }
  130. },
  131. xHours: {
  132. present: {
  133. one: "{{count}} ura",
  134. two: "{{count}} uri",
  135. few: "{{count}} ure",
  136. other: "{{count}} ur"
  137. },
  138. past: {
  139. one: "{{count}} uro",
  140. two: "{{count}} urama",
  141. few: "{{count}} urami",
  142. other: "{{count}} urami"
  143. },
  144. future: {
  145. one: "{{count}} uro",
  146. two: "{{count}} uri",
  147. few: "{{count}} ure",
  148. other: "{{count}} ur"
  149. }
  150. },
  151. xDays: {
  152. present: {
  153. one: "{{count}} dan",
  154. two: "{{count}} dni",
  155. few: "{{count}} dni",
  156. other: "{{count}} dni"
  157. },
  158. past: {
  159. one: "{{count}} dnem",
  160. two: "{{count}} dnevoma",
  161. few: "{{count}} dnevi",
  162. other: "{{count}} dnevi"
  163. },
  164. future: {
  165. one: "{{count}} dan",
  166. two: "{{count}} dni",
  167. few: "{{count}} dni",
  168. other: "{{count}} dni"
  169. }
  170. },
  171. aboutXWeeks: {
  172. one: "pribli\u017Eno {{count}} teden",
  173. two: "pribli\u017Eno {{count}} tedna",
  174. few: "pribli\u017Eno {{count}} tedne",
  175. other: "pribli\u017Eno {{count}} tednov"
  176. },
  177. xWeeks: {
  178. one: "{{count}} teden",
  179. two: "{{count}} tedna",
  180. few: "{{count}} tedne",
  181. other: "{{count}} tednov"
  182. },
  183. aboutXMonths: {
  184. present: {
  185. one: "pribli\u017Eno {{count}} mesec",
  186. two: "pribli\u017Eno {{count}} meseca",
  187. few: "pribli\u017Eno {{count}} mesece",
  188. other: "pribli\u017Eno {{count}} mesecev"
  189. },
  190. past: {
  191. one: "pribli\u017Eno {{count}} mesecem",
  192. two: "pribli\u017Eno {{count}} mesecema",
  193. few: "pribli\u017Eno {{count}} meseci",
  194. other: "pribli\u017Eno {{count}} meseci"
  195. },
  196. future: {
  197. one: "pribli\u017Eno {{count}} mesec",
  198. two: "pribli\u017Eno {{count}} meseca",
  199. few: "pribli\u017Eno {{count}} mesece",
  200. other: "pribli\u017Eno {{count}} mesecev"
  201. }
  202. },
  203. xMonths: {
  204. present: {
  205. one: "{{count}} mesec",
  206. two: "{{count}} meseca",
  207. few: "{{count}} meseci",
  208. other: "{{count}} mesecev"
  209. },
  210. past: {
  211. one: "{{count}} mesecem",
  212. two: "{{count}} mesecema",
  213. few: "{{count}} meseci",
  214. other: "{{count}} meseci"
  215. },
  216. future: {
  217. one: "{{count}} mesec",
  218. two: "{{count}} meseca",
  219. few: "{{count}} mesece",
  220. other: "{{count}} mesecev"
  221. }
  222. },
  223. aboutXYears: {
  224. present: {
  225. one: "pribli\u017Eno {{count}} leto",
  226. two: "pribli\u017Eno {{count}} leti",
  227. few: "pribli\u017Eno {{count}} leta",
  228. other: "pribli\u017Eno {{count}} let"
  229. },
  230. past: {
  231. one: "pribli\u017Eno {{count}} letom",
  232. two: "pribli\u017Eno {{count}} letoma",
  233. few: "pribli\u017Eno {{count}} leti",
  234. other: "pribli\u017Eno {{count}} leti"
  235. },
  236. future: {
  237. one: "pribli\u017Eno {{count}} leto",
  238. two: "pribli\u017Eno {{count}} leti",
  239. few: "pribli\u017Eno {{count}} leta",
  240. other: "pribli\u017Eno {{count}} let"
  241. }
  242. },
  243. xYears: {
  244. present: {
  245. one: "{{count}} leto",
  246. two: "{{count}} leti",
  247. few: "{{count}} leta",
  248. other: "{{count}} let"
  249. },
  250. past: {
  251. one: "{{count}} letom",
  252. two: "{{count}} letoma",
  253. few: "{{count}} leti",
  254. other: "{{count}} leti"
  255. },
  256. future: {
  257. one: "{{count}} leto",
  258. two: "{{count}} leti",
  259. few: "{{count}} leta",
  260. other: "{{count}} let"
  261. }
  262. },
  263. overXYears: {
  264. present: {
  265. one: "ve\u010D kot {{count}} leto",
  266. two: "ve\u010D kot {{count}} leti",
  267. few: "ve\u010D kot {{count}} leta",
  268. other: "ve\u010D kot {{count}} let"
  269. },
  270. past: {
  271. one: "ve\u010D kot {{count}} letom",
  272. two: "ve\u010D kot {{count}} letoma",
  273. few: "ve\u010D kot {{count}} leti",
  274. other: "ve\u010D kot {{count}} leti"
  275. },
  276. future: {
  277. one: "ve\u010D kot {{count}} leto",
  278. two: "ve\u010D kot {{count}} leti",
  279. few: "ve\u010D kot {{count}} leta",
  280. other: "ve\u010D kot {{count}} let"
  281. }
  282. },
  283. almostXYears: {
  284. present: {
  285. one: "skoraj {{count}} leto",
  286. two: "skoraj {{count}} leti",
  287. few: "skoraj {{count}} leta",
  288. other: "skoraj {{count}} let"
  289. },
  290. past: {
  291. one: "skoraj {{count}} letom",
  292. two: "skoraj {{count}} letoma",
  293. few: "skoraj {{count}} leti",
  294. other: "skoraj {{count}} leti"
  295. },
  296. future: {
  297. one: "skoraj {{count}} leto",
  298. two: "skoraj {{count}} leti",
  299. few: "skoraj {{count}} leta",
  300. other: "skoraj {{count}} let"
  301. }
  302. }
  303. };
  304. var formatDistance = function formatDistance(token, count, options) {
  305. var result = "";
  306. var tense = "present";
  307. if (options !== null && options !== void 0 && options.addSuffix) {
  308. if (options.comparison && options.comparison > 0) {
  309. tense = "future";
  310. result = "\u010Dez ";
  311. } else {
  312. tense = "past";
  313. result = "pred ";
  314. }
  315. }
  316. var tokenValue = formatDistanceLocale[token];
  317. if (typeof tokenValue === "string") {
  318. result += tokenValue;
  319. } else {
  320. var form = getFormFromCount(count);
  321. if (isPluralType(tokenValue)) {
  322. result += tokenValue[form].replace("{{count}}", String(count));
  323. } else {
  324. result += tokenValue[tense][form].replace("{{count}}", String(count));
  325. }
  326. }
  327. return result;
  328. };
  329. // lib/locale/_lib/buildFormatLongFn.js
  330. function buildFormatLongFn(args) {
  331. return function () {var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
  332. var width = options.width ? String(options.width) : args.defaultWidth;
  333. var format = args.formats[width] || args.formats[args.defaultWidth];
  334. return format;
  335. };
  336. }
  337. // lib/locale/sl/_lib/formatLong.js
  338. var dateFormats = {
  339. full: "EEEE, dd. MMMM y",
  340. long: "dd. MMMM y",
  341. medium: "d. MMM y",
  342. short: "d. MM. yy"
  343. };
  344. var timeFormats = {
  345. full: "HH:mm:ss zzzz",
  346. long: "HH:mm:ss z",
  347. medium: "HH:mm:ss",
  348. short: "HH:mm"
  349. };
  350. var dateTimeFormats = {
  351. full: "{{date}} {{time}}",
  352. long: "{{date}} {{time}}",
  353. medium: "{{date}} {{time}}",
  354. short: "{{date}} {{time}}"
  355. };
  356. var formatLong = {
  357. date: buildFormatLongFn({
  358. formats: dateFormats,
  359. defaultWidth: "full"
  360. }),
  361. time: buildFormatLongFn({
  362. formats: timeFormats,
  363. defaultWidth: "full"
  364. }),
  365. dateTime: buildFormatLongFn({
  366. formats: dateTimeFormats,
  367. defaultWidth: "full"
  368. })
  369. };
  370. // lib/locale/sl/_lib/formatRelative.js
  371. var formatRelativeLocale = {
  372. lastWeek: function lastWeek(date) {
  373. var day = date.getDay();
  374. switch (day) {
  375. case 0:
  376. return "'prej\u0161njo nedeljo ob' p";
  377. case 3:
  378. return "'prej\u0161njo sredo ob' p";
  379. case 6:
  380. return "'prej\u0161njo soboto ob' p";
  381. default:
  382. return "'prej\u0161nji' EEEE 'ob' p";
  383. }
  384. },
  385. yesterday: "'v\u010Deraj ob' p",
  386. today: "'danes ob' p",
  387. tomorrow: "'jutri ob' p",
  388. nextWeek: function nextWeek(date) {
  389. var day = date.getDay();
  390. switch (day) {
  391. case 0:
  392. return "'naslednjo nedeljo ob' p";
  393. case 3:
  394. return "'naslednjo sredo ob' p";
  395. case 6:
  396. return "'naslednjo soboto ob' p";
  397. default:
  398. return "'naslednji' EEEE 'ob' p";
  399. }
  400. },
  401. other: "P"
  402. };
  403. var formatRelative = function formatRelative(token, date, _baseDate, _options) {
  404. var format = formatRelativeLocale[token];
  405. if (typeof format === "function") {
  406. return format(date);
  407. }
  408. return format;
  409. };
  410. // lib/locale/_lib/buildLocalizeFn.js
  411. function buildLocalizeFn(args) {
  412. return function (value, options) {
  413. var context = options !== null && options !== void 0 && options.context ? String(options.context) : "standalone";
  414. var valuesArray;
  415. if (context === "formatting" && args.formattingValues) {
  416. var defaultWidth = args.defaultFormattingWidth || args.defaultWidth;
  417. var width = options !== null && options !== void 0 && options.width ? String(options.width) : defaultWidth;
  418. valuesArray = args.formattingValues[width] || args.formattingValues[defaultWidth];
  419. } else {
  420. var _defaultWidth = args.defaultWidth;
  421. var _width = options !== null && options !== void 0 && options.width ? String(options.width) : args.defaultWidth;
  422. valuesArray = args.values[_width] || args.values[_defaultWidth];
  423. }
  424. var index = args.argumentCallback ? args.argumentCallback(value) : value;
  425. return valuesArray[index];
  426. };
  427. }
  428. // lib/locale/sl/_lib/localize.js
  429. var eraValues = {
  430. narrow: ["pr. n. \u0161t.", "po n. \u0161t."],
  431. abbreviated: ["pr. n. \u0161t.", "po n. \u0161t."],
  432. wide: ["pred na\u0161im \u0161tetjem", "po na\u0161em \u0161tetju"]
  433. };
  434. var quarterValues = {
  435. narrow: ["1", "2", "3", "4"],
  436. abbreviated: ["1. \u010Det.", "2. \u010Det.", "3. \u010Det.", "4. \u010Det."],
  437. wide: ["1. \u010Detrtletje", "2. \u010Detrtletje", "3. \u010Detrtletje", "4. \u010Detrtletje"]
  438. };
  439. var monthValues = {
  440. narrow: ["j", "f", "m", "a", "m", "j", "j", "a", "s", "o", "n", "d"],
  441. abbreviated: [
  442. "jan.",
  443. "feb.",
  444. "mar.",
  445. "apr.",
  446. "maj",
  447. "jun.",
  448. "jul.",
  449. "avg.",
  450. "sep.",
  451. "okt.",
  452. "nov.",
  453. "dec."],
  454. wide: [
  455. "januar",
  456. "februar",
  457. "marec",
  458. "april",
  459. "maj",
  460. "junij",
  461. "julij",
  462. "avgust",
  463. "september",
  464. "oktober",
  465. "november",
  466. "december"]
  467. };
  468. var dayValues = {
  469. narrow: ["n", "p", "t", "s", "\u010D", "p", "s"],
  470. short: ["ned.", "pon.", "tor.", "sre.", "\u010Det.", "pet.", "sob."],
  471. abbreviated: ["ned.", "pon.", "tor.", "sre.", "\u010Det.", "pet.", "sob."],
  472. wide: [
  473. "nedelja",
  474. "ponedeljek",
  475. "torek",
  476. "sreda",
  477. "\u010Detrtek",
  478. "petek",
  479. "sobota"]
  480. };
  481. var dayPeriodValues = {
  482. narrow: {
  483. am: "d",
  484. pm: "p",
  485. midnight: "24.00",
  486. noon: "12.00",
  487. morning: "j",
  488. afternoon: "p",
  489. evening: "v",
  490. night: "n"
  491. },
  492. abbreviated: {
  493. am: "dop.",
  494. pm: "pop.",
  495. midnight: "poln.",
  496. noon: "pold.",
  497. morning: "jut.",
  498. afternoon: "pop.",
  499. evening: "ve\u010D.",
  500. night: "no\u010D"
  501. },
  502. wide: {
  503. am: "dop.",
  504. pm: "pop.",
  505. midnight: "polno\u010D",
  506. noon: "poldne",
  507. morning: "jutro",
  508. afternoon: "popoldne",
  509. evening: "ve\u010Der",
  510. night: "no\u010D"
  511. }
  512. };
  513. var formattingDayPeriodValues = {
  514. narrow: {
  515. am: "d",
  516. pm: "p",
  517. midnight: "24.00",
  518. noon: "12.00",
  519. morning: "zj",
  520. afternoon: "p",
  521. evening: "zv",
  522. night: "po"
  523. },
  524. abbreviated: {
  525. am: "dop.",
  526. pm: "pop.",
  527. midnight: "opoln.",
  528. noon: "opold.",
  529. morning: "zjut.",
  530. afternoon: "pop.",
  531. evening: "zve\u010D.",
  532. night: "pono\u010Di"
  533. },
  534. wide: {
  535. am: "dop.",
  536. pm: "pop.",
  537. midnight: "opolno\u010Di",
  538. noon: "opoldne",
  539. morning: "zjutraj",
  540. afternoon: "popoldan",
  541. evening: "zve\u010Der",
  542. night: "pono\u010Di"
  543. }
  544. };
  545. var ordinalNumber = function ordinalNumber(dirtyNumber, _options) {
  546. var number = Number(dirtyNumber);
  547. return number + ".";
  548. };
  549. var localize = {
  550. ordinalNumber: ordinalNumber,
  551. era: buildLocalizeFn({
  552. values: eraValues,
  553. defaultWidth: "wide"
  554. }),
  555. quarter: buildLocalizeFn({
  556. values: quarterValues,
  557. defaultWidth: "wide",
  558. argumentCallback: function argumentCallback(quarter) {return quarter - 1;}
  559. }),
  560. month: buildLocalizeFn({
  561. values: monthValues,
  562. defaultWidth: "wide"
  563. }),
  564. day: buildLocalizeFn({
  565. values: dayValues,
  566. defaultWidth: "wide"
  567. }),
  568. dayPeriod: buildLocalizeFn({
  569. values: dayPeriodValues,
  570. defaultWidth: "wide",
  571. formattingValues: formattingDayPeriodValues,
  572. defaultFormattingWidth: "wide"
  573. })
  574. };
  575. // lib/locale/_lib/buildMatchFn.js
  576. function buildMatchFn(args) {
  577. return function (string) {var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
  578. var width = options.width;
  579. var matchPattern = width && args.matchPatterns[width] || args.matchPatterns[args.defaultMatchWidth];
  580. var matchResult = string.match(matchPattern);
  581. if (!matchResult) {
  582. return null;
  583. }
  584. var matchedString = matchResult[0];
  585. var parsePatterns = width && args.parsePatterns[width] || args.parsePatterns[args.defaultParseWidth];
  586. var key = Array.isArray(parsePatterns) ? findIndex(parsePatterns, function (pattern) {return pattern.test(matchedString);}) : findKey(parsePatterns, function (pattern) {return pattern.test(matchedString);});
  587. var value;
  588. value = args.valueCallback ? args.valueCallback(key) : key;
  589. value = options.valueCallback ? options.valueCallback(value) : value;
  590. var rest = string.slice(matchedString.length);
  591. return { value: value, rest: rest };
  592. };
  593. }
  594. function findKey(object, predicate) {
  595. for (var key in object) {
  596. if (Object.prototype.hasOwnProperty.call(object, key) && predicate(object[key])) {
  597. return key;
  598. }
  599. }
  600. return;
  601. }
  602. function findIndex(array, predicate) {
  603. for (var key = 0; key < array.length; key++) {
  604. if (predicate(array[key])) {
  605. return key;
  606. }
  607. }
  608. return;
  609. }
  610. // lib/locale/_lib/buildMatchPatternFn.js
  611. function buildMatchPatternFn(args) {
  612. return function (string) {var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
  613. var matchResult = string.match(args.matchPattern);
  614. if (!matchResult)
  615. return null;
  616. var matchedString = matchResult[0];
  617. var parseResult = string.match(args.parsePattern);
  618. if (!parseResult)
  619. return null;
  620. var value = args.valueCallback ? args.valueCallback(parseResult[0]) : parseResult[0];
  621. value = options.valueCallback ? options.valueCallback(value) : value;
  622. var rest = string.slice(matchedString.length);
  623. return { value: value, rest: rest };
  624. };
  625. }
  626. // lib/locale/sl/_lib/match.js
  627. var matchOrdinalNumberPattern = /^(\d+)\./i;
  628. var parseOrdinalNumberPattern = /\d+/i;
  629. var matchEraPatterns = {
  630. abbreviated: /^(pr\. n\. št\.|po n\. št\.)/i,
  631. wide: /^(pred Kristusom|pred na[sš]im [sš]tetjem|po Kristusu|po na[sš]em [sš]tetju|na[sš]ega [sš]tetja)/i
  632. };
  633. var parseEraPatterns = {
  634. any: [/^pr/i, /^(po|na[sš]em)/i]
  635. };
  636. var matchQuarterPatterns = {
  637. narrow: /^[1234]/i,
  638. abbreviated: /^[1234]\.\s?[čc]et\.?/i,
  639. wide: /^[1234]\. [čc]etrtletje/i
  640. };
  641. var parseQuarterPatterns = {
  642. any: [/1/i, /2/i, /3/i, /4/i]
  643. };
  644. var matchMonthPatterns = {
  645. narrow: /^[jfmasond]/i,
  646. abbreviated: /^(jan\.|feb\.|mar\.|apr\.|maj|jun\.|jul\.|avg\.|sep\.|okt\.|nov\.|dec\.)/i,
  647. wide: /^(januar|februar|marec|april|maj|junij|julij|avgust|september|oktober|november|december)/i
  648. };
  649. var parseMonthPatterns = {
  650. narrow: [
  651. /^j/i,
  652. /^f/i,
  653. /^m/i,
  654. /^a/i,
  655. /^m/i,
  656. /^j/i,
  657. /^j/i,
  658. /^a/i,
  659. /^s/i,
  660. /^o/i,
  661. /^n/i,
  662. /^d/i],
  663. abbreviated: [
  664. /^ja/i,
  665. /^fe/i,
  666. /^mar/i,
  667. /^ap/i,
  668. /^maj/i,
  669. /^jun/i,
  670. /^jul/i,
  671. /^av/i,
  672. /^s/i,
  673. /^o/i,
  674. /^n/i,
  675. /^d/i],
  676. wide: [
  677. /^ja/i,
  678. /^fe/i,
  679. /^mar/i,
  680. /^ap/i,
  681. /^maj/i,
  682. /^jun/i,
  683. /^jul/i,
  684. /^av/i,
  685. /^s/i,
  686. /^o/i,
  687. /^n/i,
  688. /^d/i]
  689. };
  690. var matchDayPatterns = {
  691. narrow: /^[nptsčc]/i,
  692. short: /^(ned\.|pon\.|tor\.|sre\.|[cč]et\.|pet\.|sob\.)/i,
  693. abbreviated: /^(ned\.|pon\.|tor\.|sre\.|[cč]et\.|pet\.|sob\.)/i,
  694. wide: /^(nedelja|ponedeljek|torek|sreda|[cč]etrtek|petek|sobota)/i
  695. };
  696. var parseDayPatterns = {
  697. narrow: [/^n/i, /^p/i, /^t/i, /^s/i, /^[cč]/i, /^p/i, /^s/i],
  698. any: [/^n/i, /^po/i, /^t/i, /^sr/i, /^[cč]/i, /^pe/i, /^so/i]
  699. };
  700. var matchDayPeriodPatterns = {
  701. narrow: /^(d|po?|z?v|n|z?j|24\.00|12\.00)/i,
  702. any: /^(dop\.|pop\.|o?poln(\.|o[cč]i?)|o?pold(\.|ne)|z?ve[cč](\.|er)|(po)?no[cč]i?|popold(ne|an)|jut(\.|ro)|zjut(\.|raj))/i
  703. };
  704. var parseDayPeriodPatterns = {
  705. narrow: {
  706. am: /^d/i,
  707. pm: /^p/i,
  708. midnight: /^24/i,
  709. noon: /^12/i,
  710. morning: /^(z?j)/i,
  711. afternoon: /^p/i,
  712. evening: /^(z?v)/i,
  713. night: /^(n|po)/i
  714. },
  715. any: {
  716. am: /^dop\./i,
  717. pm: /^pop\./i,
  718. midnight: /^o?poln/i,
  719. noon: /^o?pold/i,
  720. morning: /j/i,
  721. afternoon: /^pop\./i,
  722. evening: /^z?ve/i,
  723. night: /(po)?no/i
  724. }
  725. };
  726. var match = {
  727. ordinalNumber: buildMatchPatternFn({
  728. matchPattern: matchOrdinalNumberPattern,
  729. parsePattern: parseOrdinalNumberPattern,
  730. valueCallback: function valueCallback(value) {return parseInt(value, 10);}
  731. }),
  732. era: buildMatchFn({
  733. matchPatterns: matchEraPatterns,
  734. defaultMatchWidth: "wide",
  735. parsePatterns: parseEraPatterns,
  736. defaultParseWidth: "any"
  737. }),
  738. quarter: buildMatchFn({
  739. matchPatterns: matchQuarterPatterns,
  740. defaultMatchWidth: "wide",
  741. parsePatterns: parseQuarterPatterns,
  742. defaultParseWidth: "any",
  743. valueCallback: function valueCallback(index) {return index + 1;}
  744. }),
  745. month: buildMatchFn({
  746. matchPatterns: matchMonthPatterns,
  747. defaultMatchWidth: "wide",
  748. parsePatterns: parseMonthPatterns,
  749. defaultParseWidth: "wide"
  750. }),
  751. day: buildMatchFn({
  752. matchPatterns: matchDayPatterns,
  753. defaultMatchWidth: "wide",
  754. parsePatterns: parseDayPatterns,
  755. defaultParseWidth: "any"
  756. }),
  757. dayPeriod: buildMatchFn({
  758. matchPatterns: matchDayPeriodPatterns,
  759. defaultMatchWidth: "any",
  760. parsePatterns: parseDayPeriodPatterns,
  761. defaultParseWidth: "any"
  762. })
  763. };
  764. // lib/locale/sl.js
  765. var sl = {
  766. code: "sl",
  767. formatDistance: formatDistance,
  768. formatLong: formatLong,
  769. formatRelative: formatRelative,
  770. localize: localize,
  771. match: match,
  772. options: {
  773. weekStartsOn: 1,
  774. firstWeekContainsDate: 1
  775. }
  776. };
  777. // lib/locale/sl/cdn.js
  778. window.dateFns = _objectSpread(_objectSpread({},
  779. window.dateFns), {}, {
  780. locale: _objectSpread(_objectSpread({}, (_window$dateFns =
  781. window.dateFns) === null || _window$dateFns === void 0 ? void 0 : _window$dateFns.locale), {}, {
  782. sl: sl }) });
  783. //# debugId=2E2BB7293682F67664756E2164756E21
  784. //# sourceMappingURL=cdn.js.map
  785. })();