md-editor-v3 6.0.0 → 6.0.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.
@@ -1,8 +1,8 @@
1
1
  import { defineComponent as s, createVNode as l, Fragment as r, isVNode as c } from "vue";
2
- import { M as g } from "./chunks/index2.mjs";
2
+ import { M as y } from "./chunks/index2.mjs";
3
3
  import { p as a } from "./chunks/config.mjs";
4
4
  import { g as d } from "./chunks/vue-tsx.mjs";
5
- function y(e) {
5
+ function g(e) {
6
6
  return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !c(e);
7
7
  }
8
8
  const m = {
@@ -122,8 +122,9 @@ const m = {
122
122
  disabled: e.disabled,
123
123
  onClick: () => {
124
124
  e.onClick?.(), t.emit("onClick");
125
- }
126
- }, [u]), l(g, {
125
+ },
126
+ type: "button"
127
+ }, [u]), l(y, {
127
128
  style: e.style,
128
129
  class: e.class,
129
130
  width: e.width,
@@ -139,7 +140,7 @@ const m = {
139
140
  onAdjust: (o) => {
140
141
  e.onAdjust?.(o), t.emit("onAdjust", o);
141
142
  }
142
- }, y(n) ? n : {
143
+ }, g(n) ? n : {
143
144
  default: () => [n]
144
145
  })]);
145
146
  };
@@ -72,7 +72,8 @@ const f = {
72
72
  disabled: e.disabled,
73
73
  onClick: (i) => {
74
74
  e.onClick?.(i), t.emit("onClick", i);
75
- }
75
+ },
76
+ type: "button"
76
77
  }, [a || o]);
77
78
  };
78
79
  }
@@ -1,4 +1,4 @@
1
- import { defineComponent as H, reactive as D, ref as w, watch as $, onMounted as B, onBeforeUnmount as N, cloneVNode as W, createVNode as c, inject as O } from "vue";
1
+ import { defineComponent as H, reactive as D, ref as w, watch as $, onMounted as B, onBeforeUnmount as N, cloneVNode as W, createVNode as y, inject as O } from "vue";
2
2
  import { p as i } from "./config.mjs";
3
3
  import { g as u } from "./vue-tsx.mjs";
4
4
  const j = {
@@ -40,11 +40,11 @@ const j = {
40
40
  const n = r.value, o = l.value;
41
41
  if (!n || !o)
42
42
  return;
43
- const g = n.getBoundingClientRect(), y = n.offsetTop, L = n.offsetLeft, E = g.height, T = g.width, S = n.getRootNode(), m = S.querySelector(e.relative)?.scrollLeft || 0, C = S.querySelector(e.relative)?.clientWidth || 0;
43
+ const g = n.getBoundingClientRect(), c = n.offsetTop, L = n.offsetLeft, E = g.height, T = g.width, S = n.getRootNode(), m = S.querySelector(e.relative)?.scrollLeft || 0, C = S.querySelector(e.relative)?.clientWidth || 0;
44
44
  let f = L - o.offsetWidth / 2 + T / 2 - m;
45
45
  f + o.offsetWidth > m + C && (f = m + C - o.offsetWidth), f < 0 && (f = 0), t.overlayStyle = {
46
46
  ...t.overlayStyle,
47
- top: y + E + "px",
47
+ top: c + E + "px",
48
48
  left: f + "px"
49
49
  }, e.onChange(!0);
50
50
  }, b = () => {
@@ -74,14 +74,14 @@ const j = {
74
74
  }, "overlay"), g = W(n instanceof Array ? n[0] : n, {
75
75
  ref: r,
76
76
  key: "cloned-dropdown-trigger"
77
- }), y = c("div", {
77
+ }), c = y("div", {
78
78
  class: [`${i}-dropdown`, t.overlayClass],
79
79
  style: t.overlayStyle,
80
80
  ref: l
81
- }, [c("div", {
81
+ }, [y("div", {
82
82
  class: `${i}-dropdown-overlay`
83
83
  }, [o instanceof Array ? o[0] : o])]);
84
- return [g, y];
84
+ return [g, c];
85
85
  };
86
86
  }
87
87
  }), R = {
@@ -162,7 +162,7 @@ const j = {
162
162
  props: e,
163
163
  ctx: a
164
164
  });
165
- return c(I, {
165
+ return y(I, {
166
166
  relative: `#${d}-toolbar-wrapper`,
167
167
  visible: e.visible,
168
168
  onChange: (s) => {
@@ -171,10 +171,11 @@ const j = {
171
171
  overlay: r,
172
172
  disabled: e.disabled
173
173
  }, {
174
- default: () => [c("button", {
174
+ default: () => [y("button", {
175
175
  class: [`${i}-toolbar-item`, e.disabled && `${i}-disabled`],
176
176
  title: e.title || "",
177
- disabled: e.disabled
177
+ disabled: e.disabled,
178
+ type: "button"
178
179
  }, [l || t])]
179
180
  });
180
181
  };