mirror of
https://github.com/lightpanda-io/browser.git
synced 2026-02-04 14:33:47 +00:00
add more generic HTML types
This commit is contained in:
@@ -1367,7 +1367,7 @@ pub fn createElementNS(self: *Page, namespace: Element.Namespace, name: []const
|
|||||||
Element.Html.Quote,
|
Element.Html.Quote,
|
||||||
namespace,
|
namespace,
|
||||||
attribute_iterator,
|
attribute_iterator,
|
||||||
.{ ._proto = undefined, ._tag_name = String.init(undefined, "q", .{}) catch unreachable, ._tag = .unknown },
|
.{ ._proto = undefined, ._tag_name = String.init(undefined, "q", .{}) catch unreachable, ._tag = .quote },
|
||||||
),
|
),
|
||||||
's' => return self.createHtmlElementT(
|
's' => return self.createHtmlElementT(
|
||||||
Element.Html.Generic,
|
Element.Html.Generic,
|
||||||
@@ -1523,7 +1523,7 @@ pub fn createElementNS(self: *Page, namespace: Element.Namespace, name: []const
|
|||||||
Element.Html.TableCol,
|
Element.Html.TableCol,
|
||||||
namespace,
|
namespace,
|
||||||
attribute_iterator,
|
attribute_iterator,
|
||||||
.{ ._proto = undefined, ._tag_name = String.init(undefined, "col", .{}) catch unreachable, ._tag = .unknown },
|
.{ ._proto = undefined, ._tag_name = String.init(undefined, "col", .{}) catch unreachable, ._tag = .col },
|
||||||
),
|
),
|
||||||
asUint("dir") => return self.createHtmlElementT(
|
asUint("dir") => return self.createHtmlElementT(
|
||||||
Element.Html.Directory,
|
Element.Html.Directory,
|
||||||
@@ -1926,7 +1926,7 @@ pub fn createElementNS(self: *Page, namespace: Element.Namespace, name: []const
|
|||||||
Element.Html.TableCol,
|
Element.Html.TableCol,
|
||||||
namespace,
|
namespace,
|
||||||
attribute_iterator,
|
attribute_iterator,
|
||||||
.{ ._proto = undefined, ._tag_name = String.init(undefined, "colgroup", .{}) catch unreachable, ._tag = .unknown },
|
.{ ._proto = undefined, ._tag_name = String.init(undefined, "colgroup", .{}) catch unreachable, ._tag = .colgroup },
|
||||||
),
|
),
|
||||||
asUint("fieldset") => return self.createHtmlElementT(
|
asUint("fieldset") => return self.createHtmlElementT(
|
||||||
Element.Html.FieldSet,
|
Element.Html.FieldSet,
|
||||||
@@ -1952,6 +1952,12 @@ pub fn createElementNS(self: *Page, namespace: Element.Namespace, name: []const
|
|||||||
attribute_iterator,
|
attribute_iterator,
|
||||||
.{ ._proto = undefined },
|
.{ ._proto = undefined },
|
||||||
),
|
),
|
||||||
|
asUint("noscript") => return self.createHtmlElementT(
|
||||||
|
Element.Html.Generic,
|
||||||
|
namespace,
|
||||||
|
attribute_iterator,
|
||||||
|
.{ ._proto = undefined, ._tag_name = String.init(undefined, "noscript", .{}) catch unreachable, ._tag = .noscript },
|
||||||
|
),
|
||||||
else => {},
|
else => {},
|
||||||
},
|
},
|
||||||
10 => switch (@as(u80, @bitCast(name[0..10].*))) {
|
10 => switch (@as(u80, @bitCast(name[0..10].*))) {
|
||||||
|
|||||||
@@ -1219,6 +1219,8 @@ pub const Tag = enum {
|
|||||||
caption,
|
caption,
|
||||||
circle,
|
circle,
|
||||||
code,
|
code,
|
||||||
|
col,
|
||||||
|
colgroup,
|
||||||
custom,
|
custom,
|
||||||
data,
|
data,
|
||||||
datalist,
|
datalist,
|
||||||
@@ -1265,20 +1267,26 @@ pub const Tag = enum {
|
|||||||
meta,
|
meta,
|
||||||
meter,
|
meter,
|
||||||
nav,
|
nav,
|
||||||
|
noscript,
|
||||||
|
object,
|
||||||
ol,
|
ol,
|
||||||
optgroup,
|
optgroup,
|
||||||
option,
|
option,
|
||||||
|
output,
|
||||||
p,
|
p,
|
||||||
path,
|
path,
|
||||||
|
param,
|
||||||
polygon,
|
polygon,
|
||||||
polyline,
|
polyline,
|
||||||
progress,
|
progress,
|
||||||
|
quote,
|
||||||
rect,
|
rect,
|
||||||
s,
|
s,
|
||||||
script,
|
script,
|
||||||
section,
|
section,
|
||||||
select,
|
select,
|
||||||
slot,
|
slot,
|
||||||
|
source,
|
||||||
span,
|
span,
|
||||||
strong,
|
strong,
|
||||||
style,
|
style,
|
||||||
@@ -1298,6 +1306,7 @@ pub const Tag = enum {
|
|||||||
thead,
|
thead,
|
||||||
title,
|
title,
|
||||||
tr,
|
tr,
|
||||||
|
track,
|
||||||
ul,
|
ul,
|
||||||
video,
|
video,
|
||||||
unknown,
|
unknown,
|
||||||
|
|||||||
Reference in New Issue
Block a user