File tree Expand file tree Collapse file tree 4 files changed +325
-82
lines changed Expand file tree Collapse file tree 4 files changed +325
-82
lines changed Original file line number Diff line number Diff line change @@ -258,7 +258,7 @@ aria.widget.slider.prototype.updateThumbPosition = function () {
258
258
259
259
console . log ( this . valueNow ) ;
260
260
this . thumb . setAttribute ( 'aria-valuenow' , this . valueNow ) ;
261
- this . thumb . setAttribute ( 'aria-valuetext' , `${ this . valueNow } slices` ) ;
261
+ this . thumb . setAttribute ( 'aria-valuetext' , `${ this . valueNow } ${ this . valueNow === 1 ? "slice" : " slices" } ` ) ;
262
262
263
263
var pos = Math . round (
264
264
( this . valueNow * this . sliderWidth ) / ( this . valueMax - this . valueMin )
Original file line number Diff line number Diff line change
1
+ <!DOCTYPE HTML>
2
+ < html >
3
+ < head >
4
+ </ head >
5
+ < body >
6
+
7
+ < button id ="press-to-speak "> Press to speak</ button >
8
+
9
+ < script >
10
+ var a = `
11
+ <speak>
12
+ What does the Spanish word
13
+ <break time="1s"/><prosody rate="slow"><lang xml:lang="es-ES">casa</lang></prosody><break time="1s"/>
14
+ mean in English?
15
+ </speak>
16
+ ` ;
17
+
18
+ var b = `
19
+ <speak>
20
+ <p>
21
+ <s>You have 4 new messages.</s>
22
+ <s>The first is from Stephanie Williams and arrived at <break/> 3:45pm.
23
+ </s>
24
+ <s>
25
+ The subject is <prosody rate="-20%">ski trip</prosody>
26
+ </s>
27
+ </p>
28
+ </speak>
29
+ `
30
+
31
+ var utterThis = new SpeechSynthesisUtterance ( a ) ;
32
+ // utterThis.voice = window.speechSynthesis.getVoices()[0];
33
+ document . getElementById ( "press-to-speak" ) . addEventListener ( "click" , ( ) => {
34
+ window . speechSynthesis . speak ( utterThis ) ;
35
+ } ) ;
36
+
37
+ </ script >
38
+ </ body >
39
+ </ html >
40
+
Original file line number Diff line number Diff line change 1
1
<!DOCTYPE HTML>
2
2
< html >
3
3
< head >
4
+ < meta charset ="UTF-8 ">
4
5
< style >
5
6
body {
6
7
text-align : center;
7
8
font-size : 24px ;
8
9
}
9
-
10
10
# show-score-container {
11
11
margin-top : 30px ;
12
12
}
13
-
14
13
# show-score-container > button {
15
14
font-size : 32px ;
16
15
}
17
-
18
16
.first-answer-wrapper {
19
17
margin-top : 15px ;
20
18
}
29
27
margin-right : auto;
30
28
width : 300px ;
31
29
}
32
-
33
30
div .aria-widget-slider .rail {
34
31
margin : 2px ;
35
32
padding : 1px ;
38
35
position : relative;
39
36
top : 2em ;
40
37
}
41
-
42
38
div .aria-widget-slider .thumb {
43
39
border : 1px solid # 888 ;
44
40
border-top-color : # 666 ;
45
41
border-left-color : # 666 ;
46
42
background-color : # DDD ;
47
43
position : relative;
48
44
}
49
-
50
45
div .aria-widget-slider .value {
51
46
width : 2em ;
52
47
text-align : right;
53
48
position : absolute;
54
49
}
55
-
56
50
div .focus .thumb {
57
51
border : 1px solid # 444 ;
58
52
background-color : # 888 ;
59
53
position : relative;
60
54
}
61
-
55
+ .thumb ::before {
56
+ content : "🍕" ;
57
+ font-size : 44px ;
58
+ margin-left : -30px ;
59
+ margin-top : -16px ;
60
+ position : absolute;
61
+ }
62
62
div .focus .rail {
63
63
background-color : # CCC ;
64
64
}
@@ -71,6 +71,8 @@ <h1>Pop quiz</h1>
71
71
< div >
72
72
< h3 > Question one</ h3 >
73
73
How many slices are in 1/4 of a pizza with 8 total slices?
74
+ < br />
75
+ Grab the pizza slice and drag to select your answer!
74
76
75
77
< div class ="aria-widget-slider ">
76
78
< div class ="value "> 0</ div >
You can’t perform that action at this time.
0 commit comments