Skip to content
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

feat: update index file and simplify zk send transaction request model #93

Merged
merged 1 commit into from
Oct 4, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions sample/Assets/Scripts/AuthenticatedScript.cs
Original file line number Diff line number Diff line change
Expand Up @@ -224,11 +224,9 @@ public async void SendZkTransaction()
try
{
ShowOutput($"Called sendTransaction()...");
List<string> accounts = await passport.ZkEvmRequestAccounts();
string? response = await passport.ZkEvmSendTransaction(new TransactionRequest()
{
To = zkSendTransactionTo.text,
From = accounts[0],
Value = zkSendTransactionAmount.text,
Data = zkSendTransactionFunctionSignature.text

Expand Down
2 changes: 1 addition & 1 deletion src/Packages/Passport/Editor/PassportPostprocess.cs
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ public void OnPostprocessBuild(BuildReport report)
var method = type.GetMethod("AddFrameworkToProject");
method.Invoke(proj, new object[] { target, "AuthenticationServices.framework", false });
}

var cflags = "";
if (EditorUserBuildSettings.development)
{
Expand Down
8 changes: 4 additions & 4 deletions src/Packages/Passport/Runtime/Resources/index.html

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -6,38 +6,8 @@ namespace Immutable.Passport.Model
[JsonObject(NamingStrategyType = typeof(CamelCaseNamingStrategy))]
public class TransactionRequest
{
public string? To;
public string? From;
public string? Nonce;

public string? GasLimit;
public string? GasPrice;

public string To;
public string? Data;
public string? Value;
public int? ChainId;

public int? Type;
public AccessListItem[]? AccessList;

public string? MaxPriorityFeePerGas;
public string? MaxFeePerGas;

public CustomData[]? CustomData;
public bool? CcipReadEnabled;
}

[JsonObject(NamingStrategyType = typeof(CamelCaseNamingStrategy))]
public class AccessListItem
{
public string Address;
public string[] StorageKeys;
}

[JsonObject(NamingStrategyType = typeof(CamelCaseNamingStrategy))]
public class CustomData
{
public string Key;
public object Value;
}
}
Loading