-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindexPWA.html
More file actions
207 lines (166 loc) · 7.06 KB
/
indexPWA.html
File metadata and controls
207 lines (166 loc) · 7.06 KB
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
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1 , viewport-fit=cover">
<meta name="mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="black-translucent">
<title>signpost PWA</title>
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.0.2/dist/css/bootstrap.min.css" rel="stylesheet">
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.5.0/font/bootstrap-icons.css">
<link href="https://fonts.googleapis.com/css?family=Montserrat&display=swap" rel="stylesheet">
<link href="https://cdn.jsdelivr.net/npm/boxicons@latest/css/boxicons.min.css" rel="stylesheet">
<link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:opsz,wght,FILL,GRAD@20..48,100..700,0..1,-50..200" />
<link href="https://cdn.datatables.net/1.13.6/css/jquery.dataTables.min.css" rel="stylesheet">
<link href="https://cdn.datatables.net/1.13.6/css/dataTables.bootstrap5.min.css" rel="stylesheet">
<link href="https://cdn.datatables.net/buttons/2.4.1/css/buttons.dataTables.min.css" rel="stylesheet">
<script src="https://code.jquery.com/jquery-3.5.1.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.0.2/dist/js/bootstrap.bundle.min.js"></script>
<script src="https://cdn.datatables.net/1.13.6/js/jquery.dataTables.min.js"></script>
<script src="https://cdn.datatables.net/fixedcolumns/4.3.0/js/dataTables.fixedColumns.min.js"></script>
<script src="https://cdn.datatables.net/buttons/2.4.1/js/dataTables.buttons.min.js"></script>
<script src="https://cdn.datatables.net/buttons/2.4.1/js/buttons.colVis.min.js"></script>
<!-- APP Manifest -->
<link rel="manifest" href="/manifest.json">
<style>
:root {
--gridHeight: 60px;
--gridHeightKPI: calc(var(--gridHeight) * 1.2) ;
--gridHeightLogo:calc(var(--gridHeight) * 3) ;
--gridHeightFoot: var(--gridHeight) ;
--spCardBaseFont: 16px;
}
body {
background-color: lightblue;
}
.footer-container {
display: flex;
flex-direction: row;
flex-wrap: nowrap;
justify-content: space-between;
align-items: center;
align-content: center;
}
.footer-items:nth-child(1) {
display: block;
flex-grow: 0;
flex-shrink: 1;
flex-basis: auto;
align-self: auto;
order: 0;
}
.footer-items:nth-child(2) {
display: block;
flex-grow: 0;
flex-shrink: 1;
flex-basis: auto;
align-self: auto;
order: 0;
}
.footer-container {
display: flex;
flex-direction: row;
flex-wrap: nowrap;
justify-content: space-between;
align-items: center;
align-content: center;
}
.footer-items:nth-child(1) {
display: block;
flex-grow: 0;
flex-shrink: 1;
flex-basis: auto;
align-self: auto;
order: 0;
}
.footer-items:nth-child(2) {
display: block;
flex-grow: 0;
flex-shrink: 1;
flex-basis: auto;
align-self: auto;
order: 0;
}
.material-symbols-outlined {
font-variation-settings:
'FILL' 0,
'wght' 400,
'GRAD' 0,
'opsz' 24
}
th, td {
white-space: nowrap;
}
div.dataTables_wrapper {
width: 1240px;
margin: 0 auto;
}
</style>
</head>
<body>
<nav class="navbar sticky-top navbar-expand-lg navbar-light bg-light">
<div class="container-fluid">
<a href="#" class="navbar-brand">
<img src="images/logo_athena.svg" height="28" alt="CoolBrand">
</a>
<button type="button" class="navbar-toggler" data-bs-toggle="collapse" data-bs-target="#navbarCollapse">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarCollapse">
<div class="navbar-nav">
<a href="#" class="nav-item nav-link active">Home</a>
<a href="#" class="nav-item nav-link">Profile</a>
<a href="#" class="nav-item nav-link">Messages</a>
<a href="#" class="nav-item nav-link disabled" tabindex="-1">Reports</a>
</div>
<div class="navbar-nav ms-auto">
<a href="#" class="nav-item nav-link">Login</a>
</div>
</div>
</div>
</nav>
<div class="m-4" style="font-family: 'Roboto',sans-serif;" id="webCompPortfolio">
</div>
<div class="m-4 border" style="font-family: 'Roboto',sans-serif;" id="webCompMessage">
</div>
<div class="m-4" style="font-family: 'Roboto',sans-serif;" id="webCompNews">
</div>
<div class="m-4" style="font-family: 'Roboto',sans-serif;" id="webCompDividends">
</div>
<div class="m-4" style="font-family: 'Roboto',sans-serif;" id="webCompCompanyKPI">
</div>
<script src="./js/signpostPortfolio.js"></script>
<script src="./js/signpostMessage.js"></script>
<script src="./js/signpostNews.js"></script>
<script src="./js/signpostDividends.js"></script>
<script src="./js/signpostCompanyKPI.js"></script>
<script>
if ('serviceWorker' in navigator) {
window.addEventListener('load', function() {
navigator.serviceWorker.register('/PWA_sw.js').then(function(registration) {
// Registration was successful
console.log('ServiceWorker registration successful with scope: ', registration.scope);
}, function(err) {
// registration failed :(
console.log('ServiceWorker registration failed: ', err);
});
});
}
</script>
<script>
$( document ).ready(function() {
console.log( "ready!" );
renderPortfolio(document.getElementById('webCompPortfolio'),'myPortfolio','idMyPortfolio') ;
renderMessage(document.getElementById('webCompMessage'),"我选择上文所示sell put。如果没有行权的话,收益是7.47/(90-7.47)=9.05%,7.47是我收到的权利金,(90-7.47)是我为行权预留的现金。如果换算成年化收益率的话,大概是9.05%*3=27%,这个收益率我是满足的","CNBC news Report, 2023/09/13") ;
let cSource = "2023/08/27, LA,USA. CNBC report --1" ;
let cTitle = "Brrokfield jumps on $10.20 per share deal to go private" ;
let cContent = "Thorne HealthTech (NASDAQ:THRN), a New York-based developer of health and wellness products, added ~29% pre-market Monday after announcing an agreement to be acquired by investment firm L Catterton for $10.20 per share in cash." ;
renderNews(document.getElementById('webCompNews'),cSource,cTitle,cContent) ;
renderDividends(document.getElementById('webCompDividends'),'Centurion.Dividends','tbl_Dividends') ;
renderCompanyKPI(document.getElementById('webCompCompanyKPI'),null) ;
//renderCompanyKPI(document.getElementById('webCompCompanyKPI1'),null) ;
});
</script>
</body>
</html>