Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug with Cursor Movement in iPhone Safari #58

Open
mycalls opened this issue Dec 31, 2024 · 1 comment
Open

Bug with Cursor Movement in iPhone Safari #58

mycalls opened this issue Dec 31, 2024 · 1 comment
Assignees
Labels
bug Something isn't working

Comments

@mycalls
Copy link

mycalls commented Dec 31, 2024

  1. Run the sample code in Safari on an iPhone.
  2. Moving the cursor causes the character before the cursor to be deleted.
import 'package:flutter/material.dart';
import 'package:re_editor/re_editor.dart';

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

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

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: const MyHomePage(),
    );
  }
}

class MyHomePage extends StatefulWidget {
  const MyHomePage({super.key});

  @override
  State<MyHomePage> createState() => _MyHomePageState();
}

final _initialText =
    List.generate(500, (int index) => '${index + 1} abcde').join('\n');

class _MyHomePageState extends State<MyHomePage> {
  final _controller = CodeLineEditingController.fromText(_initialText);

  @override
  void dispose() {
    _controller.dispose();
    super.dispose();
  }

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        title: Text('re_editor smaple'),
      ),
      body: CodeEditor(
        controller: _controller,
      ),
    );
  }
}

Screenshots
https://github.com/user-attachments/assets/6df245ed-1815-4f6f-87a1-ff522152d69f

Device:

  • OS: iOS
  • Version 18.2
@mycalls mycalls added the bug Something isn't working label Dec 31, 2024
@hommes-doutant
Copy link

I've also noticed this bug on android when testing the behaviour in the reqable app for #71

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants