mirror of
https://github.com/filecoin-project/slate.git
synced 2024-11-27 10:52:41 +03:00
298 lines
8.9 KiB
JavaScript
298 lines
8.9 KiB
JavaScript
import * as Strings from "~/common/strings";
|
|
|
|
export const DEMO_TOOLTIP_TEXT =
|
|
"The reign of Marcus Aurelius was marked by military conflict.";
|
|
|
|
export const EXTERNAL_ADDRESSES = [
|
|
"bafy2bzaceauqgsxjgxurysrujxmushykl52cfzjqyfbrpfjmu2zh33sg5sois",
|
|
];
|
|
|
|
export const EXAMPLE_ADDRESSES = [
|
|
"bafy2bzacedispf4crg5oc3mlvkrzh5yk7kbvh7ebkv7o4a3fs7vdhcctr4rys",
|
|
"aaaa2bzacedispf4crg5oc3mlvkrzh5yk7kbvh7ebkv7o4a3fs7vdhccbbbrys",
|
|
"bbbb2bzacedispf4crg5oc3mlvkrzh5yk7kbvh7ebkv7o4a3fs7vdhccbbbrys",
|
|
];
|
|
|
|
export const EXAMPLE_FOLDERS = [
|
|
{
|
|
decorator: "FOLDER",
|
|
id: `folder-root`,
|
|
folderId: "folder-root",
|
|
icon: "FOLDER",
|
|
file: "Files",
|
|
name: "Files",
|
|
pageTitle: "for files",
|
|
date: Strings.toDate("2017-01-01 00:00:00 UTC"),
|
|
size: Strings.bytesToSize(20020220),
|
|
},
|
|
{
|
|
decorator: "FOLDER",
|
|
id: `folder-1`,
|
|
folderId: "folder-1",
|
|
icon: "FOLDER",
|
|
file: "oil_paintings_2020",
|
|
name: "oil_paintings_2020",
|
|
pageTitle: "for files",
|
|
date: Strings.toDate("2017-01-01 00:00:00 UTC"),
|
|
size: Strings.bytesToSize(20020220),
|
|
},
|
|
{
|
|
decorator: "FOLDER",
|
|
id: `folder-2`,
|
|
folderId: "folder-2",
|
|
icon: "FOLDER",
|
|
file: "oil_paintings_2021",
|
|
name: "oil_paintings_2021",
|
|
pageTitle: "for files",
|
|
date: Strings.toDate("2017-01-01 00:00:00 UTC"),
|
|
size: Strings.bytesToSize(0),
|
|
},
|
|
{
|
|
decorator: "FOLDER",
|
|
id: `folder-3`,
|
|
folderId: "folder-3",
|
|
icon: "FOLDER",
|
|
file: "oil_paintings_1993",
|
|
name: "oil_paintings_1993",
|
|
pageTitle: "for files",
|
|
date: Strings.toDate("2017-01-01 00:00:00 UTC"),
|
|
size: Strings.bytesToSize(0),
|
|
},
|
|
];
|
|
|
|
export const EXAMPLE_FILES = [
|
|
{
|
|
id: `file-1`,
|
|
icon: "PNG",
|
|
file: "test-image.jpg",
|
|
miner: "Example Miner A",
|
|
"deal-cid": "23Y7Yh4UquoXHLPFo2XbhXkhBvFoPwmQUSa92pxnxjQuPU",
|
|
date: Strings.toDate("2014-06-06 00:00:00 UTC"),
|
|
size: Strings.bytesToSize(66666, 3),
|
|
amount: Strings.formatAsFilecoin(2),
|
|
remaining: Strings.getRemainingTime(666666),
|
|
cid: "QmY7Yh4UquoXHLPFo2XbhXkhBvFoPwmQUSa92pxnxjQuPU",
|
|
"retrieval-status": 6,
|
|
errors: 4,
|
|
},
|
|
{
|
|
id: `file-2`,
|
|
icon: "PNG",
|
|
file: "test-image-2.jpg",
|
|
miner: "Example Miner A",
|
|
"deal-cid": "ABCDYh4UquoXHLPFo2XbhXkhBvFoPwmQUSa92pxnxjQuPU",
|
|
date: Strings.toDate("2014-06-07 00:00:00 UTC"),
|
|
size: Strings.bytesToSize(77777, 3),
|
|
amount: Strings.formatAsFilecoin(2.04),
|
|
remaining: Strings.getRemainingTime(777777),
|
|
cid: "w2w2Yh4UquoXHLPFo2XbhXkhBvFoPwmQUSa92pxnxjQuPU",
|
|
"retrieval-status": 6,
|
|
errors: 0,
|
|
},
|
|
{
|
|
id: `file-3`,
|
|
icon: "PNG",
|
|
file: "test-image-3.jpg",
|
|
miner: "Example Miner B",
|
|
"deal-cid": "FHJKYh4UquoXHLPFo2XbhXkhBvFoPwmQUSa92pxnxjQuPU",
|
|
date: Strings.toDate("2014-06-08 00:00:00 UTC"),
|
|
size: Strings.bytesToSize(88888, 3),
|
|
amount: Strings.formatAsFilecoin(2.08),
|
|
remaining: Strings.getRemainingTime(888888),
|
|
cid: "0707Yh4UquoXHLPFo2XbhXkhBvFoPwmQUSa92pxnxjQuPU",
|
|
"retrieval-status": 6,
|
|
errors: 0,
|
|
},
|
|
{
|
|
id: `file-4`,
|
|
icon: "PNG",
|
|
file: "test-image-4.jpg",
|
|
miner: "Example Miner C",
|
|
"deal-cid": "KKKKYh4UquoXHLPFo2XbhXkhBvFoPwmQUSa92pxnxjQuPU",
|
|
date: Strings.toDate("2014-06-09 00:00:00 UTC"),
|
|
size: Strings.bytesToSize(9999999, 3),
|
|
amount: Strings.formatAsFilecoin(4.08),
|
|
remaining: Strings.getRemainingTime(999999),
|
|
cid: "1010Yh4UquoXHLPFo2XbhXkhBvFoPwmQUSa92pxnxjQuPU",
|
|
"retrieval-status": 6,
|
|
errors: 0,
|
|
},
|
|
{
|
|
id: `file-5`,
|
|
icon: "PNG",
|
|
file: "test-image-5.jpg",
|
|
miner: "Example Miner D",
|
|
"deal-cid": "WWWWWWWUquoXHLPFo2XbhXkhBvFoPwmQUSa92pxnxjQuPU",
|
|
date: Strings.toDate("2014-06-10 00:00:00 UTC"),
|
|
size: Strings.bytesToSize(4444444, 3),
|
|
amount: Strings.formatAsFilecoin(5.13),
|
|
remaining: Strings.getRemainingTime(797979),
|
|
cid: "1414Yh4UquoXHLPFo2XbhXkhBvFoPwmQUSa92pxnxjQuPU",
|
|
"retrieval-status": 6,
|
|
errors: 0,
|
|
},
|
|
{
|
|
id: `file-6`,
|
|
icon: "PNG",
|
|
file: "test-image-6.jpg",
|
|
miner: "Example Miner D",
|
|
"deal-cid": "XXXXUquoXHLPFo2XbhXkhBvFoPwmQUSa92pxnxjQuPU",
|
|
date: Strings.toDate("2014-06-11 00:00:00 UTC"),
|
|
size: Strings.bytesToSize(373737, 3),
|
|
amount: Strings.formatAsFilecoin(12.13),
|
|
remaining: Strings.getRemainingTime(828282),
|
|
cid: "3030Yh4UquoXHLPFo2XbhXkhBvFoPwmQUSa92pxnxjQuPU",
|
|
"retrieval-status": 6,
|
|
errors: 0,
|
|
},
|
|
{
|
|
id: `file-7`,
|
|
icon: "PNG",
|
|
file: "test-image-7.jpg",
|
|
miner: "Example Miner E",
|
|
"deal-cid": "HGHGHGXHLPFo2XbhXkhBvFoPwmQUSa92pxnxjQuPU",
|
|
date: Strings.toDate("2014-06-12 00:00:00 UTC"),
|
|
size: Strings.bytesToSize(373737, 3),
|
|
amount: Strings.formatAsFilecoin(12.13),
|
|
remaining: Strings.getRemainingTime(828282),
|
|
cid: "3030Yh4UquoXHLPFo2XbhXkhBvFoPwmQUSa92pxnxjQuPU",
|
|
"retrieval-status": 6,
|
|
errors: 1,
|
|
},
|
|
{
|
|
id: `file-8`,
|
|
icon: "PNG",
|
|
file: "example-painting-a-1.jpg",
|
|
miner: "Example Miner F",
|
|
"deal-cid": "12CCCCCLPFo2XbhXkhBvFoPwmQUSa92pxnxjQuPU",
|
|
date: Strings.toDate("2014-06-12 00:00:00 UTC"),
|
|
size: Strings.bytesToSize(444444, 3),
|
|
amount: Strings.formatAsFilecoin(2.13),
|
|
remaining: Strings.getRemainingTime(8282822),
|
|
cid: "asdfadsfPFo2XbhXkhBvFoPwmQUSa92pxnxjQuPU",
|
|
"retrieval-status": 6,
|
|
errors: 0,
|
|
},
|
|
{
|
|
id: `file-9`,
|
|
icon: "PNG",
|
|
file: "example-painting-a-2.jpg",
|
|
miner: "Example Miner F",
|
|
"deal-cid": "CGFDFASXbhXkhBvFoPwmQUSa92pxnxjQuPU",
|
|
date: Strings.toDate("2014-06-12 00:00:00 UTC"),
|
|
size: Strings.bytesToSize(44432, 3),
|
|
amount: Strings.formatAsFilecoin(20.13),
|
|
remaining: Strings.getRemainingTime(182822822),
|
|
cid: "asdfadsfPFo2XbhXkhBvFoPwmQUSa92pxnxjQuPU",
|
|
"retrieval-status": 6,
|
|
errors: 0,
|
|
},
|
|
{
|
|
id: `file-10`,
|
|
icon: "PNG",
|
|
file: "example-painting-a-3.jpg",
|
|
miner: "Example Miner F",
|
|
"deal-cid": "HHFGFDDFGvFoPwmQUSa92pxnxjQuPU",
|
|
date: Strings.toDate("2014-07-20 00:00:00 UTC"),
|
|
size: Strings.bytesToSize(44432, 3),
|
|
amount: Strings.formatAsFilecoin(20.13),
|
|
remaining: Strings.getRemainingTime(7432123),
|
|
cid: "asdfadsfPFo2XbhXkhBvFoPwmQUSa92pxnxjQuPU",
|
|
"retrieval-status": 6,
|
|
errors: 0,
|
|
},
|
|
{
|
|
id: `file-11`,
|
|
icon: "PNG",
|
|
file: "example-painting-a-4.jpg",
|
|
miner: "Example Miner F",
|
|
"deal-cid": "HHFGFDDFGvFoPwmQUSa92pxnxjQuPU",
|
|
date: Strings.toDate("2014-07-20 00:00:00 UTC"),
|
|
size: Strings.bytesToSize(44432, 3),
|
|
amount: Strings.formatAsFilecoin(20.13),
|
|
remaining: Strings.getRemainingTime(742988),
|
|
cid: "ppdmdfeFo2XbhXkhBvFoPwmQUSa92pxnxjQuPU",
|
|
"retrieval-status": 6,
|
|
errors: 0,
|
|
},
|
|
{
|
|
id: `file-12`,
|
|
icon: "PNG",
|
|
file: "example-painting-a-5.jpg",
|
|
miner: "Example Miner F",
|
|
"deal-cid": "GHREREFGvFoPwmQUSa92pxnxjQuPU",
|
|
date: Strings.toDate("2014-07-24 00:00:00 UTC"),
|
|
size: Strings.bytesToSize(44432, 3),
|
|
amount: Strings.formatAsFilecoin(20.13),
|
|
remaining: Strings.getRemainingTime(320021),
|
|
cid: "dfsffdbPFo2XbhXkhBvFoPwmQUSa92pxnxjQuPU",
|
|
"retrieval-status": 6,
|
|
errors: 0,
|
|
},
|
|
{
|
|
id: `file-13`,
|
|
icon: "PNG",
|
|
file: "pending-file-1.jpg",
|
|
miner: "Example Miner G",
|
|
"deal-cid": "13REREFGvFoPwmQUSa92pxnxjQuPU",
|
|
date: Strings.toDate("2014-07-24 00:00:00 UTC"),
|
|
size: Strings.bytesToSize(44432, 3),
|
|
amount: Strings.formatAsFilecoin(20.13),
|
|
remaining: null,
|
|
cid: "13sffdbPFo2XbhXkhBvFoPwmQUSa92pxnxjQuPU",
|
|
"retrieval-status": 1,
|
|
},
|
|
{
|
|
id: `file-14`,
|
|
icon: "PNG",
|
|
file: "pending-file-2.jpg",
|
|
miner: "Example Miner G",
|
|
"deal-cid": "14REREFGvFoPwmQUSa92pxnxjQuPU",
|
|
date: Strings.toDate("2014-07-24 00:00:00 UTC"),
|
|
size: Strings.bytesToSize(44432, 3),
|
|
amount: Strings.formatAsFilecoin(20.13),
|
|
remaining: null,
|
|
cid: "14sffdbPFo2XbhXkhBvFoPwmQUSa92pxnxjQuPU",
|
|
"retrieval-status": 2,
|
|
},
|
|
{
|
|
id: `file-15`,
|
|
icon: "PNG",
|
|
file: "pending-file-3.jpg",
|
|
miner: "Example Miner H",
|
|
"deal-cid": "15REREFGvFoPwmQUSa92pxnxjQuPU",
|
|
date: Strings.toDate("2014-07-24 00:00:00 UTC"),
|
|
size: Strings.bytesToSize(44432, 3),
|
|
amount: Strings.formatAsFilecoin(20.13),
|
|
remaining: null,
|
|
cid: "15sffdbPFo2XbhXkhBvFoPwmQUSa92pxnxjQuPU",
|
|
"retrieval-status": 3,
|
|
},
|
|
{
|
|
id: `file-16`,
|
|
icon: "PNG",
|
|
file: "pending-file-4.jpg",
|
|
miner: "Example Miner I",
|
|
"deal-cid": "16REREFGvFoPwmQUSa92pxnxjQuPU",
|
|
date: Strings.toDate("2014-07-24 00:00:00 UTC"),
|
|
size: Strings.bytesToSize(44432, 3),
|
|
amount: Strings.formatAsFilecoin(20.13),
|
|
remaining: null,
|
|
cid: "16sffdbPFo2XbhXkhBvFoPwmQUSa92pxnxjQuPU",
|
|
"retrieval-status": 4,
|
|
},
|
|
{
|
|
id: `file-17`,
|
|
icon: "PNG",
|
|
file: "pending-file-5.jpg",
|
|
miner: "Example Miner J",
|
|
"deal-cid": "17REREFGvFoPwmQUSa92pxnxjQuPU",
|
|
date: Strings.toDate("2014-07-24 00:00:00 UTC"),
|
|
size: Strings.bytesToSize(44432, 3),
|
|
amount: Strings.formatAsFilecoin(20.13),
|
|
remaining: null,
|
|
cid: "17sffdbPFo2XbhXkhBvFoPwmQUSa92pxnxjQuPU",
|
|
"retrieval-status": 5,
|
|
},
|
|
];
|