Updated @automattic/tour-kit to 1.1.1 which has live resize functionality (#33452)

This commit is contained in:
RJ 2022-06-16 15:49:03 +08:00 committed by GitHub
parent ea194237a3
commit a78670bfec
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 40 additions and 15 deletions

View File

@ -0,0 +1,4 @@
Significance: minor
Type: add
Updated @automattic/tour-kit to 1.1.1 which has live resize functionality

View File

@ -28,7 +28,7 @@
"dependencies": {
"@automattic/calypso-color-schemes": "^2.1.1",
"@automattic/interpolate-components": "^1.2.0",
"@automattic/tour-kit": "^1.0.0",
"@automattic/tour-kit": "^1.1.1",
"@woocommerce/csv-export": "workspace:*",
"@woocommerce/currency": "workspace:*",
"@woocommerce/data": "workspace:*",

View File

@ -3,7 +3,7 @@
*/
import { createElement } from '@wordpress/element';
import TourKit, { TourStepRenderer } from '@automattic/tour-kit';
import TourKit, { TourStepRenderer, Options } from '@automattic/tour-kit';
/**
* Internal dependencies
@ -15,8 +15,18 @@ interface Props {
config: WooConfig;
}
const defaultOptions = {
effects: { spotlight: {}, arrowIndicator: true },
const defaultOptions: Options = {
effects: {
spotlight: {
interactivity: { enabled: true, rootElementSelector: '#wpwrap' },
},
arrowIndicator: true,
liveResize: {
mutation: true,
resize: true,
rootElementSelector: '#wpwrap',
},
},
};
const WooTourKit: React.FunctionComponent< Props > = ( { config } ) => {

View File

@ -48,6 +48,11 @@ const getTourConfig = ( {
behavior: 'auto',
block: 'center',
},
liveResize: {
mutation: true,
resize: true,
rootElementSelector: '#wpwrap',
},
},
popperModifiers: [
{

View File

@ -0,0 +1,4 @@
Significance: minor
Type: add
Updated @automattic/tour-kit to 1.1.1 which has live resize functionality

View File

@ -204,7 +204,7 @@ importers:
specifiers:
'@automattic/calypso-color-schemes': ^2.1.1
'@automattic/interpolate-components': ^1.2.0
'@automattic/tour-kit': ^1.0.0
'@automattic/tour-kit': ^1.1.1
'@babel/core': ^7.17.5
'@babel/runtime': ^7.17.2
'@storybook/addon-actions': ^6.4.0
@ -280,7 +280,7 @@ importers:
dependencies:
'@automattic/calypso-color-schemes': 2.1.1
'@automattic/interpolate-components': 1.2.1
'@automattic/tour-kit': 1.0.0_535ee2ac29d7af3b13ff2600d9b8992f
'@automattic/tour-kit': 1.1.1_535ee2ac29d7af3b13ff2600d9b8992f
'@woocommerce/csv-export': link:../csv-export
'@woocommerce/currency': link:../currency
'@woocommerce/data': link:../data
@ -1949,8 +1949,8 @@ packages:
tslib: 2.3.1
dev: false
/@automattic/tour-kit/1.0.0_535ee2ac29d7af3b13ff2600d9b8992f:
resolution: {integrity: sha512-md3VLtvCMR8lMqKJ+JH4YDQnN9VA5acCUGxeMWyyledu06cBU/Ki2Gyw3XTPz0IRO78n4dXFpFHR4sezfHDJcA==}
/@automattic/tour-kit/1.1.1_535ee2ac29d7af3b13ff2600d9b8992f:
resolution: {integrity: sha512-qC15YGZZW5VUhvl47y9C+aN0q0QIejP9g9pFZ9M3PRRgaZcXx00+ZrL1Ngg0+V9eS5io5OZcji3D8OU6i48t/w==}
peerDependencies:
'@wordpress/data': ^6.1.5
react: ^17.0.2
@ -1972,6 +1972,7 @@ packages:
'@wordpress/primitives': 3.8.0
'@wordpress/react-i18n': 3.8.0
classnames: 2.3.1
debug: 4.3.4
react-popper: 2.2.5_@popperjs+core@2.11.4
transitivePeerDependencies:
- '@babel/core'
@ -12721,6 +12722,7 @@ packages:
re-resizable: 4.11.0
transitivePeerDependencies:
- react
- react-dom
dev: true
/@types/wordpress__compose/4.0.1:
@ -25239,7 +25241,7 @@ packages:
'@automattic/interpolate-components': 1.2.1
'@babel/runtime': 7.17.7
'@tannin/sprintf': 1.2.0
'@wordpress/compose': 5.2.1
'@wordpress/compose': 5.8.0
debug: 4.3.4
events: 3.3.0
hash.js: 1.1.7
@ -25260,7 +25262,7 @@ packages:
'@automattic/interpolate-components': 1.2.1_react@17.0.2
'@babel/runtime': 7.17.7
'@tannin/sprintf': 1.2.0
'@wordpress/compose': 5.2.1_react@17.0.2
'@wordpress/compose': 5.8.0_react@17.0.2
debug: 4.3.4
events: 3.3.0
hash.js: 1.1.7
@ -26073,7 +26075,7 @@ packages:
resolution: {integrity: sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==}
/isarray/2.0.1:
resolution: {integrity: sha512-c2cu3UxbI+b6kR3fy0nRnAhodsvR9dx7U5+znCOzdj6IfP3upFURTr0Xl5BlQZNKZjEtxrmVyfSdeE3O57smoQ==}
resolution: {integrity: sha1-o32U7ZzaLVmGXJ92/llu4fM4dB4=}
dev: false
/isarray/2.0.5:
@ -35079,7 +35081,7 @@ packages:
dev: true
/seed-random/2.2.0:
resolution: {integrity: sha1-KpsZ4lCoFwmSMaW5mk2vgLf77VQ=}
resolution: {integrity: sha512-34EQV6AAHQGhoc0tn/96a9Fsi6v2xdqe/dMUwljGRaFOzR3EgRmECvD0O8vi8X+/uQ50LGHfkNu/Eue5TPKZkQ==}
dev: false
/select/1.1.2:
@ -37943,7 +37945,7 @@ packages:
dev: true
/uppercamelcase/1.1.0:
resolution: {integrity: sha1-Mk2YprOvx+iolT4QZBUJsOTiP5c=}
resolution: {integrity: sha512-C7YEMvhgrvTEKEEVqA7LXNID/1TvvIwYZqNIKLquS6y/MGSkRQAav9LnTTILlC1RqUM8eTVBOe1U/fnB652PRA==}
dependencies:
camelcase: 1.2.1
dev: false
@ -39152,7 +39154,7 @@ packages:
dev: true
/wp-error/1.3.0:
resolution: {integrity: sha1-cgJHqjJkJJkcWHdcsv7cm/2IVCA=}
resolution: {integrity: sha512-6Mn8fIBgWYgKJveRpB5oR+T9JEXxUawq5Om35ZE0yvCh5p3SQ+2OCH+KH39k0ZMxvNh9CI7LyfihtQH6itHbdQ==}
dependencies:
builtin-status-codes: 2.0.0
uppercamelcase: 1.1.0
@ -39366,7 +39368,7 @@ packages:
dev: false
/xmlhttprequest-ssl/1.5.5:
resolution: {integrity: sha1-wodrBhaKrcQOV9l+gRkayPQ5iz4=}
resolution: {integrity: sha512-/bFPLUgJrfGUL10AIv4Y7/CUt6so9CLtB/oFxQSHseSDNNCdC6vwwKEqwLN6wNPBg9YWXAiMu8jkf6RPRS/75Q==}
engines: {node: '>=0.4.0'}
dev: false