{"version":3,"file":"memoTheme.mjs","sources":["../../../../../../../../node_modules/@mui/system/esm/memoTheme.js"],"sourcesContent":["import preprocessStyles from \"./preprocessStyles.js\";\n\n/* eslint-disable @typescript-eslint/naming-convention */\n\n// We need to pass an argument as `{ theme }` for PigmentCSS, but we don't want to\n// allocate more objects.\nconst arg = {\n  theme: undefined\n};\n\n/**\n * Memoize style function on theme.\n * Intended to be used in styled() calls that only need access to the theme.\n */\nexport default function unstable_memoTheme(styleFn) {\n  let lastValue;\n  let lastTheme;\n  return function styleMemoized(props) {\n    let value = lastValue;\n    if (value === undefined || props.theme !== lastTheme) {\n      arg.theme = props.theme;\n      value = preprocessStyles(styleFn(arg));\n      lastValue = value;\n      lastTheme = props.theme;\n    }\n    return value;\n  };\n}"],"names":[],"mappings":";;AAEA;;AAEA;AACA;AACA,MAAM,GAAG,GAAG;AACZ,EAAE,KAAK,EAAE;AACT,CAAC;;AAED;AACA;AACA;AACA;AACe,SAAS,kBAAkB,CAAC,OAAO,EAAE;AACpD,EAAE,IAAI,SAAS;AACf,EAAE,IAAI,SAAS;AACf,EAAE,OAAO,SAAS,aAAa,CAAC,KAAK,EAAE;AACvC,IAAI,IAAI,KAAK,GAAG,SAAS;AACzB,IAAI,IAAI,KAAK,KAAK,SAAS,IAAI,KAAK,CAAC,KAAK,KAAK,SAAS,EAAE;AAC1D,MAAM,GAAG,CAAC,KAAK,GAAG,KAAK,CAAC,KAAK;AAC7B,MAAM,KAAK,GAAG,gBAAgB,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC;AAC5C,MAAM,SAAS,GAAG,KAAK;AACvB,MAAM,SAAS,GAAG,KAAK,CAAC,KAAK;AAC7B,IAAI;AACJ,IAAI,OAAO,KAAK;AAChB,EAAE,CAAC;AACH;;;;","x_google_ignoreList":[0]}