Skip to content

Commit

Permalink
chore: align use of quotes with biome
Browse files Browse the repository at this point in the history
  • Loading branch information
peetzweg committed Nov 13, 2023
1 parent 0a4c9c5 commit dc56786
Show file tree
Hide file tree
Showing 15 changed files with 359 additions and 358 deletions.
14 changes: 7 additions & 7 deletions basic-contract-caller/frontend/src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,20 +23,20 @@ function App() {

return (
<InkLayout
className="md:py-12 md:p-6 p-4 h-screen flex items-center justify-center"
animationSrc="https://raw.githubusercontent.com/paritytech/ink-workshop/d819d10a35b2ac3d2bff4f77a96701a527b3ad3a/frontend/public/dark-sea-creatures.json"
className='md:py-12 md:p-6 p-4 h-screen flex items-center justify-center'
animationSrc='https://raw.githubusercontent.com/paritytech/ink-workshop/d819d10a35b2ac3d2bff4f77a96701a527b3ad3a/frontend/public/dark-sea-creatures.json'
>
<div className="flex flex-col justify-center items-center gap-3 h-full">
<Card className="p-6 flex flex-col w-full max-w-md backdrop-blur-sm bg-opacity-70">
<h1 className="text-2xl font-bold">
<div className='flex flex-col justify-center items-center gap-3 h-full'>
<Card className='p-6 flex flex-col w-full max-w-md backdrop-blur-sm bg-opacity-70'>
<h1 className='text-2xl font-bold'>
{formatContractName(metadata.contract.name)}
</h1>

{account ? (
<Button
disabled={shouldDisable(flipAndGet)}
onClick={() => flipAndGet.signAndSend()}
className="mt-6"
className='mt-6'
>
{isPendingSignature(flipAndGet)
? 'Please sign transaction...'
Expand All @@ -45,7 +45,7 @@ function App() {
: 'Flip Other Contract'}
</Button>
) : (
<ConnectButton className="mt-6" />
<ConnectButton className='mt-6' />
)}
</Card>

Expand Down
2 changes: 1 addition & 1 deletion basic-contract-caller/frontend/tailwind.config.js
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
import config from '../../ui/tailwind.config';
export default config;
export default config;
1 change: 1 addition & 0 deletions biome.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
"javascript": {
"formatter": {
"quoteStyle": "single",
"jsxQuoteStyle": "single",
"trailingComma": "all",
"semicolons": "always"
}
Expand Down
2 changes: 1 addition & 1 deletion contract-terminate/frontend/tailwind.config.js
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
import config from '../../ui/tailwind.config';
export default config;
export default config;
26 changes: 13 additions & 13 deletions contract-transfer/frontend/src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -45,19 +45,19 @@ function App() {

return (
<InkLayout
className="md:py-12 md:p-6 p-4 h-screen flex items-center justify-center"
animationSrc="https://raw.githubusercontent.com/paritytech/ink-workshop/d819d10a35b2ac3d2bff4f77a96701a527b3ad3a/frontend/public/dark-sea-creatures.json"
className='md:py-12 md:p-6 p-4 h-screen flex items-center justify-center'
animationSrc='https://raw.githubusercontent.com/paritytech/ink-workshop/d819d10a35b2ac3d2bff4f77a96701a527b3ad3a/frontend/public/dark-sea-creatures.json'
>
<div className="flex flex-col justify-center items-center h-full">
<Card className="mx-auto p-6 flex flex-col w-full max-w-md backdrop-blur-sm bg-opacity-70">
<h1 className="text-2xl font-bold">
<div className='flex flex-col justify-center items-center h-full'>
<Card className='mx-auto p-6 flex flex-col w-full max-w-md backdrop-blur-sm bg-opacity-70'>
<h1 className='text-2xl font-bold'>
{formatContractName(metadata.contract.name)}
</h1>

<hgroup className="mt-6 mb-2 ml-2 text-white/80 text-xs">
<hgroup className='mt-6 mb-2 ml-2 text-white/80 text-xs'>
<h3>
Contract Balance:{' '}
<b className="uppercase">
<b className='uppercase'>
{contractBalance
? planckToDecimalFormatted(contractBalance?.freeBalance, {
api: chainContract?.contract.api,
Expand All @@ -69,7 +69,7 @@ function App() {

<h3>
Your Balance:{' '}
<b className="uppercase">
<b className='uppercase'>
{userBalance
? planckToDecimalFormatted(userBalance?.freeBalance, {
api: chainContract?.contract.api,
Expand All @@ -96,7 +96,7 @@ function App() {
<Button
disabled={shouldDisable(giveMe) || needsMoreFunds}
onClick={() => giveMe.signAndSend([planckAmount])}
className="mt-6"
className='mt-6'
>
{isPendingSignature(giveMe)
? 'Please sign transaction...'
Expand All @@ -105,17 +105,17 @@ function App() {
: `Withdraw ${amount} ROC`}
</Button>
) : (
<ConnectButton className="mt-6" />
<ConnectButton className='mt-6' />
)}

<div className="text-center mt-6">
<div className='text-center mt-6'>
{needsMoreFunds && (
<p className="mb-3">There are not enough funds.</p>
<p className='mb-3'>There are not enough funds.</p>
)}

<Link
href={`https://use.ink/faucet?acc=${CONTRACT_ROCOCO_ADDRESS}`}
target="_blank"
target='_blank'
>
Add ROC to contract with faucet
</Link>
Expand Down
2 changes: 1 addition & 1 deletion contract-transfer/frontend/tailwind.config.js
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
import config from '../../ui/tailwind.config';
export default config;
export default config;
2 changes: 1 addition & 1 deletion erc20/frontend/tailwind.config.js
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
import config from '../../ui/tailwind.config';
export default config;
export default config;
2 changes: 1 addition & 1 deletion erc721/frontend/tailwind.config.js
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
import config from '../../ui/tailwind.config';
export default config;
export default config;
2 changes: 1 addition & 1 deletion flipper/frontend/tailwind.config.js
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
import config from '../../ui/tailwind.config';
export default config;
export default config;
2 changes: 1 addition & 1 deletion incrementer/frontend/tailwind.config.js
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
import config from '../../ui/tailwind.config';
export default config;
export default config;
18 changes: 9 additions & 9 deletions ui/src/ConnectWallet/ConnectWallet.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,19 +11,19 @@ export const ConnectWallet: React.FC = () => {

return (
<div>
<h2 className="text-2xl font-bold mb-8 text-white">Connect Wallet</h2>
<h2 className='text-2xl font-bold mb-8 text-white'>Connect Wallet</h2>

{!account && installed.length > 0 && (
<ul>
{installed.map((w) => (
<li key={w.title} className="mt-3">
<li key={w.title} className='mt-3'>
<Button
className="flex items-center gap-2 w-full"
className='flex items-center gap-2 w-full'
onClick={() => {
connect(w.extensionName);
}}
>
<img className="w-10 mr-2" src={w.logo.src} alt={w.logo.alt} />
<img className='w-10 mr-2' src={w.logo.src} alt={w.logo.alt} />
Connect to {w.extensionName}
</Button>
</li>
Expand All @@ -33,20 +33,20 @@ export const ConnectWallet: React.FC = () => {

{!account && uninstalled.length && installed.length === 0 && (
<>
<p className="font-semibold my-6 text-center text-white/80">
<p className='font-semibold my-6 text-center text-white/80'>
Please install one of these supported wallets.
</p>

<ul>
{uninstalled.map((w) => (
<li key={w.title} className="mt-3">
<li key={w.title} className='mt-3'>
<Button
className="flex items-center gap-2 w-full"
className='flex items-center gap-2 w-full'
onClick={() => window.open(w.installUrl, '_blank')}
rel="noopener noreferrer"
rel='noopener noreferrer'
>
<img
className="w-10 mr-2"
className='w-10 mr-2'
src={w.logo.src}
alt={w.logo.alt}
/>
Expand Down
4 changes: 2 additions & 2 deletions ui/src/InkLayout/ManageWallet/ManageWallet.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,13 @@ export const ManageWallet: React.FC = () => {
{account && (
<>
<Button
className="mx-auto mt-6 w-full"
className='mx-auto mt-6 w-full'
onClick={() => setView('contract')}
>
View Contract
</Button>

<Button className="mx-auto mt-6 w-full" onClick={disconnect}>
<Button className='mx-auto mt-6 w-full' onClick={disconnect}>
Disconnect
</Button>
</>
Expand Down
6 changes: 3 additions & 3 deletions ui/src/InkLayout/Screen/Screen.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,11 @@ export const Screen: React.FC<React.PropsWithChildren> = ({ children }) => {
...screenPosition,
}}
>
<div className="py-32 h-full overflow-y-scroll">
<div className='py-32 h-full overflow-y-scroll'>
{view === 'contract' && children}
{view === 'wallet' && (
<div className="flex flex-col items-center h-full justify-center w-full">
<Card className="mx-auto w-full">
<div className='flex flex-col items-center h-full justify-center w-full'>
<Card className='mx-auto w-full'>
<ManageWallet />
</Card>
</div>
Expand Down
Loading

0 comments on commit dc56786

Please sign in to comment.