@nextui-org/react 1.0.0-beta.11 → 1.0.0-beta.13
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/README.md +1 -1
- package/cjs/button/button.styles.js +1 -1
- package/cjs/card/card.js +1 -1
- package/cjs/checkbox/checkbox.js +1 -1
- package/cjs/input/input.js +1 -1
- package/cjs/input/input.styles.js +1 -1
- package/cjs/popover/popover-trigger.js +1 -1
- package/cjs/progress/progress.js +1 -1
- package/cjs/progress/progress.styles.js +1 -1
- package/cjs/radio/radio.js +1 -1
- package/cjs/textarea/textarea.js +1 -1
- package/cjs/tooltip/tooltip.js +1 -1
- package/cjs/use-pagination/index.js +1 -1
- package/esm/button/button.styles.js +1 -1
- package/esm/card/card.js +1 -1
- package/esm/card/use-card.js +1 -1
- package/esm/checkbox/checkbox.js +1 -1
- package/esm/input/input.js +1 -1
- package/esm/input/input.styles.js +1 -1
- package/esm/navbar/navbar-item.js +1 -1
- package/esm/popover/popover-trigger.js +1 -1
- package/esm/progress/progress.js +1 -1
- package/esm/progress/progress.styles.js +1 -1
- package/esm/radio/radio.js +1 -1
- package/esm/textarea/textarea.js +1 -1
- package/esm/tooltip/tooltip.js +1 -1
- package/esm/use-pagination/index.js +1 -1
- package/package.json +1 -1
- package/types/button/button.styles.d.ts +36 -0
- package/types/button/index.d.ts +1 -0
- package/types/dropdown/dropdown-context.d.ts +2 -2
- package/types/dropdown/use-dropdown.d.ts +1 -1
- package/types/input/input.styles.d.ts +1076 -0
- package/types/modal/modal.d.ts +1 -1
- package/types/table/table.d.ts +2 -1
- package/types/textarea/utils.d.ts +1 -1
- package/types/tooltip/tooltip.d.ts +1 -2
- package/umd/nextui.js +9522 -14564
- package/umd/nextui.min.js +1 -1
package/esm/progress/progress.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import e,{useMemo as r}from"react";import
|
|
1
|
+
import e,{useMemo as r}from"react";import i from"../utils/css-transition";import t from"../utils/with-defaults";import{valueToPercent as a}from"../utils/numbers";import s from"../utils/clsx";import{__DEV__ as m}from"../utils/assertion";import{StyledProgress as o,StyledProgressBar as n}from"./progress.styles";import{jsx as p}from"react/jsx-runtime";const d="nextui-progress",l=({value:e,max:t,min:m,striped:l,animated:u,shadow:c,indeterminated:x,css:f,...g})=>{const w=r((()=>e>t?t:e<m?m:e),[e,m,t]),v=r((()=>a(w,m,t)),[w,m,t]);return p(o,{"aria-label":"progress","aria-valuemax":t,"aria-valuemin":m,"aria-valuenow":w,css:{"nextui-progress-wrapper-enter":{opacity:0},".nextui-progress-wrapper-enter-active":{opacity:1,width:`${v}%`},...f},indeterminated:x,role:"progressbar",...g,children:p(i,{visible:!0,clearTime:300,enterTime:10,leaveTime:20,name:`${d}-wrapper`,children:p(n,{animated:u,className:s(`${d}-bar`,{[`${d}-striped`]:l,[`${d}-indeterminated`]:x}),indeterminated:x,shadow:c,striped:l,...g})})})};m&&(l.displayName="NextUI.Progress"),l.toString=()=>".nextui-progress";const u=e.memo(l);export default t(u,{striped:!1,animated:!0,shadow:!1,indeterminated:!1,value:0,min:0,max:100});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{styled as r,keyframes as o}from"../theme/stitches.config";const s=o({"0%":{left:"-40%"},"100%":{left:"100%"}});export const StyledProgress=r("div",{margin:0,padding:0,width:"100%",position:"relative",overflow:"
|
|
1
|
+
import{styled as r,keyframes as o}from"../theme/stitches.config";const s=o({"0%":{left:"-40%"},"100%":{left:"100%"}});export const StyledProgress=r("div",{margin:0,padding:0,width:"100%",position:"relative",overflow:"hidden",variants:{color:{default:{$$progressColor:"$colors$primary",$$progressShadowColor:"$colors$primaryShadow"},primary:{$$progressColor:"$colors$primary",$$progressShadowColor:"$colors$primaryShadow"},secondary:{$$progressColor:"$colors$secondary",$$progressShadowColor:"$colors$secondaryShadow"},success:{$$progressColor:"$colors$success",$$progressShadowColor:"$colors$successShadow"},warning:{$$progressColor:"$colors$warning",$$progressShadowColor:"$colors$warningShadow"},error:{$$progressColor:"$colors$error",$$progressShadowColor:"$colors$errorShadow"},gradient:{$$progressColor:"$colors$gradient",$$progressShadowColor:"$colors$primaryShadow"}},status:{default:{bg:"$accents2"},primary:{bg:"$primaryLight"},secondary:{bg:"$secondaryLight"},success:{bg:"$successLight"},warning:{bg:"$warningLight"},error:{bg:"$errorLight"}},size:{xs:{$$progressHeight:"$space$2",height:"$$progressHeight",br:"$$progressHeight"},sm:{$$progressHeight:"$space$4",height:"$$progressHeight",br:"$$progressHeight"},md:{$$progressHeight:"$space$8",height:"$$progressHeight",br:"$$progressHeight"},lg:{$$progressHeight:"$space$10",height:"$$progressHeight",br:"$$progressHeight"},xl:{$$progressHeight:"$space$11",height:"$$progressHeight",br:"$$progressHeight"}},indeterminated:{true:{overflow:"hidden"}},squared:{true:{br:"calc($$progressHeight * 0.25)"}}},defaultVariants:{color:"default",status:"default",size:"md"}});export const StyledProgressBar=r("div",{margin:0,padding:0,width:0,opacity:0,height:"100%",minWidth:"inherit",bg:"$$progressColor",br:"inherit",transition:"width 0.5s cubic-bezier(0.4, 0, 0.2, 1)","@motion":{transition:"none"},variants:{animated:{false:{transition:"none"}},shadow:{true:{normalShadowVar:"$$progressShadowColor"}},striped:{true:{backgroundImage:"linear-gradient(45deg, rgba(0, 0, 0, 0.1) 25%, transparent 25%, transparent 50%, rgba(0, 0, 0, 0.1) 50%, rgba(0, 0, 0, 0.1) 75%, transparent 75%, transparent)",backgroundSize:"$space$lg $space$lg"}},indeterminated:{true:{position:"absolute",width:"0%",transitionProperty:"background-color, width, left, border-color,opacity, shadow, transform",transitionDuration:"300ms",willChange:"left",minWidth:"50%",animation:`1s ease 0s infinite normal none running ${s}`}}}});
|
package/esm/radio/radio.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import i,{useMemo as e}from"react";import{mergeProps as s}from"@react-aria/utils";import{useFocusRing as r}from"@react-aria/focus";import{VisuallyHidden as a}from"@react-aria/visually-hidden";import o from"../utils/clsx";import{__DEV__ as t}from"../utils/assertion";import{useFocusableRef as d}from"../utils/dom";import{useRadio as l}from"./use-radio";import{StyledRadioText as c,StyledRadioPoint as n,StyledRadioLabel as u,StyledRadioDescription as m,StyledRadioContainer as p}from"./radio.styles";import{jsx as f}from"react/jsx-runtime";import{jsxs as h}from"react/jsx-runtime";export const Radio=i.forwardRef(((i,t)=>{const{className:x,as:b,css:v,children:N,label:R,description:k,...I}=i,{size:j,color:q,inputRef:D,labelColor:F,isHovered:y,isSquared:P,isInvalid:S,isDisabled:z,autoFocus:A,disableAnimation:C,hoverProps:H,inputProps:V,isRequired:g}=l({...I,children:null!=N?N:R}),w=d(t,D),{focusProps:U,isFocusVisible:$}=r({autoFocus:A}),B=e((()=>y?"is-hovered":z?"is-disabled":V.checked?"checked":"
|
|
1
|
+
import i,{useMemo as e}from"react";import{mergeProps as s}from"@react-aria/utils";import{useFocusRing as r}from"@react-aria/focus";import{VisuallyHidden as a}from"@react-aria/visually-hidden";import o from"../utils/clsx";import{__DEV__ as t}from"../utils/assertion";import{useFocusableRef as d}from"../utils/dom";import{useRadio as l}from"./use-radio";import{StyledRadioText as c,StyledRadioPoint as n,StyledRadioLabel as u,StyledRadioDescription as m,StyledRadioContainer as p}from"./radio.styles";import{jsx as f}from"react/jsx-runtime";import{jsxs as h}from"react/jsx-runtime";export const Radio=i.forwardRef(((i,t)=>{const{className:x,as:b,css:v,children:N,label:R,description:k,...I}=i,{size:j,color:q,inputRef:D,labelColor:F,isHovered:y,isSquared:P,isInvalid:S,isDisabled:z,autoFocus:A,disableAnimation:C,hoverProps:H,inputProps:V,isRequired:g}=l({...I,children:null!=N?N:R}),w=d(t,D),{focusProps:U,isFocusVisible:$}=r({autoFocus:A}),B=e((()=>y?"is-hovered":z?"is-disabled":V.checked?"checked":"unchecked"),[z,V.checked,y]);return h(u,{ref:w,...H,as:b,className:o("nextui-radio-label",`nextui-radio--${B}`,x),color:q,css:v,"data-state":B,disableAnimation:C,isChecked:V.checked,isDisabled:z,isHovered:y,isInvalid:S,isSquared:P,size:j,children:[h(p,{className:"nextui-radio-container",children:[f(n,{className:"nextui-radio-point",isFocusVisible:$,...U,children:f(a,{children:f("input",{ref:D,className:"nextui-radio-input",required:g,...s(V,U)})})}),f(c,{className:"nextui-radio-text",color:F,isDisabled:z,isInvalid:S,children:N})]}),k&&f(m,{className:"nextui-radio-description",isDisabled:z,isInvalid:S,children:k})]})}));t&&(Radio.displayName="NextUI.Radio"),Radio.toString=()=>".nextui-radio";export default Radio;
|
package/esm/textarea/textarea.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import e,{useRef as t,useImperativeHandle as r,useLayoutEffect as s}from"react";import o from"../utils/with-defaults";import i from"../input";import n from"../use-resize";import{warn as a}from"../utils/console";import{excludedInputPropsForTextarea as
|
|
1
|
+
import e,{useRef as t,useImperativeHandle as r,useLayoutEffect as s}from"react";import o from"../utils/with-defaults";import i from"../input";import n from"../use-resize";import{warn as a}from"../utils/console";import{excludedInputPropsForTextarea as u}from"../utils/prop-types";import{__DEV__ as m}from"../utils/assertion";import{calculateNodeHeight as l,getSizingData as c}from"./utils";import{jsx as p}from"react/jsx-runtime";const f=e.forwardRef(((o,f)=>{const x=t(null),h=e.useRef(0),d=e.useRef(),{cacheMeasurements:g,rows:y,maxRows:w,minRows:R,onChange:H,onHeightChange:v,css:j,...C}=o;Object.keys(C).forEach((e=>{u.indexOf(e)>-1&&delete C[e]}));const P=void 0!==C.value;m&&C.style&&("maxHeight"in C.style&&a("Using `style.maxHeight` for <Textarea/> is not supported. Please use `maxRows`."),"minHeight"in C.style&&a("Using `style.minHeight` for <Textarea/> is not supported. Please use `minRows`.")),r(f,(()=>x.current));const T=()=>{const e=x.current,t=g&&d.current?d.current:c(e);if(!t)return;d.current=t;const[r,s]=l(t,P&&C.value||e.value||e.placeholder||"x",y||R,y||w);h.current!==r&&(h.current=r,e.style.setProperty("height",`${r}px`,"important"),v&&v(r,{rowHeight:s}))};return"undefined"!=typeof document&&(s(T),n(T)),p(i,{ref:x,as:"textarea",css:j,onChange:e=>{T(),H&&H(e)},...C})}));m&&(f.displayName="NextUI.Textarea"),f.toString=()=>".nextui-textarea";export default o(f,{minRows:3,maxRows:6,cacheMeasurements:!0,initialValue:""});
|
package/esm/tooltip/tooltip.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import e,{useEffect as o,useRef as t,useState as i}from"react";import r from"../utils/with-defaults";import n from"../use-click-away";import l from"./tooltip-content";import{StyledTooltipTrigger as s}from"./tooltip.styles";import{jsx as a}from"react/jsx-runtime";import{jsxs as c}from"react/jsx-runtime";const m=({children:e,initialVisible:r,content:m,offset:
|
|
1
|
+
import e,{useEffect as o,useRef as t,useState as i}from"react";import r from"../utils/with-defaults";import n from"../use-click-away";import l from"./tooltip-content";import{StyledTooltipTrigger as s}from"./tooltip.styles";import{jsx as a}from"react/jsx-runtime";import{jsxs as c}from"react/jsx-runtime";const m=({children:e,initialVisible:r,content:m,offset:u,placement:d,portalClassName:p,enterDelay:f,leaveDelay:h,trigger:w,rounded:b,animated:C,shadow:g,className:v,color:x,contentColor:k,onVisibleChange:y,hideArrow:D,css:N,triggerCss:j,onClick:M,keepMounted:V,visible:A,isDisabled:T,...B})=>{const E=t(),F=t(null),[I,K]=i(r),L={animated:C,visible:I,css:N,shadow:g,offset:u,placement:d,rounded:b,color:x,contentColor:k,hideArrow:D,parent:F,className:p},S=e=>{const o=()=>{clearTimeout(E.current),E.current=void 0},t=e=>{K(e),y(e),o()};o(),E.current=e?window.setTimeout((()=>t(!0)),f):window.setTimeout((()=>t(!1)),h)},U=e=>{"hover"===w&&S(e)};return n(F,(()=>"click"===w&&!V&&S(!1))),o((()=>{void 0!==A&&S(A)}),[A]),c(s,{ref:F,className:`nextui-tooltip-button ${v}`,css:j,role:"button",tabIndex:-1,onBlur:()=>U(!1),onClickCapture:()=>{"click"===w&&S(!I),null==M||M()},onFocus:()=>U(!0),onKeyUp:()=>U(!0),onMouseEnter:()=>U(!0),onMouseLeave:()=>U(!1),...B,children:[e,m&&!T?a(l,{...L,children:m}):null]})};m.toString=()=>".nextui-tooltip";export default r(m,{initialVisible:!1,hideArrow:!1,animated:!0,shadow:!0,rounded:!1,keepMounted:!1,isDisabled:!1,trigger:"hover",enterDelay:0,leaveDelay:0,className:"",portalClassName:"",onVisibleChange:()=>{}});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{useMemo as t,useCallback as r,useState as e,useEffect as n}from"react";import{range as i}from"../utils/numbers";export const DOTS="dots";export default({page:o,total:a,siblings:s=1,boundaries:u=1,initialPage:l=1,onChange:c})=>{const[f,m]=e(o||l);n((()=>{o&&o!==f&&m(o)}),[o]);const
|
|
1
|
+
import{useMemo as t,useCallback as r,useState as e,useEffect as n}from"react";import{range as i}from"../utils/numbers";export const DOTS="dots";export default({page:o,total:a,siblings:s=1,boundaries:u=1,initialPage:l=1,onChange:c})=>{const[f,m]=e(o||l),g=t((()=>void 0!==o),[o]);n((()=>{o&&o!==f&&m(o)}),[o,f]);const p=r((t=>{g||m(t),null==c||c(t)}),[m,c,g]),D=r((t=>{p(t<=0?1:t>a?a:t)}),[p,a]);return{range:t((()=>{if(2*s+3+2*u>=a)return i(1,a);const t=Math.max(f-s,u),r=Math.min(f+s,a-u),e=t>u+2,n=r<a-(u+1);if(!e&&n){return[...i(1,2*s+u+2),DOTS,...i(a-(u-1),a)]}if(e&&!n){const t=u+1+2*s;return[...i(1,u),DOTS,...i(a-t,a)]}return[...i(1,u),DOTS,...i(t,r),DOTS,...i(a-u+1,a)]}),[a,s,f]),active:f,setPage:D,next:()=>D(f+1),previous:()=>D(f-1),first:()=>D(1),last:()=>D(a)}};
|
package/package.json
CHANGED
|
@@ -26,6 +26,7 @@ export declare const StyledButton: import("@stitches/react/types/styled-componen
|
|
|
26
26
|
isChildLess?: undefined;
|
|
27
27
|
size?: undefined;
|
|
28
28
|
shadow?: undefined;
|
|
29
|
+
isFocusVisible?: undefined;
|
|
29
30
|
color?: undefined;
|
|
30
31
|
light?: undefined;
|
|
31
32
|
bordered?: undefined;
|
|
@@ -59,6 +60,7 @@ export declare const StyledButton: import("@stitches/react/types/styled-componen
|
|
|
59
60
|
isPressed?: undefined;
|
|
60
61
|
animated?: undefined;
|
|
61
62
|
shadow?: undefined;
|
|
63
|
+
isFocusVisible?: undefined;
|
|
62
64
|
color?: undefined;
|
|
63
65
|
light?: undefined;
|
|
64
66
|
bordered?: undefined;
|
|
@@ -68,6 +70,7 @@ export declare const StyledButton: import("@stitches/react/types/styled-componen
|
|
|
68
70
|
rounded?: undefined;
|
|
69
71
|
} | {
|
|
70
72
|
shadow: true;
|
|
73
|
+
isFocusVisible: false;
|
|
71
74
|
color: string;
|
|
72
75
|
css: {
|
|
73
76
|
normalShadow: string;
|
|
@@ -133,6 +136,7 @@ export declare const StyledButton: import("@stitches/react/types/styled-componen
|
|
|
133
136
|
isChildLess?: undefined;
|
|
134
137
|
size?: undefined;
|
|
135
138
|
shadow?: undefined;
|
|
139
|
+
isFocusVisible?: undefined;
|
|
136
140
|
bordered?: undefined;
|
|
137
141
|
ghost?: undefined;
|
|
138
142
|
isHovered?: undefined;
|
|
@@ -171,6 +175,7 @@ export declare const StyledButton: import("@stitches/react/types/styled-componen
|
|
|
171
175
|
isChildLess?: undefined;
|
|
172
176
|
size?: undefined;
|
|
173
177
|
shadow?: undefined;
|
|
178
|
+
isFocusVisible?: undefined;
|
|
174
179
|
light?: undefined;
|
|
175
180
|
ghost?: undefined;
|
|
176
181
|
isHovered?: undefined;
|
|
@@ -209,6 +214,7 @@ export declare const StyledButton: import("@stitches/react/types/styled-componen
|
|
|
209
214
|
isChildLess?: undefined;
|
|
210
215
|
size?: undefined;
|
|
211
216
|
shadow?: undefined;
|
|
217
|
+
isFocusVisible?: undefined;
|
|
212
218
|
light?: undefined;
|
|
213
219
|
ghost?: undefined;
|
|
214
220
|
isHovered?: undefined;
|
|
@@ -243,6 +249,7 @@ export declare const StyledButton: import("@stitches/react/types/styled-componen
|
|
|
243
249
|
isChildLess?: undefined;
|
|
244
250
|
size?: undefined;
|
|
245
251
|
shadow?: undefined;
|
|
252
|
+
isFocusVisible?: undefined;
|
|
246
253
|
light?: undefined;
|
|
247
254
|
bordered?: undefined;
|
|
248
255
|
flat?: undefined;
|
|
@@ -281,6 +288,7 @@ export declare const StyledButton: import("@stitches/react/types/styled-componen
|
|
|
281
288
|
isChildLess?: undefined;
|
|
282
289
|
size?: undefined;
|
|
283
290
|
shadow?: undefined;
|
|
291
|
+
isFocusVisible?: undefined;
|
|
284
292
|
light?: undefined;
|
|
285
293
|
bordered?: undefined;
|
|
286
294
|
ghost?: undefined;
|
|
@@ -315,6 +323,7 @@ export declare const StyledButton: import("@stitches/react/types/styled-componen
|
|
|
315
323
|
isChildLess?: undefined;
|
|
316
324
|
size?: undefined;
|
|
317
325
|
shadow?: undefined;
|
|
326
|
+
isFocusVisible?: undefined;
|
|
318
327
|
light?: undefined;
|
|
319
328
|
bordered?: undefined;
|
|
320
329
|
ghost?: undefined;
|
|
@@ -347,6 +356,7 @@ export declare const StyledButton: import("@stitches/react/types/styled-componen
|
|
|
347
356
|
isChildLess?: undefined;
|
|
348
357
|
size?: undefined;
|
|
349
358
|
shadow?: undefined;
|
|
359
|
+
isFocusVisible?: undefined;
|
|
350
360
|
light?: undefined;
|
|
351
361
|
bordered?: undefined;
|
|
352
362
|
ghost?: undefined;
|
|
@@ -390,6 +400,7 @@ export declare const StyledButton: import("@stitches/react/types/styled-componen
|
|
|
390
400
|
isChildLess?: undefined;
|
|
391
401
|
size?: undefined;
|
|
392
402
|
shadow?: undefined;
|
|
403
|
+
isFocusVisible?: undefined;
|
|
393
404
|
light?: undefined;
|
|
394
405
|
ghost?: undefined;
|
|
395
406
|
isHovered?: undefined;
|
|
@@ -422,6 +433,7 @@ export declare const StyledButton: import("@stitches/react/types/styled-componen
|
|
|
422
433
|
auto?: undefined;
|
|
423
434
|
isChildLess?: undefined;
|
|
424
435
|
shadow?: undefined;
|
|
436
|
+
isFocusVisible?: undefined;
|
|
425
437
|
color?: undefined;
|
|
426
438
|
light?: undefined;
|
|
427
439
|
bordered?: undefined;
|
|
@@ -448,6 +460,7 @@ export declare const StyledButton: import("@stitches/react/types/styled-componen
|
|
|
448
460
|
isPressed?: undefined;
|
|
449
461
|
isHovered?: undefined;
|
|
450
462
|
isChildLess?: undefined;
|
|
463
|
+
isFocusVisible?: undefined;
|
|
451
464
|
} | {
|
|
452
465
|
dflex: string;
|
|
453
466
|
zIndex: string;
|
|
@@ -470,6 +483,7 @@ export declare const StyledButton: import("@stitches/react/types/styled-componen
|
|
|
470
483
|
isPressed?: undefined;
|
|
471
484
|
isHovered?: undefined;
|
|
472
485
|
isChildLess?: undefined;
|
|
486
|
+
isFocusVisible?: undefined;
|
|
473
487
|
} | {
|
|
474
488
|
zIndex: string;
|
|
475
489
|
".nextui-drip-filler": {
|
|
@@ -493,6 +507,7 @@ export declare const StyledButton: import("@stitches/react/types/styled-componen
|
|
|
493
507
|
isPressed?: undefined;
|
|
494
508
|
isHovered?: undefined;
|
|
495
509
|
isChildLess?: undefined;
|
|
510
|
+
isFocusVisible?: undefined;
|
|
496
511
|
} | {
|
|
497
512
|
bordered: {
|
|
498
513
|
true: {
|
|
@@ -663,6 +678,10 @@ export declare const StyledButton: import("@stitches/react/types/styled-componen
|
|
|
663
678
|
height: string;
|
|
664
679
|
};
|
|
665
680
|
};
|
|
681
|
+
isFocusVisible: {
|
|
682
|
+
true: {};
|
|
683
|
+
false: {};
|
|
684
|
+
};
|
|
666
685
|
transition?: undefined;
|
|
667
686
|
dflex?: undefined;
|
|
668
687
|
zIndex?: undefined;
|
|
@@ -688,6 +707,7 @@ export declare const StyledButton: import("@stitches/react/types/styled-componen
|
|
|
688
707
|
isPressed?: undefined;
|
|
689
708
|
isHovered?: undefined;
|
|
690
709
|
isChildLess?: undefined;
|
|
710
|
+
isFocusVisible?: undefined;
|
|
691
711
|
};
|
|
692
712
|
$$buttonBorderRadius: string;
|
|
693
713
|
$$buttonPressedScale: number;
|
|
@@ -887,6 +907,10 @@ export declare const StyledButton: import("@stitches/react/types/styled-componen
|
|
|
887
907
|
height: string;
|
|
888
908
|
};
|
|
889
909
|
};
|
|
910
|
+
isFocusVisible: {
|
|
911
|
+
true: {};
|
|
912
|
+
false: {};
|
|
913
|
+
};
|
|
890
914
|
};
|
|
891
915
|
compoundVariants: ({
|
|
892
916
|
isPressed: true;
|
|
@@ -914,6 +938,7 @@ export declare const StyledButton: import("@stitches/react/types/styled-componen
|
|
|
914
938
|
isChildLess?: undefined;
|
|
915
939
|
size?: undefined;
|
|
916
940
|
shadow?: undefined;
|
|
941
|
+
isFocusVisible?: undefined;
|
|
917
942
|
color?: undefined;
|
|
918
943
|
light?: undefined;
|
|
919
944
|
bordered?: undefined;
|
|
@@ -947,6 +972,7 @@ export declare const StyledButton: import("@stitches/react/types/styled-componen
|
|
|
947
972
|
isPressed?: undefined;
|
|
948
973
|
animated?: undefined;
|
|
949
974
|
shadow?: undefined;
|
|
975
|
+
isFocusVisible?: undefined;
|
|
950
976
|
color?: undefined;
|
|
951
977
|
light?: undefined;
|
|
952
978
|
bordered?: undefined;
|
|
@@ -956,6 +982,7 @@ export declare const StyledButton: import("@stitches/react/types/styled-componen
|
|
|
956
982
|
rounded?: undefined;
|
|
957
983
|
} | {
|
|
958
984
|
shadow: true;
|
|
985
|
+
isFocusVisible: false;
|
|
959
986
|
color: string;
|
|
960
987
|
css: {
|
|
961
988
|
normalShadow: string;
|
|
@@ -1021,6 +1048,7 @@ export declare const StyledButton: import("@stitches/react/types/styled-componen
|
|
|
1021
1048
|
isChildLess?: undefined;
|
|
1022
1049
|
size?: undefined;
|
|
1023
1050
|
shadow?: undefined;
|
|
1051
|
+
isFocusVisible?: undefined;
|
|
1024
1052
|
bordered?: undefined;
|
|
1025
1053
|
ghost?: undefined;
|
|
1026
1054
|
isHovered?: undefined;
|
|
@@ -1059,6 +1087,7 @@ export declare const StyledButton: import("@stitches/react/types/styled-componen
|
|
|
1059
1087
|
isChildLess?: undefined;
|
|
1060
1088
|
size?: undefined;
|
|
1061
1089
|
shadow?: undefined;
|
|
1090
|
+
isFocusVisible?: undefined;
|
|
1062
1091
|
light?: undefined;
|
|
1063
1092
|
ghost?: undefined;
|
|
1064
1093
|
isHovered?: undefined;
|
|
@@ -1097,6 +1126,7 @@ export declare const StyledButton: import("@stitches/react/types/styled-componen
|
|
|
1097
1126
|
isChildLess?: undefined;
|
|
1098
1127
|
size?: undefined;
|
|
1099
1128
|
shadow?: undefined;
|
|
1129
|
+
isFocusVisible?: undefined;
|
|
1100
1130
|
light?: undefined;
|
|
1101
1131
|
ghost?: undefined;
|
|
1102
1132
|
isHovered?: undefined;
|
|
@@ -1131,6 +1161,7 @@ export declare const StyledButton: import("@stitches/react/types/styled-componen
|
|
|
1131
1161
|
isChildLess?: undefined;
|
|
1132
1162
|
size?: undefined;
|
|
1133
1163
|
shadow?: undefined;
|
|
1164
|
+
isFocusVisible?: undefined;
|
|
1134
1165
|
light?: undefined;
|
|
1135
1166
|
bordered?: undefined;
|
|
1136
1167
|
flat?: undefined;
|
|
@@ -1169,6 +1200,7 @@ export declare const StyledButton: import("@stitches/react/types/styled-componen
|
|
|
1169
1200
|
isChildLess?: undefined;
|
|
1170
1201
|
size?: undefined;
|
|
1171
1202
|
shadow?: undefined;
|
|
1203
|
+
isFocusVisible?: undefined;
|
|
1172
1204
|
light?: undefined;
|
|
1173
1205
|
bordered?: undefined;
|
|
1174
1206
|
ghost?: undefined;
|
|
@@ -1203,6 +1235,7 @@ export declare const StyledButton: import("@stitches/react/types/styled-componen
|
|
|
1203
1235
|
isChildLess?: undefined;
|
|
1204
1236
|
size?: undefined;
|
|
1205
1237
|
shadow?: undefined;
|
|
1238
|
+
isFocusVisible?: undefined;
|
|
1206
1239
|
light?: undefined;
|
|
1207
1240
|
bordered?: undefined;
|
|
1208
1241
|
ghost?: undefined;
|
|
@@ -1235,6 +1268,7 @@ export declare const StyledButton: import("@stitches/react/types/styled-componen
|
|
|
1235
1268
|
isChildLess?: undefined;
|
|
1236
1269
|
size?: undefined;
|
|
1237
1270
|
shadow?: undefined;
|
|
1271
|
+
isFocusVisible?: undefined;
|
|
1238
1272
|
light?: undefined;
|
|
1239
1273
|
bordered?: undefined;
|
|
1240
1274
|
ghost?: undefined;
|
|
@@ -1278,6 +1312,7 @@ export declare const StyledButton: import("@stitches/react/types/styled-componen
|
|
|
1278
1312
|
isChildLess?: undefined;
|
|
1279
1313
|
size?: undefined;
|
|
1280
1314
|
shadow?: undefined;
|
|
1315
|
+
isFocusVisible?: undefined;
|
|
1281
1316
|
light?: undefined;
|
|
1282
1317
|
ghost?: undefined;
|
|
1283
1318
|
isHovered?: undefined;
|
|
@@ -1310,6 +1345,7 @@ export declare const StyledButton: import("@stitches/react/types/styled-componen
|
|
|
1310
1345
|
auto?: undefined;
|
|
1311
1346
|
isChildLess?: undefined;
|
|
1312
1347
|
shadow?: undefined;
|
|
1348
|
+
isFocusVisible?: undefined;
|
|
1313
1349
|
color?: undefined;
|
|
1314
1350
|
light?: undefined;
|
|
1315
1351
|
bordered?: undefined;
|
package/types/button/index.d.ts
CHANGED
|
@@ -2,6 +2,7 @@ import Button from "./button";
|
|
|
2
2
|
export type { ButtonProps } from "./button";
|
|
3
3
|
export type { ButtonGroupProps } from "./button-group";
|
|
4
4
|
export type { ButtonIconProps } from "./button-icon";
|
|
5
|
+
export type { PressEvent, PointerType } from "@react-types/shared";
|
|
5
6
|
export { StyledButton } from "./button.styles";
|
|
6
7
|
export type { ButtonVariantsProps } from "./button.styles";
|
|
7
8
|
export { StyledButtonGroup } from "./button-group.styles";
|
|
@@ -30,6 +30,7 @@ export declare const DropdownProvider: import("react").Provider<{
|
|
|
30
30
|
}) | undefined;
|
|
31
31
|
placement?: import("..").PopoverPlacement | undefined;
|
|
32
32
|
onClose?: (() => void) | undefined;
|
|
33
|
+
scrollRef?: import("react").RefObject<HTMLElement> | undefined;
|
|
33
34
|
disableShadow?: boolean | "true" | ({
|
|
34
35
|
"@xs"?: boolean | "true" | undefined;
|
|
35
36
|
"@sm"?: boolean | "true" | undefined;
|
|
@@ -105,7 +106,6 @@ export declare const DropdownProvider: import("react").Provider<{
|
|
|
105
106
|
} & {
|
|
106
107
|
[x: string]: boolean | "true" | "false" | undefined;
|
|
107
108
|
}) | undefined;
|
|
108
|
-
scrollRef?: import("react").RefObject<HTMLElement> | undefined;
|
|
109
109
|
shouldFlip?: boolean | undefined;
|
|
110
110
|
isDismissable?: boolean | undefined;
|
|
111
111
|
triggerType?: "grid" | "dialog" | "menu" | "listbox" | "tree" | undefined;
|
|
@@ -196,6 +196,7 @@ export declare const DropdownProvider: import("react").Provider<{
|
|
|
196
196
|
}) | undefined;
|
|
197
197
|
placement?: import("..").PopoverPlacement | undefined;
|
|
198
198
|
onClose?: (() => void) | undefined;
|
|
199
|
+
scrollRef?: import("react").RefObject<HTMLElement> | undefined;
|
|
199
200
|
disableShadow?: boolean | "true" | ({
|
|
200
201
|
"@xs"?: boolean | "true" | undefined;
|
|
201
202
|
"@sm"?: boolean | "true" | undefined;
|
|
@@ -271,7 +272,6 @@ export declare const DropdownProvider: import("react").Provider<{
|
|
|
271
272
|
} & {
|
|
272
273
|
[x: string]: boolean | "true" | "false" | undefined;
|
|
273
274
|
}) | undefined;
|
|
274
|
-
scrollRef?: import("react").RefObject<HTMLElement> | undefined;
|
|
275
275
|
shouldFlip?: boolean | undefined;
|
|
276
276
|
isDismissable?: boolean | undefined;
|
|
277
277
|
triggerType?: "grid" | "dialog" | "menu" | "listbox" | "tree" | undefined;
|
|
@@ -58,6 +58,7 @@ export declare function useDropdown(props?: UseDropdownProps): {
|
|
|
58
58
|
}) | undefined;
|
|
59
59
|
placement?: import("../popover").PopoverPlacement | undefined;
|
|
60
60
|
onClose?: (() => void) | undefined;
|
|
61
|
+
scrollRef?: import("react").RefObject<HTMLElement> | undefined;
|
|
61
62
|
disableShadow?: boolean | "true" | ({
|
|
62
63
|
"@xs"?: boolean | "true" | undefined;
|
|
63
64
|
"@sm"?: boolean | "true" | undefined;
|
|
@@ -133,7 +134,6 @@ export declare function useDropdown(props?: UseDropdownProps): {
|
|
|
133
134
|
} & {
|
|
134
135
|
[x: string]: boolean | "true" | "false" | undefined;
|
|
135
136
|
}) | undefined;
|
|
136
|
-
scrollRef?: import("react").RefObject<HTMLElement> | undefined;
|
|
137
137
|
shouldFlip?: boolean | undefined;
|
|
138
138
|
isDismissable?: boolean | undefined;
|
|
139
139
|
triggerType?: "grid" | "dialog" | "menu" | "listbox" | "tree" | undefined;
|