UNPKG

n8n-editor-ui

Version:

Workflow Editor UI for n8n

186 lines (185 loc) 11.8 kB
; (function () { System.register(["./vue.runtime.esm-bundler-legacy--Sn1h8On.js", "./_plugin-vue_export-helper-legacy-DZMI5HPp.js"], function (_export, _context) { "use strict"; var computed, toDisplayString, createElementBlock, createCommentVNode, unref, createVNode, defineComponent, createBlock, openBlock, withModifiers, createBaseVNode, __plugin_vue_export_helper_default, __vite_style__, _hoisted_1$6, closeThick_default, _hoisted_1$5, fileImage_default, _hoisted_1$4, fileMusic_default, _hoisted_1$3, fileText_default, _hoisted_1$2, fileVideo_default, _hoisted_1$1, openInNew_default, _hoisted_1, ChatFile_vue_vue_type_script_setup_true_lang_default, ChatFile_default; function render$5(_ctx, _cache) { return openBlock(), createElementBlock("svg", _hoisted_1$6, _cache[0] || (_cache[0] = [createBaseVNode("path", { fill: "currentColor", d: "M20 6.91L17.09 4L12 9.09L6.91 4L4 6.91L9.09 12L4 17.09L6.91 20L12 14.91L17.09 20L20 17.09L14.91 12z" }, null, -1)])); } function render$4(_ctx, _cache) { return openBlock(), createElementBlock("svg", _hoisted_1$5, _cache[0] || (_cache[0] = [createBaseVNode("path", { fill: "currentColor", d: "M13 9h5.5L13 3.5zM6 2h8l6 6v12a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V4c0-1.11.89-2 2-2m0 18h12v-8l-4 4l-2-2zM8 9a2 2 0 0 0-2 2a2 2 0 0 0 2 2a2 2 0 0 0 2-2a2 2 0 0 0-2-2" }, null, -1)])); } function render$3(_ctx, _cache) { return openBlock(), createElementBlock("svg", _hoisted_1$4, _cache[0] || (_cache[0] = [createBaseVNode("path", { fill: "currentColor", d: "M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8zm-1 11h-2v5a2 2 0 0 1-2 2a2 2 0 0 1-2-2a2 2 0 0 1 2-2c.4 0 .7.1 1 .3V11h3zm0-4V3.5L18.5 9z" }, null, -1)])); } function render$2(_ctx, _cache) { return openBlock(), createElementBlock("svg", _hoisted_1$3, _cache[0] || (_cache[0] = [createBaseVNode("path", { fill: "currentColor", d: "M13 9h5.5L13 3.5zM6 2h8l6 6v12a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V4c0-1.11.89-2 2-2m9 16v-2H6v2zm3-4v-2H6v2z" }, null, -1)])); } function render$1(_ctx, _cache) { return openBlock(), createElementBlock("svg", _hoisted_1$2, _cache[0] || (_cache[0] = [createBaseVNode("path", { fill: "currentColor", d: "M13 9h5.5L13 3.5zM6 2h8l6 6v12a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V4c0-1.11.89-2 2-2m11 17v-6l-3 2.2V13H7v6h7v-2.2z" }, null, -1)])); } function render(_ctx, _cache) { return openBlock(), createElementBlock("svg", _hoisted_1$1, _cache[0] || (_cache[0] = [createBaseVNode("path", { fill: "currentColor", d: "M14 3v2h3.59l-9.83 9.83l1.41 1.41L19 6.41V10h2V3m-2 16H5V5h7V3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7h-2z" }, null, -1)])); } return { setters: [function (_vueRuntimeEsmBundlerLegacy003Js) { computed = _vueRuntimeEsmBundlerLegacy003Js.C; toDisplayString = _vueRuntimeEsmBundlerLegacy003Js.Cn; createElementBlock = _vueRuntimeEsmBundlerLegacy003Js.D; createCommentVNode = _vueRuntimeEsmBundlerLegacy003Js.E; unref = _vueRuntimeEsmBundlerLegacy003Js.Gt; createVNode = _vueRuntimeEsmBundlerLegacy003Js.M; defineComponent = _vueRuntimeEsmBundlerLegacy003Js.P; createBlock = _vueRuntimeEsmBundlerLegacy003Js.T; openBlock = _vueRuntimeEsmBundlerLegacy003Js.et; withModifiers = _vueRuntimeEsmBundlerLegacy003Js.h; createBaseVNode = _vueRuntimeEsmBundlerLegacy003Js.w; }, function (_pluginVue_exportHelperLegacy00fJs) { __plugin_vue_export_helper_default = _pluginVue_exportHelperLegacy00fJs.t; }], execute: function () { __vite_style__ = document.createElement('style'); __vite_style__.textContent = "/* BEM support Func\n -------------------------- */\n/* Transition\n-------------------------- */\n/* Color\n-------------------------- */\n/* Link\n-------------------------- */\n/* Border\n-------------------------- */\n/* Outline\n-------------------------- */\n/* Box shadow\n-------------------------- */\n/* Fill\n-------------------------- */\n/* Typography\n-------------------------- */\n/* z-index\n-------------------------- */\n/* Disable base\n-------------------------- */\n/* Icon\n-------------------------- */\n/* Checkbox\n-------------------------- */\n/* Radio\n-------------------------- */\n/* Select\n-------------------------- */\n/* Alert\n-------------------------- */\n/* MessageBox\n-------------------------- */\n/* Message\n-------------------------- */\n/* Notification\n-------------------------- */\n/* Input\n-------------------------- */\n/* Cascader\n-------------------------- */\n/* Group\n-------------------------- */\n/* Tab\n-------------------------- */\n/* Button\n-------------------------- */\n/* cascader\n-------------------------- */\n/* Switch\n-------------------------- */\n/* Dialog\n-------------------------- */\n/* Table\n-------------------------- */\n/* Pagination\n-------------------------- */\n/* Popup\n-------------------------- */\n/* Popover\n-------------------------- */\n/* Tooltip\n-------------------------- */\n/* Tag\n-------------------------- */\n/* Tree\n-------------------------- */\n/* Dropdown\n-------------------------- */\n/* Badge\n-------------------------- */\n/* Card\n--------------------------*/\n/* Slider\n--------------------------*/\n/* Steps\n--------------------------*/\n/* Menu\n--------------------------*/\n/* Rate\n--------------------------*/\n/* DatePicker\n--------------------------*/\n/* Loading\n--------------------------*/\n/* Scrollbar\n--------------------------*/\n/* Carousel\n--------------------------*/\n/* Collapse\n--------------------------*/\n/* Transfer\n--------------------------*/\n/* Header\n --------------------------*/\n/* Footer\n--------------------------*/\n/* Main\n--------------------------*/\n/* Timeline\n--------------------------*/\n/* Backtop\n--------------------------*/\n/* Link\n--------------------------*/\n/* Calendar\n--------------------------*/\n/* Form\n-------------------------- */\n/* Avatar\n--------------------------*/\n/* Break-point\n--------------------------*/\n/* Break-points\n -------------------------- */\n/* Scrollbar\n -------------------------- */\n/* Placeholder\n -------------------------- */\n/* BEM\n -------------------------- */\n.chat-file[data-v-4d3cc671] {\n display: flex;\n align-items: center;\n flex-wrap: nowrap;\n width: -moz-fit-content;\n width: fit-content;\n max-width: 15rem;\n padding: 0.5rem;\n border-radius: 0.25rem;\n gap: 0.25rem;\n font-size: 0.75rem;\n background: white;\n color: var(--chat--color-dark);\n border: 1px solid var(--chat--color-dark);\n}\n.chat-file[data-v-4d3cc671]:has(.chat-file-preview) {\n cursor: pointer;\n}\n.chat-icon[data-v-4d3cc671] {\n flex-shrink: 0;\n}\n.chat-file-name-tooltip[data-v-4d3cc671] {\n overflow: hidden;\n}\n.chat-file-name[data-v-4d3cc671] {\n overflow: hidden;\n max-width: 100%;\n text-overflow: ellipsis;\n white-space: nowrap;\n margin: 0;\n}\n.chat-file-delete[data-v-4d3cc671],\n.chat-file-preview[data-v-4d3cc671] {\n background: none;\n border: none;\n display: block;\n cursor: pointer;\n flex-shrink: 0;\n}\n.chat-file-delete[data-v-4d3cc671] {\n position: relative;\n /* Increase hit area for better clickability */\n}\n.chat-file-delete[data-v-4d3cc671]:hover {\n color: red;\n}\n.chat-file-delete[data-v-4d3cc671]:before {\n content: \"\";\n position: absolute;\n top: -10px;\n right: -10px;\n bottom: -10px;\n left: -10px;\n}/*$vite$:1*/"; document.head.appendChild(__vite_style__); //#region ~icons/mdi/closeThick _hoisted_1$6 = { viewBox: "0 0 24 24", width: "1.2em", height: "1.2em" }; closeThick_default = { name: "mdi-closeThick", render: render$5 }; //#endregion //#region ~icons/mdi/fileImage _hoisted_1$5 = { viewBox: "0 0 24 24", width: "1.2em", height: "1.2em" }; fileImage_default = { name: "mdi-fileImage", render: render$4 }; //#endregion //#region ~icons/mdi/fileMusic _hoisted_1$4 = { viewBox: "0 0 24 24", width: "1.2em", height: "1.2em" }; fileMusic_default = { name: "mdi-fileMusic", render: render$3 }; //#endregion //#region ~icons/mdi/fileText _hoisted_1$3 = { viewBox: "0 0 24 24", width: "1.2em", height: "1.2em" }; fileText_default = { name: "mdi-fileText", render: render$2 }; //#endregion //#region ~icons/mdi/fileVideo _hoisted_1$2 = { viewBox: "0 0 24 24", width: "1.2em", height: "1.2em" }; fileVideo_default = { name: "mdi-fileVideo", render: render$1 }; //#endregion //#region ~icons/mdi/openInNew _hoisted_1$1 = { viewBox: "0 0 24 24", width: "1.2em", height: "1.2em" }; openInNew_default = { name: "mdi-openInNew", render }; //#endregion //#region ../@n8n/chat/src/components/ChatFile.vue?vue&type=script&setup=true&lang.ts _hoisted_1 = { class: "chat-file-name" }; ChatFile_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */defineComponent({ __name: "ChatFile", props: { file: {}, isRemovable: { type: Boolean }, isPreviewable: { type: Boolean }, href: {} }, emits: ["remove"], setup(__props, { emit: __emit }) { const props = __props; const emit = __emit; const iconMapper = { document: fileText_default, audio: fileMusic_default, image: fileImage_default, video: fileVideo_default }; const TypeIcon = computed(() => { return iconMapper[props.file?.type.split("/")[0]] || fileText_default; }); function onClick() { if (props.href) { window.open(props.href, "_blank", "noopener noreferrer"); return; } if (props.isPreviewable) window.open(URL.createObjectURL(props.file)); } function onDelete() { emit("remove", props.file); } return (_ctx, _cache) => { return openBlock(), createElementBlock("div", { class: "chat-file", onClick }, [createVNode(unref(TypeIcon), { class: "chat-icon" }), createBaseVNode("p", _hoisted_1, toDisplayString(_ctx.file.name), 1), _ctx.isRemovable ? (openBlock(), createElementBlock("span", { key: 0, class: "chat-file-delete", onClick: withModifiers(onDelete, ["stop"]) }, [createVNode(unref(closeThick_default))])) : _ctx.isPreviewable || _ctx.href ? (openBlock(), createBlock(unref(openInNew_default), { key: 1, class: "chat-file-preview" })) : createCommentVNode("", true)]); }; } }); //#endregion //#region ../@n8n/chat/src/components/ChatFile.vue _export("t", ChatFile_default = /* @__PURE__ */__plugin_vue_export_helper_default(ChatFile_vue_vue_type_script_setup_true_lang_default, [["__scopeId", "data-v-4d3cc671"]])); //#endregion } }; }); })();