refactor: i18n

This commit is contained in:
liyasthomas
2021-08-16 23:15:06 +05:30
parent c04435108b
commit 6c3607d7e7
21 changed files with 16882 additions and 14611 deletions

View File

@@ -1,5 +1,5 @@
const htmlLens = {
lensName: "HTML",
lensName: "response.html",
isSupportedContentType: (contentType) =>
/\btext\/html|application\/xhtml\+xml\b/i.test(contentType),
renderer: "htmlres",

View File

@@ -1,5 +1,5 @@
const imageLens = {
lensName: "Image",
lensName: "response.image",
isSupportedContentType: (contentType) =>
/\bimage\/(?:gif|jpeg|png|bmp|svg\+xml|x-icon|vnd\.microsoft\.icon)\b/i.test(
contentType

View File

@@ -1,7 +1,7 @@
import { isJSONContentType } from "../utils/contenttypes"
const jsonLens = {
lensName: "JSON",
lensName: "response.json",
isSupportedContentType: isJSONContentType,
renderer: "json",
rendererImport: () =>

View File

@@ -1,5 +1,5 @@
const rawLens = {
lensName: "Raw",
lensName: "response.raw",
isSupportedContentType: () => true,
renderer: "raw",
rendererImport: () => import("~/components/lenses/renderers/RawLensRenderer"),

View File

@@ -1,5 +1,5 @@
const xmlLens = {
lensName: "XML",
lensName: "response.xml",
isSupportedContentType: (contentType) => /\bxml\b/i.test(contentType),
renderer: "xmlres",
rendererImport: () => import("~/components/lenses/renderers/XMLLensRenderer"),