freemium-ui 2.0.0-beta.30 → 2.0.0-beta.31

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.
Files changed (3) hide show
  1. package/index.cjs.js +13 -10
  2. package/index.js +13 -10
  3. package/package.json +1 -1
package/index.cjs.js CHANGED
@@ -3505,11 +3505,12 @@ activeIndex:d}}Bf.stateChangeTypes=If;const jf=on.textarea`
3505
3505
  outline: unset;
3506
3506
  padding: unset;
3507
3507
  margin: unset;
3508
- color: ${({theme:e})=>e.colors.text.primary};
3509
3508
  line-height: ${({theme:e})=>e.typography.primary.lineHeight};
3510
3509
  font-weight: ${({theme:e})=>e.typography.primary.fontWeight};
3511
3510
  font-size: ${({theme:e})=>e.typography.primary.fontSize};
3512
3511
  font-family: ${({theme:e})=>e.typography.fontFamily};
3512
+ background-color: ${({theme:e})=>e.colors.fill.surface};
3513
+ color: ${({theme:e})=>e.colors.text.primary};
3513
3514
  &::placeholder {
3514
3515
  font-family: ${({theme:e})=>e.typography.fontFamily};
3515
3516
  font-size: ${({theme:e})=>e.typography.primary.fontSize};
@@ -3529,6 +3530,8 @@ activeIndex:d}}Bf.stateChangeTypes=If;const jf=on.textarea`
3529
3530
  font-weight: ${({theme:e})=>e.typography.primary.fontWeight};
3530
3531
  font-size: ${({theme:e})=>e.typography.primary.fontSize};
3531
3532
  font-family: ${({theme:e})=>e.typography.fontFamily};
3533
+ background-color: ${({theme:e})=>e.colors.fill.surface};
3534
+ color: ${({theme:e})=>e.colors.text.primary};
3532
3535
  &::placeholder {
3533
3536
  font-family: ${({theme:e})=>e.typography.fontFamily};
3534
3537
  font-size: ${({theme:e})=>e.typography.primary.fontSize};
@@ -3623,7 +3626,7 @@ className:"input-label","aria-label":a,htmlFor:o
3623
3626
  },a,d&&e.createElement(zn,null,"*"))),e.createElement(md,{open:x,defaultOpen:M,
3624
3627
  name:f,required:d,disabled:u,value:b?.[r]??void 0,onValueChange:e=>{if(s)return
3625
3628
  ;const t=i.find((t=>t?.[r]===e));l?.(t??null)}},e.createElement(Dd,{
3626
- className:`SelectTrigger ${g||""}`.trim(),"aria-label":"Food",disabled:u,id:o,
3629
+ className:`SelectTrigger ${g??""}`.trim(),"aria-label":"Food",disabled:u,id:o,
3627
3630
  isErrored:!!w,"aria-invalid":!!w,width:v,style:y},e.createElement(gd,{
3628
3631
  className:"SelectValue",placeholder:c}),e.createElement(Hd,{
3629
3632
  className:"SelectIcon"},e.createElement(Rl,{fill:n.colors.text.primary
@@ -3637,9 +3640,9 @@ className:"SelectScrollButton"},e.createElement(Rl,{fill:n.colors.text.primary
3637
3640
  },t.key,e.createElement(wd,null)),t.items.map(((t,n)=>{
3638
3641
  const a="string"==typeof t?t:t?.[r],o=t?.[r]??""
3639
3642
  ;return o&&""!==o||console.warn("No value for item",t),
3640
- e.createElement(e.Fragment,null,m?m(t,{key:a,value:o||a.trim,
3641
- disabled:!!t.disabled,showTick:h}):e.createElement(am,{key:a,value:o||a,
3642
- disabled:!!t.disabled,showTick:h},p(t,"list-item")))})))))),e.createElement(_d,{
3643
+ e.createElement(e.Fragment,null,m?m(t,{key:a,value:o??a,disabled:!!t.disabled,
3644
+ showTick:h}):e.createElement(am,{key:a,value:o||a,disabled:!!t.disabled,
3645
+ showTick:h},p(t,"list-item")))})))))),e.createElement(_d,{
3643
3646
  className:"SelectScrollButton"},e.createElement(Rl,{fill:n.colors.text.primary
3644
3647
  })))))),w&&z&&e.createElement(vc,null,z))
3645
3648
  },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})=>{
@@ -12476,7 +12479,7 @@ return e.createElement(tm,{items:n,
12476
12479
  itemToString:(e,n)=>"list-item"===n?e?.name??"":"months"===t.name&&e?.name?jR?.[e?.name?.toString().toLowerCase()]:e?.name??"",
12477
12480
  type:"button",disabled:!!t.disabled,
12478
12481
  defaultSelectedItem:n.find((e=>e.id===t.value))??null,style:t.style,
12479
- className:`${t.className} bp-custom-dropdown bp-custom-dropdown-${t.name}`.trim(),
12482
+ className:`${t.className??""} bp-custom-dropdown bp-custom-dropdown-${t.name??""}`.trim(),
12480
12483
  onChange:e=>{t?.onChange?.({target:{value:e?.id}})}})}
12481
12484
  return e.createElement(tm,{itemToString:()=>"",type:"button"})},$R=[{id:"AM",
12482
12485
  name:"AM"},{id:"PM",name:"PM"
@@ -15637,7 +15640,7 @@ d:"M8 0C3.58172 0 0 3.58172 0 8C0 12.4183 3.58172 16 8 16C12.4183 16 16 12.4183
15637
15640
  fill:n.colors.text.semantic.error}))},XB=({index:t,...n})=>{
15638
15641
  const r=qt(),{updateToasts:a,windowState:o}=e.useContext(rB)??{},i=e.useRef(null)
15639
15642
  ;return e.createElement(e.Fragment,null,e.createElement(FB,{ref:i,
15640
- toastType:n.type,toastIndex:t,className:`ToastRoot Toast-${n.id}`.trim(),
15643
+ toastType:n.type,toastIndex:t,className:`ToastRoot Toast-${n.id??""}`.trim(),
15641
15644
  duration:n.delay??3e3,onOpenChange:e=>{e||a((e=>e.filter((e=>e.id!==n.id))))}
15642
15645
  },e.createElement(YB,{className:"ToastProgress",windowState:o,toastType:n.type,
15643
15646
  delay:n.delay??3e3
@@ -16127,7 +16130,7 @@ formatDate:e=>e?Lm(e).format(u):"",...d}),i&&l&&e.createElement(vc,null,l))
16127
16130
  const u=qt();return e.createElement(Ws,{open:t,onOpenChange:e=>{e||s?.()}
16128
16131
  },e.createElement(Gs,null,e.createElement(js,{forceMount:!0,
16129
16132
  className:"DialogOverlay",onClick:()=>{c&&s?.()}}),e.createElement(Us,{
16130
- forceMount:!0,className:`DialogContent ${a}`.trim(),isFullHeight:i,size:o,
16133
+ forceMount:!0,className:`DialogContent ${a??""}`.trim(),isFullHeight:i,size:o,
16131
16134
  placement:l},!r&&e.createElement(Ys,{asChild:!0},e.createElement($s,{
16132
16135
  "aria-label":"Close"},e.createElement(qn,{fill:u.colors.text.inverse}))),n)))
16133
16136
  },exports.Dropdown=tm,
@@ -16140,7 +16143,7 @@ exports.InputLabel=Cn,
16140
16143
  exports.Loader=em,exports.Menu=Tl,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,{
16141
16144
  open:t,onOpenChange:e=>{e||l?.()}},e.createElement(sm,null,e.createElement(um,{
16142
16145
  forceMount:!0,className:"DialogOverlay",onClick:()=>l?.()}),e.createElement(dm,{
16143
- forceMount:!0,className:`DialogContent ${a}`.trim(),size:s??"default",
16146
+ forceMount:!0,className:`DialogContent ${a??""}`.trim(),size:s??"default",
16144
16147
  fullWidth:o,align:r,position:c,style:i
16145
16148
  },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})=>{
16146
16149
  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({
@@ -16189,7 +16192,7 @@ index:r})
16189
16192
  fill:R.colors.common.accent})))})))),E&&_&&e.createElement(vc,null,_))
16190
16193
  },exports.Popover=yP,
16191
16194
  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,{
16192
- className:`RadioGroupRoot ${n}`.trim(),id:a,name:l,"aria-label":i,
16195
+ className:`RadioGroupRoot ${n??""}`.trim(),id:a,name:l,"aria-label":i,
16193
16196
  value:t?"default":"",required:o,disabled:r,"aria-readonly":c,...s
16194
16197
  },e.createElement(MP,null,e.createElement(zP,{checked:t,"aria-checked":t,
16195
16198
  className:"RadioGroupItem",disabled:r,"aria-readonly":c,value:"default",
package/index.js CHANGED
@@ -2163,7 +2163,7 @@ variant:"primary","aria-disabled":s,disabled:s,onClick:()=>a?.(),"aria-label":u
2163
2163
  const u=vn();return t.createElement(vu,{open:e,onOpenChange:e=>{e||s?.()}
2164
2164
  },t.createElement(gu,null,t.createElement(hu,{forceMount:!0,
2165
2165
  className:"DialogOverlay",onClick:()=>{c&&s?.()}}),t.createElement(pu,{
2166
- forceMount:!0,className:`DialogContent ${a}`.trim(),isFullHeight:i,size:o,
2166
+ forceMount:!0,className:`DialogContent ${a??""}`.trim(),isFullHeight:i,size:o,
2167
2167
  placement:l},!r&&t.createElement(mu,{asChild:!0},t.createElement(fu,{
2168
2168
  "aria-label":"Close"},t.createElement(mr,{fill:u.colors.text.inverse}))),n)))}
2169
2169
  ;function bu(e,[t,n]){return Math.min(n,Math.max(t,e))}
@@ -3484,11 +3484,12 @@ hm.stateChangeTypes=cm;const pm=En.textarea`
3484
3484
  outline: unset;
3485
3485
  padding: unset;
3486
3486
  margin: unset;
3487
- color: ${({theme:e})=>e.colors.text.primary};
3488
3487
  line-height: ${({theme:e})=>e.typography.primary.lineHeight};
3489
3488
  font-weight: ${({theme:e})=>e.typography.primary.fontWeight};
3490
3489
  font-size: ${({theme:e})=>e.typography.primary.fontSize};
3491
3490
  font-family: ${({theme:e})=>e.typography.fontFamily};
3491
+ background-color: ${({theme:e})=>e.colors.fill.surface};
3492
+ color: ${({theme:e})=>e.colors.text.primary};
3492
3493
  &::placeholder {
3493
3494
  font-family: ${({theme:e})=>e.typography.fontFamily};
3494
3495
  font-size: ${({theme:e})=>e.typography.primary.fontSize};
@@ -3508,6 +3509,8 @@ hm.stateChangeTypes=cm;const pm=En.textarea`
3508
3509
  font-weight: ${({theme:e})=>e.typography.primary.fontWeight};
3509
3510
  font-size: ${({theme:e})=>e.typography.primary.fontSize};
3510
3511
  font-family: ${({theme:e})=>e.typography.fontFamily};
3512
+ background-color: ${({theme:e})=>e.colors.fill.surface};
3513
+ color: ${({theme:e})=>e.colors.text.primary};
3511
3514
  &::placeholder {
3512
3515
  font-family: ${({theme:e})=>e.typography.fontFamily};
3513
3516
  font-size: ${({theme:e})=>e.typography.primary.fontSize};
@@ -3613,7 +3616,7 @@ className:"input-label","aria-label":a,htmlFor:o
3613
3616
  },a,d&&t.createElement(jn,null,"*"))),t.createElement(Fd,{open:x,defaultOpen:M,
3614
3617
  name:f,required:d,disabled:u,value:b?.[r]??void 0,onValueChange:e=>{if(s)return
3615
3618
  ;const t=i.find((t=>t?.[r]===e));l?.(t??null)}},t.createElement(eh,{
3616
- className:`SelectTrigger ${g||""}`.trim(),"aria-label":"Food",disabled:u,id:o,
3619
+ className:`SelectTrigger ${g??""}`.trim(),"aria-label":"Food",disabled:u,id:o,
3617
3620
  isErrored:!!w,"aria-invalid":!!w,width:v,style:y},t.createElement(jd,{
3618
3621
  className:"SelectValue",placeholder:c}),t.createElement(Jd,{
3619
3622
  className:"SelectIcon"},t.createElement(nc,{fill:n.colors.text.primary
@@ -3627,9 +3630,9 @@ className:"SelectScrollButton"},t.createElement(nc,{fill:n.colors.text.primary
3627
3630
  },e.key,t.createElement(Yd,null)),e.items.map(((e,n)=>{
3628
3631
  const a="string"==typeof e?e:e?.[r],o=e?.[r]??""
3629
3632
  ;return o&&""!==o||console.warn("No value for item",e),
3630
- t.createElement(t.Fragment,null,m?m(e,{key:a,value:o||a.trim,
3631
- disabled:!!e.disabled,showTick:h}):t.createElement(Lm,{key:a,value:o||a,
3632
- disabled:!!e.disabled,showTick:h},p(e,"list-item")))})))))),t.createElement(Qd,{
3633
+ t.createElement(t.Fragment,null,m?m(e,{key:a,value:o??a,disabled:!!e.disabled,
3634
+ showTick:h}):t.createElement(Lm,{key:a,value:o||a,disabled:!!e.disabled,
3635
+ showTick:h},p(e,"list-item")))})))))),t.createElement(Qd,{
3633
3636
  className:"SelectScrollButton"},t.createElement(nc,{fill:n.colors.text.primary
3634
3637
  })))))),w&&z&&t.createElement(Oc,null,z))
3635
3638
  },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})=>{
@@ -3791,7 +3794,7 @@ default:"512px",small:"424px",medium:"600px",large:"800px","x-large":"1200px"
3791
3794
  `,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,{
3792
3795
  open:e,onOpenChange:e=>{e||l?.()}},t.createElement(Pm,null,t.createElement(Im,{
3793
3796
  forceMount:!0,className:"DialogOverlay",onClick:()=>l?.()}),t.createElement(Rm,{
3794
- forceMount:!0,className:`DialogContent ${a}`.trim(),size:s??"default",
3797
+ forceMount:!0,className:`DialogContent ${a??""}`.trim(),size:s??"default",
3795
3798
  fullWidth:o,align:r,position:c,style:i},n))),Nm=En.div`
3796
3799
  flex: 1;
3797
3800
  gap: 8px;
@@ -12508,7 +12511,7 @@ return t.createElement(_m,{items:n,
12508
12511
  itemToString:(t,n)=>"list-item"===n?t?.name??"":"months"===e.name&&t?.name?vI?.[t?.name?.toString().toLowerCase()]:t?.name??"",
12509
12512
  type:"button",disabled:!!e.disabled,
12510
12513
  defaultSelectedItem:n.find((t=>t.id===e.value))??null,style:e.style,
12511
- className:`${e.className} bp-custom-dropdown bp-custom-dropdown-${e.name}`.trim(),
12514
+ className:`${e.className??""} bp-custom-dropdown bp-custom-dropdown-${e.name??""}`.trim(),
12512
12515
  onChange:t=>{e?.onChange?.({target:{value:t?.id}})}})}
12513
12516
  return t.createElement(_m,{itemToString:()=>"",type:"button"})},yI=e=>{
12514
12517
  const{placeholder:n,name:r,isRequired:a,label:o,isErrored:i,errorText:l,id:c,disabled:s,displayFormat:u="YYYY-MM-DD",...d}=e
@@ -12737,7 +12740,7 @@ onInteractOutside:()=>u&&u(),side:g,align:o,sideOffset:8,avoidCollisions:l
12737
12740
  display: flex;
12738
12741
  align-items: center;
12739
12742
  `,rR=({checked:e,className:n,disabled:r,id:a,isRequired:o,label:i,name:l,readOnly:c,...s})=>t.createElement(JI,{
12740
- className:`RadioGroupRoot ${n}`.trim(),id:a,name:l,"aria-label":i,
12743
+ className:`RadioGroupRoot ${n??""}`.trim(),id:a,name:l,"aria-label":i,
12741
12744
  value:e?"default":"",required:o,disabled:r,"aria-readonly":c,...s
12742
12745
  },t.createElement(nR,null,t.createElement(tR,{checked:e,"aria-checked":e,
12743
12746
  className:"RadioGroupItem",disabled:r,"aria-readonly":c,value:"default",
@@ -15834,7 +15837,7 @@ d:"M8 0C3.58172 0 0 3.58172 0 8C0 12.4183 3.58172 16 8 16C12.4183 16 16 12.4183
15834
15837
  fill:n.colors.text.semantic.error}))},kj=({index:e,...n})=>{
15835
15838
  const r=vn(),{updateToasts:a,windowState:o}=t.useContext(NB)??{},i=t.useRef(null)
15836
15839
  ;return t.createElement(t.Fragment,null,t.createElement(zj,{ref:i,
15837
- toastType:n.type,toastIndex:e,className:`ToastRoot Toast-${n.id}`.trim(),
15840
+ toastType:n.type,toastIndex:e,className:`ToastRoot Toast-${n.id??""}`.trim(),
15838
15841
  duration:n.delay??3e3,onOpenChange:e=>{e||a((e=>e.filter((e=>e.id!==n.id))))}
15839
15842
  },t.createElement(_j,{className:"ToastProgress",windowState:o,toastType:n.type,
15840
15843
  delay:n.delay??3e3
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "freemium-ui",
3
- "version": "2.0.0-beta.30",
3
+ "version": "2.0.0-beta.31",
4
4
  "description": "React Ui Components for Freemium Apps",
5
5
  "main": "./index.js",
6
6
  "module": "./index.js",