@difizen/libro-core 0.1.15 → 0.1.17

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.
@@ -135,28 +135,31 @@ var CellOutput = /*#__PURE__*/forwardRef(function CellOutput(props, ref) {
135
135
  useLayoutEffect(function () {
136
136
  isExecutingRef.current = !!executing;
137
137
  }, [executing]);
138
- useLayoutEffect(function () {
139
- if (!outputRef || !isExecutingRef || !(outputRef !== null && outputRef !== void 0 && outputRef.current)) {
140
- return function () {
141
- //
142
- };
143
- }
144
- var el = outputRef === null || outputRef === void 0 ? void 0 : outputRef.current;
145
- var resizeObserver = new ResizeObserver(function (entries) {
146
- entries.forEach(function () {
147
- var _outputRef$current;
148
- var outputAreaHeight = (outputRef === null || outputRef === void 0 || (_outputRef$current = outputRef.current) === null || _outputRef$current === void 0 ? void 0 : _outputRef$current.clientHeight) || 0;
149
- if (isExecutingRef.current && outputAreaHeight > 495) {
150
- command.executeCommand(NotebookCommands['EnableOutputScrolling'].id);
151
- }
152
- });
153
- });
154
- resizeObserver.observe(el);
155
- return function () {
156
- resizeObserver.unobserve(el);
157
- resizeObserver.disconnect();
158
- };
159
- }, [outputRef.current, cell, isExecutingRef]);
138
+
139
+ // useLayoutEffect(() => {
140
+ // if (!outputRef || !isExecutingRef || !outputRef?.current) {
141
+ // return () => {
142
+ // //
143
+ // };
144
+ // }
145
+ // const el = outputRef?.current;
146
+
147
+ // const resizeObserver = new ResizeObserver((entries) => {
148
+ // entries.forEach(() => {
149
+ // const outputAreaHeight = outputRef?.current?.clientHeight || 0;
150
+ // if (isExecutingRef.current && outputAreaHeight > 495) {
151
+ // command.executeCommand(NotebookCommands['EnableOutputScrolling'].id);
152
+ // }
153
+ // });
154
+ // });
155
+
156
+ // resizeObserver.observe(el as HTMLElement);
157
+ // return () => {
158
+ // resizeObserver.unobserve(el as HTMLElement);
159
+ // resizeObserver.disconnect();
160
+ // };
161
+ // }, [outputRef.current, cell, isExecutingRef]);
162
+
160
163
  if (!ExecutableCellView.is(cell)) {
161
164
  return null;
162
165
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@difizen/libro-core",
3
- "version": "0.1.15",
3
+ "version": "0.1.17",
4
4
  "description": "",
5
5
  "keywords": [
6
6
  "libro",
@@ -34,10 +34,10 @@
34
34
  ],
35
35
  "dependencies": {
36
36
  "@ant-design/icons": "^5.1.0",
37
- "@difizen/libro-code-editor": "^0.1.15",
38
- "@difizen/libro-common": "^0.1.15",
39
- "@difizen/libro-shared-model": "^0.1.15",
40
- "@difizen/libro-virtualized": "^0.1.15",
37
+ "@difizen/libro-code-editor": "^0.1.17",
38
+ "@difizen/libro-common": "^0.1.17",
39
+ "@difizen/libro-shared-model": "^0.1.17",
40
+ "@difizen/libro-virtualized": "^0.1.17",
41
41
  "@difizen/mana-app": "latest",
42
42
  "@difizen/mana-l10n": "latest",
43
43
  "@difizen/mana-react": "latest",
@@ -201,29 +201,29 @@ const CellOutput: React.FC<{ cell: CellView }> = forwardRef(function CellOutput(
201
201
  isExecutingRef.current = !!executing;
202
202
  }, [executing]);
203
203
 
204
- useLayoutEffect(() => {
205
- if (!outputRef || !isExecutingRef || !outputRef?.current) {
206
- return () => {
207
- //
208
- };
209
- }
210
- const el = outputRef?.current;
211
-
212
- const resizeObserver = new ResizeObserver((entries) => {
213
- entries.forEach(() => {
214
- const outputAreaHeight = outputRef?.current?.clientHeight || 0;
215
- if (isExecutingRef.current && outputAreaHeight > 495) {
216
- command.executeCommand(NotebookCommands['EnableOutputScrolling'].id);
217
- }
218
- });
219
- });
220
-
221
- resizeObserver.observe(el as HTMLElement);
222
- return () => {
223
- resizeObserver.unobserve(el as HTMLElement);
224
- resizeObserver.disconnect();
225
- };
226
- }, [outputRef.current, cell, isExecutingRef]);
204
+ // useLayoutEffect(() => {
205
+ // if (!outputRef || !isExecutingRef || !outputRef?.current) {
206
+ // return () => {
207
+ // //
208
+ // };
209
+ // }
210
+ // const el = outputRef?.current;
211
+
212
+ // const resizeObserver = new ResizeObserver((entries) => {
213
+ // entries.forEach(() => {
214
+ // const outputAreaHeight = outputRef?.current?.clientHeight || 0;
215
+ // if (isExecutingRef.current && outputAreaHeight > 495) {
216
+ // command.executeCommand(NotebookCommands['EnableOutputScrolling'].id);
217
+ // }
218
+ // });
219
+ // });
220
+
221
+ // resizeObserver.observe(el as HTMLElement);
222
+ // return () => {
223
+ // resizeObserver.unobserve(el as HTMLElement);
224
+ // resizeObserver.disconnect();
225
+ // };
226
+ // }, [outputRef.current, cell, isExecutingRef]);
227
227
 
228
228
  if (!ExecutableCellView.is(cell)) {
229
229
  return null;