-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathindex.html
More file actions
139 lines (126 loc) · 7.3 KB
/
index.html
File metadata and controls
139 lines (126 loc) · 7.3 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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Email Analyzer</title>
<link rel="preconnect" href="https://fonts.gstatic.com">
<link href="https://fonts.googleapis.com/css2?family=Istok+Web&display=swap" rel="stylesheet">
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/materialize/1.0.0/css/materialize.min.css">
<link rel="stylesheet" href="assets/css/style.css">
</head>
<body>
<header>
<nav class="nav-expand blue-grey darken-2">
<div class="nav-wrapper container">
<h1><a href="#" class="brand-logo left"><span class="orange-text text-accent-4">re:</span>Analysis</a>
</h1>
</div>
</nav>
</header>
<main>
<div class="container">
<div class="row">
<div id="submission" class="col s12 xl8 offset-xl2 blue-grey lighten-5">
<div class="row">
<div class="col s12 l10 offset-l1" id="instructions">
<h5 class="bold">How It Works</h5>
<p class="instruction-line">Writing an email, memo, or other professional
communication, and wondering how your audience will read it? We'll tell you.</p>
<p class="instruction-line"><span class="bold">re:Analysis</span> uses machine learning to
detect the tone of any piece of text, both overall and line by line.</p>
<p class="instruction-line">Place your text below and hit "<span
class="bold">re:Analyze</span>", and we'll walk you through your results for
optimal audience reception. </p>
</div>
</div>
<div class="row">
<form class="col s12" id="user-text">
<div class="input-field">
<textarea id="textarea1" class="materialize-textarea"></textarea>
<label for="textarea1">Your text here</label>
</div>
<button class="btn waves-effect waves-light orange accent-4" id="submit-button"
type="submit">re:Analyze</button>
<button class="btn tooltipped modal-trigger waves-effect waves-light blue darken-1"
id="clear-button" data-position="bottom" data-tooltip="Clear Input Field"
data-target="clear-modal">Clear</button>
<button class="btn tooltipped waves-effect waves-light blue darken-1" id="save-button"
data-position="bottom" data-tooltip="Save To Browser Storage">Save</button>
<button class="btn tooltipped waves-effect waves-light blue darken-1" id="load-button"
data-position="bottom" data-tooltip="Load Saved Text">Load</button>
</form>
</div>
</div>
</div>
<div class="row" id="feedback">
<div class="col">
<div class="row">
<div class="col s12 xl8 offset-xl2">
<div class="score-scale" id="document-score-scale">
<div class="score-bar" id="document-score-bar"></div>
</div>
</div>
</div>
<div class="row">
<div class="col s12 xl6">
<h5>
Key:
</h5>
<p class="key-paragraph">
<span class="bold">Sentiment Score</span> ranges from -1.0 (negative) to 1.0 (positive)
and indicates the overall emotional leaning of the text. Color-coding is based on
sentiment score.<br>
<span id="blue">Blue</span> text indicates a negative score, while <span
id="orange">orange</span> text indicates a positive score. Colors appear darker or
lighter based on the strength of the positive or negative score. For example, a score of
-.8 will be very dark, while a score of -.01 will be very light. White text indicates a
score of 0.
</p>
<p class="key-paragraph">
<span class="bold">Sentiment Magnitude</span> ranges from 0.0 to infinity, and indicates
the strength of the emotion in the text. Because each emotional expression present in
the text contributes to its magnitude, longer texts may have higher overall magnitude.
Hover your cursor over each sentence in your text to view its sentiment magnitude.
</p>
<p class="key-paragraph">
<span class="bold">Entities</span> refer to most nouns present in the text, and appear
underlined in the text. Click on each entitiy to display the sentiment score
and magnitude of how it is described in the text, along with more information
about that entity, if available.
</p>
<p class="key-paragraph">
Edit your text above and re-submit to see changes to score, magnitude, and entities.
</p>
</div>
<div class="col s12 xl6">
<p id="response"></p>
</div>
</div>
</div>
</div>
</div>
</main>
<!-- div for modals -->
<div class="modal-holder"></div>
<!-- clear modal separate so it doesn't get cleared -->
<div id="clear-modal" class="modal">
<div class="modal-content">
<h4>This will clear your text from the input field. Do you want to start over?</h4>
</div>
<div class="modal-footer">
<a href="#!" class="modal-close waves-effect waves-green btn-flat" id="delete">Yes, Clear Input Field</a>
<a href="#!" class="modal-close waves-effect waves-green btn-flat">No, Leave My Text</a>
</div>
</div>
<footer class="page-footer blue-grey darken-2">
<div class="footer-copyright">
<div class="container">© 2020 re:Analysis</div>
</div>
</footer>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/materialize/1.0.0/js/materialize.min.js"></script>
<script src="assets/js/script.js"></script>
</body>
</html>