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
2 changes: 1 addition & 1 deletion docs/examples/basic.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -75,4 +75,4 @@ const App = () => {
);
};

export default App;
export default App;
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,12 +36,12 @@
"prepublishOnly": "npm run compile && rc-np",
"prettier": "prettier --write \"**/*.{js,jsx,tsx,ts,less,md,json}\"",
"start": "dumi dev",
"test": "umi-test",
"test": "rc-test",
"watch": "father dev"
},
"dependencies": {
"@rc-component/portal": "^2.0.0",
"@rc-component/trigger": "^2.0.0",
"@rc-component/trigger": "^3.0.0",
"@rc-component/util": "^1.2.1",
"classnames": "^2.3.2"
},
Expand All @@ -60,10 +60,10 @@
"father": "^4.0.0",
"gh-pages": "^3.1.0",
"prettier": "^3.0.0",
"rc-test": "^7.1.2",
"react": "^18.3.1",
"react-dom": "^18.3.1",
"typescript": "^5.0.0",
"umi-test": "^1.9.7"
"typescript": "^5.0.0"
},
"peerDependencies": {
"react": ">=16.9.0",
Expand Down
2 changes: 1 addition & 1 deletion src/Tour.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,7 @@ const Tour: React.FC<TourProps> = props => {
prefixCls={prefixCls}
popup={getPopupElement}
forceRender={false}
destroyPopupOnHide
autoDestroy
zIndex={zIndex}
getTriggerDOMNode={getTriggerDOMNode}
arrow={!!mergedArrow}
Expand Down
28 changes: 14 additions & 14 deletions tests/__snapshots__/index.test.tsx.snap
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ exports[`Tour animated placeholder true 1`] = `
<div>
<div
class="rc-tour customClassName rc-tour-placement-bottom"
style="left: -1000vw; top: -1000vh; box-sizing: border-box; z-index: 1001;"
style="--arrow-x: 0px; --arrow-y: 0px; left: -1000vw; top: -1000vh; box-sizing: border-box; z-index: 1001;"
>
<div
class="rc-tour-arrow"
Expand Down Expand Up @@ -246,7 +246,7 @@ exports[`Tour animated true 1`] = `
<div>
<div
class="rc-tour customClassName rc-tour-placement-bottom"
style="left: -1000vw; top: -1000vh; box-sizing: border-box; z-index: 1001;"
style="--arrow-x: 0px; --arrow-y: 0px; left: -1000vw; top: -1000vh; box-sizing: border-box; z-index: 1001;"
>
<div
class="rc-tour-arrow"
Expand Down Expand Up @@ -427,7 +427,7 @@ exports[`Tour renderPanel basic 1`] = `
<div>
<div
class="rc-tour rc-tour-placement-bottom"
style="left: -1000vw; top: -1000vh; box-sizing: border-box; z-index: 1001;"
style="--arrow-x: 0px; --arrow-y: 0px; left: -1000vw; top: -1000vh; box-sizing: border-box; z-index: 1001;"
>
<div
class="rc-tour-arrow"
Expand Down Expand Up @@ -538,7 +538,7 @@ exports[`Tour rootClassName 1`] = `
<div>
<div
class="rc-tour customClassName rc-tour-placement-bottom"
style="left: -1000vw; top: -1000vh; box-sizing: border-box; z-index: 1001;"
style="--arrow-x: 0px; --arrow-y: 0px; left: -1000vw; top: -1000vh; box-sizing: border-box; z-index: 1001;"
>
<div
class="rc-tour-arrow"
Expand Down Expand Up @@ -658,7 +658,7 @@ exports[`Tour run in strict mode 1`] = `
<div>
<div
class="rc-tour rc-tour-placement-bottom"
style="left: -1000vw; top: -1000vh; box-sizing: border-box; z-index: 1001;"
style="--arrow-x: 0px; --arrow-y: 0px; left: -1000vw; top: -1000vh; box-sizing: border-box; z-index: 1001;"
>
<div
class="rc-tour-pannel"
Expand Down Expand Up @@ -822,7 +822,7 @@ exports[`Tour run in strict mode 2`] = `
<div>
<div
class="rc-tour rc-tour-placement-bottom"
style="left: -1000vw; top: -1000vh; box-sizing: border-box; z-index: 1001;"
style="--arrow-x: 0px; --arrow-y: 0px; left: -1000vw; top: -1000vh; box-sizing: border-box; z-index: 1001;"
>
<div
class="rc-tour-arrow"
Expand Down Expand Up @@ -944,7 +944,7 @@ exports[`Tour should keep current when controlled 1`] = `
<div>
<div
class="rc-tour"
style="left: -1000vw; top: -1000vh; box-sizing: border-box; z-index: 1001;"
style="--arrow-x: 0px; --arrow-y: 0px; left: -1000vw; top: -1000vh; box-sizing: border-box; z-index: 1001;"
>
<div
class="rc-tour-pannel"
Expand Down Expand Up @@ -1062,7 +1062,7 @@ exports[`Tour should return step 1 when reopen 1`] = `
<div>
<div
class="rc-tour"
style="left: -1000vw; top: -1000vh; box-sizing: border-box; z-index: 1001;"
style="--arrow-x: 0px; --arrow-y: 0px; left: -1000vw; top: -1000vh; box-sizing: border-box; z-index: 1001;"
>
<div
class="rc-tour-pannel"
Expand Down Expand Up @@ -1220,7 +1220,7 @@ exports[`Tour should update position when window resize 1`] = `
<div>
<div
class="rc-tour rc-tour-placement-bottom"
style="left: -1000vw; top: -1000vh; box-sizing: border-box; z-index: 1001;"
style="--arrow-x: 0px; --arrow-y: 0px; left: -1000vw; top: -1000vh; box-sizing: border-box; z-index: 1001;"
>
<div
class="rc-tour-arrow"
Expand Down Expand Up @@ -1373,7 +1373,7 @@ exports[`Tour showArrow should show tooltip arrow default 1`] = `
<div>
<div
class="rc-tour rc-tour-placement-bottom"
style="left: -1000vw; top: -1000vh; box-sizing: border-box; z-index: 1001;"
style="--arrow-x: 0px; --arrow-y: 0px; left: -1000vw; top: -1000vh; box-sizing: border-box; z-index: 1001;"
>
<div
class="rc-tour-pannel"
Expand Down Expand Up @@ -1522,7 +1522,7 @@ exports[`Tour single 1`] = `
<div>
<div
class="rc-tour rc-tour-placement-bottom"
style="left: -1000vw; top: -1000vh; box-sizing: border-box; z-index: 1001;"
style="--arrow-x: 0px; --arrow-y: 0px; left: -1000vw; top: -1000vh; box-sizing: border-box; z-index: 1001;"
>
<div
class="rc-tour-arrow"
Expand Down Expand Up @@ -1677,7 +1677,7 @@ exports[`Tour use custom builtinPlacements 1`] = `
<div>
<div
class="rc-tour rc-tour-placement-bottom"
style="left: -1000vw; top: -1000vh; box-sizing: border-box; z-index: 1001;"
style="--arrow-x: 0px; --arrow-y: 0px; left: -1000vw; top: -1000vh; box-sizing: border-box; z-index: 1001;"
>
<div
class="rc-tour-arrow"
Expand Down Expand Up @@ -1832,7 +1832,7 @@ exports[`Tour use custom builtinPlacements 2`] = `
<div>
<div
class="rc-tour rc-tour-placement-bottom"
style="left: -1000vw; top: -1000vh; box-sizing: border-box; z-index: 1001;"
style="--arrow-x: 0px; --arrow-y: 0px; left: -1000vw; top: -1000vh; box-sizing: border-box; z-index: 1001;"
>
<div
class="rc-tour-arrow"
Expand Down Expand Up @@ -1998,7 +1998,7 @@ exports[`Tour use custom builtinPlacements 3`] = `
<div>
<div
class="rc-tour rc-tour-placement-bottom"
style="left: -1000vw; top: -1000vh; box-sizing: border-box; z-index: 1001;"
style="--arrow-x: 0px; --arrow-y: 0px; left: -1000vw; top: -1000vh; box-sizing: border-box; z-index: 1001;"
>
<div
class="rc-tour-arrow"
Expand Down