Auto-maximize attached files on open (#9472)

Signed-off-by: Alexander Platov <alexander.platov@hardcoreeng.com>
This commit is contained in:
Alexander Platov
2025-07-05 11:33:21 +07:00
committed by GitHub
parent 8b5bfc35d1
commit 89d8a6fd03
7 changed files with 61 additions and 13 deletions
+2 -1
View File
@@ -30,6 +30,7 @@
export let canSave: boolean = false
export let okLabel: IntlString = ui.string.Ok
export let padding: string | undefined = undefined
export let bottomPadding: string | undefined = undefined
export let hidden: boolean = false
export let noTopIndent: boolean = false
export let hideFooter: boolean = false
@@ -89,7 +90,7 @@
{#if scrollableContent}
<Scroller
padding={padding ?? typePadding}
bottomPadding={type === 'type-popup'
bottomPadding={bottomPadding ?? type === 'type-popup'
? undefined
: type === 'type-aside'
? 'var(--spacing-2)'
@@ -40,6 +40,7 @@
initialProps = Object.assign(initialProps, props)
}
const WINDOW_PADDING = 1
const ALLOW_ANIMATION = false // Fullsize animation
interface PopupParams {
x: number
@@ -51,7 +52,7 @@
let modalHTML: HTMLElement
let componentInstance: any
let docSize: boolean = false
let fullSize: boolean = false
let fullSize: boolean = initialProps?.fullSize ?? false
let clientWidth = -1
let clientHeight = -1
@@ -282,7 +283,7 @@
id={popup.options.refId}
class="popup {testing ? 'endShow' : showing === undefined ? 'endShow' : !showing ? 'preShow' : 'startShow'}"
class:testing
class:anim={(element === 'float' || element === 'centered') && !testing && !drag}
class:anim={(element === 'float' || element === 'centered') && !testing && !drag && ALLOW_ANIMATION}
bind:this={modalHTML}
style={`z-index: ${zIndex};`}
style:top={options?.props?.top}