{"ast":null,"code":"/**\n * Copyright (c) 2015-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';\n\nvar _slicedToArray = require(\"/Users/paolasanchez/Desktop/Pry4/Katoikia/katoikia-app/web-ui/sakai-react/node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/slicedToArray\");\n\nvar chalk = require('chalk');\n\nvar friendlySyntaxErrorLabel = 'Syntax error:';\n\nfunction isLikelyASyntaxError(message) {\n return message.indexOf(friendlySyntaxErrorLabel) !== -1;\n} // Cleans up webpack error messages.\n\n\nfunction formatMessage(message) {\n var lines = message.split('\\n'); // Strip webpack-added headers off errors/warnings\n // https://github.com/webpack/webpack/blob/master/lib/ModuleError.js\n\n lines = lines.filter(function (line) {\n return !/Module [A-z ]+\\(from/.test(line);\n }); // Transform parsing error into syntax error\n // TODO: move this to our ESLint formatter?\n\n lines = lines.map(function (line) {\n var parsingError = /Line (\\d+):(?:(\\d+):)?\\s*Parsing error: (.+)$/.exec(line);\n\n if (!parsingError) {\n return line;\n }\n\n var _parsingError = _slicedToArray(parsingError, 4),\n errorLine = _parsingError[1],\n errorColumn = _parsingError[2],\n errorMessage = _parsingError[3];\n\n return \"\".concat(friendlySyntaxErrorLabel, \" \").concat(errorMessage, \" (\").concat(errorLine, \":\").concat(errorColumn, \")\");\n });\n message = lines.join('\\n'); // Smoosh syntax errors (commonly found in CSS)\n\n message = message.replace(/SyntaxError\\s+\\((\\d+):(\\d+)\\)\\s*(.+?)\\n/g, \"\".concat(friendlySyntaxErrorLabel, \" $3 ($1:$2)\\n\")); // Clean up export errors\n\n message = message.replace(/^.*export '(.+?)' was not found in '(.+?)'.*$/gm, \"Attempted import error: '$1' is not exported from '$2'.\");\n message = message.replace(/^.*export 'default' \\(imported as '(.+?)'\\) was not found in '(.+?)'.*$/gm, \"Attempted import error: '$2' does not contain a default export (imported as '$1').\");\n message = message.replace(/^.*export '(.+?)' \\(imported as '(.+?)'\\) was not found in '(.+?)'.*$/gm, \"Attempted import error: '$1' is not exported from '$3' (imported as '$2').\");\n lines = message.split('\\n'); // Remove leading newline\n\n if (lines.length > 2 && lines[1].trim() === '') {\n lines.splice(1, 1);\n } // Clean up file name\n\n\n lines[0] = lines[0].replace(/^(.*) \\d+:\\d+-\\d+$/, '$1'); // Cleans up verbose \"module not found\" messages for files and packages.\n\n if (lines[1] && lines[1].indexOf('Module not found: ') === 0) {\n lines = [lines[0], lines[1].replace('Error: ', '').replace('Module not found: Cannot find file:', 'Cannot find file:')];\n } // Add helpful message for users trying to use Sass for the first time\n\n\n if (lines[1] && lines[1].match(/Cannot find module.+node-sass/)) {\n lines[1] = 'To import Sass files, you first need to install node-sass.\\n';\n lines[1] += 'Run `npm install node-sass` or `yarn add node-sass` inside your workspace.';\n }\n\n lines[0] = chalk.inverse(lines[0]);\n message = lines.join('\\n'); // Internal stacks are generally useless so we strip them... with the\n // exception of stacks containing `webpack:` because they're normally\n // from user code generated by webpack. For more information see\n // https://github.com/facebook/create-react-app/pull/1050\n\n message = message.replace(/^\\s*at\\s((?!webpack:).)*:\\d+:\\d+[\\s)]*(\\n|$)/gm, ''); // at ... ...:x:y\n\n message = message.replace(/^\\s*at\\s(\\n|$)/gm, ''); // at \n\n lines = message.split('\\n'); // Remove duplicated newlines\n\n lines = lines.filter(function (line, index, arr) {\n return index === 0 || line.trim() !== '' || line.trim() !== arr[index - 1].trim();\n }); // Reassemble the message\n\n message = lines.join('\\n');\n return message.trim();\n}\n\nfunction formatWebpackMessages(json) {\n var formattedErrors = json.errors.map(function (message) {\n return formatMessage(message, true);\n });\n var formattedWarnings = json.warnings.map(function (message) {\n return formatMessage(message, false);\n });\n var result = {\n errors: formattedErrors,\n warnings: formattedWarnings\n };\n\n if (result.errors.some(isLikelyASyntaxError)) {\n // If there are any syntax errors, show just them.\n result.errors = result.errors.filter(isLikelyASyntaxError);\n }\n\n return result;\n}\n\nmodule.exports = formatWebpackMessages;","map":{"version":3,"names":["chalk","require","friendlySyntaxErrorLabel","isLikelyASyntaxError","message","indexOf","formatMessage","lines","split","filter","line","test","map","parsingError","exec","errorLine","errorColumn","errorMessage","join","replace","length","trim","splice","match","inverse","index","arr","formatWebpackMessages","json","formattedErrors","errors","formattedWarnings","warnings","result","some","module","exports"],"sources":["/Users/paolasanchez/Desktop/Pry4/Katoikia/katoikia-app/web-ui/sakai-react/node_modules/react-dev-utils/formatWebpackMessages.js"],"sourcesContent":["/**\n * Copyright (c) 2015-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nconst chalk = require('chalk');\nconst friendlySyntaxErrorLabel = 'Syntax error:';\n\nfunction isLikelyASyntaxError(message) {\n return message.indexOf(friendlySyntaxErrorLabel) !== -1;\n}\n\n// Cleans up webpack error messages.\nfunction formatMessage(message) {\n let lines = message.split('\\n');\n\n // Strip webpack-added headers off errors/warnings\n // https://github.com/webpack/webpack/blob/master/lib/ModuleError.js\n lines = lines.filter(line => !/Module [A-z ]+\\(from/.test(line));\n\n // Transform parsing error into syntax error\n // TODO: move this to our ESLint formatter?\n lines = lines.map(line => {\n const parsingError = /Line (\\d+):(?:(\\d+):)?\\s*Parsing error: (.+)$/.exec(\n line\n );\n if (!parsingError) {\n return line;\n }\n const [, errorLine, errorColumn, errorMessage] = parsingError;\n return `${friendlySyntaxErrorLabel} ${errorMessage} (${errorLine}:${errorColumn})`;\n });\n\n message = lines.join('\\n');\n // Smoosh syntax errors (commonly found in CSS)\n message = message.replace(\n /SyntaxError\\s+\\((\\d+):(\\d+)\\)\\s*(.+?)\\n/g,\n `${friendlySyntaxErrorLabel} $3 ($1:$2)\\n`\n );\n // Clean up export errors\n message = message.replace(\n /^.*export '(.+?)' was not found in '(.+?)'.*$/gm,\n `Attempted import error: '$1' is not exported from '$2'.`\n );\n message = message.replace(\n /^.*export 'default' \\(imported as '(.+?)'\\) was not found in '(.+?)'.*$/gm,\n `Attempted import error: '$2' does not contain a default export (imported as '$1').`\n );\n message = message.replace(\n /^.*export '(.+?)' \\(imported as '(.+?)'\\) was not found in '(.+?)'.*$/gm,\n `Attempted import error: '$1' is not exported from '$3' (imported as '$2').`\n );\n lines = message.split('\\n');\n\n // Remove leading newline\n if (lines.length > 2 && lines[1].trim() === '') {\n lines.splice(1, 1);\n }\n // Clean up file name\n lines[0] = lines[0].replace(/^(.*) \\d+:\\d+-\\d+$/, '$1');\n\n // Cleans up verbose \"module not found\" messages for files and packages.\n if (lines[1] && lines[1].indexOf('Module not found: ') === 0) {\n lines = [\n lines[0],\n lines[1]\n .replace('Error: ', '')\n .replace('Module not found: Cannot find file:', 'Cannot find file:'),\n ];\n }\n\n // Add helpful message for users trying to use Sass for the first time\n if (lines[1] && lines[1].match(/Cannot find module.+node-sass/)) {\n lines[1] = 'To import Sass files, you first need to install node-sass.\\n';\n lines[1] +=\n 'Run `npm install node-sass` or `yarn add node-sass` inside your workspace.';\n }\n\n lines[0] = chalk.inverse(lines[0]);\n\n message = lines.join('\\n');\n // Internal stacks are generally useless so we strip them... with the\n // exception of stacks containing `webpack:` because they're normally\n // from user code generated by webpack. For more information see\n // https://github.com/facebook/create-react-app/pull/1050\n message = message.replace(\n /^\\s*at\\s((?!webpack:).)*:\\d+:\\d+[\\s)]*(\\n|$)/gm,\n ''\n ); // at ... ...:x:y\n message = message.replace(/^\\s*at\\s(\\n|$)/gm, ''); // at \n lines = message.split('\\n');\n\n // Remove duplicated newlines\n lines = lines.filter(\n (line, index, arr) =>\n index === 0 || line.trim() !== '' || line.trim() !== arr[index - 1].trim()\n );\n\n // Reassemble the message\n message = lines.join('\\n');\n return message.trim();\n}\n\nfunction formatWebpackMessages(json) {\n const formattedErrors = json.errors.map(function(message) {\n return formatMessage(message, true);\n });\n const formattedWarnings = json.warnings.map(function(message) {\n return formatMessage(message, false);\n });\n const result = { errors: formattedErrors, warnings: formattedWarnings };\n if (result.errors.some(isLikelyASyntaxError)) {\n // If there are any syntax errors, show just them.\n result.errors = result.errors.filter(isLikelyASyntaxError);\n }\n return result;\n}\n\nmodule.exports = formatWebpackMessages;\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AAEA;;;;AAEA,IAAMA,KAAK,GAAGC,OAAO,CAAC,OAAD,CAArB;;AACA,IAAMC,wBAAwB,GAAG,eAAjC;;AAEA,SAASC,oBAAT,CAA8BC,OAA9B,EAAuC;EACrC,OAAOA,OAAO,CAACC,OAAR,CAAgBH,wBAAhB,MAA8C,CAAC,CAAtD;AACD,C,CAED;;;AACA,SAASI,aAAT,CAAuBF,OAAvB,EAAgC;EAC9B,IAAIG,KAAK,GAAGH,OAAO,CAACI,KAAR,CAAc,IAAd,CAAZ,CAD8B,CAG9B;EACA;;EACAD,KAAK,GAAGA,KAAK,CAACE,MAAN,CAAa,UAAAC,IAAI;IAAA,OAAI,CAAC,uBAAuBC,IAAvB,CAA4BD,IAA5B,CAAL;EAAA,CAAjB,CAAR,CAL8B,CAO9B;EACA;;EACAH,KAAK,GAAGA,KAAK,CAACK,GAAN,CAAU,UAAAF,IAAI,EAAI;IACxB,IAAMG,YAAY,GAAG,gDAAgDC,IAAhD,CACnBJ,IADmB,CAArB;;IAGA,IAAI,CAACG,YAAL,EAAmB;MACjB,OAAOH,IAAP;IACD;;IACD,mCAAiDG,YAAjD;IAAA,IAASE,SAAT;IAAA,IAAoBC,WAApB;IAAA,IAAiCC,YAAjC;;IACA,iBAAUf,wBAAV,cAAsCe,YAAtC,eAAuDF,SAAvD,cAAoEC,WAApE;EACD,CATO,CAAR;EAWAZ,OAAO,GAAGG,KAAK,CAACW,IAAN,CAAW,IAAX,CAAV,CApB8B,CAqB9B;;EACAd,OAAO,GAAGA,OAAO,CAACe,OAAR,CACR,0CADQ,YAELjB,wBAFK,mBAAV,CAtB8B,CA0B9B;;EACAE,OAAO,GAAGA,OAAO,CAACe,OAAR,CACR,iDADQ,4DAAV;EAIAf,OAAO,GAAGA,OAAO,CAACe,OAAR,CACR,2EADQ,uFA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