import{s as p,b0 as m,b1 as l,j as s,d as o,R as j}from"./index-Dz5JRQhj.js";const d=({image:c,projectName:e,disabledReason:t})=>{const r=p(),{canCreateInstances:n}=m(),{data:a}=l(e),i=()=>{r(`${j}/ui/project/${encodeURIComponent(e)}/instances/create`,{state:{selectedImage:c,cancelLocation:window.location.pathname}})},u=()=>n(a)?t||"Create instance":"You do not have permission to create instances";return s.jsx(o.Button,{appearance:"base",onClick:i,type:"button",title:u(),hasIcon:!0,disabled:!!t||!n(a),children:s.jsx(o.Icon,{name:"play"})})};export{d as C};
