mirror of
https://github.com/IRBorisov/ConceptPortal.git
synced 2025-06-26 13:00:39 +03:00
Minor fixes
This commit is contained in:
parent
0fe2360886
commit
de86365e86
|
@ -19,12 +19,14 @@ import UserProfilePage from './pages/UserProfilePage';
|
||||||
function App () {
|
function App () {
|
||||||
const { noNavigation } = useConceptTheme();
|
const { noNavigation } = useConceptTheme();
|
||||||
|
|
||||||
const scrollWindowSize = useMemo(() => {
|
const scrollWindowSize = useMemo(
|
||||||
|
() => {
|
||||||
return !noNavigation ?
|
return !noNavigation ?
|
||||||
'max-h-[calc(100vh-4.5rem)]'
|
'max-h-[calc(100vh-4.5rem)]'
|
||||||
: 'max-h-[100vh]';
|
: 'max-h-[100vh]';
|
||||||
}, [noNavigation]);
|
}, [noNavigation]);
|
||||||
const mainSize = useMemo(() => {
|
const mainSize = useMemo(
|
||||||
|
() => {
|
||||||
return !noNavigation ?
|
return !noNavigation ?
|
||||||
'min-h-[calc(100vh-12rem)]'
|
'min-h-[calc(100vh-12rem)]'
|
||||||
: 'min-h-[calc(100vh-8rem)] ';
|
: 'min-h-[calc(100vh-8rem)] ';
|
||||||
|
|
|
@ -28,9 +28,9 @@ function Footer() {
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
<div className='max-w-xl px-4 text-sm'>
|
<div className='max-w-[28rem] px-4 text-sm'>
|
||||||
<p className='mt-0.5'>© 2023 ЦИВТ КОНЦЕПТ</p>
|
<p className='mt-0.5'>© 2023 ЦИВТ КОНЦЕПТ</p>
|
||||||
<p>Данный инструмент работы с экспликациями концептуальных схем в родоструктурной форме является уникальной Российской разработкой и вобрал в себя разработки начиная с 1990-х годов</p>
|
<p>Портал позволяет анализировать предметные области, формально записывать системы определений и синтезировать их с помощью математического аппарата родов структур</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</footer >
|
</footer >
|
||||||
|
|
|
@ -10,12 +10,14 @@ import SubmitButton from '../components/Common/SubmitButton';
|
||||||
import TextArea from '../components/Common/TextArea';
|
import TextArea from '../components/Common/TextArea';
|
||||||
import TextInput from '../components/Common/TextInput';
|
import TextInput from '../components/Common/TextInput';
|
||||||
import RequireAuth from '../components/RequireAuth';
|
import RequireAuth from '../components/RequireAuth';
|
||||||
|
import { useLibrary } from '../context/LibraryContext';
|
||||||
import useNewRSForm from '../hooks/useNewRSForm';
|
import useNewRSForm from '../hooks/useNewRSForm';
|
||||||
import { IRSFormCreateData, IRSFormMeta } from '../utils/models';
|
import { IRSFormCreateData, IRSFormMeta } from '../utils/models';
|
||||||
|
|
||||||
function CreateRSFormPage() {
|
function CreateRSFormPage() {
|
||||||
const navigate = useNavigate();
|
const navigate = useNavigate();
|
||||||
const { createSchema, error, setError, loading } = useNewRSForm()
|
const { createSchema, error, setError, loading } = useNewRSForm();
|
||||||
|
const library = useLibrary();
|
||||||
|
|
||||||
const [title, setTitle] = useState('');
|
const [title, setTitle] = useState('');
|
||||||
const [alias, setAlias] = useState('');
|
const [alias, setAlias] = useState('');
|
||||||
|
@ -37,6 +39,7 @@ function CreateRSFormPage() {
|
||||||
|
|
||||||
function onSuccess(newSchema: IRSFormMeta) {
|
function onSuccess(newSchema: IRSFormMeta) {
|
||||||
toast.success('Схема успешно создана');
|
toast.success('Схема успешно создана');
|
||||||
|
library.reload();
|
||||||
navigate(`/rsforms/${newSchema.id}`);
|
navigate(`/rsforms/${newSchema.id}`);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -18,7 +18,7 @@ interface ViewSideConstituentsProps {
|
||||||
}
|
}
|
||||||
|
|
||||||
function ViewSideConstituents({ expression, activeID, onOpenEdit }: ViewSideConstituentsProps) {
|
function ViewSideConstituents({ expression, activeID, onOpenEdit }: ViewSideConstituentsProps) {
|
||||||
const { darkMode } = useConceptTheme();
|
const { darkMode, noNavigation } = useConceptTheme();
|
||||||
const { schema } = useRSForm();
|
const { schema } = useRSForm();
|
||||||
|
|
||||||
const [filterMatch, setFilterMatch] = useLocalStorage('side-filter-match', CstMatchMode.ALL);
|
const [filterMatch, setFilterMatch] = useLocalStorage('side-filter-match', CstMatchMode.ALL);
|
||||||
|
@ -139,8 +139,16 @@ function ViewSideConstituents({ expression, activeID, onOpenEdit }: ViewSideCons
|
||||||
], []
|
], []
|
||||||
);
|
);
|
||||||
|
|
||||||
|
const maxHeight = useMemo(
|
||||||
|
() => {
|
||||||
|
// TODO: calculate hieght based on left editor column height
|
||||||
|
return !noNavigation ?
|
||||||
|
'max-h-[calc(100vh-10.3rem)]'
|
||||||
|
: 'max-h-[calc(100vh-10.3rem)] ';
|
||||||
|
}, [noNavigation]);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className='max-h-[80vh] min-h-[40rem] overflow-y-scroll border flex-grow w-full'>
|
<div className={`${maxHeight} min-h-[40rem] overflow-y-scroll border flex-grow w-full`}>
|
||||||
<div className='sticky top-0 left-0 right-0 z-10 flex items-center justify-between w-full gap-1 px-2 py-1 bg-white border-b-2 border-gray-400 rounded dark:bg-gray-700 dark:border-gray-300'>
|
<div className='sticky top-0 left-0 right-0 z-10 flex items-center justify-between w-full gap-1 px-2 py-1 bg-white border-b-2 border-gray-400 rounded dark:bg-gray-700 dark:border-gray-300'>
|
||||||
<div className='flex items-center justify-between w-full'>
|
<div className='flex items-center justify-between w-full'>
|
||||||
<MatchModePicker value={filterMatch} onChange={setFilterMatch}/>
|
<MatchModePicker value={filterMatch} onChange={setFilterMatch}/>
|
||||||
|
|
Loading…
Reference in New Issue
Block a user