diff options
author | bptato <nincsnevem662@gmail.com> | 2021-03-17 12:20:05 +0100 |
---|---|---|
committer | bptato <nincsnevem662@gmail.com> | 2021-03-17 12:20:05 +0100 |
commit | 94a10242dca6181ef8f15a37e7083069ead09559 (patch) | |
tree | ccdb28c82535aa7cda25f2bfe26cbfa451eaecab /src/main.nim | |
parent | 97f19da347b27a4d12f54784fa8bcbf304aa4fea (diff) | |
download | chawan-94a10242dca6181ef8f15a37e7083069ead09559.tar.gz |
...
Diffstat (limited to 'src/main.nim')
-rw-r--r-- | src/main.nim | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/main.nim b/src/main.nim index bc212ef0..95f1f3cd 100644 --- a/src/main.nim +++ b/src/main.nim @@ -8,7 +8,9 @@ import termattrs import buffer import twtio import config -import parser +import htmlparser +import dom +import style let clientInstance = newHttpClient() proc loadRemotePage*(url: string): string = @@ -44,6 +46,9 @@ proc main*() = let uri = parseUri(paramStr(1)) buffers.add(buffer) buffer.document = parseHtml(getPageUri(uri)) + #discard buffer.document.querySelector("#hi.a[title=\"test\"]") + var box = CSSBox() + applyProperties(box, "color: #090; line-height: 1.2") buffer.setLocation(uri) buffer.renderHtml() var lastUri = uri |