diff options
author | bptato <nincsnevem662@gmail.com> | 2022-01-23 01:02:44 +0100 |
---|---|---|
committer | bptato <nincsnevem662@gmail.com> | 2022-01-23 01:02:44 +0100 |
commit | 010185f7c306f2465b691a82fcbfe1c76513f8fc (patch) | |
tree | b755627c1ff776485cf04a469d3dcdeebe2639c8 /src/types | |
parent | 6ff61c5ad2ad2af36195b83582ed98be57b93f18 (diff) | |
download | chawan-010185f7c306f2465b691a82fcbfe1c76513f8fc.tar.gz |
Support external stylesheets
Diffstat (limited to 'src/types')
-rw-r--r-- | src/types/mime.nim | 1 | ||||
-rw-r--r-- | src/types/url.nim | 5 |
2 files changed, 5 insertions, 1 deletions
diff --git a/src/types/mime.nim b/src/types/mime.nim index 5c48c896..fb3f4b2c 100644 --- a/src/types/mime.nim +++ b/src/types/mime.nim @@ -7,6 +7,7 @@ const DefaultGuess = [ ("xhtm", "application/xhtml+xml"), ("xht", "application/xhtml+xml"), ("txt", "text/plain"), + ("css", "text/css"), ("", "text/plain") ].toTable() diff --git a/src/types/url.nim b/src/types/url.nim index 2356fb73..00a5fd51 100644 --- a/src/types/url.nim +++ b/src/types/url.nim @@ -317,7 +317,10 @@ proc shorten_path(url: var Url) {.inline.} = discard url.path.ss.pop() proc append(path: var UrlPath, s: string) = - path.ss.add(s) + if path.opaque: + path.s &= s + else: + path.ss.add(s) template includes_credentials(url: Url): bool = url.username != "" or url.password != "" |