     ] map ;
 
 : find-by-id ( vector id -- vector' elt/f )
-    '[ "id" attribute _ = ] find ;
+    '[ _ html-id? ] find ;
 
 : find-by-class ( vector id -- vector' elt/f )
     '[ _ html-class? ] find ;

    [ "type" attribute "hidden" = ] filter ;

: input. ( tag -- )
    dup name>> print
    attributes>>
    [ bl bl bl bl [ write "=" write ] [ write bl ] bi* nl ] assoc-each ;

: form. ( vector -- )

    >lower '[ name>> _ = ] find ;

: find-by-id-between ( vector string -- vector' )
    '[ _ html-id? ] dupd find find-between* ;

: find-by-class-between ( vector string -- vector' )
    '[ _ html-class? ] dupd find find-between* ;

: find-by-class-id-between ( vector class id -- vector' )
    '[
        [ _ html-class? ] [ _ html-id? ] bi and
    ] dupd find find-between* ;

: find-by-attribute-key ( vector key -- vector' )
    >lower '[ _ attribute? ] filter sift ;

: find-by-attribute-key-value ( vector value key -- vector' )
    >lower swap '[ _ attribute _ = ] filter sift ;

: find-first-attribute-key-value ( vector value key -- i/f tag/f )
    >lower swap '[ _ attribute _ = ] find ;

: find-links ( vector -- vector' )
    [ { [ name>> "a" = ] [ "href" attribute ] } 1&& ]
    find-between-all ;

: find-images ( vector -- vector' )
    [ { [ name>> "img" = ] [ "src" attribute ] } 1&& ] filter sift
    [ "src" attribute ] map ;

: find-by-text ( seq quot -- tag )
    [ dup name>> text = ] prepose find drop ; inline
