-
Notifications
You must be signed in to change notification settings - Fork 0
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
Styling and UX improvements. #43
Conversation
* text colors * @apply for button types * class overrides for KeySelection * Actions are now "cards" that use the class overrides * remove old styles in components for unified look * fix bug in AddControlKey * de-linting
<div class="pl-6 ml-6 border-l-8 border-aqua"> | ||
<h3 class="text-aqua font-bold">Capacity</h3> | ||
{#if !connected} | ||
<p>Not connected</p> |
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.
All the "status" items at the top now display more or less the same information until you are connected and we know if you are a Provider or you just have an MSA.
@@ -81,7 +78,7 @@ | |||
if (isFunction(thisWeb3FromSource) && isFunction(thisWeb3Enable)) { | |||
const extensions = await thisWeb3Enable('Frequency parachain provider dashboard: Adding Keys'); | |||
if (extensions.length !== 0) { | |||
const injectedExtension = await thisWeb3FromSource(signingKeys.meta.source); | |||
const injectedExtension = await thisWeb3FromSource(signingKeys.meta.source.toString()); |
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.
because typescript
}; | ||
</script> | ||
|
||
<svelte:head> | ||
<link rel="stylesheet" href="https://unpkg.com/[email protected]/mvp.css" /> |
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.
💀
<link rel="stylesheet" href="https://unpkg.com/[email protected]/mvp.css" /> | ||
</svelte:head> | ||
|
||
<h1>Welcome to Provider Dashboard</h1> |
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.
still need a good title though.
it('is hidden', () => { | ||
const { container } = render(Capacity, { token: 'FLARP' }); | ||
expect(container.querySelector('div div')).toHaveClass('hidden'); | ||
it('is says it is not connected', () => { |
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.
it('is says it is not connected', () => { | |
it('it says it is not connected', () => { |
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.
I ran the dev version with tests against a local node.
It's looking really good!
e2e tests are broken and I created a branch to see if I could fix it, but I didn't find a satisfying solution yet.
One other thing: on Rococo, my test account has 5,009.7716 XRQCY, but Provider Dashboard shows it as 50.0977. I didn't get a chance to dig in and find where that happens in the code. |
src/lib/utils.ts
Outdated
}; | ||
|
||
export const balanceToHuman = (balance: bigint, token: string): string => { | ||
return formatBalance(balance, { withSiFull: true, withUnit: token, withZero: true, decimals: 10 }); |
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.
return formatBalance(balance, { withSiFull: true, withUnit: token, withZero: true, decimals: 10 }); | |
return formatBalance(balance, { withSiFull: true, withUnit: token, withZero: true, decimals: 8 }); |
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.
Fixed
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.
One note on the decimals, but that's all from me
Styling and UX improvements
References #41
Details
I'd like to get this in to main before it goes any further since this was supposed to be "basic" styling and it's kind of a lot.