Download this source code for
5 USD


Download this source code for
5 USD


Download this source code for
5 USD


Download this source code for
5 USD

flutter gallery

flutter gallery is a resource to help developers evaluate and use flutter. it is a collection of material design & cupertino widgets, behaviors, and vignettes implemented with flutter. we often get asked how one can see flutter in action, and this gallery demonstrates what flutter provides and how it behaves in the wild.

running flutter gallery on flutter’s master channel

the flutter gallery targets flutter’s master channel. as such, it can take advantage
of new sdk features that haven’t landed in the stable channel.

if you’d like to run the flutter gallery, make sure to switch to the master channel
first:

flutter channel master
flutter upgrade

when you’re done, use this command to return to the safety of the stable
channel:

flutter channel stable
flutter upgrade

supported platforms

flutter gallery has been built to support multiple platforms.
this includes:

  • android
  • ios
  • web
  • macos
  • linux
  • windows

that being said, extra steps must be taken to enable desktop support. for
example, to run the macos app:

cd gallery/
flutter config --enable-macos-desktop
flutter create .
flutter run -d macos

additionally, the ui adapts between mobile and desktop layouts regardless of the
platform it runs on. this is determined based on window size as outlined in
adaptive.dart.

to include a new splash animation

  1. convert your animation to a .gif file.
    ideally, use a background color of 0xff030303 to ensure the animation
    blends into the background of the app.
  2. add your new .gif file to the assets directory under
    assets/splash_effects. ensure the name follows the format
    splash_effect_$num.gif. the number should be the next number after the
    current largest number in the repository.
  3. update the map _effectdurations in
    splash.dart to include the number of the
    new .gif as well as its estimated duration. the duration is used to
    determine how long to display the splash animation at launch.

generating localized strings and highlighted code segments

to generate localized strings or highlighted code segments, make sure that you
have grinder installed. you can install it
by getting the packages in samples/gallery/:

flutter pub get

to generate localized strings (see separate readme
for more details):

flutter pub run grinder l10n

to generate code segments (see separate readme for
more details):

flutter pub run grinder update-code-segments

creating a new release (for flutter org members)

  1. bump the version number up in the pubspec.yaml. use semantic versioning to determine
    which number to increment. for example 2.2.0+020200 should become 2.3.0+020300.
  2. create a tag on the master branch of this repo in the form of v2.3.
    • git tag v2.3
    • git push --tags
  3. publish the web release (using the peanut package).
    • flutter pub global activate peanut
    • flutter pub global run peanut:peanut
    • git push upstream gh-pages:gh-pages
      • git update-ref refs/heads/gh-pages upstream/gh-pages if you need to align with upstream.
  4. publish the android release (using the correct signing certificates).
    • create the app bundle with flutter build appbundle.
    • upload to the play store console.
    • publish the play store release.
    • create the apk with flutter build apk (this is for the github release).
  5. draft a release in github from the tag you created, call the release flutter gallery 2.x
    • upload the android apk from above.
    • create and upload the macos build by running flutter build macos and zipping the
      app inside build/macos/build/products/release.
    • optional: create and upload the linux/windows builds.
    • publish the release.

Download this source code for
5 USD


Download this source code for
5 USD


Download this source code for
5 USD


Download this source code for
5 USD

Comments are closed.