RiverTest commited on
Commit
7193f6f
·
verified ·
1 Parent(s): 70a89d3

clear everything but a single text box input

Browse files
Files changed (1) hide show
  1. index.html +10 -156
index.html CHANGED
@@ -4,172 +4,26 @@
4
  <head>
5
  <meta charset="UTF-8">
6
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
7
- <title>Google</title>
8
  <style>
9
  body {
10
- font-family: Arial, sans-serif;
11
- margin: 0;
12
- padding: 0;
13
- display: flex;
14
- flex-direction: column;
15
- height: 100vh;
16
- }
17
- .search-container {
18
  display: flex;
19
- flex-direction: column;
20
- align-items: center;
21
  justify-content: center;
22
- flex-grow: 1;
23
- margin-top: -100px;
24
- }
25
- .logo {
26
- margin-bottom: 20px;
27
- }
28
- .search-box {
29
- display: flex;
30
- border: 1px solid #dfe1e5;
31
- border-radius: 24px;
32
- width: 584px;
33
- height: 44px;
34
- margin: 0 auto;
35
- padding: 5px 15px;
36
- }
37
- .search-box:hover {
38
- box-shadow: 0 1px 6px rgba(32,33,36,.28);
39
  }
40
- .search-input {
41
- border: none;
42
- outline: none;
43
- flex-grow: 1;
44
  font-size: 16px;
45
- }
46
- .buttons {
47
- margin-top: 30px;
48
- }
49
- .btn {
50
- background-color: #f8f9fa;
51
- border: 1px solid #f8f9fa;
52
  border-radius: 4px;
53
- color: #3c4043;
54
- font-size: 14px;
55
- padding: 0 16px;
56
- line-height: 27px;
57
- height: 36px;
58
- min-width: 54px;
59
- text-align: center;
60
- cursor: pointer;
61
- margin: 0 4px;
62
- }
63
- .btn:hover {
64
- box-shadow: 0 1px 1px rgba(0,0,0,.1);
65
- border: 1px solid #dadce0;
66
- }
67
- .nav {
68
- display: flex;
69
- justify-content: flex-end;
70
- padding: 6px;
71
- }
72
- .nav a {
73
- color: rgba(0,0,0,.87);
74
- text-decoration: none;
75
- font-size: 13px;
76
- padding: 5px 10px;
77
- }
78
- .nav a:hover {
79
- text-decoration: underline;
80
- }
81
- .footer {
82
- background: #f2f2f2;
83
- position: fixed;
84
- bottom: 0;
85
- width: 100%;
86
- }
87
- .footer-line {
88
- padding: 15px 30px;
89
- border-bottom: 1px solid #dadce0;
90
- font-size: 15px;
91
- color: rgba(0,0,0,.54);
92
- }
93
- .footer-links {
94
- display: flex;
95
- flex-wrap: wrap;
96
- justify-content: space-between;
97
- padding: 0 20px;
98
- }
99
- .footer-links a {
100
- color: #70757a;
101
- text-decoration: none;
102
- font-size: 14px;
103
- padding: 15px;
104
- }
105
- .footer-links a:hover {
106
- text-decoration: underline;
107
  }
108
  </style>
109
  </head>
110
  <body>
111
- <div class="nav">
112
- <a href="#">Gmail</a>
113
- <a href="#">Images</a>
114
- <a href="#">
115
- <svg focusable="false" viewBox="0 0 24 24" width="24" height="24" style="vertical-align: middle;">
116
- <path d="M6,8c1.1,0 2,-0.9 2,-2s-0.9,-2 -2,-2 -2,0.9 -2,2 0.9,2 2,2zM12,20c1.1,0 2,-0.9 2,-2s-0.9,-2 -2,-2 -2,0.9 -2,2 0.9,2 2,2zM6,20c1.1,0 2,-0.9 2,-2s-0.9,-2 -2,-2 -2,0.9 -2,2 0.9,2 2,2zM6,14c1.1,0 2,-0.9 2,-2s-0.9,-2 -2,-2 -2,0.9 -2,2 0.9,2 2,2zM12,14c1.1,0 2,-0.9 2,-2s-0.9,-2 -2,-2 -2,0.9 -2,2 0.9,2 2,2zM16,6c0,1.1 0.9,2 2,2s2,-0.9 2,-2 -0.9,-2 -2,-2 -2,0.9 -2,2zM12,8c1.1,0 2,-0.9 2,-2s-0.9,-2 -2,-2 -2,0.9 -2,2 0.9,2 2,2zM18,14c1.1,0 2,-0.9 2,-2s-0.9,-2 -2,-2 -2,0.9 -2,2 0.9,2 2,2zM18,20c1.1,0 2,-0.9 2,-2s-0.9,-2 -2,-2 -2,0.9 -2,2 0.9,2 2,2z"></path>
117
- </svg>
118
- </a>
119
- <a href="#">
120
- <button class="btn sign-in">Sign in</button>
121
- </a>
122
- </div>
123
-
124
- <div class="search-container">
125
- <div class="logo">
126
- <img src="https://www.google.com/images/branding/googlelogo/1x/googlelogo_color_272x92dp.png" alt="Google">
127
- </div>
128
- <div class="search-box">
129
- <svg focusable="false" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24" style="margin-right: 10px;">
130
- <path d="M15.5 14h-.79l-.28-.27A6.471 6.471 0 0 0 16 9.5 6.5 6.5 0 1 0 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z"></path>
131
- </svg>
132
- <input type="text" class="search-input">
133
- <svg focusable="false" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24" style="margin-left: 10px;">
134
- <path d="M12 15c1.66 0 3-1.34 3-3V6c0-1.66-1.34-3-3-3S9 4.34 9 6v6c0 1.66 1.34 3 3 3zm-1.2-9.1c0-.66.54-1.2 1.2-1.2.66 0 1.2.54 1.2 1.2l-.01 6.2c0 .66-.53 1.2-1.19 1.2-.66 0-1.2-.54-1.2-1.2V5.9zm6.5 6.1c0 3-2.54 5.1-5.3 5.1S6.7 15 6.7 12H5c0 3.41 2.72 6.23 6 6.72V22h2v-3.28c3.28-.48 6-3.3 6-6.72h-1.7z"></path>
135
- </svg>
136
- </div>
137
- <div class="buttons">
138
- <button class="btn" onclick="
139
- const searchTerm = document.querySelector('.search-input').value;
140
- localStorage.setItem('lastSearch', searchTerm);
141
- console.log('Search term saved to localStorage:', searchTerm);
142
- document.querySelector('.search-input').value = '';
143
- ">Google Search</button>
144
- <button class="btn">I'm Feeling Lucky</button>
145
- </div>
146
- </div>
147
-
148
- <div class="footer">
149
- <div class="footer-line">
150
- United States | Last search: <span id="lastSearch"></span>
151
- </div>
152
- <div class="footer-links">
153
- <div>
154
- <a href="#">About</a>
155
- <a href="#">Advertising</a>
156
- <a href="#">Business</a>
157
- <a href="#">How Search works</a>
158
- </div>
159
- <div>
160
- <a href="#">Privacy</a>
161
- <a href="#">Terms</a>
162
- <a href="#">Settings</a>
163
- </div>
164
- </div>
165
- </div>
166
- <script>
167
- document.addEventListener('DOMContentLoaded', function() {
168
- const lastSearch = localStorage.getItem('lastSearch');
169
- if (lastSearch) {
170
- document.getElementById('lastSearch').textContent = lastSearch;
171
- }
172
- });
173
- </script>
174
  </body>
175
  </html>
 
4
  <head>
5
  <meta charset="UTF-8">
6
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
7
+ <title>Text Input</title>
8
  <style>
9
  body {
 
 
 
 
 
 
 
 
10
  display: flex;
 
 
11
  justify-content: center;
12
+ align-items: center;
13
+ height: 100vh;
14
+ margin: 0;
15
+ padding: 0;
 
 
 
 
 
 
 
 
 
 
 
 
 
16
  }
17
+ input {
18
+ padding: 10px;
 
 
19
  font-size: 16px;
20
+ border: 1px solid #ccc;
 
 
 
 
 
 
21
  border-radius: 4px;
22
+ min-width: 300px;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
23
  }
24
  </style>
25
  </head>
26
  <body>
27
+ <input type="text">
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
28
  </body>
29
  </html>