@flozy/editor 1.2.4 → 1.2.6

Sign up to get free protection for your applications and to get access to all the features.
@@ -50,6 +50,7 @@ const CommonEditor = /*#__PURE__*/forwardRef((props, ref) => {
50
50
  const [loadedValue] = useState(value);
51
51
  const [isInteracted, setIsInteracted] = useState(false);
52
52
  const [deboundedValue] = useDebounce(value, 500);
53
+ const [fullScreen, setFullScreen] = useState(false);
53
54
  const editor = useMemo(() => {
54
55
  if (collaborativeEditor) return collaborativeEditor;
55
56
  return withCommon(createEditor());
@@ -122,6 +123,9 @@ const CommonEditor = /*#__PURE__*/forwardRef((props, ref) => {
122
123
  },
123
124
  insertFragments(fragments) {
124
125
  editor.insertNode(fragments);
126
+ },
127
+ toggleFullscreen() {
128
+ setFullScreen(!fullScreen);
125
129
  }
126
130
  }));
127
131
  const [htmlAction, setHtmlAction] = useState({
@@ -190,6 +194,7 @@ const CommonEditor = /*#__PURE__*/forwardRef((props, ref) => {
190
194
  const Overlay = collaborativeEditor && !isReadOnly ? RemoteCursorOverlay : React.Fragment;
191
195
  return /*#__PURE__*/_jsx(DialogWrapper, {
192
196
  ...props,
197
+ fullScreen: fullScreen,
193
198
  children: /*#__PURE__*/_jsx("div", {
194
199
  style: {
195
200
  display: "flex",
@@ -17,10 +17,13 @@ blockquote{
17
17
  color: #aaa;
18
18
  font-style: italic;
19
19
  }
20
- table, th, td {
20
+
21
+ .editor-wrapper table,
22
+ .editor-wrapperth,
23
+ .editor-wrapper td {
21
24
  border: 1px solid black;
22
25
  }
23
- table{
26
+ .editor-wrapper table{
24
27
  border-collapse: collapse;
25
28
  }
26
29
  button{
@@ -39,10 +42,10 @@ button{
39
42
  border: none !important
40
43
  }
41
44
 
42
- table{
45
+ .editor-wrapper table{
43
46
  /* width:100%; */
44
47
  }
45
- td{
48
+ .editor-wrapper td{
46
49
  height: 50px;
47
50
  padding:0 5px;
48
51
  }
@@ -66,17 +69,17 @@ td{
66
69
  width: 300px;
67
70
 
68
71
  }
69
- button{
72
+ .editor-wrapper button{
70
73
  cursor: pointer;
71
74
  }
72
- code {
75
+ .editor-wrapper code {
73
76
  font-family: source-code-pro, Menlo, Monaco, Consolas, 'Courier New',
74
77
  monospace;
75
78
  }
76
79
  [data-slate-node="element"] {
77
80
  margin: 10px 0;
78
81
  }
79
- html{
82
+ .editor-wrapper html{
80
83
  scroll-behavior: smooth;
81
84
  }
82
85
  .editor-wrapper *:focus-visible {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@flozy/editor",
3
- "version": "1.2.4",
3
+ "version": "1.2.6",
4
4
  "description": "An Editor for flozy app brain",
5
5
  "files": [
6
6
  "dist"