Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
F
Frontend V2
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Contributor analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
GraphPolaris
Frontend V2
Commits
82cc1b11
Verified
Commit
82cc1b11
authored
1 week ago
by
Dennis Collaris
Browse files
Options
Downloads
Patches
Plain Diff
fix: rebase issues
parent
007f0de1
No related branches found
No related tags found
No related merge requests found
Pipeline
#147872
passed
1 week ago
Stage: tag-release
Stage: get-release-tag
Stage: container-image
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/lib/querybuilder/panel/QueryBuilderContextMenu.tsx
+22
-30
22 additions, 30 deletions
src/lib/querybuilder/panel/QueryBuilderContextMenu.tsx
with
22 additions
and
30 deletions
src/lib/querybuilder/panel/QueryBuilderContextMenu.tsx
+
22
−
30
View file @
82cc1b11
...
...
@@ -8,9 +8,6 @@ import {
MenuRadioItem
,
MenuSeparator
,
MenuTrigger
,
SubMenu
,
SubMenuContent
,
SubMenuTrigger
,
}
from
'
@/lib/components/menu
'
;
import
{
attributeShownToggle
,
...
...
@@ -118,12 +115,12 @@ export const QueryBuilderContextMenu = (props: {
return
(
<
Menu
isOpen
=
{
props
.
open
&&
state
!==
undefined
}
>
<
MenuTrigger
x
=
{
state
?
state
.
x
:
0
}
y
=
{
state
?
state
.
y
:
0
}
>
<
div
className
=
"hidden"
></
div
>
<
div
/
>
</
MenuTrigger
>
<
MenuContent
>
<
Sub
Menu
>
<
Sub
MenuTrigger
label
=
"Add/remove attribute"
/>
<
Sub
MenuContent
className
=
"max-h-60 overflow-y-auto"
>
<
Menu
>
<
MenuTrigger
label
=
"Add/remove attribute"
/>
<
MenuContent
className
=
"max-h-60 overflow-y-auto"
>
{
props
.
node
?.
data
.
attributes
.
map
((
attr
:
{
handleData
:
QueryGraphEdgeHandle
})
=>
(
<
MenuCheckboxItem
key
=
{
attr
.
handleData
.
attributeName
+
attr
.
handleData
.
nodeId
}
...
...
@@ -133,41 +130,36 @@ export const QueryBuilderContextMenu = (props: {
iconRight
=
{
getDataTypeIcon
(
attr
?.
handleData
?.
attributeType
)
}
/>
))
}
</
Sub
MenuContent
>
</
Sub
Menu
>
<
Sub
Menu
>
<
Sub
MenuTrigger
label
=
"Union type"
/>
<
Sub
MenuContent
>
</
MenuContent
>
</
Menu
>
<
Menu
>
<
MenuTrigger
label
=
"Union type"
/>
<
MenuContent
>
<
MenuRadioGroup
value
=
{
unionType
??
QueryUnionType
.
AND
}
onValueChange
=
{
setUnionType
}
>
<
MenuRadioItem
label
=
"AND"
value
=
{
QueryUnionType
.
AND
}
/>
<
MenuRadioItem
label
=
"OR"
value
=
{
QueryUnionType
.
OR
}
/>
</
MenuRadioGroup
>
</
Sub
MenuContent
>
</
Sub
Menu
>
</
MenuContent
>
</
Menu
>
{
relationDirection
&&
(
<
Sub
Menu
>
<
Sub
MenuTrigger
label
=
"Direction"
/>
<
Sub
MenuContent
>
<
Menu
>
<
MenuTrigger
label
=
"Direction"
/>
<
MenuContent
>
<
MenuRadioGroup
value
=
{
relationDirection
}
onValueChange
=
{
setRelationDirection
}
>
<
MenuRadioItem
label
=
{
QueryRelationDirection
.
BOTH
}
value
=
{
QueryRelationDirection
.
BOTH
}
/>
<
MenuRadioItem
label
=
{
QueryRelationDirection
.
RIGHT
}
value
=
{
QueryRelationDirection
.
RIGHT
}
/>
<
MenuRadioItem
label
=
{
QueryRelationDirection
.
LEFT
}
value
=
{
QueryRelationDirection
.
LEFT
}
/>
</
MenuRadioGroup
>
</
Sub
MenuContent
>
</
Sub
Menu
>
</
MenuContent
>
</
Menu
>
)
}
<
Sub
Menu
>
<
Sub
MenuTrigger
label
=
"Entity statistics"
/>
<
Sub
MenuContent
>
<
Menu
>
<
MenuTrigger
label
=
"Entity statistics"
/>
<
MenuContent
>
<
MenuLabel
label
=
"Total node count"
/>
<
MenuItem
disabled
label
=
{
String
(
activeQuery
?.
graphCounts
?.
nodeCounts
?
activeQuery
.
graphCounts
.
nodeCounts
[
props
.
node
?.
id
+
'
_count
'
]
:
'
unknown
'
,
)
}
></
MenuItem
>
</
SubMenuContent
>
</
SubMenu
>
<
MenuItem
disabled
label
=
{
String
(
activeQuery
?.
graphCounts
?.
nodeCounts
[
props
.
node
?.
id
+
'
_count
'
]
??
'
unknown
'
)
}
></
MenuItem
>
</
MenuContent
>
</
Menu
>
<
MenuSeparator
/>
<
MenuItem
label
=
"Remove"
className
=
"text-danger"
onClick
=
{
()
=>
removeNode
()
}
/>
</
MenuContent
>
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment