-
-
Notifications
You must be signed in to change notification settings - Fork 164
feat(REB-289): Add Rylo redirect overlay on translate app #252
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
eebdeeb
feat(REB-289): Add Rylo redirect overlay on translate app
HTMHell d09761f
chore: Simplify after Rylo redirect overlay
HTMHell db731ad
feat(REB-289): Use official Rylo hero background and split headline
HTMHell 4b134fb
feat(REB-289): Make redirect a centered modal card with backdrop
HTMHell cbc6517
feat(REB-289): Enlarge modal and use full sky photo background
HTMHell 4fe4f62
feat(REB-289): Brighten modal background and update banner to Rylo
HTMHell 9db8bb6
feat(REB-289): Match Rylo palette and swap header logo to Rylo
HTMHell 543a722
feat(REB-289): Show redirect modal on every page
HTMHell affd857
feat(REB-289): Update subtitle text
HTMHell File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,3 +1,4 @@ | ||
| <ion-app> | ||
| <ion-router-outlet /> | ||
| <app-rylo-redirect-overlay /> | ||
| </ion-app> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 2 additions & 2 deletions
4
src/app/components/announcement-banner/announcement-banner.component.html
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -17,7 +17,7 @@ img { | |
| display: block; | ||
| } | ||
|
|
||
| .nagish-logo { | ||
| .rylo-logo { | ||
| img { | ||
| height: 1em; | ||
| } | ||
|
|
||
11 changes: 11 additions & 0 deletions
11
src/app/components/rylo-redirect-overlay/rylo-redirect-overlay.component.html
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,11 @@ | ||
| @if (visible) { | ||
| <div class="rylo-overlay"> | ||
| <div class="rylo-overlay__card" role="dialog" aria-modal="true" aria-labelledby="rylo-overlay-title"> | ||
| <div class="rylo-overlay__text"> | ||
| <h1 id="rylo-overlay-title" class="rylo-overlay__title">sign.Translate is now Sign Translate by Rylo.</h1> | ||
| <p class="rylo-overlay__subtitle">We have our new name and looks but your experience stays the same.</p> | ||
| </div> | ||
| <a class="rylo-overlay__cta" [href]="redirectUrl" (click)="redirect($event)" autofocus>Try Sign Translate</a> | ||
| </div> | ||
| </div> | ||
| } |
91 changes: 91 additions & 0 deletions
91
src/app/components/rylo-redirect-overlay/rylo-redirect-overlay.component.scss
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,91 @@ | ||
| @forward '../../../theme/fonts/poppins.css'; | ||
|
|
||
| :host { | ||
| display: contents; | ||
| } | ||
|
|
||
| .rylo-overlay { | ||
| position: fixed; | ||
| inset: 0; | ||
| z-index: 99999; | ||
| display: flex; | ||
| align-items: center; | ||
| justify-content: center; | ||
| padding: 24px; | ||
| background-color: rgba(25, 20, 18, 0.6); | ||
| backdrop-filter: blur(2px); | ||
| } | ||
|
|
||
| .rylo-overlay__card { | ||
| display: flex; | ||
| flex-direction: column; | ||
| align-items: center; | ||
| gap: 32px; | ||
| width: 100%; | ||
| max-width: 760px; | ||
| padding: 72px 48px; | ||
| overflow: hidden; | ||
| text-align: center; | ||
| border-radius: 28px; | ||
| background-color: #5d7c93; | ||
| background-image: linear-gradient(rgba(93, 124, 147, 0.4), rgba(93, 124, 147, 0.4)), url('/assets/rylo-clouds.webp'); | ||
| background-position: center; | ||
| background-repeat: no-repeat; | ||
| background-size: cover; | ||
| box-shadow: 0 24px 60px rgba(25, 20, 18, 0.4); | ||
| } | ||
|
|
||
| .rylo-overlay__text { | ||
| display: flex; | ||
| flex-direction: column; | ||
| gap: 14px; | ||
| } | ||
|
|
||
| .rylo-overlay__title { | ||
| margin: 0; | ||
| font-family: 'Poppins', sans-serif; | ||
| font-weight: 600; | ||
| font-size: clamp(28px, 5vw, 44px); | ||
| line-height: 1.15; | ||
| letter-spacing: -0.02em; | ||
| color: #faf5f2; | ||
| } | ||
|
|
||
| .rylo-overlay__subtitle { | ||
| margin: 0; | ||
| font-family: 'Poppins', sans-serif; | ||
| font-weight: 400; | ||
| font-size: clamp(16px, 2.2vw, 19px); | ||
| line-height: 1.45; | ||
| color: rgba(250, 245, 242, 0.95); | ||
| } | ||
|
|
||
| .rylo-overlay__cta { | ||
| display: inline-flex; | ||
| align-items: center; | ||
| justify-content: center; | ||
| height: 48px; | ||
| padding: 8px 24px; | ||
| border-radius: 12px; | ||
| background-color: #f9923c; | ||
| color: #191412; | ||
| font-family: 'Poppins', sans-serif; | ||
| font-weight: 600; | ||
| font-size: 16px; | ||
| text-decoration: none; | ||
| box-shadow: | ||
| 0 8px 12px rgba(25, 20, 18, 0.15), | ||
| inset 0 0 8px rgba(255, 255, 255, 0.4); | ||
| transition: | ||
| transform 0.15s ease, | ||
| filter 0.15s ease; | ||
| } | ||
|
|
||
| .rylo-overlay__cta:hover { | ||
| transform: translateY(-1px); | ||
| filter: brightness(1.03); | ||
| } | ||
|
|
||
| .rylo-overlay__cta:active { | ||
| transform: translateY(0); | ||
| } |
29 changes: 29 additions & 0 deletions
29
src/app/components/rylo-redirect-overlay/rylo-redirect-overlay.component.spec.ts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,29 @@ | ||
| import {TestBed} from '@angular/core/testing'; | ||
| import {Capacitor} from '@capacitor/core'; | ||
| import {RyloRedirectOverlayComponent} from './rylo-redirect-overlay.component'; | ||
|
|
||
| describe('RyloRedirectOverlayComponent', () => { | ||
| beforeEach(async () => { | ||
| await TestBed.configureTestingModule({ | ||
| imports: [RyloRedirectOverlayComponent], | ||
| }).compileComponents(); | ||
| }); | ||
|
|
||
| it('renders the redirect overlay with a CTA to Rylo on web', () => { | ||
| spyOn(Capacitor, 'isNativePlatform').and.returnValue(false); | ||
| const fixture = TestBed.createComponent(RyloRedirectOverlayComponent); | ||
| fixture.detectChanges(); | ||
|
|
||
| const cta = fixture.nativeElement.querySelector('.rylo-overlay__cta') as HTMLAnchorElement; | ||
| expect(cta).toBeTruthy(); | ||
| expect(cta.getAttribute('href')).toBe('https://rylo.com/sign/translate'); | ||
| }); | ||
|
|
||
| it('renders nothing on native platforms', () => { | ||
| spyOn(Capacitor, 'isNativePlatform').and.returnValue(true); | ||
| const fixture = TestBed.createComponent(RyloRedirectOverlayComponent); | ||
| fixture.detectChanges(); | ||
|
|
||
| expect(fixture.nativeElement.querySelector('.rylo-overlay')).toBeNull(); | ||
| }); | ||
| }); |
26 changes: 26 additions & 0 deletions
26
src/app/components/rylo-redirect-overlay/rylo-redirect-overlay.component.ts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,26 @@ | ||
| import {Component, inject} from '@angular/core'; | ||
| import {Capacitor} from '@capacitor/core'; | ||
| import {GoogleAnalyticsService} from '../../core/modules/google-analytics/google-analytics.service'; | ||
|
|
||
| @Component({ | ||
| selector: 'app-rylo-redirect-overlay', | ||
| standalone: true, | ||
| templateUrl: './rylo-redirect-overlay.component.html', | ||
| styleUrl: './rylo-redirect-overlay.component.scss', | ||
| }) | ||
| export class RyloRedirectOverlayComponent { | ||
| private ga = inject(GoogleAnalyticsService); | ||
|
|
||
| readonly visible = !Capacitor.isNativePlatform(); | ||
| readonly redirectUrl = 'https://rylo.com/sign/translate'; | ||
|
|
||
| async redirect(event: Event): Promise<void> { | ||
| event.preventDefault(); | ||
| try { | ||
| await this.ga.logEvent('rylo_redirect_click'); | ||
| } catch { | ||
| // Analytics must never block the redirect. | ||
| } | ||
| window.location.href = this.redirectUrl; | ||
| } | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.