Skip to content

Commit 6633b82

Browse files
committed
feat(temperature) : add input and btn css
1 parent 4895056 commit 6633b82

File tree

2 files changed

+34
-8
lines changed

2 files changed

+34
-8
lines changed

Temperature-convertor/index.html

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,16 @@
1111
<h1>Temperature convertor</h1>
1212

1313
<form action="" method="post" id="form">
14-
<label for="response">Temperature</label>
15-
<input type="text" name="response" id="response">
14+
<h2 >Type of conversion</h2>
15+
<div class="btn-section">
16+
<button type="button" onclick="getSentenceResult();">Celsius</button>
17+
<button type="button" onclick="getSentenceResult();">Fahrenheit </button>
18+
19+
</div>
20+
<div class="input-section">
21+
<label for="response">Temperature</label>
22+
<input type="text" name="response" id="response" placeholder="12">
23+
</div>
1624
<button type="button" onclick="getSentenceResult();">Submit</button>
1725
</form>
1826
<section id="element_result" style="font-size: larger;">

Temperature-convertor/style.css

Lines changed: 24 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -43,20 +43,30 @@ button{
4343
transition: box-shadow 0.2s ease 0s, -ms-transform 0.1s ease 0s, -webkit-transform 0.1s ease 0s, transform 0.1s ease 0s;
4444
background: #fff;
4545
color: #222222;
46-
}
47-
:hover {
46+
}:hover {
4847
border-color: #000000;
4948
background: #f7f7f7;
5049
}
50+
.btn-section {
51+
display: flex;
52+
justify-content: space-around;
53+
}
54+
.btn-section button{
55+
width: 150px;
56+
color: #f7f7f7;
57+
background-color: #86b0ff;
58+
text-align: center;
59+
60+
}:hover {
61+
border-color: #000000;
62+
}
5163
#form{
52-
53-
max-width: 300px;
64+
max-width: 500px;
65+
min-width: 450px;
5466
min-height: 200px;
5567
display: flex;
5668
flex-direction: column;
5769
justify-content: space-between;
58-
59-
max-width: 500px;
6070
height: 300px;
6171
padding: 35px;
6272

@@ -65,3 +75,11 @@ button{
6575
background-color: rgba(255, 255, 255, 0.45);
6676
box-shadow: 0px 4px 6px 0px rgba(50,50,93,0.11) , 0px 1px 3px 0px rgba(0,0,0,0.08);
6777
}
78+
.input-section{
79+
display: flex;
80+
flex-direction: column;
81+
}
82+
.input-section label{
83+
font-weight: bold;
84+
margin-bottom: 5px;
85+
}

0 commit comments

Comments
 (0)