{"version":3,"sources":["node_modules\\react-dom\\lib\\escapeTextContentForBrowser.js"],"names":["matchHtmlRegExp","escapeHtml","string","str","match","exec","escape","html","index","lastIndex","length","charCodeAt","substring","escapeTextContentForBrowser","text","module","exports"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAmCA;;;;;;;;AAQA,GAAIA,iBAAkB,SAAtB;;;;;;;;;;AAUA,QAASC,WAAT,CAAoBC,MAApB,CAA4B;AAC1B,GAAIC,KAAM,GAAKD,MAAf;AACA,GAAIE,OAAQJ,gBAAgBK,IAAhB,CAAqBF,GAArB,CAAZ;;AAEA,GAAI,CAACC,KAAL,CAAY;AACV,MAAOD,IAAP;AACD;;AAED,GAAIG,OAAJ;AACA,GAAIC,MAAO,EAAX;AACA,GAAIC,OAAQ,CAAZ;AACA,GAAIC,WAAY,CAAhB;;AAEA,IAAKD,MAAQJ,MAAMI,KAAnB,CAA0BA,MAAQL,IAAIO,MAAtC,CAA8CF,OAA9C,CAAuD;AACrD,OAAQL,IAAIQ,UAAJ,CAAeH,KAAf,CAAR;AACE,IAAK,GAAL;;AAEEF,OAAS,QAAT;AACA;AACF,IAAK,GAAL;;AAEEA,OAAS,OAAT;AACA;AACF,IAAK,GAAL;;AAEEA,OAAS,QAAT;AACA;AACF,IAAK,GAAL;;AAEEA,OAAS,MAAT;AACA;AACF,IAAK,GAAL;;AAEEA,OAAS,MAAT;AACA;AACF;AACE,SAtBJ;;;AAyBA,GAAIG,YAAcD,KAAlB,CAAyB;AACvBD,MAAQJ,IAAIS,SAAJ,CAAcH,SAAd,CAAyBD,KAAzB,CAAR;AACD;;AAEDC,UAAYD,MAAQ,CAApB;AACAD,MAAQD,MAAR;AACD;;AAED,MAAOG,aAAcD,KAAd,CAAsBD,KAAOJ,IAAIS,SAAJ,CAAcH,SAAd,CAAyBD,KAAzB,CAA7B,CAA+DD,IAAtE;AACD;;;;;;;;;AASD,QAASM,4BAAT,CAAqCC,IAArC,CAA2C;AACzC,GAAI,MAAOA,KAAP,GAAgB,SAAhB,EAA6B,MAAOA,KAAP,GAAgB,QAAjD,CAA2D;;;;AAIzD,MAAO,GAAKA,IAAZ;AACD;AACD,MAAOb,YAAWa,IAAX,CAAP;AACD;;AAEDC,OAAOC,OAAP,CAAiBH,2BAAjB","file":"escapeTextContentForBrowser.js","sourceRoot":"d:/Work/Office/react-native-on-web/cli/tmpl/project","sourcesContent":["/**\n * Copyright 2016-present, Facebook, Inc.\n * All rights reserved.\n *\n * This source code is licensed under the BSD-style license found in the\n * LICENSE file in the root directory of this source tree. An additional grant\n * of patent rights can be found in the PATENTS file in the same directory.\n *\n * Based on the escape-html library, which is used under the MIT License below:\n *\n * Copyright (c) 2012-2013 TJ Holowaychuk\n * Copyright (c) 2015 Andreas Lubbe\n * Copyright (c) 2015 Tiancheng \"Timothy\" Gu\n *\n * Permission is hereby granted, free of charge, to any person obtaining\n * a copy of this software and associated documentation files (the\n * 'Software'), to deal in the Software without restriction, including\n * without limitation the rights to use, copy, modify, merge, publish,\n * distribute, sublicense, and/or sell copies of the Software, and to\n * permit persons to whom the Software is furnished to do so, subject to\n * the following conditions:\n *\n * The above copyright notice and this permission notice shall be\n * included in all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,\n * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\n * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.\n * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY\n * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,\n * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE\n * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n *\n */\n\n'use strict';\n\n// code copied and modified from escape-html\n/**\n * Module variables.\n * @private\n */\n\nvar matchHtmlRegExp = /[\"'&<>]/;\n\n/**\n * Escape special characters in the given string of html.\n *\n * @param  {string} string The string to escape for inserting into HTML\n * @return {string}\n * @public\n */\n\nfunction escapeHtml(string) {\n  var str = '' + string;\n  var match = matchHtmlRegExp.exec(str);\n\n  if (!match) {\n    return str;\n  }\n\n  var escape;\n  var html = '';\n  var index = 0;\n  var lastIndex = 0;\n\n  for (index = match.index; index < str.length; index++) {\n    switch (str.charCodeAt(index)) {\n      case 34:\n        // \"\n        escape = '&quot;';\n        break;\n      case 38:\n        // &\n        escape = '&amp;';\n        break;\n      case 39:\n        // '\n        escape = '&#x27;'; // modified from escape-html; used to be '&#39'\n        break;\n      case 60:\n        // <\n        escape = '&lt;';\n        break;\n      case 62:\n        // >\n        escape = '&gt;';\n        break;\n      default:\n        continue;\n    }\n\n    if (lastIndex !== index) {\n      html += str.substring(lastIndex, index);\n    }\n\n    lastIndex = index + 1;\n    html += escape;\n  }\n\n  return lastIndex !== index ? html + str.substring(lastIndex, index) : html;\n}\n// end code copied and modified from escape-html\n\n/**\n * Escapes text to prevent scripting attacks.\n *\n * @param {*} text Text value to escape.\n * @return {string} An escaped string.\n */\nfunction escapeTextContentForBrowser(text) {\n  if (typeof text === 'boolean' || typeof text === 'number') {\n    // this shortcircuit helps perf for types that we know will never have\n    // special characters, especially given that this function is used often\n    // for numeric dom ids.\n    return '' + text;\n  }\n  return escapeHtml(text);\n}\n\nmodule.exports = escapeTextContentForBrowser;"]}