stylized Choose Save File button

This commit is contained in:
ReznoRMichael 2021-07-20 14:32:11 +02:00
parent 0976c4426b
commit 227e906145
5 changed files with 41 additions and 9 deletions

View file

@ -183,7 +183,8 @@
<div class="input-buttons"> <div class="input-buttons">
<!-- <input id="save-area-file" class="" type="file" name="file" accept=".dat,.bak*" onchange="LoadSaveFile(this);" onclick="this.value = '';"> --> <!-- <input id="save-area-file" class="" type="file" name="file" accept=".dat,.bak*" onchange="LoadSaveFile(this);" onclick="this.value = '';"> -->
<input id="save-area-file" class="" type="file" name="file" accept=".dat,.bak*"> <input id="save-area-file" class="input-file" type="file" name="file" accept=".dat,.bak*">
<label for="save-area-file" class="button">Choose Save File</label>
</div> </div>
<div class="input-buttons"> <div class="input-buttons">

View file

@ -332,8 +332,17 @@ textarea::placeholder {
} }
input[type="file"] { input[type="file"] {
max-width: 500px; /* max-width: 500px; */
margin: 0.5rem 0.5rem 0.5rem 0.25rem; /* margin: 0.5rem 0.5rem 0.5rem 0.25rem; */
}
.input-file {
width: 0.1px;
height: 0.1px;
opacity: 0;
overflow: hidden;
position: absolute;
z-index: -1;
} }
#save-area { #save-area {
@ -443,7 +452,8 @@ input[type="file"] {
cursor: pointer; cursor: pointer;
} }
.button:focus { .button:focus,
.input-file:focus + label {
/* outline: 2px solid #5e8dac; */ /* outline: 2px solid #5e8dac; */
outline: 0; outline: 0;
border-color: #5e8dac; border-color: #5e8dac;
@ -799,6 +809,11 @@ input[type="radio"] {
background: #000; background: #000;
} }
/* input[type="checkbox"]:focus + label,
input[type="radio"]:focus + label {
outline: solid 1px #aac7d4;
} */
.tooltip { .tooltip {
position: relative; position: relative;
display: block; display: block;

File diff suppressed because one or more lines are too long

View file

@ -225,8 +225,17 @@ textarea::placeholder {
} }
input[type="file"] { input[type="file"] {
max-width: 500px; /* max-width: 500px; */
margin: 0.5rem 0.5rem 0.5rem 0.25rem; /* margin: 0.5rem 0.5rem 0.5rem 0.25rem; */
}
.input-file {
width: 0.1px;
height: 0.1px;
opacity: 0;
overflow: hidden;
position: absolute;
z-index: -1;
} }
#save-area { #save-area {
@ -336,7 +345,8 @@ input[type="file"] {
cursor: pointer; cursor: pointer;
} }
.button:focus { .button:focus,
.input-file:focus + label {
/* outline: 2px solid #5e8dac; */ /* outline: 2px solid #5e8dac; */
outline: 0; outline: 0;
border-color: #5e8dac; border-color: #5e8dac;
@ -692,6 +702,11 @@ input[type="radio"] {
background: #000; background: #000;
} }
/* input[type="checkbox"]:focus + label,
input[type="radio"]:focus + label {
outline: solid 1px #aac7d4;
} */
.tooltip { .tooltip {
position: relative; position: relative;
display: block; display: block;

View file

@ -68,7 +68,8 @@
<div class="input-buttons"> <div class="input-buttons">
<!-- <input id="save-area-file" class="" type="file" name="file" accept=".dat,.bak*" onchange="LoadSaveFile(this);" onclick="this.value = '';"> --> <!-- <input id="save-area-file" class="" type="file" name="file" accept=".dat,.bak*" onchange="LoadSaveFile(this);" onclick="this.value = '';"> -->
<input id="save-area-file" class="" type="file" name="file" accept=".dat,.bak*"> <input id="save-area-file" class="input-file" type="file" name="file" accept=".dat,.bak*">
<label for="save-area-file" class="button">Choose Save File</label>
</div> </div>
<div class="input-buttons"> <div class="input-buttons">