hyperlang 0.1.0

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.
Files changed (117) hide show
  1. checksums.yaml +7 -0
  2. data/.github/workflows/rake.yml +19 -0
  3. data/.github/workflows/release.yml +28 -0
  4. data/.gitignore +8 -0
  5. data/.rspec +3 -0
  6. data/.rubocop.yml +19 -0
  7. data/.rubocop_todo.yml +45 -0
  8. data/Gemfile +15 -0
  9. data/README.adoc +176 -0
  10. data/Rakefile +12 -0
  11. data/hyperlang.gemspec +36 -0
  12. data/lib/hyperlang/version.rb +5 -0
  13. data/lib/hyperlang/xhtml/a.rb +44 -0
  14. data/lib/hyperlang/xhtml/abbr.rb +22 -0
  15. data/lib/hyperlang/xhtml/acronym.rb +22 -0
  16. data/lib/hyperlang/xhtml/address.rb +26 -0
  17. data/lib/hyperlang/xhtml/applet.rb +42 -0
  18. data/lib/hyperlang/xhtml/area.rb +29 -0
  19. data/lib/hyperlang/xhtml/b.rb +22 -0
  20. data/lib/hyperlang/xhtml/base.rb +17 -0
  21. data/lib/hyperlang/xhtml/basefont.rb +21 -0
  22. data/lib/hyperlang/xhtml/bdo.rb +22 -0
  23. data/lib/hyperlang/xhtml/big.rb +22 -0
  24. data/lib/hyperlang/xhtml/blockquote.rb +44 -0
  25. data/lib/hyperlang/xhtml/body.rb +54 -0
  26. data/lib/hyperlang/xhtml/br.rb +12 -0
  27. data/lib/hyperlang/xhtml/button.rb +42 -0
  28. data/lib/hyperlang/xhtml/caption.rb +20 -0
  29. data/lib/hyperlang/xhtml/center.rb +48 -0
  30. data/lib/hyperlang/xhtml/cite.rb +20 -0
  31. data/lib/hyperlang/xhtml/code.rb +22 -0
  32. data/lib/hyperlang/xhtml/col.rb +29 -0
  33. data/lib/hyperlang/xhtml/colgroup.rb +31 -0
  34. data/lib/hyperlang/xhtml/dd.rb +40 -0
  35. data/lib/hyperlang/xhtml/del.rb +38 -0
  36. data/lib/hyperlang/xhtml/dfn.rb +20 -0
  37. data/lib/hyperlang/xhtml/dir.rb +21 -0
  38. data/lib/hyperlang/xhtml/div.rb +64 -0
  39. data/lib/hyperlang/xhtml/dl.rb +21 -0
  40. data/lib/hyperlang/xhtml/dt.rb +30 -0
  41. data/lib/hyperlang/xhtml/em.rb +22 -0
  42. data/lib/hyperlang/xhtml/fieldset.rb +34 -0
  43. data/lib/hyperlang/xhtml/font.rb +26 -0
  44. data/lib/hyperlang/xhtml/form.rb +40 -0
  45. data/lib/hyperlang/xhtml/frame.rb +31 -0
  46. data/lib/hyperlang/xhtml/frameset.rb +25 -0
  47. data/lib/hyperlang/xhtml/h1.rb +34 -0
  48. data/lib/hyperlang/xhtml/h2.rb +34 -0
  49. data/lib/hyperlang/xhtml/h3.rb +34 -0
  50. data/lib/hyperlang/xhtml/h4.rb +34 -0
  51. data/lib/hyperlang/xhtml/h5.rb +34 -0
  52. data/lib/hyperlang/xhtml/h6.rb +34 -0
  53. data/lib/hyperlang/xhtml/head.rb +27 -0
  54. data/lib/hyperlang/xhtml/hr.rb +17 -0
  55. data/lib/hyperlang/xhtml/html.rb +17 -0
  56. data/lib/hyperlang/xhtml/i.rb +22 -0
  57. data/lib/hyperlang/xhtml/iframe.rb +40 -0
  58. data/lib/hyperlang/xhtml/img.rb +35 -0
  59. data/lib/hyperlang/xhtml/input.rb +55 -0
  60. data/lib/hyperlang/xhtml/ins.rb +38 -0
  61. data/lib/hyperlang/xhtml/isindex.rb +19 -0
  62. data/lib/hyperlang/xhtml/kbd.rb +20 -0
  63. data/lib/hyperlang/xhtml/label.rb +24 -0
  64. data/lib/hyperlang/xhtml/legend.rb +22 -0
  65. data/lib/hyperlang/xhtml/li.rb +42 -0
  66. data/lib/hyperlang/xhtml/link.rb +31 -0
  67. data/lib/hyperlang/xhtml/map.rb +35 -0
  68. data/lib/hyperlang/xhtml/menu.rb +21 -0
  69. data/lib/hyperlang/xhtml/meta.rb +23 -0
  70. data/lib/hyperlang/xhtml/namespace.rb +10 -0
  71. data/lib/hyperlang/xhtml/noframes.rb +46 -0
  72. data/lib/hyperlang/xhtml/noscript.rb +42 -0
  73. data/lib/hyperlang/xhtml/object.rb +48 -0
  74. data/lib/hyperlang/xhtml/ol.rb +25 -0
  75. data/lib/hyperlang/xhtml/optgroup.rb +23 -0
  76. data/lib/hyperlang/xhtml/option.rb +25 -0
  77. data/lib/hyperlang/xhtml/p.rb +36 -0
  78. data/lib/hyperlang/xhtml/param.rb +23 -0
  79. data/lib/hyperlang/xhtml/pre.rb +32 -0
  80. data/lib/hyperlang/xhtml/q.rb +22 -0
  81. data/lib/hyperlang/xhtml/rb.rb +20 -0
  82. data/lib/hyperlang/xhtml/rbc.rb +19 -0
  83. data/lib/hyperlang/xhtml/rp.rb +19 -0
  84. data/lib/hyperlang/xhtml/rt.rb +22 -0
  85. data/lib/hyperlang/xhtml/rtc.rb +23 -0
  86. data/lib/hyperlang/xhtml/ruby.rb +27 -0
  87. data/lib/hyperlang/xhtml/s.rb +20 -0
  88. data/lib/hyperlang/xhtml/samp.rb +20 -0
  89. data/lib/hyperlang/xhtml/script.rb +25 -0
  90. data/lib/hyperlang/xhtml/select.rb +37 -0
  91. data/lib/hyperlang/xhtml/small.rb +22 -0
  92. data/lib/hyperlang/xhtml/span.rb +24 -0
  93. data/lib/hyperlang/xhtml/strike.rb +20 -0
  94. data/lib/hyperlang/xhtml/strong.rb +22 -0
  95. data/lib/hyperlang/xhtml/style.rb +23 -0
  96. data/lib/hyperlang/xhtml/sub.rb +20 -0
  97. data/lib/hyperlang/xhtml/sup.rb +20 -0
  98. data/lib/hyperlang/xhtml/table.rb +43 -0
  99. data/lib/hyperlang/xhtml/tbody.rb +27 -0
  100. data/lib/hyperlang/xhtml/td.rb +42 -0
  101. data/lib/hyperlang/xhtml/textarea.rb +41 -0
  102. data/lib/hyperlang/xhtml/tfoot.rb +27 -0
  103. data/lib/hyperlang/xhtml/th.rb +42 -0
  104. data/lib/hyperlang/xhtml/thead.rb +27 -0
  105. data/lib/hyperlang/xhtml/title.rb +15 -0
  106. data/lib/hyperlang/xhtml/tr.rb +29 -0
  107. data/lib/hyperlang/xhtml/tt.rb +20 -0
  108. data/lib/hyperlang/xhtml/u.rb +20 -0
  109. data/lib/hyperlang/xhtml/ul.rb +23 -0
  110. data/lib/hyperlang/xhtml/var.rb +20 -0
  111. data/lib/hyperlang/xhtml/xhtml.rb +147 -0
  112. data/lib/hyperlang.rb +16 -0
  113. data/spec/hyperlang/round_trip_spec.rb +86 -0
  114. data/spec/hyperlang/xhtml/block_spec.rb +56 -0
  115. data/spec/hyperlang/xhtml/inline_spec.rb +60 -0
  116. data/spec/spec_helper.rb +17 -0
  117. metadata +173 -0
@@ -0,0 +1,42 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Hyperlang
4
+ module Xhtml
5
+ class Li < Lutaml::Model::Serializable
6
+ attribute :content, :string
7
+ attribute :p, Hyperlang::Xhtml::P, collection: true
8
+ attribute :span, Hyperlang::Xhtml::Span, collection: true
9
+ # div omitted: creates circular dependency div↔li
10
+ # ul/ol omitted: creates circular dependency li↔ul, li↔ol
11
+ attribute :a, Hyperlang::Xhtml::A, collection: true
12
+ attribute :strong, Hyperlang::Xhtml::Strong, collection: true
13
+ attribute :em, Hyperlang::Xhtml::Em, collection: true
14
+ attribute :br, Hyperlang::Xhtml::Br, collection: true
15
+ attribute :img, Hyperlang::Xhtml::Img, collection: true
16
+ attribute :type, :string
17
+ attribute :value, :integer
18
+ attribute :id, :string
19
+ attribute :klass, :string
20
+
21
+ xml do
22
+ element "li"
23
+ namespace Hyperlang::Xhtml::Namespace
24
+ mixed_content
25
+ map_content to: :content
26
+ map_element "p", to: :p
27
+ map_element "span", to: :span
28
+ # div omitted: creates circular div↔li
29
+ # ul/ol omitted: creates circular li↔ul, li↔ol
30
+ map_element "a", to: :a
31
+ map_element "strong", to: :strong
32
+ map_element "em", to: :em
33
+ map_element "br", to: :br
34
+ map_element "img", to: :img
35
+ map_attribute "type", to: :type
36
+ map_attribute "value", to: :value
37
+ map_attribute "id", to: :id
38
+ map_attribute "class", to: :klass
39
+ end
40
+ end
41
+ end
42
+ end
@@ -0,0 +1,31 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Hyperlang
4
+ module Xhtml
5
+ class Link < Lutaml::Model::Serializable
6
+ attribute :charset, :string
7
+ attribute :href, :string
8
+ attribute :hreflang, :string
9
+ attribute :type, :string
10
+ attribute :rel, :string
11
+ attribute :rev, :string
12
+ attribute :media, :string
13
+ attribute :id, :string
14
+ attribute :klass, :string
15
+
16
+ xml do
17
+ element "link"
18
+ namespace Hyperlang::Xhtml::Namespace
19
+ map_attribute "charset", to: :charset
20
+ map_attribute "href", to: :href
21
+ map_attribute "hreflang", to: :hreflang
22
+ map_attribute "type", to: :type
23
+ map_attribute "rel", to: :rel
24
+ map_attribute "rev", to: :rev
25
+ map_attribute "media", to: :media
26
+ map_attribute "id", to: :id
27
+ map_attribute "class", to: :klass
28
+ end
29
+ end
30
+ end
31
+ end
@@ -0,0 +1,35 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Hyperlang
4
+ module Xhtml
5
+ class Map < Lutaml::Model::Serializable
6
+ attribute :area, Hyperlang::Xhtml::Area, collection: true
7
+ attribute :p, Hyperlang::Xhtml::P, collection: true
8
+ attribute :div, Hyperlang::Xhtml::Div, collection: true
9
+ attribute :h1, Hyperlang::Xhtml::H1, collection: true
10
+ attribute :h2, Hyperlang::Xhtml::H2, collection: true
11
+ attribute :h3, Hyperlang::Xhtml::H3, collection: true
12
+ attribute :h4, Hyperlang::Xhtml::H4, collection: true
13
+ attribute :h5, Hyperlang::Xhtml::H5, collection: true
14
+ attribute :h6, Hyperlang::Xhtml::H6, collection: true
15
+ attribute :name, :string
16
+ attribute :id, :string
17
+
18
+ xml do
19
+ element "map"
20
+ namespace Hyperlang::Xhtml::Namespace
21
+ map_element "area", to: :area
22
+ map_element "p", to: :p
23
+ map_element "div", to: :div
24
+ map_element "h1", to: :h1
25
+ map_element "h2", to: :h2
26
+ map_element "h3", to: :h3
27
+ map_element "h4", to: :h4
28
+ map_element "h5", to: :h5
29
+ map_element "h6", to: :h6
30
+ map_attribute "name", to: :name
31
+ map_attribute "id", to: :id
32
+ end
33
+ end
34
+ end
35
+ end
@@ -0,0 +1,21 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Hyperlang
4
+ module Xhtml
5
+ class Menu < Lutaml::Model::Serializable
6
+ attribute :li, Hyperlang::Xhtml::Li, collection: true
7
+ attribute :compact, :string
8
+ attribute :id, :string
9
+ attribute :klass, :string
10
+
11
+ xml do
12
+ element "menu"
13
+ namespace Hyperlang::Xhtml::Namespace
14
+ map_element "li", to: :li
15
+ map_attribute "compact", to: :compact
16
+ map_attribute "id", to: :id
17
+ map_attribute "class", to: :klass
18
+ end
19
+ end
20
+ end
21
+ end
@@ -0,0 +1,23 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Hyperlang
4
+ module Xhtml
5
+ class Meta < Lutaml::Model::Serializable
6
+ attribute :http_equiv, :string
7
+ attribute :name, :string
8
+ attribute :content, :string
9
+ attribute :scheme, :string
10
+ attribute :id, :string
11
+
12
+ xml do
13
+ element "meta"
14
+ namespace Hyperlang::Xhtml::Namespace
15
+ map_attribute "http-equiv", to: :http_equiv
16
+ map_attribute "name", to: :name
17
+ map_attribute "content", to: :content
18
+ map_attribute "scheme", to: :scheme
19
+ map_attribute "id", to: :id
20
+ end
21
+ end
22
+ end
23
+ end
@@ -0,0 +1,10 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Hyperlang
4
+ module Xhtml
5
+ class Namespace < Lutaml::Xml::Namespace
6
+ uri "http://www.w3.org/1999/xhtml"
7
+ prefix_default "xhtml"
8
+ end
9
+ end
10
+ end
@@ -0,0 +1,46 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Hyperlang
4
+ module Xhtml
5
+ class Noframes < Lutaml::Model::Serializable
6
+ attribute :content, :string
7
+ attribute :body, Hyperlang::Xhtml::Body
8
+ attribute :div, Hyperlang::Xhtml::Div, collection: true
9
+ attribute :p, Hyperlang::Xhtml::P, collection: true
10
+ attribute :h1, Hyperlang::Xhtml::H1, collection: true
11
+ attribute :h2, Hyperlang::Xhtml::H2, collection: true
12
+ attribute :h3, Hyperlang::Xhtml::H3, collection: true
13
+ attribute :h4, Hyperlang::Xhtml::H4, collection: true
14
+ attribute :h5, Hyperlang::Xhtml::H5, collection: true
15
+ attribute :h6, Hyperlang::Xhtml::H6, collection: true
16
+ attribute :ul, Hyperlang::Xhtml::Ul, collection: true
17
+ attribute :ol, Hyperlang::Xhtml::Ol, collection: true
18
+ attribute :table, Hyperlang::Xhtml::Table, collection: true
19
+ attribute :form, Hyperlang::Xhtml::Form, collection: true
20
+ attribute :id, :string
21
+ attribute :klass, :string
22
+
23
+ xml do
24
+ element "noframes"
25
+ namespace Hyperlang::Xhtml::Namespace
26
+ mixed_content
27
+ map_content to: :content
28
+ map_element "body", to: :body
29
+ map_element "div", to: :div
30
+ map_element "p", to: :p
31
+ map_element "h1", to: :h1
32
+ map_element "h2", to: :h2
33
+ map_element "h3", to: :h3
34
+ map_element "h4", to: :h4
35
+ map_element "h5", to: :h5
36
+ map_element "h6", to: :h6
37
+ map_element "ul", to: :ul
38
+ map_element "ol", to: :ol
39
+ map_element "table", to: :table
40
+ map_element "form", to: :form
41
+ map_attribute "id", to: :id
42
+ map_attribute "class", to: :klass
43
+ end
44
+ end
45
+ end
46
+ end
@@ -0,0 +1,42 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Hyperlang
4
+ module Xhtml
5
+ class Noscript < Lutaml::Model::Serializable
6
+ attribute :content, :string
7
+ attribute :p, Hyperlang::Xhtml::P, collection: true
8
+ attribute :div, Hyperlang::Xhtml::Div, collection: true
9
+ attribute :ul, Hyperlang::Xhtml::Ul, collection: true
10
+ attribute :ol, Hyperlang::Xhtml::Ol, collection: true
11
+ attribute :table, Hyperlang::Xhtml::Table, collection: true
12
+ attribute :h1, Hyperlang::Xhtml::H1, collection: true
13
+ attribute :h2, Hyperlang::Xhtml::H2, collection: true
14
+ attribute :h3, Hyperlang::Xhtml::H3, collection: true
15
+ attribute :h4, Hyperlang::Xhtml::H4, collection: true
16
+ attribute :h5, Hyperlang::Xhtml::H5, collection: true
17
+ attribute :h6, Hyperlang::Xhtml::H6, collection: true
18
+ attribute :id, :string
19
+ attribute :klass, :string
20
+
21
+ xml do
22
+ element "noscript"
23
+ namespace Hyperlang::Xhtml::Namespace
24
+ mixed_content
25
+ map_content to: :content
26
+ map_element "p", to: :p
27
+ map_element "div", to: :div
28
+ map_element "ul", to: :ul
29
+ map_element "ol", to: :ol
30
+ map_element "table", to: :table
31
+ map_element "h1", to: :h1
32
+ map_element "h2", to: :h2
33
+ map_element "h3", to: :h3
34
+ map_element "h4", to: :h4
35
+ map_element "h5", to: :h5
36
+ map_element "h6", to: :h6
37
+ map_attribute "id", to: :id
38
+ map_attribute "class", to: :klass
39
+ end
40
+ end
41
+ end
42
+ end
@@ -0,0 +1,48 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Hyperlang
4
+ module Xhtml
5
+ class Object < Lutaml::Model::Serializable
6
+ attribute :param, Hyperlang::Xhtml::Param, collection: true
7
+ attribute :content, :string
8
+ attribute :declare, :string
9
+ attribute :classid, :string
10
+ attribute :codebase, :string
11
+ attribute :data, :string
12
+ attribute :type, :string
13
+ attribute :codetype, :string
14
+ attribute :archive, :string
15
+ attribute :standby, :string
16
+ attribute :height, :string
17
+ attribute :width, :string
18
+ attribute :name, :string
19
+ attribute :tabindex, :integer
20
+ attribute :usemap, :string
21
+ attribute :id, :string
22
+ attribute :klass, :string
23
+
24
+ xml do
25
+ element "object"
26
+ namespace Hyperlang::Xhtml::Namespace
27
+ mixed_content
28
+ map_element "param", to: :param
29
+ map_content to: :content
30
+ map_attribute "declare", to: :declare
31
+ map_attribute "classid", to: :classid
32
+ map_attribute "codebase", to: :codebase
33
+ map_attribute "data", to: :data
34
+ map_attribute "type", to: :type
35
+ map_attribute "codetype", to: :codetype
36
+ map_attribute "archive", to: :archive
37
+ map_attribute "standby", to: :standby
38
+ map_attribute "height", to: :height
39
+ map_attribute "width", to: :width
40
+ map_attribute "name", to: :name
41
+ map_attribute "tabindex", to: :tabindex
42
+ map_attribute "usemap", to: :usemap
43
+ map_attribute "id", to: :id
44
+ map_attribute "class", to: :klass
45
+ end
46
+ end
47
+ end
48
+ end
@@ -0,0 +1,25 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Hyperlang
4
+ module Xhtml
5
+ class Ol < Lutaml::Model::Serializable
6
+ attribute :li, Hyperlang::Xhtml::Li, collection: true
7
+ attribute :type, :string
8
+ attribute :start, :integer
9
+ attribute :compact, :string
10
+ attribute :id, :string
11
+ attribute :klass, :string
12
+
13
+ xml do
14
+ element "ol"
15
+ namespace Hyperlang::Xhtml::Namespace
16
+ map_element "li", to: :li
17
+ map_attribute "type", to: :type
18
+ map_attribute "start", to: :start
19
+ map_attribute "compact", to: :compact
20
+ map_attribute "id", to: :id
21
+ map_attribute "class", to: :klass
22
+ end
23
+ end
24
+ end
25
+ end
@@ -0,0 +1,23 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Hyperlang
4
+ module Xhtml
5
+ class Optgroup < Lutaml::Model::Serializable
6
+ attribute :option, Hyperlang::Xhtml::Option, collection: true
7
+ attribute :disabled, :string
8
+ attribute :label, :string
9
+ attribute :id, :string
10
+ attribute :klass, :string
11
+
12
+ xml do
13
+ element "optgroup"
14
+ namespace Hyperlang::Xhtml::Namespace
15
+ map_element "option", to: :option
16
+ map_attribute "disabled", to: :disabled
17
+ map_attribute "label", to: :label
18
+ map_attribute "id", to: :id
19
+ map_attribute "class", to: :klass
20
+ end
21
+ end
22
+ end
23
+ end
@@ -0,0 +1,25 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Hyperlang
4
+ module Xhtml
5
+ class Option < Lutaml::Model::Serializable
6
+ attribute :content, :string
7
+ attribute :selected, :string
8
+ attribute :disabled, :string
9
+ attribute :value, :string
10
+ attribute :label, :string
11
+ attribute :id, :string
12
+
13
+ xml do
14
+ element "option"
15
+ namespace Hyperlang::Xhtml::Namespace
16
+ map_content to: :content
17
+ map_attribute "selected", to: :selected
18
+ map_attribute "disabled", to: :disabled
19
+ map_attribute "value", to: :value
20
+ map_attribute "label", to: :label
21
+ map_attribute "id", to: :id
22
+ end
23
+ end
24
+ end
25
+ end
@@ -0,0 +1,36 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Hyperlang
4
+ module Xhtml
5
+ class P < Lutaml::Model::Serializable
6
+ attribute :content, :string
7
+ attribute :span, Hyperlang::Xhtml::Span, collection: true
8
+ attribute :a, Hyperlang::Xhtml::A, collection: true
9
+ attribute :strong, Hyperlang::Xhtml::Strong, collection: true
10
+ attribute :em, Hyperlang::Xhtml::Em, collection: true
11
+ attribute :code, Hyperlang::Xhtml::Code, collection: true
12
+ attribute :br, Hyperlang::Xhtml::Br, collection: true
13
+ attribute :img, Hyperlang::Xhtml::Img, collection: true
14
+ attribute :klass, :string
15
+ attribute :style, :string
16
+ attribute :id, :string
17
+
18
+ xml do
19
+ element "p"
20
+ namespace Hyperlang::Xhtml::Namespace
21
+ mixed_content
22
+ map_content to: :content
23
+ map_element "span", to: :span
24
+ map_element "a", to: :a
25
+ map_element "strong", to: :strong
26
+ map_element "em", to: :em
27
+ map_element "code", to: :code
28
+ map_element "br", to: :br
29
+ map_element "img", to: :img
30
+ map_attribute "class", to: :klass
31
+ map_attribute "style", to: :style
32
+ map_attribute "id", to: :id
33
+ end
34
+ end
35
+ end
36
+ end
@@ -0,0 +1,23 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Hyperlang
4
+ module Xhtml
5
+ class Param < Lutaml::Model::Serializable
6
+ attribute :name, :string
7
+ attribute :value, :string
8
+ attribute :type, :string
9
+ attribute :valuetype, :string
10
+ attribute :id, :string
11
+
12
+ xml do
13
+ element "param"
14
+ namespace Hyperlang::Xhtml::Namespace
15
+ map_attribute "name", to: :name
16
+ map_attribute "value", to: :value
17
+ map_attribute "type", to: :type
18
+ map_attribute "valuetype", to: :valuetype
19
+ map_attribute "id", to: :id
20
+ end
21
+ end
22
+ end
23
+ end
@@ -0,0 +1,32 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Hyperlang
4
+ module Xhtml
5
+ class Pre < Lutaml::Model::Serializable
6
+ attribute :content, :string
7
+ attribute :a, Hyperlang::Xhtml::A, collection: true
8
+ attribute :span, Hyperlang::Xhtml::Span, collection: true
9
+ attribute :strong, Hyperlang::Xhtml::Strong, collection: true
10
+ attribute :em, Hyperlang::Xhtml::Em, collection: true
11
+ attribute :code, Hyperlang::Xhtml::Code, collection: true
12
+ attribute :klass, :string
13
+ attribute :style, :string
14
+ attribute :id, :string
15
+
16
+ xml do
17
+ element "pre"
18
+ namespace Hyperlang::Xhtml::Namespace
19
+ mixed_content
20
+ map_content to: :content
21
+ map_element "a", to: :a
22
+ map_element "span", to: :span
23
+ map_element "strong", to: :strong
24
+ map_element "em", to: :em
25
+ map_element "code", to: :code
26
+ map_attribute "class", to: :klass
27
+ map_attribute "style", to: :style
28
+ map_attribute "id", to: :id
29
+ end
30
+ end
31
+ end
32
+ end
@@ -0,0 +1,22 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Hyperlang
4
+ module Xhtml
5
+ class Q < Lutaml::Model::Serializable
6
+ attribute :content, :string
7
+ attribute :cite, :string
8
+ attribute :id, :string
9
+ attribute :klass, :string
10
+
11
+ xml do
12
+ element "q"
13
+ namespace Hyperlang::Xhtml::Namespace
14
+ mixed_content
15
+ map_content to: :content
16
+ map_attribute "cite", to: :cite
17
+ map_attribute "id", to: :id
18
+ map_attribute "class", to: :klass
19
+ end
20
+ end
21
+ end
22
+ end
@@ -0,0 +1,20 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Hyperlang
4
+ module Xhtml
5
+ class Rb < Lutaml::Model::Serializable
6
+ attribute :content, :string
7
+ attribute :id, :string
8
+ attribute :klass, :string
9
+
10
+ xml do
11
+ element "rb"
12
+ namespace Hyperlang::Xhtml::Namespace
13
+ mixed_content
14
+ map_content to: :content
15
+ map_attribute "id", to: :id
16
+ map_attribute "class", to: :klass
17
+ end
18
+ end
19
+ end
20
+ end
@@ -0,0 +1,19 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Hyperlang
4
+ module Xhtml
5
+ class Rbc < Lutaml::Model::Serializable
6
+ attribute :rb, Hyperlang::Xhtml::Rb, collection: true
7
+ attribute :id, :string
8
+ attribute :klass, :string
9
+
10
+ xml do
11
+ element "rbc"
12
+ namespace Hyperlang::Xhtml::Namespace
13
+ map_element "rb", to: :rb
14
+ map_attribute "id", to: :id
15
+ map_attribute "class", to: :klass
16
+ end
17
+ end
18
+ end
19
+ end
@@ -0,0 +1,19 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Hyperlang
4
+ module Xhtml
5
+ class Rp < Lutaml::Model::Serializable
6
+ attribute :content, :string
7
+ attribute :id, :string
8
+ attribute :klass, :string
9
+
10
+ xml do
11
+ element "rp"
12
+ namespace Hyperlang::Xhtml::Namespace
13
+ map_content to: :content
14
+ map_attribute "id", to: :id
15
+ map_attribute "class", to: :klass
16
+ end
17
+ end
18
+ end
19
+ end
@@ -0,0 +1,22 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Hyperlang
4
+ module Xhtml
5
+ class Rt < Lutaml::Model::Serializable
6
+ attribute :content, :string
7
+ attribute :rbspan, :integer
8
+ attribute :id, :string
9
+ attribute :klass, :string
10
+
11
+ xml do
12
+ element "rt"
13
+ namespace Hyperlang::Xhtml::Namespace
14
+ mixed_content
15
+ map_content to: :content
16
+ map_attribute "rbspan", to: :rbspan
17
+ map_attribute "id", to: :id
18
+ map_attribute "class", to: :klass
19
+ end
20
+ end
21
+ end
22
+ end
@@ -0,0 +1,23 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Hyperlang
4
+ module Xhtml
5
+ class Rtc < Lutaml::Model::Serializable
6
+ attribute :rt, Hyperlang::Xhtml::Rt, collection: true
7
+ attribute :rp, Hyperlang::Xhtml::Rp, collection: true
8
+ attribute :rbspan, :integer
9
+ attribute :id, :string
10
+ attribute :klass, :string
11
+
12
+ xml do
13
+ element "rtc"
14
+ namespace Hyperlang::Xhtml::Namespace
15
+ map_element "rt", to: :rt
16
+ map_element "rp", to: :rp
17
+ map_attribute "rbspan", to: :rbspan
18
+ map_attribute "id", to: :id
19
+ map_attribute "class", to: :klass
20
+ end
21
+ end
22
+ end
23
+ end
@@ -0,0 +1,27 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Hyperlang
4
+ module Xhtml
5
+ class Ruby < Lutaml::Model::Serializable
6
+ attribute :rbc, Hyperlang::Xhtml::Rbc
7
+ attribute :rtc, Hyperlang::Xhtml::Rtc
8
+ attribute :rb, Hyperlang::Xhtml::Rb, collection: true
9
+ attribute :rt, Hyperlang::Xhtml::Rt, collection: true
10
+ attribute :rp, Hyperlang::Xhtml::Rp, collection: true
11
+ attribute :id, :string
12
+ attribute :klass, :string
13
+
14
+ xml do
15
+ element "ruby"
16
+ namespace Hyperlang::Xhtml::Namespace
17
+ map_element "rbc", to: :rbc
18
+ map_element "rtc", to: :rtc
19
+ map_element "rb", to: :rb
20
+ map_element "rt", to: :rt
21
+ map_element "rp", to: :rp
22
+ map_attribute "id", to: :id
23
+ map_attribute "class", to: :klass
24
+ end
25
+ end
26
+ end
27
+ end
@@ -0,0 +1,20 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Hyperlang
4
+ module Xhtml
5
+ class S < Lutaml::Model::Serializable
6
+ attribute :content, :string
7
+ attribute :id, :string
8
+ attribute :klass, :string
9
+
10
+ xml do
11
+ element "s"
12
+ namespace Hyperlang::Xhtml::Namespace
13
+ mixed_content
14
+ map_content to: :content
15
+ map_attribute "id", to: :id
16
+ map_attribute "class", to: :klass
17
+ end
18
+ end
19
+ end
20
+ end
@@ -0,0 +1,20 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Hyperlang
4
+ module Xhtml
5
+ class Samp < Lutaml::Model::Serializable
6
+ attribute :content, :string
7
+ attribute :id, :string
8
+ attribute :klass, :string
9
+
10
+ xml do
11
+ element "samp"
12
+ namespace Hyperlang::Xhtml::Namespace
13
+ mixed_content
14
+ map_content to: :content
15
+ map_attribute "id", to: :id
16
+ map_attribute "class", to: :klass
17
+ end
18
+ end
19
+ end
20
+ end