-
Notifications
You must be signed in to change notification settings - Fork 0
/
arabic-subtending-marks-css-counter.html
executable file
·226 lines (196 loc) · 6.11 KB
/
arabic-subtending-marks-css-counter.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
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Testing an Arabic subtending mark (U+0602) in Noto Nastaliq Urdu</title>
<meta name="viewport" content="width=device-width,initial-scale=1.0">
<style>
@font-face {
font-family: "NotoNastaliqUrduWeb";
src: url("fonts/NotoNastaliqUrdu-Regular.woff2") format("woff2"),
url("fonts/NotoNastaliqUrdu-Regular.woff") format("woff"),
url("fonts/NotoNastaliqUrdu-Regular.ttf") format("truetype");
}
.noto-nastaliq {
font-family: "NotoNastaliqUrduWeb", serif;
}
html {
font-size: 80%;
}
@media(min-width: 768px) {
html {
font-size: 90%;
}
}
@media(min-width: 900px) {
html {
font-size: 100%;
}
}
:root {
--system-ui: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", "Noto Sans", "Liberation Sans", Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
}
body {
font-family: var(--system-ui);
line-height: 1.5;
width: 90%;
max-width: 960px;
margin: 2em auto;
}
h1 {
font-size: 1.125rem;
margin: 0 0 1.3334em 0;
}
h3 {
font-size: 1rem;
margin: 0;
}
p {
margin: 0 0 1.5em;
}
.update {
margin: 0 0 1.714286em 0;
padding: 1em;
background-color: #FFFFCC;
border-top: 1px solid #FFEF00;
border-bottom: 1px solid #FFEF00;
}
.note {
font-size: 0.90625rem;
margin: 0 0 1.714286em 0;
padding: 1em;
border-top: 1px solid #ccc;
border-bottom: 1px solid #ccc;
background-color: #f8f8f8;
}
.note ul {
list-style: none;
margin: 0;
padding: 0;
}
.note li {
padding: 0.75em 0;
border-bottom: 1px solid #ccc;
}
.note li:last-child {
border-bottom: 0;
}
.note p {
margin-top: 0.125em;
margin-bottom: 0;
font-size: 0.9em;
}
table {
width: 100%;
border-collapse: collapse;
table-layout: fixed;
}
tr {
border-bottom: 1px solid #ccc;
}
thead tr {
border-bottom: 2px solid #ccc;
}
th {
padding: 10px 15px;
}
td {
font-size: 1.25rem;
line-height: 3;
padding: 10px 15px;
vertical-align: top;
}
.regular,
.counter {
list-style: none;
text-align: center;
margin: 0;
padding: 0;
}
.regular li {
unicode-bidi: bidi-override;
}
.counter {
counter-reset: c;
}
.counter li::before {
content: ""counter(c, persian);
counter-increment: c;
unicode-bidi: bidi-override;
}
</style>
</head>
<body>
<h1>Testing an Arabic subtending mark (U+0602) in Noto Nastaliq Urdu</h1>
<div class="update">
This page illustrates a test case for a <a href="https://bugzilla.mozilla.org/show_bug.cgi?id=1599841">bug in Firefox v70</a>. The bug was fixed in v72.
</div>
<div class="note">
<h3>Note:</h3>
<ul>
<li>The test below uses U+0602 ARABIC FOOTNOTE MARKER, but the issue can be reproduced with any of the subtending marks (U+0600..U+0604).</li>
<li>Ignore the incorrect rendering for the digits sequence containing <mark class="noto-nastaliq" lang="ur">۶</mark>; it is a <a href="https://github.com/googlefonts/noto-fonts/issues/1620">bug</a> in the font itself.</li>
</ul>
</div>
<table>
<thead>
<tr>
<th style="width: 50%">In plain HTML</th>
<th style="width: 50%">In CSS counter</th>
</tr>
</thead>
<tbody>
<tr>
<td>
<ul class="regular noto-nastaliq" lang="ur" dir="rtl">
<li>۱</li>
<li>۲</li>
<li>۳</li>
<li>۴</li>
<li>۵</li>
<li>۶</li>
<li>۷</li>
<li>۸</li>
<li>۹</li>
<li>۱۰</li>
<li>۱۱</li>
<li>۱۲</li>
<li>۱۳</li>
<li>۱۴</li>
<li>۱۵</li>
<li>۱۶</li>
<li>۱۷</li>
<li>۱۸</li>
<li>۱۹</li>
<li>۲۰</li>
</ul>
</td>
<td>
<ul class="counter noto-nastaliq" lang="ur" dir="rtl">
<li></li>
<li></li>
<li></li>
<li></li>
<li></li>
<li></li>
<li></li>
<li></li>
<li></li>
<li></li>
<li></li>
<li></li>
<li></li>
<li></li>
<li></li>
<li></li>
<li></li>
<li></li>
<li></li>
<li></li>
</ul>
</td>
</tr>
</tbody>
</table>
</body>
</html>