Committed by
GitHub
feat: sheet improvements (#355)
* feat: sheet improvements * fix: remove unused simulation * fix: rebase * fix: update dependencies
Showing
35 changed files
with
469 additions
and
414 deletions
| @@ -21,6 +21,6 @@ | @@ -21,6 +21,6 @@ | ||
| 21 | <key>CFBundleVersion</key> | 21 | <key>CFBundleVersion</key> |
| 22 | <string>1.0</string> | 22 | <string>1.0</string> |
| 23 | <key>MinimumOSVersion</key> | 23 | <key>MinimumOSVersion</key> |
| 24 | - <string>9.0</string> | 24 | + <string>11.0</string> |
| 25 | </dict> | 25 | </dict> |
| 26 | </plist> | 26 | </plist> |
| 1 | # Uncomment this line to define a global platform for your project | 1 | # Uncomment this line to define a global platform for your project |
| 2 | -# platform :ios, '9.0' | 2 | +# platform :ios, '11.0' |
| 3 | 3 | ||
| 4 | # CocoaPods analytics sends network stats synchronously affecting flutter build latency. | 4 | # CocoaPods analytics sends network stats synchronously affecting flutter build latency. |
| 5 | ENV['COCOAPODS_DISABLE_STATS'] = 'true' | 5 | ENV['COCOAPODS_DISABLE_STATS'] = 'true' |
| @@ -14,9 +14,9 @@ EXTERNAL SOURCES: | @@ -14,9 +14,9 @@ EXTERNAL SOURCES: | ||
| 14 | :path: ".symlinks/plugins/url_launcher_ios/ios" | 14 | :path: ".symlinks/plugins/url_launcher_ios/ios" |
| 15 | 15 | ||
| 16 | SPEC CHECKSUMS: | 16 | SPEC CHECKSUMS: |
| 17 | - Flutter: 50d75fe2f02b26cc09d224853bb45737f8b3214a | ||
| 18 | - url_launcher_ios: 839c58cdb4279282219f5e248c3321761ff3c4de | 17 | + Flutter: f04841e97a9d0b0a8025694d0796dd46242b2854 |
| 18 | + url_launcher_ios: ae1517e5e344f5544fb090b079e11f399dfbe4d2 | ||
| 19 | 19 | ||
| 20 | -PODFILE CHECKSUM: aafe91acc616949ddb318b77800a7f51bffa2a4c | 20 | +PODFILE CHECKSUM: ef19549a9bc3046e7bb7d2fab4d021637c0c58a3 |
| 21 | 21 | ||
| 22 | -COCOAPODS: 1.11.3 | 22 | +COCOAPODS: 1.13.0 |
| @@ -3,7 +3,7 @@ | @@ -3,7 +3,7 @@ | ||
| 3 | archiveVersion = 1; | 3 | archiveVersion = 1; |
| 4 | classes = { | 4 | classes = { |
| 5 | }; | 5 | }; |
| 6 | - objectVersion = 50; | 6 | + objectVersion = 54; |
| 7 | objects = { | 7 | objects = { |
| 8 | 8 | ||
| 9 | /* Begin PBXBuildFile section */ | 9 | /* Begin PBXBuildFile section */ |
| @@ -113,7 +113,6 @@ | @@ -113,7 +113,6 @@ | ||
| 113 | 9E13656F8C2A211F9F4C04EF /* Pods-Runner.release.xcconfig */, | 113 | 9E13656F8C2A211F9F4C04EF /* Pods-Runner.release.xcconfig */, |
| 114 | C33049C8773181A0B4BCD4EE /* Pods-Runner.profile.xcconfig */, | 114 | C33049C8773181A0B4BCD4EE /* Pods-Runner.profile.xcconfig */, |
| 115 | ); | 115 | ); |
| 116 | - name = Pods; | ||
| 117 | path = Pods; | 116 | path = Pods; |
| 118 | sourceTree = "<group>"; | 117 | sourceTree = "<group>"; |
| 119 | }; | 118 | }; |
| @@ -156,7 +155,7 @@ | @@ -156,7 +155,7 @@ | ||
| 156 | 97C146E61CF9000F007C117D /* Project object */ = { | 155 | 97C146E61CF9000F007C117D /* Project object */ = { |
| 157 | isa = PBXProject; | 156 | isa = PBXProject; |
| 158 | attributes = { | 157 | attributes = { |
| 159 | - LastUpgradeCheck = 1300; | 158 | + LastUpgradeCheck = 1430; |
| 160 | ORGANIZATIONNAME = ""; | 159 | ORGANIZATIONNAME = ""; |
| 161 | TargetAttributes = { | 160 | TargetAttributes = { |
| 162 | 97C146ED1CF9000F007C117D = { | 161 | 97C146ED1CF9000F007C117D = { |
| @@ -200,10 +199,12 @@ | @@ -200,10 +199,12 @@ | ||
| 200 | /* Begin PBXShellScriptBuildPhase section */ | 199 | /* Begin PBXShellScriptBuildPhase section */ |
| 201 | 3B06AD1E1E4923F5004D2608 /* Thin Binary */ = { | 200 | 3B06AD1E1E4923F5004D2608 /* Thin Binary */ = { |
| 202 | isa = PBXShellScriptBuildPhase; | 201 | isa = PBXShellScriptBuildPhase; |
| 202 | + alwaysOutOfDate = 1; | ||
| 203 | buildActionMask = 2147483647; | 203 | buildActionMask = 2147483647; |
| 204 | files = ( | 204 | files = ( |
| 205 | ); | 205 | ); |
| 206 | inputPaths = ( | 206 | inputPaths = ( |
| 207 | + "${TARGET_BUILD_DIR}/${INFOPLIST_PATH}", | ||
| 207 | ); | 208 | ); |
| 208 | name = "Thin Binary"; | 209 | name = "Thin Binary"; |
| 209 | outputPaths = ( | 210 | outputPaths = ( |
| @@ -214,6 +215,7 @@ | @@ -214,6 +215,7 @@ | ||
| 214 | }; | 215 | }; |
| 215 | 9740EEB61CF901F6004384FC /* Run Script */ = { | 216 | 9740EEB61CF901F6004384FC /* Run Script */ = { |
| 216 | isa = PBXShellScriptBuildPhase; | 217 | isa = PBXShellScriptBuildPhase; |
| 218 | + alwaysOutOfDate = 1; | ||
| 217 | buildActionMask = 2147483647; | 219 | buildActionMask = 2147483647; |
| 218 | files = ( | 220 | files = ( |
| 219 | ); | 221 | ); |
| @@ -340,7 +342,7 @@ | @@ -340,7 +342,7 @@ | ||
| 340 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; | 342 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; |
| 341 | GCC_WARN_UNUSED_FUNCTION = YES; | 343 | GCC_WARN_UNUSED_FUNCTION = YES; |
| 342 | GCC_WARN_UNUSED_VARIABLE = YES; | 344 | GCC_WARN_UNUSED_VARIABLE = YES; |
| 343 | - IPHONEOS_DEPLOYMENT_TARGET = 9.0; | 345 | + IPHONEOS_DEPLOYMENT_TARGET = 11.0; |
| 344 | MTL_ENABLE_DEBUG_INFO = NO; | 346 | MTL_ENABLE_DEBUG_INFO = NO; |
| 345 | SDKROOT = iphoneos; | 347 | SDKROOT = iphoneos; |
| 346 | SUPPORTED_PLATFORMS = iphoneos; | 348 | SUPPORTED_PLATFORMS = iphoneos; |
| @@ -356,6 +358,7 @@ | @@ -356,6 +358,7 @@ | ||
| 356 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; | 358 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; |
| 357 | CLANG_ENABLE_MODULES = YES; | 359 | CLANG_ENABLE_MODULES = YES; |
| 358 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; | 360 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; |
| 361 | + DEVELOPMENT_TEAM = 87RQQPQ85J; | ||
| 359 | ENABLE_BITCODE = NO; | 362 | ENABLE_BITCODE = NO; |
| 360 | INFOPLIST_FILE = Runner/Info.plist; | 363 | INFOPLIST_FILE = Runner/Info.plist; |
| 361 | LD_RUNPATH_SEARCH_PATHS = ( | 364 | LD_RUNPATH_SEARCH_PATHS = ( |
| @@ -417,7 +420,7 @@ | @@ -417,7 +420,7 @@ | ||
| 417 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; | 420 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; |
| 418 | GCC_WARN_UNUSED_FUNCTION = YES; | 421 | GCC_WARN_UNUSED_FUNCTION = YES; |
| 419 | GCC_WARN_UNUSED_VARIABLE = YES; | 422 | GCC_WARN_UNUSED_VARIABLE = YES; |
| 420 | - IPHONEOS_DEPLOYMENT_TARGET = 9.0; | 423 | + IPHONEOS_DEPLOYMENT_TARGET = 11.0; |
| 421 | MTL_ENABLE_DEBUG_INFO = YES; | 424 | MTL_ENABLE_DEBUG_INFO = YES; |
| 422 | ONLY_ACTIVE_ARCH = YES; | 425 | ONLY_ACTIVE_ARCH = YES; |
| 423 | SDKROOT = iphoneos; | 426 | SDKROOT = iphoneos; |
| @@ -466,7 +469,7 @@ | @@ -466,7 +469,7 @@ | ||
| 466 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; | 469 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; |
| 467 | GCC_WARN_UNUSED_FUNCTION = YES; | 470 | GCC_WARN_UNUSED_FUNCTION = YES; |
| 468 | GCC_WARN_UNUSED_VARIABLE = YES; | 471 | GCC_WARN_UNUSED_VARIABLE = YES; |
| 469 | - IPHONEOS_DEPLOYMENT_TARGET = 9.0; | 472 | + IPHONEOS_DEPLOYMENT_TARGET = 11.0; |
| 470 | MTL_ENABLE_DEBUG_INFO = NO; | 473 | MTL_ENABLE_DEBUG_INFO = NO; |
| 471 | SDKROOT = iphoneos; | 474 | SDKROOT = iphoneos; |
| 472 | SUPPORTED_PLATFORMS = iphoneos; | 475 | SUPPORTED_PLATFORMS = iphoneos; |
| @@ -483,6 +486,7 @@ | @@ -483,6 +486,7 @@ | ||
| 483 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; | 486 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; |
| 484 | CLANG_ENABLE_MODULES = YES; | 487 | CLANG_ENABLE_MODULES = YES; |
| 485 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; | 488 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; |
| 489 | + DEVELOPMENT_TEAM = 87RQQPQ85J; | ||
| 486 | ENABLE_BITCODE = NO; | 490 | ENABLE_BITCODE = NO; |
| 487 | INFOPLIST_FILE = Runner/Info.plist; | 491 | INFOPLIST_FILE = Runner/Info.plist; |
| 488 | LD_RUNPATH_SEARCH_PATHS = ( | 492 | LD_RUNPATH_SEARCH_PATHS = ( |
| @@ -505,6 +509,7 @@ | @@ -505,6 +509,7 @@ | ||
| 505 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; | 509 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; |
| 506 | CLANG_ENABLE_MODULES = YES; | 510 | CLANG_ENABLE_MODULES = YES; |
| 507 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; | 511 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; |
| 512 | + DEVELOPMENT_TEAM = 87RQQPQ85J; | ||
| 508 | ENABLE_BITCODE = NO; | 513 | ENABLE_BITCODE = NO; |
| 509 | INFOPLIST_FILE = Runner/Info.plist; | 514 | INFOPLIST_FILE = Runner/Info.plist; |
| 510 | LD_RUNPATH_SEARCH_PATHS = ( | 515 | LD_RUNPATH_SEARCH_PATHS = ( |
| @@ -5,10 +5,10 @@ packages: | @@ -5,10 +5,10 @@ packages: | ||
| 5 | dependency: transitive | 5 | dependency: transitive |
| 6 | description: | 6 | description: |
| 7 | name: async | 7 | name: async |
| 8 | - sha256: bfe67ef28df125b7dddcea62755991f807aa39a2492a23e1550161692950bbe0 | 8 | + sha256: "947bfcf187f74dbc5e146c9eb9c0f10c9f8b30743e341481c1e2ed3ecc18c20c" |
| 9 | url: "https://pub.dev" | 9 | url: "https://pub.dev" |
| 10 | source: hosted | 10 | source: hosted |
| 11 | - version: "2.10.0" | 11 | + version: "2.11.0" |
| 12 | boolean_selector: | 12 | boolean_selector: |
| 13 | dependency: transitive | 13 | dependency: transitive |
| 14 | description: | 14 | description: |
| @@ -21,10 +21,10 @@ packages: | @@ -21,10 +21,10 @@ packages: | ||
| 21 | dependency: transitive | 21 | dependency: transitive |
| 22 | description: | 22 | description: |
| 23 | name: characters | 23 | name: characters |
| 24 | - sha256: e6a326c8af69605aec75ed6c187d06b349707a27fbff8222ca9cc2cff167975c | 24 | + sha256: "04a925763edad70e8443c99234dc3328f442e811f1d8fd1a72f1c8ad0f69a605" |
| 25 | url: "https://pub.dev" | 25 | url: "https://pub.dev" |
| 26 | source: hosted | 26 | source: hosted |
| 27 | - version: "1.2.1" | 27 | + version: "1.3.0" |
| 28 | clock: | 28 | clock: |
| 29 | dependency: transitive | 29 | dependency: transitive |
| 30 | description: | 30 | description: |
| @@ -37,18 +37,18 @@ packages: | @@ -37,18 +37,18 @@ packages: | ||
| 37 | dependency: transitive | 37 | dependency: transitive |
| 38 | description: | 38 | description: |
| 39 | name: collection | 39 | name: collection |
| 40 | - sha256: cfc915e6923fe5ce6e153b0723c753045de46de1b4d63771530504004a45fae0 | 40 | + sha256: f092b211a4319e98e5ff58223576de6c2803db36221657b46c82574721240687 |
| 41 | url: "https://pub.dev" | 41 | url: "https://pub.dev" |
| 42 | source: hosted | 42 | source: hosted |
| 43 | - version: "1.17.0" | 43 | + version: "1.17.2" |
| 44 | cupertino_icons: | 44 | cupertino_icons: |
| 45 | dependency: "direct main" | 45 | dependency: "direct main" |
| 46 | description: | 46 | description: |
| 47 | name: cupertino_icons | 47 | name: cupertino_icons |
| 48 | - sha256: e35129dc44c9118cee2a5603506d823bab99c68393879edb440e0090d07586be | 48 | + sha256: d57953e10f9f8327ce64a508a355f0b1ec902193f66288e8cb5070e7c47eeb2d |
| 49 | url: "https://pub.dev" | 49 | url: "https://pub.dev" |
| 50 | source: hosted | 50 | source: hosted |
| 51 | - version: "1.0.5" | 51 | + version: "1.0.6" |
| 52 | fake_async: | 52 | fake_async: |
| 53 | dependency: transitive | 53 | dependency: transitive |
| 54 | description: | 54 | description: |
| @@ -72,61 +72,53 @@ packages: | @@ -72,61 +72,53 @@ packages: | ||
| 72 | description: flutter | 72 | description: flutter |
| 73 | source: sdk | 73 | source: sdk |
| 74 | version: "0.0.0" | 74 | version: "0.0.0" |
| 75 | - js: | ||
| 76 | - dependency: transitive | ||
| 77 | - description: | ||
| 78 | - name: js | ||
| 79 | - sha256: "5528c2f391ededb7775ec1daa69e65a2d61276f7552de2b5f7b8d34ee9fd4ab7" | ||
| 80 | - url: "https://pub.dev" | ||
| 81 | - source: hosted | ||
| 82 | - version: "0.6.5" | ||
| 83 | matcher: | 75 | matcher: |
| 84 | dependency: transitive | 76 | dependency: transitive |
| 85 | description: | 77 | description: |
| 86 | name: matcher | 78 | name: matcher |
| 87 | - sha256: "16db949ceee371e9b99d22f88fa3a73c4e59fd0afed0bd25fc336eb76c198b72" | 79 | + sha256: "1803e76e6653768d64ed8ff2e1e67bea3ad4b923eb5c56a295c3e634bad5960e" |
| 88 | url: "https://pub.dev" | 80 | url: "https://pub.dev" |
| 89 | source: hosted | 81 | source: hosted |
| 90 | - version: "0.12.13" | 82 | + version: "0.12.16" |
| 91 | material_color_utilities: | 83 | material_color_utilities: |
| 92 | dependency: transitive | 84 | dependency: transitive |
| 93 | description: | 85 | description: |
| 94 | name: material_color_utilities | 86 | name: material_color_utilities |
| 95 | - sha256: d92141dc6fe1dad30722f9aa826c7fbc896d021d792f80678280601aff8cf724 | 87 | + sha256: "9528f2f296073ff54cb9fee677df673ace1218163c3bc7628093e7eed5203d41" |
| 96 | url: "https://pub.dev" | 88 | url: "https://pub.dev" |
| 97 | source: hosted | 89 | source: hosted |
| 98 | - version: "0.2.0" | 90 | + version: "0.5.0" |
| 99 | meta: | 91 | meta: |
| 100 | dependency: transitive | 92 | dependency: transitive |
| 101 | description: | 93 | description: |
| 102 | name: meta | 94 | name: meta |
| 103 | - sha256: "6c268b42ed578a53088d834796959e4a1814b5e9e164f147f580a386e5decf42" | 95 | + sha256: "3c74dbf8763d36539f114c799d8a2d87343b5067e9d796ca22b5eb8437090ee3" |
| 104 | url: "https://pub.dev" | 96 | url: "https://pub.dev" |
| 105 | source: hosted | 97 | source: hosted |
| 106 | - version: "1.8.0" | 98 | + version: "1.9.1" |
| 107 | modal_bottom_sheet: | 99 | modal_bottom_sheet: |
| 108 | dependency: "direct main" | 100 | dependency: "direct main" |
| 109 | description: | 101 | description: |
| 110 | path: ".." | 102 | path: ".." |
| 111 | relative: true | 103 | relative: true |
| 112 | source: path | 104 | source: path |
| 113 | - version: "2.1.2" | 105 | + version: "3.0.1" |
| 114 | path: | 106 | path: |
| 115 | dependency: transitive | 107 | dependency: transitive |
| 116 | description: | 108 | description: |
| 117 | name: path | 109 | name: path |
| 118 | - sha256: db9d4f58c908a4ba5953fcee2ae317c94889433e5024c27ce74a37f94267945b | 110 | + sha256: "8829d8a55c13fc0e37127c29fedf290c102f4e40ae94ada574091fe0ff96c917" |
| 119 | url: "https://pub.dev" | 111 | url: "https://pub.dev" |
| 120 | source: hosted | 112 | source: hosted |
| 121 | - version: "1.8.2" | 113 | + version: "1.8.3" |
| 122 | plugin_platform_interface: | 114 | plugin_platform_interface: |
| 123 | dependency: transitive | 115 | dependency: transitive |
| 124 | description: | 116 | description: |
| 125 | name: plugin_platform_interface | 117 | name: plugin_platform_interface |
| 126 | - sha256: dbf0f707c78beedc9200146ad3cb0ab4d5da13c246336987be6940f026500d3a | 118 | + sha256: da3fdfeccc4d4ff2da8f8c556704c08f912542c5fb3cf2233ed75372384a034d |
| 127 | url: "https://pub.dev" | 119 | url: "https://pub.dev" |
| 128 | source: hosted | 120 | source: hosted |
| 129 | - version: "2.1.3" | 121 | + version: "2.1.6" |
| 130 | sky_engine: | 122 | sky_engine: |
| 131 | dependency: transitive | 123 | dependency: transitive |
| 132 | description: flutter | 124 | description: flutter |
| @@ -136,10 +128,10 @@ packages: | @@ -136,10 +128,10 @@ packages: | ||
| 136 | dependency: transitive | 128 | dependency: transitive |
| 137 | description: | 129 | description: |
| 138 | name: source_span | 130 | name: source_span |
| 139 | - sha256: dd904f795d4b4f3b870833847c461801f6750a9fa8e61ea5ac53f9422b31f250 | 131 | + sha256: "53e943d4206a5e30df338fd4c6e7a077e02254531b138a15aec3bd143c1a8b3c" |
| 140 | url: "https://pub.dev" | 132 | url: "https://pub.dev" |
| 141 | source: hosted | 133 | source: hosted |
| 142 | - version: "1.9.1" | 134 | + version: "1.10.0" |
| 143 | stack_trace: | 135 | stack_trace: |
| 144 | dependency: transitive | 136 | dependency: transitive |
| 145 | description: | 137 | description: |
| @@ -176,74 +168,74 @@ packages: | @@ -176,74 +168,74 @@ packages: | ||
| 176 | dependency: transitive | 168 | dependency: transitive |
| 177 | description: | 169 | description: |
| 178 | name: test_api | 170 | name: test_api |
| 179 | - sha256: ad540f65f92caa91bf21dfc8ffb8c589d6e4dc0c2267818b4cc2792857706206 | 171 | + sha256: "75760ffd7786fffdfb9597c35c5b27eaeec82be8edfb6d71d32651128ed7aab8" |
| 180 | url: "https://pub.dev" | 172 | url: "https://pub.dev" |
| 181 | source: hosted | 173 | source: hosted |
| 182 | - version: "0.4.16" | 174 | + version: "0.6.0" |
| 183 | url_launcher: | 175 | url_launcher: |
| 184 | dependency: "direct main" | 176 | dependency: "direct main" |
| 185 | description: | 177 | description: |
| 186 | name: url_launcher | 178 | name: url_launcher |
| 187 | - sha256: "698fa0b4392effdc73e9e184403b627362eb5fbf904483ac9defbb1c2191d809" | 179 | + sha256: b1c9e98774adf8820c96fbc7ae3601231d324a7d5ebd8babe27b6dfac91357ba |
| 188 | url: "https://pub.dev" | 180 | url: "https://pub.dev" |
| 189 | source: hosted | 181 | source: hosted |
| 190 | - version: "6.1.8" | 182 | + version: "6.2.1" |
| 191 | url_launcher_android: | 183 | url_launcher_android: |
| 192 | dependency: transitive | 184 | dependency: transitive |
| 193 | description: | 185 | description: |
| 194 | name: url_launcher_android | 186 | name: url_launcher_android |
| 195 | - sha256: "3e2f6dfd2c7d9cd123296cab8ef66cfc2c1a13f5845f42c7a0f365690a8a7dd1" | 187 | + sha256: "31222ffb0063171b526d3e569079cf1f8b294075ba323443fdc690842bfd4def" |
| 196 | url: "https://pub.dev" | 188 | url: "https://pub.dev" |
| 197 | source: hosted | 189 | source: hosted |
| 198 | - version: "6.0.23" | 190 | + version: "6.2.0" |
| 199 | url_launcher_ios: | 191 | url_launcher_ios: |
| 200 | dependency: transitive | 192 | dependency: transitive |
| 201 | description: | 193 | description: |
| 202 | name: url_launcher_ios | 194 | name: url_launcher_ios |
| 203 | - sha256: bb328b24d3bccc20bdf1024a0990ac4f869d57663660de9c936fb8c043edefe3 | 195 | + sha256: "4ac97281cf60e2e8c5cc703b2b28528f9b50c8f7cebc71df6bdf0845f647268a" |
| 204 | url: "https://pub.dev" | 196 | url: "https://pub.dev" |
| 205 | source: hosted | 197 | source: hosted |
| 206 | - version: "6.0.18" | 198 | + version: "6.2.0" |
| 207 | url_launcher_linux: | 199 | url_launcher_linux: |
| 208 | dependency: transitive | 200 | dependency: transitive |
| 209 | description: | 201 | description: |
| 210 | name: url_launcher_linux | 202 | name: url_launcher_linux |
| 211 | - sha256: "318c42cba924e18180c029be69caf0a1a710191b9ec49bb42b5998fdcccee3cc" | 203 | + sha256: "9f2d390e096fdbe1e6e6256f97851e51afc2d9c423d3432f1d6a02a8a9a8b9fd" |
| 212 | url: "https://pub.dev" | 204 | url: "https://pub.dev" |
| 213 | source: hosted | 205 | source: hosted |
| 214 | - version: "3.0.2" | 206 | + version: "3.1.0" |
| 215 | url_launcher_macos: | 207 | url_launcher_macos: |
| 216 | dependency: transitive | 208 | dependency: transitive |
| 217 | description: | 209 | description: |
| 218 | name: url_launcher_macos | 210 | name: url_launcher_macos |
| 219 | - sha256: "41988b55570df53b3dd2a7fc90c76756a963de6a8c5f8e113330cb35992e2094" | 211 | + sha256: b7244901ea3cf489c5335bdacda07264a6e960b1c1b1a9f91e4bc371d9e68234 |
| 220 | url: "https://pub.dev" | 212 | url: "https://pub.dev" |
| 221 | source: hosted | 213 | source: hosted |
| 222 | - version: "3.0.2" | 214 | + version: "3.1.0" |
| 223 | url_launcher_platform_interface: | 215 | url_launcher_platform_interface: |
| 224 | dependency: transitive | 216 | dependency: transitive |
| 225 | description: | 217 | description: |
| 226 | name: url_launcher_platform_interface | 218 | name: url_launcher_platform_interface |
| 227 | - sha256: "4eae912628763eb48fc214522e58e942fd16ce195407dbf45638239523c759a6" | 219 | + sha256: "980e8d9af422f477be6948bdfb68df8433be71f5743a188968b0c1b887807e50" |
| 228 | url: "https://pub.dev" | 220 | url: "https://pub.dev" |
| 229 | source: hosted | 221 | source: hosted |
| 230 | - version: "2.1.1" | 222 | + version: "2.2.0" |
| 231 | url_launcher_web: | 223 | url_launcher_web: |
| 232 | dependency: transitive | 224 | dependency: transitive |
| 233 | description: | 225 | description: |
| 234 | name: url_launcher_web | 226 | name: url_launcher_web |
| 235 | - sha256: "44d79408ce9f07052095ef1f9a693c258d6373dc3944249374e30eff7219ccb0" | 227 | + sha256: "7fd2f55fe86cea2897b963e864dc01a7eb0719ecc65fcef4c1cc3d686d718bb2" |
| 236 | url: "https://pub.dev" | 228 | url: "https://pub.dev" |
| 237 | source: hosted | 229 | source: hosted |
| 238 | - version: "2.0.14" | 230 | + version: "2.2.0" |
| 239 | url_launcher_windows: | 231 | url_launcher_windows: |
| 240 | dependency: transitive | 232 | dependency: transitive |
| 241 | description: | 233 | description: |
| 242 | name: url_launcher_windows | 234 | name: url_launcher_windows |
| 243 | - sha256: "387e227c4b979034cc52afb11d66b04ed9b288ca1f45beeef39b2ea69e714fa5" | 235 | + sha256: "7754a1ad30ee896b265f8d14078b0513a4dba28d358eabb9d5f339886f4a1adc" |
| 244 | url: "https://pub.dev" | 236 | url: "https://pub.dev" |
| 245 | source: hosted | 237 | source: hosted |
| 246 | - version: "3.0.2" | 238 | + version: "3.1.0" |
| 247 | vector_math: | 239 | vector_math: |
| 248 | dependency: transitive | 240 | dependency: transitive |
| 249 | description: | 241 | description: |
| @@ -252,6 +244,14 @@ packages: | @@ -252,6 +244,14 @@ packages: | ||
| 252 | url: "https://pub.dev" | 244 | url: "https://pub.dev" |
| 253 | source: hosted | 245 | source: hosted |
| 254 | version: "2.1.4" | 246 | version: "2.1.4" |
| 247 | + web: | ||
| 248 | + dependency: transitive | ||
| 249 | + description: | ||
| 250 | + name: web | ||
| 251 | + sha256: dc8ccd225a2005c1be616fe02951e2e342092edf968cf0844220383757ef8f10 | ||
| 252 | + url: "https://pub.dev" | ||
| 253 | + source: hosted | ||
| 254 | + version: "0.1.4-beta" | ||
| 255 | sdks: | 255 | sdks: |
| 256 | - dart: ">=2.18.0 <4.0.0" | ||
| 257 | - flutter: ">=3.7.0" | 256 | + dart: ">=3.1.0 <4.0.0" |
| 257 | + flutter: ">=3.13.0" |
| 1 | import 'dart:async'; | 1 | import 'dart:async'; |
| 2 | 2 | ||
| 3 | -import 'package:flutter/material.dart' hide ModalBottomSheetRoute; | 3 | +import 'package:flutter/material.dart'; |
| 4 | import 'package:flutter/services.dart'; | 4 | import 'package:flutter/services.dart'; |
| 5 | +import 'package:modal_bottom_sheet/modal_bottom_sheet.dart'; | ||
| 5 | 6 | ||
| 6 | const Radius kDefaultBarTopRadius = Radius.circular(15); | 7 | const Radius kDefaultBarTopRadius = Radius.circular(15); |
| 7 | 8 | ||
| @@ -96,7 +97,7 @@ Future<T?> showBarModalBottomSheet<T>({ | @@ -96,7 +97,7 @@ Future<T?> showBarModalBottomSheet<T>({ | ||
| 96 | assert(debugCheckHasMediaQuery(context)); | 97 | assert(debugCheckHasMediaQuery(context)); |
| 97 | assert(debugCheckHasMaterialLocalizations(context)); | 98 | assert(debugCheckHasMaterialLocalizations(context)); |
| 98 | final result = await Navigator.of(context, rootNavigator: useRootNavigator) | 99 | final result = await Navigator.of(context, rootNavigator: useRootNavigator) |
| 99 | - .push(ModalBottomSheetRoute<T>( | 100 | + .push(ModalSheetRoute<T>( |
| 100 | builder: builder, | 101 | builder: builder, |
| 101 | bounce: bounce, | 102 | bounce: bounce, |
| 102 | closeProgressThreshold: closeProgressThreshold, | 103 | closeProgressThreshold: closeProgressThreshold, |
| @@ -26,7 +26,7 @@ Future<T?> showMaterialModalBottomSheet<T>({ | @@ -26,7 +26,7 @@ Future<T?> showMaterialModalBottomSheet<T>({ | ||
| 26 | assert(debugCheckHasMediaQuery(context)); | 26 | assert(debugCheckHasMediaQuery(context)); |
| 27 | assert(debugCheckHasMaterialLocalizations(context)); | 27 | assert(debugCheckHasMaterialLocalizations(context)); |
| 28 | final result = await Navigator.of(context, rootNavigator: useRootNavigator) | 28 | final result = await Navigator.of(context, rootNavigator: useRootNavigator) |
| 29 | - .push(ModalBottomSheetRoute<T>( | 29 | + .push(ModalSheetRoute<T>( |
| 30 | builder: builder, | 30 | builder: builder, |
| 31 | closeProgressThreshold: closeProgressThreshold, | 31 | closeProgressThreshold: closeProgressThreshold, |
| 32 | containerBuilder: _materialContainerBuilder( | 32 | containerBuilder: _materialContainerBuilder( |
| @@ -20,7 +20,7 @@ class MaterialWithModalsPageRoute<T> extends MaterialPageRoute<T> { | @@ -20,7 +20,7 @@ class MaterialWithModalsPageRoute<T> extends MaterialPageRoute<T> { | ||
| 20 | builder: builder, | 20 | builder: builder, |
| 21 | maintainState: maintainState); | 21 | maintainState: maintainState); |
| 22 | 22 | ||
| 23 | - ModalBottomSheetRoute? _nextModalRoute; | 23 | + ModalSheetRoute? _nextModalRoute; |
| 24 | 24 | ||
| 25 | @override | 25 | @override |
| 26 | bool canTransitionTo(TransitionRoute<dynamic> nextRoute) { | 26 | bool canTransitionTo(TransitionRoute<dynamic> nextRoute) { |
| @@ -29,12 +29,12 @@ class MaterialWithModalsPageRoute<T> extends MaterialPageRoute<T> { | @@ -29,12 +29,12 @@ class MaterialWithModalsPageRoute<T> extends MaterialPageRoute<T> { | ||
| 29 | (nextRoute is CupertinoPageRoute && !nextRoute.fullscreenDialog) || | 29 | (nextRoute is CupertinoPageRoute && !nextRoute.fullscreenDialog) || |
| 30 | (nextRoute is MaterialWithModalsPageRoute && | 30 | (nextRoute is MaterialWithModalsPageRoute && |
| 31 | !nextRoute.fullscreenDialog) || | 31 | !nextRoute.fullscreenDialog) || |
| 32 | - (nextRoute is ModalBottomSheetRoute); | 32 | + (nextRoute is ModalSheetRoute); |
| 33 | } | 33 | } |
| 34 | 34 | ||
| 35 | @override | 35 | @override |
| 36 | void didChangeNext(Route? nextRoute) { | 36 | void didChangeNext(Route? nextRoute) { |
| 37 | - if (nextRoute is ModalBottomSheetRoute) { | 37 | + if (nextRoute is ModalSheetRoute) { |
| 38 | _nextModalRoute = nextRoute; | 38 | _nextModalRoute = nextRoute; |
| 39 | } | 39 | } |
| 40 | 40 | ||
| @@ -42,11 +42,6 @@ class MaterialWithModalsPageRoute<T> extends MaterialPageRoute<T> { | @@ -42,11 +42,6 @@ class MaterialWithModalsPageRoute<T> extends MaterialPageRoute<T> { | ||
| 42 | } | 42 | } |
| 43 | 43 | ||
| 44 | @override | 44 | @override |
| 45 | - void didPopNext(Route nextRoute) { | ||
| 46 | - super.didPopNext(nextRoute); | ||
| 47 | - } | ||
| 48 | - | ||
| 49 | - @override | ||
| 50 | bool didPop(T? result) { | 45 | bool didPop(T? result) { |
| 51 | _nextModalRoute = null; | 46 | _nextModalRoute = null; |
| 52 | return super.didPop(result); | 47 | return super.didPop(result); |
| @@ -5,10 +5,10 @@ packages: | @@ -5,10 +5,10 @@ packages: | ||
| 5 | dependency: transitive | 5 | dependency: transitive |
| 6 | description: | 6 | description: |
| 7 | name: async | 7 | name: async |
| 8 | - sha256: bfe67ef28df125b7dddcea62755991f807aa39a2492a23e1550161692950bbe0 | 8 | + sha256: "947bfcf187f74dbc5e146c9eb9c0f10c9f8b30743e341481c1e2ed3ecc18c20c" |
| 9 | url: "https://pub.dev" | 9 | url: "https://pub.dev" |
| 10 | source: hosted | 10 | source: hosted |
| 11 | - version: "2.10.0" | 11 | + version: "2.11.0" |
| 12 | boolean_selector: | 12 | boolean_selector: |
| 13 | dependency: transitive | 13 | dependency: transitive |
| 14 | description: | 14 | description: |
| @@ -21,10 +21,10 @@ packages: | @@ -21,10 +21,10 @@ packages: | ||
| 21 | dependency: transitive | 21 | dependency: transitive |
| 22 | description: | 22 | description: |
| 23 | name: characters | 23 | name: characters |
| 24 | - sha256: e6a326c8af69605aec75ed6c187d06b349707a27fbff8222ca9cc2cff167975c | 24 | + sha256: "04a925763edad70e8443c99234dc3328f442e811f1d8fd1a72f1c8ad0f69a605" |
| 25 | url: "https://pub.dev" | 25 | url: "https://pub.dev" |
| 26 | source: hosted | 26 | source: hosted |
| 27 | - version: "1.2.1" | 27 | + version: "1.3.0" |
| 28 | clock: | 28 | clock: |
| 29 | dependency: transitive | 29 | dependency: transitive |
| 30 | description: | 30 | description: |
| @@ -37,10 +37,10 @@ packages: | @@ -37,10 +37,10 @@ packages: | ||
| 37 | dependency: transitive | 37 | dependency: transitive |
| 38 | description: | 38 | description: |
| 39 | name: collection | 39 | name: collection |
| 40 | - sha256: cfc915e6923fe5ce6e153b0723c753045de46de1b4d63771530504004a45fae0 | 40 | + sha256: f092b211a4319e98e5ff58223576de6c2803db36221657b46c82574721240687 |
| 41 | url: "https://pub.dev" | 41 | url: "https://pub.dev" |
| 42 | source: hosted | 42 | source: hosted |
| 43 | - version: "1.17.0" | 43 | + version: "1.17.2" |
| 44 | fake_async: | 44 | fake_async: |
| 45 | dependency: transitive | 45 | dependency: transitive |
| 46 | description: | 46 | description: |
| @@ -59,54 +59,46 @@ packages: | @@ -59,54 +59,46 @@ packages: | ||
| 59 | description: flutter | 59 | description: flutter |
| 60 | source: sdk | 60 | source: sdk |
| 61 | version: "0.0.0" | 61 | version: "0.0.0" |
| 62 | - js: | ||
| 63 | - dependency: transitive | ||
| 64 | - description: | ||
| 65 | - name: js | ||
| 66 | - sha256: "5528c2f391ededb7775ec1daa69e65a2d61276f7552de2b5f7b8d34ee9fd4ab7" | ||
| 67 | - url: "https://pub.dev" | ||
| 68 | - source: hosted | ||
| 69 | - version: "0.6.5" | ||
| 70 | lints: | 62 | lints: |
| 71 | dependency: "direct dev" | 63 | dependency: "direct dev" |
| 72 | description: | 64 | description: |
| 73 | name: lints | 65 | name: lints |
| 74 | - sha256: "5e4a9cd06d447758280a8ac2405101e0e2094d2a1dbdd3756aec3fe7775ba593" | 66 | + sha256: "0a217c6c989d21039f1498c3ed9f3ed71b354e69873f13a8dfc3c9fe76f1b452" |
| 75 | url: "https://pub.dev" | 67 | url: "https://pub.dev" |
| 76 | source: hosted | 68 | source: hosted |
| 77 | - version: "2.0.1" | 69 | + version: "2.1.1" |
| 78 | matcher: | 70 | matcher: |
| 79 | dependency: transitive | 71 | dependency: transitive |
| 80 | description: | 72 | description: |
| 81 | name: matcher | 73 | name: matcher |
| 82 | - sha256: "16db949ceee371e9b99d22f88fa3a73c4e59fd0afed0bd25fc336eb76c198b72" | 74 | + sha256: "1803e76e6653768d64ed8ff2e1e67bea3ad4b923eb5c56a295c3e634bad5960e" |
| 83 | url: "https://pub.dev" | 75 | url: "https://pub.dev" |
| 84 | source: hosted | 76 | source: hosted |
| 85 | - version: "0.12.13" | 77 | + version: "0.12.16" |
| 86 | material_color_utilities: | 78 | material_color_utilities: |
| 87 | dependency: transitive | 79 | dependency: transitive |
| 88 | description: | 80 | description: |
| 89 | name: material_color_utilities | 81 | name: material_color_utilities |
| 90 | - sha256: d92141dc6fe1dad30722f9aa826c7fbc896d021d792f80678280601aff8cf724 | 82 | + sha256: "9528f2f296073ff54cb9fee677df673ace1218163c3bc7628093e7eed5203d41" |
| 91 | url: "https://pub.dev" | 83 | url: "https://pub.dev" |
| 92 | source: hosted | 84 | source: hosted |
| 93 | - version: "0.2.0" | 85 | + version: "0.5.0" |
| 94 | meta: | 86 | meta: |
| 95 | dependency: transitive | 87 | dependency: transitive |
| 96 | description: | 88 | description: |
| 97 | name: meta | 89 | name: meta |
| 98 | - sha256: "6c268b42ed578a53088d834796959e4a1814b5e9e164f147f580a386e5decf42" | 90 | + sha256: "3c74dbf8763d36539f114c799d8a2d87343b5067e9d796ca22b5eb8437090ee3" |
| 99 | url: "https://pub.dev" | 91 | url: "https://pub.dev" |
| 100 | source: hosted | 92 | source: hosted |
| 101 | - version: "1.8.0" | 93 | + version: "1.9.1" |
| 102 | path: | 94 | path: |
| 103 | dependency: transitive | 95 | dependency: transitive |
| 104 | description: | 96 | description: |
| 105 | name: path | 97 | name: path |
| 106 | - sha256: db9d4f58c908a4ba5953fcee2ae317c94889433e5024c27ce74a37f94267945b | 98 | + sha256: "8829d8a55c13fc0e37127c29fedf290c102f4e40ae94ada574091fe0ff96c917" |
| 107 | url: "https://pub.dev" | 99 | url: "https://pub.dev" |
| 108 | source: hosted | 100 | source: hosted |
| 109 | - version: "1.8.2" | 101 | + version: "1.8.3" |
| 110 | sky_engine: | 102 | sky_engine: |
| 111 | dependency: transitive | 103 | dependency: transitive |
| 112 | description: flutter | 104 | description: flutter |
| @@ -116,10 +108,10 @@ packages: | @@ -116,10 +108,10 @@ packages: | ||
| 116 | dependency: transitive | 108 | dependency: transitive |
| 117 | description: | 109 | description: |
| 118 | name: source_span | 110 | name: source_span |
| 119 | - sha256: dd904f795d4b4f3b870833847c461801f6750a9fa8e61ea5ac53f9422b31f250 | 111 | + sha256: "53e943d4206a5e30df338fd4c6e7a077e02254531b138a15aec3bd143c1a8b3c" |
| 120 | url: "https://pub.dev" | 112 | url: "https://pub.dev" |
| 121 | source: hosted | 113 | source: hosted |
| 122 | - version: "1.9.1" | 114 | + version: "1.10.0" |
| 123 | stack_trace: | 115 | stack_trace: |
| 124 | dependency: transitive | 116 | dependency: transitive |
| 125 | description: | 117 | description: |
| @@ -156,10 +148,10 @@ packages: | @@ -156,10 +148,10 @@ packages: | ||
| 156 | dependency: transitive | 148 | dependency: transitive |
| 157 | description: | 149 | description: |
| 158 | name: test_api | 150 | name: test_api |
| 159 | - sha256: ad540f65f92caa91bf21dfc8ffb8c589d6e4dc0c2267818b4cc2792857706206 | 151 | + sha256: "75760ffd7786fffdfb9597c35c5b27eaeec82be8edfb6d71d32651128ed7aab8" |
| 160 | url: "https://pub.dev" | 152 | url: "https://pub.dev" |
| 161 | source: hosted | 153 | source: hosted |
| 162 | - version: "0.4.16" | 154 | + version: "0.6.0" |
| 163 | vector_math: | 155 | vector_math: |
| 164 | dependency: transitive | 156 | dependency: transitive |
| 165 | description: | 157 | description: |
| @@ -168,6 +160,13 @@ packages: | @@ -168,6 +160,13 @@ packages: | ||
| 168 | url: "https://pub.dev" | 160 | url: "https://pub.dev" |
| 169 | source: hosted | 161 | source: hosted |
| 170 | version: "2.1.4" | 162 | version: "2.1.4" |
| 163 | + web: | ||
| 164 | + dependency: transitive | ||
| 165 | + description: | ||
| 166 | + name: web | ||
| 167 | + sha256: dc8ccd225a2005c1be616fe02951e2e342092edf968cf0844220383757ef8f10 | ||
| 168 | + url: "https://pub.dev" | ||
| 169 | + source: hosted | ||
| 170 | + version: "0.1.4-beta" | ||
| 171 | sdks: | 171 | sdks: |
| 172 | - dart: ">=2.18.0 <4.0.0" | ||
| 173 | - flutter: ">=3.7.0" | 172 | + dart: ">=3.1.0-185.0.dev <4.0.0" |
| 1 | name: modal_bottom_sheet | 1 | name: modal_bottom_sheet |
| 2 | description: 'Create awesome and powerful modal bottom sheets. Material, Cupertino iOS 13 or create your own style' | 2 | description: 'Create awesome and powerful modal bottom sheets. Material, Cupertino iOS 13 or create your own style' |
| 3 | -version: 3.0.0-pre | 3 | +version: 3.0.1 |
| 4 | homepage: 'https://github.com/jamesblasco/modal_bottom_sheet' | 4 | homepage: 'https://github.com/jamesblasco/modal_bottom_sheet' |
| 5 | 5 | ||
| 6 | environment: | 6 | environment: |
| 7 | sdk: ">=2.17.0 <3.0.0" | 7 | sdk: ">=2.17.0 <3.0.0" |
| 8 | - flutter: ">=3.7.0" | ||
| 9 | 8 | ||
| 10 | dependencies: | 9 | dependencies: |
| 11 | flutter: | 10 | flutter: |
| @@ -47,7 +47,7 @@ Stack( | @@ -47,7 +47,7 @@ Stack( | ||
| 47 | ``` | 47 | ``` |
| 48 | 48 | ||
| 49 | 49 | ||
| 50 | -The widget has several parameters that allow fully costumization of the sheet | 50 | +The widget has several parameters that allow fully customization of the sheet |
| 51 | 51 | ||
| 52 | #### Add an initial position | 52 | #### Add an initial position |
| 53 | 53 | ||
| @@ -60,7 +60,7 @@ Sheet( | @@ -60,7 +60,7 @@ Sheet( | ||
| 60 | ) | 60 | ) |
| 61 | ``` | 61 | ``` |
| 62 | 62 | ||
| 63 | -#### Clamp the sheet between a min and maximun values | 63 | +#### Clamp the sheet between a min and maximum values |
| 64 | 64 | ||
| 65 | You can set a `minExtent` and `maxExtent` to limit the position of the Sheet between those values | 65 | You can set a `minExtent` and `maxExtent` to limit the position of the Sheet between those values |
| 66 | 66 | ||
| @@ -89,9 +89,9 @@ Sheet( | @@ -89,9 +89,9 @@ Sheet( | ||
| 89 | 89 | ||
| 90 | #### Fit modes | 90 | #### Fit modes |
| 91 | 91 | ||
| 92 | -By default the sheet height will be the minimun between the max available height and the one recommended by the child. | 92 | +By default the sheet height will be the minimum between the max available height and the one recommended by the child. |
| 93 | 93 | ||
| 94 | -It is possible to force the sheet child to be the maxium size available by setting `SheetFit.expand` | 94 | +It is possible to force the sheet child to be the maximum size available by setting `SheetFit.expand` |
| 95 | 95 | ||
| 96 | ```dart | 96 | ```dart |
| 97 | Sheet( | 97 | Sheet( |
| @@ -104,7 +104,7 @@ Sheet( | @@ -104,7 +104,7 @@ Sheet( | ||
| 104 | #### Resizable | 104 | #### Resizable |
| 105 | 105 | ||
| 106 | By default the sheet has a fixed sized and it is vertically translated according to the user drag. | 106 | By default the sheet has a fixed sized and it is vertically translated according to the user drag. |
| 107 | -It is posible to make the sheet change the height of the child by setting `resize: true` | 107 | +It is possible to make the sheet change the height of the child by setting `resize: true` |
| 108 | This will force the child to fit the available visual space. | 108 | This will force the child to fit the available visual space. |
| 109 | 109 | ||
| 110 | ```dart | 110 | ```dart |
| @@ -131,7 +131,7 @@ Sheet( | @@ -131,7 +131,7 @@ Sheet( | ||
| 131 | 131 | ||
| 132 | #### Control the position of the sheet | 132 | #### Control the position of the sheet |
| 133 | 133 | ||
| 134 | -It is possible to pass a `SheetController` to control programatically the position of the sheet. | 134 | +It is possible to pass a `SheetController` to control programmatically the position of the sheet. |
| 135 | 135 | ||
| 136 | ```dart | 136 | ```dart |
| 137 | SheetController controller = SheetController(); | 137 | SheetController controller = SheetController(); |
| @@ -3,7 +3,7 @@ | @@ -3,7 +3,7 @@ | ||
| 3 | archiveVersion = 1; | 3 | archiveVersion = 1; |
| 4 | classes = { | 4 | classes = { |
| 5 | }; | 5 | }; |
| 6 | - objectVersion = 50; | 6 | + objectVersion = 54; |
| 7 | objects = { | 7 | objects = { |
| 8 | 8 | ||
| 9 | /* Begin PBXBuildFile section */ | 9 | /* Begin PBXBuildFile section */ |
| @@ -171,10 +171,12 @@ | @@ -171,10 +171,12 @@ | ||
| 171 | /* Begin PBXShellScriptBuildPhase section */ | 171 | /* Begin PBXShellScriptBuildPhase section */ |
| 172 | 3B06AD1E1E4923F5004D2608 /* Thin Binary */ = { | 172 | 3B06AD1E1E4923F5004D2608 /* Thin Binary */ = { |
| 173 | isa = PBXShellScriptBuildPhase; | 173 | isa = PBXShellScriptBuildPhase; |
| 174 | + alwaysOutOfDate = 1; | ||
| 174 | buildActionMask = 2147483647; | 175 | buildActionMask = 2147483647; |
| 175 | files = ( | 176 | files = ( |
| 176 | ); | 177 | ); |
| 177 | inputPaths = ( | 178 | inputPaths = ( |
| 179 | + "${TARGET_BUILD_DIR}/${INFOPLIST_PATH}", | ||
| 178 | ); | 180 | ); |
| 179 | name = "Thin Binary"; | 181 | name = "Thin Binary"; |
| 180 | outputPaths = ( | 182 | outputPaths = ( |
| @@ -185,6 +187,7 @@ | @@ -185,6 +187,7 @@ | ||
| 185 | }; | 187 | }; |
| 186 | 9740EEB61CF901F6004384FC /* Run Script */ = { | 188 | 9740EEB61CF901F6004384FC /* Run Script */ = { |
| 187 | isa = PBXShellScriptBuildPhase; | 189 | isa = PBXShellScriptBuildPhase; |
| 190 | + alwaysOutOfDate = 1; | ||
| 188 | buildActionMask = 2147483647; | 191 | buildActionMask = 2147483647; |
| 189 | files = ( | 192 | files = ( |
| 190 | ); | 193 | ); |
| @@ -288,7 +291,7 @@ | @@ -288,7 +291,7 @@ | ||
| 288 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; | 291 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; |
| 289 | CLANG_ENABLE_MODULES = YES; | 292 | CLANG_ENABLE_MODULES = YES; |
| 290 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; | 293 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; |
| 291 | - DEVELOPMENT_TEAM = 8734Y6QF3F; | 294 | + DEVELOPMENT_TEAM = 87RQQPQ85J; |
| 292 | ENABLE_BITCODE = NO; | 295 | ENABLE_BITCODE = NO; |
| 293 | FRAMEWORK_SEARCH_PATHS = ( | 296 | FRAMEWORK_SEARCH_PATHS = ( |
| 294 | "$(inherited)", | 297 | "$(inherited)", |
| @@ -425,7 +428,7 @@ | @@ -425,7 +428,7 @@ | ||
| 425 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; | 428 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; |
| 426 | CLANG_ENABLE_MODULES = YES; | 429 | CLANG_ENABLE_MODULES = YES; |
| 427 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; | 430 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; |
| 428 | - DEVELOPMENT_TEAM = 8734Y6QF3F; | 431 | + DEVELOPMENT_TEAM = 87RQQPQ85J; |
| 429 | ENABLE_BITCODE = NO; | 432 | ENABLE_BITCODE = NO; |
| 430 | FRAMEWORK_SEARCH_PATHS = ( | 433 | FRAMEWORK_SEARCH_PATHS = ( |
| 431 | "$(inherited)", | 434 | "$(inherited)", |
| @@ -456,7 +459,7 @@ | @@ -456,7 +459,7 @@ | ||
| 456 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; | 459 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; |
| 457 | CLANG_ENABLE_MODULES = YES; | 460 | CLANG_ENABLE_MODULES = YES; |
| 458 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; | 461 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; |
| 459 | - DEVELOPMENT_TEAM = 8734Y6QF3F; | 462 | + DEVELOPMENT_TEAM = 87RQQPQ85J; |
| 460 | ENABLE_BITCODE = NO; | 463 | ENABLE_BITCODE = NO; |
| 461 | FRAMEWORK_SEARCH_PATHS = ( | 464 | FRAMEWORK_SEARCH_PATHS = ( |
| 462 | "$(inherited)", | 465 | "$(inherited)", |
| @@ -5,28 +5,112 @@ class NestedScrollModal extends StatelessWidget { | @@ -5,28 +5,112 @@ class NestedScrollModal extends StatelessWidget { | ||
| 5 | 5 | ||
| 6 | @override | 6 | @override |
| 7 | Widget build(BuildContext context) { | 7 | Widget build(BuildContext context) { |
| 8 | - return NestedScrollView( | ||
| 9 | - physics: const ClampingScrollPhysics(), | ||
| 10 | - controller: PrimaryScrollController.of(context), | 8 | + final List<String> tabs = <String>['Tab 1', 'Tab 2']; |
| 9 | + return DefaultTabController( | ||
| 10 | + length: tabs.length, // This is the number of tabs. | ||
| 11 | + child: Scaffold( | ||
| 12 | + body: NestedScrollView( | ||
| 11 | headerSliverBuilder: (BuildContext context, bool innerBoxIsScrolled) { | 13 | headerSliverBuilder: (BuildContext context, bool innerBoxIsScrolled) { |
| 14 | + // These are the slivers that show up in the "outer" scroll view. | ||
| 12 | return <Widget>[ | 15 | return <Widget>[ |
| 13 | - SliverList( | ||
| 14 | - delegate: SliverChildListDelegate( | ||
| 15 | - <Widget>[ | ||
| 16 | - Container(height: 300, color: Colors.blue), | ||
| 17 | - ], | 16 | + SliverOverlapAbsorber( |
| 17 | + // This widget takes the overlapping behavior of the SliverAppBar, | ||
| 18 | + // and redirects it to the SliverOverlapInjector below. If it is | ||
| 19 | + // missing, then it is possible for the nested "inner" scroll view | ||
| 20 | + // below to end up under the SliverAppBar even when the inner | ||
| 21 | + // scroll view thinks it has not been scrolled. | ||
| 22 | + // This is not necessary if the "headerSliverBuilder" only builds | ||
| 23 | + // widgets that do not overlap the next sliver. | ||
| 24 | + handle: | ||
| 25 | + NestedScrollView.sliverOverlapAbsorberHandleFor(context), | ||
| 26 | + sliver: SliverAppBar( | ||
| 27 | + title: | ||
| 28 | + const Text('Books'), // This is the title in the app bar. | ||
| 29 | + pinned: true, | ||
| 30 | + expandedHeight: 150.0, | ||
| 31 | + // The "forceElevated" property causes the SliverAppBar to show | ||
| 32 | + // a shadow. The "innerBoxIsScrolled" parameter is true when the | ||
| 33 | + // inner scroll view is scrolled beyond its "zero" point, i.e. | ||
| 34 | + // when it appears to be scrolled below the SliverAppBar. | ||
| 35 | + // Without this, there are cases where the shadow would appear | ||
| 36 | + // or not appear inappropriately, because the SliverAppBar is | ||
| 37 | + // not actually aware of the precise position of the inner | ||
| 38 | + // scroll views. | ||
| 39 | + forceElevated: innerBoxIsScrolled, | ||
| 40 | + bottom: TabBar( | ||
| 41 | + // These are the widgets to put in each tab in the tab bar. | ||
| 42 | + tabs: tabs.map((String name) => Tab(text: name)).toList(), | ||
| 43 | + ), | ||
| 18 | ), | 44 | ), |
| 19 | ), | 45 | ), |
| 20 | ]; | 46 | ]; |
| 21 | }, | 47 | }, |
| 22 | - body: ListView.builder( | ||
| 23 | - itemBuilder: (BuildContext context, int index) { | ||
| 24 | - return Container( | ||
| 25 | - height: 100, | ||
| 26 | - color: index.isOdd ? Colors.green : Colors.orange, | 48 | + body: TabBarView( |
| 49 | + // These are the contents of the tab views, below the tabs. | ||
| 50 | + children: tabs.map((String name) { | ||
| 51 | + return SafeArea( | ||
| 52 | + top: false, | ||
| 53 | + bottom: false, | ||
| 54 | + child: Builder( | ||
| 55 | + // This Builder is needed to provide a BuildContext that is | ||
| 56 | + // "inside" the NestedScrollView, so that | ||
| 57 | + // sliverOverlapAbsorberHandleFor() can find the | ||
| 58 | + // NestedScrollView. | ||
| 59 | + builder: (BuildContext context) { | ||
| 60 | + return CustomScrollView( | ||
| 61 | + controller: PrimaryScrollController.of(context), | ||
| 62 | + // The "controller" and "primary" members should be left | ||
| 63 | + // unset, so that the NestedScrollView can control this | ||
| 64 | + // inner scroll view. | ||
| 65 | + // If the "controller" property is set, then this scroll | ||
| 66 | + // view will not be associated with the NestedScrollView. | ||
| 67 | + // The PageStorageKey should be unique to this ScrollView; | ||
| 68 | + // it allows the list to remember its scroll position when | ||
| 69 | + // the tab view is not on the screen. | ||
| 70 | + key: PageStorageKey<String>(name), | ||
| 71 | + slivers: <Widget>[ | ||
| 72 | + SliverOverlapInjector( | ||
| 73 | + // This is the flip side of the SliverOverlapAbsorber | ||
| 74 | + // above. | ||
| 75 | + handle: | ||
| 76 | + NestedScrollView.sliverOverlapAbsorberHandleFor( | ||
| 77 | + context), | ||
| 78 | + ), | ||
| 79 | + SliverPadding( | ||
| 80 | + padding: const EdgeInsets.all(8.0), | ||
| 81 | + // In this example, the inner scroll view has | ||
| 82 | + // fixed-height list items, hence the use of | ||
| 83 | + // SliverFixedExtentList. However, one could use any | ||
| 84 | + // sliver widget here, e.g. SliverList or SliverGrid. | ||
| 85 | + sliver: SliverFixedExtentList( | ||
| 86 | + // The items in this example are fixed to 48 pixels | ||
| 87 | + // high. This matches the Material Design spec for | ||
| 88 | + // ListTile widgets. | ||
| 89 | + itemExtent: 48.0, | ||
| 90 | + delegate: SliverChildBuilderDelegate( | ||
| 91 | + (BuildContext context, int index) { | ||
| 92 | + // This builder is called for each child. | ||
| 93 | + // In this example, we just number each list item. | ||
| 94 | + return ListTile( | ||
| 95 | + title: Text('Item $index'), | ||
| 27 | ); | 96 | ); |
| 28 | }, | 97 | }, |
| 29 | - itemCount: 12, | 98 | + // The childCount of the SliverChildBuilderDelegate |
| 99 | + // specifies how many children this inner list | ||
| 100 | + // has. In this example, each tab has a list of | ||
| 101 | + // exactly 30 items, but this is arbitrary. | ||
| 102 | + childCount: 30, | ||
| 103 | + ), | ||
| 104 | + ), | ||
| 105 | + ), | ||
| 106 | + ], | ||
| 107 | + ); | ||
| 108 | + }, | ||
| 109 | + ), | ||
| 110 | + ); | ||
| 111 | + }).toList(), | ||
| 112 | + ), | ||
| 113 | + ), | ||
| 30 | ), | 114 | ), |
| 31 | ); | 115 | ); |
| 32 | } | 116 | } |
| @@ -66,7 +66,7 @@ class _GoRouterBooksAppState extends State<GoRouterBooksApp> { | @@ -66,7 +66,7 @@ class _GoRouterBooksAppState extends State<GoRouterBooksApp> { | ||
| 66 | name: 'book', | 66 | name: 'book', |
| 67 | path: 'book/:bid', | 67 | path: 'book/:bid', |
| 68 | pageBuilder: (BuildContext context, GoRouterState state) { | 68 | pageBuilder: (BuildContext context, GoRouterState state) { |
| 69 | - final String id = state.params['bid']!; | 69 | + final String id = state.pathParameters['bid']!; |
| 70 | final Book? book = | 70 | final Book? book = |
| 71 | books.firstWhereOrNull((Book b) => b.id == id); | 71 | books.firstWhereOrNull((Book b) => b.id == id); |
| 72 | return CupertinoSheetPage<void>( | 72 | return CupertinoSheetPage<void>( |
| @@ -76,8 +76,8 @@ class _GoRouterBooksAppState extends State<GoRouterBooksApp> { | @@ -76,8 +76,8 @@ class _GoRouterBooksAppState extends State<GoRouterBooksApp> { | ||
| 76 | ), | 76 | ), |
| 77 | ); | 77 | ); |
| 78 | }, | 78 | }, |
| 79 | - redirect: (GoRouterState state) { | ||
| 80 | - final String id = state.params['bid']!; | 79 | + redirect: (context, state) { |
| 80 | + final String id = state.pathParameters['bid']!; | ||
| 81 | final Book? book = | 81 | final Book? book = |
| 82 | books.firstWhereOrNull((Book b) => b.id == id); | 82 | books.firstWhereOrNull((Book b) => b.id == id); |
| 83 | if (book == null) { | 83 | if (book == null) { |
| @@ -17,6 +17,7 @@ import 'package:flutter/material.dart'; | @@ -17,6 +17,7 @@ import 'package:flutter/material.dart'; | ||
| 17 | import 'package:sheet/route.dart'; | 17 | import 'package:sheet/route.dart'; |
| 18 | import 'package:sheet/sheet.dart'; | 18 | import 'package:sheet/sheet.dart'; |
| 19 | 19 | ||
| 20 | +import 'examples/route/examples/modal_with_nested_scroll.dart'; | ||
| 20 | import 'examples/route/navigation/go_router.dart'; | 21 | import 'examples/route/navigation/go_router.dart'; |
| 21 | 22 | ||
| 22 | class RouteExamplePage extends StatelessWidget { | 23 | class RouteExamplePage extends StatelessWidget { |
| @@ -251,15 +252,14 @@ class RouteExamplePage extends StatelessWidget { | @@ -251,15 +252,14 @@ class RouteExamplePage extends StatelessWidget { | ||
| 251 | ), | 252 | ), |
| 252 | ), | 253 | ), |
| 253 | 254 | ||
| 254 | - // TODO(jaime): It does not work for nested scroll yet | ||
| 255 | - // ListTile( | ||
| 256 | - // title: Text('Modal with Nested Scroll'), | ||
| 257 | - // onTap: () => Navigator.of(context).push( | ||
| 258 | - // CupertinoSheetRoute<void>( | ||
| 259 | - // builder: (context) => NestedScrollModal(), | ||
| 260 | - // ), | ||
| 261 | - // ), | ||
| 262 | - // ), | 255 | + ListTile( |
| 256 | + title: Text('Modal with Nested Scroll'), | ||
| 257 | + onTap: () => Navigator.of(context).push( | ||
| 258 | + CupertinoSheetRoute<void>( | ||
| 259 | + builder: (context) => NestedScrollModal(), | ||
| 260 | + ), | ||
| 261 | + ), | ||
| 262 | + ), | ||
| 263 | ListTile( | 263 | ListTile( |
| 264 | title: const Text('Modal with PageView'), | 264 | title: const Text('Modal with PageView'), |
| 265 | onTap: () => Navigator.of(context).push( | 265 | onTap: () => Navigator.of(context).push( |
| @@ -3,7 +3,7 @@ | @@ -3,7 +3,7 @@ | ||
| 3 | archiveVersion = 1; | 3 | archiveVersion = 1; |
| 4 | classes = { | 4 | classes = { |
| 5 | }; | 5 | }; |
| 6 | - objectVersion = 51; | 6 | + objectVersion = 54; |
| 7 | objects = { | 7 | objects = { |
| 8 | 8 | ||
| 9 | /* Begin PBXAggregateTarget section */ | 9 | /* Begin PBXAggregateTarget section */ |
| @@ -182,7 +182,7 @@ | @@ -182,7 +182,7 @@ | ||
| 182 | isa = PBXProject; | 182 | isa = PBXProject; |
| 183 | attributes = { | 183 | attributes = { |
| 184 | LastSwiftUpdateCheck = 0920; | 184 | LastSwiftUpdateCheck = 0920; |
| 185 | - LastUpgradeCheck = 0930; | 185 | + LastUpgradeCheck = 1300; |
| 186 | ORGANIZATIONNAME = "The Flutter Authors"; | 186 | ORGANIZATIONNAME = "The Flutter Authors"; |
| 187 | TargetAttributes = { | 187 | TargetAttributes = { |
| 188 | 33CC10EC2044A3C60003C045 = { | 188 | 33CC10EC2044A3C60003C045 = { |
| @@ -235,6 +235,7 @@ | @@ -235,6 +235,7 @@ | ||
| 235 | /* Begin PBXShellScriptBuildPhase section */ | 235 | /* Begin PBXShellScriptBuildPhase section */ |
| 236 | 3399D490228B24CF009A79C7 /* ShellScript */ = { | 236 | 3399D490228B24CF009A79C7 /* ShellScript */ = { |
| 237 | isa = PBXShellScriptBuildPhase; | 237 | isa = PBXShellScriptBuildPhase; |
| 238 | + alwaysOutOfDate = 1; | ||
| 238 | buildActionMask = 2147483647; | 239 | buildActionMask = 2147483647; |
| 239 | files = ( | 240 | files = ( |
| 240 | ); | 241 | ); |
| @@ -344,7 +345,7 @@ | @@ -344,7 +345,7 @@ | ||
| 344 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; | 345 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; |
| 345 | GCC_WARN_UNUSED_FUNCTION = YES; | 346 | GCC_WARN_UNUSED_FUNCTION = YES; |
| 346 | GCC_WARN_UNUSED_VARIABLE = YES; | 347 | GCC_WARN_UNUSED_VARIABLE = YES; |
| 347 | - MACOSX_DEPLOYMENT_TARGET = 10.11; | 348 | + MACOSX_DEPLOYMENT_TARGET = 10.14; |
| 348 | MTL_ENABLE_DEBUG_INFO = NO; | 349 | MTL_ENABLE_DEBUG_INFO = NO; |
| 349 | SDKROOT = macosx; | 350 | SDKROOT = macosx; |
| 350 | SWIFT_COMPILATION_MODE = wholemodule; | 351 | SWIFT_COMPILATION_MODE = wholemodule; |
| @@ -427,7 +428,7 @@ | @@ -427,7 +428,7 @@ | ||
| 427 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; | 428 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; |
| 428 | GCC_WARN_UNUSED_FUNCTION = YES; | 429 | GCC_WARN_UNUSED_FUNCTION = YES; |
| 429 | GCC_WARN_UNUSED_VARIABLE = YES; | 430 | GCC_WARN_UNUSED_VARIABLE = YES; |
| 430 | - MACOSX_DEPLOYMENT_TARGET = 10.11; | 431 | + MACOSX_DEPLOYMENT_TARGET = 10.14; |
| 431 | MTL_ENABLE_DEBUG_INFO = YES; | 432 | MTL_ENABLE_DEBUG_INFO = YES; |
| 432 | ONLY_ACTIVE_ARCH = YES; | 433 | ONLY_ACTIVE_ARCH = YES; |
| 433 | SDKROOT = macosx; | 434 | SDKROOT = macosx; |
| @@ -474,7 +475,7 @@ | @@ -474,7 +475,7 @@ | ||
| 474 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; | 475 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; |
| 475 | GCC_WARN_UNUSED_FUNCTION = YES; | 476 | GCC_WARN_UNUSED_FUNCTION = YES; |
| 476 | GCC_WARN_UNUSED_VARIABLE = YES; | 477 | GCC_WARN_UNUSED_VARIABLE = YES; |
| 477 | - MACOSX_DEPLOYMENT_TARGET = 10.11; | 478 | + MACOSX_DEPLOYMENT_TARGET = 10.14; |
| 478 | MTL_ENABLE_DEBUG_INFO = NO; | 479 | MTL_ENABLE_DEBUG_INFO = NO; |
| 479 | SDKROOT = macosx; | 480 | SDKROOT = macosx; |
| 480 | SWIFT_COMPILATION_MODE = wholemodule; | 481 | SWIFT_COMPILATION_MODE = wholemodule; |
| @@ -45,10 +45,10 @@ packages: | @@ -45,10 +45,10 @@ packages: | ||
| 45 | dependency: "direct main" | 45 | dependency: "direct main" |
| 46 | description: | 46 | description: |
| 47 | name: cupertino_icons | 47 | name: cupertino_icons |
| 48 | - sha256: e35129dc44c9118cee2a5603506d823bab99c68393879edb440e0090d07586be | 48 | + sha256: d57953e10f9f8327ce64a508a355f0b1ec902193f66288e8cb5070e7c47eeb2d |
| 49 | url: "https://pub.dev" | 49 | url: "https://pub.dev" |
| 50 | source: hosted | 50 | source: hosted |
| 51 | - version: "1.0.5" | 51 | + version: "1.0.6" |
| 52 | equatable: | 52 | equatable: |
| 53 | dependency: "direct main" | 53 | dependency: "direct main" |
| 54 | description: | 54 | description: |
| @@ -84,18 +84,18 @@ packages: | @@ -84,18 +84,18 @@ packages: | ||
| 84 | dependency: "direct main" | 84 | dependency: "direct main" |
| 85 | description: | 85 | description: |
| 86 | name: go_router | 86 | name: go_router |
| 87 | - sha256: aec1999abe8b2f131eda46d4c9629048fb1befed2b65e90b73f9193a300ce489 | 87 | + sha256: "2cb236ba3f923043fdbe14a6a3a796b8c250e85658e28caee3e86c0c275847e5" |
| 88 | url: "https://pub.dev" | 88 | url: "https://pub.dev" |
| 89 | source: hosted | 89 | source: hosted |
| 90 | - version: "4.5.1" | 90 | + version: "8.2.0" |
| 91 | logging: | 91 | logging: |
| 92 | dependency: transitive | 92 | dependency: transitive |
| 93 | description: | 93 | description: |
| 94 | name: logging | 94 | name: logging |
| 95 | - sha256: c0bbfe94d46aedf9b8b3e695cf3bd48c8e14b35e3b2c639e0aa7755d589ba946 | 95 | + sha256: "623a88c9594aa774443aa3eb2d41807a48486b5613e67599fb4c41c0ad47c340" |
| 96 | url: "https://pub.dev" | 96 | url: "https://pub.dev" |
| 97 | source: hosted | 97 | source: hosted |
| 98 | - version: "1.1.0" | 98 | + version: "1.2.0" |
| 99 | matcher: | 99 | matcher: |
| 100 | dependency: transitive | 100 | dependency: transitive |
| 101 | description: | 101 | description: |
| @@ -222,4 +222,4 @@ packages: | @@ -222,4 +222,4 @@ packages: | ||
| 222 | version: "0.1.4-beta" | 222 | version: "0.1.4-beta" |
| 223 | sdks: | 223 | sdks: |
| 224 | dart: ">=3.1.0-185.0.dev <4.0.0" | 224 | dart: ">=3.1.0-185.0.dev <4.0.0" |
| 225 | - flutter: ">=3.7.0" | 225 | + flutter: ">=3.3.0" |
| @@ -4,18 +4,17 @@ publish_to: 'none' | @@ -4,18 +4,17 @@ publish_to: 'none' | ||
| 4 | version: 1.0.0+1 | 4 | version: 1.0.0+1 |
| 5 | 5 | ||
| 6 | environment: | 6 | environment: |
| 7 | - sdk: ">=2.17.0 <3.0.0" | ||
| 8 | - flutter: ">=3.7.0" | 7 | + sdk: ">=3.0.0 <4.0.0" |
| 9 | 8 | ||
| 10 | dependencies: | 9 | dependencies: |
| 11 | flutter: | 10 | flutter: |
| 12 | sdk: flutter | 11 | sdk: flutter |
| 13 | - equatable: ^2.0.3 | 12 | + equatable: ^2.0.5 |
| 14 | cupertino_icons: ^1.0.0 | 13 | cupertino_icons: ^1.0.0 |
| 15 | - provider: ^6.0.2 | 14 | + provider: ^6.0.5 |
| 16 | sheet: | 15 | sheet: |
| 17 | path: ../ | 16 | path: ../ |
| 18 | - go_router: ^4.3.0 | 17 | + go_router: ^8.0.5 |
| 19 | 18 | ||
| 20 | dev_dependencies: | 19 | dev_dependencies: |
| 21 | flutter_test: | 20 | flutter_test: |
| @@ -169,7 +169,7 @@ class BouncingSheetPhysics extends ScrollPhysics with SheetPhysics { | @@ -169,7 +169,7 @@ class BouncingSheetPhysics extends ScrollPhysics with SheetPhysics { | ||
| 169 | @override | 169 | @override |
| 170 | Simulation? createBallisticSimulation( | 170 | Simulation? createBallisticSimulation( |
| 171 | ScrollMetrics position, double velocity) { | 171 | ScrollMetrics position, double velocity) { |
| 172 | - final Tolerance tolerance = toleranceFor(position); | 172 | + |
| 173 | if (position.outOfRange) { | 173 | if (position.outOfRange) { |
| 174 | return BouncingScrollSimulation( | 174 | return BouncingScrollSimulation( |
| 175 | spring: const SpringDescription( | 175 | spring: const SpringDescription( |
| @@ -181,7 +181,7 @@ class BouncingSheetPhysics extends ScrollPhysics with SheetPhysics { | @@ -181,7 +181,7 @@ class BouncingSheetPhysics extends ScrollPhysics with SheetPhysics { | ||
| 181 | velocity: velocity, | 181 | velocity: velocity, |
| 182 | leadingExtent: position.minScrollExtent, | 182 | leadingExtent: position.minScrollExtent, |
| 183 | trailingExtent: position.maxScrollExtent, | 183 | trailingExtent: position.maxScrollExtent, |
| 184 | - tolerance: tolerance, | 184 | + tolerance: toleranceFor(position), |
| 185 | ); | 185 | ); |
| 186 | } | 186 | } |
| 187 | return super.createBallisticSimulation(position, velocity); | 187 | return super.createBallisticSimulation(position, velocity); |
| @@ -266,7 +266,6 @@ class NoMomentumSheetPhysics extends ScrollPhysics with SheetPhysics { | @@ -266,7 +266,6 @@ class NoMomentumSheetPhysics extends ScrollPhysics with SheetPhysics { | ||
| 266 | @override | 266 | @override |
| 267 | Simulation? createBallisticSimulation( | 267 | Simulation? createBallisticSimulation( |
| 268 | ScrollMetrics position, double velocity) { | 268 | ScrollMetrics position, double velocity) { |
| 269 | - final Tolerance tolerance = toleranceFor(position); | ||
| 270 | if (position.outOfRange) { | 269 | if (position.outOfRange) { |
| 271 | double? end; | 270 | double? end; |
| 272 | if (position.pixels > position.maxScrollExtent) { | 271 | if (position.pixels > position.maxScrollExtent) { |
| @@ -280,7 +279,7 @@ class NoMomentumSheetPhysics extends ScrollPhysics with SheetPhysics { | @@ -280,7 +279,7 @@ class NoMomentumSheetPhysics extends ScrollPhysics with SheetPhysics { | ||
| 280 | position.pixels, | 279 | position.pixels, |
| 281 | end!, | 280 | end!, |
| 282 | math.min(0.0, velocity), | 281 | math.min(0.0, velocity), |
| 283 | - tolerance: tolerance, | 282 | + tolerance: toleranceFor(position), |
| 284 | ); | 283 | ); |
| 285 | } | 284 | } |
| 286 | return null; | 285 | return null; |
| @@ -514,7 +513,7 @@ class SnapSheetPhysics extends ScrollPhysics with SheetPhysics { | @@ -514,7 +513,7 @@ class SnapSheetPhysics extends ScrollPhysics with SheetPhysics { | ||
| 514 | } | 513 | } |
| 515 | 514 | ||
| 516 | /// Describes how [SheetScrollable] widgets should behave. | 515 | /// Describes how [SheetScrollable] widgets should behave. |
| 517 | -class SheetBehaviour extends ScrollBehavior { | 516 | +class SheetBehavior extends ScrollBehavior { |
| 518 | static const SheetPhysics _clampingPhysics = | 517 | static const SheetPhysics _clampingPhysics = |
| 519 | NoMomentumSheetPhysics(parent: RangeMaintainingScrollPhysics()); | 518 | NoMomentumSheetPhysics(parent: RangeMaintainingScrollPhysics()); |
| 520 | 519 |
| @@ -14,16 +14,11 @@ mixin PreviousSheetRouteMixin<T> on PageRoute<T> { | @@ -14,16 +14,11 @@ mixin PreviousSheetRouteMixin<T> on PageRoute<T> { | ||
| 14 | class MaterialExtendedPageRoute<T> extends MaterialPageRoute<T> | 14 | class MaterialExtendedPageRoute<T> extends MaterialPageRoute<T> |
| 15 | with PreviousSheetRouteMixin<T>, DelegatedTransitionsRoute<T> { | 15 | with PreviousSheetRouteMixin<T>, DelegatedTransitionsRoute<T> { |
| 16 | MaterialExtendedPageRoute({ | 16 | MaterialExtendedPageRoute({ |
| 17 | - required WidgetBuilder builder, | ||
| 18 | - RouteSettings? settings, | ||
| 19 | - bool maintainState = true, | ||
| 20 | - bool fullscreenDialog = false, | ||
| 21 | - }) : super( | ||
| 22 | - builder: builder, | ||
| 23 | - maintainState: maintainState, | ||
| 24 | - settings: settings, | ||
| 25 | - fullscreenDialog: fullscreenDialog, | ||
| 26 | - ); | 17 | + required super.builder, |
| 18 | + super.settings, | ||
| 19 | + super.maintainState = true, | ||
| 20 | + super.fullscreenDialog = false, | ||
| 21 | + }); | ||
| 27 | } | 22 | } |
| 28 | 23 | ||
| 29 | class MaterialExtendedPage<T> extends Page<T> { | 24 | class MaterialExtendedPage<T> extends Page<T> { |
| @@ -32,15 +27,11 @@ class MaterialExtendedPage<T> extends Page<T> { | @@ -32,15 +27,11 @@ class MaterialExtendedPage<T> extends Page<T> { | ||
| 32 | required this.child, | 27 | required this.child, |
| 33 | this.maintainState = true, | 28 | this.maintainState = true, |
| 34 | this.fullscreenDialog = false, | 29 | this.fullscreenDialog = false, |
| 35 | - LocalKey? key, | ||
| 36 | - String? name, | ||
| 37 | - Object? arguments, | ||
| 38 | - String? restorationId, | ||
| 39 | - }) : super( | ||
| 40 | - key: key, | ||
| 41 | - name: name, | ||
| 42 | - arguments: arguments, | ||
| 43 | - restorationId: restorationId); | 30 | + super.key, |
| 31 | + super.name, | ||
| 32 | + super.arguments, | ||
| 33 | + super.restorationId, | ||
| 34 | + }); | ||
| 44 | 35 | ||
| 45 | /// The content to be shown in the [Route] created by this page. | 36 | /// The content to be shown in the [Route] created by this page. |
| 46 | final Widget child; | 37 | final Widget child; |
| @@ -89,18 +80,12 @@ class _PageBasedMaterialPageRoute<T> extends MaterialExtendedPageRoute<T> { | @@ -89,18 +80,12 @@ class _PageBasedMaterialPageRoute<T> extends MaterialExtendedPageRoute<T> { | ||
| 89 | class CupertinoExtendedPageRoute<T> extends CupertinoPageRoute<T> | 80 | class CupertinoExtendedPageRoute<T> extends CupertinoPageRoute<T> |
| 90 | with PreviousSheetRouteMixin<T>, DelegatedTransitionsRoute<T> { | 81 | with PreviousSheetRouteMixin<T>, DelegatedTransitionsRoute<T> { |
| 91 | CupertinoExtendedPageRoute({ | 82 | CupertinoExtendedPageRoute({ |
| 92 | - required WidgetBuilder builder, | ||
| 93 | - String? title, | ||
| 94 | - RouteSettings? settings, | ||
| 95 | - bool maintainState = true, | ||
| 96 | - bool fullscreenDialog = false, | ||
| 97 | - }) : super( | ||
| 98 | - builder: builder, | ||
| 99 | - title: title, | ||
| 100 | - maintainState: maintainState, | ||
| 101 | - settings: settings, | ||
| 102 | - fullscreenDialog: fullscreenDialog, | ||
| 103 | - ); | 83 | + required super.builder, |
| 84 | + super.title, | ||
| 85 | + super.settings, | ||
| 86 | + super.maintainState = true, | ||
| 87 | + super.fullscreenDialog = false, | ||
| 88 | + }); | ||
| 104 | } | 89 | } |
| 105 | 90 | ||
| 106 | class CupertinoExtendedPage<T> extends Page<T> { | 91 | class CupertinoExtendedPage<T> extends Page<T> { |
| @@ -110,15 +95,11 @@ class CupertinoExtendedPage<T> extends Page<T> { | @@ -110,15 +95,11 @@ class CupertinoExtendedPage<T> extends Page<T> { | ||
| 110 | this.maintainState = true, | 95 | this.maintainState = true, |
| 111 | this.title, | 96 | this.title, |
| 112 | this.fullscreenDialog = false, | 97 | this.fullscreenDialog = false, |
| 113 | - LocalKey? key, | ||
| 114 | - String? name, | ||
| 115 | - Object? arguments, | ||
| 116 | - String? restorationId, | ||
| 117 | - }) : super( | ||
| 118 | - key: key, | ||
| 119 | - name: name, | ||
| 120 | - arguments: arguments, | ||
| 121 | - restorationId: restorationId); | 98 | + super.key, |
| 99 | + super.name, | ||
| 100 | + super.arguments, | ||
| 101 | + super.restorationId, | ||
| 102 | + }); | ||
| 122 | 103 | ||
| 123 | /// The content to be shown in the [Route] created by this page. | 104 | /// The content to be shown in the [Route] created by this page. |
| 124 | final Widget child; | 105 | final Widget child; |
| @@ -26,7 +26,7 @@ const Radius _kCupertinoSheetTopRadius = Radius.circular(10.0); | @@ -26,7 +26,7 @@ const Radius _kCupertinoSheetTopRadius = Radius.circular(10.0); | ||
| 26 | const Radius _kRoundedDeviceRadius = Radius.circular(38.5); | 26 | const Radius _kRoundedDeviceRadius = Radius.circular(38.5); |
| 27 | 27 | ||
| 28 | /// Minimal distance from the top of the screen to the top of the previous route | 28 | /// Minimal distance from the top of the screen to the top of the previous route |
| 29 | -/// It will be used ff the top safearea is less than this value. | 29 | +/// It will be used ff the top safe area is less than this value. |
| 30 | /// In iPhones the top SafeArea is more or equal to this distance. | 30 | /// In iPhones the top SafeArea is more or equal to this distance. |
| 31 | const double _kSheetMinimalOffset = 10; | 31 | const double _kSheetMinimalOffset = 10; |
| 32 | 32 | ||
| @@ -38,18 +38,17 @@ const double _kRoundedDeviceStatusBarHeight = 20; | @@ -38,18 +38,17 @@ const double _kRoundedDeviceStatusBarHeight = 20; | ||
| 38 | const Curve _kCupertinoSheetCurve = Curves.easeOutExpo; | 38 | const Curve _kCupertinoSheetCurve = Curves.easeOutExpo; |
| 39 | const Curve _kCupertinoTransitionCurve = Curves.linear; | 39 | const Curve _kCupertinoTransitionCurve = Curves.linear; |
| 40 | 40 | ||
| 41 | -/// Wraps the child into a cupertino modal sheet appareance. This is used to | 41 | +/// Wraps the child into a cupertino modal sheet appearance. This is used to |
| 42 | /// create a [SheetRoute]. | 42 | /// create a [SheetRoute]. |
| 43 | /// | 43 | /// |
| 44 | /// Clip the child widget to rectangle with top rounded corners and adds | 44 | /// Clip the child widget to rectangle with top rounded corners and adds |
| 45 | /// top padding and top safe area. | 45 | /// top padding and top safe area. |
| 46 | class _CupertinoSheetDecorationBuilder extends StatelessWidget { | 46 | class _CupertinoSheetDecorationBuilder extends StatelessWidget { |
| 47 | const _CupertinoSheetDecorationBuilder({ | 47 | const _CupertinoSheetDecorationBuilder({ |
| 48 | - Key? key, | ||
| 49 | required this.child, | 48 | required this.child, |
| 50 | required this.topRadius, | 49 | required this.topRadius, |
| 51 | this.backgroundColor, | 50 | this.backgroundColor, |
| 52 | - }) : super(key: key); | 51 | + }); |
| 53 | 52 | ||
| 54 | /// The child contained by the modal sheet | 53 | /// The child contained by the modal sheet |
| 55 | final Widget child; | 54 | final Widget child; |
| @@ -86,22 +85,22 @@ class _CupertinoSheetDecorationBuilder extends StatelessWidget { | @@ -86,22 +85,22 @@ class _CupertinoSheetDecorationBuilder extends StatelessWidget { | ||
| 86 | } | 85 | } |
| 87 | 86 | ||
| 88 | /// A modal route that overlays a widget over the current route and animates | 87 | /// A modal route that overlays a widget over the current route and animates |
| 89 | -/// it from the bottom with a cupertino modal sheet appareance | 88 | +/// it from the bottom with a cupertino modal sheet appearance |
| 90 | /// | 89 | /// |
| 91 | /// Clip the child widget to rectangle with top rounded corners and adds | 90 | /// Clip the child widget to rectangle with top rounded corners and adds |
| 92 | /// top padding and top safe area. | 91 | /// top padding and top safe area. |
| 93 | /// | 92 | /// |
| 94 | /// * [CupertinoSheetPage], which is the [Page] version of this class | 93 | /// * [CupertinoSheetPage], which is the [Page] version of this class |
| 95 | class CupertinoSheetRoute<T> extends SheetRoute<T> { | 94 | class CupertinoSheetRoute<T> extends SheetRoute<T> { |
| 96 | - CupertinoSheetRoute( | ||
| 97 | - {required WidgetBuilder builder, | ||
| 98 | - List<double>? stops, | 95 | + CupertinoSheetRoute({ |
| 96 | + required WidgetBuilder builder, | ||
| 97 | + super.stops, | ||
| 99 | double initialStop = 1, | 98 | double initialStop = 1, |
| 100 | - RouteSettings? settings, | 99 | + super.settings, |
| 101 | Color? backgroundColor, | 100 | Color? backgroundColor, |
| 102 | - bool maintainState = true, | ||
| 103 | - super.fit}) | ||
| 104 | - : super( | 101 | + super.maintainState = true, |
| 102 | + super.fit, | ||
| 103 | + }) : super( | ||
| 105 | builder: (BuildContext context) { | 104 | builder: (BuildContext context) { |
| 106 | return _CupertinoSheetDecorationBuilder( | 105 | return _CupertinoSheetDecorationBuilder( |
| 107 | child: Builder(builder: builder), | 106 | child: Builder(builder: builder), |
| @@ -109,11 +108,8 @@ class CupertinoSheetRoute<T> extends SheetRoute<T> { | @@ -109,11 +108,8 @@ class CupertinoSheetRoute<T> extends SheetRoute<T> { | ||
| 109 | topRadius: _kCupertinoSheetTopRadius, | 108 | topRadius: _kCupertinoSheetTopRadius, |
| 110 | ); | 109 | ); |
| 111 | }, | 110 | }, |
| 112 | - settings: settings, | ||
| 113 | animationCurve: _kCupertinoSheetCurve, | 111 | animationCurve: _kCupertinoSheetCurve, |
| 114 | - stops: stops, | ||
| 115 | initialExtent: initialStop, | 112 | initialExtent: initialStop, |
| 116 | - maintainState: maintainState, | ||
| 117 | ); | 113 | ); |
| 118 | 114 | ||
| 119 | @override | 115 | @override |
| @@ -239,7 +235,7 @@ class CupertinoSheetBottomRouteTransition extends StatelessWidget { | @@ -239,7 +235,7 @@ class CupertinoSheetBottomRouteTransition extends StatelessWidget { | ||
| 239 | 235 | ||
| 240 | // Currently iOS does not provide any way to detect the radius of the | 236 | // Currently iOS does not provide any way to detect the radius of the |
| 241 | // screen device. Right not we detect if the safe area has the size | 237 | // screen device. Right not we detect if the safe area has the size |
| 242 | - // for the device that contain a notch as they are the ones rigth | 238 | + // for the device that contain a notch as they are the ones right |
| 243 | // now that has corners with radius | 239 | // now that has corners with radius |
| 244 | Radius _getRadiusForDevice(MediaQueryData mediaQuery) { | 240 | Radius _getRadiusForDevice(MediaQueryData mediaQuery) { |
| 245 | final double topPadding = mediaQuery.padding.top; | 241 | final double topPadding = mediaQuery.padding.top; |
| @@ -305,7 +301,7 @@ class CupertinoSheetBottomRouteTransition extends StatelessWidget { | @@ -305,7 +301,7 @@ class CupertinoSheetBottomRouteTransition extends StatelessWidget { | ||
| 305 | } | 301 | } |
| 306 | 302 | ||
| 307 | /// A modal page that overlays a widget over the current route and animates | 303 | /// A modal page that overlays a widget over the current route and animates |
| 308 | -/// it from the bottom with a cupertino modal sheet appareance | 304 | +/// it from the bottom with a cupertino modal sheet appearance |
| 309 | /// | 305 | /// |
| 310 | /// Clip the child widget to rectangle with top rounded corners and adds | 306 | /// Clip the child widget to rectangle with top rounded corners and adds |
| 311 | /// top padding and top safe area. | 307 | /// top padding and top safe area. |
| @@ -3,6 +3,7 @@ | @@ -3,6 +3,7 @@ | ||
| 3 | // found in the LICENSE file. | 3 | // found in the LICENSE file. |
| 4 | 4 | ||
| 5 | import 'package:flutter/material.dart'; | 5 | import 'package:flutter/material.dart'; |
| 6 | +import 'package:flutter/rendering.dart'; | ||
| 6 | import 'package:flutter/widgets.dart'; | 7 | import 'package:flutter/widgets.dart'; |
| 7 | import 'package:sheet/route.dart'; | 8 | import 'package:sheet/route.dart'; |
| 8 | import 'package:sheet/sheet.dart'; | 9 | import 'package:sheet/sheet.dart'; |
| @@ -27,7 +28,7 @@ const Color _kBarrierColor = Color(0x59000000); | @@ -27,7 +28,7 @@ const Color _kBarrierColor = Color(0x59000000); | ||
| 27 | /// See also: | 28 | /// See also: |
| 28 | /// | 29 | /// |
| 29 | /// * [SheetPage], which is a [Page] of this class. | 30 | /// * [SheetPage], which is a [Page] of this class. |
| 30 | -/// * [CupertinoSheetRoute], which is has an iOS appareance | 31 | +/// * [CupertinoSheetRoute], which is has an iOS appearance |
| 31 | class SheetRoute<T> extends PageRoute<T> with DelegatedTransitionsRoute<T> { | 32 | class SheetRoute<T> extends PageRoute<T> with DelegatedTransitionsRoute<T> { |
| 32 | SheetRoute({ | 33 | SheetRoute({ |
| 33 | required this.builder, | 34 | required this.builder, |
| @@ -45,9 +46,9 @@ class SheetRoute<T> extends PageRoute<T> with DelegatedTransitionsRoute<T> { | @@ -45,9 +46,9 @@ class SheetRoute<T> extends PageRoute<T> with DelegatedTransitionsRoute<T> { | ||
| 45 | this.maintainState = true, | 46 | this.maintainState = true, |
| 46 | this.willPopThreshold = _kWillPopThreshold, | 47 | this.willPopThreshold = _kWillPopThreshold, |
| 47 | this.decorationBuilder, | 48 | this.decorationBuilder, |
| 48 | - RouteSettings? settings, | 49 | + super.settings, |
| 49 | }) : transitionDuration = duration ?? _kSheetTransitionDuration, | 50 | }) : transitionDuration = duration ?? _kSheetTransitionDuration, |
| 50 | - super(settings: settings, fullscreenDialog: true); | 51 | + super(fullscreenDialog: true); |
| 51 | 52 | ||
| 52 | /// Builds the primary contents of the route. | 53 | /// Builds the primary contents of the route. |
| 53 | final WidgetBuilder builder; | 54 | final WidgetBuilder builder; |
| @@ -85,7 +86,7 @@ class SheetRoute<T> extends PageRoute<T> with DelegatedTransitionsRoute<T> { | @@ -85,7 +86,7 @@ class SheetRoute<T> extends PageRoute<T> with DelegatedTransitionsRoute<T> { | ||
| 85 | 86 | ||
| 86 | /// Drag threshold to block any interaction if [Route.willPop] returns false | 87 | /// Drag threshold to block any interaction if [Route.willPop] returns false |
| 87 | /// See also: | 88 | /// See also: |
| 88 | - /// * [WillPopScope], that allow to block an attemp to close a [ModalRoute] | 89 | + /// * [WillPopScope], that allow to block an attempt to close a [ModalRoute] |
| 89 | final double willPopThreshold; | 90 | final double willPopThreshold; |
| 90 | 91 | ||
| 91 | /// {@macro flutter.widgets.TransitionRoute.transitionDuration} | 92 | /// {@macro flutter.widgets.TransitionRoute.transitionDuration} |
| @@ -95,7 +96,7 @@ class SheetRoute<T> extends PageRoute<T> with DelegatedTransitionsRoute<T> { | @@ -95,7 +96,7 @@ class SheetRoute<T> extends PageRoute<T> with DelegatedTransitionsRoute<T> { | ||
| 95 | /// The semantic label used for a sheet modal route. | 96 | /// The semantic label used for a sheet modal route. |
| 96 | final String? sheetLabel; | 97 | final String? sheetLabel; |
| 97 | 98 | ||
| 98 | - /// Wraps the child in a custom sheet decoration appareance | 99 | + /// Wraps the child in a custom sheet decoration appearance |
| 99 | /// | 100 | /// |
| 100 | /// The default value is null. | 101 | /// The default value is null. |
| 101 | final SheetDecorationBuilder? decorationBuilder; | 102 | final SheetDecorationBuilder? decorationBuilder; |
| @@ -225,9 +226,9 @@ class SheetPage<T> extends Page<T> { | @@ -225,9 +226,9 @@ class SheetPage<T> extends Page<T> { | ||
| 225 | const SheetPage( | 226 | const SheetPage( |
| 226 | {required this.child, | 227 | {required this.child, |
| 227 | this.maintainState = true, | 228 | this.maintainState = true, |
| 228 | - LocalKey? key, | ||
| 229 | - String? name, | ||
| 230 | - Object? arguments, | 229 | + super.key, |
| 230 | + super.name, | ||
| 231 | + super.arguments, | ||
| 231 | this.initialExtent = 1, | 232 | this.initialExtent = 1, |
| 232 | this.stops, | 233 | this.stops, |
| 233 | this.draggable = true, | 234 | this.draggable = true, |
| @@ -241,12 +242,7 @@ class SheetPage<T> extends Page<T> { | @@ -241,12 +242,7 @@ class SheetPage<T> extends Page<T> { | ||
| 241 | this.barrierDismissible = true, | 242 | this.barrierDismissible = true, |
| 242 | this.willPopThreshold = _kWillPopThreshold, | 243 | this.willPopThreshold = _kWillPopThreshold, |
| 243 | this.decorationBuilder}) | 244 | this.decorationBuilder}) |
| 244 | - : transitionDuration = duration ?? _kSheetTransitionDuration, | ||
| 245 | - super( | ||
| 246 | - key: key, | ||
| 247 | - name: name, | ||
| 248 | - arguments: arguments, | ||
| 249 | - ); | 245 | + : transitionDuration = duration ?? _kSheetTransitionDuration; |
| 250 | 246 | ||
| 251 | /// Relative extent up to where the sheet is animated when pushed for | 247 | /// Relative extent up to where the sheet is animated when pushed for |
| 252 | /// the first time. | 248 | /// the first time. |
| @@ -287,7 +283,7 @@ class SheetPage<T> extends Page<T> { | @@ -287,7 +283,7 @@ class SheetPage<T> extends Page<T> { | ||
| 287 | 283 | ||
| 288 | /// Drag threshold to block any interaction if [Route.willPop] returns false | 284 | /// Drag threshold to block any interaction if [Route.willPop] returns false |
| 289 | /// See also: | 285 | /// See also: |
| 290 | - /// * [WillPopScope], that allow to block an attemp to close a [ModalRoute] | 286 | + /// * [WillPopScope], that allow to block an attempt to close a [ModalRoute] |
| 291 | final double willPopThreshold; | 287 | final double willPopThreshold; |
| 292 | 288 | ||
| 293 | /// {@macro flutter.widgets.TransitionRoute.transitionDuration} | 289 | /// {@macro flutter.widgets.TransitionRoute.transitionDuration} |
| @@ -302,7 +298,7 @@ class SheetPage<T> extends Page<T> { | @@ -302,7 +298,7 @@ class SheetPage<T> extends Page<T> { | ||
| 302 | 298 | ||
| 303 | final String? barrierLabel; | 299 | final String? barrierLabel; |
| 304 | 300 | ||
| 305 | - /// Wraps the child in a custom sheet decoration appareance | 301 | + /// Wraps the child in a custom sheet decoration appearance |
| 306 | /// | 302 | /// |
| 307 | /// The default value is null. | 303 | /// The default value is null. |
| 308 | final SheetDecorationBuilder? decorationBuilder; | 304 | final SheetDecorationBuilder? decorationBuilder; |
| @@ -332,30 +328,17 @@ class SheetPage<T> extends Page<T> { | @@ -332,30 +328,17 @@ class SheetPage<T> extends Page<T> { | ||
| 332 | class _PageBasedSheetRoute<T> extends SheetRoute<T> { | 328 | class _PageBasedSheetRoute<T> extends SheetRoute<T> { |
| 333 | _PageBasedSheetRoute({ | 329 | _PageBasedSheetRoute({ |
| 334 | required SheetPage<T> page, | 330 | required SheetPage<T> page, |
| 335 | - Color? barrierColor, | ||
| 336 | - SheetPhysics? physics, | ||
| 337 | - SheetFit fit = SheetFit.expand, | ||
| 338 | - Curve? animationCurve, | ||
| 339 | - bool barrierDismissible = true, | ||
| 340 | - bool draggable = true, | ||
| 341 | - Duration? duration, | ||
| 342 | - List<double>? stops, | ||
| 343 | - double initialExtent = 1, | ||
| 344 | - SheetDecorationBuilder? decorationBuilder, | ||
| 345 | - }) : super( | ||
| 346 | - settings: page, | ||
| 347 | - builder: (BuildContext context) => page.child, | ||
| 348 | - physics: physics, | ||
| 349 | - fit: fit, | ||
| 350 | - stops: stops, | ||
| 351 | - initialExtent: initialExtent, | ||
| 352 | - barrierDismissible: barrierDismissible, | ||
| 353 | - barrierColor: barrierColor, | ||
| 354 | - draggable: draggable, | ||
| 355 | - animationCurve: animationCurve, | ||
| 356 | - duration: duration, | ||
| 357 | - decorationBuilder: decorationBuilder, | ||
| 358 | - ); | 331 | + super.physics, |
| 332 | + required super.fit, | ||
| 333 | + super.animationCurve, | ||
| 334 | + required super.barrierDismissible, | ||
| 335 | + super.barrierColor, | ||
| 336 | + required super.draggable, | ||
| 337 | + super.duration, | ||
| 338 | + super.stops, | ||
| 339 | + required super.initialExtent, | ||
| 340 | + super.decorationBuilder, | ||
| 341 | + }) : super(settings: page, builder: (BuildContext context) => page.child); | ||
| 359 | 342 | ||
| 360 | SheetPage<T> get _page => settings as SheetPage<T>; | 343 | SheetPage<T> get _page => settings as SheetPage<T>; |
| 361 | 344 | ||
| @@ -392,7 +375,6 @@ class __SheetRouteContainerState extends State<_SheetRouteContainer> | @@ -392,7 +375,6 @@ class __SheetRouteContainerState extends State<_SheetRouteContainer> | ||
| 392 | curve: route.animationCurve ?? Curves.easeOut, | 375 | curve: route.animationCurve ?? Curves.easeOut, |
| 393 | ); | 376 | ); |
| 394 | }); | 377 | }); |
| 395 | - | ||
| 396 | super.initState(); | 378 | super.initState(); |
| 397 | } | 379 | } |
| 398 | 380 | ||
| @@ -406,8 +388,11 @@ class __SheetRouteContainerState extends State<_SheetRouteContainer> | @@ -406,8 +388,11 @@ class __SheetRouteContainerState extends State<_SheetRouteContainer> | ||
| 406 | void onSheetExtentUpdate() { | 388 | void onSheetExtentUpdate() { |
| 407 | if (_routeController.value != _sheetController.animation.value) { | 389 | if (_routeController.value != _sheetController.animation.value) { |
| 408 | if (route.isCurrent && | 390 | if (route.isCurrent && |
| 391 | + !_firstAnimation && | ||
| 409 | !_sheetController.position.preventingDrag && | 392 | !_sheetController.position.preventingDrag && |
| 410 | - route.shouldPreventPopForExtent(_sheetController.animation.value)) { | 393 | + route.shouldPreventPopForExtent(_sheetController.animation.value) && |
| 394 | + _sheetController.position.userScrollDirection == | ||
| 395 | + ScrollDirection.forward) { | ||
| 411 | preventPop(); | 396 | preventPop(); |
| 412 | return; | 397 | return; |
| 413 | } | 398 | } |
| @@ -420,9 +405,10 @@ class __SheetRouteContainerState extends State<_SheetRouteContainer> | @@ -420,9 +405,10 @@ class __SheetRouteContainerState extends State<_SheetRouteContainer> | ||
| 420 | toHigh: 1, | 405 | toHigh: 1, |
| 421 | ); | 406 | ); |
| 422 | _routeController.value = animationValue; | 407 | _routeController.value = animationValue; |
| 423 | - | ||
| 424 | if (_sheetController.animation.value == 0) { | 408 | if (_sheetController.animation.value == 0) { |
| 425 | - widget.sheetRoute.navigator?.pop(); | 409 | + _routeController.value = 0.001; |
| 410 | + _routeController.animateBack(0); | ||
| 411 | + route.navigator?.pop(); | ||
| 426 | } | 412 | } |
| 427 | } | 413 | } |
| 428 | } | 414 | } |
| @@ -436,6 +422,8 @@ class __SheetRouteContainerState extends State<_SheetRouteContainer> | @@ -436,6 +422,8 @@ class __SheetRouteContainerState extends State<_SheetRouteContainer> | ||
| 436 | if (!_routeController.isAnimating) { | 422 | if (!_routeController.isAnimating) { |
| 437 | return; | 423 | return; |
| 438 | } | 424 | } |
| 425 | + // widget.sheetRoute.navigator!.userGestureInProgressNotifier.value = false; | ||
| 426 | + | ||
| 439 | if (!_firstAnimation && | 427 | if (!_firstAnimation && |
| 440 | _routeController.value != _sheetController.animation.value) { | 428 | _routeController.value != _sheetController.animation.value) { |
| 441 | if (_routeController.status == AnimationStatus.forward) { | 429 | if (_routeController.status == AnimationStatus.forward) { |
| @@ -462,11 +450,12 @@ class __SheetRouteContainerState extends State<_SheetRouteContainer> | @@ -462,11 +450,12 @@ class __SheetRouteContainerState extends State<_SheetRouteContainer> | ||
| 462 | @protected | 450 | @protected |
| 463 | void preventPop() { | 451 | void preventPop() { |
| 464 | _sheetController.position.preventDrag(); | 452 | _sheetController.position.preventDrag(); |
| 465 | - _sheetController.relativeAnimateTo( | ||
| 466 | - 1, | 453 | + _sheetController.position.animateTo( |
| 454 | + _sheetController.position.maxScrollExtent, | ||
| 467 | duration: const Duration(milliseconds: 400), | 455 | duration: const Duration(milliseconds: 400), |
| 468 | curve: Curves.easeInOut, | 456 | curve: Curves.easeInOut, |
| 469 | ); | 457 | ); |
| 458 | + | ||
| 470 | route.willPop().then( | 459 | route.willPop().then( |
| 471 | (RoutePopDisposition disposition) { | 460 | (RoutePopDisposition disposition) { |
| 472 | if (disposition == RoutePopDisposition.pop) { | 461 | if (disposition == RoutePopDisposition.pop) { |
| @@ -88,7 +88,7 @@ class SheetPrimaryScrollPosition extends ScrollPositionWithSingleContext { | @@ -88,7 +88,7 @@ class SheetPrimaryScrollPosition extends ScrollPositionWithSingleContext { | ||
| 88 | final SheetContext sheetContext; | 88 | final SheetContext sheetContext; |
| 89 | SheetPosition get sheetPosition => sheetContext.position; | 89 | SheetPosition get sheetPosition => sheetContext.position; |
| 90 | 90 | ||
| 91 | - bool sheetShouldSheetAcceptUserOffser(double delta) { | 91 | + bool sheetShouldSheetAcceptUserOffset(double delta) { |
| 92 | // Can drag down if list already on the top | 92 | // Can drag down if list already on the top |
| 93 | final bool canDragForward = delta >= 0 && pixels <= minScrollExtent; | 93 | final bool canDragForward = delta >= 0 && pixels <= minScrollExtent; |
| 94 | 94 | ||
| @@ -106,63 +106,37 @@ class SheetPrimaryScrollPosition extends ScrollPositionWithSingleContext { | @@ -106,63 +106,37 @@ class SheetPrimaryScrollPosition extends ScrollPositionWithSingleContext { | ||
| 106 | if (sheetPosition.preventingDrag) { | 106 | if (sheetPosition.preventingDrag) { |
| 107 | return; | 107 | return; |
| 108 | } | 108 | } |
| 109 | - if (sheetShouldSheetAcceptUserOffser(delta)) { | ||
| 110 | - final double pixels = sheetPosition.pixels - | ||
| 111 | - sheetPosition.physics.applyPhysicsToUserOffset(sheetPosition, delta); | ||
| 112 | - | ||
| 113 | - sheetPosition.forcePixels( | ||
| 114 | - pixels.clamp( | ||
| 115 | - sheetPosition.minScrollExtent, sheetPosition.maxScrollExtent), | ||
| 116 | - ); | 109 | + if (sheetShouldSheetAcceptUserOffset(delta)) { |
| 110 | + if (sheetPosition.activity is! _SheetScrollActivity) { | ||
| 117 | sheetPosition.beginActivity(_SheetScrollActivity(sheetPosition)); | 111 | sheetPosition.beginActivity(_SheetScrollActivity(sheetPosition)); |
| 112 | + } | ||
| 113 | + final double sheetDelta = | ||
| 114 | + sheetPosition.physics.applyPhysicsToUserOffset(sheetPosition, delta); | ||
| 115 | + sheetPosition.applyUserOffset(sheetDelta); | ||
| 118 | return; | 116 | return; |
| 119 | } else { | 117 | } else { |
| 120 | super.applyUserOffset(delta); | 118 | super.applyUserOffset(delta); |
| 121 | - sheetPosition.goIdle(); | 119 | + if (sheetPosition.activity is! HoldScrollActivity) { |
| 120 | + sheetPosition.hold(() {}); | ||
| 121 | + } | ||
| 122 | } | 122 | } |
| 123 | } | 123 | } |
| 124 | 124 | ||
| 125 | @override | 125 | @override |
| 126 | void goBallistic(double velocity) { | 126 | void goBallistic(double velocity) { |
| 127 | if (sheetPosition.preventingDrag) { | 127 | if (sheetPosition.preventingDrag) { |
| 128 | - beginActivity( | ||
| 129 | - BallisticScrollActivity( | ||
| 130 | - this, | ||
| 131 | - ScrollSpringSimulation( | ||
| 132 | - SpringDescription.withDampingRatio( | ||
| 133 | - mass: 0.5, | ||
| 134 | - stiffness: 100.0, | ||
| 135 | - ratio: 1.1, | ||
| 136 | - ), | ||
| 137 | - pixels, | ||
| 138 | - 0, | ||
| 139 | - velocity, | ||
| 140 | - ), | ||
| 141 | - context.vsync, | ||
| 142 | - true, | ||
| 143 | - ), | ||
| 144 | - ); | ||
| 145 | - | 128 | + goIdle(); |
| 146 | return; | 129 | return; |
| 147 | } | 130 | } |
| 148 | 131 | ||
| 149 | - final bool sheetDragging = sheetPosition.activity!.isScrolling; | ||
| 150 | - if (sheetDragging && | ||
| 151 | - sheetPosition.hasContentDimensions && | ||
| 152 | - !sheetPosition.preventingDrag && | ||
| 153 | - sheetPosition.activity!.isScrolling) { | 132 | + if (sheetPosition.hasContentDimensions) { |
| 154 | sheetPosition.goBallistic(velocity); | 133 | sheetPosition.goBallistic(velocity); |
| 155 | - } else { | ||
| 156 | - sheetPosition.goIdle(); | ||
| 157 | } | 134 | } |
| 158 | 135 | ||
| 159 | - if (!sheetDragging) { | ||
| 160 | - super.goBallistic(velocity); | ||
| 161 | - return; | ||
| 162 | - } else if (velocity > 0.0 && | 136 | + if (velocity > 0.0 && |
| 163 | sheetPosition.pixels >= sheetPosition.maxScrollExtent || | 137 | sheetPosition.pixels >= sheetPosition.maxScrollExtent || |
| 164 | (velocity < 0.0 && pixels > 0)) { | 138 | (velocity < 0.0 && pixels > 0)) { |
| 165 | - // super.goBallistic(velocity); | 139 | + super.goBallistic(velocity); |
| 166 | return; | 140 | return; |
| 167 | } else if (outOfRange) { | 141 | } else if (outOfRange) { |
| 168 | beginActivity( | 142 | beginActivity( |
| @@ -183,11 +157,9 @@ class SheetPrimaryScrollPosition extends ScrollPositionWithSingleContext { | @@ -183,11 +157,9 @@ class SheetPrimaryScrollPosition extends ScrollPositionWithSingleContext { | ||
| 183 | ), | 157 | ), |
| 184 | ); | 158 | ); |
| 185 | return; | 159 | return; |
| 186 | - } | ||
| 187 | - | 160 | + } else { |
| 188 | goIdle(); | 161 | goIdle(); |
| 162 | + return; | ||
| 163 | + } | ||
| 189 | } | 164 | } |
| 190 | - | ||
| 191 | - //@override | ||
| 192 | - //double get pixels => super.pixels + viewportDimension; | ||
| 193 | } | 165 | } |
| @@ -196,11 +196,11 @@ class SheetScrollable extends StatefulWidget { | @@ -196,11 +196,11 @@ class SheetScrollable extends StatefulWidget { | ||
| 196 | 196 | ||
| 197 | /// {@macro flutter.widgets.shadow.scrollBehavior} | 197 | /// {@macro flutter.widgets.shadow.scrollBehavior} |
| 198 | /// | 198 | /// |
| 199 | - /// [SheetBehaviour]s also provide [SheetPhysics]. If an explicit | 199 | + /// [SheetBehavior]s also provide [SheetPhysics]. If an explicit |
| 200 | /// [ScrollPhysics] is provided in [physics], it will take precedence, | 200 | /// [ScrollPhysics] is provided in [physics], it will take precedence, |
| 201 | /// followed by [scrollBehavior], and then the inherited ancestor | 201 | /// followed by [scrollBehavior], and then the inherited ancestor |
| 202 | - /// [SheetBehaviour]. | ||
| 203 | - final SheetBehaviour? scrollBehavior; | 202 | + /// [SheetBehavior]. |
| 203 | + final SheetBehavior? scrollBehavior; | ||
| 204 | 204 | ||
| 205 | final double? initialExtent; | 205 | final double? initialExtent; |
| 206 | 206 | ||
| @@ -328,7 +328,7 @@ class SheetState extends State<SheetScrollable> | @@ -328,7 +328,7 @@ class SheetState extends State<SheetScrollable> | ||
| 328 | @override | 328 | @override |
| 329 | AxisDirection get axisDirection => widget.axisDirection; | 329 | AxisDirection get axisDirection => widget.axisDirection; |
| 330 | 330 | ||
| 331 | - late SheetBehaviour _configuration; | 331 | + late SheetBehavior _configuration; |
| 332 | ScrollPhysics? _physics; | 332 | ScrollPhysics? _physics; |
| 333 | SheetController? _fallbackScrollController; | 333 | SheetController? _fallbackScrollController; |
| 334 | 334 | ||
| @@ -339,7 +339,7 @@ class SheetState extends State<SheetScrollable> | @@ -339,7 +339,7 @@ class SheetState extends State<SheetScrollable> | ||
| 339 | 339 | ||
| 340 | // Only call this from places that will definitely trigger a rebuild. | 340 | // Only call this from places that will definitely trigger a rebuild. |
| 341 | void _updatePosition() { | 341 | void _updatePosition() { |
| 342 | - _configuration = widget.scrollBehavior ?? SheetBehaviour(); | 342 | + _configuration = widget.scrollBehavior ?? SheetBehavior(); |
| 343 | _physics = _configuration.getScrollPhysics(context); | 343 | _physics = _configuration.getScrollPhysics(context); |
| 344 | if (widget.physics != null) { | 344 | if (widget.physics != null) { |
| 345 | _physics = widget.physics!.applyTo(_physics); | 345 | _physics = widget.physics!.applyTo(_physics); |
| @@ -21,14 +21,14 @@ enum SheetFit { | @@ -21,14 +21,14 @@ enum SheetFit { | ||
| 21 | /// The constraints passed to the child from the sheet are loosened. | 21 | /// The constraints passed to the child from the sheet are loosened. |
| 22 | /// | 22 | /// |
| 23 | /// For example, if the sheet has expand constraints with 600 high, this would allow the child of the sheet to have any | 23 | /// For example, if the sheet has expand constraints with 600 high, this would allow the child of the sheet to have any |
| 24 | - /// height from zero to maximun available. | 24 | + /// height from zero to maximum available. |
| 25 | loose, | 25 | loose, |
| 26 | 26 | ||
| 27 | /// The constraints passed to the stack from its parent are tightened to the | 27 | /// The constraints passed to the stack from its parent are tightened to the |
| 28 | /// biggest size allowed. | 28 | /// biggest size allowed. |
| 29 | /// | 29 | /// |
| 30 | /// For example, if the sheet has loose constraints with a height in the | 30 | /// For example, if the sheet has loose constraints with a height in the |
| 31 | - /// range 0 to 600, then the child of the shhet would all be sized | 31 | + /// range 0 to 600, then the child of the sheet would all be sized |
| 32 | /// as 600 high. | 32 | /// as 600 high. |
| 33 | expand, | 33 | expand, |
| 34 | } | 34 | } |
| @@ -54,7 +54,7 @@ typedef SheetDecorationBuilder = Widget Function( | @@ -54,7 +54,7 @@ typedef SheetDecorationBuilder = Widget Function( | ||
| 54 | /// | 54 | /// |
| 55 | /// By default the bottom sheet inherits the values provided by the | 55 | /// By default the bottom sheet inherits the values provided by the |
| 56 | /// material theme and prioritize the ones passed in the constructor. | 56 | /// material theme and prioritize the ones passed in the constructor. |
| 57 | -/// Use [Sheet.raw] if you wish to remove the Material appareance and | 57 | +/// Use [Sheet.raw] if you wish to remove the Material appearance and |
| 58 | /// build your own | 58 | /// build your own |
| 59 | /// | 59 | /// |
| 60 | /// See also: | 60 | /// See also: |
| @@ -115,7 +115,7 @@ class Sheet extends StatelessWidget { | @@ -115,7 +115,7 @@ class Sheet extends StatelessWidget { | ||
| 115 | /// Empty space to surround the [child]. | 115 | /// Empty space to surround the [child]. |
| 116 | final EdgeInsets padding; | 116 | final EdgeInsets padding; |
| 117 | 117 | ||
| 118 | - /// The inital height to use when displaying the widget. | 118 | + /// The initial height to use when displaying the widget. |
| 119 | /// | 119 | /// |
| 120 | /// This value will be clamped between [minExtent] and [maxExtent] | 120 | /// This value will be clamped between [minExtent] and [maxExtent] |
| 121 | /// | 121 | /// |
| @@ -129,12 +129,12 @@ class Sheet extends StatelessWidget { | @@ -129,12 +129,12 @@ class Sheet extends StatelessWidget { | ||
| 129 | 129 | ||
| 130 | /// The maximum height to use when displaying the widget. | 130 | /// The maximum height to use when displaying the widget. |
| 131 | /// | 131 | /// |
| 132 | - /// This value will be clamped to be as maximun the parent container's height | 132 | + /// This value will be clamped to be as maximum the parent container's height |
| 133 | /// | 133 | /// |
| 134 | /// The default value is `double.infinity`. | 134 | /// The default value is `double.infinity`. |
| 135 | final double? maxExtent; | 135 | final double? maxExtent; |
| 136 | 136 | ||
| 137 | - /// The height area of the minimun interaction zone to allow to | 137 | + /// The height area of the minimum interaction zone to allow to |
| 138 | /// drag up the sheet when it is closed | 138 | /// drag up the sheet when it is closed |
| 139 | /// | 139 | /// |
| 140 | /// The default value is `0`. | 140 | /// The default value is `0`. |
| @@ -148,10 +148,10 @@ class Sheet extends StatelessWidget { | @@ -148,10 +148,10 @@ class Sheet extends StatelessWidget { | ||
| 148 | /// The default value is `false`. | 148 | /// The default value is `false`. |
| 149 | final bool resizable; | 149 | final bool resizable; |
| 150 | 150 | ||
| 151 | - /// If resizable true, the minimun height that the sheet can be. | 151 | + /// If resizable true, the minimum height that the sheet can be. |
| 152 | /// The content of the sheet will be resized to fit the | 152 | /// The content of the sheet will be resized to fit the |
| 153 | /// available visible space until this value, after that will be | 153 | /// available visible space until this value, after that will be |
| 154 | - /// translated keeping this minimun height. | 154 | + /// translated keeping this minimum height. |
| 155 | /// | 155 | /// |
| 156 | /// The default value is `0`. | 156 | /// The default value is `0`. |
| 157 | final double? minResizableExtent; | 157 | final double? minResizableExtent; |
| @@ -212,7 +212,7 @@ class Sheet extends StatelessWidget { | @@ -212,7 +212,7 @@ class Sheet extends StatelessWidget { | ||
| 212 | /// will be [Clip.none]. | 212 | /// will be [Clip.none]. |
| 213 | final Clip? clipBehavior; | 213 | final Clip? clipBehavior; |
| 214 | 214 | ||
| 215 | - /// Wraps the child in a custom sheet decoration appareance | 215 | + /// Wraps the child in a custom sheet decoration appearance |
| 216 | /// If null, the sheet has material appareance | 216 | /// If null, the sheet has material appareance |
| 217 | /// | 217 | /// |
| 218 | /// The default value is null. | 218 | /// The default value is null. |
| @@ -222,8 +222,7 @@ class Sheet extends StatelessWidget { | @@ -222,8 +222,7 @@ class Sheet extends StatelessWidget { | ||
| 222 | return child; | 222 | return child; |
| 223 | } | 223 | } |
| 224 | 224 | ||
| 225 | - @override | ||
| 226 | - Widget build(BuildContext context) { | 225 | + Widget decorationBuild(BuildContext context, Widget child) { |
| 227 | final SheetDecorationBuilder decorationBuilder = this.decorationBuilder ?? | 226 | final SheetDecorationBuilder decorationBuilder = this.decorationBuilder ?? |
| 228 | (BuildContext context, Widget child) { | 227 | (BuildContext context, Widget child) { |
| 229 | final BottomSheetThemeData bottomSheetTheme = | 228 | final BottomSheetThemeData bottomSheetTheme = |
| @@ -244,6 +243,11 @@ class Sheet extends StatelessWidget { | @@ -244,6 +243,11 @@ class Sheet extends StatelessWidget { | ||
| 244 | child: child, | 243 | child: child, |
| 245 | ); | 244 | ); |
| 246 | }; | 245 | }; |
| 246 | + return decorationBuilder(context, child); | ||
| 247 | + } | ||
| 248 | + | ||
| 249 | + @override | ||
| 250 | + Widget build(BuildContext context) { | ||
| 247 | final SheetController? effectiveController = | 251 | final SheetController? effectiveController = |
| 248 | controller ?? DefaultSheetController.of(context); | 252 | controller ?? DefaultSheetController.of(context); |
| 249 | final double? initialExtent = | 253 | final double? initialExtent = |
| @@ -254,7 +258,7 @@ class Sheet extends StatelessWidget { | @@ -254,7 +258,7 @@ class Sheet extends StatelessWidget { | ||
| 254 | physics: physics, | 258 | physics: physics, |
| 255 | controller: effectiveController, | 259 | controller: effectiveController, |
| 256 | axisDirection: AxisDirection.down, | 260 | axisDirection: AxisDirection.down, |
| 257 | - scrollBehavior: SheetBehaviour(), | 261 | + scrollBehavior: SheetBehavior(), |
| 258 | viewportBuilder: (BuildContext context, ViewportOffset offset) { | 262 | viewportBuilder: (BuildContext context, ViewportOffset offset) { |
| 259 | return _DefaultSheetScrollController( | 263 | return _DefaultSheetScrollController( |
| 260 | child: ScrollToTopStatusBarHandler( | 264 | child: ScrollToTopStatusBarHandler( |
| @@ -274,10 +278,7 @@ class Sheet extends StatelessWidget { | @@ -274,10 +278,7 @@ class Sheet extends StatelessWidget { | ||
| 274 | child: Builder( | 278 | child: Builder( |
| 275 | key: const Key('_sheet_child'), | 279 | key: const Key('_sheet_child'), |
| 276 | builder: (BuildContext context) { | 280 | builder: (BuildContext context) { |
| 277 | - return decorationBuilder( | ||
| 278 | - context, | ||
| 279 | - child, | ||
| 280 | - ); | 281 | + return decorationBuild(context, child); |
| 281 | }, | 282 | }, |
| 282 | ), | 283 | ), |
| 283 | ), | 284 | ), |
| @@ -317,12 +318,7 @@ class _DefaultSheetScrollController extends StatelessWidget { | @@ -317,12 +318,7 @@ class _DefaultSheetScrollController extends StatelessWidget { | ||
| 317 | /// * [SheetPosition], which manages the positioning logic for | 318 | /// * [SheetPosition], which manages the positioning logic for |
| 318 | /// this controller. | 319 | /// this controller. |
| 319 | class SheetController extends ScrollController { | 320 | class SheetController extends ScrollController { |
| 320 | - SheetController({ | ||
| 321 | - String? debugLabel, | ||
| 322 | - }) : super( | ||
| 323 | - debugLabel: debugLabel, | ||
| 324 | - initialScrollOffset: 0, | ||
| 325 | - ); | 321 | + SheetController({super.debugLabel}) : super(initialScrollOffset: 0); |
| 326 | 322 | ||
| 327 | final ProxyAnimation _animation = ProxyAnimation(); | 323 | final ProxyAnimation _animation = ProxyAnimation(); |
| 328 | Animation<double> get animation => _animation; | 324 | Animation<double> get animation => _animation; |
| @@ -411,20 +407,13 @@ class SheetController extends ScrollController { | @@ -411,20 +407,13 @@ class SheetController extends ScrollController { | ||
| 411 | /// * [_SheetScrollController], which uses this as its [ScrollPosition]. | 407 | /// * [_SheetScrollController], which uses this as its [ScrollPosition]. |
| 412 | class SheetPosition extends ScrollPositionWithSingleContext { | 408 | class SheetPosition extends ScrollPositionWithSingleContext { |
| 413 | SheetPosition({ | 409 | SheetPosition({ |
| 414 | - required ScrollPhysics physics, | ||
| 415 | - required SheetContext context, | ||
| 416 | - double initialPixels = 0.0, | ||
| 417 | - bool keepScrollOffset = true, | ||
| 418 | - ScrollPosition? oldPosition, | ||
| 419 | - String? debugLabel, | ||
| 420 | - }) : super( | ||
| 421 | - physics: physics, | ||
| 422 | - context: context, | ||
| 423 | - initialPixels: initialPixels, | ||
| 424 | - keepScrollOffset: keepScrollOffset, | ||
| 425 | - oldPosition: oldPosition, | ||
| 426 | - debugLabel: debugLabel, | ||
| 427 | - ); | 410 | + required super.physics, |
| 411 | + required SheetContext super.context, | ||
| 412 | + super.initialPixels = 0.0, | ||
| 413 | + super.keepScrollOffset = true, | ||
| 414 | + super.oldPosition, | ||
| 415 | + super.debugLabel, | ||
| 416 | + }); | ||
| 428 | 417 | ||
| 429 | late final SheetPrimaryScrollController _scrollController = | 418 | late final SheetPrimaryScrollController _scrollController = |
| 430 | SheetPrimaryScrollController(sheetContext: context as SheetContext); | 419 | SheetPrimaryScrollController(sheetContext: context as SheetContext); |
| @@ -540,15 +529,15 @@ class SheetPosition extends ScrollPositionWithSingleContext { | @@ -540,15 +529,15 @@ class SheetPosition extends ScrollPositionWithSingleContext { | ||
| 540 | 529 | ||
| 541 | class SheetViewport extends SingleChildRenderObjectWidget { | 530 | class SheetViewport extends SingleChildRenderObjectWidget { |
| 542 | const SheetViewport({ | 531 | const SheetViewport({ |
| 543 | - Key? key, | 532 | + super.key, |
| 544 | this.axisDirection = AxisDirection.down, | 533 | this.axisDirection = AxisDirection.down, |
| 545 | required this.offset, | 534 | required this.offset, |
| 546 | this.minExtent, | 535 | this.minExtent, |
| 547 | this.maxExtent, | 536 | this.maxExtent, |
| 548 | - Widget? child, | 537 | + super.child, |
| 549 | required this.fit, | 538 | required this.fit, |
| 550 | required this.clipBehavior, | 539 | required this.clipBehavior, |
| 551 | - }) : super(key: key, child: child); | 540 | + }); |
| 552 | 541 | ||
| 553 | final AxisDirection axisDirection; | 542 | final AxisDirection axisDirection; |
| 554 | final ViewportOffset offset; | 543 | final ViewportOffset offset; |
| @@ -801,13 +790,13 @@ class RenderSheetViewport extends RenderBox | @@ -801,13 +790,13 @@ class RenderSheetViewport extends RenderBox | ||
| 801 | minHeight = overflowHeight; | 790 | minHeight = overflowHeight; |
| 802 | } | 791 | } |
| 803 | 792 | ||
| 804 | - final BoxConstraints childContstraints = BoxConstraints( | 793 | + final BoxConstraints childConstraints = BoxConstraints( |
| 805 | minHeight: minHeight, | 794 | minHeight: minHeight, |
| 806 | maxHeight: maxHeight, | 795 | maxHeight: maxHeight, |
| 807 | minWidth: constraints.minWidth, | 796 | minWidth: constraints.minWidth, |
| 808 | maxWidth: constraints.maxWidth, | 797 | maxWidth: constraints.maxWidth, |
| 809 | ); | 798 | ); |
| 810 | - child!.layout(childContstraints, parentUsesSize: true); | 799 | + child!.layout(childConstraints, parentUsesSize: true); |
| 811 | size = constraints.biggest; | 800 | size = constraints.biggest; |
| 812 | } | 801 | } |
| 813 | 802 | ||
| @@ -955,7 +944,7 @@ class RenderSheetViewport extends RenderBox | @@ -955,7 +944,7 @@ class RenderSheetViewport extends RenderBox | ||
| 955 | Curve curve = Curves.ease, | 944 | Curve curve = Curves.ease, |
| 956 | }) { | 945 | }) { |
| 957 | return; | 946 | return; |
| 958 | - // TODO(jaime): check showOnScreen method beheves when keyboard appears on | 947 | + // TODO(jaime): check showOnScreen method behaves when keyboard appears on |
| 959 | // the screen | 948 | // the screen |
| 960 | // if (!offset.allowImplicitScrolling) { | 949 | // if (!offset.allowImplicitScrolling) { |
| 961 | // return super.showOnScreen( | 950 | // return super.showOnScreen( |
| @@ -3,7 +3,7 @@ import 'package:sheet/sheet.dart'; | @@ -3,7 +3,7 @@ import 'package:sheet/sheet.dart'; | ||
| 3 | 3 | ||
| 4 | typedef SheetControllerCallback = void Function(SheetController controller); | 4 | typedef SheetControllerCallback = void Function(SheetController controller); |
| 5 | 5 | ||
| 6 | -/// A widget that injets a [SheetController] that can be used by | 6 | +/// A widget that injects a [SheetController] that can be used by |
| 7 | /// any [Sheet] children | 7 | /// any [Sheet] children |
| 8 | /// | 8 | /// |
| 9 | /// It is useful for creating initial animations | 9 | /// It is useful for creating initial animations |
sheet/lib/src/widgets/material_sheet.dart
0 → 100644
| 1 | +import 'package:flutter/material.dart'; | ||
| 2 | +import 'package:sheet/sheet.dart'; | ||
| 3 | + | ||
| 4 | +class MaterialSheet extends Sheet { | ||
| 5 | + const MaterialSheet({ | ||
| 6 | + super.key, | ||
| 7 | + required super.child, | ||
| 8 | + super.controller, | ||
| 9 | + super.physics, | ||
| 10 | + super.initialExtent, | ||
| 11 | + super.minExtent, | ||
| 12 | + super.maxExtent, | ||
| 13 | + super.minInteractionExtent = 20.0, | ||
| 14 | + super.backgroundColor, | ||
| 15 | + super.clipBehavior, | ||
| 16 | + super.shape, | ||
| 17 | + super.elevation, | ||
| 18 | + super.fit = SheetFit.loose, | ||
| 19 | + super.resizable = false, | ||
| 20 | + super.padding = EdgeInsets.zero, | ||
| 21 | + super.minResizableExtent, | ||
| 22 | + }); | ||
| 23 | + | ||
| 24 | + @override | ||
| 25 | + Widget decorationBuild(BuildContext context, Widget child) { | ||
| 26 | + final BottomSheetThemeData bottomSheetTheme = | ||
| 27 | + Theme.of(context).bottomSheetTheme; | ||
| 28 | + final Color? color = backgroundColor ?? bottomSheetTheme.backgroundColor; | ||
| 29 | + final double elevation = this.elevation ?? bottomSheetTheme.elevation ?? 0; | ||
| 30 | + final ShapeBorder? shape = this.shape ?? bottomSheetTheme.shape; | ||
| 31 | + final Clip clipBehavior = | ||
| 32 | + this.clipBehavior ?? bottomSheetTheme.clipBehavior ?? Clip.none; | ||
| 33 | + | ||
| 34 | + return Material( | ||
| 35 | + color: color, | ||
| 36 | + elevation: elevation, | ||
| 37 | + shape: shape, | ||
| 38 | + clipBehavior: clipBehavior, | ||
| 39 | + child: child, | ||
| 40 | + ); | ||
| 41 | + } | ||
| 42 | +} |
| @@ -5,26 +5,26 @@ packages: | @@ -5,26 +5,26 @@ packages: | ||
| 5 | dependency: transitive | 5 | dependency: transitive |
| 6 | description: | 6 | description: |
| 7 | name: _fe_analyzer_shared | 7 | name: _fe_analyzer_shared |
| 8 | - sha256: "0c80aeab9bc807ab10022cd3b2f4cf2ecdf231949dc1ddd9442406a003f19201" | 8 | + sha256: ae92f5d747aee634b87f89d9946000c2de774be1d6ac3e58268224348cd0101a |
| 9 | url: "https://pub.dev" | 9 | url: "https://pub.dev" |
| 10 | source: hosted | 10 | source: hosted |
| 11 | - version: "52.0.0" | 11 | + version: "61.0.0" |
| 12 | analyzer: | 12 | analyzer: |
| 13 | dependency: transitive | 13 | dependency: transitive |
| 14 | description: | 14 | description: |
| 15 | name: analyzer | 15 | name: analyzer |
| 16 | - sha256: cd8ee83568a77f3ae6b913a36093a1c9b1264e7cb7f834d9ddd2311dade9c1f4 | 16 | + sha256: ea3d8652bda62982addfd92fdc2d0214e5f82e43325104990d4f4c4a2a313562 |
| 17 | url: "https://pub.dev" | 17 | url: "https://pub.dev" |
| 18 | source: hosted | 18 | source: hosted |
| 19 | - version: "5.4.0" | 19 | + version: "5.13.0" |
| 20 | args: | 20 | args: |
| 21 | dependency: transitive | 21 | dependency: transitive |
| 22 | description: | 22 | description: |
| 23 | name: args | 23 | name: args |
| 24 | - sha256: "139d809800a412ebb26a3892da228b2d0ba36f0ef5d9a82166e5e52ec8d61611" | 24 | + sha256: eef6c46b622e0494a36c5a12d10d77fb4e855501a91c1b9ef9339326e58f0596 |
| 25 | url: "https://pub.dev" | 25 | url: "https://pub.dev" |
| 26 | source: hosted | 26 | source: hosted |
| 27 | - version: "2.3.2" | 27 | + version: "2.4.2" |
| 28 | async: | 28 | async: |
| 29 | dependency: transitive | 29 | dependency: transitive |
| 30 | description: | 30 | description: |
| @@ -77,18 +77,18 @@ packages: | @@ -77,18 +77,18 @@ packages: | ||
| 77 | dependency: transitive | 77 | dependency: transitive |
| 78 | description: | 78 | description: |
| 79 | name: coverage | 79 | name: coverage |
| 80 | - sha256: "961c4aebd27917269b1896382c7cb1b1ba81629ba669ba09c27a7e5710ec9040" | 80 | + sha256: "595a29b55ce82d53398e1bcc2cba525d7bd7c59faeb2d2540e9d42c390cfeeeb" |
| 81 | url: "https://pub.dev" | 81 | url: "https://pub.dev" |
| 82 | source: hosted | 82 | source: hosted |
| 83 | - version: "1.6.2" | 83 | + version: "1.6.4" |
| 84 | crypto: | 84 | crypto: |
| 85 | dependency: transitive | 85 | dependency: transitive |
| 86 | description: | 86 | description: |
| 87 | name: crypto | 87 | name: crypto |
| 88 | - sha256: aa274aa7774f8964e4f4f38cc994db7b6158dd36e9187aaceaddc994b35c6c67 | 88 | + sha256: ff625774173754681d66daaf4a448684fb04b78f902da9cb3d308c19cc5e8bab |
| 89 | url: "https://pub.dev" | 89 | url: "https://pub.dev" |
| 90 | source: hosted | 90 | source: hosted |
| 91 | - version: "3.0.2" | 91 | + version: "3.0.3" |
| 92 | fake_async: | 92 | fake_async: |
| 93 | dependency: transitive | 93 | dependency: transitive |
| 94 | description: | 94 | description: |
| @@ -101,10 +101,10 @@ packages: | @@ -101,10 +101,10 @@ packages: | ||
| 101 | dependency: transitive | 101 | dependency: transitive |
| 102 | description: | 102 | description: |
| 103 | name: file | 103 | name: file |
| 104 | - sha256: "1b92bec4fc2a72f59a8e15af5f52cd441e4a7860b49499d69dfa817af20e925d" | 104 | + sha256: "5fc22d7c25582e38ad9a8515372cd9a93834027aacf1801cf01164dac0ffa08c" |
| 105 | url: "https://pub.dev" | 105 | url: "https://pub.dev" |
| 106 | source: hosted | 106 | source: hosted |
| 107 | - version: "6.1.4" | 107 | + version: "7.0.0" |
| 108 | flutter: | 108 | flutter: |
| 109 | dependency: "direct main" | 109 | dependency: "direct main" |
| 110 | description: flutter | 110 | description: flutter |
| @@ -127,10 +127,10 @@ packages: | @@ -127,10 +127,10 @@ packages: | ||
| 127 | dependency: transitive | 127 | dependency: transitive |
| 128 | description: | 128 | description: |
| 129 | name: glob | 129 | name: glob |
| 130 | - sha256: "4515b5b6ddb505ebdd242a5f2cc5d22d3d6a80013789debfbda7777f47ea308c" | 130 | + sha256: "0e7014b3b7d4dac1ca4d6114f82bf1782ee86745b9b42a92c9289c23d8a0ab63" |
| 131 | url: "https://pub.dev" | 131 | url: "https://pub.dev" |
| 132 | source: hosted | 132 | source: hosted |
| 133 | - version: "2.1.1" | 133 | + version: "2.1.2" |
| 134 | http_multi_server: | 134 | http_multi_server: |
| 135 | dependency: transitive | 135 | dependency: transitive |
| 136 | description: | 136 | description: |
| @@ -159,26 +159,26 @@ packages: | @@ -159,26 +159,26 @@ packages: | ||
| 159 | dependency: transitive | 159 | dependency: transitive |
| 160 | description: | 160 | description: |
| 161 | name: js | 161 | name: js |
| 162 | - sha256: "5528c2f391ededb7775ec1daa69e65a2d61276f7552de2b5f7b8d34ee9fd4ab7" | 162 | + sha256: f2c445dce49627136094980615a031419f7f3eb393237e4ecd97ac15dea343f3 |
| 163 | url: "https://pub.dev" | 163 | url: "https://pub.dev" |
| 164 | source: hosted | 164 | source: hosted |
| 165 | - version: "0.6.5" | 165 | + version: "0.6.7" |
| 166 | lints: | 166 | lints: |
| 167 | dependency: "direct dev" | 167 | dependency: "direct dev" |
| 168 | description: | 168 | description: |
| 169 | name: lints | 169 | name: lints |
| 170 | - sha256: "5e4a9cd06d447758280a8ac2405101e0e2094d2a1dbdd3756aec3fe7775ba593" | 170 | + sha256: "0a217c6c989d21039f1498c3ed9f3ed71b354e69873f13a8dfc3c9fe76f1b452" |
| 171 | url: "https://pub.dev" | 171 | url: "https://pub.dev" |
| 172 | source: hosted | 172 | source: hosted |
| 173 | - version: "2.0.1" | 173 | + version: "2.1.1" |
| 174 | logging: | 174 | logging: |
| 175 | dependency: transitive | 175 | dependency: transitive |
| 176 | description: | 176 | description: |
| 177 | name: logging | 177 | name: logging |
| 178 | - sha256: c0bbfe94d46aedf9b8b3e695cf3bd48c8e14b35e3b2c639e0aa7755d589ba946 | 178 | + sha256: "623a88c9594aa774443aa3eb2d41807a48486b5613e67599fb4c41c0ad47c340" |
| 179 | url: "https://pub.dev" | 179 | url: "https://pub.dev" |
| 180 | source: hosted | 180 | source: hosted |
| 181 | - version: "1.1.0" | 181 | + version: "1.2.0" |
| 182 | matcher: | 182 | matcher: |
| 183 | dependency: transitive | 183 | dependency: transitive |
| 184 | description: | 184 | description: |
| @@ -223,10 +223,10 @@ packages: | @@ -223,10 +223,10 @@ packages: | ||
| 223 | dependency: transitive | 223 | dependency: transitive |
| 224 | description: | 224 | description: |
| 225 | name: node_preamble | 225 | name: node_preamble |
| 226 | - sha256: "8ebdbaa3b96d5285d068f80772390d27c21e1fa10fb2df6627b1b9415043608d" | 226 | + sha256: "6e7eac89047ab8a8d26cf16127b5ed26de65209847630400f9aefd7cd5c730db" |
| 227 | url: "https://pub.dev" | 227 | url: "https://pub.dev" |
| 228 | source: hosted | 228 | source: hosted |
| 229 | - version: "2.0.1" | 229 | + version: "2.0.2" |
| 230 | package_config: | 230 | package_config: |
| 231 | dependency: transitive | 231 | dependency: transitive |
| 232 | description: | 232 | description: |
| @@ -255,42 +255,42 @@ packages: | @@ -255,42 +255,42 @@ packages: | ||
| 255 | dependency: transitive | 255 | dependency: transitive |
| 256 | description: | 256 | description: |
| 257 | name: pub_semver | 257 | name: pub_semver |
| 258 | - sha256: "307de764d305289ff24ad257ad5c5793ce56d04947599ad68b3baa124105fc17" | 258 | + sha256: "40d3ab1bbd474c4c2328c91e3a7df8c6dd629b79ece4c4bd04bee496a224fb0c" |
| 259 | url: "https://pub.dev" | 259 | url: "https://pub.dev" |
| 260 | source: hosted | 260 | source: hosted |
| 261 | - version: "2.1.3" | 261 | + version: "2.1.4" |
| 262 | shelf: | 262 | shelf: |
| 263 | dependency: transitive | 263 | dependency: transitive |
| 264 | description: | 264 | description: |
| 265 | name: shelf | 265 | name: shelf |
| 266 | - sha256: c24a96135a2ccd62c64b69315a14adc5c3419df63b4d7c05832a346fdb73682c | 266 | + sha256: ad29c505aee705f41a4d8963641f91ac4cee3c8fad5947e033390a7bd8180fa4 |
| 267 | url: "https://pub.dev" | 267 | url: "https://pub.dev" |
| 268 | source: hosted | 268 | source: hosted |
| 269 | - version: "1.4.0" | 269 | + version: "1.4.1" |
| 270 | shelf_packages_handler: | 270 | shelf_packages_handler: |
| 271 | dependency: transitive | 271 | dependency: transitive |
| 272 | description: | 272 | description: |
| 273 | name: shelf_packages_handler | 273 | name: shelf_packages_handler |
| 274 | - sha256: aef74dc9195746a384843102142ab65b6a4735bb3beea791e63527b88cc83306 | 274 | + sha256: "89f967eca29607c933ba9571d838be31d67f53f6e4ee15147d5dc2934fee1b1e" |
| 275 | url: "https://pub.dev" | 275 | url: "https://pub.dev" |
| 276 | source: hosted | 276 | source: hosted |
| 277 | - version: "3.0.1" | 277 | + version: "3.0.2" |
| 278 | shelf_static: | 278 | shelf_static: |
| 279 | dependency: transitive | 279 | dependency: transitive |
| 280 | description: | 280 | description: |
| 281 | name: shelf_static | 281 | name: shelf_static |
| 282 | - sha256: e792b76b96a36d4a41b819da593aff4bdd413576b3ba6150df5d8d9996d2e74c | 282 | + sha256: a41d3f53c4adf0f57480578c1d61d90342cd617de7fc8077b1304643c2d85c1e |
| 283 | url: "https://pub.dev" | 283 | url: "https://pub.dev" |
| 284 | source: hosted | 284 | source: hosted |
| 285 | - version: "1.1.1" | 285 | + version: "1.1.2" |
| 286 | shelf_web_socket: | 286 | shelf_web_socket: |
| 287 | dependency: transitive | 287 | dependency: transitive |
| 288 | description: | 288 | description: |
| 289 | name: shelf_web_socket | 289 | name: shelf_web_socket |
| 290 | - sha256: a988c0e8d8ffbdb8a28aa7ec8e449c260f3deb808781fe1284d22c5bba7156e8 | 290 | + sha256: "9ca081be41c60190ebcb4766b2486a7d50261db7bd0f5d9615f2d653637a84c1" |
| 291 | url: "https://pub.dev" | 291 | url: "https://pub.dev" |
| 292 | source: hosted | 292 | source: hosted |
| 293 | - version: "1.0.3" | 293 | + version: "1.0.4" |
| 294 | sky_engine: | 294 | sky_engine: |
| 295 | dependency: transitive | 295 | dependency: transitive |
| 296 | description: flutter | 296 | description: flutter |
| @@ -308,10 +308,10 @@ packages: | @@ -308,10 +308,10 @@ packages: | ||
| 308 | dependency: transitive | 308 | dependency: transitive |
| 309 | description: | 309 | description: |
| 310 | name: source_maps | 310 | name: source_maps |
| 311 | - sha256: "490098075234dcedb83c5d949b4c93dad5e6b7702748de000be2b57b8e6b2427" | 311 | + sha256: "708b3f6b97248e5781f493b765c3337db11c5d2c81c3094f10904bfa8004c703" |
| 312 | url: "https://pub.dev" | 312 | url: "https://pub.dev" |
| 313 | source: hosted | 313 | source: hosted |
| 314 | - version: "0.10.11" | 314 | + version: "0.10.12" |
| 315 | source_span: | 315 | source_span: |
| 316 | dependency: transitive | 316 | dependency: transitive |
| 317 | description: | 317 | description: |
| @@ -380,10 +380,10 @@ packages: | @@ -380,10 +380,10 @@ packages: | ||
| 380 | dependency: transitive | 380 | dependency: transitive |
| 381 | description: | 381 | description: |
| 382 | name: typed_data | 382 | name: typed_data |
| 383 | - sha256: "26f87ade979c47a150c9eaab93ccd2bebe70a27dc0b4b29517f2904f04eb11a5" | 383 | + sha256: facc8d6582f16042dd49f2463ff1bd6e2c9ef9f3d5da3d9b087e244a7b564b3c |
| 384 | url: "https://pub.dev" | 384 | url: "https://pub.dev" |
| 385 | source: hosted | 385 | source: hosted |
| 386 | - version: "1.3.1" | 386 | + version: "1.3.2" |
| 387 | vector_math: | 387 | vector_math: |
| 388 | dependency: transitive | 388 | dependency: transitive |
| 389 | description: | 389 | description: |
| @@ -396,18 +396,18 @@ packages: | @@ -396,18 +396,18 @@ packages: | ||
| 396 | dependency: transitive | 396 | dependency: transitive |
| 397 | description: | 397 | description: |
| 398 | name: vm_service | 398 | name: vm_service |
| 399 | - sha256: e7fb6c2282f7631712b69c19d1bff82f3767eea33a2321c14fa59ad67ea391c7 | 399 | + sha256: c538be99af830f478718b51630ec1b6bee5e74e52c8a802d328d9e71d35d2583 |
| 400 | url: "https://pub.dev" | 400 | url: "https://pub.dev" |
| 401 | source: hosted | 401 | source: hosted |
| 402 | - version: "9.4.0" | 402 | + version: "11.10.0" |
| 403 | watcher: | 403 | watcher: |
| 404 | dependency: transitive | 404 | dependency: transitive |
| 405 | description: | 405 | description: |
| 406 | name: watcher | 406 | name: watcher |
| 407 | - sha256: "6a7f46926b01ce81bfc339da6a7f20afbe7733eff9846f6d6a5466aa4c6667c0" | 407 | + sha256: "3d2ad6751b3c16cf07c7fca317a1413b3f26530319181b37e3b9039b84fc01d8" |
| 408 | url: "https://pub.dev" | 408 | url: "https://pub.dev" |
| 409 | source: hosted | 409 | source: hosted |
| 410 | - version: "1.0.2" | 410 | + version: "1.1.0" |
| 411 | web: | 411 | web: |
| 412 | dependency: transitive | 412 | dependency: transitive |
| 413 | description: | 413 | description: |
| @@ -420,26 +420,25 @@ packages: | @@ -420,26 +420,25 @@ packages: | ||
| 420 | dependency: transitive | 420 | dependency: transitive |
| 421 | description: | 421 | description: |
| 422 | name: web_socket_channel | 422 | name: web_socket_channel |
| 423 | - sha256: ca49c0bc209c687b887f30527fb6a9d80040b072cc2990f34b9bec3e7663101b | 423 | + sha256: d88238e5eac9a42bb43ca4e721edba3c08c6354d4a53063afaa568516217621b |
| 424 | url: "https://pub.dev" | 424 | url: "https://pub.dev" |
| 425 | source: hosted | 425 | source: hosted |
| 426 | - version: "2.3.0" | 426 | + version: "2.4.0" |
| 427 | webkit_inspection_protocol: | 427 | webkit_inspection_protocol: |
| 428 | dependency: transitive | 428 | dependency: transitive |
| 429 | description: | 429 | description: |
| 430 | name: webkit_inspection_protocol | 430 | name: webkit_inspection_protocol |
| 431 | - sha256: "67d3a8b6c79e1987d19d848b0892e582dbb0c66c57cc1fef58a177dd2aa2823d" | 431 | + sha256: "87d3f2333bb240704cd3f1c6b5b7acd8a10e7f0bc28c28dcf14e782014f4a572" |
| 432 | url: "https://pub.dev" | 432 | url: "https://pub.dev" |
| 433 | source: hosted | 433 | source: hosted |
| 434 | - version: "1.2.0" | 434 | + version: "1.2.1" |
| 435 | yaml: | 435 | yaml: |
| 436 | dependency: transitive | 436 | dependency: transitive |
| 437 | description: | 437 | description: |
| 438 | name: yaml | 438 | name: yaml |
| 439 | - sha256: "23812a9b125b48d4007117254bca50abb6c712352927eece9e155207b1db2370" | 439 | + sha256: "75769501ea3489fca56601ff33454fe45507ea3bfb014161abc3b43ae25989d5" |
| 440 | url: "https://pub.dev" | 440 | url: "https://pub.dev" |
| 441 | source: hosted | 441 | source: hosted |
| 442 | - version: "3.1.1" | 442 | + version: "3.1.2" |
| 443 | sdks: | 443 | sdks: |
| 444 | dart: ">=3.1.0-185.0.dev <4.0.0" | 444 | dart: ">=3.1.0-185.0.dev <4.0.0" |
| 445 | - flutter: ">=3.7.0" |
| @@ -5,7 +5,6 @@ homepage: https://github.com/jamesblasco/modal_bottom_sheet | @@ -5,7 +5,6 @@ homepage: https://github.com/jamesblasco/modal_bottom_sheet | ||
| 5 | 5 | ||
| 6 | environment: | 6 | environment: |
| 7 | sdk: ">=2.17.0 <3.0.0" | 7 | sdk: ">=2.17.0 <3.0.0" |
| 8 | - flutter: ">=3.7.0" | ||
| 9 | 8 | ||
| 10 | dependencies: | 9 | dependencies: |
| 11 | flutter: | 10 | flutter: |
| @@ -15,6 +14,6 @@ dev_dependencies: | @@ -15,6 +14,6 @@ dev_dependencies: | ||
| 15 | flutter_test: | 14 | flutter_test: |
| 16 | sdk: flutter | 15 | sdk: flutter |
| 17 | mocktail: ^0.3.0 | 16 | mocktail: ^0.3.0 |
| 18 | - lints: ^2.0.0 | 17 | + lints: ^2.1.1 |
| 19 | 18 | ||
| 20 | flutter: | 19 | flutter: |
| @@ -11,7 +11,6 @@ void main() { | @@ -11,7 +11,6 @@ void main() { | ||
| 11 | testWidgets('defaultTestSize', (WidgetTester tester) async { | 11 | testWidgets('defaultTestSize', (WidgetTester tester) async { |
| 12 | final Size testSize = | 12 | final Size testSize = |
| 13 | tester.view.physicalSize / tester.view.devicePixelRatio; | 13 | tester.view.physicalSize / tester.view.devicePixelRatio; |
| 14 | - | ||
| 15 | expect(testSize, equals(kScreenSize)); | 14 | expect(testSize, equals(kScreenSize)); |
| 16 | }); | 15 | }); |
| 17 | } | 16 | } |
| @@ -77,21 +77,21 @@ void main() { | @@ -77,21 +77,21 @@ void main() { | ||
| 77 | 77 | ||
| 78 | test('overscroll is progressively harder', () { | 78 | test('overscroll is progressively harder', () { |
| 79 | final ScrollMetrics lessOverscrolledPosition = FixedScrollMetrics( | 79 | final ScrollMetrics lessOverscrolledPosition = FixedScrollMetrics( |
| 80 | - devicePixelRatio: 1, | ||
| 81 | minScrollExtent: 0.0, | 80 | minScrollExtent: 0.0, |
| 82 | maxScrollExtent: 1000.0, | 81 | maxScrollExtent: 1000.0, |
| 83 | pixels: -20.0, | 82 | pixels: -20.0, |
| 84 | viewportDimension: 100.0, | 83 | viewportDimension: 100.0, |
| 85 | axisDirection: AxisDirection.down, | 84 | axisDirection: AxisDirection.down, |
| 85 | + devicePixelRatio: 1, | ||
| 86 | ); | 86 | ); |
| 87 | 87 | ||
| 88 | final ScrollMetrics moreOverscrolledPosition = FixedScrollMetrics( | 88 | final ScrollMetrics moreOverscrolledPosition = FixedScrollMetrics( |
| 89 | minScrollExtent: 0.0, | 89 | minScrollExtent: 0.0, |
| 90 | - devicePixelRatio: 1, | ||
| 91 | maxScrollExtent: 1000.0, | 90 | maxScrollExtent: 1000.0, |
| 92 | pixels: -40.0, | 91 | pixels: -40.0, |
| 93 | viewportDimension: 100.0, | 92 | viewportDimension: 100.0, |
| 94 | axisDirection: AxisDirection.down, | 93 | axisDirection: AxisDirection.down, |
| 94 | + devicePixelRatio: 1, | ||
| 95 | ); | 95 | ); |
| 96 | 96 | ||
| 97 | final double lessOverscrollApplied = physicsUnderTest | 97 | final double lessOverscrollApplied = physicsUnderTest |
| @@ -116,11 +116,11 @@ void main() { | @@ -116,11 +116,11 @@ void main() { | ||
| 116 | test('easing an overscroll still has resistance', () { | 116 | test('easing an overscroll still has resistance', () { |
| 117 | final ScrollMetrics overscrolledPosition = FixedScrollMetrics( | 117 | final ScrollMetrics overscrolledPosition = FixedScrollMetrics( |
| 118 | minScrollExtent: 0.0, | 118 | minScrollExtent: 0.0, |
| 119 | - devicePixelRatio: 1, | ||
| 120 | maxScrollExtent: 1000.0, | 119 | maxScrollExtent: 1000.0, |
| 121 | pixels: -20.0, | 120 | pixels: -20.0, |
| 122 | viewportDimension: 100.0, | 121 | viewportDimension: 100.0, |
| 123 | axisDirection: AxisDirection.down, | 122 | axisDirection: AxisDirection.down, |
| 123 | + devicePixelRatio: 1, | ||
| 124 | ); | 124 | ); |
| 125 | 125 | ||
| 126 | final double easingApplied = physicsUnderTest.applyPhysicsToUserOffset( | 126 | final double easingApplied = physicsUnderTest.applyPhysicsToUserOffset( |
| @@ -154,10 +154,10 @@ void main() { | @@ -154,10 +154,10 @@ void main() { | ||
| 154 | final ScrollMetrics overscrolledPosition = FixedScrollMetrics( | 154 | final ScrollMetrics overscrolledPosition = FixedScrollMetrics( |
| 155 | minScrollExtent: 0.0, | 155 | minScrollExtent: 0.0, |
| 156 | maxScrollExtent: 1000.0, | 156 | maxScrollExtent: 1000.0, |
| 157 | - devicePixelRatio: 1, | ||
| 158 | pixels: -20.0, | 157 | pixels: -20.0, |
| 159 | viewportDimension: 100.0, | 158 | viewportDimension: 100.0, |
| 160 | axisDirection: AxisDirection.down, | 159 | axisDirection: AxisDirection.down, |
| 160 | + devicePixelRatio: 1, | ||
| 161 | ); | 161 | ); |
| 162 | 162 | ||
| 163 | final double easingApplied = physicsUnderTest.applyPhysicsToUserOffset( | 163 | final double easingApplied = physicsUnderTest.applyPhysicsToUserOffset( |
-
Please register or login to post a comment