Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Added demo scene with barebones connect UI page. Created implementation for a basic scale tweening animation. * Added logic to switch UI pages, supports 'back' (needs to be mapped to the back key on various platforms, but for now, we have a UI button). Added a very minimal login screen for testing this out. * Added a UIPage class that contains the base logic for a UI screen/page (e.g. open/close methods) and made ConnectPage and LoginPage inherrit from it * Refactor SequenceUI so that it no longer uses UIStates and instead calls the open/close methods on the UIPages directly. * Add basic UI. For some reason this wasn't saved properly and wasn't included in my previous commit and I had to rebuild it... *sigh* * Added a panel behind the UI * Moved UI scripts into a folder * Added the ability to choose from a set of tweening presets (implementing the ITween interface) to animate the various UI pages. The main UI panel now scrolls in from the bottom * Wait for panel to animate onto the screen before animating in the first UI page * Basic login page * Made the login page the first page and hooked up buttons on login page such that they debug.log what they are supposed to do when clicked * Added a color scheme manager that allows you to automatically reskin the UI by creating a scriptable object via 'Assets>Create>Sequence>Color Scheme', setting it as the color scheme in the ColorSchemeManager monobehaviour/gameobject, and clicking Apply in the inspector * Added dark colour scheme * Added login success page * Added login handler to the login page - this is an ILogin and is designed to handle the login request. Currently, mocking the login. Upon success or failed login, an ILogin will emit an appropriate event. SequenceUI is a subscriber to this event. * Move to login success page upon login success. Fixed UI transition animations (didn't have animations out) * Added an IValidator interface that is used to validate inputs. For now, there is only email validation - I have both a real (with tests) and mocked implementation of IValidator * Moved SequenceIndexer into its own assembly - referencing SequenceEthereum. Created assembly for SequenceExamples - referencing all the other Sequence assemblies (minus test assemblies) in the project. Finally, create a SequenceExamplesTests assembly for any tests related to the SequenceExamples and renamed our other test assembly from Tests to SequenceTests for clarity. * Created a new directory (Authentication) and assembly (SequenceAuthentication) under SequenceSDK and moved the authentication-related logic out of SequenceExamples and into Authentication. * Created base MFA page * Updated readme * Display MFA page and add mocked functionality to it * Fixed runtime error and erase 2fa code whenever revisiting the page * Only display back button when usable * Don't overwrite text that is transparrent with different colors * Moved SequenceUI monobehaviour off of the Panel and onto the canvas, made it stop being a UIPage. Instead, created a UIPanel which inherrits from UIPage - this is used to create the LoginPanel and will be used for the WalletPanel as well * Setup for UI integration tests * Setup for multiple UI tests * Added additional integration tests for sample UI login flow. Run all UI tests in one test so we don't have to setup and teardown the scene each time - makes test suite faster. * Updated Makefile to run both edit mode and play mode tests when running 'make test' * Added scroll view, creating NFT prefab (to be instantiated), created generic object pool * Added 'powered by sequence' to the bottom of the grid layout * UIPanels hold their initial page * Added support for newly supported indexer chains * Added IIndexer and implementation (ChainIndexer) - this is basically just Indexer.cs with the static methods extracted, no longer requiring chain id as a parameter, instead chain Id is provided in the constructor. * Fetch nft content when opening WalletPage - for now this is mocked * Switch to event-driven implementation for fetching as opposed to coroutine * Instantiate images in wallet view * Don't make ObjectPool a monobehaviour * Fix scaling issues * Fix animation * Subscribe to scroll event * Update scroll view size based on number of fetched objects * Allow object pool to grow. Previously wanted to recycle the elements in the pool; however, since the layout of the objects is managed by the grid layout group, anytime one of the elements is removed, the rest are shifted up and are also removed. Instead, we simply allow the object pool to grow as needed - this should still perform well on initial load, but has the potential to create slowdowns if the user has a bunch of NFTs to display. * Cleanup object pool when closing wallet page * Navigate to wallet panel and wallet page * Setup UI test harness so that we can run separate tests for the login flow and the wallet flow. Running these separately (as opposed to all in one test) feels like a happy middleground to me in terms of test runtime vs clarity (to pinpoint the issue) when tests fail. * Moved opening of next panel into a separate function that has a separate on click listener for the buttons. The functionality is the same as before, except, now it is easier to customize (developers can simply disable the Open{PanelName} on click listener and replace with some other panel to open next) * Test that we fetch enough items (random between 0 and 1000) and test that the branding stays at the bottom of the page * Fix ColorSchemeManager such that all panels have their colors modified when applying a new color scheme * Populate tokens in wallet - using a mocked fetcher * Fix token name formatting * Apply color scheme to token ui elements as well * Refresh token currency values every x seconds - using mock to generate prices * Fixed broken UI tests * Fixed ColorSchemeManager such that the changes applied to the prefab is saved. * Test that percentchange text is displayed appropriately * Added basic navigation bar to wallet panel. Tested that we can close and re-open the wallet panel. Fixed some issues with the implementation * Moved WalletPage into a nested game object that will represent the panel within which all WalletPanel UIPages live * Added base TokenInfo page * Replace NetworkIconSprite in TokenElement with the Chain (id). Now, use NetworkIcons - a scriptable object mapping Chains with Sprites - to get the appropriate sprite for the network. Added the network icons that are supported by the Sequence indexer * Created and add navigation to TokenInfoPage and populate with content. Refactoring. * Add tests for token info page and fixed any issues that came up * Fix token name resizing * Created transaction details block prefab * Updated ColorSchemeManager such that it also updates the prefabs for NFT ui elements and TransactionDetailBlocks * Finish assembly code for TransactionDetailsBlocks * Instantiate and populate transaction details blocks on the TokenInfoPage * Fixed date format and sort transaction detail blocks based on their dates in reverse chronological order so we see the most recent transactions first * Fix transaction details block UI such that the network icon moves based on whether it is sent or received as designed in the Figma * Added basic UI tests for the transaction details blocks * Add arrow to sent received text as designed in the figma * Speed up UI test suite * Switch between search button and back button when opening/closing the info pages * UIPanels keep their own page stack as opposed to SequenceUI * WalletPanel handles opening and closing of its pages and its top bar * Login panel handles event listeners and page transitions for login pages * TransitionPanel opens WalletPanel using SequenceUI * Some renamings * Added basic explanation of how the UI is structured to the README * Removed unneeded fetching of SequenceSampleUI reference * Fixed typo * Create basic NftInfoPage. Create NftElement to use to populate NftInfoPage. Use NftElement to populate NftUIElement and update mock fetcher * Populate and navigate to NftInfoPage * Added tests for NftInfoPage * Created a PageWithTransactionDetailsBlocks, inherriting from UIPage, this class is designed to reuse the code needed for spawning TransactionDetailsBlocks. Reducing copy-pasta * Further re-use code by creating InfoPage which inherrits from PageWithTransactionDetailsBlock. Both NftInfoPage and TokenInfoPage are now InfoPages * Make NftUIElement and TokenUIElement implement a new abstract class WalletUIElement * Small refactor to test code to reuse some more code * Made InfoPage, PageWithTransactionDetailsBlocks, UIPage, and UIPanel abstract classes to improve readability * Created basic CollectionInfoPage * NftElements now hold a reference to a CollectionInfo as opposed to storing collection related info in the NftElement directory * Navigate to and populate CollectionInfoPage * Fix CollectionInfoPage data population - adding some unit tests to verify that the CollectionInfos were being mapped to NftElements appropriately by CollectionNftMapper * Allow injection of a different initial panel (and initial panel opening arguments) to SequenceSampleUI for tests. This allows us to create tests that start on any panel - allowing us the flexibility to split up our tests further while keeping runtimes at a minimum * Broke WalletFlowUITests.EndToEndTest into multiple different tests so that we can get more granual results from our test suite. This will also make the WalletPanel test suite more manageable as it scales and will remove the risk of approaching the max runtime for a given test. * Reuse more UI test code * Added UI tests for CollectionInfoPage * Fixed typo * Significantly sped up runtime of CollectionInfoPageTest_navigatingThroughNftInfoPages by reducing what info it tests on the NftInfoPages when clicking on the NftWithInfoText's button. This reduced the runtime from around 3 minutes to around 1.5 minutes * Apply colour scheme - working properly * Add GetCollections method to CollectionNftMapper. This was done by expanding ArrayUtils.ConvertToTArray to support both List and IEnumerator as input types and added some unit tests. GetCollections uses ConvertToTArray to collect all the keys in a dictionary into an array * Basic setup of SearchPage * ISearchable definition and implementations * Navigate to SearchPage and populate with SearchElements. * Added ui tests to check that we can navigate to the search page and that the page is assembled correctly * Refactored tests such that CollectionInfoPageTests are in their own file * Refactored tests such that TokenInfoPageTests are in their own file * Navigate to info pages via clicking on the SearchElements on the SearchPage. Updated UI tests to test this functionality * MockNftContentFetcher returns NFTs from multiple different collections * Fixed issue with the ratio of collections to tokens the SearchableQuerier was returning. Wrote unit tests to confirm the logic is correct. * Added search functionality to the search page (based on ISearchable name). Added some unit tests to SearchableQuerierTests * Only check that currency value texts are being refreshed once per test (e.g. don't test for each token info page). This speeds up the test suite a bit * Added basic UI test for search functionality. Since I test that only the correct results are being returned by the SearchableQuerier in SearchableQuerierTests, I only test that the results being returned are getting impacted by whatever is entered into the search bar. * Update count texts based on the number of collections/tokens meeting the search criteria. Updated tests to confirm this behaviour * Designed ui for SearchViewAllPage * Create SearchableUIPage, an abstract class that SearchPage and SearchViewAllPage implement. Refactored SearchPage such that as much reusable code as possible is now in SearchableUIPage - this allows SearchViewAllPage to inherrit much of this logic. Minor changes to SearchableQuerier such that it now keeps track of valid Collections and Tokens in separate queues - this was done to make it easier for the SearchViewAllPage to get it's next element (as it will only need one or the other depending on the toggle status) * Add tests for SearchViewAllPage and fix implementation. Added ability to inject params into any UIPage when opening and the ability to inject additional params via Back. * Inject WalletPanel into UI pages as opposed to Finding it - this makes the UI slightly more performant * Update scroll view size on SearchViewAllPage so that page is scrollable * Added functionality to the toggles no the SearchViewAllPage and added accompanying UI tests * Wait for UI to update so that test passes consistently * Cleanup
- Loading branch information