/* menu - video */ import $ from '../../util/dom-core.js' import { getRandom } from '../../util/util.js' import Panel from '../panel.js' // 构造函数 function Video(editor) { this.editor = editor this.$elem = $('
') this.type = 'panel' // 当前是否 active 状态 this._active = false } // 原型 Video.prototype = { constructor: Video, onClick: function () { this._createPanel() }, _createPanel: function () { // 创建 id const textValId = getRandom('text-val') const btnId = getRandom('btn') // 创建 panel const panel = new Panel(this, { width: 350, // 一个 panel 多个 tab tabs: [ { // 标题 title: '插入视频', // 模板 tpl: `