@crystaldesign/products-component 24.15.0-beta.39 → 24.15.0-beta.40

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@crystaldesign/products-component",
3
- "version": "24.15.0-beta.39",
3
+ "version": "24.15.0-beta.40",
4
4
  "license": "COMMERCIAL",
5
5
  "devDependencies": {
6
6
  "@testing-library/jest-dom": "^6.5.0",
@@ -20,5 +20,5 @@
20
20
  "main": "build/cjs/index.js",
21
21
  "module": "build/esm/index.js",
22
22
  "types": "./build/types/products-component/src/index.d.ts",
23
- "gitHead": "45f3df474b17e57a9242b3a6ffc171036f571461"
23
+ "gitHead": "ed900e671d4442ebd8a0dc07ebf3b1013fc20dce"
24
24
  }
@@ -1,2 +0,0 @@
1
- /*! For license information please see 113.products-component.umd.min.js.LICENSE.txt */
2
- "use strict";(self.webpackChunkCrystaldesignProductsComponent=self.webpackChunkCrystaldesignProductsComponent||[]).push([[113],{5113:(e,t,o)=>{o.d(t,{Z:()=>$});var a=o(7363),r=o(7726),n=o(4062),s=o(9074),i=o(1522),c=o(1684),l=o(7843);const d=function useControlled({controlled:e,default:t,name:o,state:r="value"}){const{current:n}=a.useRef(void 0!==e),[s,i]=a.useState(t);return[n?e:s,a.useCallback((e=>{n||i(e)}),[])]};const p=a.createContext(void 0);var u=o(189),h=o(3966),m=o(431);function getSwitchBaseUtilityClass(e){return(0,m.ZP)("PrivateSwitchBase",e)}(0,h.Z)("PrivateSwitchBase",["root","checked","disabled","input","edgeStart","edgeEnd"]);var v=o(7514);const b=(0,l.ZP)(u.Z)({padding:9,borderRadius:"50%",variants:[{props:{edge:"start",size:"small"},style:{marginLeft:-3}},{props:({edge:e,ownerState:t})=>"start"===e&&"small"!==t.size,style:{marginLeft:-12}},{props:{edge:"end",size:"small"},style:{marginRight:-3}},{props:({edge:e,ownerState:t})=>"end"===e&&"small"!==t.size,style:{marginRight:-12}}]}),k=(0,l.ZP)("input",{shouldForwardProp:c.Z})({cursor:"inherit",position:"absolute",opacity:0,width:"100%",height:"100%",top:0,left:0,margin:0,padding:0,zIndex:1}),f=a.forwardRef((function SwitchBase(e,t){const{autoFocus:o,checked:s,checkedIcon:c,className:l,defaultChecked:u,disabled:h,disableFocusRipple:m=!1,edge:f=!1,icon:g,id:C,inputProps:x,inputRef:y,name:Z,onBlur:z,onChange:S,onFocus:w,readOnly:R,required:P=!1,tabIndex:B,type:F,value:$,...j}=e,[I,O]=d({controlled:s,default:Boolean(u),name:"SwitchBase",state:"checked"}),M=function useFormControl(){return a.useContext(p)}();let H=h;M&&void 0===H&&(H=M.disabled);const N="checkbox"===F||"radio"===F,q={...e,checked:I,disabled:H,disableFocusRipple:m,edge:f},E=(e=>{const{classes:t,checked:o,disabled:a,edge:r}=e,s={root:["root",o&&"checked",a&&"disabled",r&&`edge${(0,i.Z)(r)}`],input:["input"]};return(0,n.Z)(s,getSwitchBaseUtilityClass,t)})(q);return(0,v.jsxs)(b,{component:"span",className:(0,r.Z)(E.root,l),centerRipple:!0,focusRipple:!m,disabled:H,tabIndex:null,role:void 0,onFocus:e=>{w&&w(e),M&&M.onFocus&&M.onFocus(e)},onBlur:e=>{z&&z(e),M&&M.onBlur&&M.onBlur(e)},ownerState:q,ref:t,...j,children:[(0,v.jsx)(k,{autoFocus:o,checked:s,defaultChecked:u,className:E.input,disabled:H,id:N?C:void 0,name:Z,onChange:e=>{if(e.nativeEvent.defaultPrevented)return;const t=e.target.checked;O(t),S&&S(e,t)},readOnly:R,ref:y,required:P,ownerState:q,tabIndex:B,type:F,..."checkbox"===F&&void 0===$?{}:{value:$},...x}),I?c:g]})}));var g=o(6177);const C=(0,g.Z)((0,v.jsx)("path",{d:"M19 5v14H5V5h14m0-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z"}),"CheckBoxOutlineBlank"),x=(0,g.Z)((0,v.jsx)("path",{d:"M19 3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.11 0 2-.9 2-2V5c0-1.1-.89-2-2-2zm-9 14l-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8l-9 9z"}),"CheckBox"),y=(0,g.Z)((0,v.jsx)("path",{d:"M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-2 10H7v-2h10v2z"}),"IndeterminateCheckBox");function getCheckboxUtilityClass(e){return(0,m.ZP)("MuiCheckbox",e)}const Z=(0,h.Z)("MuiCheckbox",["root","checked","disabled","indeterminate","colorPrimary","colorSecondary","sizeSmall","sizeMedium"]);var z=o(518),S=o(8981),w=o(2893);const R=(0,l.ZP)(f,{shouldForwardProp:e=>(0,c.Z)(e)||"classes"===e,name:"MuiCheckbox",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:o}=e;return[t.root,o.indeterminate&&t.indeterminate,t[`size${(0,i.Z)(o.size)}`],"default"!==o.color&&t[`color${(0,i.Z)(o.color)}`]]}})((0,z.Z)((({theme:e})=>({color:(e.vars||e).palette.text.secondary,variants:[{props:{color:"default",disableRipple:!1},style:{"&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette.action.activeChannel} / ${e.vars.palette.action.hoverOpacity})`:(0,s.Fq)(e.palette.action.active,e.palette.action.hoverOpacity)}}},...Object.entries(e.palette).filter((0,S.Z)()).map((([t])=>({props:{color:t,disableRipple:!1},style:{"&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette[t].mainChannel} / ${e.vars.palette.action.hoverOpacity})`:(0,s.Fq)(e.palette[t].main,e.palette.action.hoverOpacity)}}}))),...Object.entries(e.palette).filter((0,S.Z)()).map((([t])=>({props:{color:t},style:{[`&.${Z.checked}, &.${Z.indeterminate}`]:{color:(e.vars||e).palette[t].main},[`&.${Z.disabled}`]:{color:(e.vars||e).palette.action.disabled}}}))),{props:{disableRipple:!1},style:{"&:hover":{"@media (hover: none)":{backgroundColor:"transparent"}}}}]})))),P=(0,v.jsx)(x,{}),B=(0,v.jsx)(C,{}),F=(0,v.jsx)(y,{}),$=a.forwardRef((function Checkbox(e,t){const o=(0,w.i)({props:e,name:"MuiCheckbox"}),{checkedIcon:s=P,color:c="primary",icon:l=B,indeterminate:d=!1,indeterminateIcon:p=F,inputProps:u,size:h="medium",disableRipple:m=!1,className:b,...k}=o,f=d?p:l,g=d?p:s,C={...o,disableRipple:m,color:c,indeterminate:d,size:h},x=(e=>{const{classes:t,indeterminate:o,color:a,size:r}=e,s={root:["root",o&&"indeterminate",`color${(0,i.Z)(a)}`,`size${(0,i.Z)(r)}`]},c=(0,n.Z)(s,getCheckboxUtilityClass,t);return{...t,...c}})(C);return(0,v.jsx)(R,{type:"checkbox",inputProps:{"data-indeterminate":d,...u},icon:a.cloneElement(f,{fontSize:f.props.fontSize??h}),checkedIcon:a.cloneElement(g,{fontSize:g.props.fontSize??h}),ownerState:C,ref:t,className:(0,r.Z)(x.root,b),disableRipple:m,...k,classes:x})}))}}]);
@@ -1 +0,0 @@
1
- /*! filename:113 */