at_widgets icon indicating copy to clipboard operation
at_widgets copied to clipboard

refactor(at_onboarding_flutter): Add modular support to at_onboarding_flutter

Open xavierchanth opened this issue 1 year ago • 1 comments

Many components and workflows in at_onboarding_flutter are not or reusable.

I want to refactor at_onboarding_flutter into 3 layers:

  • Pages

    the existing option / interface

  • Widgets

    the buttons and stuff currently hard coded into the pages, so parts can be embedded

  • Libraries

    at_onboarding doesn't contain any of the keychain / platform dependent code so we must make an interface available in at_onboarding_flutter which wraps the behavior underlying each of the widgets

With this change there are a few other considerations I've thought about:

  • Make it possible to control which widgets are included in the pages as a configurable list

    I've experimented with closures in the past, but they don't update when hot reloading flutter apps, so I'll see if I can come up with something static that also propogates state efficiently (maybe I lacked passing keys to the widgets, which is why the tree wouldn't update properly, it's been a while)

  • Adding the APKAM widgets, with a more modular design they can be developed in parallel without dealing with the troubles of the nested widget code.

  • I may consider starting with a blank slate, porting the old code into the new design piece by piece, simplifying behavior as I go.

xavierchanth avatar Nov 08 '24 14:11 xavierchanth