@egjs/react-flicking 4.2.5 → 4.4.1

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.
@@ -21,13 +21,15 @@ import {
21
21
  AfterResizeEvent,
22
22
  ReachEdgeEvent,
23
23
  PanelChangeEvent,
24
- Plugin
24
+ Plugin,
25
+ Status
25
26
  } from "@egjs/flicking";
26
27
 
27
28
  export interface FlickingProps {
28
29
  viewportTag: keyof JSX.IntrinsicElements;
29
30
  cameraTag: keyof JSX.IntrinsicElements;
30
31
  plugins: Plugin[];
32
+ status?: Status;
31
33
  useFindDOMNode: boolean;
32
34
  hideBeforeInit: boolean;
33
35
  firstPanelSize?: string;
@@ -1,8 +0,0 @@
1
- import * as React from "react";
2
- import ReactPanelComponent from "./ReactPanelComponent";
3
- declare class NonStrictPanelComponent extends React.Component implements ReactPanelComponent {
4
- hide: boolean;
5
- get element(): HTMLElement;
6
- render(): React.ReactNode;
7
- }
8
- export default NonStrictPanelComponent;
@@ -1,9 +0,0 @@
1
- import { ExternalPanel } from "@egjs/flicking";
2
- import NonStrictPanelComponent from "./NonStrictPanelComponent";
3
- declare class ReactPanel extends ExternalPanel<NonStrictPanelComponent> {
4
- get element(): HTMLElement;
5
- get rendered(): boolean;
6
- markForShow(): void;
7
- markForHide(): void;
8
- }
9
- export default ReactPanel;
@@ -1,6 +0,0 @@
1
- /// <reference types="react" />
2
- interface ReactPanelComponent extends React.Component {
3
- hide: boolean;
4
- element: HTMLElement;
5
- }
6
- export default ReactPanelComponent;
@@ -1,10 +0,0 @@
1
- import * as React from "react";
2
- import ReactPanelComponent from "./ReactPanelComponent";
3
- declare class StrictPanelComponent extends React.Component implements ReactPanelComponent {
4
- hide: boolean;
5
- private _elRef;
6
- get element(): HTMLElement;
7
- render(): JSX.Element;
8
- private _getElement;
9
- }
10
- export default StrictPanelComponent;
@@ -1,18 +0,0 @@
1
- import * as React from "react";
2
- import { findDOMNode } from "react-dom";
3
-
4
- import ReactPanelComponent from "./ReactPanelComponent";
5
-
6
- class NonStrictPanelComponent extends React.Component implements ReactPanelComponent {
7
- public hide: boolean = false;
8
-
9
- public get element() { return findDOMNode(this) as HTMLElement; }
10
-
11
- public render() {
12
- return this.hide
13
- ? <></>
14
- : this.props.children;
15
- }
16
- }
17
-
18
- export default NonStrictPanelComponent;
@@ -1,20 +0,0 @@
1
- import { ExternalPanel } from "@egjs/flicking";
2
-
3
- import NonStrictPanelComponent from "./NonStrictPanelComponent";
4
-
5
- class ReactPanel extends ExternalPanel<NonStrictPanelComponent> {
6
- public get element() {
7
- return this._externalComponent.element as HTMLElement;
8
- }
9
- public get rendered() { return !this._externalComponent.hide; }
10
-
11
- public markForShow() {
12
- this._externalComponent.hide = false;
13
- }
14
-
15
- public markForHide() {
16
- this._externalComponent.hide = true;
17
- }
18
- }
19
-
20
- export default ReactPanel;
@@ -1,6 +0,0 @@
1
- interface ReactPanelComponent extends React.Component {
2
- hide: boolean;
3
- element: HTMLElement;
4
- }
5
-
6
- export default ReactPanelComponent;
@@ -1,24 +0,0 @@
1
- import * as React from "react";
2
- import ReactPanelComponent from "./ReactPanelComponent";
3
-
4
- class StrictPanelComponent extends React.Component implements ReactPanelComponent {
5
- public hide: boolean = false;
6
-
7
- private _elRef: React.RefObject<HTMLElement> = React.createRef();
8
-
9
- public get element() { return this._elRef.current!; }
10
-
11
- public render() {
12
- return this.hide
13
- ? <></>
14
- : this._getElement();
15
- }
16
-
17
- private _getElement() {
18
- return React.cloneElement(React.Children.only(this.props.children) as React.ReactElement, {
19
- ref: this._elRef
20
- });
21
- }
22
- }
23
-
24
- export default StrictPanelComponent;