Merge pull request #3633 from NoelDeMartin/MOBILE-4290

MOBILE-4290: Fix site help
main
Dani Palou 2023-04-21 08:06:35 +02:00 committed by GitHub
commit ca28618670
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 10 additions and 10 deletions

View File

@ -23,7 +23,7 @@
</ion-label>
</ion-item>
<ion-item [id]="'question-' + question.id + '-answer'"
[class]="question.answer.class + 'ion-text-wrap core-login-site-help--answer'" [class.open]="isOpen(question)"
[class]="question.answer.class + ' ion-text-wrap core-login-site-help--answer'" [class.open]="isOpen(question)"
[tabindex]="isOpen(question) ? null : -1" [attr.inert]="isOpen(question) ? null : 'true'">
<ion-label>
<p *ngIf="question.answer.format === 'text'">{{ question.answer.text }}</p>

View File

@ -38,7 +38,7 @@ export class CoreLoginSiteHelpComponent implements AfterViewInit, OnDestroy {
constructor(protected el: ElementRef<HTMLElement>) {
const getStartedTitle = Translate.instant('core.login.faqsetupsitelinktitle');
const canScanQR = !CoreUtils.canScanQR();
const canScanQR = CoreUtils.canScanQR();
const urlImageHtml = CoreLoginHelperProvider.FAQ_URL_IMAGE_HTML;
const qrCodeImageHtml = CoreLoginHelperProvider.FAQ_QRCODE_IMAGE_HTML;
const setupLinkHtml = `<a href="${GET_STARTED_URL}" title="${getStartedTitle}">${GET_STARTED_URL}</a>`;
@ -65,6 +65,14 @@ export class CoreLoginSiteHelpComponent implements AfterViewInit, OnDestroy {
format: AnswerFormat.SafeHTML,
},
},
canScanQR && {
text: Translate.instant('core.login.faqwhereisqrcode'),
answer: {
text: Translate.instant('core.login.faqwhereisqrcodeanswer', { $image: qrCodeImageHtml }),
format: AnswerFormat.SafeHTML,
class: 'core-login-faqwhereisqrcodeanswer',
},
},
{
text: Translate.instant('core.login.faqsetupsitequestion'),
answer: {
@ -79,14 +87,6 @@ export class CoreLoginSiteHelpComponent implements AfterViewInit, OnDestroy {
format: AnswerFormat.SafeHTML,
},
},
canScanQR && {
text: Translate.instant('core.login.faqwhereisqrcode'),
answer: {
text: Translate.instant('core.login.faqwhereisqrcodeanswer', { $image: qrCodeImageHtml }),
format: AnswerFormat.SafeHTML,
class: 'core-login-faqwhereisqrcodeanswer',
},
},
];
for (const question of questions) {