M: Minor UI improvements
This commit is contained in:
parent
3e707eb933
commit
a919cf6baa
|
@ -301,12 +301,13 @@ export const OssState = ({ itemID, children }: OssStateProps) => {
|
|||
onError: setProcessingError,
|
||||
onSuccess: newData => {
|
||||
oss.setData(newData);
|
||||
library.localUpdateTimestamp(newData.id);
|
||||
library.reloadItems(() => {
|
||||
if (callback) callback();
|
||||
});
|
||||
}
|
||||
});
|
||||
},
|
||||
[itemID, model, library.localUpdateTimestamp, oss.setData]
|
||||
[itemID, model, library.reloadItems, oss.setData]
|
||||
);
|
||||
|
||||
const updateOperation = useCallback(
|
||||
|
|
|
@ -39,7 +39,7 @@ function DlgCreateCst({ hideWindow, initial, schema, onCreate }: DlgCreateCstPro
|
|||
canSubmit={validated}
|
||||
onSubmit={handleSubmit}
|
||||
submitText='Создать'
|
||||
className='cc-column w-[35rem] h-[30rem] py-2 px-6'
|
||||
className='cc-column w-[35rem] max-h-[30rem] py-2 px-6'
|
||||
>
|
||||
<FormCreateCst schema={schema} state={cstData} partialUpdate={updateCstData} setValidated={setValidated} />
|
||||
</Modal>
|
||||
|
|
|
@ -15,9 +15,9 @@ import {
|
|||
IconShare
|
||||
} from '@/components/Icons';
|
||||
import Button from '@/components/ui/Button';
|
||||
import DropdownDivider from '@/components/ui/DropdownDivider';
|
||||
import Dropdown from '@/components/ui/Dropdown';
|
||||
import DropdownButton from '@/components/ui/DropdownButton';
|
||||
import DropdownDivider from '@/components/ui/DropdownDivider';
|
||||
import { useAccessMode } from '@/context/AccessModeContext';
|
||||
import { useAuth } from '@/context/AuthContext';
|
||||
import { useConceptNavigation } from '@/context/NavigationContext';
|
||||
|
|
|
@ -85,6 +85,11 @@ function MenuRSTabs({ onDestroy }: MenuRSTabsProps) {
|
|||
controller.share();
|
||||
}
|
||||
|
||||
function handleCreateVersion() {
|
||||
schemaMenu.hide();
|
||||
controller.createVersion();
|
||||
}
|
||||
|
||||
function handleReindex() {
|
||||
editMenu.hide();
|
||||
controller.reindex();
|
||||
|
@ -161,7 +166,7 @@ function MenuRSTabs({ onDestroy }: MenuRSTabsProps) {
|
|||
<DropdownButton
|
||||
text='Сохранить версию'
|
||||
disabled={!controller.isContentEditable}
|
||||
onClick={controller.createVersion}
|
||||
onClick={handleCreateVersion}
|
||||
icon={<IconNewVersion size='1rem' className='icon-green' />}
|
||||
/>
|
||||
<DropdownButton
|
||||
|
|
Loading…
Reference in New Issue
Block a user