mirror of
https://github.com/IRBorisov/ConceptPortal.git
synced 2025-06-26 13:00:39 +03:00
Fix editor height to improve scroll experience
This commit is contained in:
parent
320a1b1c96
commit
230d17da35
|
@ -23,7 +23,16 @@ import { rsHoverTooltip } from './tooltip';
|
|||
interface RSInputProps
|
||||
extends Pick<
|
||||
ReactCodeMirrorProps,
|
||||
'id' | 'height' | 'minHeight' | 'maxHeight' | 'value' | 'onFocus' | 'onBlur' | 'placeholder' | 'style' | 'className'
|
||||
| 'id' // prettier: split-lines
|
||||
| 'height'
|
||||
| 'minHeight'
|
||||
| 'maxHeight'
|
||||
| 'value'
|
||||
| 'onFocus'
|
||||
| 'onBlur'
|
||||
| 'placeholder'
|
||||
| 'style'
|
||||
| 'className'
|
||||
> {
|
||||
label?: string;
|
||||
disabled?: boolean;
|
||||
|
|
|
@ -50,7 +50,18 @@ const editorSetup: BasicSetupOptions = {
|
|||
};
|
||||
|
||||
interface RefsInputInputProps
|
||||
extends Pick<ReactCodeMirrorProps, 'id' | 'height' | 'value' | 'className' | 'onFocus' | 'onBlur' | 'placeholder'> {
|
||||
extends Pick<
|
||||
ReactCodeMirrorProps,
|
||||
| 'id' // prettier: split-lines
|
||||
| 'height'
|
||||
| 'minHeight'
|
||||
| 'maxHeight'
|
||||
| 'value'
|
||||
| 'className'
|
||||
| 'onFocus'
|
||||
| 'onBlur'
|
||||
| 'placeholder'
|
||||
> {
|
||||
label?: string;
|
||||
onChange?: (newValue: string) => void;
|
||||
schema?: IRSForm;
|
||||
|
|
|
@ -145,6 +145,7 @@ function FormConstituenta({
|
|||
key='cst_term'
|
||||
id='cst_term'
|
||||
label='Термин'
|
||||
maxHeight='7.5rem'
|
||||
placeholder='Обозначение, используемое в текстовых определениях'
|
||||
schema={schema}
|
||||
value={term}
|
||||
|
@ -197,7 +198,8 @@ function FormConstituenta({
|
|||
id='cst_definition'
|
||||
label='Текстовое определение'
|
||||
placeholder='Текстовая интерпретация формального выражения'
|
||||
height='3.8rem'
|
||||
minHeight='3.75rem'
|
||||
maxHeight='7.5rem'
|
||||
schema={schema}
|
||||
value={textDefinition}
|
||||
initialValue={state?.definition_raw ?? ''}
|
||||
|
@ -210,7 +212,7 @@ function FormConstituenta({
|
|||
<TextArea
|
||||
id='cst_convention'
|
||||
spellCheck
|
||||
className='h-[3.8rem]'
|
||||
className='h-[3.75rem]'
|
||||
label={isBasic ? 'Конвенция' : 'Комментарий'}
|
||||
placeholder={isBasic ? 'Договоренность об интерпретации' : 'Пояснение разработчика'}
|
||||
value={convention}
|
||||
|
|
|
@ -211,7 +211,8 @@ function EditorRSExpression({
|
|||
<RSInput
|
||||
ref={rsInput}
|
||||
value={value}
|
||||
minHeight='3.8rem'
|
||||
minHeight='3.75rem'
|
||||
maxHeight='7.5rem'
|
||||
disabled={disabled}
|
||||
onChange={handleChange}
|
||||
onAnalyze={handleCheckExpression}
|
||||
|
|
Loading…
Reference in New Issue
Block a user