import{R as l}from"./vendor-ClLR6ncd.js";import{E as d,f as m,i as s}from"./index-OtVJl4GC.js";import"./lodash-ZyeDnt0e.js";function i(r){return!r||r.includes("(devel)")}function u(){return d(["backend-version"],async()=>{const[r,n,o,e]=await Promise.all([s({url:"/version/full"}),s({url:"/version"}),s({url:"/version/date"}),s({url:"/version/revision"})]);return{version:r,shortVersion:n,date:o,revision:e,isReleaseVersion:!i(r)}})}const c=(r,n,o)=>{const e=i(r)?"current":n;return`https://franz.com${m("/agraph/support/documentation",e,o)}`};function f(r){var o,e;const n=u();return c((o=n.data)==null?void 0:o.version,(e=n.data)==null?void 0:e.shortVersion,r)}function h(){var n,o;const r=u();return l.useCallback(e=>{var t,a;return c((t=r.data)==null?void 0:t.version,(a=r.data)==null?void 0:a.shortVersion,e)},[(n=r.data)==null?void 0:n.shortVersion,(o=r.data)==null?void 0:o.version])}export{u as a,h as b,f as u};
