diff --git a/basis/eval/eval-tests.factor b/basis/eval/eval-tests.factor index 102a4d49ef..675921944a 100644 --- a/basis/eval/eval-tests.factor +++ b/basis/eval/eval-tests.factor @@ -1,4 +1,4 @@ IN: eval.tests USING: eval tools.test ; -[ "4\n" ] [ "USING: math prettyprint ; 2 2 + ." eval>string ] unit-test \ No newline at end of file +[ "4\n" ] [ "USING: math prettyprint ; 2 2 + ." eval>string ] unit-test diff --git a/basis/html/components/components.factor b/basis/html/components/components.factor index c8a4b20ca7..e63447ec55 100644 --- a/basis/html/components/components.factor +++ b/basis/html/components/components.factor @@ -3,7 +3,7 @@ USING: accessors kernel namespaces io math.parser assocs classes classes.tuple words arrays sequences splitting mirrors hashtables combinators continuations math strings inspector -fry locals calendar calendar.format xml.entities +fry locals calendar calendar.format xml.entities xml.data validators urls present xml.writer xml.interpolate xml xmode.code2html lcs.diff2html farkup io.streams.string html.elements html.streams html.forms ; @@ -65,12 +65,15 @@ TUPLE: textarea rows cols ; : XML] ; +M:: textarea render* ( value name area -- xml ) + area rows>> :> rows + area cols>> :> cols + [XML + + XML] ; ! Choice TUPLE: choice size multiple choices ; @@ -160,8 +163,9 @@ M: farkup render* SINGLETON: inspector M: inspector render* - 2drop [ [ describe ] with-html-writer ] with-string-writer - string>xml-chunk ; + 2drop [ + [ describe ] with-html-writer + ] with-string-writer ; ! Diff component SINGLETON: comparison diff --git a/basis/xml/data/data.factor b/basis/xml/data/data.factor index c44250035a..5dc13adf16 100644 --- a/basis/xml/data/data.factor +++ b/basis/xml/data/data.factor @@ -219,3 +219,6 @@ PREDICATE: open-tag < tag children>> ; UNION: xml-data tag comment string directive instruction ; + +TUPLE: unescaped string ; +C: unescaped diff --git a/basis/xml/writer/writer-tests.factor b/basis/xml/writer/writer-tests.factor index 2d3a90cc15..e9959c1ef4 100644 --- a/basis/xml/writer/writer-tests.factor +++ b/basis/xml/writer/writer-tests.factor @@ -59,3 +59,4 @@ IN: xml.writer.tests [ "bar" string>xml [ " baz" append ] map xml>string ] unit-test [ "\n\n bar\n" ] [ " bar " string>xml pprint-xml>string ] unit-test +[ "" ] [ "" xml-chunk>string ] unit-test diff --git a/basis/xml/writer/writer.factor b/basis/xml/writer/writer.factor index a19fe69444..8e2dc4bfbf 100644 --- a/basis/xml/writer/writer.factor +++ b/basis/xml/writer/writer.factor @@ -98,6 +98,9 @@ M: open-tag write-xml-chunk } cleave ] dip xml-pprint? set ; +M: unescaped write-xml-chunk + string>> write ; + M: comment write-xml-chunk "" write ; diff --git a/basis/xmode/code2html/code2html.factor b/basis/xmode/code2html/code2html.factor index 4cdef4043e..962b0e9fbf 100644 --- a/basis/xmode/code2html/code2html.factor +++ b/basis/xmode/code2html/code2html.factor @@ -15,7 +15,7 @@ IN: xmode.code2html tokenize-line htmlize-tokens ; : htmlize-lines ( lines mode -- xml ) - f -rot load-mode [ htmlize-line ] curry map nip ; + [ f ] 2dip load-mode [ htmlize-line ] curry map nip ; : default-stylesheet ( -- xml ) "resource:basis/xmode/code2html/stylesheet.css"