{
  "Type": "Window",
  "Id": "mineral_survey",
  "Title": "Mineral Search",
  "Icon": "\u26cf",
  "Classes": [
    "ps-window-holo"
  ],
  "State": "Maximized",
  "DisplayLocation": "Taskbar",
  "WindowGroup": "static_menu",
  "IsRestorable": false,
  "IsMinimizable": false,
  "Width": "100%",
  "Height": "100%",
  "Background": "rgba(0,0,0,0.85)",
  "Padding": "16",
  "Children": [
    {
      "Type": "Grid",
      "Id": "mineral_survey_layout",
      "Width": "100%",
      "Height": "100%",
      "RowDefinitions": [
        "Auto",
        "1fr"
      ],
      "Children": [
        {
          "Type": "Panel",
          "Id": "ms_filter_shell",
          "Grid.Row": 0,
          "Padding": "0,0,0,12",
          "Children": [
            {
              "Type": "StackPanel",
              "Id": "ms_filter_shell_stack",
              "Orientation": "Vertical",
              "Gap": 8,
              "Width": "100%",
              "Children": [
                {
                  "Type": "Grid",
                  "Id": "ms_filter_header",
                  "ColumnDefinitions": [
                    "1fr",
                    "Auto"
                  ],
                  "Children": [
                    {
                      "Type": "StackPanel",
                      "Grid.Column": 0,
                      "Orientation": "Vertical",
                      "Gap": 2,
                      "Children": [
                        {
                          "Type": "Label",
                          "Text": "Mineral Survey",
                          "Classes": [
                            "ps-panel-title"
                          ]
                        },
                        {
                          "Type": "Label",
                          "Id": "ms_filter_context",
                          "Text": "Surveyed deposits across all visible systems.",
                          "Classes": [
                            "ps-text-secondary"
                          ]
                        }
                      ]
                    },
                    {
                      "Type": "Button",
                      "Id": "ms_filter_collapse",
                      "Grid.Column": 1,
                      "Text": "\u25be",
                      "Command": "core.mineral_survey.toggle_filter_panel",
                      "Classes": [
                        "ps-btn--sm"
                      ]
                    }
                  ]
                },
                {
                  "Type": "StackPanel",
                  "Id": "ms_filter_panel",
                  "Orientation": "Vertical",
                  "Gap": 8,
                  "Width": "100%",
                  "Children": [
                    {
                      "Type": "StackPanel",
                      "Id": "ms_filter_row_primary",
                      "Orientation": "Horizontal",
                      "Gap": 8,
                      "Width": "100%",
                      "Children": [
                        {
                          "Type": "Select",
                          "Id": "ms_species_select",
                          "Width": "220px",
                          "Value": "",
                          "Options": [],
                          "Command": "core.mineral_survey.select_species"
                        },
                        {
                          "Type": "Select",
                          "Id": "ms_system_select",
                          "Width": "320px",
                          "Value": "",
                          "Options": [],
                          "IsSearchable": true,
                          "Command": "core.mineral_survey.select_system"
                        }
                      ]
                    },
                    {
                      "Type": "StackPanel",
                      "Id": "ms_thresholds_row",
                      "Orientation": "Horizontal",
                      "Gap": 8,
                      "Width": "100%",
                      "Children": [
                        {
                          "Type": "StackPanel",
                          "Orientation": "Vertical",
                          "Gap": 4,
                          "Children": [
                            {
                              "Type": "Label",
                              "Text": "Dur",
                              "Classes": [
                                "ps-text-secondary"
                              ]
                            },
                            {
                              "Type": "StackPanel",
                              "Orientation": "Horizontal",
                              "Gap": 4,
                              "Children": [
                                {
                                  "Type": "Input",
                                  "Id": "ms_threshold_dur_amount",
                                  "Width": "64px",
                                  "Value": "0",
                                  "InputType": "number",
                                  "CommitOnInput": true,
                                  "Command": "core.mineral_survey.set_threshold"
                                },
                                {
                                  "Type": "Input",
                                  "Id": "ms_threshold_dur_access",
                                  "Width": "44px",
                                  "Value": "0.1",
                                  "InputType": "number",
                                  "CommitOnInput": true,
                                  "Command": "core.mineral_survey.set_threshold",
                                  "min": 0,
                                  "max": 1,
                                  "step": 0.1
                                }
                              ]
                            }
                          ]
                        },
                        {
                          "Type": "StackPanel",
                          "Orientation": "Vertical",
                          "Gap": 4,
                          "Children": [
                            {
                              "Type": "Label",
                              "Text": "Neu",
                              "Classes": [
                                "ps-text-secondary"
                              ]
                            },
                            {
                              "Type": "StackPanel",
                              "Orientation": "Horizontal",
                              "Gap": 4,
                              "Children": [
                                {
                                  "Type": "Input",
                                  "Id": "ms_threshold_neu_amount",
                                  "Width": "64px",
                                  "Value": "0",
                                  "InputType": "number",
                                  "CommitOnInput": true,
                                  "Command": "core.mineral_survey.set_threshold"
                                },
                                {
                                  "Type": "Input",
                                  "Id": "ms_threshold_neu_access",
                                  "Width": "44px",
                                  "Value": "0.1",
                                  "InputType": "number",
                                  "CommitOnInput": true,
                                  "Command": "core.mineral_survey.set_threshold",
                                  "min": 0,
                                  "max": 1,
                                  "step": 0.1
                                }
                              ]
                            }
                          ]
                        },
                        {
                          "Type": "StackPanel",
                          "Orientation": "Vertical",
                          "Gap": 4,
                          "Children": [
                            {
                              "Type": "Label",
                              "Text": "Cor",
                              "Classes": [
                                "ps-text-secondary"
                              ]
                            },
                            {
                              "Type": "StackPanel",
                              "Orientation": "Horizontal",
                              "Gap": 4,
                              "Children": [
                                {
                                  "Type": "Input",
                                  "Id": "ms_threshold_cor_amount",
                                  "Width": "64px",
                                  "Value": "0",
                                  "InputType": "number",
                                  "CommitOnInput": true,
                                  "Command": "core.mineral_survey.set_threshold"
                                },
                                {
                                  "Type": "Input",
                                  "Id": "ms_threshold_cor_access",
                                  "Width": "44px",
                                  "Value": "0.1",
                                  "InputType": "number",
                                  "CommitOnInput": true,
                                  "Command": "core.mineral_survey.set_threshold",
                                  "min": 0,
                                  "max": 1,
                                  "step": 0.1
                                }
                              ]
                            }
                          ]
                        },
                        {
                          "Type": "StackPanel",
                          "Orientation": "Vertical",
                          "Gap": 4,
                          "Children": [
                            {
                              "Type": "Label",
                              "Text": "Tri",
                              "Classes": [
                                "ps-text-secondary"
                              ]
                            },
                            {
                              "Type": "StackPanel",
                              "Orientation": "Horizontal",
                              "Gap": 4,
                              "Children": [
                                {
                                  "Type": "Input",
                                  "Id": "ms_threshold_tri_amount",
                                  "Width": "64px",
                                  "Value": "0",
                                  "InputType": "number",
                                  "CommitOnInput": true,
                                  "Command": "core.mineral_survey.set_threshold"
                                },
                                {
                                  "Type": "Input",
                                  "Id": "ms_threshold_tri_access",
                                  "Width": "44px",
                                  "Value": "0.1",
                                  "InputType": "number",
                                  "CommitOnInput": true,
                                  "Command": "core.mineral_survey.set_threshold",
                                  "min": 0,
                                  "max": 1,
                                  "step": 0.1
                                }
                              ]
                            }
                          ]
                        },
                        {
                          "Type": "StackPanel",
                          "Orientation": "Vertical",
                          "Gap": 4,
                          "Children": [
                            {
                              "Type": "Label",
                              "Text": "Bor",
                              "Classes": [
                                "ps-text-secondary"
                              ]
                            },
                            {
                              "Type": "StackPanel",
                              "Orientation": "Horizontal",
                              "Gap": 4,
                              "Children": [
                                {
                                  "Type": "Input",
                                  "Id": "ms_threshold_bor_amount",
                                  "Width": "64px",
                                  "Value": "0",
                                  "InputType": "number",
                                  "CommitOnInput": true,
                                  "Command": "core.mineral_survey.set_threshold"
                                },
                                {
                                  "Type": "Input",
                                  "Id": "ms_threshold_bor_access",
                                  "Width": "44px",
                                  "Value": "0.1",
                                  "InputType": "number",
                                  "CommitOnInput": true,
                                  "Command": "core.mineral_survey.set_threshold",
                                  "min": 0,
                                  "max": 1,
                                  "step": 0.1
                                }
                              ]
                            }
                          ]
                        },
                        {
                          "Type": "StackPanel",
                          "Orientation": "Vertical",
                          "Gap": 4,
                          "Children": [
                            {
                              "Type": "Label",
                              "Text": "Mer",
                              "Classes": [
                                "ps-text-secondary"
                              ]
                            },
                            {
                              "Type": "StackPanel",
                              "Orientation": "Horizontal",
                              "Gap": 4,
                              "Children": [
                                {
                                  "Type": "Input",
                                  "Id": "ms_threshold_mer_amount",
                                  "Width": "64px",
                                  "Value": "0",
                                  "InputType": "number",
                                  "CommitOnInput": true,
                                  "Command": "core.mineral_survey.set_threshold"
                                },
                                {
                                  "Type": "Input",
                                  "Id": "ms_threshold_mer_access",
                                  "Width": "44px",
                                  "Value": "0.1",
                                  "InputType": "number",
                                  "CommitOnInput": true,
                                  "Command": "core.mineral_survey.set_threshold",
                                  "min": 0,
                                  "max": 1,
                                  "step": 0.1
                                }
                              ]
                            }
                          ]
                        },
                        {
                          "Type": "StackPanel",
                          "Orientation": "Vertical",
                          "Gap": 4,
                          "Children": [
                            {
                              "Type": "Label",
                              "Text": "Ven",
                              "Classes": [
                                "ps-text-secondary"
                              ]
                            },
                            {
                              "Type": "StackPanel",
                              "Orientation": "Horizontal",
                              "Gap": 4,
                              "Children": [
                                {
                                  "Type": "Input",
                                  "Id": "ms_threshold_ven_amount",
                                  "Width": "64px",
                                  "Value": "0",
                                  "InputType": "number",
                                  "CommitOnInput": true,
                                  "Command": "core.mineral_survey.set_threshold"
                                },
                                {
                                  "Type": "Input",
                                  "Id": "ms_threshold_ven_access",
                                  "Width": "44px",
                                  "Value": "0.1",
                                  "InputType": "number",
                                  "CommitOnInput": true,
                                  "Command": "core.mineral_survey.set_threshold",
                                  "min": 0,
                                  "max": 1,
                                  "step": 0.1
                                }
                              ]
                            }
                          ]
                        },
                        {
                          "Type": "StackPanel",
                          "Orientation": "Vertical",
                          "Gap": 4,
                          "Children": [
                            {
                              "Type": "Label",
                              "Text": "Sor",
                              "Classes": [
                                "ps-text-secondary"
                              ]
                            },
                            {
                              "Type": "StackPanel",
                              "Orientation": "Horizontal",
                              "Gap": 4,
                              "Children": [
                                {
                                  "Type": "Input",
                                  "Id": "ms_threshold_sor_amount",
                                  "Width": "64px",
                                  "Value": "0",
                                  "InputType": "number",
                                  "CommitOnInput": true,
                                  "Command": "core.mineral_survey.set_threshold"
                                },
                                {
                                  "Type": "Input",
                                  "Id": "ms_threshold_sor_access",
                                  "Width": "44px",
                                  "Value": "0.1",
                                  "InputType": "number",
                                  "CommitOnInput": true,
                                  "Command": "core.mineral_survey.set_threshold",
                                  "min": 0,
                                  "max": 1,
                                  "step": 0.1
                                }
                              ]
                            }
                          ]
                        },
                        {
                          "Type": "StackPanel",
                          "Orientation": "Vertical",
                          "Gap": 4,
                          "Children": [
                            {
                              "Type": "Label",
                              "Text": "Uri",
                              "Classes": [
                                "ps-text-secondary"
                              ]
                            },
                            {
                              "Type": "StackPanel",
                              "Orientation": "Horizontal",
                              "Gap": 4,
                              "Children": [
                                {
                                  "Type": "Input",
                                  "Id": "ms_threshold_uri_amount",
                                  "Width": "64px",
                                  "Value": "0",
                                  "InputType": "number",
                                  "CommitOnInput": true,
                                  "Command": "core.mineral_survey.set_threshold"
                                },
                                {
                                  "Type": "Input",
                                  "Id": "ms_threshold_uri_access",
                                  "Width": "44px",
                                  "Value": "0.1",
                                  "InputType": "number",
                                  "CommitOnInput": true,
                                  "Command": "core.mineral_survey.set_threshold",
                                  "min": 0,
                                  "max": 1,
                                  "step": 0.1
                                }
                              ]
                            }
                          ]
                        },
                        {
                          "Type": "StackPanel",
                          "Orientation": "Vertical",
                          "Gap": 4,
                          "Children": [
                            {
                              "Type": "Label",
                              "Text": "Crd",
                              "Classes": [
                                "ps-text-secondary"
                              ]
                            },
                            {
                              "Type": "StackPanel",
                              "Orientation": "Horizontal",
                              "Gap": 4,
                              "Children": [
                                {
                                  "Type": "Input",
                                  "Id": "ms_threshold_crd_amount",
                                  "Width": "64px",
                                  "Value": "0",
                                  "InputType": "number",
                                  "CommitOnInput": true,
                                  "Command": "core.mineral_survey.set_threshold"
                                },
                                {
                                  "Type": "Input",
                                  "Id": "ms_threshold_crd_access",
                                  "Width": "44px",
                                  "Value": "0.1",
                                  "InputType": "number",
                                  "CommitOnInput": true,
                                  "Command": "core.mineral_survey.set_threshold",
                                  "min": 0,
                                  "max": 1,
                                  "step": 0.1
                                }
                              ]
                            }
                          ]
                        },
                        {
                          "Type": "StackPanel",
                          "Orientation": "Vertical",
                          "Gap": 4,
                          "Children": [
                            {
                              "Type": "Label",
                              "Text": "Gal",
                              "Classes": [
                                "ps-text-secondary"
                              ]
                            },
                            {
                              "Type": "StackPanel",
                              "Orientation": "Horizontal",
                              "Gap": 4,
                              "Children": [
                                {
                                  "Type": "Input",
                                  "Id": "ms_threshold_gal_amount",
                                  "Width": "64px",
                                  "Value": "0",
                                  "InputType": "number",
                                  "CommitOnInput": true,
                                  "Command": "core.mineral_survey.set_threshold"
                                },
                                {
                                  "Type": "Input",
                                  "Id": "ms_threshold_gal_access",
                                  "Width": "44px",
                                  "Value": "0.1",
                                  "InputType": "number",
                                  "CommitOnInput": true,
                                  "Command": "core.mineral_survey.set_threshold",
                                  "min": 0,
                                  "max": 1,
                                  "step": 0.1
                                }
                              ]
                            }
                          ]
                        }
                      ]
                    },
                    {
                      "Type": "StackPanel",
                      "Id": "ms_filter_row_secondary",
                      "Orientation": "Horizontal",
                      "Gap": 12,
                      "Width": "100%",
                      "Children": [
                        {
                          "Type": "RadioGroup",
                          "Id": "ms_gas_giant_filter",
                          "Label": "Gas Giants",
                          "Style": "segmented",
                          "Orientation": "Horizontal",
                          "SelectedValue": "include",
                          "Command": "core.mineral_survey.set_body_filter_mode",
                          "Items": [
                            {
                              "Label": "Inc",
                              "Value": "include"
                            },
                            {
                              "Label": "Exc",
                              "Value": "exclude"
                            },
                            {
                              "Label": "Only",
                              "Value": "only"
                            }
                          ]
                        },
                        {
                          "Type": "RadioGroup",
                          "Id": "ms_asteroid_filter",
                          "Label": "Asteroids",
                          "Style": "segmented",
                          "Orientation": "Horizontal",
                          "SelectedValue": "include",
                          "Command": "core.mineral_survey.set_body_filter_mode",
                          "Items": [
                            {
                              "Label": "Inc",
                              "Value": "include"
                            },
                            {
                              "Label": "Exc",
                              "Value": "exclude"
                            },
                            {
                              "Label": "Only",
                              "Value": "only"
                            }
                          ]
                        },
                        {
                          "Type": "StackPanel",
                          "Orientation": "Vertical",
                          "Gap": 4,
                          "Children": [
                            {
                              "Type": "Label",
                              "Text": "Max CC",
                              "Classes": [
                                "ps-text-secondary"
                              ]
                            },
                            {
                              "Type": "Input",
                              "Id": "ms_colony_cost_threshold",
                              "Width": "64px",
                              "Value": "10",
                              "InputType": "number",
                              "CommitOnInput": true,
                              "Command": "core.mineral_survey.set_numeric_filter"
                            }
                          ]
                        },
                        {
                          "Type": "Checkbox",
                          "Id": "ms_hab_colour",
                          "Label": "Hab Colour",
                          "IsChecked": true,
                          "Command": "core.mineral_survey.toggle_option"
                        },
                        {
                          "Type": "Checkbox",
                          "Id": "ms_om_eligible",
                          "Label": "OM Eligible",
                          "IsChecked": false,
                          "Command": "core.mineral_survey.toggle_option"
                        },
                        {
                          "Type": "Checkbox",
                          "Id": "ms_exclude_high_g",
                          "Label": "Exc. High-G",
                          "IsChecked": false,
                          "Command": "core.mineral_survey.toggle_option"
                        }
                      ]
                    },
                    {
                      "Type": "StackPanel",
                      "Id": "ms_filter_row_tertiary",
                      "Orientation": "Horizontal",
                      "Gap": 12,
                      "Width": "100%",
                      "Children": [
                        {
                          "Type": "StackPanel",
                          "Orientation": "Vertical",
                          "Gap": 4,
                          "Children": [
                            {
                              "Type": "Label",
                              "Text": "Max Diameter",
                              "Classes": [
                                "ps-text-secondary"
                              ]
                            },
                            {
                              "Type": "Input",
                              "Id": "ms_max_diameter",
                              "Width": "90px",
                              "Value": "0",
                              "InputType": "number",
                              "CommitOnInput": true,
                              "Command": "core.mineral_survey.set_numeric_filter"
                            }
                          ]
                        },
                        {
                          "Type": "StackPanel",
                          "Orientation": "Vertical",
                          "Gap": 4,
                          "Children": [
                            {
                              "Type": "Label",
                              "Text": "Min Gravity",
                              "Classes": [
                                "ps-text-secondary"
                              ]
                            },
                            {
                              "Type": "Input",
                              "Id": "ms_min_gravity",
                              "Width": "90px",
                              "Value": "0",
                              "InputType": "number",
                              "CommitOnInput": true,
                              "Command": "core.mineral_survey.set_numeric_filter"
                            }
                          ]
                        }
                      ]
                    }
                  ]
                }
              ]
            }
          ]
        },
        {
          "Type": "StackPanel",
          "Id": "ms_content_panel",
          "Grid.Row": 1,
          "Orientation": "Vertical",
          "Gap": 8,
          "Width": "100%",
          "Height": "100%",
          "Children": [
            {
              "Type": "DataGrid",
              "Id": "ms_body_grid",
              "Width": "100%",
              "Height": "100%",
              "EnableVerticalScroll": true,
              "EnableHorizontalScroll": true,
              "UseZebraStriping": true,
              "SelectionMode": "Single",
              "AllowSorting": true,
              "OnSelectionChanged": "core.mineral_survey.select_body_row",
              "Columns": [],
              "Rows": []
            },
            {
              "Type": "Label",
              "Id": "ms_empty_message",
              "Text": "No surveyed deposits match the current filters.",
              "IsVisible": false,
              "Classes": [
                "ps-text--muted"
              ]
            },
            {
              "Type": "Grid",
              "Id": "ms_action_row",
              "ColumnDefinitions": [
                "1fr",
                "Auto"
              ],
              "Children": [
                {
                  "Type": "StackPanel",
                  "Grid.Column": 0,
                  "Orientation": "Vertical",
                  "Gap": 2,
                  "Children": [
                    {
                      "Type": "Label",
                      "Id": "ms_body_count",
                      "Text": "0 bodies shown",
                      "Classes": [
                        "ps-text-secondary"
                      ]
                    },
                    {
                      "Type": "Label",
                      "Id": "ms_status",
                      "Text": "",
                      "IsVisible": false,
                      "Classes": [
                        "ps-text-secondary"
                      ]
                    }
                  ]
                },
                {
                  "Type": "StackPanel",
                  "Grid.Column": 1,
                  "Orientation": "Horizontal",
                  "Gap": 8,
                  "Children": [
                    {
                      "Type": "Button",
                      "Id": "ms_search",
                      "Text": "Search",
                      "Command": "core.mineral_survey.search",
                      "Classes": [
                        "ps-btn--sm"
                      ]
                    },
                    {
                      "Type": "Button",
                      "Id": "ms_create_colony",
                      "Text": "Create Colony",
                      "IsVisible": false,
                      "Command": "core.mineral_survey.create_colony",
                      "Classes": [
                        "ps-btn--sm"
                      ]
                    },
                    {
                      "Type": "Button",
                      "Id": "ms_clear_search",
                      "Text": "Clear Search",
                      "Command": "core.mineral_survey.clear_search",
                      "Classes": [
                        "ps-btn--sm"
                      ]
                    },
                    {
                      "Type": "Button",
                      "Id": "ms_wide_view",
                      "Text": "Wide View",
                      "Command": "core.mineral_survey.toggle_wide_view",
                      "Classes": [
                        "ps-btn--sm"
                      ]
                    },
                    {
                      "Type": "Checkbox",
                      "Id": "ms_center_on_body",
                      "Label": "Centre on Selected Body",
                      "IsChecked": false,
                      "Command": "core.mineral_survey.toggle_option"
                    },
                    {
                      "Type": "Checkbox",
                      "Id": "ms_center_on_system",
                      "Label": "Centre on Selected System",
                      "IsChecked": false,
                      "Command": "core.mineral_survey.toggle_option"
                    }
                  ]
                }
              ]
            }
          ]
        }
      ]
    }
  ]
}
