Repositorio del curso CCOM4030 el semestre B91 del proyecto Artesanías con el Instituto de Cultura

base-element.js 1.5KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. import _Object$getPrototypeOf from 'babel-runtime/core-js/object/get-prototype-of';
  2. import _classCallCheck from 'babel-runtime/helpers/classCallCheck';
  3. import _possibleConstructorReturn from 'babel-runtime/helpers/possibleConstructorReturn';
  4. import _inherits from 'babel-runtime/helpers/inherits';
  5. /*
  6. Copyright 2013-2015 ASIAL CORPORATION
  7. Licensed under the Apache License, Version 2.0 (the "License");
  8. you may not use this file except in compliance with the License.
  9. You may obtain a copy of the License at
  10. http://www.apache.org/licenses/LICENSE-2.0
  11. Unless required by applicable law or agreed to in writing, software
  12. distributed under the License is distributed on an "AS IS" BASIS,
  13. WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  14. See the License for the specific language governing permissions and
  15. limitations under the License.
  16. */
  17. function getElementClass() {
  18. if (typeof HTMLElement !== 'function') {
  19. // case of Safari
  20. var _BaseElement = function _BaseElement() {};
  21. _BaseElement.prototype = document.createElement('div');
  22. return _BaseElement;
  23. } else {
  24. return HTMLElement;
  25. }
  26. }
  27. var BaseElement = function (_getElementClass) {
  28. _inherits(BaseElement, _getElementClass);
  29. function BaseElement() {
  30. _classCallCheck(this, BaseElement);
  31. return _possibleConstructorReturn(this, (BaseElement.__proto__ || _Object$getPrototypeOf(BaseElement)).call(this));
  32. }
  33. return BaseElement;
  34. }(getElementClass());
  35. export default BaseElement;