Commit graph appflowy-editor/test/new
Author SHA1 Message Date
Lucas.Xu
c7d99913aa
feat: support Flutter stable channel (#581)
* feat: adjust toggle list block

* chore: upgrade Flutter to master channel

* chore: upgrade pbxproj

* fix: toolbar copy button not closing on mobile editor

* fix: formatting issues and add missing commas

* chore: add stable branch to GitHub Actions workflow

* chore: add missing trailing commas

* chore: adjust indentation padding in block component
configuration and unit tests
2023-11-08 13:46:33 +08:00
Mathias Mogensen
5b9b6d80f5
feat: power checkbox shortcut (#553) 2023-10-30 11:20:15 +08:00
Sameer Godse
51f8f791c8
feat: convert = and > to ⇒ (#523) 2023-10-24 14:07:29 +08:00
Lucas.Xu
194fe2fec9
fix: unable to clear the style by toggling twice (#532) 2023-10-11 20:14:34 +08:00
Lucas.Xu
b17bddceb8
feat: enable toggling and canceling of the formatting with shortcuts (#528) 2023-10-11 13:10:37 +08:00
Sun Jiao
8bfd779bfe
feat: add regex and case sensitive to FindReplaceMenu (#480) 2023-10-10 15:53:38 +08:00
Lucas.Xu
384532434c
feat: optimize the find and replace logic (#510) 2023-10-01 16:51:42 +08:00
Lakhan Baheti
2b58d4f9ca
feat: support RTL in toolbar (#496) 2023-09-27 15:34:33 +08:00
Lucas.Xu
c5ea228b4e
fix: undo failed in a nested list in a special case (#503) 2023-09-26 14:10:43 +08:00
Mohammad Zolfaghari
189a41f67d
fix: respect default and last direction on new line and indent (#482) 2023-09-20 14:07:38 +08:00
Sun Jiao
ce8a77014e
fix: resolve RangeErrorwhen last row deleted. (#470) 2023-09-17 16:10:14 +08:00
Lucas.Xu
b602141d32 fix: missing a required trailing comma 2023-09-13 15:26:29 +08:00
Lucas.Xu
19f999f422
feat: optimize the performance (#442) 2023-09-11 15:03:14 +08:00
Mayur Mahajan
ad55171c5b
refactor: migrate tests (#438)
* refactor: separate remove line command

* test: delete sentence

* chore: export delete left line command

* refactor: move from internal_key_handler to new

* refactor: move from command to new
2023-09-11 14:24:50 +08:00
Antony Kithinzi
2924c167e2
feat: bulk open links shortcut (#419)
* feat: creating open links shortcut command

* test: open links command

* refactor: applying suggestion

* refactor: fetching all unique links by a chain function
2023-09-11 14:23:45 +08:00
Mohammad Zolfaghari
b429ae6b96
fix: better column resize performance (#434)
* fix: table padding when it gets scrolled

The handler was getting out of region when table width was wider
than editor size.

* fix: modify scroll view padding

* fix: better column resize performance
2023-09-01 10:48:13 +08:00
Lucas.Xu
f205f8040a
fix: table block bugs (#431)
* fix: resizing the table won't send transaction

* fix: lost selection after inserting table block

* fix: test

* refactor: don't pass editorState to TableNode

pass only transaction to methods directly.

* refactor: reduce extra transactions

* fix: mitigate Appflowy transaction adapter problem

With current transaction adapter in Appflowy which creates `BlockActionPB`
for `documentService` (backend). Its not possible to have multiple
`InsertOperation`s separately as a single transaction (multiple
`transaction.insertNode()`). The `BlockActionPB` creator (`toBlockAction`)
can't figure out the `prevId` (previous node of inserting node id), The
first insert operations shifts all next nodes path.
Because of this situation we decided to apply the insert operations one by
one.

* fix: table actions keep selection

* fix: on add col|row respect row|col bg color

* refactor: moving cell related keys to TableCellBlockKeys

* style: dart format

---------

Co-authored-by: Mohammad Zolfaghari <zidom72@gmail.com>
2023-08-31 10:35:23 +08:00
Mayur Mahajan
7a03439c82
feat: toggle highlight using ctrl/cmd + shift + h (#333)
* feat: add highlight command shortcut

* feat: toggle highlight in markdown commands

* refactor: customizable highlight color

* feat: taking color from editor page
2023-08-29 15:25:08 +08:00
Mohammad Zolfaghari
dd52ce6718
feat: table plugin (#62)
* feat: table plugin requisites

* feat: moved table plugin to appflowy-editor

* fix: flutter analyze

* fix: dont use nested maps in node attributes

rust backend (flowy-document) doesn't support it.

* feat: add table to appflowy editor default selection menu

* feat table markdown encoder

* refactor: apply @Xazin review suggestions

* refactor: merge main and fix color picker conflicts

* feat: table markdown decoder

* fix: use specific backgroun generator for table

* feat: table plugin

* style: adapt new structure

* fix: table columns border height

* fix: adapt new style key commands

* fix: remove table context menu

* test: adapt to main branch changes

* fix: backspace handling regarding table

* fix: flutter analyze

* fix: enter when table cell is bullet list

* fix: selection bug on large table

* feat: row/col action menu

* fix: row action handler positioning

* refactor: merge row and col handler widget

* refactor: add size and color to handler icon

* style(merge): merge main

* feat: added padding and action wrapper

* feat: enable customizing icons and etc

* feat: table menu builder

* fix: table getBlockRect

* refactor: table action button design

---------

Co-authored-by: Lucas.Xu <lucas.xu@appflowy.io>
2023-08-29 15:24:25 +08:00
Mohammad Zolfaghari
e2fc87f892
fix: exception on prev node text direction null (#404)
* feat: default text direction property

Introduced default text direction property on editor style. which
accepts rtl|ltr|auto for controlling default fallback direction.
Before this we had something controlled by Directionality but it
had two problems:
1. It didn't accept auto text direction. We had to introduce our
own Directionality component.
2. Directionality also affects layout direction, for example
setting Directionality to RTL will cause the handlers and other
things move to right side of the screen. While this is good but
there are cases which we don't want to change whole layout direction
but only the text default direction to for example auto.

* fix: flutter analyze

* fix: exception on prev node text direction null

The code was throwing excenption on changing current node text
direction to auto when the previous node had text direction attribute
with null value.
Also changed to only use direct previous node text direction and
direct parent for inheriting text direction when the current node
text direction is auto and undeterminable (e.g. empty text).
2023-08-29 15:20:50 +08:00
Mohammad Zolfaghari
9105812cbc
feat: default text direction property (#402)
* feat: default text direction property

Introduced default text direction property on editor style. which
accepts rtl|ltr|auto for controlling default fallback direction.
Before this we had something controlled by Directionality but it
had two problems:
1. It didn't accept auto text direction. We had to introduce our
own Directionality component.
2. Directionality also affects layout direction, for example
setting Directionality to RTL will cause the handlers and other
things move to right side of the screen. While this is good but
there are cases which we don't want to change whole layout direction
but only the text default direction to for example auto.

* fix: flutter analyze

* fix: bugfix on auto as default text direction

* docs: make documentation clear
2023-08-28 17:13:04 +08:00
Mukund Tandon
5a0a6fa5e0
fix: fixed the cursor not moving to next line after inserting divider (#371)
* fix: fixed the cursor not moving to next line after inserting divider

* test: added test

* fix: fixed failing checks

* fix: fixed issues from code review

* refactor: removed the use of depriciated function
2023-08-28 17:11:58 +08:00
Mayur Mahajan
e38b07d13b
fix: replace matches on the same node (#418)
* test: failing test for expected behavior

* test: fix test by removing enter

* fix: replace all fixed

* chore: remove unused code

* test: replace selected called multiple times

* chore: remove unused variable
2023-08-28 11:02:41 +08:00
Lucas.Xu
1922e56903
feat: migrate copy paste command from AppFlowy (#413) 2023-08-25 15:58:33 +08:00
Mathias Mogensen
2eb801e7f5
feat: double hyphen to em dash (#395)
* feat: double hyphen to em dash

* chore: fix tests

---------

Co-authored-by: Lucas.Xu <lucas.xu@appflowy.io>
2023-08-21 11:46:45 +08:00
MayurSMahajan
de779ab87a test: open link command 2023-08-21 10:43:06 +08:00
MayurSMahajan
807a8dfb96 refactor: show link command test 2023-08-21 10:43:06 +08:00
Lucas.Xu
378ff75a97 fix: test error 2023-08-17 13:49:51 +08:00
Mathias Mogensen
daab208f54 test: clean slash_command.dart 2023-08-17 13:13:45 +08:00
Mathias Mogensen
a564c10e87 chore: deprecate Selection.collapse + coverage for selection.dart 2023-08-17 13:13:45 +08:00
Lucas.Xu
5df1d3ab35 fix: link is not auto formatted 2023-08-13 18:14:58 +08:00
Mayur Mahajan
f5c6dc2ce7
feat: find dialog 1760 (#106)
* feat: make find menu widget

* feat: service for find menu

* feat: add find menu shortcut event

* feat: create a search service

* docs: explain search service

* fix: unhighlight method takes searched word

* fix: unhighlight before each search

* feat: navigate between matches

* feat: forget highlighting from undo stack

* feat: replace logic and ui

* feat: replace shortcut handler and widget

* test: find functionality

* test: replace menu tests

* refactor: separate class for search algo

* refactor: suggested changes

* refactor: remove unhighlight method

* feat: add find highlight color

* refactor: name of the search algo class

* test: unit tests for search algorithm

* chore: simplify syntax

* test: renamed test group

* refactor: move to editor

* refactor: add shortcut for find

* refactor: use new api

* refactor: add abstrac class search algo

* fix: avoid multiple instances of find dialog

* refactor: xazin's suggestions

* chore: separately build input decor

* test: search algorithm

* chore: unhighlight properly

* refactor: replace handler

* refactor: move tests into new

* test: find menu widget test

* test: replace menu

* fix: localizations + resolve scroll bug partially

* fix: without update selection on highlight

* fix: do not select words when highlighting

* test: update expected selection

* fix: matches and styling

* feat: separate attribute for highlighting

* feat: unique color for selected match

* test: unique color for selected match

* refactor: cleaning the code

* fix: navigate to first match

* fix: tests and replace logic

---------

Co-authored-by: Mathias Mogensen <mathiasrieckm@gmail.com>
Co-authored-by: Mathias Mogensen <42929161+Xazin@users.noreply.github.com>
2023-08-10 13:08:45 +02:00
Lucas.Xu
953249fefd
fix: lose selection after pasting (#365)
* fix: the selection area delay to update after typing enter

* fix: selection will lose after pasting
2023-08-10 15:22:43 +08:00
Mayur Mahajan
2b517b2a5b
feat: paste plaintext shortcut (#338)
* feat: shortcut for pasting plaintext

* test: paste without formatting

* chore: use text directly

* refactor: add cut command
2023-08-02 10:03:03 +08:00
Ali Hassan
73d56b44e2
fix: copy handler migrated to latest api (#240) 2023-07-25 10:08:18 +08:00
Lucas.Xu
1205e7b00b
fix: unable to paste multiple lines (#332) 2023-07-20 18:03:49 +08:00
Mohammad Zolfaghari
3bd7c2aaa2
fix: indent padding from left when rtl (#318) 2023-07-19 15:58:27 +08:00
Mayur Mahajan
2ab67ee217
feat: delete right word with ctrl+delete (#309) 2023-07-13 19:25:50 +08:00
Mayur Mahajan
68300149bf
feat: support for shift+home/end keys (#306) 2023-07-13 19:25:14 +08:00
Lucas.Xu
5f136df356
feat: remove the reference of the deprecated values (#304)
* feat: remove the reference of the deprecated values

* chore: add migration guide
2023-07-12 13:21:54 +08:00
Mohammad Zolfaghari
f8da435ad5
feat: support RTL and auto direction (#191) 2023-07-12 10:51:38 +08:00
Mayur Mahajan
fc7b4e5c81
chore: change windows and linux command for redo (#294) 2023-07-11 22:34:05 +08:00
Mayur Mahajan
49752db13f
test: for testing parent child delete case (#296)
* test: add test for parent child delete case

* docs: suitable names to arrow commands
2023-07-10 11:12:52 +08:00
Mayur Mahajan
3f7c9fe2b5
feat: implement delete command shortcut (#272) 2023-07-07 19:49:51 +08:00
Lucas.Xu
46158d9e26
feat: customize href (#293) 2023-07-07 16:07:47 +08:00
Lucas.Xu
bb3771af63
chore: bump version 1.1.0 (#284) 2023-07-04 14:07:23 +08:00
Lucas.Xu
2b2bce4f3c
fix: analysis issues (#283) 2023-07-04 11:22:35 +08:00
Yijing Huang
13805afc33
feat: customized color options (#270) 2023-07-04 10:38:42 +08:00
Vincenzo Ursano
c8082d38df
feat: support exitting the link menu by pressing ESC 2023-07-03 17:05:42 +08:00
Yijing Huang
8bfb37f691
fix: keep keyboard appearance as same brightness as system theme (#264) 2023-07-03 12:51:18 +08:00