@indexing/jiti 0.0.37 → 0.0.39

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1,4 +1,4 @@
1
- # Just In Time Indexing (JITI)
1
+ # Just In Time Indexing Service (JITI)
2
2
 
3
3
  Open source template library for the JITI community.
4
4
 
@@ -10,4 +10,4 @@ This package will be ready for external contributors in early 2025.
10
10
 
11
11
  ## License
12
12
 
13
- See the [LICENSE](LICENSE.md) file for license rights and limitations (GPL-3.0-or-later).
13
+ See the [LICENSE](LICENSE.md) file for license rights and limitations (GPL-3.0-or-later).
package/dist/main.js CHANGED
@@ -966,23 +966,25 @@ const $3b9b8f5747dcca8e$export$722698bc663d0ac0 = {
966
966
  };
967
967
 
968
968
 
969
- const $290fd8bc430da9f0$export$1f0fe79deb1b813b = {
969
+ const $fc7ca671efecc378$export$a51565c56ceacb0a = {
970
970
  match: (block)=>[
971
- "SOLANA"
971
+ "SOLANA",
972
+ "SOLANA_DEVNET",
973
+ "ECLIPSE"
972
974
  ].includes(block._network),
973
975
  transform (block) {
974
976
  let transfers = [];
975
977
  for (const tx of block.transactions){
976
- const solanaTx = tx;
977
- const txHash = solanaTx.transaction.signatures[0];
978
+ const svmTx = tx;
979
+ const txHash = svmTx.transaction.signatures[0];
978
980
  const timestamp = block.blockTime ? new Date(block.blockTime * 1000).toISOString() : null;
979
- const allAccounts = solanaTx.transaction.message.accountKeys.concat(solanaTx.meta.loadedAddresses.writable).concat(solanaTx.meta.loadedAddresses.readonly);
980
- let txFee = BigInt(solanaTx.meta.fee);
981
+ const allAccounts = svmTx.transaction.message.accountKeys.concat(svmTx.meta.loadedAddresses.writable).concat(svmTx.meta.loadedAddresses.readonly);
982
+ let txFee = BigInt(svmTx.meta.fee);
981
983
  if (txFee < BigInt(10)) txFee = txFee * BigInt(Math.pow(10, 9));
982
984
  const transfersByKey = {};
983
- for (const post of solanaTx.meta.postTokenBalances){
985
+ for (const post of svmTx.meta.postTokenBalances){
984
986
  let matched = false;
985
- for (const pre of solanaTx.meta.preTokenBalances)if (post.mint === pre.mint && post.owner === pre.owner) {
987
+ for (const pre of svmTx.meta.preTokenBalances)if (post.mint === pre.mint && post.owner === pre.owner) {
986
988
  let diff = BigInt(post.uiTokenAmount.amount) - BigInt(pre.uiTokenAmount.amount);
987
989
  if (diff === BigInt(0)) {
988
990
  matched = true;
@@ -1050,9 +1052,9 @@ const $290fd8bc430da9f0$export$1f0fe79deb1b813b = {
1050
1052
  }
1051
1053
  }
1052
1054
  }
1053
- for(let i = 0; i < solanaTx.meta.postBalances.length; i += 1){
1054
- const post = solanaTx.meta.postBalances[i];
1055
- const pre = solanaTx.meta.preBalances[i];
1055
+ for(let i = 0; i < svmTx.meta.postBalances.length; i += 1){
1056
+ const post = svmTx.meta.postBalances[i];
1057
+ const pre = svmTx.meta.preBalances[i];
1056
1058
  if (post !== undefined && pre !== undefined && post !== pre) {
1057
1059
  let diff = BigInt(post) - BigInt(pre);
1058
1060
  if (diff < 0) diff = -diff;
@@ -1676,7 +1678,7 @@ const $7dd402f6ad0dab6a$var$SUB_TEMPLATES = [
1676
1678
  (0, $60d24c82dc5feb2e$export$893111d8d332e195),
1677
1679
  (0, $5a4d345db3c04a51$export$d7ac970e8e789607),
1678
1680
  (0, $2e46ec862e47c14f$export$400f08bfae9ee97f),
1679
- (0, $290fd8bc430da9f0$export$1f0fe79deb1b813b),
1681
+ (0, $fc7ca671efecc378$export$a51565c56ceacb0a),
1680
1682
  (0, $fc745f3cb8eb3f52$export$36783fc9701281c6),
1681
1683
  (0, $3478cd776d185339$export$681f497010b17679),
1682
1684
  (0, $11a2c5b0fd56c033$export$bc6c7ab7e0727dd7),