lukehutch · GitHub

Describe the bug

Select code like this:

image

Paste into another class, where the field Color backgroundColor is not present:

image

The onTap and icon fields are pasted as-is. However, backgroundColor gets transformed into colorScheme.background.

This is unexpected, and frankly weird...

It may have something to do with the special rendering of colors in Dart-Code, with a color swatch thumbnail.

Please complete the following information:

  • Operating System and version: Linux
  • VS Code version: latest
  • Dart extension version: latest
  • Dart/Flutter SDK version: latest
  • Target device (if the issue relates to Flutter debugging):

Read the original on github.com ↗