Skip to content
This repository was archived by the owner on Nov 9, 2024. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ export interface TippyProps extends Omit<Partial<KnownProps>, 'content'> {
visible?: boolean;
enabled?: boolean;
className?: string;
plugins?: Plugin[];
singleton?: (instance: Instance) => void;
[key: string]: any;
}
Expand All @@ -29,7 +28,6 @@ export interface TippySingletonProps extends Partial<KnownProps> {
children: Array<React.ReactElement<any>>;
enabled?: boolean;
className?: string;
plugins?: Plugin[];
[key: string]: any;
}

Expand Down
25 changes: 7 additions & 18 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
},
"dependencies": {
"prop-types": "^15.6.2",
"tippy.js": "^5.0.2"
"tippy.js": "^5.1.0"
},
"peerDependencies": {
"react": ">=16.8",
Expand Down
3 changes: 1 addition & 2 deletions src/Tippy.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ export function Tippy({
children,
content,
className,
plugins,
visible,
singleton,
enabled = true,
Expand Down Expand Up @@ -54,7 +53,7 @@ export function Tippy({

// CREATE
useIsomorphicLayoutEffect(() => {
const instance = tippy(component.ref, props, plugins);
const instance = tippy(component.ref, props);

component.instance = instance;

Expand Down
3 changes: 1 addition & 2 deletions src/TippySingleton.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ import {
export default function TippySingleton({
children,
className,
plugins,
enabled = true,
ignoreAttributes = true,
...restOfNativeProps
Expand All @@ -27,7 +26,7 @@ export default function TippySingleton({

const deps = [children.length];

useSingletonCreate(component, props, plugins, enabled, deps);
useSingletonCreate(component, props, enabled, deps);
useSingletonUpdate(component, props, enabled);
useUpdateClassName(component, className, deps);

Expand Down
3 changes: 1 addition & 2 deletions src/hooks.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ import {

export function useSingleton({
className,
plugins,
enabled = true,
ignoreAttributes = true,
...restOfNativeProps
Expand All @@ -25,7 +24,7 @@ export function useSingleton({

const deps = [component.instances.length];

useSingletonCreate(component, props, plugins, enabled, deps);
useSingletonCreate(component, props, enabled, deps);
useSingletonUpdate(component, props, enabled);
useUpdateClassName(component, className, deps);

Expand Down
4 changes: 2 additions & 2 deletions src/util-hooks.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,10 @@ export function useInstance(initialValue) {
return ref.current;
}

export function useSingletonCreate(component, props, plugins, enabled, deps) {
export function useSingletonCreate(component, props, enabled, deps) {
useIsomorphicLayoutEffect(() => {
const {instances} = component;
const instance = createSingleton(instances, props, plugins);
const instance = createSingleton(instances, props);

component.instance = instance;

Expand Down