From def500fd79d5ddd36e890d0abfa35a210a028285 Mon Sep 17 00:00:00 2001 From: Falk Werner Date: Mon, 1 Apr 2019 22:06:22 +0200 Subject: [PATCH] fixes javascript style issues --- example/daemon/www/js/connection_view.js | 24 ++++++++++++------------ example/daemon/www/js/webfuse/client.js | 2 +- 2 files changed, 13 insertions(+), 13 deletions(-) diff --git a/example/daemon/www/js/connection_view.js b/example/daemon/www/js/connection_view.js index 6dde718..c46b584 100644 --- a/example/daemon/www/js/connection_view.js +++ b/example/daemon/www/js/connection_view.js @@ -6,51 +6,51 @@ export class ConnectionView { this.element = document.createElement("div"); - const a = document.createElement("div"); - this.element.appendChild(a); + const connectBox = document.createElement("div"); + this.element.appendChild(connectBox); const urlLabel = document.createElement("span"); urlLabel.textContent = "URL:"; - a.appendChild(urlLabel); + connectBox.appendChild(urlLabel); this.urlTextbox = document.createElement("input"); this.urlTextbox.type = "text"; this.urlTextbox.value = window.location.href.replace(/^http/, "ws"); - a.appendChild(this.urlTextbox); + connectBox.appendChild(this.urlTextbox); this.connectButton = document.createElement("input"); this.connectButton.type = "button"; this.connectButton.value = "connect"; this.connectButton.addEventListener("click", () => { this._onConnectButtonClicked(); }); - a.appendChild(this.connectButton); + connectBox.appendChild(this.connectButton); - const b = document.createElement("div"); - this.element.appendChild(b); + const authenticateBox = document.createElement("div"); + this.element.appendChild(authenticateBox); const usernameLabel = document.createElement("span"); usernameLabel.textContent = "user:"; - b.appendChild(usernameLabel); + authenticateBox.appendChild(usernameLabel); this.usernameTextbox = document.createElement("input"); this.usernameTextbox.type = "text"; this.usernameTextbox.value = "bob"; - b.appendChild(this.usernameTextbox); + authenticateBox.appendChild(this.usernameTextbox); const passwordLabel = document.createElement("span"); passwordLabel.textContent = "user:"; - b.appendChild(passwordLabel); + authenticateBox.appendChild(passwordLabel); this.passwordTextbox = document.createElement("input"); this.passwordTextbox.type = "password"; this.passwordTextbox.value = "secret"; - b.appendChild(this.passwordTextbox); + authenticateBox.appendChild(this.passwordTextbox); this.authenticateButton = document.createElement("input"); this.authenticateButton.type = "button"; this.authenticateButton.value = "authenticate"; this.authenticateButton.addEventListener("click", () => { this._onAuthenticateButtonClicked(); }); - b.appendChild(this.authenticateButton); + authenticateBox.appendChild(this.authenticateButton); } _onConnectButtonClicked() { diff --git a/example/daemon/www/js/webfuse/client.js b/example/daemon/www/js/webfuse/client.js index 40724b0..2838732 100644 --- a/example/daemon/www/js/webfuse/client.js +++ b/example/daemon/www/js/webfuse/client.js @@ -24,7 +24,7 @@ export class Client { }; } - authenticate(type ,credentials) { + authenticate(type, credentials) { const request = { "method": "authenticate", "params": [type, credentials],