Skip to content

Commit

Permalink
#464 More Tool configs
Browse files Browse the repository at this point in the history
  • Loading branch information
tariqksoliman committed May 7, 2024
1 parent 6f1a3d1 commit cbc1691
Show file tree
Hide file tree
Showing 10 changed files with 260 additions and 9 deletions.
2 changes: 1 addition & 1 deletion configure/public/toolConfigs.json

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,9 @@ const useStyles = makeStyles((theme) => ({
},
contents: {
height: "100%",
width: "calc(100% - 350px)",
maxWidth: "1400px !important",
width: "100%",
maxWidth: "1500px !important",
maxHeight: "calc(100% - 32px) !important",
},
heading: {
height: theme.headHeights[2],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,9 @@ const useStyles = makeStyles((theme) => ({
},
contents: {
height: "100%",
width: "calc(100% - 350px)",
maxWidth: "1400px !important",
width: "100%",
maxWidth: "1500px !important",
maxHeight: "calc(100% - 32px) !important",
},
heading: {
height: theme.headHeights[2],
Expand Down
7 changes: 5 additions & 2 deletions configure/src/core/Maker.js
Original file line number Diff line number Diff line change
Expand Up @@ -94,12 +94,15 @@ const useStyles = makeStyles((theme) => ({
},
objectArrayBox: {
display: "flex",
margin: "0px 10px",
margin: "0px 10px 10px 10px",
background: theme.palette.swatches.grey[1000],
padding: "10px",
boxShadow: "0px 2px 2px 0px rgba(0, 0, 0, 0.1)",
},
object: {
border: `2px solid ${theme.palette.swatches.grey[900]}`,
borderLeft: `2px solid ${theme.palette.swatches.grey[200]}`,
background: theme.palette.swatches.grey[950],
background: theme.palette.swatches.grey[850],
},
map: {},
noMargin: {
Expand Down
1 change: 1 addition & 0 deletions configure/src/themes/light.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ export const palette = {
600: "#949a9e",
700: "#b4b8bb",
800: "#d4d6d8",
850: "#efefef",
900: "#f4f5f5",
950: "#fafafa",
1000: "#FFFFFF",
Expand Down
63 changes: 63 additions & 0 deletions src/essence/Tools/Identifier/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,5 +18,68 @@
"name": "Identifier",
"paths": {
"IdentifierTool": "essence/Tools/Identifier/IdentifierTool"
},
"config": {
"rows": [
{
"components": [
{
"field": "variables.layers",
"name": "Layers",
"description": "Only show DEM if associated layer is on.",
"type": "objectarray",
"width": 12,
"object": [
{
"field": "name",
"name": "Layer Name or UUID",
"description": "",
"type": "text",
"width": 4
},
{
"field": "url",
"name": "URL to .tif",
"description": "This can be a relative path to a file under the Mission name or a full url path. The former is preferred is the file is large. Can use '{starttime}' and '{endtime}' if the layer is time enabled.",
"type": "text",
"width": 8
},
{
"field": "bands",
"name": "Bands",
"description": "Number of bands from which to query.",
"type": "number",
"min": 0,
"step": 1,
"width": 2
},
{
"field": "sigfigs",
"name": "SigFigs",
"description": "Number of significant figures to use after the decimal of returned values.",
"type": "number",
"min": 0,
"step": 1,
"width": 2
},
{
"field": "unit",
"name": "Unit",
"description": "A string that is appended to your returned value. e.g. ' m' would be appended on a raw value ('41') and show '41 m'. If it was 'm', it would return '41m', without a space.",
"type": "text",
"width": 4
},
{
"field": "timeFormat",
"name": "Time Format",
"description": "A string for formatting the injected '{starttime}' and '{endtime}' in the url. See syntax in https://d3js.org/d3-time-format#locale_format",
"type": "text",
"width": 4
}
]
}
]
}
]
}
}
18 changes: 17 additions & 1 deletion src/essence/Tools/Info/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,5 +13,21 @@
"paths": {
"InfoTool": "essence/Tools/Info/InfoTool"
},
"expandable": true
"expandable": true,
"config": {
"rows": [
{
"components": [
{
"field": "variables.sortAlphabetically",
"name": "Sort Alphabetically",
"description": "Whether to sort the feature's fields alphabetically instead of listing them in their native order.",
"type": "checkbox",
"width": 3,
"defaultChecked": false
}
]
}
]
}
}
18 changes: 17 additions & 1 deletion src/essence/Tools/Layers/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,5 +13,21 @@
"paths": {
"LayersTool": "essence/Tools/Layers/LayersTool"
},
"expandable": true
"expandable": true,
"config": {
"rows": [
{
"components": [
{
"field": "variables.expanded",
"name": "Expanded",
"description": "Whether all layer groupings default to being expanded (as opposed to being collapsed).",
"type": "checkbox",
"width": 3,
"defaultChecked": false
}
]
}
]
}
}
24 changes: 24 additions & 0 deletions src/essence/Tools/Legend/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,29 @@
"separatedTool": true,
"paths": {
"LegendTool": "essence/Tools/Legend/LegendTool"
},
"config": {
"rows": [
{
"components": [
{
"field": "variables.displayOnStart",
"name": "Display on Start",
"description": "Whether the expanded legend should automatically be displayed on start.",
"type": "checkbox",
"width": 3,
"defaultChecked": false
},
{
"field": "variables.justification",
"name": "Justification",
"description": "",
"type": "dropdown",
"width": 2,
"options": ["left", "right"]
}
]
}
]
}
}
126 changes: 126 additions & 0 deletions src/essence/Tools/Shade/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,5 +39,131 @@
"ShadeTool": "essence/Tools/Shade/ShadeTool",
"ShadeTool_Manager": "essence/Tools/Shade/ShadeTool_Algorithm",
"ShadeTool_Algorithm": "essence/Tools/Shade/ShadeTool_Algorithm"
},
"config": {
"rows": [
{
"components": [
{
"field": "variables.dem",
"name": "DEM path",
"description": "Path to Data/defaultDEM.tif",
"type": "text",
"width": 12
}
]
},
{
"components": [
{
"field": "variables.data",
"name": "Layer specific DEMs",
"description": "Only show DEM if associated layer is on.",
"type": "objectarray",
"width": 12,
"object": [
{
"field": "name",
"name": "Name",
"description": "User-friendly name for DEM",
"type": "text",
"width": 2
},
{
"field": "demtileurl",
"name": "DEM Path",
"description": "",
"type": "text",
"width": 8
},
{
"field": "minZoom",
"name": "Minimum Zoom",
"description": "",
"type": "number",
"min": 0,
"step": 1,
"width": 1
},
{
"field": "maxNativeZoom",
"name": "Maximum Native Zoom",
"description": "",
"type": "number",
"min": 0,
"step": 1,
"width": 1
}
]
}
]
},
{
"components": [
{
"field": "variables.sources",
"name": "Sources",
"description": "Only show DEM if associated layer is on.",
"type": "objectarray",
"width": 12,
"object": [
{
"field": "name",
"name": "Name",
"description": "User-friendly name for orbiter or body that 'casts shadows'",
"type": "text",
"width": 4
},
{
"field": "value",
"name": "Value",
"description": "SPICE Spacecraft name or ID",
"type": "text",
"width": 4
}
]
}
]
},
{
"components": [
{
"field": "variables.observers",
"name": "Observers",
"description": "Only show DEM if associated layer is on.",
"type": "objectarray",
"width": 12,
"object": [
{
"field": "name",
"name": "Name",
"description": "User-friendly name for observer for spacecraft time computations",
"type": "text",
"width": 4
},
{
"field": "value",
"name": "Value",
"description": "SPICE Spacecraft name or ID",
"type": "text",
"width": 4
}
]
}
]
},
{
"components": [
{
"field": "variables.defaultHeight",
"name": "Default Height",
"description": "",
"type": "number",
"min": 0,
"width": 2
}
]
}
]
}
}

0 comments on commit cbc1691

Please sign in to comment.