Skip to content

Privacy-first password manager with built-in email aliasing. Fully encrypted and self-hostable.

Add mobile app download link constants (#827)

Leendert de Borstbc7f2d9d3a25
diff --git a/apps/server/AliasVault.Client/wwwroot/img/mobile-icons/android.svg b/apps/server/AliasVault.Client/wwwroot/img/mobile-icons/android.svg
new file mode 100644
index 000000000..071b9cc93
--- /dev/null
+++ b/apps/server/AliasVault.Client/wwwroot/img/mobile-icons/android.svg
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+<!-- Uploaded to: SVG Repo, www.svgrepo.com, Generator: SVG Repo Mixer Tools -->
+<svg height="800px" width="800px" version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"
+ viewBox="0 0 511.999 511.999" xml:space="preserve">
+<g>
+ <path style="fill:#32BBFF;" d="M382.369,175.623C322.891,142.356,227.427,88.937,79.355,6.028
+ C69.372-0.565,57.886-1.429,47.962,1.93l254.05,254.05L382.369,175.623z"/>
+ <path style="fill:#32BBFF;" d="M47.962,1.93c-1.86,0.63-3.67,1.39-5.401,2.308C31.602,10.166,23.549,21.573,23.549,36v439.96
+ c0,14.427,8.052,25.834,19.012,31.761c1.728,0.917,3.537,1.68,5.395,2.314L302.012,255.98L47.962,1.93z"/>
+ <path style="fill:#32BBFF;" d="M302.012,255.98L47.956,510.035c9.927,3.384,21.413,2.586,31.399-4.103
+ c143.598-80.41,237.986-133.196,298.152-166.746c1.675-0.941,3.316-1.861,4.938-2.772L302.012,255.98z"/>
+</g>
+<path style="fill:#2C9FD9;" d="M23.549,255.98v219.98c0,14.427,8.052,25.834,19.012,31.761c1.728,0.917,3.537,1.68,5.395,2.314
+ L302.012,255.98H23.549z"/>
+<path style="fill:#29CC5E;" d="M79.355,6.028C67.5-1.8,53.52-1.577,42.561,4.239l255.595,255.596l84.212-84.212
+ C322.891,142.356,227.427,88.937,79.355,6.028z"/>
+<path style="fill:#D93F21;" d="M298.158,252.126L42.561,507.721c10.96,5.815,24.939,6.151,36.794-1.789
+ c143.598-80.41,237.986-133.196,298.152-166.746c1.675-0.941,3.316-1.861,4.938-2.772L298.158,252.126z"/>
+<path style="fill:#FFD500;" d="M488.45,255.98c0-12.19-6.151-24.492-18.342-31.314c0,0-22.799-12.721-92.682-51.809l-83.123,83.123
+ l83.204,83.205c69.116-38.807,92.6-51.892,92.6-51.892C482.299,280.472,488.45,268.17,488.45,255.98z"/>
+<path style="fill:#FFAA00;" d="M470.108,287.294c12.191-6.822,18.342-19.124,18.342-31.314H294.303l83.204,83.205
+ C446.624,300.379,470.108,287.294,470.108,287.294z"/>
+</svg>
\ No newline at end of file
diff --git a/apps/server/AliasVault.Client/wwwroot/img/mobile-icons/ios.svg b/apps/server/AliasVault.Client/wwwroot/img/mobile-icons/ios.svg
new file mode 100644
index 000000000..8e3f54ccf
--- /dev/null
+++ b/apps/server/AliasVault.Client/wwwroot/img/mobile-icons/ios.svg
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Generator: Adobe Illustrator 23.0.1, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
+<svg version="1.1" id="Capa_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
+ viewBox="0 0 800 800" enable-background="new 0 0 800 800" xml:space="preserve">
+<linearGradient id="SVGID_1_" gradientUnits="userSpaceOnUse" x1="400.05" y1="798.7717" x2="400.05" y2="-1.2283" gradientTransform="matrix(1 0 0 -1 0 798.7717)">
+ <stop offset="0" style="stop-color:#18BFFB"/>
+ <stop offset="1" style="stop-color:#2072F3"/>
+</linearGradient>
+<path fill="url(#SVGID_1_)" d="M638.4,0H161.6C72.3,0,0,72.3,0,161.6v476.9C0,727.7,72.3,800,161.6,800h476.9
+ c89.2,0,161.6-72.3,161.6-161.6V161.6C800,72.3,727.7,0,638.4,0z"/>
+<path fill="#FFFFFF" d="M396.6,183.8l16.2-28c10-17.5,32.3-23.4,49.8-13.4s23.4,32.3,13.4,49.8L319.9,462.4h112.9
+ c36.6,0,57.1,43,41.2,72.8H143c-20.2,0-36.4-16.2-36.4-36.4c0-20.2,16.2-36.4,36.4-36.4h92.8l118.8-205.9l-37.1-64.4
+ c-10-17.5-4.1-39.6,13.4-49.8c17.5-10,39.6-4.1,49.8,13.4L396.6,183.8L396.6,183.8z M256.2,572.7l-35,60.7
+ c-10,17.5-32.3,23.4-49.8,13.4S148,614.5,158,597l26-45C213.4,542.9,237.3,549.9,256.2,572.7L256.2,572.7z M557.6,462.6h94.7
+ c20.2,0,36.4,16.2,36.4,36.4c0,20.2-16.2,36.4-36.4,36.4h-52.6l35.5,61.6c10,17.5,4.1,39.6-13.4,49.8c-17.5,10-39.6,4.1-49.8-13.4
+ c-59.8-103.7-104.7-181.3-134.5-233c-30.5-52.6-8.7-105.4,12.8-123.3C474.2,318.1,509.9,380,557.6,462.6L557.6,462.6z"/>
+</svg>
diff --git a/apps/server/Shared/AliasVault.Shared.Core/MobileApps/Constants.cs b/apps/server/Shared/AliasVault.Shared.Core/MobileApps/Constants.cs
new file mode 100644
index 000000000..592c989a0
--- /dev/null
+++ b/apps/server/Shared/AliasVault.Shared.Core/MobileApps/Constants.cs
@@ -0,0 +1,36 @@
+//-----------------------------------------------------------------------
+// <copyright file="Constants.cs" company="lanedirt">
+// Copyright (c) lanedirt. All rights reserved.
+// Licensed under the MIT license. See LICENSE.md file in the project root for full license information.
+// </copyright>
+//-----------------------------------------------------------------------
+#pragma warning disable S1075 // URIs should not be hardcoded
+
+namespace AliasVault.Shared.Core.MobileApps;
+
+/// <summary>
+/// Provides constants for mobile app information.
+/// </summary>
+public static class Constants
+{
+ /// <summary>
+ /// Gets the mobile apps available for AliasVault. This is used to render download links in the client.
+ /// </summary>
+ public static IReadOnlyList<MobileAppInfo> MobileApps { get; } = new List<MobileAppInfo>
+ {
+ new MobileAppInfo
+ {
+ Name = "iOS",
+ IconPath = "/img/mobile-icons/ios.svg",
+ DownloadUrl = "https://apps.apple.com/app/id6745490915",
+ IsAvailable = true,
+ },
+ new MobileAppInfo
+ {
+ Name = "Android",
+ IconPath = "/img/mobile-icons/android.svg",
+ DownloadUrl = "https://play.google.com/store/apps/details?id=com.aliasvault.app",
+ IsAvailable = false,
+ },
+ };
+}
diff --git a/apps/server/Shared/AliasVault.Shared.Core/MobileApps/MobileAppInfo.cs b/apps/server/Shared/AliasVault.Shared.Core/MobileApps/MobileAppInfo.cs
new file mode 100644
index 000000000..8c5458980
--- /dev/null
+++ b/apps/server/Shared/AliasVault.Shared.Core/MobileApps/MobileAppInfo.cs
@@ -0,0 +1,32 @@
+//-----------------------------------------------------------------------
+// <copyright file="MobileAppInfo.cs" company="lanedirt">
+// Copyright (c) lanedirt. All rights reserved.
+// Licensed under the MIT license. See LICENSE.md file in the project root for full license information.
+// </copyright>
+//-----------------------------------------------------------------------
+
+/// <summary>
+/// Represents information about a mobile app.
+/// </summary>
+public class MobileAppInfo
+{
+ /// <summary>
+ /// Gets or sets the name of the mobile app.
+ /// </summary>
+ public string Name { get; set; } = string.Empty;
+
+ /// <summary>
+ /// Gets or sets the path to the icon of the mobile app.
+ /// </summary>
+ public string IconPath { get; set; } = string.Empty;
+
+ /// <summary>
+ /// Gets or sets the download URL for the mobile app.
+ /// </summary>
+ public string DownloadUrl { get; set; } = string.Empty;
+
+ /// <summary>
+ /// Gets or sets a value indicating whether the mobile app is available.
+ /// </summary>
+ public bool IsAvailable { get; set; }
+}