@purpurds/promotion-card 8.2.5 → 8.2.6
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/dist/LICENSE.txt +4 -4
- package/dist/promotion-card.cjs.js +6 -6
- package/dist/promotion-card.cjs.js.map +1 -1
- package/dist/promotion-card.d.ts +0 -2
- package/dist/promotion-card.d.ts.map +1 -1
- package/dist/promotion-card.es.js +98 -98
- package/dist/promotion-card.es.js.map +1 -1
- package/package.json +13 -13
- package/src/promotion-card.stories.tsx +0 -2
- package/src/promotion-card.tsx +2 -4
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@purpurds/promotion-card",
|
|
3
|
-
"version": "8.2.
|
|
3
|
+
"version": "8.2.6",
|
|
4
4
|
"license": "AGPL-3.0-only",
|
|
5
5
|
"main": "./dist/promotion-card.cjs.js",
|
|
6
6
|
"types": "./dist/promotion-card.d.ts",
|
|
@@ -17,15 +17,15 @@
|
|
|
17
17
|
"source": "src/promotion-card.tsx",
|
|
18
18
|
"dependencies": {
|
|
19
19
|
"classnames": "~2.5.0",
|
|
20
|
-
"@purpurds/
|
|
21
|
-
"@purpurds/
|
|
22
|
-
"@purpurds/
|
|
23
|
-
"@purpurds/
|
|
24
|
-
"@purpurds/
|
|
25
|
-
"@purpurds/
|
|
26
|
-
"@purpurds/
|
|
27
|
-
"@purpurds/
|
|
28
|
-
"@purpurds/
|
|
20
|
+
"@purpurds/button": "8.2.6",
|
|
21
|
+
"@purpurds/cta-link": "8.2.6",
|
|
22
|
+
"@purpurds/card": "8.2.6",
|
|
23
|
+
"@purpurds/heading": "8.2.6",
|
|
24
|
+
"@purpurds/paragraph": "8.2.6",
|
|
25
|
+
"@purpurds/icon": "8.2.6",
|
|
26
|
+
"@purpurds/tokens": "8.2.6",
|
|
27
|
+
"@purpurds/common-types": "8.2.6",
|
|
28
|
+
"@purpurds/badge": "8.2.6"
|
|
29
29
|
},
|
|
30
30
|
"devDependencies": {
|
|
31
31
|
"@storybook/react-vite": "^9.0.18",
|
|
@@ -46,9 +46,9 @@
|
|
|
46
46
|
"vite": "^6.2.1",
|
|
47
47
|
"vitest": "^3.1.2",
|
|
48
48
|
"@purpurds/component-rig": "1.0.0",
|
|
49
|
-
"@purpurds/
|
|
50
|
-
"@purpurds/
|
|
51
|
-
"@purpurds/
|
|
49
|
+
"@purpurds/grid": "8.2.6",
|
|
50
|
+
"@purpurds/theme": "8.2.6",
|
|
51
|
+
"@purpurds/text-spacing": "8.2.6"
|
|
52
52
|
},
|
|
53
53
|
"peerDependencies": {
|
|
54
54
|
"@types/react": "^18 || ^19",
|
|
@@ -137,7 +137,6 @@ export const Showcase: Story = {
|
|
|
137
137
|
|
|
138
138
|
export const WithDecorativeImage: Story = {
|
|
139
139
|
args: {
|
|
140
|
-
hasGradient: true,
|
|
141
140
|
decorativeImage: (
|
|
142
141
|
<img
|
|
143
142
|
src="https://www.telia.se/images/i15skfqwpurk/5YYelnwdIJGush05RYsE6A/04d4eeb571bca6d5c72b557f6da92c92/Telia_Company_Reinvention_69.jpg?fit=scale&w=536&fm=jpg&q=70"
|
|
@@ -186,7 +185,6 @@ export const WithProductImage: Story = {
|
|
|
186
185
|
|
|
187
186
|
export const CardGroup: Story = {
|
|
188
187
|
args: {
|
|
189
|
-
hasGradient: true,
|
|
190
188
|
decorativeImage: (
|
|
191
189
|
<img
|
|
192
190
|
src="https://www.telia.se/images/i15skfqwpurk/5YYelnwdIJGush05RYsE6A/04d4eeb571bca6d5c72b557f6da92c92/Telia_Company_Reinvention_69.jpg?fit=scale&w=536&fm=jpg&q=70"
|
package/src/promotion-card.tsx
CHANGED
|
@@ -39,8 +39,8 @@ const colors: StyleRecord = {
|
|
|
39
39
|
quaternary: "var(--purpur-color-text-tone-on-tone-tertiary)",
|
|
40
40
|
} as const;
|
|
41
41
|
|
|
42
|
-
type DecorativeImage = { decorativeImage?: ReactNode
|
|
43
|
-
type ProductImage = { productImage?: ReactNode
|
|
42
|
+
type DecorativeImage = { decorativeImage?: ReactNode };
|
|
43
|
+
type ProductImage = { productImage?: ReactNode };
|
|
44
44
|
|
|
45
45
|
export type PromotionCardProps = Omit<BaseProps, "children"> & {
|
|
46
46
|
variant?: PromotionCardVariant;
|
|
@@ -92,8 +92,6 @@ export const PromotionCard = forwardRef<HTMLDivElement, PromotionCardProps>(
|
|
|
92
92
|
const { productImage, ...spread } = props;
|
|
93
93
|
image = productImage;
|
|
94
94
|
rest = spread;
|
|
95
|
-
} else if ("hasGradient" in props) {
|
|
96
|
-
rest = props;
|
|
97
95
|
}
|
|
98
96
|
|
|
99
97
|
const customProperties = {
|