From 591468dd7907e699983091fa7924edcf29147ba1 Mon Sep 17 00:00:00 2001
From: Joel Beckmeyer
Date: Sat, 26 Mar 2022 20:55:52 -0400
Subject: [PATCH 1/2] New package: vaultwarden-web-2022.05.0
---
.../vaultwarden-web/patches/v2022.05.0.patch | 312 ++++++++++++++++++
srcpkgs/vaultwarden-web/template | 33 ++
2 files changed, 345 insertions(+)
create mode 100644 srcpkgs/vaultwarden-web/patches/v2022.05.0.patch
create mode 100644 srcpkgs/vaultwarden-web/template
diff --git a/srcpkgs/vaultwarden-web/patches/v2022.05.0.patch b/srcpkgs/vaultwarden-web/patches/v2022.05.0.patch
new file mode 100644
index 000000000000..8ed7c0f6a433
--- /dev/null
+++ b/srcpkgs/vaultwarden-web/patches/v2022.05.0.patch
@@ -0,0 +1,312 @@
+Submodule jslib contains modified content
+diff --git a/jslib/angular/src/components/register.component.ts b/jslib/angular/src/components/register.component.ts
+index d4b99e17..c1626200 100644
+--- a/jslib/angular/src/components/register.component.ts
++++ b/jslib/angular/src/components/register.component.ts
+@@ -28,7 +28,7 @@ export class RegisterComponent extends CaptchaProtectedComponent implements OnIn
+ formPromise: Promise;
+ masterPasswordScore: number;
+ referenceData: ReferenceEventRequest;
+- showTerms = true;
++ showTerms = false;
+ acceptPolicies = false;
+
+ protected successRoute = "login";
+@@ -47,7 +47,7 @@ export class RegisterComponent extends CaptchaProtectedComponent implements OnIn
+ protected logService: LogService
+ ) {
+ super(environmentService, i18nService, platformUtilsService);
+- this.showTerms = !platformUtilsService.isSelfHost();
++ this.showTerms = false;
+ }
+
+ async ngOnInit() {
+@@ -85,6 +85,15 @@ export class RegisterComponent extends CaptchaProtectedComponent implements OnIn
+ }
+
+ async submit() {
++ if (typeof crypto.subtle === 'undefined') {
++ this.platformUtilsService.showToast(
++ "error",
++ "This browser requires HTTPS to use the web vault",
++ "Check the Vaultwarden wiki for details on how to enable it"
++ );
++ return;
++ }
++
+ if (!this.acceptPolicies && this.showTerms) {
+ this.platformUtilsService.showToast(
+ "error",
+diff --git a/src/404.html b/src/404.html
+index 6cf5e363..54d11495 100644
+--- a/src/404.html
++++ b/src/404.html
+@@ -42,11 +42,10 @@
+
+
+
+- You can return to the web vault, check our
+- status page or
+- contact us.
++ You can return to the web vault, or
++ contact us.
+
+
+-
++
+