Skip to content

Commit b2056e7

Browse files
committed
DPP-89: reverted changes from DBC demo fixes that belong in the branch
1 parent 148a801 commit b2056e7

3 files changed

Lines changed: 37 additions & 61 deletions

File tree

  • packages/oid4vci-demo-frontend/src

packages/oid4vci-demo-frontend/src/components/AuthenticationQR/index.tsx

Lines changed: 8 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -108,18 +108,14 @@ class AuthenticationQR extends Component<AuthenticationQRProps> {
108108
this._isMounted = false
109109
}
110110

111-
render() {
112-
// Show the loader until we have details on which parameters to load into the QR code
113-
return this.state.qrCode ? (
114-
<NonMobileOS>
115-
<div>{this.state.qrCode}</div>
116-
</NonMobileOS>
117-
) : (
118-
<NonMobileOS>
119-
<BallTriangle color="#352575" height="100" width="100"/>
120-
</NonMobileOS>
121-
)
122-
}
111+
render() {
112+
// Show the loader until we have details on which parameters to load into the QR code
113+
return this.state.qrCode ? (
114+
<div>{this.state.qrCode}</div>
115+
) : (
116+
<BallTriangle color="#352575" height="100" width="100" />
117+
)
118+
}
123119

124120
/* We don't want to keep used and unused states indefinitely, so expire the QR code after a configured timeout */
125121
private refreshQRCode = () => {

packages/oid4vci-demo-frontend/src/pages/SSICredentialVerifyFromVPRequest/index.tsx

Lines changed: 29 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -66,9 +66,7 @@ export default function SSICredentialVerifyFromVPRequestPage(): React.ReactEleme
6666
height: '100%',
6767
backgroundColor: '#FFFFFF',
6868
alignItems: 'center',
69-
justifyContent: 'center',
70-
marginLeft: 4,
71-
marginRight: 4,
69+
justifyContent: 'center'
7270
}}>
7371
<div style={{
7472
display: 'flex',
@@ -87,48 +85,35 @@ export default function SSICredentialVerifyFromVPRequestPage(): React.ReactEleme
8785
marginBottom: '25%',
8886
marginTop: '25%'
8987
}}>
88+
<div style={{flexGrow: 1, display: 'flex', justifyContent: 'center', marginBottom: 0}}>
89+
{<MemoizedAuthenticationQR ecosystem={ecosystem}
90+
fgColor={'rgba(50, 57, 72, 1)'}
91+
width={pageConfig.rightPaneLeftPane?.qrCode?.width ?? 300}
92+
vpDefinitionId={flowRouter.getVpDefinitionId()}
93+
onAuthRequestRetrieved={console.log}
94+
onSignInComplete={onSignInComplete}
95+
setQrCodeData={setDeepLink}/>}
96+
</div>
97+
<div style={{
98+
paddingTop: 20,
99+
paddingBottom: 20,
100+
display: 'flex',
101+
flexDirection: 'column',
102+
alignItems: 'center',
103+
gap: '1rem'
104+
}}>
105+
<DeepLinkButton link={deepLink} buttonType={"secondary"} textColor={pageConfig.textColor} style={{width: 300}}/>
106+
<SSIPrimaryButton
107+
caption={t('credential_verify_request_right_pane_button_caption')}
108+
onClick={async () => {
109+
navigate('/information/manual/request');
110+
}}
111+
/>
112+
</div>
113+
90114

91-
<div style={{flexGrow: 1, display: 'flex', justifyContent: 'center', marginBottom: 0}}>
92-
<NonMobileOS>
93-
<div style={{flexGrow: 1, display: 'flex', justifyContent: 'center', alignItems: 'center'}}>
94-
{/*Whether the QR code is shown (mobile) is handled in the component itself */}
95-
{<MemoizedAuthenticationQR ecosystem={ecosystem}
96-
fgColor={'rgba(50, 57, 72, 1)'}
97-
width={pageConfig.rightPaneLeftPane?.qrCode?.width ?? 300}
98-
vpDefinitionId={flowRouter.getVpDefinitionId()}
99-
onAuthRequestRetrieved={console.log}
100-
onSignInComplete={onSignInComplete}
101-
setQrCodeData={setDeepLink}/>}
102-
</div>
103-
</NonMobileOS>
104-
<MobileOS>
105-
{<MemoizedAuthenticationQR ecosystem={ecosystem}
106-
vpDefinitionId={flowRouter.getVpDefinitionId()}
107-
onAuthRequestRetrieved={console.log}
108-
onSignInComplete={onSignInComplete}
109-
setQrCodeData={setDeepLink}/>}
110-
<div style={{gap: 24, display: 'flex', flexDirection: 'column', alignItems: 'center', overflow: 'hidden'}}>
111-
<DeepLinkButton style={{flexGrow: 1}} link={deepLink}/>
112-
</div>
113-
</MobileOS>
114-
</div>
115-
<div style={{
116-
paddingTop: 40,
117-
paddingBottom: 20,
118-
display: 'flex',
119-
flexDirection: 'column',
120-
alignItems: 'center',
121-
gap: '1rem'
122-
}}>
123-
<SSIPrimaryButton
124-
caption={t('credential_verify_request_right_pane_button_caption')}
125-
onClick={async () => {
126-
navigate('/information/manual/request')
127-
}}
128-
/>
129-
<Text style={{flexGrow: 1}} className={`${style.pReduceLineSpace} poppins-semi-bold-16`}
130-
lines={t('credential_verify_request_right_pane_bottom_paragraph').split('\n')}/>
131-
</div>
115+
<Text style={{flexGrow: 1}} className={`${style.pReduceLineSpace} poppins-semi-bold-16`}
116+
lines={t('credential_verify_request_right_pane_bottom_paragraph').split('\n')}/>
132117
</div>
133118
<div style={{
134119
display: 'flex',

packages/oid4vci-demo-frontend/src/pages/SSICredentialVerifyRequestPage/index.tsx

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -114,11 +114,6 @@ export default function SSICredentialVerifyRequestPage(): React.ReactElement | n
114114
</div>
115115
</NonMobileOS>
116116
<MobileOS>
117-
{<MemoizedAuthenticationQR ecosystem={ecosystem}
118-
vpDefinitionId={flowRouter.getVpDefinitionId()}
119-
onAuthRequestRetrieved={console.log}
120-
onSignInComplete={onSignInComplete}
121-
setQrCodeData={setDeepLink}/>}
122117
<div style={{gap: 24, display: 'flex', flexDirection: 'column', alignItems: 'center', overflow: 'hidden'}}>
123118
{ pageConfig.mobile?.image &&
124119
<img src={`${pageConfig.mobile?.image}`} alt="success" style={{overflow: 'hidden'}}/>

0 commit comments

Comments
 (0)