Software zum Installieren eines Smart-Mirror Frameworks , zum Nutzen von hochschulrelevanten Informationen, auf einem Raspberry-Pi.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

parser.js 55KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585
  1. "use strict";
  2. var postcss = require('postcss');
  3. var gonzales = require('gonzales-pe');
  4. var DEFAULT_RAWS_ROOT = {
  5. before: ''
  6. };
  7. var DEFAULT_RAWS_RULE = {
  8. before: '',
  9. between: ''
  10. };
  11. var DEFAULT_RAWS_DECL = {
  12. before: '',
  13. between: '',
  14. semicolon: false
  15. };
  16. var DEFAULT_COMMENT_DECL = {
  17. before: ''
  18. };
  19. var SUPPORTED_AT_KEYWORDS = ['media'];
  20. var SassParser =
  21. /*#__PURE__*/
  22. function () {
  23. function SassParser(input) {
  24. this.input = input;
  25. }
  26. var _proto = SassParser.prototype;
  27. _proto.parse = function parse() {
  28. try {
  29. this.node = gonzales.parse(this.input.css, {
  30. syntax: 'sass'
  31. });
  32. } catch (error) {
  33. throw this.input.error(error.message, error.line, 1);
  34. }
  35. this.lines = this.input.css.match(/^.*(\r?\n|$)/gm);
  36. this.root = this.stylesheet(this.node);
  37. };
  38. _proto.extractSource = function extractSource(start, end) {
  39. var nodeLines = this.lines.slice(start.line - 1, end.line);
  40. nodeLines[0] = nodeLines[0].substring(start.column - 1);
  41. var last = nodeLines.length - 1;
  42. nodeLines[last] = nodeLines[last].substring(0, end.column);
  43. return nodeLines.join('');
  44. };
  45. _proto.stylesheet = function stylesheet(node) {
  46. var _this = this;
  47. // Create and set parameters for Root node
  48. var root = postcss.root();
  49. root.source = {
  50. start: node.start,
  51. end: node.end,
  52. input: this.input // Raws for root node
  53. };
  54. root.raws = {
  55. semicolon: DEFAULT_RAWS_ROOT.semicolon,
  56. before: DEFAULT_RAWS_ROOT.before // Store spaces before root (if exist)
  57. };
  58. this.raws = {
  59. before: ''
  60. };
  61. node.content.forEach(function (contentNode) {
  62. return _this.process(contentNode, root);
  63. });
  64. return root;
  65. };
  66. _proto.process = function process(node, parent) {
  67. if (this[node.type]) return this[node.type](node, parent) || null;
  68. return null;
  69. };
  70. _proto.ruleset = function ruleset(node, parent) {
  71. var _this2 = this;
  72. // Loop to find the deepest ruleset node
  73. this.raws.multiRuleProp = '';
  74. node.content.forEach(function (contentNode) {
  75. switch (contentNode.type) {
  76. case 'block':
  77. {
  78. // Create Rule node
  79. var rule = postcss.rule();
  80. rule.selector = ''; // Object to store raws for Rule
  81. var ruleRaws = {
  82. before: _this2.raws.before || DEFAULT_RAWS_RULE.before,
  83. between: DEFAULT_RAWS_RULE.between // Variable to store spaces and symbols before declaration property
  84. };
  85. _this2.raws.before = '';
  86. _this2.raws.comment = false; // Look up throw all nodes in current ruleset node
  87. node.content.filter(function (content) {
  88. return content.type === 'block';
  89. }).forEach(function (innerContentNode) {
  90. return _this2.process(innerContentNode, rule);
  91. });
  92. if (rule.nodes.length) {
  93. // Write selector to Rule
  94. rule.selector = _this2.extractSource(node.start, contentNode.start).slice(0, -1).replace(/\s+$/, function (spaces) {
  95. ruleRaws.between = spaces;
  96. return '';
  97. }); // Set parameters for Rule node
  98. rule.parent = parent;
  99. rule.source = {
  100. start: node.start,
  101. end: node.end,
  102. input: _this2.input
  103. };
  104. rule.raws = ruleRaws;
  105. parent.nodes.push(rule);
  106. }
  107. break;
  108. }
  109. default:
  110. }
  111. });
  112. };
  113. _proto.block = function block(node, parent) {
  114. var _this3 = this;
  115. // If nested rules exist, wrap current rule in new rule node
  116. if (this.raws.multiRule) {
  117. if (this.raws.multiRulePropVariable) {
  118. this.raws.multiRuleProp = "$" + this.raws.multiRuleProp;
  119. }
  120. var multiRule = Object.assign(postcss.rule(), {
  121. source: {
  122. start: {
  123. line: node.start.line - 1,
  124. column: node.start.column
  125. },
  126. end: node.end,
  127. input: this.input
  128. },
  129. raws: {
  130. before: this.raws.before || DEFAULT_RAWS_RULE.before,
  131. between: DEFAULT_RAWS_RULE.between
  132. },
  133. parent: parent,
  134. selector: (this.raws.customProperty ? '--' : '') + this.raws.multiRuleProp
  135. });
  136. parent.push(multiRule);
  137. parent = multiRule;
  138. }
  139. this.raws.before = ''; // Looking for declaration node in block node
  140. node.content.forEach(function (contentNode) {
  141. return _this3.process(contentNode, parent);
  142. });
  143. if (this.raws.multiRule) {
  144. this.raws.beforeMulti = this.raws.before;
  145. }
  146. };
  147. _proto.declaration = function declaration(node, parent) {
  148. var _this4 = this;
  149. var isBlockInside = false; // Create Declaration node
  150. var declarationNode = postcss.decl();
  151. declarationNode.prop = ''; // Object to store raws for Declaration
  152. var declarationRaws = Object.assign(declarationNode.raws, {
  153. before: this.raws.before || DEFAULT_RAWS_DECL.before,
  154. between: DEFAULT_RAWS_DECL.between,
  155. semicolon: DEFAULT_RAWS_DECL.semicolon
  156. });
  157. this.raws.property = false;
  158. this.raws.betweenBefore = false;
  159. this.raws.comment = false; // Looking for property and value node in declaration node
  160. node.content.forEach(function (contentNode) {
  161. switch (contentNode.type) {
  162. case 'customProperty':
  163. _this4.raws.customProperty = true;
  164. // fall through
  165. case 'property':
  166. {
  167. /* this.raws.property to detect is property is already defined in current object */
  168. _this4.raws.property = true;
  169. _this4.raws.multiRuleProp = contentNode.content[0].content;
  170. _this4.raws.multiRulePropVariable = contentNode.content[0].type === 'variable';
  171. _this4.process(contentNode, declarationNode);
  172. break;
  173. }
  174. case 'propertyDelimiter':
  175. {
  176. if (_this4.raws.property && !_this4.raws.betweenBefore) {
  177. /* If property is already defined and there's no ':' before it */
  178. declarationRaws.between += contentNode.content;
  179. _this4.raws.multiRuleProp += contentNode.content;
  180. } else {
  181. /* If ':' goes before property declaration, like :width 100px */
  182. _this4.raws.betweenBefore = true;
  183. declarationRaws.before += contentNode.content;
  184. _this4.raws.multiRuleProp += contentNode.content;
  185. }
  186. break;
  187. }
  188. case 'space':
  189. {
  190. declarationRaws.between += contentNode.content;
  191. break;
  192. }
  193. case 'value':
  194. {
  195. // Look up for a value for current property
  196. switch (contentNode.content[0].type) {
  197. case 'block':
  198. {
  199. isBlockInside = true; // If nested rules exist
  200. if (Array.isArray(contentNode.content[0].content)) {
  201. _this4.raws.multiRule = true;
  202. }
  203. _this4.process(contentNode.content[0], parent);
  204. break;
  205. }
  206. case 'variable':
  207. {
  208. declarationNode.value = '$';
  209. _this4.process(contentNode, declarationNode);
  210. break;
  211. }
  212. case 'color':
  213. {
  214. declarationNode.value = '#';
  215. _this4.process(contentNode, declarationNode);
  216. break;
  217. }
  218. case 'number':
  219. {
  220. if (contentNode.content.length > 1) {
  221. declarationNode.value = contentNode.content.join('');
  222. } else {
  223. _this4.process(contentNode, declarationNode);
  224. }
  225. break;
  226. }
  227. case 'parentheses':
  228. {
  229. declarationNode.value = '(';
  230. _this4.process(contentNode, declarationNode);
  231. break;
  232. }
  233. default:
  234. {
  235. _this4.process(contentNode, declarationNode);
  236. }
  237. }
  238. break;
  239. }
  240. default:
  241. }
  242. });
  243. if (!isBlockInside) {
  244. // Set parameters for Declaration node
  245. declarationNode.source = {
  246. start: node.start,
  247. end: node.end,
  248. input: this.input
  249. };
  250. declarationNode.parent = parent;
  251. parent.nodes.push(declarationNode);
  252. }
  253. this.raws.before = '';
  254. this.raws.customProperty = false;
  255. this.raws.multiRuleProp = '';
  256. this.raws.property = false;
  257. };
  258. _proto.customProperty = function customProperty(node, parent) {
  259. this.property(node, parent);
  260. parent.prop = "--" + parent.prop;
  261. };
  262. _proto.property = function property(node, parent) {
  263. // Set property for Declaration node
  264. switch (node.content[0].type) {
  265. case 'variable':
  266. {
  267. parent.prop += '$';
  268. break;
  269. }
  270. case 'interpolation':
  271. {
  272. this.raws.interpolation = true;
  273. parent.prop += '#{';
  274. break;
  275. }
  276. default:
  277. }
  278. parent.prop += node.content[0].content;
  279. if (this.raws.interpolation) {
  280. parent.prop += '}';
  281. this.raws.interpolation = false;
  282. }
  283. };
  284. _proto.value = function value(node, parent) {
  285. if (!parent.value) {
  286. parent.value = '';
  287. } // Set value for Declaration node
  288. if (node.content.length) {
  289. node.content.forEach(function (contentNode) {
  290. switch (contentNode.type) {
  291. case 'important':
  292. {
  293. parent.raws.important = contentNode.content;
  294. parent.important = true;
  295. var match = parent.value.match(/^(.*?)(\s*)$/);
  296. if (match) {
  297. parent.raws.important = match[2] + parent.raws.important;
  298. parent.value = match[1];
  299. }
  300. break;
  301. }
  302. case 'parentheses':
  303. {
  304. parent.value += contentNode.content.join('') + ')';
  305. break;
  306. }
  307. case 'percentage':
  308. {
  309. parent.value += contentNode.content.join('') + '%';
  310. break;
  311. }
  312. default:
  313. {
  314. if (contentNode.content.constructor === Array) {
  315. parent.value += contentNode.content.join('');
  316. } else {
  317. parent.value += contentNode.content;
  318. }
  319. }
  320. }
  321. });
  322. }
  323. };
  324. _proto.singlelineComment = function singlelineComment(node, parent) {
  325. return this.comment(node, parent, true);
  326. };
  327. _proto.multilineComment = function multilineComment(node, parent) {
  328. return this.comment(node, parent, false);
  329. };
  330. _proto.comment = function comment(node, parent, inline) {
  331. // https://github.com/nodesecurity/eslint-plugin-security#detect-unsafe-regex
  332. // eslint-disable-next-line security/detect-unsafe-regex
  333. var text = node.content.match(/^(\s*)((?:\S[\S\s]*?)?)(\s*)$/);
  334. this.raws.comment = true;
  335. var comment = Object.assign(postcss.comment(), {
  336. text: text[2],
  337. raws: {
  338. before: this.raws.before || DEFAULT_COMMENT_DECL.before,
  339. left: text[1],
  340. right: text[3],
  341. inline: inline
  342. },
  343. source: {
  344. start: {
  345. line: node.start.line,
  346. column: node.start.column
  347. },
  348. end: node.end,
  349. input: this.input
  350. },
  351. parent: parent
  352. });
  353. if (this.raws.beforeMulti) {
  354. comment.raws.before += this.raws.beforeMulti;
  355. this.raws.beforeMulti = undefined;
  356. }
  357. parent.nodes.push(comment);
  358. this.raws.before = '';
  359. };
  360. _proto.space = function space(node, parent) {
  361. // Spaces before root and rule
  362. switch (parent.type) {
  363. case 'root':
  364. {
  365. this.raws.before += node.content;
  366. break;
  367. }
  368. case 'rule':
  369. {
  370. if (this.raws.comment) {
  371. this.raws.before += node.content;
  372. } else if (this.raws.loop) {
  373. parent.selector += node.content;
  374. } else {
  375. this.raws.before = (this.raws.before || '\n') + node.content;
  376. }
  377. break;
  378. }
  379. default:
  380. }
  381. };
  382. _proto.declarationDelimiter = function declarationDelimiter(node) {
  383. this.raws.before += node.content;
  384. };
  385. _proto.loop = function loop(node, parent) {
  386. var _this5 = this;
  387. var loop = postcss.rule();
  388. this.raws.comment = false;
  389. this.raws.multiRule = false;
  390. this.raws.loop = true;
  391. loop.selector = '';
  392. loop.raws = {
  393. before: this.raws.before || DEFAULT_RAWS_RULE.before,
  394. between: DEFAULT_RAWS_RULE.between
  395. };
  396. if (this.raws.beforeMulti) {
  397. loop.raws.before += this.raws.beforeMulti;
  398. this.raws.beforeMulti = undefined;
  399. }
  400. node.content.forEach(function (contentNode, i) {
  401. if (node.content[i + 1] && node.content[i + 1].type === 'block') {
  402. _this5.raws.loop = false;
  403. }
  404. _this5.process(contentNode, loop);
  405. });
  406. parent.nodes.push(loop);
  407. this.raws.loop = false;
  408. };
  409. _proto.atrule = function atrule(node, parent) {
  410. var _this6 = this;
  411. // Skip unsupported @xxx rules
  412. var supportedNode = node.content[0].content.some(function (contentNode) {
  413. return SUPPORTED_AT_KEYWORDS.includes(contentNode.content);
  414. });
  415. if (!supportedNode) return;
  416. var atrule = postcss.rule();
  417. atrule.selector = '';
  418. atrule.raws = {
  419. before: this.raws.before || DEFAULT_RAWS_RULE.before,
  420. between: DEFAULT_RAWS_RULE.between
  421. };
  422. node.content.forEach(function (contentNode, i) {
  423. if (contentNode.type === 'space') {
  424. var prevNodeType = node.content[i - 1].type;
  425. switch (prevNodeType) {
  426. case 'atkeyword':
  427. case 'ident':
  428. atrule.selector += contentNode.content;
  429. break;
  430. default:
  431. }
  432. return;
  433. }
  434. _this6.process(contentNode, atrule);
  435. });
  436. parent.nodes.push(atrule);
  437. };
  438. _proto.parentheses = function parentheses(node, parent) {
  439. parent.selector += '(';
  440. node.content.forEach(function (contentNode) {
  441. if (typeof contentNode.content === 'string') {
  442. parent.selector += contentNode.content;
  443. }
  444. if (typeof contentNode.content === 'object') {
  445. contentNode.content.forEach(function (childrenContentNode) {
  446. if (contentNode.type === 'variable') parent.selector += '$';
  447. parent.selector += childrenContentNode.content;
  448. });
  449. }
  450. });
  451. parent.selector += ')';
  452. };
  453. _proto.interpolation = function interpolation(node, parent) {
  454. var _this7 = this;
  455. parent.selector += '#{';
  456. node.content.forEach(function (contentNode) {
  457. _this7.process(contentNode, parent);
  458. });
  459. parent.selector += '}';
  460. };
  461. _proto.atkeyword = function atkeyword(node, parent) {
  462. parent.selector += "@" + node.content;
  463. };
  464. _proto.operator = function operator(node, parent) {
  465. parent.selector += node.content;
  466. };
  467. _proto.variable = function variable(node, parent) {
  468. if (this.raws.loop) {
  469. parent.selector += "$" + node.content[0].content;
  470. return;
  471. }
  472. parent.selector += "$" + node.content;
  473. };
  474. _proto.ident = function ident(node, parent) {
  475. parent.selector += node.content;
  476. };
  477. return SassParser;
  478. }();
  479. module.exports = SassParser;
  480. //# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbInBhcnNlci5lczYiXSwibmFtZXMiOlsicG9zdGNzcyIsInJlcXVpcmUiLCJnb256YWxlcyIsIkRFRkFVTFRfUkFXU19ST09UIiwiYmVmb3JlIiwiREVGQVVMVF9SQVdTX1JVTEUiLCJiZXR3ZWVuIiwiREVGQVVMVF9SQVdTX0RFQ0wiLCJzZW1pY29sb24iLCJERUZBVUxUX0NPTU1FTlRfREVDTCIsIlNVUFBPUlRFRF9BVF9LRVlXT1JEUyIsIlNhc3NQYXJzZXIiLCJpbnB1dCIsInBhcnNlIiwibm9kZSIsImNzcyIsInN5bnRheCIsImVycm9yIiwibWVzc2FnZSIsImxpbmUiLCJsaW5lcyIsIm1hdGNoIiwicm9vdCIsInN0eWxlc2hlZXQiLCJleHRyYWN0U291cmNlIiwic3RhcnQiLCJlbmQiLCJub2RlTGluZXMiLCJzbGljZSIsInN1YnN0cmluZyIsImNvbHVtbiIsImxhc3QiLCJsZW5ndGgiLCJqb2luIiwic291cmNlIiwicmF3cyIsImNvbnRlbnQiLCJmb3JFYWNoIiwiY29udGVudE5vZGUiLCJwcm9jZXNzIiwicGFyZW50IiwidHlwZSIsInJ1bGVzZXQiLCJtdWx0aVJ1bGVQcm9wIiwicnVsZSIsInNlbGVjdG9yIiwicnVsZVJhd3MiLCJjb21tZW50IiwiZmlsdGVyIiwiaW5uZXJDb250ZW50Tm9kZSIsIm5vZGVzIiwicmVwbGFjZSIsInNwYWNlcyIsInB1c2giLCJibG9jayIsIm11bHRpUnVsZSIsIm11bHRpUnVsZVByb3BWYXJpYWJsZSIsIk9iamVjdCIsImFzc2lnbiIsImN1c3RvbVByb3BlcnR5IiwiYmVmb3JlTXVsdGkiLCJkZWNsYXJhdGlvbiIsImlzQmxvY2tJbnNpZGUiLCJkZWNsYXJhdGlvbk5vZGU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AgICAuZm9yRWFjaChpbm5lckNvbnRlbnROb2RlID0+IHRoaXMucHJvY2Vzcyhpbm5lckNvbnRlbnROb2RlLCBydWxlKSlcblxuICAgICAgICAgIGlmIChydWxlLm5vZGVzLmxlbmd0aCkge1xuICAgICAgICAgICAgLy8gV3JpdGUgc2VsZWN0b3IgdG8gUnVsZVxuICAgICAgICAgICAgcnVsZS5zZWxlY3RvciA9IHRoaXMuZXh0cmFjdFNvdXJjZShcbiAgICAgICAgICAgICAgbm9kZS5zdGFydCxcbiAgICAgICAgICAgICAgY29udGVudE5vZGUuc3RhcnRcbiAgICAgICAgICAgICkuc2xpY2UoMCwgLTEpLnJlcGxhY2UoL1xccyskLywgc3BhY2VzID0+IHtcbiAgICAgICAgICAgICAgcnVsZVJhd3MuYmV0d2VlbiA9IHNwYWNlc1xuICAgICAgICAgICAgICByZXR1cm4gJydcbiAgICAgICAgICAgIH0pXG4gICAgICAgICAgICAvLyBTZXQgcGFyYW1ldGVycyBmb3IgUnVsZSBub2RlXG4gICAgICAgICAgICBydWxlLnBhcmVudCA9IHBhcmVudFxuICAgICAgICAgICAgcnVsZS5zb3VyY2UgPSB7XG4gICAgICAgICAgICAgIHN0YXJ0OiBub2RlLnN0YXJ0LFxuICAgICAgICAgICAgICBlbmQ6IG5vZGUuZW5kLFxuICAgICAgICAgICAgICBpbnB1dDogdGhpcy5pbnB1dFxuICAgICAgICAgICAgfVxuICAgICAgICAgICAgcnVsZS5yYXdzID0gcnVsZVJhd3NcbiAgICAgICAgICAgIHBhcmVudC5ub2Rlcy5wdXNoKHJ1bGUpXG4gICAgICAgICAgfVxuICAgICAgICAgIGJyZWFrXG4gICAgICAgIH1cbiAgICAgICAgZGVmYXVsdDpcbiAgICAgIH1cbiAgICB9KVxuICB9XG5cbiAgYmxvY2sgKG5vZGUsIHBhcmVudCkge1xuICAgIC8vIElmIG5lc3RlZCBydWxlcyBleGlzdCwgd3JhcCBjdXJyZW50IHJ1bGUgaW4gbmV3IHJ1bGUg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AnOicgZ29lcyBiZWZvcmUgcHJvcGVydHkgZGVjbGFyYXRpb24sIGxpa2UgOndpZHRoIDEwMHB4ICovXG4gICAgICAgICAgICB0aGlzLnJhd3MuYmV0d2VlbkJlZm9yZSA9IHRydWVcbiAgICAgICAgICAgIGRlY2xhcmF0aW9uUmF3cy5iZWZvcmUgKz0gY29udGVudE5vZGUuY29udGVudFxuICAgICAgICAgICAgdGhpcy5yYXdzLm11bHRpUnVsZVByb3AgKz0gY29udGVudE5vZGUuY29udGVudFxuICAgICAgICAgIH1cbiAgICAgICAgICBicmVha1xuICAgICAgICB9XG4gICAgICAgIGNhc2UgJ3NwYWNlJzoge1xuICAgICAgICAgIGRlY2xhcmF0aW9uUmF3cy5iZXR3ZWVuICs9IGNvbnRlbnROb2RlLmNvbnRlbnRcbiAgICAgICAgICBicmVha1xuICAgICAgICB9XG4gICAgICAgIGNhc2UgJ3ZhbHVlJzoge1xuICAgICAgICAgIC8vIExvb2sgdXAgZm9yIGEgdmFsdWUgZm9yIGN1cnJlbnQgcHJvcGVydHlcbiAgICAgICAgICBzd2l0Y2ggKGNvbnRlbnROb2RlLmNvbnRlbnRbMF0udHlwZSkge1xuICAgICAgICAgICAgY2FzZSAnYmxvY2snOiB7XG4gICAgICAgICAgICAgIGlzQmxvY2tJbnNpZGUgPSB0cnVlXG4gICAgICAgICAgICAgIC8vIElmIG5lc3RlZCBydWxlcyBleGlzdFxuICAgICAgICAgICAgICBpZiAoQXJyYXkuaXNBcnJheShjb250ZW50Tm9kZS5jb250ZW50WzBdLmNvbnRlbnQpKSB7XG4gICAgICAgICAgICAgICAgdGhpcy5yYXdzLm11bHRpUnVsZSA9IHRydWVcbiAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICB0aGlzLnByb2Nlc3MoY29udGVudE5vZGUuY29udGVudFswXSwgcGFyZW50KVxuICAgICAgICAgICAgICBicmVha1xuICAgICAgICAgICAgfVxuICAgICAgICAgICAgY2FzZSAndmFyaWFibGUnOiB7XG4gICAgICAgICAgICAgIGRlY2xhcmF0aW9uTm9kZS52YWx1ZSA9ICckJ1xuICAgICAgICAgICAgICB0aGlzLnByb2Nlc3MoY29udGVudE5vZGUsIGRlY2xhcmF0aW9uTm9kZSlcbiAgICAgICAgICAgICAgYnJlYWtcbiAgICAgICAgICAgIH1cbiAgICAgICAgICAgIGNhc2UgJ2NvbG9yJzoge1xuICAgICAgICAgICAgICBkZWNsYXJhdGlvbk5vZGUudmFsdWUgPSAnIydcbiAgICAgICAgICAgICAgdGhpcy5wcm9jZXNzKGNvbnRlbnROb2RlLCBkZWNsYXJhdGlvbk5vZGUpXG4gICAgICAgICAgICAgIGJyZWFrXG4gICAgICAgICAgICB9XG4gICAgICAgICAgICBjYXNlICdudW1iZXInOiB7XG4gICAgICAgICAgICAgIGlmIChjb250ZW50Tm9kZS5jb250ZW50Lmxlbmd0aCA+IDEpIHtcbiAgICAgICAgICAgICAgICBkZWNsYXJhdGlvbk5vZGUudmFsdWUgPSBjb250ZW50Tm9kZS5jb250ZW50LmpvaW4oJycpXG4gICAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgICAgdGhpcy5wcm9jZXNzKGNvbnRlbnROb2RlLCBkZWNsYXJhdGlvbk5vZGUpXG4gICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgYnJlYWtcbiAgICAgICAgICAgIH1cbiAgICAgICAgICAgIGNhc2UgJ3BhcmVudGhlc2VzJzoge1xuICAgICAgICAgICAgICBkZWNsYXJhdGlvbk5vZGUudmFsdWUgPSAnKCdcbiAgICAgICAgICAgICAgdGhpcy5wcm9jZXNzKGNvbnRlbnROb2RlLCBkZWNsYXJhdGlvbk5vZGUpXG4gICAgICAgICAgICAgIGJyZWFrXG4gICAgICAgICAgICB9XG4gICAgICAgICAgICBkZWZhdWx0OiB7XG4gICAgICAgICAgICAgIHRoaXMucHJvY2Vzcyhjb250ZW50Tm9kZSwgZGVjbGFyYXRpb25Ob2RlKVxuICAgICAgICAgICAgfVx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24nOiB7XG4gICAgICAgIHRoaXMucmF3cy5pbnRlcnBvbGF0aW9uID0gdHJ1ZVxuICAgICAgICBwYXJlbnQucHJvcCArPSAnI3snXG4gICAgICAgIGJyZWFrXG4gICAgICB9XG4gICAgICBkZWZhdWx0OlxuICAgIH1cbiAgICBwYXJlbnQucHJvcCArPSBub2RlLmNvbnRlbnRbMF0uY29udGVudFxuICAgIGlmICh0aGlzLnJhd3MuaW50ZXJwb2xhdGlvbikge1xuICAgICAgcGFyZW50LnByb3AgKz0gJ30nXG4gICAgICB0aGlzLnJhd3MuaW50ZXJwb2xhdGlvbiA9IGZhbHNlXG4gICAgfVxuICB9XG5cbiAgdmFsdWUgKG5vZGUsIHBhcmVudCkge1xuICAgIGlmICghcGFyZW50LnZhbHVlKSB7XG4gICAgICBwYXJlbnQudmFsdWUgPSAnJ1xuICAgIH1cbiAgICAvLyBTZXQgdmFsdWUgZm9yIERlY2xhcmF0aW9uIG5vZGVcbiAgICBpZiAobm9kZS5jb250ZW50Lmxlbmd0aCkge1xuICAgICAgbm9kZS5jb250ZW50LmZvckVhY2goY29udGVudE5vZGUgPT4ge1xuICAgICAgICBzd2l0Y2ggKGNvbnRlbnROb2RlLnR5cGUpIHtcbiAgICAgICAgICBjYXNlICdpbXBvcnRhbnQnOiB7XG4gICAgICAgICAgICBwYXJlbnQucmF3cy5pbXBvcnRhbnQgPSBjb250ZW50Tm9kZS5jb250ZW50XG4gICAgICAgICAgICBwYXJlbnQuaW1wb3J0YW50ID0gdHJ1ZVxuICAgICAgICAgICAgbGV0IG1hdGNoID0gcGFyZW50LnZhbHVlLm1hdGNoKC9eKC4qPykoXFxzKikkLylcbiAgICAgICAgICAgIGlmIChtYXRjaCkge1xuICAgICAgICAgICAgICBwYXJlbnQucmF3cy5pbXBvcnRhbnQgPSBtYXRjaFsyXSArIHBhcmVudC5yYXdzLmltcG9ydGFudFxuICAgICAgICAgICAgICBwYXJlbnQudmFsdWUgPSBtYXRjaFsxXVxuICAgICAgICAgICAgfVxuICAgICAgICAgICAgYnJlYWtcbiAgICAgICAgICB9XG4gICAgICAgICAgY2FzZSAncGFyZW50aGVzZXMnOiB7XG4gICAgICAgICAgICBwYXJlbnQudmFsdWUgKz0gY29udGVudE5vZGUuY29udGVudC5qb2luKCcnKSArICcpJ1xuICAgICAgICAgICAgYnJlYWtcbiAgICAgICAgICB9XG4gICAgICAgICAgY2FzZSAncGVyY2VudGFnZSc6IHtcbiAgICAgICAgICAgIHBhcmVudC52YWx1ZSArPSBjb250ZW50Tm9kZS5jb250ZW50LmpvaW4oJycpICsgJyUnXG4gICAgICAgICAgICBicmVha1xuICAgICAgICAgIH1cbiAgICAgICAgICBkZWZhdWx0OiB7XG4gICAgICAgICAgICBpZiAoY29udGVudE5vZGUuY29udGVudC5jb25zdHJ1Y3RvciA9PT0gQXJyYXkpIHtcbiAgICAgICAgICAgICAgcGFyZW50LnZhbHVlICs9IGNvbnRlbnROb2RlLmNvbnRlbnQuam9pbignJylcbiAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgIHBhcmVudC52YWx1ZSArPSBjb250ZW50Tm9kZS5jb250ZW50XG4gICAgICAgICAgICB9XG4gICAgICAgICAgfVxuICAgICAgICB9XG4gICAgICB9KVxuICAgIH1cbiAgfVxuXG4gIHNpbmdsZWxpbmVDb21tZW50IChub2RlLCBwYXJlbnQpIHtcbiAgICByZXR1cm4gdGhpcy5jb21tZW50KG5vZGUsIHBhcmVudCwgdHJ1ZSlcbiAgfVxuXG4gIG11bHRpbGluZUNvbW1lbnQgKG5vZGUsIHBhcmVudCkge1xuICAgIHJldHVybiB0aGlzLmNvbW1lbnQobm9kZSwgcGFyZW50LCBmYWxzZSlcbiAgfVxuXG4gIGNvbW1lbnQgKG5vZGUsIHBhcmVudCwgaW5saW5lKSB7XG4gICAgLy8gaHR0cHM6Ly9naXRodWIuY29tL25vZGVzZWN1cml0eS9lc2xpbnQtcGx1Z2luLXNlY3VyaXR5I2RldGVjdC11bnNhZm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ERUZBVUxUX1JBV1NfUlVMRS5iZXR3ZWVuXG4gICAgfVxuICAgIG5vZGUuY29udGVudC5mb3JFYWNoKChjb250ZW50Tm9kZSwgaSkgPT4ge1xuICAgICAgaWYgKGNvbnRlbnROb2RlLnR5cGUgPT09ICdzcGFjZScpIHtcbiAgICAgICAgbGV0IHByZXZOb2RlVHlwZSA9IG5vZGUuY29udGVudFtpIC0gMV0udHlwZVxuICAgICAgICBzd2l0Y2ggKHByZXZOb2RlVHlwZSkge1xuICAgICAgICAgIGNhc2UgJ2F0a2V5d29yZCc6XG4gICAgICAgICAgY2FzZSAnaWRlbnQnOlxuICAgICAgICAgICAgYXRydWxlLnNlbGVjdG9yICs9IGNvbnRlbnROb2RlLmNvbnRlbnRcbiAgICAgICAgICAgIGJyZWFrXG4gICAgICAgICAgZGVmYXVsdDpcbiAgICAgICAgfVxuICAgICAgICByZXR1cm5cbiAgICAgIH1cbiAgICAgIHRoaXMucHJvY2Vzcyhjb250ZW50Tm9kZSwgYXRydWxlKVxuICAgIH0pXG4gICAgcGFyZW50Lm5vZGVzLnB1c2goYXRydWxlKVxuICB9XG5cbiAgcGFyZW50aGVzZXMgKG5vZGUsIHBhcmVudCkge1xuICAgIHBhcmVudC5zZWxlY3RvciArPSAnKCdcbiAgICBub2RlLmNvbnRlbnQuZm9yRWFjaChjb250ZW50Tm9kZSA9PiB7XG4gICAgICBpZiAodHlwZW9mIGNvbnRlbnROb2RlLmNvbnRlbnQgPT09ICdzdHJpbmcnKSB7XG4gICAgICAgIHBhcmVudC5zZWxlY3RvciArPSBjb250ZW50Tm9kZS5jb250ZW50XG4gICAgICB9XG5cbiAgICAgIGlmICh0eXBlb2YgY29udGVudE5vZGUuY29udGVudCA9PT0gJ29iamVjdCcpIHtcbiAgICAgICAgY29udGVudE5vZGUuY29udGVudC5mb3JFYWNoKGNoaWxkcmVuQ29udGVudE5vZGUgPT4ge1xuICAgICAgICAgIGlmIChjb250ZW50Tm9kZS50eXBlID09PSAndmFyaW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