mirror of
https://github.com/IRBorisov/ConceptPortal.git
synced 2025-08-13 20:30:36 +03:00
B: Small UI fixes
This commit is contained in:
parent
62678b8b59
commit
7eb7fb09cf
|
@ -31,7 +31,7 @@ interface ToolbarGraphSelectionProps extends Styling {
|
|||
export function ToolbarGraphSelection({
|
||||
className,
|
||||
graph,
|
||||
value: selected,
|
||||
value,
|
||||
isCore,
|
||||
isInherited,
|
||||
isCrucial,
|
||||
|
@ -40,7 +40,7 @@ export function ToolbarGraphSelection({
|
|||
}: ToolbarGraphSelectionProps) {
|
||||
const selectedMenu = useDropdown();
|
||||
const groupMenu = useDropdown();
|
||||
const emptySelection = selected.length === 0;
|
||||
const emptySelection = value.length === 0;
|
||||
|
||||
function handleSelectReset() {
|
||||
onChange([]);
|
||||
|
@ -68,31 +68,31 @@ export function ToolbarGraphSelection({
|
|||
}
|
||||
|
||||
function handleExpandOutputs() {
|
||||
onChange([...selected, ...graph.expandOutputs(selected)]);
|
||||
onChange([...value, ...graph.expandOutputs(value)]);
|
||||
}
|
||||
|
||||
function handleExpandInputs() {
|
||||
onChange([...selected, ...graph.expandInputs(selected)]);
|
||||
onChange([...value, ...graph.expandInputs(value)]);
|
||||
}
|
||||
|
||||
function handleSelectMaximize() {
|
||||
selectedMenu.hide();
|
||||
onChange(graph.maximizePart(selected));
|
||||
onChange(graph.maximizePart(value));
|
||||
}
|
||||
|
||||
function handleSelectInvert() {
|
||||
selectedMenu.hide();
|
||||
onChange([...graph.nodes.keys()].filter(item => !selected.includes(item)));
|
||||
onChange([...graph.nodes.keys()].filter(item => !value.includes(item)));
|
||||
}
|
||||
|
||||
function handleSelectAllInputs() {
|
||||
selectedMenu.hide();
|
||||
onChange([...graph.expandInputs(selected)]);
|
||||
onChange([...value, ...graph.expandInputs(value)]);
|
||||
}
|
||||
|
||||
function handleSelectAllOutputs() {
|
||||
selectedMenu.hide();
|
||||
onChange([...graph.expandOutputs(selected)]);
|
||||
onChange([...value, ...graph.expandOutputs(value)]);
|
||||
}
|
||||
|
||||
return (
|
||||
|
@ -166,7 +166,7 @@ export function ToolbarGraphSelection({
|
|||
icon={<IconGroupSelection size='1.25rem' className='icon-primary' />}
|
||||
onClick={groupMenu.toggle}
|
||||
/>
|
||||
<Dropdown isOpen={groupMenu.isOpen} className='-translate-x-1/2'>
|
||||
<Dropdown isOpen={groupMenu.isOpen} stretchLeft>
|
||||
<DropdownButton
|
||||
text='ядро'
|
||||
title='Выделить ядро'
|
||||
|
|
|
@ -33,10 +33,9 @@ export function ViewConstituents({
|
|||
autoScroll
|
||||
}: ViewConstituentsProps) {
|
||||
return (
|
||||
<aside className={cn(!noBorder && 'border', className)}>
|
||||
<div className={cn(!noBorder && 'border', className)}>
|
||||
<ConstituentsSearch
|
||||
schema={schema} //
|
||||
dense={dense}
|
||||
dense={dense} //
|
||||
hideGraphFilter={!activeCst}
|
||||
/>
|
||||
<TableSideConstituents
|
||||
|
@ -47,6 +46,6 @@ export function ViewConstituents({
|
|||
autoScroll={autoScroll}
|
||||
onDoubleClick={onDoubleClick}
|
||||
/>
|
||||
</aside>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
|
|
@ -36,6 +36,7 @@ export function DlgEditCst() {
|
|||
target: target.id,
|
||||
item_data: {
|
||||
alias: target.alias,
|
||||
crucial: target.crucial,
|
||||
cst_type: target.cst_type,
|
||||
convention: target.convention,
|
||||
definition_formal: target.definition_formal,
|
||||
|
|
|
@ -122,7 +122,7 @@ export function EditorConstituenta() {
|
|||
</div>
|
||||
<ViewConstituents
|
||||
className={clsx(
|
||||
'cc-animate-sidebar',
|
||||
'cc-animate-sidebar min-h-55',
|
||||
isNarrow ? 'mt-3 mx-6 rounded-md overflow-hidden' : 'mt-9 rounded-l-md rounded-r-none overflow-visible',
|
||||
showList ? 'max-w-full' : 'opacity-0 max-w-0'
|
||||
)}
|
||||
|
|
Loading…
Reference in New Issue
Block a user