react 16 upgrade
[sdc.git] / openecomp-ui / src / sdc-app / sdc.app.jsx
1 /*
2  * Copyright © 2016-2018 European Support Limited
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *      http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 import '../../resources/scss/bootstrap.scss';
17 import 'react-select/dist/react-select.min.css';
18 import 'dox-sequence-diagram-ui/src/main/webapp/res/sdc-sequencer.scss';
19 import '../../resources/scss/style.scss';
20
21 import React from 'react';
22 import ReactDOM from 'react-dom';
23
24 import Application from './Application.jsx';
25 import Modules from './ModulesOptions.jsx';
26
27 //chrome 48 remove svg method which is used in jointjs core -> https://github.com/cpettitt/dagre-d3/issues/202 --> http://jointjs.com/blog/get-transform-to-element-polyfill.html
28 SVGElement.prototype.getTransformToElement =
29     SVGElement.prototype.getTransformToElement ||
30     function(toElement) {
31         return toElement
32             .getScreenCTM()
33             .inverse()
34             .multiply(this.getScreenCTM());
35     };
36
37 ReactDOM.render(
38     <Application>
39         <Modules />
40     </Application>,
41     document.getElementById('sdc-app')
42 );