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

Discovery aligned right fix #71

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion example/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ dependencies:

# The following adds the Cupertino Icons font to your application.
# Use with the CupertinoIcons class for iOS style icons.
cupertino_icons: ^0.1.2
cupertino_icons: ^1.0.3
feature_discovery:
path: ../

Expand Down
1 change: 1 addition & 0 deletions lib/src/foundation/feature_discovery.dart
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ enum ContentLocation {
above,
below,
trivial,
right,
}

class FeatureDiscovery extends StatelessWidget {
Expand Down
4 changes: 4 additions & 0 deletions lib/src/widgets/overlay.dart
Original file line number Diff line number Diff line change
Expand Up @@ -462,6 +462,10 @@ class _DescribedFeatureOverlayState extends State<DescribedFeatureOverlay>

Offset? endingBackgroundPosition;
switch (contentLocation) {
case ContentLocation.right:
endingBackgroundPosition =
Offset(width / 2.0, anchor.dy + (width / 4.0));
break;
case ContentLocation.above:
endingBackgroundPosition = Offset(
anchor.dx -
Expand Down
9 changes: 3 additions & 6 deletions pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ description: >-
A Flutter package that implements Material Design Feature discovery
to show a description of specific features to new users.
See https://tinyurl.com/FeatureDiscovery
version: 0.14.0
version: 0.14.0+1
homepage: https://github.com/ayalma/feature_discovery

environment:
Expand All @@ -16,14 +16,11 @@ dependencies:
sdk: flutter

provider: ^5.0.0
shared_preferences: ^2.0.3
shared_preferences: ^2.0.5

dev_dependencies:
flutter_test:
sdk: flutter

pedantic: 1.9.0
pedantic: ^1.11.0

dependency_overrides:
# TODO(creativecreatorormaybenot): Remove when Pedantic is updated in flutter_test.
pedantic: 1.9.0