Skip to content
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
6 changes: 6 additions & 0 deletions .changeset/cuddly-grapes-lose.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"@knocklabs/client": patch
"@knocklabs/react": patch
---

revert 4b888c4 to remove nextjs helper components and fix module resolution error
5 changes: 2 additions & 3 deletions packages/client/src/clients/guide/client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -341,7 +341,7 @@ export class KnockGuideClient {

cleanup() {
this.unsubscribe();
this.removeLocationChangeEventListeners();
this.removeEventListeners();
this.clearGroupStage();
this.clearCounterInterval();
}
Expand Down Expand Up @@ -1144,7 +1144,6 @@ export class KnockGuideClient {

// Define as an arrow func property to always bind this to the class instance.
private handleLocationChange = () => {
this.knock.log(`[Guide] .handleLocationChange`);
const win = checkForWindow();
if (!win?.location) return;

Expand Down Expand Up @@ -1224,7 +1223,7 @@ export class KnockGuideClient {
}
}

removeLocationChangeEventListeners() {
private removeEventListeners() {
const win = checkForWindow();
if (!win?.history) return;

Expand Down
7 changes: 0 additions & 7 deletions packages/react/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -46,15 +46,9 @@
"url": "https://github.com/knocklabs/javascript/issues"
},
"peerDependencies": {
"next": "^13.0.0 || ^14.0.0 || ^15.0.0 || ^16.0.0",
"react": "^16.11.0 || ^17.0.0 || ^18.0.0 || ^19.0.0",
"react-dom": "^16.11.0 || ^17.0.0 || ^18.0.0 || ^19.0.0"
},
"peerDependenciesMeta": {
"next": {
"optional": true
}
},
"dependencies": {
"@knocklabs/client": "workspace:^",
"@knocklabs/react-core": "workspace:^",
Expand Down Expand Up @@ -85,7 +79,6 @@
"eslint-plugin-react-hooks": "^5.2.0",
"eslint-plugin-react-refresh": "^0.4.14",
"jsdom": "^27.0.0",
"next": "15.3.3",
"react": "^19.0.0",
"react-dom": "^19.0.0",
"rimraf": "^6.0.1",
Expand Down
2 changes: 0 additions & 2 deletions packages/react/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,6 @@ export {
CardView,
KnockGuideProvider,
GuideToolbar as KnockGuideToolbar,
LocationSensorNextPagesRouter as KnockGuideLocationSensorNextPagesRouter,
LocationSensorNextAppRouter as KnockGuideLocationSensorNextAppRouter,
Modal,
ModalView,
} from "./modules/guide";
Expand Down

This file was deleted.

This file was deleted.

This file was deleted.

4 changes: 0 additions & 4 deletions packages/react/src/modules/guide/components/index.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,4 @@
export { Banner, BannerView } from "./Banner";
export { Card, CardView } from "./Card";
export { GuideToolbar } from "./GuideToolbar";
export {
LocationSensorNextAppRouter,
LocationSensorNextPagesRouter,
} from "./LocationSensor";
export { Modal, ModalView } from "./Modal";
2 changes: 0 additions & 2 deletions packages/react/src/modules/guide/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,5 @@ export {
Modal,
ModalView,
GuideToolbar,
LocationSensorNextAppRouter,
LocationSensorNextPagesRouter,
} from "./components";
export { KnockGuideProvider } from "./providers";
5 changes: 0 additions & 5 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -4228,7 +4228,6 @@ __metadata:
eslint-plugin-react-refresh: "npm:^0.4.14"
jsdom: "npm:^27.0.0"
lodash.debounce: "npm:^4.0.8"
next: "npm:15.3.3"
react: "npm:^19.0.0"
react-dom: "npm:^19.0.0"
rimraf: "npm:^6.0.1"
Expand All @@ -4241,12 +4240,8 @@ __metadata:
vitest: "npm:^3.1.1"
vitest-axe: "npm:^0.1.0"
peerDependencies:
next: ^13.0.0 || ^14.0.0 || ^15.0.0 || ^16.0.0
react: ^16.11.0 || ^17.0.0 || ^18.0.0 || ^19.0.0
react-dom: ^16.11.0 || ^17.0.0 || ^18.0.0 || ^19.0.0
peerDependenciesMeta:
next:
optional: true
languageName: unknown
linkType: soft

Expand Down
Loading