import{n as e}from"./rolldown-runtime-CMxvf4Kt.js";import{D as t,E as n,T as r,w as i}from"./vendor-C4JLrdLj.js";import{x as a,y as o}from"./ws-JRT2XE7Y.js";var s,c,l,u,d,f,p,m=e((()=>{s=`../packages/audio/schemas/patch.schema.json`,c=`Minimal`,l=`Raphael Salaja`,u=`1.0.0`,d=`An ultra-clean sine-based palette for quiet, transparent UI feedback, made for products that prioritize subtlety, restraint, and smooth interaction cues over expressive flourish.`,f={tap:{source:{type:`sine`,frequency:1200},envelope:{attack:0,decay:.012,sustain:0,release:.004},gain:.08},click:{source:{type:`sine`,frequency:800},envelope:{attack:0,decay:.015,sustain:0,release:.005},gain:.1},"key-press":{source:{type:`sine`,frequency:1100},envelope:{attack:0,decay:.01,sustain:0,release:.003},gain:.06},"toggle-on":{layers:[{source:{type:`sine`,frequency:880},envelope:{attack:0,decay:.02,sustain:0,release:.006},gain:.08},{source:{type:`sine`,frequency:1320},envelope:{attack:0,decay:.02,sustain:0,release:.006},delay:.03,gain:.07}]},"toggle-off":{layers:[{source:{type:`sine`,frequency:1320},envelope:{attack:0,decay:.02,sustain:0,release:.006},gain:.08},{source:{type:`sine`,frequency:880},envelope:{attack:0,decay:.02,sustain:0,release:.006},delay:.03,gain:.07}]},checkbox:{source:{type:`sine`,frequency:1e3},envelope:{attack:0,decay:.018,sustain:0,release:.005},gain:.09},select:{source:{type:`sine`,frequency:1100},envelope:{attack:0,decay:.02,sustain:0,release:.006},gain:.08},deselect:{source:{type:`sine`,frequency:900},envelope:{attack:0,decay:.018,sustain:0,release:.005},gain:.06},hover:{source:{type:`sine`,frequency:1300},envelope:{attack:0,decay:.01,sustain:0,release:.004},gain:.04},"tab-switch":{source:{type:`sine`,frequency:1050},envelope:{attack:0,decay:.015,sustain:0,release:.005},gain:.07},expand:{source:{type:`sine`,frequency:{start:800,end:1e3}},envelope:{attack:0,decay:.04,sustain:0,release:.012},gain:.06},collapse:{source:{type:`sine`,frequency:{start:1e3,end:800}},envelope:{attack:0,decay:.04,sustain:0,release:.012},gain:.06},"page-enter":{source:{type:`sine`,frequency:{start:700,end:900}},envelope:{attack:.003,decay:.04,sustain:0,release:.015},gain:.05},"page-exit":{source:{type:`sine`,frequency:{start:900,end:700}},envelope:{attack:0,decay:.04,sustain:0,release:.015},gain:.04},success:{layers:[{source:{type:`sine`,frequency:523},envelope:{attack:0,decay:.05,sustain:0,release:.015},gain:.1},{source:{type:`sine`,frequency:784},envelope:{attack:0,decay:.05,sustain:0,release:.015},delay:.06,gain:.08}]},error:{layers:[{source:{type:`sine`,frequency:300},envelope:{attack:0,decay:.04,sustain:0,release:.012},gain:.12},{source:{type:`sine`,frequency:280},envelope:{attack:0,decay:.04,sustain:0,release:.012},delay:.01,gain:.1}]},warning:{layers:[{source:{type:`sine`,frequency:440},envelope:{attack:0,decay:.03,sustain:0,release:.01},gain:.1},{source:{type:`sine`,frequency:466},envelope:{attack:0,decay:.03,sustain:0,release:.01},delay:.008,gain:.08}]},notification:{layers:[{source:{type:`sine`,frequency:660},envelope:{attack:0,decay:.05,sustain:0,release:.02},gain:.1},{source:{type:`sine`,frequency:880},envelope:{attack:0,decay:.04,sustain:0,release:.015},delay:.08,gain:.08}]},info:{source:{type:`sine`,frequency:880},envelope:{attack:0,decay:.04,sustain:0,release:.015},gain:.08},copy:{layers:[{source:{type:`sine`,frequency:1e3},envelope:{attack:0,decay:.012,sustain:0,release:.004},gain:.08},{source:{type:`sine`,frequency:1200},envelope:{attack:0,decay:.012,sustain:0,release:.004},delay:.035,gain:.07}]},send:{source:{type:`sine`,frequency:{start:600,end:1e3}},envelope:{attack:0,decay:.04,sustain:0,release:.012},gain:.08},delete:{source:{type:`sine`,frequency:{start:500,end:250}},envelope:{attack:0,decay:.05,sustain:0,release:.015},gain:.1},undo:{source:{type:`sine`,frequency:{start:800,end:600}},envelope:{attack:0,decay:.035,sustain:0,release:.01},gain:.07},pop:{source:{type:`sine`,frequency:{start:400,end:200}},envelope:{attack:0,decay:.04,sustain:0,release:.012},gain:.1},swoosh:{source:{type:`sine`,frequency:{start:600,end:1400}},envelope:{attack:.005,decay:.04,sustain:0,release:.015},gain:.05},slide:{source:{type:`sine`,frequency:{start:800,end:1100}},envelope:{attack:.003,decay:.035,sustain:0,release:.012},gain:.05}},p={$schema:s,name:c,author:l,version:u,description:d,sounds:f}}));function h(){y||(y=i(p),r().catch(()=>{}))}function g(e){e!==b&&(b=e,t(e))}function _(e){let t=o().accessibility?.sounds;if(!t?.enabled||e===`hover`&&!t.hoverEnabled)return;let n=typeof performance<`u`?performance.now():Date.now();if(e===`slide-tick`){if(n-x<40)return;x=n}if(e===`hover`){if(n-S<60)return;S=n}h(),g(Math.min(1,Math.max(0,t.volume??.4)));let r=v[e],i=y;if(i)try{i.play(r)}catch{}}var v,y,b,x,S,C=e((()=>{n(),m(),a(),v={click:`click`,"switch-on":`toggle-on`,"switch-off":`toggle-off`,"slide-tick":`tap`,hover:`hover`,"tab-switch":`tab-switch`,expand:`expand`,collapse:`collapse`},y=null,b=-1,x=0,S=0}));export{_ as n,C as t};