Skip to content
This repository was archived by the owner on Jul 31, 2019. It is now read-only.

Commit ba9a2ee

Browse files
committed
#2 Supported English display
1 parent 7a81dbf commit ba9a2ee

14 files changed

Lines changed: 549 additions & 473 deletions

File tree

README.ja.md

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ FlashAir™の無線LAN機能を使い、FlashAir IoT Hubを経由する事で
2222

2323
## Demo
2424

25-
![FlashAirFileManager Demo](https://github.com/FlashAirDevelopers/FlashAirFileManager/blob/master/img/doc/demo.gif)
25+
![FlashAirFileManager Demo](https://github.com/FlashAirDevelopers/FlashAirFileManager/blob/master/img/doc/demo_ja.gif)
2626

2727
## Install
2828

@@ -76,6 +76,19 @@ FlashAir™の無線LAN機能を使い、FlashAir IoT Hubを経由する事で
7676
- アプリ起動時に「読み込み中...」と表示し続ける。
7777
- メニューの リモート > ログアウト をクリックし、FlashAir IoT Hubに再ログインする事で解消する事があります。
7878

79+
## Changelog
80+
81+
- [0.3.0](https://github.com/FlashAirDevelopers/FlashAirFileManager/releases/tag/v0.3.0)
82+
- 英語表示に対応しました。`メニュー > 言語`から言語を切り替え可能です。(日本語 / 英語)
83+
- [0.2.1](https://github.com/FlashAirDevelopers/FlashAirFileManager/releases/tag/v0.2.1)
84+
- 起動に失敗する問題を修正しました。
85+
- [0.2.0](https://github.com/FlashAirDevelopers/FlashAirFileManager/releases/tag/v0.2.0)
86+
- [FlashAir IoT Hub](https://iot-hub.flashair-developers.com)が提供するLuaスクリプトを使う様に変更。
87+
- [0.1.1](https://github.com/FlashAirDevelopers/FlashAirFileManager/releases/tag/v0.1.1)
88+
- ファイル一覧の取得に失敗する問題を修正しました。
89+
- [0.1.0](https://github.com/FlashAirDevelopers/FlashAirFileManager/releases/tag/v0.1.0)
90+
- 初回リリース。
91+
7992
## Licence
8093

8194
[Apache 2.0](https://github.com/FlashAirDevelopers/FlashAirFileManager/blob/master/LICENSE.txt)

README.md

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,9 +73,22 @@ Note: Since version 0.2.0, Lua scripts are using [FlashAir IoT Hub](https://iot-
7373
- `cd node_modules/keytar`
7474
- run `..\.bin\node-gyp rebuild --target=1.7.8 --arch=x64 --dist-url=https://atom.io/download/atom-shell`
7575
- Please specify the version number of Electron for `- target` and the parameter of your environment for `--arch = x64`.
76-
- Continue displaying "読み込み中...(in English "Loading")" at application startup.
76+
- Continue displaying "Loading" at application startup.
7777
- Click Remote> Logout on the menu. It may be solved by re-logging in to FlashAir IoT Hub.
7878

79+
## Changelog
80+
81+
- [0.3.0](https://github.com/FlashAirDevelopers/FlashAirFileManager/releases/tag/v0.3.0)
82+
- Supported English display. You can switch display languages from `Menu> Language`.
83+
- [0.2.1](https://github.com/FlashAirDevelopers/FlashAirFileManager/releases/tag/v0.2.1)
84+
- Fixed issue that fails to start.
85+
- [0.2.0](https://github.com/FlashAirDevelopers/FlashAirFileManager/releases/tag/v0.2.0)
86+
- Changed to use Lua script provided by [FlashAir IoT Hub](https://iot-hub.flashair-developers.com).
87+
- [0.1.1](https://github.com/FlashAirDevelopers/FlashAirFileManager/releases/tag/v0.1.1)
88+
- Fixed issue that failed to get file list.
89+
- [0.1.0](https://github.com/FlashAirDevelopers/FlashAirFileManager/releases/tag/v0.1.0)
90+
- The first release.
91+
7992
## Licence
8093

8194
[Apache 2.0](https://github.com/FlashAirDevelopers/FlashAirFileManager/blob/master/LICENSE.txt)

electron-builder.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"appId": "com.flashair-developers",
33
"productName": "FlashAirFileManger",
44
"asar": true,
5-
"electronVersion": "1.7.10",
5+
"electronVersion": "1.8.2",
66
"files": [
77
"static/**/*",
88
"node_modules/**/*",

img/doc/demo.gif

8.74 KB
Loading

img/doc/demo_ja.gif

195 KB
Loading

package.json

Lines changed: 18 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "flashair-file-manager",
3-
"version": "0.2.1",
3+
"version": "0.3.0",
44
"description": "The application to browse and download files on FlashAir™ via the network.",
55
"homepage": "https://github.com/FlashAirDevelopers/FlashAirFileManager",
66
"main": "./src/main/main.js",
@@ -24,37 +24,38 @@
2424
"author": "FlashAir Developers",
2525
"license": "Apache-2.0",
2626
"dependencies": {
27-
"@openid/appauth": "^0.3.0",
28-
"about-window": "^1.8.0",
27+
"@openid/appauth": "^0.3.1",
28+
"about-window": "^1.9.1",
2929
"bootstrap": "^3.3.7",
3030
"bootstrap-notify": "^3.1.3",
3131
"bootstrap-select": "^1.12.4",
32-
"electron-log": "^2.2.13",
32+
"electron-json-storage": "^4.0.2",
33+
"electron-log": "^2.2.14",
3334
"es6-promise": "^4.1.1",
3435
"handlebars": "^4.0.11",
3536
"isomorphic-fetch": "^2.2.1",
3637
"jquery": "^3.2.1",
37-
"js-base64": "^2.4.0",
38+
"js-base64": "^2.4.3",
3839
"jssha": "^2.3.1",
3940
"keytar": "^4.1.0",
40-
"source-map-support": "^0.5.0",
41+
"source-map-support": "^0.5.3",
4142
"spin.js": "^3.1.0"
4243
},
4344
"devDependencies": {
4445
"babel-core": "^6.26.0",
45-
"babel-eslint": "^8.0.1",
46+
"babel-eslint": "^8.2.1",
4647
"babel-loader": "^7.1.2",
47-
"babel-minify-webpack-plugin": "^0.2.0",
48+
"babel-minify-webpack-plugin": "^0.3.0",
4849
"babel-preset-es2015": "^6.24.1",
4950
"babel-runtime": "^6.26.0",
50-
"clean-webpack-plugin": "^0.1.17",
51-
"cross-env": "^5.1.1",
52-
"css-hot-loader": "^1.3.4",
53-
"css-loader": "^0.28.7",
54-
"electron": "^1.7.10",
55-
"electron-builder": "^19.49.0",
56-
"electron-webpack": "^1.11.0",
57-
"eslint": "^4.13.1",
51+
"clean-webpack-plugin": "^0.1.18",
52+
"cross-env": "^5.1.3",
53+
"css-hot-loader": "^1.3.6",
54+
"css-loader": "^0.28.9",
55+
"electron": "^1.8.2",
56+
"electron-builder": "^19.56.0",
57+
"electron-webpack": "^1.12.1",
58+
"eslint": "^4.17.0",
5859
"eslint-config-standard": "^10.2.1",
5960
"eslint-plugin-import": "^2.8.0",
6061
"eslint-plugin-node": "^5.2.1",
@@ -67,7 +68,7 @@
6768
"node-loader": "^0.6.0",
6869
"rcedit": "^0.9.0",
6970
"shebang-loader": "^0.0.1",
70-
"style-loader": "^0.19.1",
71+
"style-loader": "^0.20.1",
7172
"url-loader": "^0.6.2",
7273
"webpack": "^3.10.0"
7374
}

src/common/resources.js

Lines changed: 43 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* Copyright 2017 FlashAir Developers
2+
* Copyright 2017-2018 FlashAir Developers
33
*
44
* Licensed to the Apache Software Foundation (ASF) under one
55
* or more contributor license agreements. See the NOTICE file
@@ -20,20 +20,46 @@
2020
*/
2121

2222
export const resources = {
23-
common_window_title: 'FlashAir File Manager',
24-
menu_label_file: 'ファイル (F)',
25-
menu_label_file_close: '終了 (X)',
26-
menu_label_remote: 'リモート (L)',
27-
menu_label_remote_logout: 'ログアウト',
28-
menu_label_help: 'ヘルプ (H)',
29-
menu_label_help_about: 'FlashAir File Manager について',
30-
filer_label_local_file_name: '名前',
31-
filer_label_local_file_date: '更新日付',
32-
filer_label_remote_file_name: '名前',
33-
filer_label_remote_file_date: '更新日付',
34-
filer_msg_remote_download_progress: 'ダウンロード中...',
35-
filer_msg_remote_download_completed: 'ダウンロードが完了しました。',
36-
auth_msg_invalid_access_token: '認証処理が失敗しました。再度ログインし直してください。',
37-
common_msg_loading: '読み込み中...',
38-
common_msg_process_failure: '処理中にエラーが発生しました。'
23+
ja: {
24+
common_window_title: 'FlashAir File Manager',
25+
menu_label_file: 'ファイル',
26+
menu_label_file_close: '終了',
27+
menu_label_remote: 'リモート',
28+
menu_label_remote_logout: 'ログアウト',
29+
menu_label_locale_language: '言語',
30+
menu_label_locale_ja: '日本語',
31+
menu_label_locale_en: '英語',
32+
menu_label_help: 'ヘルプ',
33+
menu_label_help_about: 'FlashAir File Manager について',
34+
filer_label_local_file_name: '名前',
35+
filer_label_local_file_date: '更新日付',
36+
filer_label_remote_file_name: '名前',
37+
filer_label_remote_file_date: '更新日付',
38+
filer_msg_remote_download_progress: 'ダウンロード中...',
39+
filer_msg_remote_download_completed: 'ダウンロードが完了しました。',
40+
auth_msg_invalid_access_token: '認証処理が失敗しました。再度ログインし直してください。',
41+
common_msg_loading: '読み込み中...',
42+
common_msg_process_failure: '処理中にエラーが発生しました。'
43+
},
44+
'en-US': {
45+
common_window_title: 'FlashAir File Manager',
46+
menu_label_file: 'File',
47+
menu_label_file_close: 'Close',
48+
menu_label_remote: 'Remote',
49+
menu_label_remote_logout: 'Log out',
50+
menu_label_locale_language: 'Language',
51+
menu_label_locale_ja: 'Japanese',
52+
menu_label_locale_en: 'English',
53+
menu_label_help: 'Help',
54+
menu_label_help_about: 'About FlashAir File Manager',
55+
filer_label_local_file_name: 'Name',
56+
filer_label_local_file_date: 'Update date',
57+
filer_label_remote_file_name: 'Name',
58+
filer_label_remote_file_date: 'Update date',
59+
filer_msg_remote_download_progress: 'Downloading...',
60+
filer_msg_remote_download_completed: 'Download is completed.',
61+
auth_msg_invalid_access_token: 'Authentication processing failed. Please login again.',
62+
common_msg_loading: 'Loading...',
63+
common_msg_process_failure: 'An error occurred while processing.'
64+
}
3965
};

src/main/auth.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* Copyright 2017 FlashAir Developers
2+
* Copyright 2017-2018 FlashAir Developers
33
*
44
* Licensed to the Apache Software Foundation (ASF) under one
55
* or more contributor license agreements. See the NOTICE file
@@ -25,7 +25,7 @@ import {AuthorizationRequest} from '@openid/appauth/built/authorization_request'
2525
import {AuthorizationNotifier, AuthorizationRequestResponse, BUILT_IN_PARAMETERS} from '@openid/appauth/built/authorization_request_handler';
2626
import {AuthorizationResponse} from '@openid/appauth/built/authorization_response';
2727
import {AuthorizationServiceConfiguration} from '@openid/appauth/built/authorization_service_configuration';
28-
import {generateRandom} from '@openid/appauth/built/crypto_utils';
28+
import {cryptoGenerateRandom} from '@openid/appauth/built/crypto_utils';
2929
import {AppAuthError} from '@openid/appauth/built/errors';
3030
import {NodeBasedHandler} from '@openid/appauth/built/node_support/node_request_handler';
3131
import {NodeRequestor} from '@openid/appauth/built/node_support/node_requestor';
@@ -119,7 +119,7 @@ class CodePair {
119119
_makeCodeVerifier() {
120120
// minimum raw length 32
121121
// see: https://tools.ietf.org/html/rfc7636#section-4.1
122-
return Base64.encodeURI(generateRandom(32));
122+
return Base64.encodeURI(cryptoGenerateRandom(32));
123123
}
124124
// Base64url Encoding without Padding
125125
// see: https://tools.ietf.org/html/rfc7636#appendix-A
@@ -220,7 +220,7 @@ export class Auth {
220220
log.error('Unknown service configuration');
221221
return;
222222
}
223-
this.authState = generateRandom(10);
223+
this.authState = cryptoGenerateRandom(10);
224224
// extra prameter for OAuth PKCE code_challenge
225225
const extra = [];
226226
if (this.codePair) {

0 commit comments

Comments
 (0)