diff --git a/browser/app/js/browser/StorageInfo.js b/browser/app/js/browser/StorageInfo.js
index 0532fb4d7..6bcd958ed 100644
--- a/browser/app/js/browser/StorageInfo.js
+++ b/browser/app/js/browser/StorageInfo.js
@@ -25,19 +25,18 @@ export class StorageInfo extends React.Component {
fetchStorageInfo()
}
render() {
- const { total, free } = this.props.storageInfo
- const used = total - free
+ const { total, used } = this.props.storageInfo
const usedPercent = used / total * 100 + "%"
- const freePercent = free * 100 / total
+ const freePercent = (total - used) * 100 / total
return (
-
+
-
Used:
- {humanize.filesize(total - free)}
+ {humanize.filesize(used)}
-
Free:
diff --git a/browser/app/js/browser/__tests__/StorageInfo.test.js b/browser/app/js/browser/__tests__/StorageInfo.test.js
index 6cf1ccbf4..4b1e857c9 100644
--- a/browser/app/js/browser/__tests__/StorageInfo.test.js
+++ b/browser/app/js/browser/__tests__/StorageInfo.test.js
@@ -22,7 +22,7 @@ describe("StorageInfo", () => {
it("should render without crashing", () => {
shallow(
)
@@ -32,7 +32,7 @@ describe("StorageInfo", () => {
const fetchStorageInfo = jest.fn()
shallow(
)
diff --git a/browser/app/js/browser/__tests__/actions.test.js b/browser/app/js/browser/__tests__/actions.test.js
index 012d7031f..d02174fc9 100644
--- a/browser/app/js/browser/__tests__/actions.test.js
+++ b/browser/app/js/browser/__tests__/actions.test.js
@@ -20,7 +20,7 @@ import * as actionsCommon from "../actions"
jest.mock("../../web", () => ({
StorageInfo: jest.fn(() => {
- return Promise.resolve({ storageInfo: { Total: 100, Free: 60 } })
+ return Promise.resolve({ storageInfo: { Total: 100, Used: 60 } })
}),
ServerInfo: jest.fn(() => {
return Promise.resolve({
@@ -40,7 +40,7 @@ describe("Common actions", () => {
it("creates common/SET_STORAGE_INFO after fetching the storage details ", () => {
const store = mockStore()
const expectedActions = [
- { type: "common/SET_STORAGE_INFO", storageInfo: { total: 100, free: 60 } }
+ { type: "common/SET_STORAGE_INFO", storageInfo: { total: 100, used: 60 } }
]
return store.dispatch(actionsCommon.fetchStorageInfo()).then(() => {
const actions = store.getActions()
diff --git a/browser/app/js/browser/actions.js b/browser/app/js/browser/actions.js
index f82d03b4f..390ddc85b 100644
--- a/browser/app/js/browser/actions.js
+++ b/browser/app/js/browser/actions.js
@@ -34,7 +34,7 @@ export const fetchStorageInfo = () => {
return web.StorageInfo().then(res => {
const storageInfo = {
total: res.storageInfo.Total,
- free: res.storageInfo.Free
+ used: res.storageInfo.Used
}
dispatch(setStorageInfo(storageInfo))
})
diff --git a/browser/app/less/inc/header.less b/browser/app/less/inc/header.less
index 436fc4e41..4fce95887 100644
--- a/browser/app/less/inc/header.less
+++ b/browser/app/less/inc/header.less
@@ -44,9 +44,9 @@
/*--------------------------
- Disk usage
+ Disk used
----------------------------*/
-.feh-usage {
+.feh-used {
margin-top: 12px;
max-width: 285px;
diff --git a/browser/ui-assets.go b/browser/ui-assets.go
index 9b34a2538..e5e538ccc 100644
--- a/browser/ui-assets.go
+++ b/browser/ui-assets.go
@@ -4,7 +4,7 @@
// production/favicon.ico
// production/firefox.png
// production/index.html
-// production/index_bundle-2018-04-16T18-35-51Z.js
+// production/index_bundle-2018-05-23T09-12-50Z.js
// production/loader.css
// production/logo.svg
// production/safari.png
@@ -65,7 +65,7 @@ func productionChromePng() (*asset, error) {
return nil, err
}
- info := bindataFileInfo{name: "production/chrome.png", size: 3726, mode: os.FileMode(420), modTime: time.Unix(1523903781, 0)}
+ info := bindataFileInfo{name: "production/chrome.png", size: 3726, mode: os.FileMode(436), modTime: time.Unix(1527066786, 0)}
a := &asset{bytes: bytes, info: info}
return a, nil
}
@@ -82,7 +82,7 @@ func productionFaviconIco() (*asset, error) {
return nil, err
}
- info := bindataFileInfo{name: "production/favicon.ico", size: 501, mode: os.FileMode(420), modTime: time.Unix(1523903781, 0)}
+ info := bindataFileInfo{name: "production/favicon.ico", size: 501, mode: os.FileMode(436), modTime: time.Unix(1527066786, 0)}
a := &asset{bytes: bytes, info: info}
return a, nil
}
@@ -99,7 +99,7 @@ func productionFirefoxPng() (*asset, error) {
return nil, err
}
- info := bindataFileInfo{name: "production/firefox.png", size: 4795, mode: os.FileMode(420), modTime: time.Unix(1523903781, 0)}
+ info := bindataFileInfo{name: "production/firefox.png", size: 4795, mode: os.FileMode(436), modTime: time.Unix(1527066786, 0)}
a := &asset{bytes: bytes, info: info}
return a, nil
}
@@ -156,8 +156,8 @@ var _productionIndexHTML = []byte(`
-
-
+
+