Skip to content

Intellisense doesn't show type information on factories #4943

@JCKodel

Description

@JCKodel

Describe the bug
There is a discrepancy in information shown on intellisense for Flutter properties.

To Reproduce

  1. Create a flutter project
  2. Add the skeletonizer package

image

In this screenshot, is the normal behavior of Flutter in VSCode (the activeColor property is of type Color, as shown in the intellisense panel).

Now, the Skeletonizer widget shows this:

image

No type information beside the property type.

The only difference is this:

SwitchListTile.adaptive is a const constructor, while skeletonizer is a const factory:

const factory Skeletonizer({
  Key? key,
  required Widget child,
  bool enabled,
  PaintingEffect? effect,
  TextBoneBorderRadius? textBoneBorderRadius,
  bool? ignoreContainers,
  bool? justifyMultiLineText,
  Color? containersColor,
  bool ignorePointers,
}) = _Skeletonizer;
Workspace Environment
Dart Code extension: 3.80.0
Flutter extension: 3.80.0 (activated)

App: Visual Studio Code
App Host: desktop
Version: win 1.85.1

Workspace type: Flutter (LSP)

Dart (3.2.4): C:\Users\jckod\fvm\versions\3.16.7\bin\cache\dart-sdk
Flutter (3.16.7): C:\Users\jckod\fvm\versions\3.16.7 (sdk gphone64 x86 64 (android-x64/android))

Output from 'dart info'

C:\Users\jckod\fvm\versions\3.16.7\bin\cache\dart-sdk\bin\dart.exe info

If providing this information as part of reporting a bug, please review the information
below to ensure it only contains things you're comfortable posting publicly.

General info

  • Dart 3.2.4 (stable) (Thu Dec 21 19:13:53 2023 +0000) on "windows_x64"
  • on windows / "Windows 10 Pro" 10.0 (Build 22631)
  • locale is pt-BR

Project info

  • sdk constraint: '>=3.2.3 <4.0.0'
  • dependencies: animated_emoji, cupertino_icons, dart_mappable, device_details_flutter, dio, fancy_dio_inspector, firebase_analytics, firebase_auth, firebase_core, firebase_crashlytics, firebase_performance, firebase_performance_dio, flutter, flutter_localizations, flutter_native_splash, google_sign_in, gql_dio_link, graphql_flutter, image_size_getter, image_size_getter_flutter, ksuid, local_auth, markdown_viewer, material_symbols_icons, native_dio_adapter, path, path_provider, provider, rive, rxdart, sign_in_with_apple, skeletonizer, slide_indexed_stack, sqflite, sqlite3_flutter_libs, sqlite_viewer, url_launcher
  • dev_dependencies: build_runner, dart_mappable_builder, flutter_lints, graphql_codegen

Process info

Memory CPU Elapsed time Command line
1056 MB -- dart.exe
91 MB -- dart.exe
112 MB -- dart.exe
158 MB -- dart.exe
189 MB -- dart.exe
686 MB -- dart.exe
87 MB -- dart.exe
Output from 'flutter doctor'

C:\Users\jckod\fvm\versions\3.16.7\bin\flutter.bat doctor -v

[√] Flutter (Channel stable, 3.16.7, on Microsoft Windows [Version 10.0.22631.3007], locale pt-BR)
    • Flutter version 3.16.7 on channel stable at C:\Users\jckod\fvm\versions\3.16.7
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision ef1af02aea (4 days ago), 2024-01-11 15:19:26 -0600
    • Engine revision 4a585b7929
    • Dart version 3.2.4
    • DevTools version 2.28.5

[√] Windows Version (Installed version of Windows is version 10 or higher)

[√] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
    • Android SDK at C:\Users\jckod\AppData\Local\Android\sdk
    • Platform android-34, build-tools 34.0.0
    • Java binary at: C:\Program Files\Android\Android Studio\jbr\bin\java
    • Java version OpenJDK Runtime Environment (build 17.0.7+0-b2043.56-10550314)
    • All Android licenses accepted.

[√] Chrome - develop for the web
    • Chrome at C:\Program Files\Google\Chrome\Application\chrome.exe

[√] Visual Studio - develop Windows apps (Visual Studio Community 2022 17.8.3)
    • Visual Studio at C:\Program Files\Microsoft Visual Studio\2022\Community
    • Visual Studio Community 2022 version 17.8.34330.188
    • Windows 10 SDK version 10.0.22621.0

[√] Android Studio (version 2023.1)
    • Android Studio at C:\Program Files\Android\Android Studio
    • Flutter plugin can be installed from:
       https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
       https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 17.0.7+0-b2043.56-10550314)

[√] VS Code (version 1.85.1)
    • VS Code at C:\Users\jckod\AppData\Local\Programs\Microsoft VS Code
    • Flutter extension version 3.80.0

[√] Connected device (4 available)
    • sdk gphone64 x86 64 (mobile) • emulator-5554 • android-x64    • Android 14 (API 34) (emulator)
    • Windows (desktop)            • windows       • windows-x64    • Microsoft Windows [Version 10.0.22631.3007]
    • Chrome (web)                 • chrome        • web-javascript • Google Chrome 120.0.6099.217
    • Edge (web)                   • edge          • web-javascript • Microsoft Edge 120.0.2210.91

[√] Network resources
    • All expected network resources are available.

• No issues found!

Metadata

Metadata

Assignees

No one assigned

    Labels

    in editorRelates to code editing or language featuresin lsp/analysis serverSomething to be fixed in the Dart analysis serveris bugrelies on sdk changesSomething that requires changes in the Dart/Flutter SDK to ship before it will become available

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions