mirror of
https://github.com/WordPress/WordPress.git
synced 2024-11-15 15:16:29 +01:00
2ae0f9e6b4
Updates packages: annotations, api-fetch, block-library, blocks, components, compose, core-data, data, date, edit-post, editor, element, format-library, i18n, list-reusable-blocks, notices, nux, plugins, rich-text, viewport Updates changed dependencies in script-loader.php Upgrades React from 16.5.2 to 16.6.3 See #45145 Built from https://develop.svn.wordpress.org/branches/5.0@43903 git-svn-id: http://core.svn.wordpress.org/branches/5.0@43735 1a063a9b-81f0-0310-95a4-ce76da25c4cd
1 line
54 KiB
Plaintext
1 line
54 KiB
Plaintext
{"version":3,"sources":["webpack://wp.[name]/webpack/bootstrap","webpack://wp.[name]//Users/riad/Workspace/a8c/gutenberg/packages/date/src/index.js","webpack://wp.[name]/./node_modules/moment-timezone/index.js","webpack://wp.[name]/./node_modules/moment-timezone/moment-timezone-utils.js","webpack://wp.[name]/./node_modules/moment-timezone/moment-timezone.js","webpack://wp.[name]/external \"moment\""],"names":["settings","l10n","locale","months","monthsShort","weekdays","weekdaysShort","meridiem","am","pm","AM","PM","relative","future","past","formats","time","date","datetime","datetimeAbbreviated","timezone","offset","string","setSettings","dateSettings","currentLocale","momentLib","updateLocale","parentLocale","hour","minute","isLowercase","longDateFormat","LT","LTS","L","LL","LLL","LLLL","relativeTime","s","m","mm","h","hh","d","dd","M","MM","y","yy","setupWPTimezone","__experimentalGetSettings","tz","add","pack","name","abbrs","untils","offsets","MINUTE_IN_SECONDS","HOUR_IN_MINUTES","HOUR_IN_SECONDS","formatMap","D","j","l","N","S","momentDate","num","format","withOrdinal","replace","w","z","parseInt","W","F","n","t","daysInMonth","isLeapYear","o","Y","a","A","B","timezoned","utcOffset","seconds","minutes","hours","g","G","H","i","u","v","e","I","isDST","O","P","T","Z","sign","parts","substring","split","c","r","U","dateFormat","dateValue","Date","char","newFormat","length","push","join","dateMoment","gmdate","utc","dateI18n","gmt","isInTheFuture","now","momentObject","isAfter","getDate","dateString","toDate"],"mappings":";;AAAA;AACA;;AAEA;AAC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KAAK,UAAU,IAA0C;AACzD,EAAE,iCAAO,CAAC,2CAAQ,CAAC,oCAAE,OAAO;AAAA;AAAA;AAAA,oGAAC,CAAC;AAC9B,EAAE,MAAM,EAEN;AACF,CAAC;AACD;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA,qBAAqB;;AAErB;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA,aAAa,uBAAuB;AACpC;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA,WAAW;AACX;;AAEA,aAAa,yBAAyB;AACtC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA,wBAAwB,iCAAiC;AACzD,wBAAwB,kCAAkC;AAC1D,wBAAwB,mCAAmC;AAC3D,wBAAwB,oCAAoC;AAC5D;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;;AAEA,8BAA8B,cAAc;;AAE5C,aAAa,cAAc;AAC3B;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;;AAEA,aAAa,kBAAkB;AAC/B;AACA;;AAEA,cAAc,mBAAmB;AACjC;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA,qBAAqB;AACrB;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA,aAAa,mBAAmB;AAChC;AACA;AACA,cAAc,kBAAkB;AAChC;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA,aAAa,mBAAmB;AAChC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA,aAAa,uBAAuB;AACpC;AACA;;AAEA;AACA;AACA;AACA;AACA,GAAG;;AAEH,aAAa,yBAAyB;AACtC;AACA;;AAEA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA,CAAC;;;;;;;;;;;;AC7TD;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA,KAAK,KAA0B;AAC/B,2BAA2B,mBAAO,CAAC,sBAAQ,GAAG;AAC9C,EAAE,UAAU,IAA0C;AACtD,EAAE,iCAAO,CAAC,2CAAQ,CAAC,oCAAE,OAAO;AAAA;AAAA;AAAA,oGAAC,CAAC;AAC9B,EAAE,MAAM,EAEN;AACF,CAAC;AACD;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA,YAAY;AACZ,YAAY;AACZ,YAAY;AACZ,cAAc;AACd;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA,SAAS,kBAAkB;AAC3B;AACA;AACA;;AAEA;AACA,aAAa,uBAAuB;AACpC;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA,iBAAiB,kBAAkB;AACnC;AACA;AACA;;AAEA;AACA,iBAAiB,YAAY;AAC7B,mEAAmE;AACnE;;AAEA;AACA;;AAEA;AACA;;AAEA,aAAa,oBAAoB;AACjC;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;;AAEH;AACA;AACA;AACA;;AAEA,cAAc,mBAAmB;AACjC;AACA;AACA;AACA;AACA,GAAG;;AAEH;AACA;AACA;AACA;AACA;AACA;;AAEA,cAAc,SAAS;AACvB;AACA;AACA;;AAEA;AACA;AACA,KAAK;AACL;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA,GAAG;;AAEH;AACA;AACA,GAAG;;AAEH;AACA;AACA;AACA,GAAG;;AAEH;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA,kCAAkC,IAAI;AACtC;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA,aAAa,QAAQ;AACrB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,aAAa,OAAO;AACpB;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,aAAa,oBAAoB;AACjC;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA,uBAAuB;AACvB;AACA;;AAEA,aAAa,mBAAmB;AAChC;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA,aAAa,oBAAoB;AACjC;AACA,cAAc,mBAAmB;AACjC;AACA;AACA;AACA;;AAEA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;;AAEA,aAAa,mBAAmB;AAChC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;;AAEA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;;AAEA,aAAa,oBAAoB;AACjC;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,8BAA8B;AAC9B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;;AAEA;;AAEA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA;AACA,gBAAgB,qBAAqB;AACrC;;AAEA;AACA;AACA,iBAAiB,2BAA2B;AAC5C;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,EAAE;AACF;AACA;AACA;;AAEA;;AAEA;AACA,CAAC;;;;;;;;;;;;ACpmBD,aAAa,iCAAiC,EAAE,I","file":"date.js","sourcesContent":[" \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = \"./node_modules/@wordpress/date/build-module/index.js\");\n","/**\n * External dependencies\n */\nimport momentLib from 'moment';\nimport 'moment-timezone';\nimport 'moment-timezone/moment-timezone-utils';\n\n// Changes made here will likely need to be made in `lib/client-assets.php` as\n// well because it uses the `setSettings()` function to change these settings.\nlet settings = {\n\tl10n: {\n\t\tlocale: 'en_US',\n\t\tmonths: [ 'January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December' ],\n\t\tmonthsShort: [ 'Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec' ],\n\t\tweekdays: [ 'Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday' ],\n\t\tweekdaysShort: [ 'Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat' ],\n\t\tmeridiem: { am: 'am', pm: 'pm', AM: 'AM', PM: 'PM' },\n\t\trelative: { future: ' % s from now', past: '% s ago' },\n\t},\n\tformats: {\n\t\ttime: 'g: i a',\n\t\tdate: 'F j, Y',\n\t\tdatetime: 'F j, Y g: i a',\n\t\tdatetimeAbbreviated: 'M j, Y g: i a',\n\t},\n\ttimezone: { offset: '0', string: '' },\n};\n\n/**\n * Adds a locale to moment, using the format supplied by `wp_localize_script()`.\n *\n * @param {Object} dateSettings Settings, including locale data.\n */\nexport function setSettings( dateSettings ) {\n\tsettings = dateSettings;\n\n\t// Backup and restore current locale.\n\tconst currentLocale = momentLib.locale();\n\tmomentLib.updateLocale( dateSettings.l10n.locale, {\n\t\t// Inherit anything missing from the default locale.\n\t\tparentLocale: currentLocale,\n\t\tmonths: dateSettings.l10n.months,\n\t\tmonthsShort: dateSettings.l10n.monthsShort,\n\t\tweekdays: dateSettings.l10n.weekdays,\n\t\tweekdaysShort: dateSettings.l10n.weekdaysShort,\n\t\tmeridiem( hour, minute, isLowercase ) {\n\t\t\tif ( hour < 12 ) {\n\t\t\t\treturn isLowercase ? dateSettings.l10n.meridiem.am : dateSettings.l10n.meridiem.AM;\n\t\t\t}\n\t\t\treturn isLowercase ? dateSettings.l10n.meridiem.pm : dateSettings.l10n.meridiem.PM;\n\t\t},\n\t\tlongDateFormat: {\n\t\t\tLT: dateSettings.formats.time,\n\t\t\tLTS: null,\n\t\t\tL: null,\n\t\t\tLL: dateSettings.formats.date,\n\t\t\tLLL: dateSettings.formats.datetime,\n\t\t\tLLLL: null,\n\t\t},\n\t\t// From human_time_diff?\n\t\t// Set to `(number, withoutSuffix, key, isFuture) => {}` instead.\n\t\trelativeTime: {\n\t\t\tfuture: dateSettings.l10n.relative.future,\n\t\t\tpast: dateSettings.l10n.relative.past,\n\t\t\ts: 'seconds',\n\t\t\tm: 'a minute',\n\t\t\tmm: '%d minutes',\n\t\t\th: 'an hour',\n\t\t\thh: '%d hours',\n\t\t\td: 'a day',\n\t\t\tdd: '%d days',\n\t\t\tM: 'a month',\n\t\t\tMM: '%d months',\n\t\t\ty: 'a year',\n\t\t\tyy: '%d years',\n\t\t},\n\t} );\n\tmomentLib.locale( currentLocale );\n\n\tsetupWPTimezone();\n}\n\n/**\n * Returns the currently defined date settings.\n *\n * @return {Object} Settings, including locale data.\n */\nexport function __experimentalGetSettings() {\n\treturn settings;\n}\n\nfunction setupWPTimezone() {\n\t// Create WP timezone based off dateSettings.\n\tmomentLib.tz.add( momentLib.tz.pack( {\n\t\tname: 'WP',\n\t\tabbrs: [ 'WP' ],\n\t\tuntils: [ null ],\n\t\toffsets: [ -settings.timezone.offset * 60 || 0 ],\n\t} ) );\n}\n\n// Date constants.\n/**\n * Number of seconds in one minute.\n *\n * @type {Number}\n */\nconst MINUTE_IN_SECONDS = 60;\n/**\n * Number of minutes in one hour.\n *\n * @type {Number}\n */\nconst HOUR_IN_MINUTES = 60;\n/**\n * Number of seconds in one hour.\n *\n * @type {Number}\n */\nconst HOUR_IN_SECONDS = 60 * MINUTE_IN_SECONDS;\n\n/**\n * Map of PHP formats to Moment.js formats.\n *\n * These are used internally by {@link wp.date.format}, and are either\n * a string representing the corresponding Moment.js format code, or a\n * function which returns the formatted string.\n *\n * This should only be used through {@link wp.date.format}, not\n * directly.\n *\n * @type {Object}\n */\nconst formatMap = {\n\t// Day\n\td: 'DD',\n\tD: 'ddd',\n\tj: 'D',\n\tl: 'dddd',\n\tN: 'E',\n\n\t/**\n\t * Gets the ordinal suffix.\n\t *\n\t * @param {moment} momentDate Moment instance.\n\t *\n\t * @return {string} Formatted date.\n\t */\n\tS( momentDate ) {\n\t\t// Do - D\n\t\tconst num = momentDate.format( 'D' );\n\t\tconst withOrdinal = momentDate.format( 'Do' );\n\t\treturn withOrdinal.replace( num, '' );\n\t},\n\n\tw: 'd',\n\t/**\n\t * Gets the day of the year (zero-indexed).\n\t *\n\t * @param {moment} momentDate Moment instance.\n\t *\n\t * @return {string} Formatted date.\n\t */\n\tz( momentDate ) {\n\t\t// DDD - 1\n\t\treturn '' + parseInt( momentDate.format( 'DDD' ), 10 ) - 1;\n\t},\n\n\t// Week\n\tW: 'W',\n\n\t// Month\n\tF: 'MMMM',\n\tm: 'MM',\n\tM: 'MMM',\n\tn: 'M',\n\t/**\n\t * Gets the days in the month.\n\t *\n\t * @param {moment} momentDate Moment instance.\n\t *\n\t * @return {string} Formatted date.\n\t */\n\tt( momentDate ) {\n\t\treturn momentDate.daysInMonth();\n\t},\n\n\t// Year\n\t/**\n\t * Gets whether the current year is a leap year.\n\t *\n\t * @param {moment} momentDate Moment instance.\n\t *\n\t * @return {string} Formatted date.\n\t */\n\tL( momentDate ) {\n\t\treturn momentDate.isLeapYear() ? '1' : '0';\n\t},\n\to: 'GGGG',\n\tY: 'YYYY',\n\ty: 'YY',\n\n\t// Time\n\ta: 'a',\n\tA: 'A',\n\t/**\n\t * Gets the current time in Swatch Internet Time (.beats).\n\t *\n\t * @param {moment} momentDate Moment instance.\n\t *\n\t * @return {string} Formatted date.\n\t */\n\tB( momentDate ) {\n\t\tconst timezoned = momentLib( momentDate ).utcOffset( 60 );\n\t\tconst seconds = parseInt( timezoned.format( 's' ), 10 ),\n\t\t\tminutes = parseInt( timezoned.format( 'm' ), 10 ),\n\t\t\thours = parseInt( timezoned.format( 'H' ), 10 );\n\t\treturn parseInt(\n\t\t\t(\n\t\t\t\tseconds +\n\t\t\t\t( minutes * MINUTE_IN_SECONDS ) +\n\t\t\t\t( hours * HOUR_IN_SECONDS )\n\t\t\t) / 86.4,\n\t\t\t10\n\t\t);\n\t},\n\tg: 'h',\n\tG: 'H',\n\th: 'hh',\n\tH: 'HH',\n\ti: 'mm',\n\ts: 'ss',\n\tu: 'SSSSSS',\n\tv: 'SSS',\n\t// Timezone\n\te: 'zz',\n\t/**\n\t * Gets whether the timezone is in DST currently.\n\t *\n\t * @param {moment} momentDate Moment instance.\n\t *\n\t * @return {string} Formatted date.\n\t */\n\tI( momentDate ) {\n\t\treturn momentDate.isDST() ? '1' : '0';\n\t},\n\tO: 'ZZ',\n\tP: 'Z',\n\tT: 'z',\n\t/**\n\t * Gets the timezone offset in seconds.\n\t *\n\t * @param {moment} momentDate Moment instance.\n\t *\n\t * @return {string} Formatted date.\n\t */\n\tZ( momentDate ) {\n\t\t// Timezone offset in seconds.\n\t\tconst offset = momentDate.format( 'Z' );\n\t\tconst sign = offset[ 0 ] === '-' ? -1 : 1;\n\t\tconst parts = offset.substring( 1 ).split( ':' );\n\t\treturn sign * ( ( parts[ 0 ] * HOUR_IN_MINUTES ) + parts[ 1 ] ) * MINUTE_IN_SECONDS;\n\t},\n\t// Full date/time\n\tc: 'YYYY-MM-DDTHH:mm:ssZ', // .toISOString\n\tr: 'ddd, D MMM YYYY HH:mm:ss ZZ',\n\tU: 'X',\n};\n\n/**\n * Formats a date. Does not alter the date's timezone.\n *\n * @param {string} dateFormat PHP-style formatting string.\n * See php.net/date.\n * @param {(Date|string|moment|null)} dateValue Date object or string,\n * parsable by moment.js.\n *\n * @return {string} Formatted date.\n */\nexport function format( dateFormat, dateValue = new Date() ) {\n\tlet i, char;\n\tlet newFormat = [];\n\tconst momentDate = momentLib( dateValue );\n\tfor ( i = 0; i < dateFormat.length; i++ ) {\n\t\tchar = dateFormat[ i ];\n\t\t// Is this an escape?\n\t\tif ( '\\\\' === char ) {\n\t\t\t// Add next character, then move on.\n\t\t\ti++;\n\t\t\tnewFormat.push( '[' + dateFormat[ i ] + ']' );\n\t\t\tcontinue;\n\t\t}\n\t\tif ( char in formatMap ) {\n\t\t\tif ( typeof formatMap[ char ] !== 'string' ) {\n\t\t\t\t// If the format is a function, call it.\n\t\t\t\tnewFormat.push( '[' + formatMap[ char ]( momentDate ) + ']' );\n\t\t\t} else {\n\t\t\t\t// Otherwise, add as a formatting string.\n\t\t\t\tnewFormat.push( formatMap[ char ] );\n\t\t\t}\n\t\t} else {\n\t\t\tnewFormat.push( '[' + char + ']' );\n\t\t}\n\t}\n\t// Join with [] between to separate characters, and replace\n\t// unneeded separators with static text.\n\tnewFormat = newFormat.join( '[]' );\n\treturn momentDate.format( newFormat );\n}\n\n/**\n * Formats a date (like `date()` in PHP), in the site's timezone.\n *\n * @param {string} dateFormat PHP-style formatting string.\n * See php.net/date.\n * @param {(Date|string|moment|null)} dateValue Date object or string,\n * parsable by moment.js.\n *\n * @return {string} Formatted date.\n */\nexport function date( dateFormat, dateValue = new Date() ) {\n\tconst offset = settings.timezone.offset * HOUR_IN_MINUTES;\n\tconst dateMoment = momentLib( dateValue ).utcOffset( offset, true );\n\treturn format( dateFormat, dateMoment );\n}\n\n/**\n * Formats a date (like `date()` in PHP), in the UTC timezone.\n *\n * @param {string} dateFormat PHP-style formatting string.\n * See php.net/date.\n * @param {(Date|string|moment|null)} dateValue Date object or string,\n * parsable by moment.js.\n *\n * @return {string} Formatted date.\n */\nexport function gmdate( dateFormat, dateValue = new Date() ) {\n\tconst dateMoment = momentLib( dateValue ).utc();\n\treturn format( dateFormat, dateMoment );\n}\n\n/**\n * Formats a date (like `dateI18n()` in PHP).\n *\n * @param {string} dateFormat PHP-style formatting string.\n * See php.net/date.\n * @param {(Date|string|moment|null)} dateValue Date object or string,\n * parsable by moment.js.\n * @param {boolean} gmt True for GMT/UTC, false for\n * site's timezone.\n *\n * @return {string} Formatted date.\n */\nexport function dateI18n( dateFormat, dateValue = new Date(), gmt = false ) {\n\t// Defaults.\n\tconst offset = gmt ? 0 : settings.timezone.offset * HOUR_IN_MINUTES;\n\t// Convert to moment object.\n\tconst dateMoment = momentLib( dateValue ).utcOffset( offset, true );\n\n\t// Set the locale.\n\tdateMoment.locale( settings.l10n.locale );\n\t// Format and return.\n\treturn format( dateFormat, dateMoment );\n}\n\n/**\n * Check whether a date is considered in the future according to the WordPress settings.\n *\n * @param {string} dateValue Date String or Date object in the Defined WP Timezone.\n *\n * @return {boolean} Is in the future.\n */\nexport function isInTheFuture( dateValue ) {\n\tconst now = momentLib.tz( 'WP' );\n\tconst momentObject = momentLib.tz( dateValue, 'WP' );\n\n\treturn momentObject.isAfter( now );\n}\n\n/**\n * Create and return a JavaScript Date Object from a date string in the WP timezone.\n *\n * @param {string?} dateString Date formatted in the WP timezone.\n *\n * @return {Date} Date\n */\nexport function getDate( dateString ) {\n\tif ( ! dateString ) {\n\t\treturn momentLib.tz( 'WP' ).toDate();\n\t}\n\n\treturn momentLib.tz( dateString, 'WP' ).toDate();\n}\n\nsetupWPTimezone();\n","var moment = module.exports = require(\"./moment-timezone\");\r\nmoment.tz.load(require('./data/packed/latest.json'));\r\n","//! moment-timezone-utils.js\r\n//! version : 0.5.23\r\n//! Copyright (c) JS Foundation and other contributors\r\n//! license : MIT\r\n//! github.com/moment/moment-timezone\r\n\r\n(function (root, factory) {\r\n\t\"use strict\";\r\n\r\n\t/*global define*/\r\n if (typeof module === 'object' && module.exports) {\r\n module.exports = factory(require('./')); // Node\r\n } else if (typeof define === 'function' && define.amd) {\r\n\t\tdefine(['moment'], factory); // AMD\r\n\t} else {\r\n\t\tfactory(root.moment); // Browser\r\n\t}\r\n}(this, function (moment) {\r\n\t\"use strict\";\r\n\r\n\tif (!moment.tz) {\r\n\t\tthrow new Error(\"moment-timezone-utils.js must be loaded after moment-timezone.js\");\r\n\t}\r\n\r\n\t/************************************\r\n\t\tPack Base 60\r\n\t************************************/\r\n\r\n\tvar BASE60 = '0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWX',\r\n\t\tEPSILON = 0.000001; // Used to fix floating point rounding errors\r\n\r\n\tfunction packBase60Fraction(fraction, precision) {\r\n\t\tvar buffer = '.',\r\n\t\t\toutput = '',\r\n\t\t\tcurrent;\r\n\r\n\t\twhile (precision > 0) {\r\n\t\t\tprecision -= 1;\r\n\t\t\tfraction *= 60;\r\n\t\t\tcurrent = Math.floor(fraction + EPSILON);\r\n\t\t\tbuffer += BASE60[current];\r\n\t\t\tfraction -= current;\r\n\r\n\t\t\t// Only add buffer to output once we have a non-zero value.\r\n\t\t\t// This makes '.000' output '', and '.100' output '.1'\r\n\t\t\tif (current) {\r\n\t\t\t\toutput += buffer;\r\n\t\t\t\tbuffer = '';\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\treturn output;\r\n\t}\r\n\r\n\tfunction packBase60(number, precision) {\r\n\t\tvar output = '',\r\n\t\t\tabsolute = Math.abs(number),\r\n\t\t\twhole = Math.floor(absolute),\r\n\t\t\tfraction = packBase60Fraction(absolute - whole, Math.min(~~precision, 10));\r\n\r\n\t\twhile (whole > 0) {\r\n\t\t\toutput = BASE60[whole % 60] + output;\r\n\t\t\twhole = Math.floor(whole / 60);\r\n\t\t}\r\n\r\n\t\tif (number < 0) {\r\n\t\t\toutput = '-' + output;\r\n\t\t}\r\n\r\n\t\tif (output && fraction) {\r\n\t\t\treturn output + fraction;\r\n\t\t}\r\n\r\n\t\tif (!fraction && output === '-') {\r\n\t\t\treturn '0';\r\n\t\t}\r\n\r\n\t\treturn output || fraction || '0';\r\n\t}\r\n\r\n\t/************************************\r\n\t\tPack\r\n\t************************************/\r\n\r\n\tfunction packUntils(untils) {\r\n\t\tvar out = [],\r\n\t\t\tlast = 0,\r\n\t\t\ti;\r\n\r\n\t\tfor (i = 0; i < untils.length - 1; i++) {\r\n\t\t\tout[i] = packBase60(Math.round((untils[i] - last) / 1000) / 60, 1);\r\n\t\t\tlast = untils[i];\r\n\t\t}\r\n\r\n\t\treturn out.join(' ');\r\n\t}\r\n\r\n\tfunction packAbbrsAndOffsets(source) {\r\n\t\tvar index = 0,\r\n\t\t\tabbrs = [],\r\n\t\t\toffsets = [],\r\n\t\t\tindices = [],\r\n\t\t\tmap = {},\r\n\t\t\ti, key;\r\n\r\n\t\tfor (i = 0; i < source.abbrs.length; i++) {\r\n\t\t\tkey = source.abbrs[i] + '|' + source.offsets[i];\r\n\t\t\tif (map[key] === undefined) {\r\n\t\t\t\tmap[key] = index;\r\n\t\t\t\tabbrs[index] = source.abbrs[i];\r\n\t\t\t\toffsets[index] = packBase60(Math.round(source.offsets[i] * 60) / 60, 1);\r\n\t\t\t\tindex++;\r\n\t\t\t}\r\n\t\t\tindices[i] = packBase60(map[key], 0);\r\n\t\t}\r\n\r\n\t\treturn abbrs.join(' ') + '|' + offsets.join(' ') + '|' + indices.join('');\r\n\t}\r\n\r\n\tfunction packPopulation (number) {\r\n\t\tif (!number) {\r\n\t\t\treturn '';\r\n\t\t}\r\n\t\tif (number < 1000) {\r\n\t\t\treturn '|' + number;\r\n\t\t}\r\n\t\tvar exponent = String(number | 0).length - 2;\r\n\t\tvar precision = Math.round(number / Math.pow(10, exponent));\r\n\t\treturn '|' + precision + 'e' + exponent;\r\n\t}\r\n\r\n\tfunction validatePackData (source) {\r\n\t\tif (!source.name) { throw new Error(\"Missing name\"); }\r\n\t\tif (!source.abbrs) { throw new Error(\"Missing abbrs\"); }\r\n\t\tif (!source.untils) { throw new Error(\"Missing untils\"); }\r\n\t\tif (!source.offsets) { throw new Error(\"Missing offsets\"); }\r\n\t\tif (\r\n\t\t\tsource.offsets.length !== source.untils.length ||\r\n\t\t\tsource.offsets.length !== source.abbrs.length\r\n\t\t) {\r\n\t\t\tthrow new Error(\"Mismatched array lengths\");\r\n\t\t}\r\n\t}\r\n\r\n\tfunction pack (source) {\r\n\t\tvalidatePackData(source);\r\n\t\treturn [\r\n\t\t\tsource.name,\r\n\t\t\tpackAbbrsAndOffsets(source),\r\n\t\t\tpackUntils(source.untils) + packPopulation(source.population)\r\n\t\t].join('|');\r\n\t}\r\n\r\n\t/************************************\r\n\t\tCreate Links\r\n\t************************************/\r\n\r\n\tfunction arraysAreEqual(a, b) {\r\n\t\tvar i;\r\n\r\n\t\tif (a.length !== b.length) { return false; }\r\n\r\n\t\tfor (i = 0; i < a.length; i++) {\r\n\t\t\tif (a[i] !== b[i]) {\r\n\t\t\t\treturn false;\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn true;\r\n\t}\r\n\r\n\tfunction zonesAreEqual(a, b) {\r\n\t\treturn arraysAreEqual(a.offsets, b.offsets) && arraysAreEqual(a.abbrs, b.abbrs) && arraysAreEqual(a.untils, b.untils);\r\n\t}\r\n\r\n\tfunction findAndCreateLinks (input, output, links, groupLeaders) {\r\n\t\tvar i, j, a, b, group, foundGroup, groups = [];\r\n\r\n\t\tfor (i = 0; i < input.length; i++) {\r\n\t\t\tfoundGroup = false;\r\n\t\t\ta = input[i];\r\n\r\n\t\t\tfor (j = 0; j < groups.length; j++) {\r\n\t\t\t\tgroup = groups[j];\r\n\t\t\t\tb = group[0];\r\n\t\t\t\tif (zonesAreEqual(a, b)) {\r\n\t\t\t\t\tif (a.population > b.population) {\r\n\t\t\t\t\t\tgroup.unshift(a);\r\n\t\t\t\t\t} else if (a.population === b.population && groupLeaders && groupLeaders[a.name]) {\r\n group.unshift(a);\r\n } else {\r\n\t\t\t\t\t\tgroup.push(a);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tfoundGroup = true;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tif (!foundGroup) {\r\n\t\t\t\tgroups.push([a]);\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfor (i = 0; i < groups.length; i++) {\r\n\t\t\tgroup = groups[i];\r\n\t\t\toutput.push(group[0]);\r\n\t\t\tfor (j = 1; j < group.length; j++) {\r\n\t\t\t\tlinks.push(group[0].name + '|' + group[j].name);\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n\r\n\tfunction createLinks (source, groupLeaders) {\r\n\t\tvar zones = [],\r\n\t\t\tlinks = [];\r\n\r\n\t\tif (source.links) {\r\n\t\t\tlinks = source.links.slice();\r\n\t\t}\r\n\r\n\t\tfindAndCreateLinks(source.zones, zones, links, groupLeaders);\r\n\r\n\t\treturn {\r\n\t\t\tversion : source.version,\r\n\t\t\tzones : zones,\r\n\t\t\tlinks : links.sort()\r\n\t\t};\r\n\t}\r\n\r\n\t/************************************\r\n\t\tFilter Years\r\n\t************************************/\r\n\r\n\tfunction findStartAndEndIndex (untils, start, end) {\r\n\t\tvar startI = 0,\r\n\t\t\tendI = untils.length + 1,\r\n\t\t\tuntilYear,\r\n\t\t\ti;\r\n\r\n\t\tif (!end) {\r\n\t\t\tend = start;\r\n\t\t}\r\n\r\n\t\tif (start > end) {\r\n\t\t\ti = start;\r\n\t\t\tstart = end;\r\n\t\t\tend = i;\r\n\t\t}\r\n\r\n\t\tfor (i = 0; i < untils.length; i++) {\r\n\t\t\tif (untils[i] == null) {\r\n\t\t\t\tcontinue;\r\n\t\t\t}\r\n\t\t\tuntilYear = new Date(untils[i]).getUTCFullYear();\r\n\t\t\tif (untilYear < start) {\r\n\t\t\t\tstartI = i + 1;\r\n\t\t\t}\r\n\t\t\tif (untilYear > end) {\r\n\t\t\t\tendI = Math.min(endI, i + 1);\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\treturn [startI, endI];\r\n\t}\r\n\r\n\tfunction filterYears (source, start, end) {\r\n\t\tvar slice = Array.prototype.slice,\r\n\t\t\tindices = findStartAndEndIndex(source.untils, start, end),\r\n\t\t\tuntils = slice.apply(source.untils, indices);\r\n\r\n\t\tuntils[untils.length - 1] = null;\r\n\r\n\t\treturn {\r\n\t\t\tname : source.name,\r\n\t\t\tabbrs : slice.apply(source.abbrs, indices),\r\n\t\t\tuntils : untils,\r\n\t\t\toffsets : slice.apply(source.offsets, indices),\r\n\t\t\tpopulation : source.population\r\n\t\t};\r\n\t}\r\n\r\n\t/************************************\r\n\t\tFilter, Link, and Pack\r\n\t************************************/\r\n\r\n\tfunction filterLinkPack (input, start, end, groupLeaders) {\r\n\t\tvar i,\r\n\t\t\tinputZones = input.zones,\r\n\t\t\toutputZones = [],\r\n\t\t\toutput;\r\n\r\n\t\tfor (i = 0; i < inputZones.length; i++) {\r\n\t\t\toutputZones[i] = filterYears(inputZones[i], start, end);\r\n\t\t}\r\n\r\n\t\toutput = createLinks({\r\n\t\t\tzones : outputZones,\r\n\t\t\tlinks : input.links.slice(),\r\n\t\t\tversion : input.version\r\n\t\t}, groupLeaders);\r\n\r\n\t\tfor (i = 0; i < output.zones.length; i++) {\r\n\t\t\toutput.zones[i] = pack(output.zones[i]);\r\n\t\t}\r\n\r\n\t\treturn output;\r\n\t}\r\n\r\n\t/************************************\r\n\t\tExports\r\n\t************************************/\r\n\r\n\tmoment.tz.pack = pack;\r\n\tmoment.tz.packBase60 = packBase60;\r\n\tmoment.tz.createLinks = createLinks;\r\n\tmoment.tz.filterYears = filterYears;\r\n\tmoment.tz.filterLinkPack = filterLinkPack;\r\n\r\n\treturn moment;\r\n}));\r\n","//! moment-timezone.js\r\n//! version : 0.5.23\r\n//! Copyright (c) JS Foundation and other contributors\r\n//! license : MIT\r\n//! github.com/moment/moment-timezone\r\n\r\n(function (root, factory) {\r\n\t\"use strict\";\r\n\r\n\t/*global define*/\r\n\tif (typeof module === 'object' && module.exports) {\r\n\t\tmodule.exports = factory(require('moment')); // Node\r\n\t} else if (typeof define === 'function' && define.amd) {\r\n\t\tdefine(['moment'], factory); // AMD\r\n\t} else {\r\n\t\tfactory(root.moment); // Browser\r\n\t}\r\n}(this, function (moment) {\r\n\t\"use strict\";\r\n\r\n\t// Do not load moment-timezone a second time.\r\n\t// if (moment.tz !== undefined) {\r\n\t// \tlogError('Moment Timezone ' + moment.tz.version + ' was already loaded ' + (moment.tz.dataVersion ? 'with data from ' : 'without any data') + moment.tz.dataVersion);\r\n\t// \treturn moment;\r\n\t// }\r\n\r\n\tvar VERSION = \"0.5.23\",\r\n\t\tzones = {},\r\n\t\tlinks = {},\r\n\t\tnames = {},\r\n\t\tguesses = {},\r\n\t\tcachedGuess;\r\n\r\n\tif (!moment || typeof moment.version !== 'string') {\r\n\t\tlogError('Moment Timezone requires Moment.js. See https://momentjs.com/timezone/docs/#/use-it/browser/');\r\n\t}\r\n\r\n\tvar momentVersion = moment.version.split('.'),\r\n\t\tmajor = +momentVersion[0],\r\n\t\tminor = +momentVersion[1];\r\n\r\n\t// Moment.js version check\r\n\tif (major < 2 || (major === 2 && minor < 6)) {\r\n\t\tlogError('Moment Timezone requires Moment.js >= 2.6.0. You are using Moment.js ' + moment.version + '. See momentjs.com');\r\n\t}\r\n\r\n\t/************************************\r\n\t\tUnpacking\r\n\t************************************/\r\n\r\n\tfunction charCodeToInt(charCode) {\r\n\t\tif (charCode > 96) {\r\n\t\t\treturn charCode - 87;\r\n\t\t} else if (charCode > 64) {\r\n\t\t\treturn charCode - 29;\r\n\t\t}\r\n\t\treturn charCode - 48;\r\n\t}\r\n\r\n\tfunction unpackBase60(string) {\r\n\t\tvar i = 0,\r\n\t\t\tparts = string.split('.'),\r\n\t\t\twhole = parts[0],\r\n\t\t\tfractional = parts[1] || '',\r\n\t\t\tmultiplier = 1,\r\n\t\t\tnum,\r\n\t\t\tout = 0,\r\n\t\t\tsign = 1;\r\n\r\n\t\t// handle negative numbers\r\n\t\tif (string.charCodeAt(0) === 45) {\r\n\t\t\ti = 1;\r\n\t\t\tsign = -1;\r\n\t\t}\r\n\r\n\t\t// handle digits before the decimal\r\n\t\tfor (i; i < whole.length; i++) {\r\n\t\t\tnum = charCodeToInt(whole.charCodeAt(i));\r\n\t\t\tout = 60 * out + num;\r\n\t\t}\r\n\r\n\t\t// handle digits after the decimal\r\n\t\tfor (i = 0; i < fractional.length; i++) {\r\n\t\t\tmultiplier = multiplier / 60;\r\n\t\t\tnum = charCodeToInt(fractional.charCodeAt(i));\r\n\t\t\tout += num * multiplier;\r\n\t\t}\r\n\r\n\t\treturn out * sign;\r\n\t}\r\n\r\n\tfunction arrayToInt (array) {\r\n\t\tfor (var i = 0; i < array.length; i++) {\r\n\t\t\tarray[i] = unpackBase60(array[i]);\r\n\t\t}\r\n\t}\r\n\r\n\tfunction intToUntil (array, length) {\r\n\t\tfor (var i = 0; i < length; i++) {\r\n\t\t\tarray[i] = Math.round((array[i - 1] || 0) + (array[i] * 60000)); // minutes to milliseconds\r\n\t\t}\r\n\r\n\t\tarray[length - 1] = Infinity;\r\n\t}\r\n\r\n\tfunction mapIndices (source, indices) {\r\n\t\tvar out = [], i;\r\n\r\n\t\tfor (i = 0; i < indices.length; i++) {\r\n\t\t\tout[i] = source[indices[i]];\r\n\t\t}\r\n\r\n\t\treturn out;\r\n\t}\r\n\r\n\tfunction unpack (string) {\r\n\t\tvar data = string.split('|'),\r\n\t\t\toffsets = data[2].split(' '),\r\n\t\t\tindices = data[3].split(''),\r\n\t\t\tuntils = data[4].split(' ');\r\n\r\n\t\tarrayToInt(offsets);\r\n\t\tarrayToInt(indices);\r\n\t\tarrayToInt(untils);\r\n\r\n\t\tintToUntil(untils, indices.length);\r\n\r\n\t\treturn {\r\n\t\t\tname : data[0],\r\n\t\t\tabbrs : mapIndices(data[1].split(' '), indices),\r\n\t\t\toffsets : mapIndices(offsets, indices),\r\n\t\t\tuntils : untils,\r\n\t\t\tpopulation : data[5] | 0\r\n\t\t};\r\n\t}\r\n\r\n\t/************************************\r\n\t\tZone object\r\n\t************************************/\r\n\r\n\tfunction Zone (packedString) {\r\n\t\tif (packedString) {\r\n\t\t\tthis._set(unpack(packedString));\r\n\t\t}\r\n\t}\r\n\r\n\tZone.prototype = {\r\n\t\t_set : function (unpacked) {\r\n\t\t\tthis.name = unpacked.name;\r\n\t\t\tthis.abbrs = unpacked.abbrs;\r\n\t\t\tthis.untils = unpacked.untils;\r\n\t\t\tthis.offsets = unpacked.offsets;\r\n\t\t\tthis.population = unpacked.population;\r\n\t\t},\r\n\r\n\t\t_index : function (timestamp) {\r\n\t\t\tvar target = +timestamp,\r\n\t\t\t\tuntils = this.untils,\r\n\t\t\t\ti;\r\n\r\n\t\t\tfor (i = 0; i < untils.length; i++) {\r\n\t\t\t\tif (target < untils[i]) {\r\n\t\t\t\t\treturn i;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t},\r\n\r\n\t\tparse : function (timestamp) {\r\n\t\t\tvar target = +timestamp,\r\n\t\t\t\toffsets = this.offsets,\r\n\t\t\t\tuntils = this.untils,\r\n\t\t\t\tmax = untils.length - 1,\r\n\t\t\t\toffset, offsetNext, offsetPrev, i;\r\n\r\n\t\t\tfor (i = 0; i < max; i++) {\r\n\t\t\t\toffset = offsets[i];\r\n\t\t\t\toffsetNext = offsets[i + 1];\r\n\t\t\t\toffsetPrev = offsets[i ? i - 1 : i];\r\n\r\n\t\t\t\tif (offset < offsetNext && tz.moveAmbiguousForward) {\r\n\t\t\t\t\toffset = offsetNext;\r\n\t\t\t\t} else if (offset > offsetPrev && tz.moveInvalidForward) {\r\n\t\t\t\t\toffset = offsetPrev;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tif (target < untils[i] - (offset * 60000)) {\r\n\t\t\t\t\treturn offsets[i];\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\treturn offsets[max];\r\n\t\t},\r\n\r\n\t\tabbr : function (mom) {\r\n\t\t\treturn this.abbrs[this._index(mom)];\r\n\t\t},\r\n\r\n\t\toffset : function (mom) {\r\n\t\t\tlogError(\"zone.offset has been deprecated in favor of zone.utcOffset\");\r\n\t\t\treturn this.offsets[this._index(mom)];\r\n\t\t},\r\n\r\n\t\tutcOffset : function (mom) {\r\n\t\t\treturn this.offsets[this._index(mom)];\r\n\t\t}\r\n\t};\r\n\r\n\t/************************************\r\n\t\tCurrent Timezone\r\n\t************************************/\r\n\r\n\tfunction OffsetAt(at) {\r\n\t\tvar timeString = at.toTimeString();\r\n\t\tvar abbr = timeString.match(/\\([a-z ]+\\)/i);\r\n\t\tif (abbr && abbr[0]) {\r\n\t\t\t// 17:56:31 GMT-0600 (CST)\r\n\t\t\t// 17:56:31 GMT-0600 (Central Standard Time)\r\n\t\t\tabbr = abbr[0].match(/[A-Z]/g);\r\n\t\t\tabbr = abbr ? abbr.join('') : undefined;\r\n\t\t} else {\r\n\t\t\t// 17:56:31 CST\r\n\t\t\t// 17:56:31 GMT+0800 (台北標準時間)\r\n\t\t\tabbr = timeString.match(/[A-Z]{3,5}/g);\r\n\t\t\tabbr = abbr ? abbr[0] : undefined;\r\n\t\t}\r\n\r\n\t\tif (abbr === 'GMT') {\r\n\t\t\tabbr = undefined;\r\n\t\t}\r\n\r\n\t\tthis.at = +at;\r\n\t\tthis.abbr = abbr;\r\n\t\tthis.offset = at.getTimezoneOffset();\r\n\t}\r\n\r\n\tfunction ZoneScore(zone) {\r\n\t\tthis.zone = zone;\r\n\t\tthis.offsetScore = 0;\r\n\t\tthis.abbrScore = 0;\r\n\t}\r\n\r\n\tZoneScore.prototype.scoreOffsetAt = function (offsetAt) {\r\n\t\tthis.offsetScore += Math.abs(this.zone.utcOffset(offsetAt.at) - offsetAt.offset);\r\n\t\tif (this.zone.abbr(offsetAt.at).replace(/[^A-Z]/g, '') !== offsetAt.abbr) {\r\n\t\t\tthis.abbrScore++;\r\n\t\t}\r\n\t};\r\n\r\n\tfunction findChange(low, high) {\r\n\t\tvar mid, diff;\r\n\r\n\t\twhile ((diff = ((high.at - low.at) / 12e4 | 0) * 6e4)) {\r\n\t\t\tmid = new OffsetAt(new Date(low.at + diff));\r\n\t\t\tif (mid.offset === low.offset) {\r\n\t\t\t\tlow = mid;\r\n\t\t\t} else {\r\n\t\t\t\thigh = mid;\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\treturn low;\r\n\t}\r\n\r\n\tfunction userOffsets() {\r\n\t\tvar startYear = new Date().getFullYear() - 2,\r\n\t\t\tlast = new OffsetAt(new Date(startYear, 0, 1)),\r\n\t\t\toffsets = [last],\r\n\t\t\tchange, next, i;\r\n\r\n\t\tfor (i = 1; i < 48; i++) {\r\n\t\t\tnext = new OffsetAt(new Date(startYear, i, 1));\r\n\t\t\tif (next.offset !== last.offset) {\r\n\t\t\t\tchange = findChange(last, next);\r\n\t\t\t\toffsets.push(change);\r\n\t\t\t\toffsets.push(new OffsetAt(new Date(change.at + 6e4)));\r\n\t\t\t}\r\n\t\t\tlast = next;\r\n\t\t}\r\n\r\n\t\tfor (i = 0; i < 4; i++) {\r\n\t\t\toffsets.push(new OffsetAt(new Date(startYear + i, 0, 1)));\r\n\t\t\toffsets.push(new OffsetAt(new Date(startYear + i, 6, 1)));\r\n\t\t}\r\n\r\n\t\treturn offsets;\r\n\t}\r\n\r\n\tfunction sortZoneScores (a, b) {\r\n\t\tif (a.offsetScore !== b.offsetScore) {\r\n\t\t\treturn a.offsetScore - b.offsetScore;\r\n\t\t}\r\n\t\tif (a.abbrScore !== b.abbrScore) {\r\n\t\t\treturn a.abbrScore - b.abbrScore;\r\n\t\t}\r\n\t\treturn b.zone.population - a.zone.population;\r\n\t}\r\n\r\n\tfunction addToGuesses (name, offsets) {\r\n\t\tvar i, offset;\r\n\t\tarrayToInt(offsets);\r\n\t\tfor (i = 0; i < offsets.length; i++) {\r\n\t\t\toffset = offsets[i];\r\n\t\t\tguesses[offset] = guesses[offset] || {};\r\n\t\t\tguesses[offset][name] = true;\r\n\t\t}\r\n\t}\r\n\r\n\tfunction guessesForUserOffsets (offsets) {\r\n\t\tvar offsetsLength = offsets.length,\r\n\t\t\tfilteredGuesses = {},\r\n\t\t\tout = [],\r\n\t\t\ti, j, guessesOffset;\r\n\r\n\t\tfor (i = 0; i < offsetsLength; i++) {\r\n\t\t\tguessesOffset = guesses[offsets[i].offset] || {};\r\n\t\t\tfor (j in guessesOffset) {\r\n\t\t\t\tif (guessesOffset.hasOwnProperty(j)) {\r\n\t\t\t\t\tfilteredGuesses[j] = true;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfor (i in filteredGuesses) {\r\n\t\t\tif (filteredGuesses.hasOwnProperty(i)) {\r\n\t\t\t\tout.push(names[i]);\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\treturn out;\r\n\t}\r\n\r\n\tfunction rebuildGuess () {\r\n\r\n\t\t// use Intl API when available and returning valid time zone\r\n\t\ttry {\r\n\t\t\tvar intlName = Intl.DateTimeFormat().resolvedOptions().timeZone;\r\n\t\t\tif (intlName && intlName.length > 3) {\r\n\t\t\t\tvar name = names[normalizeName(intlName)];\r\n\t\t\t\tif (name) {\r\n\t\t\t\t\treturn name;\r\n\t\t\t\t}\r\n\t\t\t\tlogError(\"Moment Timezone found \" + intlName + \" from the Intl api, but did not have that data loaded.\");\r\n\t\t\t}\r\n\t\t} catch (e) {\r\n\t\t\t// Intl unavailable, fall back to manual guessing.\r\n\t\t}\r\n\r\n\t\tvar offsets = userOffsets(),\r\n\t\t\toffsetsLength = offsets.length,\r\n\t\t\tguesses = guessesForUserOffsets(offsets),\r\n\t\t\tzoneScores = [],\r\n\t\t\tzoneScore, i, j;\r\n\r\n\t\tfor (i = 0; i < guesses.length; i++) {\r\n\t\t\tzoneScore = new ZoneScore(getZone(guesses[i]), offsetsLength);\r\n\t\t\tfor (j = 0; j < offsetsLength; j++) {\r\n\t\t\t\tzoneScore.scoreOffsetAt(offsets[j]);\r\n\t\t\t}\r\n\t\t\tzoneScores.push(zoneScore);\r\n\t\t}\r\n\r\n\t\tzoneScores.sort(sortZoneScores);\r\n\r\n\t\treturn zoneScores.length > 0 ? zoneScores[0].zone.name : undefined;\r\n\t}\r\n\r\n\tfunction guess (ignoreCache) {\r\n\t\tif (!cachedGuess || ignoreCache) {\r\n\t\t\tcachedGuess = rebuildGuess();\r\n\t\t}\r\n\t\treturn cachedGuess;\r\n\t}\r\n\r\n\t/************************************\r\n\t\tGlobal Methods\r\n\t************************************/\r\n\r\n\tfunction normalizeName (name) {\r\n\t\treturn (name || '').toLowerCase().replace(/\\//g, '_');\r\n\t}\r\n\r\n\tfunction addZone (packed) {\r\n\t\tvar i, name, split, normalized;\r\n\r\n\t\tif (typeof packed === \"string\") {\r\n\t\t\tpacked = [packed];\r\n\t\t}\r\n\r\n\t\tfor (i = 0; i < packed.length; i++) {\r\n\t\t\tsplit = packed[i].split('|');\r\n\t\t\tname = split[0];\r\n\t\t\tnormalized = normalizeName(name);\r\n\t\t\tzones[normalized] = packed[i];\r\n\t\t\tnames[normalized] = name;\r\n\t\t\taddToGuesses(normalized, split[2].split(' '));\r\n\t\t}\r\n\t}\r\n\r\n\tfunction getZone (name, caller) {\r\n\t\t\r\n\t\tname = normalizeName(name);\r\n\r\n\t\tvar zone = zones[name];\r\n\t\tvar link;\r\n\r\n\t\tif (zone instanceof Zone) {\r\n\t\t\treturn zone;\r\n\t\t}\r\n\r\n\t\tif (typeof zone === 'string') {\r\n\t\t\tzone = new Zone(zone);\r\n\t\t\tzones[name] = zone;\r\n\t\t\treturn zone;\r\n\t\t}\r\n\r\n\t\t// Pass getZone to prevent recursion more than 1 level deep\r\n\t\tif (links[name] && caller !== getZone && (link = getZone(links[name], getZone))) {\r\n\t\t\tzone = zones[name] = new Zone();\r\n\t\t\tzone._set(link);\r\n\t\t\tzone.name = names[name];\r\n\t\t\treturn zone;\r\n\t\t}\r\n\r\n\t\treturn null;\r\n\t}\r\n\r\n\tfunction getNames () {\r\n\t\tvar i, out = [];\r\n\r\n\t\tfor (i in names) {\r\n\t\t\tif (names.hasOwnProperty(i) && (zones[i] || zones[links[i]]) && names[i]) {\r\n\t\t\t\tout.push(names[i]);\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\treturn out.sort();\r\n\t}\r\n\r\n\tfunction addLink (aliases) {\r\n\t\tvar i, alias, normal0, normal1;\r\n\r\n\t\tif (typeof aliases === \"string\") {\r\n\t\t\taliases = [aliases];\r\n\t\t}\r\n\r\n\t\tfor (i = 0; i < aliases.length; i++) {\r\n\t\t\talias = aliases[i].split('|');\r\n\r\n\t\t\tnormal0 = normalizeName(alias[0]);\r\n\t\t\tnormal1 = normalizeName(alias[1]);\r\n\r\n\t\t\tlinks[normal0] = normal1;\r\n\t\t\tnames[normal0] = alias[0];\r\n\r\n\t\t\tlinks[normal1] = normal0;\r\n\t\t\tnames[normal1] = alias[1];\r\n\t\t}\r\n\t}\r\n\r\n\tfunction loadData (data) {\r\n\t\taddZone(data.zones);\r\n\t\taddLink(data.links);\r\n\t\ttz.dataVersion = data.version;\r\n\t}\r\n\r\n\tfunction zoneExists (name) {\r\n\t\tif (!zoneExists.didShowError) {\r\n\t\t\tzoneExists.didShowError = true;\r\n\t\t\t\tlogError(\"moment.tz.zoneExists('\" + name + \"') has been deprecated in favor of !moment.tz.zone('\" + name + \"')\");\r\n\t\t}\r\n\t\treturn !!getZone(name);\r\n\t}\r\n\r\n\tfunction needsOffset (m) {\r\n\t\tvar isUnixTimestamp = (m._f === 'X' || m._f === 'x');\r\n\t\treturn !!(m._a && (m._tzm === undefined) && !isUnixTimestamp);\r\n\t}\r\n\r\n\tfunction logError (message) {\r\n\t\tif (typeof console !== 'undefined' && typeof console.error === 'function') {\r\n\t\t\tconsole.error(message);\r\n\t\t}\r\n\t}\r\n\r\n\t/************************************\r\n\t\tmoment.tz namespace\r\n\t************************************/\r\n\r\n\tfunction tz (input) {\r\n\t\tvar args = Array.prototype.slice.call(arguments, 0, -1),\r\n\t\t\tname = arguments[arguments.length - 1],\r\n\t\t\tzone = getZone(name),\r\n\t\t\tout = moment.utc.apply(null, args);\r\n\r\n\t\tif (zone && !moment.isMoment(input) && needsOffset(out)) {\r\n\t\t\tout.add(zone.parse(out), 'minutes');\r\n\t\t}\r\n\r\n\t\tout.tz(name);\r\n\r\n\t\treturn out;\r\n\t}\r\n\r\n\ttz.version = VERSION;\r\n\ttz.dataVersion = '';\r\n\ttz._zones = zones;\r\n\ttz._links = links;\r\n\ttz._names = names;\r\n\ttz.add = addZone;\r\n\ttz.link = addLink;\r\n\ttz.load = loadData;\r\n\ttz.zone = getZone;\r\n\ttz.zoneExists = zoneExists; // deprecated in 0.1.0\r\n\ttz.guess = guess;\r\n\ttz.names = getNames;\r\n\ttz.Zone = Zone;\r\n\ttz.unpack = unpack;\r\n\ttz.unpackBase60 = unpackBase60;\r\n\ttz.needsOffset = needsOffset;\r\n\ttz.moveInvalidForward = true;\r\n\ttz.moveAmbiguousForward = false;\r\n\r\n\t/************************************\r\n\t\tInterface with Moment.js\r\n\t************************************/\r\n\r\n\tvar fn = moment.fn;\r\n\r\n\tmoment.tz = tz;\r\n\r\n\tmoment.defaultZone = null;\r\n\r\n\tmoment.updateOffset = function (mom, keepTime) {\r\n\t\tvar zone = moment.defaultZone,\r\n\t\t\toffset;\r\n\r\n\t\tif (mom._z === undefined) {\r\n\t\t\tif (zone && needsOffset(mom) && !mom._isUTC) {\r\n\t\t\t\tmom._d = moment.utc(mom._a)._d;\r\n\t\t\t\tmom.utc().add(zone.parse(mom), 'minutes');\r\n\t\t\t}\r\n\t\t\tmom._z = zone;\r\n\t\t}\r\n\t\tif (mom._z) {\r\n\t\t\toffset = mom._z.utcOffset(mom);\r\n\t\t\tif (Math.abs(offset) < 16) {\r\n\t\t\t\toffset = offset / 60;\r\n\t\t\t}\r\n\t\t\tif (mom.utcOffset !== undefined) {\r\n\t\t\t\tmom.utcOffset(-offset, keepTime);\r\n\t\t\t} else {\r\n\t\t\t\tmom.zone(offset, keepTime);\r\n\t\t\t}\r\n\t\t}\r\n\t};\r\n\r\n\tfn.tz = function (name, keepTime) {\r\n\t\tif (name) {\r\n\t\t\tif (typeof name !== 'string') {\r\n\t\t\t\tthrow new Error('Time zone name must be a string, got ' + name + ' [' + typeof name + ']');\r\n\t\t\t}\r\n\t\t\tthis._z = getZone(name);\r\n\t\t\tif (this._z) {\r\n\t\t\t\tmoment.updateOffset(this, keepTime);\r\n\t\t\t} else {\r\n\t\t\t\tlogError(\"Moment Timezone has no data for \" + name + \". See http://momentjs.com/timezone/docs/#/data-loading/.\");\r\n\t\t\t}\r\n\t\t\treturn this;\r\n\t\t}\r\n\t\tif (this._z) { return this._z.name; }\r\n\t};\r\n\r\n\tfunction abbrWrap (old) {\r\n\t\treturn function () {\r\n\t\t\tif (this._z) { return this._z.abbr(this); }\r\n\t\t\treturn old.call(this);\r\n\t\t};\r\n\t}\r\n\r\n\tfunction resetZoneWrap (old) {\r\n\t\treturn function () {\r\n\t\t\tthis._z = null;\r\n\t\t\treturn old.apply(this, arguments);\r\n\t\t};\r\n\t}\r\n\r\n\tfn.zoneName = abbrWrap(fn.zoneName);\r\n\tfn.zoneAbbr = abbrWrap(fn.zoneAbbr);\r\n\tfn.utc = resetZoneWrap(fn.utc);\r\n\r\n\tmoment.tz.setDefault = function(name) {\r\n\t\tif (major < 2 || (major === 2 && minor < 9)) {\r\n\t\t\tlogError('Moment Timezone setDefault() requires Moment.js >= 2.9.0. You are using Moment.js ' + moment.version + '.');\r\n\t\t}\r\n\t\tmoment.defaultZone = name ? getZone(name) : null;\r\n\t\treturn moment;\r\n\t};\r\n\r\n\t// Cloning a moment should include the _z property.\r\n\tvar momentProperties = moment.momentProperties;\r\n\tif (Object.prototype.toString.call(momentProperties) === '[object Array]') {\r\n\t\t// moment 2.8.1+\r\n\t\tmomentProperties.push('_z');\r\n\t\tmomentProperties.push('_a');\r\n\t} else if (momentProperties) {\r\n\t\t// moment 2.7.0\r\n\t\tmomentProperties._z = null;\r\n\t}\r\n\r\n\t// INJECT DATA\r\n\r\n\treturn moment;\r\n}));\r\n","(function() { module.exports = this[\"moment\"]; }());"],"sourceRoot":""} |