-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmyTextarea.html
108 lines (108 loc) · 2.89 KB
/
myTextarea.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Document</title>
<style>
:root {
--bgColor: #dddddd;
--boxShadow1: rgba(244, 244, 244, 0.7);
--boxShadow2: rgba(136, 136, 136, 0.7);
}
* {
margin: 0;
padding: 0;
box-sizing: border-box;
font-family: sans-serif;
}
body {
display: flex;
justify-content: center;
align-items: center;
height: 100vh;
background-color: var(--bgColor);
}
.container-form {
display: flex;
justify-content: center;
align-items: center;
min-height: 100vh;
background-color: var(--bgColor);
}
.myform {
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
padding: 10px;
box-shadow: 0 0 3px 3px var(--bgColor),
4px 4px 5px 2px var(--boxShadow2), -4px -4px 5px 2px var(--boxShadow1);
}
.text-area {
padding: 10px;
min-width: 300px;
resize: none;
height: 120px;
margin: 10px;
border-style: none;
border-radius: 4px;
box-shadow: 0 0 3px 3px var(--bgColor),
inset 2px 2px 4px 1px var(--boxShadow2),
inset -2px -2px 4px 3px var(--boxShadow1);
background-color: var(--bgColor);
}
.text-area:focus {
outline: none;
}
.upload-file {
height: 30px;
cursor: pointer;
position: relative;
top: -44px;
left: 133px;
padding: 2px 1px;
border-radius: 3px;
background-color: var(--bgColor);
box-shadow: 2px 2px 3px 3px var(--bgColor),
-4px -4px 6px 2px var(--boxShadow1);
}
.upload-post {
display: none;
}
.text-submit {
border-style: none;
background-color: var(--bgColor);
padding: 8px;
width: 80px;
font-weight: bold;
border-radius: 3px;
margin-bottom: 15px;
cursor: pointer;
box-shadow: 2px 2px 3px 3px var(--bgColor),
4px 4px 6px 2px var(--boxShadow2), -4px -4px 6px 2px var(--boxShadow1);
}
.text-submit:active {
transform: scale(0.9);
}
</style>
</head>
<body>
<div class="container-form">
<form class="myform">
<label for="textarea"></label>
<textarea
name="textarea"
id="text-area"
class="text-area"
placeholder="what about think . . ."
></textarea>
<label for="file"
><img src="/post.png" alt="" srcset="" class="upload-file"
/></label>
<input type="file" class="upload-post" id="file" />
<button class="text-submit">Post</button>
</form>
</div>
</body>
</html>