Skip to content

Commit

Permalink
Arguments top border, align arguments input box
Browse files Browse the repository at this point in the history
  • Loading branch information
ngundotra committed Jan 6, 2024
1 parent eb07efb commit 9bbed04
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 19 deletions.
2 changes: 1 addition & 1 deletion app/api/program-interface/resolution.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ export async function resolveRemainingAccounts(
addressLookupTableAccounts: slut ? [lookupTable!] : undefined,
instructions: PRE_INSTRUCTIONS.concat(instructions),
payerKey: payer,
recentBlockhash: (await connection.getLatestBlockhash()).blockhash,
recentBlockhash: (await connection.getLatestBlockhashAndContext()).value.blockhash,
});
const transaction = new anchor.web3.VersionedTransaction(message);

Expand Down
45 changes: 27 additions & 18 deletions app/components/account/ProgramInterfaceCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -426,9 +426,9 @@ function MsaInstructionCard({

{ix.args.length > 0 ? (
<>
<div className="card-header">
<div className="card-header" style={{ borderTop: '1px solid #282d2b' }}>
<div className="row align-items-center">
<div className="col" style={{ display: 'flex', flexDirection: 'row' }}>
<div className="col ">
<h3 className="card-header-title">Arguments</h3>
</div>
</div>
Expand All @@ -449,23 +449,32 @@ function MsaInstructionCard({
<td>{arg.name}</td>
<td>{arg.type.toString()}</td>
<td>
<input
type="input"
className="form-control"
style={{ width: '100%' }}
id={`card-input-${ix.name}-${arg.name}-${key}`}
value={inputArgumentValues[key] || ''}
onChange={e => {
setInputArgumentValues({
...inputAccountValues,
[key]: e.target.value,
});
<div
style={{
alignItems: 'center',
display: 'flex',
flexDirection: 'row',
width: '100%',
}}
/>
<label
className="form-check-label"
htmlFor={`card-input-${ix.name}-${arg.name}-${key}`}
></label>
>
<input
type="input"
className="form-control"
style={{ width: '100%' }}
id={`card-input-${ix.name}-${arg.name}-${key}`}
value={inputArgumentValues[key] || ''}
onChange={e => {
setInputArgumentValues({
...inputAccountValues,
[key]: e.target.value,
});
}}
/>
<label
className="form-check-label"
htmlFor={`card-input-${ix.name}-${arg.name}-${key}`}
></label>
</div>
</td>
</tr>
);
Expand Down

0 comments on commit 9bbed04

Please sign in to comment.