{# Copyright 2025 ellipse2v Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. Threat layer, shared by diagram_template.html and navigable_diagram_template.html. Draws one severity badge per element that has threats (count of threats, coloured by the worst one) and lists that element's threats in a side panel on click. Toggled and filtered by severity from the "Threats" section of the legend. Context: threat_layer_json (threat_layer.build_threat_layer), report_url. Must be included after the page's main script: it runs after svg-pan-zoom is set up. #}