chore: changes for v1.4.8

This commit is contained in:
Andrei O 2024-10-29 23:29:39 +02:00
parent 146a740050
commit 547d1368b1
No known key found for this signature in database
GPG Key ID: B961E5B68389457E
7 changed files with 47 additions and 36 deletions

View File

@ -1,5 +1,12 @@
# Changelog # Changelog
## Manifest Version 1.4.8
- updated dependencies
- updated release script
- better clearing of storage
- return higher MM vestion when wallet queried
## Manifest Version 1.4.7 ## Manifest Version 1.4.7
- added network(Rootstock Network) template from @ahsan-javaiid - added network(Rootstock Network) template from @ahsan-javaiid

BIN
bun.lockb

Binary file not shown.

View File

@ -18,8 +18,8 @@
"only-pub": "bun run build && bun run ./release-scripts/create-release.ts" "only-pub": "bun run build && bun run ./release-scripts/create-release.ts"
}, },
"dependencies": { "dependencies": {
"@ionic/vue": "^8.3.2", "@ionic/vue": "^8.3.3",
"@ionic/vue-router": "^8.3.2", "@ionic/vue-router": "^8.3.3",
"core-js": "^3.38.1", "core-js": "^3.38.1",
"ethers": "^6.13.4", "ethers": "^6.13.4",
"qr-scanner": "^1.4.2", "qr-scanner": "^1.4.2",
@ -28,28 +28,28 @@
}, },
"devDependencies": { "devDependencies": {
"@crxjs/vite-plugin": "2.0.0-beta.25", "@crxjs/vite-plugin": "2.0.0-beta.25",
"@types/archiver": "^6.0.2", "@types/archiver": "^6.0.3",
"@types/chrome": "^0.0.269", "@types/chrome": "^0.0.269",
"@types/jest": "^29.5.13", "@types/jest": "^29.5.14",
"@types/node": "^22.7.5", "@types/node": "^22.8.2",
"@typescript-eslint/eslint-plugin": "^8.8.1", "@typescript-eslint/eslint-plugin": "^8.12.1",
"@typescript-eslint/parser": "^8.8.1", "@typescript-eslint/parser": "^8.12.1",
"@vitejs/plugin-vue": "^5.1.4", "@vitejs/plugin-vue": "^5.1.4",
"@vue/eslint-config-typescript": "^13.0.0", "@vue/eslint-config-typescript": "^13.0.0",
"archiver": "^7.0.1", "archiver": "^7.0.1",
"eslint": "^9.12.0", "eslint": "^9.13.0",
"eslint-plugin-vue": "^9.29.0", "eslint-plugin-vue": "^9.30.0",
"http-browserify": "^1.7.0", "http-browserify": "^1.7.0",
"https-browserify": "^1.0.0", "https-browserify": "^1.0.0",
"jest": "^29.7.0", "jest": "^29.7.0",
"sass": "^1.79.5", "sass": "^1.80.4",
"stream-browserify": "^3.0.0", "stream-browserify": "^3.0.0",
"ts-jest": "^29.2.5", "ts-jest": "^29.2.5",
"tsx": "^4.19.1", "tsx": "^4.19.2",
"typescript": "^5.6.3", "typescript": "^5.6.3",
"util": "^0.12.5", "util": "^0.12.5",
"vite": "^5.4.8", "vite": "^5.4.10",
"vue-tsc": "^2.1.6" "vue-tsc": "^2.1.8"
}, },
"disabledNativeDependencies": { "disabledNativeDependencies": {
"@capacitor/app": "^5.0.6", "@capacitor/app": "^5.0.6",

View File

@ -13,7 +13,7 @@ async function main() {
// 3. Commit changes // 3. Commit changes
execSync(`git add .`); execSync(`git add .`);
execSync(`git commit -m "Release v${newVersion}"`); execSync(`git commit -m "clear-wallet@v${newVersion}"`);
// 4. Create and push tag // 4. Create and push tag
execSync(`git tag v${newVersion}`); execSync(`git tag v${newVersion}`);

View File

@ -3,8 +3,8 @@
"name": "__MSG_appName__", "name": "__MSG_appName__",
"description": "__MSG_appDesc__", "description": "__MSG_appDesc__",
"default_locale": "en", "default_locale": "en",
"version": "1.4.7", "version": "1.4.8",
"version_name": "1.4.7", "version_name": "1.4.8",
"icons": { "icons": {
"16": "assets/extension-icon/wallet_16.png", "16": "assets/extension-icon/wallet_16.png",
"32": "assets/extension-icon/wallet_32.png", "32": "assets/extension-icon/wallet_32.png",

View File

@ -586,8 +586,6 @@ const mainListner = (message: RequestArguments, sender: any, sendResponse: (a: a
}) })
try { try {
console.log('waiting for user to approve or reject')
console.log(rIdData?.[String(gWin?.id ?? 0)])
const tx = await sendTransaction({ ...params, ...(rIdData?.[String(gWin?.id ?? 0)] ?? {}) }) const tx = await sendTransaction({ ...params, ...(rIdData?.[String(gWin?.id ?? 0)] ?? {}) })
sendResponse(tx.hash) sendResponse(tx.hash)
const buttons = {} as any const buttons = {} as any
@ -620,12 +618,6 @@ const mainListner = (message: RequestArguments, sender: any, sendResponse: (a: a
type: 'basic', type: 'basic',
...(buttons) ...(buttons)
} as any) } as any)
const settings = await getSettings()
if (settings.encryptAfterEveryTx) {
await clearPk()
}
} catch (err) { } catch (err) {
console.info('Error: eth_sendTransaction', err) console.info('Error: eth_sendTransaction', err)
sendResponse({ sendResponse({
@ -654,6 +646,14 @@ const mainListner = (message: RequestArguments, sender: any, sendResponse: (a: a
message: 'User Rejected Signature' message: 'User Rejected Signature'
}) })
} }
try {
const settings = await getSettings()
if (settings.encryptAfterEveryTx) {
await clearPk()
}
} catch {
// ignore
}
break break
} }
case 'signTypedData': case 'signTypedData':
@ -667,7 +667,6 @@ const mainListner = (message: RequestArguments, sender: any, sendResponse: (a: a
case 'personal_sign': case 'personal_sign':
case 'eth_sign': { case 'eth_sign': {
try { try {
const account = await getSelectedAccount() const account = await getSelectedAccount()
if (!account || !('address' in account)) { if (!account || !('address' in account)) {
@ -709,10 +708,6 @@ const mainListner = (message: RequestArguments, sender: any, sendResponse: (a: a
await signTypedData(signMsgData) : await signTypedData(signMsgData) :
await signMsg(signMsgData) await signMsg(signMsgData)
) )
const settings = await getSettings()
if (settings.encryptAfterEveryTx) {
await clearPk()
}
} catch (e) { } catch (e) {
console.warn('Error: signTypedData', e) console.warn('Error: signTypedData', e)
sendResponse({ sendResponse({
@ -721,6 +716,14 @@ const mainListner = (message: RequestArguments, sender: any, sendResponse: (a: a
message: 'User Rejected Signature' message: 'User Rejected Signature'
}) })
} }
try {
const settings = await getSettings()
if (settings.encryptAfterEveryTx) {
await clearPk()
}
} catch {
// ignore
}
break break
} }
// NON Standard / metamask API // NON Standard / metamask API
@ -735,7 +738,7 @@ const mainListner = (message: RequestArguments, sender: any, sendResponse: (a: a
break break
} }
case 'web3_clientVersion': { case 'web3_clientVersion': {
sendResponse("MetaMask/v11.0.0") sendResponse("MetaMask/v12.3.0")
break break
} }
case 'wallet_getPermissions': case 'wallet_getPermissions':

View File

@ -367,12 +367,6 @@ export default defineComponent({
onIonViewWillEnter(async () => { onIonViewWillEnter(async () => {
(window as any)?.resizeTo?.(600, 800); (window as any)?.resizeTo?.(600, 800);
const pEstimateGas = estimateGas({
to: params?.to ?? "",
from: params?.from ?? "",
data: params?.data ?? "",
value: params?.value ?? "0x0",
});
blockLockout(); blockLockout();
const pGasPrice = getGasPrice(); const pGasPrice = getGasPrice();
const pBalance = getBalance(); const pBalance = getBalance();
@ -388,6 +382,13 @@ export default defineComponent({
gasPrice.value = parseFloat(price.toString() ?? 0.1); gasPrice.value = parseFloat(price.toString() ?? 0.1);
const pEstimateGas = estimateGas({
to: params?.to ?? "",
from: params?.from ?? "",
data: params?.data ?? "",
value: params?.value ?? "0x0",
});
try { try {
gasLimit.value = parseInt((await pEstimateGas).toString(), 10); gasLimit.value = parseInt((await pEstimateGas).toString(), 10);
} catch (err) { } catch (err) {