@atlaskit/ads-mcp 1.12.11 → 1.12.13
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.
- package/CHANGELOG.md +15 -0
- package/dist/cjs/tools/get-all-components/components.codegen.js +2 -2
- package/dist/cjs/tools/get-atlaskit-components/atlaskit-components.codegen.js +2 -2
- package/dist/cjs/tools/get-atlaskit-hooks/atlaskit-hooks.codegen.js +5 -5
- package/dist/cjs/tools/get-atlaskit-utilities/atlaskit-utilities.codegen.js +2 -2
- package/dist/cjs/tools/get-lint-rules/lint-rules-structured-content.codegen.js +41 -25
- package/dist/cjs/tools/migration-guides/migrations/onboarding-with-motion.js +5 -5
- package/dist/es2019/tools/get-all-components/components.codegen.js +2 -2
- package/dist/es2019/tools/get-atlaskit-components/atlaskit-components.codegen.js +2 -2
- package/dist/es2019/tools/get-atlaskit-hooks/atlaskit-hooks.codegen.js +5 -5
- package/dist/es2019/tools/get-atlaskit-utilities/atlaskit-utilities.codegen.js +2 -2
- package/dist/es2019/tools/get-lint-rules/lint-rules-structured-content.codegen.js +41 -25
- package/dist/es2019/tools/migration-guides/migrations/onboarding-with-motion.js +23 -30
- package/dist/esm/tools/get-all-components/components.codegen.js +2 -2
- package/dist/esm/tools/get-atlaskit-components/atlaskit-components.codegen.js +2 -2
- package/dist/esm/tools/get-atlaskit-hooks/atlaskit-hooks.codegen.js +5 -5
- package/dist/esm/tools/get-atlaskit-utilities/atlaskit-utilities.codegen.js +2 -2
- package/dist/esm/tools/get-lint-rules/lint-rules-structured-content.codegen.js +41 -25
- package/dist/esm/tools/migration-guides/migrations/onboarding-with-motion.js +5 -5
- package/dist/types/tools/get-all-components/components.codegen.d.ts +1 -1
- package/dist/types/tools/get-atlaskit-components/atlaskit-components.codegen.d.ts +1 -1
- package/dist/types/tools/get-atlaskit-hooks/atlaskit-hooks.codegen.d.ts +1 -1
- package/dist/types/tools/get-atlaskit-utilities/atlaskit-utilities.codegen.d.ts +1 -1
- package/dist/types/tools/get-lint-rules/lint-rules-structured-content.codegen.d.ts +1 -1
- package/package.json +3 -3
|
@@ -2,12 +2,12 @@ const additionalResources = 'Visit https://hello.atlassian.net/wiki/spaces/DST/p
|
|
|
2
2
|
export const onboardingWithMotion = {
|
|
3
3
|
id: 'motion',
|
|
4
4
|
title: 'Single Step Spotlight with Motion Migration',
|
|
5
|
-
description: 'Migrate a single step spotlight with entrance animation from @atlaskit/onboarding to @atlaskit/spotlight
|
|
5
|
+
description: 'Migrate a single step spotlight with entrance animation from @atlaskit/onboarding to @atlaskit/spotlight, which owns its default motion',
|
|
6
6
|
fromPackage: '@atlaskit/onboarding',
|
|
7
7
|
toPackage: '@atlaskit/spotlight',
|
|
8
8
|
examples: [{
|
|
9
9
|
title: 'Migrate spotlight with transition animation',
|
|
10
|
-
description: '
|
|
10
|
+
description: 'Remove SpotlightTransition because @atlaskit/spotlight applies its default motion internally',
|
|
11
11
|
before: `import React, { useState } from 'react';
|
|
12
12
|
import Button from '@atlaskit/button/default/button';
|
|
13
13
|
import {
|
|
@@ -54,7 +54,6 @@ const OnboardingSpotlightWithTransition = () => {
|
|
|
54
54
|
};`,
|
|
55
55
|
after: `import React, { useState } from 'react';
|
|
56
56
|
import Button from '@atlaskit/button/default/button';
|
|
57
|
-
import { FadeIn } from '@atlaskit/motion';
|
|
58
57
|
import { Text } from '@atlaskit/primitives/compiled';
|
|
59
58
|
import { PopoverContent } from '@atlaskit/spotlight/popover-content';
|
|
60
59
|
import { PopoverProvider } from '@atlaskit/spotlight/popover-provider';
|
|
@@ -80,39 +79,33 @@ const SpotlightWithMotion = () => {
|
|
|
80
79
|
<Button onClick={() => setIsVisible(true)}>Target Element</Button>
|
|
81
80
|
</PopoverTarget>
|
|
82
81
|
<PopoverContent done={done} dismiss={dismiss} placement="bottom-start" isVisible={isVisible}>
|
|
83
|
-
<
|
|
84
|
-
|
|
85
|
-
<
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
</SpotlightActions>
|
|
100
|
-
</SpotlightFooter>
|
|
101
|
-
</SpotlightCard>
|
|
102
|
-
</div>
|
|
103
|
-
)}
|
|
104
|
-
</FadeIn>
|
|
82
|
+
<SpotlightCard>
|
|
83
|
+
<SpotlightHeader>
|
|
84
|
+
<SpotlightHeadline>Feature Heading</SpotlightHeadline>
|
|
85
|
+
<SpotlightControls>
|
|
86
|
+
<SpotlightDismissControl />
|
|
87
|
+
</SpotlightControls>
|
|
88
|
+
</SpotlightHeader>
|
|
89
|
+
<SpotlightBody>
|
|
90
|
+
<Text>This is the spotlight body content describing the feature.</Text>
|
|
91
|
+
</SpotlightBody>
|
|
92
|
+
<SpotlightFooter>
|
|
93
|
+
<SpotlightActions>
|
|
94
|
+
<SpotlightPrimaryAction onClick={done}>Got it</SpotlightPrimaryAction>
|
|
95
|
+
</SpotlightActions>
|
|
96
|
+
</SpotlightFooter>
|
|
97
|
+
</SpotlightCard>
|
|
105
98
|
</PopoverContent>
|
|
106
99
|
</PopoverProvider>
|
|
107
100
|
);
|
|
108
101
|
};`,
|
|
109
102
|
explanation: `Key changes when migrating a spotlight with transition animation:
|
|
110
|
-
-
|
|
111
|
-
-
|
|
112
|
-
-
|
|
113
|
-
-
|
|
103
|
+
- Remove SpotlightTransition; PopoverContent applies the default spotlight motion internally
|
|
104
|
+
- Do not add a separate @atlaskit/motion wrapper around SpotlightCard
|
|
105
|
+
- Pass motion={null} to PopoverContent only when motion must be disabled
|
|
106
|
+
- Pass a custom motion component to PopoverContent's motion prop only when the default treatment does not meet the approved design
|
|
114
107
|
- All other migration changes from single step spotlight apply (PopoverProvider, compositional components, etc.)`
|
|
115
108
|
}],
|
|
116
|
-
bestPractices: ['
|
|
109
|
+
bestPractices: ['Use the default motion owned by PopoverContent', 'Pass motion={null} to PopoverContent to disable motion, or pass a custom motion component only for an approved custom treatment'],
|
|
117
110
|
additionalResources
|
|
118
111
|
};
|