chore: revert "fix: word boundary regards white space as a word (#1157)" (#1160)

* chore: revert "fix: word boundary regards white space as a word (#1157)"

This reverts commit a1f1c6708a.

* chore: remove test

---------

Co-authored-by: Lucas.Xu <lucas.xu@appflowy.io>
This commit is contained in:
Richard Shiue 2025-11-12 12:03:15 +08:00 • committed by GitHub
commit 2dbc203b14
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -54,38 +54,6 @@ void main() async {
await editor.dispose();
});
testWidgets('context menu cut test ', (tester) async {
const text = 'Welcome to AppFlowy';
final editor = tester.editor..addParagraph(initialText: text);
await editor.startTesting();
expect(
find.text(text, findRichText: true),
findsOneWidget,
);
await editor.updateSelection(
Selection(
start: Position(path: [0], offset: 0),
end: Position(path: [0], offset: 18),
),
);
final copiedText =
editor.editorState.getTextInSelection(editor.selection).join('/n');
final position = tester.getCenter(find.text(text, findRichText: true));
rightClickAt(position);
await tester.pump();
final cutButton = find.text('Cut');
expect(cutButton, findsOneWidget);
await tester.tap(cutButton);
await tester.pumpAndSettle(const Duration(milliseconds: 500));
expect(
find.text('Welcome to AppFlowy', findRichText: true),
findsNothing,
);
final clipBoardData = await AppFlowyClipboard.getData();
expect(clipBoardData.text, copiedText);
await editor.dispose();
});
testWidgets('context menu copy and paste test', (tester) async {
const text = 'Welcome to AppFlowy';
final editor = tester.editor