"use strict";
var __importDefault = (this && this.__importDefault) || function (mod) {
    return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.createErrorNode = createErrorNode;
exports.createSlotTemplateNode = createSlotTemplateNode;
const pick_1 = __importDefault(require("lodash/pick"));
const node_1 = require("../utils/node");
const _ = { pick: pick_1.default };
function createErrorNode(element, error) {
    const errorElement = (0, node_1.parseHTML)(`<div style="color: red">${error.message}</div>`)[0];
    return Object.assign(element, _.pick(errorElement, ['name', 'attribs', 'children']));
}
function createSlotTemplateNode(slotName, content) {
    return (0, node_1.parseHTML)(`<template #${slotName}>${content}</template>`);
}
//# sourceMappingURL=elements.js.map