flipside-js/index.html

270 lines
6.3 KiB
HTML
Raw Permalink Normal View History

2018-11-30 21:53:43 +00:00
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<title>flipside.js</title>
<meta name="viewport" content="width=device-width, initial-scale=1" />
2020-09-30 21:25:50 +00:00
<script src="flipside-v1.16.1.js"></script>
2018-11-30 21:53:43 +00:00
<style>
body {
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji",
"Segoe UI Symbol";
padding: 0;
margin: 0;
background-color: #fff !important;
}
2019-02-23 00:00:07 +00:00
text {
font-weight: 700;
font-size: 24px;
}
2018-11-30 21:53:43 +00:00
.wrapper {
width: 1080px;
2020-08-14 01:40:35 +00:00
height: 800px;
2019-02-23 00:00:07 +00:00
font-weight: 700;
font-size: 20px;
2019-02-16 10:53:29 +00:00
}
2020-08-14 01:40:35 +00:00
.frameWidget {
width: 100%;
height: 100%;
}
2019-02-16 10:53:29 +00:00
.wrapper p {
font-size: 40px;
}
2019-01-18 15:20:32 +00:00
#widget-1 {
2019-01-17 07:13:37 +00:00
background: black;
}
2019-01-18 15:20:32 +00:00
#widget-2 {
width: 300px;
background: #33435e;
}
2018-11-30 21:53:43 +00:00
</style>
</head>
<body>
2020-08-14 01:40:35 +00:00
<div class="wrapper">
<h3>Frame</h3>
<div id="frame-widget" class="frameWidget"></div>
</div>
<div class="wrapper">
2020-04-14 17:42:44 +00:00
<h3>Dynamic</h3>
<div id="widget"></div>
</div>
2020-04-14 17:42:44 +00:00
<div class="wrapper">
<h2>Chart</h2>
<div id="chart"></div>
</div>
2020-09-30 21:25:50 +00:00
<div class="wrapper dark" style="background-color: #000000">
2019-03-01 07:04:45 +00:00
<div id="chart2"></div>
</div>
2019-02-16 10:53:29 +00:00
<div class="wrapper"><div id="score"></div></div>
2020-09-30 21:25:50 +00:00
<div class="wrapper"><div id="widget-0" style="width: 289px"></div></div>
2020-09-30 21:25:50 +00:00
<div class="wrapper" style="background-color: #000000">
<div id="widget-1" style="width: 289px"></div>
2019-01-28 22:23:52 +00:00
</div>
2020-09-30 21:25:50 +00:00
<div class="wrapper" style="background-color: #33435e">
2019-01-28 22:23:52 +00:00
<div id="widget-2"></div>
</div>
<div class="wrapper"><div id="multiTable"></div></div>
2019-03-12 14:42:02 +00:00
<div class="wrapper">
<div id="multiTableFcas"></div>
</div>
2018-11-30 21:53:43 +00:00
<script>
const flipside = new Flipside("a7936778-4f87-4790-889f-3ab617271458");
2020-02-26 18:29:21 +00:00
2020-08-14 01:40:35 +00:00
flipside.frame("frame-widget", {
url:
"https://velocity.flipsidecrypto.com/public/question/3964591d-a657-4432-b3e8-8675bfbfb714",
});
2020-02-26 18:29:21 +00:00
flipside.dynamic("widget", {
widgetId: "578375af-3467-4742-9863-5ca6f2fa30d1",
darkMode: false,
data: {
asset_id: 1,
},
});
flipside.dynamic("widget", {
widgetId: "26dd8193-b061-4ef5-a49d-b7bf3c282853",
darkMode: false,
data: {
asset_id: 1,
metric: "fcas",
2020-04-14 17:42:44 +00:00
symbol: "BTC",
title: "BTC FCAS",
2020-04-14 17:42:44 +00:00
},
2020-02-26 18:29:21 +00:00
});
flipside.chart("chart", {
2019-03-13 19:18:16 +00:00
title: "Flipside 25 - Overall Industry Health",
2019-03-15 18:40:53 +00:00
chart: {
2020-04-14 17:42:44 +00:00
type: "area",
2019-03-15 18:40:53 +00:00
},
plotOptions: {
area: {
threshold: null,
fillColor: {
linearGradient: {
x1: 0,
y1: 0,
x2: 0,
2020-04-14 17:42:44 +00:00
y2: 1,
2019-03-15 18:40:53 +00:00
},
2020-02-26 18:29:21 +00:00
stops: [
[0, "#9EC9FE"],
2020-04-14 17:42:44 +00:00
[1, "rgba(255, 255, 255, 0)"],
],
},
},
2019-03-15 18:40:53 +00:00
},
2019-02-16 10:53:29 +00:00
series: [
{
2019-03-13 19:18:16 +00:00
name: "FLIP25",
symbol: "FLIP25",
metric: "fcas",
type: "line",
2020-04-14 17:42:44 +00:00
yAxis: 1,
},
],
2019-03-15 18:40:53 +00:00
colors: ["#9EC9FE"],
rangeSelector: {
2020-04-14 17:42:44 +00:00
enabled: true,
},
2019-02-16 10:53:29 +00:00
});
flipside.chart("chart2", {
mode: "light",
title: "Ethereum Health",
2019-02-16 10:53:29 +00:00
axisTitles: ["FCAS", "Dev"],
colors: ["#E44C27", "#7FCCC5"],
series: [
{ asset_id: 2, metric: "fcas", type: "line", yAxis: 0 },
2020-04-14 17:42:44 +00:00
{ asset_id: 2, metric: "dev", type: "line", yAxis: 1 },
],
});
2019-01-29 16:25:59 +00:00
flipside.spectrum("widget-0", {
asset: {
asset_id: 1,
2020-04-14 17:42:44 +00:00
highlights: ["BTC", "ETH", "QTUM"],
},
2019-01-29 15:56:45 +00:00
mode: "light",
fontFamily: "inherit",
relatedMarkers: {
enabled: true,
bucketDistance: 35,
lineDistance: 25,
2020-04-14 17:42:44 +00:00
fontFamily: "inherit",
2019-01-29 15:56:45 +00:00
},
showHeader: false,
2019-01-29 15:56:45 +00:00
name: { enabled: true, style: {} },
spectrum: { enabled: true },
icon: { enabled: true },
rank: { enabled: true },
2020-04-14 17:42:44 +00:00
trend: { enabled: true },
2019-01-22 00:19:45 +00:00
});
2019-01-28 20:40:52 +00:00
2019-01-30 09:24:46 +00:00
flipside.spectrum("widget-1", {
assets: [
{
asset_id: 1,
2020-04-14 17:42:44 +00:00
highlights: ["BTC", "NMR", "QTUM"],
2019-01-30 09:24:46 +00:00
},
{
asset_id: 2,
2020-04-14 17:42:44 +00:00
highlights: ["BTC", "NMR", "QTUM"],
},
2019-01-30 09:24:46 +00:00
],
2019-01-28 20:40:52 +00:00
mode: "dark",
2019-01-22 00:19:08 +00:00
bucketDistance: 100,
showHeader: false,
relatedMarkers: {
2019-02-11 13:51:01 +00:00
bucketDistance: 55,
2020-04-14 17:42:44 +00:00
lineDistance: 35,
},
2018-12-23 06:55:10 +00:00
});
2019-01-28 20:40:52 +00:00
2019-01-18 15:20:32 +00:00
flipside.createTable("widget-2", "btc", {
dark: true,
2020-04-14 17:42:44 +00:00
borderColor: "#737e8d",
2019-01-18 15:20:32 +00:00
});
2019-03-12 14:09:00 +00:00
// Price table
flipside.multiTable("multiTable", {
2019-03-12 15:14:47 +00:00
widgetType: "price-multi-table",
2019-03-12 14:09:00 +00:00
columns: ["market_cap", "price", "volume_24h"],
sortBy: "market_cap",
showFullName: true,
2019-01-29 15:36:34 +00:00
fontFamily: "inherit",
2019-03-12 14:09:00 +00:00
limit: 50,
2019-01-29 15:36:34 +00:00
mode: "light",
headers: {
style: {
fontWeight: "bold",
2020-04-14 17:42:44 +00:00
padding: "10px 0 10px 0",
},
},
2019-01-29 15:36:34 +00:00
rows: {
2019-03-12 14:09:00 +00:00
dividers: true,
dividersColor: "#eaeaea",
alternating: false,
style: {
2020-04-14 17:42:44 +00:00
padding: "10px 0 10px 0",
},
2019-01-29 15:36:34 +00:00
},
title: {
2019-03-12 14:09:00 +00:00
text: "Top 50 Coins By Market Cap",
2020-04-14 17:42:44 +00:00
style: { fontSize: "24px", fontWeight: 400 },
},
});
2019-03-12 14:48:16 +00:00
// FCAS
2019-03-12 14:42:02 +00:00
flipside.multiTable("multiTableFcas", {
autoWidth: false,
assets: null,
columns: [
"fcas",
"trend",
"userActivity",
"developerBehavior",
"marketMaturity",
2020-04-14 17:42:44 +00:00
"rank",
2019-03-12 14:42:02 +00:00
],
exlusions: null,
2019-01-29 15:36:34 +00:00
fontFamily: "inherit",
headers: {},
2019-03-12 14:42:02 +00:00
limit: 10,
2019-01-29 15:36:34 +00:00
mode: "light",
rows: {
2019-03-12 14:42:02 +00:00
alternating: true,
alternatingColors: "#eeeeee",
2020-04-14 17:42:44 +00:00
dividers: false,
2019-01-29 15:36:34 +00:00
},
title: {
text: "Top Coins",
2020-04-14 17:42:44 +00:00
style: {},
2019-01-29 15:36:34 +00:00
},
trend: {
2019-03-12 14:42:02 +00:00
enabled: true,
2020-02-26 18:29:21 +00:00
changeOver: 14,
2020-04-14 17:42:44 +00:00
style: {},
},
});
flipside.score("score", { symbol: "eth" });
2018-11-30 21:53:43 +00:00
</script>
</body>
</html>