-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
183 lines (169 loc) · 7.75 KB
/
index.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
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<!-- FAVICON -->
<link rel="icon" type="image/png" href="./assets/images/favicon/stock-market-transparent.png">
<title>PORTFOLIO EDGE | stock info app</title>
<!-- Added link for tailwind -->
<link href="https://unpkg.com/tailwindcss@^1.0/dist/tailwind.min.css" rel="stylesheet" />
<!-- Added link for our css file -->
<link rel="stylesheet" href="./style.css" />
</head>
<body>
<!-- title in bigger size bolded with margins -->
<header>
<h1 style="text-align: center; font-weight: bold; font-size: 35px;">Stock Quotes</h1>
</header>
<!-- 3 search boxes -->
<div class="flex mb-4 mx-1 mt-4">
<div class="w-1/3 h-auto">
<form class="w-full px-5 pb-1 pt-5">
<label for="nyse-ticker-input"
>Enter a company to find ticker symbol (NYSE only)</label
>
<div class="flex items-center border-teal-500 py-2">
<input
class="appearance-none bg-transparent border-none w-full text-gray-700 py-1 px-2 leading-tight focus:outline-none h-10"
type="text"
placeholder="Enter company traded on NYSE..."
aria-label="Full name"
id="nyse-ticker-input"
/>
<button
class="bg-teal-500 hover:bg-teal-700 border-teal-500 hover:border-teal-700 text-lg border-4 text-white py-1 px-2 rounded"
id="nyse-ticker-searchBtn"
type="button"
>
Search
</button>
</div>
<p id="nyse-ticker" style="display: none"></p>
</form>
<form class="w-full px-5 pb-5 pt-1">
<label for="nasdaq-ticker-input"
>Enter a company to find ticker symbol (NASDAQ only)</label
>
<div class="flex items-center border-teal-500 py-2">
<input
class="appearance-none bg-transparent border-none w-full text-gray-700 py-1 px-2 leading-tight focus:outline-none h-10"
type="text"
placeholder="Enter company traded on NASDAQ..."
aria-label="Full name"
id="nasdaq-ticker-input"
/>
<button
class="bg-teal-500 hover:bg-teal-700 border-teal-500 hover:border-teal-700 text-lg border-4 text-white py-1 px-2 rounded"
id="nasdaq-ticker-searchBtn"
type="button"
>
Search
</button>
</div>
<p id="nasdaq-ticker" style="display: none"></p>
</form>
<form class="w-full px-5 pb-5 pt-1 block">
<label for="clear-search-btn"
>Click to clear screen:</label
>
<div class="flex text-center border-teal-500 py-2">
<button class="bg-teal-500 hover:bg-teal-700 border-teal-500 hover:border-teal-700 text-lg border-4 text-white py-1 px-2 rounded"
id="clear-search-btn"
type="button">Clear Search</button>
</div>
</form>
<!-- <form class="w-full max-w-sm">
<label for="stock-profile-input">Enter a stock for company profile:</label>
<div class="flex items-center border-teal-500 py-2">
<input
class="appearance-none bg-transparent border-none w-full text-gray-700 mr-3 py-1 px-2 leading-tight focus:outline-none"
type="text"
placeholder="Enter a stock symbol..."
aria-label="Full name"
id="stock-profile-input"
/>
<button
class="flex-shrink-0 bg-teal-500 hover:bg-teal-700 border-teal-500 hover:border-teal-700 text-lg border-4 text-white py-1 px-2 rounded"
id="stock-profile-searchBtn"
type="button"
>
<div class="flex items-center border-teal-500 py-2">
<input
class="appearance-none bg-transparent border-none w-full text-gray-700 mr-3 py-2 px-2 leading-tight focus:outline-none"
type="text"
placeholder="Company's name..."
aria-label="Full name"
id="nasdaq-ticker-input"
/>
<button
class="flex-shrink-0 bg-teal-500 hover:bg-teal-700 border-teal-500 hover:border-teal-700 text-lg border-4 text-white py-1 px-2 rounded"
id="nasdaq-ticker-searchBtn"
type="button"
>
Search
</button>
</div>
<p id="nasdaq-ticker" style="display: none"></p>
</form>
</fieldset>
Input box for ticker search -->
<!-- <form class="w-full max-w-sm labelTicker" style="margin-top: 10px">
<label for="stock-profile-input">Search for stocks:</label>
<div class="flex items-center border-teal-500 py-2">
<input class="appearance-none bg-transparent border-none w-full text-gray-700 mr-3 py-2 px-2 leading-tight focus:outline-none" type="text" placeholder="Enter a stock symbol..." aria-label="Full name" id="stock-profile-input" />
<button class="flex-shrink-0 bg-teal-500 hover:bg-teal-700 border-teal-500 hover:border-teal-700 text-lg border-4 text-white py-1 px-2 rounded" id="stock-profile-searchBtn" type="button">
Search
</button>
</div>
</form> -->
</div>
<!-- company profile is put below -->
<!-- <div class="w-2/3 h-auto flex-auto"> -->
<fieldset class="w-2/3 h-auto border-green-400 mx-3">
<h2>Company profile</h2>
<hr style="margin: 0px 50px 0px 10px; border: 1px solid tomato; border-radius: 5px"></hr>
<!-- <h4 style="margin: 10px">Company profile</h4> -->
<!-- <hr style="margin: 0px 50px 0px 10px"></hr> -->
<div id="company-profile" style="white-space: pre-wrap; margin: 10px" id="company-info"></div>
</fieldset>
<!-- </div> -->
</div>
<!-- section with chart and stock data -->
<div class="flex mb-4">
<!-- chart -->
<div style="margin: 10px" class="w-1/2 h-auto flex-auto border border-green-400">
<div id="chart">
<canvas id="myChart"></canvas>
</div>
</div>
<!-- stock data -->
<section style="margin: 10px;" class="w-1/2 h-auto border border-green-400">
<h4 style="margin: 10px">Stock Information</h4>
<hr style="margin: 0px 50px 0px 10px; border: 1px solid tomato; border-radius: 5px"></hr>
<div id="stock-info" class="flex">
<!-- info list on the left of the div -->
<div class="w-1/2 h-auto flex-auto">
<ul style="margin: 10px" id="left-ul"></ul>
</div>
<!-- info list on the right of the div -->
<div class="w-1/2 h-auto flex-auto">
<ul style="margin: 10px" id="right-ul"></ul>
</div>
</div>
</section>
</div>
<!-- stock news go below -->
<div class="container mx-auto">
<h4 class="w-full">Stock News</h4>
<hr style="margin: 10px 50px 10px 10px; border: 1px solid tomato; border-radius: 5px"></hr>
<div id="stock-news"></div>
</div>
<!-- chart.js library -->
<script src="https://cdn.jsdelivr.net/npm/[email protected]"></script>
<!-- jquery library -->
<script src="https://code.jquery.com/jquery-3.5.1.js" integrity="sha256-QWo7LDvxbWT2tbbQ97B53yJnYU3WhH/C8ycbRAkjPDc=" crossorigin="anonymous"></script>
<!-- our javascript file link -->
<script src="./app.js"></script>
</body>
</html>