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
This commit is contained in:
Lucas.Xu 2023-11-08 13:46:33 +08:00 • committed by GitHub
commit c7d99913aa
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 215 additions and 285 deletions

View file

@ -391,7 +391,7 @@ void main() {
paragraphNode(
text: 'س',
textDirection: blockComponentTextDirectionRTL,
)
),
],
);
final editor = tester.editor..addNode(node);

View file

@ -348,7 +348,7 @@ void main() async {
expect(delta1.toJson(), [
{
"insert": "Hello",
"attributes": {"bold": true, "italic": true, "underline": true}
"attributes": {"bold": true, "italic": true, "underline": true},
}
]);
@ -366,11 +366,11 @@ void main() async {
expect(delta2.toJson(), [
{
"insert": "Hello",
"attributes": {"bold": true, "italic": true, "underline": true}
"attributes": {"bold": true, "italic": true, "underline": true},
},
{
"insert": "World",
"attributes": {"bold": false, "italic": false, "underline": false}
"attributes": {"bold": false, "italic": false, "underline": false},
},
]);
@ -415,7 +415,7 @@ void main() async {
expect(delta1.toJson(), [
{
"insert": "Hello",
"attributes": {"bold": false, "italic": false, "underline": false}
"attributes": {"bold": false, "italic": false, "underline": false},
}
]);

View file

@ -17,7 +17,7 @@ void main() async {
final nestedBlock = node.key.currentState!
.unwrapOrNull<NestedBlockComponentStatefulWidgetMixin>();
expect(nestedBlock?.indentPadding.left, 30);
expect(nestedBlock?.indentPadding.left, 24);
expect(nestedBlock?.indentPadding.right, 0);
await editor.dispose();
@ -34,7 +34,7 @@ void main() async {
final nestedBlock = node.key.currentState!
.unwrapOrNull<NestedBlockComponentStatefulWidgetMixin>();
expect(nestedBlock?.indentPadding.left, 30);
expect(nestedBlock?.indentPadding.left, 24);
expect(nestedBlock?.indentPadding.right, 0);
await editor.dispose();
@ -55,7 +55,7 @@ void main() async {
.unwrapOrNull<NestedBlockComponentStatefulWidgetMixin>();
expect(nestedBlock?.indentPadding.left, 0);
expect(nestedBlock?.indentPadding.right, 30);
expect(nestedBlock?.indentPadding.right, 24);
await editor.dispose();
});
@ -75,7 +75,7 @@ void main() async {
.unwrapOrNull<NestedBlockComponentStatefulWidgetMixin>();
expect(nestedBlock?.indentPadding.left, 0);
expect(nestedBlock?.indentPadding.right, 30);
expect(nestedBlock?.indentPadding.right, 24);
await editor.dispose();
});
@ -95,7 +95,7 @@ void main() async {
.unwrapOrNull<NestedBlockComponentStatefulWidgetMixin>();
expect(nestedBlock?.indentPadding.left, 0);
expect(nestedBlock?.indentPadding.right, 30);
expect(nestedBlock?.indentPadding.right, 24);
await editor.dispose();
});
@ -120,7 +120,7 @@ void main() async {
.unwrapOrNull<NestedBlockComponentStatefulWidgetMixin>();
expect(nestedBlock?.indentPadding.left, 0);
expect(nestedBlock?.indentPadding.right, 30);
expect(nestedBlock?.indentPadding.right, 24);
final selection = Selection.single(
path: [0, 0],
@ -134,7 +134,7 @@ void main() async {
final nestedBlockAfter = node.key.currentState!
.unwrapOrNull<NestedBlockComponentStatefulWidgetMixin>();
expect(nestedBlockAfter?.indentPadding.left, 30);
expect(nestedBlockAfter?.indentPadding.left, 24);
expect(nestedBlockAfter?.indentPadding.right, 0);
await editor.dispose();

View file

@ -10,7 +10,7 @@ void main() async {
const HTMLQuoteNodeParser(),
const HTMLHeadingNodeParser(),
const HTMLImageNodeParser(),
const HtmlTableNodeParser()
const HtmlTableNodeParser(),
];
group('document_html_encoder_test.dart', () {
setUpAll(() {

View file

@ -10,7 +10,7 @@ void main() async {
const HTMLQuoteNodeParser(),
const HTMLHeadingNodeParser(),
const HTMLImageNodeParser(),
const HtmlTableNodeParser()
const HtmlTableNodeParser(),
];
group('html_image_node_parser.dart', () {
test('parser image node', () {

View file

@ -11,7 +11,7 @@ void main() async {
const HTMLQuoteNodeParser(),
const HTMLHeadingNodeParser(),
const HTMLImageNodeParser(),
const HtmlTableNodeParser()
const HtmlTableNodeParser(),
];
group('html_image_node_parser.dart', () {
test('table node parser test', () {

View file

@ -249,53 +249,57 @@ void main() {
[
{
"insert": "DTrace is a ",
"attributes": {"bg_color": "0xffffffff", "font_color": "0xff242424"}
"attributes": {"bg_color": "0xffffffff", "font_color": "0xff242424"},
},
{
"insert": "dynamic tracing",
"attributes": {"bg_color": "0xffbbdbba", "bold": true, "italic": true}
"attributes": {
"bg_color": "0xffbbdbba",
"bold": true,
"italic": true,
},
},
{
"insert": " technology",
"attributes": {"bg_color": "0xffbbdbba"}
"attributes": {"bg_color": "0xffbbdbba"},
},
{
"insert": " that can be used to locate ",
"attributes": {"bg_color": "0xffffffff", "font_color": "0xff242424"}
"attributes": {"bg_color": "0xffffffff", "font_color": "0xff242424"},
},
{
"insert": "system performance issues",
"attributes": {"bg_color": "0xffe8f3e8"}
"attributes": {"bg_color": "0xffe8f3e8"},
},
{
"insert": ", obtain information about ",
"attributes": {"bg_color": "0xffffffff", "font_color": "0xff242424"}
"attributes": {"bg_color": "0xffffffff", "font_color": "0xff242424"},
},
{
"insert": "system function calls",
"attributes": {"bg_color": "0xffe8f3e8"}
"attributes": {"bg_color": "0xffe8f3e8"},
},
{
"insert":
", or monitor system runtime information. And worth noting is that DTrace is ",
"attributes": {"bg_color": "0xffffffff", "font_color": "0xff242424"}
"attributes": {"bg_color": "0xffffffff", "font_color": "0xff242424"},
},
{
"insert": "non-intrusive",
"attributes": {"bg_color": "0xffe8f3e8", "bold": true}
"attributes": {"bg_color": "0xffe8f3e8", "bold": true},
},
{
"insert":
" to existing code. Also, there is no need to modify the existing code or use ",
"attributes": {"bg_color": "0xffffffff", "font_color": "0xff242424"}
"attributes": {"bg_color": "0xffffffff", "font_color": "0xff242424"},
},
{
"insert": "instrumentation technology",
"attributes": {"bg_color": "0xffe8f3e8"}
"attributes": {"bg_color": "0xffe8f3e8"},
},
{
"insert": " to obtain more system information.",
"attributes": {"bg_color": "0xffffffff", "font_color": "0xff242424"}
"attributes": {"bg_color": "0xffffffff", "font_color": "0xff242424"},
}
],
);