All Downloads are FREE. Search and download functionalities are using the official Maven repository.

web-interface.assets.30.746b58959a350aa1ebcf.js.map Maven / Gradle / Ivy

There is a newer version: 6.0.5
Show newest version
{"version":3,"sources":["webpack:///30.746b58959a350aa1ebcf.js","webpack:///./src/pages/ContentPacksPage.jsx","webpack:///./src/components/source-tagging/ConfigurationBundles.jsx","webpack:///./src/components/source-tagging/SourceType.jsx","webpack:///./src/components/source-tagging/ConfigurationBundlePreview.jsx","webpack:///./node_modules/markdown/lib/index.js","webpack:///./node_modules/markdown/lib/markdown.js","webpack:///./node_modules/util/util.js","webpack:///./node_modules/util/support/isBufferBrowser.js","webpack:///./node_modules/util/node_modules/inherits/inherits_browser.js"],"names":["webpackJsonp","1401","module","exports","__webpack_require__","_interopRequireDefault","obj","__esModule","default","Object","defineProperty","value","_react","_react2","_reactBootstrap","_reactRouterBootstrap","_Routes","_Routes2","_common","_ConfigurationBundles","_ConfigurationBundles2","ContentPacksPage","createClass","displayName","render","createElement","DocumentTitle","title","PageHeader","href","target","LinkContainer","to","SYSTEM","CONTENTPACKS","EXPORT","Button","bsStyle","bsSize","Row","className","Col","md","id","1402","_reflux","_reflux2","_jquery","_jquery2","_UserNotification","_UserNotification2","_ActionsProvider","_ActionsProvider2","_StoreProvider","_StoreProvider2","_SourceType","_SourceType2","_ConfigurationBundlePreview","_ConfigurationBundlePreview2","_Spinner","_Spinner2","ConfigurationBundlesActions","getActions","ConfigurationBundlesStore","getStore","ConfigurationBundles","mixins","connect","getInitialState","sourceTypeId","sourceTypeDescription","componentDidMount","list","_getCategoriesHtml","_this","this","categories","map","state","configurationBundles","bundles","category","sort","idx","_getSourceTypeHtml","_this2","_getSortedBundles","bundlesJsx","bundle","key","name","description","onSelect","handleSourceTypeChange","Panel","header","eventKey","bundle1","bundle2","onSubmit","submitEvent","preventDefault","refs","uploadedFile","files","reader","FileReader","onload","evt","request","result","create","triggerPromise","then","success","error","readAsText","setState","_resetSelection","Accordion","encType","ref","type","onDelete","1403","_propTypes","_propTypes2","SourceType","propTypes","string","isRequired","func","_onChange","event","props","onChange","1404","_markdown","ConfigurationBundlePreview","_confirmDeletion","window","confirm","delete","_onApply","apply","preview","applyAction","deleteAction","onClick","markdownPreview","markdown","toHTML","style","marginBottom","dangerouslySetInnerHTML","__html","1405","parse","1406","expose","mk_block_toSource","uneval","toString","trailing","lineNumber","mk_block_inspect","util","inspect","count_lines","str","n","i","indexOf","strong_em","tag","CloseTag","len","len_after","state_slot","other_slot","text","orig_match","shift","length","other","slice","unshift","res","processInline","substr","last","pop","concat","split_meta_hash","meta_string","meta","split","parts","in_quotes","letter","push","extract_attr","jsonml","isArray","undefined","escapeHTML","replace","render_tree","attributes","content","Array","tag_attrs","a","join","convert_tree_to_html","tree","references","options","preprocessTreeNode","attrs","level","code","splice","src","original","merge_text_nodes","Markdown","dialect","dialects","Gruber","Error","String","em_state","strong_state","debug_indent","source","toTree","input","toHTMLTree","renderJsonML","html","mk_block","block","trail","line","arguments","s","toSource","prototype","split_blocks","startLine","m","re","blocks","line_no","exec","lastIndex","processBlock","next","cbs","ord","__order__","__call__","call","debug","inline","custom_root","old_tree","b","args","print","console","log","loop_re_over_block","cb","valueOf","atxHeader","match","setextHeader","ret","block_search","substring","horizRule","lists","regex_for_depth","depth","RegExp","indent_re","any_list","expand_tab","add","li","loose","nl","add_to","what","get_contained_blocks","x","paragraphify","stack","last_li","sublist","bullet_list","is_list_re","make_list","indent","lines","li_accumulate","l","line_re","wanted_depth","Math","floor","found","contained","forEach","next_block","hr","blockquote","prev","abutting","processedBlock","attr","isEmpty","referenceDefn","toLowerCase","para","__oneElement__","patterns_or_re","previous_nodes","__patterns__","index","patterns","out","]","}","__escape__","\\","charAt","![","alt","[","orig","DialectHelpers","inline_until_char","link","consumed","children","url","open_parens","<","`","  \n","buildBlockOrder","d","buildInlinePatterns","fn","pattern","want","nodes","subclassDialect","Block","Inline","Maruku","processMetaHash","test","document_meta","pairs","p","block_meta","hash","node","definition_list","tight","terms","defns","table","_split_on_unescaped","ch","r","leading_pipe","no_leading_pipe","html_attrs","align","trim","row","html_row","matches","before","k","arr","thisp","hasOwnProperty","root","1407","global","process","opts","ctx","seen","stylize","stylizeNoColor","colors","isBoolean","showHidden","_extend","isUndefined","customInspect","stylizeWithColor","formatValue","styleType","styles","arrayToHash","array","val","recurseTimes","isFunction","constructor","isString","primitive","formatPrimitive","keys","visibleKeys","getOwnPropertyNames","isError","formatError","isRegExp","isDate","Date","base","braces","toUTCString","output","formatArray","formatProperty","reduceToSingleString","simple","JSON","stringify","isNumber","isNull","desc","getOwnPropertyDescriptor","get","set","numLinesEst","reduce","cur","ar","arg","isNullOrUndefined","isSymbol","isObject","objectToString","e","isPrimitive","o","pad","timestamp","time","getHours","getMinutes","getSeconds","getDate","months","getMonth","prop","formatRegExp","format","f","objects","Number","_","deprecate","msg","deprecated","warned","throwDeprecation","traceDeprecation","trace","noDeprecation","debugEnviron","debugs","debuglog","env","NODE_DEBUG","toUpperCase","pid","bold","italic","underline","inverse","white","grey","black","blue","cyan","green","magenta","red","yellow","special","number","boolean","null","date","regexp","isBuffer","inherits","origin","1408","copy","fill","readUInt8","1409","ctor","superCtor","super_","enumerable","writable","configurable","TempCtor"],"mappings":"AAAAA,cAAc,KAERC,KACA,SAAUC,EAAQC,QAASC,GAEjC,YAyBA,SAASC,GAAuBC,GAAO,MAAOA,IAAOA,EAAIC,WAAaD,GAAQE,QAASF,GAtBvFG,OAAOC,eAAeP,QAAS,cAC7BQ,OAAO,GCTT,IAAAC,GAAAR,EAAA,GDcIS,EAAUR,EAAuBO,GCbrCE,EAAAV,EAAA,IACAW,EAAAX,EAAA,KAEAY,EAAAZ,EAAA,IDkBIa,EAAWZ,EAAuBW,GChBtCE,EAAAd,EAAA,IACAe,EAAAf,EAAA,MDqBIgB,EAAyBf,EAAuBc,GCnB9CE,EAAmBR,EAAAL,QAAMc,aAAYC,YAAA,mBACzCC,OADyC,WAEvC,MACEX,GAAAL,QAAAiB,cAAAP,EAAAQ,eAAeC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,IAAA,gBAAAA,IACA,kBAAAA,GAAA8D,MACA,kBAAA9D,GAAA+D,MACA,kBAAA/D,GAAAgE,YR4uFMC,KACA,SAAUhgB,EAAQC,SSjvFxB,kBAAAM,QAAAsG,OAEA7G,EAAAC,QAAA,SAAAggB,EAAAC,GACAD,EAAAE,OAAAD,EACAD,EAAA3Q,UAAA/O,OAAAsG,OAAAqZ,EAAA5Q,WACAyK,aACAtZ,MAAAwf,EACAG,YAAA,EACAC,UAAA,EACAC,cAAA,MAMAtgB,EAAAC,QAAA,SAAAggB,EAAAC,GACAD,EAAAE,OAAAD,CACA,IAAAK,GAAA,YACAA,GAAAjR,UAAA4Q,EAAA5Q,UACA2Q,EAAA3Q,UAAA,GAAAiR,GACAN,EAAA3Q,UAAAyK,YAAAkG","file":"30.746b58959a350aa1ebcf.js","sourcesContent":["webpackJsonp([30],{\n\n/***/ 1401:\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\n\nObject.defineProperty(exports, \"__esModule\", {\n  value: true\n});\n\nvar _react = __webpack_require__(2);\n\nvar _react2 = _interopRequireDefault(_react);\n\nvar _reactBootstrap = __webpack_require__(16);\n\nvar _reactRouterBootstrap = __webpack_require__(915);\n\nvar _Routes = __webpack_require__(76);\n\nvar _Routes2 = _interopRequireDefault(_Routes);\n\nvar _common = __webpack_require__(46);\n\nvar _ConfigurationBundles = __webpack_require__(1402);\n\nvar _ConfigurationBundles2 = _interopRequireDefault(_ConfigurationBundles);\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nvar ContentPacksPage = _react2.default.createClass({\n  displayName: 'ContentPacksPage',\n  render: function render() {\n    return _react2.default.createElement(\n      _common.DocumentTitle,\n      { title: 'Content packs' },\n      _react2.default.createElement(\n        'span',\n        null,\n        _react2.default.createElement(\n          _common.PageHeader,\n          { title: 'Content packs' },\n          _react2.default.createElement(\n            'span',\n            null,\n            'Content packs accelerate the set up process for a specific data source. A content pack can include inputs/extractors, streams, and dashboards.'\n          ),\n          _react2.default.createElement(\n            'span',\n            null,\n            'Find more content packs in ',\n            ' ',\n            _react2.default.createElement(\n              'a',\n              { href: 'https://marketplace.graylog.org/', target: '_blank' },\n              'the Graylog Marketplace'\n            ),\n            '.'\n          ),\n          _react2.default.createElement(\n            _reactRouterBootstrap.LinkContainer,\n            { to: _Routes2.default.SYSTEM.CONTENTPACKS.EXPORT },\n            _react2.default.createElement(\n              _reactBootstrap.Button,\n              { bsStyle: 'success', bsSize: 'large' },\n              'Create a content pack'\n            )\n          )\n        ),\n        _react2.default.createElement(\n          _reactBootstrap.Row,\n          { className: 'content' },\n          _react2.default.createElement(\n            _reactBootstrap.Col,\n            { md: 12 },\n            _react2.default.createElement(\n              'h2',\n              null,\n              'Select content packs'\n            ),\n            _react2.default.createElement(\n              'div',\n              { id: 'react-configuration-bundles' },\n              _react2.default.createElement(_ConfigurationBundles2.default, null)\n            )\n          )\n        )\n      )\n    );\n  }\n});\n\nexports.default = ContentPacksPage;\nmodule.exports = exports['default'];\n\n/***/ }),\n\n/***/ 1402:\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\n\nObject.defineProperty(exports, \"__esModule\", {\n  value: true\n});\n\nvar _react = __webpack_require__(2);\n\nvar _react2 = _interopRequireDefault(_react);\n\nvar _reflux = __webpack_require__(1);\n\nvar _reflux2 = _interopRequireDefault(_reflux);\n\nvar _reactBootstrap = __webpack_require__(16);\n\nvar _jquery = __webpack_require__(14);\n\nvar _jquery2 = _interopRequireDefault(_jquery);\n\nvar _UserNotification = __webpack_require__(6);\n\nvar _UserNotification2 = _interopRequireDefault(_UserNotification);\n\nvar _ActionsProvider = __webpack_require__(8);\n\nvar _ActionsProvider2 = _interopRequireDefault(_ActionsProvider);\n\nvar _StoreProvider = __webpack_require__(23);\n\nvar _StoreProvider2 = _interopRequireDefault(_StoreProvider);\n\nvar _SourceType = __webpack_require__(1403);\n\nvar _SourceType2 = _interopRequireDefault(_SourceType);\n\nvar _ConfigurationBundlePreview = __webpack_require__(1404);\n\nvar _ConfigurationBundlePreview2 = _interopRequireDefault(_ConfigurationBundlePreview);\n\nvar _Spinner = __webpack_require__(265);\n\nvar _Spinner2 = _interopRequireDefault(_Spinner);\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nvar ConfigurationBundlesActions = _ActionsProvider2.default.getActions('ConfigurationBundles');\n\nvar ConfigurationBundlesStore = _StoreProvider2.default.getStore('ConfigurationBundles');\n\nvar ConfigurationBundles = _react2.default.createClass({\n  displayName: 'ConfigurationBundles',\n\n  mixins: [_reflux2.default.connect(ConfigurationBundlesStore)],\n\n  getInitialState: function getInitialState() {\n    return {\n      sourceTypeId: '',\n      sourceTypeDescription: ''\n    };\n  },\n  componentDidMount: function componentDidMount() {\n    ConfigurationBundlesActions.list();\n  },\n  _getCategoriesHtml: function _getCategoriesHtml() {\n    var _this = this;\n\n    var categories = _jquery2.default.map(this.state.configurationBundles, function (bundles, category) {\n      return category;\n    });\n    categories.sort();\n    return categories.map(function (category, idx) {\n      return _this._getSourceTypeHtml(category, idx);\n    }, this);\n  },\n  _getSourceTypeHtml: function _getSourceTypeHtml(category, idx) {\n    var _this2 = this;\n\n    var bundles = this._getSortedBundles(category);\n    var bundlesJsx = bundles.map(function (bundle) {\n      return _react2.default.createElement(\n        'li',\n        { key: bundle.id },\n        _react2.default.createElement(_SourceType2.default, { id: bundle.id,\n          name: bundle.name,\n          description: bundle.description,\n          onSelect: _this2.handleSourceTypeChange })\n      );\n    }, this);\n\n    return _react2.default.createElement(\n      _reactBootstrap.Panel,\n      { key: category, header: category, eventKey: category + '-' + idx },\n      _react2.default.createElement(\n        'ul',\n        null,\n        bundlesJsx\n      )\n    );\n  },\n  _getSortedBundles: function _getSortedBundles(category) {\n    var bundles = this.state.configurationBundles[category];\n    bundles.sort(function (bundle1, bundle2) {\n      if (bundle1.name > bundle2.name) {\n        return 1;\n      }\n      if (bundle1.name < bundle2.name) {\n        return -1;\n      }\n      return 0;\n    });\n    return bundles;\n  },\n  onSubmit: function onSubmit(submitEvent) {\n    submitEvent.preventDefault();\n    if (!this.refs.uploadedFile.files || !this.refs.uploadedFile.files[0]) {\n      return;\n    }\n\n    var reader = new FileReader();\n\n    reader.onload = function (evt) {\n      var request = evt.target.result;\n      ConfigurationBundlesActions.create.triggerPromise(request).then(function () {\n        _UserNotification2.default.success('Content pack imported successfully', 'Success!');\n        ConfigurationBundlesActions.list();\n      }, function () {\n        _UserNotification2.default.error('Error importing content pack, please ensure it is a valid JSON file. Check your ' + 'Graylog logs for more information.', 'Could not import content pack');\n      });\n    };\n\n    reader.readAsText(this.refs.uploadedFile.files[0]);\n  },\n  handleSourceTypeChange: function handleSourceTypeChange(sourceTypeId, sourceTypeDescription) {\n    this.setState({ sourceTypeId: sourceTypeId, sourceTypeDescription: sourceTypeDescription });\n  },\n  _resetSelection: function _resetSelection() {\n    this.setState(this.getInitialState());\n  },\n  render: function render() {\n    return _react2.default.createElement(\n      _reactBootstrap.Row,\n      { className: 'configuration-bundles' },\n      _react2.default.createElement(\n        _reactBootstrap.Col,\n        { md: 6 },\n        this.state.configurationBundles ? _react2.default.createElement(\n          _reactBootstrap.Accordion,\n          null,\n          this._getCategoriesHtml(),\n          _react2.default.createElement(\n            _reactBootstrap.Panel,\n            { header: 'Import content pack', eventKey: -1 },\n            _react2.default.createElement(\n              'form',\n              { onSubmit: this.onSubmit, className: 'upload', encType: 'multipart/form-data' },\n              _react2.default.createElement(\n                'span',\n                { className: 'help-block' },\n                'Remember to apply the content pack after uploading it, to make the changes effective.'\n              ),\n              _react2.default.createElement(\n                'div',\n                { className: 'form-group' },\n                _react2.default.createElement('input', { ref: 'uploadedFile', type: 'file', name: 'bundle' })\n              ),\n              _react2.default.createElement(\n                'button',\n                { type: 'submit', className: 'btn btn-success' },\n                'Upload'\n              )\n            )\n          )\n        ) : _react2.default.createElement(_Spinner2.default, null)\n      ),\n      _react2.default.createElement(\n        _reactBootstrap.Col,\n        { md: 6 },\n        _react2.default.createElement(_ConfigurationBundlePreview2.default, { sourceTypeId: this.state.sourceTypeId,\n          sourceTypeDescription: this.state.sourceTypeDescription,\n          onDelete: this._resetSelection })\n      )\n    );\n  }\n});\n\nexports.default = ConfigurationBundles;\nmodule.exports = exports['default'];\n\n/***/ }),\n\n/***/ 1403:\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\n\nObject.defineProperty(exports, \"__esModule\", {\n  value: true\n});\n\nvar _propTypes = __webpack_require__(5);\n\nvar _propTypes2 = _interopRequireDefault(_propTypes);\n\nvar _react = __webpack_require__(2);\n\nvar _react2 = _interopRequireDefault(_react);\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nvar SourceType = _react2.default.createClass({\n  displayName: 'SourceType',\n\n  propTypes: {\n    name: _propTypes2.default.string.isRequired,\n    description: _propTypes2.default.string.isRequired,\n    onSelect: _propTypes2.default.func.isRequired\n  },\n  _onChange: function _onChange(event) {\n    this.props.onSelect(event.target.id, event.target.value);\n  },\n  render: function render() {\n    return _react2.default.createElement(\n      'label',\n      { className: 'radio' },\n      _react2.default.createElement('input', { type: 'radio', name: 'sourceType', id: this.props.id, value: this.props.description,\n        onChange: this._onChange }),\n      this.props.name\n    );\n  }\n});\n\nexports.default = SourceType;\nmodule.exports = exports['default'];\n\n/***/ }),\n\n/***/ 1404:\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\n\nObject.defineProperty(exports, \"__esModule\", {\n  value: true\n});\n\nvar _propTypes = __webpack_require__(5);\n\nvar _propTypes2 = _interopRequireDefault(_propTypes);\n\nvar _react = __webpack_require__(2);\n\nvar _react2 = _interopRequireDefault(_react);\n\nvar _reactBootstrap = __webpack_require__(16);\n\nvar _markdown = __webpack_require__(1405);\n\nvar _UserNotification = __webpack_require__(6);\n\nvar _UserNotification2 = _interopRequireDefault(_UserNotification);\n\nvar _ActionsProvider = __webpack_require__(8);\n\nvar _ActionsProvider2 = _interopRequireDefault(_ActionsProvider);\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nvar ConfigurationBundlesActions = _ActionsProvider2.default.getActions('ConfigurationBundles');\n\nvar ConfigurationBundlePreview = _react2.default.createClass({\n  displayName: 'ConfigurationBundlePreview',\n\n  propTypes: {\n    sourceTypeId: _propTypes2.default.string,\n    sourceTypeDescription: _propTypes2.default.string,\n    onDelete: _propTypes2.default.func.isRequired\n  },\n\n  _confirmDeletion: function _confirmDeletion() {\n    var _this = this;\n\n    if (window.confirm('You are about to delete this content pack, are you sure?')) {\n      ConfigurationBundlesActions.delete(this.props.sourceTypeId).then(function () {\n        _UserNotification2.default.success('Bundle deleted successfully.', 'Success');\n        _this.props.onDelete();\n      }, function () {\n        _UserNotification2.default.error('Deleting bundle failed, please check your logs for more information.', 'Error');\n      });\n    }\n  },\n  _onApply: function _onApply() {\n    ConfigurationBundlesActions.apply(this.props.sourceTypeId).then(function () {\n      _UserNotification2.default.success('Bundle applied successfully.', 'Success');\n    }, function () {\n      _UserNotification2.default.error('Applying bundle failed, please check your logs for more information.', 'Error');\n    });\n  },\n  render: function render() {\n    var preview = 'Select a content pack from the list to see its preview.';\n    var applyAction = '';\n    var deleteAction = '';\n\n    if (this.props.sourceTypeDescription) {\n      preview = this.props.sourceTypeDescription;\n      applyAction = _react2.default.createElement(\n        _reactBootstrap.Button,\n        { bsStyle: 'success', onClick: this._onApply },\n        'Apply content'\n      );\n      deleteAction = _react2.default.createElement(\n        _reactBootstrap.Button,\n        { className: 'pull-right', bsStyle: 'warning', bsSize: 'xsmall', onClick: this._confirmDeletion },\n        'Remove pack'\n      );\n    }\n\n    var markdownPreview = _markdown.markdown.toHTML(preview);\n\n    return _react2.default.createElement(\n      'div',\n      { className: 'bundle-preview' },\n      _react2.default.createElement(\n        'div',\n        { style: { marginBottom: 5 } },\n        deleteAction,\n        _react2.default.createElement(\n          'h2',\n          null,\n          'Content pack description:'\n        )\n      ),\n      _react2.default.createElement('div', { dangerouslySetInnerHTML: { __html: markdownPreview } }),\n      _react2.default.createElement(\n        'div',\n        { className: 'preview-actions' },\n        applyAction\n      )\n    );\n  }\n});\n\nexports.default = ConfigurationBundlePreview;\nmodule.exports = exports['default'];\n\n/***/ }),\n\n/***/ 1405:\n/***/ (function(module, exports, __webpack_require__) {\n\n// super simple module for the most common nodejs use case.\nexports.markdown = __webpack_require__(1406);\nexports.parse = exports.markdown.toHTML;\n\n\n/***/ }),\n\n/***/ 1406:\n/***/ (function(module, exports, __webpack_require__) {\n\n// Released under MIT license\n// Copyright (c) 2009-2010 Dominic Baggott\n// Copyright (c) 2009-2010 Ash Berlin\n// Copyright (c) 2011 Christoph Dorn  (http://www.christophdorn.com)\n\n/*jshint browser:true, devel:true */\n\n(function( expose ) {\n\n/**\n *  class Markdown\n *\n *  Markdown processing in Javascript done right. We have very particular views\n *  on what constitutes 'right' which include:\n *\n *  - produces well-formed HTML (this means that em and strong nesting is\n *    important)\n *\n *  - has an intermediate representation to allow processing of parsed data (We\n *    in fact have two, both as [JsonML]: a markdown tree and an HTML tree).\n *\n *  - is easily extensible to add new dialects without having to rewrite the\n *    entire parsing mechanics\n *\n *  - has a good test suite\n *\n *  This implementation fulfills all of these (except that the test suite could\n *  do with expanding to automatically run all the fixtures from other Markdown\n *  implementations.)\n *\n *  ##### Intermediate Representation\n *\n *  *TODO* Talk about this :) Its JsonML, but document the node names we use.\n *\n *  [JsonML]: http://jsonml.org/ \"JSON Markup Language\"\n **/\nvar Markdown = expose.Markdown = function(dialect) {\n  switch (typeof dialect) {\n    case \"undefined\":\n      this.dialect = Markdown.dialects.Gruber;\n      break;\n    case \"object\":\n      this.dialect = dialect;\n      break;\n    default:\n      if ( dialect in Markdown.dialects ) {\n        this.dialect = Markdown.dialects[dialect];\n      }\n      else {\n        throw new Error(\"Unknown Markdown dialect '\" + String(dialect) + \"'\");\n      }\n      break;\n  }\n  this.em_state = [];\n  this.strong_state = [];\n  this.debug_indent = \"\";\n};\n\n/**\n *  parse( markdown, [dialect] ) -> JsonML\n *  - markdown (String): markdown string to parse\n *  - dialect (String | Dialect): the dialect to use, defaults to gruber\n *\n *  Parse `markdown` and return a markdown document as a Markdown.JsonML tree.\n **/\nexpose.parse = function( source, dialect ) {\n  // dialect will default if undefined\n  var md = new Markdown( dialect );\n  return md.toTree( source );\n};\n\n/**\n *  toHTML( markdown, [dialect]  ) -> String\n *  toHTML( md_tree ) -> String\n *  - markdown (String): markdown string to parse\n *  - md_tree (Markdown.JsonML): parsed markdown tree\n *\n *  Take markdown (either as a string or as a JsonML tree) and run it through\n *  [[toHTMLTree]] then turn it into a well-formated HTML fragment.\n **/\nexpose.toHTML = function toHTML( source , dialect , options ) {\n  var input = expose.toHTMLTree( source , dialect , options );\n\n  return expose.renderJsonML( input );\n};\n\n/**\n *  toHTMLTree( markdown, [dialect] ) -> JsonML\n *  toHTMLTree( md_tree ) -> JsonML\n *  - markdown (String): markdown string to parse\n *  - dialect (String | Dialect): the dialect to use, defaults to gruber\n *  - md_tree (Markdown.JsonML): parsed markdown tree\n *\n *  Turn markdown into HTML, represented as a JsonML tree. If a string is given\n *  to this function, it is first parsed into a markdown tree by calling\n *  [[parse]].\n **/\nexpose.toHTMLTree = function toHTMLTree( input, dialect , options ) {\n  // convert string input to an MD tree\n  if ( typeof input ===\"string\" ) input = this.parse( input, dialect );\n\n  // Now convert the MD tree to an HTML tree\n\n  // remove references from the tree\n  var attrs = extract_attr( input ),\n      refs = {};\n\n  if ( attrs && attrs.references ) {\n    refs = attrs.references;\n  }\n\n  var html = convert_tree_to_html( input, refs , options );\n  merge_text_nodes( html );\n  return html;\n};\n\n// For Spidermonkey based engines\nfunction mk_block_toSource() {\n  return \"Markdown.mk_block( \" +\n          uneval(this.toString()) +\n          \", \" +\n          uneval(this.trailing) +\n          \", \" +\n          uneval(this.lineNumber) +\n          \" )\";\n}\n\n// node\nfunction mk_block_inspect() {\n  var util = __webpack_require__(1407);\n  return \"Markdown.mk_block( \" +\n          util.inspect(this.toString()) +\n          \", \" +\n          util.inspect(this.trailing) +\n          \", \" +\n          util.inspect(this.lineNumber) +\n          \" )\";\n\n}\n\nvar mk_block = Markdown.mk_block = function(block, trail, line) {\n  // Be helpful for default case in tests.\n  if ( arguments.length == 1 ) trail = \"\\n\\n\";\n\n  var s = new String(block);\n  s.trailing = trail;\n  // To make it clear its not just a string\n  s.inspect = mk_block_inspect;\n  s.toSource = mk_block_toSource;\n\n  if ( line != undefined )\n    s.lineNumber = line;\n\n  return s;\n};\n\nfunction count_lines( str ) {\n  var n = 0, i = -1;\n  while ( ( i = str.indexOf(\"\\n\", i + 1) ) !== -1 ) n++;\n  return n;\n}\n\n// Internal - split source into rough blocks\nMarkdown.prototype.split_blocks = function splitBlocks( input, startLine ) {\n  input = input.replace(/(\\r\\n|\\n|\\r)/g, \"\\n\");\n  // [\\s\\S] matches _anything_ (newline or space)\n  // [^] is equivalent but doesn't work in IEs.\n  var re = /([\\s\\S]+?)($|\\n#|\\n(?:\\s*\\n|$)+)/g,\n      blocks = [],\n      m;\n\n  var line_no = 1;\n\n  if ( ( m = /^(\\s*\\n)/.exec(input) ) != null ) {\n    // skip (but count) leading blank lines\n    line_no += count_lines( m[0] );\n    re.lastIndex = m[0].length;\n  }\n\n  while ( ( m = re.exec(input) ) !== null ) {\n    if (m[2] == \"\\n#\") {\n      m[2] = \"\\n\";\n      re.lastIndex--;\n    }\n    blocks.push( mk_block( m[1], m[2], line_no ) );\n    line_no += count_lines( m[0] );\n  }\n\n  return blocks;\n};\n\n/**\n *  Markdown#processBlock( block, next ) -> undefined | [ JsonML, ... ]\n *  - block (String): the block to process\n *  - next (Array): the following blocks\n *\n * Process `block` and return an array of JsonML nodes representing `block`.\n *\n * It does this by asking each block level function in the dialect to process\n * the block until one can. Succesful handling is indicated by returning an\n * array (with zero or more JsonML nodes), failure by a false value.\n *\n * Blocks handlers are responsible for calling [[Markdown#processInline]]\n * themselves as appropriate.\n *\n * If the blocks were split incorrectly or adjacent blocks need collapsing you\n * can adjust `next` in place using shift/splice etc.\n *\n * If any of this default behaviour is not right for the dialect, you can\n * define a `__call__` method on the dialect that will get invoked to handle\n * the block processing.\n */\nMarkdown.prototype.processBlock = function processBlock( block, next ) {\n  var cbs = this.dialect.block,\n      ord = cbs.__order__;\n\n  if ( \"__call__\" in cbs ) {\n    return cbs.__call__.call(this, block, next);\n  }\n\n  for ( var i = 0; i < ord.length; i++ ) {\n    //D:this.debug( \"Testing\", ord[i] );\n    var res = cbs[ ord[i] ].call( this, block, next );\n    if ( res ) {\n      //D:this.debug(\"  matched\");\n      if ( !isArray(res) || ( res.length > 0 && !( isArray(res[0]) ) ) )\n        this.debug(ord[i], \"didn't return a proper array\");\n      //D:this.debug( \"\" );\n      return res;\n    }\n  }\n\n  // Uhoh! no match! Should we throw an error?\n  return [];\n};\n\nMarkdown.prototype.processInline = function processInline( block ) {\n  return this.dialect.inline.__call__.call( this, String( block ) );\n};\n\n/**\n *  Markdown#toTree( source ) -> JsonML\n *  - source (String): markdown source to parse\n *\n *  Parse `source` into a JsonML tree representing the markdown document.\n **/\n// custom_tree means set this.tree to `custom_tree` and restore old value on return\nMarkdown.prototype.toTree = function toTree( source, custom_root ) {\n  var blocks = source instanceof Array ? source : this.split_blocks( source );\n\n  // Make tree a member variable so its easier to mess with in extensions\n  var old_tree = this.tree;\n  try {\n    this.tree = custom_root || this.tree || [ \"markdown\" ];\n\n    blocks:\n    while ( blocks.length ) {\n      var b = this.processBlock( blocks.shift(), blocks );\n\n      // Reference blocks and the like won't return any content\n      if ( !b.length ) continue blocks;\n\n      this.tree.push.apply( this.tree, b );\n    }\n    return this.tree;\n  }\n  finally {\n    if ( custom_root ) {\n      this.tree = old_tree;\n    }\n  }\n};\n\n// Noop by default\nMarkdown.prototype.debug = function () {\n  var args = Array.prototype.slice.call( arguments);\n  args.unshift(this.debug_indent);\n  if ( typeof print !== \"undefined\" )\n      print.apply( print, args );\n  if ( typeof console !== \"undefined\" && typeof console.log !== \"undefined\" )\n      console.log.apply( null, args );\n}\n\nMarkdown.prototype.loop_re_over_block = function( re, block, cb ) {\n  // Dont use /g regexps with this\n  var m,\n      b = block.valueOf();\n\n  while ( b.length && (m = re.exec(b) ) != null ) {\n    b = b.substr( m[0].length );\n    cb.call(this, m);\n  }\n  return b;\n};\n\n/**\n * Markdown.dialects\n *\n * Namespace of built-in dialects.\n **/\nMarkdown.dialects = {};\n\n/**\n * Markdown.dialects.Gruber\n *\n * The default dialect that follows the rules set out by John Gruber's\n * markdown.pl as closely as possible. Well actually we follow the behaviour of\n * that script which in some places is not exactly what the syntax web page\n * says.\n **/\nMarkdown.dialects.Gruber = {\n  block: {\n    atxHeader: function atxHeader( block, next ) {\n      var m = block.match( /^(#{1,6})\\s*(.*?)\\s*#*\\s*(?:\\n|$)/ );\n\n      if ( !m ) return undefined;\n\n      var header = [ \"header\", { level: m[ 1 ].length } ];\n      Array.prototype.push.apply(header, this.processInline(m[ 2 ]));\n\n      if ( m[0].length < block.length )\n        next.unshift( mk_block( block.substr( m[0].length ), block.trailing, block.lineNumber + 2 ) );\n\n      return [ header ];\n    },\n\n    setextHeader: function setextHeader( block, next ) {\n      var m = block.match( /^(.*)\\n([-=])\\2\\2+(?:\\n|$)/ );\n\n      if ( !m ) return undefined;\n\n      var level = ( m[ 2 ] === \"=\" ) ? 1 : 2;\n      var header = [ \"header\", { level : level }, m[ 1 ] ];\n\n      if ( m[0].length < block.length )\n        next.unshift( mk_block( block.substr( m[0].length ), block.trailing, block.lineNumber + 2 ) );\n\n      return [ header ];\n    },\n\n    code: function code( block, next ) {\n      // |    Foo\n      // |bar\n      // should be a code block followed by a paragraph. Fun\n      //\n      // There might also be adjacent code block to merge.\n\n      var ret = [],\n          re = /^(?: {0,3}\\t| {4})(.*)\\n?/,\n          lines;\n\n      // 4 spaces + content\n      if ( !block.match( re ) ) return undefined;\n\n      block_search:\n      do {\n        // Now pull out the rest of the lines\n        var b = this.loop_re_over_block(\n                  re, block.valueOf(), function( m ) { ret.push( m[1] ); } );\n\n        if ( b.length ) {\n          // Case alluded to in first comment. push it back on as a new block\n          next.unshift( mk_block(b, block.trailing) );\n          break block_search;\n        }\n        else if ( next.length ) {\n          // Check the next block - it might be code too\n          if ( !next[0].match( re ) ) break block_search;\n\n          // Pull how how many blanks lines follow - minus two to account for .join\n          ret.push ( block.trailing.replace(/[^\\n]/g, \"\").substring(2) );\n\n          block = next.shift();\n        }\n        else {\n          break block_search;\n        }\n      } while ( true );\n\n      return [ [ \"code_block\", ret.join(\"\\n\") ] ];\n    },\n\n    horizRule: function horizRule( block, next ) {\n      // this needs to find any hr in the block to handle abutting blocks\n      var m = block.match( /^(?:([\\s\\S]*?)\\n)?[ \\t]*([-_*])(?:[ \\t]*\\2){2,}[ \\t]*(?:\\n([\\s\\S]*))?$/ );\n\n      if ( !m ) {\n        return undefined;\n      }\n\n      var jsonml = [ [ \"hr\" ] ];\n\n      // if there's a leading abutting block, process it\n      if ( m[ 1 ] ) {\n        jsonml.unshift.apply( jsonml, this.processBlock( m[ 1 ], [] ) );\n      }\n\n      // if there's a trailing abutting block, stick it into next\n      if ( m[ 3 ] ) {\n        next.unshift( mk_block( m[ 3 ] ) );\n      }\n\n      return jsonml;\n    },\n\n    // There are two types of lists. Tight and loose. Tight lists have no whitespace\n    // between the items (and result in text just in the 
  • ) and loose lists,\n // which have an empty line between list items, resulting in (one or more)\n // paragraphs inside the
  • .\n //\n // There are all sorts weird edge cases about the original markdown.pl's\n // handling of lists:\n //\n // * Nested lists are supposed to be indented by four chars per level. But\n // if they aren't, you can get a nested list by indenting by less than\n // four so long as the indent doesn't match an indent of an existing list\n // item in the 'nest stack'.\n //\n // * The type of the list (bullet or number) is controlled just by the\n // first item at the indent. Subsequent changes are ignored unless they\n // are for nested lists\n //\n lists: (function( ) {\n // Use a closure to hide a few variables.\n var any_list = \"[*+-]|\\\\d+\\\\.\",\n bullet_list = /[*+-]/,\n number_list = /\\d+\\./,\n // Capture leading indent as it matters for determining nested lists.\n is_list_re = new RegExp( \"^( {0,3})(\" + any_list + \")[ \\t]+\" ),\n indent_re = \"(?: {0,3}\\\\t| {4})\";\n\n // TODO: Cache this regexp for certain depths.\n // Create a regexp suitable for matching an li for a given stack depth\n function regex_for_depth( depth ) {\n\n return new RegExp(\n // m[1] = indent, m[2] = list_type\n \"(?:^(\" + indent_re + \"{0,\" + depth + \"} {0,3})(\" + any_list + \")\\\\s+)|\" +\n // m[3] = cont\n \"(^\" + indent_re + \"{0,\" + (depth-1) + \"}[ ]{0,4})\"\n );\n }\n function expand_tab( input ) {\n return input.replace( / {0,3}\\t/g, \" \" );\n }\n\n // Add inline content `inline` to `li`. inline comes from processInline\n // so is an array of content\n function add(li, loose, inline, nl) {\n if ( loose ) {\n li.push( [ \"para\" ].concat(inline) );\n return;\n }\n // Hmmm, should this be any block level element or just paras?\n var add_to = li[li.length -1] instanceof Array && li[li.length - 1][0] == \"para\"\n ? li[li.length -1]\n : li;\n\n // If there is already some content in this list, add the new line in\n if ( nl && li.length > 1 ) inline.unshift(nl);\n\n for ( var i = 0; i < inline.length; i++ ) {\n var what = inline[i],\n is_str = typeof what == \"string\";\n if ( is_str && add_to.length > 1 && typeof add_to[add_to.length-1] == \"string\" ) {\n add_to[ add_to.length-1 ] += what;\n }\n else {\n add_to.push( what );\n }\n }\n }\n\n // contained means have an indent greater than the current one. On\n // *every* line in the block\n function get_contained_blocks( depth, blocks ) {\n\n var re = new RegExp( \"^(\" + indent_re + \"{\" + depth + \"}.*?\\\\n?)*$\" ),\n replace = new RegExp(\"^\" + indent_re + \"{\" + depth + \"}\", \"gm\"),\n ret = [];\n\n while ( blocks.length > 0 ) {\n if ( re.exec( blocks[0] ) ) {\n var b = blocks.shift(),\n // Now remove that indent\n x = b.replace( replace, \"\");\n\n ret.push( mk_block( x, b.trailing, b.lineNumber ) );\n }\n else {\n break;\n }\n }\n return ret;\n }\n\n // passed to stack.forEach to turn list items up the stack into paras\n function paragraphify(s, i, stack) {\n var list = s.list;\n var last_li = list[list.length-1];\n\n if ( last_li[1] instanceof Array && last_li[1][0] == \"para\" ) {\n return;\n }\n if ( i + 1 == stack.length ) {\n // Last stack frame\n // Keep the same array, but replace the contents\n last_li.push( [\"para\"].concat( last_li.splice(1, last_li.length - 1) ) );\n }\n else {\n var sublist = last_li.pop();\n last_li.push( [\"para\"].concat( last_li.splice(1, last_li.length - 1) ), sublist );\n }\n }\n\n // The matcher function\n return function( block, next ) {\n var m = block.match( is_list_re );\n if ( !m ) return undefined;\n\n function make_list( m ) {\n var list = bullet_list.exec( m[2] )\n ? [\"bulletlist\"]\n : [\"numberlist\"];\n\n stack.push( { list: list, indent: m[1] } );\n return list;\n }\n\n\n var stack = [], // Stack of lists for nesting.\n list = make_list( m ),\n last_li,\n loose = false,\n ret = [ stack[0].list ],\n i;\n\n // Loop to search over block looking for inner block elements and loose lists\n loose_search:\n while ( true ) {\n // Split into lines preserving new lines at end of line\n var lines = block.split( /(?=\\n)/ );\n\n // We have to grab all lines for a li and call processInline on them\n // once as there are some inline things that can span lines.\n var li_accumulate = \"\";\n\n // Loop over the lines in this block looking for tight lists.\n tight_search:\n for ( var line_no = 0; line_no < lines.length; line_no++ ) {\n var nl = \"\",\n l = lines[line_no].replace(/^\\n/, function(n) { nl = n; return \"\"; });\n\n // TODO: really should cache this\n var line_re = regex_for_depth( stack.length );\n\n m = l.match( line_re );\n //print( \"line:\", uneval(l), \"\\nline match:\", uneval(m) );\n\n // We have a list item\n if ( m[1] !== undefined ) {\n // Process the previous list item, if any\n if ( li_accumulate.length ) {\n add( last_li, loose, this.processInline( li_accumulate ), nl );\n // Loose mode will have been dealt with. Reset it\n loose = false;\n li_accumulate = \"\";\n }\n\n m[1] = expand_tab( m[1] );\n var wanted_depth = Math.floor(m[1].length/4)+1;\n //print( \"want:\", wanted_depth, \"stack:\", stack.length);\n if ( wanted_depth > stack.length ) {\n // Deep enough for a nested list outright\n //print ( \"new nested list\" );\n list = make_list( m );\n last_li.push( list );\n last_li = list[1] = [ \"listitem\" ];\n }\n else {\n // We aren't deep enough to be strictly a new level. This is\n // where Md.pl goes nuts. If the indent matches a level in the\n // stack, put it there, else put it one deeper then the\n // wanted_depth deserves.\n var found = false;\n for ( i = 0; i < stack.length; i++ ) {\n if ( stack[ i ].indent != m[1] ) continue;\n list = stack[ i ].list;\n stack.splice( i+1, stack.length - (i+1) );\n found = true;\n break;\n }\n\n if (!found) {\n //print(\"not found. l:\", uneval(l));\n wanted_depth++;\n if ( wanted_depth <= stack.length ) {\n stack.splice(wanted_depth, stack.length - wanted_depth);\n //print(\"Desired depth now\", wanted_depth, \"stack:\", stack.length);\n list = stack[wanted_depth-1].list;\n //print(\"list:\", uneval(list) );\n }\n else {\n //print (\"made new stack for messy indent\");\n list = make_list(m);\n last_li.push(list);\n }\n }\n\n //print( uneval(list), \"last\", list === stack[stack.length-1].list );\n last_li = [ \"listitem\" ];\n list.push(last_li);\n } // end depth of shenegains\n nl = \"\";\n }\n\n // Add content\n if ( l.length > m[0].length ) {\n li_accumulate += nl + l.substr( m[0].length );\n }\n } // tight_search\n\n if ( li_accumulate.length ) {\n add( last_li, loose, this.processInline( li_accumulate ), nl );\n // Loose mode will have been dealt with. Reset it\n loose = false;\n li_accumulate = \"\";\n }\n\n // Look at the next block - we might have a loose list. Or an extra\n // paragraph for the current li\n var contained = get_contained_blocks( stack.length, next );\n\n // Deal with code blocks or properly nested lists\n if ( contained.length > 0 ) {\n // Make sure all listitems up the stack are paragraphs\n forEach( stack, paragraphify, this);\n\n last_li.push.apply( last_li, this.toTree( contained, [] ) );\n }\n\n var next_block = next[0] && next[0].valueOf() || \"\";\n\n if ( next_block.match(is_list_re) || next_block.match( /^ / ) ) {\n block = next.shift();\n\n // Check for an HR following a list: features/lists/hr_abutting\n var hr = this.dialect.block.horizRule( block, next );\n\n if ( hr ) {\n ret.push.apply(ret, hr);\n break;\n }\n\n // Make sure all listitems up the stack are paragraphs\n forEach( stack, paragraphify, this);\n\n loose = true;\n continue loose_search;\n }\n break;\n } // loose_search\n\n return ret;\n };\n })(),\n\n blockquote: function blockquote( block, next ) {\n if ( !block.match( /^>/m ) )\n return undefined;\n\n var jsonml = [];\n\n // separate out the leading abutting block, if any. I.e. in this case:\n //\n // a\n // > b\n //\n if ( block[ 0 ] != \">\" ) {\n var lines = block.split( /\\n/ ),\n prev = [],\n line_no = block.lineNumber;\n\n // keep shifting lines until you find a crotchet\n while ( lines.length && lines[ 0 ][ 0 ] != \">\" ) {\n prev.push( lines.shift() );\n line_no++;\n }\n\n var abutting = mk_block( prev.join( \"\\n\" ), \"\\n\", block.lineNumber );\n jsonml.push.apply( jsonml, this.processBlock( abutting, [] ) );\n // reassemble new block of just block quotes!\n block = mk_block( lines.join( \"\\n\" ), block.trailing, line_no );\n }\n\n\n // if the next block is also a blockquote merge it in\n while ( next.length && next[ 0 ][ 0 ] == \">\" ) {\n var b = next.shift();\n block = mk_block( block + block.trailing + b, b.trailing, block.lineNumber );\n }\n\n // Strip off the leading \"> \" and re-process as a block.\n var input = block.replace( /^> ?/gm, \"\" ),\n old_tree = this.tree,\n processedBlock = this.toTree( input, [ \"blockquote\" ] ),\n attr = extract_attr( processedBlock );\n\n // If any link references were found get rid of them\n if ( attr && attr.references ) {\n delete attr.references;\n // And then remove the attribute object if it's empty\n if ( isEmpty( attr ) ) {\n processedBlock.splice( 1, 1 );\n }\n }\n\n jsonml.push( processedBlock );\n return jsonml;\n },\n\n referenceDefn: function referenceDefn( block, next) {\n var re = /^\\s*\\[(.*?)\\]:\\s*(\\S+)(?:\\s+(?:(['\"])(.*?)\\3|\\((.*?)\\)))?\\n?/;\n // interesting matches are [ , ref_id, url, , title, title ]\n\n if ( !block.match(re) )\n return undefined;\n\n // make an attribute node if it doesn't exist\n if ( !extract_attr( this.tree ) ) {\n this.tree.splice( 1, 0, {} );\n }\n\n var attrs = extract_attr( this.tree );\n\n // make a references hash if it doesn't exist\n if ( attrs.references === undefined ) {\n attrs.references = {};\n }\n\n var b = this.loop_re_over_block(re, block, function( m ) {\n\n if ( m[2] && m[2][0] == \"<\" && m[2][m[2].length-1] == \">\" )\n m[2] = m[2].substring( 1, m[2].length - 1 );\n\n var ref = attrs.references[ m[1].toLowerCase() ] = {\n href: m[2]\n };\n\n if ( m[4] !== undefined )\n ref.title = m[4];\n else if ( m[5] !== undefined )\n ref.title = m[5];\n\n } );\n\n if ( b.length )\n next.unshift( mk_block( b, block.trailing ) );\n\n return [];\n },\n\n para: function para( block, next ) {\n // everything's a para!\n return [ [\"para\"].concat( this.processInline( block ) ) ];\n }\n }\n};\n\nMarkdown.dialects.Gruber.inline = {\n\n __oneElement__: function oneElement( text, patterns_or_re, previous_nodes ) {\n var m,\n res,\n lastIndex = 0;\n\n patterns_or_re = patterns_or_re || this.dialect.inline.__patterns__;\n var re = new RegExp( \"([\\\\s\\\\S]*?)(\" + (patterns_or_re.source || patterns_or_re) + \")\" );\n\n m = re.exec( text );\n if (!m) {\n // Just boring text\n return [ text.length, text ];\n }\n else if ( m[1] ) {\n // Some un-interesting text matched. Return that first\n return [ m[1].length, m[1] ];\n }\n\n var res;\n if ( m[2] in this.dialect.inline ) {\n res = this.dialect.inline[ m[2] ].call(\n this,\n text.substr( m.index ), m, previous_nodes || [] );\n }\n // Default for now to make dev easier. just slurp special and output it.\n res = res || [ m[2].length, m[2] ];\n return res;\n },\n\n __call__: function inline( text, patterns ) {\n\n var out = [],\n res;\n\n function add(x) {\n //D:self.debug(\" adding output\", uneval(x));\n if ( typeof x == \"string\" && typeof out[out.length-1] == \"string\" )\n out[ out.length-1 ] += x;\n else\n out.push(x);\n }\n\n while ( text.length > 0 ) {\n res = this.dialect.inline.__oneElement__.call(this, text, patterns, out );\n text = text.substr( res.shift() );\n forEach(res, add )\n }\n\n return out;\n },\n\n // These characters are intersting elsewhere, so have rules for them so that\n // chunks of plain text blocks don't include them\n \"]\": function () {},\n \"}\": function () {},\n\n __escape__ : /^\\\\[\\\\`\\*_{}\\[\\]()#\\+.!\\-]/,\n\n \"\\\\\": function escaped( text ) {\n // [ length of input processed, node/children to add... ]\n // Only esacape: \\ ` * _ { } [ ] ( ) # * + - . !\n if ( this.dialect.inline.__escape__.exec( text ) )\n return [ 2, text.charAt( 1 ) ];\n else\n // Not an esacpe\n return [ 1, \"\\\\\" ];\n },\n\n \"![\": function image( text ) {\n\n // Unlike images, alt text is plain text only. no other elements are\n // allowed in there\n\n // ![Alt text](/path/to/img.jpg \"Optional title\")\n // 1 2 3 4 <--- captures\n var m = text.match( /^!\\[(.*?)\\][ \\t]*\\([ \\t]*([^\")]*?)(?:[ \\t]+([\"'])(.*?)\\3)?[ \\t]*\\)/ );\n\n if ( m ) {\n if ( m[2] && m[2][0] == \"<\" && m[2][m[2].length-1] == \">\" )\n m[2] = m[2].substring( 1, m[2].length - 1 );\n\n m[2] = this.dialect.inline.__call__.call( this, m[2], /\\\\/ )[0];\n\n var attrs = { alt: m[1], href: m[2] || \"\" };\n if ( m[4] !== undefined)\n attrs.title = m[4];\n\n return [ m[0].length, [ \"img\", attrs ] ];\n }\n\n // ![Alt text][id]\n m = text.match( /^!\\[(.*?)\\][ \\t]*\\[(.*?)\\]/ );\n\n if ( m ) {\n // We can't check if the reference is known here as it likely wont be\n // found till after. Check it in md tree->hmtl tree conversion\n return [ m[0].length, [ \"img_ref\", { alt: m[1], ref: m[2].toLowerCase(), original: m[0] } ] ];\n }\n\n // Just consume the '!['\n return [ 2, \"![\" ];\n },\n\n \"[\": function link( text ) {\n\n var orig = String(text);\n // Inline content is possible inside `link text`\n var res = Markdown.DialectHelpers.inline_until_char.call( this, text.substr(1), \"]\" );\n\n // No closing ']' found. Just consume the [\n if ( !res ) return [ 1, \"[\" ];\n\n var consumed = 1 + res[ 0 ],\n children = res[ 1 ],\n link,\n attrs;\n\n // At this point the first [...] has been parsed. See what follows to find\n // out which kind of link we are (reference or direct url)\n text = text.substr( consumed );\n\n // [link text](/path/to/img.jpg \"Optional title\")\n // 1 2 3 <--- captures\n // This will capture up to the last paren in the block. We then pull\n // back based on if there a matching ones in the url\n // ([here](/url/(test))\n // The parens have to be balanced\n var m = text.match( /^\\s*\\([ \\t]*([^\"']*)(?:[ \\t]+([\"'])(.*?)\\2)?[ \\t]*\\)/ );\n if ( m ) {\n var url = m[1];\n consumed += m[0].length;\n\n if ( url && url[0] == \"<\" && url[url.length-1] == \">\" )\n url = url.substring( 1, url.length - 1 );\n\n // If there is a title we don't have to worry about parens in the url\n if ( !m[3] ) {\n var open_parens = 1; // One open that isn't in the capture\n for ( var len = 0; len < url.length; len++ ) {\n switch ( url[len] ) {\n case \"(\":\n open_parens++;\n break;\n case \")\":\n if ( --open_parens == 0) {\n consumed -= url.length - len;\n url = url.substring(0, len);\n }\n break;\n }\n }\n }\n\n // Process escapes only\n url = this.dialect.inline.__call__.call( this, url, /\\\\/ )[0];\n\n attrs = { href: url || \"\" };\n if ( m[3] !== undefined)\n attrs.title = m[3];\n\n link = [ \"link\", attrs ].concat( children );\n return [ consumed, link ];\n }\n\n // [Alt text][id]\n // [Alt text] [id]\n m = text.match( /^\\s*\\[(.*?)\\]/ );\n\n if ( m ) {\n\n consumed += m[ 0 ].length;\n\n // [links][] uses links as its reference\n attrs = { ref: ( m[ 1 ] || String(children) ).toLowerCase(), original: orig.substr( 0, consumed ) };\n\n link = [ \"link_ref\", attrs ].concat( children );\n\n // We can't check if the reference is known here as it likely wont be\n // found till after. Check it in md tree->hmtl tree conversion.\n // Store the original so that conversion can revert if the ref isn't found.\n return [ consumed, link ];\n }\n\n // [id]\n // Only if id is plain (no formatting.)\n if ( children.length == 1 && typeof children[0] == \"string\" ) {\n\n attrs = { ref: children[0].toLowerCase(), original: orig.substr( 0, consumed ) };\n link = [ \"link_ref\", attrs, children[0] ];\n return [ consumed, link ];\n }\n\n // Just consume the \"[\"\n return [ 1, \"[\" ];\n },\n\n\n \"<\": function autoLink( text ) {\n var m;\n\n if ( ( m = text.match( /^<(?:((https?|ftp|mailto):[^>]+)|(.*?@.*?\\.[a-zA-Z]+))>/ ) ) != null ) {\n if ( m[3] ) {\n return [ m[0].length, [ \"link\", { href: \"mailto:\" + m[3] }, m[3] ] ];\n\n }\n else if ( m[2] == \"mailto\" ) {\n return [ m[0].length, [ \"link\", { href: m[1] }, m[1].substr(\"mailto:\".length ) ] ];\n }\n else\n return [ m[0].length, [ \"link\", { href: m[1] }, m[1] ] ];\n }\n\n return [ 1, \"<\" ];\n },\n\n \"`\": function inlineCode( text ) {\n // Inline code block. as many backticks as you like to start it\n // Always skip over the opening ticks.\n var m = text.match( /(`+)(([\\s\\S]*?)\\1)/ );\n\n if ( m && m[2] )\n return [ m[1].length + m[2].length, [ \"inlinecode\", m[3] ] ];\n else {\n // TODO: No matching end code found - warn!\n return [ 1, \"`\" ];\n }\n },\n\n \" \\n\": function lineBreak( text ) {\n return [ 3, [ \"linebreak\" ] ];\n }\n\n};\n\n// Meta Helper/generator method for em and strong handling\nfunction strong_em( tag, md ) {\n\n var state_slot = tag + \"_state\",\n other_slot = tag == \"strong\" ? \"em_state\" : \"strong_state\";\n\n function CloseTag(len) {\n this.len_after = len;\n this.name = \"close_\" + md;\n }\n\n return function ( text, orig_match ) {\n\n if ( this[state_slot][0] == md ) {\n // Most recent em is of this type\n //D:this.debug(\"closing\", md);\n this[state_slot].shift();\n\n // \"Consume\" everything to go back to the recrusion in the else-block below\n return[ text.length, new CloseTag(text.length-md.length) ];\n }\n else {\n // Store a clone of the em/strong states\n var other = this[other_slot].slice(),\n state = this[state_slot].slice();\n\n this[state_slot].unshift(md);\n\n //D:this.debug_indent += \" \";\n\n // Recurse\n var res = this.processInline( text.substr( md.length ) );\n //D:this.debug_indent = this.debug_indent.substr(2);\n\n var last = res[res.length - 1];\n\n //D:this.debug(\"processInline from\", tag + \": \", uneval( res ) );\n\n var check = this[state_slot].shift();\n if ( last instanceof CloseTag ) {\n res.pop();\n // We matched! Huzzah.\n var consumed = text.length - last.len_after;\n return [ consumed, [ tag ].concat(res) ];\n }\n else {\n // Restore the state of the other kind. We might have mistakenly closed it.\n this[other_slot] = other;\n this[state_slot] = state;\n\n // We can't reuse the processed result as it could have wrong parsing contexts in it.\n return [ md.length, md ];\n }\n }\n }; // End returned function\n}\n\nMarkdown.dialects.Gruber.inline[\"**\"] = strong_em(\"strong\", \"**\");\nMarkdown.dialects.Gruber.inline[\"__\"] = strong_em(\"strong\", \"__\");\nMarkdown.dialects.Gruber.inline[\"*\"] = strong_em(\"em\", \"*\");\nMarkdown.dialects.Gruber.inline[\"_\"] = strong_em(\"em\", \"_\");\n\n\n// Build default order from insertion order.\nMarkdown.buildBlockOrder = function(d) {\n var ord = [];\n for ( var i in d ) {\n if ( i == \"__order__\" || i == \"__call__\" ) continue;\n ord.push( i );\n }\n d.__order__ = ord;\n};\n\n// Build patterns for inline matcher\nMarkdown.buildInlinePatterns = function(d) {\n var patterns = [];\n\n for ( var i in d ) {\n // __foo__ is reserved and not a pattern\n if ( i.match( /^__.*__$/) ) continue;\n var l = i.replace( /([\\\\.*+?|()\\[\\]{}])/g, \"\\\\$1\" )\n .replace( /\\n/, \"\\\\n\" );\n patterns.push( i.length == 1 ? l : \"(?:\" + l + \")\" );\n }\n\n patterns = patterns.join(\"|\");\n d.__patterns__ = patterns;\n //print(\"patterns:\", uneval( patterns ) );\n\n var fn = d.__call__;\n d.__call__ = function(text, pattern) {\n if ( pattern != undefined ) {\n return fn.call(this, text, pattern);\n }\n else\n {\n return fn.call(this, text, patterns);\n }\n };\n};\n\nMarkdown.DialectHelpers = {};\nMarkdown.DialectHelpers.inline_until_char = function( text, want ) {\n var consumed = 0,\n nodes = [];\n\n while ( true ) {\n if ( text.charAt( consumed ) == want ) {\n // Found the character we were looking for\n consumed++;\n return [ consumed, nodes ];\n }\n\n if ( consumed >= text.length ) {\n // No closing char found. Abort.\n return null;\n }\n\n var res = this.dialect.inline.__oneElement__.call(this, text.substr( consumed ) );\n consumed += res[ 0 ];\n // Add any returned nodes.\n nodes.push.apply( nodes, res.slice( 1 ) );\n }\n}\n\n// Helper function to make sub-classing a dialect easier\nMarkdown.subclassDialect = function( d ) {\n function Block() {}\n Block.prototype = d.block;\n function Inline() {}\n Inline.prototype = d.inline;\n\n return { block: new Block(), inline: new Inline() };\n};\n\nMarkdown.buildBlockOrder ( Markdown.dialects.Gruber.block );\nMarkdown.buildInlinePatterns( Markdown.dialects.Gruber.inline );\n\nMarkdown.dialects.Maruku = Markdown.subclassDialect( Markdown.dialects.Gruber );\n\nMarkdown.dialects.Maruku.processMetaHash = function processMetaHash( meta_string ) {\n var meta = split_meta_hash( meta_string ),\n attr = {};\n\n for ( var i = 0; i < meta.length; ++i ) {\n // id: #foo\n if ( /^#/.test( meta[ i ] ) ) {\n attr.id = meta[ i ].substring( 1 );\n }\n // class: .foo\n else if ( /^\\./.test( meta[ i ] ) ) {\n // if class already exists, append the new one\n if ( attr[\"class\"] ) {\n attr[\"class\"] = attr[\"class\"] + meta[ i ].replace( /./, \" \" );\n }\n else {\n attr[\"class\"] = meta[ i ].substring( 1 );\n }\n }\n // attribute: foo=bar\n else if ( /\\=/.test( meta[ i ] ) ) {\n var s = meta[ i ].split( /\\=/ );\n attr[ s[ 0 ] ] = s[ 1 ];\n }\n }\n\n return attr;\n}\n\nfunction split_meta_hash( meta_string ) {\n var meta = meta_string.split( \"\" ),\n parts = [ \"\" ],\n in_quotes = false;\n\n while ( meta.length ) {\n var letter = meta.shift();\n switch ( letter ) {\n case \" \" :\n // if we're in a quoted section, keep it\n if ( in_quotes ) {\n parts[ parts.length - 1 ] += letter;\n }\n // otherwise make a new part\n else {\n parts.push( \"\" );\n }\n break;\n case \"'\" :\n case '\"' :\n // reverse the quotes and move straight on\n in_quotes = !in_quotes;\n break;\n case \"\\\\\" :\n // shift off the next letter to be used straight away.\n // it was escaped so we'll keep it whatever it is\n letter = meta.shift();\n default :\n parts[ parts.length - 1 ] += letter;\n break;\n }\n }\n\n return parts;\n}\n\nMarkdown.dialects.Maruku.block.document_meta = function document_meta( block, next ) {\n // we're only interested in the first block\n if ( block.lineNumber > 1 ) return undefined;\n\n // document_meta blocks consist of one or more lines of `Key: Value\\n`\n if ( ! block.match( /^(?:\\w+:.*\\n)*\\w+:.*$/ ) ) return undefined;\n\n // make an attribute node if it doesn't exist\n if ( !extract_attr( this.tree ) ) {\n this.tree.splice( 1, 0, {} );\n }\n\n var pairs = block.split( /\\n/ );\n for ( p in pairs ) {\n var m = pairs[ p ].match( /(\\w+):\\s*(.*)$/ ),\n key = m[ 1 ].toLowerCase(),\n value = m[ 2 ];\n\n this.tree[ 1 ][ key ] = value;\n }\n\n // document_meta produces no content!\n return [];\n};\n\nMarkdown.dialects.Maruku.block.block_meta = function block_meta( block, next ) {\n // check if the last line of the block is an meta hash\n var m = block.match( /(^|\\n) {0,3}\\{:\\s*((?:\\\\\\}|[^\\}])*)\\s*\\}$/ );\n if ( !m ) return undefined;\n\n // process the meta hash\n var attr = this.dialect.processMetaHash( m[ 2 ] );\n\n var hash;\n\n // if we matched ^ then we need to apply meta to the previous block\n if ( m[ 1 ] === \"\" ) {\n var node = this.tree[ this.tree.length - 1 ];\n hash = extract_attr( node );\n\n // if the node is a string (rather than JsonML), bail\n if ( typeof node === \"string\" ) return undefined;\n\n // create the attribute hash if it doesn't exist\n if ( !hash ) {\n hash = {};\n node.splice( 1, 0, hash );\n }\n\n // add the attributes in\n for ( a in attr ) {\n hash[ a ] = attr[ a ];\n }\n\n // return nothing so the meta hash is removed\n return [];\n }\n\n // pull the meta hash off the block and process what's left\n var b = block.replace( /\\n.*$/, \"\" ),\n result = this.processBlock( b, [] );\n\n // get or make the attributes hash\n hash = extract_attr( result[ 0 ] );\n if ( !hash ) {\n hash = {};\n result[ 0 ].splice( 1, 0, hash );\n }\n\n // attach the attributes to the block\n for ( a in attr ) {\n hash[ a ] = attr[ a ];\n }\n\n return result;\n};\n\nMarkdown.dialects.Maruku.block.definition_list = function definition_list( block, next ) {\n // one or more terms followed by one or more definitions, in a single block\n var tight = /^((?:[^\\s:].*\\n)+):\\s+([\\s\\S]+)$/,\n list = [ \"dl\" ],\n i, m;\n\n // see if we're dealing with a tight or loose block\n if ( ( m = block.match( tight ) ) ) {\n // pull subsequent tight DL blocks out of `next`\n var blocks = [ block ];\n while ( next.length && tight.exec( next[ 0 ] ) ) {\n blocks.push( next.shift() );\n }\n\n for ( var b = 0; b < blocks.length; ++b ) {\n var m = blocks[ b ].match( tight ),\n terms = m[ 1 ].replace( /\\n$/, \"\" ).split( /\\n/ ),\n defns = m[ 2 ].split( /\\n:\\s+/ );\n\n // print( uneval( m ) );\n\n for ( i = 0; i < terms.length; ++i ) {\n list.push( [ \"dt\", terms[ i ] ] );\n }\n\n for ( i = 0; i < defns.length; ++i ) {\n // run inline processing over the definition\n list.push( [ \"dd\" ].concat( this.processInline( defns[ i ].replace( /(\\n)\\s+/, \"$1\" ) ) ) );\n }\n }\n }\n else {\n return undefined;\n }\n\n return [ list ];\n};\n\n// splits on unescaped instances of @ch. If @ch is not a character the result\n// can be unpredictable\n\nMarkdown.dialects.Maruku.block.table = function table (block, next) {\n\n var _split_on_unescaped = function(s, ch) {\n ch = ch || '\\\\s';\n if (ch.match(/^[\\\\|\\[\\]{}?*.+^$]$/)) { ch = '\\\\' + ch; }\n var res = [ ],\n r = new RegExp('^((?:\\\\\\\\.|[^\\\\\\\\' + ch + '])*)' + ch + '(.*)'),\n m;\n while(m = s.match(r)) {\n res.push(m[1]);\n s = m[2];\n }\n res.push(s);\n return res;\n }\n\n var leading_pipe = /^ {0,3}\\|(.+)\\n {0,3}\\|\\s*([\\-:]+[\\-| :]*)\\n((?:\\s*\\|.*(?:\\n|$))*)(?=\\n|$)/,\n // find at least an unescaped pipe in each line\n no_leading_pipe = /^ {0,3}(\\S(?:\\\\.|[^\\\\|])*\\|.*)\\n {0,3}([\\-:]+\\s*\\|[\\-| :]*)\\n((?:(?:\\\\.|[^\\\\|])*\\|.*(?:\\n|$))*)(?=\\n|$)/,\n i, m;\n if (m = block.match(leading_pipe)) {\n // remove leading pipes in contents\n // (header and horizontal rule already have the leading pipe left out)\n m[3] = m[3].replace(/^\\s*\\|/gm, '');\n } else if (! ( m = block.match(no_leading_pipe))) {\n return undefined;\n }\n\n var table = [ \"table\", [ \"thead\", [ \"tr\" ] ], [ \"tbody\" ] ];\n\n // remove trailing pipes, then split on pipes\n // (no escaped pipes are allowed in horizontal rule)\n m[2] = m[2].replace(/\\|\\s*$/, '').split('|');\n\n // process alignment\n var html_attrs = [ ];\n forEach (m[2], function (s) {\n if (s.match(/^\\s*-+:\\s*$/)) html_attrs.push({align: \"right\"});\n else if (s.match(/^\\s*:-+\\s*$/)) html_attrs.push({align: \"left\"});\n else if (s.match(/^\\s*:-+:\\s*$/)) html_attrs.push({align: \"center\"});\n else html_attrs.push({});\n });\n\n // now for the header, avoid escaped pipes\n m[1] = _split_on_unescaped(m[1].replace(/\\|\\s*$/, ''), '|');\n for (i = 0; i < m[1].length; i++) {\n table[1][1].push(['th', html_attrs[i] || {}].concat(\n this.processInline(m[1][i].trim())));\n }\n\n // now for body contents\n forEach (m[3].replace(/\\|\\s*$/mg, '').split('\\n'), function (row) {\n var html_row = ['tr'];\n row = _split_on_unescaped(row, '|');\n for (i = 0; i < row.length; i++) {\n html_row.push(['td', html_attrs[i] || {}].concat(this.processInline(row[i].trim())));\n }\n table[2].push(html_row);\n }, this);\n\n return [table];\n}\n\nMarkdown.dialects.Maruku.inline[ \"{:\" ] = function inline_meta( text, matches, out ) {\n if ( !out.length ) {\n return [ 2, \"{:\" ];\n }\n\n // get the preceeding element\n var before = out[ out.length - 1 ];\n\n if ( typeof before === \"string\" ) {\n return [ 2, \"{:\" ];\n }\n\n // match a meta hash\n var m = text.match( /^\\{:\\s*((?:\\\\\\}|[^\\}])*)\\s*\\}/ );\n\n // no match, false alarm\n if ( !m ) {\n return [ 2, \"{:\" ];\n }\n\n // attach the attributes to the preceeding element\n var meta = this.dialect.processMetaHash( m[ 1 ] ),\n attr = extract_attr( before );\n\n if ( !attr ) {\n attr = {};\n before.splice( 1, 0, attr );\n }\n\n for ( var k in meta ) {\n attr[ k ] = meta[ k ];\n }\n\n // cut out the string and replace it with nothing\n return [ m[ 0 ].length, \"\" ];\n};\n\nMarkdown.dialects.Maruku.inline.__escape__ = /^\\\\[\\\\`\\*_{}\\[\\]()#\\+.!\\-|:]/;\n\nMarkdown.buildBlockOrder ( Markdown.dialects.Maruku.block );\nMarkdown.buildInlinePatterns( Markdown.dialects.Maruku.inline );\n\nvar isArray = Array.isArray || function(obj) {\n return Object.prototype.toString.call(obj) == \"[object Array]\";\n};\n\nvar forEach;\n// Don't mess with Array.prototype. Its not friendly\nif ( Array.prototype.forEach ) {\n forEach = function( arr, cb, thisp ) {\n return arr.forEach( cb, thisp );\n };\n}\nelse {\n forEach = function(arr, cb, thisp) {\n for (var i = 0; i < arr.length; i++) {\n cb.call(thisp || arr, arr[i], i, arr);\n }\n }\n}\n\nvar isEmpty = function( obj ) {\n for ( var key in obj ) {\n if ( hasOwnProperty.call( obj, key ) ) {\n return false;\n }\n }\n\n return true;\n}\n\nfunction extract_attr( jsonml ) {\n return isArray(jsonml)\n && jsonml.length > 1\n && typeof jsonml[ 1 ] === \"object\"\n && !( isArray(jsonml[ 1 ]) )\n ? jsonml[ 1 ]\n : undefined;\n}\n\n\n\n/**\n * renderJsonML( jsonml[, options] ) -> String\n * - jsonml (Array): JsonML array to render to XML\n * - options (Object): options\n *\n * Converts the given JsonML into well-formed XML.\n *\n * The options currently understood are:\n *\n * - root (Boolean): wether or not the root node should be included in the\n * output, or just its children. The default `false` is to not include the\n * root itself.\n */\nexpose.renderJsonML = function( jsonml, options ) {\n options = options || {};\n // include the root element in the rendered output?\n options.root = options.root || false;\n\n var content = [];\n\n if ( options.root ) {\n content.push( render_tree( jsonml ) );\n }\n else {\n jsonml.shift(); // get rid of the tag\n if ( jsonml.length && typeof jsonml[ 0 ] === \"object\" && !( jsonml[ 0 ] instanceof Array ) ) {\n jsonml.shift(); // get rid of the attributes\n }\n\n while ( jsonml.length ) {\n content.push( render_tree( jsonml.shift() ) );\n }\n }\n\n return content.join( \"\\n\\n\" );\n};\n\nfunction escapeHTML( text ) {\n return text.replace( /&/g, \"&\" )\n .replace( //g, \">\" )\n .replace( /\"/g, \""\" )\n .replace( /'/g, \"'\" );\n}\n\nfunction render_tree( jsonml ) {\n // basic case\n if ( typeof jsonml === \"string\" ) {\n return escapeHTML( jsonml );\n }\n\n var tag = jsonml.shift(),\n attributes = {},\n content = [];\n\n if ( jsonml.length && typeof jsonml[ 0 ] === \"object\" && !( jsonml[ 0 ] instanceof Array ) ) {\n attributes = jsonml.shift();\n }\n\n while ( jsonml.length ) {\n content.push( render_tree( jsonml.shift() ) );\n }\n\n var tag_attrs = \"\";\n for ( var a in attributes ) {\n tag_attrs += \" \" + a + '=\"' + escapeHTML( attributes[ a ] ) + '\"';\n }\n\n // be careful about adding whitespace here for inline elements\n if ( tag == \"img\" || tag == \"br\" || tag == \"hr\" ) {\n return \"<\"+ tag + tag_attrs + \"/>\";\n }\n else {\n return \"<\"+ tag + tag_attrs + \">\" + content.join( \"\" ) + \"\";\n }\n}\n\nfunction convert_tree_to_html( tree, references, options ) {\n var i;\n options = options || {};\n\n // shallow clone\n var jsonml = tree.slice( 0 );\n\n if ( typeof options.preprocessTreeNode === \"function\" ) {\n jsonml = options.preprocessTreeNode(jsonml, references);\n }\n\n // Clone attributes if they exist\n var attrs = extract_attr( jsonml );\n if ( attrs ) {\n jsonml[ 1 ] = {};\n for ( i in attrs ) {\n jsonml[ 1 ][ i ] = attrs[ i ];\n }\n attrs = jsonml[ 1 ];\n }\n\n // basic case\n if ( typeof jsonml === \"string\" ) {\n return jsonml;\n }\n\n // convert this node\n switch ( jsonml[ 0 ] ) {\n case \"header\":\n jsonml[ 0 ] = \"h\" + jsonml[ 1 ].level;\n delete jsonml[ 1 ].level;\n break;\n case \"bulletlist\":\n jsonml[ 0 ] = \"ul\";\n break;\n case \"numberlist\":\n jsonml[ 0 ] = \"ol\";\n break;\n case \"listitem\":\n jsonml[ 0 ] = \"li\";\n break;\n case \"para\":\n jsonml[ 0 ] = \"p\";\n break;\n case \"markdown\":\n jsonml[ 0 ] = \"html\";\n if ( attrs ) delete attrs.references;\n break;\n case \"code_block\":\n jsonml[ 0 ] = \"pre\";\n i = attrs ? 2 : 1;\n var code = [ \"code\" ];\n code.push.apply( code, jsonml.splice( i, jsonml.length - i ) );\n jsonml[ i ] = code;\n break;\n case \"inlinecode\":\n jsonml[ 0 ] = \"code\";\n break;\n case \"img\":\n jsonml[ 1 ].src = jsonml[ 1 ].href;\n delete jsonml[ 1 ].href;\n break;\n case \"linebreak\":\n jsonml[ 0 ] = \"br\";\n break;\n case \"link\":\n jsonml[ 0 ] = \"a\";\n break;\n case \"link_ref\":\n jsonml[ 0 ] = \"a\";\n\n // grab this ref and clean up the attribute node\n var ref = references[ attrs.ref ];\n\n // if the reference exists, make the link\n if ( ref ) {\n delete attrs.ref;\n\n // add in the href and title, if present\n attrs.href = ref.href;\n if ( ref.title ) {\n attrs.title = ref.title;\n }\n\n // get rid of the unneeded original text\n delete attrs.original;\n }\n // the reference doesn't exist, so revert to plain text\n else {\n return attrs.original;\n }\n break;\n case \"img_ref\":\n jsonml[ 0 ] = \"img\";\n\n // grab this ref and clean up the attribute node\n var ref = references[ attrs.ref ];\n\n // if the reference exists, make the link\n if ( ref ) {\n delete attrs.ref;\n\n // add in the href and title, if present\n attrs.src = ref.href;\n if ( ref.title ) {\n attrs.title = ref.title;\n }\n\n // get rid of the unneeded original text\n delete attrs.original;\n }\n // the reference doesn't exist, so revert to plain text\n else {\n return attrs.original;\n }\n break;\n }\n\n // convert all the children\n i = 1;\n\n // deal with the attribute node, if it exists\n if ( attrs ) {\n // if there are keys, skip over it\n for ( var key in jsonml[ 1 ] ) {\n i = 2;\n break;\n }\n // if there aren't, remove it\n if ( i === 1 ) {\n jsonml.splice( i, 1 );\n }\n }\n\n for ( ; i < jsonml.length; ++i ) {\n jsonml[ i ] = convert_tree_to_html( jsonml[ i ], references, options );\n }\n\n return jsonml;\n}\n\n\n// merges adjacent text nodes into a single node\nfunction merge_text_nodes( jsonml ) {\n // skip the tag name and attribute hash\n var i = extract_attr( jsonml ) ? 2 : 1;\n\n while ( i < jsonml.length ) {\n // if it's a string check the next item too\n if ( typeof jsonml[ i ] === \"string\" ) {\n if ( i + 1 < jsonml.length && typeof jsonml[ i + 1 ] === \"string\" ) {\n // merge the second string into the first and remove it\n jsonml[ i ] += jsonml.splice( i + 1, 1 )[ 0 ];\n }\n else {\n ++i;\n }\n }\n // if it's not a string recurse\n else {\n merge_text_nodes( jsonml[ i ] );\n ++i;\n }\n }\n}\n\n} )( (function() {\n if ( false ) {\n window.markdown = {};\n return window.markdown;\n }\n else {\n return exports;\n }\n} )() );\n\n\n/***/ }),\n\n/***/ 1407:\n/***/ (function(module, exports, __webpack_require__) {\n\n/* WEBPACK VAR INJECTION */(function(global, process) {// Copyright Joyent, Inc. and other Node contributors.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a\n// 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 permit\n// persons to whom the Software is furnished to do so, subject to the\n// following conditions:\n//\n// The above copyright notice and this permission notice shall be included\n// in all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS\n// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\n// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN\n// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR\n// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE\n// USE OR OTHER DEALINGS IN THE SOFTWARE.\n\nvar formatRegExp = /%[sdj%]/g;\nexports.format = function(f) {\n if (!isString(f)) {\n var objects = [];\n for (var i = 0; i < arguments.length; i++) {\n objects.push(inspect(arguments[i]));\n }\n return objects.join(' ');\n }\n\n var i = 1;\n var args = arguments;\n var len = args.length;\n var str = String(f).replace(formatRegExp, function(x) {\n if (x === '%%') return '%';\n if (i >= len) return x;\n switch (x) {\n case '%s': return String(args[i++]);\n case '%d': return Number(args[i++]);\n case '%j':\n try {\n return JSON.stringify(args[i++]);\n } catch (_) {\n return '[Circular]';\n }\n default:\n return x;\n }\n });\n for (var x = args[i]; i < len; x = args[++i]) {\n if (isNull(x) || !isObject(x)) {\n str += ' ' + x;\n } else {\n str += ' ' + inspect(x);\n }\n }\n return str;\n};\n\n\n// Mark that a method should not be used.\n// Returns a modified function which warns once by default.\n// If --no-deprecation is set, then it is a no-op.\nexports.deprecate = function(fn, msg) {\n // Allow for deprecating things in the process of starting up.\n if (isUndefined(global.process)) {\n return function() {\n return exports.deprecate(fn, msg).apply(this, arguments);\n };\n }\n\n if (process.noDeprecation === true) {\n return fn;\n }\n\n var warned = false;\n function deprecated() {\n if (!warned) {\n if (process.throwDeprecation) {\n throw new Error(msg);\n } else if (process.traceDeprecation) {\n console.trace(msg);\n } else {\n console.error(msg);\n }\n warned = true;\n }\n return fn.apply(this, arguments);\n }\n\n return deprecated;\n};\n\n\nvar debugs = {};\nvar debugEnviron;\nexports.debuglog = function(set) {\n if (isUndefined(debugEnviron))\n debugEnviron = process.env.NODE_DEBUG || '';\n set = set.toUpperCase();\n if (!debugs[set]) {\n if (new RegExp('\\\\b' + set + '\\\\b', 'i').test(debugEnviron)) {\n var pid = process.pid;\n debugs[set] = function() {\n var msg = exports.format.apply(exports, arguments);\n console.error('%s %d: %s', set, pid, msg);\n };\n } else {\n debugs[set] = function() {};\n }\n }\n return debugs[set];\n};\n\n\n/**\n * Echos the value of a value. Trys to print the value out\n * in the best way possible given the different types.\n *\n * @param {Object} obj The object to print out.\n * @param {Object} opts Optional options object that alters the output.\n */\n/* legacy: obj, showHidden, depth, colors*/\nfunction inspect(obj, opts) {\n // default options\n var ctx = {\n seen: [],\n stylize: stylizeNoColor\n };\n // legacy...\n if (arguments.length >= 3) ctx.depth = arguments[2];\n if (arguments.length >= 4) ctx.colors = arguments[3];\n if (isBoolean(opts)) {\n // legacy...\n ctx.showHidden = opts;\n } else if (opts) {\n // got an \"options\" object\n exports._extend(ctx, opts);\n }\n // set default options\n if (isUndefined(ctx.showHidden)) ctx.showHidden = false;\n if (isUndefined(ctx.depth)) ctx.depth = 2;\n if (isUndefined(ctx.colors)) ctx.colors = false;\n if (isUndefined(ctx.customInspect)) ctx.customInspect = true;\n if (ctx.colors) ctx.stylize = stylizeWithColor;\n return formatValue(ctx, obj, ctx.depth);\n}\nexports.inspect = inspect;\n\n\n// http://en.wikipedia.org/wiki/ANSI_escape_code#graphics\ninspect.colors = {\n 'bold' : [1, 22],\n 'italic' : [3, 23],\n 'underline' : [4, 24],\n 'inverse' : [7, 27],\n 'white' : [37, 39],\n 'grey' : [90, 39],\n 'black' : [30, 39],\n 'blue' : [34, 39],\n 'cyan' : [36, 39],\n 'green' : [32, 39],\n 'magenta' : [35, 39],\n 'red' : [31, 39],\n 'yellow' : [33, 39]\n};\n\n// Don't use 'blue' not visible on cmd.exe\ninspect.styles = {\n 'special': 'cyan',\n 'number': 'yellow',\n 'boolean': 'yellow',\n 'undefined': 'grey',\n 'null': 'bold',\n 'string': 'green',\n 'date': 'magenta',\n // \"name\": intentionally not styling\n 'regexp': 'red'\n};\n\n\nfunction stylizeWithColor(str, styleType) {\n var style = inspect.styles[styleType];\n\n if (style) {\n return '\\u001b[' + inspect.colors[style][0] + 'm' + str +\n '\\u001b[' + inspect.colors[style][1] + 'm';\n } else {\n return str;\n }\n}\n\n\nfunction stylizeNoColor(str, styleType) {\n return str;\n}\n\n\nfunction arrayToHash(array) {\n var hash = {};\n\n array.forEach(function(val, idx) {\n hash[val] = true;\n });\n\n return hash;\n}\n\n\nfunction formatValue(ctx, value, recurseTimes) {\n // Provide a hook for user-specified inspect functions.\n // Check that value is an object with an inspect function on it\n if (ctx.customInspect &&\n value &&\n isFunction(value.inspect) &&\n // Filter out the util module, it's inspect function is special\n value.inspect !== exports.inspect &&\n // Also filter out any prototype objects using the circular check.\n !(value.constructor && value.constructor.prototype === value)) {\n var ret = value.inspect(recurseTimes, ctx);\n if (!isString(ret)) {\n ret = formatValue(ctx, ret, recurseTimes);\n }\n return ret;\n }\n\n // Primitive types cannot have properties\n var primitive = formatPrimitive(ctx, value);\n if (primitive) {\n return primitive;\n }\n\n // Look up the keys of the object.\n var keys = Object.keys(value);\n var visibleKeys = arrayToHash(keys);\n\n if (ctx.showHidden) {\n keys = Object.getOwnPropertyNames(value);\n }\n\n // IE doesn't make error fields non-enumerable\n // http://msdn.microsoft.com/en-us/library/ie/dww52sbt(v=vs.94).aspx\n if (isError(value)\n && (keys.indexOf('message') >= 0 || keys.indexOf('description') >= 0)) {\n return formatError(value);\n }\n\n // Some type of object without properties can be shortcutted.\n if (keys.length === 0) {\n if (isFunction(value)) {\n var name = value.name ? ': ' + value.name : '';\n return ctx.stylize('[Function' + name + ']', 'special');\n }\n if (isRegExp(value)) {\n return ctx.stylize(RegExp.prototype.toString.call(value), 'regexp');\n }\n if (isDate(value)) {\n return ctx.stylize(Date.prototype.toString.call(value), 'date');\n }\n if (isError(value)) {\n return formatError(value);\n }\n }\n\n var base = '', array = false, braces = ['{', '}'];\n\n // Make Array say that they are Array\n if (isArray(value)) {\n array = true;\n braces = ['[', ']'];\n }\n\n // Make functions say that they are functions\n if (isFunction(value)) {\n var n = value.name ? ': ' + value.name : '';\n base = ' [Function' + n + ']';\n }\n\n // Make RegExps say that they are RegExps\n if (isRegExp(value)) {\n base = ' ' + RegExp.prototype.toString.call(value);\n }\n\n // Make dates with properties first say the date\n if (isDate(value)) {\n base = ' ' + Date.prototype.toUTCString.call(value);\n }\n\n // Make error with message first say the error\n if (isError(value)) {\n base = ' ' + formatError(value);\n }\n\n if (keys.length === 0 && (!array || value.length == 0)) {\n return braces[0] + base + braces[1];\n }\n\n if (recurseTimes < 0) {\n if (isRegExp(value)) {\n return ctx.stylize(RegExp.prototype.toString.call(value), 'regexp');\n } else {\n return ctx.stylize('[Object]', 'special');\n }\n }\n\n ctx.seen.push(value);\n\n var output;\n if (array) {\n output = formatArray(ctx, value, recurseTimes, visibleKeys, keys);\n } else {\n output = keys.map(function(key) {\n return formatProperty(ctx, value, recurseTimes, visibleKeys, key, array);\n });\n }\n\n ctx.seen.pop();\n\n return reduceToSingleString(output, base, braces);\n}\n\n\nfunction formatPrimitive(ctx, value) {\n if (isUndefined(value))\n return ctx.stylize('undefined', 'undefined');\n if (isString(value)) {\n var simple = '\\'' + JSON.stringify(value).replace(/^\"|\"$/g, '')\n .replace(/'/g, \"\\\\'\")\n .replace(/\\\\\"/g, '\"') + '\\'';\n return ctx.stylize(simple, 'string');\n }\n if (isNumber(value))\n return ctx.stylize('' + value, 'number');\n if (isBoolean(value))\n return ctx.stylize('' + value, 'boolean');\n // For some reason typeof null is \"object\", so special case here.\n if (isNull(value))\n return ctx.stylize('null', 'null');\n}\n\n\nfunction formatError(value) {\n return '[' + Error.prototype.toString.call(value) + ']';\n}\n\n\nfunction formatArray(ctx, value, recurseTimes, visibleKeys, keys) {\n var output = [];\n for (var i = 0, l = value.length; i < l; ++i) {\n if (hasOwnProperty(value, String(i))) {\n output.push(formatProperty(ctx, value, recurseTimes, visibleKeys,\n String(i), true));\n } else {\n output.push('');\n }\n }\n keys.forEach(function(key) {\n if (!key.match(/^\\d+$/)) {\n output.push(formatProperty(ctx, value, recurseTimes, visibleKeys,\n key, true));\n }\n });\n return output;\n}\n\n\nfunction formatProperty(ctx, value, recurseTimes, visibleKeys, key, array) {\n var name, str, desc;\n desc = Object.getOwnPropertyDescriptor(value, key) || { value: value[key] };\n if (desc.get) {\n if (desc.set) {\n str = ctx.stylize('[Getter/Setter]', 'special');\n } else {\n str = ctx.stylize('[Getter]', 'special');\n }\n } else {\n if (desc.set) {\n str = ctx.stylize('[Setter]', 'special');\n }\n }\n if (!hasOwnProperty(visibleKeys, key)) {\n name = '[' + key + ']';\n }\n if (!str) {\n if (ctx.seen.indexOf(desc.value) < 0) {\n if (isNull(recurseTimes)) {\n str = formatValue(ctx, desc.value, null);\n } else {\n str = formatValue(ctx, desc.value, recurseTimes - 1);\n }\n if (str.indexOf('\\n') > -1) {\n if (array) {\n str = str.split('\\n').map(function(line) {\n return ' ' + line;\n }).join('\\n').substr(2);\n } else {\n str = '\\n' + str.split('\\n').map(function(line) {\n return ' ' + line;\n }).join('\\n');\n }\n }\n } else {\n str = ctx.stylize('[Circular]', 'special');\n }\n }\n if (isUndefined(name)) {\n if (array && key.match(/^\\d+$/)) {\n return str;\n }\n name = JSON.stringify('' + key);\n if (name.match(/^\"([a-zA-Z_][a-zA-Z_0-9]*)\"$/)) {\n name = name.substr(1, name.length - 2);\n name = ctx.stylize(name, 'name');\n } else {\n name = name.replace(/'/g, \"\\\\'\")\n .replace(/\\\\\"/g, '\"')\n .replace(/(^\"|\"$)/g, \"'\");\n name = ctx.stylize(name, 'string');\n }\n }\n\n return name + ': ' + str;\n}\n\n\nfunction reduceToSingleString(output, base, braces) {\n var numLinesEst = 0;\n var length = output.reduce(function(prev, cur) {\n numLinesEst++;\n if (cur.indexOf('\\n') >= 0) numLinesEst++;\n return prev + cur.replace(/\\u001b\\[\\d\\d?m/g, '').length + 1;\n }, 0);\n\n if (length > 60) {\n return braces[0] +\n (base === '' ? '' : base + '\\n ') +\n ' ' +\n output.join(',\\n ') +\n ' ' +\n braces[1];\n }\n\n return braces[0] + base + ' ' + output.join(', ') + ' ' + braces[1];\n}\n\n\n// NOTE: These type checking functions intentionally don't use `instanceof`\n// because it is fragile and can be easily faked with `Object.create()`.\nfunction isArray(ar) {\n return Array.isArray(ar);\n}\nexports.isArray = isArray;\n\nfunction isBoolean(arg) {\n return typeof arg === 'boolean';\n}\nexports.isBoolean = isBoolean;\n\nfunction isNull(arg) {\n return arg === null;\n}\nexports.isNull = isNull;\n\nfunction isNullOrUndefined(arg) {\n return arg == null;\n}\nexports.isNullOrUndefined = isNullOrUndefined;\n\nfunction isNumber(arg) {\n return typeof arg === 'number';\n}\nexports.isNumber = isNumber;\n\nfunction isString(arg) {\n return typeof arg === 'string';\n}\nexports.isString = isString;\n\nfunction isSymbol(arg) {\n return typeof arg === 'symbol';\n}\nexports.isSymbol = isSymbol;\n\nfunction isUndefined(arg) {\n return arg === void 0;\n}\nexports.isUndefined = isUndefined;\n\nfunction isRegExp(re) {\n return isObject(re) && objectToString(re) === '[object RegExp]';\n}\nexports.isRegExp = isRegExp;\n\nfunction isObject(arg) {\n return typeof arg === 'object' && arg !== null;\n}\nexports.isObject = isObject;\n\nfunction isDate(d) {\n return isObject(d) && objectToString(d) === '[object Date]';\n}\nexports.isDate = isDate;\n\nfunction isError(e) {\n return isObject(e) &&\n (objectToString(e) === '[object Error]' || e instanceof Error);\n}\nexports.isError = isError;\n\nfunction isFunction(arg) {\n return typeof arg === 'function';\n}\nexports.isFunction = isFunction;\n\nfunction isPrimitive(arg) {\n return arg === null ||\n typeof arg === 'boolean' ||\n typeof arg === 'number' ||\n typeof arg === 'string' ||\n typeof arg === 'symbol' || // ES6 symbol\n typeof arg === 'undefined';\n}\nexports.isPrimitive = isPrimitive;\n\nexports.isBuffer = __webpack_require__(1408);\n\nfunction objectToString(o) {\n return Object.prototype.toString.call(o);\n}\n\n\nfunction pad(n) {\n return n < 10 ? '0' + n.toString(10) : n.toString(10);\n}\n\n\nvar months = ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep',\n 'Oct', 'Nov', 'Dec'];\n\n// 26 Feb 16:19:34\nfunction timestamp() {\n var d = new Date();\n var time = [pad(d.getHours()),\n pad(d.getMinutes()),\n pad(d.getSeconds())].join(':');\n return [d.getDate(), months[d.getMonth()], time].join(' ');\n}\n\n\n// log is just a thin wrapper to console.log that prepends a timestamp\nexports.log = function() {\n console.log('%s - %s', timestamp(), exports.format.apply(exports, arguments));\n};\n\n\n/**\n * Inherit the prototype methods from one constructor into another.\n *\n * The Function.prototype.inherits from lang.js rewritten as a standalone\n * function (not on Function.prototype). NOTE: If this file is to be loaded\n * during bootstrapping this function needs to be rewritten using some native\n * functions as prototype setup using normal JavaScript does not work as\n * expected during bootstrapping (see mirror.js in r114903).\n *\n * @param {function} ctor Constructor function which needs to inherit the\n * prototype.\n * @param {function} superCtor Constructor function to inherit prototype from.\n */\nexports.inherits = __webpack_require__(1409);\n\nexports._extend = function(origin, add) {\n // Don't do anything if add isn't an object\n if (!add || !isObject(add)) return origin;\n\n var keys = Object.keys(add);\n var i = keys.length;\n while (i--) {\n origin[keys[i]] = add[keys[i]];\n }\n return origin;\n};\n\nfunction hasOwnProperty(obj, prop) {\n return Object.prototype.hasOwnProperty.call(obj, prop);\n}\n\n/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(30), __webpack_require__(283)))\n\n/***/ }),\n\n/***/ 1408:\n/***/ (function(module, exports) {\n\nmodule.exports = function isBuffer(arg) {\n return arg && typeof arg === 'object'\n && typeof arg.copy === 'function'\n && typeof arg.fill === 'function'\n && typeof arg.readUInt8 === 'function';\n}\n\n/***/ }),\n\n/***/ 1409:\n/***/ (function(module, exports) {\n\nif (typeof Object.create === 'function') {\n // implementation from standard node.js 'util' module\n module.exports = function inherits(ctor, superCtor) {\n ctor.super_ = superCtor\n ctor.prototype = Object.create(superCtor.prototype, {\n constructor: {\n value: ctor,\n enumerable: false,\n writable: true,\n configurable: true\n }\n });\n };\n} else {\n // old school shim for old browsers\n module.exports = function inherits(ctor, superCtor) {\n ctor.super_ = superCtor\n var TempCtor = function () {}\n TempCtor.prototype = superCtor.prototype\n ctor.prototype = new TempCtor()\n ctor.prototype.constructor = ctor\n }\n}\n\n\n/***/ })\n\n});\n\n\n// WEBPACK FOOTER //\n// 30.746b58959a350aa1ebcf.js","import React from 'react';\nimport { Row, Col, Button } from 'react-bootstrap';\nimport { LinkContainer } from 'react-router-bootstrap';\n\nimport Routes from 'routing/Routes';\n\nimport { DocumentTitle, PageHeader } from 'components/common';\nimport ConfigurationBundles from 'components/source-tagging/ConfigurationBundles';\n\nconst ContentPacksPage = React.createClass({\n render() {\n return (\n \n \n \n \n Content packs accelerate the set up process for a specific data source. A content pack can include inputs/extractors, streams, and dashboards.\n \n\n \n Find more content packs in {' '}\n the Graylog Marketplace.\n \n\n \n \n \n \n\n \n \n\n

    Select content packs

    \n
    \n \n
    \n \n
    \n
    \n
    \n );\n },\n});\n\nexport default ContentPacksPage;\n\n\n\n// WEBPACK FOOTER //\n// ./src/pages/ContentPacksPage.jsx","import React from 'react';\nimport Reflux from 'reflux';\nimport { Accordion, Panel, Row, Col } from 'react-bootstrap';\nimport $ from 'jquery';\n\nimport UserNotification from 'util/UserNotification';\n\nimport ActionsProvider from 'injection/ActionsProvider';\nconst ConfigurationBundlesActions = ActionsProvider.getActions('ConfigurationBundles');\n\nimport StoreProvider from 'injection/StoreProvider';\nconst ConfigurationBundlesStore = StoreProvider.getStore('ConfigurationBundles');\n\nimport SourceType from './SourceType';\nimport ConfigurationBundlePreview from './ConfigurationBundlePreview';\nimport Spinner from 'components/common/Spinner';\n\nconst ConfigurationBundles = React.createClass({\n mixins: [Reflux.connect(ConfigurationBundlesStore)],\n\n getInitialState() {\n return {\n sourceTypeId: '',\n sourceTypeDescription: '',\n };\n },\n componentDidMount() {\n ConfigurationBundlesActions.list();\n },\n _getCategoriesHtml() {\n const categories = $.map(this.state.configurationBundles, (bundles, category) => category);\n categories.sort();\n return categories.map((category, idx) => this._getSourceTypeHtml(category, idx), this);\n },\n _getSourceTypeHtml(category, idx) {\n const bundles = this._getSortedBundles(category);\n const bundlesJsx = bundles.map((bundle) => {\n return (\n
  • \n \n
  • \n );\n }, this);\n\n return (\n \n
      \n {bundlesJsx}\n
    \n
    \n );\n },\n _getSortedBundles(category) {\n const bundles = this.state.configurationBundles[category];\n bundles.sort((bundle1, bundle2) => {\n if (bundle1.name > bundle2.name) {\n return 1;\n }\n if (bundle1.name < bundle2.name) {\n return -1;\n }\n return 0;\n });\n return bundles;\n },\n onSubmit(submitEvent) {\n submitEvent.preventDefault();\n if (!this.refs.uploadedFile.files || !this.refs.uploadedFile.files[0]) {\n return;\n }\n\n const reader = new FileReader();\n\n reader.onload = (evt) => {\n const request = evt.target.result;\n ConfigurationBundlesActions.create.triggerPromise(request)\n .then(\n () => {\n UserNotification.success('Content pack imported successfully', 'Success!');\n ConfigurationBundlesActions.list();\n },\n () => {\n UserNotification.error('Error importing content pack, please ensure it is a valid JSON file. Check your ' +\n 'Graylog logs for more information.', 'Could not import content pack');\n });\n };\n\n reader.readAsText(this.refs.uploadedFile.files[0]);\n },\n handleSourceTypeChange(sourceTypeId, sourceTypeDescription) {\n this.setState({ sourceTypeId: sourceTypeId, sourceTypeDescription: sourceTypeDescription });\n },\n _resetSelection() {\n this.setState(this.getInitialState());\n },\n render() {\n return (\n \n \n {this.state.configurationBundles ?\n \n {this._getCategoriesHtml()}\n \n
    \n Remember to apply the content pack after uploading it, to make the changes effective.\n
    \n \n
    \n \n
    \n
    \n
    \n :\n \n }\n \n \n \n \n
    \n );\n },\n});\n\nexport default ConfigurationBundles;\n\n\n\n// WEBPACK FOOTER //\n// ./src/components/source-tagging/ConfigurationBundles.jsx","import PropTypes from 'prop-types';\nimport React from 'react';\n\nconst SourceType = React.createClass({\n propTypes: {\n name: PropTypes.string.isRequired,\n description: PropTypes.string.isRequired,\n onSelect: PropTypes.func.isRequired,\n },\n _onChange(event) {\n this.props.onSelect(event.target.id, event.target.value);\n },\n render() {\n return (\n \n );\n },\n});\n\nexport default SourceType;\n\n\n\n// WEBPACK FOOTER //\n// ./src/components/source-tagging/SourceType.jsx","import PropTypes from 'prop-types';\nimport React from 'react';\nimport { Button } from 'react-bootstrap';\nimport { markdown } from 'markdown';\n\nimport UserNotification from 'util/UserNotification';\n\nimport ActionsProvider from 'injection/ActionsProvider';\nconst ConfigurationBundlesActions = ActionsProvider.getActions('ConfigurationBundles');\n\nconst ConfigurationBundlePreview = React.createClass({\n propTypes: {\n sourceTypeId: PropTypes.string,\n sourceTypeDescription: PropTypes.string,\n onDelete: PropTypes.func.isRequired,\n },\n\n _confirmDeletion() {\n if (window.confirm('You are about to delete this content pack, are you sure?')) {\n ConfigurationBundlesActions.delete(this.props.sourceTypeId).then(() => {\n UserNotification.success('Bundle deleted successfully.', 'Success');\n this.props.onDelete();\n }, () => {\n UserNotification.error('Deleting bundle failed, please check your logs for more information.', 'Error');\n });\n }\n },\n _onApply() {\n ConfigurationBundlesActions.apply(this.props.sourceTypeId).then(() => {\n UserNotification.success('Bundle applied successfully.', 'Success');\n }, () => {\n UserNotification.error('Applying bundle failed, please check your logs for more information.', 'Error');\n });\n },\n render() {\n let preview = 'Select a content pack from the list to see its preview.';\n let applyAction = '';\n let deleteAction = '';\n\n if (this.props.sourceTypeDescription) {\n preview = this.props.sourceTypeDescription;\n applyAction = ;\n deleteAction = ;\n }\n\n const markdownPreview = markdown.toHTML(preview);\n\n return (\n
    \n
    \n {deleteAction}\n

    Content pack description:

    \n
    \n
    \n
    \n {applyAction}\n
    \n
    \n );\n },\n});\n\nexport default ConfigurationBundlePreview;\n\n\n\n// WEBPACK FOOTER //\n// ./src/components/source-tagging/ConfigurationBundlePreview.jsx","// super simple module for the most common nodejs use case.\nexports.markdown = require(\"./markdown\");\nexports.parse = exports.markdown.toHTML;\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./node_modules/markdown/lib/index.js\n// module id = 1405\n// module chunks = 30","// Released under MIT license\n// Copyright (c) 2009-2010 Dominic Baggott\n// Copyright (c) 2009-2010 Ash Berlin\n// Copyright (c) 2011 Christoph Dorn (http://www.christophdorn.com)\n\n/*jshint browser:true, devel:true */\n\n(function( expose ) {\n\n/**\n * class Markdown\n *\n * Markdown processing in Javascript done right. We have very particular views\n * on what constitutes 'right' which include:\n *\n * - produces well-formed HTML (this means that em and strong nesting is\n * important)\n *\n * - has an intermediate representation to allow processing of parsed data (We\n * in fact have two, both as [JsonML]: a markdown tree and an HTML tree).\n *\n * - is easily extensible to add new dialects without having to rewrite the\n * entire parsing mechanics\n *\n * - has a good test suite\n *\n * This implementation fulfills all of these (except that the test suite could\n * do with expanding to automatically run all the fixtures from other Markdown\n * implementations.)\n *\n * ##### Intermediate Representation\n *\n * *TODO* Talk about this :) Its JsonML, but document the node names we use.\n *\n * [JsonML]: http://jsonml.org/ \"JSON Markup Language\"\n **/\nvar Markdown = expose.Markdown = function(dialect) {\n switch (typeof dialect) {\n case \"undefined\":\n this.dialect = Markdown.dialects.Gruber;\n break;\n case \"object\":\n this.dialect = dialect;\n break;\n default:\n if ( dialect in Markdown.dialects ) {\n this.dialect = Markdown.dialects[dialect];\n }\n else {\n throw new Error(\"Unknown Markdown dialect '\" + String(dialect) + \"'\");\n }\n break;\n }\n this.em_state = [];\n this.strong_state = [];\n this.debug_indent = \"\";\n};\n\n/**\n * parse( markdown, [dialect] ) -> JsonML\n * - markdown (String): markdown string to parse\n * - dialect (String | Dialect): the dialect to use, defaults to gruber\n *\n * Parse `markdown` and return a markdown document as a Markdown.JsonML tree.\n **/\nexpose.parse = function( source, dialect ) {\n // dialect will default if undefined\n var md = new Markdown( dialect );\n return md.toTree( source );\n};\n\n/**\n * toHTML( markdown, [dialect] ) -> String\n * toHTML( md_tree ) -> String\n * - markdown (String): markdown string to parse\n * - md_tree (Markdown.JsonML): parsed markdown tree\n *\n * Take markdown (either as a string or as a JsonML tree) and run it through\n * [[toHTMLTree]] then turn it into a well-formated HTML fragment.\n **/\nexpose.toHTML = function toHTML( source , dialect , options ) {\n var input = expose.toHTMLTree( source , dialect , options );\n\n return expose.renderJsonML( input );\n};\n\n/**\n * toHTMLTree( markdown, [dialect] ) -> JsonML\n * toHTMLTree( md_tree ) -> JsonML\n * - markdown (String): markdown string to parse\n * - dialect (String | Dialect): the dialect to use, defaults to gruber\n * - md_tree (Markdown.JsonML): parsed markdown tree\n *\n * Turn markdown into HTML, represented as a JsonML tree. If a string is given\n * to this function, it is first parsed into a markdown tree by calling\n * [[parse]].\n **/\nexpose.toHTMLTree = function toHTMLTree( input, dialect , options ) {\n // convert string input to an MD tree\n if ( typeof input ===\"string\" ) input = this.parse( input, dialect );\n\n // Now convert the MD tree to an HTML tree\n\n // remove references from the tree\n var attrs = extract_attr( input ),\n refs = {};\n\n if ( attrs && attrs.references ) {\n refs = attrs.references;\n }\n\n var html = convert_tree_to_html( input, refs , options );\n merge_text_nodes( html );\n return html;\n};\n\n// For Spidermonkey based engines\nfunction mk_block_toSource() {\n return \"Markdown.mk_block( \" +\n uneval(this.toString()) +\n \", \" +\n uneval(this.trailing) +\n \", \" +\n uneval(this.lineNumber) +\n \" )\";\n}\n\n// node\nfunction mk_block_inspect() {\n var util = require(\"util\");\n return \"Markdown.mk_block( \" +\n util.inspect(this.toString()) +\n \", \" +\n util.inspect(this.trailing) +\n \", \" +\n util.inspect(this.lineNumber) +\n \" )\";\n\n}\n\nvar mk_block = Markdown.mk_block = function(block, trail, line) {\n // Be helpful for default case in tests.\n if ( arguments.length == 1 ) trail = \"\\n\\n\";\n\n var s = new String(block);\n s.trailing = trail;\n // To make it clear its not just a string\n s.inspect = mk_block_inspect;\n s.toSource = mk_block_toSource;\n\n if ( line != undefined )\n s.lineNumber = line;\n\n return s;\n};\n\nfunction count_lines( str ) {\n var n = 0, i = -1;\n while ( ( i = str.indexOf(\"\\n\", i + 1) ) !== -1 ) n++;\n return n;\n}\n\n// Internal - split source into rough blocks\nMarkdown.prototype.split_blocks = function splitBlocks( input, startLine ) {\n input = input.replace(/(\\r\\n|\\n|\\r)/g, \"\\n\");\n // [\\s\\S] matches _anything_ (newline or space)\n // [^] is equivalent but doesn't work in IEs.\n var re = /([\\s\\S]+?)($|\\n#|\\n(?:\\s*\\n|$)+)/g,\n blocks = [],\n m;\n\n var line_no = 1;\n\n if ( ( m = /^(\\s*\\n)/.exec(input) ) != null ) {\n // skip (but count) leading blank lines\n line_no += count_lines( m[0] );\n re.lastIndex = m[0].length;\n }\n\n while ( ( m = re.exec(input) ) !== null ) {\n if (m[2] == \"\\n#\") {\n m[2] = \"\\n\";\n re.lastIndex--;\n }\n blocks.push( mk_block( m[1], m[2], line_no ) );\n line_no += count_lines( m[0] );\n }\n\n return blocks;\n};\n\n/**\n * Markdown#processBlock( block, next ) -> undefined | [ JsonML, ... ]\n * - block (String): the block to process\n * - next (Array): the following blocks\n *\n * Process `block` and return an array of JsonML nodes representing `block`.\n *\n * It does this by asking each block level function in the dialect to process\n * the block until one can. Succesful handling is indicated by returning an\n * array (with zero or more JsonML nodes), failure by a false value.\n *\n * Blocks handlers are responsible for calling [[Markdown#processInline]]\n * themselves as appropriate.\n *\n * If the blocks were split incorrectly or adjacent blocks need collapsing you\n * can adjust `next` in place using shift/splice etc.\n *\n * If any of this default behaviour is not right for the dialect, you can\n * define a `__call__` method on the dialect that will get invoked to handle\n * the block processing.\n */\nMarkdown.prototype.processBlock = function processBlock( block, next ) {\n var cbs = this.dialect.block,\n ord = cbs.__order__;\n\n if ( \"__call__\" in cbs ) {\n return cbs.__call__.call(this, block, next);\n }\n\n for ( var i = 0; i < ord.length; i++ ) {\n //D:this.debug( \"Testing\", ord[i] );\n var res = cbs[ ord[i] ].call( this, block, next );\n if ( res ) {\n //D:this.debug(\" matched\");\n if ( !isArray(res) || ( res.length > 0 && !( isArray(res[0]) ) ) )\n this.debug(ord[i], \"didn't return a proper array\");\n //D:this.debug( \"\" );\n return res;\n }\n }\n\n // Uhoh! no match! Should we throw an error?\n return [];\n};\n\nMarkdown.prototype.processInline = function processInline( block ) {\n return this.dialect.inline.__call__.call( this, String( block ) );\n};\n\n/**\n * Markdown#toTree( source ) -> JsonML\n * - source (String): markdown source to parse\n *\n * Parse `source` into a JsonML tree representing the markdown document.\n **/\n// custom_tree means set this.tree to `custom_tree` and restore old value on return\nMarkdown.prototype.toTree = function toTree( source, custom_root ) {\n var blocks = source instanceof Array ? source : this.split_blocks( source );\n\n // Make tree a member variable so its easier to mess with in extensions\n var old_tree = this.tree;\n try {\n this.tree = custom_root || this.tree || [ \"markdown\" ];\n\n blocks:\n while ( blocks.length ) {\n var b = this.processBlock( blocks.shift(), blocks );\n\n // Reference blocks and the like won't return any content\n if ( !b.length ) continue blocks;\n\n this.tree.push.apply( this.tree, b );\n }\n return this.tree;\n }\n finally {\n if ( custom_root ) {\n this.tree = old_tree;\n }\n }\n};\n\n// Noop by default\nMarkdown.prototype.debug = function () {\n var args = Array.prototype.slice.call( arguments);\n args.unshift(this.debug_indent);\n if ( typeof print !== \"undefined\" )\n print.apply( print, args );\n if ( typeof console !== \"undefined\" && typeof console.log !== \"undefined\" )\n console.log.apply( null, args );\n}\n\nMarkdown.prototype.loop_re_over_block = function( re, block, cb ) {\n // Dont use /g regexps with this\n var m,\n b = block.valueOf();\n\n while ( b.length && (m = re.exec(b) ) != null ) {\n b = b.substr( m[0].length );\n cb.call(this, m);\n }\n return b;\n};\n\n/**\n * Markdown.dialects\n *\n * Namespace of built-in dialects.\n **/\nMarkdown.dialects = {};\n\n/**\n * Markdown.dialects.Gruber\n *\n * The default dialect that follows the rules set out by John Gruber's\n * markdown.pl as closely as possible. Well actually we follow the behaviour of\n * that script which in some places is not exactly what the syntax web page\n * says.\n **/\nMarkdown.dialects.Gruber = {\n block: {\n atxHeader: function atxHeader( block, next ) {\n var m = block.match( /^(#{1,6})\\s*(.*?)\\s*#*\\s*(?:\\n|$)/ );\n\n if ( !m ) return undefined;\n\n var header = [ \"header\", { level: m[ 1 ].length } ];\n Array.prototype.push.apply(header, this.processInline(m[ 2 ]));\n\n if ( m[0].length < block.length )\n next.unshift( mk_block( block.substr( m[0].length ), block.trailing, block.lineNumber + 2 ) );\n\n return [ header ];\n },\n\n setextHeader: function setextHeader( block, next ) {\n var m = block.match( /^(.*)\\n([-=])\\2\\2+(?:\\n|$)/ );\n\n if ( !m ) return undefined;\n\n var level = ( m[ 2 ] === \"=\" ) ? 1 : 2;\n var header = [ \"header\", { level : level }, m[ 1 ] ];\n\n if ( m[0].length < block.length )\n next.unshift( mk_block( block.substr( m[0].length ), block.trailing, block.lineNumber + 2 ) );\n\n return [ header ];\n },\n\n code: function code( block, next ) {\n // | Foo\n // |bar\n // should be a code block followed by a paragraph. Fun\n //\n // There might also be adjacent code block to merge.\n\n var ret = [],\n re = /^(?: {0,3}\\t| {4})(.*)\\n?/,\n lines;\n\n // 4 spaces + content\n if ( !block.match( re ) ) return undefined;\n\n block_search:\n do {\n // Now pull out the rest of the lines\n var b = this.loop_re_over_block(\n re, block.valueOf(), function( m ) { ret.push( m[1] ); } );\n\n if ( b.length ) {\n // Case alluded to in first comment. push it back on as a new block\n next.unshift( mk_block(b, block.trailing) );\n break block_search;\n }\n else if ( next.length ) {\n // Check the next block - it might be code too\n if ( !next[0].match( re ) ) break block_search;\n\n // Pull how how many blanks lines follow - minus two to account for .join\n ret.push ( block.trailing.replace(/[^\\n]/g, \"\").substring(2) );\n\n block = next.shift();\n }\n else {\n break block_search;\n }\n } while ( true );\n\n return [ [ \"code_block\", ret.join(\"\\n\") ] ];\n },\n\n horizRule: function horizRule( block, next ) {\n // this needs to find any hr in the block to handle abutting blocks\n var m = block.match( /^(?:([\\s\\S]*?)\\n)?[ \\t]*([-_*])(?:[ \\t]*\\2){2,}[ \\t]*(?:\\n([\\s\\S]*))?$/ );\n\n if ( !m ) {\n return undefined;\n }\n\n var jsonml = [ [ \"hr\" ] ];\n\n // if there's a leading abutting block, process it\n if ( m[ 1 ] ) {\n jsonml.unshift.apply( jsonml, this.processBlock( m[ 1 ], [] ) );\n }\n\n // if there's a trailing abutting block, stick it into next\n if ( m[ 3 ] ) {\n next.unshift( mk_block( m[ 3 ] ) );\n }\n\n return jsonml;\n },\n\n // There are two types of lists. Tight and loose. Tight lists have no whitespace\n // between the items (and result in text just in the
  • ) and loose lists,\n // which have an empty line between list items, resulting in (one or more)\n // paragraphs inside the
  • .\n //\n // There are all sorts weird edge cases about the original markdown.pl's\n // handling of lists:\n //\n // * Nested lists are supposed to be indented by four chars per level. But\n // if they aren't, you can get a nested list by indenting by less than\n // four so long as the indent doesn't match an indent of an existing list\n // item in the 'nest stack'.\n //\n // * The type of the list (bullet or number) is controlled just by the\n // first item at the indent. Subsequent changes are ignored unless they\n // are for nested lists\n //\n lists: (function( ) {\n // Use a closure to hide a few variables.\n var any_list = \"[*+-]|\\\\d+\\\\.\",\n bullet_list = /[*+-]/,\n number_list = /\\d+\\./,\n // Capture leading indent as it matters for determining nested lists.\n is_list_re = new RegExp( \"^( {0,3})(\" + any_list + \")[ \\t]+\" ),\n indent_re = \"(?: {0,3}\\\\t| {4})\";\n\n // TODO: Cache this regexp for certain depths.\n // Create a regexp suitable for matching an li for a given stack depth\n function regex_for_depth( depth ) {\n\n return new RegExp(\n // m[1] = indent, m[2] = list_type\n \"(?:^(\" + indent_re + \"{0,\" + depth + \"} {0,3})(\" + any_list + \")\\\\s+)|\" +\n // m[3] = cont\n \"(^\" + indent_re + \"{0,\" + (depth-1) + \"}[ ]{0,4})\"\n );\n }\n function expand_tab( input ) {\n return input.replace( / {0,3}\\t/g, \" \" );\n }\n\n // Add inline content `inline` to `li`. inline comes from processInline\n // so is an array of content\n function add(li, loose, inline, nl) {\n if ( loose ) {\n li.push( [ \"para\" ].concat(inline) );\n return;\n }\n // Hmmm, should this be any block level element or just paras?\n var add_to = li[li.length -1] instanceof Array && li[li.length - 1][0] == \"para\"\n ? li[li.length -1]\n : li;\n\n // If there is already some content in this list, add the new line in\n if ( nl && li.length > 1 ) inline.unshift(nl);\n\n for ( var i = 0; i < inline.length; i++ ) {\n var what = inline[i],\n is_str = typeof what == \"string\";\n if ( is_str && add_to.length > 1 && typeof add_to[add_to.length-1] == \"string\" ) {\n add_to[ add_to.length-1 ] += what;\n }\n else {\n add_to.push( what );\n }\n }\n }\n\n // contained means have an indent greater than the current one. On\n // *every* line in the block\n function get_contained_blocks( depth, blocks ) {\n\n var re = new RegExp( \"^(\" + indent_re + \"{\" + depth + \"}.*?\\\\n?)*$\" ),\n replace = new RegExp(\"^\" + indent_re + \"{\" + depth + \"}\", \"gm\"),\n ret = [];\n\n while ( blocks.length > 0 ) {\n if ( re.exec( blocks[0] ) ) {\n var b = blocks.shift(),\n // Now remove that indent\n x = b.replace( replace, \"\");\n\n ret.push( mk_block( x, b.trailing, b.lineNumber ) );\n }\n else {\n break;\n }\n }\n return ret;\n }\n\n // passed to stack.forEach to turn list items up the stack into paras\n function paragraphify(s, i, stack) {\n var list = s.list;\n var last_li = list[list.length-1];\n\n if ( last_li[1] instanceof Array && last_li[1][0] == \"para\" ) {\n return;\n }\n if ( i + 1 == stack.length ) {\n // Last stack frame\n // Keep the same array, but replace the contents\n last_li.push( [\"para\"].concat( last_li.splice(1, last_li.length - 1) ) );\n }\n else {\n var sublist = last_li.pop();\n last_li.push( [\"para\"].concat( last_li.splice(1, last_li.length - 1) ), sublist );\n }\n }\n\n // The matcher function\n return function( block, next ) {\n var m = block.match( is_list_re );\n if ( !m ) return undefined;\n\n function make_list( m ) {\n var list = bullet_list.exec( m[2] )\n ? [\"bulletlist\"]\n : [\"numberlist\"];\n\n stack.push( { list: list, indent: m[1] } );\n return list;\n }\n\n\n var stack = [], // Stack of lists for nesting.\n list = make_list( m ),\n last_li,\n loose = false,\n ret = [ stack[0].list ],\n i;\n\n // Loop to search over block looking for inner block elements and loose lists\n loose_search:\n while ( true ) {\n // Split into lines preserving new lines at end of line\n var lines = block.split( /(?=\\n)/ );\n\n // We have to grab all lines for a li and call processInline on them\n // once as there are some inline things that can span lines.\n var li_accumulate = \"\";\n\n // Loop over the lines in this block looking for tight lists.\n tight_search:\n for ( var line_no = 0; line_no < lines.length; line_no++ ) {\n var nl = \"\",\n l = lines[line_no].replace(/^\\n/, function(n) { nl = n; return \"\"; });\n\n // TODO: really should cache this\n var line_re = regex_for_depth( stack.length );\n\n m = l.match( line_re );\n //print( \"line:\", uneval(l), \"\\nline match:\", uneval(m) );\n\n // We have a list item\n if ( m[1] !== undefined ) {\n // Process the previous list item, if any\n if ( li_accumulate.length ) {\n add( last_li, loose, this.processInline( li_accumulate ), nl );\n // Loose mode will have been dealt with. Reset it\n loose = false;\n li_accumulate = \"\";\n }\n\n m[1] = expand_tab( m[1] );\n var wanted_depth = Math.floor(m[1].length/4)+1;\n //print( \"want:\", wanted_depth, \"stack:\", stack.length);\n if ( wanted_depth > stack.length ) {\n // Deep enough for a nested list outright\n //print ( \"new nested list\" );\n list = make_list( m );\n last_li.push( list );\n last_li = list[1] = [ \"listitem\" ];\n }\n else {\n // We aren't deep enough to be strictly a new level. This is\n // where Md.pl goes nuts. If the indent matches a level in the\n // stack, put it there, else put it one deeper then the\n // wanted_depth deserves.\n var found = false;\n for ( i = 0; i < stack.length; i++ ) {\n if ( stack[ i ].indent != m[1] ) continue;\n list = stack[ i ].list;\n stack.splice( i+1, stack.length - (i+1) );\n found = true;\n break;\n }\n\n if (!found) {\n //print(\"not found. l:\", uneval(l));\n wanted_depth++;\n if ( wanted_depth <= stack.length ) {\n stack.splice(wanted_depth, stack.length - wanted_depth);\n //print(\"Desired depth now\", wanted_depth, \"stack:\", stack.length);\n list = stack[wanted_depth-1].list;\n //print(\"list:\", uneval(list) );\n }\n else {\n //print (\"made new stack for messy indent\");\n list = make_list(m);\n last_li.push(list);\n }\n }\n\n //print( uneval(list), \"last\", list === stack[stack.length-1].list );\n last_li = [ \"listitem\" ];\n list.push(last_li);\n } // end depth of shenegains\n nl = \"\";\n }\n\n // Add content\n if ( l.length > m[0].length ) {\n li_accumulate += nl + l.substr( m[0].length );\n }\n } // tight_search\n\n if ( li_accumulate.length ) {\n add( last_li, loose, this.processInline( li_accumulate ), nl );\n // Loose mode will have been dealt with. Reset it\n loose = false;\n li_accumulate = \"\";\n }\n\n // Look at the next block - we might have a loose list. Or an extra\n // paragraph for the current li\n var contained = get_contained_blocks( stack.length, next );\n\n // Deal with code blocks or properly nested lists\n if ( contained.length > 0 ) {\n // Make sure all listitems up the stack are paragraphs\n forEach( stack, paragraphify, this);\n\n last_li.push.apply( last_li, this.toTree( contained, [] ) );\n }\n\n var next_block = next[0] && next[0].valueOf() || \"\";\n\n if ( next_block.match(is_list_re) || next_block.match( /^ / ) ) {\n block = next.shift();\n\n // Check for an HR following a list: features/lists/hr_abutting\n var hr = this.dialect.block.horizRule( block, next );\n\n if ( hr ) {\n ret.push.apply(ret, hr);\n break;\n }\n\n // Make sure all listitems up the stack are paragraphs\n forEach( stack, paragraphify, this);\n\n loose = true;\n continue loose_search;\n }\n break;\n } // loose_search\n\n return ret;\n };\n })(),\n\n blockquote: function blockquote( block, next ) {\n if ( !block.match( /^>/m ) )\n return undefined;\n\n var jsonml = [];\n\n // separate out the leading abutting block, if any. I.e. in this case:\n //\n // a\n // > b\n //\n if ( block[ 0 ] != \">\" ) {\n var lines = block.split( /\\n/ ),\n prev = [],\n line_no = block.lineNumber;\n\n // keep shifting lines until you find a crotchet\n while ( lines.length && lines[ 0 ][ 0 ] != \">\" ) {\n prev.push( lines.shift() );\n line_no++;\n }\n\n var abutting = mk_block( prev.join( \"\\n\" ), \"\\n\", block.lineNumber );\n jsonml.push.apply( jsonml, this.processBlock( abutting, [] ) );\n // reassemble new block of just block quotes!\n block = mk_block( lines.join( \"\\n\" ), block.trailing, line_no );\n }\n\n\n // if the next block is also a blockquote merge it in\n while ( next.length && next[ 0 ][ 0 ] == \">\" ) {\n var b = next.shift();\n block = mk_block( block + block.trailing + b, b.trailing, block.lineNumber );\n }\n\n // Strip off the leading \"> \" and re-process as a block.\n var input = block.replace( /^> ?/gm, \"\" ),\n old_tree = this.tree,\n processedBlock = this.toTree( input, [ \"blockquote\" ] ),\n attr = extract_attr( processedBlock );\n\n // If any link references were found get rid of them\n if ( attr && attr.references ) {\n delete attr.references;\n // And then remove the attribute object if it's empty\n if ( isEmpty( attr ) ) {\n processedBlock.splice( 1, 1 );\n }\n }\n\n jsonml.push( processedBlock );\n return jsonml;\n },\n\n referenceDefn: function referenceDefn( block, next) {\n var re = /^\\s*\\[(.*?)\\]:\\s*(\\S+)(?:\\s+(?:(['\"])(.*?)\\3|\\((.*?)\\)))?\\n?/;\n // interesting matches are [ , ref_id, url, , title, title ]\n\n if ( !block.match(re) )\n return undefined;\n\n // make an attribute node if it doesn't exist\n if ( !extract_attr( this.tree ) ) {\n this.tree.splice( 1, 0, {} );\n }\n\n var attrs = extract_attr( this.tree );\n\n // make a references hash if it doesn't exist\n if ( attrs.references === undefined ) {\n attrs.references = {};\n }\n\n var b = this.loop_re_over_block(re, block, function( m ) {\n\n if ( m[2] && m[2][0] == \"<\" && m[2][m[2].length-1] == \">\" )\n m[2] = m[2].substring( 1, m[2].length - 1 );\n\n var ref = attrs.references[ m[1].toLowerCase() ] = {\n href: m[2]\n };\n\n if ( m[4] !== undefined )\n ref.title = m[4];\n else if ( m[5] !== undefined )\n ref.title = m[5];\n\n } );\n\n if ( b.length )\n next.unshift( mk_block( b, block.trailing ) );\n\n return [];\n },\n\n para: function para( block, next ) {\n // everything's a para!\n return [ [\"para\"].concat( this.processInline( block ) ) ];\n }\n }\n};\n\nMarkdown.dialects.Gruber.inline = {\n\n __oneElement__: function oneElement( text, patterns_or_re, previous_nodes ) {\n var m,\n res,\n lastIndex = 0;\n\n patterns_or_re = patterns_or_re || this.dialect.inline.__patterns__;\n var re = new RegExp( \"([\\\\s\\\\S]*?)(\" + (patterns_or_re.source || patterns_or_re) + \")\" );\n\n m = re.exec( text );\n if (!m) {\n // Just boring text\n return [ text.length, text ];\n }\n else if ( m[1] ) {\n // Some un-interesting text matched. Return that first\n return [ m[1].length, m[1] ];\n }\n\n var res;\n if ( m[2] in this.dialect.inline ) {\n res = this.dialect.inline[ m[2] ].call(\n this,\n text.substr( m.index ), m, previous_nodes || [] );\n }\n // Default for now to make dev easier. just slurp special and output it.\n res = res || [ m[2].length, m[2] ];\n return res;\n },\n\n __call__: function inline( text, patterns ) {\n\n var out = [],\n res;\n\n function add(x) {\n //D:self.debug(\" adding output\", uneval(x));\n if ( typeof x == \"string\" && typeof out[out.length-1] == \"string\" )\n out[ out.length-1 ] += x;\n else\n out.push(x);\n }\n\n while ( text.length > 0 ) {\n res = this.dialect.inline.__oneElement__.call(this, text, patterns, out );\n text = text.substr( res.shift() );\n forEach(res, add )\n }\n\n return out;\n },\n\n // These characters are intersting elsewhere, so have rules for them so that\n // chunks of plain text blocks don't include them\n \"]\": function () {},\n \"}\": function () {},\n\n __escape__ : /^\\\\[\\\\`\\*_{}\\[\\]()#\\+.!\\-]/,\n\n \"\\\\\": function escaped( text ) {\n // [ length of input processed, node/children to add... ]\n // Only esacape: \\ ` * _ { } [ ] ( ) # * + - . !\n if ( this.dialect.inline.__escape__.exec( text ) )\n return [ 2, text.charAt( 1 ) ];\n else\n // Not an esacpe\n return [ 1, \"\\\\\" ];\n },\n\n \"![\": function image( text ) {\n\n // Unlike images, alt text is plain text only. no other elements are\n // allowed in there\n\n // ![Alt text](/path/to/img.jpg \"Optional title\")\n // 1 2 3 4 <--- captures\n var m = text.match( /^!\\[(.*?)\\][ \\t]*\\([ \\t]*([^\")]*?)(?:[ \\t]+([\"'])(.*?)\\3)?[ \\t]*\\)/ );\n\n if ( m ) {\n if ( m[2] && m[2][0] == \"<\" && m[2][m[2].length-1] == \">\" )\n m[2] = m[2].substring( 1, m[2].length - 1 );\n\n m[2] = this.dialect.inline.__call__.call( this, m[2], /\\\\/ )[0];\n\n var attrs = { alt: m[1], href: m[2] || \"\" };\n if ( m[4] !== undefined)\n attrs.title = m[4];\n\n return [ m[0].length, [ \"img\", attrs ] ];\n }\n\n // ![Alt text][id]\n m = text.match( /^!\\[(.*?)\\][ \\t]*\\[(.*?)\\]/ );\n\n if ( m ) {\n // We can't check if the reference is known here as it likely wont be\n // found till after. Check it in md tree->hmtl tree conversion\n return [ m[0].length, [ \"img_ref\", { alt: m[1], ref: m[2].toLowerCase(), original: m[0] } ] ];\n }\n\n // Just consume the '!['\n return [ 2, \"![\" ];\n },\n\n \"[\": function link( text ) {\n\n var orig = String(text);\n // Inline content is possible inside `link text`\n var res = Markdown.DialectHelpers.inline_until_char.call( this, text.substr(1), \"]\" );\n\n // No closing ']' found. Just consume the [\n if ( !res ) return [ 1, \"[\" ];\n\n var consumed = 1 + res[ 0 ],\n children = res[ 1 ],\n link,\n attrs;\n\n // At this point the first [...] has been parsed. See what follows to find\n // out which kind of link we are (reference or direct url)\n text = text.substr( consumed );\n\n // [link text](/path/to/img.jpg \"Optional title\")\n // 1 2 3 <--- captures\n // This will capture up to the last paren in the block. We then pull\n // back based on if there a matching ones in the url\n // ([here](/url/(test))\n // The parens have to be balanced\n var m = text.match( /^\\s*\\([ \\t]*([^\"']*)(?:[ \\t]+([\"'])(.*?)\\2)?[ \\t]*\\)/ );\n if ( m ) {\n var url = m[1];\n consumed += m[0].length;\n\n if ( url && url[0] == \"<\" && url[url.length-1] == \">\" )\n url = url.substring( 1, url.length - 1 );\n\n // If there is a title we don't have to worry about parens in the url\n if ( !m[3] ) {\n var open_parens = 1; // One open that isn't in the capture\n for ( var len = 0; len < url.length; len++ ) {\n switch ( url[len] ) {\n case \"(\":\n open_parens++;\n break;\n case \")\":\n if ( --open_parens == 0) {\n consumed -= url.length - len;\n url = url.substring(0, len);\n }\n break;\n }\n }\n }\n\n // Process escapes only\n url = this.dialect.inline.__call__.call( this, url, /\\\\/ )[0];\n\n attrs = { href: url || \"\" };\n if ( m[3] !== undefined)\n attrs.title = m[3];\n\n link = [ \"link\", attrs ].concat( children );\n return [ consumed, link ];\n }\n\n // [Alt text][id]\n // [Alt text] [id]\n m = text.match( /^\\s*\\[(.*?)\\]/ );\n\n if ( m ) {\n\n consumed += m[ 0 ].length;\n\n // [links][] uses links as its reference\n attrs = { ref: ( m[ 1 ] || String(children) ).toLowerCase(), original: orig.substr( 0, consumed ) };\n\n link = [ \"link_ref\", attrs ].concat( children );\n\n // We can't check if the reference is known here as it likely wont be\n // found till after. Check it in md tree->hmtl tree conversion.\n // Store the original so that conversion can revert if the ref isn't found.\n return [ consumed, link ];\n }\n\n // [id]\n // Only if id is plain (no formatting.)\n if ( children.length == 1 && typeof children[0] == \"string\" ) {\n\n attrs = { ref: children[0].toLowerCase(), original: orig.substr( 0, consumed ) };\n link = [ \"link_ref\", attrs, children[0] ];\n return [ consumed, link ];\n }\n\n // Just consume the \"[\"\n return [ 1, \"[\" ];\n },\n\n\n \"<\": function autoLink( text ) {\n var m;\n\n if ( ( m = text.match( /^<(?:((https?|ftp|mailto):[^>]+)|(.*?@.*?\\.[a-zA-Z]+))>/ ) ) != null ) {\n if ( m[3] ) {\n return [ m[0].length, [ \"link\", { href: \"mailto:\" + m[3] }, m[3] ] ];\n\n }\n else if ( m[2] == \"mailto\" ) {\n return [ m[0].length, [ \"link\", { href: m[1] }, m[1].substr(\"mailto:\".length ) ] ];\n }\n else\n return [ m[0].length, [ \"link\", { href: m[1] }, m[1] ] ];\n }\n\n return [ 1, \"<\" ];\n },\n\n \"`\": function inlineCode( text ) {\n // Inline code block. as many backticks as you like to start it\n // Always skip over the opening ticks.\n var m = text.match( /(`+)(([\\s\\S]*?)\\1)/ );\n\n if ( m && m[2] )\n return [ m[1].length + m[2].length, [ \"inlinecode\", m[3] ] ];\n else {\n // TODO: No matching end code found - warn!\n return [ 1, \"`\" ];\n }\n },\n\n \" \\n\": function lineBreak( text ) {\n return [ 3, [ \"linebreak\" ] ];\n }\n\n};\n\n// Meta Helper/generator method for em and strong handling\nfunction strong_em( tag, md ) {\n\n var state_slot = tag + \"_state\",\n other_slot = tag == \"strong\" ? \"em_state\" : \"strong_state\";\n\n function CloseTag(len) {\n this.len_after = len;\n this.name = \"close_\" + md;\n }\n\n return function ( text, orig_match ) {\n\n if ( this[state_slot][0] == md ) {\n // Most recent em is of this type\n //D:this.debug(\"closing\", md);\n this[state_slot].shift();\n\n // \"Consume\" everything to go back to the recrusion in the else-block below\n return[ text.length, new CloseTag(text.length-md.length) ];\n }\n else {\n // Store a clone of the em/strong states\n var other = this[other_slot].slice(),\n state = this[state_slot].slice();\n\n this[state_slot].unshift(md);\n\n //D:this.debug_indent += \" \";\n\n // Recurse\n var res = this.processInline( text.substr( md.length ) );\n //D:this.debug_indent = this.debug_indent.substr(2);\n\n var last = res[res.length - 1];\n\n //D:this.debug(\"processInline from\", tag + \": \", uneval( res ) );\n\n var check = this[state_slot].shift();\n if ( last instanceof CloseTag ) {\n res.pop();\n // We matched! Huzzah.\n var consumed = text.length - last.len_after;\n return [ consumed, [ tag ].concat(res) ];\n }\n else {\n // Restore the state of the other kind. We might have mistakenly closed it.\n this[other_slot] = other;\n this[state_slot] = state;\n\n // We can't reuse the processed result as it could have wrong parsing contexts in it.\n return [ md.length, md ];\n }\n }\n }; // End returned function\n}\n\nMarkdown.dialects.Gruber.inline[\"**\"] = strong_em(\"strong\", \"**\");\nMarkdown.dialects.Gruber.inline[\"__\"] = strong_em(\"strong\", \"__\");\nMarkdown.dialects.Gruber.inline[\"*\"] = strong_em(\"em\", \"*\");\nMarkdown.dialects.Gruber.inline[\"_\"] = strong_em(\"em\", \"_\");\n\n\n// Build default order from insertion order.\nMarkdown.buildBlockOrder = function(d) {\n var ord = [];\n for ( var i in d ) {\n if ( i == \"__order__\" || i == \"__call__\" ) continue;\n ord.push( i );\n }\n d.__order__ = ord;\n};\n\n// Build patterns for inline matcher\nMarkdown.buildInlinePatterns = function(d) {\n var patterns = [];\n\n for ( var i in d ) {\n // __foo__ is reserved and not a pattern\n if ( i.match( /^__.*__$/) ) continue;\n var l = i.replace( /([\\\\.*+?|()\\[\\]{}])/g, \"\\\\$1\" )\n .replace( /\\n/, \"\\\\n\" );\n patterns.push( i.length == 1 ? l : \"(?:\" + l + \")\" );\n }\n\n patterns = patterns.join(\"|\");\n d.__patterns__ = patterns;\n //print(\"patterns:\", uneval( patterns ) );\n\n var fn = d.__call__;\n d.__call__ = function(text, pattern) {\n if ( pattern != undefined ) {\n return fn.call(this, text, pattern);\n }\n else\n {\n return fn.call(this, text, patterns);\n }\n };\n};\n\nMarkdown.DialectHelpers = {};\nMarkdown.DialectHelpers.inline_until_char = function( text, want ) {\n var consumed = 0,\n nodes = [];\n\n while ( true ) {\n if ( text.charAt( consumed ) == want ) {\n // Found the character we were looking for\n consumed++;\n return [ consumed, nodes ];\n }\n\n if ( consumed >= text.length ) {\n // No closing char found. Abort.\n return null;\n }\n\n var res = this.dialect.inline.__oneElement__.call(this, text.substr( consumed ) );\n consumed += res[ 0 ];\n // Add any returned nodes.\n nodes.push.apply( nodes, res.slice( 1 ) );\n }\n}\n\n// Helper function to make sub-classing a dialect easier\nMarkdown.subclassDialect = function( d ) {\n function Block() {}\n Block.prototype = d.block;\n function Inline() {}\n Inline.prototype = d.inline;\n\n return { block: new Block(), inline: new Inline() };\n};\n\nMarkdown.buildBlockOrder ( Markdown.dialects.Gruber.block );\nMarkdown.buildInlinePatterns( Markdown.dialects.Gruber.inline );\n\nMarkdown.dialects.Maruku = Markdown.subclassDialect( Markdown.dialects.Gruber );\n\nMarkdown.dialects.Maruku.processMetaHash = function processMetaHash( meta_string ) {\n var meta = split_meta_hash( meta_string ),\n attr = {};\n\n for ( var i = 0; i < meta.length; ++i ) {\n // id: #foo\n if ( /^#/.test( meta[ i ] ) ) {\n attr.id = meta[ i ].substring( 1 );\n }\n // class: .foo\n else if ( /^\\./.test( meta[ i ] ) ) {\n // if class already exists, append the new one\n if ( attr[\"class\"] ) {\n attr[\"class\"] = attr[\"class\"] + meta[ i ].replace( /./, \" \" );\n }\n else {\n attr[\"class\"] = meta[ i ].substring( 1 );\n }\n }\n // attribute: foo=bar\n else if ( /\\=/.test( meta[ i ] ) ) {\n var s = meta[ i ].split( /\\=/ );\n attr[ s[ 0 ] ] = s[ 1 ];\n }\n }\n\n return attr;\n}\n\nfunction split_meta_hash( meta_string ) {\n var meta = meta_string.split( \"\" ),\n parts = [ \"\" ],\n in_quotes = false;\n\n while ( meta.length ) {\n var letter = meta.shift();\n switch ( letter ) {\n case \" \" :\n // if we're in a quoted section, keep it\n if ( in_quotes ) {\n parts[ parts.length - 1 ] += letter;\n }\n // otherwise make a new part\n else {\n parts.push( \"\" );\n }\n break;\n case \"'\" :\n case '\"' :\n // reverse the quotes and move straight on\n in_quotes = !in_quotes;\n break;\n case \"\\\\\" :\n // shift off the next letter to be used straight away.\n // it was escaped so we'll keep it whatever it is\n letter = meta.shift();\n default :\n parts[ parts.length - 1 ] += letter;\n break;\n }\n }\n\n return parts;\n}\n\nMarkdown.dialects.Maruku.block.document_meta = function document_meta( block, next ) {\n // we're only interested in the first block\n if ( block.lineNumber > 1 ) return undefined;\n\n // document_meta blocks consist of one or more lines of `Key: Value\\n`\n if ( ! block.match( /^(?:\\w+:.*\\n)*\\w+:.*$/ ) ) return undefined;\n\n // make an attribute node if it doesn't exist\n if ( !extract_attr( this.tree ) ) {\n this.tree.splice( 1, 0, {} );\n }\n\n var pairs = block.split( /\\n/ );\n for ( p in pairs ) {\n var m = pairs[ p ].match( /(\\w+):\\s*(.*)$/ ),\n key = m[ 1 ].toLowerCase(),\n value = m[ 2 ];\n\n this.tree[ 1 ][ key ] = value;\n }\n\n // document_meta produces no content!\n return [];\n};\n\nMarkdown.dialects.Maruku.block.block_meta = function block_meta( block, next ) {\n // check if the last line of the block is an meta hash\n var m = block.match( /(^|\\n) {0,3}\\{:\\s*((?:\\\\\\}|[^\\}])*)\\s*\\}$/ );\n if ( !m ) return undefined;\n\n // process the meta hash\n var attr = this.dialect.processMetaHash( m[ 2 ] );\n\n var hash;\n\n // if we matched ^ then we need to apply meta to the previous block\n if ( m[ 1 ] === \"\" ) {\n var node = this.tree[ this.tree.length - 1 ];\n hash = extract_attr( node );\n\n // if the node is a string (rather than JsonML), bail\n if ( typeof node === \"string\" ) return undefined;\n\n // create the attribute hash if it doesn't exist\n if ( !hash ) {\n hash = {};\n node.splice( 1, 0, hash );\n }\n\n // add the attributes in\n for ( a in attr ) {\n hash[ a ] = attr[ a ];\n }\n\n // return nothing so the meta hash is removed\n return [];\n }\n\n // pull the meta hash off the block and process what's left\n var b = block.replace( /\\n.*$/, \"\" ),\n result = this.processBlock( b, [] );\n\n // get or make the attributes hash\n hash = extract_attr( result[ 0 ] );\n if ( !hash ) {\n hash = {};\n result[ 0 ].splice( 1, 0, hash );\n }\n\n // attach the attributes to the block\n for ( a in attr ) {\n hash[ a ] = attr[ a ];\n }\n\n return result;\n};\n\nMarkdown.dialects.Maruku.block.definition_list = function definition_list( block, next ) {\n // one or more terms followed by one or more definitions, in a single block\n var tight = /^((?:[^\\s:].*\\n)+):\\s+([\\s\\S]+)$/,\n list = [ \"dl\" ],\n i, m;\n\n // see if we're dealing with a tight or loose block\n if ( ( m = block.match( tight ) ) ) {\n // pull subsequent tight DL blocks out of `next`\n var blocks = [ block ];\n while ( next.length && tight.exec( next[ 0 ] ) ) {\n blocks.push( next.shift() );\n }\n\n for ( var b = 0; b < blocks.length; ++b ) {\n var m = blocks[ b ].match( tight ),\n terms = m[ 1 ].replace( /\\n$/, \"\" ).split( /\\n/ ),\n defns = m[ 2 ].split( /\\n:\\s+/ );\n\n // print( uneval( m ) );\n\n for ( i = 0; i < terms.length; ++i ) {\n list.push( [ \"dt\", terms[ i ] ] );\n }\n\n for ( i = 0; i < defns.length; ++i ) {\n // run inline processing over the definition\n list.push( [ \"dd\" ].concat( this.processInline( defns[ i ].replace( /(\\n)\\s+/, \"$1\" ) ) ) );\n }\n }\n }\n else {\n return undefined;\n }\n\n return [ list ];\n};\n\n// splits on unescaped instances of @ch. If @ch is not a character the result\n// can be unpredictable\n\nMarkdown.dialects.Maruku.block.table = function table (block, next) {\n\n var _split_on_unescaped = function(s, ch) {\n ch = ch || '\\\\s';\n if (ch.match(/^[\\\\|\\[\\]{}?*.+^$]$/)) { ch = '\\\\' + ch; }\n var res = [ ],\n r = new RegExp('^((?:\\\\\\\\.|[^\\\\\\\\' + ch + '])*)' + ch + '(.*)'),\n m;\n while(m = s.match(r)) {\n res.push(m[1]);\n s = m[2];\n }\n res.push(s);\n return res;\n }\n\n var leading_pipe = /^ {0,3}\\|(.+)\\n {0,3}\\|\\s*([\\-:]+[\\-| :]*)\\n((?:\\s*\\|.*(?:\\n|$))*)(?=\\n|$)/,\n // find at least an unescaped pipe in each line\n no_leading_pipe = /^ {0,3}(\\S(?:\\\\.|[^\\\\|])*\\|.*)\\n {0,3}([\\-:]+\\s*\\|[\\-| :]*)\\n((?:(?:\\\\.|[^\\\\|])*\\|.*(?:\\n|$))*)(?=\\n|$)/,\n i, m;\n if (m = block.match(leading_pipe)) {\n // remove leading pipes in contents\n // (header and horizontal rule already have the leading pipe left out)\n m[3] = m[3].replace(/^\\s*\\|/gm, '');\n } else if (! ( m = block.match(no_leading_pipe))) {\n return undefined;\n }\n\n var table = [ \"table\", [ \"thead\", [ \"tr\" ] ], [ \"tbody\" ] ];\n\n // remove trailing pipes, then split on pipes\n // (no escaped pipes are allowed in horizontal rule)\n m[2] = m[2].replace(/\\|\\s*$/, '').split('|');\n\n // process alignment\n var html_attrs = [ ];\n forEach (m[2], function (s) {\n if (s.match(/^\\s*-+:\\s*$/)) html_attrs.push({align: \"right\"});\n else if (s.match(/^\\s*:-+\\s*$/)) html_attrs.push({align: \"left\"});\n else if (s.match(/^\\s*:-+:\\s*$/)) html_attrs.push({align: \"center\"});\n else html_attrs.push({});\n });\n\n // now for the header, avoid escaped pipes\n m[1] = _split_on_unescaped(m[1].replace(/\\|\\s*$/, ''), '|');\n for (i = 0; i < m[1].length; i++) {\n table[1][1].push(['th', html_attrs[i] || {}].concat(\n this.processInline(m[1][i].trim())));\n }\n\n // now for body contents\n forEach (m[3].replace(/\\|\\s*$/mg, '').split('\\n'), function (row) {\n var html_row = ['tr'];\n row = _split_on_unescaped(row, '|');\n for (i = 0; i < row.length; i++) {\n html_row.push(['td', html_attrs[i] || {}].concat(this.processInline(row[i].trim())));\n }\n table[2].push(html_row);\n }, this);\n\n return [table];\n}\n\nMarkdown.dialects.Maruku.inline[ \"{:\" ] = function inline_meta( text, matches, out ) {\n if ( !out.length ) {\n return [ 2, \"{:\" ];\n }\n\n // get the preceeding element\n var before = out[ out.length - 1 ];\n\n if ( typeof before === \"string\" ) {\n return [ 2, \"{:\" ];\n }\n\n // match a meta hash\n var m = text.match( /^\\{:\\s*((?:\\\\\\}|[^\\}])*)\\s*\\}/ );\n\n // no match, false alarm\n if ( !m ) {\n return [ 2, \"{:\" ];\n }\n\n // attach the attributes to the preceeding element\n var meta = this.dialect.processMetaHash( m[ 1 ] ),\n attr = extract_attr( before );\n\n if ( !attr ) {\n attr = {};\n before.splice( 1, 0, attr );\n }\n\n for ( var k in meta ) {\n attr[ k ] = meta[ k ];\n }\n\n // cut out the string and replace it with nothing\n return [ m[ 0 ].length, \"\" ];\n};\n\nMarkdown.dialects.Maruku.inline.__escape__ = /^\\\\[\\\\`\\*_{}\\[\\]()#\\+.!\\-|:]/;\n\nMarkdown.buildBlockOrder ( Markdown.dialects.Maruku.block );\nMarkdown.buildInlinePatterns( Markdown.dialects.Maruku.inline );\n\nvar isArray = Array.isArray || function(obj) {\n return Object.prototype.toString.call(obj) == \"[object Array]\";\n};\n\nvar forEach;\n// Don't mess with Array.prototype. Its not friendly\nif ( Array.prototype.forEach ) {\n forEach = function( arr, cb, thisp ) {\n return arr.forEach( cb, thisp );\n };\n}\nelse {\n forEach = function(arr, cb, thisp) {\n for (var i = 0; i < arr.length; i++) {\n cb.call(thisp || arr, arr[i], i, arr);\n }\n }\n}\n\nvar isEmpty = function( obj ) {\n for ( var key in obj ) {\n if ( hasOwnProperty.call( obj, key ) ) {\n return false;\n }\n }\n\n return true;\n}\n\nfunction extract_attr( jsonml ) {\n return isArray(jsonml)\n && jsonml.length > 1\n && typeof jsonml[ 1 ] === \"object\"\n && !( isArray(jsonml[ 1 ]) )\n ? jsonml[ 1 ]\n : undefined;\n}\n\n\n\n/**\n * renderJsonML( jsonml[, options] ) -> String\n * - jsonml (Array): JsonML array to render to XML\n * - options (Object): options\n *\n * Converts the given JsonML into well-formed XML.\n *\n * The options currently understood are:\n *\n * - root (Boolean): wether or not the root node should be included in the\n * output, or just its children. The default `false` is to not include the\n * root itself.\n */\nexpose.renderJsonML = function( jsonml, options ) {\n options = options || {};\n // include the root element in the rendered output?\n options.root = options.root || false;\n\n var content = [];\n\n if ( options.root ) {\n content.push( render_tree( jsonml ) );\n }\n else {\n jsonml.shift(); // get rid of the tag\n if ( jsonml.length && typeof jsonml[ 0 ] === \"object\" && !( jsonml[ 0 ] instanceof Array ) ) {\n jsonml.shift(); // get rid of the attributes\n }\n\n while ( jsonml.length ) {\n content.push( render_tree( jsonml.shift() ) );\n }\n }\n\n return content.join( \"\\n\\n\" );\n};\n\nfunction escapeHTML( text ) {\n return text.replace( /&/g, \"&\" )\n .replace( //g, \">\" )\n .replace( /\"/g, \""\" )\n .replace( /'/g, \"'\" );\n}\n\nfunction render_tree( jsonml ) {\n // basic case\n if ( typeof jsonml === \"string\" ) {\n return escapeHTML( jsonml );\n }\n\n var tag = jsonml.shift(),\n attributes = {},\n content = [];\n\n if ( jsonml.length && typeof jsonml[ 0 ] === \"object\" && !( jsonml[ 0 ] instanceof Array ) ) {\n attributes = jsonml.shift();\n }\n\n while ( jsonml.length ) {\n content.push( render_tree( jsonml.shift() ) );\n }\n\n var tag_attrs = \"\";\n for ( var a in attributes ) {\n tag_attrs += \" \" + a + '=\"' + escapeHTML( attributes[ a ] ) + '\"';\n }\n\n // be careful about adding whitespace here for inline elements\n if ( tag == \"img\" || tag == \"br\" || tag == \"hr\" ) {\n return \"<\"+ tag + tag_attrs + \"/>\";\n }\n else {\n return \"<\"+ tag + tag_attrs + \">\" + content.join( \"\" ) + \"\";\n }\n}\n\nfunction convert_tree_to_html( tree, references, options ) {\n var i;\n options = options || {};\n\n // shallow clone\n var jsonml = tree.slice( 0 );\n\n if ( typeof options.preprocessTreeNode === \"function\" ) {\n jsonml = options.preprocessTreeNode(jsonml, references);\n }\n\n // Clone attributes if they exist\n var attrs = extract_attr( jsonml );\n if ( attrs ) {\n jsonml[ 1 ] = {};\n for ( i in attrs ) {\n jsonml[ 1 ][ i ] = attrs[ i ];\n }\n attrs = jsonml[ 1 ];\n }\n\n // basic case\n if ( typeof jsonml === \"string\" ) {\n return jsonml;\n }\n\n // convert this node\n switch ( jsonml[ 0 ] ) {\n case \"header\":\n jsonml[ 0 ] = \"h\" + jsonml[ 1 ].level;\n delete jsonml[ 1 ].level;\n break;\n case \"bulletlist\":\n jsonml[ 0 ] = \"ul\";\n break;\n case \"numberlist\":\n jsonml[ 0 ] = \"ol\";\n break;\n case \"listitem\":\n jsonml[ 0 ] = \"li\";\n break;\n case \"para\":\n jsonml[ 0 ] = \"p\";\n break;\n case \"markdown\":\n jsonml[ 0 ] = \"html\";\n if ( attrs ) delete attrs.references;\n break;\n case \"code_block\":\n jsonml[ 0 ] = \"pre\";\n i = attrs ? 2 : 1;\n var code = [ \"code\" ];\n code.push.apply( code, jsonml.splice( i, jsonml.length - i ) );\n jsonml[ i ] = code;\n break;\n case \"inlinecode\":\n jsonml[ 0 ] = \"code\";\n break;\n case \"img\":\n jsonml[ 1 ].src = jsonml[ 1 ].href;\n delete jsonml[ 1 ].href;\n break;\n case \"linebreak\":\n jsonml[ 0 ] = \"br\";\n break;\n case \"link\":\n jsonml[ 0 ] = \"a\";\n break;\n case \"link_ref\":\n jsonml[ 0 ] = \"a\";\n\n // grab this ref and clean up the attribute node\n var ref = references[ attrs.ref ];\n\n // if the reference exists, make the link\n if ( ref ) {\n delete attrs.ref;\n\n // add in the href and title, if present\n attrs.href = ref.href;\n if ( ref.title ) {\n attrs.title = ref.title;\n }\n\n // get rid of the unneeded original text\n delete attrs.original;\n }\n // the reference doesn't exist, so revert to plain text\n else {\n return attrs.original;\n }\n break;\n case \"img_ref\":\n jsonml[ 0 ] = \"img\";\n\n // grab this ref and clean up the attribute node\n var ref = references[ attrs.ref ];\n\n // if the reference exists, make the link\n if ( ref ) {\n delete attrs.ref;\n\n // add in the href and title, if present\n attrs.src = ref.href;\n if ( ref.title ) {\n attrs.title = ref.title;\n }\n\n // get rid of the unneeded original text\n delete attrs.original;\n }\n // the reference doesn't exist, so revert to plain text\n else {\n return attrs.original;\n }\n break;\n }\n\n // convert all the children\n i = 1;\n\n // deal with the attribute node, if it exists\n if ( attrs ) {\n // if there are keys, skip over it\n for ( var key in jsonml[ 1 ] ) {\n i = 2;\n break;\n }\n // if there aren't, remove it\n if ( i === 1 ) {\n jsonml.splice( i, 1 );\n }\n }\n\n for ( ; i < jsonml.length; ++i ) {\n jsonml[ i ] = convert_tree_to_html( jsonml[ i ], references, options );\n }\n\n return jsonml;\n}\n\n\n// merges adjacent text nodes into a single node\nfunction merge_text_nodes( jsonml ) {\n // skip the tag name and attribute hash\n var i = extract_attr( jsonml ) ? 2 : 1;\n\n while ( i < jsonml.length ) {\n // if it's a string check the next item too\n if ( typeof jsonml[ i ] === \"string\" ) {\n if ( i + 1 < jsonml.length && typeof jsonml[ i + 1 ] === \"string\" ) {\n // merge the second string into the first and remove it\n jsonml[ i ] += jsonml.splice( i + 1, 1 )[ 0 ];\n }\n else {\n ++i;\n }\n }\n // if it's not a string recurse\n else {\n merge_text_nodes( jsonml[ i ] );\n ++i;\n }\n }\n}\n\n} )( (function() {\n if ( typeof exports === \"undefined\" ) {\n window.markdown = {};\n return window.markdown;\n }\n else {\n return exports;\n }\n} )() );\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./node_modules/markdown/lib/markdown.js\n// module id = 1406\n// module chunks = 30","// Copyright Joyent, Inc. and other Node contributors.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a\n// 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 permit\n// persons to whom the Software is furnished to do so, subject to the\n// following conditions:\n//\n// The above copyright notice and this permission notice shall be included\n// in all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS\n// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\n// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN\n// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR\n// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE\n// USE OR OTHER DEALINGS IN THE SOFTWARE.\n\nvar formatRegExp = /%[sdj%]/g;\nexports.format = function(f) {\n if (!isString(f)) {\n var objects = [];\n for (var i = 0; i < arguments.length; i++) {\n objects.push(inspect(arguments[i]));\n }\n return objects.join(' ');\n }\n\n var i = 1;\n var args = arguments;\n var len = args.length;\n var str = String(f).replace(formatRegExp, function(x) {\n if (x === '%%') return '%';\n if (i >= len) return x;\n switch (x) {\n case '%s': return String(args[i++]);\n case '%d': return Number(args[i++]);\n case '%j':\n try {\n return JSON.stringify(args[i++]);\n } catch (_) {\n return '[Circular]';\n }\n default:\n return x;\n }\n });\n for (var x = args[i]; i < len; x = args[++i]) {\n if (isNull(x) || !isObject(x)) {\n str += ' ' + x;\n } else {\n str += ' ' + inspect(x);\n }\n }\n return str;\n};\n\n\n// Mark that a method should not be used.\n// Returns a modified function which warns once by default.\n// If --no-deprecation is set, then it is a no-op.\nexports.deprecate = function(fn, msg) {\n // Allow for deprecating things in the process of starting up.\n if (isUndefined(global.process)) {\n return function() {\n return exports.deprecate(fn, msg).apply(this, arguments);\n };\n }\n\n if (process.noDeprecation === true) {\n return fn;\n }\n\n var warned = false;\n function deprecated() {\n if (!warned) {\n if (process.throwDeprecation) {\n throw new Error(msg);\n } else if (process.traceDeprecation) {\n console.trace(msg);\n } else {\n console.error(msg);\n }\n warned = true;\n }\n return fn.apply(this, arguments);\n }\n\n return deprecated;\n};\n\n\nvar debugs = {};\nvar debugEnviron;\nexports.debuglog = function(set) {\n if (isUndefined(debugEnviron))\n debugEnviron = process.env.NODE_DEBUG || '';\n set = set.toUpperCase();\n if (!debugs[set]) {\n if (new RegExp('\\\\b' + set + '\\\\b', 'i').test(debugEnviron)) {\n var pid = process.pid;\n debugs[set] = function() {\n var msg = exports.format.apply(exports, arguments);\n console.error('%s %d: %s', set, pid, msg);\n };\n } else {\n debugs[set] = function() {};\n }\n }\n return debugs[set];\n};\n\n\n/**\n * Echos the value of a value. Trys to print the value out\n * in the best way possible given the different types.\n *\n * @param {Object} obj The object to print out.\n * @param {Object} opts Optional options object that alters the output.\n */\n/* legacy: obj, showHidden, depth, colors*/\nfunction inspect(obj, opts) {\n // default options\n var ctx = {\n seen: [],\n stylize: stylizeNoColor\n };\n // legacy...\n if (arguments.length >= 3) ctx.depth = arguments[2];\n if (arguments.length >= 4) ctx.colors = arguments[3];\n if (isBoolean(opts)) {\n // legacy...\n ctx.showHidden = opts;\n } else if (opts) {\n // got an \"options\" object\n exports._extend(ctx, opts);\n }\n // set default options\n if (isUndefined(ctx.showHidden)) ctx.showHidden = false;\n if (isUndefined(ctx.depth)) ctx.depth = 2;\n if (isUndefined(ctx.colors)) ctx.colors = false;\n if (isUndefined(ctx.customInspect)) ctx.customInspect = true;\n if (ctx.colors) ctx.stylize = stylizeWithColor;\n return formatValue(ctx, obj, ctx.depth);\n}\nexports.inspect = inspect;\n\n\n// http://en.wikipedia.org/wiki/ANSI_escape_code#graphics\ninspect.colors = {\n 'bold' : [1, 22],\n 'italic' : [3, 23],\n 'underline' : [4, 24],\n 'inverse' : [7, 27],\n 'white' : [37, 39],\n 'grey' : [90, 39],\n 'black' : [30, 39],\n 'blue' : [34, 39],\n 'cyan' : [36, 39],\n 'green' : [32, 39],\n 'magenta' : [35, 39],\n 'red' : [31, 39],\n 'yellow' : [33, 39]\n};\n\n// Don't use 'blue' not visible on cmd.exe\ninspect.styles = {\n 'special': 'cyan',\n 'number': 'yellow',\n 'boolean': 'yellow',\n 'undefined': 'grey',\n 'null': 'bold',\n 'string': 'green',\n 'date': 'magenta',\n // \"name\": intentionally not styling\n 'regexp': 'red'\n};\n\n\nfunction stylizeWithColor(str, styleType) {\n var style = inspect.styles[styleType];\n\n if (style) {\n return '\\u001b[' + inspect.colors[style][0] + 'm' + str +\n '\\u001b[' + inspect.colors[style][1] + 'm';\n } else {\n return str;\n }\n}\n\n\nfunction stylizeNoColor(str, styleType) {\n return str;\n}\n\n\nfunction arrayToHash(array) {\n var hash = {};\n\n array.forEach(function(val, idx) {\n hash[val] = true;\n });\n\n return hash;\n}\n\n\nfunction formatValue(ctx, value, recurseTimes) {\n // Provide a hook for user-specified inspect functions.\n // Check that value is an object with an inspect function on it\n if (ctx.customInspect &&\n value &&\n isFunction(value.inspect) &&\n // Filter out the util module, it's inspect function is special\n value.inspect !== exports.inspect &&\n // Also filter out any prototype objects using the circular check.\n !(value.constructor && value.constructor.prototype === value)) {\n var ret = value.inspect(recurseTimes, ctx);\n if (!isString(ret)) {\n ret = formatValue(ctx, ret, recurseTimes);\n }\n return ret;\n }\n\n // Primitive types cannot have properties\n var primitive = formatPrimitive(ctx, value);\n if (primitive) {\n return primitive;\n }\n\n // Look up the keys of the object.\n var keys = Object.keys(value);\n var visibleKeys = arrayToHash(keys);\n\n if (ctx.showHidden) {\n keys = Object.getOwnPropertyNames(value);\n }\n\n // IE doesn't make error fields non-enumerable\n // http://msdn.microsoft.com/en-us/library/ie/dww52sbt(v=vs.94).aspx\n if (isError(value)\n && (keys.indexOf('message') >= 0 || keys.indexOf('description') >= 0)) {\n return formatError(value);\n }\n\n // Some type of object without properties can be shortcutted.\n if (keys.length === 0) {\n if (isFunction(value)) {\n var name = value.name ? ': ' + value.name : '';\n return ctx.stylize('[Function' + name + ']', 'special');\n }\n if (isRegExp(value)) {\n return ctx.stylize(RegExp.prototype.toString.call(value), 'regexp');\n }\n if (isDate(value)) {\n return ctx.stylize(Date.prototype.toString.call(value), 'date');\n }\n if (isError(value)) {\n return formatError(value);\n }\n }\n\n var base = '', array = false, braces = ['{', '}'];\n\n // Make Array say that they are Array\n if (isArray(value)) {\n array = true;\n braces = ['[', ']'];\n }\n\n // Make functions say that they are functions\n if (isFunction(value)) {\n var n = value.name ? ': ' + value.name : '';\n base = ' [Function' + n + ']';\n }\n\n // Make RegExps say that they are RegExps\n if (isRegExp(value)) {\n base = ' ' + RegExp.prototype.toString.call(value);\n }\n\n // Make dates with properties first say the date\n if (isDate(value)) {\n base = ' ' + Date.prototype.toUTCString.call(value);\n }\n\n // Make error with message first say the error\n if (isError(value)) {\n base = ' ' + formatError(value);\n }\n\n if (keys.length === 0 && (!array || value.length == 0)) {\n return braces[0] + base + braces[1];\n }\n\n if (recurseTimes < 0) {\n if (isRegExp(value)) {\n return ctx.stylize(RegExp.prototype.toString.call(value), 'regexp');\n } else {\n return ctx.stylize('[Object]', 'special');\n }\n }\n\n ctx.seen.push(value);\n\n var output;\n if (array) {\n output = formatArray(ctx, value, recurseTimes, visibleKeys, keys);\n } else {\n output = keys.map(function(key) {\n return formatProperty(ctx, value, recurseTimes, visibleKeys, key, array);\n });\n }\n\n ctx.seen.pop();\n\n return reduceToSingleString(output, base, braces);\n}\n\n\nfunction formatPrimitive(ctx, value) {\n if (isUndefined(value))\n return ctx.stylize('undefined', 'undefined');\n if (isString(value)) {\n var simple = '\\'' + JSON.stringify(value).replace(/^\"|\"$/g, '')\n .replace(/'/g, \"\\\\'\")\n .replace(/\\\\\"/g, '\"') + '\\'';\n return ctx.stylize(simple, 'string');\n }\n if (isNumber(value))\n return ctx.stylize('' + value, 'number');\n if (isBoolean(value))\n return ctx.stylize('' + value, 'boolean');\n // For some reason typeof null is \"object\", so special case here.\n if (isNull(value))\n return ctx.stylize('null', 'null');\n}\n\n\nfunction formatError(value) {\n return '[' + Error.prototype.toString.call(value) + ']';\n}\n\n\nfunction formatArray(ctx, value, recurseTimes, visibleKeys, keys) {\n var output = [];\n for (var i = 0, l = value.length; i < l; ++i) {\n if (hasOwnProperty(value, String(i))) {\n output.push(formatProperty(ctx, value, recurseTimes, visibleKeys,\n String(i), true));\n } else {\n output.push('');\n }\n }\n keys.forEach(function(key) {\n if (!key.match(/^\\d+$/)) {\n output.push(formatProperty(ctx, value, recurseTimes, visibleKeys,\n key, true));\n }\n });\n return output;\n}\n\n\nfunction formatProperty(ctx, value, recurseTimes, visibleKeys, key, array) {\n var name, str, desc;\n desc = Object.getOwnPropertyDescriptor(value, key) || { value: value[key] };\n if (desc.get) {\n if (desc.set) {\n str = ctx.stylize('[Getter/Setter]', 'special');\n } else {\n str = ctx.stylize('[Getter]', 'special');\n }\n } else {\n if (desc.set) {\n str = ctx.stylize('[Setter]', 'special');\n }\n }\n if (!hasOwnProperty(visibleKeys, key)) {\n name = '[' + key + ']';\n }\n if (!str) {\n if (ctx.seen.indexOf(desc.value) < 0) {\n if (isNull(recurseTimes)) {\n str = formatValue(ctx, desc.value, null);\n } else {\n str = formatValue(ctx, desc.value, recurseTimes - 1);\n }\n if (str.indexOf('\\n') > -1) {\n if (array) {\n str = str.split('\\n').map(function(line) {\n return ' ' + line;\n }).join('\\n').substr(2);\n } else {\n str = '\\n' + str.split('\\n').map(function(line) {\n return ' ' + line;\n }).join('\\n');\n }\n }\n } else {\n str = ctx.stylize('[Circular]', 'special');\n }\n }\n if (isUndefined(name)) {\n if (array && key.match(/^\\d+$/)) {\n return str;\n }\n name = JSON.stringify('' + key);\n if (name.match(/^\"([a-zA-Z_][a-zA-Z_0-9]*)\"$/)) {\n name = name.substr(1, name.length - 2);\n name = ctx.stylize(name, 'name');\n } else {\n name = name.replace(/'/g, \"\\\\'\")\n .replace(/\\\\\"/g, '\"')\n .replace(/(^\"|\"$)/g, \"'\");\n name = ctx.stylize(name, 'string');\n }\n }\n\n return name + ': ' + str;\n}\n\n\nfunction reduceToSingleString(output, base, braces) {\n var numLinesEst = 0;\n var length = output.reduce(function(prev, cur) {\n numLinesEst++;\n if (cur.indexOf('\\n') >= 0) numLinesEst++;\n return prev + cur.replace(/\\u001b\\[\\d\\d?m/g, '').length + 1;\n }, 0);\n\n if (length > 60) {\n return braces[0] +\n (base === '' ? '' : base + '\\n ') +\n ' ' +\n output.join(',\\n ') +\n ' ' +\n braces[1];\n }\n\n return braces[0] + base + ' ' + output.join(', ') + ' ' + braces[1];\n}\n\n\n// NOTE: These type checking functions intentionally don't use `instanceof`\n// because it is fragile and can be easily faked with `Object.create()`.\nfunction isArray(ar) {\n return Array.isArray(ar);\n}\nexports.isArray = isArray;\n\nfunction isBoolean(arg) {\n return typeof arg === 'boolean';\n}\nexports.isBoolean = isBoolean;\n\nfunction isNull(arg) {\n return arg === null;\n}\nexports.isNull = isNull;\n\nfunction isNullOrUndefined(arg) {\n return arg == null;\n}\nexports.isNullOrUndefined = isNullOrUndefined;\n\nfunction isNumber(arg) {\n return typeof arg === 'number';\n}\nexports.isNumber = isNumber;\n\nfunction isString(arg) {\n return typeof arg === 'string';\n}\nexports.isString = isString;\n\nfunction isSymbol(arg) {\n return typeof arg === 'symbol';\n}\nexports.isSymbol = isSymbol;\n\nfunction isUndefined(arg) {\n return arg === void 0;\n}\nexports.isUndefined = isUndefined;\n\nfunction isRegExp(re) {\n return isObject(re) && objectToString(re) === '[object RegExp]';\n}\nexports.isRegExp = isRegExp;\n\nfunction isObject(arg) {\n return typeof arg === 'object' && arg !== null;\n}\nexports.isObject = isObject;\n\nfunction isDate(d) {\n return isObject(d) && objectToString(d) === '[object Date]';\n}\nexports.isDate = isDate;\n\nfunction isError(e) {\n return isObject(e) &&\n (objectToString(e) === '[object Error]' || e instanceof Error);\n}\nexports.isError = isError;\n\nfunction isFunction(arg) {\n return typeof arg === 'function';\n}\nexports.isFunction = isFunction;\n\nfunction isPrimitive(arg) {\n return arg === null ||\n typeof arg === 'boolean' ||\n typeof arg === 'number' ||\n typeof arg === 'string' ||\n typeof arg === 'symbol' || // ES6 symbol\n typeof arg === 'undefined';\n}\nexports.isPrimitive = isPrimitive;\n\nexports.isBuffer = require('./support/isBuffer');\n\nfunction objectToString(o) {\n return Object.prototype.toString.call(o);\n}\n\n\nfunction pad(n) {\n return n < 10 ? '0' + n.toString(10) : n.toString(10);\n}\n\n\nvar months = ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep',\n 'Oct', 'Nov', 'Dec'];\n\n// 26 Feb 16:19:34\nfunction timestamp() {\n var d = new Date();\n var time = [pad(d.getHours()),\n pad(d.getMinutes()),\n pad(d.getSeconds())].join(':');\n return [d.getDate(), months[d.getMonth()], time].join(' ');\n}\n\n\n// log is just a thin wrapper to console.log that prepends a timestamp\nexports.log = function() {\n console.log('%s - %s', timestamp(), exports.format.apply(exports, arguments));\n};\n\n\n/**\n * Inherit the prototype methods from one constructor into another.\n *\n * The Function.prototype.inherits from lang.js rewritten as a standalone\n * function (not on Function.prototype). NOTE: If this file is to be loaded\n * during bootstrapping this function needs to be rewritten using some native\n * functions as prototype setup using normal JavaScript does not work as\n * expected during bootstrapping (see mirror.js in r114903).\n *\n * @param {function} ctor Constructor function which needs to inherit the\n * prototype.\n * @param {function} superCtor Constructor function to inherit prototype from.\n */\nexports.inherits = require('inherits');\n\nexports._extend = function(origin, add) {\n // Don't do anything if add isn't an object\n if (!add || !isObject(add)) return origin;\n\n var keys = Object.keys(add);\n var i = keys.length;\n while (i--) {\n origin[keys[i]] = add[keys[i]];\n }\n return origin;\n};\n\nfunction hasOwnProperty(obj, prop) {\n return Object.prototype.hasOwnProperty.call(obj, prop);\n}\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./node_modules/util/util.js\n// module id = 1407\n// module chunks = 30","module.exports = function isBuffer(arg) {\n return arg && typeof arg === 'object'\n && typeof arg.copy === 'function'\n && typeof arg.fill === 'function'\n && typeof arg.readUInt8 === 'function';\n}\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./node_modules/util/support/isBufferBrowser.js\n// module id = 1408\n// module chunks = 30","if (typeof Object.create === 'function') {\n // implementation from standard node.js 'util' module\n module.exports = function inherits(ctor, superCtor) {\n ctor.super_ = superCtor\n ctor.prototype = Object.create(superCtor.prototype, {\n constructor: {\n value: ctor,\n enumerable: false,\n writable: true,\n configurable: true\n }\n });\n };\n} else {\n // old school shim for old browsers\n module.exports = function inherits(ctor, superCtor) {\n ctor.super_ = superCtor\n var TempCtor = function () {}\n TempCtor.prototype = superCtor.prototype\n ctor.prototype = new TempCtor()\n ctor.prototype.constructor = ctor\n }\n}\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./node_modules/util/node_modules/inherits/inherits_browser.js\n// module id = 1409\n// module chunks = 30"],"sourceRoot":""}




  • © 2015 - 2024 Weber Informatics LLC | Privacy Policy