Skip to content

Commit f7dfddb

Browse files
committed
INT-3337: Bump agar and eslint-plugin to latest
1 parent c5cfca3 commit f7dfddb

File tree

4 files changed

+182
-122
lines changed

4 files changed

+182
-122
lines changed

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@
4343
"@babel/preset-env": "^7.26.9",
4444
"@babel/preset-react": "^7.26.3",
4545
"@babel/preset-typescript": "^7.26.0",
46-
"@ephox/agar": "^8.0.0-alpha.0",
46+
"@ephox/agar": "^8.0.1",
4747
"@ephox/bedrock-client": "^14.1.1",
4848
"@ephox/bedrock-server": "^14.1.4",
4949
"@ephox/katamari": "^9.1.5",
@@ -57,7 +57,7 @@
5757
"@storybook/react": "^8.2.4",
5858
"@storybook/react-vite": "^8.2.4",
5959
"@tinymce/beehive-flow": "^0.19.0",
60-
"@tinymce/eslint-plugin": "^2.3.1",
60+
"@tinymce/eslint-plugin": "^2.4.0",
6161
"@tinymce/miniature": "^6.0.0",
6262
"@types/node": "^22.13.10",
6363
"@types/prop-types": "^15.7.12",

src/main/ts/components/Editor.tsx

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,7 @@ export class Editor extends React.Component<IAllProps> {
190190
// getBookmark throws exceptions when the editor has not been focused
191191
// possibly only in inline mode but I'm not taking chances
192192
cursor = localEditor.selection.getBookmark(3);
193-
} catch (e) { /* ignore */ }
193+
} catch (_e) { /* ignore */ }
194194
}
195195
const valueCursor = this.valueCursor;
196196
localEditor.setContent(this.props.value as string);
@@ -201,7 +201,7 @@ export class Editor extends React.Component<IAllProps> {
201201
localEditor.selection.moveToBookmark(bookmark);
202202
this.valueCursor = bookmark;
203203
break;
204-
} catch (e) { /* ignore */ }
204+
} catch (_e) { /* ignore */ }
205205
}
206206
}
207207
}
@@ -361,7 +361,7 @@ export class Editor extends React.Component<IAllProps> {
361361
if (this.valueCursor && (!this.inline || editor.hasFocus())) {
362362
try {
363363
editor.selection.moveToBookmark(this.valueCursor);
364-
} catch (e) { /* ignore */ }
364+
} catch (_e) { /* ignore */ }
365365
}
366366
});
367367
}
@@ -375,7 +375,7 @@ export class Editor extends React.Component<IAllProps> {
375375
// getBookmark throws exceptions when the editor has not been focused
376376
// possibly only in inline mode but I'm not taking chances
377377
this.valueCursor = this.editor.selection.getBookmark(3);
378-
} catch (e) { /* ignore */ }
378+
} catch (_e) { /* ignore */ }
379379
}
380380
}
381381
};
@@ -498,6 +498,7 @@ export class Editor extends React.Component<IAllProps> {
498498
target.value = this.getInitialValue();
499499
}
500500

501+
// eslint-disable-next-line @typescript-eslint/no-floating-promises
501502
tinymce.init(finalInit);
502503
};
503504
}

src/test/ts/browser/EditorInitTest.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -65,14 +65,14 @@ describe('EditorInitTest', () => {
6565
it('Value prop should propagate changes to editor', async () => {
6666
using ctx = await render({ value: '<p>Initial Value</p>' });
6767
TinyAssertions.assertContent(ctx.editor, '<p>Initial Value</p>');
68-
ctx.reRender({ ...defaultProps, value: '<p>New Value</p>' });
68+
await ctx.reRender({ ...defaultProps, value: '<p>New Value</p>' });
6969
TinyAssertions.assertContent(ctx.editor, '<p>New Value</p>');
7070
});
7171

7272
it('Disabled prop should disable editor', async () => {
7373
using ctx = await render();
7474
Assertions.assertEq('Should be design mode', true, '4' === version ? !ctx.editor.readonly : ctx.editor.mode.get() === 'design');
75-
ctx.reRender({ ...defaultProps, disabled: true });
75+
await ctx.reRender({ ...defaultProps, disabled: true });
7676
Assertions.assertEq('Should be readonly mode', true, '4' === version ? ctx.editor.readonly : ctx.editor.mode.get() === 'readonly');
7777
});
7878

0 commit comments

Comments
 (0)