From 358bd56091c35145e2433c1cd12c64e223fd0a42 Mon Sep 17 00:00:00 2001 From: totoro Date: Sat, 16 Oct 2021 20:58:29 +0200 Subject: [PATCH] [+] add html_tag in many form --- web/making_a_web_site.anubis | 17 +++++++++++++++++ 1 file changed, 17 insertions(+), 0 deletions(-) diff --git a/web/making_a_web_site.anubis b/web/making_a_web_site.anubis index 5101596..0706dbf 100644 --- a/web/making_a_web_site.anubis +++ b/web/making_a_web_site.anubis @@ -1351,6 +1351,23 @@ public define HTML_Off_Form button(List(CoreAttrs) attrs) public define HTML_Off_Form button(List(HTML_Off_Form) content) = html_tag("button", [], content). public define HTML_Off_Form button(HTML_Off_Form content) = html_tag("button", [], [content]). + // +public define HTML_Off_Form canvas(List(CoreAttrs) attrs, List(HTML_Off_Form) content) = html_tag("canvas", attrs, content). +public define HTML_Off_Form canvas(List(CoreAttrs) attrs, HTML_Off_Form content) = html_tag("canvas", attrs, [content]). +public define HTML_Off_Form canvas(CoreAttrs attr, List(HTML_Off_Form) content) = html_tag("canvas", [attr], content). +public define HTML_Off_Form canvas(CoreAttrs attr, HTML_Off_Form content) = html_tag("canvas", [attr], [content]). +public define HTML_Off_Form canvas(List(CoreAttrs) attrs) = html_tag("canvas", attrs, []). +public define HTML_Off_Form canvas(List(HTML_Off_Form) content) = html_tag("canvas", [], content). +public define HTML_Off_Form canvas(HTML_Off_Form content) = html_tag("canvas", [], [content]). +public define HTML_Off_Form canvas(CoreAttrs cattr, Int width, Int height) = html_tag("canvas", [cattr, + attr("width", to_String(width)), + attr("height", to_String(height)) + ], []). +public define HTML_Off_Form canvas(List(CoreAttrs) attrs, Int width, Int height) = html_tag("canvas", [ + attr("width", to_String(width)), + attr("height", to_String(height)). + attrs + ], []). // public define HTML_Off_Form datalist(List(CoreAttrs) attrs, List(HTML_Off_Form) content) = html_tag("datalist", attrs, content). public define HTML_Off_Form datalist(List(CoreAttrs) attrs, HTML_Off_Form content) = html_tag("datalist", attrs, [content]). -- libgit2 0.21.4