"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); function createDivWithClassName(className, parent) { var ele = document.createElement('div'); if (parent) { parent.appendChild(ele); } if (className) { addClassName(ele, className); } return ele; } exports.createDivWithClassName = createDivWithClassName; function addClassName(ele, className) { if (!ele) { return; } ele.className = ((ele.className || '') + " " + className).trim(); } exports.addClassName = addClassName;