@lobehub/editor 4.26.0 → 4.26.2

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.
@@ -44,7 +44,7 @@ function tryToPositionRange(leadOffset, range, editorWindow) {
44
44
  }
45
45
  return true;
46
46
  }
47
- const PUNCTUATION = "\\.,\\+\\*\\?\\$\\@\\|#{}\\(\\)\\^\\-\\[\\]\\\\!%'\"~=<>_:;";
47
+ const PUNCTUATION = "\\.,\\+\\*\\?\\$\\@\\|#{}\\(\\)\\^\\[\\]\\\\!%'\"~=<>_:;";
48
48
  function getBasicTypeaheadTriggerMatch(trigger, { minLength = 0, maxLength = 75, punctuation = PUNCTUATION, allowWhitespace = false }) {
49
49
  return (text) => {
50
50
  const validCharsSuffix = allowWhitespace ? "" : "\\s";
@@ -1,55 +1,77 @@
1
1
  import { jsx, jsxs } from "react/jsx-runtime";
2
2
  import { createStaticStyles, cssVar, cx } from "antd-style";
3
3
  //#region src/react/SendButton/components/StopIcon.tsx
4
- const styles = createStaticStyles(({ css }) => ({ icon: css`
4
+ const styles = createStaticStyles(({ css }) => ({
5
+ icon: css`
6
+ position: relative;
7
+ display: inline-block;
5
8
  flex: none;
6
9
  line-height: 1;
7
- ` }));
10
+ `,
11
+ layer: css`
12
+ position: absolute;
13
+ inset: 0;
14
+
15
+ display: block;
16
+
17
+ width: 100%;
18
+ height: 100%;
19
+ `,
20
+ spinner: css`
21
+ transform-origin: 50% 50%;
22
+ animation: send-button-stop-spin 1s linear infinite;
23
+
24
+ @keyframes send-button-stop-spin {
25
+ to {
26
+ transform: rotate(360deg);
27
+ }
28
+ }
29
+ `
30
+ }));
8
31
  const StopIcon = ({ size = "1.5em", style }) => {
9
- return /* @__PURE__ */ jsx("svg", {
32
+ return /* @__PURE__ */ jsxs("span", {
10
33
  className: cx("anticon", styles.icon),
11
- color: "currentColor",
12
- height: size,
13
- style,
14
- viewBox: "0 0 1024 1024",
15
- width: size,
16
- xmlns: "http://www.w3.org/2000/svg",
17
- children: /* @__PURE__ */ jsxs("g", {
34
+ style: {
35
+ height: size,
36
+ width: size,
37
+ ...style
38
+ },
39
+ children: [/* @__PURE__ */ jsxs("svg", {
40
+ className: styles.layer,
18
41
  fill: "none",
19
- children: [
20
- /* @__PURE__ */ jsx("circle", {
21
- cx: "512",
22
- cy: "512",
23
- fill: "none",
24
- r: "426",
25
- stroke: cssVar.colorBorder,
26
- strokeWidth: "72"
27
- }),
28
- /* @__PURE__ */ jsx("rect", {
29
- fill: "currentColor",
30
- height: "252",
31
- rx: "24",
32
- ry: "24",
33
- width: "252",
34
- x: "386",
35
- y: "386"
36
- }),
37
- /* @__PURE__ */ jsx("path", {
38
- d: "M938.667 512C938.667 276.359 747.64 85.333 512 85.333",
39
- stroke: "currentColor",
40
- strokeLinecap: "round",
41
- strokeWidth: "73",
42
- children: /* @__PURE__ */ jsx("animateTransform", {
43
- attributeName: "transform",
44
- dur: "1s",
45
- from: "0 512 512",
46
- repeatCount: "indefinite",
47
- to: "360 512 512",
48
- type: "rotate"
49
- })
50
- })
51
- ]
52
- })
42
+ height: size,
43
+ viewBox: "0 0 1024 1024",
44
+ width: size,
45
+ xmlns: "http://www.w3.org/2000/svg",
46
+ children: [/* @__PURE__ */ jsx("circle", {
47
+ cx: "512",
48
+ cy: "512",
49
+ r: "426",
50
+ stroke: cssVar.colorBorder,
51
+ strokeWidth: "72"
52
+ }), /* @__PURE__ */ jsx("rect", {
53
+ fill: "currentColor",
54
+ height: "252",
55
+ rx: "24",
56
+ ry: "24",
57
+ width: "252",
58
+ x: "386",
59
+ y: "386"
60
+ })]
61
+ }), /* @__PURE__ */ jsx("svg", {
62
+ className: cx(styles.layer, styles.spinner),
63
+ fill: "none",
64
+ height: size,
65
+ viewBox: "0 0 1024 1024",
66
+ width: size,
67
+ xmlns: "http://www.w3.org/2000/svg",
68
+ children: /* @__PURE__ */ jsx("path", {
69
+ d: "M938.667 512C938.667 276.359 747.64 85.333 512 85.333",
70
+ stroke: "currentColor",
71
+ strokeLinecap: "round",
72
+ strokeWidth: "73"
73
+ })
74
+ })]
53
75
  });
54
76
  };
55
77
  //#endregion
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lobehub/editor",
3
- "version": "4.26.0",
3
+ "version": "4.26.2",
4
4
  "description": "A powerful and extensible rich text editor built on Meta's Lexical framework, providing a modern editing experience with React integration.",
5
5
  "keywords": [
6
6
  "lobehub",