Skip to content

Commit

Permalink
fix(mdoc): fix dependency versions and return requested items (#215)
Browse files Browse the repository at this point in the history
Signed-off-by: Berend Sliedrecht <[email protected]>
  • Loading branch information
berendsliedrecht authored Nov 19, 2024
1 parent 670ee81 commit 7acb285
Show file tree
Hide file tree
Showing 5 changed files with 798 additions and 308 deletions.
1 change: 1 addition & 0 deletions apps/easypid/babel.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ module.exports = (api) => {
return {
presets: ['babel-preset-expo'],
plugins: [
'babel-plugin-syntax-hermes-parser',
[
'module-resolver',
{
Expand Down
1 change: 1 addition & 0 deletions apps/easypid/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@
"devDependencies": {
"@babel/core": "^7.24.4",
"@tamagui/babel-plugin": "1.109.5",
"babel-plugin-syntax-hermes-parser": "^0.25.1",
"expo-build-properties": "^0.12.5",
"typescript": "*"
}
Expand Down
6 changes: 5 additions & 1 deletion apps/easypid/src/features/proximity/mdocProximity.ts
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,11 @@ export const getMdocQrCode = async () => {
*/
export const waitForDeviceRequest = async () => {
const mdt = mdocDataTransfer.instance()
return await mdt.waitForDeviceRequest()
const { deviceRequest, sessionTranscript } = await mdt.waitForDeviceRequest()
const decodedDeviceRequest = DeviceRequest.parse(deviceRequest)
const requestedItems = decodedDeviceRequest.docRequests.map((d) => d.itemsRequest.data.nameSpaces)

return { deviceRequest, sessionTranscript, requestedItems }
}

/**
Expand Down
7 changes: 3 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -41,17 +41,16 @@
"@animo-id/expo-secure-environment": "0.1.0-alpha.5",
"@animo-id/expo-mdoc-data-transfer": "0.0.3-alpha.6",
"@types/react": "~18.2.79",
"react": "18.3.1",
"react-docgen-typescript": "2.2.2",
"react-native": "~0.75.0",
"react-native-reanimated": "~3.15.5",
"@sphereon/did-auth-siop": "https://gitpkg.vercel.app/animo/OID4VC/packages/siop-oid4vp?funke",
"@sphereon/oid4vc-common": "https://gitpkg.vercel.app/animo/OID4VC/packages/common?funke",
"@sphereon/oid4vci-common": "https://gitpkg.vercel.app/animo/OID4VC/packages/oid4vci-common?funke",
"@sphereon/oid4vci-issuer": "https://gitpkg.vercel.app/animo/OID4VC/packages/issuer?funke",
"@sphereon/oid4vci-client": "https://gitpkg.vercel.app/animo/OID4VC/packages/client?funke",
"@sphereon/jarm": "https://gitpkg.vercel.app/animo/OID4VC/packages/jarm?funke",
"@protokoll/mdoc-client": "0.2.36"
"@protokoll/mdoc-client": "0.2.36",
"react": "18.3.1",
"react-natve": "~0.74.5"
},
"patchedDependencies": {
"@hyperledger/[email protected]": "patches/@[email protected]",
Expand Down
Loading

0 comments on commit 7acb285

Please sign in to comment.