Skip to content

Regression in 10.4.0: TabView within Flutter loses horizontal swipe functionality when containing multiple Quill editors #2376

@aitaro

Description

@aitaro

Is there an existing issue for this?

Flutter Quill version

10.8.5

Steps to reproduce

  1. Clone the following repository with the reproduction setup: https://github.com/aitaro/flutter_quill_example.
  2. Run the app on a device or emulator.
  3. Swipe horizontally between tabs containing individual Quill editors.
import 'package:flutter/material.dart';
import 'package:flutter_quill/flutter_quill.dart';
import 'package:flutter_quill_example/samples/quill_text_sample.dart';

void main() {
  runApp(const MyApp());
}

class MyApp extends StatelessWidget {
  const MyApp({super.key});

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Flutter Demo',
      home: DefaultTabController(
        length: 2,
        child: Scaffold(
          backgroundColor: Colors.white,
          appBar: AppBar(
            title: const Text('home'),
            bottom: const TabBar(
              tabs: <Widget>[
                Tab(text: 'quillTextSample1'),
                Tab(text: 'quillTextSample2'),
              ],
            ),
          ),
          body: TabBarView(
            children: [
              SingleChildScrollView(
                padding: const EdgeInsets.all(16),
                child: MyQuillEditor(
                  document: Document.fromJson(quillTextSample),
                ),
              ),
              SingleChildScrollView(
                padding: const EdgeInsets.all(16),
                child: MyQuillEditor(
                  document: Document.fromJson(quillTextSample),
                ),
              ),
            ],
          ),
        ),
      ),
    );
  }
}

class MyQuillEditor extends StatelessWidget {
  const MyQuillEditor({
    required this.document,
    super.key,
  });

  final Document document;

  @override
  Widget build(BuildContext context) {
    final controller = QuillController(
      document: document,
      selection: const TextSelection.collapsed(offset: 0),
      readOnly: true,
    );

    return QuillEditor(
      scrollController: ScrollController(),
      focusNode: FocusNode(),
      controller: controller,
      configurations: const QuillEditorConfigurations(
        scrollable: false,
        showCursor: false,
      ),
    );
  }
}

Expected results

Swiping horizontally should change the active tab as usual, allowing seamless tab switching.

Actual results

Horizontal swiping no longer works to change tabs when each tab contains a Quill editor, blocking the TabView’s normal navigation behavior.

Additional Context

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingiOSIssues or feature requests specific to the iOS platform.majorSignificant impact on the user experience or performance. This issue should be addressed in the nextregressionFor issues where a previously working feature is now broken due to recent changes.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions