Commit beb1120f authored by Kevin Neaton's avatar Kevin Neaton

Display viewed directory's size

parent 269b1d03
This diff is collapsed.
......@@ -13,6 +13,7 @@ const templateFile = "../dir-index.html"
// Copied from go-ipfs/core/corehttp/gateway_indexPage.go
type listingTemplateData struct {
Listing []directoryItem
Size string
Path string
BackLink string
Hash string
......@@ -34,6 +35,7 @@ var testData = listingTemplateData{
Name: "this-piece-of-papers-got-47-words-37-sentences-58-words-we-wanna-know.txt",
Path: "this-piece-of-papers-got-47-words-37-sentences-58-words-we-wanna-know.txt",
}},
Size: "25 MiB",
Path: "/ipfs/QmFooBarQXB2mzChmMeKY47C43LxUdg1NDJ5MWcKMKxDu7RgQm",
BackLink: "/..",
Hash: "QmFooBarQXB2mzChmMeKY47C43LxUdg1NDJ5MWcKMKxDu7RgQm",
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment