Cleanup: remove tracked pycache and db.sqlite3; add map membership backfill, new components, backups, docs

This commit is contained in:
gitrusprus
2026-06-28 22:16:01 +03:00
parent 4eb4c145b6
commit ce4e9ac5e6
46 changed files with 12125 additions and 176 deletions
+47 -2
View File
@@ -34,7 +34,7 @@
</div>
</div>
<div class="graph-area" ref="graphArea">
<div class="graph-area" ref="graphArea" @contextmenu.prevent="onGraphAreaContextMenu">
<div class="graph-chrome-bar">
<button
type="button"
@@ -77,7 +77,7 @@
</svg>
</button>
<div v-if="loading" class="spinner"></div>
<div v-else-if="nodes.length === 0" class="empty-state card">
<div v-else-if="nodes.length === 0" class="empty-state card" @contextmenu.prevent="onGraphAreaContextMenu">
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.5">
<circle cx="5" cy="12" r="3"/><circle cx="19" cy="5" r="3"/><circle cx="19" cy="19" r="3"/>
</svg>
@@ -139,6 +139,20 @@
@edit="openEditRelation"
/>
<GraphCanvasContextMenu
:open="canvasContextMenuOpen"
:x="canvasContextMenuX"
:y="canvasContextMenuY"
@close="closeContextMenu"
@create-contact="openCreateContact"
/>
<CreateContactModal
:open="createContactOpen"
@close="createContactOpen = false"
@created="onContactCreated"
/>
<EditRelationModal
:open="editRelationOpen"
:relation="editRelationTarget"
@@ -177,8 +191,11 @@ import RelationTypeFilters from '../components/RelationTypeFilters.vue'
import CreateRelationModal from '../components/CreateRelationModal.vue'
import GraphNodeContextMenu from '../components/GraphNodeContextMenu.vue'
import GraphEdgeContextMenu from '../components/GraphEdgeContextMenu.vue'
import GraphCanvasContextMenu from '../components/GraphCanvasContextMenu.vue'
import CreateContactModal from '../components/CreateContactModal.vue'
import EditRelationModal from '../components/EditRelationModal.vue'
import { useGraphNodeContextMenu } from '../composables/useGraphNodeContextMenu.js'
import { useNetworkMapsStore } from '../stores/networkMaps'
import { getGraphToolbarActions } from '../core/pluginRegistry'
let themeObserver = null
@@ -193,16 +210,44 @@ const {
contextMenuEdge,
edgeContextMenuX,
edgeContextMenuY,
canvasContextMenuOpen,
canvasContextMenuX,
canvasContextMenuY,
openCanvasContextMenu,
closeContextMenu,
closeEdgeContextMenu,
attachNodeContextHandlers,
} = useGraphNodeContextMenu()
const createContactOpen = ref(false)
function openNodeInfo(node) {
selectedNode.value = node || null
}
function openCreateContact() {
closeContextMenu()
createContactOpen.value = true
}
function onGraphAreaContextMenu(event) {
if (nodes.value.length > 0) return
openCanvasContextMenu(event)
}
async function onContactCreated(data, mapIds, pluginPayload) {
const created = await store.createContact(data)
if (mapIds?.length) {
await mapsStore.setContactMapMemberships(created.id, mapIds)
}
const { saveContactPluginData } = await import('../application/services/contactPluginService')
await saveContactPluginData(created.id, pluginPayload)
createContactOpen.value = false
await ensureGraphReady({ showSpinner: false })
}
const store = useContactsStore()
const mapsStore = useNetworkMapsStore()
const router = useRouter()
const graphToolbarActions = getGraphToolbarActions()
const graphArea = ref(null)