Skip to content

Commit

Permalink
test: add login theme tests
Browse files Browse the repository at this point in the history
  • Loading branch information
lukin committed Sep 23, 2023
1 parent fb2abd7 commit 01df82a
Show file tree
Hide file tree
Showing 36 changed files with 2,235 additions and 515 deletions.
49 changes: 49 additions & 0 deletions html/login/error.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
<html>
<head>
<title>Sign in to </title>
<meta charset="utf-8">
<meta name="robots" content="noindex, nofollow">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link href="../../theme/keywind/login/resources/dist/index.css" rel="stylesheet">
<script defer src="../../theme/keywind/login/resources/dist/index.js" type="module"></script>
</head>
<body class="bg-secondary-100 flex flex-col items-center justify-center min-h-screen sm:py-16">
<div class="max-w-md space-y-6 w-full">
<div class="bg-white p-8 rounded-lg space-y-6">
<div class="space-y-4">
<div class="font-bold text-center text-2xl">
Keywind
</div>
<h1 class="text-center text-xl">We are sorry...</h1>
</div>
<div class="space-y-4">
<div class="bg-red-100 text-red-600 p-4 rounded-lg text-sm" role="alert">
Example of an error message
</div>
<form action="loginAction" method="post">
<input name="tryAnotherWay" type="hidden" value="on"> <button class="bg-secondary-100 text-secondary-600 focus:ring-secondary-600 hover:bg-secondary-200 hover:text-secondary-900 px-4 py-2 text-sm flex justify-center relative rounded-lg w-full focus:outline-none focus:ring-2 focus:ring-offset-2" type="submit"> Try Another Way </button>
</form>
</div>
</div>
<div class="flex justify-around">
<div class="relative" x-data="{ open: false }">
<button class="text-secondary-600 hover:text-secondary-900 inline-flex" @click="open = true" type="button">
<div class="flex items-center">
<span class="mr-1 text-sm">English</span>
<svg class="h-5 w-5" fill="currentColor" viewbox="0 0 20 20" xmlns="http://www.w3.org/2000/svg">
<path clip-rule="evenodd" d="M5.23017 7.20938C5.52875 6.92228 6.00353 6.93159 6.29063 7.23017L10 11.1679L13.7094 7.23017C13.9965 6.93159 14.4713 6.92228 14.7698 7.20938C15.0684 7.49647 15.0777 7.97125 14.7906 8.26983L10.5406 12.7698C10.3992 12.9169 10.204 13 10 13C9.79599 13 9.60078 12.9169 9.45938 12.7698L5.20938 8.26983C4.92228 7.97125 4.93159 7.49647 5.23017 7.20938Z" fill-rule="evenodd" />
</svg>
</div></button>
<div @click.away="open = false" class="absolute bg-white bottom-0 -left-4 max-h-80 mb-6 overflow-y-scroll rounded-lg shadow-lg" x-cloak x-show="open">
<div class="px-4 py-2">
<a class="text-secondary-600 hover:text-secondary-900 text-sm inline-flex" href="url"> Deutsch </a>
</div>
<div class="px-4 py-2">
<a class="text-secondary-600 hover:text-secondary-900 text-sm inline-flex" href="url"> Français </a>
</div>
</div>
</div>
</div>
</div>
</body>
</html>
76 changes: 76 additions & 0 deletions html/login/login-config-totp.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
<html>
<head>
<title>Sign in to </title>
<meta charset="utf-8">
<meta name="robots" content="noindex, nofollow">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link href="../../theme/keywind/login/resources/dist/index.css" rel="stylesheet">
<script defer src="../../theme/keywind/login/resources/dist/index.js" type="module"></script>
</head>
<body class="bg-secondary-100 flex flex-col items-center justify-center min-h-screen sm:py-16">
<div class="max-w-md space-y-6 w-full">
<div class="bg-white p-8 rounded-lg space-y-6">
<div class="space-y-4">
<div class="font-bold text-center text-2xl">
Keywind
</div>
<h1 class="text-center text-xl">Mobile Authenticator Setup</h1>
</div>
<div class="space-y-4">
<div class="bg-red-100 text-red-600 p-4 rounded-lg text-sm" role="alert">
Example of an error message
</div>
<ol class="list-decimal pl-4 space-y-2">
<li class="space-y-2">
<p>Install one of the following applications on your mobile:</p>
<ul class="list-disc pl-4">
<li>FreeOTP</li>
</ul></li>
<li>
<p>Open the application and scan the barcode:</p><img alt="Figure: Barcode" class="mx-auto" src="data:image/png;base64, iVBORw0KGgoAAAANSUhEUgAAASwAAAEsCAYAAAB5fY51AAAABGdBTUEAALGPC/xhBQAAACBjSFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8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GRhdGU6bW9kaWZ5ADIwMjMtMDktMjVUMjA6MTI6NTkrMDA6MDDN8iPlAAAAAElFTkSuQmCC"> <a class="text-primary-600 hover:text-primary-500 inline-flex" href="manualUrl"> Unable to scan? </a></li>
<li>Enter the one-time code provided by the application and click Submit to finish the setup.</li>
<li>Provide a Device Name to help you manage your OTP devices.</li>
</ol>
<form class="m-0 space-y-4" method="post" action="loginAction">
<input name="totpSecret" type="hidden" value="totpSecret">
<div>
<label class="sr-only" for="totp"> One-time code * </label> <input autofocus aria-invalid="false" class="block border-secondary-200 mt-1 rounded-md w-full focus:border-primary-300 focus:ring focus:ring-primary-200 focus:ring-opacity-50 sm:text-sm" id="totp" name="totp" placeholder="One-time code *" autocomplete="off" type="text">
<div class="mt-2 text-red-600 text-sm">
</div>
</div>
<div>
<label class="sr-only" for="userLabel"> Device Name * </label> <input aria-invalid="false" class="block border-secondary-200 mt-1 rounded-md w-full focus:border-primary-300 focus:ring focus:ring-primary-200 focus:ring-opacity-50 sm:text-sm" id="userLabel" name="userLabel" placeholder="Device Name *" autocomplete="off" type="text">
<div class="mt-2 text-red-600 text-sm">
</div>
</div>
<div class="flex flex-col pt-4 space-y-2">
<button class="bg-primary-600 text-white focus:ring-primary-600 hover:bg-primary-700 px-4 py-2 text-sm flex justify-center relative rounded-lg w-full focus:outline-none focus:ring-2 focus:ring-offset-2" type="submit"> Submit </button>
</div>
</form>
<form action="loginAction" method="post">
<input name="tryAnotherWay" type="hidden" value="on"> <button class="bg-secondary-100 text-secondary-600 focus:ring-secondary-600 hover:bg-secondary-200 hover:text-secondary-900 px-4 py-2 text-sm flex justify-center relative rounded-lg w-full focus:outline-none focus:ring-2 focus:ring-offset-2" type="submit"> Try Another Way </button>
</form>
</div>
</div>
<div class="flex justify-around">
<div class="relative" x-data="{ open: false }">
<button class="text-secondary-600 hover:text-secondary-900 inline-flex" @click="open = true" type="button">
<div class="flex items-center">
<span class="mr-1 text-sm">English</span>
<svg class="h-5 w-5" fill="currentColor" viewbox="0 0 20 20" xmlns="http://www.w3.org/2000/svg">
<path clip-rule="evenodd" d="M5.23017 7.20938C5.52875 6.92228 6.00353 6.93159 6.29063 7.23017L10 11.1679L13.7094 7.23017C13.9965 6.93159 14.4713 6.92228 14.7698 7.20938C15.0684 7.49647 15.0777 7.97125 14.7906 8.26983L10.5406 12.7698C10.3992 12.9169 10.204 13 10 13C9.79599 13 9.60078 12.9169 9.45938 12.7698L5.20938 8.26983C4.92228 7.97125 4.93159 7.49647 5.23017 7.20938Z" fill-rule="evenodd" />
</svg>
</div></button>
<div @click.away="open = false" class="absolute bg-white bottom-0 -left-4 max-h-80 mb-6 overflow-y-scroll rounded-lg shadow-lg" x-cloak x-show="open">
<div class="px-4 py-2">
<a class="text-secondary-600 hover:text-secondary-900 text-sm inline-flex" href="url"> Deutsch </a>
</div>
<div class="px-4 py-2">
<a class="text-secondary-600 hover:text-secondary-900 text-sm inline-flex" href="url"> Français </a>
</div>
</div>
</div>
</div>
</div>
</body>
</html>
52 changes: 52 additions & 0 deletions html/login/login-idp-link-confirm.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
<html>
<head>
<title>Sign in to </title>
<meta charset="utf-8">
<meta name="robots" content="noindex, nofollow">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link href="../../theme/keywind/login/resources/dist/index.css" rel="stylesheet">
<script defer src="../../theme/keywind/login/resources/dist/index.js" type="module"></script>
</head>
<body class="bg-secondary-100 flex flex-col items-center justify-center min-h-screen sm:py-16">
<div class="max-w-md space-y-6 w-full">
<div class="bg-white p-8 rounded-lg space-y-6">
<div class="space-y-4">
<div class="font-bold text-center text-2xl">
Keywind
</div>
<h1 class="text-center text-xl">Account already exists</h1>
</div>
<div class="space-y-4">
<div class="bg-red-100 text-red-600 p-4 rounded-lg text-sm" role="alert">
Example of an error message
</div>
<form class="m-0 space-y-4" method="post" action="loginAction">
<button class="bg-primary-600 text-white focus:ring-primary-600 hover:bg-primary-700 px-4 py-2 text-sm flex justify-center relative rounded-lg w-full focus:outline-none focus:ring-2 focus:ring-offset-2" name="submitAction" type="submit" value="updateProfile"> Review profile </button> <button class="bg-primary-600 text-white focus:ring-primary-600 hover:bg-primary-700 px-4 py-2 text-sm flex justify-center relative rounded-lg w-full focus:outline-none focus:ring-2 focus:ring-offset-2" name="submitAction" type="submit" value="linkAccount"> Add to existing account </button>
</form>
<form action="loginAction" method="post">
<input name="tryAnotherWay" type="hidden" value="on"> <button class="bg-secondary-100 text-secondary-600 focus:ring-secondary-600 hover:bg-secondary-200 hover:text-secondary-900 px-4 py-2 text-sm flex justify-center relative rounded-lg w-full focus:outline-none focus:ring-2 focus:ring-offset-2" type="submit"> Try Another Way </button>
</form>
</div>
</div>
<div class="flex justify-around">
<div class="relative" x-data="{ open: false }">
<button class="text-secondary-600 hover:text-secondary-900 inline-flex" @click="open = true" type="button">
<div class="flex items-center">
<span class="mr-1 text-sm">English</span>
<svg class="h-5 w-5" fill="currentColor" viewbox="0 0 20 20" xmlns="http://www.w3.org/2000/svg">
<path clip-rule="evenodd" d="M5.23017 7.20938C5.52875 6.92228 6.00353 6.93159 6.29063 7.23017L10 11.1679L13.7094 7.23017C13.9965 6.93159 14.4713 6.92228 14.7698 7.20938C15.0684 7.49647 15.0777 7.97125 14.7906 8.26983L10.5406 12.7698C10.3992 12.9169 10.204 13 10 13C9.79599 13 9.60078 12.9169 9.45938 12.7698L5.20938 8.26983C4.92228 7.97125 4.93159 7.49647 5.23017 7.20938Z" fill-rule="evenodd" />
</svg>
</div></button>
<div @click.away="open = false" class="absolute bg-white bottom-0 -left-4 max-h-80 mb-6 overflow-y-scroll rounded-lg shadow-lg" x-cloak x-show="open">
<div class="px-4 py-2">
<a class="text-secondary-600 hover:text-secondary-900 text-sm inline-flex" href="url"> Deutsch </a>
</div>
<div class="px-4 py-2">
<a class="text-secondary-600 hover:text-secondary-900 text-sm inline-flex" href="url"> Français </a>
</div>
</div>
</div>
</div>
</div>
</body>
</html>
59 changes: 59 additions & 0 deletions html/login/login-oauth-grant.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
<html>
<head>
<title>Sign in to </title>
<meta charset="utf-8">
<meta name="robots" content="noindex, nofollow">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link href="../../theme/keywind/login/resources/dist/index.css" rel="stylesheet">
<script defer src="../../theme/keywind/login/resources/dist/index.js" type="module"></script>
</head>
<body class="bg-secondary-100 flex flex-col items-center justify-center min-h-screen sm:py-16">
<div class="max-w-md space-y-6 w-full">
<div class="bg-white p-8 rounded-lg space-y-6">
<div class="space-y-4">
<div class="font-bold text-center text-2xl">
Keywind
</div>
<h1 class="text-center text-xl">
<p>Grant Access to null</p></h1>
</div>
<div class="space-y-4">
<div class="bg-red-100 text-red-600 p-4 rounded-lg text-sm" role="alert">
Example of an error message
</div>
<h3>Do you grant these access privileges?</h3>
<ul class="list-disc pl-4">
</ul>
<form class="m-0 space-y-4" method="post" action="oauthAction">
<input name="code" type="hidden" value="code">
<div class="flex flex-col pt-4 space-y-2">
<button class="bg-primary-600 text-white focus:ring-primary-600 hover:bg-primary-700 px-4 py-2 text-sm flex justify-center relative rounded-lg w-full focus:outline-none focus:ring-2 focus:ring-offset-2" name="accept" type="submit"> Yes </button> <button class="bg-secondary-100 text-secondary-600 focus:ring-secondary-600 hover:bg-secondary-200 hover:text-secondary-900 px-4 py-2 text-sm flex justify-center relative rounded-lg w-full focus:outline-none focus:ring-2 focus:ring-offset-2" name="cancel" type="submit"> No </button>
</div>
</form>
<form action="loginAction" method="post">
<input name="tryAnotherWay" type="hidden" value="on"> <button class="bg-secondary-100 text-secondary-600 focus:ring-secondary-600 hover:bg-secondary-200 hover:text-secondary-900 px-4 py-2 text-sm flex justify-center relative rounded-lg w-full focus:outline-none focus:ring-2 focus:ring-offset-2" type="submit"> Try Another Way </button>
</form>
</div>
</div>
<div class="flex justify-around">
<div class="relative" x-data="{ open: false }">
<button class="text-secondary-600 hover:text-secondary-900 inline-flex" @click="open = true" type="button">
<div class="flex items-center">
<span class="mr-1 text-sm">English</span>
<svg class="h-5 w-5" fill="currentColor" viewbox="0 0 20 20" xmlns="http://www.w3.org/2000/svg">
<path clip-rule="evenodd" d="M5.23017 7.20938C5.52875 6.92228 6.00353 6.93159 6.29063 7.23017L10 11.1679L13.7094 7.23017C13.9965 6.93159 14.4713 6.92228 14.7698 7.20938C15.0684 7.49647 15.0777 7.97125 14.7906 8.26983L10.5406 12.7698C10.3992 12.9169 10.204 13 10 13C9.79599 13 9.60078 12.9169 9.45938 12.7698L5.20938 8.26983C4.92228 7.97125 4.93159 7.49647 5.23017 7.20938Z" fill-rule="evenodd" />
</svg>
</div></button>
<div @click.away="open = false" class="absolute bg-white bottom-0 -left-4 max-h-80 mb-6 overflow-y-scroll rounded-lg shadow-lg" x-cloak x-show="open">
<div class="px-4 py-2">
<a class="text-secondary-600 hover:text-secondary-900 text-sm inline-flex" href="url"> Deutsch </a>
</div>
<div class="px-4 py-2">
<a class="text-secondary-600 hover:text-secondary-900 text-sm inline-flex" href="url"> Français </a>
</div>
</div>
</div>
</div>
</div>
</body>
</html>
Loading

0 comments on commit 01df82a

Please sign in to comment.