959 lines
34 KiB
HTML
959 lines
34 KiB
HTML
{% load static %}
|
|
{% load cache %}
|
|
{% load page_title %}
|
|
{% load accessibility %}
|
|
|
|
<!DOCTYPE html>
|
|
<html lang="en-GB">
|
|
<head>
|
|
<script>
|
|
(function () {
|
|
var storedTheme = "light";
|
|
try {
|
|
storedTheme = localStorage.getItem("theme") || "light";
|
|
} catch (error) {
|
|
}
|
|
var resolvedTheme = storedTheme === "dark" ? "dark" : "light";
|
|
document.documentElement.dataset.theme = resolvedTheme;
|
|
if (resolvedTheme === "dark") {
|
|
document.documentElement.style.backgroundColor = "#090d16";
|
|
document.documentElement.style.color = "#f8fafc";
|
|
} else {
|
|
document.documentElement.style.backgroundColor = "#f3f4f6";
|
|
document.documentElement.style.color = "#1b2433";
|
|
}
|
|
var faviconHref = resolvedTheme === "dark"
|
|
? "{% static 'favicon-dark.svg' %}"
|
|
: "{% static 'favicon-light.svg' %}";
|
|
document.querySelectorAll("link[data-gia-favicon]").forEach(function (link) {
|
|
link.setAttribute("href", faviconHref);
|
|
});
|
|
document.querySelectorAll(".js-theme-logo").forEach(function (image) {
|
|
image.setAttribute("src", faviconHref);
|
|
});
|
|
})();
|
|
</script>
|
|
<style>
|
|
html[data-theme="dark"],
|
|
html[data-theme="dark"] body {
|
|
background: #090d16 !important;
|
|
color: #f8fafc !important;
|
|
}
|
|
html[data-theme="light"],
|
|
html[data-theme="light"] body {
|
|
background: #f3f4f6 !important;
|
|
color: #1b2433 !important;
|
|
}
|
|
</style>
|
|
<meta charset="utf-8">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
<title>{% block browser_title %}{% firstof page_browser_title page_title as explicit_title %}{% if explicit_title %}{{ explicit_title }} · GIA{% else %}{% with route_value=request.resolver_match.url_name|default:request.path_info|humanize_route %}{% if route_value %}{{ route_value }} · GIA{% else %}GIA{% endif %}{% endwith %}{% endif %}{% endblock %}</title>
|
|
<link rel="icon" type="image/svg+xml" href="{% static 'favicon-light.svg' %}" data-gia-favicon>
|
|
<link rel="shortcut icon" href="{% static 'favicon-light.svg' %}" data-gia-favicon>
|
|
<link rel="manifest" href="{% static 'manifest.webmanifest' %}">
|
|
<link rel="stylesheet" href="{% static 'css/bulma.min.css' %}">
|
|
<link rel="stylesheet" href="{% static 'css/bulma-tooltip.min.css' %}">
|
|
<link rel="stylesheet" href="https://site-assets.fontawesome.com/releases/v6.1.1/css/all.css">
|
|
<link rel="stylesheet" href="{% static 'css/bulma-slider.min.css' %}">
|
|
<link rel="stylesheet" href="{% static 'css/bulma-calendar.min.css' %}">
|
|
<link rel="stylesheet" href="{% static 'css/bulma-tagsinput.min.css' %}">
|
|
<link rel="stylesheet" href="{% static 'css/bulma-switch.min.css' %}">
|
|
<link rel="stylesheet" href="{% static 'css/gridstack.min.css' %}">
|
|
<script src="{% static 'js/bulma-calendar.min.js' %}" integrity="sha384-DThNif0xGXbopX7+PE+UabkuClfI/zELNhaVqoGLutaWB76dyMw0vIQBGmUxSfVQ" crossorigin="anonymous"></script>
|
|
<script src="{% static 'js/bulma-slider.min.js' %}" integrity="sha384-wbyps8iLG8QzJE02viYc/27BtT5HSa11+b5V7QPR1/huVuA8f4LRTNGc82qAIeIZ" crossorigin="anonymous"></script>
|
|
<script src="{% static 'js/htmx.min.js' %}" integrity="sha384-cZuAZ+ZbwkNRnrKi05G/fjBX+azI9DNOkNYysZ0I/X5ZFgsmMiBXgDZof30F5ofc" crossorigin="anonymous"></script>
|
|
<script defer src="{% static 'js/remove-me.js' %}" integrity="sha384-6fHcFNoQ8QEI3ZDgw9Z/A6Brk64gF7AnFbLgdrumo8/kBbsKQ/wo7wPegj5WkzuG" crossorigin="anonymous"></script>
|
|
<script defer src="{% static 'js/hyperscript.min.js' %}" integrity="sha384-6GYN8BDHOJkkru6zcpGOUa//1mn+5iZ/MyT6mq34WFIpuOeLF52kSi721q0SsYF9" crossorigin="anonymous"></script>
|
|
<script src="{% static 'js/bulma-tagsinput.min.js' %}"></script>
|
|
<script src="{% static 'js/jquery.min.js' %}"></script>
|
|
<script src="{% static 'js/gridstack-all.js' %}"></script>
|
|
<script defer src="{% static 'js/magnet.min.js' %}"></script>
|
|
<script>
|
|
(function () {
|
|
function applyFavicon(theme) {
|
|
var href = theme === "dark"
|
|
? "{% static 'favicon-dark.svg' %}"
|
|
: "{% static 'favicon-light.svg' %}";
|
|
document.querySelectorAll("link[data-gia-favicon]").forEach(function (link) {
|
|
link.setAttribute("href", href);
|
|
});
|
|
document.querySelectorAll(".js-theme-logo").forEach(function (image) {
|
|
image.setAttribute("src", href);
|
|
});
|
|
}
|
|
|
|
function applyTheme(mode) {
|
|
var validMode = mode === "dark" ? "dark" : "light";
|
|
document.documentElement.dataset.theme = validMode;
|
|
applyFavicon(validMode);
|
|
try {
|
|
localStorage.setItem("theme", validMode);
|
|
} catch (error) {
|
|
}
|
|
document.querySelectorAll(".js-theme-toggle").forEach(function (button) {
|
|
var nextMode = validMode === "dark" ? "light" : "dark";
|
|
button.setAttribute("data-theme-mode", validMode);
|
|
button.setAttribute("aria-label", "Theme: " + validMode + ". Click to switch to " + nextMode + ".");
|
|
button.setAttribute("title", "Theme: " + validMode);
|
|
var label = button.querySelector("[data-theme-label]");
|
|
if (label) {
|
|
label.textContent = validMode === "dark" ? "Dark" : "Light";
|
|
}
|
|
});
|
|
}
|
|
|
|
function cycleTheme() {
|
|
var currentTheme = "light";
|
|
try {
|
|
currentTheme = localStorage.getItem("theme") || "light";
|
|
} catch (error) {
|
|
}
|
|
if (currentTheme === "dark") {
|
|
applyTheme("light");
|
|
return;
|
|
}
|
|
applyTheme("dark");
|
|
}
|
|
|
|
try {
|
|
applyTheme(localStorage.getItem("theme") || "light");
|
|
} catch (error) {
|
|
applyTheme("light");
|
|
}
|
|
|
|
document.addEventListener("DOMContentLoaded", function () {
|
|
document.querySelectorAll(".js-theme-toggle").forEach(function (button) {
|
|
button.addEventListener("click", cycleTheme);
|
|
});
|
|
applyTheme(document.documentElement.dataset.theme || "light");
|
|
});
|
|
})();
|
|
|
|
document.addEventListener("restore-scroll", function () {
|
|
var scrollpos = localStorage.getItem("scrollpos");
|
|
if (scrollpos) {
|
|
window.scrollTo(0, scrollpos);
|
|
}
|
|
});
|
|
|
|
document.addEventListener("htmx:beforeSwap", function () {
|
|
localStorage.setItem("scrollpos", window.scrollY);
|
|
});
|
|
|
|
document.addEventListener("DOMContentLoaded", function () {
|
|
document.querySelectorAll(".navbar-burger").forEach(function (el) {
|
|
el.addEventListener("click", function () {
|
|
var target = document.getElementById(el.dataset.target);
|
|
el.classList.toggle("is-active");
|
|
if (target) {
|
|
target.classList.toggle("is-active");
|
|
}
|
|
});
|
|
});
|
|
|
|
var composeLink = document.getElementById("nav-compose-link");
|
|
var composeDropdown = document.getElementById("nav-compose-contacts");
|
|
var composePreviewLoaded = false;
|
|
var composePreviewLoading = false;
|
|
if (!composeLink || !composeDropdown) {
|
|
return;
|
|
}
|
|
composeLink.addEventListener("mouseenter", function () {
|
|
var previewUrl = composeLink.dataset.previewUrl || "";
|
|
if (!previewUrl || composePreviewLoaded || composePreviewLoading) {
|
|
return;
|
|
}
|
|
composePreviewLoading = true;
|
|
fetch(previewUrl, {
|
|
method: "GET",
|
|
credentials: "same-origin",
|
|
headers: { "HX-Request": "true" },
|
|
})
|
|
.then(function (response) {
|
|
if (!response.ok) {
|
|
throw new Error("Failed contacts preview fetch.");
|
|
}
|
|
return response.text();
|
|
})
|
|
.then(function (html) {
|
|
composeDropdown.innerHTML = html;
|
|
composePreviewLoaded = true;
|
|
})
|
|
.catch(function () {
|
|
composePreviewLoaded = false;
|
|
})
|
|
.finally(function () {
|
|
composePreviewLoading = false;
|
|
});
|
|
});
|
|
});
|
|
</script>
|
|
<style>
|
|
.icon { border-bottom: 0px !important;}
|
|
.wrap {
|
|
word-wrap: break-word;
|
|
}
|
|
.nowrap-parent {
|
|
white-space: nowrap;
|
|
}
|
|
.nowrap-child {
|
|
display: inline-block;
|
|
}
|
|
.htmx-indicator{
|
|
opacity:0;
|
|
transition: opacity 500ms ease-in;
|
|
}
|
|
.htmx-request .htmx-indicator,
|
|
.htmx-request.htmx-indicator{
|
|
opacity:1
|
|
}
|
|
|
|
.tooltiptext {
|
|
visibility: hidden;
|
|
background-color: black;
|
|
color: #fff;
|
|
text-align: center;
|
|
padding: 5px 0;
|
|
border-radius: 6px;
|
|
position: absolute;
|
|
z-index: 1;
|
|
}
|
|
|
|
.rounded-tooltip:hover .tooltiptext {
|
|
visibility: visible;
|
|
}
|
|
|
|
.table {
|
|
background: transparent !important;
|
|
}
|
|
|
|
tr {
|
|
transition: all 0.2s ease-in-out;
|
|
}
|
|
|
|
a.panel-block {
|
|
transition: all 0.2s ease-in-out;
|
|
}
|
|
|
|
tr:hover,
|
|
a.panel-block:hover {
|
|
cursor:pointer;
|
|
background-color:rgba(221, 224, 255, 0.3) !important;
|
|
}
|
|
@media (prefers-color-scheme: dark) {
|
|
:root {
|
|
--background-color: rgba(84, 84, 84, 0.9) !important;
|
|
--modal-color: rgba(81, 81, 81, 0.9) !important;
|
|
}
|
|
}
|
|
|
|
:root {
|
|
--background-color-light: rgba(210, 210, 210, 0.9) !important;
|
|
--background-color-dark: rgba(84, 84, 84, 0.9) !important;
|
|
--background-color-modal-light: rgba(250, 250, 250, 0.5) !important;
|
|
--background-color-modal-dark: rgba(210, 210, 210, 0.9) !important;
|
|
}
|
|
|
|
[data-theme="light"] {
|
|
--background-color: var(--background-color-light);
|
|
--modal-color: var(--background-color-modal-light);
|
|
}
|
|
|
|
[data-theme="dark"] {
|
|
--background-color: var(--background-color-dark);
|
|
--modal-color: var(--background-color-modal-dark);
|
|
}
|
|
|
|
.panel, .box, .modal {
|
|
background-color: var(--modal-color) !important;
|
|
}
|
|
.box {
|
|
border: 1px solid rgba(25, 33, 52, 0.08);
|
|
box-shadow: 0 18px 48px rgba(20, 28, 45, 0.08);
|
|
}
|
|
.modal, .modal.box{
|
|
background-color: var(--background-color) !important;
|
|
}
|
|
.modal-background{
|
|
background-color:rgba(255, 255, 255, 0.3) !important;
|
|
}
|
|
#modals-here .modal-background {
|
|
background-color: rgba(0, 0, 0, 0.34) !important;
|
|
}
|
|
#modals-here .modal-content > .box {
|
|
background-color: rgba(255, 255, 255, 0.97) !important;
|
|
color: inherit;
|
|
}
|
|
#modals-here .modal-content .input,
|
|
#modals-here .modal-content .textarea,
|
|
#modals-here .modal-content .select select {
|
|
background-color: rgba(255, 255, 255, 0.98) !important;
|
|
}
|
|
[data-theme="dark"] #modals-here .modal-content > .box {
|
|
background-color: rgba(45, 45, 45, 0.97) !important;
|
|
}
|
|
[data-theme="dark"] #modals-here .modal-content .input,
|
|
[data-theme="dark"] #modals-here .modal-content .textarea,
|
|
[data-theme="dark"] #modals-here .modal-content .select select {
|
|
background-color: rgba(33, 33, 33, 0.98) !important;
|
|
}
|
|
|
|
.has-background-grey-lighter{
|
|
background-color:rgba(219, 219, 219, 0.5) !important;
|
|
}
|
|
.navbar {
|
|
background-color:rgba(0, 0, 0, 0.03) !important;
|
|
}
|
|
.gia-brand-shell {
|
|
display: inline-flex;
|
|
align-items: center;
|
|
}
|
|
.gia-brand-logo {
|
|
display: inline-flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
padding: 0.45rem 0.75rem;
|
|
border-radius: 16px;
|
|
background: rgba(255, 255, 255, 0.82);
|
|
border: 1px solid rgba(21, 28, 39, 0.08);
|
|
box-shadow: 0 10px 24px rgba(21, 28, 39, 0.08);
|
|
}
|
|
.gia-brand-logo img {
|
|
display: block;
|
|
}
|
|
[data-theme="dark"] .gia-brand-logo {
|
|
background: rgba(255, 255, 255, 0.96);
|
|
border-color: rgba(255, 255, 255, 0.82);
|
|
box-shadow: 0 12px 28px rgba(0, 0, 0, 0.34);
|
|
}
|
|
.section > .container.gia-page-shell,
|
|
.section > .container {
|
|
max-width: 1340px;
|
|
}
|
|
.gia-page-header {
|
|
display: flex;
|
|
align-items: flex-start;
|
|
justify-content: space-between;
|
|
gap: 1rem;
|
|
margin-bottom: 1rem;
|
|
flex-wrap: wrap;
|
|
}
|
|
.gia-page-header .title,
|
|
.gia-page-header .subtitle {
|
|
max-width: 72ch;
|
|
}
|
|
.gia-page-header .subtitle {
|
|
margin-bottom: 0;
|
|
}
|
|
.table thead th {
|
|
position: sticky;
|
|
top: 0;
|
|
background: rgba(248, 250, 252, 0.96) !important;
|
|
color: #1b1f2a !important;
|
|
backdrop-filter: blur(6px);
|
|
z-index: 1;
|
|
}
|
|
[data-theme="dark"] .table thead th {
|
|
background: rgba(44, 44, 44, 0.96) !important;
|
|
color: #f3f5f8 !important;
|
|
}
|
|
.table td,
|
|
.table th {
|
|
vertical-align: top;
|
|
}
|
|
.help {
|
|
max-width: 78ch;
|
|
}
|
|
.button.is-light {
|
|
border-color: rgba(27, 38, 59, 0.12);
|
|
}
|
|
.input,
|
|
.textarea,
|
|
.select select {
|
|
border-color: rgba(27, 38, 59, 0.18);
|
|
box-shadow: none;
|
|
}
|
|
.input:focus,
|
|
.textarea:focus,
|
|
.select select:focus {
|
|
border-color: rgba(27, 99, 214, 0.8);
|
|
box-shadow: 0 0 0 0.125em rgba(27, 99, 214, 0.14);
|
|
}
|
|
|
|
.grid-stack-item-content,
|
|
.floating-window {
|
|
display: flex !important;
|
|
flex-direction: column !important;
|
|
overflow-x: hidden !important;
|
|
overflow-y: hidden !important;
|
|
}
|
|
|
|
.panel {
|
|
display: flex !important;
|
|
flex-direction: column !important;
|
|
overflow: hidden;
|
|
}
|
|
|
|
.panel-block {
|
|
overflow-y:auto;
|
|
overflow-x:auto;
|
|
min-height: 90%;
|
|
display: block;
|
|
}
|
|
|
|
.floating-window {
|
|
max-height: 300px;
|
|
z-index: 9000;
|
|
position: absolute;
|
|
top: 50px;
|
|
left: 50px;
|
|
}
|
|
|
|
.floating-window .panel {
|
|
background-color:rgba(250, 250, 250, 0.8) !important;
|
|
}
|
|
|
|
.float-right {
|
|
float: right;
|
|
padding: 0 5px;
|
|
}
|
|
.grid-stack-item:hover .ui-resizable-handle {
|
|
display: block !important;
|
|
}
|
|
.ui-resizable-handle {
|
|
z-index: 39 !important;
|
|
}
|
|
|
|
.osint-table-shell {
|
|
border: 1px solid rgba(127, 127, 127, 0.2);
|
|
border-radius: 14px;
|
|
padding: 0.9rem;
|
|
background: rgba(255, 255, 255, 0.45);
|
|
}
|
|
|
|
.osint-table-toolbar {
|
|
margin-bottom: 0.75rem;
|
|
}
|
|
|
|
.osint-results-table-wrap {
|
|
border-radius: 10px;
|
|
overflow: auto;
|
|
}
|
|
|
|
.task-ui-badge {
|
|
background: #f5f5f5 !important;
|
|
border: 1px solid #dbdbdb !important;
|
|
color: #1f1f1f !important;
|
|
font-size: 0.75rem;
|
|
line-height: 1.5;
|
|
padding: 0.25em 0.75em;
|
|
font-weight: 500;
|
|
}
|
|
|
|
.osint-results-table th {
|
|
font-size: 0.8rem;
|
|
text-transform: uppercase;
|
|
letter-spacing: 0.05em;
|
|
}
|
|
|
|
.osint-sort-link {
|
|
color: inherit;
|
|
display: inline-flex;
|
|
align-items: center;
|
|
gap: 0.25rem;
|
|
}
|
|
|
|
.osint-sort-link:hover {
|
|
color: #3273dc;
|
|
}
|
|
|
|
.osint-search-form .button.is-fullwidth {
|
|
width: 100%;
|
|
}
|
|
.navbar-dropdown .navbar-item.is-current-route {
|
|
background-color: rgba(50, 115, 220, 0.14) !important;
|
|
color: #1f4f99 !important;
|
|
font-weight: 600;
|
|
}
|
|
.theme-toggle-button {
|
|
display: inline-flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
}
|
|
.brand-theme-toggle {
|
|
min-width: 0;
|
|
padding: 0;
|
|
border: 0 !important;
|
|
background: transparent !important;
|
|
box-shadow: none !important;
|
|
line-height: 1;
|
|
width: 3.15rem;
|
|
height: 3.15rem;
|
|
}
|
|
.brand-theme-logo {
|
|
display: block;
|
|
width: 3.15rem;
|
|
height: 3.15rem;
|
|
}
|
|
.security-page-tabs a {
|
|
transition: background-color 0.15s ease-in-out, color 0.15s ease-in-out;
|
|
}
|
|
.reduced-motion,
|
|
.reduced-motion * {
|
|
animation-duration: 0.01ms !important;
|
|
animation-iteration-count: 1 !important;
|
|
transition-duration: 0.01ms !important;
|
|
scroll-behavior: auto !important;
|
|
}
|
|
|
|
</style>
|
|
</head>
|
|
{% get_accessibility_settings request.user as a11y_settings %}
|
|
<body{% if a11y_settings and a11y_settings.disable_animations %} class="reduced-motion"{% endif %}>
|
|
|
|
<nav class="navbar" role="navigation" aria-label="main navigation">
|
|
<div class="navbar-brand">
|
|
<div class="navbar-item">
|
|
<span class="gia-brand-shell">
|
|
{% if user.is_authenticated %}
|
|
<button class="button is-light theme-toggle-button gia-brand-logo brand-theme-toggle js-theme-toggle" type="button" data-theme-mode="light" aria-label="Theme toggle">
|
|
<img class="brand-theme-logo js-theme-logo" src="{% static 'favicon-light.svg' %}" alt="" aria-hidden="true">
|
|
<span class="is-sr-only" data-theme-label>Auto</span>
|
|
</button>
|
|
{% else %}
|
|
<a href="{% url 'home' %}" class="gia-brand-logo" aria-label="GIA home">
|
|
<img class="brand-theme-logo" src="{% static 'favicon-light.svg' %}" alt="logo">
|
|
</a>
|
|
{% endif %}
|
|
</span>
|
|
</div>
|
|
|
|
<a role="button" class="navbar-burger" aria-label="menu" aria-expanded="false" data-target="bar">
|
|
<span aria-hidden="true"></span>
|
|
<span aria-hidden="true"></span>
|
|
<span aria-hidden="true"></span>
|
|
</a>
|
|
</div>
|
|
|
|
<div id="bar" class="navbar-menu">
|
|
<div class="navbar-start">
|
|
<a class="navbar-item" href="{% url 'home' %}">
|
|
Home
|
|
</a>
|
|
{% if user.is_authenticated %}
|
|
<div class="navbar-item has-dropdown is-hoverable">
|
|
<a
|
|
id="nav-compose-link"
|
|
class="navbar-link"
|
|
data-preview-url="{% url 'compose_contacts_dropdown' %}"
|
|
data-full-url="{% url 'compose_contacts_dropdown' %}?all=1"
|
|
hx-get="{% url 'compose_contacts_dropdown' %}?all=1"
|
|
hx-target="#nav-compose-contacts"
|
|
hx-trigger="click"
|
|
hx-swap="innerHTML">
|
|
<span class="icon is-small"><i class="fa-solid fa-paper-plane"></i></span>
|
|
<span style="margin-left: 0.35rem;">Compose</span>
|
|
</a>
|
|
<div class="navbar-dropdown" id="nav-compose-contacts">
|
|
<a
|
|
class="navbar-item"
|
|
hx-get="{% url 'compose_contacts_dropdown' %}?all=1"
|
|
hx-target="#nav-compose-contacts"
|
|
hx-swap="innerHTML">
|
|
Open Contacts
|
|
</a>
|
|
</div>
|
|
</div>
|
|
<a class="navbar-item" href="{% url 'tasks_hub' %}">
|
|
Task Inbox
|
|
</a>
|
|
<a class="navbar-item" href="{% url 'ai_workspace' %}">
|
|
AI
|
|
</a>
|
|
<a class="navbar-item" href="{% url 'osint_search' type='page' %}">
|
|
Search
|
|
</a>
|
|
{% endif %}
|
|
</div>
|
|
|
|
<div class="navbar-end">
|
|
{% if user.is_authenticated %}
|
|
<div class="navbar-item has-dropdown is-hoverable">
|
|
<a class="navbar-link">
|
|
Services
|
|
</a>
|
|
|
|
<div class="navbar-dropdown">
|
|
<a class="navbar-item" href="{% url 'signal' %}">
|
|
Signal
|
|
</a>
|
|
<a class="navbar-item" href="{% url 'whatsapp' %}">
|
|
WhatsApp
|
|
</a>
|
|
<a class="navbar-item" href="{% url 'instagram' %}">
|
|
Instagram
|
|
</a>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="navbar-item has-dropdown is-hoverable">
|
|
<a class="navbar-link">
|
|
Data
|
|
</a>
|
|
|
|
<div class="navbar-dropdown">
|
|
<a class="navbar-item" href="{% url 'sessions' type='page' %}">
|
|
Sessions
|
|
</a>
|
|
<a class="navbar-item{% if request.resolver_match.url_name == 'business_plan_inbox' or request.resolver_match.url_name == 'business_plan_editor' %} is-current-route{% endif %}" href="{% url 'business_plan_inbox' %}">
|
|
Business Plans
|
|
</a>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="navbar-item has-dropdown is-hoverable">
|
|
<a class="navbar-link">
|
|
Settings
|
|
</a>
|
|
|
|
<div class="navbar-dropdown">
|
|
<div class="navbar-item has-text-weight-semibold is-size-7 has-text-grey">
|
|
General
|
|
</div>
|
|
<a class="navbar-item{% if request.resolver_match.url_name == 'notifications_settings' or request.resolver_match.url_name == 'notifications_update' %} is-current-route{% endif %}" href="{% url 'notifications_settings' %}">
|
|
Notifications
|
|
</a>
|
|
{% if user.is_superuser %}
|
|
<a class="navbar-item{% if request.resolver_match.url_name == 'system_settings' %} is-current-route{% endif %}" href="{% url 'system_settings' %}">
|
|
System
|
|
</a>
|
|
{% endif %}
|
|
<a class="navbar-item{% if request.resolver_match.url_name == 'accessibility_settings' %} is-current-route{% endif %}" href="{% url 'accessibility_settings' %}">
|
|
Accessibility
|
|
</a>
|
|
<hr class="navbar-divider">
|
|
<div class="navbar-item has-text-weight-semibold is-size-7 has-text-grey">
|
|
Security
|
|
</div>
|
|
<a class="navbar-item{% if request.resolver_match.url_name == 'encryption_settings' or request.resolver_match.url_name == 'security_settings' %} is-current-route{% endif %}" href="{% url 'encryption_settings' %}">
|
|
Encryption
|
|
</a>
|
|
<a class="navbar-item{% if request.resolver_match.url_name == 'permission_settings' %} is-current-route{% endif %}" href="{% url 'permission_settings' %}">
|
|
Permissions
|
|
</a>
|
|
<a class="navbar-item{% if request.resolver_match.url_name == 'security_2fa' or request.resolver_match.namespace == 'two_factor' %} is-current-route{% endif %}" href="{% url 'security_2fa' %}">
|
|
2FA
|
|
</a>
|
|
<hr class="navbar-divider">
|
|
<div class="navbar-item has-text-weight-semibold is-size-7 has-text-grey">
|
|
AI
|
|
</div>
|
|
<a class="navbar-item{% if request.resolver_match.url_name == 'ai_models' or request.resolver_match.url_name == 'ais' %} is-current-route{% endif %}" href="{% url 'ai_models' %}">
|
|
Models
|
|
</a>
|
|
<a class="navbar-item{% if request.resolver_match.url_name == 'ai_execution_log' %} is-current-route{% endif %}" href="{% url 'ai_execution_log' %}">
|
|
Traces
|
|
</a>
|
|
<hr class="navbar-divider">
|
|
<div class="navbar-item has-text-weight-semibold is-size-7 has-text-grey">
|
|
Modules
|
|
</div>
|
|
<a class="navbar-item{% if request.resolver_match.url_name == 'command_routing' %} is-current-route{% endif %}" href="{% url 'command_routing' %}">
|
|
Commands
|
|
</a>
|
|
<a class="navbar-item{% if request.resolver_match.url_name == 'business_plan_inbox' or request.resolver_match.url_name == 'business_plan_editor' %} is-current-route{% endif %}" href="{% url 'business_plan_inbox' %}">
|
|
Business Plans
|
|
</a>
|
|
<a class="navbar-item{% if request.resolver_match.url_name == 'tasks_settings' %} is-current-route{% endif %}" href="{% url 'tasks_settings' %}">
|
|
Task Automation
|
|
</a>
|
|
<a class="navbar-item{% if request.resolver_match.url_name == 'translation_settings' %} is-current-route{% endif %}" href="{% url 'translation_settings' %}">
|
|
Translation
|
|
</a>
|
|
<a class="navbar-item{% if request.resolver_match.url_name == 'availability_settings' or request.resolver_match.url_name == 'behavioral_signals_settings' %} is-current-route{% endif %}" href="{% url 'behavioral_signals_settings' %}">
|
|
Behavioral Signals
|
|
</a>
|
|
<hr class="navbar-divider">
|
|
<div class="navbar-item has-text-weight-semibold is-size-7 has-text-grey">
|
|
Automation
|
|
</div>
|
|
<a class="navbar-item{% if request.resolver_match.url_name == 'queues' %} is-current-route{% endif %}" href="{% url 'queues' type='page' %}">
|
|
Approvals Queue
|
|
</a>
|
|
<a class="navbar-item{% if request.resolver_match.url_name == 'osint_workspace' %} is-current-route{% endif %}" href="{% url 'osint_workspace' %}">
|
|
OSINT Workspace
|
|
</a>
|
|
</div>
|
|
</div>
|
|
{% endif %}
|
|
|
|
<div class="navbar-item">
|
|
<div class="buttons">
|
|
{% if not user.is_authenticated %}
|
|
<a class="button is-info" href="{% url 'signup' %}">
|
|
<strong>Sign up</strong>
|
|
</a>
|
|
<a class="button" href="{% url 'two_factor:login' %}">
|
|
Log in
|
|
</a>
|
|
{% endif %}
|
|
|
|
{% if user.is_authenticated %}
|
|
<button class="button is-light add-button" type="button" style="display:none;">Install App</button>
|
|
<a class="button is-dark" href="{% url 'logout' %}">Logout</a>
|
|
{% endif %}
|
|
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</nav>
|
|
<script>
|
|
let deferredPrompt;
|
|
const addBtn = document.querySelector('.add-button');
|
|
if (addBtn) {
|
|
addBtn.style.display = 'none';
|
|
}
|
|
window.addEventListener('beforeinstallprompt', (e) => {
|
|
if (!addBtn) {
|
|
return;
|
|
}
|
|
// Prevent Chrome 67 and earlier from automatically showing the prompt
|
|
e.preventDefault();
|
|
// Stash the event so it can be triggered later.
|
|
deferredPrompt = e;
|
|
// Update UI to notify the user they can add to home screen
|
|
addBtn.style.display = 'block';
|
|
|
|
addBtn.addEventListener('click', (e) => {
|
|
// hide our user interface that shows our A2HS button
|
|
addBtn.style.display = 'none';
|
|
// Show the prompt
|
|
deferredPrompt.prompt();
|
|
// Wait for the user to respond to the prompt
|
|
deferredPrompt.userChoice.then((choiceResult) => {
|
|
if (choiceResult.outcome === 'accepted') {
|
|
console.log('User accepted the A2HS prompt');
|
|
} else {
|
|
console.log('User dismissed the A2HS prompt');
|
|
}
|
|
deferredPrompt = null;
|
|
});
|
|
});
|
|
});
|
|
|
|
window.giaPrepareWidgetTarget = function () {
|
|
const target = document.getElementById("widgets-here");
|
|
if (target) {
|
|
target.style.display = "block";
|
|
}
|
|
};
|
|
|
|
window.giaCanSpawnWidgets = function () {
|
|
return !!(
|
|
window.grid &&
|
|
typeof window.grid.addWidget === "function" &&
|
|
document.getElementById("grid-stack-main") &&
|
|
document.getElementById("widgets-here")
|
|
);
|
|
};
|
|
|
|
window.giaEnableWidgetSpawnButtons = function (root) {
|
|
const scope = root && root.querySelectorAll ? root : document;
|
|
const canSpawn = window.giaCanSpawnWidgets();
|
|
scope.querySelectorAll(".js-widget-spawn-trigger").forEach(function (button) {
|
|
const widgetUrl = String(
|
|
button.getAttribute("data-widget-url")
|
|
|| button.getAttribute("hx-get")
|
|
|| ""
|
|
).trim();
|
|
const visible = canSpawn && !!widgetUrl;
|
|
button.classList.toggle("is-hidden", !visible);
|
|
button.setAttribute("aria-hidden", visible ? "false" : "true");
|
|
});
|
|
};
|
|
|
|
window.giaPrepareWindowAnchor = function (trigger) {
|
|
if (!trigger || !trigger.getBoundingClientRect) {
|
|
window.giaWindowAnchor = null;
|
|
return;
|
|
}
|
|
const rect = trigger.getBoundingClientRect();
|
|
window.giaWindowAnchor = {
|
|
left: rect.left,
|
|
right: rect.right,
|
|
top: rect.top,
|
|
bottom: rect.bottom,
|
|
width: rect.width,
|
|
height: rect.height,
|
|
ts: Date.now(),
|
|
};
|
|
};
|
|
|
|
window.giaPositionFloatingWindow = function (windowEl) {
|
|
if (!windowEl) {
|
|
return;
|
|
}
|
|
const isMobile = window.matchMedia("(max-width: 768px)").matches;
|
|
const margin = 12;
|
|
const rect = windowEl.getBoundingClientRect();
|
|
const anchor = window.giaWindowAnchor || null;
|
|
windowEl.style.position = "fixed";
|
|
|
|
if (isMobile) {
|
|
const centeredLeftViewport = Math.max(
|
|
margin,
|
|
Math.round((window.innerWidth - rect.width) / 2)
|
|
);
|
|
const centeredTopViewport = Math.max(
|
|
margin,
|
|
Math.round((window.innerHeight - rect.height) / 2)
|
|
);
|
|
windowEl.style.left = centeredLeftViewport + "px";
|
|
windowEl.style.top = centeredTopViewport + "px";
|
|
windowEl.style.right = "auto";
|
|
windowEl.style.bottom = "auto";
|
|
windowEl.style.transform = "none";
|
|
windowEl.setAttribute("tabindex", "-1");
|
|
if (typeof windowEl.focus === "function") {
|
|
windowEl.focus({preventScroll: true});
|
|
}
|
|
if (typeof windowEl.scrollIntoView === "function") {
|
|
windowEl.scrollIntoView({block: "center", inline: "center", behavior: "smooth"});
|
|
}
|
|
window.giaWindowAnchor = null;
|
|
return;
|
|
}
|
|
|
|
if (!anchor || (Date.now() - anchor.ts) > 10000) {
|
|
return;
|
|
}
|
|
|
|
const desiredLeftViewport = anchor.left;
|
|
const desiredTopViewport = anchor.bottom + 6;
|
|
const maxLeftViewport = window.innerWidth - rect.width - margin;
|
|
const maxTopViewport = window.innerHeight - rect.height - margin;
|
|
const boundedLeftViewport = Math.max(
|
|
margin,
|
|
Math.min(desiredLeftViewport, maxLeftViewport)
|
|
);
|
|
const boundedTopViewport = Math.max(
|
|
margin,
|
|
Math.min(desiredTopViewport, maxTopViewport)
|
|
);
|
|
windowEl.style.left = boundedLeftViewport + "px";
|
|
windowEl.style.top = boundedTopViewport + "px";
|
|
windowEl.style.right = "auto";
|
|
windowEl.style.bottom = "auto";
|
|
windowEl.style.transform = "none";
|
|
window.giaWindowAnchor = null;
|
|
};
|
|
|
|
window.giaEnableFloatingWindowInteractions = function (windowEl) {
|
|
if (!windowEl || windowEl.dataset.giaWindowInteractive === "1") {
|
|
return;
|
|
}
|
|
windowEl.dataset.giaWindowInteractive = "1";
|
|
|
|
// Disable magnet-block global drag so text inputs remain editable.
|
|
windowEl.setAttribute("unmovable", "");
|
|
|
|
const heading = windowEl.querySelector(".panel-heading");
|
|
if (!heading) {
|
|
return;
|
|
}
|
|
|
|
let dragging = false;
|
|
let startX = 0;
|
|
let startY = 0;
|
|
let startLeft = 0;
|
|
let startTop = 0;
|
|
|
|
const onMove = function (event) {
|
|
if (!dragging) {
|
|
return;
|
|
}
|
|
const deltaX = event.clientX - startX;
|
|
const deltaY = event.clientY - startY;
|
|
windowEl.style.left = (startLeft + deltaX) + "px";
|
|
windowEl.style.top = (startTop + deltaY) + "px";
|
|
windowEl.style.right = "auto";
|
|
windowEl.style.bottom = "auto";
|
|
};
|
|
|
|
const stopDrag = function () {
|
|
dragging = false;
|
|
document.removeEventListener("pointermove", onMove);
|
|
document.removeEventListener("pointerup", stopDrag);
|
|
};
|
|
|
|
heading.addEventListener("pointerdown", function (event) {
|
|
if (event.button !== 0) {
|
|
return;
|
|
}
|
|
const interactive = event.target.closest(
|
|
"button, a, input, textarea, select, label, .delete, .icon"
|
|
);
|
|
if (interactive) {
|
|
return;
|
|
}
|
|
const rect = windowEl.getBoundingClientRect();
|
|
windowEl.style.position = "fixed";
|
|
startLeft = rect.left;
|
|
startTop = rect.top;
|
|
startX = event.clientX;
|
|
startY = event.clientY;
|
|
dragging = true;
|
|
document.addEventListener("pointermove", onMove);
|
|
document.addEventListener("pointerup", stopDrag);
|
|
event.preventDefault();
|
|
});
|
|
};
|
|
|
|
document.addEventListener("click", function (event) {
|
|
const trigger = event.target.closest(".js-widget-spawn-trigger");
|
|
if (!trigger) {
|
|
return;
|
|
}
|
|
window.giaPrepareWidgetTarget();
|
|
});
|
|
|
|
document.addEventListener("DOMContentLoaded", function () {
|
|
window.giaEnableWidgetSpawnButtons(document);
|
|
});
|
|
|
|
document.body.addEventListener("htmx:afterSwap", function (event) {
|
|
const target = (event && event.target) || document;
|
|
window.giaEnableWidgetSpawnButtons(target);
|
|
const targetId = (target && target.id) || "";
|
|
if (targetId === "windows-here") {
|
|
const floatingWindows = target.querySelectorAll(".floating-window");
|
|
floatingWindows.forEach(function (floatingWindow) {
|
|
window.setTimeout(function () {
|
|
window.giaPositionFloatingWindow(floatingWindow);
|
|
window.giaEnableFloatingWindowInteractions(floatingWindow);
|
|
}, 0);
|
|
});
|
|
}
|
|
});
|
|
</script>
|
|
{% block outer_content %}
|
|
{% endblock %}
|
|
<div>
|
|
<div class="container">
|
|
{% include "partials/settings-hierarchy-nav.html" %}
|
|
{% block content_wrapper %}
|
|
{% block content %}
|
|
{% endblock %}
|
|
{% endblock %}
|
|
<div id="modals-here">
|
|
</div>
|
|
<div id="windows-here" style="z-index: 120;">
|
|
</div>
|
|
<div id="widgets-here" style="display: none;">
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</body>
|
|
</html>
|