@n8n/chat 1.5.0 → 1.5.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +6 -0
- package/dist/chat.bundle.es.js +24 -13
- package/dist/chat.bundle.umd.js +5 -5
- package/dist/chat.es.js +24 -13
- package/dist/chat.umd.js +2 -2
- package/dist/components/Button.vue.d.ts +2 -0
- package/dist/style.css +2 -2
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -310,12 +310,18 @@ The Chat window is entirely customizable using CSS variables.
|
|
|
310
310
|
--chat--button--color--primary--hover: var(--chat--color-light);
|
|
311
311
|
--chat--button--background--primary--hover: var(--chat--color-secondary-shade-50);
|
|
312
312
|
--chat--button--border--primary--hover: none;
|
|
313
|
+
--chat--button--color--primary--disabled: var(--chat--color-light);
|
|
314
|
+
--chat--button--background--primary--disabled: #81bbb1;
|
|
315
|
+
--chat--button--border--primary--disabled: none;
|
|
313
316
|
--chat--button--color--secondary: var(--chat--color-light);
|
|
314
317
|
--chat--button--background--secondary: hsl(0, 0%, 58%);
|
|
315
318
|
--chat--button--border--secondary: none;
|
|
316
319
|
--chat--button--color--secondary--hover: var(--chat--color-light);
|
|
317
320
|
--chat--button--background--secondary--hover: hsl(0, 0%, 51%);
|
|
318
321
|
--chat--button--border--secondary--hover: none;
|
|
322
|
+
--chat--button--color--secondary--disabled: var(--chat--color-light);
|
|
323
|
+
--chat--button--background--secondary--disabled: hsl(0, 0%, 78%);
|
|
324
|
+
--chat--button--border--secondary--disabled: none;
|
|
319
325
|
--chat--close--button--color-hover: var(--chat--color--primary);
|
|
320
326
|
|
|
321
327
|
/* Send and File Buttons */
|
package/dist/chat.bundle.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! Package version @n8n/chat@1.5.
|
|
1
|
+
/*! Package version @n8n/chat@1.5.1 */
|
|
2
2
|
var __create = Object.create, __defProp$1 = Object.defineProperty, __getOwnPropDesc = Object.getOwnPropertyDescriptor, __getOwnPropNames = Object.getOwnPropertyNames, __getProtoOf = Object.getPrototypeOf, __hasOwnProp$1 = Object.prototype.hasOwnProperty, __esmMin = (e, t) => () => (e && (t = e(e = 0)), t), __commonJSMin = (e, t) => () => (t || e((t = { exports: {} }).exports, t), t.exports), __export = (e, n) => {
|
|
3
3
|
let r = {};
|
|
4
4
|
for (var i in e) __defProp$1(r, i, {
|
|
@@ -3243,17 +3243,22 @@ function normalizeContainer(e) {
|
|
|
3243
3243
|
return isString(e) ? document.querySelector(e) : e;
|
|
3244
3244
|
}
|
|
3245
3245
|
var Button_default$1 = /* @__PURE__ */ defineComponent({
|
|
3246
|
+
inheritAttrs: !1,
|
|
3246
3247
|
__name: "Button",
|
|
3247
3248
|
props: {
|
|
3248
3249
|
type: { default: "primary" },
|
|
3249
|
-
element: { default: "button" }
|
|
3250
|
+
element: { default: "button" },
|
|
3251
|
+
disabled: {
|
|
3252
|
+
type: Boolean,
|
|
3253
|
+
default: !1
|
|
3254
|
+
}
|
|
3250
3255
|
},
|
|
3251
3256
|
setup(e) {
|
|
3252
|
-
let t = e, n = computed(() => `chat-button-${t.type}`);
|
|
3253
|
-
return (
|
|
3254
|
-
default: withCtx(() => [renderSlot(
|
|
3257
|
+
let t = e, n = computed(() => `chat-button-${t.type}${t.disabled ? "-disabled" : ""}`);
|
|
3258
|
+
return (r, i) => (openBlock(), createElementBlock("span", { class: normalizeClass({ "chat-button-wrapper-disabled": t.disabled }) }, [(openBlock(), createBlock(resolveDynamicComponent(e.element), mergeProps({ class: ["chat-button", n.value] }, r.$attrs), {
|
|
3259
|
+
default: withCtx(() => [renderSlot(r.$slots, "default")]),
|
|
3255
3260
|
_: 3
|
|
3256
|
-
},
|
|
3261
|
+
}, 16, ["class"]))], 2));
|
|
3257
3262
|
}
|
|
3258
3263
|
}), core_default = (/* @__PURE__ */ __toESM((/* @__PURE__ */ __commonJSMin(((e, t) => {
|
|
3259
3264
|
function n(e) {
|
|
@@ -11773,17 +11778,23 @@ var require_markdown_it_link_attributes = /* @__PURE__ */ __commonJSMin(((e, t)
|
|
|
11773
11778
|
buttons: {}
|
|
11774
11779
|
},
|
|
11775
11780
|
setup(e) {
|
|
11776
|
-
|
|
11777
|
-
|
|
11778
|
-
|
|
11779
|
-
|
|
11781
|
+
let t = ref(null), n = async (e, n) => {
|
|
11782
|
+
t.value === null && (await fetch(e)).ok && (t.value = n);
|
|
11783
|
+
};
|
|
11784
|
+
return (r, i) => (openBlock(), createElementBlock("div", null, [createVNode(MarkdownRenderer_default, { text: e.text }, null, 8, ["text"]), createBaseVNode("div", { class: normalizeClass(r.$style.buttons) }, [(openBlock(!0), createElementBlock(Fragment, null, renderList(e.buttons, (e, r) => (openBlock(), createElementBlock(Fragment, { key: e.text }, [t.value === null || r === t.value ? (openBlock(), createBlock(Button_default$1, {
|
|
11785
|
+
key: 0,
|
|
11786
|
+
element: "button",
|
|
11780
11787
|
type: e.type,
|
|
11781
|
-
|
|
11782
|
-
|
|
11788
|
+
disabled: r === t.value,
|
|
11789
|
+
onClick: (t) => n(e.link, r)
|
|
11783
11790
|
}, {
|
|
11784
11791
|
default: withCtx(() => [createTextVNode(toDisplayString(e.text), 1)]),
|
|
11785
11792
|
_: 2
|
|
11786
|
-
}, 1032, [
|
|
11793
|
+
}, 1032, [
|
|
11794
|
+
"type",
|
|
11795
|
+
"disabled",
|
|
11796
|
+
"onClick"
|
|
11797
|
+
])) : createCommentVNode("", !0)], 64))), 128))], 2)]));
|
|
11787
11798
|
}
|
|
11788
11799
|
}), MessageWithButtons_vue_vue_type_style_index_0_lang_module_default = { buttons: "_buttons_omuwb_1" }, __plugin_vue_export_helper_default = (e, t) => {
|
|
11789
11800
|
let n = e.__vccOpts || e;
|