svishnev | 1eb66b7 | 2018-01-11 14:39:45 +0200 | [diff] [blame] | 1 | /* |
| 2 | * Copyright © 2016-2017 European Support Limited |
Michael Lando | efa037d | 2017-02-19 12:57:33 +0200 | [diff] [blame] | 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 |
svishnev | 1eb66b7 | 2018-01-11 14:39:45 +0200 | [diff] [blame] | 7 | * |
svishnev | 0d08f88 | 2018-01-21 13:45:31 +0200 | [diff] [blame] | 8 | * * http://www.apache.org/licenses/LICENSE-2.0 |
svishnev | 1eb66b7 | 2018-01-11 14:39:45 +0200 | [diff] [blame] | 9 | * |
Michael Lando | efa037d | 2017-02-19 12:57:33 +0200 | [diff] [blame] | 10 | * Unless required by applicable law or agreed to in writing, software |
| 11 | * distributed under the License is distributed on an "AS IS" BASIS, |
svishnev | 1eb66b7 | 2018-01-11 14:39:45 +0200 | [diff] [blame] | 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. |
Michael Lando | efa037d | 2017-02-19 12:57:33 +0200 | [diff] [blame] | 15 | */ |
| 16 | |
| 17 | import React from 'react'; |
svishnev | 0d08f88 | 2018-01-21 13:45:31 +0200 | [diff] [blame] | 18 | import { render } from 'react-dom'; |
Michael Lando | efa037d | 2017-02-19 12:57:33 +0200 | [diff] [blame] | 19 | import Sequencer from './ecomp/asdc/sequencer/Sequencer'; |
| 20 | import '../res/ecomp/asdc/sequencer/sequencer-development.scss'; |
| 21 | import '../res/thirdparty/react-select/react-select.min.css'; |
| 22 | |
| 23 | function renderApplication() { |
Einav Weiss Keidar | 7fdf733 | 2018-03-20 14:45:40 +0200 | [diff] [blame] | 24 | const shell = document.createElement('div'); |
| 25 | shell.setAttribute('style', 'height:100%;width:100%;margin:0;padding:0'); |
| 26 | document.body.appendChild(shell); |
| 27 | const options = { demo: true }; |
| 28 | render(<Sequencer options={options} />, shell); |
Michael Lando | efa037d | 2017-02-19 12:57:33 +0200 | [diff] [blame] | 29 | } |
| 30 | |
| 31 | if (window.addEventListener) { |
Einav Weiss Keidar | 7fdf733 | 2018-03-20 14:45:40 +0200 | [diff] [blame] | 32 | window.addEventListener('DOMContentLoaded', renderApplication); |
Michael Lando | efa037d | 2017-02-19 12:57:33 +0200 | [diff] [blame] | 33 | } else { |
Einav Weiss Keidar | 7fdf733 | 2018-03-20 14:45:40 +0200 | [diff] [blame] | 34 | window.attachEvent('onload', renderApplication); |
Michael Lando | efa037d | 2017-02-19 12:57:33 +0200 | [diff] [blame] | 35 | } |