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

web-interface.assets.325e2d4b-9859.5e9affa757691f7f7d4d.js.map Maven / Gradle / Ivy

There is a newer version: 6.0.2
Show newest version
{"version":3,"file":"325e2d4b-9859.5e9affa757691f7f7d4d.js","mappings":"mSAyBA,MAAMA,UAAmCC,EAAAA,UAMvCC,YAAYC,GACVC,MAAMD,GAENE,KAAKC,YAAcD,KAAKC,YAAYC,KAAKF,KAC1C,CAEDG,kBACE,MAAM,cAAEC,EAAF,SAAiBC,GAAaL,KAAKF,MAEzC,OAAOQ,EAAAA,EAAAA,IAAWC,EAAAA,EAAAA,uBAAAA,YAA6CH,EAAeC,GAAUG,IACzF,CAEDP,cACED,KAAKS,cAAcC,OACpB,CAEDC,OACEX,KAAKS,cAAcE,MACpB,CAEDC,SAGE,OACE,gBAAC,IAAD,CAAuBC,IAAMC,IAAWd,KAAKS,cAAgBK,CAArB,EAA8BC,OAAO,SAC3E,gBAAC,YAAD,CAAcC,aAAW,GACvB,gBAAC,WAAD,+BAEF,gBAAC,UAAD,KACE,yBARW,sGASX,yBACE,qBAAGC,KAAMjB,KAAKG,kBAAmBe,OAAO,SAASC,IAAI,uBACnD,gBAAC,KAAD,CAAMC,KAAK,uBAAwB,IADrC,cAKJ,gBAAC,YAAD,KACE,gBAAC,KAAD,CAAQC,QAASrB,KAAKC,aAAtB,UAIP,E,EA/CGN,E,EAAAA,Y,EACe,CACjBS,cAAekB,IAAAA,OAAAA,WACfjB,SAAUiB,IAAAA,OAAAA,Y,6FA+Cd,S,2RCjDA,MAAMC,UAA2B3B,EAAAA,UAU/BC,YAAYC,GACVC,MAAMD,GADW,oBAsBP,KACV,GAAIE,KAAKwB,iBAAkB,CACzB,MAAMpB,EAAgBJ,KAAKF,MAAM2B,YAAYC,GACvCC,EAAiB3B,KAAKF,MAAM2B,YAAYG,IACxCC,EAAa7B,KAAK8B,uBAExB9B,KAAKF,MAAMiC,UAAU3B,EAAeuB,EAAgB,CAAEE,WAAYA,E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qCX,G,mFChHCC,E,MAA0B,GAA4B,KAE1DA,EAAwBC,KAAK,CAACC,EAAO1K,GAAI,0DAA2D,GAAG,CAAC,QAAU,EAAE,QAAU,CAAC,0EAA0E,MAAQ,GAAG,SAAW,yBAAyB,eAAiB,CAAC,qDAAqD,WAAa,MAE5UwK,EAAwBG,OAAS,CAChC,OAAU,wBAEX,S","sources":["webpack://graylog-web-interface/./src/components/content-packs/ContentPackDownloadControl.jsx","webpack://graylog-web-interface/./src/components/content-packs/ContentPackInstall.jsx","webpack://graylog-web-interface/./src/components/content-packs/ContentPacksList.jsx","webpack://graylog-web-interface/./src/components/content-packs/ContentPackUploadControls.css?3063","webpack://graylog-web-interface/./src/components/content-packs/ContentPackUploadControls.jsx","webpack://graylog-web-interface/./src/pages/ContentPacksPage.jsx","webpack://graylog-web-interface/./src/components/content-packs/ContentPackUploadControls.css"],"sourcesContent":["/*\n * Copyright (C) 2020 Graylog, Inc.\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the Server Side Public License, version 1,\n * as published by MongoDB, Inc.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * Server Side Public License for more details.\n *\n * You should have received a copy of the Server Side Public License\n * along with this program. If not, see\n * .\n */\nimport PropTypes from 'prop-types';\nimport React from 'react';\n\nimport { qualifyUrl } from 'util/URLUtils';\nimport ApiRoutes from 'routing/ApiRoutes';\nimport { Modal, Button } from 'components/bootstrap';\nimport { Icon } from 'components/common';\nimport BootstrapModalWrapper from 'components/bootstrap/BootstrapModalWrapper';\n\nclass ContentPackDownloadControl extends React.Component {\n  static propTypes = {\n    contentPackId: PropTypes.string.isRequired,\n    revision: PropTypes.number.isRequired,\n  };\n\n  constructor(props) {\n    super(props);\n\n    this._closeModal = this._closeModal.bind(this);\n  }\n\n  _getDownloadUrl() {\n    const { contentPackId, revision } = this.props;\n\n    return qualifyUrl(ApiRoutes.ContentPacksController.downloadRev(contentPackId, revision).url);\n  }\n\n  _closeModal() {\n    this.downloadModal.close();\n  }\n\n  open() {\n    this.downloadModal.open();\n  }\n\n  render() {\n    const infoText = 'Please right click the download link below and choose \"Save Link As...\" to download the JSON file.';\n\n    return (\n       { this.downloadModal = node; }} bsSize=\"large\">\n        \n          Download Content Pack\n        \n        \n          

{infoText}

\n

\n \n {' '}Download\n \n

\n
\n \n \n \n
\n );\n }\n}\n\nexport default ContentPackDownloadControl;\n","/*\n * Copyright (C) 2020 Graylog, Inc.\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the Server Side Public License, version 1,\n * as published by MongoDB, Inc.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * Server Side Public License for more details.\n *\n * You should have received a copy of the Server Side Public License\n * along with this program. If not, see\n * .\n */\nimport PropTypes from 'prop-types';\nimport React from 'react';\n\nimport ContentPack from 'logic/content-packs/ContentPack';\nimport { Row, Col, Input } from 'components/bootstrap';\nimport ValueRefHelper from 'util/ValueRefHelper';\n\nimport ContentPackUtils from './ContentPackUtils';\nimport ContentPackEntitiesList from './ContentPackEntitiesList';\n\nclass ContentPackInstall extends React.Component {\n static propTypes = {\n contentPack: PropTypes.object.isRequired,\n onInstall: PropTypes.func,\n };\n\n static defaultProps = {\n onInstall: () => {},\n };\n\n constructor(props) {\n super(props);\n\n const parameterInput = props.contentPack.parameters.reduce((result, parameter) => {\n if (parameter.default_value) {\n const newResult = result;\n\n newResult[parameter.name] = ContentPackUtils.convertToString(parameter);\n\n return newResult;\n }\n\n return result;\n }, {});\n\n this.state = {\n parameterInput: parameterInput,\n comment: '',\n errorMessages: {},\n };\n }\n\n onInstall = () => {\n if (this._validateInput()) {\n const contentPackId = this.props.contentPack.id;\n const contentPackRev = this.props.contentPack.rev;\n const parameters = this._convertedParameters();\n\n this.props.onInstall(contentPackId, contentPackRev, { parameters: parameters, comment: this.state.comment });\n }\n };\n\n _convertedParameters = () => {\n return Object.keys(this.state.parameterInput).reduce((result, paramName) => {\n const newResult = result;\n const paramType = this.props.contentPack.parameters.find((parameter) => parameter.name === paramName).type;\n const value = ContentPackUtils.convertValue(paramType, this.state.parameterInput[paramName]);\n\n newResult[paramName] = ValueRefHelper.createValueRef(paramType, value);\n\n return newResult;\n }, {});\n };\n\n _getValue = (name, value) => {\n const newParameterInput = this.state.parameterInput;\n\n newParameterInput[name] = value;\n this.setState({ parameterInput: newParameterInput });\n };\n\n _getComment = (e) => {\n this.setState({ comment: e.target.value });\n };\n\n _validateInput = () => {\n const { parameterInput } = this.state;\n const errors = this.props.contentPack.parameters.reduce((result, parameter) => {\n if (parameterInput[parameter.name] && parameterInput[parameter.name].length > 0) {\n return result;\n }\n\n const newResult = result;\n\n newResult[parameter.name] = 'Needs to be filled.';\n\n return newResult;\n }, {});\n\n this.setState({ errorMessages: errors });\n\n return Object.keys(errors).length <= 0;\n };\n\n renderParameter(parameter) {\n const error = this.state.errorMessages[parameter.name];\n\n return (\n { this._getValue(parameter.name, e.target.value); }}\n labelClassName=\"col-sm-3\"\n wrapperClassName=\"col-sm-7\"\n label={parameter.title}\n help={error || parameter.description}\n bsStyle={error ? 'error' : undefined}\n required />\n );\n }\n\n render() {\n const parameterInput = this.props.contentPack.parameters.map((parameter) => {\n return this.renderParameter(parameter);\n });\n const contentPack = ContentPack.fromJSON(this.props.contentPack);\n\n return (\n
\n \n \n

Install comment

\n
\n
\n \n \n
\n {parameterInput.length > 0\n && (\n \n \n

Configure Parameter

\n
\n
\n {parameterInput}\n \n
\n )}\n \n \n \n \n \n
\n );\n }\n}\n\nexport default ContentPackInstall;\n","/*\n * Copyright (C) 2020 Graylog, Inc.\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the Server Side Public License, version 1,\n * as published by MongoDB, Inc.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * Server Side Public License for more details.\n *\n * You should have received a copy of the Server Side Public License\n * along with this program. If not, see\n * .\n */\nimport PropTypes from 'prop-types';\nimport React from 'react';\n\nimport { LinkContainer, Link } from 'components/common/router';\nimport Routes from 'routing/Routes';\nimport {\n Button,\n Col,\n DropdownButton,\n MenuItem,\n Modal,\n Row,\n ButtonToolbar,\n} from 'components/bootstrap';\nimport {\n Pagination, PageSizeSelect,\n ModalSubmit,\n} from 'components/common';\nimport TypeAheadDataFilter from 'components/common/TypeAheadDataFilter';\nimport BootstrapModalWrapper from 'components/bootstrap/BootstrapModalWrapper';\nimport ControlledTableList from 'components/common/ControlledTableList';\nimport ContentPackStatus from 'components/content-packs/ContentPackStatus';\nimport ContentPackDownloadControl from 'components/content-packs/ContentPackDownloadControl';\n\nimport ContentPackInstall from './ContentPackInstall';\n\nclass ContentPacksList extends React.Component {\n static propTypes = {\n contentPacks: PropTypes.arrayOf(PropTypes.object),\n contentPackMetadata: PropTypes.object,\n onDeletePack: PropTypes.func,\n onInstall: PropTypes.func,\n };\n\n static defaultProps = {\n contentPacks: [],\n onDeletePack: () => {},\n onInstall: () => {},\n contentPackMetadata: {},\n };\n\n constructor(props) {\n super(props);\n\n this.state = {\n filteredContentPacks: props.contentPacks,\n pageSize: 10,\n currentPage: 1,\n };\n\n this._filterContentPacks = this._filterContentPacks.bind(this);\n this._itemsShownChange = this._itemsShownChange.bind(this);\n this._onChangePage = this._onChangePage.bind(this);\n }\n\n UNSAFE_componentWillReceiveProps(nextProps) {\n this.setState({ filteredContentPacks: nextProps.contentPacks });\n }\n\n _installModal(item) {\n let modalRef;\n let installRef;\n\n const { onInstall: onInstallProp } = this.props;\n\n const closeModal = () => {\n modalRef.close();\n };\n\n const open = () => {\n modalRef.open();\n };\n\n const onInstall = () => {\n installRef.onInstall();\n modalRef.close();\n };\n\n const modal = (\n { modalRef = node; }} bsSize=\"large\">\n \n Install Content Pack\n \n \n { installRef = node; }}\n contentPack={item}\n onInstall={onInstallProp} />\n \n \n \n \n \n );\n\n return { openFunc: open, installModal: modal };\n }\n\n _formatItems(items) {\n const { pageSize, currentPage } = this.state;\n const { contentPackMetadata, onDeletePack } = this.props;\n const begin = (pageSize * (currentPage - 1));\n const end = begin + pageSize;\n const shownItems = items.slice(begin, end);\n\n return shownItems.map((item) => {\n const { openFunc, installModal } = this._installModal(item);\n let downloadRef;\n const downloadModal = (\n { downloadRef = node; }}\n contentPackId={item.id}\n revision={item.rev} />\n );\n\n const metadata = contentPackMetadata[item.id] || {};\n const installed = Object.keys(metadata).find((rev) => metadata[rev].installation_count > 0);\n const states = installed ? ['installed'] : [];\n const updateButton = states.includes('updatable') ? : '';\n\n return (\n \n \n \n

{item.name} Latest Version: {item.rev} \n

\n \n \n \n {updateButton}\n \n {installModal}\n \n \n Show\n \n \n Create New Version\n \n { downloadRef.open(); }}>Download\n \n { onDeletePack(item.id); }}>Delete All Versions\n \n {downloadModal}\n \n \n
\n \n \n {item.summary} \n \n \n
\n );\n });\n }\n\n _filterContentPacks(filteredItems) {\n this.setState({ filteredContentPacks: filteredItems });\n }\n\n _itemsShownChange(event) {\n this.setState({ pageSize: Number(event.target.value), currentPage: 1 });\n }\n\n _onChangePage(nextPage) {\n this.setState({ currentPage: nextPage });\n }\n\n render() {\n const { filteredContentPacks, pageSize, currentPage } = this.state;\n const { contentPacks } = this.props;\n const numberPages = Math.ceil(filteredContentPacks.length / pageSize);\n\n const pagination = (\n \n );\n\n const pageSizeSelect = ;\n\n const noContentMessage = contentPacks.length <= 0\n ? 'No content packs found. Please create or upload one'\n : 'No matching content packs found';\n const content = filteredContentPacks.length <= 0\n ? (
{noContentMessage}
)\n : (\n \n \n {this._formatItems(filteredContentPacks)}\n \n );\n\n return (\n
\n \n \n \n \n \n {pagination}\n \n \n {pageSizeSelect}\n \n \n {content}\n \n \n \n {pagination}\n \n \n {pageSizeSelect}\n \n \n
\n );\n }\n}\n\nexport default ContentPacksList;\n","\n import API from \"!../../../node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js\";\n import domAPI from \"!../../../node_modules/style-loader/dist/runtime/styleDomAPI.js\";\n import insertFn from \"!../../../node_modules/style-loader/dist/runtime/insertBySelector.js\";\n import setAttributes from \"!../../../node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js\";\n import insertStyleElement from \"!../../../node_modules/style-loader/dist/runtime/insertStyleElement.js\";\n import styleTagTransformFn from \"!../../../node_modules/style-loader/dist/runtime/styleTagTransform.js\";\n import content, * as namedExport from \"!!../../../node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[6].use[1]!./ContentPackUploadControls.css\";\n \n \n\nvar options = {};\n\noptions.styleTagTransform = styleTagTransformFn;\noptions.setAttributes = setAttributes;\n\n options.insert = insertFn.bind(null, \"head\");\n \noptions.domAPI = domAPI;\noptions.insertStyleElement = insertStyleElement;\n\nvar update = API(content, options);\n\n\n\nexport * from \"!!../../../node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[6].use[1]!./ContentPackUploadControls.css\";\n export default content && content.locals ? content.locals : undefined;\n","/*\n * Copyright (C) 2020 Graylog, Inc.\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the Server Side Public License, version 1,\n * as published by MongoDB, Inc.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * Server Side Public License for more details.\n *\n * You should have received a copy of the Server Side Public License\n * along with this program. If not, see\n * .\n */\nimport React from 'react';\n\nimport UserNotification from 'util/UserNotification';\nimport { BootstrapModalForm, Input, Button } from 'components/bootstrap';\nimport { ContentPacksActions } from 'stores/content-packs/ContentPacksStore';\n\nimport style from './ContentPackUploadControls.css';\n\nclass ContentPackUploadControls extends React.Component {\n constructor(props) {\n super(props);\n\n this.state = {\n isOpen: false,\n };\n\n this._openModal = this._openModal.bind(this);\n this._closeModal = this._closeModal.bind(this);\n this._save = this._save.bind(this);\n }\n\n _openModal() {\n this.setState({ isOpen: true });\n this.uploadModal.open();\n }\n\n _closeModal() {\n this.uploadModal.close();\n }\n\n _save(submitEvent) {\n submitEvent.preventDefault();\n\n if (!this.uploadInput.getInputDOMNode().files || !this.uploadInput.getInputDOMNode().files[0]) {\n return;\n }\n\n const reader = new FileReader();\n\n reader.onload = (evt) => {\n const request = evt.target.result;\n\n ContentPacksActions.create.triggerPromise(request)\n .then(\n () => {\n UserNotification.success('Content pack imported successfully', 'Success!');\n ContentPacksActions.list();\n },\n (response) => {\n const message = 'Error importing content pack, please ensure it is a valid JSON file. Check your '\n + 'Graylog logs for more information.';\n const title = 'Could not import content pack';\n let smallMessage = '';\n\n if (response.additional && response.additional.body && response.additional.body.message) {\n smallMessage = `
${response.additional.body.message}`;\n }\n\n UserNotification.error(message + smallMessage, title);\n },\n );\n };\n\n reader.readAsText(this.uploadInput.getInputDOMNode().files[0]);\n this._closeModal();\n }\n\n render() {\n const { isOpen } = this.state;\n\n return (\n \n \n { this.setState({ isOpen: false }); }}\n ref={(node) => { this.uploadModal = node; }}\n onSubmitForm={this._save}\n title=\"Upload Content Pack\"\n submitButtonText=\"Upload\">\n { this.uploadInput = node; }}\n id=\"upload-content-pack\"\n label=\"Choose File\"\n type=\"file\"\n help=\"Choose Content Pack from disk\" />\n \n \n );\n }\n}\n\nexport default ContentPackUploadControls;\n","/*\n * Copyright (C) 2020 Graylog, Inc.\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the Server Side Public License, version 1,\n * as published by MongoDB, Inc.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * Server Side Public License for more details.\n *\n * You should have received a copy of the Server Side Public License\n * along with this program. If not, see\n * .\n */\nimport React from 'react';\nimport Reflux from 'reflux';\n// eslint-disable-next-line no-restricted-imports\nimport createReactClass from 'create-react-class';\nimport styled, { css } from 'styled-components';\n\nimport { LinkContainer } from 'components/common/router';\nimport { Row, Col, ButtonToolbar, Button } from 'components/bootstrap';\nimport Routes from 'routing/Routes';\nimport Spinner from 'components/common/Spinner';\nimport UserNotification from 'util/UserNotification';\nimport { DocumentTitle, PageHeader } from 'components/common';\nimport ContentPacksList from 'components/content-packs/ContentPacksList';\nimport ContentPackUploadControls from 'components/content-packs/ContentPackUploadControls';\nimport { ContentPacksActions, ContentPacksStore } from 'stores/content-packs/ContentPacksStore';\n\nconst ConfigurationBundles = styled.div(({ theme }) => css`\n font-size: ${theme.fonts.size.body};\n font-weight: normal;\n margin-top: 15px;\n`);\n\nconst ContentPacksPage = createReactClass({\n mixins: [Reflux.connect(ContentPacksStore)],\n\n componentDidMount() {\n ContentPacksActions.list();\n },\n\n _deleteContentPack(contentPackId) {\n // eslint-disable-next-line no-alert\n if (window.confirm('You are about to delete this Content Pack, are you sure?')) {\n ContentPacksActions.delete(contentPackId).then(() => {\n UserNotification.success('Content Pack deleted successfully.', 'Success');\n ContentPacksActions.list();\n }, (error) => {\n let err_message = error.message;\n const err_body = error.additional.body;\n\n if (err_body && err_body.message) {\n err_message = error.additional.body.message;\n }\n\n UserNotification.error(`Deleting bundle failed: ${err_message}`, 'Error');\n });\n }\n },\n\n _installContentPack(contentPackId, contentPackRev, parameters) {\n ContentPacksActions.install(contentPackId, contentPackRev, parameters).then(() => {\n UserNotification.success('Content Pack installed successfully.', 'Success');\n ContentPacksActions.list();\n }, (error) => {\n UserNotification.error(`Installing content pack failed with status: ${error}.\n Could not install Content Pack with ID: ${contentPackId}`);\n });\n },\n\n render() {\n const { contentPacks, contentPackMetadata } = this.state;\n\n if (!contentPacks) {\n return ();\n }\n\n return (\n \n \n Content Packs}\n actions={(\n \n \n \n \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 Find more Content Packs in {' '}\n the Graylog Marketplace.\n
\n
\n\n \n \n \n \n \n \n \n
\n
\n );\n },\n});\n\nexport default ContentPacksPage;\n","// Imports\nimport ___CSS_LOADER_API_SOURCEMAP_IMPORT___ from \"../../../node_modules/css-loader/dist/runtime/sourceMaps.js\";\nimport ___CSS_LOADER_API_IMPORT___ from \"../../../node_modules/css-loader/dist/runtime/api.js\";\nvar ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);\n// Module\n___CSS_LOADER_EXPORT___.push([module.id, \".btn.Hi7bFFbRdcngspsKDSna {\\n margin-left: 5px;\\n}\\n\", \"\",{\"version\":3,\"sources\":[\"webpack://./src/components/content-packs/ContentPackUploadControls.css\"],\"names\":[],\"mappings\":\"AAAA;IACI,gBAAgB;AACpB\",\"sourcesContent\":[\".btn:local(.button) {\\n margin-left: 5px;\\n}\\n\"],\"sourceRoot\":\"\"}]);\n// Exports\n___CSS_LOADER_EXPORT___.locals = {\n\t\"button\": \"Hi7bFFbRdcngspsKDSna\"\n};\nexport default ___CSS_LOADER_EXPORT___;\n"],"names":["ContentPackDownloadControl","React","constructor","props","super","this","_closeModal","bind","_getDownloadUrl","contentPackId","revision","qualifyUrl","ApiRoutes","url","downloadModal","close","open","render","ref","node","bsSize","closeButton","href","target","rel","name","onClick","PropTypes","ContentPackInstall","_validateInput","contentPack","id","contentPackRev","rev","parameters","_convertedParameters","onInstall","comment","state","Object","keys","parameterInput","reduce","result","paramName","newResult","paramType","find","parameter","type","value","ContentPackUtils","ValueRefHelper","newParameterInput","setState","e","errors","length","errorMessages","default_value","renderParameter","error","key","maxLength","onChange","_getValue","labelClassName","wrapperClassName","label","title","help","description","bsStyle","undefined","required","map","ContentPack","smOffset","sm","_getComment","readOnly","ContentPacksList","filteredContentPacks","contentPacks","pageSize","currentPage","_filterContentPacks","_itemsShownChange","_onChangePage","UNSAFE_componentWillReceiveProps","nextProps","_installModal","item","modalRef","installRef","onInstallProp","openFunc","installModal","BootstrapModalWrapper","submitButtonText","onSubmit","onCancel","_formatItems","items","contentPackMetadata","onDeletePack","begin","end","slice","downloadRef","metadata","states","installation_count","updateButton","includes","ControlledTableList","className","md","to","Routes","ContentPackStatus","pullRight","encodeURIComponent","onSelect","divider","summary","filteredItems","event","Number","nextPage","numberPages","Math","ceil","pagination","totalPages","pageSizeSelect","pageSizes","noContentMessage","content","TypeAheadDataFilter","data","displayKey","onDataFiltered","searchInKeys","filterSuggestions","options","styleTagTransform","setAttributes","insert","domAPI","insertStyleElement","ContentPackUploadControls","isOpen","_openModal","_save","uploadModal","submitEvent","preventDefault","uploadInput","getInputDOMNode","files","reader","FileReader","onload","evt","request","ContentPacksActions","then","UserNotification","response","smallMessage","additional","body","message","readAsText","style","active","onModalClose","onSubmitForm","ConfigurationBundles","styled","theme","css","fonts","size","createReactClass","mixins","Reflux","ContentPacksStore","componentDidMount","_deleteContentPack","window","confirm","err_message","err_body","_installContentPack","topActions","actions","Spinner","___CSS_LOADER_EXPORT___","push","module","locals"],"sourceRoot":""}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy