htmy 0.1.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of htmy might be problematic. Click here for more details.

htmy/html.py ADDED
@@ -0,0 +1,1247 @@
1
+ from __future__ import annotations
2
+
3
+ from .core import SafeStr, StandaloneTag, Tag, TagConfig, TagWithProps
4
+ from .typing import PropertyValue
5
+
6
+
7
+ class _DefaultTagConfig:
8
+ inline_children: TagConfig = {"child_separator": None}
9
+
10
+
11
+ class DOCTYPE:
12
+ """Document type declaration."""
13
+
14
+ html = SafeStr("<!DOCTYPE html>")
15
+ """HTML document type."""
16
+
17
+
18
+ class html(Tag):
19
+ """
20
+ `<html>` element.
21
+
22
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/html.
23
+ """
24
+
25
+ __slots__ = ()
26
+
27
+
28
+ class head(Tag):
29
+ """
30
+ `<head>` element.
31
+
32
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/head.
33
+ """
34
+
35
+ __slots__ = ()
36
+
37
+
38
+ class body(Tag):
39
+ """
40
+ `<body>` element.
41
+
42
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/body.
43
+ """
44
+
45
+ __slots__ = ()
46
+
47
+
48
+ class base(StandaloneTag):
49
+ """
50
+ `<base>` element.
51
+
52
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/base.
53
+ """
54
+
55
+ __slots__ = ()
56
+
57
+
58
+ class title(Tag):
59
+ """
60
+ `<title>` element.
61
+
62
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/title.
63
+ """
64
+
65
+ __slots__ = ()
66
+
67
+ tag_config = _DefaultTagConfig.inline_children
68
+
69
+ def __init__(self, text: str, **props: PropertyValue) -> None:
70
+ super().__init__(text, **props)
71
+
72
+
73
+ class link(StandaloneTag):
74
+ """
75
+ `<link>` element.
76
+
77
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/link.
78
+ """
79
+
80
+ __slots__ = ()
81
+
82
+ @classmethod
83
+ def css(cls, href: str) -> link:
84
+ return cls(rel="stylesheet", type="text/css", href=href)
85
+
86
+
87
+ class meta(StandaloneTag):
88
+ """
89
+ `<meta>` element.
90
+
91
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/meta.
92
+ """
93
+
94
+ __slots__ = ()
95
+
96
+ @classmethod
97
+ def author(cls, content: str) -> meta:
98
+ return cls(name="author", content=content)
99
+
100
+ @classmethod
101
+ def charset(cls, charset: str = "utf-8") -> meta:
102
+ return cls(charset=charset)
103
+
104
+ @classmethod
105
+ def description(cls, content: str) -> meta:
106
+ return cls(name="description", content=content)
107
+
108
+ @classmethod
109
+ def keywords(cls, content: str) -> meta:
110
+ return cls(name="keywords", content=content)
111
+
112
+ @classmethod
113
+ def viewport(cls, content: str = "width=device-width, initial-scale=1.0") -> meta:
114
+ return cls(name="viewport", content=content)
115
+
116
+
117
+ class script(Tag):
118
+ """
119
+ `<script>` element.
120
+
121
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/script.
122
+ """
123
+
124
+ __slots__ = ()
125
+
126
+ def __init__(self, text: str = "", **props: PropertyValue) -> None:
127
+ """
128
+ Initialization.
129
+
130
+ Arguments:
131
+ text: The inner content of the tag. If not empty, it should be a
132
+ `SafeStr` for HTML and plain `str` for XHTML.
133
+ **props: Tag attributes.
134
+ """
135
+ super().__init__(text, **props)
136
+
137
+
138
+ class style(Tag):
139
+ """
140
+ `<style>` element.
141
+
142
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/style.
143
+ """
144
+
145
+ __slots__ = ()
146
+
147
+ def __init__(self, content: str, **props: PropertyValue) -> None:
148
+ """
149
+ Initialization.
150
+
151
+ Arguments:
152
+ content: The content of the tag. It is automatically converted to a `SafeStr`.
153
+ **props: Tag attributes.
154
+ """
155
+ super().__init__(SafeStr(content), **props)
156
+
157
+
158
+ class dialog(Tag):
159
+ """
160
+ `<dialog>` element.
161
+
162
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/dialog.
163
+ """
164
+
165
+ __slots__ = ()
166
+
167
+
168
+ class address(Tag):
169
+ """
170
+ `<address>` element.
171
+
172
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/address.
173
+ """
174
+
175
+ __slots__ = ()
176
+
177
+
178
+ class article(Tag):
179
+ """
180
+ `<article>` element.
181
+
182
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/article.
183
+ """
184
+
185
+ __slots__ = ()
186
+
187
+
188
+ class aside(Tag):
189
+ """
190
+ `<aside>` element.
191
+
192
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/aside.
193
+ """
194
+
195
+ __slots__ = ()
196
+
197
+
198
+ class blockquote(Tag):
199
+ """
200
+ `<blockquote>` element.
201
+
202
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/blockquote.
203
+ """
204
+
205
+ __slots__ = ()
206
+
207
+
208
+ class div(Tag):
209
+ """
210
+ `<div>` element.
211
+
212
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/div.
213
+ """
214
+
215
+ __slots__ = ()
216
+
217
+
218
+ class embed(StandaloneTag):
219
+ """
220
+ `<embed>` element.
221
+
222
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/embed.
223
+ """
224
+
225
+ __slots__ = ()
226
+
227
+
228
+ class figure(Tag):
229
+ """
230
+ `<figure>` element.
231
+
232
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/figure.
233
+ """
234
+
235
+ __slots__ = ()
236
+
237
+
238
+ class figcaption(Tag):
239
+ """
240
+ `<figcaption>` element.
241
+
242
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/figcaption.
243
+ """
244
+
245
+ __slots__ = ()
246
+
247
+
248
+ class footer(Tag):
249
+ """
250
+ `<footer>` element.
251
+
252
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/footer.
253
+ """
254
+
255
+ __slots__ = ()
256
+
257
+
258
+ class header(Tag):
259
+ """
260
+ `<header>` element.
261
+
262
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/header.
263
+ """
264
+
265
+ __slots__ = ()
266
+
267
+
268
+ class hgroup(Tag):
269
+ """
270
+ `<hgroup>` element.
271
+
272
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/hgroup.
273
+ """
274
+
275
+ __slots__ = ()
276
+
277
+
278
+ class hr(StandaloneTag):
279
+ """
280
+ `<hr>` element.
281
+
282
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/hr.
283
+ """
284
+
285
+ __slots__ = ()
286
+
287
+
288
+ class iframe(TagWithProps):
289
+ """
290
+ `<iframe>` element.
291
+
292
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/iframe.
293
+ """
294
+
295
+ __slots__ = ()
296
+
297
+
298
+ class main(Tag):
299
+ """
300
+ `<main>` element.
301
+
302
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/main.
303
+ """
304
+
305
+ __slots__ = ()
306
+
307
+
308
+ class details(Tag):
309
+ """
310
+ `<details>` element.
311
+
312
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/details.
313
+ """
314
+
315
+ __slots__ = ()
316
+
317
+
318
+ class summary(Tag):
319
+ """
320
+ `<summary>` element.
321
+
322
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/summary.
323
+ """
324
+
325
+ __slots__ = ()
326
+
327
+ tag_config = _DefaultTagConfig.inline_children
328
+
329
+
330
+ class nav(Tag):
331
+ """
332
+ `<nav>` element.
333
+
334
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/nav.
335
+ """
336
+
337
+ __slots__ = ()
338
+
339
+
340
+ class menu(Tag):
341
+ """
342
+ `<menu>` element.
343
+
344
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/menu.
345
+ """
346
+
347
+ __slots__ = ()
348
+
349
+
350
+ class noscript(Tag):
351
+ """
352
+ `<noscript>` element.
353
+
354
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/noscript.
355
+ """
356
+
357
+ __slots__ = ()
358
+
359
+
360
+ class pre(Tag):
361
+ """
362
+ `<pre>` element.
363
+
364
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/pre.
365
+ """
366
+
367
+ __slots__ = ()
368
+
369
+
370
+ class section(Tag):
371
+ """
372
+ `<section>` element.
373
+
374
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/section.
375
+ """
376
+
377
+ __slots__ = ()
378
+
379
+
380
+ class template(Tag):
381
+ """
382
+ `<>` element.
383
+
384
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/template.
385
+ """
386
+
387
+ __slots__ = ()
388
+
389
+
390
+ class form(Tag):
391
+ """
392
+ `<form>` element.
393
+
394
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/form.
395
+ """
396
+
397
+ __slots__ = ()
398
+
399
+
400
+ class search(Tag):
401
+ """
402
+ `<search>` element.
403
+
404
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/search.
405
+ """
406
+
407
+ __slots__ = ()
408
+
409
+
410
+ class button(Tag):
411
+ """
412
+ `<button>` element.
413
+
414
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/button.
415
+ """
416
+
417
+ __slots__ = ()
418
+
419
+
420
+ class option(Tag):
421
+ """
422
+ `<option>` element.
423
+
424
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/option.
425
+ """
426
+
427
+ __slots__ = ()
428
+
429
+
430
+ class optgroup(Tag):
431
+ """
432
+ `<optgroup>` element.
433
+
434
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/optgroup.
435
+ """
436
+
437
+ __slots__ = ()
438
+
439
+
440
+ class datalist(Tag):
441
+ """
442
+ `<datalist>` element.
443
+
444
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/datalist.
445
+ """
446
+
447
+ __slots__ = ()
448
+
449
+
450
+ class fieldset(Tag):
451
+ """
452
+ `<fieldset>` element.
453
+
454
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/fieldset.
455
+ """
456
+
457
+ __slots__ = ()
458
+
459
+
460
+ class input_(StandaloneTag):
461
+ """
462
+ `<input>` element.
463
+
464
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input.
465
+ """
466
+
467
+ __slots__ = ()
468
+
469
+ @property
470
+ def _htmy_name(self) -> str:
471
+ return "input"
472
+
473
+
474
+ class label(Tag):
475
+ """
476
+ `<label>` element.
477
+
478
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/label.
479
+ """
480
+
481
+ __slots__ = ()
482
+
483
+
484
+ class legend(Tag):
485
+ """
486
+ `<legend>` element.
487
+
488
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/legend.
489
+ """
490
+
491
+ __slots__ = ()
492
+
493
+
494
+ class meter(Tag):
495
+ """
496
+ `<meter>` element.
497
+
498
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/meter.
499
+ """
500
+
501
+ __slots__ = ()
502
+
503
+
504
+ class object(Tag):
505
+ """
506
+ `<object>` element.
507
+
508
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/object.
509
+ """
510
+
511
+ __slots__ = ()
512
+
513
+
514
+ class output(Tag):
515
+ """
516
+ `<output>` element.
517
+
518
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/output.
519
+ """
520
+
521
+ __slots__ = ()
522
+
523
+
524
+ class progress(Tag):
525
+ """
526
+ `<progress>` element.
527
+
528
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/progress.
529
+ """
530
+
531
+ __slots__ = ()
532
+
533
+
534
+ class select(Tag):
535
+ """
536
+ `<select>` element.
537
+
538
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/select.
539
+ """
540
+
541
+ __slots__ = ()
542
+
543
+
544
+ class textarea(Tag):
545
+ """
546
+ `<textarea>` element.
547
+
548
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/textarea.
549
+ """
550
+
551
+ __slots__ = ()
552
+
553
+
554
+ class a(Tag):
555
+ """
556
+ `<a>` element.
557
+
558
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a.
559
+ """
560
+
561
+ __slots__ = ()
562
+
563
+ tag_config = _DefaultTagConfig.inline_children
564
+
565
+
566
+ class abbr(Tag):
567
+ """
568
+ `<abbr>` element.
569
+
570
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/abbr.
571
+ """
572
+
573
+ __slots__ = ()
574
+
575
+ tag_config = _DefaultTagConfig.inline_children
576
+
577
+
578
+ class b(Tag):
579
+ """
580
+ `<b>` element.
581
+
582
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/b.
583
+ """
584
+
585
+ __slots__ = ()
586
+
587
+ tag_config = _DefaultTagConfig.inline_children
588
+
589
+
590
+ class bdi(Tag):
591
+ """
592
+ `<bdi>` element.
593
+
594
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/bdi.
595
+ """
596
+
597
+ __slots__ = ()
598
+
599
+ tag_config = _DefaultTagConfig.inline_children
600
+
601
+
602
+ class bdo(Tag):
603
+ """
604
+ `<bdo>` element.
605
+
606
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/bdo.
607
+ """
608
+
609
+ __slots__ = ()
610
+
611
+ tag_config = _DefaultTagConfig.inline_children
612
+
613
+
614
+ class br(StandaloneTag):
615
+ """
616
+ `<br>` element.
617
+
618
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/br.
619
+ """
620
+
621
+ __slots__ = ()
622
+
623
+
624
+ class cite(Tag):
625
+ """
626
+ `<cite>` element.
627
+
628
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/cite.
629
+ """
630
+
631
+ __slots__ = ()
632
+
633
+ tag_config = _DefaultTagConfig.inline_children
634
+
635
+
636
+ class code(Tag):
637
+ """
638
+ `<code>` element.
639
+
640
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/code.
641
+ """
642
+
643
+ __slots__ = ()
644
+
645
+ tag_config = _DefaultTagConfig.inline_children
646
+
647
+
648
+ class data(Tag):
649
+ """
650
+ `<data>` element.
651
+
652
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/data.
653
+ """
654
+
655
+ __slots__ = ()
656
+
657
+ tag_config = _DefaultTagConfig.inline_children
658
+
659
+
660
+ class del_(Tag):
661
+ """
662
+ `<del>` element.
663
+
664
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/del.
665
+ """
666
+
667
+ __slots__ = ()
668
+
669
+ tag_config = _DefaultTagConfig.inline_children
670
+
671
+ @property
672
+ def _htmy_name(self) -> str:
673
+ return "del"
674
+
675
+
676
+ class dfn(Tag):
677
+ """
678
+ `<dfn>` element.
679
+
680
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/dfn.
681
+ """
682
+
683
+ __slots__ = ()
684
+
685
+ tag_config = _DefaultTagConfig.inline_children
686
+
687
+
688
+ class em(Tag):
689
+ """
690
+ `<em>` element.
691
+
692
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/em.
693
+ """
694
+
695
+ __slots__ = ()
696
+
697
+ tag_config = _DefaultTagConfig.inline_children
698
+
699
+
700
+ class i(Tag):
701
+ """
702
+ `<i>` element.
703
+
704
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/i.
705
+ """
706
+
707
+ __slots__ = ()
708
+
709
+ tag_config = _DefaultTagConfig.inline_children
710
+
711
+
712
+ class picture(Tag):
713
+ """
714
+ `<picture>` element.
715
+
716
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/picture.
717
+ """
718
+
719
+ __slots__ = ()
720
+
721
+
722
+ class img(StandaloneTag):
723
+ """
724
+ `<img>` element.
725
+
726
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/img.
727
+ """
728
+
729
+ __slots__ = ()
730
+
731
+
732
+ class source(StandaloneTag):
733
+ """
734
+ `<source>` element.
735
+
736
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/source.
737
+ """
738
+
739
+ __slots__ = ()
740
+
741
+
742
+ class ins(Tag):
743
+ """
744
+ `<ins>` element.
745
+
746
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/ins.
747
+ """
748
+
749
+ __slots__ = ()
750
+
751
+ tag_config = _DefaultTagConfig.inline_children
752
+
753
+
754
+ class mark(Tag):
755
+ """
756
+ `<mark>` element.
757
+
758
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/mark.
759
+ """
760
+
761
+ __slots__ = ()
762
+
763
+ tag_config = _DefaultTagConfig.inline_children
764
+
765
+
766
+ class q(Tag):
767
+ """
768
+ `<q>` element.
769
+
770
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/q.
771
+ """
772
+
773
+ __slots__ = ()
774
+
775
+ tag_config = _DefaultTagConfig.inline_children
776
+
777
+
778
+ class s(Tag):
779
+ """
780
+ `<s>` element.
781
+
782
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/s.
783
+ """
784
+
785
+ __slots__ = ()
786
+
787
+ tag_config = _DefaultTagConfig.inline_children
788
+
789
+
790
+ class samp(Tag):
791
+ """
792
+ `<samp>` element.
793
+
794
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/samp.
795
+ """
796
+
797
+ __slots__ = ()
798
+
799
+ tag_config = _DefaultTagConfig.inline_children
800
+
801
+
802
+ class small(Tag):
803
+ """
804
+ `<small>` element.
805
+
806
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/small.
807
+ """
808
+
809
+ __slots__ = ()
810
+
811
+ tag_config = _DefaultTagConfig.inline_children
812
+
813
+
814
+ class span(Tag):
815
+ """
816
+ `<span>` element.
817
+
818
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/span.
819
+ """
820
+
821
+ __slots__ = ()
822
+
823
+ tag_config = _DefaultTagConfig.inline_children
824
+
825
+
826
+ class strong(Tag):
827
+ """
828
+ `<strong>` element.
829
+
830
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/strong.
831
+ """
832
+
833
+ __slots__ = ()
834
+
835
+ tag_config = _DefaultTagConfig.inline_children
836
+
837
+
838
+ class sub(Tag):
839
+ """
840
+ `<sub>` element.
841
+
842
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/sub.
843
+ """
844
+
845
+ __slots__ = ()
846
+
847
+ tag_config = _DefaultTagConfig.inline_children
848
+
849
+
850
+ class sup(Tag):
851
+ """
852
+ `<sup>` element.
853
+
854
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/sup.
855
+ """
856
+
857
+ __slots__ = ()
858
+
859
+ tag_config = _DefaultTagConfig.inline_children
860
+
861
+
862
+ class u(Tag):
863
+ """
864
+ `<u>` element.
865
+
866
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/u.
867
+ """
868
+
869
+ __slots__ = ()
870
+
871
+ tag_config = _DefaultTagConfig.inline_children
872
+
873
+
874
+ class var(Tag):
875
+ """
876
+ `<var>` element.
877
+
878
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/var.
879
+ """
880
+
881
+ __slots__ = ()
882
+
883
+ tag_config = _DefaultTagConfig.inline_children
884
+
885
+
886
+ class wbr(Tag):
887
+ """
888
+ `<>` element.
889
+
890
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/.
891
+ """
892
+
893
+ __slots__ = ()
894
+
895
+ tag_config = _DefaultTagConfig.inline_children
896
+
897
+
898
+ class li(Tag):
899
+ """
900
+ `<li>` element.
901
+
902
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/li.
903
+ """
904
+
905
+ __slots__ = ()
906
+
907
+ tag_config = _DefaultTagConfig.inline_children
908
+
909
+
910
+ class ol(Tag):
911
+ """
912
+ `<ol>` element.
913
+
914
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/ol.
915
+ """
916
+
917
+ __slots__ = ()
918
+
919
+
920
+ class ul(Tag):
921
+ """
922
+ `<ul>` element.
923
+
924
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/ul.
925
+ """
926
+
927
+ __slots__ = ()
928
+
929
+
930
+ class dl(Tag):
931
+ """
932
+ `<dl>` element.
933
+
934
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/dl.
935
+ """
936
+
937
+ __slots__ = ()
938
+
939
+
940
+ class dt(Tag):
941
+ """
942
+ `<dt>` element.
943
+
944
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/dt.
945
+ """
946
+
947
+ __slots__ = ()
948
+
949
+ tag_config = _DefaultTagConfig.inline_children
950
+
951
+
952
+ class dd(Tag):
953
+ """
954
+ `<dd>` element.
955
+
956
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/dd.
957
+ """
958
+
959
+ __slots__ = ()
960
+
961
+
962
+ class caption(Tag):
963
+ """
964
+ `<caption>` element.
965
+
966
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/caption.
967
+ """
968
+
969
+ __slots__ = ()
970
+
971
+
972
+ class table(Tag):
973
+ """
974
+ `<table>` element.
975
+
976
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/table.
977
+ """
978
+
979
+ __slots__ = ()
980
+
981
+
982
+ class thead(Tag):
983
+ """
984
+ `<thead>` element.
985
+
986
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/thead.
987
+ """
988
+
989
+ __slots__ = ()
990
+
991
+
992
+ class tbody(Tag):
993
+ """
994
+ `<tbody>` element.
995
+
996
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/tbody.
997
+ """
998
+
999
+ __slots__ = ()
1000
+
1001
+
1002
+ class tfoot(Tag):
1003
+ """
1004
+ `<tfoot>` element.
1005
+
1006
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/tfoot.
1007
+ """
1008
+
1009
+ __slots__ = ()
1010
+
1011
+
1012
+ class tr(Tag):
1013
+ """
1014
+ `<tr>` element.
1015
+
1016
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/tr.
1017
+ """
1018
+
1019
+ __slots__ = ()
1020
+
1021
+
1022
+ class th(Tag):
1023
+ """
1024
+ `<th>` element.
1025
+
1026
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/th.
1027
+ """
1028
+
1029
+ __slots__ = ()
1030
+
1031
+ tag_config = _DefaultTagConfig.inline_children
1032
+
1033
+
1034
+ class td(Tag):
1035
+ """
1036
+ `<td>` element.
1037
+
1038
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/td.
1039
+ """
1040
+
1041
+ __slots__ = ()
1042
+
1043
+ tag_config = _DefaultTagConfig.inline_children
1044
+
1045
+
1046
+ class colgroup(StandaloneTag):
1047
+ """
1048
+ `<colgroup>` element.
1049
+
1050
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/colgroup.
1051
+ """
1052
+
1053
+ __slots__ = ()
1054
+
1055
+
1056
+ class col(StandaloneTag):
1057
+ """
1058
+ `<col>` element.
1059
+
1060
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/col.
1061
+ """
1062
+
1063
+ __slots__ = ()
1064
+
1065
+
1066
+ class h1(Tag):
1067
+ """
1068
+ `<h1>` element.
1069
+
1070
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/h1.
1071
+ """
1072
+
1073
+ __slots__ = ()
1074
+
1075
+ tag_config = _DefaultTagConfig.inline_children
1076
+
1077
+
1078
+ class h2(Tag):
1079
+ """
1080
+ `<h2>` element.
1081
+
1082
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/h2.
1083
+ """
1084
+
1085
+ __slots__ = ()
1086
+
1087
+ tag_config = _DefaultTagConfig.inline_children
1088
+
1089
+
1090
+ class h3(Tag):
1091
+ """
1092
+ `<h3>` element.
1093
+
1094
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/h3.
1095
+ """
1096
+
1097
+ __slots__ = ()
1098
+
1099
+ tag_config = _DefaultTagConfig.inline_children
1100
+
1101
+
1102
+ class h4(Tag):
1103
+ """
1104
+ `<h4>` element.
1105
+
1106
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/h4.
1107
+ """
1108
+
1109
+ __slots__ = ()
1110
+
1111
+ tag_config = _DefaultTagConfig.inline_children
1112
+
1113
+
1114
+ class h5(Tag):
1115
+ """
1116
+ `<h5>` element.
1117
+
1118
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/h5.
1119
+ """
1120
+
1121
+ __slots__ = ()
1122
+
1123
+ tag_config = _DefaultTagConfig.inline_children
1124
+
1125
+
1126
+ class h6(Tag):
1127
+ """
1128
+ `<h6>` element.
1129
+
1130
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/h6.
1131
+ """
1132
+
1133
+ __slots__ = ()
1134
+
1135
+ tag_config = _DefaultTagConfig.inline_children
1136
+
1137
+
1138
+ class p(Tag):
1139
+ """
1140
+ `<p>` element.
1141
+
1142
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/p.
1143
+ """
1144
+
1145
+ __slots__ = ()
1146
+
1147
+ tag_config = _DefaultTagConfig.inline_children
1148
+
1149
+
1150
+ class time(Tag):
1151
+ """
1152
+ `<time>` element.
1153
+
1154
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/time.
1155
+ """
1156
+
1157
+ __slots__ = ()
1158
+
1159
+ tag_config = _DefaultTagConfig.inline_children
1160
+
1161
+
1162
+ class audio(Tag):
1163
+ """
1164
+ `<audio>` element.
1165
+
1166
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/audio.
1167
+ """
1168
+
1169
+ __slots__ = ()
1170
+
1171
+
1172
+ class video(Tag):
1173
+ """
1174
+ `<video>` element.
1175
+
1176
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/video.
1177
+ """
1178
+
1179
+ __slots__ = ()
1180
+
1181
+
1182
+ class track(StandaloneTag):
1183
+ """
1184
+ `<track>` element.
1185
+
1186
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/track.
1187
+ """
1188
+
1189
+ __slots__ = ()
1190
+
1191
+
1192
+ class canvas(Tag):
1193
+ """
1194
+ `<canvas>` element.
1195
+
1196
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/canvas.
1197
+ """
1198
+
1199
+ __slots__ = ()
1200
+
1201
+
1202
+ class area(StandaloneTag):
1203
+ """
1204
+ `<area>` element.
1205
+
1206
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/area.
1207
+ """
1208
+
1209
+ __slots__ = ()
1210
+
1211
+
1212
+ class map(Tag):
1213
+ """
1214
+ `<map>` element.
1215
+
1216
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/map.
1217
+ """
1218
+
1219
+ __slots__ = ()
1220
+
1221
+
1222
+ class slot(Tag):
1223
+ """
1224
+ `<slot>` element.
1225
+
1226
+ See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/slot.
1227
+ """
1228
+
1229
+ __slots__ = ()
1230
+
1231
+
1232
+ class entity:
1233
+ amp = SafeStr("&amp;")
1234
+ apos = SafeStr("&apos;")
1235
+ cent = SafeStr("&cent;")
1236
+ copy = SafeStr("&copy;")
1237
+ euro = SafeStr("&euro;")
1238
+ gt = SafeStr("&gt;")
1239
+ lt = SafeStr("&lt;")
1240
+ mdash = SafeStr("&mdash;")
1241
+ nbsp = SafeStr("&nbsp;")
1242
+ ndash = SafeStr("&ndash;")
1243
+ pound = SafeStr("&pound;")
1244
+ quot = SafeStr("&quot;")
1245
+ reg = SafeStr("&reg;")
1246
+ times = SafeStr("&times;")
1247
+ yen = SafeStr("&yen;")