mirror of
https://github.com/IRBorisov/ConceptPortal.git
synced 2025-06-26 13:00:39 +03:00
Minor UI fixes for editor
This commit is contained in:
parent
f64f6a6c3d
commit
ec75cb866c
|
@ -11,6 +11,7 @@ function ConceptTooltip({
|
||||||
className,
|
className,
|
||||||
layer='z-tooltip',
|
layer='z-tooltip',
|
||||||
place='bottom',
|
place='bottom',
|
||||||
|
style,
|
||||||
...props
|
...props
|
||||||
}: ConceptTooltipProps) {
|
}: ConceptTooltipProps) {
|
||||||
const { darkMode } = useConceptTheme();
|
const { darkMode } = useConceptTheme();
|
||||||
|
@ -18,6 +19,7 @@ function ConceptTooltip({
|
||||||
return (
|
return (
|
||||||
<Tooltip
|
<Tooltip
|
||||||
opacity={0.97}
|
opacity={0.97}
|
||||||
|
style={{...{ paddingTop: '2px', paddingBottom: '2px'}, ...style}}
|
||||||
className={`overflow-auto border shadow-md ${layer} ${className}`}
|
className={`overflow-auto border shadow-md ${layer} ${className}`}
|
||||||
variant={(darkMode ? 'dark' : 'light')}
|
variant={(darkMode ? 'dark' : 'light')}
|
||||||
place={place}
|
place={place}
|
||||||
|
|
|
@ -12,7 +12,7 @@ function InfoCstClass({ title }: InfoCstClassProps) {
|
||||||
const { colors } = useConceptTheme();
|
const { colors } = useConceptTheme();
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className='flex flex-col gap-1'>
|
<div className='flex flex-col gap-1 mb-2'>
|
||||||
{ title && <h1>{title}</h1>}
|
{ title && <h1>{title}</h1>}
|
||||||
{ Object.values(CstClass).map(
|
{ Object.values(CstClass).map(
|
||||||
(cclass, index) => {
|
(cclass, index) => {
|
||||||
|
|
|
@ -12,7 +12,7 @@ function InfoCstStatus({ title }: InfoCstStatusProps) {
|
||||||
const { colors } = useConceptTheme();
|
const { colors } = useConceptTheme();
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className='flex flex-col gap-1'>
|
<div className='flex flex-col gap-1 h-fit mb-2'>
|
||||||
{ title && <h1>{title}</h1>}
|
{ title && <h1>{title}</h1>}
|
||||||
{ Object.values(ExpressionStatus)
|
{ Object.values(ExpressionStatus)
|
||||||
.filter(status => status !== ExpressionStatus.UNDEFINED)
|
.filter(status => status !== ExpressionStatus.UNDEFINED)
|
||||||
|
|
|
@ -14,7 +14,7 @@ function Navigation () {
|
||||||
const navigateCreateNew = () => navigateTo('/rsform-create');
|
const navigateCreateNew = () => navigateTo('/rsform-create');
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<nav className='sticky top-0 left-0 right-0 select-none z-navigation h-fit'>
|
<nav className='sticky top-0 left-0 right-0 select-none clr-app z-navigation h-fit'>
|
||||||
{!noNavigation &&
|
{!noNavigation &&
|
||||||
<button
|
<button
|
||||||
title='Скрыть навигацию'
|
title='Скрыть навигацию'
|
||||||
|
|
|
@ -161,8 +161,8 @@ function EditorConstituenta({
|
||||||
}
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className='flex max-w-[1500px] gap-2' tabIndex={-1} onKeyDown={handleInput}>
|
<div className='flex max-w-[1500px]' tabIndex={-1} onKeyDown={handleInput}>
|
||||||
<form onSubmit={handleSubmit} className='min-w-[50rem] max-w-[50rem] px-4 py-1'>
|
<form onSubmit={handleSubmit} className='min-w-[47.8rem] max-w-[47.8rem] px-4 py-1'>
|
||||||
<div className='relative w-full'>
|
<div className='relative w-full'>
|
||||||
<div className='absolute top-0 right-0 flex items-start justify-between w-full'>
|
<div className='absolute top-0 right-0 flex items-start justify-between w-full'>
|
||||||
{activeCst &&
|
{activeCst &&
|
||||||
|
|
|
@ -85,8 +85,8 @@ interface RSEditorControlsProps {
|
||||||
|
|
||||||
function RSEditorControls({ onEdit, disabled }: RSEditorControlsProps) {
|
function RSEditorControls({ onEdit, disabled }: RSEditorControlsProps) {
|
||||||
return (
|
return (
|
||||||
<div className='flex items-center justify-between w-full text-sm'>
|
<div className='flex items-center justify-start w-full text-sm'>
|
||||||
<div className='border-r w-fit'>
|
<div className='w-fit'>
|
||||||
<div className='flex justify-start'>
|
<div className='flex justify-start'>
|
||||||
{MAIN_FIRST_ROW.map(
|
{MAIN_FIRST_ROW.map(
|
||||||
(token) =>
|
(token) =>
|
||||||
|
@ -110,7 +110,7 @@ function RSEditorControls({ onEdit, disabled }: RSEditorControlsProps) {
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div className='border-l w-fit'>
|
<div className='w-fit'>
|
||||||
<div className='flex justify-start'>
|
<div className='flex justify-start'>
|
||||||
{SECONDARY_FIRST_ROW.map(
|
{SECONDARY_FIRST_ROW.map(
|
||||||
({text, tooltip}) =>
|
({text, tooltip}) =>
|
||||||
|
|
|
@ -107,7 +107,7 @@ function RSItemsMenu({
|
||||||
<div className='ml-1' id='items-table-help'>
|
<div className='ml-1' id='items-table-help'>
|
||||||
<HelpIcon color='text-primary' size={5} />
|
<HelpIcon color='text-primary' size={5} />
|
||||||
</div>
|
</div>
|
||||||
<ConceptTooltip anchorSelect='#items-table-help' offset={30}>
|
<ConceptTooltip anchorSelect='#items-table-help' offset={8}>
|
||||||
<HelpRSFormItems />
|
<HelpRSFormItems />
|
||||||
</ConceptTooltip>
|
</ConceptTooltip>
|
||||||
</div>);
|
</div>);
|
||||||
|
|
Loading…
Reference in New Issue
Block a user