mui-collage-fab 0.2.0 → 0.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/README.md +6 -2
- package/dist-lib/index.cjs +1 -1
- package/dist-lib/index.d.cts +36 -3
- package/dist-lib/index.d.ts +36 -3
- package/dist-lib/index.js +176 -135
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -73,8 +73,12 @@ const [open, setOpen] = useState(false);
|
|
|
73
73
|
|
|
74
74
|
| Prop | Type | Default | Description |
|
|
75
75
|
| -------------------- | ------------------------------------------ | -------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
76
|
-
| `children` | `React.ReactNode` | — | The buttons to stack. Every valid element is wrapped in a masked slot shaped by `variant`. Order matters: index 0 is the anchor, the rest fan out along `direction`.
|
|
76
|
+
| `children` | `React.ReactNode` | — | The buttons to stack. Every valid element is wrapped in a masked slot shaped by `variant`. Order matters: index 0 is the anchor, the rest fan out along `direction` or their own entry in `directions`. |
|
|
77
77
|
| `direction` | `'left' \| 'right' \| 'up' \| 'down'` | `'left'` | The axis the buttons fan out on, starting from the anchor child. `left` matches the original right-anchored behaviour. |
|
|
78
|
+
| `directions` | `('left' \| 'right' \| 'up' \| 'down')[]` | — | A direction per child, in child order, so one group can fan over several axes. Entry 0 belongs to the anchor and has no visible effect; an entry that is missing or past the end of the list falls back to `direction`. |
|
|
79
|
+
| `spread` | `'line' \| 'radial'` | `'line'` | How the children leave the anchor. `'line'` fans them along their directions; `'radial'` sends them onto a ring one pitch around the anchor, each cut by a wedge that lets it emerge from behind the anchor. |
|
|
80
|
+
| `radialStart` | `number` | `0` | Angle in degrees the first ring child sits on when `spread` is `'radial'`. |
|
|
81
|
+
| `radialStep` | `number` | — | Angle in degrees between two ring children when `spread` is `'radial'`. Defaults to `360 / (count - 1)`, which spaces them evenly around the anchor. |
|
|
78
82
|
| `size` | `'small' \| 'medium' \| 'large' \| number` | `'large'` | Diameter of every button. Named sizes resolve to small 40px, medium 48px, large 56px; numeric values are used verbatim. |
|
|
79
83
|
| `variant` | `'circular' \| 'rounded' \| 'square'` | `'circular'` | The shape of every button. `'circular'` clips each slice to a circle, `'rounded'` to a rounded square and `'square'` to a sharp-cornered square. The mask still slices the silhouette along the main axis, so the stack reads as one shape when collapsed and as separate shapes when expanded. |
|
|
80
84
|
| `gap` | `number` | `16` | Main-axis gap in pixels between two buttons when expanded. |
|
|
@@ -108,7 +112,7 @@ const [open, setOpen] = useState(false);
|
|
|
108
112
|
|
|
109
113
|
<!-- api:owner-state:start -->
|
|
110
114
|
|
|
111
|
-
`CollageFabOwnerState` carries `open`, `direction`, `trigger`, `size`, `variant`, `cornerRadius`, `gap`, `fadeWidth`, `count`, `transitionDuration` and `transitionEasing`. `CollageFabItemOwnerState` adds `index`, `isAnchor` and `geometry`.
|
|
115
|
+
`CollageFabOwnerState` carries `open`, `direction`, `directions`, `spread`, `radialStart`, `radialStep`, `trigger`, `size`, `variant`, `cornerRadius`, `gap`, `fadeWidth`, `count`, `transitionDuration` and `transitionEasing`. `CollageFabItemOwnerState` adds `index`, `isAnchor` and `geometry`.
|
|
112
116
|
<!-- api:owner-state:end -->
|
|
113
117
|
|
|
114
118
|
Theme-level defaults and overrides work through the `MuiCollageFab` component key:
|
package/dist-lib/index.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});var e=Object.create,t=Object.defineProperty,n=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,i=Object.getPrototypeOf,a=Object.prototype.hasOwnProperty,o=(e,i,o,s)=>{if(i&&typeof i==`object`||typeof i==`function`)for(var c=r(i),l=0,u=c.length,d;l<u;l++)d=c[l],!a.call(e,d)&&d!==o&&t(e,d,{get:(e=>i[e]).bind(null,d),enumerable:!(s=n(i,d))||s.enumerable});return e},s=(n,r,s)=>(s=n==null?{}:e(i(n)),o(r||!n||!n.__esModule||!a.call(n,`default`)?t(s,`default`,{value:n,enumerable:!0}):s,n));let c=require("react");c=s(c,1);let l=require("@mui/material"),u=require("@mui/material/styles"),d=require("@mui/material/utils"),f=require("@mui/utils/useSlotProps");f=s(f,1);let p=require("@mui/utils/composeClasses");p=s(p,1);let m=require("@mui/utils/generateUtilityClass");m=s(m,1);let h=require("react/jsx-runtime");var g={small:40,medium:48,large:56};function _(e){return typeof e==`number`?e:g[e]}var v={
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});var e=Object.create,t=Object.defineProperty,n=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,i=Object.getPrototypeOf,a=Object.prototype.hasOwnProperty,o=(e,i,o,s)=>{if(i&&typeof i==`object`||typeof i==`function`)for(var c=r(i),l=0,u=c.length,d;l<u;l++)d=c[l],!a.call(e,d)&&d!==o&&t(e,d,{get:(e=>i[e]).bind(null,d),enumerable:!(s=n(i,d))||s.enumerable});return e},s=(n,r,s)=>(s=n==null?{}:e(i(n)),o(r||!n||!n.__esModule||!a.call(n,`default`)?t(s,`default`,{value:n,enumerable:!0}):s,n));let c=require("react");c=s(c,1);let l=require("@mui/material"),u=require("@mui/material/styles"),d=require("@mui/material/utils"),f=require("@mui/utils/useSlotProps");f=s(f,1);let p=require("@mui/utils/composeClasses");p=s(p,1);let m=require("@mui/utils/generateUtilityClass");m=s(m,1);let h=require("react/jsx-runtime");var g={small:40,medium:48,large:56};function _(e){return typeof e==`number`?e:g[e]}var v={x:0,y:0},y={left:[-1,0],right:[1,0],up:[0,-1],down:[0,1]};function b({x:e,y:t},n){return t===0&&(n||e!==0)?`translateX(${e}px)`:e===0?`translateY(${t}px)`:`translate(${e}px, ${t}px)`}function x(e){return+e.toFixed(4)}function S(e,t){return t.directions[e]??t.direction}function C(e,t){let n=t.size+t.gap;if(t.spread===`radial`){if(e===0)return v;let r=(t.radialStart+(e-1)*t.radialStep)*Math.PI/180;return{x:x(Math.sin(r)*n),y:x(-Math.cos(r)*n)}}let r=S(e,t),[i,a]=y[r],o=0;for(let n=0;n<e;n+=1)S(n,t)===r&&(o+=1);let s=(o+(r===S(0,t)?0:1))*n;return{x:i*s,y:a*s}}function w(e,t){let n=Math.min(...e,0),r=Math.max(...e,0),i=n<0&&r>0?`center`:n<0?`end`:`start`;return[i===`center`?2*Math.max(-n,r)+t:r-n+t,i]}function T(e){let{count:t,size:n}=e;if(e.spread===`radial`)return{extent:{width:n,height:n},align:{x:`center`,y:`center`}};let r=Array.from({length:t},(t,n)=>C(n,e)),i=r.map(e=>e.x),a=r.map(e=>e.y),[o,s]=w(i,n),[c,l]=w(a,n);return{extent:{width:o,height:c},align:{x:s,y:l}}}function E(e,t){if(t.spread===`radial`)return D(e,t);let{count:n,size:r,gap:i,fadeWidth:a,open:o}=t,s=(n-1)*(r+i)+r+a,[c,l]=y[S(e,t)],u=c!==0,d=(u?c:l)<0,f=o?C(e,t):v,p=e===0?s:(n-e)*(r/n),m=e===0?-a/2:r/n*e,h=(d?p:m)-s-a/2,g=u?h-f.x:-f.x,_=u?-f.y:h-f.y,x=d?`#000 0px, #000 ${s}px, transparent ${s+a}px, transparent ${2*s}px`:`transparent 0px, transparent ${s}px, #000 ${s+a}px, #000 ${2*s}px`;return{translate:b(f,u),maskImage:n>1?`linear-gradient(${u?`to right`:`to bottom`}, ${x})`:`none`,maskSize:u?`${2*s}px 100%`:`100% ${2*s}px`,maskPosition:`${g}px ${_}px`}}function D(e,t){let{count:n,size:r,gap:i,fadeWidth:a,open:o}=t,s=t.radialStep,c=o?C(e,t):v,l=n>1?r+i:0,u=r+2*l,d=a?a/(r/2)*180/Math.PI:0,f=t.radialStart+(e-1)*s-s/2-d/2,p=x(s+d);return{translate:b(c,!1),maskImage:n>1&&e>0?`conic-gradient(from ${x(f)}deg, #0000 0deg, #000 ${x(d)}deg, #000 ${x(e===n-1?s:s+d)}deg, transparent ${p}deg)`:`none`,maskSize:`${u}px ${u}px`,maskPosition:`${-c.x-l}px ${-c.y-l}px`}}var O={direction:`left`,size:`large`,variant:`circular`,gap:16,fadeWidth:12,spread:`line`,radialStart:0,trigger:`hover`,defaultOpen:!1,disableClickAway:!1,transitionDuration:400,transitionEasing:`cubic-bezier(0.4, 0, 0.2, 1)`},ee={circular:`50%`,rounded:`25%`,square:0},k=`a[href],button:not([disabled]),input:not([disabled]),select:not([disabled]),textarea:not([disabled]),[tabindex]:not([tabindex="-1"])`;function A(e,t){return`${e}ms ${t}`}function j(e){return(0,m.default)(`MuiCollageFab`,e)}var M=(e,t)=>(0,p.default)({root:[`root`,e?`expanded`:`collapsed`],item:[`item`]},j,t),N=(0,u.styled)(`div`,{name:`MuiCollageFab`,slot:`root`,overridesResolver:(e,t)=>t.root})(({ownerState:e})=>{let{open:t,size:n,spread:r,gap:i,count:a,transitionDuration:o,transitionEasing:s}=e,{extent:c}=T(e),l=A(o,s),u=t&&r===`radial`&&a>1?n+i:0;return{position:`relative`,...u>0&&{"&::after":{content:`""`,position:`absolute`,inset:-u,borderRadius:`50%`,zIndex:-1}},width:t?c.width:n,height:t?c.height:n,transition:`width ${l}, height ${l}`,filter:`drop-shadow(0px 6px 12px rgba(0,0,0,0.25))`,cursor:t?`default`:`pointer`,WebkitTapHighlightColor:`transparent`}}),P=(0,u.styled)(`div`,{name:`MuiCollageFab`,slot:`item`,overridesResolver:(e,t)=>t.item})(({ownerState:e})=>{let{size:t,index:n,geometry:r,cornerRadius:i,transitionDuration:a,transitionEasing:o}=e,{align:s}=T(e),c={...s.x===`end`?{right:0}:s.x===`center`?{left:`50%`,marginLeft:-t/2}:{left:0},...s.y===`end`?{bottom:0}:s.y===`center`?{top:`50%`,marginTop:-t/2}:{top:0}},l=A(a,o);return{position:`absolute`,...c,width:t,height:t,borderRadius:i,overflow:`hidden`,display:`flex`,alignItems:`center`,justifyContent:`center`,zIndex:e.spread===`radial`?e.count-n:n,transform:r.translate,WebkitMaskImage:r.maskImage,maskImage:r.maskImage,WebkitMaskSize:r.maskSize,maskSize:r.maskSize,WebkitMaskPosition:r.maskPosition,maskPosition:r.maskPosition,WebkitMaskRepeat:`no-repeat`,maskRepeat:`no-repeat`,transition:`transform ${l}, -webkit-mask-position ${l}, mask-position ${l}`,"& > *":{boxShadow:`none !important`,borderRadius:`inherit !important`,width:`100%`,height:`100%`,margin:0}}});function F(e){let{index:t,ownerState:n,geometry:r,className:i,component:a,inert:o,itemRefs:s,slotProps:l,children:u}=e,p=c.useMemo(()=>({...n,index:t,isAnchor:t===0,geometry:r}),[n,t,r]),m=c.useRef(null),g=c.useCallback(e=>{s.current[t]=e},[s,t]),_=(0,d.useForkRef)(g,m);c.useEffect(()=>{let e=m.current;e&&`inert`in HTMLElement.prototype&&(e.inert=o)},[o]);let v=(0,f.default)({elementType:a,externalSlotProps:l,ownerState:p,additionalProps:{ref:_,className:i,"aria-hidden":o||void 0,children:u}});return(0,h.jsx)(a,{...v})}var I=c.forwardRef(function(e,t){let{children:n,direction:r=O.direction,directions:i,spread:a=O.spread,radialStart:o=O.radialStart,radialStep:s,size:p=O.size,variant:m=O.variant,gap:g=O.gap,fadeWidth:v=O.fadeWidth,trigger:y=O.trigger,open:b,defaultOpen:x=O.defaultOpen,onOpen:S,onClose:C,disableClickAway:w=O.disableClickAway,transitionDuration:T=O.transitionDuration,transitionEasing:D=O.transitionEasing,classes:A,slots:j,slotProps:I,className:L,...R}=(0,u.useThemeProps)({props:e,name:`MuiCollageFab`}),[z,B]=(0,d.useControlled)({controlled:b,default:x,name:`CollageFab`,state:`open`}),V=c.useMemo(()=>c.Children.toArray(n).filter(e=>c.isValidElement(e)),[n]),H=V.length,U={open:z,direction:r,directions:c.useMemo(()=>V.map((e,t)=>i?.[t]??r),[V,i,r]),spread:a,radialStart:o,radialStep:s??360/Math.max(H-1,1),trigger:y,size:_(p),variant:m,cornerRadius:ee[m],gap:g,fadeWidth:v,count:H,transitionDuration:T,transitionEasing:D},W=M(z,A),G=c.useRef(null),K=c.useRef([]),q=c.useRef(!1),J=c.useRef(`mouse`),Y=c.useRef(!1),X=(0,d.useForkRef)(G,t),Z=c.useCallback((e,t)=>{e!==z&&(B(e),e?S?.(t):C?.(t))},[z,B,S,C]),te=e=>{y===`hover`&&e.pointerType===`mouse`&&Z(!0,e)},ne=e=>{y===`hover`&&e.pointerType===`mouse`&&Z(!1,e)},re=e=>{y!==`manual`&&(J.current=e.pointerType,q.current=!1,e.pointerType===`mouse`||z||(q.current=!0,Z(!0,e)))},ie=e=>{q.current&&(q.current=!1,e.stopPropagation(),e.preventDefault())},ae=e=>{y!==`manual`&&(y===`click`?Z(!z,e):z&&J.current!==`mouse`&&Z(!1,e))},oe=e=>{if(y!==`manual`){if(z){if(e.key!==`Escape`)return;e.stopPropagation(),Z(!1,e),G.current?.focus()}else(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),Y.current=!0,Z(!0,e))}},se=e=>{Z(!1,e)},Q=j?.root??N,ce=j?.item??P,le=(0,f.default)({elementType:Q,externalForwardedProps:R,externalSlotProps:I?.root,ownerState:U,additionalProps:{ref:X,role:`group`,tabIndex:!z&&y!==`manual`?0:-1,onPointerEnter:te,onPointerLeave:ne,onPointerDown:re,onClick:ae,onClickCapture:ie,onKeyDown:oe},className:[W.root,L]});if(c.useEffect(()=>{if(!z||!Y.current)return;Y.current=!1;let e=K.current[0];e&&(e.querySelector(k)??e).focus()},[z]),H===0)return null;let $=(0,h.jsx)(Q,{...le,children:V.map((e,t)=>(0,h.jsx)(F,{index:t,ownerState:U,geometry:E(t,U),className:W.item,component:ce,inert:!z&&y!==`manual`,itemRefs:K,slotProps:I?.item,children:e},t))});return w||y===`manual`?$:(0,h.jsx)(l.ClickAwayListener,{onClickAway:se,children:$})});exports.CollageFab=I;
|
package/dist-lib/index.d.cts
CHANGED
|
@@ -20,6 +20,10 @@ type CollageFabSize = 'small' | 'medium' | 'large' | number;
|
|
|
20
20
|
* square.
|
|
21
21
|
*/
|
|
22
22
|
type CollageFabVariant = 'circular' | 'rounded' | 'square';
|
|
23
|
+
/**
|
|
24
|
+
* How the children leave the anchor: along a line, or onto a ring around it.
|
|
25
|
+
*/
|
|
26
|
+
type CollageFabSpread = 'line' | 'radial';
|
|
23
27
|
/**
|
|
24
28
|
* Class names the component applies, and the accepted keys for `classes`.
|
|
25
29
|
*/
|
|
@@ -53,8 +57,16 @@ interface CollageFabItemSlotPropsOverrides {
|
|
|
53
57
|
interface CollageFabOwnerState {
|
|
54
58
|
/** Whether the group is currently expanded. */
|
|
55
59
|
open: boolean;
|
|
56
|
-
/** The resolved fan-out direction. */
|
|
60
|
+
/** The resolved fan-out direction used by every child without a `directions` entry. */
|
|
57
61
|
direction: CollageFabDirection;
|
|
62
|
+
/** The resolved direction of each child, in child order. */
|
|
63
|
+
directions: CollageFabDirection[];
|
|
64
|
+
/** How the children leave the anchor: along a line, or onto a ring. */
|
|
65
|
+
spread: CollageFabSpread;
|
|
66
|
+
/** The angle in degrees the first wedge is centred on when `spread` is `'radial'`. */
|
|
67
|
+
radialStart: number;
|
|
68
|
+
/** The angle in degrees between two wedges when `spread` is `'radial'`. */
|
|
69
|
+
radialStep: number;
|
|
58
70
|
/** The resolved pointer trigger mode. */
|
|
59
71
|
trigger: CollageFabTrigger;
|
|
60
72
|
/** The button diameter in pixels, after resolving the named size. */
|
|
@@ -124,7 +136,7 @@ interface CollageFabProps extends Omit<React.HTMLAttributes<HTMLDivElement>, 'ch
|
|
|
124
136
|
/**
|
|
125
137
|
* The buttons to stack. Every valid element is wrapped in a masked slot shaped
|
|
126
138
|
* by `variant`. Order matters: index 0 is the anchor, the rest fan out along
|
|
127
|
-
* `direction`.
|
|
139
|
+
* `direction` or their own entry in `directions`.
|
|
128
140
|
*/
|
|
129
141
|
children?: React.ReactNode;
|
|
130
142
|
/**
|
|
@@ -132,6 +144,27 @@ interface CollageFabProps extends Omit<React.HTMLAttributes<HTMLDivElement>, 'ch
|
|
|
132
144
|
* matches the original right-anchored behaviour.
|
|
133
145
|
*/
|
|
134
146
|
direction?: CollageFabDirection;
|
|
147
|
+
/**
|
|
148
|
+
* A direction per child, in child order, so one group can fan over several axes.
|
|
149
|
+
* Entry 0 belongs to the anchor and has no visible effect; an entry that is
|
|
150
|
+
* missing or past the end of the list falls back to `direction`.
|
|
151
|
+
*/
|
|
152
|
+
directions?: CollageFabDirection[];
|
|
153
|
+
/**
|
|
154
|
+
* How the children leave the anchor. `'line'` fans them along their directions;
|
|
155
|
+
* `'radial'` sends them onto a ring one pitch around the anchor, each cut by a wedge
|
|
156
|
+
* that lets it emerge from behind the anchor.
|
|
157
|
+
*/
|
|
158
|
+
spread?: CollageFabSpread;
|
|
159
|
+
/**
|
|
160
|
+
* Angle in degrees the first ring child sits on when `spread` is `'radial'`.
|
|
161
|
+
*/
|
|
162
|
+
radialStart?: number;
|
|
163
|
+
/**
|
|
164
|
+
* Angle in degrees between two ring children when `spread` is `'radial'`.
|
|
165
|
+
* Defaults to `360 / (count - 1)`, which spaces them evenly around the anchor.
|
|
166
|
+
*/
|
|
167
|
+
radialStep?: number;
|
|
135
168
|
/**
|
|
136
169
|
* Diameter of every button. Named sizes resolve to small 40px, medium 48px,
|
|
137
170
|
* large 56px; numeric values are used verbatim.
|
|
@@ -213,4 +246,4 @@ interface CollageFabProps extends Omit<React.HTMLAttributes<HTMLDivElement>, 'ch
|
|
|
213
246
|
declare const CollageFab: React.ForwardRefExoticComponent<CollageFabProps & React.RefAttributes<HTMLDivElement>>;
|
|
214
247
|
|
|
215
248
|
export { CollageFab };
|
|
216
|
-
export type { CollageFabClassKey, CollageFabClasses, CollageFabDirection, CollageFabItemGeometry, CollageFabItemOwnerState, CollageFabItemSlotPropsOverrides, CollageFabOwnerState, CollageFabProps, CollageFabRootSlotPropsOverrides, CollageFabSize, CollageFabSlots, CollageFabSlotsAndSlotProps, CollageFabTrigger, CollageFabVariant };
|
|
249
|
+
export type { CollageFabClassKey, CollageFabClasses, CollageFabDirection, CollageFabItemGeometry, CollageFabItemOwnerState, CollageFabItemSlotPropsOverrides, CollageFabOwnerState, CollageFabProps, CollageFabRootSlotPropsOverrides, CollageFabSize, CollageFabSlots, CollageFabSlotsAndSlotProps, CollageFabSpread, CollageFabTrigger, CollageFabVariant };
|
package/dist-lib/index.d.ts
CHANGED
|
@@ -20,6 +20,10 @@ type CollageFabSize = 'small' | 'medium' | 'large' | number;
|
|
|
20
20
|
* square.
|
|
21
21
|
*/
|
|
22
22
|
type CollageFabVariant = 'circular' | 'rounded' | 'square';
|
|
23
|
+
/**
|
|
24
|
+
* How the children leave the anchor: along a line, or onto a ring around it.
|
|
25
|
+
*/
|
|
26
|
+
type CollageFabSpread = 'line' | 'radial';
|
|
23
27
|
/**
|
|
24
28
|
* Class names the component applies, and the accepted keys for `classes`.
|
|
25
29
|
*/
|
|
@@ -53,8 +57,16 @@ interface CollageFabItemSlotPropsOverrides {
|
|
|
53
57
|
interface CollageFabOwnerState {
|
|
54
58
|
/** Whether the group is currently expanded. */
|
|
55
59
|
open: boolean;
|
|
56
|
-
/** The resolved fan-out direction. */
|
|
60
|
+
/** The resolved fan-out direction used by every child without a `directions` entry. */
|
|
57
61
|
direction: CollageFabDirection;
|
|
62
|
+
/** The resolved direction of each child, in child order. */
|
|
63
|
+
directions: CollageFabDirection[];
|
|
64
|
+
/** How the children leave the anchor: along a line, or onto a ring. */
|
|
65
|
+
spread: CollageFabSpread;
|
|
66
|
+
/** The angle in degrees the first wedge is centred on when `spread` is `'radial'`. */
|
|
67
|
+
radialStart: number;
|
|
68
|
+
/** The angle in degrees between two wedges when `spread` is `'radial'`. */
|
|
69
|
+
radialStep: number;
|
|
58
70
|
/** The resolved pointer trigger mode. */
|
|
59
71
|
trigger: CollageFabTrigger;
|
|
60
72
|
/** The button diameter in pixels, after resolving the named size. */
|
|
@@ -124,7 +136,7 @@ interface CollageFabProps extends Omit<React.HTMLAttributes<HTMLDivElement>, 'ch
|
|
|
124
136
|
/**
|
|
125
137
|
* The buttons to stack. Every valid element is wrapped in a masked slot shaped
|
|
126
138
|
* by `variant`. Order matters: index 0 is the anchor, the rest fan out along
|
|
127
|
-
* `direction`.
|
|
139
|
+
* `direction` or their own entry in `directions`.
|
|
128
140
|
*/
|
|
129
141
|
children?: React.ReactNode;
|
|
130
142
|
/**
|
|
@@ -132,6 +144,27 @@ interface CollageFabProps extends Omit<React.HTMLAttributes<HTMLDivElement>, 'ch
|
|
|
132
144
|
* matches the original right-anchored behaviour.
|
|
133
145
|
*/
|
|
134
146
|
direction?: CollageFabDirection;
|
|
147
|
+
/**
|
|
148
|
+
* A direction per child, in child order, so one group can fan over several axes.
|
|
149
|
+
* Entry 0 belongs to the anchor and has no visible effect; an entry that is
|
|
150
|
+
* missing or past the end of the list falls back to `direction`.
|
|
151
|
+
*/
|
|
152
|
+
directions?: CollageFabDirection[];
|
|
153
|
+
/**
|
|
154
|
+
* How the children leave the anchor. `'line'` fans them along their directions;
|
|
155
|
+
* `'radial'` sends them onto a ring one pitch around the anchor, each cut by a wedge
|
|
156
|
+
* that lets it emerge from behind the anchor.
|
|
157
|
+
*/
|
|
158
|
+
spread?: CollageFabSpread;
|
|
159
|
+
/**
|
|
160
|
+
* Angle in degrees the first ring child sits on when `spread` is `'radial'`.
|
|
161
|
+
*/
|
|
162
|
+
radialStart?: number;
|
|
163
|
+
/**
|
|
164
|
+
* Angle in degrees between two ring children when `spread` is `'radial'`.
|
|
165
|
+
* Defaults to `360 / (count - 1)`, which spaces them evenly around the anchor.
|
|
166
|
+
*/
|
|
167
|
+
radialStep?: number;
|
|
135
168
|
/**
|
|
136
169
|
* Diameter of every button. Named sizes resolve to small 40px, medium 48px,
|
|
137
170
|
* large 56px; numeric values are used verbatim.
|
|
@@ -213,4 +246,4 @@ interface CollageFabProps extends Omit<React.HTMLAttributes<HTMLDivElement>, 'ch
|
|
|
213
246
|
declare const CollageFab: React.ForwardRefExoticComponent<CollageFabProps & React.RefAttributes<HTMLDivElement>>;
|
|
214
247
|
|
|
215
248
|
export { CollageFab };
|
|
216
|
-
export type { CollageFabClassKey, CollageFabClasses, CollageFabDirection, CollageFabItemGeometry, CollageFabItemOwnerState, CollageFabItemSlotPropsOverrides, CollageFabOwnerState, CollageFabProps, CollageFabRootSlotPropsOverrides, CollageFabSize, CollageFabSlots, CollageFabSlotsAndSlotProps, CollageFabTrigger, CollageFabVariant };
|
|
249
|
+
export type { CollageFabClassKey, CollageFabClasses, CollageFabDirection, CollageFabItemGeometry, CollageFabItemOwnerState, CollageFabItemSlotPropsOverrides, CollageFabOwnerState, CollageFabProps, CollageFabRootSlotPropsOverrides, CollageFabSize, CollageFabSlots, CollageFabSlotsAndSlotProps, CollageFabSpread, CollageFabTrigger, CollageFabVariant };
|
package/dist-lib/index.js
CHANGED
|
@@ -16,120 +16,153 @@ function d(e) {
|
|
|
16
16
|
return typeof e == "number" ? e : u[e];
|
|
17
17
|
}
|
|
18
18
|
var f = {
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
right:
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
},
|
|
27
|
-
up: {
|
|
28
|
-
x: 0,
|
|
29
|
-
y: -1
|
|
30
|
-
},
|
|
31
|
-
down: {
|
|
32
|
-
x: 0,
|
|
33
|
-
y: 1
|
|
34
|
-
}
|
|
19
|
+
x: 0,
|
|
20
|
+
y: 0
|
|
21
|
+
}, p = {
|
|
22
|
+
left: [-1, 0],
|
|
23
|
+
right: [1, 0],
|
|
24
|
+
up: [0, -1],
|
|
25
|
+
down: [0, 1]
|
|
35
26
|
};
|
|
36
|
-
function
|
|
37
|
-
return
|
|
27
|
+
function m({ x: e, y: t }, n) {
|
|
28
|
+
return t === 0 && (n || e !== 0) ? `translateX(${e}px)` : e === 0 ? `translateY(${t}px)` : `translate(${e}px, ${t}px)`;
|
|
29
|
+
}
|
|
30
|
+
function h(e) {
|
|
31
|
+
return +e.toFixed(4);
|
|
38
32
|
}
|
|
39
|
-
function
|
|
40
|
-
|
|
33
|
+
function g(e, t) {
|
|
34
|
+
return t.directions[e] ?? t.direction;
|
|
35
|
+
}
|
|
36
|
+
function _(e, t) {
|
|
37
|
+
let n = t.size + t.gap;
|
|
38
|
+
if (t.spread === "radial") {
|
|
39
|
+
if (e === 0) return f;
|
|
40
|
+
let r = (t.radialStart + (e - 1) * t.radialStep) * Math.PI / 180;
|
|
41
|
+
return {
|
|
42
|
+
x: h(Math.sin(r) * n),
|
|
43
|
+
y: h(-Math.cos(r) * n)
|
|
44
|
+
};
|
|
45
|
+
}
|
|
46
|
+
let r = g(e, t), [i, a] = p[r], o = 0;
|
|
47
|
+
for (let n = 0; n < e; n += 1) g(n, t) === r && (o += 1);
|
|
48
|
+
let s = (o + (r === g(0, t) ? 0 : 1)) * n;
|
|
41
49
|
return {
|
|
42
|
-
x:
|
|
43
|
-
y:
|
|
50
|
+
x: i * s,
|
|
51
|
+
y: a * s
|
|
44
52
|
};
|
|
45
53
|
}
|
|
46
|
-
function
|
|
47
|
-
|
|
54
|
+
function v(e, t) {
|
|
55
|
+
let n = Math.min(...e, 0), r = Math.max(...e, 0), i = n < 0 && r > 0 ? "center" : n < 0 ? "end" : "start";
|
|
56
|
+
return [i === "center" ? 2 * Math.max(-n, r) + t : r - n + t, i];
|
|
48
57
|
}
|
|
49
|
-
function
|
|
50
|
-
let { count: t, size: n } = e
|
|
58
|
+
function y(e) {
|
|
59
|
+
let { count: t, size: n } = e;
|
|
60
|
+
if (e.spread === "radial") return {
|
|
61
|
+
extent: {
|
|
62
|
+
width: n,
|
|
63
|
+
height: n
|
|
64
|
+
},
|
|
65
|
+
align: {
|
|
66
|
+
x: "center",
|
|
67
|
+
y: "center"
|
|
68
|
+
}
|
|
69
|
+
};
|
|
70
|
+
let r = Array.from({ length: t }, (t, n) => _(n, e)), i = r.map((e) => e.x), a = r.map((e) => e.y), [o, s] = v(i, n), [c, l] = v(a, n);
|
|
51
71
|
return {
|
|
52
72
|
extent: {
|
|
53
|
-
width:
|
|
54
|
-
height:
|
|
73
|
+
width: o,
|
|
74
|
+
height: c
|
|
55
75
|
},
|
|
56
76
|
align: {
|
|
57
|
-
x:
|
|
58
|
-
y:
|
|
77
|
+
x: s,
|
|
78
|
+
y: l
|
|
59
79
|
}
|
|
60
80
|
};
|
|
61
81
|
}
|
|
62
|
-
function
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
y: b.y - g.y
|
|
75
|
-
}, S = h ? `#000 0px, #000 ${l}px, transparent ${l + a}px, transparent ${2 * l}px` : `transparent 0px, transparent ${l}px, #000 ${l + a}px, #000 ${2 * l}px`;
|
|
82
|
+
function b(e, t) {
|
|
83
|
+
if (t.spread === "radial") return x(e, t);
|
|
84
|
+
let { count: n, size: r, gap: i, fadeWidth: a, open: o } = t, s = (n - 1) * (r + i) + r + a, [c, l] = p[g(e, t)], u = c !== 0, d = (u ? c : l) < 0, h = o ? _(e, t) : f, v = e === 0 ? s : (n - e) * (r / n), y = e === 0 ? -a / 2 : r / n * e, b = (d ? v : y) - s - a / 2, S = u ? b - h.x : -h.x, C = u ? -h.y : b - h.y, w = d ? `#000 0px, #000 ${s}px, transparent ${s + a}px, transparent ${2 * s}px` : `transparent 0px, transparent ${s}px, #000 ${s + a}px, #000 ${2 * s}px`;
|
|
85
|
+
return {
|
|
86
|
+
translate: m(h, u),
|
|
87
|
+
maskImage: n > 1 ? `linear-gradient(${u ? "to right" : "to bottom"}, ${w})` : "none",
|
|
88
|
+
maskSize: u ? `${2 * s}px 100%` : `100% ${2 * s}px`,
|
|
89
|
+
maskPosition: `${S}px ${C}px`
|
|
90
|
+
};
|
|
91
|
+
}
|
|
92
|
+
function x(e, t) {
|
|
93
|
+
let { count: n, size: r, gap: i, fadeWidth: a, open: o } = t, s = t.radialStep, c = o ? _(e, t) : f, l = n > 1 ? r + i : 0, u = r + 2 * l, d = a ? a / (r / 2) * 180 / Math.PI : 0, p = t.radialStart + (e - 1) * s - s / 2 - d / 2, g = h(s + d);
|
|
76
94
|
return {
|
|
77
|
-
translate:
|
|
78
|
-
maskImage: n > 1 ? `
|
|
79
|
-
maskSize:
|
|
80
|
-
maskPosition: `${
|
|
95
|
+
translate: m(c, !1),
|
|
96
|
+
maskImage: n > 1 && e > 0 ? `conic-gradient(from ${h(p)}deg, #0000 0deg, #000 ${h(d)}deg, #000 ${h(e === n - 1 ? s : s + d)}deg, transparent ${g}deg)` : "none",
|
|
97
|
+
maskSize: `${u}px ${u}px`,
|
|
98
|
+
maskPosition: `${-c.x - l}px ${-c.y - l}px`
|
|
81
99
|
};
|
|
82
100
|
}
|
|
83
101
|
// src/components/collageFabDefaults.ts
|
|
84
|
-
var
|
|
102
|
+
var S = {
|
|
85
103
|
direction: "left",
|
|
86
104
|
size: "large",
|
|
87
105
|
variant: "circular",
|
|
88
106
|
gap: 16,
|
|
89
107
|
fadeWidth: 12,
|
|
108
|
+
spread: "line",
|
|
109
|
+
radialStart: 0,
|
|
90
110
|
trigger: "hover",
|
|
91
111
|
defaultOpen: !1,
|
|
92
112
|
disableClickAway: !1,
|
|
93
113
|
transitionDuration: 400,
|
|
94
114
|
transitionEasing: "cubic-bezier(0.4, 0, 0.2, 1)"
|
|
95
|
-
},
|
|
115
|
+
}, C = {
|
|
96
116
|
circular: "50%",
|
|
97
117
|
rounded: "25%",
|
|
98
118
|
square: 0
|
|
99
|
-
},
|
|
100
|
-
function
|
|
119
|
+
}, w = "a[href],button:not([disabled]),input:not([disabled]),select:not([disabled]),textarea:not([disabled]),[tabindex]:not([tabindex=\"-1\"])";
|
|
120
|
+
function T(e, t) {
|
|
101
121
|
return `${e}ms ${t}`;
|
|
102
122
|
}
|
|
103
|
-
function
|
|
123
|
+
function E(e) {
|
|
104
124
|
return c("MuiCollageFab", e);
|
|
105
125
|
}
|
|
106
|
-
var
|
|
126
|
+
var D = (e, t) => s({
|
|
107
127
|
root: ["root", e ? "expanded" : "collapsed"],
|
|
108
128
|
item: ["item"]
|
|
109
|
-
},
|
|
129
|
+
}, E, t), O = n("div", {
|
|
110
130
|
name: "MuiCollageFab",
|
|
111
131
|
slot: "root",
|
|
112
132
|
overridesResolver: (e, t) => t.root
|
|
113
133
|
})(({ ownerState: e }) => {
|
|
114
|
-
let { open: t, size: n,
|
|
134
|
+
let { open: t, size: n, spread: r, gap: i, count: a, transitionDuration: o, transitionEasing: s } = e, { extent: c } = y(e), l = T(o, s), u = t && r === "radial" && a > 1 ? n + i : 0;
|
|
115
135
|
return {
|
|
116
136
|
position: "relative",
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
137
|
+
...u > 0 && { "&::after": {
|
|
138
|
+
content: "\"\"",
|
|
139
|
+
position: "absolute",
|
|
140
|
+
inset: -u,
|
|
141
|
+
borderRadius: "50%",
|
|
142
|
+
zIndex: -1
|
|
143
|
+
} },
|
|
144
|
+
width: t ? c.width : n,
|
|
145
|
+
height: t ? c.height : n,
|
|
146
|
+
transition: `width ${l}, height ${l}`,
|
|
120
147
|
filter: "drop-shadow(0px 6px 12px rgba(0,0,0,0.25))",
|
|
121
148
|
cursor: t ? "default" : "pointer",
|
|
122
149
|
WebkitTapHighlightColor: "transparent"
|
|
123
150
|
};
|
|
124
|
-
}),
|
|
151
|
+
}), k = n("div", {
|
|
125
152
|
name: "MuiCollageFab",
|
|
126
153
|
slot: "item",
|
|
127
154
|
overridesResolver: (e, t) => t.item
|
|
128
155
|
})(({ ownerState: e }) => {
|
|
129
|
-
let { size: t, index: n, geometry: r, cornerRadius: i, transitionDuration: a, transitionEasing: o } = e, { align: s } =
|
|
130
|
-
...s.x === "end" ? { right: 0 } :
|
|
131
|
-
|
|
132
|
-
|
|
156
|
+
let { size: t, index: n, geometry: r, cornerRadius: i, transitionDuration: a, transitionEasing: o } = e, { align: s } = y(e), c = {
|
|
157
|
+
...s.x === "end" ? { right: 0 } : s.x === "center" ? {
|
|
158
|
+
left: "50%",
|
|
159
|
+
marginLeft: -t / 2
|
|
160
|
+
} : { left: 0 },
|
|
161
|
+
...s.y === "end" ? { bottom: 0 } : s.y === "center" ? {
|
|
162
|
+
top: "50%",
|
|
163
|
+
marginTop: -t / 2
|
|
164
|
+
} : { top: 0 }
|
|
165
|
+
}, l = T(a, o);
|
|
133
166
|
return {
|
|
134
167
|
position: "absolute",
|
|
135
168
|
...c,
|
|
@@ -140,7 +173,7 @@ var C = (e, t) => s({
|
|
|
140
173
|
display: "flex",
|
|
141
174
|
alignItems: "center",
|
|
142
175
|
justifyContent: "center",
|
|
143
|
-
zIndex: n,
|
|
176
|
+
zIndex: e.spread === "radial" ? e.count - n : n,
|
|
144
177
|
transform: r.translate,
|
|
145
178
|
WebkitMaskImage: r.maskImage,
|
|
146
179
|
maskImage: r.maskImage,
|
|
@@ -160,7 +193,7 @@ var C = (e, t) => s({
|
|
|
160
193
|
}
|
|
161
194
|
};
|
|
162
195
|
});
|
|
163
|
-
function
|
|
196
|
+
function A(t) {
|
|
164
197
|
let { index: n, ownerState: r, geometry: i, className: s, component: c, inert: u, itemRefs: d, slotProps: f, children: p } = t, m = e.useMemo(() => ({
|
|
165
198
|
...r,
|
|
166
199
|
index: n,
|
|
@@ -190,94 +223,102 @@ function E(t) {
|
|
|
190
223
|
});
|
|
191
224
|
return /* @__PURE__ */ l(c, { ...v });
|
|
192
225
|
}
|
|
193
|
-
var
|
|
194
|
-
let { children: c, direction: u =
|
|
226
|
+
var j = e.forwardRef(function(n, s) {
|
|
227
|
+
let { children: c, direction: u = S.direction, directions: f, spread: p = S.spread, radialStart: m = S.radialStart, radialStep: h, size: g = S.size, variant: _ = S.variant, gap: v = S.gap, fadeWidth: y = S.fadeWidth, trigger: x = S.trigger, open: T, defaultOpen: E = S.defaultOpen, onOpen: j, onClose: M, disableClickAway: ee = S.disableClickAway, transitionDuration: te = S.transitionDuration, transitionEasing: ne = S.transitionEasing, classes: N, slots: P, slotProps: F, className: I, ...L } = r({
|
|
195
228
|
props: n,
|
|
196
229
|
name: "MuiCollageFab"
|
|
197
|
-
}), [
|
|
198
|
-
controlled:
|
|
199
|
-
default:
|
|
230
|
+
}), [R, z] = i({
|
|
231
|
+
controlled: T,
|
|
232
|
+
default: E,
|
|
200
233
|
name: "CollageFab",
|
|
201
234
|
state: "open"
|
|
202
|
-
}),
|
|
203
|
-
open:
|
|
235
|
+
}), B = e.useMemo(() => e.Children.toArray(c).filter((t) => e.isValidElement(t)), [c]), V = B.length, H = {
|
|
236
|
+
open: R,
|
|
204
237
|
direction: u,
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
238
|
+
directions: e.useMemo(() => B.map((e, t) => f?.[t] ?? u), [
|
|
239
|
+
B,
|
|
240
|
+
f,
|
|
241
|
+
u
|
|
242
|
+
]),
|
|
243
|
+
spread: p,
|
|
244
|
+
radialStart: m,
|
|
245
|
+
radialStep: h ?? 360 / Math.max(V - 1, 1),
|
|
246
|
+
trigger: x,
|
|
247
|
+
size: d(g),
|
|
248
|
+
variant: _,
|
|
249
|
+
cornerRadius: C[_],
|
|
250
|
+
gap: v,
|
|
251
|
+
fadeWidth: y,
|
|
252
|
+
count: V,
|
|
253
|
+
transitionDuration: te,
|
|
254
|
+
transitionEasing: ne
|
|
255
|
+
}, U = D(R, N), W = e.useRef(null), G = e.useRef([]), K = e.useRef(!1), q = e.useRef("mouse"), J = e.useRef(!1), Y = a(W, s), X = e.useCallback((e, t) => {
|
|
256
|
+
e !== R && (z(e), e ? j?.(t) : M?.(t));
|
|
216
257
|
}, [
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
]),
|
|
222
|
-
|
|
223
|
-
},
|
|
224
|
-
|
|
225
|
-
},
|
|
226
|
-
|
|
227
|
-
},
|
|
228
|
-
|
|
229
|
-
},
|
|
230
|
-
|
|
231
|
-
},
|
|
232
|
-
if (
|
|
233
|
-
if (
|
|
258
|
+
R,
|
|
259
|
+
z,
|
|
260
|
+
j,
|
|
261
|
+
M
|
|
262
|
+
]), re = (e) => {
|
|
263
|
+
x === "hover" && e.pointerType === "mouse" && X(!0, e);
|
|
264
|
+
}, ie = (e) => {
|
|
265
|
+
x === "hover" && e.pointerType === "mouse" && X(!1, e);
|
|
266
|
+
}, ae = (e) => {
|
|
267
|
+
x !== "manual" && (q.current = e.pointerType, K.current = !1, e.pointerType === "mouse" || R || (K.current = !0, X(!0, e)));
|
|
268
|
+
}, oe = (e) => {
|
|
269
|
+
K.current && (K.current = !1, e.stopPropagation(), e.preventDefault());
|
|
270
|
+
}, se = (e) => {
|
|
271
|
+
x !== "manual" && (x === "click" ? X(!R, e) : R && q.current !== "mouse" && X(!1, e));
|
|
272
|
+
}, ce = (e) => {
|
|
273
|
+
if (x !== "manual") {
|
|
274
|
+
if (R) {
|
|
234
275
|
if (e.key !== "Escape") return;
|
|
235
|
-
e.stopPropagation(),
|
|
236
|
-
} else (e.key === "Enter" || e.key === " ") && (e.preventDefault(),
|
|
276
|
+
e.stopPropagation(), X(!1, e), W.current?.focus();
|
|
277
|
+
} else (e.key === "Enter" || e.key === " ") && (e.preventDefault(), J.current = !0, X(!0, e));
|
|
237
278
|
}
|
|
238
|
-
},
|
|
239
|
-
|
|
240
|
-
}, Q =
|
|
279
|
+
}, Z = (e) => {
|
|
280
|
+
X(!1, e);
|
|
281
|
+
}, Q = P?.root ?? O, le = P?.item ?? k, ue = o({
|
|
241
282
|
elementType: Q,
|
|
242
|
-
externalForwardedProps:
|
|
243
|
-
externalSlotProps:
|
|
244
|
-
ownerState:
|
|
283
|
+
externalForwardedProps: L,
|
|
284
|
+
externalSlotProps: F?.root,
|
|
285
|
+
ownerState: H,
|
|
245
286
|
additionalProps: {
|
|
246
|
-
ref:
|
|
287
|
+
ref: Y,
|
|
247
288
|
role: "group",
|
|
248
|
-
tabIndex: !
|
|
249
|
-
onPointerEnter:
|
|
250
|
-
onPointerLeave:
|
|
251
|
-
onPointerDown:
|
|
252
|
-
onClick:
|
|
253
|
-
onClickCapture:
|
|
254
|
-
onKeyDown:
|
|
289
|
+
tabIndex: !R && x !== "manual" ? 0 : -1,
|
|
290
|
+
onPointerEnter: re,
|
|
291
|
+
onPointerLeave: ie,
|
|
292
|
+
onPointerDown: ae,
|
|
293
|
+
onClick: se,
|
|
294
|
+
onClickCapture: oe,
|
|
295
|
+
onKeyDown: ce
|
|
255
296
|
},
|
|
256
|
-
className: [
|
|
297
|
+
className: [U.root, I]
|
|
257
298
|
});
|
|
258
299
|
if (e.useEffect(() => {
|
|
259
|
-
if (!
|
|
260
|
-
|
|
261
|
-
let e =
|
|
262
|
-
e && (e.querySelector(
|
|
263
|
-
}, [
|
|
300
|
+
if (!R || !J.current) return;
|
|
301
|
+
J.current = !1;
|
|
302
|
+
let e = G.current[0];
|
|
303
|
+
e && (e.querySelector(w) ?? e).focus();
|
|
304
|
+
}, [R]), V === 0) return null;
|
|
264
305
|
let $ = /* @__PURE__ */ l(Q, {
|
|
265
|
-
...
|
|
266
|
-
children:
|
|
306
|
+
...ue,
|
|
307
|
+
children: B.map((e, t) => /* @__PURE__ */ l(A, {
|
|
267
308
|
index: t,
|
|
268
|
-
ownerState:
|
|
269
|
-
geometry:
|
|
270
|
-
className:
|
|
271
|
-
component:
|
|
272
|
-
inert: !
|
|
273
|
-
itemRefs:
|
|
274
|
-
slotProps:
|
|
309
|
+
ownerState: H,
|
|
310
|
+
geometry: b(t, H),
|
|
311
|
+
className: U.item,
|
|
312
|
+
component: le,
|
|
313
|
+
inert: !R && x !== "manual",
|
|
314
|
+
itemRefs: G,
|
|
315
|
+
slotProps: F?.item,
|
|
275
316
|
children: e
|
|
276
317
|
}, t))
|
|
277
318
|
});
|
|
278
|
-
return
|
|
279
|
-
onClickAway:
|
|
319
|
+
return ee || x === "manual" ? $ : /* @__PURE__ */ l(t, {
|
|
320
|
+
onClickAway: Z,
|
|
280
321
|
children: $
|
|
281
322
|
});
|
|
282
323
|
});
|
|
283
|
-
export {
|
|
324
|
+
export { j as CollageFab };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "mui-collage-fab",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.4.0",
|
|
4
4
|
"description": "Material UI floating action button that unfolds a stack of overlapping Fab circles into a row.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Radomir Wojtera",
|
|
@@ -151,7 +151,7 @@
|
|
|
151
151
|
{
|
|
152
152
|
"name": "CJS build",
|
|
153
153
|
"path": "dist-lib/index.cjs",
|
|
154
|
-
"limit": "3.
|
|
154
|
+
"limit": "3.2 kB"
|
|
155
155
|
}
|
|
156
156
|
]
|
|
157
157
|
}
|