mirror of
https://github.com/IRBorisov/ConceptPortal.git
synced 2025-06-26 04:50:36 +03:00
M: Optimize dialogs height for small screen notebooks
Some checks are pending
Frontend CI / build (22.x) (push) Waiting to run
Some checks are pending
Frontend CI / build (22.x) (push) Waiting to run
This commit is contained in:
parent
aebd1598ee
commit
3edee8450e
|
@ -103,23 +103,19 @@ function Modal({
|
|||
{children}
|
||||
</div>
|
||||
|
||||
<div className={clsx('z-modalControls', 'px-6 py-3 flex gap-12 justify-center')}>
|
||||
<div className='z-modalControls my-2 flex gap-12 justify-center text-sm'>
|
||||
{!readonly ? (
|
||||
<Button
|
||||
autoFocus
|
||||
text={submitText}
|
||||
title={!canSubmit ? submitInvalidTooltip : ''}
|
||||
className='min-w-[8rem] min-h-[2.6rem]'
|
||||
className='min-w-[7rem]'
|
||||
colors='clr-btn-primary'
|
||||
disabled={!canSubmit}
|
||||
onClick={handleSubmit}
|
||||
/>
|
||||
) : null}
|
||||
<Button
|
||||
text={readonly ? 'Закрыть' : 'Отмена'}
|
||||
className='min-w-[8rem] min-h-[2.6rem]'
|
||||
onClick={handleCancel}
|
||||
/>
|
||||
<Button text={readonly ? 'Закрыть' : 'Отмена'} className='min-w-[7rem]' onClick={handleCancel} />
|
||||
</div>
|
||||
</motion.div>
|
||||
</div>
|
||||
|
|
|
@ -160,13 +160,13 @@ function DlgConstituentaTemplate({ hideWindow, schema, onCreate, insertAfter }:
|
|||
<Modal
|
||||
header='Создание конституенты из шаблона'
|
||||
submitText='Создать'
|
||||
className='w-[43rem] h-[36.5rem] px-6'
|
||||
className='w-[43rem] h-[35rem] px-6'
|
||||
hideWindow={hideWindow}
|
||||
canSubmit={validated}
|
||||
beforeSubmit={handlePrompt}
|
||||
onSubmit={handleSubmit}
|
||||
>
|
||||
<Overlay position='top-0 right-[6rem]'>
|
||||
<Overlay position='top-0 right-[5.9rem]'>
|
||||
<BadgeHelp
|
||||
topic={HelpTopic.RSL_TEMPLATES}
|
||||
className={clsx(PARAMETER.TOOLTIP_WIDTH, 'sm:max-w-[40rem]')}
|
||||
|
|
|
@ -118,7 +118,7 @@ function TabTemplate({ state, partialUpdate, templateSchema }: TabTemplateProps)
|
|||
data={filteredData}
|
||||
onSelectValue={cst => partialUpdate({ prototype: cst })}
|
||||
prefixID={prefixes.cst_template_ist}
|
||||
rows={9}
|
||||
rows={8}
|
||||
/>
|
||||
<TextArea
|
||||
id='dlg_template_term'
|
||||
|
|
|
@ -147,7 +147,7 @@ function DlgCreateOperation({ hideWindow, oss, onCreate, initialInputs }: DlgCre
|
|||
hideWindow={hideWindow}
|
||||
canSubmit={isValid}
|
||||
onSubmit={handleSubmit}
|
||||
className='w-[40rem] px-6 min-h-[35rem]'
|
||||
className='w-[40rem] px-6 h-[32rem]'
|
||||
>
|
||||
<Overlay position='top-0 right-0'>
|
||||
<BadgeHelp topic={HelpTopic.CC_OSS} className={clsx(PARAMETER.TOOLTIP_WIDTH, 'sm:max-w-[40rem]')} offset={14} />
|
||||
|
@ -155,11 +155,11 @@ function DlgCreateOperation({ hideWindow, oss, onCreate, initialInputs }: DlgCre
|
|||
|
||||
<Tabs
|
||||
selectedTabClassName='clr-selected'
|
||||
className='flex flex-col'
|
||||
className='flex flex-col pt-2'
|
||||
selectedIndex={activeTab}
|
||||
onSelect={handleSelectTab}
|
||||
>
|
||||
<TabList className={clsx('mb-3 self-center', 'flex', 'border divide-x rounded-none')}>
|
||||
<TabList className={clsx('self-center absolute top-[2.4rem]', 'flex', 'border divide-x rounded-none')}>
|
||||
<TabLabel
|
||||
title={describeOperationType(OperationType.INPUT)}
|
||||
label={labelOperationType(OperationType.INPUT)}
|
||||
|
|
|
@ -169,7 +169,7 @@ function DlgEditOperation({ hideWindow, oss, target, onSubmit }: DlgEditOperatio
|
|||
hideWindow={hideWindow}
|
||||
canSubmit={canSubmit}
|
||||
onSubmit={handleSubmit}
|
||||
className='w-[40rem] px-6 min-h-[35rem]'
|
||||
className='w-[40rem] px-6 h-[32rem]'
|
||||
>
|
||||
<Overlay position='top-0 right-0'>
|
||||
<BadgeHelp topic={HelpTopic.CC_OSS} className={clsx(PARAMETER.TOOLTIP_WIDTH, 'sm:max-w-[40rem]')} offset={14} />
|
||||
|
|
|
@ -35,7 +35,7 @@ function TabSynthesis({
|
|||
<PickSubstitutions
|
||||
schemas={schemas}
|
||||
prefixID={prefixes.dlg_cst_substitutes_list}
|
||||
rows={10}
|
||||
rows={8}
|
||||
substitutions={substitutions}
|
||||
setSubstitutions={setSubstitutions}
|
||||
suggestions={suggestions}
|
||||
|
|
|
@ -70,7 +70,7 @@ function DlgEditReference({ hideWindow, schema, initial, onSave }: DlgEditRefere
|
|||
hideWindow={hideWindow}
|
||||
canSubmit={isValid}
|
||||
onSubmit={handleSubmit}
|
||||
className='w-[40rem] px-6 min-h-[35rem]'
|
||||
className='w-[40rem] px-6 h-[32rem]'
|
||||
>
|
||||
<Overlay position='top-0 right-0'>
|
||||
<BadgeHelp
|
||||
|
|
|
@ -70,7 +70,7 @@ function TabEntityReference({ initial, schema, setIsValid, setReference }: TabEn
|
|||
describeFunc={cst => cst.term_resolved}
|
||||
matchFunc={(cst, filter) => matchConstituenta(cst, filter, CstMatchMode.TERM)}
|
||||
onBeginFilter={cst => cst.term_resolved !== ''}
|
||||
rows={8}
|
||||
rows={7}
|
||||
/>
|
||||
|
||||
<div className='flex gap-3'>
|
||||
|
|
|
@ -96,7 +96,7 @@ function DlgInlineSynthesis({ hideWindow, receiver, onInlineSynthesis }: DlgInli
|
|||
<Modal
|
||||
header='Импорт концептуальной схем'
|
||||
submitText='Добавить конституенты'
|
||||
className='w-[40rem] h-[36rem] px-6'
|
||||
className='w-[40rem] h-[33rem] px-6'
|
||||
hideWindow={hideWindow}
|
||||
canSubmit={validated}
|
||||
onSubmit={handleSubmit}
|
||||
|
|
|
@ -19,7 +19,7 @@ function TabConstituents({ schema, error, loading, selected, setSelected }: TabC
|
|||
<DataLoader id='dlg-constituents-tab' isLoading={loading} error={error} hasNoData={!schema}>
|
||||
<PickMultiConstituenta
|
||||
schema={schema}
|
||||
rows={14}
|
||||
rows={13}
|
||||
prefixID={prefixes.cst_inline_synth_list}
|
||||
selected={selected}
|
||||
setSelected={setSelected}
|
||||
|
|
|
@ -35,7 +35,7 @@ function TabSchema({ selected, setSelected }: TabSchemaProps) {
|
|||
id='dlg_schema_picker' // prettier: split lines
|
||||
items={library.items}
|
||||
itemType={LibraryItemType.RSFORM}
|
||||
rows={15}
|
||||
rows={14}
|
||||
value={selected}
|
||||
onSelectValue={setSelected}
|
||||
/>
|
||||
|
|
Loading…
Reference in New Issue
Block a user