这是indexloc提供的服务,不要输入任何密码
Skip to content

Move FlutterLogo out of Material library #154711

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

Conversation

SohanRaidev
Copy link

@SohanRaidev SohanRaidev commented Sep 6, 2024

  • Moved flutter_logo.dart from material to widgets
  • Updated exports in material.dart and widgets.dart
  • Updated imports in CupertinoContextMenu examples

Fixes #154448

Pre-launch Checklist

If you need help, consider asking for advice on the #hackers-new channel on Discord.

@flutter-dashboard
Copy link

It looks like this pull request may not have tests. Please make sure to add tests before merging. If you need an exemption, contact "@test-exemption-reviewer" in the #hackers channel in Discord (don't just cc them here, they won't see it!).

If you are not sure if you need tests, consider this rule of thumb: the purpose of a test is to make sure someone doesn't accidentally revert the fix. Ask yourself, is there anything in your PR that you feel it is important we not accidentally revert back to how it was before your fix?

Reviewers: Read the Tree Hygiene page and make sure this patch meets those guidelines before LGTMing. The test exemption team is a small volunteer group, so all reviewers should feel empowered to ask for tests, without delegating that responsibility entirely to the test exemption group.

@github-actions github-actions bot added a: text input Entering text in a text field or keyboard related problems framework flutter/packages/flutter repository. See also f: labels. f: material design flutter/packages/flutter/material repository. f: cupertino flutter/packages/flutter/cupertino repository d: api docs Issues with https://api.flutter.dev/ d: examples Sample code and demos labels Sep 6, 2024
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To verify that the new import works, this needs a test. However, we already have a test for FlutterLogo at

https://github.com/flutter/flutter/blob/master/packages/flutter/test/material/flutter_logo_test.dart

Could you move flutter_logo_test.dart to test/widgets/flutter_logo_test.dart (so essentially also moving the test file)
and update the import in that file to point to the widgets library? That would be sufficient as a test for this.
(updating the import statement is the new test)

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the feedback, Sir! I'll make the changes and update the test file as soon as I can. I'll notify you once it's done.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @navaronbracke , I’ve made the requested changes. I’ve moved flutter_logo_test.dart to the widgets directory and updated the import to point to the widgets library. Please review when you have time. Thank you!

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Test file is still under material directory.

@navaronbracke
Copy link
Contributor

This still has an analysis failure:

An error was detected when looking at import dependencies within the Flutter package:
One of the files in the widgets package imports that package recursively.

If you run dev/bots/analyze.dart from your checkout of the Flutter SDK you can probably reproduce the failure.

@SohanRaidev
Copy link
Author

@piedcipher @navaronbracke

Thanks for pointing that out! I'll fix it as soon as possible and update the PR.

@Piinks
Copy link
Contributor

Piinks commented Sep 25, 2024

@SohanRaidev there are still some failing checks here, can you take a look?

auto-submit bot pushed a commit that referenced this pull request Sep 30, 2024
The PR is moving FlutterLogo from `lib/src/material` to `lib/src/widgets` because it has no dependency on Material.

Issue: #154448

PS: There is [older PR](#154711) for this issue and I don't know the policy on conflicting PRs. Let me know if I need to drop mine.
@victorsanni
Copy link
Contributor

Closing as #155864 fixes the accompanying issue.

thejitenpatel pushed a commit to thejitenpatel/flutter that referenced this pull request Oct 1, 2024
The PR is moving FlutterLogo from `lib/src/material` to `lib/src/widgets` because it has no dependency on Material.

Issue: flutter#154448

PS: There is [older PR](flutter#154711) for this issue and I don't know the policy on conflicting PRs. Let me know if I need to drop mine.
@SohanRaidev SohanRaidev deleted the move-flutter-logo-out-of-material branch November 2, 2024 18:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
a: text input Entering text in a text field or keyboard related problems d: api docs Issues with https://api.flutter.dev/ d: examples Sample code and demos f: cupertino flutter/packages/flutter/cupertino repository f: material design flutter/packages/flutter/material repository. framework flutter/packages/flutter repository. See also f: labels.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Move FlutterLogo out of the Material library
5 participants