onekijs-ui 1.0.3 → 1.0.4
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.
- package/dist/components/list/typings.d.ts +1 -1
- package/dist/components/select/SelectService.d.ts +3 -3
- package/dist/components/wizard/WizardModal.d.ts +2 -2
- package/dist/components/wizard/index.d.ts +2 -2
- package/dist/index.js +14 -5
- package/dist/index.js.map +1 -1
- package/dist/index.module.js +14 -5
- package/dist/index.module.js.map +1 -1
- package/package.json +2 -2
- package/src/components/list/typings.ts +1 -1
- package/src/components/tooltip/components/TooltipComponent.tsx +7 -2
- package/src/vendor/reactVirtual.js +12 -3
|
@@ -77,7 +77,7 @@ export type ListConfig<T = any, I extends ListItem<T> = ListItem<T>> = {
|
|
|
77
77
|
onItemUnselect?: ListItemHandler<T, I>;
|
|
78
78
|
paddingEnd?: number;
|
|
79
79
|
paddingStart?: number;
|
|
80
|
-
parentRef?: React.RefObject<HTMLDivElement>;
|
|
80
|
+
parentRef?: React.RefObject<HTMLDivElement | null>;
|
|
81
81
|
overscan?: number;
|
|
82
82
|
preload?: number;
|
|
83
83
|
style?: React.CSSProperties;
|
|
@@ -5,17 +5,17 @@ declare class SelectService<T = any, I extends SelectItem<T> = SelectItem<T>, S
|
|
|
5
5
|
protected lastCheckQuery: Query | undefined;
|
|
6
6
|
get defaultValue(): T | T[] | null | undefined;
|
|
7
7
|
get defaultValueLoading(): boolean | undefined;
|
|
8
|
-
check(): Generator<void | import("redux-saga/effects").AllEffect<import("redux-saga/effects").CallEffect<Generator<I[] | Generator<void | import("redux-saga/effects").
|
|
8
|
+
check(): Generator<void | import("redux-saga/effects").AllEffect<import("redux-saga/effects").CallEffect<Generator<I[] | Generator<void | import("redux-saga/effects").CancelEffect | CollectionFetcherResult<T> | import("redux-saga/effects").ForkEffect<Generator<void | import("redux-saga/effects").CallEffect<true>, void, unknown>> | Promise<CollectionFetcherResult<T> | undefined>, CollectionFetcherResult<T>, (import("redux-saga").Task<any> | null) & (CollectionFetcherResult<T> & (CollectionFetcherResult<T> | undefined))>, I | undefined, I[] & CollectionFetcherResult<T>>>> | import("redux-saga/effects").AllEffect<Generator<I[] | Generator<void | import("redux-saga/effects").CancelEffect | CollectionFetcherResult<T> | import("redux-saga/effects").ForkEffect<Generator<void | import("redux-saga/effects").CallEffect<true>, void, unknown>> | Promise<CollectionFetcherResult<T> | undefined>, CollectionFetcherResult<T>, (import("redux-saga").Task<any> | null) & (CollectionFetcherResult<T> & (CollectionFetcherResult<T> | undefined))>, I | undefined, I[] & CollectionFetcherResult<T>>> | import("redux-saga/effects").CallEffect<void>, void, (I | undefined)[]>;
|
|
9
9
|
get status(): CollectionStatus;
|
|
10
10
|
setData(data: T[], query?: Query): void;
|
|
11
|
-
setDefaultValue(value: T | T[] | null | undefined): Generator<void | Generator<void | import("redux-saga/effects").AllEffect<import("redux-saga/effects").CallEffect<Generator<I[] | Generator<void | import("redux-saga/effects").
|
|
11
|
+
setDefaultValue(value: T | T[] | null | undefined): Generator<void | Generator<void | import("redux-saga/effects").AllEffect<import("redux-saga/effects").CallEffect<Generator<I[] | Generator<void | import("redux-saga/effects").CancelEffect | CollectionFetcherResult<T> | import("redux-saga/effects").ForkEffect<Generator<void | import("redux-saga/effects").CallEffect<true>, void, unknown>> | Promise<CollectionFetcherResult<T> | undefined>, CollectionFetcherResult<T>, (import("redux-saga").Task<any> | null) & (CollectionFetcherResult<T> & (CollectionFetcherResult<T> | undefined))>, I | undefined, I[] & CollectionFetcherResult<T>>>> | import("redux-saga/effects").AllEffect<Generator<I[] | Generator<void | import("redux-saga/effects").CancelEffect | CollectionFetcherResult<T> | import("redux-saga/effects").ForkEffect<Generator<void | import("redux-saga/effects").CallEffect<true>, void, unknown>> | Promise<CollectionFetcherResult<T> | undefined>, CollectionFetcherResult<T>, (import("redux-saga").Task<any> | null) & (CollectionFetcherResult<T> & (CollectionFetcherResult<T> | undefined))>, I | undefined, I[] & CollectionFetcherResult<T>>> | import("redux-saga/effects").CallEffect<void>, void, (I | undefined)[]>, void, unknown>;
|
|
12
12
|
setDefaultValueLoading(loading: boolean): void;
|
|
13
13
|
setInputValue(value: string | null): Generator<void | T | Promise<T | null> | null, void, T>;
|
|
14
14
|
setItemWidth(_item: I, value: number): void;
|
|
15
15
|
setValue(value: null | T | T[]): void;
|
|
16
16
|
setUrl(url: string, query?: Query): void;
|
|
17
17
|
_buildItem(data: T | null | undefined, adaptee: unknown, context?: AnonymousObject): I;
|
|
18
|
-
_filterItem(item: I | undefined, query: Query, valid: boolean): Generator<I[] | Generator<void | import("redux-saga/effects").
|
|
18
|
+
_filterItem(item: I | undefined, query: Query, valid: boolean): Generator<I[] | Generator<void | import("redux-saga/effects").CancelEffect | CollectionFetcherResult<T> | import("redux-saga/effects").ForkEffect<Generator<void | import("redux-saga/effects").CallEffect<true>, void, unknown>> | Promise<CollectionFetcherResult<T> | undefined>, CollectionFetcherResult<T>, (import("redux-saga").Task<any> | null) & (CollectionFetcherResult<T> & (CollectionFetcherResult<T> | undefined))>, I | undefined, I[] & CollectionFetcherResult<T>>;
|
|
19
19
|
_compareItem(a: I | undefined, b: I | undefined): boolean;
|
|
20
20
|
_doSearch(search: Primitive | undefined): boolean;
|
|
21
21
|
_setDefaultValue(value: T | T[] | null | undefined): void;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
declare const WizardModal: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("../..").ModalProps & Omit<import("../..").TabsProps, "
|
|
1
|
+
declare const WizardModal: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("../..").ModalProps & Omit<import("../..").TabsProps, "controller" | "TitleComponent" | "Component"> & {
|
|
2
2
|
cancelLabel?: import("react").ReactNode;
|
|
3
3
|
controller?: import("./WizardService").WizardService;
|
|
4
4
|
Component?: import("onekijs-framework").FCC<Omit<import("./typings").WizardProps, "Component">>;
|
|
@@ -19,7 +19,7 @@ declare const WizardModal: import("styled-components/dist/types").IStyledCompone
|
|
|
19
19
|
hasSummaryStep?: boolean;
|
|
20
20
|
} & {
|
|
21
21
|
children?: import("react").ReactNode | undefined;
|
|
22
|
-
}, never> & Partial<Pick<import("../..").ModalProps & Omit<import("../..").TabsProps, "
|
|
22
|
+
}, never> & Partial<Pick<import("../..").ModalProps & Omit<import("../..").TabsProps, "controller" | "TitleComponent" | "Component"> & {
|
|
23
23
|
cancelLabel?: import("react").ReactNode;
|
|
24
24
|
controller?: import("./WizardService").WizardService;
|
|
25
25
|
Component?: import("onekijs-framework").FCC<Omit<import("./typings").WizardProps, "Component">>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
declare const Wizard: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<Omit<import("../..").TabsProps, "
|
|
1
|
+
declare const Wizard: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<Omit<import("../..").TabsProps, "controller" | "TitleComponent" | "Component"> & {
|
|
2
2
|
cancelLabel?: import("react").ReactNode;
|
|
3
3
|
controller?: import("./WizardService").WizardService;
|
|
4
4
|
Component?: import("onekijs-framework").FCC<Omit<import("./typings").WizardProps, "Component">>;
|
|
@@ -19,7 +19,7 @@ declare const Wizard: import("styled-components/dist/types").IStyledComponentBas
|
|
|
19
19
|
hasSummaryStep?: boolean;
|
|
20
20
|
} & {
|
|
21
21
|
children?: import("react").ReactNode | undefined;
|
|
22
|
-
}, never> & Partial<Pick<Omit<import("../..").TabsProps, "
|
|
22
|
+
}, never> & Partial<Pick<Omit<import("../..").TabsProps, "controller" | "TitleComponent" | "Component"> & {
|
|
23
23
|
cancelLabel?: import("react").ReactNode;
|
|
24
24
|
controller?: import("./WizardService").WizardService;
|
|
25
25
|
Component?: import("onekijs-framework").FCC<Omit<import("./typings").WizardProps, "Component">>;
|
package/dist/index.js
CHANGED
|
@@ -1705,7 +1705,7 @@ const TooltipComponent = (props) => {
|
|
|
1705
1705
|
const [show, setShow] = React.useState(true);
|
|
1706
1706
|
const [open, setOpen] = React.useState(false);
|
|
1707
1707
|
const arrowRef = React.useRef(null);
|
|
1708
|
-
const { context, floatingStyles, middlewareData, refs } = react.useFloating({
|
|
1708
|
+
const { context, floatingStyles, middlewareData, placement: resolvedPlacement, refs } = react.useFloating({
|
|
1709
1709
|
open,
|
|
1710
1710
|
onOpenChange: setOpen,
|
|
1711
1711
|
placement,
|
|
@@ -1737,7 +1737,7 @@ const TooltipComponent = (props) => {
|
|
|
1737
1737
|
document.removeEventListener('tooltipVisible', listener);
|
|
1738
1738
|
};
|
|
1739
1739
|
}, [uid]);
|
|
1740
|
-
const element = (jsxRuntimeExports.jsxs("div", { ref: refs.setFloating, style: floatingStyles, ...getFloatingProps({ className: 'o-tooltip-container' }), children: [jsxRuntimeExports.jsx("div", { ref: arrowRef, className: "o-tooltip-arrow", style: { left: middlewareData.arrow?.x, top: middlewareData.arrow?.y } }), content] }));
|
|
1740
|
+
const element = (jsxRuntimeExports.jsxs("div", { ref: refs.setFloating, style: floatingStyles, "data-popper-placement": resolvedPlacement, ...getFloatingProps({ className: 'o-tooltip-container' }), children: [jsxRuntimeExports.jsx("div", { ref: arrowRef, className: "o-tooltip-arrow", style: { left: middlewareData.arrow?.x, top: middlewareData.arrow?.y } }), content] }));
|
|
1741
1741
|
if (attachToBody) {
|
|
1742
1742
|
return (jsxRuntimeExports.jsxs("div", { ref: refs.setReference, ...getReferenceProps(), children: [children, show && open && content && ReactDOM.createPortal(jsxRuntimeExports.jsx("div", { className: classNames, children: element }), document.body)] }));
|
|
1743
1743
|
}
|
|
@@ -5183,7 +5183,10 @@ const useElementScroll = ({ parentRef, horizontal, useObserver, initialRect }) =
|
|
|
5183
5183
|
const [scrollOffset, setScrollOffset] = React.useState(0);
|
|
5184
5184
|
const [element, setElement] = React.useState(parentRef.current);
|
|
5185
5185
|
useIsomorphicLayoutEffect(() => {
|
|
5186
|
-
|
|
5186
|
+
const currentElement = parentRef.current;
|
|
5187
|
+
if (currentElement !== element) {
|
|
5188
|
+
setElement(currentElement);
|
|
5189
|
+
}
|
|
5187
5190
|
});
|
|
5188
5191
|
useIsomorphicLayoutEffect(() => {
|
|
5189
5192
|
if (!element) {
|
|
@@ -5220,7 +5223,10 @@ const useWindowRect = (windowRef, initialRect = { width: 0, height: 0 }) => {
|
|
|
5220
5223
|
const [rect, setRect] = React.useState(initialRect);
|
|
5221
5224
|
const [element, setElement] = React.useState(windowRef.current);
|
|
5222
5225
|
useIsomorphicLayoutEffect(() => {
|
|
5223
|
-
|
|
5226
|
+
const currentElement = windowRef.current;
|
|
5227
|
+
if (currentElement !== element) {
|
|
5228
|
+
setElement(currentElement);
|
|
5229
|
+
}
|
|
5224
5230
|
});
|
|
5225
5231
|
useIsomorphicLayoutEffect(() => {
|
|
5226
5232
|
if (!element) {
|
|
@@ -5248,7 +5254,10 @@ const useWindowScroll = ({ windowRef, parentRef, horizontal, useWindowObserver,
|
|
|
5248
5254
|
const rectKey = horizontal ? 'left' : 'top';
|
|
5249
5255
|
const scrollKey = horizontal ? 'scrollX' : 'scrollY';
|
|
5250
5256
|
useIsomorphicLayoutEffect(() => {
|
|
5251
|
-
|
|
5257
|
+
const currentElement = windowRef.current;
|
|
5258
|
+
if (currentElement !== element) {
|
|
5259
|
+
setElement(currentElement);
|
|
5260
|
+
}
|
|
5252
5261
|
});
|
|
5253
5262
|
useIsomorphicLayoutEffect(() => {
|
|
5254
5263
|
if (!element) {
|