1
0
mirror of https://github.com/node-red/node-red.git synced 2023-10-10 13:36:53 +02:00

revise header options

- remove Accept-Charset
- Use camel case by default
- additional encodings
This commit is contained in:
Steve-Mcl 2022-03-12 15:00:48 +00:00
parent 6007132640
commit b7ee46d400

View File

@ -120,14 +120,13 @@
(function() { (function() {
const headerTypes = [ const headerTypes = [
{ value: "Accept", label: "Accept", hasValue: false }, { value: "Accept", label: "Accept", hasValue: false },
{ value: "Accept-Charset", label: "Accept-Charset", hasValue: false },
{ value: "Accept-Encoding", label: "Accept-Encoding", hasValue: false }, { value: "Accept-Encoding", label: "Accept-Encoding", hasValue: false },
{ value: "Accept-Language", label: "Accept-Language", hasValue: false }, { value: "Accept-Language", label: "Accept-Language", hasValue: false },
{ value: "Authorization", label: "Authorization", hasValue: false }, { value: "Authorization", label: "Authorization", hasValue: false },
{ value: "content-type", label: "Content-Type", hasValue: false }, { value: "Content-Type", label: "Content-Type", hasValue: false },
{ value: "Cache-Control", label: "Cache-Control", hasValue: false }, { value: "Cache-Control", label: "Cache-Control", hasValue: false },
{ value: "User-Agent", label: "User-Agent", hasValue: false }, { value: "User-Agent", label: "User-Agent", hasValue: false },
{ value: "location", label: "Location", hasValue: false }, { value: "Location", label: "Location", hasValue: false },
{ value: "other", label: "other", hasValue: true, icon: "red/images/typedInput/az.png" }, { value: "other", label: "other", hasValue: true, icon: "red/images/typedInput/az.png" },
{ value: "msg", label: "msg.", hasValue: true }, { value: "msg", label: "msg.", hasValue: true },
] ]
@ -146,7 +145,8 @@
headerOptions["accept-encoding"] = [ headerOptions["accept-encoding"] = [
{ value: "gzip", label: "gzip", hasValue: false }, { value: "gzip", label: "gzip", hasValue: false },
{ value: "deflate", label: "deflate", hasValue: false }, { value: "deflate", label: "deflate", hasValue: false },
{ value: "gzip", label: "gzip", hasValue: false }, { value: "compress", label: "compress", hasValue: false },
{ value: "br", label: "br", hasValue: false },
{ value: "gzip, deflate", label: "gzip, deflate", hasValue: false }, { value: "gzip, deflate", label: "gzip, deflate", hasValue: false },
{ value: "gzip, deflate, br", label: "gzip, deflate, br", hasValue: false }, { value: "gzip, deflate, br", label: "gzip, deflate, br", hasValue: false },
...defaultOptions, ...defaultOptions,
@ -158,7 +158,7 @@
{ value: "es-mx,es,en;q=0.5", label: "es-mx,es,en;q=0.5", hasValue: false }, { value: "es-mx,es,en;q=0.5", label: "es-mx,es,en;q=0.5", hasValue: false },
{ value: "fr-CH, fr;q=0.9, en;q=0.8", label: "fr-CH, fr;q=0.9, en;q=0.8", hasValue: false }, { value: "fr-CH, fr;q=0.9, en;q=0.8", label: "fr-CH, fr;q=0.9, en;q=0.8", hasValue: false },
{ value: "zh-CN, zh-TW; q = 0.9, zh-HK; q = 0.8, zh; q = 0.7, en; q = 0.6", label: "zh-CN, zh-TW; q = 0.9, zh-HK; q = 0.8, zh; q = 0.7, en; q = 0.6", hasValue: false }, { value: "zh-CN, zh-TW; q = 0.9, zh-HK; q = 0.8, zh; q = 0.7, en; q = 0.6", label: "zh-CN, zh-TW; q = 0.9, zh-HK; q = 0.8, zh; q = 0.7, en; q = 0.6", hasValue: false },
{ value: "jp", label: "jp", hasValue: false }, { value: "ja-JP, jp", label: "ja-JP, jp", hasValue: false },
...defaultOptions, ...defaultOptions,
]; ];
headerOptions["content-type"] = [ headerOptions["content-type"] = [