mirror of
https://github.com/chanzuckerberg/cellxgene.git
synced 2026-09-30 15:58:12 +08:00
Prettier
This commit is contained in:
+138
-36
@@ -1,5 +1,13 @@
|
||||
// jshint esversion: 6
|
||||
/* these will be either (preferably) specified or inferred */
|
||||
export const categories = ["Sample.type", "Selection", "Location", "Sample.name", "Class", "Neoplastic"];
|
||||
export const categories = [
|
||||
"Sample.type",
|
||||
"Selection",
|
||||
"Location",
|
||||
"Sample.name",
|
||||
"Class",
|
||||
"Neoplastic"
|
||||
];
|
||||
export const continuous = [
|
||||
"Total_reads",
|
||||
"Unique_reads",
|
||||
@@ -18,7 +26,7 @@ export const continuous = [
|
||||
"Unmapped_mismatch",
|
||||
"Unmapped_other",
|
||||
"Unmapped_short"
|
||||
]
|
||||
];
|
||||
|
||||
/* colors */
|
||||
export const blue = "#4a90e2";
|
||||
@@ -44,55 +52,149 @@ export let API = {
|
||||
// prefix: "http://pbmc33k.cxg.czi.technology/api/",
|
||||
|
||||
// prefix: "http://api-staging.clustering.czi.technology/api/",
|
||||
version: "v0.1/",
|
||||
}
|
||||
version: "v0.1/"
|
||||
};
|
||||
|
||||
if (window.CELLXGENE && window.CELLXGENE.API) API = window.CELLXGENE.API;
|
||||
|
||||
export let datasetTitle = "";
|
||||
|
||||
if (window.CELLXGENE && window.CELLXGENE.datasetTitle) datasetTitle = window.CELLXGENE.datasetTitle;
|
||||
if (window.CELLXGENE && window.CELLXGENE.datasetTitle)
|
||||
datasetTitle = window.CELLXGENE.datasetTitle;
|
||||
|
||||
export const accentFont = "Georgia,Times,Times New Roman,serif";
|
||||
export const maxParagraphWidth = 600;
|
||||
export const maxControlsWidth = 800;
|
||||
|
||||
export const graphMargin = {top: 20, right: 10, bottom: 30, left: 40};
|
||||
export const graphMargin = { top: 20, right: 10, bottom: 30, left: 40 };
|
||||
// export const graphWidth = 1440 /* window width */ - 410 /* sidebar */ - (15 + 15) /* left right padding */ /* but responsive */;
|
||||
// export const graphHeight = 500;
|
||||
export const graphWidth = 960;
|
||||
export const graphHeight = 960;
|
||||
|
||||
export const graphXScale = d3.scaleLinear()
|
||||
.domain([0, 1]) /* while this is the default for d3, our data is normalized so better to be explicit */
|
||||
.range([
|
||||
0 + graphMargin.left,
|
||||
graphWidth - graphMargin.right
|
||||
]);
|
||||
|
||||
export const graphYScale = d3.scaleLinear()
|
||||
.domain([0, 1]) /* while this is the default for d3, our data is normalized so better to be explicit */
|
||||
.range([
|
||||
graphHeight - graphMargin.bottom,
|
||||
0 + graphMargin.top
|
||||
]);
|
||||
export const graphXScale = d3
|
||||
.scaleLinear()
|
||||
.domain([
|
||||
0,
|
||||
1
|
||||
]) /* while this is the default for d3, our data is normalized so better to be explicit */
|
||||
.range([0 + graphMargin.left, graphWidth - graphMargin.right]);
|
||||
|
||||
export const graphYScale = d3
|
||||
.scaleLinear()
|
||||
.domain([
|
||||
0,
|
||||
1
|
||||
]) /* while this is the default for d3, our data is normalized so better to be explicit */
|
||||
.range([graphHeight - graphMargin.bottom, 0 + graphMargin.top]);
|
||||
|
||||
export const ordinalColors = [
|
||||
'#0ac115', '#c10ab6', '#c1710a', '#0a5ac1', '#c1150a', '#0ab6c1', '#5ac10a',
|
||||
'#710ac1', '#0ac171', '#c10a5a', '#b6c10a', '#150ac1', '#b2ffb7', '#ffb2fa',
|
||||
'#ffddb2', '#b2d4ff', '#ffb7b2', '#b2faff', '#d4ffb2', '#ddb2ff', '#b2ffdd',
|
||||
'#ffb2d4', '#faffb2', '#b7b2ff', '#27a908', '#8b08a9', '#a93a08', '#0877a9',
|
||||
'#a90827', '#08a98b', '#77a908', '#3a08a9', '#08a93a', '#a90877', '#a98b08',
|
||||
'#0827a9', '#00ff0f', '#ff00ef', '#ff8e00', '#0070ff', '#ff0f00', '#00efff',
|
||||
'#70ff00', '#8e00ff', '#00ff8e', '#ff0070', '#efff00', '#0f00ff', '#006606',
|
||||
'#66005f', '#663900', '#002c66', '#660600', '#005f66', '#2c6600', '#390066',
|
||||
'#006639', '#66002c', '#5f6600', '#060066', '#83ff65', '#e165ff', '#ff9565',
|
||||
'#65cfff', '#ff6583', '#65ffe1', '#cfff65', '#9565ff', '#65ff95', '#ff65cf',
|
||||
'#ffe165', '#6583ff', '#009909', '#99008f', '#995500', '#004399', '#990900',
|
||||
'#008f99', '#439900', '#550099', '#009955', '#990043', '#8f9900', '#090099',
|
||||
'#d9fecc', '#f1ccfe', '#fed7cc', '#ccf3fe', '#feccd9', '#ccfef1', '#f3fecc',
|
||||
'#d7ccfe', '#ccfed7', '#feccf3', '#fef1cc', '#ccd9fe', '#47ea51', '#ea47e0',
|
||||
'#eaa247', '#478fea', '#ea5147', '#47e0ea', '#8fea47', '#a247ea', '#47eaa2',
|
||||
'#ea478f', '#e0ea47', '#5147ea'
|
||||
]
|
||||
"#0ac115",
|
||||
"#c10ab6",
|
||||
"#c1710a",
|
||||
"#0a5ac1",
|
||||
"#c1150a",
|
||||
"#0ab6c1",
|
||||
"#5ac10a",
|
||||
"#710ac1",
|
||||
"#0ac171",
|
||||
"#c10a5a",
|
||||
"#b6c10a",
|
||||
"#150ac1",
|
||||
"#b2ffb7",
|
||||
"#ffb2fa",
|
||||
"#ffddb2",
|
||||
"#b2d4ff",
|
||||
"#ffb7b2",
|
||||
"#b2faff",
|
||||
"#d4ffb2",
|
||||
"#ddb2ff",
|
||||
"#b2ffdd",
|
||||
"#ffb2d4",
|
||||
"#faffb2",
|
||||
"#b7b2ff",
|
||||
"#27a908",
|
||||
"#8b08a9",
|
||||
"#a93a08",
|
||||
"#0877a9",
|
||||
"#a90827",
|
||||
"#08a98b",
|
||||
"#77a908",
|
||||
"#3a08a9",
|
||||
"#08a93a",
|
||||
"#a90877",
|
||||
"#a98b08",
|
||||
"#0827a9",
|
||||
"#00ff0f",
|
||||
"#ff00ef",
|
||||
"#ff8e00",
|
||||
"#0070ff",
|
||||
"#ff0f00",
|
||||
"#00efff",
|
||||
"#70ff00",
|
||||
"#8e00ff",
|
||||
"#00ff8e",
|
||||
"#ff0070",
|
||||
"#efff00",
|
||||
"#0f00ff",
|
||||
"#006606",
|
||||
"#66005f",
|
||||
"#663900",
|
||||
"#002c66",
|
||||
"#660600",
|
||||
"#005f66",
|
||||
"#2c6600",
|
||||
"#390066",
|
||||
"#006639",
|
||||
"#66002c",
|
||||
"#5f6600",
|
||||
"#060066",
|
||||
"#83ff65",
|
||||
"#e165ff",
|
||||
"#ff9565",
|
||||
"#65cfff",
|
||||
"#ff6583",
|
||||
"#65ffe1",
|
||||
"#cfff65",
|
||||
"#9565ff",
|
||||
"#65ff95",
|
||||
"#ff65cf",
|
||||
"#ffe165",
|
||||
"#6583ff",
|
||||
"#009909",
|
||||
"#99008f",
|
||||
"#995500",
|
||||
"#004399",
|
||||
"#990900",
|
||||
"#008f99",
|
||||
"#439900",
|
||||
"#550099",
|
||||
"#009955",
|
||||
"#990043",
|
||||
"#8f9900",
|
||||
"#090099",
|
||||
"#d9fecc",
|
||||
"#f1ccfe",
|
||||
"#fed7cc",
|
||||
"#ccf3fe",
|
||||
"#feccd9",
|
||||
"#ccfef1",
|
||||
"#f3fecc",
|
||||
"#d7ccfe",
|
||||
"#ccfed7",
|
||||
"#feccf3",
|
||||
"#fef1cc",
|
||||
"#ccd9fe",
|
||||
"#47ea51",
|
||||
"#ea47e0",
|
||||
"#eaa247",
|
||||
"#478fea",
|
||||
"#ea5147",
|
||||
"#47e0ea",
|
||||
"#8fea47",
|
||||
"#a247ea",
|
||||
"#47eaa2",
|
||||
"#ea478f",
|
||||
"#e0ea47",
|
||||
"#5147ea"
|
||||
];
|
||||
|
||||
Reference in New Issue
Block a user