require(["jquery","underscore","splunkjs/mvc","splunkjs/mvc/tableview","splunkjs/mvc/simplexml/ready!"],function(__WEBPACK_EXTERNAL_MODULE_1__,__WEBPACK_EXTERNAL_MODULE_2__,__WEBPACK_EXTERNAL_MODULE_3__,__WEBPACK_EXTERNAL_MODULE_4__,__WEBPACK_EXTERNAL_MODULE_5__){return function(modules){function __webpack_require__(moduleId){if(installedModules[moduleId])return installedModules[moduleId].exports;var module=installedModules[moduleId]={exports:{},id:moduleId,loaded:!1};return modules[moduleId].call(module.exports,module,module.exports,__webpack_require__),module.loaded=!0,module.exports}var installedModules={};return __webpack_require__.m=modules,__webpack_require__.c=installedModules,__webpack_require__.p="",__webpack_require__(0)}([function(module,exports,__webpack_require__){var __WEBPACK_AMD_DEFINE_ARRAY__,__WEBPACK_AMD_DEFINE_RESULT__;__WEBPACK_AMD_DEFINE_ARRAY__=[__webpack_require__(1),__webpack_require__(2),__webpack_require__(3),__webpack_require__(4),__webpack_require__(5)],__WEBPACK_AMD_DEFINE_RESULT__=function($,_,mvc,TableView){var submitTokens=function(){mvc.Components.get("submitted").set(mvc.Components.get("default").toJSON())};mvc.Components.get("default").on("all",submitTokens),submitTokens();var FIELD_NAMES=["Interval Load Factor"],TABLE_IDS=["runtime_statistics"],COLORS={inherit:"inherit",white:"white",red:"#d6563c",yellow:"#f2b827",black:"black"},template=_.template('<div style="background-color: <%= backgroundColor %>; color: <%= textColor %>;"><%= data %></div>'),IntervalLoadFactorCellRender=TableView.BaseCellRenderer.extend({canRender:function(cell){return _.contains(FIELD_NAMES,cell.field)},render:function($td,cell){var data=parseFloat(cell.value)||0,backgroundColor=COLORS.inherit,textColor=COLORS.inherit;data>=100?(backgroundColor=COLORS.red,textColor=COLORS.white):data>=90&&(backgroundColor=COLORS.yellow,textColor=COLORS.white),$td.html(template({backgroundColor:backgroundColor,textColor:textColor,data:cell.value}))}});_.forEach(TABLE_IDS,function(id){var table=mvc.Components.get(id);table&&table.getVisualization(function(tableView){tableView.table.addCellRenderer(new IntervalLoadFactorCellRender),tableView.table.render()})})}.apply(exports,__WEBPACK_AMD_DEFINE_ARRAY__),!(void 0!==__WEBPACK_AMD_DEFINE_RESULT__&&(module.exports=__WEBPACK_AMD_DEFINE_RESULT__))},function(module,exports){module.exports=__WEBPACK_EXTERNAL_MODULE_1__},function(module,exports){module.exports=__WEBPACK_EXTERNAL_MODULE_2__},function(module,exports){module.exports=__WEBPACK_EXTERNAL_MODULE_3__},function(module,exports){module.exports=__WEBPACK_EXTERNAL_MODULE_4__},function(module,exports){module.exports=__WEBPACK_EXTERNAL_MODULE_5__}])});