@linzjs/windows 5.6.0 → 5.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -4,7 +4,16 @@ import '@linzjs/lui/dist/scss/base.scss';
4
4
 
5
5
  import clsx from 'clsx';
6
6
  import { NumberSize } from 're-resizable';
7
- import { PropsWithChildren, ReactElement, useCallback, useContext, useEffect, useRef, useState } from 'react';
7
+ import {
8
+ forwardRef,
9
+ PropsWithChildren,
10
+ ReactElement,
11
+ useCallback,
12
+ useContext,
13
+ useEffect,
14
+ useRef,
15
+ useState,
16
+ } from 'react';
8
17
  import { createPortal } from 'react-dom';
9
18
 
10
19
  import { useConstFunction } from '../common';
@@ -136,6 +145,13 @@ export interface PanelContentProps {
136
145
  className?: string | undefined;
137
146
  }
138
147
 
139
- export const PanelContent = ({ children, className }: PropsWithChildren<PanelContentProps>) => (
140
- <div className={clsx(`WindowPanel-content`, className)}>{children}</div>
141
- );
148
+ export const PanelContent = forwardRef<HTMLDivElement, PropsWithChildren<PanelContentProps>>(function PanelContentFr(
149
+ { children, className },
150
+ ref,
151
+ ) {
152
+ return (
153
+ <div className={clsx(`WindowPanel-content`, className)} ref={ref}>
154
+ {children}
155
+ </div>
156
+ );
157
+ });
package/package.json CHANGED
@@ -13,7 +13,7 @@
13
13
  "popout"
14
14
  ],
15
15
  "main": "./dist/index.ts",
16
- "version": "5.6.0",
16
+ "version": "5.7.0",
17
17
  "peerDependencies": {
18
18
  "@linzjs/lui": ">=21",
19
19
  "lodash-es": ">=4",