html completion fixes

- filter out template completions
- use the completion replacement string to accomodate completions
  outside the context of a tag.

fixes #322