Skip to content

Commit

Permalink
Get latest changes from nuxt repo
Browse files Browse the repository at this point in the history
  • Loading branch information
louis-md committed Sep 18, 2024
1 parent 12bcd3c commit e5e1461
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 8 deletions.
6 changes: 3 additions & 3 deletions .github/scripts/generateCodeExamples.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ const repos = [
organization: '5afe',
repo: 'safe-passkeys-tutorial',
destination: './examples/passkeys',
branch: 'fix-light-theme',
branch: 'main',
files: [
'/lib/constants.ts',
'/lib/passkeys.ts',
Expand All @@ -23,7 +23,7 @@ const repos = [
organization: '5afe',
repo: 'safe-passkeys-nuxt',
destination: './examples/passkeys-vue',
branch: 'fix-light-theme',
branch: 'main',
files: [
'/utils/constants.ts',
'/utils/passkeys.ts',
Expand All @@ -40,7 +40,7 @@ const repos = [
organization: '5afe',
repo: 'safe-7579-tutorial',
destination: './examples/erc-7579',
branch: 'fix-light-theme',
branch: 'main',
files: [
'/lib/permissionless.ts',
'/lib/scheduledTransfers.ts',
Expand Down
8 changes: 4 additions & 4 deletions examples/passkeys-vue/components/SafeAccountDetails.vue
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ async function handleMintNFT() {
store.setIsLoading(false);
store.setIsSafeDeployed(true);
store.setUserOp(userOp);
store.setJiffyLink(`https://jiffyscan.xyz/userOpHash/${userOp}?network=${CHAIN_NAME}`);
store.setSafeLink(`https://app.safe.global/home?safe=sep:${store.safeAddress}`);
}
const DEFAULT_CHAR_DISPLAYED = 6;
Expand All @@ -25,8 +27,6 @@ function splitAddress(
return `${firstPart}...${lastPart}`;
}
const safeLink = `https://app.safe.global/home?safe=sep:${store.safeAddress}`;
const jiffscanLink = `https://jiffyscan.xyz/userOpHash/${store.userOp}?network=${CHAIN_NAME}`;
</script>

<template>
Expand All @@ -42,7 +42,7 @@ const jiffscanLink = `https://jiffyscan.xyz/userOpHash/${store.userOp}?network=$
color="white"
v-if="store.safeAddress"
class="my-8"
:to="safeLink"
:to="store.safeLink"
target="_blank"
rel="noopener noreferrer"
>
Expand Down Expand Up @@ -72,7 +72,7 @@ const jiffscanLink = `https://jiffyscan.xyz/userOpHash/${store.userOp}?network=$
color="white"
v-if="store.userOp"
class="my-8"
:to="jiffscanLink"
:to="store.jiffyLink"
target="_blank"
rel="noopener noreferrer"
>{{ store.userOp }}
Expand Down
10 changes: 9 additions & 1 deletion examples/passkeys-vue/stores/safe.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@ export const useSafeStore = defineStore('safe', {
safeAddress: <string>(''),
isSafeDeployed: <boolean>(false),
isLoading: <boolean>(false),
userOp: <string>('')
userOp: <string>(''),
jiffyLink: <string>(''),
safeLink: <string>(''),
}),
actions: {
setPasskeys(data: PasskeyArgType[]) {
Expand All @@ -27,6 +29,12 @@ export const useSafeStore = defineStore('safe', {
},
setUserOp(data: string) {
this.userOp = data
},
setSafeLink(data: string) {
this.safeLink = data
},
setJiffyLink(data: string) {
this.jiffyLink = data
}
}
})

0 comments on commit e5e1461

Please sign in to comment.