1
0
mirror of https://github.com/muety/wakapi.git synced 2023-08-10 21:12:56 +03:00

Fixed custom rule settings CSS

This commit is contained in:
Roch D'Amour 2020-10-26 00:27:07 -04:00
parent 86fc751e58
commit 3f973a28ea
2 changed files with 27 additions and 26 deletions

View File

@ -14,5 +14,5 @@ func validateLanguage(language string) bool {
}
func validateExtension(extension string) bool {
return len(extension) >= 2
return len(extension) >= 1
}

View File

@ -71,8 +71,11 @@
Custom Rules
</div>
{{ if .Rules }}
<div class="text-gray-300 text-sm mb-4 mt-6">
Custom rules modify future coding activity, theyre useful for correcting languages displayed wrong on your dashboard.
</div>
{{ if .Rules }}
{{ range $i, $rule := .Rules }}
<div class="text-white border-1 w-full border-green-700 inline-block my-1 py-1 text-align">
<label class="inline-block text-sm mb-1 text-gray-500" >When filename ends in:</label>
@ -94,18 +97,16 @@
</div>
{{end}}
<form class="mt-10" action="settings/customrules" method="post">
<div class="flex justify-around mt-4">
<form action="settings/customrules" method="post">
<div class="inline-block justify-around mt-4 w-full">
<label class="inline-block text-sm mb-1 text-gray-500" for="extension">When filename ends in:</label>
<input class="shadow appearance-none bg-gray-800 focus:bg-gray-700 text-gray-300 border-green-700 focus:border-gray-500 border rounded w-full py-1 px-3"
<input class="shadow appearance-nonshadow appearance-none bg-gray-800 focus:bg-gray-700 text-gray-300 border-green-700 focus:border-gray-500 border rounded w-full py-1 px-3"
type="text" id="extension"
name="extension" placeholder="py" minlength="1" required>
</div>
<div class="flex justify-around mt-4">
<div class="inline-block justify-around mt-4 w-full">
<label class="inline-block text-sm mb-1 text-gray-500" for="language">Change the language to:</label>
<input class="shadow appearance-none bg-gray-800 focus:bg-gray-700 text-gray-300 border-green-700 focus:border-gray-500 border rounded w-full py-1 px-3"
<input class="shadow appearance-nonshadow appearance-none bg-gray-800 focus:bg-gray-700 text-gray-300 border-green-700 focus:border-gray-500 border rounded w-full py-1 px-3"
type="text" id="language"
name="language" placeholder="Python" minlength="1" required>
</div>