mirror of
https://github.com/idanoo/GoScrobble.git
synced 2024-11-25 09:55:15 +00:00
1 line
2.1 KiB
JSON
1 line
2.1 KiB
JSON
|
{"ast":null,"code":"import * as React from 'react';\n/**\n * Private module reserved for @material-ui/x packages.\n */\n\nexport default function useId(idOverride) {\n var _React$useState = React.useState(idOverride),\n defaultId = _React$useState[0],\n setDefaultId = _React$useState[1];\n\n var id = idOverride || defaultId;\n React.useEffect(function () {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the random value for client-side rendering only.\n // We can't use it server-side.\n setDefaultId(\"mui-\".concat(Math.round(Math.random() * 1e5)));\n }\n }, [defaultId]);\n return id;\n}","map":{"version":3,"sources":["/app/node_modules/@material-ui/core/esm/utils/unstable_useId.js"],"names":["React","useId","idOverride","_React$useState","useState","defaultId","setDefaultId","id","useEffect","concat","Math","round","random"],"mappings":"AAAA,OAAO,KAAKA,KAAZ,MAAuB,OAAvB;AACA;AACA;AACA;;AAEA,eAAe,SAASC,KAAT,CAAeC,UAAf,EAA2B;AACxC,MAAIC,eAAe,GAAGH,KAAK,CAACI,QAAN,CAAeF,UAAf,CAAtB;AAAA,MACIG,SAAS,GAAGF,eAAe,CAAC,CAAD,CAD/B;AAAA,MAEIG,YAAY,GAAGH,eAAe,CAAC,CAAD,CAFlC;;AAIA,MAAII,EAAE,GAAGL,UAAU,IAAIG,SAAvB;AACAL,EAAAA,KAAK,CAACQ,SAAN,CAAgB,YAAY;AAC1B,QAAIH,SAAS,IAAI,IAAjB,EAAuB;AACrB;AACA;AACA;AACAC,MAAAA,YAAY,CAAC,OAAOG,MAAP,CAAcC,IAAI,CAACC,KAAL,CAAWD,IAAI,CAACE,MAAL,KAAgB,GAA3B,CAAd,CAAD,CAAZ;AACD;AACF,GAPD,EAOG,CAACP,SAAD,CAPH;AAQA,SAAOE,EAAP;AACD","sourcesContent":["import * as React from 'react';\n/**\n * Private module reserved for @material-ui/x packages.\n */\n\nexport default function useId(idOverride) {\n var _React$useState = React.useState(idOverride),\n defaultId = _React$useState[0],\n setDefaultId = _React$useState[1];\n\n var id = idOverride || defaultId;\n React.useEffect(function () {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the random value for client-side rendering only.\n // We can't use it server-side.\n setDefaultId(\"mui-\".concat(Math.round(Math.random() * 1e5)));\n }\n }, [defaultId]);\n return id;\n}"]},"metadata":{},"sourceType":"module"}
|