@kbach/react 0.6.31 → 0.6.32

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.
@@ -3873,7 +3873,7 @@ var InteractiveWrapper = forwardRef(
3873
3873
  [resolvedStyle, isDark, pressed, hovered, focused, width, disabled, checked, isNonStringComponent]
3874
3874
  );
3875
3875
  const skipComputedInline = isWebPlatform;
3876
- const finalStyle = skipComputedInline ? styleProp ?? void 0 : styleProp ? Array.isArray(styleProp) ? Object.assign({}, computedStyle, ...styleProp) : { ...computedStyle, ...styleProp } : computedStyle;
3876
+ const finalStyle = skipComputedInline ? styleProp ?? void 0 : styleProp ? Array.isArray(styleProp) ? [computedStyle, ...styleProp] : [computedStyle, styleProp] : computedStyle;
3877
3877
  const componentProps = {
3878
3878
  ref,
3879
3879
  ...restForComponent,
@@ -25,7 +25,7 @@ import {
25
25
  transformToWebProps,
26
26
  useConditionalGlobalDarkMode,
27
27
  useConditionalWidth
28
- } from "./chunk-OIJ6RP4F.mjs";
28
+ } from "./chunk-E322MVGC.mjs";
29
29
 
30
30
  // src/jsx-runtime.tsx
31
31
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
@@ -50,7 +50,7 @@ var DarkWrapper = React.forwardRef(
50
50
  return s;
51
51
  }, [resolvedStyle, isDark, width, screens, isNonStringComponent]);
52
52
  const skipComputedInline = isWebPlatform;
53
- const finalStyle = skipComputedInline ? styleProp ?? void 0 : styleProp ? Array.isArray(styleProp) ? Object.assign({}, computedStyle, ...styleProp) : { ...computedStyle, ...styleProp } : computedStyle;
53
+ const finalStyle = skipComputedInline ? styleProp ?? void 0 : styleProp ? Array.isArray(styleProp) ? [computedStyle, ...styleProp] : [computedStyle, styleProp] : computedStyle;
54
54
  const props = { ref, ...rest, style: finalStyle };
55
55
  return Array.isArray(children) ? React.createElement(Component, props, ...children) : React.createElement(Component, props, children);
56
56
  }
@@ -108,8 +108,7 @@ function omitConsumed(props) {
108
108
  }
109
109
  function mergeStyle(computed, userStyle) {
110
110
  if (!userStyle) return computed;
111
- if (Array.isArray(userStyle)) return Object.assign({}, computed, ...userStyle);
112
- return { ...computed, ...userStyle };
111
+ return Array.isArray(userStyle) ? [computed, ...userStyle] : [computed, userStyle];
113
112
  }
114
113
  function withImpliedFlexIfNeeded(webTag, resolvedBase, userStyle) {
115
114
  if (!webTag || !resolvedBase) return userStyle;
package/dist/index.js CHANGED
@@ -842,8 +842,7 @@ function styled(Component, baseClasses = "") {
842
842
  [resolved, isDark, pressed, hovered, focused, disabled, checked, width]
843
843
  // eslint-disable-line react-hooks/exhaustive-deps
844
844
  );
845
- const extraStyle = Array.isArray(styleProp) ? Object.assign({}, ...styleProp) : styleProp;
846
- const finalStyle = isWebPlatform ? extraStyle ?? void 0 : extraStyle ? { ...computedStyle, ...extraStyle } : computedStyle;
845
+ const finalStyle = isWebPlatform ? (Array.isArray(styleProp) ? Object.assign({}, ...styleProp) : styleProp) ?? void 0 : styleProp ? Array.isArray(styleProp) ? [computedStyle, ...styleProp] : [computedStyle, styleProp] : computedStyle;
847
846
  const webTag = isWebPlatform ? getWebTag(Component, rest) : null;
848
847
  const effectiveComponent = webTag ?? Component;
849
848
  const componentName2 = Component.displayName ?? Component.name ?? "";
@@ -1030,7 +1029,7 @@ var InteractiveWrapper = (0, import_react9.forwardRef)(
1030
1029
  [resolvedStyle, isDark, pressed, hovered, focused, width, disabled, checked, isNonStringComponent]
1031
1030
  );
1032
1031
  const skipComputedInline = isWebPlatform;
1033
- const finalStyle = skipComputedInline ? styleProp ?? void 0 : styleProp ? Array.isArray(styleProp) ? Object.assign({}, computedStyle, ...styleProp) : { ...computedStyle, ...styleProp } : computedStyle;
1032
+ const finalStyle = skipComputedInline ? styleProp ?? void 0 : styleProp ? Array.isArray(styleProp) ? [computedStyle, ...styleProp] : [computedStyle, styleProp] : computedStyle;
1034
1033
  const componentProps = {
1035
1034
  ref,
1036
1035
  ...restForComponent,
package/dist/index.mjs CHANGED
@@ -43,7 +43,7 @@ import {
43
43
  useGlobalDarkMode,
44
44
  useGlobalWidth,
45
45
  useSyncExternalStore
46
- } from "./chunk-OIJ6RP4F.mjs";
46
+ } from "./chunk-E322MVGC.mjs";
47
47
 
48
48
  // src/context.tsx
49
49
  import { createContext, useContext } from "react";
@@ -406,8 +406,7 @@ function styled(Component, baseClasses = "") {
406
406
  [resolved, isDark, pressed, hovered, focused, disabled, checked, width]
407
407
  // eslint-disable-line react-hooks/exhaustive-deps
408
408
  );
409
- const extraStyle = Array.isArray(styleProp) ? Object.assign({}, ...styleProp) : styleProp;
410
- const finalStyle = isWebPlatform ? extraStyle ?? void 0 : extraStyle ? { ...computedStyle, ...extraStyle } : computedStyle;
409
+ const finalStyle = isWebPlatform ? (Array.isArray(styleProp) ? Object.assign({}, ...styleProp) : styleProp) ?? void 0 : styleProp ? Array.isArray(styleProp) ? [computedStyle, ...styleProp] : [computedStyle, styleProp] : computedStyle;
411
410
  const webTag = isWebPlatform ? getWebTag(Component, rest) : null;
412
411
  const effectiveComponent = webTag ?? Component;
413
412
  const componentName2 = Component.displayName ?? Component.name ?? "";
@@ -234,7 +234,7 @@ var InteractiveWrapper = (0, import_react2.forwardRef)(
234
234
  [resolvedStyle, isDark, pressed, hovered, focused, width, disabled, checked, isNonStringComponent]
235
235
  );
236
236
  const skipComputedInline = isWebPlatform;
237
- const finalStyle = skipComputedInline ? styleProp ?? void 0 : styleProp ? Array.isArray(styleProp) ? Object.assign({}, computedStyle, ...styleProp) : { ...computedStyle, ...styleProp } : computedStyle;
237
+ const finalStyle = skipComputedInline ? styleProp ?? void 0 : styleProp ? Array.isArray(styleProp) ? [computedStyle, ...styleProp] : [computedStyle, styleProp] : computedStyle;
238
238
  const componentProps = {
239
239
  ref,
240
240
  ...restForComponent,
@@ -291,7 +291,7 @@ var DarkWrapper = import_react3.default.forwardRef(
291
291
  return s;
292
292
  }, [resolvedStyle, isDark, width, screens, isNonStringComponent]);
293
293
  const skipComputedInline = isWebPlatform;
294
- const finalStyle = skipComputedInline ? styleProp ?? void 0 : styleProp ? Array.isArray(styleProp) ? Object.assign({}, computedStyle, ...styleProp) : { ...computedStyle, ...styleProp } : computedStyle;
294
+ const finalStyle = skipComputedInline ? styleProp ?? void 0 : styleProp ? Array.isArray(styleProp) ? [computedStyle, ...styleProp] : [computedStyle, styleProp] : computedStyle;
295
295
  const props = { ref, ...rest, style: finalStyle };
296
296
  return Array.isArray(children) ? import_react3.default.createElement(Component, props, ...children) : import_react3.default.createElement(Component, props, children);
297
297
  }
@@ -619,8 +619,7 @@ function omitConsumed(props) {
619
619
  }
620
620
  function mergeStyle(computed, userStyle) {
621
621
  if (!userStyle) return computed;
622
- if (Array.isArray(userStyle)) return Object.assign({}, computed, ...userStyle);
623
- return { ...computed, ...userStyle };
622
+ return Array.isArray(userStyle) ? [computed, ...userStyle] : [computed, userStyle];
624
623
  }
625
624
  function withImpliedFlexIfNeeded(webTag, resolvedBase, userStyle) {
626
625
  if (!webTag || !resolvedBase) return userStyle;
@@ -3,8 +3,8 @@ import {
3
3
  Fragment,
4
4
  jsx,
5
5
  jsxs
6
- } from "./chunk-MOWXWICC.mjs";
7
- import "./chunk-OIJ6RP4F.mjs";
6
+ } from "./chunk-JUGDQQQ4.mjs";
7
+ import "./chunk-E322MVGC.mjs";
8
8
 
9
9
  // src/jsx-dev-runtime.tsx
10
10
  function jsxDEV(type, props, key, isStaticChildren, source, self) {
@@ -235,7 +235,7 @@ var InteractiveWrapper = (0, import_react2.forwardRef)(
235
235
  [resolvedStyle, isDark, pressed, hovered, focused, width, disabled, checked, isNonStringComponent]
236
236
  );
237
237
  const skipComputedInline = isWebPlatform;
238
- const finalStyle = skipComputedInline ? styleProp ?? void 0 : styleProp ? Array.isArray(styleProp) ? Object.assign({}, computedStyle, ...styleProp) : { ...computedStyle, ...styleProp } : computedStyle;
238
+ const finalStyle = skipComputedInline ? styleProp ?? void 0 : styleProp ? Array.isArray(styleProp) ? [computedStyle, ...styleProp] : [computedStyle, styleProp] : computedStyle;
239
239
  const componentProps = {
240
240
  ref,
241
241
  ...restForComponent,
@@ -292,7 +292,7 @@ var DarkWrapper = import_react3.default.forwardRef(
292
292
  return s;
293
293
  }, [resolvedStyle, isDark, width, screens, isNonStringComponent]);
294
294
  const skipComputedInline = isWebPlatform;
295
- const finalStyle = skipComputedInline ? styleProp ?? void 0 : styleProp ? Array.isArray(styleProp) ? Object.assign({}, computedStyle, ...styleProp) : { ...computedStyle, ...styleProp } : computedStyle;
295
+ const finalStyle = skipComputedInline ? styleProp ?? void 0 : styleProp ? Array.isArray(styleProp) ? [computedStyle, ...styleProp] : [computedStyle, styleProp] : computedStyle;
296
296
  const props = { ref, ...rest, style: finalStyle };
297
297
  return Array.isArray(children) ? import_react3.default.createElement(Component, props, ...children) : import_react3.default.createElement(Component, props, children);
298
298
  }
@@ -625,8 +625,7 @@ function omitConsumed(props) {
625
625
  }
626
626
  function mergeStyle(computed, userStyle) {
627
627
  if (!userStyle) return computed;
628
- if (Array.isArray(userStyle)) return Object.assign({}, computed, ...userStyle);
629
- return { ...computed, ...userStyle };
628
+ return Array.isArray(userStyle) ? [computed, ...userStyle] : [computed, userStyle];
630
629
  }
631
630
  function withImpliedFlexIfNeeded(webTag, resolvedBase, userStyle) {
632
631
  if (!webTag || !resolvedBase) return userStyle;
@@ -4,10 +4,10 @@ import {
4
4
  _invalidateDefaultFontCache,
5
5
  jsx,
6
6
  jsxs
7
- } from "./chunk-MOWXWICC.mjs";
7
+ } from "./chunk-JUGDQQQ4.mjs";
8
8
  import {
9
9
  registerWebElement
10
- } from "./chunk-OIJ6RP4F.mjs";
10
+ } from "./chunk-E322MVGC.mjs";
11
11
  export {
12
12
  Fragment,
13
13
  _invalidateDefaultFontCache,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kbach/react",
3
- "version": "0.6.31",
3
+ "version": "0.6.32",
4
4
  "description": "React / React Native components and hooks for the Kbach framework",
5
5
  "repository": {
6
6
  "type": "git",