@spscommerce/ds-react 6.1.0 → 6.1.1
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/lib/index.cjs.js +66 -66
- package/lib/index.es.js +11 -3
- package/lib/tile-list/SpsTile.d.ts +2 -0
- package/package.json +11 -11
package/lib/index.es.js
CHANGED
|
@@ -35225,8 +35225,10 @@ const propsDoc$l = {
|
|
|
35225
35225
|
href: "string",
|
|
35226
35226
|
icon: { type: "ReactNodeOrRenderFn", required: "true" },
|
|
35227
35227
|
error: "boolean",
|
|
35228
|
+
errorIcon: "ReactNodeOrRenderFn",
|
|
35228
35229
|
title: { type: "string", required: "true" },
|
|
35229
35230
|
warning: "boolean",
|
|
35231
|
+
warningIcon: "ReactNodeOrRenderFn",
|
|
35230
35232
|
disabled: "boolean"
|
|
35231
35233
|
};
|
|
35232
35234
|
const propTypes$l = __spreadProps(__spreadValues({}, spsGlobalPropTypes), {
|
|
@@ -35234,8 +35236,10 @@ const propTypes$l = __spreadProps(__spreadValues({}, spsGlobalPropTypes), {
|
|
|
35234
35236
|
target: propTypes$1G.exports.string,
|
|
35235
35237
|
icon: nodeOrRenderFn.isRequired,
|
|
35236
35238
|
error: propTypes$1G.exports.bool,
|
|
35239
|
+
errorIcon: nodeOrRenderFn,
|
|
35237
35240
|
title: propTypes$1G.exports.string.isRequired,
|
|
35238
35241
|
warning: propTypes$1G.exports.bool,
|
|
35242
|
+
warningIcon: nodeOrRenderFn,
|
|
35239
35243
|
disabled: propTypes$1G.exports.bool
|
|
35240
35244
|
});
|
|
35241
35245
|
function SpsTile(props2) {
|
|
@@ -35245,9 +35249,11 @@ function SpsTile(props2) {
|
|
|
35245
35249
|
target,
|
|
35246
35250
|
icon,
|
|
35247
35251
|
error = false,
|
|
35252
|
+
errorIcon,
|
|
35248
35253
|
title,
|
|
35249
35254
|
unsafelyReplaceClassName,
|
|
35250
35255
|
warning = false,
|
|
35256
|
+
warningIcon,
|
|
35251
35257
|
disabled = false
|
|
35252
35258
|
} = _a, rest = __objRest(_a, [
|
|
35253
35259
|
"className",
|
|
@@ -35255,9 +35261,11 @@ function SpsTile(props2) {
|
|
|
35255
35261
|
"target",
|
|
35256
35262
|
"icon",
|
|
35257
35263
|
"error",
|
|
35264
|
+
"errorIcon",
|
|
35258
35265
|
"title",
|
|
35259
35266
|
"unsafelyReplaceClassName",
|
|
35260
35267
|
"warning",
|
|
35268
|
+
"warningIcon",
|
|
35261
35269
|
"disabled"
|
|
35262
35270
|
]);
|
|
35263
35271
|
const classes = clsx(unsafelyReplaceClassName || "sps-tile", className, error && "sps-tile--error", warning && "sps-tile--warning", disabled && "sps-tile--disabled");
|
|
@@ -35275,11 +35283,11 @@ function SpsTile(props2) {
|
|
|
35275
35283
|
rel: target === "_blank" ? "noopener noreferrer" : void 0
|
|
35276
35284
|
}, rest), (warning || error) && /* @__PURE__ */ React.createElement("div", {
|
|
35277
35285
|
className: "sps-tile--icon"
|
|
35278
|
-
}, warning && /* @__PURE__ */ React.createElement("i", {
|
|
35286
|
+
}, warning && (warningIcon ? contentOf(warningIcon) : /* @__PURE__ */ React.createElement("i", {
|
|
35279
35287
|
className: clsx("sps-icon", "sps-icon-status-warning")
|
|
35280
|
-
}), error && /* @__PURE__ */ React.createElement("i", {
|
|
35288
|
+
})), error && (errorIcon ? contentOf(errorIcon) : /* @__PURE__ */ React.createElement("i", {
|
|
35281
35289
|
className: clsx("sps-icon", "sps-icon-ban")
|
|
35282
|
-
})), /* @__PURE__ */ React.createElement("div", {
|
|
35290
|
+
}))), /* @__PURE__ */ React.createElement("div", {
|
|
35283
35291
|
className: "sps-tile--content"
|
|
35284
35292
|
}, /* @__PURE__ */ React.createElement("div", {
|
|
35285
35293
|
className: "sps-tile--image"
|
|
@@ -4,8 +4,10 @@ declare const propTypes: {
|
|
|
4
4
|
target: PropTypes.Requireable<string>;
|
|
5
5
|
icon: PropTypes.Validator<PropTypes.ReactNodeOrRenderFn>;
|
|
6
6
|
error: PropTypes.Requireable<boolean>;
|
|
7
|
+
errorIcon: PropTypes.Requireable<PropTypes.ReactNodeOrRenderFn>;
|
|
7
8
|
title: PropTypes.Validator<string>;
|
|
8
9
|
warning: PropTypes.Requireable<boolean>;
|
|
10
|
+
warningIcon: PropTypes.Requireable<PropTypes.ReactNodeOrRenderFn>;
|
|
9
11
|
disabled: PropTypes.Requireable<boolean>;
|
|
10
12
|
children: PropTypes.Requireable<PropTypes.ReactNodeLike>;
|
|
11
13
|
className: PropTypes.Requireable<string>;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@spscommerce/ds-react",
|
|
3
3
|
"description": "SPS Design System React components",
|
|
4
|
-
"version": "6.1.
|
|
4
|
+
"version": "6.1.1",
|
|
5
5
|
"author": "SPS Commerce",
|
|
6
6
|
"license": "UNLICENSED",
|
|
7
7
|
"repository": "https://github.com/spscommerce/design-system/tree/main/packages/@spscommerce/ds-react",
|
|
@@ -28,11 +28,11 @@
|
|
|
28
28
|
},
|
|
29
29
|
"peerDependencies": {
|
|
30
30
|
"@react-stately/collections": "^3.3.3",
|
|
31
|
-
"@spscommerce/ds-colors": "6.1.
|
|
32
|
-
"@spscommerce/ds-illustrations": "6.1.
|
|
33
|
-
"@spscommerce/ds-shared": "6.1.
|
|
34
|
-
"@spscommerce/positioning": "6.1.
|
|
35
|
-
"@spscommerce/utils": "6.1.
|
|
31
|
+
"@spscommerce/ds-colors": "6.1.1",
|
|
32
|
+
"@spscommerce/ds-illustrations": "6.1.1",
|
|
33
|
+
"@spscommerce/ds-shared": "6.1.1",
|
|
34
|
+
"@spscommerce/positioning": "6.1.1",
|
|
35
|
+
"@spscommerce/utils": "6.1.1",
|
|
36
36
|
"moment": "^2.25.3",
|
|
37
37
|
"moment-timezone": "^0.5.28",
|
|
38
38
|
"react": "^16.9.0",
|
|
@@ -40,11 +40,11 @@
|
|
|
40
40
|
},
|
|
41
41
|
"devDependencies": {
|
|
42
42
|
"@react-stately/collections": "^3.3.3",
|
|
43
|
-
"@spscommerce/ds-colors": "6.1.
|
|
44
|
-
"@spscommerce/ds-illustrations": "6.1.
|
|
45
|
-
"@spscommerce/ds-shared": "6.1.
|
|
46
|
-
"@spscommerce/positioning": "6.1.
|
|
47
|
-
"@spscommerce/utils": "6.1.
|
|
43
|
+
"@spscommerce/ds-colors": "6.1.1",
|
|
44
|
+
"@spscommerce/ds-illustrations": "6.1.1",
|
|
45
|
+
"@spscommerce/ds-shared": "6.1.1",
|
|
46
|
+
"@spscommerce/positioning": "6.1.1",
|
|
47
|
+
"@spscommerce/utils": "6.1.1",
|
|
48
48
|
"@testing-library/react": "^9.3.2",
|
|
49
49
|
"@types/prop-types": "^15.7.1",
|
|
50
50
|
"@types/react": "^16.9.0",
|