freemium-ui 2.0.0-beta.27 → 2.0.0-beta.29
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/{dist/index.cjs.js → index.cjs.js} +11 -11
- package/{dist/index.d.ts → index.d.ts} +2 -2
- package/{dist/index.js → index.js} +11 -11
- package/package.json +7 -65
- package/LICENSE +0 -21
- package/dist/README.md +0 -86
- package/dist/package.json +0 -75
- package/freemium-ui-1.0.335.tgz +0 -0
|
@@ -3613,7 +3613,7 @@ className:"input-label","aria-label":a,htmlFor:o
|
|
|
3613
3613
|
},a,d&&e.createElement(zn,null,"*"))),e.createElement(md,{open:x,defaultOpen:M,
|
|
3614
3614
|
name:f,required:d,disabled:u,value:b?.[r]??void 0,onValueChange:e=>{if(s)return
|
|
3615
3615
|
;const t=i.find((t=>t?.[r]===e));l?.(t??null)}},e.createElement(Dd,{
|
|
3616
|
-
className:`SelectTrigger ${g
|
|
3616
|
+
className:`SelectTrigger ${g??""}`.trim(),"aria-label":"Food",disabled:u,id:o,
|
|
3617
3617
|
isErrored:!!w,"aria-invalid":!!w,width:v,style:y},e.createElement(gd,{
|
|
3618
3618
|
className:"SelectValue",placeholder:c}),e.createElement(Hd,{
|
|
3619
3619
|
className:"SelectIcon"},e.createElement(rr,{fill:n.colors.text.primary
|
|
@@ -3627,9 +3627,9 @@ className:"SelectScrollButton"},e.createElement(rr,{fill:n.colors.text.primary
|
|
|
3627
3627
|
},t.key,e.createElement(wd,null)),t.items.map(((t,n)=>{
|
|
3628
3628
|
const a="string"==typeof t?t:t?.[r],o=t?.[r]??""
|
|
3629
3629
|
;return o&&""!==o||console.warn("No value for item",t),
|
|
3630
|
-
e.createElement(e.Fragment,null,m?m(t,{key:a,value:o
|
|
3631
|
-
|
|
3632
|
-
|
|
3630
|
+
e.createElement(e.Fragment,null,m?m(t,{key:a,value:o??a,disabled:!!t.disabled,
|
|
3631
|
+
showTick:h}):e.createElement(am,{key:a,value:o||a,disabled:!!t.disabled,
|
|
3632
|
+
showTick:h},p(t,"list-item")))})))))),e.createElement(_d,{
|
|
3633
3633
|
className:"SelectScrollButton"},e.createElement(rr,{fill:n.colors.text.primary
|
|
3634
3634
|
})))))),w&&z&&e.createElement(vc,null,z))
|
|
3635
3635
|
},rm=({itemIdentifier:t="id",label:n,id:r,items:a=[],placeholder:o,readOnly:i=!1,disabled:l=!1,isRequired:c=!1,hideClear:s=!1,itemToString:u,name:d,filterKey:h,width:p,customValues:f,onCustomValueAdd:m,itemComponent:v,emptyItemsText:g,getCustomMessage:y,onChange:b,useComboboxProps:w,isErrored:C,errorText:z,defaultSelectedItem:M,isMenuLoading:x})=>{
|
|
@@ -12466,7 +12466,7 @@ return e.createElement(tm,{items:n,
|
|
|
12466
12466
|
itemToString:(e,n)=>"list-item"===n?e?.name??"":"months"===t.name&&e?.name?jR?.[e?.name?.toString().toLowerCase()]:e?.name??"",
|
|
12467
12467
|
type:"button",disabled:!!t.disabled,
|
|
12468
12468
|
defaultSelectedItem:n.find((e=>e.id===t.value))??null,style:t.style,
|
|
12469
|
-
className:`${t.className} bp-custom-dropdown bp-custom-dropdown-${t.name}`.trim(),
|
|
12469
|
+
className:`${t.className??""} bp-custom-dropdown bp-custom-dropdown-${t.name??""}`.trim(),
|
|
12470
12470
|
onChange:e=>{t?.onChange?.({target:{value:e?.id}})}})}
|
|
12471
12471
|
return e.createElement(tm,{itemToString:()=>"",type:"button"})},$R=[{id:"AM",
|
|
12472
12472
|
name:"AM"},{id:"PM",name:"PM"
|
|
@@ -15627,7 +15627,7 @@ d:"M8 0C3.58172 0 0 3.58172 0 8C0 12.4183 3.58172 16 8 16C12.4183 16 16 12.4183
|
|
|
15627
15627
|
fill:n.colors.text.semantic.error}))},XB=({index:t,...n})=>{
|
|
15628
15628
|
const r=qt(),{updateToasts:a,windowState:o}=e.useContext(rB)??{},i=e.useRef(null)
|
|
15629
15629
|
;return e.createElement(e.Fragment,null,e.createElement(FB,{ref:i,
|
|
15630
|
-
toastType:n.type,toastIndex:t,className:`ToastRoot Toast-${n.id}`.trim(),
|
|
15630
|
+
toastType:n.type,toastIndex:t,className:`ToastRoot Toast-${n.id??""}`.trim(),
|
|
15631
15631
|
duration:n.delay??3e3,onOpenChange:e=>{e||a((e=>e.filter((e=>e.id!==n.id))))}
|
|
15632
15632
|
},e.createElement(YB,{className:"ToastProgress",windowState:o,toastType:n.type,
|
|
15633
15633
|
delay:n.delay??3e3
|
|
@@ -16036,7 +16036,7 @@ disabled:v||r,"aria-disabled":v||r,onClick:e=>c?.(o,e),
|
|
|
16036
16036
|
"aria-describedby":"string"===(typeof o?.[l]??s?.[0]?.[l])?o?.[l]??s?.[0]?.[l]:void 0,
|
|
16037
16037
|
role:"button"
|
|
16038
16038
|
},e.createElement("span",null,o?.[l]??s?.[0]?.[l]??""),e.createElement(Il,{
|
|
16039
|
-
trigger:e.createElement(ar,{fill:b.colors.text.
|
|
16039
|
+
trigger:e.createElement(ar,{fill:b.colors.text.primary}),onSelect:e=>c?.(e),
|
|
16040
16040
|
options:s?.filter((e=>e?.[i]!==o?.[i]))||[],showArrow:!1,side:u,align:h,
|
|
16041
16041
|
alignOffset:p,arrowPadding:f,avoidCollisions:m,sideOffset:d,idAccessor:i,
|
|
16042
16042
|
nameAccessor:l}))
|
|
@@ -16117,7 +16117,7 @@ formatDate:e=>e?Lm(e).format(u):"",...d}),i&&l&&e.createElement(vc,null,l))
|
|
|
16117
16117
|
const u=qt();return e.createElement(Ws,{open:t,onOpenChange:e=>{e||s?.()}
|
|
16118
16118
|
},e.createElement(Gs,null,e.createElement(js,{forceMount:!0,
|
|
16119
16119
|
className:"DialogOverlay",onClick:()=>{c&&s?.()}}),e.createElement(Us,{
|
|
16120
|
-
forceMount:!0,className:`DialogContent ${a}`.trim(),isFullHeight:i,size:o,
|
|
16120
|
+
forceMount:!0,className:`DialogContent ${a??""}`.trim(),isFullHeight:i,size:o,
|
|
16121
16121
|
placement:l},!r&&e.createElement(Ys,{asChild:!0},e.createElement($s,{
|
|
16122
16122
|
"aria-label":"Close"},e.createElement(qn,{fill:u.colors.text.inverse}))),n)))
|
|
16123
16123
|
},exports.Dropdown=tm,
|
|
@@ -16130,9 +16130,9 @@ exports.InputLabel=Cn,
|
|
|
16130
16130
|
exports.Loader=em,exports.Menu=Il,exports.Minus=Vc,exports.Modal=({isOpen:t,children:n,align:r="center",customClass:a="",fullWidth:o=!1,customModalContentStyles:i={},onDismiss:l,position:c="center",size:s})=>e.createElement(cm,{
|
|
16131
16131
|
open:t,onOpenChange:e=>{e||l?.()}},e.createElement(sm,null,e.createElement(um,{
|
|
16132
16132
|
forceMount:!0,className:"DialogOverlay",onClick:()=>l?.()}),e.createElement(dm,{
|
|
16133
|
-
forceMount:!0,className:`DialogContent ${a}`.trim(),size:s??"default",
|
|
16133
|
+
forceMount:!0,className:`DialogContent ${a??""}`.trim(),size:s??"default",
|
|
16134
16134
|
fullWidth:o,align:r,position:c,style:i
|
|
16135
|
-
},n))),exports.MoreVertical=od,exports.MultiSelectDropdown=({itemIdentifier:t="id",label:n,id:r,items:a=[],onChange:o,placeholder:i,readOnly:l=!1,disabled:c=!1,isRequired:s=!1,itemToString:u,name:d,filterKey:h,width:p,useComboboxProps:f,useMultipleSelectionProps:m,emptyItemsText:v,getCustomMessage:g,onCustomValueAdd:y,customValues:b,inputValue:w,hideClear:C,removeSelectedItem:z,
|
|
16135
|
+
},n))),exports.MoreVertical=od,exports.MultiSelectDropdown=({itemIdentifier:t="id",label:n,id:r,items:a=[],onChange:o,placeholder:i,readOnly:l=!1,disabled:c=!1,isRequired:s=!1,itemToString:u,name:d,filterKey:h,width:p,useComboboxProps:f,useMultipleSelectionProps:m,emptyItemsText:v,getCustomMessage:g,onCustomValueAdd:y,customValues:b,inputValue:w,hideClear:C,removeSelectedItem:z,defaultSelectedItems:M=[],handleInputChange:x,isErrored:E,isMenuLoading:S,errorText:_,InputProps:H,itemComponent:D,isDynamicMenu:L,locale:V,maxAllowedLength:A,minAllowedLength:k,onBackSpace:T})=>{
|
|
16136
16136
|
const R=qt(),[P,I]=e.useState(""),[O,N]=e.useState([]),F=e.useMemo((()=>a.filter((e=>!P||("string"==typeof e?e:e?.[h||t]).toLowerCase().includes(P.toLowerCase())))),[a,h,t,P]),{getSelectedItemProps:B,getDropdownProps:j,removeSelectedItem:U,setSelectedItems:$}=Bf({
|
|
16137
16137
|
selectedItems:O,onStateChange:({selectedItems:e,type:t})=>{switch(t){
|
|
16138
16138
|
case Bf.stateChangeTypes.SelectedItemKeyDownBackspace:
|
|
@@ -16179,7 +16179,7 @@ index:r})
|
|
|
16179
16179
|
fill:R.colors.common.accent})))})))),E&&_&&e.createElement(vc,null,_))
|
|
16180
16180
|
},exports.Popover=yP,
|
|
16181
16181
|
exports.PopoverClose=gP,exports.Radio=({checked:t,className:n,disabled:r,id:a,isRequired:o,label:i,name:l,readOnly:c,...s})=>e.createElement(wP,{
|
|
16182
|
-
className:`RadioGroupRoot ${n}`.trim(),id:a,name:l,"aria-label":i,
|
|
16182
|
+
className:`RadioGroupRoot ${n??""}`.trim(),id:a,name:l,"aria-label":i,
|
|
16183
16183
|
value:t?"default":"",required:o,disabled:r,"aria-readonly":c,...s
|
|
16184
16184
|
},e.createElement(MP,null,e.createElement(zP,{checked:t,"aria-checked":t,
|
|
16185
16185
|
className:"RadioGroupItem",disabled:r,"aria-readonly":c,value:"default",
|
|
@@ -707,7 +707,7 @@ interface MultiSelectDropdownProps<T extends DefaultMultiSelectDropdownItem = De
|
|
|
707
707
|
/**
|
|
708
708
|
* selected item of dropdown
|
|
709
709
|
*/
|
|
710
|
-
|
|
710
|
+
defaultSelectedItems?: T[];
|
|
711
711
|
/**
|
|
712
712
|
* Called when select an option or input value change
|
|
713
713
|
*/
|
|
@@ -795,7 +795,7 @@ interface MultiSelectDropdownProps<T extends DefaultMultiSelectDropdownItem = De
|
|
|
795
795
|
/**
|
|
796
796
|
* MultiSelectDropdown displays a list or drop-down box that enables selection of an option or multiple options from an available list of values.
|
|
797
797
|
*/
|
|
798
|
-
declare const MultiSelectDropdown: <T extends DefaultMultiSelectDropdownItem>({ itemIdentifier, label, id, items, onChange, placeholder, readOnly, disabled, isRequired, itemToString, name, filterKey, width, useComboboxProps, useMultipleSelectionProps, emptyItemsText, getCustomMessage, onCustomValueAdd, customValues, inputValue: iV, hideClear, removeSelectedItem: rSelectedItem,
|
|
798
|
+
declare const MultiSelectDropdown: <T extends DefaultMultiSelectDropdownItem>({ itemIdentifier, label, id, items, onChange, placeholder, readOnly, disabled, isRequired, itemToString, name, filterKey, width, useComboboxProps, useMultipleSelectionProps, emptyItemsText, getCustomMessage, onCustomValueAdd, customValues, inputValue: iV, hideClear, removeSelectedItem: rSelectedItem, defaultSelectedItems, handleInputChange, isErrored, isMenuLoading, errorText, InputProps, itemComponent, isDynamicMenu, locale, maxAllowedLength, minAllowedLength, onBackSpace, }: MultiSelectDropdownProps<T>) => react__default.JSX.Element;
|
|
799
799
|
|
|
800
800
|
type DefaultProps = {
|
|
801
801
|
/**
|
|
@@ -1678,7 +1678,7 @@ disabled:v||r,"aria-disabled":v||r,onClick:e=>c?.(o,e),
|
|
|
1678
1678
|
"aria-describedby":"string"===(typeof o?.[l]??s?.[0]?.[l])?o?.[l]??s?.[0]?.[l]:void 0,
|
|
1679
1679
|
role:"button"
|
|
1680
1680
|
},t.createElement("span",null,o?.[l]??s?.[0]?.[l]??""),t.createElement(ac,{
|
|
1681
|
-
trigger:t.createElement(Sr,{fill:b.colors.text.
|
|
1681
|
+
trigger:t.createElement(Sr,{fill:b.colors.text.primary}),onSelect:e=>c?.(e),
|
|
1682
1682
|
options:s?.filter((e=>e?.[i]!==o?.[i]))||[],showArrow:!1,side:u,align:h,
|
|
1683
1683
|
alignOffset:p,arrowPadding:f,avoidCollisions:m,sideOffset:d,idAccessor:i,
|
|
1684
1684
|
nameAccessor:l}))};function ic(e){const t=r({value:e,previous:e})
|
|
@@ -2153,7 +2153,7 @@ variant:"primary","aria-disabled":s,disabled:s,onClick:()=>a?.(),"aria-label":u
|
|
|
2153
2153
|
const u=vn();return t.createElement(vu,{open:e,onOpenChange:e=>{e||s?.()}
|
|
2154
2154
|
},t.createElement(gu,null,t.createElement(hu,{forceMount:!0,
|
|
2155
2155
|
className:"DialogOverlay",onClick:()=>{c&&s?.()}}),t.createElement(pu,{
|
|
2156
|
-
forceMount:!0,className:`DialogContent ${a}`.trim(),isFullHeight:i,size:o,
|
|
2156
|
+
forceMount:!0,className:`DialogContent ${a??""}`.trim(),isFullHeight:i,size:o,
|
|
2157
2157
|
placement:l},!r&&t.createElement(mu,{asChild:!0},t.createElement(fu,{
|
|
2158
2158
|
"aria-label":"Close"},t.createElement(mr,{fill:u.colors.text.inverse}))),n)))}
|
|
2159
2159
|
;function bu(e,[t,n]){return Math.min(n,Math.max(t,e))}
|
|
@@ -3603,7 +3603,7 @@ className:"input-label","aria-label":a,htmlFor:o
|
|
|
3603
3603
|
},a,d&&t.createElement(jn,null,"*"))),t.createElement(Fd,{open:x,defaultOpen:M,
|
|
3604
3604
|
name:f,required:d,disabled:u,value:b?.[r]??void 0,onValueChange:e=>{if(s)return
|
|
3605
3605
|
;const t=i.find((t=>t?.[r]===e));l?.(t??null)}},t.createElement(eh,{
|
|
3606
|
-
className:`SelectTrigger ${g
|
|
3606
|
+
className:`SelectTrigger ${g??""}`.trim(),"aria-label":"Food",disabled:u,id:o,
|
|
3607
3607
|
isErrored:!!w,"aria-invalid":!!w,width:v,style:y},t.createElement(jd,{
|
|
3608
3608
|
className:"SelectValue",placeholder:c}),t.createElement(Jd,{
|
|
3609
3609
|
className:"SelectIcon"},t.createElement(xr,{fill:n.colors.text.primary
|
|
@@ -3617,9 +3617,9 @@ className:"SelectScrollButton"},t.createElement(xr,{fill:n.colors.text.primary
|
|
|
3617
3617
|
},e.key,t.createElement(Yd,null)),e.items.map(((e,n)=>{
|
|
3618
3618
|
const a="string"==typeof e?e:e?.[r],o=e?.[r]??""
|
|
3619
3619
|
;return o&&""!==o||console.warn("No value for item",e),
|
|
3620
|
-
t.createElement(t.Fragment,null,m?m(e,{key:a,value:o
|
|
3621
|
-
|
|
3622
|
-
|
|
3620
|
+
t.createElement(t.Fragment,null,m?m(e,{key:a,value:o??a,disabled:!!e.disabled,
|
|
3621
|
+
showTick:h}):t.createElement(Lm,{key:a,value:o||a,disabled:!!e.disabled,
|
|
3622
|
+
showTick:h},p(e,"list-item")))})))))),t.createElement(Qd,{
|
|
3623
3623
|
className:"SelectScrollButton"},t.createElement(xr,{fill:n.colors.text.primary
|
|
3624
3624
|
})))))),w&&z&&t.createElement(Oc,null,z))
|
|
3625
3625
|
},Dm=({itemIdentifier:e="id",label:n,id:r,items:a=[],placeholder:o,readOnly:i=!1,disabled:l=!1,isRequired:c=!1,hideClear:s=!1,itemToString:u,name:d,filterKey:h,width:p,customValues:f,onCustomValueAdd:m,itemComponent:v,emptyItemsText:g,getCustomMessage:y,onChange:b,useComboboxProps:w,isErrored:C,errorText:z,defaultSelectedItem:M,isMenuLoading:x})=>{
|
|
@@ -3781,7 +3781,7 @@ default:"512px",small:"424px",medium:"600px",large:"800px","x-large":"1200px"
|
|
|
3781
3781
|
`,Om=({isOpen:e,children:n,align:r="center",customClass:a="",fullWidth:o=!1,customModalContentStyles:i={},onDismiss:l,position:c="center",size:s})=>t.createElement(Tm,{
|
|
3782
3782
|
open:e,onOpenChange:e=>{e||l?.()}},t.createElement(Pm,null,t.createElement(Im,{
|
|
3783
3783
|
forceMount:!0,className:"DialogOverlay",onClick:()=>l?.()}),t.createElement(Rm,{
|
|
3784
|
-
forceMount:!0,className:`DialogContent ${a}`.trim(),size:s??"default",
|
|
3784
|
+
forceMount:!0,className:`DialogContent ${a??""}`.trim(),size:s??"default",
|
|
3785
3785
|
fullWidth:o,align:r,position:c,style:i},n))),Nm=En.div`
|
|
3786
3786
|
flex: 1;
|
|
3787
3787
|
gap: 8px;
|
|
@@ -3878,7 +3878,7 @@ className:"StyledTag"},i||l?t.createElement(Km,{className:"AvatarRoot"
|
|
|
3878
3878
|
className:"AvatarFallback",delayMs:600
|
|
3879
3879
|
},l)):t.createElement("div",null),e,t.createElement(Xm,{...n,onClick:r
|
|
3880
3880
|
},t.createElement(mr,{fill:u.colors.text.primary})))
|
|
3881
|
-
},ev=({itemIdentifier:e="id",label:n,id:r,items:a=[],onChange:o,placeholder:i,readOnly:l=!1,disabled:c=!1,isRequired:s=!1,itemToString:u,name:d,filterKey:h,width:p,useComboboxProps:f,useMultipleSelectionProps:m,emptyItemsText:v,getCustomMessage:g,onCustomValueAdd:y,customValues:b,inputValue:w,hideClear:C,removeSelectedItem:z,
|
|
3881
|
+
},ev=({itemIdentifier:e="id",label:n,id:r,items:a=[],onChange:o,placeholder:i,readOnly:l=!1,disabled:c=!1,isRequired:s=!1,itemToString:u,name:d,filterKey:h,width:p,useComboboxProps:f,useMultipleSelectionProps:m,emptyItemsText:v,getCustomMessage:g,onCustomValueAdd:y,customValues:b,inputValue:w,hideClear:C,removeSelectedItem:z,defaultSelectedItems:M=[],handleInputChange:x,isErrored:S,isMenuLoading:E,errorText:_,InputProps:H,itemComponent:D,isDynamicMenu:L,locale:V,maxAllowedLength:A,minAllowedLength:k,onBackSpace:T})=>{
|
|
3882
3882
|
const P=vn(),[I,R]=t.useState(""),[O,N]=t.useState([]),F=t.useMemo((()=>a.filter((t=>!I||("string"==typeof t?t:t?.[h||e]).toLowerCase().includes(I.toLowerCase())))),[a,h,e,I]),{getSelectedItemProps:B,getDropdownProps:j,removeSelectedItem:U,setSelectedItems:$}=hm({
|
|
3883
3883
|
selectedItems:O,onStateChange:({selectedItems:e,type:t})=>{switch(t){
|
|
3884
3884
|
case hm.stateChangeTypes.SelectedItemKeyDownBackspace:
|
|
@@ -12498,7 +12498,7 @@ return t.createElement(_m,{items:n,
|
|
|
12498
12498
|
itemToString:(t,n)=>"list-item"===n?t?.name??"":"months"===e.name&&t?.name?vI?.[t?.name?.toString().toLowerCase()]:t?.name??"",
|
|
12499
12499
|
type:"button",disabled:!!e.disabled,
|
|
12500
12500
|
defaultSelectedItem:n.find((t=>t.id===e.value))??null,style:e.style,
|
|
12501
|
-
className:`${e.className} bp-custom-dropdown bp-custom-dropdown-${e.name}`.trim(),
|
|
12501
|
+
className:`${e.className??""} bp-custom-dropdown bp-custom-dropdown-${e.name??""}`.trim(),
|
|
12502
12502
|
onChange:t=>{e?.onChange?.({target:{value:t?.id}})}})}
|
|
12503
12503
|
return t.createElement(_m,{itemToString:()=>"",type:"button"})},yI=e=>{
|
|
12504
12504
|
const{placeholder:n,name:r,isRequired:a,label:o,isErrored:i,errorText:l,id:c,disabled:s,displayFormat:u="YYYY-MM-DD",...d}=e
|
|
@@ -12727,7 +12727,7 @@ onInteractOutside:()=>u&&u(),side:g,align:o,sideOffset:8,avoidCollisions:l
|
|
|
12727
12727
|
display: flex;
|
|
12728
12728
|
align-items: center;
|
|
12729
12729
|
`,rR=({checked:e,className:n,disabled:r,id:a,isRequired:o,label:i,name:l,readOnly:c,...s})=>t.createElement(JI,{
|
|
12730
|
-
className:`RadioGroupRoot ${n}`.trim(),id:a,name:l,"aria-label":i,
|
|
12730
|
+
className:`RadioGroupRoot ${n??""}`.trim(),id:a,name:l,"aria-label":i,
|
|
12731
12731
|
value:e?"default":"",required:o,disabled:r,"aria-readonly":c,...s
|
|
12732
12732
|
},t.createElement(nR,null,t.createElement(tR,{checked:e,"aria-checked":e,
|
|
12733
12733
|
className:"RadioGroupItem",disabled:r,"aria-readonly":c,value:"default",
|
|
@@ -15824,7 +15824,7 @@ d:"M8 0C3.58172 0 0 3.58172 0 8C0 12.4183 3.58172 16 8 16C12.4183 16 16 12.4183
|
|
|
15824
15824
|
fill:n.colors.text.semantic.error}))},kj=({index:e,...n})=>{
|
|
15825
15825
|
const r=vn(),{updateToasts:a,windowState:o}=t.useContext(NB)??{},i=t.useRef(null)
|
|
15826
15826
|
;return t.createElement(t.Fragment,null,t.createElement(zj,{ref:i,
|
|
15827
|
-
toastType:n.type,toastIndex:e,className:`ToastRoot Toast-${n.id}`.trim(),
|
|
15827
|
+
toastType:n.type,toastIndex:e,className:`ToastRoot Toast-${n.id??""}`.trim(),
|
|
15828
15828
|
duration:n.delay??3e3,onOpenChange:e=>{e||a((e=>e.filter((e=>e.id!==n.id))))}
|
|
15829
15829
|
},t.createElement(_j,{className:"ToastProgress",windowState:o,toastType:n.type,
|
|
15830
15830
|
delay:n.delay??3e3
|
package/package.json
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "freemium-ui",
|
|
3
|
-
"version": "2.0.0-beta.
|
|
3
|
+
"version": "2.0.0-beta.29",
|
|
4
4
|
"description": "React Ui Components for Freemium Apps",
|
|
5
|
-
"main": "
|
|
6
|
-
"module": "
|
|
7
|
-
"typings": "
|
|
5
|
+
"main": "./index.js",
|
|
6
|
+
"module": "./index.js",
|
|
7
|
+
"typings": "./index.d.ts",
|
|
8
8
|
"dependencies": {
|
|
9
9
|
"@blueprintjs/datetime2": "^2.3.2",
|
|
10
10
|
"@dnd-kit/core": "^6.1.0",
|
|
@@ -34,65 +34,6 @@
|
|
|
34
34
|
"typescript": "^4.9.5",
|
|
35
35
|
"web-vitals": "^2.1.4"
|
|
36
36
|
},
|
|
37
|
-
"devDependencies": {
|
|
38
|
-
"@babel/plugin-proposal-private-property-in-object": "^7.21.11",
|
|
39
|
-
"@rollup/plugin-commonjs": "^25.0.7",
|
|
40
|
-
"@rollup/plugin-node-resolve": "^15.2.3",
|
|
41
|
-
"@rollup/plugin-terser": "^0.4.4",
|
|
42
|
-
"@rollup/plugin-typescript": "^11.1.6",
|
|
43
|
-
"@storybook/addon-essentials": "^8.0.0",
|
|
44
|
-
"@storybook/addon-interactions": "^8.0.0",
|
|
45
|
-
"@storybook/addon-links": "^8.0.0",
|
|
46
|
-
"@storybook/addon-onboarding": "^8.0.0",
|
|
47
|
-
"@storybook/blocks": "^8.0.0",
|
|
48
|
-
"@storybook/preset-create-react-app": "^8.0.0",
|
|
49
|
-
"@storybook/preview-api": "^8.0.0",
|
|
50
|
-
"@storybook/react": "^8.0.0",
|
|
51
|
-
"@storybook/react-webpack5": "^8.0.0",
|
|
52
|
-
"@storybook/test": "^8.0.0",
|
|
53
|
-
"@testing-library/jest-dom": "^5.17.0",
|
|
54
|
-
"@testing-library/react": "^13.4.0",
|
|
55
|
-
"@testing-library/user-event": "^13.5.0",
|
|
56
|
-
"@types/jest": "^27.5.2",
|
|
57
|
-
"@types/node": "^16.18.64",
|
|
58
|
-
"@types/react": "^18.2.63",
|
|
59
|
-
"@types/react-dom": "^18.2.19",
|
|
60
|
-
"@types/react-transition-group": "^4.4.10",
|
|
61
|
-
"@types/rollup-plugin-generate-package-json": "^3.2.8",
|
|
62
|
-
"@types/rollup-plugin-peer-deps-external": "^2.2.5",
|
|
63
|
-
"@types/styled-components": "^5.1.34",
|
|
64
|
-
"babel-plugin-named-exports-order": "^0.0.2",
|
|
65
|
-
"eslint-plugin-storybook": "^0.8.0",
|
|
66
|
-
"husky": "^8.0.3",
|
|
67
|
-
"postcss": "^8.4.35",
|
|
68
|
-
"prettier": "^3.2.5",
|
|
69
|
-
"prop-types": "^15.8.1",
|
|
70
|
-
"rollup": "^4.12.0",
|
|
71
|
-
"rollup-plugin-dts": "^6.1.0",
|
|
72
|
-
"rollup-plugin-generate-package-json": "^3.2.0",
|
|
73
|
-
"rollup-plugin-peer-deps-external": "^2.2.4",
|
|
74
|
-
"storybook": "^8.0.0",
|
|
75
|
-
"webpack": "^5.90.3"
|
|
76
|
-
},
|
|
77
|
-
"scripts": {
|
|
78
|
-
"version:beta": "npm version prerelease --preid=beta",
|
|
79
|
-
"publish:beta": "npm publish ./dist --tag beta",
|
|
80
|
-
"publish": "npm publish ./dist",
|
|
81
|
-
"prepublishOnly": "npm run build",
|
|
82
|
-
"start": "react-scripts start",
|
|
83
|
-
"build:react-app": "react-scripts build",
|
|
84
|
-
"build": "npm run rollup && npm run post:build",
|
|
85
|
-
"post:build": "node ./scripts/frankBuild.js",
|
|
86
|
-
"rollup": "rm -rf dist && rollup --config rollup.config.ts --configPlugin @rollup/plugin-typescript",
|
|
87
|
-
"test": "react-scripts test",
|
|
88
|
-
"eject": "react-scripts eject",
|
|
89
|
-
"check": "prettier --check .",
|
|
90
|
-
"format": "prettier --write .",
|
|
91
|
-
"storybook": "storybook dev -p 6006",
|
|
92
|
-
"build-storybook": "storybook build",
|
|
93
|
-
"typescript": "tsc -p tsconfig.json",
|
|
94
|
-
"prepare": "husky install"
|
|
95
|
-
},
|
|
96
37
|
"repository": {
|
|
97
38
|
"type": "git",
|
|
98
39
|
"url": "git+https://github.com/freshdesk/freemium-ui.git"
|
|
@@ -129,5 +70,6 @@
|
|
|
129
70
|
"last 1 firefox version",
|
|
130
71
|
"last 1 safari version"
|
|
131
72
|
]
|
|
132
|
-
}
|
|
133
|
-
|
|
73
|
+
},
|
|
74
|
+
"private": false
|
|
75
|
+
}
|
package/LICENSE
DELETED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
MIT License
|
|
2
|
-
|
|
3
|
-
Copyright (c) 2024 Freshworks
|
|
4
|
-
|
|
5
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
-
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
-
in the Software without restriction, including without limitation the rights
|
|
8
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
-
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
-
furnished to do so, subject to the following conditions:
|
|
11
|
-
|
|
12
|
-
The above copyright notice and this permission notice shall be included in all
|
|
13
|
-
copies or substantial portions of the Software.
|
|
14
|
-
|
|
15
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
-
SOFTWARE.
|
package/dist/README.md
DELETED
|
@@ -1,86 +0,0 @@
|
|
|
1
|
-
<h1 align="center">Freemium Ui</h1>
|
|
2
|
-
|
|
3
|
-
## [DEMO](https://freemium-ui.netlify.app)
|
|
4
|
-
|
|
5
|
-
[React](https://reactjs.org/) based light weight ui components based on [Styled Components](https://styled-components.com/)
|
|
6
|
-
|
|
7
|
-
## Installation
|
|
8
|
-
|
|
9
|
-
Peer Dependencies to be installed
|
|
10
|
-
|
|
11
|
-
```
|
|
12
|
-
npm install styled-components
|
|
13
|
-
```
|
|
14
|
-
|
|
15
|
-
Install the package
|
|
16
|
-
|
|
17
|
-
```
|
|
18
|
-
npm install freemium-ui
|
|
19
|
-
```
|
|
20
|
-
|
|
21
|
-
Please note that `@next` will only point to pre-releases; to get the latest stable release use `@latest` instead.
|
|
22
|
-
|
|
23
|
-
## Usage
|
|
24
|
-
|
|
25
|
-
Here is a quick example to get you started, **it's all you need**:
|
|
26
|
-
|
|
27
|
-
```jsx
|
|
28
|
-
import React from 'react';
|
|
29
|
-
import ReactDOM from 'react-dom';
|
|
30
|
-
import { Button } from 'freemium-ui';
|
|
31
|
-
// import { Button } from 'freemium-ui/Button';
|
|
32
|
-
|
|
33
|
-
function App() {
|
|
34
|
-
return <Button>Freemium Button</Button>;
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
ReactDOM.render(<App />, document.querySelector('#app'));
|
|
38
|
-
```
|
|
39
|
-
|
|
40
|
-
## Contribution
|
|
41
|
-
|
|
42
|
-
Install Dependencies
|
|
43
|
-
|
|
44
|
-
```
|
|
45
|
-
npm install
|
|
46
|
-
```
|
|
47
|
-
|
|
48
|
-
Start the app using storybook
|
|
49
|
-
|
|
50
|
-
```
|
|
51
|
-
npm run storybook
|
|
52
|
-
```
|
|
53
|
-
|
|
54
|
-
Build Freemium Ui Core Components
|
|
55
|
-
|
|
56
|
-
```
|
|
57
|
-
npm run build
|
|
58
|
-
```
|
|
59
|
-
|
|
60
|
-
JavaScript heap out of memory could lead to build failure. Check the [official docs](https://rollupjs.org/troubleshooting/#error-javascript-heap-out-of-memory). Or execute any of the required below config
|
|
61
|
-
|
|
62
|
-
```
|
|
63
|
-
export NODE_OPTIONS="--max-old-space-size=8192"
|
|
64
|
-
export NODE_OPTIONS="--max-old-space-size=12288"
|
|
65
|
-
export NODE_OPTIONS="--max-old-space-size=16384"
|
|
66
|
-
```
|
|
67
|
-
|
|
68
|
-
To check the heap size in MB
|
|
69
|
-
|
|
70
|
-
```
|
|
71
|
-
node -e 'console.log(v8.getHeapStatistics().heap_size_limit/(1024*1024))'
|
|
72
|
-
```
|
|
73
|
-
|
|
74
|
-
Generate a PAT with `admin:org`, `write:packages`, `read:packages`, `delete:packages`
|
|
75
|
-
|
|
76
|
-
Authenticate to npm github package
|
|
77
|
-
|
|
78
|
-
```
|
|
79
|
-
npm login --registry=https://registry.npmjs.org/
|
|
80
|
-
```
|
|
81
|
-
|
|
82
|
-
Publish the package to npm
|
|
83
|
-
|
|
84
|
-
```
|
|
85
|
-
npm publish
|
|
86
|
-
```
|
package/dist/package.json
DELETED
|
@@ -1,75 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "freemium-ui",
|
|
3
|
-
"version": "2.0.0-beta.27",
|
|
4
|
-
"description": "React Ui Components for Freemium Apps",
|
|
5
|
-
"main": "./index.js",
|
|
6
|
-
"module": "./index.js",
|
|
7
|
-
"typings": "./index.d.ts",
|
|
8
|
-
"dependencies": {
|
|
9
|
-
"@blueprintjs/datetime2": "^2.3.2",
|
|
10
|
-
"@dnd-kit/core": "^6.1.0",
|
|
11
|
-
"@dnd-kit/modifiers": "^7.0.0",
|
|
12
|
-
"@dnd-kit/sortable": "^8.0.0",
|
|
13
|
-
"@dnd-kit/utilities": "^3.2.2",
|
|
14
|
-
"@radix-ui/react-alert-dialog": "^1.0.5",
|
|
15
|
-
"@radix-ui/react-avatar": "^1.0.4",
|
|
16
|
-
"@radix-ui/react-checkbox": "^1.0.4",
|
|
17
|
-
"@radix-ui/react-dropdown-menu": "^2.0.6",
|
|
18
|
-
"@radix-ui/react-label": "^2.0.2",
|
|
19
|
-
"@radix-ui/react-popover": "^1.0.7",
|
|
20
|
-
"@radix-ui/react-radio-group": "^1.1.3",
|
|
21
|
-
"@radix-ui/react-select": "^2.0.0",
|
|
22
|
-
"@radix-ui/react-switch": "^1.0.3",
|
|
23
|
-
"@radix-ui/react-tabs": "^1.0.4",
|
|
24
|
-
"@radix-ui/react-toast": "^1.1.5",
|
|
25
|
-
"@radix-ui/react-tooltip": "^1.0.7",
|
|
26
|
-
"@tanstack/react-table": "^8.13.2",
|
|
27
|
-
"downshift": "^8.4.0",
|
|
28
|
-
"moment": "^2.30.1",
|
|
29
|
-
"react": "^18.2.0",
|
|
30
|
-
"react-dom": "^18.2.0",
|
|
31
|
-
"react-scripts": "5.0.1",
|
|
32
|
-
"react-transition-group": "^4.4.5",
|
|
33
|
-
"styled-components": "^6.1.8",
|
|
34
|
-
"typescript": "^4.9.5",
|
|
35
|
-
"web-vitals": "^2.1.4"
|
|
36
|
-
},
|
|
37
|
-
"repository": {
|
|
38
|
-
"type": "git",
|
|
39
|
-
"url": "git+https://github.com/freshdesk/freemium-ui.git"
|
|
40
|
-
},
|
|
41
|
-
"publishConfig": {
|
|
42
|
-
"registry": "https://registry.npmjs.org/"
|
|
43
|
-
},
|
|
44
|
-
"keywords": [
|
|
45
|
-
"Freemiui",
|
|
46
|
-
"React",
|
|
47
|
-
"UI",
|
|
48
|
-
"Material"
|
|
49
|
-
],
|
|
50
|
-
"author": "Freshworks",
|
|
51
|
-
"bugs": {
|
|
52
|
-
"url": "https://github.com/freshdesk/freemium-ui/issues"
|
|
53
|
-
},
|
|
54
|
-
"homepage": "https://github.com/freshdesk/freemium-ui#readme",
|
|
55
|
-
"eslintConfig": {
|
|
56
|
-
"extends": [
|
|
57
|
-
"react-app",
|
|
58
|
-
"react-app/jest",
|
|
59
|
-
"plugin:storybook/recommended"
|
|
60
|
-
]
|
|
61
|
-
},
|
|
62
|
-
"browserslist": {
|
|
63
|
-
"production": [
|
|
64
|
-
">0.2%",
|
|
65
|
-
"not dead",
|
|
66
|
-
"not op_mini all"
|
|
67
|
-
],
|
|
68
|
-
"development": [
|
|
69
|
-
"last 1 chrome version",
|
|
70
|
-
"last 1 firefox version",
|
|
71
|
-
"last 1 safari version"
|
|
72
|
-
]
|
|
73
|
-
},
|
|
74
|
-
"private": false
|
|
75
|
-
}
|
package/freemium-ui-1.0.335.tgz
DELETED
|
Binary file
|