import{d as e,l as t,s as n,t as r}from"./hooks.module-BrXTvcfS.js";import{A as i,k as a}from"./content_renderer-DOj8g78V.js";import{h as o}from"./i18n-BaLR3UdQ.js";import{t as s}from"./jsxRuntime.module-Cao1NCKs.js";import{o as c}from"./react_utils-Bz0ffU2Y.js";import{J as l}from"./hooks-ClTXKdUl.js";import{t as u}from"./ImageViewer-BRYZ_kar.js";import{t as d}from"./SiblingNavigator-C50Tef4q.js";e();var f=[`Backspace`],p=[`Space`];function m({note:e,ntxId:m,noteContext:h}){let g=r(null),[_,v]=n(0);return t(()=>a.setupContextMenu(c(g)),[]),l(`copyImageReferenceToClipboard`,({ntxId:e})=>{if(e!==m)return;let t=c(g).find(`img`);t.length&&i(t.parent())}),l(`entitiesReloaded`,({loadResults:t})=>{t.isNoteReloaded(e.noteId)&&v(e=>e+1)}),s(`div`,{ref:g,className:`note-detail-image-wrapper`,children:[s(u,{imgClassName:`note-detail-image-view`,src:o(e),alt:e.title},`${e.noteId}-${_}`),s(d,{note:e,noteContext:h,previousTooltipI18nKey:`image_navigation.previous`,nextTooltipI18nKey:`image_navigation.next`,extraPreviousKeys:f,extraNextKeys:p})]})}export{m as default};