mirror of
https://github.com/zadam/trilium.git
synced 2025-10-26 15:56:29 +01:00
handle views without clientSize
This commit is contained in:
@@ -348,11 +348,14 @@ const Split = (idsOption, options = {}) => {
|
||||
|
||||
function innerSize(element) {
|
||||
// Return nothing if getComputedStyle is not supported (< IE9)
|
||||
// Or if parent element has no layout yet
|
||||
if (!getComputedStyle) return null
|
||||
|
||||
const computedStyle = getComputedStyle(element)
|
||||
let size = element[clientSize]
|
||||
|
||||
if (size === 0) return null
|
||||
|
||||
if (direction === HORIZONTAL) {
|
||||
size -=
|
||||
parseFloat(computedStyle.paddingLeft) +
|
||||
|
||||
Reference in New Issue
Block a user