diff --git a/server.ts b/server.ts index dd919c9..902e252 100644 --- a/server.ts +++ b/server.ts @@ -72,6 +72,21 @@ const controllers = [ new BlockchainOutputController() ]; +app.use(function(req, res, next) { + res.header('Access-Control-Allow-Origin', '*'); + res.header('Access-Control-Allow-Methods', 'GET,PUT,POST,DELETE,OPTIONS'); + res.header('Access-Control-Allow-Headers', 'Content-Type, Authorization, Content-Length, X-Requested-With, Accept, Authtoken,cookie_id'); + + // intercept OPTIONS method + if ('OPTIONS' == req.method) { + return res.status(200).end(); + } + else { + next(); + } +} +); + app.use(errorMiddleware); app.use(bodyParser.json({ limit: "50mb" })); app.use(bodyParser.urlencoded({ extended: false })); diff --git a/server/i18n/de.json b/server/i18n/de.json index 5f94735..e8de9f0 100644 --- a/server/i18n/de.json +++ b/server/i18n/de.json @@ -17,7 +17,7 @@ "VIEWALL": "Alle Diagramme anzeigen", "BLOCKCHAIN_HEIGHT": "Blockchain Höhe", "LATEST_BLOCK": "Letzter Block", - "LATEST_BLOCK1": "Neueste Block-Schwierigkeit", + "LATEST_BLOCK1": "Aktuelle Schwierigkeit", "COIN_IN": "Münzen in Existenz", "HEIGHT": "Höhe", "HASH": "Hash", @@ -29,7 +29,8 @@ "INPUT" : "Eingang", "OUTPUTS" : "Ausgänge", "OUTPUT" : "Ausgabe", - "KERNELS" : "Kernel", + "KERNEL" : "Kernel", + "KERNELS" : "Kernels", "EPIC" : "Epic", "EXPLORE" : "Erkunden", "AGO" : "vor", diff --git a/server/i18n/en.json b/server/i18n/en.json index dfa128f..1ddb240 100644 --- a/server/i18n/en.json +++ b/server/i18n/en.json @@ -16,8 +16,8 @@ "EXPLORE_IT": "Explore", "VIEWALL": "View All Charts", "BLOCKCHAIN_HEIGHT": "Blockchain Height", - "LATEST_BLOCK": "Latest Blocks", - "LATEST_BLOCK1": "Latest Block Difficulty", + "LATEST_BLOCK": "Latest Block", + "LATEST_BLOCK1": "Current Difficulty", "COIN_IN": "Coins in Existence", "HEIGHT": "Height", "HASH": "Hash", @@ -29,6 +29,7 @@ "INPUT" : "Input", "OUTPUTS" : "Outputs", "OUTPUT" : "Output", + "KERNEL" : "Kernel", "KERNELS" : "Kernels", "EPIC" : "Epic", "EXPLORE" : "Explore", diff --git a/src/app/shared/components/header/header.component.html b/src/app/shared/components/header/header.component.html index 8c0c790..b2d3515 100755 --- a/src/app/shared/components/header/header.component.html +++ b/src/app/shared/components/header/header.component.html @@ -2,7 +2,19 @@