@nimbus-ds/box 4.3.2 → 4.4.0
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 +12 -0
- package/dist/CHANGELOG.md +12 -0
- package/dist/index.d.ts +21 -23
- package/dist/index.js +1 -1
- package/package.json +4 -4
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,18 @@
|
|
|
2
2
|
|
|
3
3
|
A low-level utility component that accepts styled system props to enable custom theme-aware styling
|
|
4
4
|
|
|
5
|
+
## 2026-02-12 `4.4.0`
|
|
6
|
+
|
|
7
|
+
#### 🎉 New features
|
|
8
|
+
|
|
9
|
+
- Enabled `className` prop forwarding to allow consumers to pass custom CSS classes. ([#426](https://github.com/TiendaNube/nimbus-design-system/pull/426) by [@joacotornello](https://github.com/joacotornello))
|
|
10
|
+
|
|
11
|
+
## 2026-01-13 `4.3.3`
|
|
12
|
+
|
|
13
|
+
#### 🎉 New features
|
|
14
|
+
|
|
15
|
+
- Adds support for React 19. ([#404](https://github.com/TiendaNube/nimbus-design-system/pull/404) by [@joacotornello](https://github.com/joacotornello))
|
|
16
|
+
|
|
5
17
|
## 2025-11-11 `4.3.2`
|
|
6
18
|
|
|
7
19
|
#### 🎉 New features
|
package/dist/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,18 @@
|
|
|
2
2
|
|
|
3
3
|
A low-level utility component that accepts styled system props to enable custom theme-aware styling
|
|
4
4
|
|
|
5
|
+
## 2026-02-12 `4.4.0`
|
|
6
|
+
|
|
7
|
+
#### 🎉 New features
|
|
8
|
+
|
|
9
|
+
- Enabled `className` prop forwarding to allow consumers to pass custom CSS classes. ([#426](https://github.com/TiendaNube/nimbus-design-system/pull/426) by [@joacotornello](https://github.com/joacotornello))
|
|
10
|
+
|
|
11
|
+
## 2026-01-13 `4.3.3`
|
|
12
|
+
|
|
13
|
+
#### 🎉 New features
|
|
14
|
+
|
|
15
|
+
- Adds support for React 19. ([#404](https://github.com/TiendaNube/nimbus-design-system/pull/404) by [@joacotornello](https://github.com/joacotornello))
|
|
16
|
+
|
|
5
17
|
## 2025-11-11 `4.3.2`
|
|
6
18
|
|
|
7
19
|
#### 🎉 New features
|
package/dist/index.d.ts
CHANGED
|
@@ -22,10 +22,10 @@ export interface PolymorphicForwardRefComponent<IntrinsicElementString, OwnProps
|
|
|
22
22
|
* so that events are typed when using JSX.IntrinsicElements.
|
|
23
23
|
*/
|
|
24
24
|
<As = IntrinsicElementString>(props: As extends "" ? {
|
|
25
|
-
as: keyof JSX.IntrinsicElements;
|
|
25
|
+
as: keyof React.JSX.IntrinsicElements;
|
|
26
26
|
} : As extends React.ComponentType<infer P> ? Merge<P, OwnProps & {
|
|
27
27
|
as: As;
|
|
28
|
-
}> : As extends keyof JSX.IntrinsicElements ? Merge<JSX.IntrinsicElements[As], OwnProps & {
|
|
28
|
+
}> : As extends keyof React.JSX.IntrinsicElements ? Merge<React.JSX.IntrinsicElements[As], OwnProps & {
|
|
29
29
|
as: As;
|
|
30
30
|
}> : never): React.ReactElement | null;
|
|
31
31
|
}
|
|
@@ -34,6 +34,7 @@ export interface Conditions<T> {
|
|
|
34
34
|
md?: T;
|
|
35
35
|
lg?: T;
|
|
36
36
|
xl?: T;
|
|
37
|
+
xxl?: T;
|
|
37
38
|
}
|
|
38
39
|
export type BorderStyle = "solid" | "none" | "hidden" | "dashed" | "dotted";
|
|
39
40
|
export type BoxSizing = "border-box" | "content-box";
|
|
@@ -50,6 +51,7 @@ export type Position = "absolute" | "fixed" | "relative" | "static" | "sticky";
|
|
|
50
51
|
export type Overflow = "visible" | "hidden" | "scroll" | "auto";
|
|
51
52
|
export type PointerEvents = "auto" | "none" | "visiblePainted" | "visibleFill" | "visibleStroke" | "visible" | "painted" | "fill" | "stroke" | "all" | "inherit";
|
|
52
53
|
export type TransitionTiming = "ease" | "ease-in" | "ease-out" | "ease-in-out" | "linear" | "step-start" | "step-end";
|
|
54
|
+
export type ScrollbarWidth = "auto" | "none" | "thin";
|
|
53
55
|
declare const propertiesBox: {
|
|
54
56
|
gap: {
|
|
55
57
|
none: string;
|
|
@@ -110,9 +112,7 @@ declare const propertiesBox: {
|
|
|
110
112
|
"primary-interactive": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
111
113
|
"primary-surface": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
112
114
|
"primary-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
113
|
-
"primary-textLow": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
114
|
-
* The width property specifies the width of a box's content area.
|
|
115
|
-
*/
|
|
115
|
+
"primary-textLow": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
116
116
|
"success-interactive": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
117
117
|
"success-surface": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
118
118
|
"success-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
@@ -146,9 +146,7 @@ declare const propertiesBox: {
|
|
|
146
146
|
"primary-interactive": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
147
147
|
"primary-surface": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
148
148
|
"primary-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
149
|
-
"primary-textLow": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
150
|
-
* The width property specifies the width of a box's content area.
|
|
151
|
-
*/
|
|
149
|
+
"primary-textLow": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
152
150
|
"success-interactive": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
153
151
|
"success-surface": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
154
152
|
"success-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
@@ -181,18 +179,17 @@ declare const propertiesBox: {
|
|
|
181
179
|
"success-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
182
180
|
"warning-interactive": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
183
181
|
"warning-surface": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
184
|
-
"warning-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
182
|
+
"warning-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`; /**
|
|
183
|
+
* The gridTemplateAreas property specifies named grid areas, establishing the cells in the grid and assigning them names.
|
|
184
|
+
*/
|
|
185
185
|
"danger-interactive": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
186
186
|
"danger-surface": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
187
187
|
"danger-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
188
188
|
"neutral-interactive": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
189
|
-
/**
|
|
190
|
-
* The gridArea shorthand property specifies a grid item's size and location within a grid by contributing a line,
|
|
191
|
-
* a span, or nothing (automatic) to its grid placement, thereby specifying the edges of its grid area.
|
|
192
|
-
*/
|
|
193
189
|
"neutral-surface": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
194
190
|
"neutral-surfaceDisabled": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
195
191
|
"neutral-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
192
|
+
"ai-generative-interactiveHover": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
196
193
|
transparent: string;
|
|
197
194
|
};
|
|
198
195
|
borderRadius: {
|
|
@@ -211,16 +208,16 @@ declare const propertiesBox: {
|
|
|
211
208
|
borderWidth: {
|
|
212
209
|
"1": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
213
210
|
"2": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
214
|
-
"3": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
215
|
-
* The gap property sets the gaps between rows and columns. It is a shorthand for rowGap and columnGap.
|
|
216
|
-
*/
|
|
211
|
+
"3": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
217
212
|
"4": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
218
213
|
"5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
219
214
|
none: string;
|
|
220
215
|
};
|
|
221
216
|
borderStyle: BorderStyle[];
|
|
222
217
|
boxSizing: BoxSizing[];
|
|
223
|
-
cursor: Cursor[];
|
|
218
|
+
cursor: Cursor[]; /**
|
|
219
|
+
* The padding properties are used to generate space around an box's content area.
|
|
220
|
+
*/
|
|
224
221
|
spacing: {
|
|
225
222
|
none: string;
|
|
226
223
|
"0-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
@@ -335,9 +332,7 @@ declare const propertiesBox: {
|
|
|
335
332
|
h2: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
336
333
|
h3: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
337
334
|
h4: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
338
|
-
h5: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
339
|
-
* This defines the ability for a flex item to grow if necessary.
|
|
340
|
-
*/
|
|
335
|
+
h5: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
341
336
|
h6: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
342
337
|
};
|
|
343
338
|
lineHeight: {
|
|
@@ -362,15 +357,14 @@ declare const propertiesBox: {
|
|
|
362
357
|
"16": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
363
358
|
"18": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
364
359
|
"20": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
365
|
-
h1: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
366
|
-
* The flexWrap property sets whether flex items are forced onto one line or can wrap onto multiple lines.
|
|
367
|
-
*/
|
|
360
|
+
h1: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
368
361
|
h2: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
369
362
|
h3: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
370
363
|
h4: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
371
364
|
h5: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
372
365
|
h6: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
373
366
|
};
|
|
367
|
+
scrollbarWidth: ScrollbarWidth[];
|
|
374
368
|
};
|
|
375
369
|
export type BoxBorderColorProperties = keyof typeof propertiesBox.borderColor;
|
|
376
370
|
export type BoxBorderRadiusProperties = keyof typeof propertiesBox.borderRadius;
|
|
@@ -771,6 +765,10 @@ export interface BoxSprinkle {
|
|
|
771
765
|
* @default left
|
|
772
766
|
*/
|
|
773
767
|
textAlign?: TextAlign | BoxConditions<TextAlign>;
|
|
768
|
+
/**
|
|
769
|
+
* The scrollbarWidth property specifies the width of the scrollbar.
|
|
770
|
+
*/
|
|
771
|
+
scrollbarWidth?: ScrollbarWidth | BoxConditions<ScrollbarWidth>;
|
|
774
772
|
}
|
|
775
773
|
export interface BoxProperties extends BoxSprinkle {
|
|
776
774
|
/**
|
package/dist/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("react"),require("@nimbus-ds/styles")):"function"==typeof define&&define.amd?define(["react","@nimbus-ds/styles"],t):"object"==typeof exports?exports["@nimbus-ds/box"]=t(require("react"),require("@nimbus-ds/styles")):e["@nimbus-ds/box"]=t(e.react,e["@nimbus-ds/styles"])}(global,((e,t)=>(()=>{"use strict";var r={971:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.Box=void 0;const n=r(769).__importStar(r(155)),o=r(367),a=(0,n.forwardRef)((({className:e,style:t,as:r="div",boxSizing:a="border-box",...i},c)=>{const s="button"===r,{className:u,style:l,otherProps:f}=o.box.sprinkle({...i,boxSizing:a}),p=[u,s&&o.box.asButton].filter(Boolean).join(" ");return n.default.createElement(r,{ref:c,className:p,style:l,...f})}));t.Box=a,a.displayName="Box"},367:e=>{e.exports=t},155:t=>{t.exports=e},769:(e,t,r)=>{r.r(t),r.d(t,{__addDisposableResource:()=>A,__assign:()=>a,__asyncDelegator:()=>P,__asyncGenerator:()=>x,__asyncValues:()=>S,__await:()=>j,__awaiter:()=>d,__classPrivateFieldGet:()=>I,__classPrivateFieldIn:()=>R,__classPrivateFieldSet:()=>B,__createBinding:()=>b,__decorate:()=>c,__disposeResources:()=>M,__esDecorate:()=>u,__exportStar:()=>v,__extends:()=>o,__generator:()=>_,__importDefault:()=>k,__importStar:()=>D,__makeTemplateObject:()=>E,__metadata:()=>y,__param:()=>s,__propKey:()=>f,__read:()=>w,__rest:()=>i,__runInitializers:()=>l,__setFunctionName:()=>p,__spread:()=>m,__spreadArray:()=>O,__spreadArrays:()=>g,__values:()=>h,default:()=>z});var n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])},n(e,t)};function o(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}var a=function(){return a=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var o in t=arguments[r])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},a.apply(this,arguments)};function i(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]])}return r}function c(e,t,r,n){var o,a=arguments.length,i=a<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var c=e.length-1;c>=0;c--)(o=e[c])&&(i=(a<3?o(i):a>3?o(t,r,i):o(t,r))||i);return a>3&&i&&Object.defineProperty(t,r,i),i}function s(e,t){return function(r,n){t(r,n,e)}}function u(e,t,r,n,o,a){function i(e){if(void 0!==e&&"function"!=typeof e)throw new TypeError("Function expected");return e}for(var c,s=n.kind,u="getter"===s?"get":"setter"===s?"set":"value",l=!t&&e?n.static?e:e.prototype:null,f=t||(l?Object.getOwnPropertyDescriptor(l,n.name):{}),p=!1,y=r.length-1;y>=0;y--){var d={};for(var _ in n)d[_]="access"===_?{}:n[_];for(var _ in n.access)d.access[_]=n.access[_];d.addInitializer=function(e){if(p)throw new TypeError("Cannot add initializers after decoration has completed");a.push(i(e||null))};var b=(0,r[y])("accessor"===s?{get:f.get,set:f.set}:f[u],d);if("accessor"===s){if(void 0===b)continue;if(null===b||"object"!=typeof b)throw new TypeError("Object expected");(c=i(b.get))&&(f.get=c),(c=i(b.set))&&(f.set=c),(c=i(b.init))&&o.unshift(c)}else(c=i(b))&&("field"===s?o.unshift(c):f[u]=c)}l&&Object.defineProperty(l,n.name,f),p=!0}function l(e,t,r){for(var n=arguments.length>2,o=0;o<t.length;o++)r=n?t[o].call(e,r):t[o].call(e);return n?r:void 0}function f(e){return"symbol"==typeof e?e:"".concat(e)}function p(e,t,r){return"symbol"==typeof t&&(t=t.description?"[".concat(t.description,"]"):""),Object.defineProperty(e,"name",{configurable:!0,value:r?"".concat(r," ",t):t})}function y(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)}function d(e,t,r,n){return new(r||(r=Promise))((function(o,a){function i(e){try{s(n.next(e))}catch(e){a(e)}}function c(e){try{s(n.throw(e))}catch(e){a(e)}}function s(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(i,c)}s((n=n.apply(e,t||[])).next())}))}function _(e,t){var r,n,o,a,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return a={next:c(0),throw:c(1),return:c(2)},"function"==typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a;function c(c){return function(s){return function(c){if(r)throw new TypeError("Generator is already executing.");for(;a&&(a=0,c[0]&&(i=0)),i;)try{if(r=1,n&&(o=2&c[0]?n.return:c[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,c[1])).done)return o;switch(n=0,o&&(c=[2&c[0],o.value]),c[0]){case 0:case 1:o=c;break;case 4:return i.label++,{value:c[1],done:!1};case 5:i.label++,n=c[1],c=[0];continue;case 7:c=i.ops.pop(),i.trys.pop();continue;default:if(!(o=i.trys,(o=o.length>0&&o[o.length-1])||6!==c[0]&&2!==c[0])){i=0;continue}if(3===c[0]&&(!o||c[1]>o[0]&&c[1]<o[3])){i.label=c[1];break}if(6===c[0]&&i.label<o[1]){i.label=o[1],o=c;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(c);break}o[2]&&i.ops.pop(),i.trys.pop();continue}c=t.call(e,i)}catch(e){c=[6,e],n=0}finally{r=o=0}if(5&c[0])throw c[1];return{value:c[0]?c[1]:void 0,done:!0}}([c,s])}}}var b=Object.create?function(e,t,r,n){void 0===n&&(n=r);var o=Object.getOwnPropertyDescriptor(t,r);o&&!("get"in o?!t.__esModule:o.writable||o.configurable)||(o={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,o)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]};function v(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||b(t,e,r)}function h(e){var t="function"==typeof Symbol&&Symbol.iterator,r=t&&e[t],n=0;if(r)return r.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&n>=e.length&&(e=void 0),{value:e&&e[n++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function w(e,t){var r="function"==typeof Symbol&&e[Symbol.iterator];if(!r)return e;var n,o,a=r.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(n=a.next()).done;)i.push(n.value)}catch(e){o={error:e}}finally{try{n&&!n.done&&(r=a.return)&&r.call(a)}finally{if(o)throw o.error}}return i}function m(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(w(arguments[t]));return e}function g(){for(var e=0,t=0,r=arguments.length;t<r;t++)e+=arguments[t].length;var n=Array(e),o=0;for(t=0;t<r;t++)for(var a=arguments[t],i=0,c=a.length;i<c;i++,o++)n[o]=a[i];return n}function O(e,t,r){if(r||2===arguments.length)for(var n,o=0,a=t.length;o<a;o++)!n&&o in t||(n||(n=Array.prototype.slice.call(t,0,o)),n[o]=t[o]);return e.concat(n||Array.prototype.slice.call(t))}function j(e){return this instanceof j?(this.v=e,this):new j(e)}function x(e,t,r){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var n,o=r.apply(e,t||[]),a=[];return n={},i("next"),i("throw"),i("return"),n[Symbol.asyncIterator]=function(){return this},n;function i(e){o[e]&&(n[e]=function(t){return new Promise((function(r,n){a.push([e,t,r,n])>1||c(e,t)}))})}function c(e,t){try{(r=o[e](t)).value instanceof j?Promise.resolve(r.value.v).then(s,u):l(a[0][2],r)}catch(e){l(a[0][3],e)}var r}function s(e){c("next",e)}function u(e){c("throw",e)}function l(e,t){e(t),a.shift(),a.length&&c(a[0][0],a[0][1])}}function P(e){var t,r;return t={},n("next"),n("throw",(function(e){throw e})),n("return"),t[Symbol.iterator]=function(){return this},t;function n(n,o){t[n]=e[n]?function(t){return(r=!r)?{value:j(e[n](t)),done:!1}:o?o(t):t}:o}}function S(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t,r=e[Symbol.asyncIterator];return r?r.call(e):(e=h(e),t={},n("next"),n("throw"),n("return"),t[Symbol.asyncIterator]=function(){return this},t);function n(r){t[r]=e[r]&&function(t){return new Promise((function(n,o){(function(e,t,r,n){Promise.resolve(n).then((function(t){e({value:t,done:r})}),t)})(n,o,(t=e[r](t)).done,t.value)}))}}}function E(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e}var T=Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t};function D(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.prototype.hasOwnProperty.call(e,r)&&b(t,e,r);return T(t,e),t}function k(e){return e&&e.__esModule?e:{default:e}}function I(e,t,r,n){if("a"===r&&!n)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!n:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===r?n:"a"===r?n.call(e):n?n.value:t.get(e)}function B(e,t,r,n,o){if("m"===n)throw new TypeError("Private method is not writable");if("a"===n&&!o)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!o:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===n?o.call(e,r):o?o.value=r:t.set(e,r),r}function R(e,t){if(null===t||"object"!=typeof t&&"function"!=typeof t)throw new TypeError("Cannot use 'in' operator on non-object");return"function"==typeof e?t===e:e.has(t)}function A(e,t,r){if(null!=t){if("object"!=typeof t&&"function"!=typeof t)throw new TypeError("Object expected.");var n;if(r){if(!Symbol.asyncDispose)throw new TypeError("Symbol.asyncDispose is not defined.");n=t[Symbol.asyncDispose]}if(void 0===n){if(!Symbol.dispose)throw new TypeError("Symbol.dispose is not defined.");n=t[Symbol.dispose]}if("function"!=typeof n)throw new TypeError("Object not disposable.");e.stack.push({value:t,dispose:n,async:r})}else r&&e.stack.push({async:!0});return t}var F="function"==typeof SuppressedError?SuppressedError:function(e,t,r){var n=new Error(r);return n.name="SuppressedError",n.error=e,n.suppressed=t,n};function M(e){function t(t){e.error=e.hasError?new F(t,e.error,"An error was suppressed during disposal."):t,e.hasError=!0}return function r(){for(;e.stack.length;){var n=e.stack.pop();try{var o=n.dispose&&n.dispose.call(n.value);if(n.async)return Promise.resolve(o).then(r,(function(e){return t(e),r()}))}catch(e){t(e)}}if(e.hasError)throw e.error}()}const z={__extends:o,__assign:a,__rest:i,__decorate:c,__param:s,__metadata:y,__awaiter:d,__generator:_,__createBinding:b,__exportStar:v,__values:h,__read:w,__spread:m,__spreadArrays:g,__spreadArray:O,__await:j,__asyncGenerator:x,__asyncDelegator:P,__asyncValues:S,__makeTemplateObject:E,__importStar:D,__importDefault:k,__classPrivateFieldGet:I,__classPrivateFieldSet:B,__classPrivateFieldIn:R,__addDisposableResource:A,__disposeResources:M}}},n={};function o(e){var t=n[e];if(void 0!==t)return t.exports;var a=n[e]={exports:{}};return r[e](a,a.exports,o),a.exports}o.d=(e,t)=>{for(var r in t)o.o(t,r)&&!o.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},o.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),o.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var a={};return(()=>{var e=a;Object.defineProperty(e,"__esModule",{value:!0}),e.Box=void 0;const t=o(971);var r=o(971);Object.defineProperty(e,"Box",{enumerable:!0,get:function(){return r.Box}}),e.default=t.Box})(),a})()));
|
|
1
|
+
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("react"),require("@nimbus-ds/styles")):"function"==typeof define&&define.amd?define(["react","@nimbus-ds/styles"],t):"object"==typeof exports?exports["@nimbus-ds/box"]=t(require("react"),require("@nimbus-ds/styles")):e["@nimbus-ds/box"]=t(e.react,e["@nimbus-ds/styles"])}(global,((e,t)=>(()=>{"use strict";var r={971:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.Box=void 0;const n=r(769).__importStar(r(155)),o=r(367),a=(0,n.forwardRef)((({className:e,style:t,as:r="div",boxSizing:a="border-box",...i},c)=>{const s="button"===r,{className:u,style:l,otherProps:f}=o.box.sprinkle({...i,boxSizing:a}),p=[e,u,s&&o.box.asButton].filter(Boolean).join(" ");return n.default.createElement(r,{ref:c,className:p,style:l,...f})}));t.Box=a,a.displayName="Box"},367:e=>{e.exports=t},155:t=>{t.exports=e},769:(e,t,r)=>{r.r(t),r.d(t,{__addDisposableResource:()=>A,__assign:()=>a,__asyncDelegator:()=>P,__asyncGenerator:()=>x,__asyncValues:()=>S,__await:()=>j,__awaiter:()=>d,__classPrivateFieldGet:()=>I,__classPrivateFieldIn:()=>R,__classPrivateFieldSet:()=>B,__createBinding:()=>b,__decorate:()=>c,__disposeResources:()=>M,__esDecorate:()=>u,__exportStar:()=>v,__extends:()=>o,__generator:()=>_,__importDefault:()=>k,__importStar:()=>D,__makeTemplateObject:()=>E,__metadata:()=>y,__param:()=>s,__propKey:()=>f,__read:()=>w,__rest:()=>i,__runInitializers:()=>l,__setFunctionName:()=>p,__spread:()=>m,__spreadArray:()=>O,__spreadArrays:()=>g,__values:()=>h,default:()=>z});var n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])},n(e,t)};function o(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}var a=function(){return a=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var o in t=arguments[r])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},a.apply(this,arguments)};function i(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]])}return r}function c(e,t,r,n){var o,a=arguments.length,i=a<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var c=e.length-1;c>=0;c--)(o=e[c])&&(i=(a<3?o(i):a>3?o(t,r,i):o(t,r))||i);return a>3&&i&&Object.defineProperty(t,r,i),i}function s(e,t){return function(r,n){t(r,n,e)}}function u(e,t,r,n,o,a){function i(e){if(void 0!==e&&"function"!=typeof e)throw new TypeError("Function expected");return e}for(var c,s=n.kind,u="getter"===s?"get":"setter"===s?"set":"value",l=!t&&e?n.static?e:e.prototype:null,f=t||(l?Object.getOwnPropertyDescriptor(l,n.name):{}),p=!1,y=r.length-1;y>=0;y--){var d={};for(var _ in n)d[_]="access"===_?{}:n[_];for(var _ in n.access)d.access[_]=n.access[_];d.addInitializer=function(e){if(p)throw new TypeError("Cannot add initializers after decoration has completed");a.push(i(e||null))};var b=(0,r[y])("accessor"===s?{get:f.get,set:f.set}:f[u],d);if("accessor"===s){if(void 0===b)continue;if(null===b||"object"!=typeof b)throw new TypeError("Object expected");(c=i(b.get))&&(f.get=c),(c=i(b.set))&&(f.set=c),(c=i(b.init))&&o.unshift(c)}else(c=i(b))&&("field"===s?o.unshift(c):f[u]=c)}l&&Object.defineProperty(l,n.name,f),p=!0}function l(e,t,r){for(var n=arguments.length>2,o=0;o<t.length;o++)r=n?t[o].call(e,r):t[o].call(e);return n?r:void 0}function f(e){return"symbol"==typeof e?e:"".concat(e)}function p(e,t,r){return"symbol"==typeof t&&(t=t.description?"[".concat(t.description,"]"):""),Object.defineProperty(e,"name",{configurable:!0,value:r?"".concat(r," ",t):t})}function y(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)}function d(e,t,r,n){return new(r||(r=Promise))((function(o,a){function i(e){try{s(n.next(e))}catch(e){a(e)}}function c(e){try{s(n.throw(e))}catch(e){a(e)}}function s(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(i,c)}s((n=n.apply(e,t||[])).next())}))}function _(e,t){var r,n,o,a,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return a={next:c(0),throw:c(1),return:c(2)},"function"==typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a;function c(c){return function(s){return function(c){if(r)throw new TypeError("Generator is already executing.");for(;a&&(a=0,c[0]&&(i=0)),i;)try{if(r=1,n&&(o=2&c[0]?n.return:c[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,c[1])).done)return o;switch(n=0,o&&(c=[2&c[0],o.value]),c[0]){case 0:case 1:o=c;break;case 4:return i.label++,{value:c[1],done:!1};case 5:i.label++,n=c[1],c=[0];continue;case 7:c=i.ops.pop(),i.trys.pop();continue;default:if(!(o=i.trys,(o=o.length>0&&o[o.length-1])||6!==c[0]&&2!==c[0])){i=0;continue}if(3===c[0]&&(!o||c[1]>o[0]&&c[1]<o[3])){i.label=c[1];break}if(6===c[0]&&i.label<o[1]){i.label=o[1],o=c;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(c);break}o[2]&&i.ops.pop(),i.trys.pop();continue}c=t.call(e,i)}catch(e){c=[6,e],n=0}finally{r=o=0}if(5&c[0])throw c[1];return{value:c[0]?c[1]:void 0,done:!0}}([c,s])}}}var b=Object.create?function(e,t,r,n){void 0===n&&(n=r);var o=Object.getOwnPropertyDescriptor(t,r);o&&!("get"in o?!t.__esModule:o.writable||o.configurable)||(o={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,o)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]};function v(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||b(t,e,r)}function h(e){var t="function"==typeof Symbol&&Symbol.iterator,r=t&&e[t],n=0;if(r)return r.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&n>=e.length&&(e=void 0),{value:e&&e[n++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function w(e,t){var r="function"==typeof Symbol&&e[Symbol.iterator];if(!r)return e;var n,o,a=r.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(n=a.next()).done;)i.push(n.value)}catch(e){o={error:e}}finally{try{n&&!n.done&&(r=a.return)&&r.call(a)}finally{if(o)throw o.error}}return i}function m(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(w(arguments[t]));return e}function g(){for(var e=0,t=0,r=arguments.length;t<r;t++)e+=arguments[t].length;var n=Array(e),o=0;for(t=0;t<r;t++)for(var a=arguments[t],i=0,c=a.length;i<c;i++,o++)n[o]=a[i];return n}function O(e,t,r){if(r||2===arguments.length)for(var n,o=0,a=t.length;o<a;o++)!n&&o in t||(n||(n=Array.prototype.slice.call(t,0,o)),n[o]=t[o]);return e.concat(n||Array.prototype.slice.call(t))}function j(e){return this instanceof j?(this.v=e,this):new j(e)}function x(e,t,r){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var n,o=r.apply(e,t||[]),a=[];return n={},i("next"),i("throw"),i("return"),n[Symbol.asyncIterator]=function(){return this},n;function i(e){o[e]&&(n[e]=function(t){return new Promise((function(r,n){a.push([e,t,r,n])>1||c(e,t)}))})}function c(e,t){try{(r=o[e](t)).value instanceof j?Promise.resolve(r.value.v).then(s,u):l(a[0][2],r)}catch(e){l(a[0][3],e)}var r}function s(e){c("next",e)}function u(e){c("throw",e)}function l(e,t){e(t),a.shift(),a.length&&c(a[0][0],a[0][1])}}function P(e){var t,r;return t={},n("next"),n("throw",(function(e){throw e})),n("return"),t[Symbol.iterator]=function(){return this},t;function n(n,o){t[n]=e[n]?function(t){return(r=!r)?{value:j(e[n](t)),done:!1}:o?o(t):t}:o}}function S(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t,r=e[Symbol.asyncIterator];return r?r.call(e):(e=h(e),t={},n("next"),n("throw"),n("return"),t[Symbol.asyncIterator]=function(){return this},t);function n(r){t[r]=e[r]&&function(t){return new Promise((function(n,o){(function(e,t,r,n){Promise.resolve(n).then((function(t){e({value:t,done:r})}),t)})(n,o,(t=e[r](t)).done,t.value)}))}}}function E(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e}var T=Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t};function D(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.prototype.hasOwnProperty.call(e,r)&&b(t,e,r);return T(t,e),t}function k(e){return e&&e.__esModule?e:{default:e}}function I(e,t,r,n){if("a"===r&&!n)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!n:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===r?n:"a"===r?n.call(e):n?n.value:t.get(e)}function B(e,t,r,n,o){if("m"===n)throw new TypeError("Private method is not writable");if("a"===n&&!o)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!o:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===n?o.call(e,r):o?o.value=r:t.set(e,r),r}function R(e,t){if(null===t||"object"!=typeof t&&"function"!=typeof t)throw new TypeError("Cannot use 'in' operator on non-object");return"function"==typeof e?t===e:e.has(t)}function A(e,t,r){if(null!=t){if("object"!=typeof t&&"function"!=typeof t)throw new TypeError("Object expected.");var n;if(r){if(!Symbol.asyncDispose)throw new TypeError("Symbol.asyncDispose is not defined.");n=t[Symbol.asyncDispose]}if(void 0===n){if(!Symbol.dispose)throw new TypeError("Symbol.dispose is not defined.");n=t[Symbol.dispose]}if("function"!=typeof n)throw new TypeError("Object not disposable.");e.stack.push({value:t,dispose:n,async:r})}else r&&e.stack.push({async:!0});return t}var F="function"==typeof SuppressedError?SuppressedError:function(e,t,r){var n=new Error(r);return n.name="SuppressedError",n.error=e,n.suppressed=t,n};function M(e){function t(t){e.error=e.hasError?new F(t,e.error,"An error was suppressed during disposal."):t,e.hasError=!0}return function r(){for(;e.stack.length;){var n=e.stack.pop();try{var o=n.dispose&&n.dispose.call(n.value);if(n.async)return Promise.resolve(o).then(r,(function(e){return t(e),r()}))}catch(e){t(e)}}if(e.hasError)throw e.error}()}const z={__extends:o,__assign:a,__rest:i,__decorate:c,__param:s,__metadata:y,__awaiter:d,__generator:_,__createBinding:b,__exportStar:v,__values:h,__read:w,__spread:m,__spreadArrays:g,__spreadArray:O,__await:j,__asyncGenerator:x,__asyncDelegator:P,__asyncValues:S,__makeTemplateObject:E,__importStar:D,__importDefault:k,__classPrivateFieldGet:I,__classPrivateFieldSet:B,__classPrivateFieldIn:R,__addDisposableResource:A,__disposeResources:M}}},n={};function o(e){var t=n[e];if(void 0!==t)return t.exports;var a=n[e]={exports:{}};return r[e](a,a.exports,o),a.exports}o.d=(e,t)=>{for(var r in t)o.o(t,r)&&!o.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},o.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),o.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var a={};return(()=>{var e=a;Object.defineProperty(e,"__esModule",{value:!0}),e.Box=void 0;const t=o(971);var r=o(971);Object.defineProperty(e,"Box",{enumerable:!0,get:function(){return r.Box}}),e.default=t.Box})(),a})()));
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nimbus-ds/box",
|
|
3
|
-
"version": "4.
|
|
3
|
+
"version": "4.4.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"files": [
|
|
@@ -14,8 +14,8 @@
|
|
|
14
14
|
"version": "yarn version"
|
|
15
15
|
},
|
|
16
16
|
"peerDependencies": {
|
|
17
|
-
"react": "^16.8 || ^17.0 || ^18.0",
|
|
18
|
-
"react-dom": "^16.8 || ^17.0 || ^18.0"
|
|
17
|
+
"react": "^16.8 || ^17.0 || ^18.0 || ^19.0",
|
|
18
|
+
"react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0"
|
|
19
19
|
},
|
|
20
20
|
"homepage": "https://nimbus.nuvemshop.com.br/documentation",
|
|
21
21
|
"repository": {
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
"url": "https://github.com/TiendaNube/nimbus-design-system/issues"
|
|
27
27
|
},
|
|
28
28
|
"devDependencies": {
|
|
29
|
-
"@nimbus-ds/webpack": "^1.7.
|
|
29
|
+
"@nimbus-ds/webpack": "^1.7.2",
|
|
30
30
|
"@vanilla-extract/dynamic": "^2.0.3"
|
|
31
31
|
}
|
|
32
32
|
}
|