@butternutbox/pawprint-native 0.4.0 → 0.4.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/.turbo/turbo-build.log +7 -7
- package/CHANGELOG.md +6 -0
- package/dist/index.cjs +56 -31
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +12 -6
- package/dist/index.d.ts +12 -6
- package/dist/index.js +56 -31
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/src/components/molecules/NumberField/NumberFieldInput.tsx +14 -24
- package/src/components/molecules/ProductDisplayCard/ProductDisplayCard.stories.tsx +44 -17
- package/src/components/molecules/ProductDisplayCard/ProductDisplayCard.tsx +62 -13
package/.turbo/turbo-build.log
CHANGED
|
@@ -14,17 +14,17 @@
|
|
|
14
14
|
[32mESM[39m [1mdist/ibm-plex-sans-condensed-600-normal-UX5ZU5T6.woff2 [22m[32m19.35 KB[39m
|
|
15
15
|
[32mESM[39m [1mdist/ibm-plex-sans-condensed-700-normal-4PFYFTSO.woff2 [22m[32m18.90 KB[39m
|
|
16
16
|
[32mESM[39m [1mdist/index.js [22m[32m1.70 MB[39m
|
|
17
|
-
[32mESM[39m [1mdist/index.js.map [22m[32m2.
|
|
18
|
-
[32mESM[39m ⚡️ Build success in
|
|
17
|
+
[32mESM[39m [1mdist/index.js.map [22m[32m2.65 MB[39m
|
|
18
|
+
[32mESM[39m ⚡️ Build success in 11422ms
|
|
19
19
|
[32mCJS[39m [1mdist/ida-narrow-500-normal-C6I2PK4T.woff2 [22m[32m47.41 KB[39m
|
|
20
20
|
[32mCJS[39m [1mdist/ida-narrow-700-normal-UPHPRIN6.woff2 [22m[32m49.90 KB[39m
|
|
21
21
|
[32mCJS[39m [1mdist/ibm-plex-sans-condensed-400-normal-I2XLJNNB.woff2 [22m[32m19.33 KB[39m
|
|
22
|
-
[32mCJS[39m [1mdist/ibm-plex-sans-condensed-500-normal-IEQBNVGX.woff2 [22m[32m19.48 KB[39m
|
|
23
22
|
[32mCJS[39m [1mdist/ibm-plex-sans-condensed-600-normal-UX5ZU5T6.woff2 [22m[32m19.35 KB[39m
|
|
24
23
|
[32mCJS[39m [1mdist/ibm-plex-sans-condensed-700-normal-4PFYFTSO.woff2 [22m[32m18.90 KB[39m
|
|
24
|
+
[32mCJS[39m [1mdist/ibm-plex-sans-condensed-500-normal-IEQBNVGX.woff2 [22m[32m19.48 KB[39m
|
|
25
25
|
[32mCJS[39m [1mdist/index.cjs [22m[32m1.77 MB[39m
|
|
26
26
|
[32mCJS[39m [1mdist/index.cjs.map [22m[32m2.65 MB[39m
|
|
27
|
-
[32mCJS[39m ⚡️ Build success in
|
|
28
|
-
[32mDTS[39m ⚡️ Build success in
|
|
29
|
-
[32mDTS[39m [1mdist/index.d.cts [22m[32m87.
|
|
30
|
-
[32mDTS[39m [1mdist/index.d.ts [22m[32m87.
|
|
27
|
+
[32mCJS[39m ⚡️ Build success in 11424ms
|
|
28
|
+
[32mDTS[39m ⚡️ Build success in 22144ms
|
|
29
|
+
[32mDTS[39m [1mdist/index.d.cts [22m[32m87.78 KB[39m
|
|
30
|
+
[32mDTS[39m [1mdist/index.d.ts [22m[32m87.78 KB[39m
|
package/CHANGELOG.md
CHANGED
package/dist/index.cjs
CHANGED
|
@@ -10190,28 +10190,20 @@ var StyledFieldWrapper = styled60__default.default(reactNative.View)(
|
|
|
10190
10190
|
overflow: "hidden"
|
|
10191
10191
|
})
|
|
10192
10192
|
);
|
|
10193
|
-
var StyledTextInput = styled60__default.default(reactNative.TextInput)(
|
|
10194
|
-
|
|
10195
|
-
|
|
10196
|
-
|
|
10197
|
-
|
|
10198
|
-
|
|
10199
|
-
|
|
10200
|
-
|
|
10201
|
-
|
|
10202
|
-
|
|
10203
|
-
|
|
10204
|
-
|
|
10205
|
-
|
|
10206
|
-
|
|
10207
|
-
height: "100%",
|
|
10208
|
-
color: inputColor,
|
|
10209
|
-
fontFamily: inputFontFamily
|
|
10210
|
-
}, inputFontWeight ? { fontWeight: inputFontWeight } : {}), {
|
|
10211
|
-
fontSize: inputFontSize,
|
|
10212
|
-
lineHeight: inputLineHeight
|
|
10213
|
-
})
|
|
10214
|
-
);
|
|
10193
|
+
var StyledTextInput = styled60__default.default(reactNative.TextInput)(({ inputColor, inputFontFamily, inputFontWeight, inputFontSize }) => __spreadProps(__spreadValues({
|
|
10194
|
+
textAlign: "center",
|
|
10195
|
+
outlineStyle: "none",
|
|
10196
|
+
padding: 0,
|
|
10197
|
+
minWidth: 0,
|
|
10198
|
+
minHeight: 0,
|
|
10199
|
+
width: "100%",
|
|
10200
|
+
height: "100%",
|
|
10201
|
+
color: inputColor,
|
|
10202
|
+
fontFamily: inputFontFamily
|
|
10203
|
+
}, inputFontWeight ? { fontWeight: inputFontWeight } : {}), {
|
|
10204
|
+
fontSize: inputFontSize,
|
|
10205
|
+
lineHeight: 0
|
|
10206
|
+
}));
|
|
10215
10207
|
var StyledRow = styled60__default.default(reactNative.View)(({ rowGap }) => ({
|
|
10216
10208
|
flexDirection: "row",
|
|
10217
10209
|
alignItems: "center",
|
|
@@ -10345,7 +10337,6 @@ var NumberFieldInput = React60__default.default.forwardRef(
|
|
|
10345
10337
|
inputFontFamily: resolvedInputFontFamily,
|
|
10346
10338
|
inputFontWeight: resolvedInputFontFamily === typographyToken.fontFamily ? typographyToken.fontWeight : void 0,
|
|
10347
10339
|
inputFontSize: parseTokenValue34(typographyToken.fontSize),
|
|
10348
|
-
inputLineHeight: parseTokenValue34(typographyToken.lineHeight),
|
|
10349
10340
|
keyboardType: "numeric",
|
|
10350
10341
|
editable: !disabled,
|
|
10351
10342
|
onFocus: handleFocus,
|
|
@@ -14197,13 +14188,34 @@ var StyledCardContainer = styled60__default.default(reactNative.View)(({ theme:
|
|
|
14197
14188
|
zIndex: 1
|
|
14198
14189
|
};
|
|
14199
14190
|
});
|
|
14200
|
-
var StyledImage3 = styled60__default.default(reactNative.View)(
|
|
14201
|
-
|
|
14202
|
-
|
|
14203
|
-
|
|
14204
|
-
|
|
14205
|
-
|
|
14206
|
-
|
|
14191
|
+
var StyledImage3 = styled60__default.default(reactNative.View)(
|
|
14192
|
+
({ theme: theme2, imageBackgroundColor }) => ({
|
|
14193
|
+
flexShrink: 0,
|
|
14194
|
+
backgroundColor: imageBackgroundColor || theme2.tokens.semantics.colour.background.container.secondary,
|
|
14195
|
+
overflow: "hidden",
|
|
14196
|
+
aspectRatio: "1 / 1",
|
|
14197
|
+
height: "100%",
|
|
14198
|
+
position: "relative"
|
|
14199
|
+
})
|
|
14200
|
+
);
|
|
14201
|
+
var StyledQuantityBadge = styled60__default.default(reactNative.View)(({ theme: theme2 }) => {
|
|
14202
|
+
const spacing = theme2.tokens.semantics.dimensions.spacing;
|
|
14203
|
+
const borderRadius = theme2.tokens.semantics.dimensions.borderRadius;
|
|
14204
|
+
const { colour } = theme2.tokens.semantics;
|
|
14205
|
+
return {
|
|
14206
|
+
position: "absolute",
|
|
14207
|
+
top: parseTokenValue8(spacing["2xs"]),
|
|
14208
|
+
right: parseTokenValue8(spacing["2xs"]),
|
|
14209
|
+
backgroundColor: colour.background.container.brand,
|
|
14210
|
+
borderRadius: parseTokenValue8(borderRadius.xs),
|
|
14211
|
+
paddingHorizontal: parseTokenValue8(spacing.sm),
|
|
14212
|
+
height: parseTokenValue8(spacing["2xl"]),
|
|
14213
|
+
minWidth: parseTokenValue8(spacing["2xl"]),
|
|
14214
|
+
alignItems: "center",
|
|
14215
|
+
justifyContent: "center",
|
|
14216
|
+
zIndex: 2
|
|
14217
|
+
};
|
|
14218
|
+
});
|
|
14207
14219
|
var StyledContentArea = styled60__default.default(reactNative.View)(({ theme: theme2 }) => {
|
|
14208
14220
|
const { spacing } = theme2.tokens.semantics.dimensions;
|
|
14209
14221
|
return {
|
|
@@ -14255,6 +14267,8 @@ var ProductDisplayCard = React60__default.default.forwardRef(
|
|
|
14255
14267
|
incrementDisabled = false,
|
|
14256
14268
|
decrementDisabled = false,
|
|
14257
14269
|
image,
|
|
14270
|
+
imageBackgroundColor,
|
|
14271
|
+
showImageQuantityBadge = false,
|
|
14258
14272
|
banner,
|
|
14259
14273
|
showBanner = false,
|
|
14260
14274
|
bannerType = "info",
|
|
@@ -14274,6 +14288,8 @@ var ProductDisplayCard = React60__default.default.forwardRef(
|
|
|
14274
14288
|
"incrementDisabled",
|
|
14275
14289
|
"decrementDisabled",
|
|
14276
14290
|
"image",
|
|
14291
|
+
"imageBackgroundColor",
|
|
14292
|
+
"showImageQuantityBadge",
|
|
14277
14293
|
"banner",
|
|
14278
14294
|
"showBanner",
|
|
14279
14295
|
"bannerType",
|
|
@@ -14285,7 +14301,16 @@ var ProductDisplayCard = React60__default.default.forwardRef(
|
|
|
14285
14301
|
}
|
|
14286
14302
|
};
|
|
14287
14303
|
const cardContent = /* @__PURE__ */ jsxRuntime.jsxs(StyledCardContainer, __spreadProps(__spreadValues({ ref, cardDevice: device }, rest), { children: [
|
|
14288
|
-
image && /* @__PURE__ */ jsxRuntime.
|
|
14304
|
+
image && /* @__PURE__ */ jsxRuntime.jsxs(StyledImage3, { imageBackgroundColor, children: [
|
|
14305
|
+
typeof image === "string" ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
14306
|
+
reactNative.Image,
|
|
14307
|
+
{
|
|
14308
|
+
source: { uri: image },
|
|
14309
|
+
style: { width: "100%", height: "100%" }
|
|
14310
|
+
}
|
|
14311
|
+
) : image,
|
|
14312
|
+
showImageQuantityBadge && quantity && /* @__PURE__ */ jsxRuntime.jsx(StyledQuantityBadge, { children: /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "body", size: "sm", weight: "bold", children: quantity }) })
|
|
14313
|
+
] }),
|
|
14289
14314
|
/* @__PURE__ */ jsxRuntime.jsxs(StyledContentArea, { contentDevice: device, children: [
|
|
14290
14315
|
/* @__PURE__ */ jsxRuntime.jsxs(StyledTextContainer, { children: [
|
|
14291
14316
|
/* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "heading", size: "xs", color: "primary", children: title }),
|