wazuh-kibana-app/public/app.js

97 lines
2.4 KiB
JavaScript
Raw Normal View History

/*
* Wazuh app - File for app requirements and set up
2019-01-14 16:36:47 +00:00
* Copyright (C) 2015-2019 Wazuh, Inc.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* Find more information about this on the LICENSE file.
*/
2018-11-12 09:33:53 +00:00
import 'ui/autoload/styles';
2018-09-10 08:32:49 +00:00
import 'uiExports/visTypes';
import 'uiExports/visResponseHandlers';
import 'uiExports/visRequestHandlers';
import 'uiExports/visEditorTypes';
import 'uiExports/savedObjectTypes';
import 'uiExports/spyModes';
import 'uiExports/fieldFormats';
import 'uiExports/fieldFormatEditors';
import 'uiExports/navbarExtensions';
import 'uiExports/managementSections';
import 'uiExports/devTools';
import 'uiExports/docViews';
import 'uiExports/embeddableFactories';
import 'uiExports/autocompleteProviders';
2016-06-29 01:43:18 +00:00
// Require CSS
2018-06-15 10:42:57 +00:00
import './less/loader';
2018-07-31 09:04:36 +00:00
import { uiModules } from 'ui/modules';
2016-06-29 01:43:18 +00:00
// Set up Wazuh app
2018-06-15 10:42:57 +00:00
const app = uiModules.get('app/wazuh', ['ngCookies', 'ngMaterial']);
2018-03-06 11:03:58 +00:00
2018-09-10 08:32:49 +00:00
app.config([
'$compileProvider',
function($compileProvider) {
$compileProvider.aHrefSanitizationWhitelist(
/^\s*(https?|ftp|mailto|data|blob):/
);
}
]);
2018-03-06 11:03:58 +00:00
2018-09-10 08:32:49 +00:00
app.config([
'$httpProvider',
function($httpProvider) {
$httpProvider.useApplyAsync(true);
2018-09-10 08:32:49 +00:00
}
]);
2016-06-29 01:43:18 +00:00
// Font Awesome, Kibana UI framework and others
2018-06-15 10:42:57 +00:00
import './utils/fontawesome/css/font-awesome.min.css';
2018-05-08 14:08:12 +00:00
// Dev tools
2018-09-10 08:32:49 +00:00
import './utils/codemirror';
2018-05-08 14:08:12 +00:00
// Material
2018-07-31 09:04:36 +00:00
import 'angular-material/angular-material.css';
import 'angular-aria/angular-aria';
import 'angular-animate/angular-animate';
import 'angular-material/angular-material';
// Cookies
2018-07-31 09:04:36 +00:00
import 'angular-cookies/angular-cookies';
import 'ui/autoload/all';
import 'ui/chrome';
2017-11-23 10:33:34 +00:00
2018-05-04 10:29:07 +00:00
// Wazuh
2018-09-10 08:32:49 +00:00
import './kibana-integrations';
import './services';
import './controllers';
import './factories';
import './directives';
2018-06-25 07:47:35 +00:00
// Added due to Kibana 6.3.0. Do not modify.
2018-09-10 08:32:49 +00:00
uiModules.get('kibana').provider('dashboardConfig', () => {
let hideWriteControls = false;
2018-06-25 07:47:35 +00:00
2018-09-10 08:32:49 +00:00
return {
/**
* Part of the exposed plugin API - do not remove without careful consideration.
* @type {boolean}
*/
turnHideWriteControlsOn() {
hideWriteControls = true;
},
$get() {
return {
getHideWriteControls() {
return hideWriteControls;
}
};
}
};
2018-07-02 07:28:08 +00:00
});