-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
refactor: remove api dependencies from UI components #301
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
Running Lighthouse audit... |
I think the workflow issue is because we're also running it using |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good :) Only issue I can see is that we are right now using two types CurrencySymbol
and CurrencyIdLiteral
which are same so the code is little inconsistent. Maybe we could unify it in the future and replace the lib types in other parts of the codebase with the new types defined in the UI codebase. Or are we going to use the newly-defined types only for the new component library built with the storybook?
Note: Storybook is fixed, but there's an issue with the workflow pushing to Chromatic (which seems to be workflow related). No issue running Storybook locally, so PR unblocks UI development.
This PR removes all api dependencies from the new UI components (which resolves the Storybook issue) and creates configuration for vault collateral tokens. I'm happy with this solution for now - may be something we can improve upon as and when we make type changes in the lib.
Original comments:
This is still WIP, but before I tidy it up I'd really like some opinions on the solution.
The main thing here is to remove all
@interlay/interbtc-ui
type dependencies from the components in thecomponentLibrary
directory as the UI components shouldn't be using these types. (This also fixes the Storybook build).I've fixed this by created some additional types and utilities in the UI, but there may be better solutions - open to suggestions!