"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
const Common_1 = require("../Common");
const fsExtra = require("fs-extra");
const VueParse_1 = require("../../generator/VueParse");
const path = require("path");
const config_1 = require("../../../config");
class UploadWall extends Common_1.default {
    constructor(params = {}) {
        super();
        this.name = 'UploadWall';
        this.init();
    }
    init() {
        const fileStr = fsExtra.readFileSync(path.join(config_1.default.templatePath, 'Custom/PhotoWall', 'comp.vue'), 'utf8');
        this.vueParse = new VueParse_1.default(this.uuid, fileStr);
    }
    fragment() {
        return `
      <div>
        <el-upload
          action="https://jsonplaceholder.typicode.com/posts/"
          list-type="picture-card"
          :on-preview="handlePictureCardPreview"
          :on-remove="handleRemove">
          <i class="el-icon-plus"></i>
        </el-upload>
        <el-dialog :visible.sync="dialogVisible">
          <img width="100%" :src="dialogImageUrl" alt="" />
        </el-dialog>
      </div>
    `;
    }
}
exports.default = UploadWall;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9zcmMvbGliL2FkYXB0ZXItdnVlL21vZHVsZXMvY3VzdG9tL1VwbG9hZFdhbGwvaW5kZXgudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7QUFBQSxzQ0FBK0I7QUFDL0Isb0NBQW9DO0FBQ3BDLHVEQUFnRDtBQUNoRCw2QkFBNkI7QUFDN0IsNENBQXFDO0FBRXJDLE1BQXFCLFVBQVcsU0FBUSxnQkFBTTtJQU81QyxZQUFhLFNBQWMsRUFBRTtRQUMzQixLQUFLLEVBQUUsQ0FBQztRQVBWLFNBQUksR0FBVyxZQUFZLENBQUM7UUFRMUIsSUFBSSxDQUFDLElBQUksRUFBRSxDQUFDO0lBQ2QsQ0FBQztJQUVPLElBQUk7UUFDVixNQUFNLE9BQU8sR0FBRyxPQUFPLENBQUMsWUFBWSxDQUFDLElBQUksQ0FBQyxJQUFJLENBQUMsZ0JBQU0sQ0FBQyxZQUFZLEVBQUUsa0JBQWtCLEVBQUUsVUFBVSxDQUFDLEVBQUUsTUFBTSxDQUFDLENBQUM7UUFDN0csSUFBSSxDQUFDLFFBQVEsR0FBRyxJQUFJLGtCQUFRLENBQUMsSUFBSSxDQUFDLElBQUksRUFBRSxPQUFPLENBQUMsQ0FBQztJQUNuRCxDQUFDO0lBRU0sUUFBUTtRQUNiLE9BQU87Ozs7Ozs7Ozs7Ozs7S0FhTixDQUFDO0lBQ0osQ0FBQztDQUNGO0FBakNELDZCQWlDQyJ9