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B,EACPz0C,CACT,EACO2kD,EAAgB3kD,EAAGy0C,EAC5B,CCLe,SAAS5H,EAAe9gB,EAAUC,GAC/CD,EAASl5C,UAAYR,OAAO45C,OAAOD,EAAWn5C,WAC9Ck5C,EAASl5C,UAAUuuC,YAAc2K,EACjC,EAAeA,EAAUC,EAC3B","sources":["webpack://parks-australia/./node_modules/@gatsbyjs/reach-router/lib/history.js","webpack://parks-australia/./node_modules/@gatsbyjs/reach-router/lib/utils.js","webpack://parks-australia/./node_modules/camelcase/index.js","webpack://parks-australia/./node_modules/common-tags/es/TemplateTag/TemplateTag.js","webpack://parks-australia/./node_modules/common-tags/es/inlineArrayTransformer/inlineArrayTransformer.js","webpack://parks-australia/./node_modules/common-tags/es/stripIndentTransformer/stripIndentTransformer.js","webpack://parks-australia/./node_modules/common-tags/es/trimResultTransformer/trimResultTransformer.js","webpack://parks-australia/./node_modules/common-tags/es/splitStringTransformer/splitStringTransformer.js","webpack://parks-australia/./node_modules/common-tags/es/commaLists/commaLists.js","webpack://parks-australia/./node_modules/common-tags/es/commaListsAnd/commaListsAnd.js","webpack://parks-australia/./node_modules/common-tags/es/commaListsOr/commaListsOr.js","webpack://parks-australia/./node_modules/common-tags/es/removeNonPrintingValuesTransformer/removeNonPrintingValuesTransformer.js","webpack://parks-australia/./node_modules/common-tags/es/replaceSubstitutionTransformer/replaceSubstitutionTransformer.js","webpack://parks-australia/./node_modules/common-tags/es/html/html.js","webpack://parks-australia/./node_modules/common-tags/es/replaceResultTransformer/replaceResultTransformer.js","webpack://parks-australia/./node_modules/common-tags/es/safeHtml/safeHtml.js","webpack://parks-australia/./node_modules/common-tags/es/oneLine/oneLine.js","webpack://parks-australia/./node_modules/common-tags/es/oneLineTrim/oneLineTrim.js","webpack://parks-australia/./node_modules/common-tags/es/oneLineCommaLists/oneLineCommaLists.js","webpack://parks-australia/./node_modules/common-tags/es/oneLineCommaListsOr/oneLineCommaListsOr.js","webpack://parks-australia/./node_modules/common-tags/es/oneLineCommaListsAnd/oneLineCommaListsAnd.js","webpack://parks-australia/./node_modules/common-tags/es/inlineLists/inlineLists.js","webpack://parks-australia/./node_modules/common-tags/es/oneLineInlineLists/oneLineInlineLists.js","webpack://parks-australia/./node_modules/common-tags/es/stripIndent/stripIndent.js","webpack://parks-australia/./node_modules/common-tags/es/stripIndents/stripIndents.js","webpack://parks-australia/./node_modules/gatsby/dist/internal-plugins/bundle-optimisations/polyfills/object-assign.js","webpack://parks-australia/./node_modules/moment-timezone/index.js","webpack://parks-australia/./node_modules/moment-timezone/moment-timezone.js","webpack://parks-australia/./node_modules/moment/moment.js","webpack://parks-australia/./node_modules/react-fast-compare/index.js","webpack://parks-australia/./node_modules/react-helmet/es/Helmet.js","webpack://parks-australia/./node_modules/react-side-effect/lib/index.js","webpack://parks-australia/./node_modules/gatsby-link/index.js","webpack://parks-australia/./node_modules/gatsby-link/parse-path.js","webpack://parks-australia/./node_modules/gatsby-react-router-scroll/index.js","webpack://parks-australia/./node_modules/gatsby-react-router-scroll/scroll-handler.js","webpack://parks-australia/./node_modules/gatsby-react-router-scroll/session-storage.js","webpack://parks-australia/./node_modules/gatsby-react-router-scroll/use-scroll-restoration.js","webpack://parks-australia/./src/components/dev-aids.tsx","webpack://parks-australia/./src/components/elements/link.tsx","webpack://parks-australia/./src/components/structure/head.tsx","webpack://parks-australia/./src/functions/build_menus/menu-main.js","webpack://parks-australia/./src/components/blocks/site-logo.tsx","webpack://parks-australia/./src/components/elements/skip-links.tsx","webpack://parks-australia/./src/components/structure/header.tsx","webpack://parks-australia/./src/components/blocks/footer-logos.tsx","webpack://parks-australia/./src/components/structure/footer-logos-panel.tsx","webpack://parks-australia/./src/functions/build_menus/menu-footer.js","webpack://parks-australia/./src/components/blocks/footer-nav-list.tsx","webpack://parks-australia/./src/components/structure/footer-navigation-panel.tsx","webpack://parks-australia/./src/components/blocks/cross-site-top-banner.tsx","webpack://parks-australia/./src/components/blocks/shared-parks-logo.tsx","webpack://parks-australia/./src/components/structure/footer-parks-logo-panel.tsx","webpack://parks-australia/./src/layouts/layout.tsx","webpack://parks-australia/./src/layouts/layout-amp.tsx","webpack://parks-australia/./.cache/_this_is_virtual_fs_path_/$virtual/async-requires.js","webpack://parks-australia/./.cache/api-runner-browser-plugins.js","webpack://parks-australia/./.cache/api-runner-browser.js","webpack://parks-australia/./.cache/emitter.js","webpack://parks-australia/./node_modules/mitt/dist/mitt.es.js","webpack://parks-australia/./.cache/normalize-page-path.js","webpack://parks-australia/./.cache/find-path.js","webpack://parks-australia/./.cache/gatsby-browser-entry.js","webpack://parks-australia/./node_modules/@babel/runtime/helpers/esm/arrayLikeToArray.js","webpack://parks-australia/./node_modules/@babel/runtime/helpers/esm/toConsumableArray.js","webpack://parks-australia/./node_modules/@babel/runtime/helpers/esm/arrayWithoutHoles.js","webpack://parks-australia/./node_modules/@babel/runtime/helpers/esm/iterableToArray.js","webpack://parks-australia/./node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js","webpack://parks-australia/./node_modules/@babel/runtime/helpers/esm/nonIterableSpread.js","webpack://parks-australia/./.cache/prefetch.js","webpack://parks-australia/./.cache/loader.js","webpack://parks-australia/./.cache/page-renderer.js","webpack://parks-australia/./.cache/route-announcer-props.js","webpack://parks-australia/./.cache/navigation.js","webpack://parks-australia/./node_modules/shallow-compare/es/index.js","webpack://parks-australia/./.cache/ensure-resources.js","webpack://parks-australia/./.cache/production-app.js","webpack://parks-australia/./.cache/public-page-renderer-prod.js","webpack://parks-australia/./.cache/public-page-renderer.js","webpack://parks-australia/./.cache/react-lifecycles-compat.js","webpack://parks-australia/./.cache/redirect-utils.js","webpack://parks-australia/./.cache/register-service-worker.js","webpack://parks-australia/./.cache/strip-prefix.js","webpack://parks-australia/./gatsby-browser.js","webpack://parks-australia/../src/image-utils.ts","webpack://parks-australia/../src/components/hooks.ts","webpack://parks-australia/../src/components/layout-wrapper.tsx","webpack://parks-australia/../src/components/picture.tsx","webpack://parks-australia/../src/components/placeholder.tsx","webpack://parks-australia/../src/components/main-image.tsx","webpack://parks-australia/../src/components/gatsby-image.server.tsx","webpack://parks-australia/../src/components/gatsby-image.browser.tsx","webpack://parks-australia/../src/components/static-image.server.tsx","webpack://parks-australia/../src/components/static-image.tsx","webpack://parks-australia/../src/components/later-hydrator.tsx","webpack://parks-australia/./node_modules/gatsby-plugin-image/gatsby-browser.js","webpack://parks-australia/./node_modules/gatsby-plugin-layout/gatsby-browser.js","webpack://parks-australia/./node_modules/gatsby-plugin-layout/wrap-page.js","webpack://parks-australia/./node_modules/gatsby-plugin-manifest/gatsby-browser.js","webpack://parks-australia/./node_modules/gatsby-plugin-manifest/get-manifest-pathname.js","webpack://parks-australia/./plugins/gatsby-plugin-breakpoint-helper/breakpoint-events.js","webpack://parks-australia/./plugins/gatsby-plugin-breakpoint-helper/gatsby-browser.js","webpack://parks-australia/./src/functions/build_menus/build-menu-tree.js","webpack://parks-australia/./src/functions/common.js","webpack://parks-australia/./node_modules/@gatsbyjs/reach-router/es/lib/utils.js","webpack://parks-australia/./node_modules/@gatsbyjs/reach-router/es/lib/history.js","webpack://parks-australia/./node_modules/@gatsbyjs/reach-router/es/index.js","webpack://parks-australia/./node_modules/invariant/browser.js","webpack://parks-australia/./node_modules/@babel/runtime/helpers/arrayLikeToArray.js","webpack://parks-australia/./node_modules/@babel/runtime/helpers/arrayWithoutHoles.js","webpack://parks-australia/./node_modules/@babel/runtime/helpers/assertThisInitialized.js","webpack://parks-australia/./node_modules/@babel/runtime/helpers/extends.js","webpack://parks-australia/./node_modules/@babel/runtime/helpers/inheritsLoose.js","webpack://parks-australia/./node_modules/@babel/runtime/helpers/interopRequireDefault.js","webpack://parks-australia/./node_modules/@babel/runtime/helpers/iterableToArray.js","webpack://parks-australia/./node_modules/@babel/runtime/helpers/nonIterableSpread.js","webpack://parks-australia/./node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","webpack://parks-australia/./node_modules/@babel/runtime/helpers/setPrototypeOf.js","webpack://parks-australia/./node_modules/@babel/runtime/helpers/toConsumableArray.js","webpack://parks-australia/./node_modules/@babel/runtime/helpers/unsupportedIterableToArray.js","webpack://parks-australia/./node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","webpack://parks-australia/./node_modules/@babel/runtime/helpers/esm/inheritsLoose.js"],"sourcesContent":["\"use strict\";\n\nexports.__esModule = true;\nvar _extends = Object.assign || function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n};\nvar getLocation = function getLocation(source) {\n var _source$location = source.location,\n search = _source$location.search,\n hash = _source$location.hash,\n href = _source$location.href,\n origin = _source$location.origin,\n protocol = _source$location.protocol,\n host = _source$location.host,\n hostname = _source$location.hostname,\n port = _source$location.port;\n var pathname = source.location.pathname;\n if (!pathname && href && canUseDOM) {\n var url = new URL(href);\n pathname = url.pathname;\n }\n return {\n pathname: encodeURI(decodeURI(pathname)),\n search: search,\n hash: hash,\n href: href,\n origin: origin,\n protocol: protocol,\n host: host,\n hostname: hostname,\n port: port,\n state: source.history.state,\n key: source.history.state && source.history.state.key || \"initial\"\n };\n};\nvar createHistory = function createHistory(source, options) {\n var listeners = [];\n var location = getLocation(source);\n var transitioning = false;\n var resolveTransition = function resolveTransition() {};\n return {\n get location() {\n return location;\n },\n get transitioning() {\n return transitioning;\n },\n _onTransitionComplete: function _onTransitionComplete() {\n transitioning = false;\n resolveTransition();\n },\n listen: function listen(listener) {\n listeners.push(listener);\n var popstateListener = function popstateListener() {\n location = getLocation(source);\n listener({\n location: location,\n action: \"POP\"\n });\n };\n source.addEventListener(\"popstate\", popstateListener);\n return function () {\n source.removeEventListener(\"popstate\", popstateListener);\n listeners = listeners.filter(function (fn) {\n return fn !== listener;\n });\n };\n },\n navigate: function navigate(to) {\n var _ref = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {},\n state = _ref.state,\n _ref$replace = _ref.replace,\n replace = _ref$replace === undefined ? false : _ref$replace;\n if (typeof to === \"number\") {\n source.history.go(to);\n } else {\n state = _extends({}, state, {\n key: Date.now() + \"\"\n });\n // try...catch iOS Safari limits to 100 pushState calls\n try {\n if (transitioning || replace) {\n source.history.replaceState(state, null, to);\n } else {\n source.history.pushState(state, null, to);\n }\n } catch (e) {\n source.location[replace ? \"replace\" : \"assign\"](to);\n }\n }\n location = getLocation(source);\n transitioning = true;\n var transition = new Promise(function (res) {\n return resolveTransition = res;\n });\n listeners.forEach(function (listener) {\n return listener({\n location: location,\n action: \"PUSH\"\n });\n });\n return transition;\n }\n };\n};\n\n////////////////////////////////////////////////////////////////////////////////\n// Stores history entries in memory for testing or other platforms like Native\nvar createMemorySource = function createMemorySource() {\n var initialPath = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : \"/\";\n var searchIndex = initialPath.indexOf(\"?\");\n var initialLocation = {\n pathname: searchIndex > -1 ? initialPath.substr(0, searchIndex) : initialPath,\n search: searchIndex > -1 ? initialPath.substr(searchIndex) : \"\"\n };\n var index = 0;\n var stack = [initialLocation];\n var states = [null];\n return {\n get location() {\n return stack[index];\n },\n addEventListener: function addEventListener(name, fn) {},\n removeEventListener: function removeEventListener(name, fn) {},\n history: {\n get entries() {\n return stack;\n },\n get index() {\n return index;\n },\n get state() {\n return states[index];\n },\n pushState: function pushState(state, _, uri) {\n var _uri$split = uri.split(\"?\"),\n pathname = _uri$split[0],\n _uri$split$ = _uri$split[1],\n search = _uri$split$ === undefined ? \"\" : _uri$split$;\n index++;\n stack.push({\n pathname: pathname,\n search: search.length ? \"?\" + search : search\n });\n states.push(state);\n },\n replaceState: function replaceState(state, _, uri) {\n var _uri$split2 = uri.split(\"?\"),\n pathname = _uri$split2[0],\n _uri$split2$ = _uri$split2[1],\n search = _uri$split2$ === undefined ? \"\" : _uri$split2$;\n stack[index] = {\n pathname: pathname,\n search: search\n };\n states[index] = state;\n },\n go: function go(to) {\n var newIndex = index + to;\n if (newIndex < 0 || newIndex > states.length - 1) {\n return;\n }\n index = newIndex;\n }\n }\n };\n};\n\n////////////////////////////////////////////////////////////////////////////////\n// global history - uses window.history as the source if available, otherwise a\n// memory history\nvar canUseDOM = !!(typeof window !== \"undefined\" && window.document && window.document.createElement);\nvar getSource = function getSource() {\n return canUseDOM ? window : createMemorySource();\n};\nvar globalHistory = createHistory(getSource());\nvar navigate = globalHistory.navigate;\n\n////////////////////////////////////////////////////////////////////////////////\n\nexports.globalHistory = globalHistory;\nexports.navigate = navigate;\nexports.createHistory = createHistory;\nexports.createMemorySource = createMemorySource;","\"use strict\";\n\nexports.__esModule = true;\nexports.shallowCompare = exports.validateRedirect = exports.insertParams = exports.resolve = exports.match = exports.pick = exports.startsWith = undefined;\nvar _invariant = require(\"invariant\");\nvar _invariant2 = _interopRequireDefault(_invariant);\nfunction _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n default: obj\n };\n}\n\n////////////////////////////////////////////////////////////////////////////////\n// startsWith(string, search) - Check if `string` starts with `search`\nvar startsWith = function startsWith(string, search) {\n return string.substr(0, search.length) === search;\n};\n\n////////////////////////////////////////////////////////////////////////////////\n// pick(routes, uri)\n//\n// Ranks and picks the best route to match. Each segment gets the highest\n// amount of points, then the type of segment gets an additional amount of\n// points where\n//\n// static > dynamic > splat > root\n//\n// This way we don't have to worry about the order of our routes, let the\n// computers do it.\n//\n// A route looks like this\n//\n// { path, default, value }\n//\n// And a returned match looks like:\n//\n// { route, params, uri }\n//\n// I know, I should use TypeScript not comments for these types.\nvar pick = function pick(routes, uri) {\n var match = void 0;\n var default_ = void 0;\n var _uri$split = uri.split(\"?\"),\n uriPathname = _uri$split[0];\n var uriSegments = segmentize(uriPathname);\n var isRootUri = uriSegments[0] === \"\";\n var ranked = rankRoutes(routes);\n for (var i = 0, l = ranked.length; i < l; i++) {\n var missed = false;\n var route = ranked[i].route;\n if (route.default) {\n default_ = {\n route: route,\n params: {},\n uri: uri\n };\n continue;\n }\n var routeSegments = segmentize(route.path);\n var params = {};\n var max = Math.max(uriSegments.length, routeSegments.length);\n var index = 0;\n for (; index < max; index++) {\n var routeSegment = routeSegments[index];\n var uriSegment = uriSegments[index];\n if (isSplat(routeSegment)) {\n // Hit a splat, just grab the rest, and return a match\n // uri: /files/documents/work\n // route: /files/*\n var param = routeSegment.slice(1) || \"*\";\n params[param] = uriSegments.slice(index).map(decodeURIComponent).join(\"/\");\n break;\n }\n if (uriSegment === undefined) {\n // URI is shorter than the route, no match\n // uri: /users\n // route: /users/:userId\n missed = true;\n break;\n }\n var dynamicMatch = paramRe.exec(routeSegment);\n if (dynamicMatch && !isRootUri) {\n var matchIsNotReserved = reservedNames.indexOf(dynamicMatch[1]) === -1;\n !matchIsNotReserved ? process.env.NODE_ENV !== \"production\" ? (0, _invariant2.default)(false, \" dynamic segment \\\"\" + dynamicMatch[1] + \"\\\" is a reserved name. Please use a different name in path \\\"\" + route.path + \"\\\".\") : (0, _invariant2.default)(false) : void 0;\n var value = decodeURIComponent(uriSegment);\n params[dynamicMatch[1]] = value;\n } else if (routeSegment !== uriSegment) {\n // Current segments don't match, not dynamic, not splat, so no match\n // uri: /users/123/settings\n // route: /users/:id/profile\n missed = true;\n break;\n }\n }\n if (!missed) {\n match = {\n route: route,\n params: params,\n uri: \"/\" + uriSegments.slice(0, index).join(\"/\")\n };\n break;\n }\n }\n return match || default_ || null;\n};\n\n////////////////////////////////////////////////////////////////////////////////\n// match(path, uri) - Matches just one path to a uri, also lol\nvar match = function match(path, uri) {\n return pick([{\n path: path\n }], uri);\n};\n\n////////////////////////////////////////////////////////////////////////////////\n// resolve(to, basepath)\n//\n// Resolves URIs as though every path is a directory, no files. Relative URIs\n// in the browser can feel awkward because not only can you be \"in a directory\"\n// you can be \"at a file\", too. For example\n//\n// browserSpecResolve('foo', '/bar/') => /bar/foo\n// browserSpecResolve('foo', '/bar') => /foo\n//\n// But on the command line of a file system, it's not as complicated, you can't\n// `cd` from a file, only directories. This way, links have to know less about\n// their current path. To go deeper you can do this:\n//\n// \n// // instead of\n// \n//\n// Just like `cd`, if you want to go deeper from the command line, you do this:\n//\n// cd deeper\n// # not\n// cd $(pwd)/deeper\n//\n// By treating every path as a directory, linking to relative paths should\n// require less contextual information and (fingers crossed) be more intuitive.\nvar resolve = function resolve(to, base) {\n // /foo/bar, /baz/qux => /foo/bar\n if (startsWith(to, \"/\")) {\n return to;\n }\n var _to$split = to.split(\"?\"),\n toPathname = _to$split[0],\n toQuery = _to$split[1];\n var _base$split = base.split(\"?\"),\n basePathname = _base$split[0];\n var toSegments = segmentize(toPathname);\n var baseSegments = segmentize(basePathname);\n\n // ?a=b, /users?b=c => /users?a=b\n if (toSegments[0] === \"\") {\n return addQuery(basePathname, toQuery);\n }\n\n // profile, /users/789 => /users/789/profile\n if (!startsWith(toSegments[0], \".\")) {\n var pathname = baseSegments.concat(toSegments).join(\"/\");\n return addQuery((basePathname === \"/\" ? \"\" : \"/\") + pathname, toQuery);\n }\n\n // ./ /users/123 => /users/123\n // ../ /users/123 => /users\n // ../.. /users/123 => /\n // ../../one /a/b/c/d => /a/b/one\n // .././one /a/b/c/d => /a/b/c/one\n var allSegments = baseSegments.concat(toSegments);\n var segments = [];\n for (var i = 0, l = allSegments.length; i < l; i++) {\n var segment = allSegments[i];\n if (segment === \"..\") segments.pop();else if (segment !== \".\") segments.push(segment);\n }\n return addQuery(\"/\" + segments.join(\"/\"), toQuery);\n};\n\n////////////////////////////////////////////////////////////////////////////////\n// insertParams(path, params)\n\nvar insertParams = function insertParams(path, params) {\n var _path$split = path.split(\"?\"),\n pathBase = _path$split[0],\n _path$split$ = _path$split[1],\n query = _path$split$ === undefined ? \"\" : _path$split$;\n var segments = segmentize(pathBase);\n var constructedPath = \"/\" + segments.map(function (segment) {\n var match = paramRe.exec(segment);\n return match ? params[match[1]] : segment;\n }).join(\"/\");\n var _params$location = params.location;\n _params$location = _params$location === undefined ? {} : _params$location;\n var _params$location$sear = _params$location.search,\n search = _params$location$sear === undefined ? \"\" : _params$location$sear;\n var searchSplit = search.split(\"?\")[1] || \"\";\n constructedPath = addQuery(constructedPath, query, searchSplit);\n return constructedPath;\n};\nvar validateRedirect = function validateRedirect(from, to) {\n var filter = function filter(segment) {\n return isDynamic(segment);\n };\n var fromString = segmentize(from).filter(filter).sort().join(\"/\");\n var toString = segmentize(to).filter(filter).sort().join(\"/\");\n return fromString === toString;\n};\n\n////////////////////////////////////////////////////////////////////////////////\n// Junk\nvar paramRe = /^:(.+)/;\nvar SEGMENT_POINTS = 4;\nvar STATIC_POINTS = 3;\nvar DYNAMIC_POINTS = 2;\nvar SPLAT_PENALTY = 1;\nvar ROOT_POINTS = 1;\nvar isRootSegment = function isRootSegment(segment) {\n return segment === \"\";\n};\nvar isDynamic = function isDynamic(segment) {\n return paramRe.test(segment);\n};\nvar isSplat = function isSplat(segment) {\n return segment && segment[0] === \"*\";\n};\nvar rankRoute = function rankRoute(route, index) {\n var score = route.default ? 0 : segmentize(route.path).reduce(function (score, segment) {\n score += SEGMENT_POINTS;\n if (isRootSegment(segment)) score += ROOT_POINTS;else if (isDynamic(segment)) score += DYNAMIC_POINTS;else if (isSplat(segment)) score -= SEGMENT_POINTS + SPLAT_PENALTY;else score += STATIC_POINTS;\n return score;\n }, 0);\n return {\n route: route,\n score: score,\n index: index\n };\n};\nvar rankRoutes = function rankRoutes(routes) {\n return routes.map(rankRoute).sort(function (a, b) {\n return a.score < b.score ? 1 : a.score > b.score ? -1 : a.index - b.index;\n });\n};\nvar segmentize = function segmentize(uri) {\n return uri\n // strip starting/ending slashes\n .replace(/(^\\/+|\\/+$)/g, \"\").split(\"/\");\n};\nvar addQuery = function addQuery(pathname) {\n for (var _len = arguments.length, query = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n query[_key - 1] = arguments[_key];\n }\n query = query.filter(function (q) {\n return q && q.length > 0;\n });\n return pathname + (query && query.length > 0 ? \"?\" + query.join(\"&\") : \"\");\n};\nvar reservedNames = [\"uri\", \"path\"];\n\n/**\n * Shallow compares two objects.\n * @param {Object} obj1 The first object to compare.\n * @param {Object} obj2 The second object to compare.\n */\nvar shallowCompare = function shallowCompare(obj1, obj2) {\n var obj1Keys = Object.keys(obj1);\n return obj1Keys.length === Object.keys(obj2).length && obj1Keys.every(function (key) {\n return obj2.hasOwnProperty(key) && obj1[key] === obj2[key];\n });\n};\n\n////////////////////////////////////////////////////////////////////////////////\nexports.startsWith = startsWith;\nexports.pick = pick;\nexports.match = match;\nexports.resolve = resolve;\nexports.insertParams = insertParams;\nexports.validateRedirect = validateRedirect;\nexports.shallowCompare = shallowCompare;","'use strict';\n\nconst preserveCamelCase = string => {\n let isLastCharLower = false;\n let isLastCharUpper = false;\n let isLastLastCharUpper = false;\n for (let i = 0; i < string.length; i++) {\n const character = string[i];\n if (isLastCharLower && /[a-zA-Z]/.test(character) && character.toUpperCase() === character) {\n string = string.slice(0, i) + '-' + string.slice(i);\n isLastCharLower = false;\n isLastLastCharUpper = isLastCharUpper;\n isLastCharUpper = true;\n i++;\n } else if (isLastCharUpper && isLastLastCharUpper && /[a-zA-Z]/.test(character) && character.toLowerCase() === character) {\n string = string.slice(0, i - 1) + '-' + string.slice(i - 1);\n isLastLastCharUpper = isLastCharUpper;\n isLastCharUpper = false;\n isLastCharLower = true;\n } else {\n isLastCharLower = character.toLowerCase() === character && character.toUpperCase() !== character;\n isLastLastCharUpper = isLastCharUpper;\n isLastCharUpper = character.toUpperCase() === character && character.toLowerCase() !== character;\n }\n }\n return string;\n};\nconst camelCase = (input, options) => {\n if (!(typeof input === 'string' || Array.isArray(input))) {\n throw new TypeError('Expected the input to be `string | string[]`');\n }\n options = Object.assign({\n pascalCase: false\n }, options);\n const postProcess = x => options.pascalCase ? x.charAt(0).toUpperCase() + x.slice(1) : x;\n if (Array.isArray(input)) {\n input = input.map(x => x.trim()).filter(x => x.length).join('-');\n } else {\n input = input.trim();\n }\n if (input.length === 0) {\n return '';\n }\n if (input.length === 1) {\n return options.pascalCase ? input.toUpperCase() : input.toLowerCase();\n }\n const hasUpperCase = input !== input.toLowerCase();\n if (hasUpperCase) {\n input = preserveCamelCase(input);\n }\n input = input.replace(/^[_.\\- ]+/, '').toLowerCase().replace(/[_.\\- ]+(\\w|$)/g, (_, p1) => p1.toUpperCase()).replace(/\\d+(\\w|$)/g, m => m.toUpperCase());\n return postProcess(input);\n};\nmodule.exports = camelCase;\n// TODO: Remove this for the next major release\nmodule.exports.default = camelCase;","var _createClass = function () {\n function defineProperties(target, props) {\n for (var i = 0; i < props.length; i++) {\n var descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;\n descriptor.configurable = true;\n if (\"value\" in descriptor) descriptor.writable = true;\n Object.defineProperty(target, descriptor.key, descriptor);\n }\n }\n return function (Constructor, protoProps, staticProps) {\n if (protoProps) defineProperties(Constructor.prototype, protoProps);\n if (staticProps) defineProperties(Constructor, staticProps);\n return Constructor;\n };\n}();\nvar _templateObject = _taggedTemplateLiteral(['', ''], ['', '']);\nfunction _taggedTemplateLiteral(strings, raw) {\n return Object.freeze(Object.defineProperties(strings, {\n raw: {\n value: Object.freeze(raw)\n }\n }));\n}\nfunction _classCallCheck(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n}\n\n/**\n * @class TemplateTag\n * @classdesc Consumes a pipeline of composable transformer plugins and produces a template tag.\n */\nvar TemplateTag = function () {\n /**\n * constructs a template tag\n * @constructs TemplateTag\n * @param {...Object} [...transformers] - an array or arguments list of transformers\n * @return {Function} - a template tag\n */\n function TemplateTag() {\n var _this = this;\n for (var _len = arguments.length, transformers = Array(_len), _key = 0; _key < _len; _key++) {\n transformers[_key] = arguments[_key];\n }\n _classCallCheck(this, TemplateTag);\n this.tag = function (strings) {\n for (var _len2 = arguments.length, expressions = Array(_len2 > 1 ? _len2 - 1 : 0), _key2 = 1; _key2 < _len2; _key2++) {\n expressions[_key2 - 1] = arguments[_key2];\n }\n if (typeof strings === 'function') {\n // if the first argument passed is a function, assume it is a template tag and return\n // an intermediary tag that processes the template using the aforementioned tag, passing the\n // result to our tag\n return _this.interimTag.bind(_this, strings);\n }\n if (typeof strings === 'string') {\n // if the first argument passed is a string, just transform it\n return _this.transformEndResult(strings);\n }\n\n // else, return a transformed end result of processing the template with our tag\n strings = strings.map(_this.transformString.bind(_this));\n return _this.transformEndResult(strings.reduce(_this.processSubstitutions.bind(_this, expressions)));\n };\n\n // if first argument is an array, extrude it as a list of transformers\n if (transformers.length > 0 && Array.isArray(transformers[0])) {\n transformers = transformers[0];\n }\n\n // if any transformers are functions, this means they are not initiated - automatically initiate them\n this.transformers = transformers.map(function (transformer) {\n return typeof transformer === 'function' ? transformer() : transformer;\n });\n\n // return an ES2015 template tag\n return this.tag;\n }\n\n /**\n * Applies all transformers to a template literal tagged with this method.\n * If a function is passed as the first argument, assumes the function is a template tag\n * and applies it to the template, returning a template tag.\n * @param {(Function|String|Array)} strings - Either a template tag or an array containing template strings separated by identifier\n * @param {...*} ...expressions - Optional list of substitution values.\n * @return {(String|Function)} - Either an intermediary tag function or the results of processing the template.\n */\n\n _createClass(TemplateTag, [{\n key: 'interimTag',\n /**\n * An intermediary template tag that receives a template tag and passes the result of calling the template with the received\n * template tag to our own template tag.\n * @param {Function} nextTag - the received template tag\n * @param {Array} template - the template to process\n * @param {...*} ...substitutions - `substitutions` is an array of all substitutions in the template\n * @return {*} - the final processed value\n */\n value: function interimTag(previousTag, template) {\n for (var _len3 = arguments.length, substitutions = Array(_len3 > 2 ? _len3 - 2 : 0), _key3 = 2; _key3 < _len3; _key3++) {\n substitutions[_key3 - 2] = arguments[_key3];\n }\n return this.tag(_templateObject, previousTag.apply(undefined, [template].concat(substitutions)));\n }\n\n /**\n * Performs bulk processing on the tagged template, transforming each substitution and then\n * concatenating the resulting values into a string.\n * @param {Array<*>} substitutions - an array of all remaining substitutions present in this template\n * @param {String} resultSoFar - this iteration's result string so far\n * @param {String} remainingPart - the template chunk after the current substitution\n * @return {String} - the result of joining this iteration's processed substitution with the result\n */\n }, {\n key: 'processSubstitutions',\n value: function processSubstitutions(substitutions, resultSoFar, remainingPart) {\n var substitution = this.transformSubstitution(substitutions.shift(), resultSoFar);\n return ''.concat(resultSoFar, substitution, remainingPart);\n }\n\n /**\n * Iterate through each transformer, applying the transformer's `onString` method to the template\n * strings before all substitutions are processed.\n * @param {String} str - The input string\n * @return {String} - The final results of processing each transformer\n */\n }, {\n key: 'transformString',\n value: function transformString(str) {\n var cb = function cb(res, transform) {\n return transform.onString ? transform.onString(res) : res;\n };\n return this.transformers.reduce(cb, str);\n }\n\n /**\n * When a substitution is encountered, iterates through each transformer and applies the transformer's\n * `onSubstitution` method to the substitution.\n * @param {*} substitution - The current substitution\n * @param {String} resultSoFar - The result up to and excluding this substitution.\n * @return {*} - The final result of applying all substitution transformations.\n */\n }, {\n key: 'transformSubstitution',\n value: function transformSubstitution(substitution, resultSoFar) {\n var cb = function cb(res, transform) {\n return transform.onSubstitution ? transform.onSubstitution(res, resultSoFar) : res;\n };\n return this.transformers.reduce(cb, substitution);\n }\n\n /**\n * Iterates through each transformer, applying the transformer's `onEndResult` method to the\n * template literal after all substitutions have finished processing.\n * @param {String} endResult - The processed template, just before it is returned from the tag\n * @return {String} - The final results of processing each transformer\n */\n }, {\n key: 'transformEndResult',\n value: function transformEndResult(endResult) {\n var cb = function cb(res, transform) {\n return transform.onEndResult ? transform.onEndResult(res) : res;\n };\n return this.transformers.reduce(cb, endResult);\n }\n }]);\n return TemplateTag;\n}();\nexport default TemplateTag;","var defaults = {\n separator: '',\n conjunction: '',\n serial: false\n};\n\n/**\n * Converts an array substitution to a string containing a list\n * @param {String} [opts.separator = ''] - the character that separates each item\n * @param {String} [opts.conjunction = ''] - replace the last separator with this\n * @param {Boolean} [opts.serial = false] - include the separator before the conjunction? (Oxford comma use-case)\n *\n * @return {Object} - a TemplateTag transformer\n */\nvar inlineArrayTransformer = function inlineArrayTransformer() {\n var opts = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : defaults;\n return {\n onSubstitution: function onSubstitution(substitution, resultSoFar) {\n // only operate on arrays\n if (Array.isArray(substitution)) {\n var arrayLength = substitution.length;\n var separator = opts.separator;\n var conjunction = opts.conjunction;\n var serial = opts.serial;\n // join each item in the array into a string where each item is separated by separator\n // be sure to maintain indentation\n var indent = resultSoFar.match(/(\\n?[^\\S\\n]+)$/);\n if (indent) {\n substitution = substitution.join(separator + indent[1]);\n } else {\n substitution = substitution.join(separator + ' ');\n }\n // if conjunction is set, replace the last separator with conjunction, but only if there is more than one substitution\n if (conjunction && arrayLength > 1) {\n var separatorIndex = substitution.lastIndexOf(separator);\n substitution = substitution.slice(0, separatorIndex) + (serial ? separator : '') + ' ' + conjunction + substitution.slice(separatorIndex + 1);\n }\n }\n return substitution;\n }\n };\n};\nexport default inlineArrayTransformer;","function _toConsumableArray(arr) {\n if (Array.isArray(arr)) {\n for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) {\n arr2[i] = arr[i];\n }\n return arr2;\n } else {\n return Array.from(arr);\n }\n}\n\n/**\n * strips indentation from a template literal\n * @param {String} type = 'initial' - whether to remove all indentation or just leading indentation. can be 'all' or 'initial'\n * @return {Object} - a TemplateTag transformer\n */\nvar stripIndentTransformer = function stripIndentTransformer() {\n var type = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'initial';\n return {\n onEndResult: function onEndResult(endResult) {\n if (type === 'initial') {\n // remove the shortest leading indentation from each line\n var match = endResult.match(/^[^\\S\\n]*(?=\\S)/gm);\n var indent = match && Math.min.apply(Math, _toConsumableArray(match.map(function (el) {\n return el.length;\n })));\n if (indent) {\n var regexp = new RegExp('^.{' + indent + '}', 'gm');\n return endResult.replace(regexp, '');\n }\n return endResult;\n }\n if (type === 'all') {\n // remove all indentation from each line\n return endResult.replace(/^[^\\S\\n]+/gm, '');\n }\n throw new Error('Unknown type: ' + type);\n }\n };\n};\nexport default stripIndentTransformer;","/**\n * TemplateTag transformer that trims whitespace on the end result of a tagged template\n * @param {String} side = '' - The side of the string to trim. Can be 'start' or 'end' (alternatively 'left' or 'right')\n * @return {Object} - a TemplateTag transformer\n */\nvar trimResultTransformer = function trimResultTransformer() {\n var side = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';\n return {\n onEndResult: function onEndResult(endResult) {\n if (side === '') {\n return endResult.trim();\n }\n side = side.toLowerCase();\n if (side === 'start' || side === 'left') {\n return endResult.replace(/^\\s*/, '');\n }\n if (side === 'end' || side === 'right') {\n return endResult.replace(/\\s*$/, '');\n }\n throw new Error('Side not supported: ' + side);\n }\n };\n};\nexport default trimResultTransformer;","var splitStringTransformer = function splitStringTransformer(splitBy) {\n return {\n onSubstitution: function onSubstitution(substitution, resultSoFar) {\n if (splitBy != null && typeof splitBy === 'string') {\n if (typeof substitution === 'string' && substitution.includes(splitBy)) {\n substitution = substitution.split(splitBy);\n }\n } else {\n throw new Error('You need to specify a string character to split by.');\n }\n return substitution;\n }\n };\n};\nexport default splitStringTransformer;","import TemplateTag from '../TemplateTag';\nimport stripIndentTransformer from '../stripIndentTransformer';\nimport inlineArrayTransformer from '../inlineArrayTransformer';\nimport trimResultTransformer from '../trimResultTransformer';\nvar commaLists = new TemplateTag(inlineArrayTransformer({\n separator: ','\n}), stripIndentTransformer, trimResultTransformer);\nexport default commaLists;","import TemplateTag from '../TemplateTag';\nimport stripIndentTransformer from '../stripIndentTransformer';\nimport inlineArrayTransformer from '../inlineArrayTransformer';\nimport trimResultTransformer from '../trimResultTransformer';\nvar commaListsAnd = new TemplateTag(inlineArrayTransformer({\n separator: ',',\n conjunction: 'and'\n}), stripIndentTransformer, trimResultTransformer);\nexport default commaListsAnd;","import TemplateTag from '../TemplateTag';\nimport stripIndentTransformer from '../stripIndentTransformer';\nimport inlineArrayTransformer from '../inlineArrayTransformer';\nimport trimResultTransformer from '../trimResultTransformer';\nvar commaListsOr = new TemplateTag(inlineArrayTransformer({\n separator: ',',\n conjunction: 'or'\n}), stripIndentTransformer, trimResultTransformer);\nexport default commaListsOr;","var isValidValue = function isValidValue(x) {\n return x != null && !Number.isNaN(x) && typeof x !== 'boolean';\n};\nvar removeNonPrintingValuesTransformer = function removeNonPrintingValuesTransformer() {\n return {\n onSubstitution: function onSubstitution(substitution) {\n if (Array.isArray(substitution)) {\n return substitution.filter(isValidValue);\n }\n if (isValidValue(substitution)) {\n return substitution;\n }\n return '';\n }\n };\n};\nexport default removeNonPrintingValuesTransformer;","var replaceSubstitutionTransformer = function replaceSubstitutionTransformer(replaceWhat, replaceWith) {\n return {\n onSubstitution: function onSubstitution(substitution, resultSoFar) {\n if (replaceWhat == null || replaceWith == null) {\n throw new Error('replaceSubstitutionTransformer requires at least 2 arguments.');\n }\n\n // Do not touch if null or undefined\n if (substitution == null) {\n return substitution;\n } else {\n return substitution.toString().replace(replaceWhat, replaceWith);\n }\n }\n };\n};\nexport default replaceSubstitutionTransformer;","import TemplateTag from '../TemplateTag';\nimport stripIndentTransformer from '../stripIndentTransformer';\nimport inlineArrayTransformer from '../inlineArrayTransformer';\nimport trimResultTransformer from '../trimResultTransformer';\nimport splitStringTransformer from '../splitStringTransformer';\nimport removeNonPrintingValuesTransformer from '../removeNonPrintingValuesTransformer';\nvar html = new TemplateTag(splitStringTransformer('\\n'), removeNonPrintingValuesTransformer, inlineArrayTransformer, stripIndentTransformer, trimResultTransformer);\nexport default html;","/**\n * Replaces tabs, newlines and spaces with the chosen value when they occur in sequences\n * @param {(String|RegExp)} replaceWhat - the value or pattern that should be replaced\n * @param {*} replaceWith - the replacement value\n * @return {Object} - a TemplateTag transformer\n */\nvar replaceResultTransformer = function replaceResultTransformer(replaceWhat, replaceWith) {\n return {\n onEndResult: function onEndResult(endResult) {\n if (replaceWhat == null || replaceWith == null) {\n throw new Error('replaceResultTransformer requires at least 2 arguments.');\n }\n return endResult.replace(replaceWhat, replaceWith);\n }\n };\n};\nexport default replaceResultTransformer;","import TemplateTag from '../TemplateTag';\nimport stripIndentTransformer from '../stripIndentTransformer';\nimport inlineArrayTransformer from '../inlineArrayTransformer';\nimport trimResultTransformer from '../trimResultTransformer';\nimport splitStringTransformer from '../splitStringTransformer';\nimport replaceSubstitutionTransformer from '../replaceSubstitutionTransformer';\nvar safeHtml = new TemplateTag(splitStringTransformer('\\n'), inlineArrayTransformer, stripIndentTransformer, trimResultTransformer, replaceSubstitutionTransformer(/&/g, '&'), replaceSubstitutionTransformer(//g, '>'), replaceSubstitutionTransformer(/\"/g, '"'), replaceSubstitutionTransformer(/'/g, '''), replaceSubstitutionTransformer(/`/g, '`'));\nexport default safeHtml;","import TemplateTag from '../TemplateTag';\nimport trimResultTransformer from '../trimResultTransformer';\nimport replaceResultTransformer from '../replaceResultTransformer';\nvar oneLine = new TemplateTag(replaceResultTransformer(/(?:\\n(?:\\s*))+/g, ' '), trimResultTransformer);\nexport default oneLine;","import TemplateTag from '../TemplateTag';\nimport trimResultTransformer from '../trimResultTransformer';\nimport replaceResultTransformer from '../replaceResultTransformer';\nvar oneLineTrim = new TemplateTag(replaceResultTransformer(/(?:\\n\\s*)/g, ''), trimResultTransformer);\nexport default oneLineTrim;","import TemplateTag from '../TemplateTag';\nimport inlineArrayTransformer from '../inlineArrayTransformer';\nimport trimResultTransformer from '../trimResultTransformer';\nimport replaceResultTransformer from '../replaceResultTransformer';\nvar oneLineCommaLists = new TemplateTag(inlineArrayTransformer({\n separator: ','\n}), replaceResultTransformer(/(?:\\s+)/g, ' '), trimResultTransformer);\nexport default oneLineCommaLists;","import TemplateTag from '../TemplateTag';\nimport inlineArrayTransformer from '../inlineArrayTransformer';\nimport trimResultTransformer from '../trimResultTransformer';\nimport replaceResultTransformer from '../replaceResultTransformer';\nvar oneLineCommaListsOr = new TemplateTag(inlineArrayTransformer({\n separator: ',',\n conjunction: 'or'\n}), replaceResultTransformer(/(?:\\s+)/g, ' '), trimResultTransformer);\nexport default oneLineCommaListsOr;","import TemplateTag from '../TemplateTag';\nimport inlineArrayTransformer from '../inlineArrayTransformer';\nimport trimResultTransformer from '../trimResultTransformer';\nimport replaceResultTransformer from '../replaceResultTransformer';\nvar oneLineCommaListsAnd = new TemplateTag(inlineArrayTransformer({\n separator: ',',\n conjunction: 'and'\n}), replaceResultTransformer(/(?:\\s+)/g, ' '), trimResultTransformer);\nexport default oneLineCommaListsAnd;","import TemplateTag from '../TemplateTag';\nimport stripIndentTransformer from '../stripIndentTransformer';\nimport inlineArrayTransformer from '../inlineArrayTransformer';\nimport trimResultTransformer from '../trimResultTransformer';\nvar inlineLists = new TemplateTag(inlineArrayTransformer, stripIndentTransformer, trimResultTransformer);\nexport default inlineLists;","import TemplateTag from '../TemplateTag';\nimport inlineArrayTransformer from '../inlineArrayTransformer';\nimport trimResultTransformer from '../trimResultTransformer';\nimport replaceResultTransformer from '../replaceResultTransformer';\nvar oneLineInlineLists = new TemplateTag(inlineArrayTransformer, replaceResultTransformer(/(?:\\s+)/g, ' '), trimResultTransformer);\nexport default oneLineInlineLists;","import TemplateTag from '../TemplateTag';\nimport stripIndentTransformer from '../stripIndentTransformer';\nimport trimResultTransformer from '../trimResultTransformer';\nvar stripIndent = new TemplateTag(stripIndentTransformer, trimResultTransformer);\nexport default stripIndent;","import TemplateTag from '../TemplateTag';\nimport stripIndentTransformer from '../stripIndentTransformer';\nimport trimResultTransformer from '../trimResultTransformer';\nvar stripIndents = new TemplateTag(stripIndentTransformer('all'), trimResultTransformer);\nexport default stripIndents;","\"use strict\";\n\nmodule.exports = Object.assign;","var moment = module.exports = require(\"./moment-timezone\");\nmoment.tz.load(require('./data/packed/latest.json'));","//! moment-timezone.js\n//! version : 0.5.45\n//! Copyright (c) JS Foundation and other contributors\n//! license : MIT\n//! github.com/moment/moment-timezone\n\n(function (root, factory) {\n \"use strict\";\n\n /*global define*/\n if (typeof module === 'object' && module.exports) {\n module.exports = factory(require('moment')); // Node\n } else if (typeof define === 'function' && define.amd) {\n define(['moment'], factory); // AMD\n } else {\n factory(root.moment); // Browser\n }\n})(this, function (moment) {\n \"use strict\";\n\n // Resolves es6 module loading issue\n if (moment.version === undefined && moment.default) {\n moment = moment.default;\n }\n\n // Do not load moment-timezone a second time.\n // if (moment.tz !== undefined) {\n // \tlogError('Moment Timezone ' + moment.tz.version + ' was already loaded ' + (moment.tz.dataVersion ? 'with data from ' : 'without any data') + moment.tz.dataVersion);\n // \treturn moment;\n // }\n\n var VERSION = \"0.5.45\",\n zones = {},\n links = {},\n countries = {},\n names = {},\n guesses = {},\n cachedGuess;\n if (!moment || typeof moment.version !== 'string') {\n logError('Moment Timezone requires Moment.js. See https://momentjs.com/timezone/docs/#/use-it/browser/');\n }\n var momentVersion = moment.version.split('.'),\n major = +momentVersion[0],\n minor = +momentVersion[1];\n\n // Moment.js version check\n if (major < 2 || major === 2 && minor < 6) {\n logError('Moment Timezone requires Moment.js >= 2.6.0. You are using Moment.js ' + moment.version + '. See momentjs.com');\n }\n\n /************************************\n \tUnpacking\n ************************************/\n\n function charCodeToInt(charCode) {\n if (charCode > 96) {\n return charCode - 87;\n } else if (charCode > 64) {\n return charCode - 29;\n }\n return charCode - 48;\n }\n function unpackBase60(string) {\n var i = 0,\n parts = string.split('.'),\n whole = parts[0],\n fractional = parts[1] || '',\n multiplier = 1,\n num,\n out = 0,\n sign = 1;\n\n // handle negative numbers\n if (string.charCodeAt(0) === 45) {\n i = 1;\n sign = -1;\n }\n\n // handle digits before the decimal\n for (i; i < whole.length; i++) {\n num = charCodeToInt(whole.charCodeAt(i));\n out = 60 * out + num;\n }\n\n // handle digits after the decimal\n for (i = 0; i < fractional.length; i++) {\n multiplier = multiplier / 60;\n num = charCodeToInt(fractional.charCodeAt(i));\n out += num * multiplier;\n }\n return out * sign;\n }\n function arrayToInt(array) {\n for (var i = 0; i < array.length; i++) {\n array[i] = unpackBase60(array[i]);\n }\n }\n function intToUntil(array, length) {\n for (var i = 0; i < length; i++) {\n array[i] = Math.round((array[i - 1] || 0) + array[i] * 60000); // minutes to milliseconds\n }\n array[length - 1] = Infinity;\n }\n function mapIndices(source, indices) {\n var out = [],\n i;\n for (i = 0; i < indices.length; i++) {\n out[i] = source[indices[i]];\n }\n return out;\n }\n function unpack(string) {\n var data = string.split('|'),\n offsets = data[2].split(' '),\n indices = data[3].split(''),\n untils = data[4].split(' ');\n arrayToInt(offsets);\n arrayToInt(indices);\n arrayToInt(untils);\n intToUntil(untils, indices.length);\n return {\n name: data[0],\n abbrs: mapIndices(data[1].split(' '), indices),\n offsets: mapIndices(offsets, indices),\n untils: untils,\n population: data[5] | 0\n };\n }\n\n /************************************\n \tZone object\n ************************************/\n\n function Zone(packedString) {\n if (packedString) {\n this._set(unpack(packedString));\n }\n }\n function closest(num, arr) {\n var len = arr.length;\n if (num < arr[0]) {\n return 0;\n } else if (len > 1 && arr[len - 1] === Infinity && num >= arr[len - 2]) {\n return len - 1;\n } else if (num >= arr[len - 1]) {\n return -1;\n }\n var mid;\n var lo = 0;\n var hi = len - 1;\n while (hi - lo > 1) {\n mid = Math.floor((lo + hi) / 2);\n if (arr[mid] <= num) {\n lo = mid;\n } else {\n hi = mid;\n }\n }\n return hi;\n }\n Zone.prototype = {\n _set: function (unpacked) {\n this.name = unpacked.name;\n this.abbrs = unpacked.abbrs;\n this.untils = unpacked.untils;\n this.offsets = unpacked.offsets;\n this.population = unpacked.population;\n },\n _index: function (timestamp) {\n var target = +timestamp,\n untils = this.untils,\n i;\n i = closest(target, untils);\n if (i >= 0) {\n return i;\n }\n },\n countries: function () {\n var zone_name = this.name;\n return Object.keys(countries).filter(function (country_code) {\n return countries[country_code].zones.indexOf(zone_name) !== -1;\n });\n },\n parse: function (timestamp) {\n var target = +timestamp,\n offsets = this.offsets,\n untils = this.untils,\n max = untils.length - 1,\n offset,\n offsetNext,\n offsetPrev,\n i;\n for (i = 0; i < max; i++) {\n offset = offsets[i];\n offsetNext = offsets[i + 1];\n offsetPrev = offsets[i ? i - 1 : i];\n if (offset < offsetNext && tz.moveAmbiguousForward) {\n offset = offsetNext;\n } else if (offset > offsetPrev && tz.moveInvalidForward) {\n offset = offsetPrev;\n }\n if (target < untils[i] - offset * 60000) {\n return offsets[i];\n }\n }\n return offsets[max];\n },\n abbr: function (mom) {\n return this.abbrs[this._index(mom)];\n },\n offset: function (mom) {\n logError(\"zone.offset has been deprecated in favor of zone.utcOffset\");\n return this.offsets[this._index(mom)];\n },\n utcOffset: function (mom) {\n return this.offsets[this._index(mom)];\n }\n };\n\n /************************************\n \tCountry object\n ************************************/\n\n function Country(country_name, zone_names) {\n this.name = country_name;\n this.zones = zone_names;\n }\n\n /************************************\n \tCurrent Timezone\n ************************************/\n\n function OffsetAt(at) {\n var timeString = at.toTimeString();\n var abbr = timeString.match(/\\([a-z ]+\\)/i);\n if (abbr && abbr[0]) {\n // 17:56:31 GMT-0600 (CST)\n // 17:56:31 GMT-0600 (Central Standard Time)\n abbr = abbr[0].match(/[A-Z]/g);\n abbr = abbr ? abbr.join('') : undefined;\n } else {\n // 17:56:31 CST\n // 17:56:31 GMT+0800 (台北標準時間)\n abbr = timeString.match(/[A-Z]{3,5}/g);\n abbr = abbr ? abbr[0] : undefined;\n }\n if (abbr === 'GMT') {\n abbr = undefined;\n }\n this.at = +at;\n this.abbr = abbr;\n this.offset = at.getTimezoneOffset();\n }\n function ZoneScore(zone) {\n this.zone = zone;\n this.offsetScore = 0;\n this.abbrScore = 0;\n }\n ZoneScore.prototype.scoreOffsetAt = function (offsetAt) {\n this.offsetScore += Math.abs(this.zone.utcOffset(offsetAt.at) - offsetAt.offset);\n if (this.zone.abbr(offsetAt.at).replace(/[^A-Z]/g, '') !== offsetAt.abbr) {\n this.abbrScore++;\n }\n };\n function findChange(low, high) {\n var mid, diff;\n while (diff = ((high.at - low.at) / 12e4 | 0) * 6e4) {\n mid = new OffsetAt(new Date(low.at + diff));\n if (mid.offset === low.offset) {\n low = mid;\n } else {\n high = mid;\n }\n }\n return low;\n }\n function userOffsets() {\n var startYear = new Date().getFullYear() - 2,\n last = new OffsetAt(new Date(startYear, 0, 1)),\n lastOffset = last.offset,\n offsets = [last],\n change,\n next,\n nextOffset,\n i;\n for (i = 1; i < 48; i++) {\n nextOffset = new Date(startYear, i, 1).getTimezoneOffset();\n if (nextOffset !== lastOffset) {\n // Create OffsetAt here to avoid unnecessary abbr parsing before checking offsets\n next = new OffsetAt(new Date(startYear, i, 1));\n change = findChange(last, next);\n offsets.push(change);\n offsets.push(new OffsetAt(new Date(change.at + 6e4)));\n last = next;\n lastOffset = nextOffset;\n }\n }\n for (i = 0; i < 4; i++) {\n offsets.push(new OffsetAt(new Date(startYear + i, 0, 1)));\n offsets.push(new OffsetAt(new Date(startYear + i, 6, 1)));\n }\n return offsets;\n }\n function sortZoneScores(a, b) {\n if (a.offsetScore !== b.offsetScore) {\n return a.offsetScore - b.offsetScore;\n }\n if (a.abbrScore !== b.abbrScore) {\n return a.abbrScore - b.abbrScore;\n }\n if (a.zone.population !== b.zone.population) {\n return b.zone.population - a.zone.population;\n }\n return b.zone.name.localeCompare(a.zone.name);\n }\n function addToGuesses(name, offsets) {\n var i, offset;\n arrayToInt(offsets);\n for (i = 0; i < offsets.length; i++) {\n offset = offsets[i];\n guesses[offset] = guesses[offset] || {};\n guesses[offset][name] = true;\n }\n }\n function guessesForUserOffsets(offsets) {\n var offsetsLength = offsets.length,\n filteredGuesses = {},\n out = [],\n checkedOffsets = {},\n i,\n j,\n offset,\n guessesOffset;\n for (i = 0; i < offsetsLength; i++) {\n offset = offsets[i].offset;\n if (checkedOffsets.hasOwnProperty(offset)) {\n continue;\n }\n guessesOffset = guesses[offset] || {};\n for (j in guessesOffset) {\n if (guessesOffset.hasOwnProperty(j)) {\n filteredGuesses[j] = true;\n }\n }\n checkedOffsets[offset] = true;\n }\n for (i in filteredGuesses) {\n if (filteredGuesses.hasOwnProperty(i)) {\n out.push(names[i]);\n }\n }\n return out;\n }\n function rebuildGuess() {\n // use Intl API when available and returning valid time zone\n try {\n var intlName = Intl.DateTimeFormat().resolvedOptions().timeZone;\n if (intlName && intlName.length > 3) {\n var name = names[normalizeName(intlName)];\n if (name) {\n return name;\n }\n logError(\"Moment Timezone found \" + intlName + \" from the Intl api, but did not have that data loaded.\");\n }\n } catch (e) {\n // Intl unavailable, fall back to manual guessing.\n }\n var offsets = userOffsets(),\n offsetsLength = offsets.length,\n guesses = guessesForUserOffsets(offsets),\n zoneScores = [],\n zoneScore,\n i,\n j;\n for (i = 0; i < guesses.length; i++) {\n zoneScore = new ZoneScore(getZone(guesses[i]), offsetsLength);\n for (j = 0; j < offsetsLength; j++) {\n zoneScore.scoreOffsetAt(offsets[j]);\n }\n zoneScores.push(zoneScore);\n }\n zoneScores.sort(sortZoneScores);\n return zoneScores.length > 0 ? zoneScores[0].zone.name : undefined;\n }\n function guess(ignoreCache) {\n if (!cachedGuess || ignoreCache) {\n cachedGuess = rebuildGuess();\n }\n return cachedGuess;\n }\n\n /************************************\n \tGlobal Methods\n ************************************/\n\n function normalizeName(name) {\n return (name || '').toLowerCase().replace(/\\//g, '_');\n }\n function addZone(packed) {\n var i, name, split, normalized;\n if (typeof packed === \"string\") {\n packed = [packed];\n }\n for (i = 0; i < packed.length; i++) {\n split = packed[i].split('|');\n name = split[0];\n normalized = normalizeName(name);\n zones[normalized] = packed[i];\n names[normalized] = name;\n addToGuesses(normalized, split[2].split(' '));\n }\n }\n function getZone(name, caller) {\n name = normalizeName(name);\n var zone = zones[name];\n var link;\n if (zone instanceof Zone) {\n return zone;\n }\n if (typeof zone === 'string') {\n zone = new Zone(zone);\n zones[name] = zone;\n return zone;\n }\n\n // Pass getZone to prevent recursion more than 1 level deep\n if (links[name] && caller !== getZone && (link = getZone(links[name], getZone))) {\n zone = zones[name] = new Zone();\n zone._set(link);\n zone.name = names[name];\n return zone;\n }\n return null;\n }\n function getNames() {\n var i,\n out = [];\n for (i in names) {\n if (names.hasOwnProperty(i) && (zones[i] || zones[links[i]]) && names[i]) {\n out.push(names[i]);\n }\n }\n return out.sort();\n }\n function getCountryNames() {\n return Object.keys(countries);\n }\n function addLink(aliases) {\n var i, alias, normal0, normal1;\n if (typeof aliases === \"string\") {\n aliases = [aliases];\n }\n for (i = 0; i < aliases.length; i++) {\n alias = aliases[i].split('|');\n normal0 = normalizeName(alias[0]);\n normal1 = normalizeName(alias[1]);\n links[normal0] = normal1;\n names[normal0] = alias[0];\n links[normal1] = normal0;\n names[normal1] = alias[1];\n }\n }\n function addCountries(data) {\n var i, country_code, country_zones, split;\n if (!data || !data.length) return;\n for (i = 0; i < data.length; i++) {\n split = data[i].split('|');\n country_code = split[0].toUpperCase();\n country_zones = split[1].split(' ');\n countries[country_code] = new Country(country_code, country_zones);\n }\n }\n function getCountry(name) {\n name = name.toUpperCase();\n return countries[name] || null;\n }\n function zonesForCountry(country, with_offset) {\n country = getCountry(country);\n if (!country) return null;\n var zones = country.zones.sort();\n if (with_offset) {\n return zones.map(function (zone_name) {\n var zone = getZone(zone_name);\n return {\n name: zone_name,\n offset: zone.utcOffset(new Date())\n };\n });\n }\n return zones;\n }\n function loadData(data) {\n addZone(data.zones);\n addLink(data.links);\n addCountries(data.countries);\n tz.dataVersion = data.version;\n }\n function zoneExists(name) {\n if (!zoneExists.didShowError) {\n zoneExists.didShowError = true;\n logError(\"moment.tz.zoneExists('\" + name + \"') has been deprecated in favor of !moment.tz.zone('\" + name + \"')\");\n }\n return !!getZone(name);\n }\n function needsOffset(m) {\n var isUnixTimestamp = m._f === 'X' || m._f === 'x';\n return !!(m._a && m._tzm === undefined && !isUnixTimestamp);\n }\n function logError(message) {\n if (typeof console !== 'undefined' && typeof console.error === 'function') {\n console.error(message);\n }\n }\n\n /************************************\n \tmoment.tz namespace\n ************************************/\n\n function tz(input) {\n var args = Array.prototype.slice.call(arguments, 0, -1),\n name = arguments[arguments.length - 1],\n out = moment.utc.apply(null, args),\n zone;\n if (!moment.isMoment(input) && needsOffset(out) && (zone = getZone(name))) {\n out.add(zone.parse(out), 'minutes');\n }\n out.tz(name);\n return out;\n }\n tz.version = VERSION;\n tz.dataVersion = '';\n tz._zones = zones;\n tz._links = links;\n tz._names = names;\n tz._countries = countries;\n tz.add = addZone;\n tz.link = addLink;\n tz.load = loadData;\n tz.zone = getZone;\n tz.zoneExists = zoneExists; // deprecated in 0.1.0\n tz.guess = guess;\n tz.names = getNames;\n tz.Zone = Zone;\n tz.unpack = unpack;\n tz.unpackBase60 = unpackBase60;\n tz.needsOffset = needsOffset;\n tz.moveInvalidForward = true;\n tz.moveAmbiguousForward = false;\n tz.countries = getCountryNames;\n tz.zonesForCountry = zonesForCountry;\n\n /************************************\n \tInterface with Moment.js\n ************************************/\n\n var fn = moment.fn;\n moment.tz = tz;\n moment.defaultZone = null;\n moment.updateOffset = function (mom, keepTime) {\n var zone = moment.defaultZone,\n offset;\n if (mom._z === undefined) {\n if (zone && needsOffset(mom) && !mom._isUTC && mom.isValid()) {\n mom._d = moment.utc(mom._a)._d;\n mom.utc().add(zone.parse(mom), 'minutes');\n }\n mom._z = zone;\n }\n if (mom._z) {\n offset = mom._z.utcOffset(mom);\n if (Math.abs(offset) < 16) {\n offset = offset / 60;\n }\n if (mom.utcOffset !== undefined) {\n var z = mom._z;\n mom.utcOffset(-offset, keepTime);\n mom._z = z;\n } else {\n mom.zone(offset, keepTime);\n }\n }\n };\n fn.tz = function (name, keepTime) {\n if (name) {\n if (typeof name !== 'string') {\n throw new Error('Time zone name must be a string, got ' + name + ' [' + typeof name + ']');\n }\n this._z = getZone(name);\n if (this._z) {\n moment.updateOffset(this, keepTime);\n } else {\n logError(\"Moment Timezone has no data for \" + name + \". See http://momentjs.com/timezone/docs/#/data-loading/.\");\n }\n return this;\n }\n if (this._z) {\n return this._z.name;\n }\n };\n function abbrWrap(old) {\n return function () {\n if (this._z) {\n return this._z.abbr(this);\n }\n return old.call(this);\n };\n }\n function resetZoneWrap(old) {\n return function () {\n this._z = null;\n return old.apply(this, arguments);\n };\n }\n function resetZoneWrap2(old) {\n return function () {\n if (arguments.length > 0) this._z = null;\n return old.apply(this, arguments);\n };\n }\n fn.zoneName = abbrWrap(fn.zoneName);\n fn.zoneAbbr = abbrWrap(fn.zoneAbbr);\n fn.utc = resetZoneWrap(fn.utc);\n fn.local = resetZoneWrap(fn.local);\n fn.utcOffset = resetZoneWrap2(fn.utcOffset);\n moment.tz.setDefault = function (name) {\n if (major < 2 || major === 2 && minor < 9) {\n logError('Moment Timezone setDefault() requires Moment.js >= 2.9.0. You are using Moment.js ' + moment.version + '.');\n }\n moment.defaultZone = name ? getZone(name) : null;\n return moment;\n };\n\n // Cloning a moment should include the _z property.\n var momentProperties = moment.momentProperties;\n if (Object.prototype.toString.call(momentProperties) === '[object Array]') {\n // moment 2.8.1+\n momentProperties.push('_z');\n momentProperties.push('_a');\n } else if (momentProperties) {\n // moment 2.7.0\n momentProperties._z = null;\n }\n\n // INJECT DATA\n\n return moment;\n});","//! moment.js\n//! version : 2.30.1\n//! authors : Tim Wood, Iskren Chernev, Moment.js contributors\n//! license : MIT\n//! momentjs.com\n\n;\n(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() : typeof define === 'function' && define.amd ? define(factory) : global.moment = factory();\n})(this, function () {\n 'use strict';\n\n var hookCallback;\n function hooks() {\n return hookCallback.apply(null, arguments);\n }\n\n // This is done to register the method called with moment()\n // without creating circular dependencies.\n function setHookCallback(callback) {\n hookCallback = callback;\n }\n function isArray(input) {\n return input instanceof Array || Object.prototype.toString.call(input) === '[object Array]';\n }\n function isObject(input) {\n // IE8 will treat undefined and null as object if it wasn't for\n // input != null\n return input != null && Object.prototype.toString.call(input) === '[object Object]';\n }\n function hasOwnProp(a, b) {\n return Object.prototype.hasOwnProperty.call(a, b);\n }\n function isObjectEmpty(obj) {\n if (Object.getOwnPropertyNames) {\n return Object.getOwnPropertyNames(obj).length === 0;\n } else {\n var k;\n for (k in obj) {\n if (hasOwnProp(obj, k)) {\n return false;\n }\n }\n return true;\n }\n }\n function isUndefined(input) {\n return input === void 0;\n }\n function isNumber(input) {\n return typeof input === 'number' || Object.prototype.toString.call(input) === '[object Number]';\n }\n function isDate(input) {\n return input instanceof Date || Object.prototype.toString.call(input) === '[object Date]';\n }\n function map(arr, fn) {\n var res = [],\n i,\n arrLen = arr.length;\n for (i = 0; i < arrLen; ++i) {\n res.push(fn(arr[i], i));\n }\n return res;\n }\n function extend(a, b) {\n for (var i in b) {\n if (hasOwnProp(b, i)) {\n a[i] = b[i];\n }\n }\n if (hasOwnProp(b, 'toString')) {\n a.toString = b.toString;\n }\n if (hasOwnProp(b, 'valueOf')) {\n a.valueOf = b.valueOf;\n }\n return a;\n }\n function createUTC(input, format, locale, strict) {\n return createLocalOrUTC(input, format, locale, strict, true).utc();\n }\n function defaultParsingFlags() {\n // We need to deep clone this object.\n return {\n empty: false,\n unusedTokens: [],\n unusedInput: [],\n overflow: -2,\n charsLeftOver: 0,\n nullInput: false,\n invalidEra: null,\n invalidMonth: null,\n invalidFormat: false,\n userInvalidated: false,\n iso: false,\n parsedDateParts: [],\n era: null,\n meridiem: null,\n rfc2822: false,\n weekdayMismatch: false\n };\n }\n function getParsingFlags(m) {\n if (m._pf == null) {\n m._pf = defaultParsingFlags();\n }\n return m._pf;\n }\n var some;\n if (Array.prototype.some) {\n some = Array.prototype.some;\n } else {\n some = function (fun) {\n var t = Object(this),\n len = t.length >>> 0,\n i;\n for (i = 0; i < len; i++) {\n if (i in t && fun.call(this, t[i], i, t)) {\n return true;\n }\n }\n return false;\n };\n }\n function isValid(m) {\n var flags = null,\n parsedParts = false,\n isNowValid = m._d && !isNaN(m._d.getTime());\n if (isNowValid) {\n flags = getParsingFlags(m);\n parsedParts = some.call(flags.parsedDateParts, function (i) {\n return i != null;\n });\n isNowValid = flags.overflow < 0 && !flags.empty && !flags.invalidEra && !flags.invalidMonth && !flags.invalidWeekday && !flags.weekdayMismatch && !flags.nullInput && !flags.invalidFormat && !flags.userInvalidated && (!flags.meridiem || flags.meridiem && parsedParts);\n if (m._strict) {\n isNowValid = isNowValid && flags.charsLeftOver === 0 && flags.unusedTokens.length === 0 && flags.bigHour === undefined;\n }\n }\n if (Object.isFrozen == null || !Object.isFrozen(m)) {\n m._isValid = isNowValid;\n } else {\n return isNowValid;\n }\n return m._isValid;\n }\n function createInvalid(flags) {\n var m = createUTC(NaN);\n if (flags != null) {\n extend(getParsingFlags(m), flags);\n } else {\n getParsingFlags(m).userInvalidated = true;\n }\n return m;\n }\n\n // Plugins that add properties should also add the key here (null value),\n // so we can properly clone ourselves.\n var momentProperties = hooks.momentProperties = [],\n updateInProgress = false;\n function copyConfig(to, from) {\n var i,\n prop,\n val,\n momentPropertiesLen = momentProperties.length;\n if (!isUndefined(from._isAMomentObject)) {\n to._isAMomentObject = from._isAMomentObject;\n }\n if (!isUndefined(from._i)) {\n to._i = from._i;\n }\n if (!isUndefined(from._f)) {\n to._f = from._f;\n }\n if (!isUndefined(from._l)) {\n to._l = from._l;\n }\n if (!isUndefined(from._strict)) {\n to._strict = from._strict;\n }\n if (!isUndefined(from._tzm)) {\n to._tzm = from._tzm;\n }\n if (!isUndefined(from._isUTC)) {\n to._isUTC = from._isUTC;\n }\n if (!isUndefined(from._offset)) {\n to._offset = from._offset;\n }\n if (!isUndefined(from._pf)) {\n to._pf = getParsingFlags(from);\n }\n if (!isUndefined(from._locale)) {\n to._locale = from._locale;\n }\n if (momentPropertiesLen > 0) {\n for (i = 0; i < momentPropertiesLen; i++) {\n prop = momentProperties[i];\n val = from[prop];\n if (!isUndefined(val)) {\n to[prop] = val;\n }\n }\n }\n return to;\n }\n\n // Moment prototype object\n function Moment(config) {\n copyConfig(this, config);\n this._d = new Date(config._d != null ? config._d.getTime() : NaN);\n if (!this.isValid()) {\n this._d = new Date(NaN);\n }\n // Prevent infinite loop in case updateOffset creates new moment\n // objects.\n if (updateInProgress === false) {\n updateInProgress = true;\n hooks.updateOffset(this);\n updateInProgress = false;\n }\n }\n function isMoment(obj) {\n return obj instanceof Moment || obj != null && obj._isAMomentObject != null;\n }\n function warn(msg) {\n if (hooks.suppressDeprecationWarnings === false && typeof console !== 'undefined' && console.warn) {\n console.warn('Deprecation warning: ' + msg);\n }\n }\n function deprecate(msg, fn) {\n var firstTime = true;\n return extend(function () {\n if (hooks.deprecationHandler != null) {\n hooks.deprecationHandler(null, msg);\n }\n if (firstTime) {\n var args = [],\n arg,\n i,\n key,\n argLen = arguments.length;\n for (i = 0; i < argLen; i++) {\n arg = '';\n if (typeof arguments[i] === 'object') {\n arg += '\\n[' + i + '] ';\n for (key in arguments[0]) {\n if (hasOwnProp(arguments[0], key)) {\n arg += key + ': ' + arguments[0][key] + ', ';\n }\n }\n arg = arg.slice(0, -2); // Remove trailing comma and space\n } else {\n arg = arguments[i];\n }\n args.push(arg);\n }\n warn(msg + '\\nArguments: ' + Array.prototype.slice.call(args).join('') + '\\n' + new Error().stack);\n firstTime = false;\n }\n return fn.apply(this, arguments);\n }, fn);\n }\n var deprecations = {};\n function deprecateSimple(name, msg) {\n if (hooks.deprecationHandler != null) {\n hooks.deprecationHandler(name, msg);\n }\n if (!deprecations[name]) {\n warn(msg);\n deprecations[name] = true;\n }\n }\n hooks.suppressDeprecationWarnings = false;\n hooks.deprecationHandler = null;\n function isFunction(input) {\n return typeof Function !== 'undefined' && input instanceof Function || Object.prototype.toString.call(input) === '[object Function]';\n }\n function set(config) {\n var prop, i;\n for (i in config) {\n if (hasOwnProp(config, i)) {\n prop = config[i];\n if (isFunction(prop)) {\n this[i] = prop;\n } else {\n this['_' + i] = prop;\n }\n }\n }\n this._config = config;\n // Lenient ordinal parsing accepts just a number in addition to\n // number + (possibly) stuff coming from _dayOfMonthOrdinalParse.\n // TODO: Remove \"ordinalParse\" fallback in next major release.\n this._dayOfMonthOrdinalParseLenient = new RegExp((this._dayOfMonthOrdinalParse.source || this._ordinalParse.source) + '|' + /\\d{1,2}/.source);\n }\n function mergeConfigs(parentConfig, childConfig) {\n var res = extend({}, parentConfig),\n prop;\n for (prop in childConfig) {\n if (hasOwnProp(childConfig, prop)) {\n if (isObject(parentConfig[prop]) && isObject(childConfig[prop])) {\n res[prop] = {};\n extend(res[prop], parentConfig[prop]);\n extend(res[prop], childConfig[prop]);\n } else if (childConfig[prop] != null) {\n res[prop] = childConfig[prop];\n } else {\n delete res[prop];\n }\n }\n }\n for (prop in parentConfig) {\n if (hasOwnProp(parentConfig, prop) && !hasOwnProp(childConfig, prop) && isObject(parentConfig[prop])) {\n // make sure changes to properties don't modify parent config\n res[prop] = extend({}, res[prop]);\n }\n }\n return res;\n }\n function Locale(config) {\n if (config != null) {\n this.set(config);\n }\n }\n var keys;\n if (Object.keys) {\n keys = Object.keys;\n } else {\n keys = function (obj) {\n var i,\n res = [];\n for (i in obj) {\n if (hasOwnProp(obj, i)) {\n res.push(i);\n }\n }\n return res;\n };\n }\n var defaultCalendar = {\n sameDay: '[Today at] LT',\n nextDay: '[Tomorrow at] LT',\n nextWeek: 'dddd [at] LT',\n lastDay: '[Yesterday at] LT',\n lastWeek: '[Last] dddd [at] LT',\n sameElse: 'L'\n };\n function calendar(key, mom, now) {\n var output = this._calendar[key] || this._calendar['sameElse'];\n return isFunction(output) ? output.call(mom, now) : output;\n }\n function zeroFill(number, targetLength, forceSign) {\n var absNumber = '' + Math.abs(number),\n zerosToFill = targetLength - absNumber.length,\n sign = number >= 0;\n return (sign ? forceSign ? '+' : '' : '-') + Math.pow(10, Math.max(0, zerosToFill)).toString().substr(1) + absNumber;\n }\n var formattingTokens = /(\\[[^\\[]*\\])|(\\\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|N{1,5}|YYYYYY|YYYYY|YYYY|YY|y{2,4}|yo?|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,\n localFormattingTokens = /(\\[[^\\[]*\\])|(\\\\)?(LTS|LT|LL?L?L?|l{1,4})/g,\n formatFunctions = {},\n formatTokenFunctions = {};\n\n // token: 'M'\n // padded: ['MM', 2]\n // ordinal: 'Mo'\n // callback: function () { this.month() + 1 }\n function addFormatToken(token, padded, ordinal, callback) {\n var func = callback;\n if (typeof callback === 'string') {\n func = function () {\n return this[callback]();\n };\n }\n if (token) {\n formatTokenFunctions[token] = func;\n }\n if (padded) {\n formatTokenFunctions[padded[0]] = function () {\n return zeroFill(func.apply(this, arguments), padded[1], padded[2]);\n };\n }\n if (ordinal) {\n formatTokenFunctions[ordinal] = function () {\n return this.localeData().ordinal(func.apply(this, arguments), token);\n };\n }\n }\n function removeFormattingTokens(input) {\n if (input.match(/\\[[\\s\\S]/)) {\n return input.replace(/^\\[|\\]$/g, '');\n }\n return input.replace(/\\\\/g, '');\n }\n function makeFormatFunction(format) {\n var array = format.match(formattingTokens),\n i,\n length;\n for (i = 0, length = array.length; i < length; i++) {\n if (formatTokenFunctions[array[i]]) {\n array[i] = formatTokenFunctions[array[i]];\n } else {\n array[i] = removeFormattingTokens(array[i]);\n }\n }\n return function (mom) {\n var output = '',\n i;\n for (i = 0; i < length; i++) {\n output += isFunction(array[i]) ? array[i].call(mom, format) : array[i];\n }\n return output;\n };\n }\n\n // format date using native date object\n function formatMoment(m, format) {\n if (!m.isValid()) {\n return m.localeData().invalidDate();\n }\n format = expandFormat(format, m.localeData());\n formatFunctions[format] = formatFunctions[format] || makeFormatFunction(format);\n return formatFunctions[format](m);\n }\n function expandFormat(format, locale) {\n var i = 5;\n function replaceLongDateFormatTokens(input) {\n return locale.longDateFormat(input) || input;\n }\n localFormattingTokens.lastIndex = 0;\n while (i >= 0 && localFormattingTokens.test(format)) {\n format = format.replace(localFormattingTokens, replaceLongDateFormatTokens);\n localFormattingTokens.lastIndex = 0;\n i -= 1;\n }\n return format;\n }\n var defaultLongDateFormat = {\n LTS: 'h:mm:ss A',\n LT: 'h:mm A',\n L: 'MM/DD/YYYY',\n LL: 'MMMM D, YYYY',\n LLL: 'MMMM D, YYYY h:mm A',\n LLLL: 'dddd, MMMM D, YYYY h:mm A'\n };\n function longDateFormat(key) {\n var format = this._longDateFormat[key],\n formatUpper = this._longDateFormat[key.toUpperCase()];\n if (format || !formatUpper) {\n return format;\n }\n this._longDateFormat[key] = formatUpper.match(formattingTokens).map(function (tok) {\n if (tok === 'MMMM' || tok === 'MM' || tok === 'DD' || tok === 'dddd') {\n return tok.slice(1);\n }\n return tok;\n }).join('');\n return this._longDateFormat[key];\n }\n var defaultInvalidDate = 'Invalid date';\n function invalidDate() {\n return this._invalidDate;\n }\n var defaultOrdinal = '%d',\n defaultDayOfMonthOrdinalParse = /\\d{1,2}/;\n function ordinal(number) {\n return this._ordinal.replace('%d', number);\n }\n var defaultRelativeTime = {\n future: 'in %s',\n past: '%s ago',\n s: 'a few seconds',\n ss: '%d seconds',\n m: 'a minute',\n mm: '%d minutes',\n h: 'an hour',\n hh: '%d hours',\n d: 'a day',\n dd: '%d days',\n w: 'a week',\n ww: '%d weeks',\n M: 'a month',\n MM: '%d months',\n y: 'a year',\n yy: '%d years'\n };\n function relativeTime(number, withoutSuffix, string, isFuture) {\n var output = this._relativeTime[string];\n return isFunction(output) ? output(number, withoutSuffix, string, isFuture) : output.replace(/%d/i, number);\n }\n function pastFuture(diff, output) {\n var format = this._relativeTime[diff > 0 ? 'future' : 'past'];\n return isFunction(format) ? format(output) : format.replace(/%s/i, output);\n }\n var aliases = {\n D: 'date',\n dates: 'date',\n date: 'date',\n d: 'day',\n days: 'day',\n day: 'day',\n e: 'weekday',\n weekdays: 'weekday',\n weekday: 'weekday',\n E: 'isoWeekday',\n isoweekdays: 'isoWeekday',\n isoweekday: 'isoWeekday',\n DDD: 'dayOfYear',\n dayofyears: 'dayOfYear',\n dayofyear: 'dayOfYear',\n h: 'hour',\n hours: 'hour',\n hour: 'hour',\n ms: 'millisecond',\n milliseconds: 'millisecond',\n millisecond: 'millisecond',\n m: 'minute',\n minutes: 'minute',\n minute: 'minute',\n M: 'month',\n months: 'month',\n month: 'month',\n Q: 'quarter',\n quarters: 'quarter',\n quarter: 'quarter',\n s: 'second',\n seconds: 'second',\n second: 'second',\n gg: 'weekYear',\n weekyears: 'weekYear',\n weekyear: 'weekYear',\n GG: 'isoWeekYear',\n isoweekyears: 'isoWeekYear',\n isoweekyear: 'isoWeekYear',\n w: 'week',\n weeks: 'week',\n week: 'week',\n W: 'isoWeek',\n isoweeks: 'isoWeek',\n isoweek: 'isoWeek',\n y: 'year',\n years: 'year',\n year: 'year'\n };\n function normalizeUnits(units) {\n return typeof units === 'string' ? aliases[units] || aliases[units.toLowerCase()] : undefined;\n }\n function normalizeObjectUnits(inputObject) {\n var normalizedInput = {},\n normalizedProp,\n prop;\n for (prop in inputObject) {\n if (hasOwnProp(inputObject, prop)) {\n normalizedProp = normalizeUnits(prop);\n if (normalizedProp) {\n normalizedInput[normalizedProp] = inputObject[prop];\n }\n }\n }\n return normalizedInput;\n }\n var priorities = {\n date: 9,\n day: 11,\n weekday: 11,\n isoWeekday: 11,\n dayOfYear: 4,\n hour: 13,\n millisecond: 16,\n minute: 14,\n month: 8,\n quarter: 7,\n second: 15,\n weekYear: 1,\n isoWeekYear: 1,\n week: 5,\n isoWeek: 5,\n year: 1\n };\n function getPrioritizedUnits(unitsObj) {\n var units = [],\n u;\n for (u in unitsObj) {\n if (hasOwnProp(unitsObj, u)) {\n units.push({\n unit: u,\n priority: priorities[u]\n });\n }\n }\n units.sort(function (a, b) {\n return a.priority - b.priority;\n });\n return units;\n }\n var match1 = /\\d/,\n // 0 - 9\n match2 = /\\d\\d/,\n // 00 - 99\n match3 = /\\d{3}/,\n // 000 - 999\n match4 = /\\d{4}/,\n // 0000 - 9999\n match6 = /[+-]?\\d{6}/,\n // -999999 - 999999\n match1to2 = /\\d\\d?/,\n // 0 - 99\n match3to4 = /\\d\\d\\d\\d?/,\n // 999 - 9999\n match5to6 = /\\d\\d\\d\\d\\d\\d?/,\n // 99999 - 999999\n match1to3 = /\\d{1,3}/,\n // 0 - 999\n match1to4 = /\\d{1,4}/,\n // 0 - 9999\n match1to6 = /[+-]?\\d{1,6}/,\n // -999999 - 999999\n matchUnsigned = /\\d+/,\n // 0 - inf\n matchSigned = /[+-]?\\d+/,\n // -inf - inf\n matchOffset = /Z|[+-]\\d\\d:?\\d\\d/gi,\n // +00:00 -00:00 +0000 -0000 or Z\n matchShortOffset = /Z|[+-]\\d\\d(?::?\\d\\d)?/gi,\n // +00 -00 +00:00 -00:00 +0000 -0000 or Z\n matchTimestamp = /[+-]?\\d+(\\.\\d{1,3})?/,\n // 123456789 123456789.123\n // any word (or two) characters or numbers including two/three word month in arabic.\n // includes scottish gaelic two word and hyphenated months\n matchWord = /[0-9]{0,256}['a-z\\u00A0-\\u05FF\\u0700-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFF07\\uFF10-\\uFFEF]{1,256}|[\\u0600-\\u06FF\\/]{1,256}(\\s*?[\\u0600-\\u06FF]{1,256}){1,2}/i,\n match1to2NoLeadingZero = /^[1-9]\\d?/,\n // 1-99\n match1to2HasZero = /^([1-9]\\d|\\d)/,\n // 0-99\n regexes;\n regexes = {};\n function addRegexToken(token, regex, strictRegex) {\n regexes[token] = isFunction(regex) ? regex : function (isStrict, localeData) {\n return isStrict && strictRegex ? strictRegex : regex;\n };\n }\n function getParseRegexForToken(token, config) {\n if (!hasOwnProp(regexes, token)) {\n return new RegExp(unescapeFormat(token));\n }\n return regexes[token](config._strict, config._locale);\n }\n\n // Code from http://stackoverflow.com/questions/3561493/is-there-a-regexp-escape-function-in-javascript\n function unescapeFormat(s) {\n return regexEscape(s.replace('\\\\', '').replace(/\\\\(\\[)|\\\\(\\])|\\[([^\\]\\[]*)\\]|\\\\(.)/g, function (matched, p1, p2, p3, p4) {\n return p1 || p2 || p3 || p4;\n }));\n }\n function regexEscape(s) {\n return s.replace(/[-\\/\\\\^$*+?.()|[\\]{}]/g, '\\\\$&');\n }\n function absFloor(number) {\n if (number < 0) {\n // -0 -> 0\n return Math.ceil(number) || 0;\n } else {\n return Math.floor(number);\n }\n }\n function toInt(argumentForCoercion) {\n var coercedNumber = +argumentForCoercion,\n value = 0;\n if (coercedNumber !== 0 && isFinite(coercedNumber)) {\n value = absFloor(coercedNumber);\n }\n return value;\n }\n var tokens = {};\n function addParseToken(token, callback) {\n var i,\n func = callback,\n tokenLen;\n if (typeof token === 'string') {\n token = [token];\n }\n if (isNumber(callback)) {\n func = function (input, array) {\n array[callback] = toInt(input);\n };\n }\n tokenLen = token.length;\n for (i = 0; i < tokenLen; i++) {\n tokens[token[i]] = func;\n }\n }\n function addWeekParseToken(token, callback) {\n addParseToken(token, function (input, array, config, token) {\n config._w = config._w || {};\n callback(input, config._w, config, token);\n });\n }\n function addTimeToArrayFromToken(token, input, config) {\n if (input != null && hasOwnProp(tokens, token)) {\n tokens[token](input, config._a, config, token);\n }\n }\n function isLeapYear(year) {\n return year % 4 === 0 && year % 100 !== 0 || year % 400 === 0;\n }\n var YEAR = 0,\n MONTH = 1,\n DATE = 2,\n HOUR = 3,\n MINUTE = 4,\n SECOND = 5,\n MILLISECOND = 6,\n WEEK = 7,\n WEEKDAY = 8;\n\n // FORMATTING\n\n addFormatToken('Y', 0, 0, function () {\n var y = this.year();\n return y <= 9999 ? zeroFill(y, 4) : '+' + y;\n });\n addFormatToken(0, ['YY', 2], 0, function () {\n return this.year() % 100;\n });\n addFormatToken(0, ['YYYY', 4], 0, 'year');\n addFormatToken(0, ['YYYYY', 5], 0, 'year');\n addFormatToken(0, ['YYYYYY', 6, true], 0, 'year');\n\n // PARSING\n\n addRegexToken('Y', matchSigned);\n addRegexToken('YY', match1to2, match2);\n addRegexToken('YYYY', match1to4, match4);\n addRegexToken('YYYYY', match1to6, match6);\n addRegexToken('YYYYYY', match1to6, match6);\n addParseToken(['YYYYY', 'YYYYYY'], YEAR);\n addParseToken('YYYY', function (input, array) {\n array[YEAR] = input.length === 2 ? hooks.parseTwoDigitYear(input) : toInt(input);\n });\n addParseToken('YY', function (input, array) {\n array[YEAR] = hooks.parseTwoDigitYear(input);\n });\n addParseToken('Y', function (input, array) {\n array[YEAR] = parseInt(input, 10);\n });\n\n // HELPERS\n\n function daysInYear(year) {\n return isLeapYear(year) ? 366 : 365;\n }\n\n // HOOKS\n\n hooks.parseTwoDigitYear = function (input) {\n return toInt(input) + (toInt(input) > 68 ? 1900 : 2000);\n };\n\n // MOMENTS\n\n var getSetYear = makeGetSet('FullYear', true);\n function getIsLeapYear() {\n return isLeapYear(this.year());\n }\n function makeGetSet(unit, keepTime) {\n return function (value) {\n if (value != null) {\n set$1(this, unit, value);\n hooks.updateOffset(this, keepTime);\n return this;\n } else {\n return get(this, unit);\n }\n };\n }\n function get(mom, unit) {\n if (!mom.isValid()) {\n return NaN;\n }\n var d = mom._d,\n isUTC = mom._isUTC;\n switch (unit) {\n case 'Milliseconds':\n return isUTC ? d.getUTCMilliseconds() : d.getMilliseconds();\n case 'Seconds':\n return isUTC ? d.getUTCSeconds() : d.getSeconds();\n case 'Minutes':\n return isUTC ? d.getUTCMinutes() : d.getMinutes();\n case 'Hours':\n return isUTC ? d.getUTCHours() : d.getHours();\n case 'Date':\n return isUTC ? d.getUTCDate() : d.getDate();\n case 'Day':\n return isUTC ? d.getUTCDay() : d.getDay();\n case 'Month':\n return isUTC ? d.getUTCMonth() : d.getMonth();\n case 'FullYear':\n return isUTC ? d.getUTCFullYear() : d.getFullYear();\n default:\n return NaN;\n // Just in case\n }\n }\n function set$1(mom, unit, value) {\n var d, isUTC, year, month, date;\n if (!mom.isValid() || isNaN(value)) {\n return;\n }\n d = mom._d;\n isUTC = mom._isUTC;\n switch (unit) {\n case 'Milliseconds':\n return void (isUTC ? d.setUTCMilliseconds(value) : d.setMilliseconds(value));\n case 'Seconds':\n return void (isUTC ? d.setUTCSeconds(value) : d.setSeconds(value));\n case 'Minutes':\n return void (isUTC ? d.setUTCMinutes(value) : d.setMinutes(value));\n case 'Hours':\n return void (isUTC ? d.setUTCHours(value) : d.setHours(value));\n case 'Date':\n return void (isUTC ? d.setUTCDate(value) : d.setDate(value));\n // case 'Day': // Not real\n // return void (isUTC ? d.setUTCDay(value) : d.setDay(value));\n // case 'Month': // Not used because we need to pass two variables\n // return void (isUTC ? d.setUTCMonth(value) : d.setMonth(value));\n case 'FullYear':\n break;\n // See below ...\n default:\n return;\n // Just in case\n }\n year = value;\n month = mom.month();\n date = mom.date();\n date = date === 29 && month === 1 && !isLeapYear(year) ? 28 : date;\n void (isUTC ? d.setUTCFullYear(year, month, date) : d.setFullYear(year, month, date));\n }\n\n // MOMENTS\n\n function stringGet(units) {\n units = normalizeUnits(units);\n if (isFunction(this[units])) {\n return this[units]();\n }\n return this;\n }\n function stringSet(units, value) {\n if (typeof units === 'object') {\n units = normalizeObjectUnits(units);\n var prioritized = getPrioritizedUnits(units),\n i,\n prioritizedLen = prioritized.length;\n for (i = 0; i < prioritizedLen; i++) {\n this[prioritized[i].unit](units[prioritized[i].unit]);\n }\n } else {\n units = normalizeUnits(units);\n if (isFunction(this[units])) {\n return this[units](value);\n }\n }\n return this;\n }\n function mod(n, x) {\n return (n % x + x) % x;\n }\n var indexOf;\n if (Array.prototype.indexOf) {\n indexOf = Array.prototype.indexOf;\n } else {\n indexOf = function (o) {\n // I know\n var i;\n for (i = 0; i < this.length; ++i) {\n if (this[i] === o) {\n return i;\n }\n }\n return -1;\n };\n }\n function daysInMonth(year, month) {\n if (isNaN(year) || isNaN(month)) {\n return NaN;\n }\n var modMonth = mod(month, 12);\n year += (month - modMonth) / 12;\n return modMonth === 1 ? isLeapYear(year) ? 29 : 28 : 31 - modMonth % 7 % 2;\n }\n\n // FORMATTING\n\n addFormatToken('M', ['MM', 2], 'Mo', function () {\n return this.month() + 1;\n });\n addFormatToken('MMM', 0, 0, function (format) {\n return this.localeData().monthsShort(this, format);\n });\n addFormatToken('MMMM', 0, 0, function (format) {\n return this.localeData().months(this, format);\n });\n\n // PARSING\n\n addRegexToken('M', match1to2, match1to2NoLeadingZero);\n addRegexToken('MM', match1to2, match2);\n addRegexToken('MMM', function (isStrict, locale) {\n return locale.monthsShortRegex(isStrict);\n });\n addRegexToken('MMMM', function (isStrict, locale) {\n return locale.monthsRegex(isStrict);\n });\n addParseToken(['M', 'MM'], function (input, array) {\n array[MONTH] = toInt(input) - 1;\n });\n addParseToken(['MMM', 'MMMM'], function (input, array, config, token) {\n var month = config._locale.monthsParse(input, token, config._strict);\n // if we didn't find a month name, mark the date as invalid.\n if (month != null) {\n array[MONTH] = month;\n } else {\n getParsingFlags(config).invalidMonth = input;\n }\n });\n\n // LOCALES\n\n var defaultLocaleMonths = 'January_February_March_April_May_June_July_August_September_October_November_December'.split('_'),\n defaultLocaleMonthsShort = 'Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec'.split('_'),\n MONTHS_IN_FORMAT = /D[oD]?(\\[[^\\[\\]]*\\]|\\s)+MMMM?/,\n defaultMonthsShortRegex = matchWord,\n defaultMonthsRegex = matchWord;\n function localeMonths(m, format) {\n if (!m) {\n return isArray(this._months) ? this._months : this._months['standalone'];\n }\n return isArray(this._months) ? this._months[m.month()] : this._months[(this._months.isFormat || MONTHS_IN_FORMAT).test(format) ? 'format' : 'standalone'][m.month()];\n }\n function localeMonthsShort(m, format) {\n if (!m) {\n return isArray(this._monthsShort) ? this._monthsShort : this._monthsShort['standalone'];\n }\n return isArray(this._monthsShort) ? this._monthsShort[m.month()] : this._monthsShort[MONTHS_IN_FORMAT.test(format) ? 'format' : 'standalone'][m.month()];\n }\n function handleStrictParse(monthName, format, strict) {\n var i,\n ii,\n mom,\n llc = monthName.toLocaleLowerCase();\n if (!this._monthsParse) {\n // this is not used\n this._monthsParse = [];\n this._longMonthsParse = [];\n this._shortMonthsParse = [];\n for (i = 0; i < 12; ++i) {\n mom = createUTC([2000, i]);\n this._shortMonthsParse[i] = this.monthsShort(mom, '').toLocaleLowerCase();\n this._longMonthsParse[i] = this.months(mom, '').toLocaleLowerCase();\n }\n }\n if (strict) {\n if (format === 'MMM') {\n ii = indexOf.call(this._shortMonthsParse, llc);\n return ii !== -1 ? ii : null;\n } else {\n ii = indexOf.call(this._longMonthsParse, llc);\n return ii !== -1 ? ii : null;\n }\n } else {\n if (format === 'MMM') {\n ii = indexOf.call(this._shortMonthsParse, llc);\n if (ii !== -1) {\n return ii;\n }\n ii = indexOf.call(this._longMonthsParse, llc);\n return ii !== -1 ? ii : null;\n } else {\n ii = indexOf.call(this._longMonthsParse, llc);\n if (ii !== -1) {\n return ii;\n }\n ii = indexOf.call(this._shortMonthsParse, llc);\n return ii !== -1 ? ii : null;\n }\n }\n }\n function localeMonthsParse(monthName, format, strict) {\n var i, mom, regex;\n if (this._monthsParseExact) {\n return handleStrictParse.call(this, monthName, format, strict);\n }\n if (!this._monthsParse) {\n this._monthsParse = [];\n this._longMonthsParse = [];\n this._shortMonthsParse = [];\n }\n\n // TODO: add sorting\n // Sorting makes sure if one month (or abbr) is a prefix of another\n // see sorting in computeMonthsParse\n for (i = 0; i < 12; i++) {\n // make the regex if we don't have it already\n mom = createUTC([2000, i]);\n if (strict && !this._longMonthsParse[i]) {\n this._longMonthsParse[i] = new RegExp('^' + this.months(mom, '').replace('.', '') + '$', 'i');\n this._shortMonthsParse[i] = new RegExp('^' + this.monthsShort(mom, '').replace('.', '') + '$', 'i');\n }\n if (!strict && !this._monthsParse[i]) {\n regex = '^' + this.months(mom, '') + '|^' + this.monthsShort(mom, '');\n this._monthsParse[i] = new RegExp(regex.replace('.', ''), 'i');\n }\n // test the regex\n if (strict && format === 'MMMM' && this._longMonthsParse[i].test(monthName)) {\n return i;\n } else if (strict && format === 'MMM' && this._shortMonthsParse[i].test(monthName)) {\n return i;\n } else if (!strict && this._monthsParse[i].test(monthName)) {\n return i;\n }\n }\n }\n\n // MOMENTS\n\n function setMonth(mom, value) {\n if (!mom.isValid()) {\n // No op\n return mom;\n }\n if (typeof value === 'string') {\n if (/^\\d+$/.test(value)) {\n value = toInt(value);\n } else {\n value = mom.localeData().monthsParse(value);\n // TODO: Another silent failure?\n if (!isNumber(value)) {\n return mom;\n }\n }\n }\n var month = value,\n date = mom.date();\n date = date < 29 ? date : Math.min(date, daysInMonth(mom.year(), month));\n void (mom._isUTC ? mom._d.setUTCMonth(month, date) : mom._d.setMonth(month, date));\n return mom;\n }\n function getSetMonth(value) {\n if (value != null) {\n setMonth(this, value);\n hooks.updateOffset(this, true);\n return this;\n } else {\n return get(this, 'Month');\n }\n }\n function getDaysInMonth() {\n return daysInMonth(this.year(), this.month());\n }\n function monthsShortRegex(isStrict) {\n if (this._monthsParseExact) {\n if (!hasOwnProp(this, '_monthsRegex')) {\n computeMonthsParse.call(this);\n }\n if (isStrict) {\n return this._monthsShortStrictRegex;\n } else {\n return this._monthsShortRegex;\n }\n } else {\n if (!hasOwnProp(this, '_monthsShortRegex')) {\n this._monthsShortRegex = defaultMonthsShortRegex;\n }\n return this._monthsShortStrictRegex && isStrict ? this._monthsShortStrictRegex : this._monthsShortRegex;\n }\n }\n function monthsRegex(isStrict) {\n if (this._monthsParseExact) {\n if (!hasOwnProp(this, '_monthsRegex')) {\n computeMonthsParse.call(this);\n }\n if (isStrict) {\n return this._monthsStrictRegex;\n } else {\n return this._monthsRegex;\n }\n } else {\n if (!hasOwnProp(this, '_monthsRegex')) {\n this._monthsRegex = defaultMonthsRegex;\n }\n return this._monthsStrictRegex && isStrict ? this._monthsStrictRegex : this._monthsRegex;\n }\n }\n function computeMonthsParse() {\n function cmpLenRev(a, b) {\n return b.length - a.length;\n }\n var shortPieces = [],\n longPieces = [],\n mixedPieces = [],\n i,\n mom,\n shortP,\n longP;\n for (i = 0; i < 12; i++) {\n // make the regex if we don't have it already\n mom = createUTC([2000, i]);\n shortP = regexEscape(this.monthsShort(mom, ''));\n longP = regexEscape(this.months(mom, ''));\n shortPieces.push(shortP);\n longPieces.push(longP);\n mixedPieces.push(longP);\n mixedPieces.push(shortP);\n }\n // Sorting makes sure if one month (or abbr) is a prefix of another it\n // will match the longer piece.\n shortPieces.sort(cmpLenRev);\n longPieces.sort(cmpLenRev);\n mixedPieces.sort(cmpLenRev);\n this._monthsRegex = new RegExp('^(' + mixedPieces.join('|') + ')', 'i');\n this._monthsShortRegex = this._monthsRegex;\n this._monthsStrictRegex = new RegExp('^(' + longPieces.join('|') + ')', 'i');\n this._monthsShortStrictRegex = new RegExp('^(' + shortPieces.join('|') + ')', 'i');\n }\n function createDate(y, m, d, h, M, s, ms) {\n // can't just apply() to create a date:\n // https://stackoverflow.com/q/181348\n var date;\n // the date constructor remaps years 0-99 to 1900-1999\n if (y < 100 && y >= 0) {\n // preserve leap years using a full 400 year cycle, then reset\n date = new Date(y + 400, m, d, h, M, s, ms);\n if (isFinite(date.getFullYear())) {\n date.setFullYear(y);\n }\n } else {\n date = new Date(y, m, d, h, M, s, ms);\n }\n return date;\n }\n function createUTCDate(y) {\n var date, args;\n // the Date.UTC function remaps years 0-99 to 1900-1999\n if (y < 100 && y >= 0) {\n args = Array.prototype.slice.call(arguments);\n // preserve leap years using a full 400 year cycle, then reset\n args[0] = y + 400;\n date = new Date(Date.UTC.apply(null, args));\n if (isFinite(date.getUTCFullYear())) {\n date.setUTCFullYear(y);\n }\n } else {\n date = new Date(Date.UTC.apply(null, arguments));\n }\n return date;\n }\n\n // start-of-first-week - start-of-year\n function firstWeekOffset(year, dow, doy) {\n var\n // first-week day -- which january is always in the first week (4 for iso, 1 for other)\n fwd = 7 + dow - doy,\n // first-week day local weekday -- which local weekday is fwd\n fwdlw = (7 + createUTCDate(year, 0, fwd).getUTCDay() - dow) % 7;\n return -fwdlw + fwd - 1;\n }\n\n // https://en.wikipedia.org/wiki/ISO_week_date#Calculating_a_date_given_the_year.2C_week_number_and_weekday\n function dayOfYearFromWeeks(year, week, weekday, dow, doy) {\n var localWeekday = (7 + weekday - dow) % 7,\n weekOffset = firstWeekOffset(year, dow, doy),\n dayOfYear = 1 + 7 * (week - 1) + localWeekday + weekOffset,\n resYear,\n resDayOfYear;\n if (dayOfYear <= 0) {\n resYear = year - 1;\n resDayOfYear = daysInYear(resYear) + dayOfYear;\n } else if (dayOfYear > daysInYear(year)) {\n resYear = year + 1;\n resDayOfYear = dayOfYear - daysInYear(year);\n } else {\n resYear = year;\n resDayOfYear = dayOfYear;\n }\n return {\n year: resYear,\n dayOfYear: resDayOfYear\n };\n }\n function weekOfYear(mom, dow, doy) {\n var weekOffset = firstWeekOffset(mom.year(), dow, doy),\n week = Math.floor((mom.dayOfYear() - weekOffset - 1) / 7) + 1,\n resWeek,\n resYear;\n if (week < 1) {\n resYear = mom.year() - 1;\n resWeek = week + weeksInYear(resYear, dow, doy);\n } else if (week > weeksInYear(mom.year(), dow, doy)) {\n resWeek = week - weeksInYear(mom.year(), dow, doy);\n resYear = mom.year() + 1;\n } else {\n resYear = mom.year();\n resWeek = week;\n }\n return {\n week: resWeek,\n year: resYear\n };\n }\n function weeksInYear(year, dow, doy) {\n var weekOffset = firstWeekOffset(year, dow, doy),\n weekOffsetNext = firstWeekOffset(year + 1, dow, doy);\n return (daysInYear(year) - weekOffset + weekOffsetNext) / 7;\n }\n\n // FORMATTING\n\n addFormatToken('w', ['ww', 2], 'wo', 'week');\n addFormatToken('W', ['WW', 2], 'Wo', 'isoWeek');\n\n // PARSING\n\n addRegexToken('w', match1to2, match1to2NoLeadingZero);\n addRegexToken('ww', match1to2, match2);\n addRegexToken('W', match1to2, match1to2NoLeadingZero);\n addRegexToken('WW', match1to2, match2);\n addWeekParseToken(['w', 'ww', 'W', 'WW'], function (input, week, config, token) {\n week[token.substr(0, 1)] = toInt(input);\n });\n\n // HELPERS\n\n // LOCALES\n\n function localeWeek(mom) {\n return weekOfYear(mom, this._week.dow, this._week.doy).week;\n }\n var defaultLocaleWeek = {\n dow: 0,\n // Sunday is the first day of the week.\n doy: 6 // The week that contains Jan 6th is the first week of the year.\n };\n function localeFirstDayOfWeek() {\n return this._week.dow;\n }\n function localeFirstDayOfYear() {\n return this._week.doy;\n }\n\n // MOMENTS\n\n function getSetWeek(input) {\n var week = this.localeData().week(this);\n return input == null ? week : this.add((input - week) * 7, 'd');\n }\n function getSetISOWeek(input) {\n var week = weekOfYear(this, 1, 4).week;\n return input == null ? week : this.add((input - week) * 7, 'd');\n }\n\n // FORMATTING\n\n addFormatToken('d', 0, 'do', 'day');\n addFormatToken('dd', 0, 0, function (format) {\n return this.localeData().weekdaysMin(this, format);\n });\n addFormatToken('ddd', 0, 0, function (format) {\n return this.localeData().weekdaysShort(this, format);\n });\n addFormatToken('dddd', 0, 0, function (format) {\n return this.localeData().weekdays(this, format);\n });\n addFormatToken('e', 0, 0, 'weekday');\n addFormatToken('E', 0, 0, 'isoWeekday');\n\n // PARSING\n\n addRegexToken('d', match1to2);\n addRegexToken('e', match1to2);\n addRegexToken('E', match1to2);\n addRegexToken('dd', function (isStrict, locale) {\n return locale.weekdaysMinRegex(isStrict);\n });\n addRegexToken('ddd', function (isStrict, locale) {\n return locale.weekdaysShortRegex(isStrict);\n });\n addRegexToken('dddd', function (isStrict, locale) {\n return locale.weekdaysRegex(isStrict);\n });\n addWeekParseToken(['dd', 'ddd', 'dddd'], function (input, week, config, token) {\n var weekday = config._locale.weekdaysParse(input, token, config._strict);\n // if we didn't get a weekday name, mark the date as invalid\n if (weekday != null) {\n week.d = weekday;\n } else {\n getParsingFlags(config).invalidWeekday = input;\n }\n });\n addWeekParseToken(['d', 'e', 'E'], function (input, week, config, token) {\n week[token] = toInt(input);\n });\n\n // HELPERS\n\n function parseWeekday(input, locale) {\n if (typeof input !== 'string') {\n return input;\n }\n if (!isNaN(input)) {\n return parseInt(input, 10);\n }\n input = locale.weekdaysParse(input);\n if (typeof input === 'number') {\n return input;\n }\n return null;\n }\n function parseIsoWeekday(input, locale) {\n if (typeof input === 'string') {\n return locale.weekdaysParse(input) % 7 || 7;\n }\n return isNaN(input) ? null : input;\n }\n\n // LOCALES\n function shiftWeekdays(ws, n) {\n return ws.slice(n, 7).concat(ws.slice(0, n));\n }\n var defaultLocaleWeekdays = 'Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday'.split('_'),\n defaultLocaleWeekdaysShort = 'Sun_Mon_Tue_Wed_Thu_Fri_Sat'.split('_'),\n defaultLocaleWeekdaysMin = 'Su_Mo_Tu_We_Th_Fr_Sa'.split('_'),\n defaultWeekdaysRegex = matchWord,\n defaultWeekdaysShortRegex = matchWord,\n defaultWeekdaysMinRegex = matchWord;\n function localeWeekdays(m, format) {\n var weekdays = isArray(this._weekdays) ? this._weekdays : this._weekdays[m && m !== true && this._weekdays.isFormat.test(format) ? 'format' : 'standalone'];\n return m === true ? shiftWeekdays(weekdays, this._week.dow) : m ? weekdays[m.day()] : weekdays;\n }\n function localeWeekdaysShort(m) {\n return m === true ? shiftWeekdays(this._weekdaysShort, this._week.dow) : m ? this._weekdaysShort[m.day()] : this._weekdaysShort;\n }\n function localeWeekdaysMin(m) {\n return m === true ? shiftWeekdays(this._weekdaysMin, this._week.dow) : m ? this._weekdaysMin[m.day()] : this._weekdaysMin;\n }\n function handleStrictParse$1(weekdayName, format, strict) {\n var i,\n ii,\n mom,\n llc = weekdayName.toLocaleLowerCase();\n if (!this._weekdaysParse) {\n this._weekdaysParse = [];\n this._shortWeekdaysParse = [];\n this._minWeekdaysParse = [];\n for (i = 0; i < 7; ++i) {\n mom = createUTC([2000, 1]).day(i);\n this._minWeekdaysParse[i] = this.weekdaysMin(mom, '').toLocaleLowerCase();\n this._shortWeekdaysParse[i] = this.weekdaysShort(mom, '').toLocaleLowerCase();\n this._weekdaysParse[i] = this.weekdays(mom, '').toLocaleLowerCase();\n }\n }\n if (strict) {\n if (format === 'dddd') {\n ii = indexOf.call(this._weekdaysParse, llc);\n return ii !== -1 ? ii : null;\n } else if (format === 'ddd') {\n ii = indexOf.call(this._shortWeekdaysParse, llc);\n return ii !== -1 ? ii : null;\n } else {\n ii = indexOf.call(this._minWeekdaysParse, llc);\n return ii !== -1 ? ii : null;\n }\n } else {\n if (format === 'dddd') {\n ii = indexOf.call(this._weekdaysParse, llc);\n if (ii !== -1) {\n return ii;\n }\n ii = indexOf.call(this._shortWeekdaysParse, llc);\n if (ii !== -1) {\n return ii;\n }\n ii = indexOf.call(this._minWeekdaysParse, llc);\n return ii !== -1 ? ii : null;\n } else if (format === 'ddd') {\n ii = indexOf.call(this._shortWeekdaysParse, llc);\n if (ii !== -1) {\n return ii;\n }\n ii = indexOf.call(this._weekdaysParse, llc);\n if (ii !== -1) {\n return ii;\n }\n ii = indexOf.call(this._minWeekdaysParse, llc);\n return ii !== -1 ? ii : null;\n } else {\n ii = indexOf.call(this._minWeekdaysParse, llc);\n if (ii !== -1) {\n return ii;\n }\n ii = indexOf.call(this._weekdaysParse, llc);\n if (ii !== -1) {\n return ii;\n }\n ii = indexOf.call(this._shortWeekdaysParse, llc);\n return ii !== -1 ? ii : null;\n }\n }\n }\n function localeWeekdaysParse(weekdayName, format, strict) {\n var i, mom, regex;\n if (this._weekdaysParseExact) {\n return handleStrictParse$1.call(this, weekdayName, format, strict);\n }\n if (!this._weekdaysParse) {\n this._weekdaysParse = [];\n this._minWeekdaysParse = [];\n this._shortWeekdaysParse = [];\n this._fullWeekdaysParse = [];\n }\n for (i = 0; i < 7; i++) {\n // make the regex if we don't have it already\n\n mom = createUTC([2000, 1]).day(i);\n if (strict && !this._fullWeekdaysParse[i]) {\n this._fullWeekdaysParse[i] = new RegExp('^' + this.weekdays(mom, '').replace('.', '\\\\.?') + '$', 'i');\n this._shortWeekdaysParse[i] = new RegExp('^' + this.weekdaysShort(mom, '').replace('.', '\\\\.?') + '$', 'i');\n this._minWeekdaysParse[i] = new RegExp('^' + this.weekdaysMin(mom, '').replace('.', '\\\\.?') + '$', 'i');\n }\n if (!this._weekdaysParse[i]) {\n regex = '^' + this.weekdays(mom, '') + '|^' + this.weekdaysShort(mom, '') + '|^' + this.weekdaysMin(mom, '');\n this._weekdaysParse[i] = new RegExp(regex.replace('.', ''), 'i');\n }\n // test the regex\n if (strict && format === 'dddd' && this._fullWeekdaysParse[i].test(weekdayName)) {\n return i;\n } else if (strict && format === 'ddd' && this._shortWeekdaysParse[i].test(weekdayName)) {\n return i;\n } else if (strict && format === 'dd' && this._minWeekdaysParse[i].test(weekdayName)) {\n return i;\n } else if (!strict && this._weekdaysParse[i].test(weekdayName)) {\n return i;\n }\n }\n }\n\n // MOMENTS\n\n function getSetDayOfWeek(input) {\n if (!this.isValid()) {\n return input != null ? this : NaN;\n }\n var day = get(this, 'Day');\n if (input != null) {\n input = parseWeekday(input, this.localeData());\n return this.add(input - day, 'd');\n } else {\n return day;\n }\n }\n function getSetLocaleDayOfWeek(input) {\n if (!this.isValid()) {\n return input != null ? this : NaN;\n }\n var weekday = (this.day() + 7 - this.localeData()._week.dow) % 7;\n return input == null ? weekday : this.add(input - weekday, 'd');\n }\n function getSetISODayOfWeek(input) {\n if (!this.isValid()) {\n return input != null ? this : NaN;\n }\n\n // behaves the same as moment#day except\n // as a getter, returns 7 instead of 0 (1-7 range instead of 0-6)\n // as a setter, sunday should belong to the previous week.\n\n if (input != null) {\n var weekday = parseIsoWeekday(input, this.localeData());\n return this.day(this.day() % 7 ? weekday : weekday - 7);\n } else {\n return this.day() || 7;\n }\n }\n function weekdaysRegex(isStrict) {\n if (this._weekdaysParseExact) {\n if (!hasOwnProp(this, '_weekdaysRegex')) {\n computeWeekdaysParse.call(this);\n }\n if (isStrict) {\n return this._weekdaysStrictRegex;\n } else {\n return this._weekdaysRegex;\n }\n } else {\n if (!hasOwnProp(this, '_weekdaysRegex')) {\n this._weekdaysRegex = defaultWeekdaysRegex;\n }\n return this._weekdaysStrictRegex && isStrict ? this._weekdaysStrictRegex : this._weekdaysRegex;\n }\n }\n function weekdaysShortRegex(isStrict) {\n if (this._weekdaysParseExact) {\n if (!hasOwnProp(this, '_weekdaysRegex')) {\n computeWeekdaysParse.call(this);\n }\n if (isStrict) {\n return this._weekdaysShortStrictRegex;\n } else {\n return this._weekdaysShortRegex;\n }\n } else {\n if (!hasOwnProp(this, '_weekdaysShortRegex')) {\n this._weekdaysShortRegex = defaultWeekdaysShortRegex;\n }\n return this._weekdaysShortStrictRegex && isStrict ? this._weekdaysShortStrictRegex : this._weekdaysShortRegex;\n }\n }\n function weekdaysMinRegex(isStrict) {\n if (this._weekdaysParseExact) {\n if (!hasOwnProp(this, '_weekdaysRegex')) {\n computeWeekdaysParse.call(this);\n }\n if (isStrict) {\n return this._weekdaysMinStrictRegex;\n } else {\n return this._weekdaysMinRegex;\n }\n } else {\n if (!hasOwnProp(this, '_weekdaysMinRegex')) {\n this._weekdaysMinRegex = defaultWeekdaysMinRegex;\n }\n return this._weekdaysMinStrictRegex && isStrict ? this._weekdaysMinStrictRegex : this._weekdaysMinRegex;\n }\n }\n function computeWeekdaysParse() {\n function cmpLenRev(a, b) {\n return b.length - a.length;\n }\n var minPieces = [],\n shortPieces = [],\n longPieces = [],\n mixedPieces = [],\n i,\n mom,\n minp,\n shortp,\n longp;\n for (i = 0; i < 7; i++) {\n // make the regex if we don't have it already\n mom = createUTC([2000, 1]).day(i);\n minp = regexEscape(this.weekdaysMin(mom, ''));\n shortp = regexEscape(this.weekdaysShort(mom, ''));\n longp = regexEscape(this.weekdays(mom, ''));\n minPieces.push(minp);\n shortPieces.push(shortp);\n longPieces.push(longp);\n mixedPieces.push(minp);\n mixedPieces.push(shortp);\n mixedPieces.push(longp);\n }\n // Sorting makes sure if one weekday (or abbr) is a prefix of another it\n // will match the longer piece.\n minPieces.sort(cmpLenRev);\n shortPieces.sort(cmpLenRev);\n longPieces.sort(cmpLenRev);\n mixedPieces.sort(cmpLenRev);\n this._weekdaysRegex = new RegExp('^(' + mixedPieces.join('|') + ')', 'i');\n this._weekdaysShortRegex = this._weekdaysRegex;\n this._weekdaysMinRegex = this._weekdaysRegex;\n this._weekdaysStrictRegex = new RegExp('^(' + longPieces.join('|') + ')', 'i');\n this._weekdaysShortStrictRegex = new RegExp('^(' + shortPieces.join('|') + ')', 'i');\n this._weekdaysMinStrictRegex = new RegExp('^(' + minPieces.join('|') + ')', 'i');\n }\n\n // FORMATTING\n\n function hFormat() {\n return this.hours() % 12 || 12;\n }\n function kFormat() {\n return this.hours() || 24;\n }\n addFormatToken('H', ['HH', 2], 0, 'hour');\n addFormatToken('h', ['hh', 2], 0, hFormat);\n addFormatToken('k', ['kk', 2], 0, kFormat);\n addFormatToken('hmm', 0, 0, function () {\n return '' + hFormat.apply(this) + zeroFill(this.minutes(), 2);\n });\n addFormatToken('hmmss', 0, 0, function () {\n return '' + hFormat.apply(this) + zeroFill(this.minutes(), 2) + zeroFill(this.seconds(), 2);\n });\n addFormatToken('Hmm', 0, 0, function () {\n return '' + this.hours() + zeroFill(this.minutes(), 2);\n });\n addFormatToken('Hmmss', 0, 0, function () {\n return '' + this.hours() + zeroFill(this.minutes(), 2) + zeroFill(this.seconds(), 2);\n });\n function meridiem(token, lowercase) {\n addFormatToken(token, 0, 0, function () {\n return this.localeData().meridiem(this.hours(), this.minutes(), lowercase);\n });\n }\n meridiem('a', true);\n meridiem('A', false);\n\n // PARSING\n\n function matchMeridiem(isStrict, locale) {\n return locale._meridiemParse;\n }\n addRegexToken('a', matchMeridiem);\n addRegexToken('A', matchMeridiem);\n addRegexToken('H', match1to2, match1to2HasZero);\n addRegexToken('h', match1to2, match1to2NoLeadingZero);\n addRegexToken('k', match1to2, match1to2NoLeadingZero);\n addRegexToken('HH', match1to2, match2);\n addRegexToken('hh', match1to2, match2);\n addRegexToken('kk', match1to2, match2);\n addRegexToken('hmm', match3to4);\n addRegexToken('hmmss', match5to6);\n addRegexToken('Hmm', match3to4);\n addRegexToken('Hmmss', match5to6);\n addParseToken(['H', 'HH'], HOUR);\n addParseToken(['k', 'kk'], function (input, array, config) {\n var kInput = toInt(input);\n array[HOUR] = kInput === 24 ? 0 : kInput;\n });\n addParseToken(['a', 'A'], function (input, array, config) {\n config._isPm = config._locale.isPM(input);\n config._meridiem = input;\n });\n addParseToken(['h', 'hh'], function (input, array, config) {\n array[HOUR] = toInt(input);\n getParsingFlags(config).bigHour = true;\n });\n addParseToken('hmm', function (input, array, config) {\n var pos = input.length - 2;\n array[HOUR] = toInt(input.substr(0, pos));\n array[MINUTE] = toInt(input.substr(pos));\n getParsingFlags(config).bigHour = true;\n });\n addParseToken('hmmss', function (input, array, config) {\n var pos1 = input.length - 4,\n pos2 = input.length - 2;\n array[HOUR] = toInt(input.substr(0, pos1));\n array[MINUTE] = toInt(input.substr(pos1, 2));\n array[SECOND] = toInt(input.substr(pos2));\n getParsingFlags(config).bigHour = true;\n });\n addParseToken('Hmm', function (input, array, config) {\n var pos = input.length - 2;\n array[HOUR] = toInt(input.substr(0, pos));\n array[MINUTE] = toInt(input.substr(pos));\n });\n addParseToken('Hmmss', function (input, array, config) {\n var pos1 = input.length - 4,\n pos2 = input.length - 2;\n array[HOUR] = toInt(input.substr(0, pos1));\n array[MINUTE] = toInt(input.substr(pos1, 2));\n array[SECOND] = toInt(input.substr(pos2));\n });\n\n // LOCALES\n\n function localeIsPM(input) {\n // IE8 Quirks Mode & IE7 Standards Mode do not allow accessing strings like arrays\n // Using charAt should be more compatible.\n return (input + '').toLowerCase().charAt(0) === 'p';\n }\n var defaultLocaleMeridiemParse = /[ap]\\.?m?\\.?/i,\n // Setting the hour should keep the time, because the user explicitly\n // specified which hour they want. So trying to maintain the same hour (in\n // a new timezone) makes sense. Adding/subtracting hours does not follow\n // this rule.\n getSetHour = makeGetSet('Hours', true);\n function localeMeridiem(hours, minutes, isLower) {\n if (hours > 11) {\n return isLower ? 'pm' : 'PM';\n } else {\n return isLower ? 'am' : 'AM';\n }\n }\n var baseConfig = {\n calendar: defaultCalendar,\n longDateFormat: defaultLongDateFormat,\n invalidDate: defaultInvalidDate,\n ordinal: defaultOrdinal,\n dayOfMonthOrdinalParse: defaultDayOfMonthOrdinalParse,\n relativeTime: defaultRelativeTime,\n months: defaultLocaleMonths,\n monthsShort: defaultLocaleMonthsShort,\n week: defaultLocaleWeek,\n weekdays: defaultLocaleWeekdays,\n weekdaysMin: defaultLocaleWeekdaysMin,\n weekdaysShort: defaultLocaleWeekdaysShort,\n meridiemParse: defaultLocaleMeridiemParse\n };\n\n // internal storage for locale config files\n var locales = {},\n localeFamilies = {},\n globalLocale;\n function commonPrefix(arr1, arr2) {\n var i,\n minl = Math.min(arr1.length, arr2.length);\n for (i = 0; i < minl; i += 1) {\n if (arr1[i] !== arr2[i]) {\n return i;\n }\n }\n return minl;\n }\n function normalizeLocale(key) {\n return key ? key.toLowerCase().replace('_', '-') : key;\n }\n\n // pick the locale from the array\n // try ['en-au', 'en-gb'] as 'en-au', 'en-gb', 'en', as in move through the list trying each\n // substring from most specific to least, but move to the next array item if it's a more specific variant than the current root\n function chooseLocale(names) {\n var i = 0,\n j,\n next,\n locale,\n split;\n while (i < names.length) {\n split = normalizeLocale(names[i]).split('-');\n j = split.length;\n next = normalizeLocale(names[i + 1]);\n next = next ? next.split('-') : null;\n while (j > 0) {\n locale = loadLocale(split.slice(0, j).join('-'));\n if (locale) {\n return locale;\n }\n if (next && next.length >= j && commonPrefix(split, next) >= j - 1) {\n //the next array item is better than a shallower substring of this one\n break;\n }\n j--;\n }\n i++;\n }\n return globalLocale;\n }\n function isLocaleNameSane(name) {\n // Prevent names that look like filesystem paths, i.e contain '/' or '\\'\n // Ensure name is available and function returns boolean\n return !!(name && name.match('^[^/\\\\\\\\]*$'));\n }\n function loadLocale(name) {\n var oldLocale = null,\n aliasedRequire;\n // TODO: Find a better way to register and load all the locales in Node\n if (locales[name] === undefined && typeof module !== 'undefined' && module && module.exports && isLocaleNameSane(name)) {\n try {\n oldLocale = globalLocale._abbr;\n aliasedRequire = require;\n aliasedRequire('./locale/' + name);\n getSetGlobalLocale(oldLocale);\n } catch (e) {\n // mark as not found to avoid repeating expensive file require call causing high CPU\n // when trying to find en-US, en_US, en-us for every format call\n locales[name] = null; // null means not found\n }\n }\n return locales[name];\n }\n\n // This function will load locale and then set the global locale. If\n // no arguments are passed in, it will simply return the current global\n // locale key.\n function getSetGlobalLocale(key, values) {\n var data;\n if (key) {\n if (isUndefined(values)) {\n data = getLocale(key);\n } else {\n data = defineLocale(key, values);\n }\n if (data) {\n // moment.duration._locale = moment._locale = data;\n globalLocale = data;\n } else {\n if (typeof console !== 'undefined' && console.warn) {\n //warn user if arguments are passed but the locale could not be set\n console.warn('Locale ' + key + ' not found. Did you forget to load it?');\n }\n }\n }\n return globalLocale._abbr;\n }\n function defineLocale(name, config) {\n if (config !== null) {\n var locale,\n parentConfig = baseConfig;\n config.abbr = name;\n if (locales[name] != null) {\n deprecateSimple('defineLocaleOverride', 'use moment.updateLocale(localeName, config) to change ' + 'an existing locale. moment.defineLocale(localeName, ' + 'config) should only be used for creating a new locale ' + 'See http://momentjs.com/guides/#/warnings/define-locale/ for more info.');\n parentConfig = locales[name]._config;\n } else if (config.parentLocale != null) {\n if (locales[config.parentLocale] != null) {\n parentConfig = locales[config.parentLocale]._config;\n } else {\n locale = loadLocale(config.parentLocale);\n if (locale != null) {\n parentConfig = locale._config;\n } else {\n if (!localeFamilies[config.parentLocale]) {\n localeFamilies[config.parentLocale] = [];\n }\n localeFamilies[config.parentLocale].push({\n name: name,\n config: config\n });\n return null;\n }\n }\n }\n locales[name] = new Locale(mergeConfigs(parentConfig, config));\n if (localeFamilies[name]) {\n localeFamilies[name].forEach(function (x) {\n defineLocale(x.name, x.config);\n });\n }\n\n // backwards compat for now: also set the locale\n // make sure we set the locale AFTER all child locales have been\n // created, so we won't end up with the child locale set.\n getSetGlobalLocale(name);\n return locales[name];\n } else {\n // useful for testing\n delete locales[name];\n return null;\n }\n }\n function updateLocale(name, config) {\n if (config != null) {\n var locale,\n tmpLocale,\n parentConfig = baseConfig;\n if (locales[name] != null && locales[name].parentLocale != null) {\n // Update existing child locale in-place to avoid memory-leaks\n locales[name].set(mergeConfigs(locales[name]._config, config));\n } else {\n // MERGE\n tmpLocale = loadLocale(name);\n if (tmpLocale != null) {\n parentConfig = tmpLocale._config;\n }\n config = mergeConfigs(parentConfig, config);\n if (tmpLocale == null) {\n // updateLocale is called for creating a new locale\n // Set abbr so it will have a name (getters return\n // undefined otherwise).\n config.abbr = name;\n }\n locale = new Locale(config);\n locale.parentLocale = locales[name];\n locales[name] = locale;\n }\n\n // backwards compat for now: also set the locale\n getSetGlobalLocale(name);\n } else {\n // pass null for config to unupdate, useful for tests\n if (locales[name] != null) {\n if (locales[name].parentLocale != null) {\n locales[name] = locales[name].parentLocale;\n if (name === getSetGlobalLocale()) {\n getSetGlobalLocale(name);\n }\n } else if (locales[name] != null) {\n delete locales[name];\n }\n }\n }\n return locales[name];\n }\n\n // returns locale data\n function getLocale(key) {\n var locale;\n if (key && key._locale && key._locale._abbr) {\n key = key._locale._abbr;\n }\n if (!key) {\n return globalLocale;\n }\n if (!isArray(key)) {\n //short-circuit everything else\n locale = loadLocale(key);\n if (locale) {\n return locale;\n }\n key = [key];\n }\n return chooseLocale(key);\n }\n function listLocales() {\n return keys(locales);\n }\n function checkOverflow(m) {\n var overflow,\n a = m._a;\n if (a && getParsingFlags(m).overflow === -2) {\n overflow = a[MONTH] < 0 || a[MONTH] > 11 ? MONTH : a[DATE] < 1 || a[DATE] > daysInMonth(a[YEAR], a[MONTH]) ? DATE : a[HOUR] < 0 || a[HOUR] > 24 || a[HOUR] === 24 && (a[MINUTE] !== 0 || a[SECOND] !== 0 || a[MILLISECOND] !== 0) ? HOUR : a[MINUTE] < 0 || a[MINUTE] > 59 ? MINUTE : a[SECOND] < 0 || a[SECOND] > 59 ? SECOND : a[MILLISECOND] < 0 || a[MILLISECOND] > 999 ? MILLISECOND : -1;\n if (getParsingFlags(m)._overflowDayOfYear && (overflow < YEAR || overflow > DATE)) {\n overflow = DATE;\n }\n if (getParsingFlags(m)._overflowWeeks && overflow === -1) {\n overflow = WEEK;\n }\n if (getParsingFlags(m)._overflowWeekday && overflow === -1) {\n overflow = WEEKDAY;\n }\n getParsingFlags(m).overflow = overflow;\n }\n return m;\n }\n\n // iso 8601 regex\n // 0000-00-00 0000-W00 or 0000-W00-0 + T + 00 or 00:00 or 00:00:00 or 00:00:00.000 + +00:00 or +0000 or +00)\n var extendedIsoRegex = /^\\s*((?:[+-]\\d{6}|\\d{4})-(?:\\d\\d-\\d\\d|W\\d\\d-\\d|W\\d\\d|\\d\\d\\d|\\d\\d))(?:(T| )(\\d\\d(?::\\d\\d(?::\\d\\d(?:[.,]\\d+)?)?)?)([+-]\\d\\d(?::?\\d\\d)?|\\s*Z)?)?$/,\n basicIsoRegex = /^\\s*((?:[+-]\\d{6}|\\d{4})(?:\\d\\d\\d\\d|W\\d\\d\\d|W\\d\\d|\\d\\d\\d|\\d\\d|))(?:(T| )(\\d\\d(?:\\d\\d(?:\\d\\d(?:[.,]\\d+)?)?)?)([+-]\\d\\d(?::?\\d\\d)?|\\s*Z)?)?$/,\n tzRegex = /Z|[+-]\\d\\d(?::?\\d\\d)?/,\n isoDates = [['YYYYYY-MM-DD', /[+-]\\d{6}-\\d\\d-\\d\\d/], ['YYYY-MM-DD', /\\d{4}-\\d\\d-\\d\\d/], ['GGGG-[W]WW-E', /\\d{4}-W\\d\\d-\\d/], ['GGGG-[W]WW', /\\d{4}-W\\d\\d/, false], ['YYYY-DDD', /\\d{4}-\\d{3}/], ['YYYY-MM', /\\d{4}-\\d\\d/, false], ['YYYYYYMMDD', /[+-]\\d{10}/], ['YYYYMMDD', /\\d{8}/], ['GGGG[W]WWE', /\\d{4}W\\d{3}/], ['GGGG[W]WW', /\\d{4}W\\d{2}/, false], ['YYYYDDD', /\\d{7}/], ['YYYYMM', /\\d{6}/, false], ['YYYY', /\\d{4}/, false]],\n // iso time formats and regexes\n isoTimes = [['HH:mm:ss.SSSS', /\\d\\d:\\d\\d:\\d\\d\\.\\d+/], ['HH:mm:ss,SSSS', /\\d\\d:\\d\\d:\\d\\d,\\d+/], ['HH:mm:ss', /\\d\\d:\\d\\d:\\d\\d/], ['HH:mm', /\\d\\d:\\d\\d/], ['HHmmss.SSSS', /\\d\\d\\d\\d\\d\\d\\.\\d+/], ['HHmmss,SSSS', /\\d\\d\\d\\d\\d\\d,\\d+/], ['HHmmss', /\\d\\d\\d\\d\\d\\d/], ['HHmm', /\\d\\d\\d\\d/], ['HH', /\\d\\d/]],\n aspNetJsonRegex = /^\\/?Date\\((-?\\d+)/i,\n // RFC 2822 regex: For details see https://tools.ietf.org/html/rfc2822#section-3.3\n rfc2822 = /^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\\s)?(\\d{1,2})\\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\\s(\\d{2,4})\\s(\\d\\d):(\\d\\d)(?::(\\d\\d))?\\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|([+-]\\d{4}))$/,\n obsOffsets = {\n UT: 0,\n GMT: 0,\n EDT: -4 * 60,\n EST: -5 * 60,\n CDT: -5 * 60,\n CST: -6 * 60,\n MDT: -6 * 60,\n MST: -7 * 60,\n PDT: -7 * 60,\n PST: -8 * 60\n };\n\n // date from iso format\n function configFromISO(config) {\n var i,\n l,\n string = config._i,\n match = extendedIsoRegex.exec(string) || basicIsoRegex.exec(string),\n allowTime,\n dateFormat,\n timeFormat,\n tzFormat,\n isoDatesLen = isoDates.length,\n isoTimesLen = isoTimes.length;\n if (match) {\n getParsingFlags(config).iso = true;\n for (i = 0, l = isoDatesLen; i < l; i++) {\n if (isoDates[i][1].exec(match[1])) {\n dateFormat = isoDates[i][0];\n allowTime = isoDates[i][2] !== false;\n break;\n }\n }\n if (dateFormat == null) {\n config._isValid = false;\n return;\n }\n if (match[3]) {\n for (i = 0, l = isoTimesLen; i < l; i++) {\n if (isoTimes[i][1].exec(match[3])) {\n // match[2] should be 'T' or space\n timeFormat = (match[2] || ' ') + isoTimes[i][0];\n break;\n }\n }\n if (timeFormat == null) {\n config._isValid = false;\n return;\n }\n }\n if (!allowTime && timeFormat != null) {\n config._isValid = false;\n return;\n }\n if (match[4]) {\n if (tzRegex.exec(match[4])) {\n tzFormat = 'Z';\n } else {\n config._isValid = false;\n return;\n }\n }\n config._f = dateFormat + (timeFormat || '') + (tzFormat || '');\n configFromStringAndFormat(config);\n } else {\n config._isValid = false;\n }\n }\n function extractFromRFC2822Strings(yearStr, monthStr, dayStr, hourStr, minuteStr, secondStr) {\n var result = [untruncateYear(yearStr), defaultLocaleMonthsShort.indexOf(monthStr), parseInt(dayStr, 10), parseInt(hourStr, 10), parseInt(minuteStr, 10)];\n if (secondStr) {\n result.push(parseInt(secondStr, 10));\n }\n return result;\n }\n function untruncateYear(yearStr) {\n var year = parseInt(yearStr, 10);\n if (year <= 49) {\n return 2000 + year;\n } else if (year <= 999) {\n return 1900 + year;\n }\n return year;\n }\n function preprocessRFC2822(s) {\n // Remove comments and folding whitespace and replace multiple-spaces with a single space\n return s.replace(/\\([^()]*\\)|[\\n\\t]/g, ' ').replace(/(\\s\\s+)/g, ' ').replace(/^\\s\\s*/, '').replace(/\\s\\s*$/, '');\n }\n function checkWeekday(weekdayStr, parsedInput, config) {\n if (weekdayStr) {\n // TODO: Replace the vanilla JS Date object with an independent day-of-week check.\n var weekdayProvided = defaultLocaleWeekdaysShort.indexOf(weekdayStr),\n weekdayActual = new Date(parsedInput[0], parsedInput[1], parsedInput[2]).getDay();\n if (weekdayProvided !== weekdayActual) {\n getParsingFlags(config).weekdayMismatch = true;\n config._isValid = false;\n return false;\n }\n }\n return true;\n }\n function calculateOffset(obsOffset, militaryOffset, numOffset) {\n if (obsOffset) {\n return obsOffsets[obsOffset];\n } else if (militaryOffset) {\n // the only allowed military tz is Z\n return 0;\n } else {\n var hm = parseInt(numOffset, 10),\n m = hm % 100,\n h = (hm - m) / 100;\n return h * 60 + m;\n }\n }\n\n // date and time from ref 2822 format\n function configFromRFC2822(config) {\n var match = rfc2822.exec(preprocessRFC2822(config._i)),\n parsedArray;\n if (match) {\n parsedArray = extractFromRFC2822Strings(match[4], match[3], match[2], match[5], match[6], match[7]);\n if (!checkWeekday(match[1], parsedArray, config)) {\n return;\n }\n config._a = parsedArray;\n config._tzm = calculateOffset(match[8], match[9], match[10]);\n config._d = createUTCDate.apply(null, config._a);\n config._d.setUTCMinutes(config._d.getUTCMinutes() - config._tzm);\n getParsingFlags(config).rfc2822 = true;\n } else {\n config._isValid = false;\n }\n }\n\n // date from 1) ASP.NET, 2) ISO, 3) RFC 2822 formats, or 4) optional fallback if parsing isn't strict\n function configFromString(config) {\n var matched = aspNetJsonRegex.exec(config._i);\n if (matched !== null) {\n config._d = new Date(+matched[1]);\n return;\n }\n configFromISO(config);\n if (config._isValid === false) {\n delete config._isValid;\n } else {\n return;\n }\n configFromRFC2822(config);\n if (config._isValid === false) {\n delete config._isValid;\n } else {\n return;\n }\n if (config._strict) {\n config._isValid = false;\n } else {\n // Final attempt, use Input Fallback\n hooks.createFromInputFallback(config);\n }\n }\n hooks.createFromInputFallback = deprecate('value provided is not in a recognized RFC2822 or ISO format. moment construction falls back to js Date(), ' + 'which is not reliable across all browsers and versions. Non RFC2822/ISO date formats are ' + 'discouraged. Please refer to http://momentjs.com/guides/#/warnings/js-date/ for more info.', function (config) {\n config._d = new Date(config._i + (config._useUTC ? ' UTC' : ''));\n });\n\n // Pick the first defined of two or three arguments.\n function defaults(a, b, c) {\n if (a != null) {\n return a;\n }\n if (b != null) {\n return b;\n }\n return c;\n }\n function currentDateArray(config) {\n // hooks is actually the exported moment object\n var nowValue = new Date(hooks.now());\n if (config._useUTC) {\n return [nowValue.getUTCFullYear(), nowValue.getUTCMonth(), nowValue.getUTCDate()];\n }\n return [nowValue.getFullYear(), nowValue.getMonth(), nowValue.getDate()];\n }\n\n // convert an array to a date.\n // the array should mirror the parameters below\n // note: all values past the year are optional and will default to the lowest possible value.\n // [year, month, day , hour, minute, second, millisecond]\n function configFromArray(config) {\n var i,\n date,\n input = [],\n currentDate,\n expectedWeekday,\n yearToUse;\n if (config._d) {\n return;\n }\n currentDate = currentDateArray(config);\n\n //compute day of the year from weeks and weekdays\n if (config._w && config._a[DATE] == null && config._a[MONTH] == null) {\n dayOfYearFromWeekInfo(config);\n }\n\n //if the day of the year is set, figure out what it is\n if (config._dayOfYear != null) {\n yearToUse = defaults(config._a[YEAR], currentDate[YEAR]);\n if (config._dayOfYear > daysInYear(yearToUse) || config._dayOfYear === 0) {\n getParsingFlags(config)._overflowDayOfYear = true;\n }\n date = createUTCDate(yearToUse, 0, config._dayOfYear);\n config._a[MONTH] = date.getUTCMonth();\n config._a[DATE] = date.getUTCDate();\n }\n\n // Default to current date.\n // * if no year, month, day of month are given, default to today\n // * if day of month is given, default month and year\n // * if month is given, default only year\n // * if year is given, don't default anything\n for (i = 0; i < 3 && config._a[i] == null; ++i) {\n config._a[i] = input[i] = currentDate[i];\n }\n\n // Zero out whatever was not defaulted, including time\n for (; i < 7; i++) {\n config._a[i] = input[i] = config._a[i] == null ? i === 2 ? 1 : 0 : config._a[i];\n }\n\n // Check for 24:00:00.000\n if (config._a[HOUR] === 24 && config._a[MINUTE] === 0 && config._a[SECOND] === 0 && config._a[MILLISECOND] === 0) {\n config._nextDay = true;\n config._a[HOUR] = 0;\n }\n config._d = (config._useUTC ? createUTCDate : createDate).apply(null, input);\n expectedWeekday = config._useUTC ? config._d.getUTCDay() : config._d.getDay();\n\n // Apply timezone offset from input. The actual utcOffset can be changed\n // with parseZone.\n if (config._tzm != null) {\n config._d.setUTCMinutes(config._d.getUTCMinutes() - config._tzm);\n }\n if (config._nextDay) {\n config._a[HOUR] = 24;\n }\n\n // check for mismatching day of week\n if (config._w && typeof config._w.d !== 'undefined' && config._w.d !== expectedWeekday) {\n getParsingFlags(config).weekdayMismatch = true;\n }\n }\n function dayOfYearFromWeekInfo(config) {\n var w, weekYear, week, weekday, dow, doy, temp, weekdayOverflow, curWeek;\n w = config._w;\n if (w.GG != null || w.W != null || w.E != null) {\n dow = 1;\n doy = 4;\n\n // TODO: We need to take the current isoWeekYear, but that depends on\n // how we interpret now (local, utc, fixed offset). So create\n // a now version of current config (take local/utc/offset flags, and\n // create now).\n weekYear = defaults(w.GG, config._a[YEAR], weekOfYear(createLocal(), 1, 4).year);\n week = defaults(w.W, 1);\n weekday = defaults(w.E, 1);\n if (weekday < 1 || weekday > 7) {\n weekdayOverflow = true;\n }\n } else {\n dow = config._locale._week.dow;\n doy = config._locale._week.doy;\n curWeek = weekOfYear(createLocal(), dow, doy);\n weekYear = defaults(w.gg, config._a[YEAR], curWeek.year);\n\n // Default to current week.\n week = defaults(w.w, curWeek.week);\n if (w.d != null) {\n // weekday -- low day numbers are considered next week\n weekday = w.d;\n if (weekday < 0 || weekday > 6) {\n weekdayOverflow = true;\n }\n } else if (w.e != null) {\n // local weekday -- counting starts from beginning of week\n weekday = w.e + dow;\n if (w.e < 0 || w.e > 6) {\n weekdayOverflow = true;\n }\n } else {\n // default to beginning of week\n weekday = dow;\n }\n }\n if (week < 1 || week > weeksInYear(weekYear, dow, doy)) {\n getParsingFlags(config)._overflowWeeks = true;\n } else if (weekdayOverflow != null) {\n getParsingFlags(config)._overflowWeekday = true;\n } else {\n temp = dayOfYearFromWeeks(weekYear, week, weekday, dow, doy);\n config._a[YEAR] = temp.year;\n config._dayOfYear = temp.dayOfYear;\n }\n }\n\n // constant that refers to the ISO standard\n hooks.ISO_8601 = function () {};\n\n // constant that refers to the RFC 2822 form\n hooks.RFC_2822 = function () {};\n\n // date from string and format string\n function configFromStringAndFormat(config) {\n // TODO: Move this to another part of the creation flow to prevent circular deps\n if (config._f === hooks.ISO_8601) {\n configFromISO(config);\n return;\n }\n if (config._f === hooks.RFC_2822) {\n configFromRFC2822(config);\n return;\n }\n config._a = [];\n getParsingFlags(config).empty = true;\n\n // This array is used to make a Date, either with `new Date` or `Date.UTC`\n var string = '' + config._i,\n i,\n parsedInput,\n tokens,\n token,\n skipped,\n stringLength = string.length,\n totalParsedInputLength = 0,\n era,\n tokenLen;\n tokens = expandFormat(config._f, config._locale).match(formattingTokens) || [];\n tokenLen = tokens.length;\n for (i = 0; i < tokenLen; i++) {\n token = tokens[i];\n parsedInput = (string.match(getParseRegexForToken(token, config)) || [])[0];\n if (parsedInput) {\n skipped = string.substr(0, string.indexOf(parsedInput));\n if (skipped.length > 0) {\n getParsingFlags(config).unusedInput.push(skipped);\n }\n string = string.slice(string.indexOf(parsedInput) + parsedInput.length);\n totalParsedInputLength += parsedInput.length;\n }\n // don't parse if it's not a known token\n if (formatTokenFunctions[token]) {\n if (parsedInput) {\n getParsingFlags(config).empty = false;\n } else {\n getParsingFlags(config).unusedTokens.push(token);\n }\n addTimeToArrayFromToken(token, parsedInput, config);\n } else if (config._strict && !parsedInput) {\n getParsingFlags(config).unusedTokens.push(token);\n }\n }\n\n // add remaining unparsed input length to the string\n getParsingFlags(config).charsLeftOver = stringLength - totalParsedInputLength;\n if (string.length > 0) {\n getParsingFlags(config).unusedInput.push(string);\n }\n\n // clear _12h flag if hour is <= 12\n if (config._a[HOUR] <= 12 && getParsingFlags(config).bigHour === true && config._a[HOUR] > 0) {\n getParsingFlags(config).bigHour = undefined;\n }\n getParsingFlags(config).parsedDateParts = config._a.slice(0);\n getParsingFlags(config).meridiem = config._meridiem;\n // handle meridiem\n config._a[HOUR] = meridiemFixWrap(config._locale, config._a[HOUR], config._meridiem);\n\n // handle era\n era = getParsingFlags(config).era;\n if (era !== null) {\n config._a[YEAR] = config._locale.erasConvertYear(era, config._a[YEAR]);\n }\n configFromArray(config);\n checkOverflow(config);\n }\n function meridiemFixWrap(locale, hour, meridiem) {\n var isPm;\n if (meridiem == null) {\n // nothing to do\n return hour;\n }\n if (locale.meridiemHour != null) {\n return locale.meridiemHour(hour, meridiem);\n } else if (locale.isPM != null) {\n // Fallback\n isPm = locale.isPM(meridiem);\n if (isPm && hour < 12) {\n hour += 12;\n }\n if (!isPm && hour === 12) {\n hour = 0;\n }\n return hour;\n } else {\n // this is not supposed to happen\n return hour;\n }\n }\n\n // date from string and array of format strings\n function configFromStringAndArray(config) {\n var tempConfig,\n bestMoment,\n scoreToBeat,\n i,\n currentScore,\n validFormatFound,\n bestFormatIsValid = false,\n configfLen = config._f.length;\n if (configfLen === 0) {\n getParsingFlags(config).invalidFormat = true;\n config._d = new Date(NaN);\n return;\n }\n for (i = 0; i < configfLen; i++) {\n currentScore = 0;\n validFormatFound = false;\n tempConfig = copyConfig({}, config);\n if (config._useUTC != null) {\n tempConfig._useUTC = config._useUTC;\n }\n tempConfig._f = config._f[i];\n configFromStringAndFormat(tempConfig);\n if (isValid(tempConfig)) {\n validFormatFound = true;\n }\n\n // if there is any input that was not parsed add a penalty for that format\n currentScore += getParsingFlags(tempConfig).charsLeftOver;\n\n //or tokens\n currentScore += getParsingFlags(tempConfig).unusedTokens.length * 10;\n getParsingFlags(tempConfig).score = currentScore;\n if (!bestFormatIsValid) {\n if (scoreToBeat == null || currentScore < scoreToBeat || validFormatFound) {\n scoreToBeat = currentScore;\n bestMoment = tempConfig;\n if (validFormatFound) {\n bestFormatIsValid = true;\n }\n }\n } else {\n if (currentScore < scoreToBeat) {\n scoreToBeat = currentScore;\n bestMoment = tempConfig;\n }\n }\n }\n extend(config, bestMoment || tempConfig);\n }\n function configFromObject(config) {\n if (config._d) {\n return;\n }\n var i = normalizeObjectUnits(config._i),\n dayOrDate = i.day === undefined ? i.date : i.day;\n config._a = map([i.year, i.month, dayOrDate, i.hour, i.minute, i.second, i.millisecond], function (obj) {\n return obj && parseInt(obj, 10);\n });\n configFromArray(config);\n }\n function createFromConfig(config) {\n var res = new Moment(checkOverflow(prepareConfig(config)));\n if (res._nextDay) {\n // Adding is smart enough around DST\n res.add(1, 'd');\n res._nextDay = undefined;\n }\n return res;\n }\n function prepareConfig(config) {\n var input = config._i,\n format = config._f;\n config._locale = config._locale || getLocale(config._l);\n if (input === null || format === undefined && input === '') {\n return createInvalid({\n nullInput: true\n });\n }\n if (typeof input === 'string') {\n config._i = input = config._locale.preparse(input);\n }\n if (isMoment(input)) {\n return new Moment(checkOverflow(input));\n } else if (isDate(input)) {\n config._d = input;\n } else if (isArray(format)) {\n configFromStringAndArray(config);\n } else if (format) {\n configFromStringAndFormat(config);\n } else {\n configFromInput(config);\n }\n if (!isValid(config)) {\n config._d = null;\n }\n return config;\n }\n function configFromInput(config) {\n var input = config._i;\n if (isUndefined(input)) {\n config._d = new Date(hooks.now());\n } else if (isDate(input)) {\n config._d = new Date(input.valueOf());\n } else if (typeof input === 'string') {\n configFromString(config);\n } else if (isArray(input)) {\n config._a = map(input.slice(0), function (obj) {\n return parseInt(obj, 10);\n });\n configFromArray(config);\n } else if (isObject(input)) {\n configFromObject(config);\n } else if (isNumber(input)) {\n // from milliseconds\n config._d = new Date(input);\n } else {\n hooks.createFromInputFallback(config);\n }\n }\n function createLocalOrUTC(input, format, locale, strict, isUTC) {\n var c = {};\n if (format === true || format === false) {\n strict = format;\n format = undefined;\n }\n if (locale === true || locale === false) {\n strict = locale;\n locale = undefined;\n }\n if (isObject(input) && isObjectEmpty(input) || isArray(input) && input.length === 0) {\n input = undefined;\n }\n // object construction must be done this way.\n // https://github.com/moment/moment/issues/1423\n c._isAMomentObject = true;\n c._useUTC = c._isUTC = isUTC;\n c._l = locale;\n c._i = input;\n c._f = format;\n c._strict = strict;\n return createFromConfig(c);\n }\n function createLocal(input, format, locale, strict) {\n return createLocalOrUTC(input, format, locale, strict, false);\n }\n var prototypeMin = deprecate('moment().min is deprecated, use moment.max instead. http://momentjs.com/guides/#/warnings/min-max/', function () {\n var other = createLocal.apply(null, arguments);\n if (this.isValid() && other.isValid()) {\n return other < this ? this : other;\n } else {\n return createInvalid();\n }\n }),\n prototypeMax = deprecate('moment().max is deprecated, use moment.min instead. http://momentjs.com/guides/#/warnings/min-max/', function () {\n var other = createLocal.apply(null, arguments);\n if (this.isValid() && other.isValid()) {\n return other > this ? this : other;\n } else {\n return createInvalid();\n }\n });\n\n // Pick a moment m from moments so that m[fn](other) is true for all\n // other. This relies on the function fn to be transitive.\n //\n // moments should either be an array of moment objects or an array, whose\n // first element is an array of moment objects.\n function pickBy(fn, moments) {\n var res, i;\n if (moments.length === 1 && isArray(moments[0])) {\n moments = moments[0];\n }\n if (!moments.length) {\n return createLocal();\n }\n res = moments[0];\n for (i = 1; i < moments.length; ++i) {\n if (!moments[i].isValid() || moments[i][fn](res)) {\n res = moments[i];\n }\n }\n return res;\n }\n\n // TODO: Use [].sort instead?\n function min() {\n var args = [].slice.call(arguments, 0);\n return pickBy('isBefore', args);\n }\n function max() {\n var args = [].slice.call(arguments, 0);\n return pickBy('isAfter', args);\n }\n var now = function () {\n return Date.now ? Date.now() : +new Date();\n };\n var ordering = ['year', 'quarter', 'month', 'week', 'day', 'hour', 'minute', 'second', 'millisecond'];\n function isDurationValid(m) {\n var key,\n unitHasDecimal = false,\n i,\n orderLen = ordering.length;\n for (key in m) {\n if (hasOwnProp(m, key) && !(indexOf.call(ordering, key) !== -1 && (m[key] == null || !isNaN(m[key])))) {\n return false;\n }\n }\n for (i = 0; i < orderLen; ++i) {\n if (m[ordering[i]]) {\n if (unitHasDecimal) {\n return false; // only allow non-integers for smallest unit\n }\n if (parseFloat(m[ordering[i]]) !== toInt(m[ordering[i]])) {\n unitHasDecimal = true;\n }\n }\n }\n return true;\n }\n function isValid$1() {\n return this._isValid;\n }\n function createInvalid$1() {\n return createDuration(NaN);\n }\n function Duration(duration) {\n var normalizedInput = normalizeObjectUnits(duration),\n years = normalizedInput.year || 0,\n quarters = normalizedInput.quarter || 0,\n months = normalizedInput.month || 0,\n weeks = normalizedInput.week || normalizedInput.isoWeek || 0,\n days = normalizedInput.day || 0,\n hours = normalizedInput.hour || 0,\n minutes = normalizedInput.minute || 0,\n seconds = normalizedInput.second || 0,\n milliseconds = normalizedInput.millisecond || 0;\n this._isValid = isDurationValid(normalizedInput);\n\n // representation for dateAddRemove\n this._milliseconds = +milliseconds + seconds * 1e3 +\n // 1000\n minutes * 6e4 +\n // 1000 * 60\n hours * 1000 * 60 * 60; //using 1000 * 60 * 60 instead of 36e5 to avoid floating point rounding errors https://github.com/moment/moment/issues/2978\n // Because of dateAddRemove treats 24 hours as different from a\n // day when working around DST, we need to store them separately\n this._days = +days + weeks * 7;\n // It is impossible to translate months into days without knowing\n // which months you are are talking about, so we have to store\n // it separately.\n this._months = +months + quarters * 3 + years * 12;\n this._data = {};\n this._locale = getLocale();\n this._bubble();\n }\n function isDuration(obj) {\n return obj instanceof Duration;\n }\n function absRound(number) {\n if (number < 0) {\n return Math.round(-1 * number) * -1;\n } else {\n return Math.round(number);\n }\n }\n\n // compare two arrays, return the number of differences\n function compareArrays(array1, array2, dontConvert) {\n var len = Math.min(array1.length, array2.length),\n lengthDiff = Math.abs(array1.length - array2.length),\n diffs = 0,\n i;\n for (i = 0; i < len; i++) {\n if (dontConvert && array1[i] !== array2[i] || !dontConvert && toInt(array1[i]) !== toInt(array2[i])) {\n diffs++;\n }\n }\n return diffs + lengthDiff;\n }\n\n // FORMATTING\n\n function offset(token, separator) {\n addFormatToken(token, 0, 0, function () {\n var offset = this.utcOffset(),\n sign = '+';\n if (offset < 0) {\n offset = -offset;\n sign = '-';\n }\n return sign + zeroFill(~~(offset / 60), 2) + separator + zeroFill(~~offset % 60, 2);\n });\n }\n offset('Z', ':');\n offset('ZZ', '');\n\n // PARSING\n\n addRegexToken('Z', matchShortOffset);\n addRegexToken('ZZ', matchShortOffset);\n addParseToken(['Z', 'ZZ'], function (input, array, config) {\n config._useUTC = true;\n config._tzm = offsetFromString(matchShortOffset, input);\n });\n\n // HELPERS\n\n // timezone chunker\n // '+10:00' > ['10', '00']\n // '-1530' > ['-15', '30']\n var chunkOffset = /([\\+\\-]|\\d\\d)/gi;\n function offsetFromString(matcher, string) {\n var matches = (string || '').match(matcher),\n chunk,\n parts,\n minutes;\n if (matches === null) {\n return null;\n }\n chunk = matches[matches.length - 1] || [];\n parts = (chunk + '').match(chunkOffset) || ['-', 0, 0];\n minutes = +(parts[1] * 60) + toInt(parts[2]);\n return minutes === 0 ? 0 : parts[0] === '+' ? minutes : -minutes;\n }\n\n // Return a moment from input, that is local/utc/zone equivalent to model.\n function cloneWithOffset(input, model) {\n var res, diff;\n if (model._isUTC) {\n res = model.clone();\n diff = (isMoment(input) || isDate(input) ? input.valueOf() : createLocal(input).valueOf()) - res.valueOf();\n // Use low-level api, because this fn is low-level api.\n res._d.setTime(res._d.valueOf() + diff);\n hooks.updateOffset(res, false);\n return res;\n } else {\n return createLocal(input).local();\n }\n }\n function getDateOffset(m) {\n // On Firefox.24 Date#getTimezoneOffset returns a floating point.\n // https://github.com/moment/moment/pull/1871\n return -Math.round(m._d.getTimezoneOffset());\n }\n\n // HOOKS\n\n // This function will be called whenever a moment is mutated.\n // It is intended to keep the offset in sync with the timezone.\n hooks.updateOffset = function () {};\n\n // MOMENTS\n\n // keepLocalTime = true means only change the timezone, without\n // affecting the local hour. So 5:31:26 +0300 --[utcOffset(2, true)]-->\n // 5:31:26 +0200 It is possible that 5:31:26 doesn't exist with offset\n // +0200, so we adjust the time as needed, to be valid.\n //\n // Keeping the time actually adds/subtracts (one hour)\n // from the actual represented time. That is why we call updateOffset\n // a second time. In case it wants us to change the offset again\n // _changeInProgress == true case, then we have to adjust, because\n // there is no such time in the given timezone.\n function getSetOffset(input, keepLocalTime, keepMinutes) {\n var offset = this._offset || 0,\n localAdjust;\n if (!this.isValid()) {\n return input != null ? this : NaN;\n }\n if (input != null) {\n if (typeof input === 'string') {\n input = offsetFromString(matchShortOffset, input);\n if (input === null) {\n return this;\n }\n } else if (Math.abs(input) < 16 && !keepMinutes) {\n input = input * 60;\n }\n if (!this._isUTC && keepLocalTime) {\n localAdjust = getDateOffset(this);\n }\n this._offset = input;\n this._isUTC = true;\n if (localAdjust != null) {\n this.add(localAdjust, 'm');\n }\n if (offset !== input) {\n if (!keepLocalTime || this._changeInProgress) {\n addSubtract(this, createDuration(input - offset, 'm'), 1, false);\n } else if (!this._changeInProgress) {\n this._changeInProgress = true;\n hooks.updateOffset(this, true);\n this._changeInProgress = null;\n }\n }\n return this;\n } else {\n return this._isUTC ? offset : getDateOffset(this);\n }\n }\n function getSetZone(input, keepLocalTime) {\n if (input != null) {\n if (typeof input !== 'string') {\n input = -input;\n }\n this.utcOffset(input, keepLocalTime);\n return this;\n } else {\n return -this.utcOffset();\n }\n }\n function setOffsetToUTC(keepLocalTime) {\n return this.utcOffset(0, keepLocalTime);\n }\n function setOffsetToLocal(keepLocalTime) {\n if (this._isUTC) {\n this.utcOffset(0, keepLocalTime);\n this._isUTC = false;\n if (keepLocalTime) {\n this.subtract(getDateOffset(this), 'm');\n }\n }\n return this;\n }\n function setOffsetToParsedOffset() {\n if (this._tzm != null) {\n this.utcOffset(this._tzm, false, true);\n } else if (typeof this._i === 'string') {\n var tZone = offsetFromString(matchOffset, this._i);\n if (tZone != null) {\n this.utcOffset(tZone);\n } else {\n this.utcOffset(0, true);\n }\n }\n return this;\n }\n function hasAlignedHourOffset(input) {\n if (!this.isValid()) {\n return false;\n }\n input = input ? createLocal(input).utcOffset() : 0;\n return (this.utcOffset() - input) % 60 === 0;\n }\n function isDaylightSavingTime() {\n return this.utcOffset() > this.clone().month(0).utcOffset() || this.utcOffset() > this.clone().month(5).utcOffset();\n }\n function isDaylightSavingTimeShifted() {\n if (!isUndefined(this._isDSTShifted)) {\n return this._isDSTShifted;\n }\n var c = {},\n other;\n copyConfig(c, this);\n c = prepareConfig(c);\n if (c._a) {\n other = c._isUTC ? createUTC(c._a) : createLocal(c._a);\n this._isDSTShifted = this.isValid() && compareArrays(c._a, other.toArray()) > 0;\n } else {\n this._isDSTShifted = false;\n }\n return this._isDSTShifted;\n }\n function isLocal() {\n return this.isValid() ? !this._isUTC : false;\n }\n function isUtcOffset() {\n return this.isValid() ? this._isUTC : false;\n }\n function isUtc() {\n return this.isValid() ? this._isUTC && this._offset === 0 : false;\n }\n\n // ASP.NET json date format regex\n var aspNetRegex = /^(-|\\+)?(?:(\\d*)[. ])?(\\d+):(\\d+)(?::(\\d+)(\\.\\d*)?)?$/,\n // from http://docs.closure-library.googlecode.com/git/closure_goog_date_date.js.source.html\n // somewhat more in line with 4.4.3.2 2004 spec, but allows decimal anywhere\n // and further modified to allow for strings containing both week and day\n isoRegex = /^(-|\\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;\n function createDuration(input, key) {\n var duration = input,\n // matching against regexp is expensive, do it on demand\n match = null,\n sign,\n ret,\n diffRes;\n if (isDuration(input)) {\n duration = {\n ms: input._milliseconds,\n d: input._days,\n M: input._months\n };\n } else if (isNumber(input) || !isNaN(+input)) {\n duration = {};\n if (key) {\n duration[key] = +input;\n } else {\n duration.milliseconds = +input;\n }\n } else if (match = aspNetRegex.exec(input)) {\n sign = match[1] === '-' ? -1 : 1;\n duration = {\n y: 0,\n d: toInt(match[DATE]) * sign,\n h: toInt(match[HOUR]) * sign,\n m: toInt(match[MINUTE]) * sign,\n s: toInt(match[SECOND]) * sign,\n ms: toInt(absRound(match[MILLISECOND] * 1000)) * sign // the millisecond decimal point is included in the match\n };\n } else if (match = isoRegex.exec(input)) {\n sign = match[1] === '-' ? -1 : 1;\n duration = {\n y: parseIso(match[2], sign),\n M: parseIso(match[3], sign),\n w: parseIso(match[4], sign),\n d: parseIso(match[5], sign),\n h: parseIso(match[6], sign),\n m: parseIso(match[7], sign),\n s: parseIso(match[8], sign)\n };\n } else if (duration == null) {\n // checks for null or undefined\n duration = {};\n } else if (typeof duration === 'object' && ('from' in duration || 'to' in duration)) {\n diffRes = momentsDifference(createLocal(duration.from), createLocal(duration.to));\n duration = {};\n duration.ms = diffRes.milliseconds;\n duration.M = diffRes.months;\n }\n ret = new Duration(duration);\n if (isDuration(input) && hasOwnProp(input, '_locale')) {\n ret._locale = input._locale;\n }\n if (isDuration(input) && hasOwnProp(input, '_isValid')) {\n ret._isValid = input._isValid;\n }\n return ret;\n }\n createDuration.fn = Duration.prototype;\n createDuration.invalid = createInvalid$1;\n function parseIso(inp, sign) {\n // We'd normally use ~~inp for this, but unfortunately it also\n // converts floats to ints.\n // inp may be undefined, so careful calling replace on it.\n var res = inp && parseFloat(inp.replace(',', '.'));\n // apply sign while we're at it\n return (isNaN(res) ? 0 : res) * sign;\n }\n function positiveMomentsDifference(base, other) {\n var res = {};\n res.months = other.month() - base.month() + (other.year() - base.year()) * 12;\n if (base.clone().add(res.months, 'M').isAfter(other)) {\n --res.months;\n }\n res.milliseconds = +other - +base.clone().add(res.months, 'M');\n return res;\n }\n function momentsDifference(base, other) {\n var res;\n if (!(base.isValid() && other.isValid())) {\n return {\n milliseconds: 0,\n months: 0\n };\n }\n other = cloneWithOffset(other, base);\n if (base.isBefore(other)) {\n res = positiveMomentsDifference(base, other);\n } else {\n res = positiveMomentsDifference(other, base);\n res.milliseconds = -res.milliseconds;\n res.months = -res.months;\n }\n return res;\n }\n\n // TODO: remove 'name' arg after deprecation is removed\n function createAdder(direction, name) {\n return function (val, period) {\n var dur, tmp;\n //invert the arguments, but complain about it\n if (period !== null && !isNaN(+period)) {\n deprecateSimple(name, 'moment().' + name + '(period, number) is deprecated. Please use moment().' + name + '(number, period). ' + 'See http://momentjs.com/guides/#/warnings/add-inverted-param/ for more info.');\n tmp = val;\n val = period;\n period = tmp;\n }\n dur = createDuration(val, period);\n addSubtract(this, dur, direction);\n return this;\n };\n }\n function addSubtract(mom, duration, isAdding, updateOffset) {\n var milliseconds = duration._milliseconds,\n days = absRound(duration._days),\n months = absRound(duration._months);\n if (!mom.isValid()) {\n // No op\n return;\n }\n updateOffset = updateOffset == null ? true : updateOffset;\n if (months) {\n setMonth(mom, get(mom, 'Month') + months * isAdding);\n }\n if (days) {\n set$1(mom, 'Date', get(mom, 'Date') + days * isAdding);\n }\n if (milliseconds) {\n mom._d.setTime(mom._d.valueOf() + milliseconds * isAdding);\n }\n if (updateOffset) {\n hooks.updateOffset(mom, days || months);\n }\n }\n var add = createAdder(1, 'add'),\n subtract = createAdder(-1, 'subtract');\n function isString(input) {\n return typeof input === 'string' || input instanceof String;\n }\n\n // type MomentInput = Moment | Date | string | number | (number | string)[] | MomentInputObject | void; // null | undefined\n function isMomentInput(input) {\n return isMoment(input) || isDate(input) || isString(input) || isNumber(input) || isNumberOrStringArray(input) || isMomentInputObject(input) || input === null || input === undefined;\n }\n function isMomentInputObject(input) {\n var objectTest = isObject(input) && !isObjectEmpty(input),\n propertyTest = false,\n properties = ['years', 'year', 'y', 'months', 'month', 'M', 'days', 'day', 'd', 'dates', 'date', 'D', 'hours', 'hour', 'h', 'minutes', 'minute', 'm', 'seconds', 'second', 's', 'milliseconds', 'millisecond', 'ms'],\n i,\n property,\n propertyLen = properties.length;\n for (i = 0; i < propertyLen; i += 1) {\n property = properties[i];\n propertyTest = propertyTest || hasOwnProp(input, property);\n }\n return objectTest && propertyTest;\n }\n function isNumberOrStringArray(input) {\n var arrayTest = isArray(input),\n dataTypeTest = false;\n if (arrayTest) {\n dataTypeTest = input.filter(function (item) {\n return !isNumber(item) && isString(input);\n }).length === 0;\n }\n return arrayTest && dataTypeTest;\n }\n function isCalendarSpec(input) {\n var objectTest = isObject(input) && !isObjectEmpty(input),\n propertyTest = false,\n properties = ['sameDay', 'nextDay', 'lastDay', 'nextWeek', 'lastWeek', 'sameElse'],\n i,\n property;\n for (i = 0; i < properties.length; i += 1) {\n property = properties[i];\n propertyTest = propertyTest || hasOwnProp(input, property);\n }\n return objectTest && propertyTest;\n }\n function getCalendarFormat(myMoment, now) {\n var diff = myMoment.diff(now, 'days', true);\n return diff < -6 ? 'sameElse' : diff < -1 ? 'lastWeek' : diff < 0 ? 'lastDay' : diff < 1 ? 'sameDay' : diff < 2 ? 'nextDay' : diff < 7 ? 'nextWeek' : 'sameElse';\n }\n function calendar$1(time, formats) {\n // Support for single parameter, formats only overload to the calendar function\n if (arguments.length === 1) {\n if (!arguments[0]) {\n time = undefined;\n formats = undefined;\n } else if (isMomentInput(arguments[0])) {\n time = arguments[0];\n formats = undefined;\n } else if (isCalendarSpec(arguments[0])) {\n formats = arguments[0];\n time = undefined;\n }\n }\n // We want to compare the start of today, vs this.\n // Getting start-of-today depends on whether we're local/utc/offset or not.\n var now = time || createLocal(),\n sod = cloneWithOffset(now, this).startOf('day'),\n format = hooks.calendarFormat(this, sod) || 'sameElse',\n output = formats && (isFunction(formats[format]) ? formats[format].call(this, now) : formats[format]);\n return this.format(output || this.localeData().calendar(format, this, createLocal(now)));\n }\n function clone() {\n return new Moment(this);\n }\n function isAfter(input, units) {\n var localInput = isMoment(input) ? input : createLocal(input);\n if (!(this.isValid() && localInput.isValid())) {\n return false;\n }\n units = normalizeUnits(units) || 'millisecond';\n if (units === 'millisecond') {\n return this.valueOf() > localInput.valueOf();\n } else {\n return localInput.valueOf() < this.clone().startOf(units).valueOf();\n }\n }\n function isBefore(input, units) {\n var localInput = isMoment(input) ? input : createLocal(input);\n if (!(this.isValid() && localInput.isValid())) {\n return false;\n }\n units = normalizeUnits(units) || 'millisecond';\n if (units === 'millisecond') {\n return this.valueOf() < localInput.valueOf();\n } else {\n return this.clone().endOf(units).valueOf() < localInput.valueOf();\n }\n }\n function isBetween(from, to, units, inclusivity) {\n var localFrom = isMoment(from) ? from : createLocal(from),\n localTo = isMoment(to) ? to : createLocal(to);\n if (!(this.isValid() && localFrom.isValid() && localTo.isValid())) {\n return false;\n }\n inclusivity = inclusivity || '()';\n return (inclusivity[0] === '(' ? this.isAfter(localFrom, units) : !this.isBefore(localFrom, units)) && (inclusivity[1] === ')' ? this.isBefore(localTo, units) : !this.isAfter(localTo, units));\n }\n function isSame(input, units) {\n var localInput = isMoment(input) ? input : createLocal(input),\n inputMs;\n if (!(this.isValid() && localInput.isValid())) {\n return false;\n }\n units = normalizeUnits(units) || 'millisecond';\n if (units === 'millisecond') {\n return this.valueOf() === localInput.valueOf();\n } else {\n inputMs = localInput.valueOf();\n return this.clone().startOf(units).valueOf() <= inputMs && inputMs <= this.clone().endOf(units).valueOf();\n }\n }\n function isSameOrAfter(input, units) {\n return this.isSame(input, units) || this.isAfter(input, units);\n }\n function isSameOrBefore(input, units) {\n return this.isSame(input, units) || this.isBefore(input, units);\n }\n function diff(input, units, asFloat) {\n var that, zoneDelta, output;\n if (!this.isValid()) {\n return NaN;\n }\n that = cloneWithOffset(input, this);\n if (!that.isValid()) {\n return NaN;\n }\n zoneDelta = (that.utcOffset() - this.utcOffset()) * 6e4;\n units = normalizeUnits(units);\n switch (units) {\n case 'year':\n output = monthDiff(this, that) / 12;\n break;\n case 'month':\n output = monthDiff(this, that);\n break;\n case 'quarter':\n output = monthDiff(this, that) / 3;\n break;\n case 'second':\n output = (this - that) / 1e3;\n break;\n // 1000\n case 'minute':\n output = (this - that) / 6e4;\n break;\n // 1000 * 60\n case 'hour':\n output = (this - that) / 36e5;\n break;\n // 1000 * 60 * 60\n case 'day':\n output = (this - that - zoneDelta) / 864e5;\n break;\n // 1000 * 60 * 60 * 24, negate dst\n case 'week':\n output = (this - that - zoneDelta) / 6048e5;\n break;\n // 1000 * 60 * 60 * 24 * 7, negate dst\n default:\n output = this - that;\n }\n return asFloat ? output : absFloor(output);\n }\n function monthDiff(a, b) {\n if (a.date() < b.date()) {\n // end-of-month calculations work correct when the start month has more\n // days than the end month.\n return -monthDiff(b, a);\n }\n // difference in months\n var wholeMonthDiff = (b.year() - a.year()) * 12 + (b.month() - a.month()),\n // b is in (anchor - 1 month, anchor + 1 month)\n anchor = a.clone().add(wholeMonthDiff, 'months'),\n anchor2,\n adjust;\n if (b - anchor < 0) {\n anchor2 = a.clone().add(wholeMonthDiff - 1, 'months');\n // linear across the month\n adjust = (b - anchor) / (anchor - anchor2);\n } else {\n anchor2 = a.clone().add(wholeMonthDiff + 1, 'months');\n // linear across the month\n adjust = (b - anchor) / (anchor2 - anchor);\n }\n\n //check for negative zero, return zero if negative zero\n return -(wholeMonthDiff + adjust) || 0;\n }\n hooks.defaultFormat = 'YYYY-MM-DDTHH:mm:ssZ';\n hooks.defaultFormatUtc = 'YYYY-MM-DDTHH:mm:ss[Z]';\n function toString() {\n return this.clone().locale('en').format('ddd MMM DD YYYY HH:mm:ss [GMT]ZZ');\n }\n function toISOString(keepOffset) {\n if (!this.isValid()) {\n return null;\n }\n var utc = keepOffset !== true,\n m = utc ? this.clone().utc() : this;\n if (m.year() < 0 || m.year() > 9999) {\n return formatMoment(m, utc ? 'YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]' : 'YYYYYY-MM-DD[T]HH:mm:ss.SSSZ');\n }\n if (isFunction(Date.prototype.toISOString)) {\n // native implementation is ~50x faster, use it when we can\n if (utc) {\n return this.toDate().toISOString();\n } else {\n return new Date(this.valueOf() + this.utcOffset() * 60 * 1000).toISOString().replace('Z', formatMoment(m, 'Z'));\n }\n }\n return formatMoment(m, utc ? 'YYYY-MM-DD[T]HH:mm:ss.SSS[Z]' : 'YYYY-MM-DD[T]HH:mm:ss.SSSZ');\n }\n\n /**\n * Return a human readable representation of a moment that can\n * also be evaluated to get a new moment which is the same\n *\n * @link https://nodejs.org/dist/latest/docs/api/util.html#util_custom_inspect_function_on_objects\n */\n function inspect() {\n if (!this.isValid()) {\n return 'moment.invalid(/* ' + this._i + ' */)';\n }\n var func = 'moment',\n zone = '',\n prefix,\n year,\n datetime,\n suffix;\n if (!this.isLocal()) {\n func = this.utcOffset() === 0 ? 'moment.utc' : 'moment.parseZone';\n zone = 'Z';\n }\n prefix = '[' + func + '(\"]';\n year = 0 <= this.year() && this.year() <= 9999 ? 'YYYY' : 'YYYYYY';\n datetime = '-MM-DD[T]HH:mm:ss.SSS';\n suffix = zone + '[\")]';\n return this.format(prefix + year + datetime + suffix);\n }\n function format(inputString) {\n if (!inputString) {\n inputString = this.isUtc() ? hooks.defaultFormatUtc : hooks.defaultFormat;\n }\n var output = formatMoment(this, inputString);\n return this.localeData().postformat(output);\n }\n function from(time, withoutSuffix) {\n if (this.isValid() && (isMoment(time) && time.isValid() || createLocal(time).isValid())) {\n return createDuration({\n to: this,\n from: time\n }).locale(this.locale()).humanize(!withoutSuffix);\n } else {\n return this.localeData().invalidDate();\n }\n }\n function fromNow(withoutSuffix) {\n return this.from(createLocal(), withoutSuffix);\n }\n function to(time, withoutSuffix) {\n if (this.isValid() && (isMoment(time) && time.isValid() || createLocal(time).isValid())) {\n return createDuration({\n from: this,\n to: time\n }).locale(this.locale()).humanize(!withoutSuffix);\n } else {\n return this.localeData().invalidDate();\n }\n }\n function toNow(withoutSuffix) {\n return this.to(createLocal(), withoutSuffix);\n }\n\n // If passed a locale key, it will set the locale for this\n // instance. Otherwise, it will return the locale configuration\n // variables for this instance.\n function locale(key) {\n var newLocaleData;\n if (key === undefined) {\n return this._locale._abbr;\n } else {\n newLocaleData = getLocale(key);\n if (newLocaleData != null) {\n this._locale = newLocaleData;\n }\n return this;\n }\n }\n var lang = deprecate('moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.', function (key) {\n if (key === undefined) {\n return this.localeData();\n } else {\n return this.locale(key);\n }\n });\n function localeData() {\n return this._locale;\n }\n var MS_PER_SECOND = 1000,\n MS_PER_MINUTE = 60 * MS_PER_SECOND,\n MS_PER_HOUR = 60 * MS_PER_MINUTE,\n MS_PER_400_YEARS = (365 * 400 + 97) * 24 * MS_PER_HOUR;\n\n // actual modulo - handles negative numbers (for dates before 1970):\n function mod$1(dividend, divisor) {\n return (dividend % divisor + divisor) % divisor;\n }\n function localStartOfDate(y, m, d) {\n // the date constructor remaps years 0-99 to 1900-1999\n if (y < 100 && y >= 0) {\n // preserve leap years using a full 400 year cycle, then reset\n return new Date(y + 400, m, d) - MS_PER_400_YEARS;\n } else {\n return new Date(y, m, d).valueOf();\n }\n }\n function utcStartOfDate(y, m, d) {\n // Date.UTC remaps years 0-99 to 1900-1999\n if (y < 100 && y >= 0) {\n // preserve leap years using a full 400 year cycle, then reset\n return Date.UTC(y + 400, m, d) - MS_PER_400_YEARS;\n } else {\n return Date.UTC(y, m, d);\n }\n }\n function startOf(units) {\n var time, startOfDate;\n units = normalizeUnits(units);\n if (units === undefined || units === 'millisecond' || !this.isValid()) {\n return this;\n }\n startOfDate = this._isUTC ? utcStartOfDate : localStartOfDate;\n switch (units) {\n case 'year':\n time = startOfDate(this.year(), 0, 1);\n break;\n case 'quarter':\n time = startOfDate(this.year(), this.month() - this.month() % 3, 1);\n break;\n case 'month':\n time = startOfDate(this.year(), this.month(), 1);\n break;\n case 'week':\n time = startOfDate(this.year(), this.month(), this.date() - this.weekday());\n break;\n case 'isoWeek':\n time = startOfDate(this.year(), this.month(), this.date() - (this.isoWeekday() - 1));\n break;\n case 'day':\n case 'date':\n time = startOfDate(this.year(), this.month(), this.date());\n break;\n case 'hour':\n time = this._d.valueOf();\n time -= mod$1(time + (this._isUTC ? 0 : this.utcOffset() * MS_PER_MINUTE), MS_PER_HOUR);\n break;\n case 'minute':\n time = this._d.valueOf();\n time -= mod$1(time, MS_PER_MINUTE);\n break;\n case 'second':\n time = this._d.valueOf();\n time -= mod$1(time, MS_PER_SECOND);\n break;\n }\n this._d.setTime(time);\n hooks.updateOffset(this, true);\n return this;\n }\n function endOf(units) {\n var time, startOfDate;\n units = normalizeUnits(units);\n if (units === undefined || units === 'millisecond' || !this.isValid()) {\n return this;\n }\n startOfDate = this._isUTC ? utcStartOfDate : localStartOfDate;\n switch (units) {\n case 'year':\n time = startOfDate(this.year() + 1, 0, 1) - 1;\n break;\n case 'quarter':\n time = startOfDate(this.year(), this.month() - this.month() % 3 + 3, 1) - 1;\n break;\n case 'month':\n time = startOfDate(this.year(), this.month() + 1, 1) - 1;\n break;\n case 'week':\n time = startOfDate(this.year(), this.month(), this.date() - this.weekday() + 7) - 1;\n break;\n case 'isoWeek':\n time = startOfDate(this.year(), this.month(), this.date() - (this.isoWeekday() - 1) + 7) - 1;\n break;\n case 'day':\n case 'date':\n time = startOfDate(this.year(), this.month(), this.date() + 1) - 1;\n break;\n case 'hour':\n time = this._d.valueOf();\n time += MS_PER_HOUR - mod$1(time + (this._isUTC ? 0 : this.utcOffset() * MS_PER_MINUTE), MS_PER_HOUR) - 1;\n break;\n case 'minute':\n time = this._d.valueOf();\n time += MS_PER_MINUTE - mod$1(time, MS_PER_MINUTE) - 1;\n break;\n case 'second':\n time = this._d.valueOf();\n time += MS_PER_SECOND - mod$1(time, MS_PER_SECOND) - 1;\n break;\n }\n this._d.setTime(time);\n hooks.updateOffset(this, true);\n return this;\n }\n function valueOf() {\n return this._d.valueOf() - (this._offset || 0) * 60000;\n }\n function unix() {\n return Math.floor(this.valueOf() / 1000);\n }\n function toDate() {\n return new Date(this.valueOf());\n }\n function toArray() {\n var m = this;\n return [m.year(), m.month(), m.date(), m.hour(), m.minute(), m.second(), m.millisecond()];\n }\n function toObject() {\n var m = this;\n return {\n years: m.year(),\n months: m.month(),\n date: m.date(),\n hours: m.hours(),\n minutes: m.minutes(),\n seconds: m.seconds(),\n milliseconds: m.milliseconds()\n };\n }\n function toJSON() {\n // new Date(NaN).toJSON() === null\n return this.isValid() ? this.toISOString() : null;\n }\n function isValid$2() {\n return isValid(this);\n }\n function parsingFlags() {\n return extend({}, getParsingFlags(this));\n }\n function invalidAt() {\n return getParsingFlags(this).overflow;\n }\n function creationData() {\n return {\n input: this._i,\n format: this._f,\n locale: this._locale,\n isUTC: this._isUTC,\n strict: this._strict\n };\n }\n addFormatToken('N', 0, 0, 'eraAbbr');\n addFormatToken('NN', 0, 0, 'eraAbbr');\n addFormatToken('NNN', 0, 0, 'eraAbbr');\n addFormatToken('NNNN', 0, 0, 'eraName');\n addFormatToken('NNNNN', 0, 0, 'eraNarrow');\n addFormatToken('y', ['y', 1], 'yo', 'eraYear');\n addFormatToken('y', ['yy', 2], 0, 'eraYear');\n addFormatToken('y', ['yyy', 3], 0, 'eraYear');\n addFormatToken('y', ['yyyy', 4], 0, 'eraYear');\n addRegexToken('N', matchEraAbbr);\n addRegexToken('NN', matchEraAbbr);\n addRegexToken('NNN', matchEraAbbr);\n addRegexToken('NNNN', matchEraName);\n addRegexToken('NNNNN', matchEraNarrow);\n addParseToken(['N', 'NN', 'NNN', 'NNNN', 'NNNNN'], function (input, array, config, token) {\n var era = config._locale.erasParse(input, token, config._strict);\n if (era) {\n getParsingFlags(config).era = era;\n } else {\n getParsingFlags(config).invalidEra = input;\n }\n });\n addRegexToken('y', matchUnsigned);\n addRegexToken('yy', matchUnsigned);\n addRegexToken('yyy', matchUnsigned);\n addRegexToken('yyyy', matchUnsigned);\n addRegexToken('yo', matchEraYearOrdinal);\n addParseToken(['y', 'yy', 'yyy', 'yyyy'], YEAR);\n addParseToken(['yo'], function (input, array, config, token) {\n var match;\n if (config._locale._eraYearOrdinalRegex) {\n match = input.match(config._locale._eraYearOrdinalRegex);\n }\n if (config._locale.eraYearOrdinalParse) {\n array[YEAR] = config._locale.eraYearOrdinalParse(input, match);\n } else {\n array[YEAR] = parseInt(input, 10);\n }\n });\n function localeEras(m, format) {\n var i,\n l,\n date,\n eras = this._eras || getLocale('en')._eras;\n for (i = 0, l = eras.length; i < l; ++i) {\n switch (typeof eras[i].since) {\n case 'string':\n // truncate time\n date = hooks(eras[i].since).startOf('day');\n eras[i].since = date.valueOf();\n break;\n }\n switch (typeof eras[i].until) {\n case 'undefined':\n eras[i].until = +Infinity;\n break;\n case 'string':\n // truncate time\n date = hooks(eras[i].until).startOf('day').valueOf();\n eras[i].until = date.valueOf();\n break;\n }\n }\n return eras;\n }\n function localeErasParse(eraName, format, strict) {\n var i,\n l,\n eras = this.eras(),\n name,\n abbr,\n narrow;\n eraName = eraName.toUpperCase();\n for (i = 0, l = eras.length; i < l; ++i) {\n name = eras[i].name.toUpperCase();\n abbr = eras[i].abbr.toUpperCase();\n narrow = eras[i].narrow.toUpperCase();\n if (strict) {\n switch (format) {\n case 'N':\n case 'NN':\n case 'NNN':\n if (abbr === eraName) {\n return eras[i];\n }\n break;\n case 'NNNN':\n if (name === eraName) {\n return eras[i];\n }\n break;\n case 'NNNNN':\n if (narrow === eraName) {\n return eras[i];\n }\n break;\n }\n } else if ([name, abbr, narrow].indexOf(eraName) >= 0) {\n return eras[i];\n }\n }\n }\n function localeErasConvertYear(era, year) {\n var dir = era.since <= era.until ? +1 : -1;\n if (year === undefined) {\n return hooks(era.since).year();\n } else {\n return hooks(era.since).year() + (year - era.offset) * dir;\n }\n }\n function getEraName() {\n var i,\n l,\n val,\n eras = this.localeData().eras();\n for (i = 0, l = eras.length; i < l; ++i) {\n // truncate time\n val = this.clone().startOf('day').valueOf();\n if (eras[i].since <= val && val <= eras[i].until) {\n return eras[i].name;\n }\n if (eras[i].until <= val && val <= eras[i].since) {\n return eras[i].name;\n }\n }\n return '';\n }\n function getEraNarrow() {\n var i,\n l,\n val,\n eras = this.localeData().eras();\n for (i = 0, l = eras.length; i < l; ++i) {\n // truncate time\n val = this.clone().startOf('day').valueOf();\n if (eras[i].since <= val && val <= eras[i].until) {\n return eras[i].narrow;\n }\n if (eras[i].until <= val && val <= eras[i].since) {\n return eras[i].narrow;\n }\n }\n return '';\n }\n function getEraAbbr() {\n var i,\n l,\n val,\n eras = this.localeData().eras();\n for (i = 0, l = eras.length; i < l; ++i) {\n // truncate time\n val = this.clone().startOf('day').valueOf();\n if (eras[i].since <= val && val <= eras[i].until) {\n return eras[i].abbr;\n }\n if (eras[i].until <= val && val <= eras[i].since) {\n return eras[i].abbr;\n }\n }\n return '';\n }\n function getEraYear() {\n var i,\n l,\n dir,\n val,\n eras = this.localeData().eras();\n for (i = 0, l = eras.length; i < l; ++i) {\n dir = eras[i].since <= eras[i].until ? +1 : -1;\n\n // truncate time\n val = this.clone().startOf('day').valueOf();\n if (eras[i].since <= val && val <= eras[i].until || eras[i].until <= val && val <= eras[i].since) {\n return (this.year() - hooks(eras[i].since).year()) * dir + eras[i].offset;\n }\n }\n return this.year();\n }\n function erasNameRegex(isStrict) {\n if (!hasOwnProp(this, '_erasNameRegex')) {\n computeErasParse.call(this);\n }\n return isStrict ? this._erasNameRegex : this._erasRegex;\n }\n function erasAbbrRegex(isStrict) {\n if (!hasOwnProp(this, '_erasAbbrRegex')) {\n computeErasParse.call(this);\n }\n return isStrict ? this._erasAbbrRegex : this._erasRegex;\n }\n function erasNarrowRegex(isStrict) {\n if (!hasOwnProp(this, '_erasNarrowRegex')) {\n computeErasParse.call(this);\n }\n return isStrict ? this._erasNarrowRegex : this._erasRegex;\n }\n function matchEraAbbr(isStrict, locale) {\n return locale.erasAbbrRegex(isStrict);\n }\n function matchEraName(isStrict, locale) {\n return locale.erasNameRegex(isStrict);\n }\n function matchEraNarrow(isStrict, locale) {\n return locale.erasNarrowRegex(isStrict);\n }\n function matchEraYearOrdinal(isStrict, locale) {\n return locale._eraYearOrdinalRegex || matchUnsigned;\n }\n function computeErasParse() {\n var abbrPieces = [],\n namePieces = [],\n narrowPieces = [],\n mixedPieces = [],\n i,\n l,\n erasName,\n erasAbbr,\n erasNarrow,\n eras = this.eras();\n for (i = 0, l = eras.length; i < l; ++i) {\n erasName = regexEscape(eras[i].name);\n erasAbbr = regexEscape(eras[i].abbr);\n erasNarrow = regexEscape(eras[i].narrow);\n namePieces.push(erasName);\n abbrPieces.push(erasAbbr);\n narrowPieces.push(erasNarrow);\n mixedPieces.push(erasName);\n mixedPieces.push(erasAbbr);\n mixedPieces.push(erasNarrow);\n }\n this._erasRegex = new RegExp('^(' + mixedPieces.join('|') + ')', 'i');\n this._erasNameRegex = new RegExp('^(' + namePieces.join('|') + ')', 'i');\n this._erasAbbrRegex = new RegExp('^(' + abbrPieces.join('|') + ')', 'i');\n this._erasNarrowRegex = new RegExp('^(' + narrowPieces.join('|') + ')', 'i');\n }\n\n // FORMATTING\n\n addFormatToken(0, ['gg', 2], 0, function () {\n return this.weekYear() % 100;\n });\n addFormatToken(0, ['GG', 2], 0, function () {\n return this.isoWeekYear() % 100;\n });\n function addWeekYearFormatToken(token, getter) {\n addFormatToken(0, [token, token.length], 0, getter);\n }\n addWeekYearFormatToken('gggg', 'weekYear');\n addWeekYearFormatToken('ggggg', 'weekYear');\n addWeekYearFormatToken('GGGG', 'isoWeekYear');\n addWeekYearFormatToken('GGGGG', 'isoWeekYear');\n\n // ALIASES\n\n // PARSING\n\n addRegexToken('G', matchSigned);\n addRegexToken('g', matchSigned);\n addRegexToken('GG', match1to2, match2);\n addRegexToken('gg', match1to2, match2);\n addRegexToken('GGGG', match1to4, match4);\n addRegexToken('gggg', match1to4, match4);\n addRegexToken('GGGGG', match1to6, match6);\n addRegexToken('ggggg', match1to6, match6);\n addWeekParseToken(['gggg', 'ggggg', 'GGGG', 'GGGGG'], function (input, week, config, token) {\n week[token.substr(0, 2)] = toInt(input);\n });\n addWeekParseToken(['gg', 'GG'], function (input, week, config, token) {\n week[token] = hooks.parseTwoDigitYear(input);\n });\n\n // MOMENTS\n\n function getSetWeekYear(input) {\n return getSetWeekYearHelper.call(this, input, this.week(), this.weekday() + this.localeData()._week.dow, this.localeData()._week.dow, this.localeData()._week.doy);\n }\n function getSetISOWeekYear(input) {\n return getSetWeekYearHelper.call(this, input, this.isoWeek(), this.isoWeekday(), 1, 4);\n }\n function getISOWeeksInYear() {\n return weeksInYear(this.year(), 1, 4);\n }\n function getISOWeeksInISOWeekYear() {\n return weeksInYear(this.isoWeekYear(), 1, 4);\n }\n function getWeeksInYear() {\n var weekInfo = this.localeData()._week;\n return weeksInYear(this.year(), weekInfo.dow, weekInfo.doy);\n }\n function getWeeksInWeekYear() {\n var weekInfo = this.localeData()._week;\n return weeksInYear(this.weekYear(), weekInfo.dow, weekInfo.doy);\n }\n function getSetWeekYearHelper(input, week, weekday, dow, doy) {\n var weeksTarget;\n if (input == null) {\n return weekOfYear(this, dow, doy).year;\n } else {\n weeksTarget = weeksInYear(input, dow, doy);\n if (week > weeksTarget) {\n week = weeksTarget;\n }\n return setWeekAll.call(this, input, week, weekday, dow, doy);\n }\n }\n function setWeekAll(weekYear, week, weekday, dow, doy) {\n var dayOfYearData = dayOfYearFromWeeks(weekYear, week, weekday, dow, doy),\n date = createUTCDate(dayOfYearData.year, 0, dayOfYearData.dayOfYear);\n this.year(date.getUTCFullYear());\n this.month(date.getUTCMonth());\n this.date(date.getUTCDate());\n return this;\n }\n\n // FORMATTING\n\n addFormatToken('Q', 0, 'Qo', 'quarter');\n\n // PARSING\n\n addRegexToken('Q', match1);\n addParseToken('Q', function (input, array) {\n array[MONTH] = (toInt(input) - 1) * 3;\n });\n\n // MOMENTS\n\n function getSetQuarter(input) {\n return input == null ? Math.ceil((this.month() + 1) / 3) : this.month((input - 1) * 3 + this.month() % 3);\n }\n\n // FORMATTING\n\n addFormatToken('D', ['DD', 2], 'Do', 'date');\n\n // PARSING\n\n addRegexToken('D', match1to2, match1to2NoLeadingZero);\n addRegexToken('DD', match1to2, match2);\n addRegexToken('Do', function (isStrict, locale) {\n // TODO: Remove \"ordinalParse\" fallback in next major release.\n return isStrict ? locale._dayOfMonthOrdinalParse || locale._ordinalParse : locale._dayOfMonthOrdinalParseLenient;\n });\n addParseToken(['D', 'DD'], DATE);\n addParseToken('Do', function (input, array) {\n array[DATE] = toInt(input.match(match1to2)[0]);\n });\n\n // MOMENTS\n\n var getSetDayOfMonth = makeGetSet('Date', true);\n\n // FORMATTING\n\n addFormatToken('DDD', ['DDDD', 3], 'DDDo', 'dayOfYear');\n\n // PARSING\n\n addRegexToken('DDD', match1to3);\n addRegexToken('DDDD', match3);\n addParseToken(['DDD', 'DDDD'], function (input, array, config) {\n config._dayOfYear = toInt(input);\n });\n\n // HELPERS\n\n // MOMENTS\n\n function getSetDayOfYear(input) {\n var dayOfYear = Math.round((this.clone().startOf('day') - this.clone().startOf('year')) / 864e5) + 1;\n return input == null ? dayOfYear : this.add(input - dayOfYear, 'd');\n }\n\n // FORMATTING\n\n addFormatToken('m', ['mm', 2], 0, 'minute');\n\n // PARSING\n\n addRegexToken('m', match1to2, match1to2HasZero);\n addRegexToken('mm', match1to2, match2);\n addParseToken(['m', 'mm'], MINUTE);\n\n // MOMENTS\n\n var getSetMinute = makeGetSet('Minutes', false);\n\n // FORMATTING\n\n addFormatToken('s', ['ss', 2], 0, 'second');\n\n // PARSING\n\n addRegexToken('s', match1to2, match1to2HasZero);\n addRegexToken('ss', match1to2, match2);\n addParseToken(['s', 'ss'], SECOND);\n\n // MOMENTS\n\n var getSetSecond = makeGetSet('Seconds', false);\n\n // FORMATTING\n\n addFormatToken('S', 0, 0, function () {\n return ~~(this.millisecond() / 100);\n });\n addFormatToken(0, ['SS', 2], 0, function () {\n return ~~(this.millisecond() / 10);\n });\n addFormatToken(0, ['SSS', 3], 0, 'millisecond');\n addFormatToken(0, ['SSSS', 4], 0, function () {\n return this.millisecond() * 10;\n });\n addFormatToken(0, ['SSSSS', 5], 0, function () {\n return this.millisecond() * 100;\n });\n addFormatToken(0, ['SSSSSS', 6], 0, function () {\n return this.millisecond() * 1000;\n });\n addFormatToken(0, ['SSSSSSS', 7], 0, function () {\n return this.millisecond() * 10000;\n });\n addFormatToken(0, ['SSSSSSSS', 8], 0, function () {\n return this.millisecond() * 100000;\n });\n addFormatToken(0, ['SSSSSSSSS', 9], 0, function () {\n return this.millisecond() * 1000000;\n });\n\n // PARSING\n\n addRegexToken('S', match1to3, match1);\n addRegexToken('SS', match1to3, match2);\n addRegexToken('SSS', match1to3, match3);\n var token, getSetMillisecond;\n for (token = 'SSSS'; token.length <= 9; token += 'S') {\n addRegexToken(token, matchUnsigned);\n }\n function parseMs(input, array) {\n array[MILLISECOND] = toInt(('0.' + input) * 1000);\n }\n for (token = 'S'; token.length <= 9; token += 'S') {\n addParseToken(token, parseMs);\n }\n getSetMillisecond = makeGetSet('Milliseconds', false);\n\n // FORMATTING\n\n addFormatToken('z', 0, 0, 'zoneAbbr');\n addFormatToken('zz', 0, 0, 'zoneName');\n\n // MOMENTS\n\n function getZoneAbbr() {\n return this._isUTC ? 'UTC' : '';\n }\n function getZoneName() {\n return this._isUTC ? 'Coordinated Universal Time' : '';\n }\n var proto = Moment.prototype;\n proto.add = add;\n proto.calendar = calendar$1;\n proto.clone = clone;\n proto.diff = diff;\n proto.endOf = endOf;\n proto.format = format;\n proto.from = from;\n proto.fromNow = fromNow;\n proto.to = to;\n proto.toNow = toNow;\n proto.get = stringGet;\n proto.invalidAt = invalidAt;\n proto.isAfter = isAfter;\n proto.isBefore = isBefore;\n proto.isBetween = isBetween;\n proto.isSame = isSame;\n proto.isSameOrAfter = isSameOrAfter;\n proto.isSameOrBefore = isSameOrBefore;\n proto.isValid = isValid$2;\n proto.lang = lang;\n proto.locale = locale;\n proto.localeData = localeData;\n proto.max = prototypeMax;\n proto.min = prototypeMin;\n proto.parsingFlags = parsingFlags;\n proto.set = stringSet;\n proto.startOf = startOf;\n proto.subtract = subtract;\n proto.toArray = toArray;\n proto.toObject = toObject;\n proto.toDate = toDate;\n proto.toISOString = toISOString;\n proto.inspect = inspect;\n if (typeof Symbol !== 'undefined' && Symbol.for != null) {\n proto[Symbol.for('nodejs.util.inspect.custom')] = function () {\n return 'Moment<' + this.format() + '>';\n };\n }\n proto.toJSON = toJSON;\n proto.toString = toString;\n proto.unix = unix;\n proto.valueOf = valueOf;\n proto.creationData = creationData;\n proto.eraName = getEraName;\n proto.eraNarrow = getEraNarrow;\n proto.eraAbbr = getEraAbbr;\n proto.eraYear = getEraYear;\n proto.year = getSetYear;\n proto.isLeapYear = getIsLeapYear;\n proto.weekYear = getSetWeekYear;\n proto.isoWeekYear = getSetISOWeekYear;\n proto.quarter = proto.quarters = getSetQuarter;\n proto.month = getSetMonth;\n proto.daysInMonth = getDaysInMonth;\n proto.week = proto.weeks = getSetWeek;\n proto.isoWeek = proto.isoWeeks = getSetISOWeek;\n proto.weeksInYear = getWeeksInYear;\n proto.weeksInWeekYear = getWeeksInWeekYear;\n proto.isoWeeksInYear = getISOWeeksInYear;\n proto.isoWeeksInISOWeekYear = getISOWeeksInISOWeekYear;\n proto.date = getSetDayOfMonth;\n proto.day = proto.days = getSetDayOfWeek;\n proto.weekday = getSetLocaleDayOfWeek;\n proto.isoWeekday = getSetISODayOfWeek;\n proto.dayOfYear = getSetDayOfYear;\n proto.hour = proto.hours = getSetHour;\n proto.minute = proto.minutes = getSetMinute;\n proto.second = proto.seconds = getSetSecond;\n proto.millisecond = proto.milliseconds = getSetMillisecond;\n proto.utcOffset = getSetOffset;\n proto.utc = setOffsetToUTC;\n proto.local = setOffsetToLocal;\n proto.parseZone = setOffsetToParsedOffset;\n proto.hasAlignedHourOffset = hasAlignedHourOffset;\n proto.isDST = isDaylightSavingTime;\n proto.isLocal = isLocal;\n proto.isUtcOffset = isUtcOffset;\n proto.isUtc = isUtc;\n proto.isUTC = isUtc;\n proto.zoneAbbr = getZoneAbbr;\n proto.zoneName = getZoneName;\n proto.dates = deprecate('dates accessor is deprecated. Use date instead.', getSetDayOfMonth);\n proto.months = deprecate('months accessor is deprecated. Use month instead', getSetMonth);\n proto.years = deprecate('years accessor is deprecated. Use year instead', getSetYear);\n proto.zone = deprecate('moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/', getSetZone);\n proto.isDSTShifted = deprecate('isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information', isDaylightSavingTimeShifted);\n function createUnix(input) {\n return createLocal(input * 1000);\n }\n function createInZone() {\n return createLocal.apply(null, arguments).parseZone();\n }\n function preParsePostFormat(string) {\n return string;\n }\n var proto$1 = Locale.prototype;\n proto$1.calendar = calendar;\n proto$1.longDateFormat = longDateFormat;\n proto$1.invalidDate = invalidDate;\n proto$1.ordinal = ordinal;\n proto$1.preparse = preParsePostFormat;\n proto$1.postformat = preParsePostFormat;\n proto$1.relativeTime = relativeTime;\n proto$1.pastFuture = pastFuture;\n proto$1.set = set;\n proto$1.eras = localeEras;\n proto$1.erasParse = localeErasParse;\n proto$1.erasConvertYear = localeErasConvertYear;\n proto$1.erasAbbrRegex = erasAbbrRegex;\n proto$1.erasNameRegex = erasNameRegex;\n proto$1.erasNarrowRegex = erasNarrowRegex;\n proto$1.months = localeMonths;\n proto$1.monthsShort = localeMonthsShort;\n proto$1.monthsParse = localeMonthsParse;\n proto$1.monthsRegex = monthsRegex;\n proto$1.monthsShortRegex = monthsShortRegex;\n proto$1.week = localeWeek;\n proto$1.firstDayOfYear = localeFirstDayOfYear;\n proto$1.firstDayOfWeek = localeFirstDayOfWeek;\n proto$1.weekdays = localeWeekdays;\n proto$1.weekdaysMin = localeWeekdaysMin;\n proto$1.weekdaysShort = localeWeekdaysShort;\n proto$1.weekdaysParse = localeWeekdaysParse;\n proto$1.weekdaysRegex = weekdaysRegex;\n proto$1.weekdaysShortRegex = weekdaysShortRegex;\n proto$1.weekdaysMinRegex = weekdaysMinRegex;\n proto$1.isPM = localeIsPM;\n proto$1.meridiem = localeMeridiem;\n function get$1(format, index, field, setter) {\n var locale = getLocale(),\n utc = createUTC().set(setter, index);\n return locale[field](utc, format);\n }\n function listMonthsImpl(format, index, field) {\n if (isNumber(format)) {\n index = format;\n format = undefined;\n }\n format = format || '';\n if (index != null) {\n return get$1(format, index, field, 'month');\n }\n var i,\n out = [];\n for (i = 0; i < 12; i++) {\n out[i] = get$1(format, i, field, 'month');\n }\n return out;\n }\n\n // ()\n // (5)\n // (fmt, 5)\n // (fmt)\n // (true)\n // (true, 5)\n // (true, fmt, 5)\n // (true, fmt)\n function listWeekdaysImpl(localeSorted, format, index, field) {\n if (typeof localeSorted === 'boolean') {\n if (isNumber(format)) {\n index = format;\n format = undefined;\n }\n format = format || '';\n } else {\n format = localeSorted;\n index = format;\n localeSorted = false;\n if (isNumber(format)) {\n index = format;\n format = undefined;\n }\n format = format || '';\n }\n var locale = getLocale(),\n shift = localeSorted ? locale._week.dow : 0,\n i,\n out = [];\n if (index != null) {\n return get$1(format, (index + shift) % 7, field, 'day');\n }\n for (i = 0; i < 7; i++) {\n out[i] = get$1(format, (i + shift) % 7, field, 'day');\n }\n return out;\n }\n function listMonths(format, index) {\n return listMonthsImpl(format, index, 'months');\n }\n function listMonthsShort(format, index) {\n return listMonthsImpl(format, index, 'monthsShort');\n }\n function listWeekdays(localeSorted, format, index) {\n return listWeekdaysImpl(localeSorted, format, index, 'weekdays');\n }\n function listWeekdaysShort(localeSorted, format, index) {\n return listWeekdaysImpl(localeSorted, format, index, 'weekdaysShort');\n }\n function listWeekdaysMin(localeSorted, format, index) {\n return listWeekdaysImpl(localeSorted, format, index, 'weekdaysMin');\n }\n getSetGlobalLocale('en', {\n eras: [{\n since: '0001-01-01',\n until: +Infinity,\n offset: 1,\n name: 'Anno Domini',\n narrow: 'AD',\n abbr: 'AD'\n }, {\n since: '0000-12-31',\n until: -Infinity,\n offset: 1,\n name: 'Before Christ',\n narrow: 'BC',\n abbr: 'BC'\n }],\n dayOfMonthOrdinalParse: /\\d{1,2}(th|st|nd|rd)/,\n ordinal: function (number) {\n var b = number % 10,\n output = toInt(number % 100 / 10) === 1 ? 'th' : b === 1 ? 'st' : b === 2 ? 'nd' : b === 3 ? 'rd' : 'th';\n return number + output;\n }\n });\n\n // Side effect imports\n\n hooks.lang = deprecate('moment.lang is deprecated. Use moment.locale instead.', getSetGlobalLocale);\n hooks.langData = deprecate('moment.langData is deprecated. Use moment.localeData instead.', getLocale);\n var mathAbs = Math.abs;\n function abs() {\n var data = this._data;\n this._milliseconds = mathAbs(this._milliseconds);\n this._days = mathAbs(this._days);\n this._months = mathAbs(this._months);\n data.milliseconds = mathAbs(data.milliseconds);\n data.seconds = mathAbs(data.seconds);\n data.minutes = mathAbs(data.minutes);\n data.hours = mathAbs(data.hours);\n data.months = mathAbs(data.months);\n data.years = mathAbs(data.years);\n return this;\n }\n function addSubtract$1(duration, input, value, direction) {\n var other = createDuration(input, value);\n duration._milliseconds += direction * other._milliseconds;\n duration._days += direction * other._days;\n duration._months += direction * other._months;\n return duration._bubble();\n }\n\n // supports only 2.0-style add(1, 's') or add(duration)\n function add$1(input, value) {\n return addSubtract$1(this, input, value, 1);\n }\n\n // supports only 2.0-style subtract(1, 's') or subtract(duration)\n function subtract$1(input, value) {\n return addSubtract$1(this, input, value, -1);\n }\n function absCeil(number) {\n if (number < 0) {\n return Math.floor(number);\n } else {\n return Math.ceil(number);\n }\n }\n function bubble() {\n var milliseconds = this._milliseconds,\n days = this._days,\n months = this._months,\n data = this._data,\n seconds,\n minutes,\n hours,\n years,\n monthsFromDays;\n\n // if we have a mix of positive and negative values, bubble down first\n // check: https://github.com/moment/moment/issues/2166\n if (!(milliseconds >= 0 && days >= 0 && months >= 0 || milliseconds <= 0 && days <= 0 && months <= 0)) {\n milliseconds += absCeil(monthsToDays(months) + days) * 864e5;\n days = 0;\n months = 0;\n }\n\n // The following code bubbles up values, see the tests for\n // examples of what that means.\n data.milliseconds = milliseconds % 1000;\n seconds = absFloor(milliseconds / 1000);\n data.seconds = seconds % 60;\n minutes = absFloor(seconds / 60);\n data.minutes = minutes % 60;\n hours = absFloor(minutes / 60);\n data.hours = hours % 24;\n days += absFloor(hours / 24);\n\n // convert days to months\n monthsFromDays = absFloor(daysToMonths(days));\n months += monthsFromDays;\n days -= absCeil(monthsToDays(monthsFromDays));\n\n // 12 months -> 1 year\n years = absFloor(months / 12);\n months %= 12;\n data.days = days;\n data.months = months;\n data.years = years;\n return this;\n }\n function daysToMonths(days) {\n // 400 years have 146097 days (taking into account leap year rules)\n // 400 years have 12 months === 4800\n return days * 4800 / 146097;\n }\n function monthsToDays(months) {\n // the reverse of daysToMonths\n return months * 146097 / 4800;\n }\n function as(units) {\n if (!this.isValid()) {\n return NaN;\n }\n var days,\n months,\n milliseconds = this._milliseconds;\n units = normalizeUnits(units);\n if (units === 'month' || units === 'quarter' || units === 'year') {\n days = this._days + milliseconds / 864e5;\n months = this._months + daysToMonths(days);\n switch (units) {\n case 'month':\n return months;\n case 'quarter':\n return months / 3;\n case 'year':\n return months / 12;\n }\n } else {\n // handle milliseconds separately because of floating point math errors (issue #1867)\n days = this._days + Math.round(monthsToDays(this._months));\n switch (units) {\n case 'week':\n return days / 7 + milliseconds / 6048e5;\n case 'day':\n return days + milliseconds / 864e5;\n case 'hour':\n return days * 24 + milliseconds / 36e5;\n case 'minute':\n return days * 1440 + milliseconds / 6e4;\n case 'second':\n return days * 86400 + milliseconds / 1000;\n // Math.floor prevents floating point math errors here\n case 'millisecond':\n return Math.floor(days * 864e5) + milliseconds;\n default:\n throw new Error('Unknown unit ' + units);\n }\n }\n }\n function makeAs(alias) {\n return function () {\n return this.as(alias);\n };\n }\n var asMilliseconds = makeAs('ms'),\n asSeconds = makeAs('s'),\n asMinutes = makeAs('m'),\n asHours = makeAs('h'),\n asDays = makeAs('d'),\n asWeeks = makeAs('w'),\n asMonths = makeAs('M'),\n asQuarters = makeAs('Q'),\n asYears = makeAs('y'),\n valueOf$1 = asMilliseconds;\n function clone$1() {\n return createDuration(this);\n }\n function get$2(units) {\n units = normalizeUnits(units);\n return this.isValid() ? this[units + 's']() : NaN;\n }\n function makeGetter(name) {\n return function () {\n return this.isValid() ? this._data[name] : NaN;\n };\n }\n var milliseconds = makeGetter('milliseconds'),\n seconds = makeGetter('seconds'),\n minutes = makeGetter('minutes'),\n hours = makeGetter('hours'),\n days = makeGetter('days'),\n months = makeGetter('months'),\n years = makeGetter('years');\n function weeks() {\n return absFloor(this.days() / 7);\n }\n var round = Math.round,\n thresholds = {\n ss: 44,\n // a few seconds to seconds\n s: 45,\n // seconds to minute\n m: 45,\n // minutes to hour\n h: 22,\n // hours to day\n d: 26,\n // days to month/week\n w: null,\n // weeks to month\n M: 11 // months to year\n };\n\n // helper function for moment.fn.from, moment.fn.fromNow, and moment.duration.fn.humanize\n function substituteTimeAgo(string, number, withoutSuffix, isFuture, locale) {\n return locale.relativeTime(number || 1, !!withoutSuffix, string, isFuture);\n }\n function relativeTime$1(posNegDuration, withoutSuffix, thresholds, locale) {\n var duration = createDuration(posNegDuration).abs(),\n seconds = round(duration.as('s')),\n minutes = round(duration.as('m')),\n hours = round(duration.as('h')),\n days = round(duration.as('d')),\n months = round(duration.as('M')),\n weeks = round(duration.as('w')),\n years = round(duration.as('y')),\n a = seconds <= thresholds.ss && ['s', seconds] || seconds < thresholds.s && ['ss', seconds] || minutes <= 1 && ['m'] || minutes < thresholds.m && ['mm', minutes] || hours <= 1 && ['h'] || hours < thresholds.h && ['hh', hours] || days <= 1 && ['d'] || days < thresholds.d && ['dd', days];\n if (thresholds.w != null) {\n a = a || weeks <= 1 && ['w'] || weeks < thresholds.w && ['ww', weeks];\n }\n a = a || months <= 1 && ['M'] || months < thresholds.M && ['MM', months] || years <= 1 && ['y'] || ['yy', years];\n a[2] = withoutSuffix;\n a[3] = +posNegDuration > 0;\n a[4] = locale;\n return substituteTimeAgo.apply(null, a);\n }\n\n // This function allows you to set the rounding function for relative time strings\n function getSetRelativeTimeRounding(roundingFunction) {\n if (roundingFunction === undefined) {\n return round;\n }\n if (typeof roundingFunction === 'function') {\n round = roundingFunction;\n return true;\n }\n return false;\n }\n\n // This function allows you to set a threshold for relative time strings\n function getSetRelativeTimeThreshold(threshold, limit) {\n if (thresholds[threshold] === undefined) {\n return false;\n }\n if (limit === undefined) {\n return thresholds[threshold];\n }\n thresholds[threshold] = limit;\n if (threshold === 's') {\n thresholds.ss = limit - 1;\n }\n return true;\n }\n function humanize(argWithSuffix, argThresholds) {\n if (!this.isValid()) {\n return this.localeData().invalidDate();\n }\n var withSuffix = false,\n th = thresholds,\n locale,\n output;\n if (typeof argWithSuffix === 'object') {\n argThresholds = argWithSuffix;\n argWithSuffix = false;\n }\n if (typeof argWithSuffix === 'boolean') {\n withSuffix = argWithSuffix;\n }\n if (typeof argThresholds === 'object') {\n th = Object.assign({}, thresholds, argThresholds);\n if (argThresholds.s != null && argThresholds.ss == null) {\n th.ss = argThresholds.s - 1;\n }\n }\n locale = this.localeData();\n output = relativeTime$1(this, !withSuffix, th, locale);\n if (withSuffix) {\n output = locale.pastFuture(+this, output);\n }\n return locale.postformat(output);\n }\n var abs$1 = Math.abs;\n function sign(x) {\n return (x > 0) - (x < 0) || +x;\n }\n function toISOString$1() {\n // for ISO strings we do not use the normal bubbling rules:\n // * milliseconds bubble up until they become hours\n // * days do not bubble at all\n // * months bubble up until they become years\n // This is because there is no context-free conversion between hours and days\n // (think of clock changes)\n // and also not between days and months (28-31 days per month)\n if (!this.isValid()) {\n return this.localeData().invalidDate();\n }\n var seconds = abs$1(this._milliseconds) / 1000,\n days = abs$1(this._days),\n months = abs$1(this._months),\n minutes,\n hours,\n years,\n s,\n total = this.asSeconds(),\n totalSign,\n ymSign,\n daysSign,\n hmsSign;\n if (!total) {\n // this is the same as C#'s (Noda) and python (isodate)...\n // but not other JS (goog.date)\n return 'P0D';\n }\n\n // 3600 seconds -> 60 minutes -> 1 hour\n minutes = absFloor(seconds / 60);\n hours = absFloor(minutes / 60);\n seconds %= 60;\n minutes %= 60;\n\n // 12 months -> 1 year\n years = absFloor(months / 12);\n months %= 12;\n\n // inspired by https://github.com/dordille/moment-isoduration/blob/master/moment.isoduration.js\n s = seconds ? seconds.toFixed(3).replace(/\\.?0+$/, '') : '';\n totalSign = total < 0 ? '-' : '';\n ymSign = sign(this._months) !== sign(total) ? '-' : '';\n daysSign = sign(this._days) !== sign(total) ? '-' : '';\n hmsSign = sign(this._milliseconds) !== sign(total) ? '-' : '';\n return totalSign + 'P' + (years ? ymSign + years + 'Y' : '') + (months ? ymSign + months + 'M' : '') + (days ? daysSign + days + 'D' : '') + (hours || minutes || seconds ? 'T' : '') + (hours ? hmsSign + hours + 'H' : '') + (minutes ? hmsSign + minutes + 'M' : '') + (seconds ? hmsSign + s + 'S' : '');\n }\n var proto$2 = Duration.prototype;\n proto$2.isValid = isValid$1;\n proto$2.abs = abs;\n proto$2.add = add$1;\n proto$2.subtract = subtract$1;\n proto$2.as = as;\n proto$2.asMilliseconds = asMilliseconds;\n proto$2.asSeconds = asSeconds;\n proto$2.asMinutes = asMinutes;\n proto$2.asHours = asHours;\n proto$2.asDays = asDays;\n proto$2.asWeeks = asWeeks;\n proto$2.asMonths = asMonths;\n proto$2.asQuarters = asQuarters;\n proto$2.asYears = asYears;\n proto$2.valueOf = valueOf$1;\n proto$2._bubble = bubble;\n proto$2.clone = clone$1;\n proto$2.get = get$2;\n proto$2.milliseconds = milliseconds;\n proto$2.seconds = seconds;\n proto$2.minutes = minutes;\n proto$2.hours = hours;\n proto$2.days = days;\n proto$2.weeks = weeks;\n proto$2.months = months;\n proto$2.years = years;\n proto$2.humanize = humanize;\n proto$2.toISOString = toISOString$1;\n proto$2.toString = toISOString$1;\n proto$2.toJSON = toISOString$1;\n proto$2.locale = locale;\n proto$2.localeData = localeData;\n proto$2.toIsoString = deprecate('toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)', toISOString$1);\n proto$2.lang = lang;\n\n // FORMATTING\n\n addFormatToken('X', 0, 0, 'unix');\n addFormatToken('x', 0, 0, 'valueOf');\n\n // PARSING\n\n addRegexToken('x', matchSigned);\n addRegexToken('X', matchTimestamp);\n addParseToken('X', function (input, array, config) {\n config._d = new Date(parseFloat(input) * 1000);\n });\n addParseToken('x', function (input, array, config) {\n config._d = new Date(toInt(input));\n });\n\n //! moment.js\n\n hooks.version = '2.30.1';\n setHookCallback(createLocal);\n hooks.fn = proto;\n hooks.min = min;\n hooks.max = max;\n hooks.now = now;\n hooks.utc = createUTC;\n hooks.unix = createUnix;\n hooks.months = listMonths;\n hooks.isDate = isDate;\n hooks.locale = getSetGlobalLocale;\n hooks.invalid = createInvalid;\n hooks.duration = createDuration;\n hooks.isMoment = isMoment;\n hooks.weekdays = listWeekdays;\n hooks.parseZone = createInZone;\n hooks.localeData = getLocale;\n hooks.isDuration = isDuration;\n hooks.monthsShort = listMonthsShort;\n hooks.weekdaysMin = listWeekdaysMin;\n hooks.defineLocale = defineLocale;\n hooks.updateLocale = updateLocale;\n hooks.locales = listLocales;\n hooks.weekdaysShort = listWeekdaysShort;\n hooks.normalizeUnits = normalizeUnits;\n hooks.relativeTimeRounding = getSetRelativeTimeRounding;\n hooks.relativeTimeThreshold = getSetRelativeTimeThreshold;\n hooks.calendarFormat = getCalendarFormat;\n hooks.prototype = proto;\n\n // currently HTML5 input type only supports 24-hour formats\n hooks.HTML5_FMT = {\n DATETIME_LOCAL: 'YYYY-MM-DDTHH:mm',\n // \n DATETIME_LOCAL_SECONDS: 'YYYY-MM-DDTHH:mm:ss',\n // \n DATETIME_LOCAL_MS: 'YYYY-MM-DDTHH:mm:ss.SSS',\n // \n DATE: 'YYYY-MM-DD',\n // \n TIME: 'HH:mm',\n // \n TIME_SECONDS: 'HH:mm:ss',\n // \n TIME_MS: 'HH:mm:ss.SSS',\n // \n WEEK: 'GGGG-[W]WW',\n // \n MONTH: 'YYYY-MM' // \n };\n return hooks;\n});","/* global Map:readonly, Set:readonly, ArrayBuffer:readonly */\n\nvar hasElementType = typeof Element !== 'undefined';\nvar hasMap = typeof Map === 'function';\nvar hasSet = typeof Set === 'function';\nvar hasArrayBuffer = typeof ArrayBuffer === 'function' && !!ArrayBuffer.isView;\n\n// Note: We **don't** need `envHasBigInt64Array` in fde es6/index.js\n\nfunction equal(a, b) {\n // START: fast-deep-equal es6/index.js 3.1.3\n if (a === b) return true;\n if (a && b && typeof a == 'object' && typeof b == 'object') {\n if (a.constructor !== b.constructor) return false;\n var length, i, keys;\n if (Array.isArray(a)) {\n length = a.length;\n if (length != b.length) return false;\n for (i = length; i-- !== 0;) if (!equal(a[i], b[i])) return false;\n return true;\n }\n\n // START: Modifications:\n // 1. Extra `has &&` helpers in initial condition allow es6 code\n // to co-exist with es5.\n // 2. Replace `for of` with es5 compliant iteration using `for`.\n // Basically, take:\n //\n // ```js\n // for (i of a.entries())\n // if (!b.has(i[0])) return false;\n // ```\n //\n // ... and convert to:\n //\n // ```js\n // it = a.entries();\n // while (!(i = it.next()).done)\n // if (!b.has(i.value[0])) return false;\n // ```\n //\n // **Note**: `i` access switches to `i.value`.\n var it;\n if (hasMap && a instanceof Map && b instanceof Map) {\n if (a.size !== b.size) return false;\n it = a.entries();\n while (!(i = it.next()).done) if (!b.has(i.value[0])) return false;\n it = a.entries();\n while (!(i = it.next()).done) if (!equal(i.value[1], b.get(i.value[0]))) return false;\n return true;\n }\n if (hasSet && a instanceof Set && b instanceof Set) {\n if (a.size !== b.size) return false;\n it = a.entries();\n while (!(i = it.next()).done) if (!b.has(i.value[0])) return false;\n return true;\n }\n // END: Modifications\n\n if (hasArrayBuffer && ArrayBuffer.isView(a) && ArrayBuffer.isView(b)) {\n length = a.length;\n if (length != b.length) return false;\n for (i = length; i-- !== 0;) if (a[i] !== b[i]) return false;\n return true;\n }\n if (a.constructor === RegExp) return a.source === b.source && a.flags === b.flags;\n // START: Modifications:\n // Apply guards for `Object.create(null)` handling. See:\n // - https://github.com/FormidableLabs/react-fast-compare/issues/64\n // - https://github.com/epoberezkin/fast-deep-equal/issues/49\n if (a.valueOf !== Object.prototype.valueOf && typeof a.valueOf === 'function' && typeof b.valueOf === 'function') return a.valueOf() === b.valueOf();\n if (a.toString !== Object.prototype.toString && typeof a.toString === 'function' && typeof b.toString === 'function') return a.toString() === b.toString();\n // END: Modifications\n\n keys = Object.keys(a);\n length = keys.length;\n if (length !== Object.keys(b).length) return false;\n for (i = length; i-- !== 0;) if (!Object.prototype.hasOwnProperty.call(b, keys[i])) return false;\n // END: fast-deep-equal\n\n // START: react-fast-compare\n // custom handling for DOM elements\n if (hasElementType && a instanceof Element) return false;\n\n // custom handling for React/Preact\n for (i = length; i-- !== 0;) {\n if ((keys[i] === '_owner' || keys[i] === '__v' || keys[i] === '__o') && a.$$typeof) {\n // React-specific: avoid traversing React elements' _owner\n // Preact-specific: avoid traversing Preact elements' __v and __o\n // __v = $_original / $_vnode\n // __o = $_owner\n // These properties contain circular references and are not needed when\n // comparing the actual elements (and not their owners)\n // .$$typeof and ._store on just reasonable markers of elements\n\n continue;\n }\n\n // all other properties should be traversed as usual\n if (!equal(a[keys[i]], b[keys[i]])) return false;\n }\n // END: react-fast-compare\n\n // START: fast-deep-equal\n return true;\n }\n return a !== a && b !== b;\n}\n// end fast-deep-equal\n\nmodule.exports = function isEqual(a, b) {\n try {\n return equal(a, b);\n } catch (error) {\n if ((error.message || '').match(/stack|recursion/i)) {\n // warn on circular references, don't crash\n // browsers give this different errors name and messages:\n // chrome/safari: \"RangeError\", \"Maximum call stack size exceeded\"\n // firefox: \"InternalError\", too much recursion\"\n // edge: \"Error\", \"Out of stack space\"\n console.warn('react-fast-compare cannot handle circular refs');\n return false;\n }\n // some other error. we should definitely know about these\n throw error;\n }\n};","import PropTypes from 'prop-types';\nimport withSideEffect from 'react-side-effect';\nimport isEqual from 'react-fast-compare';\nimport React from 'react';\nimport objectAssign from 'object-assign';\nvar ATTRIBUTE_NAMES = {\n BODY: \"bodyAttributes\",\n HTML: \"htmlAttributes\",\n TITLE: \"titleAttributes\"\n};\nvar TAG_NAMES = {\n BASE: \"base\",\n BODY: \"body\",\n HEAD: \"head\",\n HTML: \"html\",\n LINK: \"link\",\n META: \"meta\",\n NOSCRIPT: \"noscript\",\n SCRIPT: \"script\",\n STYLE: \"style\",\n TITLE: \"title\"\n};\nvar VALID_TAG_NAMES = Object.keys(TAG_NAMES).map(function (name) {\n return TAG_NAMES[name];\n});\nvar TAG_PROPERTIES = {\n CHARSET: \"charset\",\n CSS_TEXT: \"cssText\",\n HREF: \"href\",\n HTTPEQUIV: \"http-equiv\",\n INNER_HTML: \"innerHTML\",\n ITEM_PROP: \"itemprop\",\n NAME: \"name\",\n PROPERTY: \"property\",\n REL: \"rel\",\n SRC: \"src\",\n TARGET: \"target\"\n};\nvar REACT_TAG_MAP = {\n accesskey: \"accessKey\",\n charset: \"charSet\",\n class: \"className\",\n contenteditable: \"contentEditable\",\n contextmenu: \"contextMenu\",\n \"http-equiv\": \"httpEquiv\",\n itemprop: \"itemProp\",\n tabindex: \"tabIndex\"\n};\nvar HELMET_PROPS = {\n DEFAULT_TITLE: \"defaultTitle\",\n DEFER: \"defer\",\n ENCODE_SPECIAL_CHARACTERS: \"encodeSpecialCharacters\",\n ON_CHANGE_CLIENT_STATE: \"onChangeClientState\",\n TITLE_TEMPLATE: \"titleTemplate\"\n};\nvar HTML_TAG_MAP = Object.keys(REACT_TAG_MAP).reduce(function (obj, key) {\n obj[REACT_TAG_MAP[key]] = key;\n return obj;\n}, {});\nvar SELF_CLOSING_TAGS = [TAG_NAMES.NOSCRIPT, TAG_NAMES.SCRIPT, TAG_NAMES.STYLE];\nvar HELMET_ATTRIBUTE = \"data-react-helmet\";\nvar _typeof = typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\" ? function (obj) {\n return typeof obj;\n} : function (obj) {\n return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj;\n};\nvar classCallCheck = function (instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n};\nvar createClass = function () {\n function defineProperties(target, props) {\n for (var i = 0; i < props.length; i++) {\n var descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;\n descriptor.configurable = true;\n if (\"value\" in descriptor) descriptor.writable = true;\n Object.defineProperty(target, descriptor.key, descriptor);\n }\n }\n return function (Constructor, protoProps, staticProps) {\n if (protoProps) defineProperties(Constructor.prototype, protoProps);\n if (staticProps) defineProperties(Constructor, staticProps);\n return Constructor;\n };\n}();\nvar _extends = Object.assign || function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n};\nvar inherits = function (subClass, superClass) {\n if (typeof superClass !== \"function\" && superClass !== null) {\n throw new TypeError(\"Super expression must either be null or a function, not \" + typeof superClass);\n }\n subClass.prototype = Object.create(superClass && superClass.prototype, {\n constructor: {\n value: subClass,\n enumerable: false,\n writable: true,\n configurable: true\n }\n });\n if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass;\n};\nvar objectWithoutProperties = function (obj, keys) {\n var target = {};\n for (var i in obj) {\n if (keys.indexOf(i) >= 0) continue;\n if (!Object.prototype.hasOwnProperty.call(obj, i)) continue;\n target[i] = obj[i];\n }\n return target;\n};\nvar possibleConstructorReturn = function (self, call) {\n if (!self) {\n throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\");\n }\n return call && (typeof call === \"object\" || typeof call === \"function\") ? call : self;\n};\nvar encodeSpecialCharacters = function encodeSpecialCharacters(str) {\n var encode = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;\n if (encode === false) {\n return String(str);\n }\n return String(str).replace(/&/g, \"&\").replace(//g, \">\").replace(/\"/g, \""\").replace(/'/g, \"'\");\n};\nvar getTitleFromPropsList = function getTitleFromPropsList(propsList) {\n var innermostTitle = getInnermostProperty(propsList, TAG_NAMES.TITLE);\n var innermostTemplate = getInnermostProperty(propsList, HELMET_PROPS.TITLE_TEMPLATE);\n if (innermostTemplate && innermostTitle) {\n // use function arg to avoid need to escape $ characters\n return innermostTemplate.replace(/%s/g, function () {\n return Array.isArray(innermostTitle) ? innermostTitle.join(\"\") : innermostTitle;\n });\n }\n var innermostDefaultTitle = getInnermostProperty(propsList, HELMET_PROPS.DEFAULT_TITLE);\n return innermostTitle || innermostDefaultTitle || undefined;\n};\nvar getOnChangeClientState = function getOnChangeClientState(propsList) {\n return getInnermostProperty(propsList, HELMET_PROPS.ON_CHANGE_CLIENT_STATE) || function () {};\n};\nvar getAttributesFromPropsList = function getAttributesFromPropsList(tagType, propsList) {\n return propsList.filter(function (props) {\n return typeof props[tagType] !== \"undefined\";\n }).map(function (props) {\n return props[tagType];\n }).reduce(function (tagAttrs, current) {\n return _extends({}, tagAttrs, current);\n }, {});\n};\nvar getBaseTagFromPropsList = function getBaseTagFromPropsList(primaryAttributes, propsList) {\n return propsList.filter(function (props) {\n return typeof props[TAG_NAMES.BASE] !== \"undefined\";\n }).map(function (props) {\n return props[TAG_NAMES.BASE];\n }).reverse().reduce(function (innermostBaseTag, tag) {\n if (!innermostBaseTag.length) {\n var keys = Object.keys(tag);\n for (var i = 0; i < keys.length; i++) {\n var attributeKey = keys[i];\n var lowerCaseAttributeKey = attributeKey.toLowerCase();\n if (primaryAttributes.indexOf(lowerCaseAttributeKey) !== -1 && tag[lowerCaseAttributeKey]) {\n return innermostBaseTag.concat(tag);\n }\n }\n }\n return innermostBaseTag;\n }, []);\n};\nvar getTagsFromPropsList = function getTagsFromPropsList(tagName, primaryAttributes, propsList) {\n // Calculate list of tags, giving priority innermost component (end of the propslist)\n var approvedSeenTags = {};\n return propsList.filter(function (props) {\n if (Array.isArray(props[tagName])) {\n return true;\n }\n if (typeof props[tagName] !== \"undefined\") {\n warn(\"Helmet: \" + tagName + \" should be of type \\\"Array\\\". Instead found type \\\"\" + _typeof(props[tagName]) + \"\\\"\");\n }\n return false;\n }).map(function (props) {\n return props[tagName];\n }).reverse().reduce(function (approvedTags, instanceTags) {\n var instanceSeenTags = {};\n instanceTags.filter(function (tag) {\n var primaryAttributeKey = void 0;\n var keys = Object.keys(tag);\n for (var i = 0; i < keys.length; i++) {\n var attributeKey = keys[i];\n var lowerCaseAttributeKey = attributeKey.toLowerCase();\n\n // Special rule with link tags, since rel and href are both primary tags, rel takes priority\n if (primaryAttributes.indexOf(lowerCaseAttributeKey) !== -1 && !(primaryAttributeKey === TAG_PROPERTIES.REL && tag[primaryAttributeKey].toLowerCase() === \"canonical\") && !(lowerCaseAttributeKey === TAG_PROPERTIES.REL && tag[lowerCaseAttributeKey].toLowerCase() === \"stylesheet\")) {\n primaryAttributeKey = lowerCaseAttributeKey;\n }\n // Special case for innerHTML which doesn't work lowercased\n if (primaryAttributes.indexOf(attributeKey) !== -1 && (attributeKey === TAG_PROPERTIES.INNER_HTML || attributeKey === TAG_PROPERTIES.CSS_TEXT || attributeKey === TAG_PROPERTIES.ITEM_PROP)) {\n primaryAttributeKey = attributeKey;\n }\n }\n if (!primaryAttributeKey || !tag[primaryAttributeKey]) {\n return false;\n }\n var value = tag[primaryAttributeKey].toLowerCase();\n if (!approvedSeenTags[primaryAttributeKey]) {\n approvedSeenTags[primaryAttributeKey] = {};\n }\n if (!instanceSeenTags[primaryAttributeKey]) {\n instanceSeenTags[primaryAttributeKey] = {};\n }\n if (!approvedSeenTags[primaryAttributeKey][value]) {\n instanceSeenTags[primaryAttributeKey][value] = true;\n return true;\n }\n return false;\n }).reverse().forEach(function (tag) {\n return approvedTags.push(tag);\n });\n\n // Update seen tags with tags from this instance\n var keys = Object.keys(instanceSeenTags);\n for (var i = 0; i < keys.length; i++) {\n var attributeKey = keys[i];\n var tagUnion = objectAssign({}, approvedSeenTags[attributeKey], instanceSeenTags[attributeKey]);\n approvedSeenTags[attributeKey] = tagUnion;\n }\n return approvedTags;\n }, []).reverse();\n};\nvar getInnermostProperty = function getInnermostProperty(propsList, property) {\n for (var i = propsList.length - 1; i >= 0; i--) {\n var props = propsList[i];\n if (props.hasOwnProperty(property)) {\n return props[property];\n }\n }\n return null;\n};\nvar reducePropsToState = function reducePropsToState(propsList) {\n return {\n baseTag: getBaseTagFromPropsList([TAG_PROPERTIES.HREF, TAG_PROPERTIES.TARGET], propsList),\n bodyAttributes: getAttributesFromPropsList(ATTRIBUTE_NAMES.BODY, propsList),\n defer: getInnermostProperty(propsList, HELMET_PROPS.DEFER),\n encode: getInnermostProperty(propsList, HELMET_PROPS.ENCODE_SPECIAL_CHARACTERS),\n htmlAttributes: getAttributesFromPropsList(ATTRIBUTE_NAMES.HTML, propsList),\n linkTags: getTagsFromPropsList(TAG_NAMES.LINK, [TAG_PROPERTIES.REL, TAG_PROPERTIES.HREF], propsList),\n metaTags: getTagsFromPropsList(TAG_NAMES.META, [TAG_PROPERTIES.NAME, TAG_PROPERTIES.CHARSET, TAG_PROPERTIES.HTTPEQUIV, TAG_PROPERTIES.PROPERTY, TAG_PROPERTIES.ITEM_PROP], propsList),\n noscriptTags: getTagsFromPropsList(TAG_NAMES.NOSCRIPT, [TAG_PROPERTIES.INNER_HTML], propsList),\n onChangeClientState: getOnChangeClientState(propsList),\n scriptTags: getTagsFromPropsList(TAG_NAMES.SCRIPT, [TAG_PROPERTIES.SRC, TAG_PROPERTIES.INNER_HTML], propsList),\n styleTags: getTagsFromPropsList(TAG_NAMES.STYLE, [TAG_PROPERTIES.CSS_TEXT], propsList),\n title: getTitleFromPropsList(propsList),\n titleAttributes: getAttributesFromPropsList(ATTRIBUTE_NAMES.TITLE, propsList)\n };\n};\nvar rafPolyfill = function () {\n var clock = Date.now();\n return function (callback) {\n var currentTime = Date.now();\n if (currentTime - clock > 16) {\n clock = currentTime;\n callback(currentTime);\n } else {\n setTimeout(function () {\n rafPolyfill(callback);\n }, 0);\n }\n };\n}();\nvar cafPolyfill = function cafPolyfill(id) {\n return clearTimeout(id);\n};\nvar requestAnimationFrame = typeof window !== \"undefined\" ? window.requestAnimationFrame && window.requestAnimationFrame.bind(window) || window.webkitRequestAnimationFrame || window.mozRequestAnimationFrame || rafPolyfill : global.requestAnimationFrame || rafPolyfill;\nvar cancelAnimationFrame = typeof window !== \"undefined\" ? window.cancelAnimationFrame || window.webkitCancelAnimationFrame || window.mozCancelAnimationFrame || cafPolyfill : global.cancelAnimationFrame || cafPolyfill;\nvar warn = function warn(msg) {\n return console && typeof console.warn === \"function\" && console.warn(msg);\n};\nvar _helmetCallback = null;\nvar handleClientStateChange = function handleClientStateChange(newState) {\n if (_helmetCallback) {\n cancelAnimationFrame(_helmetCallback);\n }\n if (newState.defer) {\n _helmetCallback = requestAnimationFrame(function () {\n commitTagChanges(newState, function () {\n _helmetCallback = null;\n });\n });\n } else {\n commitTagChanges(newState);\n _helmetCallback = null;\n }\n};\nvar commitTagChanges = function commitTagChanges(newState, cb) {\n var baseTag = newState.baseTag,\n bodyAttributes = newState.bodyAttributes,\n htmlAttributes = newState.htmlAttributes,\n linkTags = newState.linkTags,\n metaTags = newState.metaTags,\n noscriptTags = newState.noscriptTags,\n onChangeClientState = newState.onChangeClientState,\n scriptTags = newState.scriptTags,\n styleTags = newState.styleTags,\n title = newState.title,\n titleAttributes = newState.titleAttributes;\n updateAttributes(TAG_NAMES.BODY, bodyAttributes);\n updateAttributes(TAG_NAMES.HTML, htmlAttributes);\n updateTitle(title, titleAttributes);\n var tagUpdates = {\n baseTag: updateTags(TAG_NAMES.BASE, baseTag),\n linkTags: updateTags(TAG_NAMES.LINK, linkTags),\n metaTags: updateTags(TAG_NAMES.META, metaTags),\n noscriptTags: updateTags(TAG_NAMES.NOSCRIPT, noscriptTags),\n scriptTags: updateTags(TAG_NAMES.SCRIPT, scriptTags),\n styleTags: updateTags(TAG_NAMES.STYLE, styleTags)\n };\n var addedTags = {};\n var removedTags = {};\n Object.keys(tagUpdates).forEach(function (tagType) {\n var _tagUpdates$tagType = tagUpdates[tagType],\n newTags = _tagUpdates$tagType.newTags,\n oldTags = _tagUpdates$tagType.oldTags;\n if (newTags.length) {\n addedTags[tagType] = newTags;\n }\n if (oldTags.length) {\n removedTags[tagType] = tagUpdates[tagType].oldTags;\n }\n });\n cb && cb();\n onChangeClientState(newState, addedTags, removedTags);\n};\nvar flattenArray = function flattenArray(possibleArray) {\n return Array.isArray(possibleArray) ? possibleArray.join(\"\") : possibleArray;\n};\nvar updateTitle = function updateTitle(title, attributes) {\n if (typeof title !== \"undefined\" && document.title !== title) {\n document.title = flattenArray(title);\n }\n updateAttributes(TAG_NAMES.TITLE, attributes);\n};\nvar updateAttributes = function updateAttributes(tagName, attributes) {\n var elementTag = document.getElementsByTagName(tagName)[0];\n if (!elementTag) {\n return;\n }\n var helmetAttributeString = elementTag.getAttribute(HELMET_ATTRIBUTE);\n var helmetAttributes = helmetAttributeString ? helmetAttributeString.split(\",\") : [];\n var attributesToRemove = [].concat(helmetAttributes);\n var attributeKeys = Object.keys(attributes);\n for (var i = 0; i < attributeKeys.length; i++) {\n var attribute = attributeKeys[i];\n var value = attributes[attribute] || \"\";\n if (elementTag.getAttribute(attribute) !== value) {\n elementTag.setAttribute(attribute, value);\n }\n if (helmetAttributes.indexOf(attribute) === -1) {\n helmetAttributes.push(attribute);\n }\n var indexToSave = attributesToRemove.indexOf(attribute);\n if (indexToSave !== -1) {\n attributesToRemove.splice(indexToSave, 1);\n }\n }\n for (var _i = attributesToRemove.length - 1; _i >= 0; _i--) {\n elementTag.removeAttribute(attributesToRemove[_i]);\n }\n if (helmetAttributes.length === attributesToRemove.length) {\n elementTag.removeAttribute(HELMET_ATTRIBUTE);\n } else if (elementTag.getAttribute(HELMET_ATTRIBUTE) !== attributeKeys.join(\",\")) {\n elementTag.setAttribute(HELMET_ATTRIBUTE, attributeKeys.join(\",\"));\n }\n};\nvar updateTags = function updateTags(type, tags) {\n var headElement = document.head || document.querySelector(TAG_NAMES.HEAD);\n var tagNodes = headElement.querySelectorAll(type + \"[\" + HELMET_ATTRIBUTE + \"]\");\n var oldTags = Array.prototype.slice.call(tagNodes);\n var newTags = [];\n var indexToDelete = void 0;\n if (tags && tags.length) {\n tags.forEach(function (tag) {\n var newElement = document.createElement(type);\n for (var attribute in tag) {\n if (tag.hasOwnProperty(attribute)) {\n if (attribute === TAG_PROPERTIES.INNER_HTML) {\n newElement.innerHTML = tag.innerHTML;\n } else if (attribute === TAG_PROPERTIES.CSS_TEXT) {\n if (newElement.styleSheet) {\n newElement.styleSheet.cssText = tag.cssText;\n } else {\n newElement.appendChild(document.createTextNode(tag.cssText));\n }\n } else {\n var value = typeof tag[attribute] === \"undefined\" ? \"\" : tag[attribute];\n newElement.setAttribute(attribute, value);\n }\n }\n }\n newElement.setAttribute(HELMET_ATTRIBUTE, \"true\");\n\n // Remove a duplicate tag from domTagstoRemove, so it isn't cleared.\n if (oldTags.some(function (existingTag, index) {\n indexToDelete = index;\n return newElement.isEqualNode(existingTag);\n })) {\n oldTags.splice(indexToDelete, 1);\n } else {\n newTags.push(newElement);\n }\n });\n }\n oldTags.forEach(function (tag) {\n return tag.parentNode.removeChild(tag);\n });\n newTags.forEach(function (tag) {\n return headElement.appendChild(tag);\n });\n return {\n oldTags: oldTags,\n newTags: newTags\n };\n};\nvar generateElementAttributesAsString = function generateElementAttributesAsString(attributes) {\n return Object.keys(attributes).reduce(function (str, key) {\n var attr = typeof attributes[key] !== \"undefined\" ? key + \"=\\\"\" + attributes[key] + \"\\\"\" : \"\" + key;\n return str ? str + \" \" + attr : attr;\n }, \"\");\n};\nvar generateTitleAsString = function generateTitleAsString(type, title, attributes, encode) {\n var attributeString = generateElementAttributesAsString(attributes);\n var flattenedTitle = flattenArray(title);\n return attributeString ? \"<\" + type + \" \" + HELMET_ATTRIBUTE + \"=\\\"true\\\" \" + attributeString + \">\" + encodeSpecialCharacters(flattenedTitle, encode) + \"\" : \"<\" + type + \" \" + HELMET_ATTRIBUTE + \"=\\\"true\\\">\" + encodeSpecialCharacters(flattenedTitle, encode) + \"\";\n};\nvar generateTagsAsString = function generateTagsAsString(type, tags, encode) {\n return tags.reduce(function (str, tag) {\n var attributeHtml = Object.keys(tag).filter(function (attribute) {\n return !(attribute === TAG_PROPERTIES.INNER_HTML || attribute === TAG_PROPERTIES.CSS_TEXT);\n }).reduce(function (string, attribute) {\n var attr = typeof tag[attribute] === \"undefined\" ? attribute : attribute + \"=\\\"\" + encodeSpecialCharacters(tag[attribute], encode) + \"\\\"\";\n return string ? string + \" \" + attr : attr;\n }, \"\");\n var tagContent = tag.innerHTML || tag.cssText || \"\";\n var isSelfClosing = SELF_CLOSING_TAGS.indexOf(type) === -1;\n return str + \"<\" + type + \" \" + HELMET_ATTRIBUTE + \"=\\\"true\\\" \" + attributeHtml + (isSelfClosing ? \"/>\" : \">\" + tagContent + \"\");\n }, \"\");\n};\nvar convertElementAttributestoReactProps = function convertElementAttributestoReactProps(attributes) {\n var initProps = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n return Object.keys(attributes).reduce(function (obj, key) {\n obj[REACT_TAG_MAP[key] || key] = attributes[key];\n return obj;\n }, initProps);\n};\nvar convertReactPropstoHtmlAttributes = function convertReactPropstoHtmlAttributes(props) {\n var initAttributes = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n return Object.keys(props).reduce(function (obj, key) {\n obj[HTML_TAG_MAP[key] || key] = props[key];\n return obj;\n }, initAttributes);\n};\nvar generateTitleAsReactComponent = function generateTitleAsReactComponent(type, title, attributes) {\n var _initProps;\n\n // assigning into an array to define toString function on it\n var initProps = (_initProps = {\n key: title\n }, _initProps[HELMET_ATTRIBUTE] = true, _initProps);\n var props = convertElementAttributestoReactProps(attributes, initProps);\n return [React.createElement(TAG_NAMES.TITLE, props, title)];\n};\nvar generateTagsAsReactComponent = function generateTagsAsReactComponent(type, tags) {\n return tags.map(function (tag, i) {\n var _mappedTag;\n var mappedTag = (_mappedTag = {\n key: i\n }, _mappedTag[HELMET_ATTRIBUTE] = true, _mappedTag);\n Object.keys(tag).forEach(function (attribute) {\n var mappedAttribute = REACT_TAG_MAP[attribute] || attribute;\n if (mappedAttribute === TAG_PROPERTIES.INNER_HTML || mappedAttribute === TAG_PROPERTIES.CSS_TEXT) {\n var content = tag.innerHTML || tag.cssText;\n mappedTag.dangerouslySetInnerHTML = {\n __html: content\n };\n } else {\n mappedTag[mappedAttribute] = tag[attribute];\n }\n });\n return React.createElement(type, mappedTag);\n });\n};\nvar getMethodsForTag = function getMethodsForTag(type, tags, encode) {\n switch (type) {\n case TAG_NAMES.TITLE:\n return {\n toComponent: function toComponent() {\n return generateTitleAsReactComponent(type, tags.title, tags.titleAttributes, encode);\n },\n toString: function toString() {\n return generateTitleAsString(type, tags.title, tags.titleAttributes, encode);\n }\n };\n case ATTRIBUTE_NAMES.BODY:\n case ATTRIBUTE_NAMES.HTML:\n return {\n toComponent: function toComponent() {\n return convertElementAttributestoReactProps(tags);\n },\n toString: function toString() {\n return generateElementAttributesAsString(tags);\n }\n };\n default:\n return {\n toComponent: function toComponent() {\n return generateTagsAsReactComponent(type, tags);\n },\n toString: function toString() {\n return generateTagsAsString(type, tags, encode);\n }\n };\n }\n};\nvar mapStateOnServer = function mapStateOnServer(_ref) {\n var baseTag = _ref.baseTag,\n bodyAttributes = _ref.bodyAttributes,\n encode = _ref.encode,\n htmlAttributes = _ref.htmlAttributes,\n linkTags = _ref.linkTags,\n metaTags = _ref.metaTags,\n noscriptTags = _ref.noscriptTags,\n scriptTags = _ref.scriptTags,\n styleTags = _ref.styleTags,\n _ref$title = _ref.title,\n title = _ref$title === undefined ? \"\" : _ref$title,\n titleAttributes = _ref.titleAttributes;\n return {\n base: getMethodsForTag(TAG_NAMES.BASE, baseTag, encode),\n bodyAttributes: getMethodsForTag(ATTRIBUTE_NAMES.BODY, bodyAttributes, encode),\n htmlAttributes: getMethodsForTag(ATTRIBUTE_NAMES.HTML, htmlAttributes, encode),\n link: getMethodsForTag(TAG_NAMES.LINK, linkTags, encode),\n meta: getMethodsForTag(TAG_NAMES.META, metaTags, encode),\n noscript: getMethodsForTag(TAG_NAMES.NOSCRIPT, noscriptTags, encode),\n script: getMethodsForTag(TAG_NAMES.SCRIPT, scriptTags, encode),\n style: getMethodsForTag(TAG_NAMES.STYLE, styleTags, encode),\n title: getMethodsForTag(TAG_NAMES.TITLE, {\n title: title,\n titleAttributes: titleAttributes\n }, encode)\n };\n};\nvar Helmet = function Helmet(Component) {\n var _class, _temp;\n return _temp = _class = function (_React$Component) {\n inherits(HelmetWrapper, _React$Component);\n function HelmetWrapper() {\n classCallCheck(this, HelmetWrapper);\n return possibleConstructorReturn(this, _React$Component.apply(this, arguments));\n }\n HelmetWrapper.prototype.shouldComponentUpdate = function shouldComponentUpdate(nextProps) {\n return !isEqual(this.props, nextProps);\n };\n HelmetWrapper.prototype.mapNestedChildrenToProps = function mapNestedChildrenToProps(child, nestedChildren) {\n if (!nestedChildren) {\n return null;\n }\n switch (child.type) {\n case TAG_NAMES.SCRIPT:\n case TAG_NAMES.NOSCRIPT:\n return {\n innerHTML: nestedChildren\n };\n case TAG_NAMES.STYLE:\n return {\n cssText: nestedChildren\n };\n }\n throw new Error(\"<\" + child.type + \" /> elements are self-closing and can not contain children. Refer to our API for more information.\");\n };\n HelmetWrapper.prototype.flattenArrayTypeChildren = function flattenArrayTypeChildren(_ref) {\n var _babelHelpers$extends;\n var child = _ref.child,\n arrayTypeChildren = _ref.arrayTypeChildren,\n newChildProps = _ref.newChildProps,\n nestedChildren = _ref.nestedChildren;\n return _extends({}, arrayTypeChildren, (_babelHelpers$extends = {}, _babelHelpers$extends[child.type] = [].concat(arrayTypeChildren[child.type] || [], [_extends({}, newChildProps, this.mapNestedChildrenToProps(child, nestedChildren))]), _babelHelpers$extends));\n };\n HelmetWrapper.prototype.mapObjectTypeChildren = function mapObjectTypeChildren(_ref2) {\n var _babelHelpers$extends2, _babelHelpers$extends3;\n var child = _ref2.child,\n newProps = _ref2.newProps,\n newChildProps = _ref2.newChildProps,\n nestedChildren = _ref2.nestedChildren;\n switch (child.type) {\n case TAG_NAMES.TITLE:\n return _extends({}, newProps, (_babelHelpers$extends2 = {}, _babelHelpers$extends2[child.type] = nestedChildren, _babelHelpers$extends2.titleAttributes = _extends({}, newChildProps), _babelHelpers$extends2));\n case TAG_NAMES.BODY:\n return _extends({}, newProps, {\n bodyAttributes: _extends({}, newChildProps)\n });\n case TAG_NAMES.HTML:\n return _extends({}, newProps, {\n htmlAttributes: _extends({}, newChildProps)\n });\n }\n return _extends({}, newProps, (_babelHelpers$extends3 = {}, _babelHelpers$extends3[child.type] = _extends({}, newChildProps), _babelHelpers$extends3));\n };\n HelmetWrapper.prototype.mapArrayTypeChildrenToProps = function mapArrayTypeChildrenToProps(arrayTypeChildren, newProps) {\n var newFlattenedProps = _extends({}, newProps);\n Object.keys(arrayTypeChildren).forEach(function (arrayChildName) {\n var _babelHelpers$extends4;\n newFlattenedProps = _extends({}, newFlattenedProps, (_babelHelpers$extends4 = {}, _babelHelpers$extends4[arrayChildName] = arrayTypeChildren[arrayChildName], _babelHelpers$extends4));\n });\n return newFlattenedProps;\n };\n HelmetWrapper.prototype.warnOnInvalidChildren = function warnOnInvalidChildren(child, nestedChildren) {\n if (process.env.NODE_ENV !== \"production\") {\n if (!VALID_TAG_NAMES.some(function (name) {\n return child.type === name;\n })) {\n if (typeof child.type === \"function\") {\n return warn(\"You may be attempting to nest components within each other, which is not allowed. Refer to our API for more information.\");\n }\n return warn(\"Only elements types \" + VALID_TAG_NAMES.join(\", \") + \" are allowed. Helmet does not support rendering <\" + child.type + \"> elements. Refer to our API for more information.\");\n }\n if (nestedChildren && typeof nestedChildren !== \"string\" && (!Array.isArray(nestedChildren) || nestedChildren.some(function (nestedChild) {\n return typeof nestedChild !== \"string\";\n }))) {\n throw new Error(\"Helmet expects a string as a child of <\" + child.type + \">. Did you forget to wrap your children in braces? ( <\" + child.type + \">{``} ) Refer to our API for more information.\");\n }\n }\n return true;\n };\n HelmetWrapper.prototype.mapChildrenToProps = function mapChildrenToProps(children, newProps) {\n var _this2 = this;\n var arrayTypeChildren = {};\n React.Children.forEach(children, function (child) {\n if (!child || !child.props) {\n return;\n }\n var _child$props = child.props,\n nestedChildren = _child$props.children,\n childProps = objectWithoutProperties(_child$props, [\"children\"]);\n var newChildProps = convertReactPropstoHtmlAttributes(childProps);\n _this2.warnOnInvalidChildren(child, nestedChildren);\n switch (child.type) {\n case TAG_NAMES.LINK:\n case TAG_NAMES.META:\n case TAG_NAMES.NOSCRIPT:\n case TAG_NAMES.SCRIPT:\n case TAG_NAMES.STYLE:\n arrayTypeChildren = _this2.flattenArrayTypeChildren({\n child: child,\n arrayTypeChildren: arrayTypeChildren,\n newChildProps: newChildProps,\n nestedChildren: nestedChildren\n });\n break;\n default:\n newProps = _this2.mapObjectTypeChildren({\n child: child,\n newProps: newProps,\n newChildProps: newChildProps,\n nestedChildren: nestedChildren\n });\n break;\n }\n });\n newProps = this.mapArrayTypeChildrenToProps(arrayTypeChildren, newProps);\n return newProps;\n };\n HelmetWrapper.prototype.render = function render() {\n var _props = this.props,\n children = _props.children,\n props = objectWithoutProperties(_props, [\"children\"]);\n var newProps = _extends({}, props);\n if (children) {\n newProps = this.mapChildrenToProps(children, newProps);\n }\n return React.createElement(Component, newProps);\n };\n createClass(HelmetWrapper, null, [{\n key: \"canUseDOM\",\n // Component.peek comes from react-side-effect:\n // For testing, you may use a static peek() method available on the returned component.\n // It lets you get the current state without resetting the mounted instance stack.\n // Don’t use it for anything other than testing.\n\n /**\n * @param {Object} base: {\"target\": \"_blank\", \"href\": \"http://mysite.com/\"}\n * @param {Object} bodyAttributes: {\"className\": \"root\"}\n * @param {String} defaultTitle: \"Default Title\"\n * @param {Boolean} defer: true\n * @param {Boolean} encodeSpecialCharacters: true\n * @param {Object} htmlAttributes: {\"lang\": \"en\", \"amp\": undefined}\n * @param {Array} link: [{\"rel\": \"canonical\", \"href\": \"http://mysite.com/example\"}]\n * @param {Array} meta: [{\"name\": \"description\", \"content\": \"Test description\"}]\n * @param {Array} noscript: [{\"innerHTML\": \" console.log(newState)\"\n * @param {Array} script: [{\"type\": \"text/javascript\", \"src\": \"http://mysite.com/js/test.js\"}]\n * @param {Array} style: [{\"type\": \"text/css\", \"cssText\": \"div { display: block; color: blue; }\"}]\n * @param {String} title: \"Title\"\n * @param {Object} titleAttributes: {\"itemprop\": \"name\"}\n * @param {String} titleTemplate: \"MySite.com - %s\"\n */\n set: function set$$1(canUseDOM) {\n Component.canUseDOM = canUseDOM;\n }\n }]);\n return HelmetWrapper;\n }(React.Component), _class.propTypes = {\n base: PropTypes.object,\n bodyAttributes: PropTypes.object,\n children: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.node), PropTypes.node]),\n defaultTitle: PropTypes.string,\n defer: PropTypes.bool,\n encodeSpecialCharacters: PropTypes.bool,\n htmlAttributes: PropTypes.object,\n link: PropTypes.arrayOf(PropTypes.object),\n meta: PropTypes.arrayOf(PropTypes.object),\n noscript: PropTypes.arrayOf(PropTypes.object),\n onChangeClientState: PropTypes.func,\n script: PropTypes.arrayOf(PropTypes.object),\n style: PropTypes.arrayOf(PropTypes.object),\n title: PropTypes.string,\n titleAttributes: PropTypes.object,\n titleTemplate: PropTypes.string\n }, _class.defaultProps = {\n defer: true,\n encodeSpecialCharacters: true\n }, _class.peek = Component.peek, _class.rewind = function () {\n var mappedState = Component.rewind();\n if (!mappedState) {\n // provide fallback if mappedState is undefined\n mappedState = mapStateOnServer({\n baseTag: [],\n bodyAttributes: {},\n encodeSpecialCharacters: true,\n htmlAttributes: {},\n linkTags: [],\n metaTags: [],\n noscriptTags: [],\n scriptTags: [],\n styleTags: [],\n title: \"\",\n titleAttributes: {}\n });\n }\n return mappedState;\n }, _temp;\n};\nvar NullComponent = function NullComponent() {\n return null;\n};\nvar HelmetSideEffects = withSideEffect(reducePropsToState, handleClientStateChange, mapStateOnServer)(NullComponent);\nvar HelmetExport = Helmet(HelmetSideEffects);\nHelmetExport.renderStatic = HelmetExport.rewind;\nexport default HelmetExport;\nexport { HelmetExport as Helmet };","'use strict';\n\nfunction _interopDefault(ex) {\n return ex && typeof ex === 'object' && 'default' in ex ? ex['default'] : ex;\n}\nvar React = require('react');\nvar React__default = _interopDefault(React);\nfunction _defineProperty(obj, key, value) {\n if (key in obj) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n } else {\n obj[key] = value;\n }\n return obj;\n}\nfunction _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n subClass.__proto__ = superClass;\n}\nvar canUseDOM = !!(typeof window !== 'undefined' && window.document && window.document.createElement);\nfunction withSideEffect(reducePropsToState, handleStateChangeOnClient, mapStateOnServer) {\n if (typeof reducePropsToState !== 'function') {\n throw new Error('Expected reducePropsToState to be a function.');\n }\n if (typeof handleStateChangeOnClient !== 'function') {\n throw new Error('Expected handleStateChangeOnClient to be a function.');\n }\n if (typeof mapStateOnServer !== 'undefined' && typeof mapStateOnServer !== 'function') {\n throw new Error('Expected mapStateOnServer to either be undefined or a function.');\n }\n function getDisplayName(WrappedComponent) {\n return WrappedComponent.displayName || WrappedComponent.name || 'Component';\n }\n return function wrap(WrappedComponent) {\n if (typeof WrappedComponent !== 'function') {\n throw new Error('Expected WrappedComponent to be a React component.');\n }\n var mountedInstances = [];\n var state;\n function emitChange() {\n state = reducePropsToState(mountedInstances.map(function (instance) {\n return instance.props;\n }));\n if (SideEffect.canUseDOM) {\n handleStateChangeOnClient(state);\n } else if (mapStateOnServer) {\n state = mapStateOnServer(state);\n }\n }\n var SideEffect = /*#__PURE__*/\n function (_PureComponent) {\n _inheritsLoose(SideEffect, _PureComponent);\n function SideEffect() {\n return _PureComponent.apply(this, arguments) || this;\n }\n\n // Try to use displayName of wrapped component\n // Expose canUseDOM so tests can monkeypatch it\n SideEffect.peek = function peek() {\n return state;\n };\n SideEffect.rewind = function rewind() {\n if (SideEffect.canUseDOM) {\n throw new Error('You may only call rewind() on the server. Call peek() to read the current state.');\n }\n var recordedState = state;\n state = undefined;\n mountedInstances = [];\n return recordedState;\n };\n var _proto = SideEffect.prototype;\n _proto.UNSAFE_componentWillMount = function UNSAFE_componentWillMount() {\n mountedInstances.push(this);\n emitChange();\n };\n _proto.componentDidUpdate = function componentDidUpdate() {\n emitChange();\n };\n _proto.componentWillUnmount = function componentWillUnmount() {\n var index = mountedInstances.indexOf(this);\n mountedInstances.splice(index, 1);\n emitChange();\n };\n _proto.render = function render() {\n return React__default.createElement(WrappedComponent, this.props);\n };\n return SideEffect;\n }(React.PureComponent);\n _defineProperty(SideEffect, \"displayName\", \"SideEffect(\" + getDisplayName(WrappedComponent) + \")\");\n _defineProperty(SideEffect, \"canUseDOM\", canUseDOM);\n return SideEffect;\n };\n}\nmodule.exports = withSideEffect;","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nexports.__esModule = true;\nexports.withPrefix = withPrefix;\nexports.withAssetPrefix = withAssetPrefix;\nexports.navigate = exports.default = void 0;\n\nvar _objectWithoutPropertiesLoose2 = _interopRequireDefault(require(\"@babel/runtime/helpers/objectWithoutPropertiesLoose\"));\n\nvar _assertThisInitialized2 = _interopRequireDefault(require(\"@babel/runtime/helpers/assertThisInitialized\"));\n\nvar _inheritsLoose2 = _interopRequireDefault(require(\"@babel/runtime/helpers/inheritsLoose\"));\n\nvar _extends2 = _interopRequireDefault(require(\"@babel/runtime/helpers/extends\"));\n\nvar _propTypes = _interopRequireDefault(require(\"prop-types\"));\n\nvar _react = _interopRequireDefault(require(\"react\"));\n\nvar _reachRouter = require(\"@gatsbyjs/reach-router\");\n\nvar _utils = require(\"@gatsbyjs/reach-router/lib/utils\");\n\nvar _parsePath = require(\"./parse-path\");\n\nexports.parsePath = _parsePath.parsePath;\nvar _excluded = [\"to\", \"getProps\", \"onClick\", \"onMouseEnter\", \"activeClassName\", \"activeStyle\", \"innerRef\", \"partiallyActive\", \"state\", \"replace\", \"_location\"];\n\nvar isAbsolutePath = function isAbsolutePath(path) {\n return path === null || path === void 0 ? void 0 : path.startsWith(\"/\");\n};\n\nfunction withPrefix(path, prefix) {\n var _ref, _prefix;\n\n if (prefix === void 0) {\n prefix = getGlobalBasePrefix();\n }\n\n if (!isLocalLink(path)) {\n return path;\n }\n\n if (path.startsWith(\"./\") || path.startsWith(\"../\")) {\n return path;\n }\n\n var base = (_ref = (_prefix = prefix) !== null && _prefix !== void 0 ? _prefix : getGlobalPathPrefix()) !== null && _ref !== void 0 ? _ref : \"/\";\n return \"\" + (base !== null && base !== void 0 && base.endsWith(\"/\") ? base.slice(0, -1) : base) + (path.startsWith(\"/\") ? path : \"/\" + path);\n} // These global values are wrapped in typeof clauses to ensure the values exist.\n// This is especially problematic in unit testing of this component.\n\n\nvar getGlobalPathPrefix = function getGlobalPathPrefix() {\n return process.env.NODE_ENV !== \"production\" ? typeof __PATH_PREFIX__ !== \"undefined\" ? __PATH_PREFIX__ : undefined : __PATH_PREFIX__;\n};\n\nvar getGlobalBasePrefix = function getGlobalBasePrefix() {\n return process.env.NODE_ENV !== \"production\" ? typeof __BASE_PATH__ !== \"undefined\" ? __BASE_PATH__ : undefined : __BASE_PATH__;\n};\n\nvar isLocalLink = function isLocalLink(path) {\n return path && !path.startsWith(\"http://\") && !path.startsWith(\"https://\") && !path.startsWith(\"//\");\n};\n\nfunction withAssetPrefix(path) {\n return withPrefix(path, getGlobalPathPrefix());\n}\n\nfunction absolutify(path, current) {\n // If it's already absolute, return as-is\n if (isAbsolutePath(path)) {\n return path;\n }\n\n return (0, _utils.resolve)(path, current);\n}\n\nvar rewriteLinkPath = function rewriteLinkPath(path, relativeTo) {\n if (typeof path === \"number\") {\n return path;\n }\n\n if (!isLocalLink(path)) {\n return path;\n }\n\n return isAbsolutePath(path) ? withPrefix(path) : absolutify(path, relativeTo);\n};\n\nvar NavLinkPropTypes = {\n activeClassName: _propTypes.default.string,\n activeStyle: _propTypes.default.object,\n partiallyActive: _propTypes.default.bool\n}; // Set up IntersectionObserver\n\nvar createIntersectionObserver = function createIntersectionObserver(el, cb) {\n var io = new window.IntersectionObserver(function (entries) {\n entries.forEach(function (entry) {\n if (el === entry.target) {\n // Check if element is within viewport, remove listener, destroy observer, and run link callback.\n // MSEdge doesn't currently support isIntersecting, so also test for an intersectionRatio > 0\n if (entry.isIntersecting || entry.intersectionRatio > 0) {\n io.unobserve(el);\n io.disconnect();\n cb();\n }\n }\n });\n }); // Add element to the observer\n\n io.observe(el);\n return {\n instance: io,\n el: el\n };\n};\n\nfunction GatsbyLinkLocationWrapper(props) {\n return /*#__PURE__*/_react.default.createElement(_reachRouter.Location, null, function (_ref2) {\n var location = _ref2.location;\n return /*#__PURE__*/_react.default.createElement(GatsbyLink, (0, _extends2.default)({}, props, {\n _location: location\n }));\n });\n}\n\nvar GatsbyLink = /*#__PURE__*/function (_React$Component) {\n (0, _inheritsLoose2.default)(GatsbyLink, _React$Component);\n\n function GatsbyLink(props) {\n var _this;\n\n _this = _React$Component.call(this, props) || this; // Default to no support for IntersectionObserver\n\n _this.defaultGetProps = function (_ref3) {\n var isPartiallyCurrent = _ref3.isPartiallyCurrent,\n isCurrent = _ref3.isCurrent;\n\n if (_this.props.partiallyActive ? isPartiallyCurrent : isCurrent) {\n return {\n className: [_this.props.className, _this.props.activeClassName].filter(Boolean).join(\" \"),\n style: (0, _extends2.default)({}, _this.props.style, _this.props.activeStyle)\n };\n }\n\n return null;\n };\n\n var IOSupported = false;\n\n if (typeof window !== \"undefined\" && window.IntersectionObserver) {\n IOSupported = true;\n }\n\n _this.state = {\n IOSupported: IOSupported\n };\n _this.handleRef = _this.handleRef.bind((0, _assertThisInitialized2.default)(_this));\n return _this;\n }\n\n var _proto = GatsbyLink.prototype;\n\n _proto._prefetch = function _prefetch() {\n var currentPath = window.location.pathname; // reach router should have the correct state\n\n if (this.props._location && this.props._location.pathname) {\n currentPath = this.props._location.pathname;\n }\n\n var rewrittenPath = rewriteLinkPath(this.props.to, currentPath);\n var newPathName = (0, _parsePath.parsePath)(rewrittenPath).pathname; // Prefech is used to speed up next navigations. When you use it on the current navigation,\n // there could be a race-condition where Chrome uses the stale data instead of waiting for the network to complete\n\n if (currentPath !== newPathName) {\n ___loader.enqueue(newPathName);\n }\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps, prevState) {\n // Preserve non IO functionality if no support\n if (this.props.to !== prevProps.to && !this.state.IOSupported) {\n this._prefetch();\n }\n };\n\n _proto.componentDidMount = function componentDidMount() {\n // Preserve non IO functionality if no support\n if (!this.state.IOSupported) {\n this._prefetch();\n }\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n if (!this.io) {\n return;\n }\n\n var _this$io = this.io,\n instance = _this$io.instance,\n el = _this$io.el;\n instance.unobserve(el);\n instance.disconnect();\n };\n\n _proto.handleRef = function handleRef(ref) {\n var _this2 = this;\n\n if (this.props.innerRef && this.props.innerRef.hasOwnProperty(\"current\")) {\n this.props.innerRef.current = ref;\n } else if (this.props.innerRef) {\n this.props.innerRef(ref);\n }\n\n if (this.state.IOSupported && ref) {\n // If IO supported and element reference found, setup Observer functionality\n this.io = createIntersectionObserver(ref, function () {\n _this2._prefetch();\n });\n }\n };\n\n _proto.render = function render() {\n var _this3 = this;\n\n var _this$props = this.props,\n to = _this$props.to,\n _this$props$getProps = _this$props.getProps,\n getProps = _this$props$getProps === void 0 ? this.defaultGetProps : _this$props$getProps,\n _onClick = _this$props.onClick,\n _onMouseEnter = _this$props.onMouseEnter,\n $activeClassName = _this$props.activeClassName,\n $activeStyle = _this$props.activeStyle,\n $innerRef = _this$props.innerRef,\n partiallyActive = _this$props.partiallyActive,\n state = _this$props.state,\n replace = _this$props.replace,\n _location = _this$props._location,\n rest = (0, _objectWithoutPropertiesLoose2.default)(_this$props, _excluded);\n\n if (process.env.NODE_ENV !== \"production\" && !isLocalLink(to)) {\n console.warn(\"External link \" + to + \" was detected in a Link component. Use the Link component only for internal links. See: https://gatsby.dev/internal-links\");\n }\n\n var prefixedTo = rewriteLinkPath(to, _location.pathname);\n\n if (!isLocalLink(prefixedTo)) {\n return /*#__PURE__*/_react.default.createElement(\"a\", (0, _extends2.default)({\n href: prefixedTo\n }, rest));\n }\n\n return /*#__PURE__*/_react.default.createElement(_reachRouter.Link, (0, _extends2.default)({\n to: prefixedTo,\n state: state,\n getProps: getProps,\n innerRef: this.handleRef,\n onMouseEnter: function onMouseEnter(e) {\n if (_onMouseEnter) {\n _onMouseEnter(e);\n }\n\n ___loader.hovering((0, _parsePath.parsePath)(prefixedTo).pathname);\n },\n onClick: function onClick(e) {\n if (_onClick) {\n _onClick(e);\n }\n\n if (e.button === 0 && // ignore right clicks\n !_this3.props.target && // let browser handle \"target=_blank\"\n !e.defaultPrevented && // onClick prevented default\n !e.metaKey && // ignore clicks with modifier keys...\n !e.altKey && !e.ctrlKey && !e.shiftKey) {\n e.preventDefault();\n var shouldReplace = replace;\n\n var isCurrent = encodeURI(prefixedTo) === _location.pathname;\n\n if (typeof replace !== \"boolean\" && isCurrent) {\n shouldReplace = true;\n } // Make sure the necessary scripts and data are\n // loaded before continuing.\n\n\n window.___navigate(prefixedTo, {\n state: state,\n replace: shouldReplace\n });\n }\n\n return true;\n }\n }, rest));\n };\n\n return GatsbyLink;\n}(_react.default.Component);\n\nGatsbyLink.propTypes = (0, _extends2.default)({}, NavLinkPropTypes, {\n onClick: _propTypes.default.func,\n to: _propTypes.default.string.isRequired,\n replace: _propTypes.default.bool,\n state: _propTypes.default.object\n});\n\nvar _default = /*#__PURE__*/_react.default.forwardRef(function (props, ref) {\n return /*#__PURE__*/_react.default.createElement(GatsbyLinkLocationWrapper, (0, _extends2.default)({\n innerRef: ref\n }, props));\n});\n\nexports.default = _default;\n\nvar navigate = function navigate(to, options) {\n window.___navigate(rewriteLinkPath(to, window.location.pathname), options);\n};\n\nexports.navigate = navigate;","\"use strict\";\n\nexports.__esModule = true;\nexports.parsePath = parsePath;\n\nfunction parsePath(path) {\n var pathname = path || \"/\";\n var search = \"\";\n var hash = \"\";\n var hashIndex = pathname.indexOf(\"#\");\n\n if (hashIndex !== -1) {\n hash = pathname.substr(hashIndex);\n pathname = pathname.substr(0, hashIndex);\n }\n\n var searchIndex = pathname.indexOf(\"?\");\n\n if (searchIndex !== -1) {\n search = pathname.substr(searchIndex);\n pathname = pathname.substr(0, searchIndex);\n }\n\n return {\n pathname: pathname,\n search: search === \"?\" ? \"\" : search,\n hash: hash === \"#\" ? \"\" : hash\n };\n}","\"use strict\";\n\nexports.__esModule = true;\nexports.useScrollRestoration = exports.ScrollContext = void 0;\n\nvar _scrollHandler = require(\"./scroll-handler\");\n\nexports.ScrollContext = _scrollHandler.ScrollHandler;\n\nvar _useScrollRestoration = require(\"./use-scroll-restoration\");\n\nexports.useScrollRestoration = _useScrollRestoration.useScrollRestoration;","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nexports.__esModule = true;\nexports.ScrollHandler = exports.ScrollContext = void 0;\n\nvar _assertThisInitialized2 = _interopRequireDefault(require(\"@babel/runtime/helpers/assertThisInitialized\"));\n\nvar _inheritsLoose2 = _interopRequireDefault(require(\"@babel/runtime/helpers/inheritsLoose\"));\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _propTypes = _interopRequireDefault(require(\"prop-types\"));\n\nvar _sessionStorage = require(\"./session-storage\");\n\nfunction _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== \"function\") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }\n\nfunction _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== \"object\" && typeof obj !== \"function\") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== \"default\" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }\n\nvar ScrollContext = /*#__PURE__*/React.createContext(new _sessionStorage.SessionStorage());\nexports.ScrollContext = ScrollContext;\nScrollContext.displayName = \"GatsbyScrollContext\";\n\nvar ScrollHandler = /*#__PURE__*/function (_React$Component) {\n (0, _inheritsLoose2.default)(ScrollHandler, _React$Component);\n\n function ScrollHandler() {\n var _this;\n\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n _this = _React$Component.call.apply(_React$Component, [this].concat(args)) || this;\n _this._stateStorage = new _sessionStorage.SessionStorage();\n _this._isTicking = false;\n _this._latestKnownScrollY = 0;\n\n _this.scrollListener = function () {\n _this._latestKnownScrollY = window.scrollY;\n\n if (!_this._isTicking) {\n _this._isTicking = true;\n requestAnimationFrame(_this._saveScroll.bind((0, _assertThisInitialized2.default)(_this)));\n }\n };\n\n _this.windowScroll = function (position, prevProps) {\n if (_this.shouldUpdateScroll(prevProps, _this.props)) {\n window.scrollTo(0, position);\n }\n };\n\n _this.scrollToHash = function (hash, prevProps) {\n var node = document.getElementById(hash.substring(1));\n\n if (node && _this.shouldUpdateScroll(prevProps, _this.props)) {\n node.scrollIntoView();\n }\n };\n\n _this.shouldUpdateScroll = function (prevRouterProps, routerProps) {\n var shouldUpdateScroll = _this.props.shouldUpdateScroll;\n\n if (!shouldUpdateScroll) {\n return true;\n } // Hack to allow accessing this._stateStorage.\n\n\n return shouldUpdateScroll.call((0, _assertThisInitialized2.default)(_this), prevRouterProps, routerProps);\n };\n\n return _this;\n }\n\n var _proto = ScrollHandler.prototype;\n\n _proto._saveScroll = function _saveScroll() {\n var key = this.props.location.key || null;\n\n if (key) {\n this._stateStorage.save(this.props.location, key, this._latestKnownScrollY);\n }\n\n this._isTicking = false;\n };\n\n _proto.componentDidMount = function componentDidMount() {\n window.addEventListener(\"scroll\", this.scrollListener);\n var scrollPosition;\n var _this$props$location = this.props.location,\n key = _this$props$location.key,\n hash = _this$props$location.hash;\n\n if (key) {\n scrollPosition = this._stateStorage.read(this.props.location, key);\n }\n\n if (scrollPosition) {\n this.windowScroll(scrollPosition, undefined);\n } else if (hash) {\n this.scrollToHash(decodeURI(hash), undefined);\n }\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n window.removeEventListener(\"scroll\", this.scrollListener);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var _this$props$location2 = this.props.location,\n hash = _this$props$location2.hash,\n key = _this$props$location2.key;\n var scrollPosition;\n\n if (key) {\n scrollPosition = this._stateStorage.read(this.props.location, key);\n }\n /** There are two pieces of state: the browser url and\n * history state which keeps track of scroll position\n * Native behaviour prescribes that we ought to restore scroll position\n * when a user navigates back in their browser (this is the `POP` action)\n * Currently, reach router has a bug that prevents this at https://github.com/reach/router/issues/228\n * So we _always_ stick to the url as a source of truth — if the url\n * contains a hash, we scroll to it\n */\n\n\n if (hash) {\n this.scrollToHash(decodeURI(hash), prevProps);\n } else {\n this.windowScroll(scrollPosition, prevProps);\n }\n };\n\n _proto.render = function render() {\n return /*#__PURE__*/React.createElement(ScrollContext.Provider, {\n value: this._stateStorage\n }, this.props.children);\n };\n\n return ScrollHandler;\n}(React.Component);\n\nexports.ScrollHandler = ScrollHandler;\nScrollHandler.propTypes = {\n shouldUpdateScroll: _propTypes.default.func,\n children: _propTypes.default.element.isRequired,\n location: _propTypes.default.object.isRequired\n};","\"use strict\";\n\nexports.__esModule = true;\nexports.SessionStorage = void 0;\nvar STATE_KEY_PREFIX = \"@@scroll|\";\nvar GATSBY_ROUTER_SCROLL_STATE = \"___GATSBY_REACT_ROUTER_SCROLL\";\n\nvar SessionStorage = /*#__PURE__*/function () {\n function SessionStorage() {}\n\n var _proto = SessionStorage.prototype;\n\n _proto.read = function read(location, key) {\n var stateKey = this.getStateKey(location, key);\n\n try {\n var value = window.sessionStorage.getItem(stateKey);\n return value ? JSON.parse(value) : 0;\n } catch (e) {\n if (process.env.NODE_ENV !== \"production\") {\n console.warn(\"[gatsby-react-router-scroll] Unable to access sessionStorage; sessionStorage is not available.\");\n }\n\n if (window && window[GATSBY_ROUTER_SCROLL_STATE] && window[GATSBY_ROUTER_SCROLL_STATE][stateKey]) {\n return window[GATSBY_ROUTER_SCROLL_STATE][stateKey];\n }\n\n return 0;\n }\n };\n\n _proto.save = function save(location, key, value) {\n var stateKey = this.getStateKey(location, key);\n var storedValue = JSON.stringify(value);\n\n try {\n window.sessionStorage.setItem(stateKey, storedValue);\n } catch (e) {\n if (window && window[GATSBY_ROUTER_SCROLL_STATE]) {\n window[GATSBY_ROUTER_SCROLL_STATE][stateKey] = JSON.parse(storedValue);\n } else {\n window[GATSBY_ROUTER_SCROLL_STATE] = {};\n window[GATSBY_ROUTER_SCROLL_STATE][stateKey] = JSON.parse(storedValue);\n }\n\n if (process.env.NODE_ENV !== \"production\") {\n console.warn(\"[gatsby-react-router-scroll] Unable to save state in sessionStorage; sessionStorage is not available.\");\n }\n }\n };\n\n _proto.getStateKey = function getStateKey(location, key) {\n var stateKeyBase = \"\" + STATE_KEY_PREFIX + location.pathname;\n return key === null || typeof key === \"undefined\" ? stateKeyBase : stateKeyBase + \"|\" + key;\n };\n\n return SessionStorage;\n}();\n\nexports.SessionStorage = SessionStorage;","\"use strict\";\n\nexports.__esModule = true;\nexports.useScrollRestoration = useScrollRestoration;\n\nvar _scrollHandler = require(\"./scroll-handler\");\n\nvar _react = require(\"react\");\n\nvar _reachRouter = require(\"@gatsbyjs/reach-router\");\n\nfunction useScrollRestoration(identifier) {\n var location = (0, _reachRouter.useLocation)();\n var state = (0, _react.useContext)(_scrollHandler.ScrollContext);\n var ref = (0, _react.useRef)(null);\n (0, _react.useLayoutEffect)(function () {\n if (ref.current) {\n var position = state.read(location, identifier);\n ref.current.scrollTo(0, position || 0);\n }\n }, [location.key]);\n return {\n ref: ref,\n onScroll: function onScroll() {\n if (ref.current) {\n state.save(location, identifier, ref.current.scrollTop);\n }\n }\n };\n}","import React from 'react';\nimport { randomKey, testEnv } from '../functions/common';\n\n//* This adds a text snippet above most elements on the page in dev mode,\n//* when the GATSBY_DEV_MODE variable is set to 'true'.\n//* This stuff should never appear on a non-dev site.\n\nexport const DevAids = ({ node, pageLinks = false }) => {\n const env = testEnv(),\n apiDomain = process.env.GATSBY_DRUPAL_DOMAIN;\n\n if (typeof node !== 'object') return ;\n\n const id = node.internal?.id || null,\n type = node.type || node.internal?.type || null,\n drupalId = node.drupal_id || null;\n\n /* overflow:hidden helped to test mobile views where uuid was causing\n /* width layout issues.\n */\n const devAids =\n env.devMode === true ? (\n pageLinks === false ? (\n
\n          Gatsby node type: {type || 'Unknown'}\n          
\n {(id && `Gatsby ID: ${id}`) ||\n (drupalId && `Drupal UUID: ${drupalId}`) ||\n 'No Gatsby ID or Drupal UUID found'}\n
\n ) : (\n \n )\n ) : (\n \n );\n return devAids;\n};\n","import React from 'react';\nimport { Link as GatsbyLink } from 'gatsby';\nimport { isFilePath } from '../../functions/common';\n\n// From Gatby's example:\n// https://www.gatsbyjs.com/docs/reference/built-in-components/gatsby-link/#use-link-only-for-internal-links\n\n// Since DOM elements cannot receive activeClassName\n// and partiallyActive, destructure the prop here and\n// pass it only to GatsbyLink\nconst Link = ({ children, to, activeClassName = '', partiallyActive = false, ...other }) => {\n // This assumes all internal links start with exactly one slash,\n // and that anything else is external.\n const internal = /^\\/(?!\\/)/.test(to),\n linkToFile = isFilePath(to);\n\n // Use Gatsby Link for internal links, and for others\n return internal && !linkToFile ? (\n \n {children}\n \n ) : (\n \n {children}\n \n );\n};\n\nexport default Link;\n","import React from 'react';\nimport { Helmet } from 'react-helmet';\nimport { getParkNames } from '../../functions/common';\n\nconst park = process.env.GATSBY_PARK;\nexport default function HtmlHead() {\n return (\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
\n );\n}\n\nexport function PageMetadata({ title, description, thumbnailImage, path, dateModified }) {\n const domain = 'https://' + getParkNames().domain,\n url = domain + path,\n imageUrl = thumbnailImage ? domain + thumbnailImage : '',\n seoTitle = path === '/' ? `${getParkNames().fullName} | Parks Australia` : `${title} | ${getParkNames().fullName} | Parks Australia`,\n seoLinkedData = JSON.stringify({\n dateModified: dateModified,\n description: description,\n image: imageUrl,\n '@type': 'WebPage',\n url: url,\n headline: seoTitle,\n '@context': 'http://schema.org',\n });\n\n return (\n \n \n \n \n \n \n \n \n \n );\n}\n","import React from 'react';\nimport { getImage, GatsbyImage } from 'gatsby-plugin-image';\nimport { createMenuTree } from './build-menu-tree';\nimport Link from '../../components/elements/link';\nimport { replaceSpecialCharacters, isFilePath } from '../common';\nimport { useStaticQuery, graphql } from 'gatsby';\n\nconst park = process.env.GATSBY_PARK;\nconst menuId = park + '-top-nav';\nconst menuMaxLevel = 3;\n\nfunction toggleNavItemChildren(event) {\n const navButton = event.currentTarget;\n navButton?.classList.toggle('navigation-dropdown__anchor--active');\n navButton?.nextElementSibling.classList.toggle('navigation-dropdown__panel--active');\n}\n\nfunction hasChildren(menuItem) {\n try {\n return menuItem.children?.length !== 0 ? true : false;\n } catch (e) {\n return false;\n }\n}\n\n//* Define HTML of the individual links\nconst buildLink = (menuItem) => {\n let menuLink;\n // Cater for Drupal menu links with no url alias e.g. manually added menu items\n let linkUrl = menuItem.link.uri_alias || menuItem.link.uri;\n\n // Top level menu items\n if (menuItem.menu_level === 1) {\n\n menuLink = (\n \n {menuItem.title}\n \n );\n } else if (menuItem.menu_level === 2 && isFilePath(menuItem.description)) {\n // Show Menu images if the 'Description' field is populated\n // and restrict this layout to level 2 menu items only\n\n let imgData =\n getImage(menuItem.customMediaMenuImage?.customLocalFieldMediaImage2) ||\n menuItem.customMediaMenuImage?.customLocalFieldMediaImage2?.publicURL ||\n null;\n\n menuLink = (\n \n
\n {imgData ? (\n \n ) : (\n \n )}\n
\n {menuItem.title}\n
\n
\n \n );\n } else {\n // 3rd level items, and 2nd level if no valid image path is found\n menuLink = {menuItem.title};\n }\n return menuLink;\n};\n\n// Define the HTML structure of the menu item wrappers down through all levels\nconst buildMenu = (menuArray) => {\n if (!menuArray) {\n return;\n }\n\n let menuShell = [];\n\n for (let item in menuArray) {\n let menuItem = menuArray[item];\n // Hide menu items below a certain level\n if (menuItem.menu_level > menuMaxLevel || menuItem.enabled !== true) {\n // Ignore these items and continue to the next\n continue;\n }\n\n // Top level menu items\n if (menuItem.menu_level === 1) {\n let linkUrl = menuItem.link.uri_alias || menuItem.link.uri;\n menuShell.push(\n
  • \n {buildLink(menuItem)}\n {hasChildren(menuItem) ? (\n \n \n {menuItem.title}\n \n \n
      \n {/* Duplicate the top level menu item for mobiles, as the real one acts as the\n button to expose the child menu and can't be clicked as a link */}\n \n {menuItem.title}\n \n {buildMenu(menuItem.children)}\n
    \n \n
    \n ) : (\n \n {menuItem.title}\n \n )}\n
  • \n );\n } else if (menuItem.menu_level === 2) {\n // Child menu items\n // Level 2 menu items show description images and child menu items\n menuShell.push(\n
  • \n
    \n {buildLink(menuItem)}\n {hasChildren(menuItem) ? (\n
      {buildMenu(menuItem.children)}
    \n ) : (\n \n )}\n
    \n
  • \n );\n } else {\n // Level 3+ menu items, noting only up to L3 is displayed\n // This is the standard menu item, including anything level 2\n // with no children or image path in the description field\n menuShell.push(\n
  • \n {buildLink(menuItem)}\n {/* Not required at this stage, as we only go down to Level 3 */}\n {/* {buildMenu(menuItem.children)} */}\n
  • \n );\n }\n }\n\n return menuShell;\n};\n\nconst generateMenu = (menuLinks) => {\n let menu = createMenuTree(menuLinks.allMenuItem.edges, menuId);\n const builtMenu = buildMenu(menu);\n return builtMenu;\n};\n\nexport default function MainMenu() {\n // This query deliberately returns all items for all menus,\n // which are then filtered above. We can't dynamically filter\n // by park or menu name as static queries don't accept variables.\n // Filtering is done in createMenuTree();\n const data = useStaticQuery(graphql`\n {\n allMenuItem(sort: { fields: weight }) {\n edges {\n node {\n enabled\n title\n menu_name\n customMediaMenuImage {\n ...MediaDataMenuImage\n }\n link {\n uri\n uri_alias\n }\n description\n drupal_id\n bundle\n drupal_parent_menu_item\n weight\n external\n }\n }\n }\n }\n `);\n return data ? (\n
      \n {generateMenu(data)}\n
    \n ) : (\n \n );\n}\n","import React, { memo } from 'react';\nimport { useStaticQuery, graphql } from 'gatsby';\nimport Link from '../elements/link';\nimport { RawText, testEnv, getParkNames, isDummyOrTestContent } from '../../functions/common.js';\n\nconst SiteLogoBlock = memo(() => {\n const park = process.env.GATSBY_PARK,\n data = useStaticQuery(graphql`\n query {\n allBlockContentSiteLogoPanel {\n nodes {\n drupal_id\n info\n field_site_for_block {\n drupal_internal__target_id\n }\n field_site_logo_class\n body {\n value\n }\n relationships {\n field_site_logo {\n ...MediaDataSvgIcon\n }\n }\n }\n }\n }\n `);\n const result = data.allBlockContentSiteLogoPanel.nodes.map((item, index: Number) => {\n if (\n item.field_site_for_block.drupal_internal__target_id === park &&\n isDummyOrTestContent(item.info) === false\n ) {\n const logoImage =\n item.relationships.field_site_logo.customLocalFieldMediaImage1?.publicURL || null,\n logoImageAlt = RawText(item.body?.value ? item.body.value : ''),\n siteLogoClass = item.field_site_logo_class ? item.field_site_logo_class : '';\n\n // Prevent build errors if attempting to render an unpublished image\n if (!logoImage) {\n testEnv().devMode\n ? console.warn(\n `[ISSUE - Images]:No image found in Site Logo block ID ${item.drupal_id}.\\nThis can mean you\\'re trying to render an unpublished media item, or the source image does not have a matching File node in GrahpQL\\n`\n )\n : null;\n }\n return (\n
    \n \n {getParkNames().fullName}\n {/* Allow graceful fallback for Gatsby not correctly saving a childImageSharp version */}\n {logoImage ? (\n {logoImageAlt}\n ) : (\n \n )}\n \n
    \n );\n }\n });\n return <>{result};\n});\n\nexport default SiteLogoBlock;\n","import React, { memo } from 'react';\nimport Link from './link'\n\nconst SkipLinks = memo(() => {\n return (\n
    \n \n Skip to main navigation\n \n \n Skip to main content\n \n \n Skip to search\n \n \n Skip to share on social media\n \n
    \n );\n});\n\nexport default SkipLinks;\n","import React, { memo, useEffect, useState } from 'react';\nimport MainMenu from '../../functions/build_menus/menu-main';\nimport SiteLogoBlock from '../blocks/site-logo';\nimport SkipLinks from '../elements/skip-links';\nimport HtmlHead from './head';\n\nfunction toggleMobileSearch(event) {\n // @TODO: This re-searches the entire DOM every time this runs\n // Refactor to run once and bind on page load. Look into onLoad = {}\n const mobSearchToggleButton = event.currentTarget,\n mobNavToggle = document.getElementById('navigation-mobile-toggle'),\n mainNavLinks = document.getElementsByClassName('navigation-dropdown--main')[0];\n\n mobSearchToggleButton?.classList.toggle('masthead__search-mobile-toggle--active');\n mobNavToggle?.classList.remove('navigation-dropdown--mobile-toggle--active');\n mainNavLinks?.classList.remove('navigation-dropdown--main--active');\n}\n\nfunction toggleMobileNav(event) {\n const mobNavToggleButton = event.currentTarget,\n mobNavToggle = document.getElementById('navigation-mobile-toggle'),\n mainNavLinks = document.getElementsByClassName('navigation-dropdown--main')[0],\n mobSearchToggleButton = document.getElementsByClassName('masthead__search-mobile-toggle')[0];\n\n mobNavToggleButton?.classList.toggle('mobile-nav-active');\n mobNavToggle?.classList.toggle('navigation-dropdown--mobile-toggle--active');\n mainNavLinks?.classList.toggle('navigation-dropdown--main--active');\n mobSearchToggleButton?.classList.remove('masthead__search-mobile-toggle--active');\n}\n\nconst PageHeader = memo(() => {\n const [currentPath, setCurrentPath] = useState('');\n\n // Get the path, to hide the Search bar if we're already on the search page\n useEffect(() => {\n setCurrentPath(document.location.pathname);\n }, []);\n\n return (\n <>\n \n \n \n \n\n
    \n {currentPath !== '/search/' ? (\n
    \n \n \n \n \n \n \n \n
    \n Search\n \n \n \n
    \n ) : (\n \n )}\n
    \n \n );\n});\n\nexport default PageHeader;\n","import React from 'react';\nimport { useStaticQuery, graphql } from 'gatsby';\nimport { isDummyOrTestContent, showTestContent } from '../../functions/common';\n\nexport default function FooterLogosBlock({ park }) {\n const data = useStaticQuery(graphql`\n query {\n allBlockContentFooterLogosPanel {\n nodes {\n info\n field_site_for_block {\n drupal_internal__target_id\n }\n body {\n value\n }\n }\n }\n }\n `);\n const result = data.allBlockContentFooterLogosPanel.nodes.map((item) => {\n if (\n item.field_site_for_block?.drupal_internal__target_id === park &&\n (!isDummyOrTestContent(item.info) || isDummyOrTestContent(item.info && showTestContent))\n ) {\n return (\n \n );\n }\n });\n return
    {result}
    ;\n}\n","import React, { memo } from 'react';\nimport FooterLogosBlock from '../blocks/footer-logos';\nconst park = process.env.GATSBY_PARK;\n\nconst FooterLogosPanel = memo(() => {\n return (\n
    \n
    \n
    \n \n
    \n
    \n
    \n );\n});\n\nexport default FooterLogosPanel;\n","import React from 'react';\nimport { createMenuTree } from './build-menu-tree';\nimport Link from '../../components/elements/link';\nimport { useStaticQuery, graphql } from 'gatsby';\n\nconst park = process.env.GATSBY_PARK;\nconst menuId = park + '-footer-nav';\nconst menuMaxLevel = 2;\n\nconst buildLink = (menuItem) => (\n {menuItem.title}\n);\n\nconst buildMenu = (menuArray) => {\n if (!menuArray) {\n return;\n }\n\n let menu = [];\n\n for (let item in menuArray) {\n let menuItem = menuArray[item];\n\n if (menuItem.menu_level > menuMaxLevel || menuItem.enabled !== true) {\n continue;\n }\n\n // For Top level menu items\n if (menuItem.menu_level === 1) {\n // If the Top level menu item has any children\n // This should be updated to nest all menu items in a single menu, but it\n // breaks styles. See PADM-719\n if (menuItem.children.length !== 0) {\n menu.push(\n
      \n
    • \n {buildLink(menuItem)}\n
    • \n {buildMenu(menuItem.children)}\n
    \n );\n } else {\n // If this Top level menu item has no children\n menu.push(\n
    \n \n {buildLink(menuItem)}\n \n
    \n );\n }\n } else {\n // For all other menu items\n menu.push(\n
  • \n {buildLink(menuItem)}\n
  • \n );\n }\n }\n return menu;\n};\n\nconst generateMenu = (menuLinks) => {\n let menu = createMenuTree(menuLinks.allMenuItem.edges, menuId);\n menu = buildMenu(menu);\n\n return menu && menu.length !== 0 ? menu : [];\n};\n\nexport default function FooterMenu() {\n // This query deliberately returns all items for all menus,\n // which are then filtered above. We can't dynamically filter\n // by park or menu name as static queries don't accept variables.\n // Filtering is done in createMenuTree();\n const data = useStaticQuery(graphql`\n {\n allMenuItem(sort: { fields: weight }) {\n edges {\n node {\n enabled\n title\n menu_name\n link {\n uri\n uri_alias\n }\n description\n drupal_id\n bundle\n drupal_parent_menu_item\n weight\n external\n }\n }\n }\n }\n `);\n return data ? generateMenu(data) : <>;\n}\n","import React from 'react';\nimport { useStaticQuery, graphql } from 'gatsby';\nimport { isDummyOrTestContent, showTestContent, testEnv } from '../../functions/common.js';\nimport Link from '../elements/link';\n\nexport default function FooterNavListBlock({ park }) {\n const data = useStaticQuery(graphql`\n query {\n allBlockContentFooterNavList {\n nodes {\n id\n drupal_id\n info\n field_site_for_block {\n drupal_internal__target_id\n }\n relationships {\n field_footer_social_links {\n field_social_media_link_url {\n title\n uri\n }\n relationships {\n field_social_media_svg_icon {\n ...MediaDataSvgIcon\n }\n }\n }\n field_footer_nav_items {\n field_social_media_link_url {\n title\n uri\n }\n relationships {\n field_social_media_svg_icon {\n ...MediaDataSvgIcon\n }\n }\n }\n }\n }\n }\n }\n `);\n\n const result = data.allBlockContentFooterNavList.nodes.map((item, index: Number) => {\n if (\n item?.field_site_for_block?.drupal_internal__target_id === park &&\n (!isDummyOrTestContent(item.info) || isDummyOrTestContent(item.info) && showTestContent)\n ) {\n const socialLinksArr = item?.relationships?.field_footer_social_links\n ? item.relationships.field_footer_social_links\n : [],\n appStoreLinksArr = item?.relationships?.field_footer_nav_items\n ? item.relationships.field_footer_nav_items\n : [];\n\n const socialLinks = socialLinksArr.map((socialLink, index: Number) => {\n const image =\n socialLink.relationships?.field_social_media_svg_icon?.customLocalFieldMediaImage1\n ?.publicURL || null,\n imageAlt =\n socialLink.relationships?.field_social_media_svg_icon?.field_media_image_1?.alt || '';\n\n // Prevent build errors if attempting to render an unpublished image\n if (!image) {\n testEnv().devMode\n ? console.warn(\n `[ISSUE - Images]: No image found in Footer Nav List block ID ${item.drupal_id}.\\nThis can mean you\\'re trying to render an unpublished media item, or the source image does not have a matching File node in GrahpQL\\n`\n )\n : null;\n }\n\n return (\n
  • \n \n {image ? (\n {imageAlt}\n ) : (\n \n )}\n \n
  • \n );\n });\n\n const appStoreLinksList = appStoreLinksArr.map((appStoreItem, index: Number) => {\n // Includes App Store links, saved under 'Footer Social and App links' custom Block type\n const image =\n appStoreItem.relationships?.field_social_media_svg_icon?.customLocalFieldMediaImage1\n ?.publicURL || null,\n imageAlt =\n appStoreItem.relationships?.field_social_media_svg_icon?.field_media_image_1?.alt || '';\n\n // Prevent build errors if attempting to render an unpublished image\n if (!image) {\n testEnv().devMode\n ? console.warn(\n `[ISSUE - Images]: No image found in Footer Nav List block ID ${item.drupal_id}.\\nThis can mean you\\'re trying to render an unpublished media item, or the source image does not have a matching File node in GrahpQL\\n`\n )\n : null;\n }\n return image ? (\n
  • \n \n {imageAlt}\n \n
  • \n ) : (\n \n );\n });\n return socialLinks.length > 0 || appStoreLinksList.length > 0 ? (\n
      \n {socialLinks.length > 0 && (\n
    • \n
        {socialLinks}
      \n
    • \n )}\n {appStoreLinksList.length > 0 && (\n
    • \n
        {appStoreLinksList}
      \n
    • \n )}\n
    \n ) : (\n \n );\n }\n });\n return result;\n}\n","// @ts-nocheck\nimport React, { memo } from 'react';\nimport FooterMenu from '../../functions/build_menus/menu-footer';\nimport FooterNavListBlock from '../blocks/footer-nav-list';\n\nconst park = process.env.GATSBY_PARK;\n\nconst FooterNavigationPanel = memo(() => {\n return (\n
    \n
    \n
    \n
    \n
    \n \n \n
    \n
    \n
    \n
    \n
    \n );\n});\n\nexport default FooterNavigationPanel;\n","import React from 'react';\nimport { graphql } from 'gatsby';\nimport { isDummyOrTestContent, showTestContent, randomKey } from '../../functions/common';\nimport { DevAids } from '../dev-aids';\n\nexport const CrossSiteTopBannerMessageBlock = ({ nodes }) => {\n const blocks = nodes.nodes.map((item, index: Number) => {\n const enabled = item?.field_enabled;\n const body = item?.body?.processed;\n const info = item?.info;\n\n return body &&\n enabled === true &&\n (!isDummyOrTestContent(info) || (isDummyOrTestContent(info) && showTestContent)) ? (\n \n \n
    \n \n ) : (\n null\n );\n }).filter((item) => item !== null);\n\n return blocks.length > 0 ? (\n
    {blocks}
    \n ) : (\n \n );\n};\n\nexport const fragment = graphql`\n fragment CrossSiteTopBannerMessageBlockQuery on block_content__cross_site_top_banner_messageConnection {\n nodes {\n id\n drupal_id\n internal {\n type\n }\n body {\n processed\n }\n info\n field_enabled\n }\n }\n`;\n","import React from 'react';\nimport { useStaticQuery, graphql } from 'gatsby';\nimport { isDummyOrTestContent, showTestContent } from '../../functions/common';\n\nexport default function SharedParksLogoBlock() {\n const data = useStaticQuery(\n graphql`\n query {\n blockContentSharedFooterParksLogoPanel {\n info\n body {\n value\n }\n }\n }\n `\n );\n if (!data || (isDummyOrTestContent(data?.blockContentSharedFooterParksLogoPanel?.info) === true) && !showTestContent) {\n return <>;\n }\n\n return data?.blockContentSharedFooterParksLogoPanel?.body?.value ? (\n \n ) : (\n <>\n );\n}\n","import React, { memo } from 'react';\nimport SharedParksLogoBlock from '../blocks/shared-parks-logo';\n\nconst FooterSharedParksLogoPanel = memo(() => {\n return (\n
    \n
    \n
    \n \n
    \n
    \n
    \n );\n});\n\nexport default FooterSharedParksLogoPanel;\n","import React from 'react';\nimport { useStaticQuery, graphql } from 'gatsby';\nimport PageHeader from '../components/structure/header';\nimport FooterLogosPanel from '../components/structure/footer-logos-panel';\nimport FooterNavigationPanel from '../components/structure/footer-navigation-panel';\nimport { CrossSiteTopBannerMessageBlock } from '../components/blocks/cross-site-top-banner';\nimport FooterSharedParksLogoPanel from '../components/structure/footer-parks-logo-panel';\n\nexport default function Layout({ children }) {\n const data = useStaticQuery(graphql`\n query {\n allBlockContentCrossSiteTopBannerMessage {\n nodes {\n id\n drupal_id\n internal {\n type\n }\n body {\n processed\n }\n info\n field_enabled\n }\n }\n }\n `);\n\n return (\n <>\n
    \n \n
    \n \n
    \n
    \n
    \n {children}\n
    \n
    \n \n \n \n
    \n \n );\n}\n","import React from \"react\";\nimport \"../styles/marine-parks.scss\";\nimport Layout from './layout';\n\nexport default function PageLayout({ children }) {\n return {children};\n}\n","// prefer default export if available\nconst preferDefault = m => (m && m.default) || m\n\nexports.components = {\n \"component---src-pages-404-js\": () => import(\"./../../../src/pages/404.js\" /* webpackChunkName: \"component---src-pages-404-js\" */),\n \"component---src-pages-search-js\": () => import(\"./../../../src/pages/search.js\" /* webpackChunkName: \"component---src-pages-search-js\" */),\n \"component---src-templates-news-article-tsx\": () => import(\"./../../../src/templates/news-article.tsx\" /* webpackChunkName: \"component---src-templates-news-article-tsx\" */),\n \"component---src-templates-page-tsx\": () => import(\"./../../../src/templates/page.tsx\" /* webpackChunkName: \"component---src-templates-page-tsx\" */),\n \"component---src-templates-place-tsx\": () => import(\"./../../../src/templates/place.tsx\" /* webpackChunkName: \"component---src-templates-place-tsx\" */),\n \"component---src-templates-publication-tsx\": () => import(\"./../../../src/templates/publication.tsx\" /* webpackChunkName: \"component---src-templates-publication-tsx\" */)\n}\n\n","module.exports = [{\n plugin: require('../node_modules/gatsby-plugin-layout/gatsby-browser.js'),\n options: {\"plugins\":[],\"component\":\"/codebuild/output/src4012599656/src/frontend/src/layouts/layout-amp.tsx\"},\n },{\n plugin: require('../node_modules/gatsby-plugin-image/gatsby-browser.js'),\n options: {\"plugins\":[]},\n },{\n plugin: require('../plugins/gatsby-plugin-breakpoint-helper/gatsby-browser.js'),\n options: {\"plugins\":[]},\n },{\n plugin: require('../node_modules/gatsby-plugin-manifest/gatsby-browser.js'),\n options: {\"plugins\":[],\"icon\":\"src/images/amp-favicon.png\",\"legacy\":true,\"theme_color_in_head\":true,\"cache_busting_mode\":\"query\",\"crossOrigin\":\"anonymous\",\"include_favicon\":true,\"cacheDigest\":\"b2bbd45f8432bd3c225f1ea732e050ec\"},\n },{\n plugin: require('../gatsby-browser.js'),\n options: {\"plugins\":[]},\n }]\n","const plugins = require(`./api-runner-browser-plugins`)\nconst { getResourceURLsForPathname, loadPage, loadPageSync } =\n require(`./loader`).publicLoader\n\nexports.apiRunner = (api, args = {}, defaultReturn, argTransform) => {\n // Hooks for gatsby-cypress's API handler\n if (process.env.CYPRESS_SUPPORT) {\n if (window.___apiHandler) {\n window.___apiHandler(api)\n } else if (window.___resolvedAPIs) {\n window.___resolvedAPIs.push(api)\n } else {\n window.___resolvedAPIs = [api]\n }\n }\n\n let results = plugins.map(plugin => {\n if (!plugin.plugin[api]) {\n return undefined\n }\n\n args.getResourceURLsForPathname = getResourceURLsForPathname\n args.loadPage = loadPage\n args.loadPageSync = loadPageSync\n\n const result = plugin.plugin[api](args, plugin.options)\n if (result && argTransform) {\n args = argTransform({ args, result, plugin })\n }\n return result\n })\n\n // Filter out undefined results.\n results = results.filter(result => typeof result !== `undefined`)\n\n if (results.length > 0) {\n return results\n } else if (defaultReturn) {\n return [defaultReturn]\n } else {\n return []\n }\n}\n\nexports.apiRunnerAsync = (api, args, defaultReturn) =>\n plugins.reduce(\n (previous, next) =>\n next.plugin[api]\n ? previous.then(() => next.plugin[api](args, next.options))\n : previous,\n Promise.resolve()\n )\n","import mitt from \"mitt\"\n\nconst emitter = mitt()\nexport default emitter\n","// \n// An event handler can take an optional event argument\n// and should not return a value\n \n \n\n// An array of all currently registered event handlers for a type\n \n \n// A map of event types and their corresponding event handlers.\n \n \n \n \n\n/** Mitt: Tiny (~200b) functional event emitter / pubsub.\n * @name mitt\n * @returns {Mitt}\n */\nfunction mitt(all ) {\n\tall = all || Object.create(null);\n\n\treturn {\n\t\t/**\n\t\t * Register an event handler for the given type.\n\t\t *\n\t\t * @param {String} type\tType of event to listen for, or `\"*\"` for all events\n\t\t * @param {Function} handler Function to call in response to given event\n\t\t * @memberOf mitt\n\t\t */\n\t\ton: function on(type , handler ) {\n\t\t\t(all[type] || (all[type] = [])).push(handler);\n\t\t},\n\n\t\t/**\n\t\t * Remove an event handler for the given type.\n\t\t *\n\t\t * @param {String} type\tType of event to unregister `handler` from, or `\"*\"`\n\t\t * @param {Function} handler Handler function to remove\n\t\t * @memberOf mitt\n\t\t */\n\t\toff: function off(type , handler ) {\n\t\t\tif (all[type]) {\n\t\t\t\tall[type].splice(all[type].indexOf(handler) >>> 0, 1);\n\t\t\t}\n\t\t},\n\n\t\t/**\n\t\t * Invoke all handlers for the given type.\n\t\t * If present, `\"*\"` handlers are invoked after type-matched handlers.\n\t\t *\n\t\t * @param {String} type The event type to invoke\n\t\t * @param {Any} [evt] Any value (object is recommended and powerful), passed to each handler\n\t\t * @memberOf mitt\n\t\t */\n\t\temit: function emit(type , evt ) {\n\t\t\t(all[type] || []).slice().map(function (handler) { handler(evt); });\n\t\t\t(all['*'] || []).slice().map(function (handler) { handler(type, evt); });\n\t\t}\n\t};\n}\n\nexport default mitt;\n//# sourceMappingURL=mitt.es.js.map\n","export default path => {\n if (path === undefined) {\n return path\n }\n if (path === `/`) {\n return `/`\n }\n if (path.charAt(path.length - 1) === `/`) {\n return path.slice(0, -1)\n }\n return path\n}\n","import { pick } from \"@gatsbyjs/reach-router/lib/utils\"\nimport stripPrefix from \"./strip-prefix\"\nimport normalizePagePath from \"./normalize-page-path\"\nimport { maybeGetBrowserRedirect } from \"./redirect-utils.js\"\n\nconst pathCache = new Map()\nlet matchPaths = []\n\nconst trimPathname = rawPathname => {\n const pathname = decodeURIComponent(rawPathname)\n // Remove the pathPrefix from the pathname.\n const trimmedPathname = stripPrefix(\n pathname,\n decodeURIComponent(__BASE_PATH__)\n )\n // Remove any hashfragment\n .split(`#`)[0]\n // Remove search query\n .split(`?`)[0]\n\n return trimmedPathname\n}\n\nfunction absolutify(path) {\n // If it's already absolute, return as-is\n if (\n path.startsWith(`/`) ||\n path.startsWith(`https://`) ||\n path.startsWith(`http://`)\n ) {\n return path\n }\n // Calculate path relative to current location, adding a trailing slash to\n // match behavior of @reach/router\n return new URL(\n path,\n window.location.href + (window.location.href.endsWith(`/`) ? `` : `/`)\n ).pathname\n}\n\n/**\n * Set list of matchPaths\n *\n * @param {Array<{path: string, matchPath: string}>} value collection of matchPaths\n */\nexport const setMatchPaths = value => {\n matchPaths = value\n}\n\n/**\n * Return a matchpath url\n * if `match-paths.json` contains `{ \"/foo*\": \"/page1\", ...}`, then\n * `/foo?bar=far` => `/page1`\n *\n * @param {string} rawPathname A raw pathname\n * @return {string|null}\n */\nexport const findMatchPath = rawPathname => {\n const trimmedPathname = cleanPath(rawPathname)\n\n const pickPaths = matchPaths.map(({ path, matchPath }) => {\n return {\n path: matchPath,\n originalPath: path,\n }\n })\n\n const path = pick(pickPaths, trimmedPathname)\n\n if (path) {\n return normalizePagePath(path.route.originalPath)\n }\n\n return null\n}\n\n/**\n * Return a matchpath params from reach/router rules\n * if `match-paths.json` contains `{ \":bar/*foo\" }`, and the path is /baz/zaz/zoo\n * then it returns\n * { bar: baz, foo: zaz/zoo }\n *\n * @param {string} rawPathname A raw pathname\n * @return {object}\n */\nexport const grabMatchParams = rawPathname => {\n const trimmedPathname = cleanPath(rawPathname)\n\n const pickPaths = matchPaths.map(({ path, matchPath }) => {\n return {\n path: matchPath,\n originalPath: path,\n }\n })\n\n const path = pick(pickPaths, trimmedPathname)\n\n if (path) {\n return path.params\n }\n\n return {}\n}\n\n// Given a raw URL path, returns the cleaned version of it (trim off\n// `#` and query params), or if it matches an entry in\n// `match-paths.json`, its matched path is returned\n//\n// E.g. `/foo?bar=far` => `/foo`\n//\n// Or if `match-paths.json` contains `{ \"/foo*\": \"/page1\", ...}`, then\n// `/foo?bar=far` => `/page1`\nexport const findPath = rawPathname => {\n const trimmedPathname = trimPathname(absolutify(rawPathname))\n if (pathCache.has(trimmedPathname)) {\n return pathCache.get(trimmedPathname)\n }\n\n const redirect = maybeGetBrowserRedirect(rawPathname)\n if (redirect) {\n return findPath(redirect.toPath)\n }\n\n let foundPath = findMatchPath(trimmedPathname)\n\n if (!foundPath) {\n foundPath = cleanPath(rawPathname)\n }\n\n pathCache.set(trimmedPathname, foundPath)\n\n return foundPath\n}\n\n/**\n * Clean a url and converts /index.html => /\n * E.g. `/foo?bar=far` => `/foo`\n *\n * @param {string} rawPathname A raw pathname\n * @return {string}\n */\nexport const cleanPath = rawPathname => {\n const trimmedPathname = trimPathname(absolutify(rawPathname))\n\n let foundPath = trimmedPathname\n if (foundPath === `/index.html`) {\n foundPath = `/`\n }\n\n foundPath = normalizePagePath(foundPath)\n\n return foundPath\n}\n","import React from \"react\"\nimport PropTypes from \"prop-types\"\nimport Link, {\n withPrefix,\n withAssetPrefix,\n navigate,\n push,\n replace,\n navigateTo,\n parsePath,\n} from \"gatsby-link\"\nimport { useScrollRestoration } from \"gatsby-react-router-scroll\"\nimport PageRenderer from \"./public-page-renderer\"\nimport loader from \"./loader\"\n\nconst prefetchPathname = loader.enqueue\n\nconst StaticQueryContext = React.createContext({})\n\nfunction StaticQueryDataRenderer({ staticQueryData, data, query, render }) {\n const finalData = data\n ? data.data\n : staticQueryData[query] && staticQueryData[query].data\n\n return (\n \n {finalData && render(finalData)}\n {!finalData &&
    Loading (StaticQuery)
    }\n
    \n )\n}\n\nconst StaticQuery = props => {\n const { data, query, render, children } = props\n\n return (\n \n {staticQueryData => (\n \n )}\n \n )\n}\n\nconst useStaticQuery = query => {\n if (\n typeof React.useContext !== `function` &&\n process.env.NODE_ENV === `development`\n ) {\n throw new Error(\n `You're likely using a version of React that doesn't support Hooks\\n` +\n `Please update React and ReactDOM to 16.8.0 or later to use the useStaticQuery hook.`\n )\n }\n const context = React.useContext(StaticQueryContext)\n\n // query is a stringified number like `3303882` when wrapped with graphql, If a user forgets\n // to wrap the query in a grqphql, then casting it to a Number results in `NaN` allowing us to\n // catch the misuse of the API and give proper direction\n if (isNaN(Number(query))) {\n throw new Error(`useStaticQuery was called with a string but expects to be called using \\`graphql\\`. Try this:\n\nimport { useStaticQuery, graphql } from 'gatsby';\n\nuseStaticQuery(graphql\\`${query}\\`);\n`)\n }\n\n if (context[query]?.data) {\n return context[query].data\n } else {\n throw new Error(\n `The result of this StaticQuery could not be fetched.\\n\\n` +\n `This is likely a bug in Gatsby and if refreshing the page does not fix it, ` +\n `please open an issue in https://github.com/gatsbyjs/gatsby/issues`\n )\n }\n}\n\nStaticQuery.propTypes = {\n data: PropTypes.object,\n query: PropTypes.string.isRequired,\n render: PropTypes.func,\n children: PropTypes.func,\n}\n\nfunction graphql() {\n throw new Error(\n `It appears like Gatsby is misconfigured. Gatsby related \\`graphql\\` calls ` +\n `are supposed to only be evaluated at compile time, and then compiled away. ` +\n `Unfortunately, something went wrong and the query was left in the compiled code.\\n\\n` +\n `Unless your site has a complex or custom babel/Gatsby configuration this is likely a bug in Gatsby.`\n )\n}\n\nexport {\n Link,\n withAssetPrefix,\n withPrefix,\n graphql,\n parsePath,\n navigate,\n useScrollRestoration,\n StaticQueryContext,\n StaticQuery,\n PageRenderer,\n useStaticQuery,\n prefetchPathname,\n}\n","export default function _arrayLikeToArray(arr, len) {\n if (len == null || len > arr.length) len = arr.length;\n for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i];\n return arr2;\n}","import arrayWithoutHoles from \"./arrayWithoutHoles.js\";\nimport iterableToArray from \"./iterableToArray.js\";\nimport unsupportedIterableToArray from \"./unsupportedIterableToArray.js\";\nimport nonIterableSpread from \"./nonIterableSpread.js\";\nexport default function _toConsumableArray(arr) {\n return arrayWithoutHoles(arr) || iterableToArray(arr) || unsupportedIterableToArray(arr) || nonIterableSpread();\n}","import arrayLikeToArray from \"./arrayLikeToArray.js\";\nexport default function _arrayWithoutHoles(arr) {\n if (Array.isArray(arr)) return arrayLikeToArray(arr);\n}","export default function _iterableToArray(iter) {\n if (typeof Symbol !== \"undefined\" && iter[Symbol.iterator] != null || iter[\"@@iterator\"] != null) return Array.from(iter);\n}","import arrayLikeToArray from \"./arrayLikeToArray.js\";\nexport default function _unsupportedIterableToArray(o, minLen) {\n if (!o) return;\n if (typeof o === \"string\") return arrayLikeToArray(o, minLen);\n var n = Object.prototype.toString.call(o).slice(8, -1);\n if (n === \"Object\" && o.constructor) n = o.constructor.name;\n if (n === \"Map\" || n === \"Set\") return Array.from(o);\n if (n === \"Arguments\" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return arrayLikeToArray(o, minLen);\n}","export default function _nonIterableSpread() {\n throw new TypeError(\"Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n}","const support = function (feature) {\n if (typeof document === `undefined`) {\n return false\n }\n const fakeLink = document.createElement(`link`)\n try {\n if (fakeLink.relList && typeof fakeLink.relList.supports === `function`) {\n return fakeLink.relList.supports(feature)\n }\n } catch (err) {\n return false\n }\n return false\n}\n\nconst linkPrefetchStrategy = function (url, options) {\n return new Promise((resolve, reject) => {\n if (typeof document === `undefined`) {\n reject()\n return\n }\n\n const link = document.createElement(`link`)\n link.setAttribute(`rel`, `prefetch`)\n link.setAttribute(`href`, url)\n\n Object.keys(options).forEach(key => {\n link.setAttribute(key, options[key])\n })\n\n link.onload = resolve\n link.onerror = reject\n\n const parentElement =\n document.getElementsByTagName(`head`)[0] ||\n document.getElementsByName(`script`)[0].parentNode\n parentElement.appendChild(link)\n })\n}\n\nconst xhrPrefetchStrategy = function (url) {\n return new Promise((resolve, reject) => {\n const req = new XMLHttpRequest()\n req.open(`GET`, url, true)\n\n req.onload = () => {\n if (req.status === 200) {\n resolve()\n } else {\n reject()\n }\n }\n\n req.send(null)\n })\n}\n\nconst supportedPrefetchStrategy = support(`prefetch`)\n ? linkPrefetchStrategy\n : xhrPrefetchStrategy\n\nconst preFetched = {}\n\nconst prefetch = function (url, options) {\n return new Promise(resolve => {\n if (preFetched[url]) {\n resolve()\n return\n }\n\n supportedPrefetchStrategy(url, options)\n .then(() => {\n resolve()\n preFetched[url] = true\n })\n .catch(() => {}) // 404s are logged to the console anyway\n })\n}\n\nexport default prefetch\n","import prefetchHelper from \"./prefetch\"\nimport emitter from \"./emitter\"\nimport { setMatchPaths, findPath, findMatchPath } from \"./find-path\"\n\n/**\n * Available resource loading statuses\n */\nexport const PageResourceStatus = {\n /**\n * At least one of critical resources failed to load\n */\n Error: `error`,\n /**\n * Resources loaded successfully\n */\n Success: `success`,\n}\n\nconst preferDefault = m => (m && m.default) || m\n\nconst stripSurroundingSlashes = s => {\n s = s[0] === `/` ? s.slice(1) : s\n s = s.endsWith(`/`) ? s.slice(0, -1) : s\n return s\n}\n\nconst createPageDataUrl = path => {\n const fixedPath = path === `/` ? `index` : stripSurroundingSlashes(path)\n return `${__PATH_PREFIX__}/page-data/${fixedPath}/page-data.json`\n}\n\nfunction doFetch(url, method = `GET`) {\n return new Promise((resolve, reject) => {\n const req = new XMLHttpRequest()\n req.open(method, url, true)\n req.onreadystatechange = () => {\n if (req.readyState == 4) {\n resolve(req)\n }\n }\n req.send(null)\n })\n}\n\nconst doesConnectionSupportPrefetch = () => {\n if (\n `connection` in navigator &&\n typeof navigator.connection !== `undefined`\n ) {\n if ((navigator.connection.effectiveType || ``).includes(`2g`)) {\n return false\n }\n if (navigator.connection.saveData) {\n return false\n }\n }\n return true\n}\n\nconst toPageResources = (pageData, component = null) => {\n const page = {\n componentChunkName: pageData.componentChunkName,\n path: pageData.path,\n webpackCompilationHash: pageData.webpackCompilationHash,\n matchPath: pageData.matchPath,\n staticQueryHashes: pageData.staticQueryHashes,\n }\n\n return {\n component,\n json: pageData.result,\n page,\n }\n}\n\nexport class BaseLoader {\n constructor(loadComponent, matchPaths) {\n // Map of pagePath -> Page. Where Page is an object with: {\n // status: PageResourceStatus.Success || PageResourceStatus.Error,\n // payload: PageResources, // undefined if PageResourceStatus.Error\n // }\n // PageResources is {\n // component,\n // json: pageData.result,\n // page: {\n // componentChunkName,\n // path,\n // webpackCompilationHash,\n // staticQueryHashes\n // },\n // staticQueryResults\n // }\n this.pageDb = new Map()\n this.inFlightDb = new Map()\n this.staticQueryDb = {}\n this.pageDataDb = new Map()\n this.prefetchTriggered = new Set()\n this.prefetchCompleted = new Set()\n this.loadComponent = loadComponent\n setMatchPaths(matchPaths)\n }\n\n inFlightNetworkRequests = new Map()\n\n memoizedGet(url) {\n let inFlightPromise = this.inFlightNetworkRequests.get(url)\n\n if (!inFlightPromise) {\n inFlightPromise = doFetch(url, `GET`)\n this.inFlightNetworkRequests.set(url, inFlightPromise)\n }\n\n // Prefer duplication with then + catch over .finally to prevent problems in ie11 + firefox\n return inFlightPromise\n .then(response => {\n this.inFlightNetworkRequests.delete(url)\n return response\n })\n .catch(err => {\n this.inFlightNetworkRequests.delete(url)\n throw err\n })\n }\n\n setApiRunner(apiRunner) {\n this.apiRunner = apiRunner\n this.prefetchDisabled = apiRunner(`disableCorePrefetching`).some(a => a)\n }\n\n fetchPageDataJson(loadObj) {\n const { pagePath, retries = 0 } = loadObj\n const url = createPageDataUrl(pagePath)\n return this.memoizedGet(url).then(req => {\n const { status, responseText } = req\n\n // Handle 200\n if (status === 200) {\n try {\n const jsonPayload = JSON.parse(responseText)\n if (jsonPayload.path === undefined) {\n throw new Error(`not a valid pageData response`)\n }\n\n return Object.assign(loadObj, {\n status: PageResourceStatus.Success,\n payload: jsonPayload,\n })\n } catch (err) {\n // continue regardless of error\n }\n }\n\n // Handle 404\n if (status === 404 || status === 200) {\n // If the request was for a 404 page and it doesn't exist, we're done\n if (pagePath === `/404.html`) {\n return Object.assign(loadObj, {\n status: PageResourceStatus.Error,\n })\n }\n\n // Need some code here to cache the 404 request. In case\n // multiple loadPageDataJsons result in 404s\n return this.fetchPageDataJson(\n Object.assign(loadObj, { pagePath: `/404.html`, notFound: true })\n )\n }\n\n // handle 500 response (Unrecoverable)\n if (status === 500) {\n return Object.assign(loadObj, {\n status: PageResourceStatus.Error,\n })\n }\n\n // Handle everything else, including status === 0, and 503s. Should retry\n if (retries < 3) {\n return this.fetchPageDataJson(\n Object.assign(loadObj, { retries: retries + 1 })\n )\n }\n\n // Retried 3 times already, result is an error.\n return Object.assign(loadObj, {\n status: PageResourceStatus.Error,\n })\n })\n }\n\n loadPageDataJson(rawPath) {\n const pagePath = findPath(rawPath)\n if (this.pageDataDb.has(pagePath)) {\n const pageData = this.pageDataDb.get(pagePath)\n if (process.env.BUILD_STAGE !== `develop` || !pageData.stale) {\n return Promise.resolve(pageData)\n }\n }\n\n return this.fetchPageDataJson({ pagePath }).then(pageData => {\n this.pageDataDb.set(pagePath, pageData)\n\n return pageData\n })\n }\n\n findMatchPath(rawPath) {\n return findMatchPath(rawPath)\n }\n\n // TODO check all uses of this and whether they use undefined for page resources not exist\n loadPage(rawPath) {\n const pagePath = findPath(rawPath)\n if (this.pageDb.has(pagePath)) {\n const page = this.pageDb.get(pagePath)\n if (process.env.BUILD_STAGE !== `develop` || !page.payload.stale) {\n if (page.error) {\n return {\n error: page.error,\n status: page.status,\n }\n }\n\n return Promise.resolve(page.payload)\n }\n }\n\n if (this.inFlightDb.has(pagePath)) {\n return this.inFlightDb.get(pagePath)\n }\n\n const inFlightPromise = Promise.all([\n this.loadAppData(),\n this.loadPageDataJson(pagePath),\n ]).then(allData => {\n const result = allData[1]\n if (result.status === PageResourceStatus.Error) {\n return {\n status: PageResourceStatus.Error,\n }\n }\n\n let pageData = result.payload\n const { componentChunkName, staticQueryHashes = [] } = pageData\n\n const finalResult = {}\n\n const componentChunkPromise = this.loadComponent(componentChunkName).then(\n component => {\n finalResult.createdAt = new Date()\n let pageResources\n if (!component || component instanceof Error) {\n finalResult.status = PageResourceStatus.Error\n finalResult.error = component\n } else {\n finalResult.status = PageResourceStatus.Success\n if (result.notFound === true) {\n finalResult.notFound = true\n }\n pageData = Object.assign(pageData, {\n webpackCompilationHash: allData[0]\n ? allData[0].webpackCompilationHash\n : ``,\n })\n pageResources = toPageResources(pageData, component)\n }\n // undefined if final result is an error\n return pageResources\n }\n )\n\n const staticQueryBatchPromise = Promise.all(\n staticQueryHashes.map(staticQueryHash => {\n // Check for cache in case this static query result has already been loaded\n if (this.staticQueryDb[staticQueryHash]) {\n const jsonPayload = this.staticQueryDb[staticQueryHash]\n return { staticQueryHash, jsonPayload }\n }\n\n return this.memoizedGet(\n `${__PATH_PREFIX__}/page-data/sq/d/${staticQueryHash}.json`\n )\n .then(req => {\n const jsonPayload = JSON.parse(req.responseText)\n return { staticQueryHash, jsonPayload }\n })\n .catch(() => {\n throw new Error(\n `We couldn't load \"${__PATH_PREFIX__}/page-data/sq/d/${staticQueryHash}.json\"`\n )\n })\n })\n ).then(staticQueryResults => {\n const staticQueryResultsMap = {}\n\n staticQueryResults.forEach(({ staticQueryHash, jsonPayload }) => {\n staticQueryResultsMap[staticQueryHash] = jsonPayload\n this.staticQueryDb[staticQueryHash] = jsonPayload\n })\n\n return staticQueryResultsMap\n })\n\n return (\n Promise.all([componentChunkPromise, staticQueryBatchPromise])\n .then(([pageResources, staticQueryResults]) => {\n let payload\n if (pageResources) {\n payload = { ...pageResources, staticQueryResults }\n finalResult.payload = payload\n emitter.emit(`onPostLoadPageResources`, {\n page: payload,\n pageResources: payload,\n })\n }\n\n this.pageDb.set(pagePath, finalResult)\n\n if (finalResult.error) {\n return {\n error: finalResult.error,\n status: finalResult.status,\n }\n }\n\n return payload\n })\n // when static-query fail to load we throw a better error\n .catch(err => {\n return {\n error: err,\n status: PageResourceStatus.Error,\n }\n })\n )\n })\n\n inFlightPromise\n .then(() => {\n this.inFlightDb.delete(pagePath)\n })\n .catch(error => {\n this.inFlightDb.delete(pagePath)\n throw error\n })\n\n this.inFlightDb.set(pagePath, inFlightPromise)\n\n return inFlightPromise\n }\n\n // returns undefined if the page does not exists in cache\n loadPageSync(rawPath, options = {}) {\n const pagePath = findPath(rawPath)\n if (this.pageDb.has(pagePath)) {\n const pageData = this.pageDb.get(pagePath)\n\n if (pageData.payload) {\n return pageData.payload\n }\n\n if (options?.withErrorDetails) {\n return {\n error: pageData.error,\n status: pageData.status,\n }\n }\n }\n return undefined\n }\n\n shouldPrefetch(pagePath) {\n // Skip prefetching if we know user is on slow or constrained connection\n if (!doesConnectionSupportPrefetch()) {\n return false\n }\n\n // Check if the page exists.\n if (this.pageDb.has(pagePath)) {\n return false\n }\n\n return true\n }\n\n prefetch(pagePath) {\n if (!this.shouldPrefetch(pagePath)) {\n return false\n }\n\n // Tell plugins with custom prefetching logic that they should start\n // prefetching this path.\n if (!this.prefetchTriggered.has(pagePath)) {\n this.apiRunner(`onPrefetchPathname`, { pathname: pagePath })\n this.prefetchTriggered.add(pagePath)\n }\n\n // If a plugin has disabled core prefetching, stop now.\n if (this.prefetchDisabled) {\n return false\n }\n\n const realPath = findPath(pagePath)\n // Todo make doPrefetch logic cacheable\n // eslint-disable-next-line consistent-return\n this.doPrefetch(realPath).then(() => {\n if (!this.prefetchCompleted.has(pagePath)) {\n this.apiRunner(`onPostPrefetchPathname`, { pathname: pagePath })\n this.prefetchCompleted.add(pagePath)\n }\n })\n\n return true\n }\n\n doPrefetch(pagePath) {\n const pageDataUrl = createPageDataUrl(pagePath)\n return prefetchHelper(pageDataUrl, {\n crossOrigin: `anonymous`,\n as: `fetch`,\n }).then(() =>\n // This was just prefetched, so will return a response from\n // the cache instead of making another request to the server\n this.loadPageDataJson(pagePath)\n )\n }\n\n hovering(rawPath) {\n this.loadPage(rawPath)\n }\n\n getResourceURLsForPathname(rawPath) {\n const pagePath = findPath(rawPath)\n const page = this.pageDataDb.get(pagePath)\n if (page) {\n const pageResources = toPageResources(page.payload)\n\n return [\n ...createComponentUrls(pageResources.page.componentChunkName),\n createPageDataUrl(pagePath),\n ]\n } else {\n return null\n }\n }\n\n isPageNotFound(rawPath) {\n const pagePath = findPath(rawPath)\n const page = this.pageDb.get(pagePath)\n return !page || page.notFound\n }\n\n loadAppData(retries = 0) {\n return this.memoizedGet(`${__PATH_PREFIX__}/page-data/app-data.json`).then(\n req => {\n const { status, responseText } = req\n\n let appData\n\n if (status !== 200 && retries < 3) {\n // Retry 3 times incase of non-200 responses\n return this.loadAppData(retries + 1)\n }\n\n // Handle 200\n if (status === 200) {\n try {\n const jsonPayload = JSON.parse(responseText)\n if (jsonPayload.webpackCompilationHash === undefined) {\n throw new Error(`not a valid app-data response`)\n }\n\n appData = jsonPayload\n } catch (err) {\n // continue regardless of error\n }\n }\n\n return appData\n }\n )\n }\n}\n\nconst createComponentUrls = componentChunkName =>\n (window.___chunkMapping[componentChunkName] || []).map(\n chunk => __PATH_PREFIX__ + chunk\n )\n\nexport class ProdLoader extends BaseLoader {\n constructor(asyncRequires, matchPaths, pageData) {\n const loadComponent = chunkName => {\n if (!asyncRequires.components[chunkName]) {\n throw new Error(\n `We couldn't find the correct component chunk with the name ${chunkName}`\n )\n }\n\n return (\n asyncRequires.components[chunkName]()\n .then(preferDefault)\n // loader will handle the case when component is error\n .catch(err => err)\n )\n }\n\n super(loadComponent, matchPaths)\n\n if (pageData) {\n this.pageDataDb.set(pageData.path, {\n pagePath: pageData.path,\n payload: pageData,\n status: `success`,\n })\n }\n }\n\n doPrefetch(pagePath) {\n return super.doPrefetch(pagePath).then(result => {\n if (result.status !== PageResourceStatus.Success) {\n return Promise.resolve()\n }\n const pageData = result.payload\n const chunkName = pageData.componentChunkName\n const componentUrls = createComponentUrls(chunkName)\n return Promise.all(componentUrls.map(prefetchHelper)).then(() => pageData)\n })\n }\n\n loadPageDataJson(rawPath) {\n return super.loadPageDataJson(rawPath).then(data => {\n if (data.notFound) {\n // check if html file exist using HEAD request:\n // if it does we should navigate to it instead of showing 404\n return doFetch(rawPath, `HEAD`).then(req => {\n if (req.status === 200) {\n // page (.html file) actually exist (or we asked for 404 )\n // returning page resources status as errored to trigger\n // regular browser navigation to given page\n return {\n status: PageResourceStatus.Error,\n }\n }\n\n // if HEAD request wasn't 200, return notFound result\n // and show 404 page\n return data\n })\n }\n return data\n })\n }\n}\n\nlet instance\n\nexport const setLoader = _loader => {\n instance = _loader\n}\n\nexport const publicLoader = {\n enqueue: rawPath => instance.prefetch(rawPath),\n\n // Real methods\n getResourceURLsForPathname: rawPath =>\n instance.getResourceURLsForPathname(rawPath),\n loadPage: rawPath => instance.loadPage(rawPath),\n // TODO add deprecation to v4 so people use withErrorDetails and then we can remove in v5 and change default behaviour\n loadPageSync: (rawPath, options = {}) =>\n instance.loadPageSync(rawPath, options),\n prefetch: rawPath => instance.prefetch(rawPath),\n isPageNotFound: rawPath => instance.isPageNotFound(rawPath),\n hovering: rawPath => instance.hovering(rawPath),\n loadAppData: () => instance.loadAppData(),\n}\n\nexport default publicLoader\n\nexport function getStaticQueryResults() {\n if (instance) {\n return instance.staticQueryDb\n } else {\n return {}\n }\n}\n","import React, { createElement } from \"react\"\nimport PropTypes from \"prop-types\"\nimport { apiRunner } from \"./api-runner-browser\"\nimport { grabMatchParams } from \"./find-path\"\n\n// Renders page\nclass PageRenderer extends React.Component {\n render() {\n const props = {\n ...this.props,\n params: {\n ...grabMatchParams(this.props.location.pathname),\n ...this.props.pageResources.json.pageContext.__params,\n },\n }\n\n const pageElement = createElement(this.props.pageResources.component, {\n ...props,\n key: this.props.path || this.props.pageResources.page.path,\n })\n\n const wrappedPage = apiRunner(\n `wrapPageElement`,\n { element: pageElement, props },\n pageElement,\n ({ result }) => {\n return { element: result, props }\n }\n ).pop()\n\n return wrappedPage\n }\n}\n\nPageRenderer.propTypes = {\n location: PropTypes.object.isRequired,\n pageResources: PropTypes.object.isRequired,\n data: PropTypes.object,\n pageContext: PropTypes.object.isRequired,\n}\n\nexport default PageRenderer\n","// This is extracted to separate module because it's shared\n// between browser and SSR code\nexport const RouteAnnouncerProps = {\n id: `gatsby-announcer`,\n style: {\n position: `absolute`,\n top: 0,\n width: 1,\n height: 1,\n padding: 0,\n overflow: `hidden`,\n clip: `rect(0, 0, 0, 0)`,\n whiteSpace: `nowrap`,\n border: 0,\n },\n \"aria-live\": `assertive`,\n \"aria-atomic\": `true`,\n}\n","import React from \"react\"\nimport PropTypes from \"prop-types\"\nimport loader, { PageResourceStatus } from \"./loader\"\nimport { maybeGetBrowserRedirect } from \"./redirect-utils.js\"\nimport { apiRunner } from \"./api-runner-browser\"\nimport emitter from \"./emitter\"\nimport { RouteAnnouncerProps } from \"./route-announcer-props\"\nimport { navigate as reachNavigate } from \"@gatsbyjs/reach-router\"\nimport { globalHistory } from \"@gatsbyjs/reach-router/lib/history\"\nimport { parsePath } from \"gatsby-link\"\n\nfunction maybeRedirect(pathname) {\n const redirect = maybeGetBrowserRedirect(pathname)\n const { hash, search } = window.location\n\n if (redirect != null) {\n window.___replace(redirect.toPath + search + hash)\n return true\n } else {\n return false\n }\n}\n\n// Catch unhandled chunk loading errors and force a restart of the app.\nlet nextRoute = ``\n\nwindow.addEventListener(`unhandledrejection`, event => {\n if (/loading chunk \\d* failed./i.test(event.reason)) {\n if (nextRoute) {\n window.location.pathname = nextRoute\n }\n }\n})\n\nconst onPreRouteUpdate = (location, prevLocation) => {\n if (!maybeRedirect(location.pathname)) {\n nextRoute = location.pathname\n apiRunner(`onPreRouteUpdate`, { location, prevLocation })\n }\n}\n\nconst onRouteUpdate = (location, prevLocation) => {\n if (!maybeRedirect(location.pathname)) {\n apiRunner(`onRouteUpdate`, { location, prevLocation })\n if (\n process.env.GATSBY_EXPERIMENTAL_QUERY_ON_DEMAND &&\n process.env.GATSBY_QUERY_ON_DEMAND_LOADING_INDICATOR === `true`\n ) {\n emitter.emit(`onRouteUpdate`, { location, prevLocation })\n }\n }\n}\n\nconst navigate = (to, options = {}) => {\n // Support forward/backward navigation with numbers\n // navigate(-2) (jumps back 2 history steps)\n // navigate(2) (jumps forward 2 history steps)\n if (typeof to === `number`) {\n globalHistory.navigate(to)\n return\n }\n\n const { pathname, search, hash } = parsePath(to)\n const redirect = maybeGetBrowserRedirect(pathname)\n\n // If we're redirecting, just replace the passed in pathname\n // to the one we want to redirect to.\n if (redirect) {\n to = redirect.toPath + search + hash\n }\n\n // If we had a service worker update, no matter the path, reload window and\n // reset the pathname whitelist\n if (window.___swUpdated) {\n window.location = pathname + search + hash\n return\n }\n\n // Start a timer to wait for a second before transitioning and showing a\n // loader in case resources aren't around yet.\n const timeoutId = setTimeout(() => {\n emitter.emit(`onDelayedLoadPageResources`, { pathname })\n apiRunner(`onRouteUpdateDelayed`, {\n location: window.location,\n })\n }, 1000)\n\n loader.loadPage(pathname).then(pageResources => {\n // If no page resources, then refresh the page\n // Do this, rather than simply `window.location.reload()`, so that\n // pressing the back/forward buttons work - otherwise when pressing\n // back, the browser will just change the URL and expect JS to handle\n // the change, which won't always work since it might not be a Gatsby\n // page.\n if (!pageResources || pageResources.status === PageResourceStatus.Error) {\n window.history.replaceState({}, ``, location.href)\n window.location = pathname\n clearTimeout(timeoutId)\n return\n }\n\n // If the loaded page has a different compilation hash to the\n // window, then a rebuild has occurred on the server. Reload.\n if (process.env.NODE_ENV === `production` && pageResources) {\n // window.___webpackCompilationHash gets set in production-app.js after navigationInit() is called\n // So on a direct visit of a page with a browser redirect this check is truthy and thus the codepath is hit\n // While the resource actually exists, but only too late\n // TODO: This should probably be fixed by setting ___webpackCompilationHash before navigationInit() is called\n if (\n pageResources.page.webpackCompilationHash !==\n window.___webpackCompilationHash\n ) {\n // Purge plugin-offline cache\n if (\n `serviceWorker` in navigator &&\n navigator.serviceWorker.controller !== null &&\n navigator.serviceWorker.controller.state === `activated`\n ) {\n navigator.serviceWorker.controller.postMessage({\n gatsbyApi: `clearPathResources`,\n })\n }\n\n window.location = pathname + search + hash\n }\n }\n reachNavigate(to, options)\n clearTimeout(timeoutId)\n })\n}\n\nfunction shouldUpdateScroll(prevRouterProps, { location }) {\n const { pathname, hash } = location\n const results = apiRunner(`shouldUpdateScroll`, {\n prevRouterProps,\n // `pathname` for backwards compatibility\n pathname,\n routerProps: { location },\n getSavedScrollPosition: args => [\n 0,\n // FIXME this is actually a big code smell, we should fix this\n // eslint-disable-next-line @babel/no-invalid-this\n this._stateStorage.read(args, args.key),\n ],\n })\n if (results.length > 0) {\n // Use the latest registered shouldUpdateScroll result, this allows users to override plugin's configuration\n // @see https://github.com/gatsbyjs/gatsby/issues/12038\n return results[results.length - 1]\n }\n\n if (prevRouterProps) {\n const {\n location: { pathname: oldPathname },\n } = prevRouterProps\n if (oldPathname === pathname) {\n // Scroll to element if it exists, if it doesn't, or no hash is provided,\n // scroll to top.\n return hash ? decodeURI(hash.slice(1)) : [0, 0]\n }\n }\n return true\n}\n\nfunction init() {\n // The \"scroll-behavior\" package expects the \"action\" to be on the location\n // object so let's copy it over.\n globalHistory.listen(args => {\n args.location.action = args.action\n })\n\n window.___push = to => navigate(to, { replace: false })\n window.___replace = to => navigate(to, { replace: true })\n window.___navigate = (to, options) => navigate(to, options)\n\n // Check for initial page-load redirect\n maybeRedirect(window.location.pathname)\n}\n\nclass RouteAnnouncer extends React.Component {\n constructor(props) {\n super(props)\n this.announcementRef = React.createRef()\n }\n\n componentDidUpdate(prevProps, nextProps) {\n requestAnimationFrame(() => {\n let pageName = `new page at ${this.props.location.pathname}`\n if (document.title) {\n pageName = document.title\n }\n const pageHeadings = document.querySelectorAll(`#gatsby-focus-wrapper h1`)\n if (pageHeadings && pageHeadings.length) {\n pageName = pageHeadings[0].textContent\n }\n const newAnnouncement = `Navigated to ${pageName}`\n if (this.announcementRef.current) {\n const oldAnnouncement = this.announcementRef.current.innerText\n if (oldAnnouncement !== newAnnouncement) {\n this.announcementRef.current.innerText = newAnnouncement\n }\n }\n })\n }\n\n render() {\n return
    \n }\n}\n\nconst compareLocationProps = (prevLocation, nextLocation) => {\n if (prevLocation.href !== nextLocation.href) {\n return true\n }\n\n if (prevLocation?.state?.key !== nextLocation?.state?.key) {\n return true\n }\n\n return false\n}\n\n// Fire on(Pre)RouteUpdate APIs\nclass RouteUpdates extends React.Component {\n constructor(props) {\n super(props)\n onPreRouteUpdate(props.location, null)\n }\n\n componentDidMount() {\n onRouteUpdate(this.props.location, null)\n }\n\n shouldComponentUpdate(prevProps) {\n if (compareLocationProps(prevProps.location, this.props.location)) {\n onPreRouteUpdate(this.props.location, prevProps.location)\n return true\n }\n return false\n }\n\n componentDidUpdate(prevProps) {\n if (compareLocationProps(prevProps.location, this.props.location)) {\n onRouteUpdate(this.props.location, prevProps.location)\n }\n }\n\n render() {\n return (\n \n {this.props.children}\n \n \n )\n }\n}\n\nRouteUpdates.propTypes = {\n location: PropTypes.object.isRequired,\n}\n\nexport { init, shouldUpdateScroll, RouteUpdates, maybeGetBrowserRedirect }\n","// Pulled from react-compat\n// https://github.com/developit/preact-compat/blob/7c5de00e7c85e2ffd011bf3af02899b63f699d3a/src/index.js#L349\nfunction shallowDiffers(a, b) {\n for (var i in a) {\n if (!(i in b)) return true;\n }for (var _i in b) {\n if (a[_i] !== b[_i]) return true;\n }return false;\n}\n\nexport default (function (instance, nextProps, nextState) {\n return shallowDiffers(instance.props, nextProps) || shallowDiffers(instance.state, nextState);\n});","import React from \"react\"\nimport loader, { PageResourceStatus } from \"./loader\"\nimport shallowCompare from \"shallow-compare\"\n\nclass EnsureResources extends React.Component {\n constructor(props) {\n super()\n const { location, pageResources } = props\n this.state = {\n location: { ...location },\n pageResources:\n pageResources ||\n loader.loadPageSync(location.pathname, { withErrorDetails: true }),\n }\n }\n\n static getDerivedStateFromProps({ location }, prevState) {\n if (prevState.location.href !== location.href) {\n const pageResources = loader.loadPageSync(location.pathname, {\n withErrorDetails: true,\n })\n\n return {\n pageResources,\n location: { ...location },\n }\n }\n\n return {\n location: { ...location },\n }\n }\n\n loadResources(rawPath) {\n loader.loadPage(rawPath).then(pageResources => {\n if (pageResources && pageResources.status !== PageResourceStatus.Error) {\n this.setState({\n location: { ...window.location },\n pageResources,\n })\n } else {\n window.history.replaceState({}, ``, location.href)\n window.location = rawPath\n }\n })\n }\n\n shouldComponentUpdate(nextProps, nextState) {\n // Always return false if we're missing resources.\n if (!nextState.pageResources) {\n this.loadResources(nextProps.location.pathname)\n return false\n }\n\n if (\n process.env.BUILD_STAGE === `develop` &&\n nextState.pageResources.stale\n ) {\n this.loadResources(nextProps.location.pathname)\n return false\n }\n\n // Check if the component or json have changed.\n if (this.state.pageResources !== nextState.pageResources) {\n return true\n }\n if (\n this.state.pageResources.component !== nextState.pageResources.component\n ) {\n return true\n }\n\n if (this.state.pageResources.json !== nextState.pageResources.json) {\n return true\n }\n // Check if location has changed on a page using internal routing\n // via matchPath configuration.\n if (\n this.state.location.key !== nextState.location.key &&\n nextState.pageResources.page &&\n (nextState.pageResources.page.matchPath ||\n nextState.pageResources.page.path)\n ) {\n return true\n }\n return shallowCompare(this, nextProps, nextState)\n }\n\n render() {\n if (\n process.env.NODE_ENV !== `production` &&\n (!this.state.pageResources ||\n this.state.pageResources.status === PageResourceStatus.Error)\n ) {\n const message = `EnsureResources was not able to find resources for path: \"${this.props.location.pathname}\"\nThis typically means that an issue occurred building components for that path.\nRun \\`gatsby clean\\` to remove any cached elements.`\n if (this.state.pageResources?.error) {\n console.error(message)\n throw this.state.pageResources.error\n }\n\n throw new Error(message)\n }\n\n return this.props.children(this.state)\n }\n}\n\nexport default EnsureResources\n","import { apiRunner, apiRunnerAsync } from \"./api-runner-browser\"\nimport React from \"react\"\nimport ReactDOM from \"react-dom\"\nimport { Router, navigate, Location, BaseContext } from \"@gatsbyjs/reach-router\"\nimport { ScrollContext } from \"gatsby-react-router-scroll\"\nimport { StaticQueryContext } from \"gatsby\"\nimport {\n shouldUpdateScroll,\n init as navigationInit,\n RouteUpdates,\n} from \"./navigation\"\nimport emitter from \"./emitter\"\nimport PageRenderer from \"./page-renderer\"\nimport asyncRequires from \"$virtual/async-requires\"\nimport {\n setLoader,\n ProdLoader,\n publicLoader,\n PageResourceStatus,\n getStaticQueryResults,\n} from \"./loader\"\nimport EnsureResources from \"./ensure-resources\"\nimport stripPrefix from \"./strip-prefix\"\n\n// Generated during bootstrap\nimport matchPaths from \"$virtual/match-paths.json\"\n\nconst loader = new ProdLoader(asyncRequires, matchPaths, window.pageData)\nsetLoader(loader)\nloader.setApiRunner(apiRunner)\n\nwindow.asyncRequires = asyncRequires\nwindow.___emitter = emitter\nwindow.___loader = publicLoader\n\nnavigationInit()\n\napiRunnerAsync(`onClientEntry`).then(() => {\n // Let plugins register a service worker. The plugin just needs\n // to return true.\n if (apiRunner(`registerServiceWorker`).filter(Boolean).length > 0) {\n require(`./register-service-worker`)\n }\n\n // In gatsby v2 if Router is used in page using matchPaths\n // paths need to contain full path.\n // For example:\n // - page have `/app/*` matchPath\n // - inside template user needs to use `/app/xyz` as path\n // Resetting `basepath`/`baseuri` keeps current behaviour\n // to not introduce breaking change.\n // Remove this in v3\n const RouteHandler = props => (\n \n \n \n )\n\n const DataContext = React.createContext({})\n\n class GatsbyRoot extends React.Component {\n render() {\n const { children } = this.props\n return (\n \n {({ location }) => (\n \n {({ pageResources, location }) => {\n const staticQueryResults = getStaticQueryResults()\n return (\n \n \n {children}\n \n \n )\n }}\n \n )}\n \n )\n }\n }\n\n class LocationHandler extends React.Component {\n render() {\n return (\n \n {({ pageResources, location }) => (\n \n \n \n \n \n \n \n )}\n \n )\n }\n }\n\n const { pagePath, location: browserLoc } = window\n\n // Explicitly call navigate if the canonical path (window.pagePath)\n // is different to the browser path (window.location.pathname). But\n // only if NONE of the following conditions hold:\n //\n // - The url matches a client side route (page.matchPath)\n // - it's a 404 page\n // - it's the offline plugin shell (/offline-plugin-app-shell-fallback/)\n if (\n pagePath &&\n __BASE_PATH__ + pagePath !== browserLoc.pathname &&\n !(\n loader.findMatchPath(stripPrefix(browserLoc.pathname, __BASE_PATH__)) ||\n pagePath === `/404.html` ||\n pagePath.match(/^\\/404\\/?$/) ||\n pagePath.match(/^\\/offline-plugin-app-shell-fallback\\/?$/)\n )\n ) {\n navigate(__BASE_PATH__ + pagePath + browserLoc.search + browserLoc.hash, {\n replace: true,\n })\n }\n\n publicLoader.loadPage(browserLoc.pathname).then(page => {\n if (!page || page.status === PageResourceStatus.Error) {\n const message = `page resources for ${browserLoc.pathname} not found. Not rendering React`\n\n // if the chunk throws an error we want to capture the real error\n // This should help with https://github.com/gatsbyjs/gatsby/issues/19618\n if (page && page.error) {\n console.error(message)\n throw page.error\n }\n\n throw new Error(message)\n }\n\n window.___webpackCompilationHash = page.page.webpackCompilationHash\n\n const SiteRoot = apiRunner(\n `wrapRootElement`,\n { element: },\n ,\n ({ result }) => {\n return { element: result }\n }\n ).pop()\n\n const App = function App() {\n const onClientEntryRanRef = React.useRef(false)\n\n React.useEffect(() => {\n if (!onClientEntryRanRef.current) {\n onClientEntryRanRef.current = true\n if (performance.mark) {\n performance.mark(`onInitialClientRender`)\n }\n\n apiRunner(`onInitialClientRender`)\n }\n }, [])\n\n return {SiteRoot}\n }\n\n const renderer = apiRunner(\n `replaceHydrateFunction`,\n undefined,\n ReactDOM.hydrateRoot ? ReactDOM.hydrateRoot : ReactDOM.hydrate\n )[0]\n\n function runRender() {\n const rootElement =\n typeof window !== `undefined`\n ? document.getElementById(`___gatsby`)\n : null\n\n if (renderer === ReactDOM.hydrateRoot) {\n renderer(rootElement, )\n } else {\n renderer(, rootElement)\n }\n }\n\n // https://github.com/madrobby/zepto/blob/b5ed8d607f67724788ec9ff492be297f64d47dfc/src/zepto.js#L439-L450\n // TODO remove IE 10 support\n const doc = document\n if (\n doc.readyState === `complete` ||\n (doc.readyState !== `loading` && !doc.documentElement.doScroll)\n ) {\n setTimeout(function () {\n runRender()\n }, 0)\n } else {\n const handler = function () {\n doc.removeEventListener(`DOMContentLoaded`, handler, false)\n window.removeEventListener(`load`, handler, false)\n\n runRender()\n }\n\n doc.addEventListener(`DOMContentLoaded`, handler, false)\n window.addEventListener(`load`, handler, false)\n }\n })\n})\n","import React from \"react\"\nimport PropTypes from \"prop-types\"\n\nimport loader from \"./loader\"\nimport InternalPageRenderer from \"./page-renderer\"\n\nconst ProdPageRenderer = ({ location }) => {\n const pageResources = loader.loadPageSync(location.pathname)\n if (!pageResources) {\n return null\n }\n return React.createElement(InternalPageRenderer, {\n location,\n pageResources,\n ...pageResources.json,\n })\n}\n\nProdPageRenderer.propTypes = {\n location: PropTypes.shape({\n pathname: PropTypes.string.isRequired,\n }).isRequired,\n}\n\nexport default ProdPageRenderer\n","const preferDefault = m => (m && m.default) || m\n\nif (process.env.BUILD_STAGE === `develop`) {\n module.exports = preferDefault(require(`./public-page-renderer-dev`))\n} else if (process.env.BUILD_STAGE === `build-javascript`) {\n module.exports = preferDefault(require(`./public-page-renderer-prod`))\n} else {\n module.exports = () => null\n}\n","exports.polyfill = Component => Component\n","import redirects from \"./redirects.json\"\n\n// Convert to a map for faster lookup in maybeRedirect()\n\nconst redirectMap = new Map()\nconst redirectIgnoreCaseMap = new Map()\n\nredirects.forEach(redirect => {\n if (redirect.ignoreCase) {\n redirectIgnoreCaseMap.set(redirect.fromPath, redirect)\n } else {\n redirectMap.set(redirect.fromPath, redirect)\n }\n})\n\nexport function maybeGetBrowserRedirect(pathname) {\n let redirect = redirectMap.get(pathname)\n if (!redirect) {\n redirect = redirectIgnoreCaseMap.get(pathname.toLowerCase())\n }\n return redirect\n}\n","import { apiRunner } from \"./api-runner-browser\"\n\nif (\n window.location.protocol !== `https:` &&\n window.location.hostname !== `localhost`\n) {\n console.error(\n `Service workers can only be used over HTTPS, or on localhost for development`\n )\n} else if (`serviceWorker` in navigator) {\n navigator.serviceWorker\n .register(`${__BASE_PATH__}/sw.js`)\n .then(function (reg) {\n reg.addEventListener(`updatefound`, () => {\n apiRunner(`onServiceWorkerUpdateFound`, { serviceWorker: reg })\n // The updatefound event implies that reg.installing is set; see\n // https://w3c.github.io/ServiceWorker/#service-worker-registration-updatefound-event\n const installingWorker = reg.installing\n console.log(`installingWorker`, installingWorker)\n installingWorker.addEventListener(`statechange`, () => {\n switch (installingWorker.state) {\n case `installed`:\n if (navigator.serviceWorker.controller) {\n // At this point, the old content will have been purged and the fresh content will\n // have been added to the cache.\n\n // We set a flag so Gatsby Link knows to refresh the page on next navigation attempt\n window.___swUpdated = true\n // We call the onServiceWorkerUpdateReady API so users can show update prompts.\n apiRunner(`onServiceWorkerUpdateReady`, { serviceWorker: reg })\n\n // If resources failed for the current page, reload.\n if (window.___failedResources) {\n console.log(`resources failed, SW updated - reloading`)\n window.location.reload()\n }\n } else {\n // At this point, everything has been precached.\n // It's the perfect time to display a \"Content is cached for offline use.\" message.\n console.log(`Content is now available offline!`)\n\n // Post to service worker that install is complete.\n // Delay to allow time for the event listener to be added --\n // otherwise fetch is called too soon and resources aren't cached.\n apiRunner(`onServiceWorkerInstalled`, { serviceWorker: reg })\n }\n break\n\n case `redundant`:\n console.error(`The installing service worker became redundant.`)\n apiRunner(`onServiceWorkerRedundant`, { serviceWorker: reg })\n break\n\n case `activated`:\n apiRunner(`onServiceWorkerActive`, { serviceWorker: reg })\n break\n }\n })\n })\n })\n .catch(function (e) {\n console.error(`Error during service worker registration:`, e)\n })\n}\n","/**\n * Remove a prefix from a string. Return the input string if the given prefix\n * isn't found.\n */\n\nexport default function stripPrefix(str, prefix = ``) {\n if (!prefix) {\n return str\n }\n\n if (str === prefix) {\n return `/`\n }\n\n if (str.startsWith(`${prefix}/`)) {\n return str.slice(prefix.length)\n }\n\n return str\n}\n","// https://www.gatsbyjs.com/docs/reference/config-files/gatsby-browser/\nconst React = require('react');\nconst { StrictMode } = require('react');\n\n// Adds React's Strict mode for debugging in non-PROD builds:\n// www.gatsbyjs.com/docs/reference/config-files/gatsby-browser/#wrapRootElement\n// This is also present in gatsby-ssr.js if SSR is being used\nexports.wrapRootElement = ({ element }) => {\n return {element};\n};\n","/* eslint-disable no-unused-expressions */\nimport { stripIndent } from \"common-tags\"\nimport camelCase from \"camelcase\"\nimport { IGatsbyImageData } from \".\"\n\nconst DEFAULT_PIXEL_DENSITIES = [0.25, 0.5, 1, 2]\nexport const DEFAULT_BREAKPOINTS = [750, 1080, 1366, 1920]\nexport const EVERY_BREAKPOINT = [\n 320, 654, 768, 1024, 1366, 1600, 1920, 2048, 2560, 3440, 3840, 4096,\n]\nconst DEFAULT_FLUID_WIDTH = 800\nconst DEFAULT_FIXED_WIDTH = 800\nconst DEFAULT_ASPECT_RATIO = 4 / 3\n\nexport type Fit = \"cover\" | \"fill\" | \"inside\" | \"outside\" | \"contain\"\n\nexport type Layout = \"fixed\" | \"fullWidth\" | \"constrained\"\nexport type ImageFormat = \"jpg\" | \"png\" | \"webp\" | \"avif\" | \"auto\" | \"\"\n\n/**\n * The minimal required reporter, as we don't want to import it from gatsby-cli\n */\nexport interface IReporter {\n warn(message: string): void\n}\n\nexport interface ISharpGatsbyImageArgs {\n layout?: Layout\n formats?: Array\n placeholder?: \"tracedSVG\" | \"dominantColor\" | \"blurred\" | \"none\"\n tracedSVGOptions?: Record\n width?: number\n height?: number\n aspectRatio?: number\n sizes?: string\n quality?: number\n transformOptions?: {\n fit?: Fit\n cropFocus?: number | string\n duotone?: {\n highlight: string\n shadow: string\n opacity?: number\n }\n grayscale?: boolean\n rotate?: number\n trim?: number\n }\n jpgOptions?: Record\n pngOptions?: Record\n webpOptions?: Record\n avifOptions?: Record\n blurredOptions?: { width?: number; toFormat?: ImageFormat }\n breakpoints?: Array\n backgroundColor?: string\n}\n\nexport interface IImageSizeArgs {\n width?: number\n height?: number\n layout?: Layout\n filename: string\n outputPixelDensities?: Array\n breakpoints?: Array\n fit?: Fit\n reporter?: IReporter\n sourceMetadata: { width: number; height: number }\n}\n\nexport interface IImageSizes {\n sizes: Array\n presentationWidth: number\n presentationHeight: number\n aspectRatio: number\n unscaledWidth: number\n}\n\nexport interface IImage {\n src: string\n width: number\n height: number\n format: ImageFormat\n}\n\nexport interface IGatsbyImageHelperArgs {\n pluginName: string\n generateImageSource: (\n filename: string,\n width: number,\n height: number,\n format: ImageFormat,\n fit?: Fit,\n options?: Record\n ) => IImage\n layout?: Layout\n formats?: Array\n filename: string\n placeholderURL?: string\n width?: number\n height?: number\n sizes?: string\n reporter?: IReporter\n sourceMetadata?: { width: number; height: number; format: ImageFormat }\n fit?: Fit\n options?: Record\n breakpoints?: Array\n backgroundColor?: string\n aspectRatio?: number\n}\n\nconst warn = (message: string): void => console.warn(message)\n\nconst sortNumeric = (a: number, b: number): number => a - b\n\nexport const getSizes = (width: number, layout: Layout): string | undefined => {\n switch (layout) {\n // If screen is wider than the max size, image width is the max size,\n // otherwise it's the width of the screen\n case `constrained`:\n return `(min-width: ${width}px) ${width}px, 100vw`\n\n // Image is always the same width, whatever the size of the screen\n case `fixed`:\n return `${width}px`\n\n // Image is always the width of the screen\n case `fullWidth`:\n return `100vw`\n\n default:\n return undefined\n }\n}\n\nexport const getSrcSet = (images: Array): string =>\n images.map(image => `${image.src} ${image.width}w`).join(`,\\n`)\n\nexport function formatFromFilename(filename: string): ImageFormat | undefined {\n const dot = filename.lastIndexOf(`.`)\n if (dot !== -1) {\n const ext = filename.substr(dot + 1)\n if (ext === `jpeg`) {\n return `jpg`\n }\n if (ext.length === 3 || ext.length === 4) {\n return ext as ImageFormat\n }\n }\n return undefined\n}\n\nexport function setDefaultDimensions(\n args: IGatsbyImageHelperArgs\n): IGatsbyImageHelperArgs {\n let {\n layout = `constrained`,\n width,\n height,\n sourceMetadata,\n breakpoints,\n aspectRatio,\n formats = [`auto`, `webp`],\n } = args\n formats = formats.map(format => format.toLowerCase() as ImageFormat)\n layout = camelCase(layout) as Layout\n\n if (width && height) {\n return { ...args, formats, layout, aspectRatio: width / height }\n }\n if (sourceMetadata.width && sourceMetadata.height && !aspectRatio) {\n aspectRatio = sourceMetadata.width / sourceMetadata.height\n }\n\n if (layout === `fullWidth`) {\n width = width || sourceMetadata.width || breakpoints[breakpoints.length - 1]\n height = height || Math.round(width / (aspectRatio || DEFAULT_ASPECT_RATIO))\n } else {\n if (!width) {\n if (height && aspectRatio) {\n width = height * aspectRatio\n } else if (sourceMetadata.width) {\n width = sourceMetadata.width\n } else if (height) {\n width = Math.round(height / DEFAULT_ASPECT_RATIO)\n } else {\n width = DEFAULT_FIXED_WIDTH\n }\n }\n\n if (aspectRatio && !height) {\n height = Math.round(width / aspectRatio)\n } else if (!aspectRatio) {\n aspectRatio = width / height\n }\n }\n return { ...args, width, height, aspectRatio, layout, formats }\n}\n\n/**\n * Use this for getting an image for the blurred placeholder. This ensures the\n * aspect ratio and crop match the main image\n */\nexport function getLowResolutionImageURL(\n args: IGatsbyImageHelperArgs,\n width = 20\n): string {\n args = setDefaultDimensions(args)\n const { generateImageSource, filename, aspectRatio } = args\n return generateImageSource(\n filename,\n width,\n Math.round(width / aspectRatio),\n args.sourceMetadata.format || `jpg`,\n args.fit,\n args.options\n )?.src\n}\n\nexport function generateImageData(\n args: IGatsbyImageHelperArgs\n): IGatsbyImageData {\n args = setDefaultDimensions(args)\n\n let {\n pluginName,\n sourceMetadata,\n generateImageSource,\n layout,\n fit,\n options,\n width,\n height,\n filename,\n reporter = { warn },\n backgroundColor,\n placeholderURL,\n } = args\n\n if (!pluginName) {\n reporter.warn(\n `[gatsby-plugin-image] \"generateImageData\" was not passed a plugin name`\n )\n }\n\n if (typeof generateImageSource !== `function`) {\n throw new Error(`generateImageSource must be a function`)\n }\n\n if (!sourceMetadata || (!sourceMetadata.width && !sourceMetadata.height)) {\n // No metadata means we let the CDN handle max size etc, aspect ratio etc\n sourceMetadata = {\n width,\n height,\n format: sourceMetadata?.format || formatFromFilename(filename) || `auto`,\n }\n } else if (!sourceMetadata.format) {\n sourceMetadata.format = formatFromFilename(filename)\n }\n\n const formats = new Set(args.formats)\n\n if (formats.size === 0 || formats.has(`auto`) || formats.has(``)) {\n formats.delete(`auto`)\n formats.delete(``)\n formats.add(sourceMetadata.format)\n }\n\n if (formats.has(`jpg`) && formats.has(`png`)) {\n reporter.warn(\n `[${pluginName}] Specifying both 'jpg' and 'png' formats is not supported. Using 'auto' instead`\n )\n if (sourceMetadata.format === `jpg`) {\n formats.delete(`png`)\n } else {\n formats.delete(`jpg`)\n }\n }\n\n const imageSizes = calculateImageSizes({ ...args, sourceMetadata })\n\n const result: IGatsbyImageData[\"images\"] = {\n sources: [],\n }\n\n let sizes = args.sizes\n if (!sizes) {\n sizes = getSizes(imageSizes.presentationWidth, layout)\n }\n\n formats.forEach(format => {\n const images = imageSizes.sizes\n .map(size => {\n const imageSrc = generateImageSource(\n filename,\n size,\n Math.round(size / imageSizes.aspectRatio),\n format,\n fit,\n options\n )\n if (\n !imageSrc?.width ||\n !imageSrc.height ||\n !imageSrc.src ||\n !imageSrc.format\n ) {\n reporter.warn(\n `[${pluginName}] The resolver for image ${filename} returned an invalid value.`\n )\n return undefined\n }\n return imageSrc\n })\n .filter(Boolean)\n\n if (format === `jpg` || format === `png` || format === `auto`) {\n const unscaled =\n images.find(img => img.width === imageSizes.unscaledWidth) || images[0]\n\n if (unscaled) {\n result.fallback = {\n src: unscaled.src,\n srcSet: getSrcSet(images),\n sizes,\n }\n }\n } else {\n result.sources?.push({\n srcSet: getSrcSet(images),\n sizes,\n type: `image/${format}`,\n })\n }\n })\n\n const imageProps: Partial = {\n images: result,\n layout,\n backgroundColor,\n }\n\n if (placeholderURL) {\n imageProps.placeholder = { fallback: placeholderURL }\n }\n\n switch (layout) {\n case `fixed`:\n imageProps.width = imageSizes.presentationWidth\n imageProps.height = imageSizes.presentationHeight\n break\n\n case `fullWidth`:\n imageProps.width = 1\n imageProps.height = 1 / imageSizes.aspectRatio\n break\n\n case `constrained`:\n imageProps.width = args.width || imageSizes.presentationWidth || 1\n imageProps.height = (imageProps.width || 1) / imageSizes.aspectRatio\n }\n\n return imageProps as IGatsbyImageData\n}\n\nconst dedupeAndSortDensities = (values: Array): Array =>\n Array.from(new Set([1, ...values])).sort(sortNumeric)\n\nexport function calculateImageSizes(args: IImageSizeArgs): IImageSizes {\n const {\n width,\n height,\n filename,\n layout = `constrained`,\n sourceMetadata: imgDimensions,\n reporter = { warn },\n breakpoints = DEFAULT_BREAKPOINTS,\n } = args\n\n // check that all dimensions provided are positive\n const userDimensions = { width, height }\n const erroneousUserDimensions = Object.entries(userDimensions).filter(\n ([_, size]) => typeof size === `number` && size < 1\n )\n if (erroneousUserDimensions.length) {\n throw new Error(\n `Specified dimensions for images must be positive numbers (> 0). Problem dimensions you have are ${erroneousUserDimensions\n .map(dim => dim.join(`: `))\n .join(`, `)}`\n )\n }\n\n if (layout === `fixed`) {\n return fixedImageSizes(args)\n } else if (layout === `constrained`) {\n return responsiveImageSizes(args)\n } else if (layout === `fullWidth`) {\n return responsiveImageSizes({ breakpoints, ...args })\n } else {\n reporter.warn(\n `No valid layout was provided for the image at ${filename}. Valid image layouts are fixed, fullWidth, and constrained. Found ${layout}`\n )\n return {\n sizes: [imgDimensions.width],\n presentationWidth: imgDimensions.width,\n presentationHeight: imgDimensions.height,\n aspectRatio: imgDimensions.width / imgDimensions.height,\n unscaledWidth: imgDimensions.width,\n }\n }\n}\nexport function fixedImageSizes({\n filename,\n sourceMetadata: imgDimensions,\n width,\n height,\n fit = `cover`,\n outputPixelDensities = DEFAULT_PIXEL_DENSITIES,\n reporter = { warn },\n}: IImageSizeArgs): IImageSizes {\n let aspectRatio = imgDimensions.width / imgDimensions.height\n // Sort, dedupe and ensure there's a 1\n const densities = dedupeAndSortDensities(outputPixelDensities)\n\n // If both are provided then we need to check the fit\n if (width && height) {\n const calculated = getDimensionsAndAspectRatio(imgDimensions, {\n width,\n height,\n fit,\n })\n width = calculated.width\n height = calculated.height\n aspectRatio = calculated.aspectRatio\n }\n\n if (!width) {\n if (!height) {\n width = DEFAULT_FIXED_WIDTH\n } else {\n width = Math.round(height * aspectRatio)\n }\n } else if (!height) {\n height = Math.round(width / aspectRatio)\n }\n\n const originalWidth = width // will use this for presentationWidth, don't want to lose it\n const isTopSizeOverriden =\n imgDimensions.width < width || imgDimensions.height < (height as number)\n\n // If the image is smaller than requested, warn the user that it's being processed as such\n // print out this message with the necessary information before we overwrite it for sizing\n if (isTopSizeOverriden) {\n const fixedDimension = imgDimensions.width < width ? `width` : `height`\n reporter.warn(stripIndent`\n The requested ${fixedDimension} \"${\n fixedDimension === `width` ? width : height\n }px\" for the image ${filename} was larger than the actual image ${fixedDimension} of ${\n imgDimensions[fixedDimension]\n }px. If possible, replace the current image with a larger one.`)\n\n if (fixedDimension === `width`) {\n width = imgDimensions.width\n height = Math.round(width / aspectRatio)\n } else {\n height = imgDimensions.height\n width = height * aspectRatio\n }\n }\n\n const sizes = densities\n .filter(size => size >= 1) // remove smaller densities because fixed images don't need them\n .map(density => Math.round(density * (width as number)))\n .filter(size => size <= imgDimensions.width)\n\n return {\n sizes,\n aspectRatio,\n presentationWidth: originalWidth,\n presentationHeight: Math.round(originalWidth / aspectRatio),\n unscaledWidth: width,\n }\n}\n\nexport function responsiveImageSizes({\n sourceMetadata: imgDimensions,\n width,\n height,\n fit = `cover`,\n outputPixelDensities = DEFAULT_PIXEL_DENSITIES,\n breakpoints,\n layout,\n}: IImageSizeArgs): IImageSizes {\n let sizes\n let aspectRatio = imgDimensions.width / imgDimensions.height\n // Sort, dedupe and ensure there's a 1\n const densities = dedupeAndSortDensities(outputPixelDensities)\n\n // If both are provided then we need to check the fit\n if (width && height) {\n const calculated = getDimensionsAndAspectRatio(imgDimensions, {\n width,\n height,\n fit,\n })\n width = calculated.width\n height = calculated.height\n aspectRatio = calculated.aspectRatio\n }\n\n // Case 1: width of height were passed in, make sure it isn't larger than the actual image\n width = width && Math.min(width, imgDimensions.width)\n height = height && Math.min(height, imgDimensions.height)\n\n // Case 2: neither width or height were passed in, use default size\n if (!width && !height) {\n width = Math.min(DEFAULT_FLUID_WIDTH, imgDimensions.width)\n height = width / aspectRatio\n }\n\n // if it still hasn't been found, calculate width from the derived height.\n // TS isn't smart enough to realise the type for height has been narrowed here\n if (!width) {\n width = (height as number) * aspectRatio\n }\n\n const originalWidth = width\n const isTopSizeOverriden =\n imgDimensions.width < width || imgDimensions.height < (height as number)\n if (isTopSizeOverriden) {\n width = imgDimensions.width\n height = imgDimensions.height\n }\n\n width = Math.round(width)\n\n if (breakpoints?.length > 0) {\n sizes = breakpoints.filter(size => size <= imgDimensions.width)\n\n // If a larger breakpoint has been filtered-out, add the actual image width instead\n if (\n sizes.length < breakpoints.length &&\n !sizes.includes(imgDimensions.width)\n ) {\n sizes.push(imgDimensions.width)\n }\n } else {\n sizes = densities.map(density => Math.round(density * (width as number)))\n sizes = sizes.filter(size => size <= imgDimensions.width)\n }\n\n // ensure that the size passed in is included in the final output\n if (layout === `constrained` && !sizes.includes(width)) {\n sizes.push(width)\n }\n sizes = sizes.sort(sortNumeric)\n return {\n sizes,\n aspectRatio,\n presentationWidth: originalWidth,\n presentationHeight: Math.round(originalWidth / aspectRatio),\n unscaledWidth: width,\n }\n}\n\nexport function getDimensionsAndAspectRatio(\n dimensions,\n options\n): { width: number; height: number; aspectRatio: number } {\n // Calculate the eventual width/height of the image.\n const imageAspectRatio = dimensions.width / dimensions.height\n\n let width = options.width\n let height = options.height\n\n switch (options.fit) {\n case `fill`: {\n width = options.width ? options.width : dimensions.width\n height = options.height ? options.height : dimensions.height\n break\n }\n case `inside`: {\n const widthOption = options.width\n ? options.width\n : Number.MAX_SAFE_INTEGER\n const heightOption = options.height\n ? options.height\n : Number.MAX_SAFE_INTEGER\n\n width = Math.min(widthOption, Math.round(heightOption * imageAspectRatio))\n height = Math.min(\n heightOption,\n Math.round(widthOption / imageAspectRatio)\n )\n break\n }\n case `outside`: {\n const widthOption = options.width ? options.width : 0\n const heightOption = options.height ? options.height : 0\n\n width = Math.max(widthOption, Math.round(heightOption * imageAspectRatio))\n height = Math.max(\n heightOption,\n Math.round(widthOption / imageAspectRatio)\n )\n break\n }\n\n default: {\n if (options.width && !options.height) {\n width = options.width\n height = Math.round(options.width / imageAspectRatio)\n }\n\n if (options.height && !options.width) {\n width = Math.round(options.height * imageAspectRatio)\n height = options.height\n }\n }\n }\n\n return {\n width,\n height,\n aspectRatio: width / height,\n }\n}\n","/* eslint-disable no-unused-expressions */\nimport {\n useState,\n CSSProperties,\n useEffect,\n HTMLAttributes,\n ImgHTMLAttributes,\n ReactEventHandler,\n SetStateAction,\n Dispatch,\n RefObject,\n} from \"react\"\nimport { Node } from \"gatsby\"\nimport { PlaceholderProps } from \"./placeholder\"\nimport { MainImageProps } from \"./main-image\"\nimport type { IGatsbyImageData } from \"./gatsby-image.browser\"\nimport {\n IGatsbyImageHelperArgs,\n generateImageData,\n Layout,\n EVERY_BREAKPOINT,\n IImage,\n ImageFormat,\n} from \"../image-utils\"\nconst imageCache = new Set()\n\n// Native lazy-loading support: https://addyosmani.com/blog/lazy-loading/\nexport const hasNativeLazyLoadSupport = (): boolean =>\n typeof HTMLImageElement !== `undefined` &&\n `loading` in HTMLImageElement.prototype\n\nexport function gatsbyImageIsInstalled(): boolean {\n return typeof GATSBY___IMAGE !== `undefined` && GATSBY___IMAGE\n}\n\nexport function storeImageloaded(cacheKey?: string): void {\n if (cacheKey) {\n imageCache.add(cacheKey)\n }\n}\n\nexport function hasImageLoaded(cacheKey: string): boolean {\n return imageCache.has(cacheKey)\n}\nexport type IGatsbyImageDataParent = T & {\n gatsbyImageData: IGatsbyImageData\n}\nexport type FileNode = Node & {\n childImageSharp?: IGatsbyImageDataParent\n}\n\nconst isGatsbyImageData = (\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n node: IGatsbyImageData | any\n): node is IGatsbyImageData =>\n // 🦆 check for a deep prop to be sure this is a valid gatsbyImageData object\n Boolean(node?.images?.fallback?.src)\n\nconst isGatsbyImageDataParent = (\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n node: IGatsbyImageDataParent | any\n): node is IGatsbyImageDataParent => Boolean(node?.gatsbyImageData)\n\nexport type ImageDataLike = FileNode | IGatsbyImageDataParent | IGatsbyImageData\nexport const getImage = (node: ImageDataLike): IGatsbyImageData | undefined => {\n if (isGatsbyImageData(node)) {\n return node\n }\n if (isGatsbyImageDataParent(node)) {\n return node.gatsbyImageData\n }\n return node?.childImageSharp?.gatsbyImageData\n}\n\nexport const getSrc = (node: ImageDataLike): string | undefined =>\n getImage(node)?.images?.fallback?.src\n\nexport const getSrcSet = (node: ImageDataLike): string | undefined =>\n getImage(node)?.images?.fallback?.srcSet\n\nexport function getWrapperProps(\n width: number,\n height: number,\n layout: Layout\n): Pick, \"className\" | \"style\"> & {\n \"data-gatsby-image-wrapper\": string\n} {\n const wrapperStyle: CSSProperties = {}\n\n let className = `gatsby-image-wrapper`\n\n // If the plugin isn't installed we need to apply the styles inline\n if (!gatsbyImageIsInstalled()) {\n wrapperStyle.position = `relative`\n wrapperStyle.overflow = `hidden`\n }\n\n if (layout === `fixed`) {\n wrapperStyle.width = width\n wrapperStyle.height = height\n } else if (layout === `constrained`) {\n if (!gatsbyImageIsInstalled()) {\n wrapperStyle.display = `inline-block`\n wrapperStyle.verticalAlign = `top`\n }\n className = `gatsby-image-wrapper gatsby-image-wrapper-constrained`\n }\n\n return {\n className,\n \"data-gatsby-image-wrapper\": ``,\n style: wrapperStyle,\n }\n}\n\nexport async function applyPolyfill(\n ref: RefObject\n): Promise {\n if (!(`objectFitPolyfill` in window)) {\n await import(\n // @ts-ignore typescript can't find the module for some reason ¯\\_(ツ)_/¯\n /* webpackChunkName: \"gatsby-plugin-image-objectfit-polyfill\" */ `objectFitPolyfill`\n )\n }\n ;(window as any).objectFitPolyfill(ref.current)\n}\n\nexport interface IUrlBuilderArgs {\n width: number\n height: number\n baseUrl: string\n format: ImageFormat\n options: OptionsType\n}\nexport interface IGetImageDataArgs> {\n baseUrl: string\n /**\n * For constrained and fixed images, the size of the image element\n */\n width?: number\n height?: number\n /**\n * If available, pass the source image width and height\n */\n sourceWidth?: number\n sourceHeight?: number\n /**\n * If only one dimension is passed, then this will be used to calculate the other.\n */\n aspectRatio?: number\n layout?: Layout\n /**\n * Returns a URL based on the passed arguments. Should be a pure function\n */\n urlBuilder: (args: IUrlBuilderArgs) => string\n\n /**\n * Should be a data URI\n */\n placeholderURL?: string\n backgroundColor?: string\n /**\n * Used in error messages etc\n */\n pluginName?: string\n\n /**\n * If you do not support auto-format, pass an array of image types here\n */\n formats?: Array\n\n breakpoints?: Array\n\n /**\n * Passed to the urlBuilder function\n */\n options?: OptionsType\n}\n\n/**\n * Use this hook to generate gatsby-plugin-image data in the browser.\n */\nexport function getImageData({\n baseUrl,\n urlBuilder,\n sourceWidth,\n sourceHeight,\n pluginName = `getImageData`,\n formats = [`auto`],\n breakpoints,\n options,\n ...props\n}: IGetImageDataArgs): IGatsbyImageData {\n if (\n !breakpoints?.length &&\n (props.layout === `fullWidth` || (props.layout as string) === `FULL_WIDTH`)\n ) {\n breakpoints = EVERY_BREAKPOINT\n }\n const generateImageSource = (\n baseUrl: string,\n width: number,\n height?: number,\n format?: ImageFormat\n ): IImage => {\n return {\n width,\n height,\n format,\n src: urlBuilder({ baseUrl, width, height, options, format }),\n }\n }\n\n const sourceMetadata: IGatsbyImageHelperArgs[\"sourceMetadata\"] = {\n width: sourceWidth,\n height: sourceHeight,\n format: `auto`,\n }\n\n const args: IGatsbyImageHelperArgs = {\n ...props,\n pluginName,\n generateImageSource,\n filename: baseUrl,\n formats,\n breakpoints,\n sourceMetadata,\n }\n return generateImageData(args)\n}\n\nexport function getMainProps(\n isLoading: boolean,\n isLoaded: boolean,\n images: IGatsbyImageData[\"images\"],\n loading?: \"eager\" | \"lazy\",\n toggleLoaded?: (loaded: boolean) => void,\n cacheKey?: string,\n ref?: RefObject,\n style: CSSProperties = {}\n): Partial {\n const onLoad: ReactEventHandler = function (e) {\n if (isLoaded) {\n return\n }\n\n storeImageloaded(cacheKey)\n\n const target = e.currentTarget\n const img = new Image()\n img.src = target.currentSrc\n\n if (img.decode) {\n // Decode the image through javascript to support our transition\n img\n .decode()\n .catch(() => {\n // ignore error, we just go forward\n })\n .then(() => {\n toggleLoaded(true)\n })\n } else {\n toggleLoaded(true)\n }\n }\n\n // Polyfill \"object-fit\" if unsupported (mostly IE)\n if (ref?.current && !(`objectFit` in document.documentElement.style)) {\n ref.current.dataset.objectFit = style.objectFit ?? `cover`\n ref.current.dataset.objectPosition = `${style.objectPosition ?? `50% 50%`}`\n applyPolyfill(ref)\n }\n\n // fallback when it's not configured in gatsby-config.\n if (!gatsbyImageIsInstalled()) {\n style = {\n height: `100%`,\n left: 0,\n position: `absolute`,\n top: 0,\n transform: `translateZ(0)`,\n transition: `opacity 250ms linear`,\n width: `100%`,\n willChange: `opacity`,\n ...style,\n }\n }\n\n const result = {\n ...images,\n loading,\n shouldLoad: isLoading,\n \"data-main-image\": ``,\n style: {\n ...style,\n opacity: isLoaded ? 1 : 0,\n },\n onLoad,\n ref,\n }\n\n return result\n}\n\nexport type PlaceholderImageAttrs = ImgHTMLAttributes &\n Pick & {\n \"data-placeholder-image\"?: string\n }\n\nexport function getPlaceholderProps(\n placeholder: PlaceholderImageAttrs | undefined,\n isLoaded: boolean,\n layout: Layout,\n width?: number,\n height?: number,\n backgroundColor?: string,\n objectFit?: CSSProperties[\"objectFit\"],\n objectPosition?: CSSProperties[\"objectPosition\"]\n): PlaceholderImageAttrs {\n const wrapperStyle: CSSProperties = {}\n\n if (backgroundColor) {\n wrapperStyle.backgroundColor = backgroundColor\n\n if (layout === `fixed`) {\n wrapperStyle.width = width\n wrapperStyle.height = height\n wrapperStyle.backgroundColor = backgroundColor\n wrapperStyle.position = `relative`\n } else if (layout === `constrained`) {\n wrapperStyle.position = `absolute`\n wrapperStyle.top = 0\n wrapperStyle.left = 0\n wrapperStyle.bottom = 0\n wrapperStyle.right = 0\n } else if (layout === `fullWidth`) {\n wrapperStyle.position = `absolute`\n wrapperStyle.top = 0\n wrapperStyle.left = 0\n wrapperStyle.bottom = 0\n wrapperStyle.right = 0\n }\n }\n\n if (objectFit) {\n wrapperStyle.objectFit = objectFit\n }\n\n if (objectPosition) {\n wrapperStyle.objectPosition = objectPosition\n }\n const result: PlaceholderImageAttrs = {\n ...placeholder,\n \"aria-hidden\": true,\n \"data-placeholder-image\": ``,\n style: {\n opacity: isLoaded ? 0 : 1,\n transition: `opacity 500ms linear`,\n ...wrapperStyle,\n },\n }\n\n // fallback when it's not configured in gatsby-config.\n if (!gatsbyImageIsInstalled()) {\n result.style = {\n height: `100%`,\n left: 0,\n position: `absolute`,\n top: 0,\n width: `100%`,\n }\n }\n\n return result\n}\n\nexport function useImageLoaded(\n cacheKey: string,\n loading: \"lazy\" | \"eager\",\n ref: any\n): {\n isLoaded: boolean\n isLoading: boolean\n toggleLoaded: Dispatch>\n} {\n const [isLoaded, toggleLoaded] = useState(false)\n const [isLoading, toggleIsLoading] = useState(loading === `eager`)\n\n const rAF =\n typeof window !== `undefined` && `requestAnimationFrame` in window\n ? requestAnimationFrame\n : function (cb: TimerHandler): number {\n return setTimeout(cb, 16)\n }\n const cRAF =\n typeof window !== `undefined` && `cancelAnimationFrame` in window\n ? cancelAnimationFrame\n : clearTimeout\n\n useEffect(() => {\n let interval: number\n // @see https://stackoverflow.com/questions/44074747/componentdidmount-called-before-ref-callback/50019873#50019873\n function toggleIfRefExists(): void {\n if (ref.current) {\n if (loading === `eager` && ref.current.complete) {\n storeImageloaded(cacheKey)\n toggleLoaded(true)\n } else {\n toggleIsLoading(true)\n }\n } else {\n interval = rAF(toggleIfRefExists)\n }\n }\n toggleIfRefExists()\n\n return (): void => {\n cRAF(interval)\n }\n }, [])\n\n return {\n isLoading,\n isLoaded,\n toggleLoaded,\n }\n}\n\nexport interface IArtDirectedImage {\n media: string\n image: IGatsbyImageData\n}\n\n/**\n * Generate a Gatsby image data object with multiple, art-directed images that display at different\n * resolutions.\n *\n * @param defaultImage The image displayed when no media query matches.\n * It is also used for all other settings applied to the image, such as width, height and layout.\n * You should pass a className to the component with media queries to adjust the size of the container,\n * as this cannot be adjusted automatically.\n * @param artDirected Array of objects which each contains a `media` string which is a media query\n * such as `(min-width: 320px)`, and the image object to use when that query matches.\n */\nexport function withArtDirection(\n defaultImage: IGatsbyImageData,\n artDirected: Array\n): IGatsbyImageData {\n const { images, placeholder, ...props } = defaultImage\n const output: IGatsbyImageData = {\n ...props,\n images: {\n ...images,\n sources: [],\n },\n placeholder: placeholder && {\n ...placeholder,\n sources: [],\n },\n }\n\n artDirected.forEach(({ media, image }) => {\n if (!media) {\n if (process.env.NODE_ENV === `development`) {\n console.warn(\n \"[gatsby-plugin-image] All art-directed images passed to must have a value set for `media`. Skipping.\"\n )\n }\n return\n }\n\n if (\n image.layout !== defaultImage.layout &&\n process.env.NODE_ENV === `development`\n ) {\n console.warn(\n `[gatsby-plugin-image] Mismatched image layout: expected \"${defaultImage.layout}\" but received \"${image.layout}\". All art-directed images use the same layout as the default image`\n )\n }\n\n output.images.sources.push(\n ...image.images.sources.map(source => {\n return { ...source, media }\n }),\n {\n media,\n srcSet: image.images.fallback.srcSet,\n }\n )\n\n if (!output.placeholder) {\n return\n }\n\n output.placeholder.sources.push({\n media,\n srcSet: image.placeholder.fallback,\n })\n })\n output.images.sources.push(...images.sources)\n if (placeholder?.sources) {\n output.placeholder?.sources.push(...placeholder.sources)\n }\n return output\n}\n","// eslint-disable-next-line @typescript-eslint/triple-slash-reference\n/// \n\nimport React, { Fragment, FunctionComponent } from \"react\"\nimport terserMacro from \"../../macros/terser.macro\"\nimport { Layout } from \"../image-utils\"\n\nexport interface ILayoutWrapperProps {\n layout: Layout\n width: number\n height: number\n}\n\nconst NativeScriptLoading: FunctionComponent = () => (\n \n)\n\nexport function getSizer(\n layout: Layout,\n width: number,\n height: number\n): string {\n let sizer: string | null = null\n if (layout === `fullWidth`) {\n sizer = `
    `\n }\n if (layout === `constrained`) {\n sizer = `
    \"\"
    `\n }\n return sizer\n}\n\nconst Sizer: FunctionComponent = function Sizer({\n layout,\n width,\n height,\n}) {\n if (layout === `fullWidth`) {\n return (\n
    \n )\n }\n if (layout === `constrained`) {\n return (\n
    \n \n
    \n )\n }\n\n return null\n}\n\nexport const LayoutWrapper: FunctionComponent =\n function LayoutWrapper({ children, ...props }) {\n return (\n \n \n {children}\n\n {\n // eslint-disable-next-line no-undef\n SERVER && \n }\n \n )\n }\n","/* eslint-disable filenames/match-regex */\nimport React, {\n FunctionComponent,\n ImgHTMLAttributes,\n forwardRef,\n LegacyRef,\n} from \"react\"\nimport * as PropTypes from \"prop-types\"\n\nexport interface IResponsiveImageProps {\n sizes?: string\n srcSet: string\n}\n\nexport type SourceProps = IResponsiveImageProps &\n (\n | {\n media: string\n type?: string\n }\n | {\n media?: string\n type: string\n }\n )\n\ntype FallbackProps = { src: string } & Partial\n\ntype ImageProps = ImgHTMLAttributes & {\n src: string\n alt: string\n shouldLoad: boolean\n innerRef: LegacyRef\n}\n\nexport type PictureProps = ImgHTMLAttributes & {\n fallback?: FallbackProps\n sources?: Array\n alt: string\n shouldLoad?: boolean\n}\n\nconst Image: FunctionComponent = function Image({\n src,\n srcSet,\n loading,\n alt = ``,\n shouldLoad,\n innerRef,\n ...props\n}) {\n return (\n \n )\n}\n\nexport const Picture = forwardRef(\n function Picture(\n { fallback, sources = [], shouldLoad = true, ...props },\n ref\n ) {\n const sizes = props.sizes || fallback?.sizes\n const fallbackImage = (\n \n )\n\n if (!sources.length) {\n return fallbackImage\n }\n\n return (\n \n {sources.map(({ media, srcSet, type }) => (\n \n ))}\n {fallbackImage}\n \n )\n }\n)\n\nImage.propTypes = {\n src: PropTypes.string.isRequired,\n alt: PropTypes.string.isRequired,\n sizes: PropTypes.string,\n srcSet: PropTypes.string,\n shouldLoad: PropTypes.bool,\n}\n\nPicture.displayName = `Picture`\nPicture.propTypes = {\n alt: PropTypes.string.isRequired,\n shouldLoad: PropTypes.bool,\n fallback: PropTypes.exact({\n src: PropTypes.string.isRequired,\n srcSet: PropTypes.string,\n sizes: PropTypes.string,\n }),\n sources: PropTypes.arrayOf(\n PropTypes.oneOfType([\n PropTypes.exact({\n media: PropTypes.string.isRequired,\n type: PropTypes.string,\n sizes: PropTypes.string,\n srcSet: PropTypes.string.isRequired,\n }),\n PropTypes.exact({\n media: PropTypes.string,\n type: PropTypes.string.isRequired,\n sizes: PropTypes.string,\n srcSet: PropTypes.string.isRequired,\n }),\n ])\n ),\n}\n","import React, { FunctionComponent, ImgHTMLAttributes } from \"react\"\nimport * as PropTypes from \"prop-types\"\nimport { Picture, SourceProps } from \"./picture\"\n\nexport type PlaceholderProps = ImgHTMLAttributes & {\n fallback?: string\n sources?: Array\n}\n\nexport const Placeholder: FunctionComponent =\n function Placeholder({ fallback, ...props }) {\n if (fallback) {\n return (\n \n )\n } else {\n return
    \n }\n }\n\nPlaceholder.displayName = `Placeholder`\nPlaceholder.propTypes = {\n fallback: PropTypes.string,\n sources: Picture.propTypes?.sources,\n alt: function (props, propName, componentName): Error | null {\n if (!props[propName]) {\n return null\n }\n return new Error(\n `Invalid prop \\`${propName}\\` supplied to \\`${componentName}\\`. Validation failed.`\n )\n },\n}\n","import React, { forwardRef } from \"react\"\nimport { Picture, PictureProps } from \"./picture\"\n\nexport type MainImageProps = PictureProps\n\nexport const MainImage = forwardRef(\n function MainImage(props, ref) {\n return (\n <>\n \n \n \n )\n }\n)\n\nMainImage.displayName = `MainImage`\nMainImage.propTypes = Picture.propTypes\n","import React, {\n ElementType,\n FunctionComponent,\n CSSProperties,\n WeakValidationMap,\n} from \"react\"\nimport { GatsbyImageProps, IGatsbyImageData } from \"./gatsby-image.browser\"\nimport { getWrapperProps, getMainProps, getPlaceholderProps } from \"./hooks\"\nimport { Placeholder } from \"./placeholder\"\nimport { MainImage, MainImageProps } from \"./main-image\"\nimport { LayoutWrapper } from \"./layout-wrapper\"\nimport PropTypes from \"prop-types\"\n\nconst removeNewLines = (str: string): string => str.replace(/\\n/g, ``)\n\nexport const GatsbyImageHydrator: FunctionComponent<{\n as?: ElementType\n style?: CSSProperties\n className?: string\n}> = function GatsbyImageHydrator({ as: Type = `div`, children, ...props }) {\n return {children}\n}\n\nexport const GatsbyImage: FunctionComponent =\n function GatsbyImage({\n as,\n className,\n class: preactClass,\n style,\n image,\n loading = `lazy`,\n imgClassName,\n imgStyle,\n backgroundColor,\n objectFit,\n objectPosition,\n ...props\n }) {\n if (!image) {\n console.warn(`[gatsby-plugin-image] Missing image prop`)\n return null\n }\n if (preactClass) {\n className = preactClass\n }\n imgStyle = {\n objectFit,\n objectPosition,\n backgroundColor,\n ...imgStyle,\n }\n\n const {\n width,\n height,\n layout,\n images,\n placeholder,\n backgroundColor: placeholderBackgroundColor,\n } = image\n\n const {\n style: wStyle,\n className: wClass,\n ...wrapperProps\n } = getWrapperProps(width, height, layout)\n\n const cleanedImages: IGatsbyImageData[\"images\"] = {\n fallback: undefined,\n sources: [],\n }\n if (images.fallback) {\n cleanedImages.fallback = {\n ...images.fallback,\n srcSet: images.fallback.srcSet\n ? removeNewLines(images.fallback.srcSet)\n : undefined,\n }\n }\n\n if (images.sources) {\n cleanedImages.sources = images.sources.map(source => {\n return {\n ...source,\n srcSet: removeNewLines(source.srcSet),\n }\n })\n }\n\n return (\n \n \n \n\n )}\n // When eager is set we want to start the isLoading state on true (we want to load the img without react)\n {...getMainProps(\n loading === `eager`,\n false,\n cleanedImages,\n loading,\n undefined,\n undefined,\n undefined,\n imgStyle\n )}\n />\n \n \n )\n }\n\nexport const altValidator: PropTypes.Validator = (\n props: GatsbyImageProps,\n propName,\n componentName,\n ...rest\n): Error | undefined => {\n if (!props.alt && props.alt !== ``) {\n return new Error(\n `The \"alt\" prop is required in ${componentName}. If the image is purely presentational then pass an empty string: e.g. alt=\"\". Learn more: https://a11y-style-guide.com/style-guide/section-media.html`\n )\n }\n return PropTypes.string(props, propName, componentName, ...rest)\n}\nexport const propTypes = {\n image: PropTypes.object.isRequired,\n alt: altValidator,\n} as WeakValidationMap\n","/* eslint-disable no-unused-expressions */\nimport React, {\n Component,\n ElementType,\n createRef,\n MutableRefObject,\n FunctionComponent,\n ImgHTMLAttributes,\n RefObject,\n CSSProperties,\n} from \"react\"\nimport {\n getWrapperProps,\n hasNativeLazyLoadSupport,\n storeImageloaded,\n hasImageLoaded,\n gatsbyImageIsInstalled,\n} from \"./hooks\"\nimport { PlaceholderProps } from \"./placeholder\"\nimport { MainImageProps } from \"./main-image\"\nimport { Layout } from \"../image-utils\"\nimport { getSizer } from \"./layout-wrapper\"\nimport { propTypes } from \"./gatsby-image.server\"\nimport { Unobserver } from \"./intersection-observer\"\nimport { render } from \"react-dom\"\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport interface GatsbyImageProps\n extends Omit<\n ImgHTMLAttributes,\n \"placeholder\" | \"onLoad\" | \"src\" | \"srcSet\" | \"width\" | \"height\"\n > {\n alt: string\n as?: ElementType\n className?: string\n class?: string\n imgClassName?: string\n image: IGatsbyImageData\n imgStyle?: CSSProperties\n backgroundColor?: string\n objectFit?: CSSProperties[\"objectFit\"]\n objectPosition?: CSSProperties[\"objectPosition\"]\n onLoad?: () => void\n onError?: () => void\n onStartLoad?: (props: { wasCached?: boolean }) => void\n}\n\nexport interface IGatsbyImageData {\n layout: Layout\n width: number\n height: number\n backgroundColor?: string\n images: Pick\n placeholder?: Pick\n}\n\nclass GatsbyImageHydrator extends Component<\n GatsbyImageProps,\n { isLoading: boolean; isLoaded: boolean }\n> {\n root: RefObject = createRef<\n HTMLImageElement | undefined\n >()\n hydrated: MutableRefObject = { current: false }\n forceRender: MutableRefObject = {\n // In dev we use render not hydrate, to avoid hydration warnings\n current: process.env.NODE_ENV === `development`,\n }\n lazyHydrator: () => void | null = null\n ref = createRef()\n unobserveRef: Unobserver\n\n constructor(props) {\n super(props)\n\n this.state = {\n isLoading: hasNativeLazyLoadSupport(),\n isLoaded: false,\n }\n }\n\n _lazyHydrate(props, state): Promise {\n const hasSSRHtml = this.root.current.querySelector(\n `[data-gatsby-image-ssr]`\n )\n // On first server hydration do nothing\n if (hasNativeLazyLoadSupport() && hasSSRHtml && !this.hydrated.current) {\n this.hydrated.current = true\n return Promise.resolve()\n }\n\n return import(`./lazy-hydrate`).then(({ lazyHydrate }) => {\n const cacheKey = JSON.stringify(this.props.image.images)\n this.lazyHydrator = lazyHydrate(\n {\n image: props.image.images,\n isLoading: state.isLoading || hasImageLoaded(cacheKey),\n isLoaded: state.isLoaded || hasImageLoaded(cacheKey),\n toggleIsLoaded: () => {\n props.onLoad?.()\n\n this.setState({\n isLoaded: true,\n })\n },\n ref: this.ref,\n ...props,\n },\n this.root,\n this.hydrated,\n this.forceRender\n )\n })\n }\n\n /**\n * Choose if setupIntersectionObserver should use the image cache or not.\n */\n _setupIntersectionObserver(useCache = true): void {\n import(`./intersection-observer`).then(({ createIntersectionObserver }) => {\n const intersectionObserver = createIntersectionObserver(() => {\n if (this.root.current) {\n const cacheKey = JSON.stringify(this.props.image.images)\n this.props.onStartLoad?.({\n wasCached: useCache && hasImageLoaded(cacheKey),\n })\n this.setState({\n isLoading: true,\n isLoaded: useCache && hasImageLoaded(cacheKey),\n })\n }\n })\n\n if (this.root.current) {\n this.unobserveRef = intersectionObserver(this.root)\n }\n })\n }\n\n shouldComponentUpdate(nextProps, nextState): boolean {\n let hasChanged = false\n if (!this.state.isLoading && nextState.isLoading && !nextState.isLoaded) {\n // Props have changed between SSR and hydration, so we need to force render instead of hydrate\n this.forceRender.current = true\n }\n // this check mostly means people do not have the correct ref checks in place, we want to reset some state to suppport loading effects\n if (this.props.image.images !== nextProps.image.images) {\n // reset state, we'll rely on intersection observer to reload\n if (this.unobserveRef) {\n // unregister intersectionObserver\n this.unobserveRef()\n\n // // on unmount, make sure we cleanup\n if (this.hydrated.current && this.lazyHydrator) {\n render(null, this.root.current)\n }\n }\n\n this.setState(\n {\n isLoading: false,\n isLoaded: false,\n },\n () => {\n this._setupIntersectionObserver(false)\n }\n )\n\n hasChanged = true\n }\n\n if (this.root.current && !hasChanged) {\n this._lazyHydrate(nextProps, nextState)\n }\n\n return false\n }\n\n componentDidMount(): void {\n if (this.root.current) {\n const ssrElement = this.root.current.querySelector(\n `[data-gatsby-image-ssr]`\n ) as HTMLImageElement\n const cacheKey = JSON.stringify(this.props.image.images)\n\n // when SSR and native lazyload is supported we'll do nothing ;)\n if (\n hasNativeLazyLoadSupport() &&\n ssrElement &&\n gatsbyImageIsInstalled()\n ) {\n this.props.onStartLoad?.({ wasCached: false })\n\n // When the image is already loaded before we have hydrated, we trigger onLoad and cache the item\n if (ssrElement.complete) {\n this.props.onLoad?.()\n storeImageloaded(cacheKey)\n } else {\n // We need the current class context (this) inside our named onLoad function\n // The named function is necessary to easily remove the listener afterward.\n // eslint-disable-next-line @typescript-eslint/no-this-alias\n const _this = this\n // add an onLoad to the image\n ssrElement.addEventListener(`load`, function onLoad() {\n ssrElement.removeEventListener(`load`, onLoad)\n\n _this.props.onLoad?.()\n storeImageloaded(cacheKey)\n })\n }\n\n return\n }\n\n // Fallback to custom lazy loading (intersection observer)\n this._setupIntersectionObserver(true)\n }\n }\n\n componentWillUnmount(): void {\n // Cleanup when onmount happens\n if (this.unobserveRef) {\n // unregister intersectionObserver\n this.unobserveRef()\n\n // on unmount, make sure we cleanup\n if (this.hydrated.current && this.lazyHydrator) {\n this.lazyHydrator()\n }\n }\n\n return\n }\n\n render(): JSX.Element {\n const Type = this.props.as || `div`\n const { width, height, layout } = this.props.image\n const {\n style: wStyle,\n className: wClass,\n ...wrapperProps\n } = getWrapperProps(width, height, layout)\n\n let className = this.props.className\n // preact class\n if (this.props.class) {\n className = this.props.class\n }\n\n const sizer = getSizer(layout, width, height)\n\n return (\n \n )\n }\n}\n\nexport const GatsbyImage: FunctionComponent =\n function GatsbyImage(props) {\n if (!props.image) {\n if (process.env.NODE_ENV === `development`) {\n console.warn(`[gatsby-plugin-image] Missing image prop`)\n }\n return null\n }\n\n if (!gatsbyImageIsInstalled() && process.env.NODE_ENV === `development`) {\n console.warn(\n `[gatsby-plugin-image] You're missing out on some cool performance features. Please add \"gatsby-plugin-image\" to your gatsby-config.js`\n )\n }\n const { className, class: classSafe, backgroundColor, image } = props\n const { width, height, layout } = image\n const propsKey = JSON.stringify([\n width,\n height,\n layout,\n className,\n classSafe,\n backgroundColor,\n ])\n return \n }\n\nGatsbyImage.propTypes = propTypes\n\nGatsbyImage.displayName = `GatsbyImage`\n","import React, { FunctionComponent, ReactElement } from \"react\"\nimport {\n altValidator,\n GatsbyImage as GatsbyImageServer,\n} from \"./gatsby-image.server\"\nimport { GatsbyImageProps, IGatsbyImageData } from \"./gatsby-image.browser\"\nimport PropTypes from \"prop-types\"\nimport { ISharpGatsbyImageArgs } from \"../image-utils\"\n\nexport interface IStaticImageProps\n extends Omit,\n Omit {\n src: string\n}\n\n// These values are added by Babel. Do not add them manually\ninterface IPrivateProps {\n __imageData?: IGatsbyImageData\n __error?: string\n}\n\nexport function _getStaticImage(\n GatsbyImage: FunctionComponent\n): React.FC {\n return function StaticImage({\n src,\n __imageData: imageData,\n __error,\n // We extract these because they're not meant to be passed-down to GatsbyImage\n /* eslint-disable @typescript-eslint/no-unused-vars */\n width,\n height,\n aspectRatio,\n tracedSVGOptions,\n placeholder,\n formats,\n quality,\n transformOptions,\n jpgOptions,\n pngOptions,\n webpOptions,\n avifOptions,\n blurredOptions,\n /* eslint-enable @typescript-eslint/no-unused-vars */\n ...props\n }): ReactElement {\n if (__error) {\n console.warn(__error)\n }\n\n if (imageData) {\n return \n }\n console.warn(`Image not loaded`, src)\n if (!__error && process.env.NODE_ENV === `development`) {\n console.warn(\n `Please ensure that \"gatsby-plugin-image\" is included in the plugins array in gatsby-config.js, and that your version of gatsby is at least 2.24.78`\n )\n }\n return null\n }\n}\n\nconst StaticImage: React.FC =\n _getStaticImage(GatsbyImageServer)\n\nconst checkDimensionProps: PropTypes.Validator = (\n props: IStaticImageProps & IPrivateProps,\n propName: keyof IStaticImageProps & IPrivateProps,\n ...rest\n) => {\n if (\n props.layout === `fullWidth` &&\n (propName === `width` || propName === `height`) &&\n props[propName]\n ) {\n return new Error(\n `\"${propName}\" ${props[propName]} may not be passed when layout is fullWidth.`\n )\n }\n return PropTypes.number(props, propName, ...rest)\n}\n\nconst validLayouts = new Set([`fixed`, `fullWidth`, `constrained`])\n\nexport const propTypes = {\n src: PropTypes.string.isRequired,\n alt: altValidator,\n width: checkDimensionProps,\n height: checkDimensionProps,\n sizes: PropTypes.string,\n layout: (props: IStaticImageProps & IPrivateProps): Error | undefined => {\n if (props.layout === undefined) {\n return undefined\n }\n if (validLayouts.has(props.layout)) {\n return undefined\n }\n\n return new Error(\n `Invalid value ${props.layout}\" provided for prop \"layout\". Defaulting to \"constrained\". Valid values are \"fixed\", \"fullWidth\" or \"constrained\".`\n )\n },\n}\n\nStaticImage.displayName = `StaticImage`\nStaticImage.propTypes = propTypes\n\nexport { StaticImage }\n","import {\n GatsbyImage as GatsbyImageBrowser,\n IGatsbyImageData,\n} from \"./gatsby-image.browser\"\nimport React from \"react\"\nimport {\n _getStaticImage,\n propTypes,\n IStaticImageProps,\n} from \"./static-image.server\"\n// These values are added by Babel. Do not add them manually\ninterface IPrivateProps {\n __imageData?: IGatsbyImageData\n __error?: string\n}\n\nconst StaticImage: React.FC =\n _getStaticImage(GatsbyImageBrowser)\n\nStaticImage.displayName = `StaticImage`\nStaticImage.propTypes = propTypes\n\nexport { StaticImage }\n","import * as React from \"react\"\nexport function LaterHydrator({\n children,\n}: React.PropsWithChildren>): React.ReactNode {\n React.useEffect(() => {\n // eslint-disable-next-line no-unused-expressions\n import(`./lazy-hydrate`)\n }, [])\n\n return children\n}\n","import React from \"react\"\nimport { LaterHydrator } from \".\"\n\nexport function wrapRootElement({ element }) {\n return {element}\n}\n","\"use strict\";\n\nexports.wrapPageElement = require(\"./wrap-page\");","\"use strict\";\n\nvar React = require(\"react\");\n\nvar preferDefault = function preferDefault(m) {\n return m && m.default || m;\n};\n\nvar Layout;\n\ntry {\n Layout = preferDefault(require(GATSBY_LAYOUT_COMPONENT_PATH));\n} catch (e) {\n if (e.toString().indexOf(\"Error: Cannot find module\") !== -1) {\n throw new Error(\"Couldn't find layout component at \\\"\" + GATSBY_LAYOUT_COMPONENT_PATH + \".\\n\\n\" + \"Please create layout component in that location or specify path to layout component in gatsby-config.js\");\n } else {\n // Logging the error for debugging older browsers as there is no way\n // to wrap the thrown error in a try/catch.\n console.error(e);\n throw e;\n }\n} // eslint-disable-next-line react/prop-types,react/display-name\n\n\nmodule.exports = function (_ref) {\n var element = _ref.element,\n props = _ref.props;\n return /*#__PURE__*/React.createElement(Layout, props, element);\n};","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nvar _gatsby = require(\"gatsby\");\n\nvar _getManifestPathname = _interopRequireDefault(require(\"./get-manifest-pathname\"));\n\n/* global __MANIFEST_PLUGIN_HAS_LOCALISATION__ */\n// when we don't have localisation in our manifest, we tree shake everything away\nif (__MANIFEST_PLUGIN_HAS_LOCALISATION__) {\n exports.onRouteUpdate = function (_ref, pluginOptions) {\n var location = _ref.location;\n var localize = pluginOptions.localize;\n var manifestFilename = (0, _getManifestPathname.default)(location.pathname, localize);\n var manifestEl = document.head.querySelector(\"link[rel=\\\"manifest\\\"]\");\n\n if (manifestEl) {\n manifestEl.setAttribute(\"href\", (0, _gatsby.withPrefix)(manifestFilename));\n }\n };\n}","\"use strict\";\n\nexports.__esModule = true;\nexports.default = void 0;\n\n/**\n * Get a manifest filename depending on localized pathname\n *\n * @param {string} pathname\n * @param {Array<{start_url: string, lang: string}>} localizedManifests\n * @return string\n */\nvar _default = function _default(pathname, localizedManifests) {\n var defaultFilename = \"manifest.webmanifest\";\n\n if (!Array.isArray(localizedManifests)) {\n return defaultFilename;\n }\n\n var localizedManifest = localizedManifests.find(function (app) {\n return pathname.startsWith(app.start_url);\n });\n\n if (!localizedManifest) {\n return defaultFilename;\n }\n\n return \"manifest_\" + localizedManifest.lang + \".webmanifest\";\n};\n\nexports.default = _default;","//* This file is a basic reverse engineer of a minified file from Cloudcannon:\n// https://github.com/envris/booderee/blob/e4b2d3ee4858fa1c2730f3431ef31c661eea5ef0/_includes/shared/head/inline-header-js.html\n// The source version is nowhere to be found.\n// It handles adding classes to the html element based on media queries and font loading.\n\nexport default !(function (global) {\n function loadModule(moduleId) {\n if (moduleCache[moduleId]) {\n return moduleCache[moduleId].exports;\n }\n\n let module = {\n exports: {},\n id: moduleId,\n loaded: false,\n };\n\n moduleCache[moduleId] = module;\n return (\n global[moduleId].call(module.exports, module, module.exports, loadModule),\n (module.loaded = true),\n module.exports\n );\n }\n\n let moduleCache = {};\n\n loadModule(0);\n})({\n 0: function (module, exports, loadModule) {\n loadModule(44);\n },\n 36: function (module, exports) {\n (function (global, document) {\n 'use strict';\n\n var metaQuery = {\n breakpoints: {},\n _isTicking: false,\n _debounceLastTime: 0,\n _namedEvents: {},\n _eventMatchCache: {},\n _globalEvents: [],\n\n onBreakpointChange: function () {\n let args = Array.prototype.slice.call(arguments),\n callback = args.pop(),\n breakpointName = args.pop();\n\n if (typeof breakpointName === 'undefined') {\n // @ts-ignore\n metaQuery._globalEvents.push(callback);\n } else {\n metaQuery._namedEvents[breakpointName] = [];\n metaQuery._namedEvents[breakpointName].push(callback);\n }\n\n updateViewport();\n },\n };\n\n function waitForReadyState(callback) {\n if (/in/.test(document.readyState)) {\n setTimeout(function () {\n waitForReadyState(callback);\n }, 9);\n } else {\n callback();\n }\n }\n\n function removeClass(element, className) {\n let classes = element.className.split(' ');\n let index = classes.indexOf(className);\n if (index > -1) {\n classes.splice(index, 1);\n element.className = classes.join(' ');\n }\n }\n\n function addClass(element, className) {\n if (element.className.indexOf(className) === -1) {\n element.className =\n element.className !== '' ? element.className + ' ' + className : className;\n }\n }\n\n function updateViewportClass(isMatch, breakpointName) {\n let className = 'breakpoint-' + breakpointName;\n let htmlElement = document.documentElement;\n\n isMatch ? addClass(htmlElement, className) : removeClass(htmlElement, className);\n }\n\n function triggerGlobalEvents(matchedBreakpoints) {\n metaQuery._globalEvents.forEach(function (eventCallback) {\n if (typeof eventCallback === 'function') {\n // @ts-ignore\n eventCallback(matchedBreakpoints);\n }\n });\n }\n\n function updateViewport() {\n metaQuery._isTicking || requestAnimationFrame(debounceUpdate);\n metaQuery._isTicking = true;\n }\n\n function debounceUpdate() {\n metaQuery._isTicking = false;\n let matchedBreakpoints = [];\n\n for (let breakpointName in metaQuery.breakpoints) {\n let mediaQuery = metaQuery.breakpoints[breakpointName];\n let isMatch = matchMedia(mediaQuery).matches;\n\n if (\n metaQuery._namedEvents[breakpointName] &&\n metaQuery._eventMatchCache[breakpointName] !== isMatch\n ) {\n metaQuery._eventMatchCache[breakpointName] = isMatch;\n\n metaQuery._namedEvents[breakpointName].forEach(function (eventCallback) {\n if (typeof eventCallback === 'function') {\n eventCallback(isMatch);\n }\n });\n }\n\n isMatch && matchedBreakpoints.push(breakpointName);\n updateViewportClass(isMatch, breakpointName);\n }\n\n if (matchedBreakpoints.length > 0) {\n triggerGlobalEvents(matchedBreakpoints);\n }\n }\n\n function parseMetaTags() {\n let metaTags = document.getElementsByTagName('meta');\n\n for (let i = 0; i < metaTags.length; i++) {\n if (metaTags[i].name === 'breakpoint') {\n let breakpointName = metaTags[i].getAttribute('content');\n let mediaQuery = metaTags[i].getAttribute('data-breakpoint');\n metaQuery.breakpoints[breakpointName] = mediaQuery;\n }\n }\n }\n\n function initialize() {\n parseMetaTags();\n updateViewport();\n }\n\n function initializeAndListen() {\n parseMetaTags();\n updateViewport();\n global.addEventListener('resize', updateViewport);\n }\n\n // @ts-ignore\n global.metaQuery = metaQuery;\n\n if (typeof exports !== 'undefined') {\n exports = metaQuery;\n }\n\n initialize();\n waitForReadyState(initializeAndListen);\n })(window, document);\n },\n 42: function (module, exports) {\n function checkFontLoading() {\n if (window.localStorage.getItem('fontsLoaded')) {\n document.documentElement.className += ' fonts-loaded';\n }\n }\n\n module.exports = checkFontLoading;\n },\n 43: function (module, exports, loadModule) {\n loadModule(36);\n let checkFontLoading = loadModule(42);\n checkFontLoading();\n },\n 44: function (module, exports, loadModule) {\n loadModule(43);\n },\n});\n","/**\n * Implement Gatsby's Browser APIs in this file.\n *\n * See: https://www.gatsbyjs.com/docs/browser-apis/\n */\n\nfunction closeMenu() {\n let qs = document.querySelector(\n '.navigation-dropdown__item > button.navigation-dropdown__anchor.mobile-nav-active'\n );\n if (qs) {\n let openChildren = document.querySelectorAll(\n '.navigation-dropdown__item > button.navigation-dropdown__anchor.navigation-dropdown__anchor--active'\n );\n // Prevent menu reopening with previously exposed items\n openChildren.forEach((child) => {\n child.classList.remove('navigation-dropdown__anchor--active');\n child.nextElementSibling.classList.remove('navigation-dropdown__panel--active');\n });\n qs.click();\n }\n}\n\nexports.onInitialClientRender = () => {\n const assessBreakpoints = require('./breakpoint-events.js');\n\n // console.log(\"ReactDOM.render has executed\")\n window.dispatchEvent(new Event('resize'));\n document.addEventListener('keyup', function (event) {\n if (event.key === 'Escape') {\n // console.log('escape pressed')\n closeMenu();\n }\n });\n document.body.addEventListener(\n 'click',\n function (x) {\n let p = [...x.target.parentNode.classList].concat(Array.from(x.target.classList));\n if (p.includes('navigation-dropdown__anchor') || p.includes('navigation-dropdown__item')) {\n return;\n }\n closeMenu();\n },\n true\n );\n};\nexports.onRouteUpdate = ({ location, prevLocation }) => {\n closeMenu();\n window.dispatchEvent(new Event('resize'));\n};\nexports.onClientEntry = () => {\n // console.log(\"------ onClientEntry\")\n // callAnalyticsAPI()\n};\n","// Logic for rebuilding Drupal menus for Gatsby\nimport {\n stripUrlEntityPrefix,\n stripUrlParkPrefix,\n isInputDataFormatCorrect,\n getParkNames,\n convertTrueFalseStringToBoolean,\n testEnv,\n} from '../common';\n\nconst env = testEnv();\n\n//* Generate the menu trail of the current page back to the top level of the menu\n// Used for creating breadcrumb trails\n// - allMenuData: an object containing the menu items\n// - nodeID: the Drupal ID of the current page, as a number\n// - url: the URL of the current page, as a string\n// - nodeType: optional, the Drupal bundle of the current page, as a string\n// - nodeTitle: optional, the title of the current page, as a string. This can be\n// useful if you want to expose the full title rather thana short\n// version that may be used in the menu\n\nexport const createPageParentTrail = (allMenuData, nodeID, url, nodeType, nodeTitle) => {\n if (!allMenuData || !nodeID) {\n console.error(\n `[ERROR - Menus]: No menu data or Node ID provided to createPageParentTrail(), quitting...`\n );\n return;\n } else if (\n !isInputDataFormatCorrect(nodeID, 'number', 'createPageParentTrail') ||\n !isInputDataFormatCorrect(allMenuData, 'object', 'createPageParentTrail')\n ) {\n return;\n }\n if (typeof url !== undefined) {\n if (!isInputDataFormatCorrect(url, 'string', 'createPageParentTrail')) {\n return;\n }\n }\n\n // Find the current page in the menu data and set a new object to\n // hold the parent structure\n let parentLevel = 0,\n parentMenuTrail = [],\n parkHomeLink = getParkNames().fullName;\n\n // For page-like content with no menu positions (e.g. news articles),\n // we hardcode the menu trail\n if (\n nodeType !== undefined &&\n nodeType === 'news_article' &&\n nodeTitle !== undefined &&\n typeof nodeTitle === 'string'\n ) {\n // Add the current page\n parentMenuTrail.push({\n crumbLevel: parentLevel,\n node: {\n title: nodeTitle,\n link: {\n uri_alias: url,\n },\n },\n });\n // Add a hard link to the parent page\n parentMenuTrail.push({\n crumbLevel: parentLevel + 1,\n node: {\n title: 'News',\n link: {\n uri_alias: '/news/',\n },\n },\n });\n } else {\n // For all other pages with menu positions, loop through the menu data\n\n for (let i = 0; i < allMenuData.length; i++) {\n // Prioritise URL aliases, then fall back to the URI for external links\n const thisPagePath =\n stripUrlParkPrefix(stripUrlEntityPrefix(allMenuData[i].node.link?.uri_alias)) ||\n stripUrlParkPrefix(stripUrlEntityPrefix(allMenuData[i].node.link.uri)) ||\n null;\n let parentMenuItemId;\n\n if (!thisPagePath) {\n console.warn(\n `[ISSUE - Menus]: No URL alias found for menu item '${allMenuData[i].node.title}', so it will not be added to the breadcrumbs`\n );\n } else if (thisPagePath !== null && thisPagePath === url) {\n // Start tracking the parent levels in the menu hierarchy, noting\n // we zero-index the count, and go from 0+. We don't assume how\n // many parents an item may have. Life can be complicated and that's ok :)\n allMenuData[i].crumbLevel = parentLevel;\n parentMenuTrail.push(allMenuData[i]);\n parentLevel++;\n\n // Handle top level items that have no parents, like Batman. He's an Apex Item, if anything\n allMenuData[i].node.drupal_parent_menu_item !== null\n ? (parentMenuItemId = allMenuData[i].node.drupal_parent_menu_item.split(':')[1])\n : (parentMenuItemId = null);\n\n // Start searching for the parents of the current page\n findParents(allMenuData, parentMenuItemId);\n break;\n }\n }\n\n // Search each parent to build up the menu trail back to the top level\n function findParents(menuData, id) {\n menuData.forEach((item) => {\n if (item.node.drupal_id === id) {\n item.crumbLevel = parentLevel;\n // If the parent is found AND enabled, add it to the parentMenuTrail object\n // This allows breadcrumbs to function correctly when a page is nested\n // under a disabled menu item\n if (item.node.enabled) {\n parentMenuTrail.push(item);\n }\n // If this parent item also has a parent, keep searching up the tree\n if (item.node.drupal_parent_menu_item !== null) {\n parentLevel++;\n findParents(allMenuData, item.node.drupal_parent_menu_item.split(':')[1]);\n }\n }\n });\n }\n }\n // Add the home link manually - simpler than retrieving and tweaking the data\n parentMenuTrail.push({\n crumbLevel: parentMenuTrail.length,\n node: {\n title: parkHomeLink,\n link: {\n uri_alias: '/',\n },\n },\n });\n return parentMenuTrail;\n};\n\n// Rebuild the menu structure, as Drupal's JSON API doesn't return\n// a nested menu structure: (\n// allMenuData: an object containing the menu items e.g. menuLinks.allMenuItem.edges\n// menuId: the machine name of the menu to be rebuilt, as a string\n\nexport const createMenuTree = (allMenuData, menuId) => {\n let menuTree = [],\n mappedArr = {};\n\n // First map the nodes of the array to an object -> create a hash table.\n\n if (!allMenuData || !menuId) {\n console.error('[ERROR - Menus]: Missing arguments for createMenuTree()');\n return;\n } else if (typeof allMenuData !== 'object') {\n console.error(\n \"[ERROR - Menus]: Invalid data type for 'allMenuData' in `createMenuTree()`, expected an object\"\n );\n return;\n } else if (typeof menuId !== 'string') {\n console.error(\n '[ERROR - Menus]: Invalid data type for menuId in `createMenuTree()`, expected a string'\n );\n return;\n }\n\n const createMenuTreeBranch = () => {\n let menuItems = [];\n\n // Collect all menu items only from the target menu - enabled or disabled\n // This is because if a page happens to live under a disabled parent, we\n // still want that page to have access to the correct menu tree to build a\n // breadcrumb trail that skips the disabled parent.\n for (const item in allMenuData) {\n if (allMenuData[item].node.menu_name === menuId) {\n // --- Any operations to be run over all links go here ---\n\n allMenuData[item].node.link.uri = stripUrlParkPrefix(\n stripUrlEntityPrefix(allMenuData[item].node.link.uri)\n );\n allMenuData[item].node.link.uri_alias = stripUrlParkPrefix(\n stripUrlEntityPrefix(allMenuData[item].node.link.uri_alias)\n );\n menuItems.push(allMenuData[item]);\n }\n }\n return menuItems;\n };\n\n const thisMenuBranch = createMenuTreeBranch();\n\n // Map each menu item to an array, then check if it has child items\n for (let i = 0, len = thisMenuBranch.length; i < len; i++) {\n let arrElem = thisMenuBranch[i].node;\n mappedArr[arrElem.drupal_id] = arrElem;\n\n // If an item has a parent, unlike Bruce Wayne, strip the bundle prefix from the ID\n // and add it to the mapped Array\n if (arrElem.drupal_parent_menu_item != null) {\n let stripped_drupal_id = arrElem.drupal_parent_menu_item.replace(arrElem.bundle + ':', '');\n mappedArr[arrElem.drupal_id].drupal_parent_menu_item = stripped_drupal_id;\n }\n // Set the 'children' key to be an empty array so we can populate it later as children are discovered\n mappedArr[arrElem.drupal_id]['children'] = [];\n }\n\n for (const item in mappedArr) {\n if (mappedArr.hasOwnProperty(item)) {\n let mappedElem = mappedArr[item];\n\n // If the element is not at the root level and has a parent,\n // add it to its parent's array of children.\n if (mappedElem.drupal_parent_menu_item !== null) {\n if (mappedArr[mappedElem.drupal_parent_menu_item] !== undefined) {\n mappedArr[mappedElem.drupal_parent_menu_item]['children'].push(mappedElem);\n }\n // If the parent menu item is set but does not exist in mappedArr, the item\n // lives under a disabled parent menu item and should be excluded entirely.\n } else {\n // If the element is at the root level, add it to first level elements array.\n menuTree.push(mappedElem);\n }\n }\n }\n\n // Iterate over the final menu structure to assign menu levels.\n // It would be easier if Drupal's JSON API did this before spitting out the links...\n function assignMenuLevels(menu, menu_level = 1) {\n menu.forEach((obj) => {\n obj.menu_level = menu_level;\n assignMenuLevels(obj.children, menu_level + 1);\n });\n }\n\n assignMenuLevels(menuTree);\n\n //* Render out the menu trees used on a page to the console for debugging\n if (env.devMode && convertTrueFalseStringToBoolean(process.env.DEBUG_MENUS) === true) {\n let menuChart = '';\n\n function crawlTree(menuObj) {\n for (const item in menuObj) {\n logMenu(menuObj[item]);\n if (menuObj[item].children.length > 0) {\n crawlTree(menuObj[item].children);\n }\n }\n }\n\n function logMenu(item) {\n let gap = '';\n for (let i = 0; i < parseInt(item.menu_level); i++) {\n gap += ' ';\n }\n menuChart += `${gap} Lv${item.menu_level} - ${item.title}\\n`;\n }\n\n console.log(`Menu: ${menuTree[0].menu_name}`);\n crawlTree(menuTree);\n console.log(menuChart);\n }\n\n return menuTree;\n};\n","// This file provides useful reusable functions to pull into components are required\n\n// Imports\nimport { useState, useEffect } from 'react';\nimport parkDetails from '../../_park_details.json';\nimport moment from 'moment';\nimport tz from 'moment-timezone';\n\nconst park = process.env.GATSBY_PARK,\n parkList = parkDetails[0];\n\nexport const showTestContent = process.env.INCLUDE_TEST_CONTENT === 'true';\n\n//* Faster logging for development, use with:\n// import {log as l} from '../functions/common';\n// then l(msg);\nexport const log = (message) => {\n if (message === null) {\n return;\n }\n console.log(message);\n};\n\n// A quicker console.dir()\nexport const ld = (data, depth = null) => {\n console.dir(data, { depth: depth });\n};\n\n//* Test input types and handle errors\n// NOTE: Doesn't work comparing NaN to NaN\n// Must also be used below any conditional React Hooks e.g. const isSsr = useIsSsr();\n//\n// input: the data to test\n// expectedInputType: the expected data type, as a string\n// funcName: optional, the name of the function calling this as a string, for easier debugging\n//\n// Usage:\n// isInputDataFormatCorrect(str, 'string') --> returns true\n// isInputDataFormatCorrect(str, 'object') --> returns false\n//\nexport const isInputDataFormatCorrect = (input, expectedInputType, funcName) => {\n let message = `Expected a '${expectedInputType}' value, '${typeof input}' found instead${\n funcName !== undefined ? `in ${funcName}.` : '.'\n }.`;\n if (typeof input !== expectedInputType) {\n console.warn(`[ISSUE - Scripts]: ${message}`);\n return false;\n } else {\n return true;\n }\n};\n\n//* React Hooks\n\n//* Check if a value exists in an object's keys\nexport const isStringInObjectKeys = (obj, str) => {\n return obj[str] !== undefined;\n};\n\n//* Check if value appears in an object's values\nexport const isStringInObjectValues = (obj, str) => {\n let match = false;\n for (let key in obj) {\n obj[key] === str ? (match = true) : (match = false);\n if (match === true) {\n return match;\n }\n }\n return match;\n};\n\n//* Delete the first instance of a target item from an object or array, if it exists\nexport const deleteItemFromArray = (arr, itemToDelete) => {\n const index = arr.indexOf(itemToDelete);\n if (index !== -1) {\n arr.splice(index, 1);\n }\n return arr;\n};\n\n//* Detect Server-side Rendering (SSR)\n// Credit to Stephen Cook - https://stephencook.dev/blog/using-window-in-react-ssr/\nexport const useIsSsr = () => {\n // We always start in \"SSR mode\", to ensure our initial browser render matches the SSR render\n const [isSsr, setIsSsr] = useState(true);\n\n useEffect(() => {\n // `useEffect` never runs on the server, so we must be on the client if we hit this block\n setIsSsr(false);\n }, []);\n\n return isSsr;\n};\n\n//* Insert