{"version":3,"file":"chunk-454WOBUV-5rTpxkNE.js","sources":["../../node_modules/@storybook/addon-actions/dist/chunk-454WOBUV.mjs"],"sourcesContent":["import { v4 } from 'uuid';\nimport { addons } from 'storybook/internal/preview-api';\nimport { global } from '@storybook/global';\nimport { ImplicitActionsDuringRendering } from 'storybook/internal/preview-errors';\n\nvar PARAM_KEY=\"actions\",ADDON_ID=\"storybook/actions\",PANEL_ID=`${ADDON_ID}/panel`,EVENT_ID=`${ADDON_ID}/action-event`,CLEAR_ID=`${ADDON_ID}/action-clear`,CYCLIC_KEY=\"$___storybook.isCyclic\";var config={depth:10,clearOnStoryChange:!0,limit:50},configureActions=(options={})=>{Object.assign(config,options);};var findProto=(obj,callback)=>{let proto=Object.getPrototypeOf(obj);return !proto||callback(proto)?proto:findProto(proto,callback)},isReactSyntheticEvent=e=>!!(typeof e==\"object\"&&e&&findProto(e,proto=>/^Synthetic(?:Base)?Event$/.test(proto.constructor.name))&&typeof e.persist==\"function\"),serializeArg=a=>{if(isReactSyntheticEvent(a)){let e=Object.create(a.constructor.prototype,Object.getOwnPropertyDescriptors(a));e.persist();let viewDescriptor=Object.getOwnPropertyDescriptor(e,\"view\"),view=viewDescriptor?.value;return typeof view==\"object\"&&view?.constructor.name===\"Window\"&&Object.defineProperty(e,\"view\",{...viewDescriptor,value:Object.create(view.constructor.prototype)}),e}return a},generateId=()=>typeof crypto==\"object\"&&typeof crypto.getRandomValues==\"function\"?v4():Date.now().toString(36)+Math.random().toString(36).substring(2);function action(name,options={}){let actionOptions={...config,...options},handler=function(...args){if(options.implicit){let storyRenderer=(\"__STORYBOOK_PREVIEW__\"in global?global.__STORYBOOK_PREVIEW__:void 0)?.storyRenders.find(render=>render.phase===\"playing\"||render.phase===\"rendering\");if(storyRenderer){let deprecated=!window?.FEATURES?.disallowImplicitActionsInRenderV8,error=new ImplicitActionsDuringRendering({phase:storyRenderer.phase,name,deprecated});if(deprecated)console.warn(error);else throw error}}let channel=addons.getChannel(),id=generateId(),minDepth=5,serializedArgs=args.map(serializeArg),normalizedArgs=args.length>1?serializedArgs:serializedArgs[0],actionDisplayToEmit={id,count:0,data:{name,args:normalizedArgs},options:{...actionOptions,maxDepth:minDepth+(actionOptions.depth||3),allowFunction:actionOptions.allowFunction||!1}};channel.emit(EVENT_ID,actionDisplayToEmit);};return handler.isAction=!0,handler.implicit=options.implicit,handler}var actions=(...args)=>{let options=config,names=args;names.length===1&&Array.isArray(names[0])&&([names]=names),names.length!==1&&typeof names[names.length-1]!=\"string\"&&(options={...config,...names.pop()});let namesObject=names[0];(names.length!==1||typeof namesObject==\"string\")&&(namesObject={},names.forEach(name=>{namesObject[name]=name;}));let actionsObject={};return Object.keys(namesObject).forEach(name=>{actionsObject[name]=action(namesObject[name],options);}),actionsObject};\n\nexport { ADDON_ID, CLEAR_ID, CYCLIC_KEY, EVENT_ID, PANEL_ID, PARAM_KEY, action, actions, config, configureActions };\n"],"names":["addons","global","ImplicitActionsDuringRendering","PARAM_KEY","ADDON_ID","EVENT_ID","config","findProto","obj","callback","proto","isReactSyntheticEvent","serializeArg","a","e","viewDescriptor","view","generateId","v4","action","name","options","actionOptions","handler","args","storyRenderer","_a","render","deprecated","_b","error","channel","id","minDepth","serializedArgs","normalizedArgs","actionDisplayToEmit","actions","names","namesObject","actionsObject"],"mappings":"qCACA,KAAA,CAAA,OAAAA,CAAA,EAAA,iCACA,CAAA,OAAAC,CAAA,EAAA,4BACA,CAAA,+BAAAC,CAAA,EAAA,gDAEG,IAACC,EAAU,UAAUC,EAAS,oBAAiDC,EAAS,GAAGD,CAAQ,gBAA4FE,EAAO,CAAC,MAAM,GAAG,mBAAmB,GAAG,MAAM,EAAE,EAAsEC,EAAU,CAACC,EAAIC,IAAW,CAAC,IAAIC,EAAM,OAAO,eAAeF,CAAG,EAAE,MAAO,CAACE,GAAOD,EAASC,CAAK,EAAEA,EAAMH,EAAUG,EAAMD,CAAQ,CAAC,EAAEE,EAAsB,GAAG,CAAC,EAAE,OAAO,GAAG,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