forked from GoogleChrome/chrome-extensions-samples
-
Notifications
You must be signed in to change notification settings - Fork 0
/
options.html
152 lines (141 loc) · 3.24 KB
/
options.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
<html>
<head>
<title>Speak Selection Options</title>
<style>
body {
font-family: arial, helvetica, sans-serif;
}
.banner {
width: 100%;
float: left;
}
.banner_left {
padding: 8px;
float: left;
}
.banner_right {
padding: 8px;
}
.body_wrapper {
width: 100%;
float: left;
}
.body_left {
border: 0;
padding: 0;
margin: 0;
width: 50%;
float: left;
}
.body_right {
border: 0;
padding: 0;
margin: 0;
width: 46%;
float: left;
}
.body_inner {
padding: 0 32px;
}
.browser_action {
vertical-align: middle;
margin: 0 2px 3px 2px;
}
.ctrl_label {
width: 100px;
float: left;
}
.ctrl_wrap {
margin: 18px 8px;
}
.ctrl {
width: 200px;
}
#hotkey {
font-size: 16px;
width: 15em;
margin-left: 12px;
}
#test {
}
#defaults {
margin-left: 24px;
}
</style>
<script src="keycodes.js"></script>
<script src="tabs.js"></script>
<script src="options.js"></script>
<script src="content_script.js"></script>
</head>
<body>
<div class="banner">
<div class="banner_left">
<img src="SpeakSel128.png" class="logo" alt="">
</div>
<div class="banner_right">
<h1>Speak Selection</h1>
<p>
This extension lets you use Chrome's text-to-speech (TTS) capabilities
to speak any text you find on the web.
</p>
</div>
</div>
<div class="body_wrapper">
<div class="body_left">
<div class="body_inner">
<h2>Speech Settings</h2>
<div class="ctrl_label">
<label for="voice">Voice:</label>
</div>
<div class="ctrl_wrap">
<select id="voice" class="ctrl"></select>
</div>
<div class="ctrl_label">
<label for="rate">Rate:</label>
</div>
<div class="ctrl_wrap">
<input id="rate" type="range" class="ctrl"
min=0.5 max=2.0 step=0.1 value=1.0></input>
</div>
<div class="ctrl_label">
<label for="pitch">Pitch:</label>
</div>
<div class="ctrl_wrap">
<input id="pitch" type="range" class="ctrl"
min=0.5 max=1.5 step=0.1 value=1.0></input>
</div>
<div class="ctrl_label">
<label for="volume">Volume:</label>
</div>
<div class="ctrl_wrap">
<input id="volume" type="range" class="ctrl"
min=0.0 max=1.0 step=0.1 value=1.0></input>
</div>
<div class="ctrl_label">
</div>
<div class="ctrl_wrap">
<button id="test">Test Speech</button>
<button id="defaults">Defaults</button>
</div>
</div>
</div>
<div class="body_right">
<div class="body_inner">
<h2>When to speak</h2>
<p>
<span id="selected">Select some text</span>
anywhere on a webpage, then either:
</p>
<p>1. Click on the
<img class="browser_action" src="SpeakSel19.png" alt="Speak Selection">
button in the toolbar ↗, or
</p>
<p>2. Use this hot key: <input type="text" id="hotkey"></input>
</p>
<p>Click the button or press the key again to stop speech.</p>
</div>
</div>
</div>
</body>
</html>