nuxt-og-image 3.0.0-rc.65 → 3.0.0-rc.67
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +67 -67
- package/dist/client/200.html +222 -213
- package/dist/client/404.html +222 -213
- package/dist/client/_nuxt/{D33OKbkv.js → 0OCEc-sb.js} +1 -1
- package/dist/client/_nuxt/16nqZaIT.js +1 -0
- package/dist/client/_nuxt/3Ts0ZrM4.js +4 -0
- package/dist/client/_nuxt/44JOqR_V.js +1 -0
- package/dist/client/_nuxt/4FkZXfg1.js +3 -0
- package/dist/client/_nuxt/4WleZr1P.js +1 -0
- package/dist/client/_nuxt/5HixFuyr.js +1 -0
- package/dist/client/_nuxt/5bRVBCrv.js +1 -0
- package/dist/client/_nuxt/{CMDmr8et.js → 7LPQ6a13.js} +2 -2
- package/dist/client/_nuxt/8WiSp-0_.js +1 -0
- package/dist/client/_nuxt/9CfBjzQa.js +1 -0
- package/dist/client/_nuxt/B-9EjyZr.js +1 -0
- package/dist/client/_nuxt/B-a2BbyY.js +1 -0
- package/dist/client/_nuxt/B0LoMq2b.js +1 -0
- package/dist/client/_nuxt/B1ejXUAS.js +1 -0
- package/dist/client/_nuxt/{BR6CMsBL.js → B3LRAdDP.js} +1 -1
- package/dist/client/_nuxt/B3a86pAO.js +1 -0
- package/dist/client/_nuxt/B5La0Eyp.js +1 -0
- package/dist/client/_nuxt/B7-FEXAT.js +1 -0
- package/dist/client/_nuxt/B9HI_aQy.js +1 -0
- package/dist/client/_nuxt/B9vFkdfw.js +1 -0
- package/dist/client/_nuxt/BAGvEKUB.js +1 -0
- package/dist/client/_nuxt/BAp2aEeE.js +1 -0
- package/dist/client/_nuxt/BB9S_66N.js +1 -0
- package/dist/client/_nuxt/BC7ivatP.js +1 -0
- package/dist/client/_nuxt/{CJQrLysU.js → BCOu96sC.js} +1 -1
- package/dist/client/_nuxt/BD3t3nJY.js +1 -0
- package/dist/client/_nuxt/BDJ7po1j.js +1 -0
- package/dist/client/_nuxt/BGk6HrHT.js +1 -0
- package/dist/client/_nuxt/BHSTd-7M.js +1 -0
- package/dist/client/_nuxt/BKFBoKT4.js +1 -0
- package/dist/client/_nuxt/BKNiEhql.js +1 -0
- package/dist/client/_nuxt/BLmvGqlk.js +1 -0
- package/dist/client/_nuxt/BMRpS3Xo.js +1 -0
- package/dist/client/_nuxt/BMkdSFOr.js +1 -0
- package/dist/client/_nuxt/BNgG76gt.js +1 -0
- package/dist/client/_nuxt/BNofkYSZ.js +165 -0
- package/dist/client/_nuxt/BOp3HRET.js +1 -0
- package/dist/client/_nuxt/BPhJoBd6.js +1 -0
- package/dist/client/_nuxt/{DGDuLtS6.js → BQnHL-cn.js} +1 -8
- package/dist/client/_nuxt/BS9sT-GQ.js +1 -0
- package/dist/client/_nuxt/BU83OF-G.js +1 -0
- package/dist/client/_nuxt/BUeIC4cT.js +1 -0
- package/dist/client/_nuxt/BXP-NDAE.js +1 -0
- package/dist/client/_nuxt/BXUVD3TH.js +1 -0
- package/dist/client/_nuxt/BXWtGw2n.js +6 -0
- package/dist/client/_nuxt/BYLuaE_S.js +3 -0
- package/dist/client/_nuxt/BYelj_cE.js +1 -0
- package/dist/client/_nuxt/B_Sdu6N9.js +1 -0
- package/dist/client/_nuxt/{BXfENWL6.js → Ba_2pva2.js} +1 -1
- package/dist/client/_nuxt/BeX7BQ1y.js +1 -0
- package/dist/client/_nuxt/{CThH5sBG.js → BfVRrWqI.js} +1 -1
- package/dist/client/_nuxt/BgEvnnZj.js +1 -0
- package/dist/client/_nuxt/{DKb4lQY2.js → Bgrlo6mM.js} +1 -1
- package/dist/client/_nuxt/{CdedUr_-.js → BiVAY1KT.js} +1 -1
- package/dist/client/_nuxt/Bl6w8nq6.js +29 -0
- package/dist/client/_nuxt/BmUjtHPt.js +1 -0
- package/dist/client/_nuxt/BnYPtiAB.js +1 -0
- package/dist/client/_nuxt/{B9S9BZZh.js → BotTw_1M.js} +1 -1
- package/dist/client/_nuxt/BpDWT_aG.js +1 -0
- package/dist/client/_nuxt/BpqPLH6b.js +1 -0
- package/dist/client/_nuxt/{ChMCFiS0.js → Br4herk8.js} +1 -1
- package/dist/client/_nuxt/Brmco9EZ.js +2 -0
- package/dist/client/_nuxt/Bs9WCFOo.js +1 -0
- package/dist/client/_nuxt/BtPWTO6-.js +1 -0
- package/dist/client/_nuxt/BuqjW-Uc.js +1 -0
- package/dist/client/_nuxt/BwUg_Rem.js +1 -0
- package/dist/client/_nuxt/Bxuka25Y.js +1 -0
- package/dist/client/_nuxt/{DsfXcHUZ.js → BxwkrKyP.js} +1 -27
- package/dist/client/_nuxt/ByN1NmdT.js +11 -0
- package/dist/client/_nuxt/C2Z2wNnw.js +1 -0
- package/dist/client/_nuxt/{CarfVElc.js → C3wf4cjV.js} +1 -54
- package/dist/client/_nuxt/C5J_9lw5.js +1 -0
- package/dist/client/_nuxt/C6doOGgB.js +1 -0
- package/dist/client/_nuxt/C7n-thn-.js +1 -0
- package/dist/client/_nuxt/C7xspq5a.js +1 -0
- package/dist/client/_nuxt/C8DXlOXe.js +1 -0
- package/dist/client/_nuxt/C9CNr0dZ.js +1 -0
- package/dist/client/_nuxt/CA2blNRc.js +1 -0
- package/dist/client/_nuxt/CCW61mLD.js +1 -0
- package/dist/client/_nuxt/CDNnVXJ3.js +1 -0
- package/dist/client/_nuxt/CDP-pALJ.js +1 -0
- package/dist/client/_nuxt/{JgH_6NEN.js → CFy8Z7mU.js} +1 -1
- package/dist/client/_nuxt/CHDuk4cg.js +1 -0
- package/dist/client/_nuxt/{DGEpfOTx.js → CJYoS41Z.js} +1 -1
- package/dist/client/_nuxt/CKK8qrH7.js +3 -0
- package/dist/client/_nuxt/CKqhLkpw.js +1 -0
- package/dist/client/_nuxt/CLTURUqp.js +9 -0
- package/dist/client/_nuxt/CPQn-Lhb.js +1 -0
- package/dist/client/_nuxt/CPw9RxLe.js +1 -0
- package/dist/client/_nuxt/CRUEGcu5.js +1 -0
- package/dist/client/_nuxt/{BN4LRXf6.js → CS6sTstm.js} +1 -1
- package/dist/client/_nuxt/{BVLuctcA.js → CSPPpfsQ.js} +1 -1
- package/dist/client/_nuxt/CTeQKLZv.js +1 -0
- package/dist/client/_nuxt/CTsPJjdJ.js +1 -0
- package/dist/client/_nuxt/{CsYA0RN7.js → CUNQUWO_.js} +1 -1
- package/dist/client/_nuxt/CV5B5C80.js +1 -0
- package/dist/client/_nuxt/CZkFsSlX.js +1 -0
- package/dist/client/_nuxt/C_g069vW.js +1 -0
- package/dist/client/_nuxt/{DZqG9GXz.js → C_h5G2He.js} +1 -31
- package/dist/client/_nuxt/CaR_I2C-.js +1 -0
- package/dist/client/_nuxt/Cb48SAmt.js +1 -0
- package/dist/client/_nuxt/{BmCW-tYz.js → CeIpHJfZ.js} +4 -78
- package/dist/client/_nuxt/{B9CT-1u6.js → CidHYXz9.js} +1 -7
- package/dist/client/_nuxt/{beD-FUib.js → ClPxYbPx.js} +1 -1
- package/dist/client/_nuxt/Clj_IpB8.js +1 -0
- package/dist/client/_nuxt/CmN1UzhW.js +1 -0
- package/dist/client/_nuxt/Crs1WKlG.js +1 -0
- package/dist/client/_nuxt/{KPqz0Sb3.js → CsW3I34-.js} +1 -1
- package/dist/client/_nuxt/CsuMf1xJ.js +1 -0
- package/dist/client/_nuxt/Ctb_e1-I.js +1 -0
- package/dist/client/_nuxt/CvHWZNAB.js +1 -0
- package/dist/client/_nuxt/CyUS7F7b.js +17 -0
- package/dist/client/_nuxt/Cz-n9WvF.js +1 -0
- package/dist/client/_nuxt/{CrhH3_Og.js → Cz3ygVR-.js} +1 -1
- package/dist/client/_nuxt/{sQpxpyUs.js → CzK8D06Z.js} +1 -1
- package/dist/client/_nuxt/{B1nm99XP.js → D0N_qbs7.js} +1 -1
- package/dist/client/_nuxt/D0pnavP-.js +1 -0
- package/dist/client/_nuxt/D25Gr2Wc.js +1 -0
- package/dist/client/_nuxt/D46m5Xd3.js +1 -0
- package/dist/client/_nuxt/D4miJ1xw.js +1 -0
- package/dist/client/_nuxt/D5lQfeOG.js +1 -0
- package/dist/client/_nuxt/D6oCKXcX.js +1 -0
- package/dist/client/_nuxt/D8V69RRQ.js +1 -0
- package/dist/client/_nuxt/DBLgxP_1.js +2 -0
- package/dist/client/_nuxt/{ByMv4Xf1.js → DCmDdbvy.js} +1 -1
- package/dist/client/_nuxt/DDG_rSGg.js +8 -0
- package/dist/client/_nuxt/{CX_FIdg1.js → DDK5Hw8n.js} +1 -1
- package/dist/client/_nuxt/DFHN_7lU.js +3 -0
- package/dist/client/_nuxt/DFaziNDp.js +1 -0
- package/dist/client/_nuxt/DFsxFixh.js +1 -0
- package/dist/client/_nuxt/DGhhRy1e.js +1 -0
- package/dist/client/_nuxt/{DdacRhvC.js → DIw1DfnK.js} +1 -1
- package/dist/client/_nuxt/DJNHLfzP.js +1 -0
- package/dist/client/_nuxt/{I4qd5QHW.js → DJOPMAPO.js} +5 -5
- package/dist/client/_nuxt/DKgh9jPU.js +20 -0
- package/dist/client/_nuxt/DO04iIl4.js +1 -0
- package/dist/client/_nuxt/DOOuMSMh.js +1 -0
- package/dist/client/_nuxt/DQ-rpzxz.js +1 -0
- package/dist/client/_nuxt/DRuVOcqL.js +1 -0
- package/dist/client/_nuxt/DSmiUmWA.js +1 -0
- package/dist/client/_nuxt/DSv7Jr7N.js +5 -0
- package/dist/client/_nuxt/DTMFIK7w.js +1 -0
- package/dist/client/_nuxt/DV9_Ze0W.js +1 -0
- package/dist/client/_nuxt/{6XBPEST2.js → DXdsTRaC.js} +1 -1
- package/dist/client/_nuxt/{DouzTJIq.js → DXtfa3TF.js} +1 -1
- package/dist/client/_nuxt/DYgwfmdY.js +1 -0
- package/dist/client/_nuxt/DYikCEmq.js +1 -0
- package/dist/client/_nuxt/{8t4jSAMm.js → DYrknm32.js} +1 -1
- package/dist/client/_nuxt/D_lsq3cR.js +1 -0
- package/dist/client/_nuxt/D_nC6SfZ.js +1 -0
- package/dist/client/_nuxt/Dc3u8CCo.js +1 -0
- package/dist/client/_nuxt/Df4vQnuo.js +1 -0
- package/dist/client/_nuxt/Di1G_BEd.js +1 -0
- package/dist/client/_nuxt/Dk2kDqHs.js +1 -0
- package/dist/client/_nuxt/DkIL16gc.js +2 -0
- package/dist/client/_nuxt/DmixpzPA.js +1 -0
- package/dist/client/_nuxt/Dnd6U92I.js +25 -0
- package/dist/client/_nuxt/DofIr7ih.js +1 -0
- package/dist/client/_nuxt/DqFtmHIk.js +1 -0
- package/dist/client/_nuxt/{Bh8mriwU.js → DrUHIbQf.js} +1 -17
- package/dist/client/_nuxt/{6Kuza3Wr.js → DrhOmAGa.js} +1 -1
- package/dist/client/_nuxt/DsO5WfEU.js +1 -0
- package/dist/client/_nuxt/DsclqnHy.js +4 -0
- package/dist/client/_nuxt/Dwk9V841.js +1 -0
- package/dist/client/_nuxt/DyLIn2qo.js +1 -0
- package/dist/client/_nuxt/{C9d3aiqh.js → DzhYcJWo.js} +1 -1
- package/dist/client/_nuxt/Dziqk49f.js +1 -0
- package/dist/client/_nuxt/E5r7Moxb.js +16 -0
- package/dist/client/_nuxt/{B_SUYfiV.js → FMRyFT8D.js} +1 -1
- package/dist/client/_nuxt/GACPk8cj.js +16 -0
- package/dist/client/_nuxt/H94RPpLS.js +1 -0
- package/dist/client/_nuxt/{DBxHOdLe.js → HxmVvryO.js} +1 -1
- package/dist/client/_nuxt/JYC31MTV.js +1 -0
- package/dist/client/_nuxt/Jl0QvYgb.js +1 -0
- package/dist/client/_nuxt/{BeX7Iu5M.js → KA8c-whL.js} +1 -90
- package/dist/client/_nuxt/KN-DOLVO.js +1 -0
- package/dist/client/_nuxt/Ka_J5llu.js +1 -0
- package/dist/client/_nuxt/KuNYkU7X.js +1 -0
- package/dist/client/_nuxt/MkuNFWFs.js +204 -0
- package/dist/client/_nuxt/{BaedD2tq.js → N3zwmhmW.js} +1 -1
- package/dist/client/_nuxt/O4cDyHwR.js +1 -0
- package/dist/client/_nuxt/OPd3ySAa.js +1 -0
- package/dist/client/_nuxt/Opso89zU.js +16 -0
- package/dist/client/_nuxt/P3XzCKkX.js +1 -0
- package/dist/client/_nuxt/PBlC1IT3.js +1 -0
- package/dist/client/_nuxt/PauOf_jS.js +1 -0
- package/dist/client/_nuxt/Qj0mFepl.js +14 -0
- package/dist/client/_nuxt/R9SNgiQ9.js +1 -0
- package/dist/client/_nuxt/{C6XIsc4F.js → Rc0-bMtX.js} +1 -1
- package/dist/client/_nuxt/TYaudu4O.js +1 -0
- package/dist/client/_nuxt/VRCUJX8G.js +1 -0
- package/dist/client/_nuxt/{BH1M7C1g.js → VntNkNt1.js} +1 -1
- package/dist/client/_nuxt/{C_8Fx7bH.js → Ys9ZunwU.js} +1 -1
- package/dist/client/_nuxt/bEygH-WE.js +3 -0
- package/dist/client/_nuxt/builds/latest.json +1 -1
- package/dist/client/_nuxt/builds/meta/4133e154-aafc-47ec-8a1d-f5919be391d9.json +1 -0
- package/dist/client/_nuxt/eJKZXzCK.js +1 -0
- package/dist/client/_nuxt/eQYbbmqd.js +16 -0
- package/dist/client/_nuxt/entry.DtsycVcr.css +1 -0
- package/dist/client/_nuxt/error-404.CUF_CFKB.css +1 -0
- package/dist/client/_nuxt/error-500.BR60owpQ.css +1 -0
- package/dist/client/_nuxt/gwSZkKbG.js +1 -0
- package/dist/client/_nuxt/i0hkWYmE.js +1 -0
- package/dist/client/_nuxt/ithPx4uF.js +1 -0
- package/dist/client/_nuxt/{CiRxTSAc.js → jDrCW69G.js} +1 -1
- package/dist/client/_nuxt/kveMaAK5.js +1 -0
- package/dist/client/_nuxt/lBoe4CZw.js +1 -0
- package/dist/client/_nuxt/{Bgpqy2XC.js → lPxKsdjn.js} +1 -1
- package/dist/client/_nuxt/lRZxrFTT.js +1 -0
- package/dist/client/_nuxt/mvTh5Gok.js +1 -0
- package/dist/client/_nuxt/pCnzZaOt.js +1 -0
- package/dist/client/_nuxt/qpF8edk8.js +1 -0
- package/dist/client/_nuxt/qvnQm5y7.js +1 -0
- package/dist/client/_nuxt/qwoaayiL.js +1 -0
- package/dist/client/_nuxt/t1S7pxBA.js +1 -0
- package/dist/client/_nuxt/t6MJYFCU.js +5 -0
- package/dist/client/_nuxt/tEd5xQ4M.js +1 -0
- package/dist/client/_nuxt/xGgVA17b.js +1 -0
- package/dist/client/_nuxt/{Bj5xdiaE.js → xuIuMB9j.js} +1 -1
- package/dist/client/_nuxt/yvfKceIB.js +1 -0
- package/dist/client/_nuxt/z5DqfkHR.js +1 -0
- package/dist/client/index.html +222 -213
- package/dist/module.d.mts +6 -2
- package/dist/module.d.ts +6 -2
- package/dist/module.json +2 -2
- package/dist/module.mjs +246 -131
- package/dist/runtime/nitro/og-image/bindings/chromium/chrome-launcher.js +1 -1
- package/dist/runtime/nitro/og-image/bindings/chromium/on-demand.js +1 -1
- package/dist/runtime/nitro/og-image/bindings/satori/wasm.js +1 -1
- package/dist/runtime/nitro/og-image/{cache.d.ts → cache/lru.d.ts} +3 -1
- package/dist/runtime/nitro/og-image/{cache.js → cache/lru.js} +6 -0
- package/dist/runtime/nitro/og-image/cache/mock.d.ts +9 -0
- package/dist/runtime/nitro/og-image/cache/mock.js +9 -0
- package/dist/runtime/nitro/og-image/chromium/renderer.js +1 -1
- package/dist/runtime/nitro/og-image/chromium/screenshot.js +1 -1
- package/dist/runtime/nitro/og-image/context.js +8 -8
- package/dist/runtime/nitro/og-image/satori/font.d.ts +1 -0
- package/dist/runtime/nitro/og-image/satori/font.js +2 -2
- package/dist/runtime/nitro/og-image/satori/instances.d.ts +1 -1
- package/dist/runtime/nitro/og-image/satori/plugins/encoding.js +1 -1
- package/dist/runtime/nitro/og-image/satori/plugins/flex.js +27 -2
- package/dist/runtime/nitro/og-image/satori/plugins/imageSrc.js +4 -4
- package/dist/runtime/nitro/og-image/satori/plugins/unocss.js +1 -1
- package/dist/runtime/nitro/og-image/satori/renderer.js +3 -7
- package/dist/runtime/nitro/og-image/satori/transforms/emojis.d.ts +0 -2
- package/dist/runtime/nitro/og-image/satori/transforms/emojis.js +1 -5
- package/dist/runtime/nitro/og-image/satori/transforms/inlineCss.js +1 -1
- package/dist/runtime/nitro/og-image/satori/vnodes.js +8 -8
- package/dist/runtime/nitro/og-image/templates/html.js +16 -21
- package/dist/runtime/nitro/plugins/__zero-runtime/nuxt-content.d.ts +2 -0
- package/dist/runtime/nitro/plugins/__zero-runtime/nuxt-content.js +9 -0
- package/dist/runtime/nitro/plugins/nuxt-content.js +2 -51
- package/dist/runtime/nitro/plugins/prerender.js +9 -4
- package/dist/runtime/nitro/routes/__zero-runtime/font.d.ts +2 -0
- package/dist/runtime/nitro/routes/__zero-runtime/font.js +8 -0
- package/dist/runtime/nitro/routes/__zero-runtime/image.d.ts +2 -0
- package/dist/runtime/nitro/routes/__zero-runtime/image.js +8 -0
- package/dist/runtime/nitro/routes/debug.json.js +2 -2
- package/dist/runtime/nitro/routes/font.js +3 -49
- package/dist/runtime/nitro/routes/image.js +3 -87
- package/dist/runtime/nitro/tsconfig.json +3 -3
- package/dist/runtime/nitro/util/cache.js +3 -3
- package/dist/runtime/nitro/util/eventHandlers.d.ts +3 -0
- package/dist/runtime/nitro/util/eventHandlers.js +155 -0
- package/dist/runtime/nitro/util/kit.d.ts +1 -1
- package/dist/runtime/nitro/util/kit.js +3 -3
- package/dist/runtime/nitro/util/plugins.d.ts +2 -0
- package/dist/runtime/nitro/util/plugins.js +54 -0
- package/dist/runtime/nuxt/components/OgImage/OgImage.d.ts +1 -3
- package/dist/runtime/nuxt/components/OgImage/OgImage.js +1 -1
- package/dist/runtime/nuxt/components/OgImage/OgImageScreenshot.d.ts +1 -3
- package/dist/runtime/nuxt/components/OgImage/OgImageScreenshot.js +1 -1
- package/dist/runtime/nuxt/components/Templates/Community/BrandedLogo.vue +29 -29
- package/dist/runtime/nuxt/components/Templates/Community/Frame.vue +64 -64
- package/dist/runtime/nuxt/components/Templates/Community/Nuxt.vue +185 -185
- package/dist/runtime/nuxt/components/Templates/Community/NuxtSeo.vue +137 -137
- package/dist/runtime/nuxt/components/Templates/Community/Pergel.vue +103 -103
- package/dist/runtime/nuxt/components/Templates/Community/SimpleBlog.vue +35 -35
- package/dist/runtime/nuxt/components/Templates/Community/UnJs.vue +108 -108
- package/dist/runtime/nuxt/components/Templates/Community/Wave.vue +34 -34
- package/dist/runtime/nuxt/components/Templates/Community/WithEmoji.vue +28 -28
- package/dist/runtime/nuxt/composables/defineOgImage.js +7 -5
- package/dist/runtime/nuxt/composables/defineOgImageComponent.d.ts +1 -1
- package/dist/runtime/nuxt/composables/mock.d.ts +1 -1
- package/dist/runtime/nuxt/plugins/__zero-runtime/og-image-canonical-urls.server.d.ts +2 -0
- package/dist/runtime/nuxt/plugins/__zero-runtime/og-image-canonical-urls.server.js +9 -0
- package/dist/runtime/nuxt/plugins/__zero-runtime/route-rule-og-image.server.d.ts +2 -0
- package/dist/runtime/nuxt/plugins/__zero-runtime/route-rule-og-image.server.js +9 -0
- package/dist/runtime/nuxt/plugins/og-image-canonical-urls.server.js +3 -51
- package/dist/runtime/nuxt/plugins/route-rule-og-image.server.js +4 -36
- package/dist/runtime/nuxt/utils/plugins.d.ts +3 -0
- package/dist/runtime/nuxt/utils/plugins.js +87 -0
- package/dist/runtime/nuxt/utils.js +6 -4
- package/dist/runtime/shared.js +3 -3
- package/dist/runtime/types.d.ts +6 -5
- package/dist/types.d.mts +0 -4
- package/dist/types.d.ts +0 -4
- package/package.json +56 -48
- package/virtual.d.ts +49 -49
- package/dist/client/_nuxt/-7WWnkdy.js +0 -517
- package/dist/client/_nuxt/0ooBkv16.js +0 -1
- package/dist/client/_nuxt/1Je9_Reo.js +0 -136
- package/dist/client/_nuxt/1rqFXsGc.js +0 -666
- package/dist/client/_nuxt/37ic6j3l.js +0 -1
- package/dist/client/_nuxt/3ghuYFLd.js +0 -1
- package/dist/client/_nuxt/9B1nZgL-.js +0 -1
- package/dist/client/_nuxt/9ZOzOPqN.js +0 -1
- package/dist/client/_nuxt/AgnqFTPX.js +0 -13
- package/dist/client/_nuxt/B3g-KkBK.js +0 -1
- package/dist/client/_nuxt/B4yE-MfL.js +0 -38
- package/dist/client/_nuxt/B6bHXiXE.js +0 -25
- package/dist/client/_nuxt/B7rNE5kf.js +0 -1
- package/dist/client/_nuxt/BB42E8aY.js +0 -186
- package/dist/client/_nuxt/BBBqETUW.js +0 -1
- package/dist/client/_nuxt/BBJYjQ0k.js +0 -1
- package/dist/client/_nuxt/BEjL32p1.js +0 -5754
- package/dist/client/_nuxt/BF6G6X0H.js +0 -1
- package/dist/client/_nuxt/BH_RS3WO.js +0 -1
- package/dist/client/_nuxt/BICIrM8O.js +0 -1
- package/dist/client/_nuxt/BIxS-Weu.js +0 -1
- package/dist/client/_nuxt/BLluXI4E.js +0 -1
- package/dist/client/_nuxt/BMHPAh1U.js +0 -2
- package/dist/client/_nuxt/BOpLLL-w.js +0 -1
- package/dist/client/_nuxt/BPiaQZfK.js +0 -1
- package/dist/client/_nuxt/BT9ZzGyQ.js +0 -69
- package/dist/client/_nuxt/BUpeXbsf.js +0 -25
- package/dist/client/_nuxt/BVGdgKAv.js +0 -1
- package/dist/client/_nuxt/BVkeqZ59.js +0 -1
- package/dist/client/_nuxt/BWKJ1FCf.js +0 -239
- package/dist/client/_nuxt/BXR915QZ.js +0 -32
- package/dist/client/_nuxt/BYdKNJ10.js +0 -1
- package/dist/client/_nuxt/BZfs-ost.js +0 -1
- package/dist/client/_nuxt/BZz1Hhek.js +0 -1
- package/dist/client/_nuxt/BaNxgKSR.js +0 -17
- package/dist/client/_nuxt/BacI6-DX.js +0 -40
- package/dist/client/_nuxt/Bbv8ARUV.js +0 -13
- package/dist/client/_nuxt/Bdt_eLrj.js +0 -756
- package/dist/client/_nuxt/BeJnKnI_.js +0 -544
- package/dist/client/_nuxt/Bg0wAK5a.js +0 -100
- package/dist/client/_nuxt/Bi43K_FX.js +0 -6
- package/dist/client/_nuxt/BiDE021q.js +0 -1
- package/dist/client/_nuxt/BigF1UXR.js +0 -1
- package/dist/client/_nuxt/Bj0fF4lQ.js +0 -1
- package/dist/client/_nuxt/BlxWTfDV.js +0 -699
- package/dist/client/_nuxt/BnyYJeap.js +0 -129
- package/dist/client/_nuxt/Br6ll-O0.js +0 -1
- package/dist/client/_nuxt/BscxmKrE.js +0 -8
- package/dist/client/_nuxt/Btshr8M_.js +0 -70
- package/dist/client/_nuxt/BwXNTs7T.js +0 -1
- package/dist/client/_nuxt/Bxkoe-BC.js +0 -1
- package/dist/client/_nuxt/C15OxdQ5.js +0 -1
- package/dist/client/_nuxt/C1DVX8_8.js +0 -831
- package/dist/client/_nuxt/C1yTBzia.js +0 -1
- package/dist/client/_nuxt/C2TBxDwV.js +0 -1
- package/dist/client/_nuxt/C3qJFuQy.js +0 -3
- package/dist/client/_nuxt/C3qUB5O8.js +0 -301
- package/dist/client/_nuxt/C6Aznpr-.js +0 -1
- package/dist/client/_nuxt/CApMHEaB.js +0 -1
- package/dist/client/_nuxt/CBPJd_fO.js +0 -1
- package/dist/client/_nuxt/CBWrHyXe.js +0 -580
- package/dist/client/_nuxt/CCqFro8U.js +0 -3
- package/dist/client/_nuxt/CEfge3mM.js +0 -1
- package/dist/client/_nuxt/CFF2d1j6.js +0 -1
- package/dist/client/_nuxt/CG4fK2Nq.js +0 -21
- package/dist/client/_nuxt/CJGKC1_q.js +0 -40
- package/dist/client/_nuxt/CJIaz0BQ.js +0 -76
- package/dist/client/_nuxt/CO5hpdkB.js +0 -1
- package/dist/client/_nuxt/CQUCfALx.js +0 -13
- package/dist/client/_nuxt/CSPeAESR.js +0 -1
- package/dist/client/_nuxt/C_ZPRiAj.js +0 -26
- package/dist/client/_nuxt/Cb-F_BZP.js +0 -1
- package/dist/client/_nuxt/CbViG2Xw.js +0 -74
- package/dist/client/_nuxt/CbYhyuC0.js +0 -505
- package/dist/client/_nuxt/CfPQhs6g.js +0 -7
- package/dist/client/_nuxt/Cgl53LJQ.js +0 -1
- package/dist/client/_nuxt/Cicx_DS6.js +0 -1
- package/dist/client/_nuxt/ClXEvkw9.js +0 -68
- package/dist/client/_nuxt/CowR2XfX.js +0 -1
- package/dist/client/_nuxt/Cp2HGa90.js +0 -353
- package/dist/client/_nuxt/CpAANOdC.js +0 -1
- package/dist/client/_nuxt/CqYeW6XZ.js +0 -1
- package/dist/client/_nuxt/CrgTADc5.js +0 -1
- package/dist/client/_nuxt/CsyrCbsw.js +0 -699
- package/dist/client/_nuxt/Cthz8VOO.js +0 -771
- package/dist/client/_nuxt/CuJfdYLG.js +0 -1
- package/dist/client/_nuxt/CupVZNk8.js +0 -25
- package/dist/client/_nuxt/CxrokwfH.js +0 -1
- package/dist/client/_nuxt/D384ylkT.js +0 -1
- package/dist/client/_nuxt/D4LaosRr.js +0 -1
- package/dist/client/_nuxt/D6pmzCqS.js +0 -1
- package/dist/client/_nuxt/D7WeZTai.js +0 -1
- package/dist/client/_nuxt/DAGYewaG.js +0 -559
- package/dist/client/_nuxt/DAP_O-zg.js +0 -1
- package/dist/client/_nuxt/DAVo6uMX.js +0 -1
- package/dist/client/_nuxt/DAfrLhwG.js +0 -1
- package/dist/client/_nuxt/DBeuZS66.js +0 -1
- package/dist/client/_nuxt/DC4hdoM9.js +0 -87
- package/dist/client/_nuxt/DC8MraHL.js +0 -666
- package/dist/client/_nuxt/DGO8GyiP.js +0 -1
- package/dist/client/_nuxt/DGxQkqYo.js +0 -1
- package/dist/client/_nuxt/DHmGyzbM.js +0 -109
- package/dist/client/_nuxt/DJZWsvj0.js +0 -1
- package/dist/client/_nuxt/DJubGRtk.js +0 -1
- package/dist/client/_nuxt/DK4oFTHQ.js +0 -200
- package/dist/client/_nuxt/DLP9ZvWb.js +0 -3
- package/dist/client/_nuxt/DM4HHECw.js +0 -1
- package/dist/client/_nuxt/DOHBU7tp.js +0 -1
- package/dist/client/_nuxt/DOtRmeXT.js +0 -1
- package/dist/client/_nuxt/DR5YgmI2.js +0 -1
- package/dist/client/_nuxt/DS9ZWoKD.js +0 -1
- package/dist/client/_nuxt/DSrLtGYv.js +0 -15
- package/dist/client/_nuxt/DSsji4Hu.js +0 -1
- package/dist/client/_nuxt/DV9JwLIa.js +0 -1
- package/dist/client/_nuxt/DVC_qXWv.js +0 -1
- package/dist/client/_nuxt/DVLwECkk.js +0 -1
- package/dist/client/_nuxt/DVfdqzEq.js +0 -1
- package/dist/client/_nuxt/DVxyIIKo.js +0 -1
- package/dist/client/_nuxt/DXFkqnOI.js +0 -816
- package/dist/client/_nuxt/DXT9h7v2.js +0 -1
- package/dist/client/_nuxt/DY7_9Ga-.js +0 -1
- package/dist/client/_nuxt/DYI1rfmx.js +0 -25
- package/dist/client/_nuxt/DZLoTQm4.js +0 -1
- package/dist/client/_nuxt/DbK06e1c.js +0 -21
- package/dist/client/_nuxt/Dble9ECP.js +0 -1
- package/dist/client/_nuxt/Dch3xQiY.js +0 -699
- package/dist/client/_nuxt/Dd6f7Z5P.js +0 -1
- package/dist/client/_nuxt/DfeQjIbs.js +0 -5
- package/dist/client/_nuxt/Dg0DGYq4.js +0 -14
- package/dist/client/_nuxt/DhFF74a2.js +0 -1
- package/dist/client/_nuxt/Dit6kIrv.js +0 -11
- package/dist/client/_nuxt/DmDrTTlz.js +0 -1
- package/dist/client/_nuxt/DrnZp123.js +0 -40
- package/dist/client/_nuxt/Du6_OKDb.js +0 -159
- package/dist/client/_nuxt/DvyTQcux.js +0 -1
- package/dist/client/_nuxt/Dwo2i-71.js +0 -1
- package/dist/client/_nuxt/DwuVtWc2.js +0 -518
- package/dist/client/_nuxt/DzwdaLuO.js +0 -223
- package/dist/client/_nuxt/ECt0lbkd.js +0 -16
- package/dist/client/_nuxt/Eh5U-gDp.js +0 -52
- package/dist/client/_nuxt/Ksn5IXup.js +0 -1
- package/dist/client/_nuxt/PWN5J14X.js +0 -1
- package/dist/client/_nuxt/PifQWv0n.js +0 -1
- package/dist/client/_nuxt/QZ3jNtnE.js +0 -515
- package/dist/client/_nuxt/RCJZWN-0.js +0 -81
- package/dist/client/_nuxt/RE3ujT-k.js +0 -1
- package/dist/client/_nuxt/RqY_Nz63.js +0 -1
- package/dist/client/_nuxt/Sfo2eW0G.js +0 -274
- package/dist/client/_nuxt/T9ysyp6P.js +0 -62
- package/dist/client/_nuxt/Urb1RsFe.js +0 -1
- package/dist/client/_nuxt/VQMr7AbF.js +0 -1
- package/dist/client/_nuxt/WfFM8TlZ.js +0 -1
- package/dist/client/_nuxt/builds/meta/5876a781-42f1-459e-a560-bbe16edad6b7.json +0 -1
- package/dist/client/_nuxt/cw46T5ID.js +0 -61
- package/dist/client/_nuxt/dIHJ9UdL.js +0 -1
- package/dist/client/_nuxt/eJfcURhx.js +0 -1
- package/dist/client/_nuxt/entry.BJu2ITzA.css +0 -1
- package/dist/client/_nuxt/error-404.B3wjZPBT.css +0 -1
- package/dist/client/_nuxt/error-500.Dxoa4Ooo.css +0 -1
- package/dist/client/_nuxt/i0IPvypD.js +0 -1
- package/dist/client/_nuxt/kuh6G-Sk.js +0 -9
- package/dist/client/_nuxt/nclm9rTJ.js +0 -266
- package/dist/client/_nuxt/vMsNTMhM.js +0 -5
- package/dist/client/_nuxt/wChcbJ1V.js +0 -37
- package/dist/client/_nuxt/xettH10j.js +0 -131
- package/dist/client/_nuxt/yX2IItqj.js +0 -1
package/dist/module.json
CHANGED
package/dist/module.mjs
CHANGED
|
@@ -1,20 +1,25 @@
|
|
|
1
1
|
import * as fs from 'node:fs';
|
|
2
2
|
import { existsSync } from 'node:fs';
|
|
3
3
|
import { readFile, writeFile } from 'node:fs/promises';
|
|
4
|
-
import { useNuxt, tryResolveModule, addTemplate,
|
|
4
|
+
import { useNuxt, tryResolveModule, addTemplate, useLogger, resolvePath, loadNuxtModuleInstance, createResolver, defineNuxtModule, addImports, addBuildPlugin, hasNuxtModule, addServerPlugin, addServerHandler, addComponentsDir, addComponent, addPlugin } from '@nuxt/kit';
|
|
5
|
+
import { defu } from 'defu';
|
|
5
6
|
import { assertSiteConfig, installNuxtSiteConfig } from 'nuxt-site-config-kit';
|
|
6
|
-
import { provider, env, isCI, isDevelopment } from 'std-env';
|
|
7
7
|
import { hash } from 'ohash';
|
|
8
|
-
import {
|
|
9
|
-
import { defu } from 'defu';
|
|
8
|
+
import { dirname, relative as relative$1, isAbsolute, basename } from 'pathe';
|
|
10
9
|
import { readPackageJSON } from 'pkg-types';
|
|
10
|
+
import { provider, env, isCI, isDevelopment } from 'std-env';
|
|
11
|
+
import { parseURL, parseQuery, withoutLeadingSlash } from 'ufo';
|
|
11
12
|
import { createStorage } from 'unstorage';
|
|
12
13
|
import fsDriver from 'unstorage/drivers/fs';
|
|
13
|
-
import {
|
|
14
|
+
import { createHash } from 'node:crypto';
|
|
14
15
|
import { ensureDependencyInstalled } from 'nypm';
|
|
15
|
-
import {
|
|
16
|
+
import { colorize } from 'consola/utils';
|
|
17
|
+
import { relative } from 'node:path';
|
|
16
18
|
import { onDevToolsInitialized, extendServerRpc } from '@nuxt/devtools-kit';
|
|
17
|
-
import {
|
|
19
|
+
import { pathToFileURL } from 'node:url';
|
|
20
|
+
import MagicString from 'magic-string';
|
|
21
|
+
import { stripLiteral } from 'strip-literal';
|
|
22
|
+
import { createUnplugin } from 'unplugin';
|
|
18
23
|
import { Launcher } from 'chrome-launcher';
|
|
19
24
|
import { $fetch } from 'ofetch';
|
|
20
25
|
|
|
@@ -148,8 +153,8 @@ async function applyNitroPresetCompatibility(nitroConfig, options) {
|
|
|
148
153
|
binding = compatibility[key];
|
|
149
154
|
if (key === "chromium" && binding === "node")
|
|
150
155
|
binding = "playwright";
|
|
151
|
-
if (key === "css-inline") {
|
|
152
|
-
if (binding === "node" && !hasCssInlineNode ||
|
|
156
|
+
if (key === "css-inline" && typeof binding === "string") {
|
|
157
|
+
if (binding === "node" && !hasCssInlineNode || ["wasm", "wasm-fs"].includes(binding) && !hasCssInlineWasm) {
|
|
153
158
|
binding = false;
|
|
154
159
|
}
|
|
155
160
|
}
|
|
@@ -191,51 +196,66 @@ function ensureDependencies(dep, nuxt = useNuxt()) {
|
|
|
191
196
|
}));
|
|
192
197
|
}
|
|
193
198
|
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
if (moduleEntry)
|
|
208
|
-
inlineOptions = moduleEntry[1];
|
|
209
|
-
if (nuxtModule.getOptions)
|
|
210
|
-
return nuxtModule.getOptions(inlineOptions, nuxt);
|
|
211
|
-
return inlineOptions;
|
|
212
|
-
}
|
|
213
|
-
function extendTypes(module, template) {
|
|
214
|
-
const nuxt = useNuxt();
|
|
215
|
-
const { resolve } = createResolver(import.meta.url);
|
|
216
|
-
addTemplate({
|
|
217
|
-
filename: `module/${module}.d.ts`,
|
|
218
|
-
getContents: async () => {
|
|
219
|
-
const typesPath = relative(resolve(nuxt.options.rootDir, nuxt.options.buildDir, "module"), resolve("runtime/types"));
|
|
220
|
-
const s = await template({ typesPath });
|
|
221
|
-
return `// Generated by ${module}
|
|
222
|
-
${s}
|
|
223
|
-
export {}
|
|
224
|
-
`;
|
|
225
|
-
}
|
|
226
|
-
});
|
|
227
|
-
nuxt.hooks.hook("prepare:types", ({ references }) => {
|
|
228
|
-
references.push({ path: resolve(nuxt.options.buildDir, `module/${module}.d.ts`) });
|
|
199
|
+
const logger = useLogger("@nuxtjs/og-image");
|
|
200
|
+
const gray = (s) => colorize("gray", s);
|
|
201
|
+
|
|
202
|
+
async function setupBuildHandler(config, resolve, nuxt = useNuxt()) {
|
|
203
|
+
nuxt.options.nitro.storage = nuxt.options.nitro.storage || {};
|
|
204
|
+
if (typeof config.runtimeCacheStorage === "object")
|
|
205
|
+
nuxt.options.nitro.storage["og-image"] = config.runtimeCacheStorage;
|
|
206
|
+
nuxt.hooks.hook("nitro:config", async (nitroConfig) => {
|
|
207
|
+
await applyNitroPresetCompatibility(nitroConfig, { compatibility: config.compatibility?.runtime, resolve });
|
|
208
|
+
nitroConfig.alias.electron = "unenv/runtime/mock/proxy-cjs";
|
|
209
|
+
nitroConfig.alias.bufferutil = "unenv/runtime/mock/proxy-cjs";
|
|
210
|
+
nitroConfig.alias["utf-8-validate"] = "unenv/runtime/mock/proxy-cjs";
|
|
211
|
+
nitroConfig.alias.queue = "unenv/runtime/mock/proxy-cjs";
|
|
229
212
|
});
|
|
230
|
-
nuxt.hooks.hook("nitro:
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
213
|
+
nuxt.hooks.hook("nitro:init", async (nitro) => {
|
|
214
|
+
nitro.hooks.hook("compiled", async (_nitro) => {
|
|
215
|
+
const target = resolveNitroPreset(_nitro.options);
|
|
216
|
+
const compatibility = getPresetNitroPresetCompatibility(target);
|
|
217
|
+
if (compatibility.wasm?.esmImport !== true)
|
|
218
|
+
return;
|
|
219
|
+
const configuredEntry = nitro.options.rollupConfig?.output.entryFileNames;
|
|
220
|
+
let serverEntry = resolve(_nitro.options.output.serverDir, typeof configuredEntry === "string" ? configuredEntry : "index.mjs");
|
|
221
|
+
const isCloudflarePagesOrModule = target === "cloudflare-pages" || target === "cloudflare-module";
|
|
222
|
+
if (isCloudflarePagesOrModule) {
|
|
223
|
+
serverEntry = [
|
|
224
|
+
resolve(dirname(serverEntry), "./chunks/wasm.mjs"),
|
|
225
|
+
resolve(dirname(serverEntry), "./chunks/_/wasm.mjs")
|
|
226
|
+
].filter(existsSync)[0] || serverEntry;
|
|
227
|
+
const routesPath = resolve(nitro.options.output.publicDir, "_routes.json");
|
|
228
|
+
const routes = await readFile(routesPath).then((buffer) => JSON.parse(buffer.toString()));
|
|
229
|
+
const preSize = routes.exclude.length;
|
|
230
|
+
routes.exclude = routes.exclude.filter((path2) => !path2.startsWith("/__og-image__/static"));
|
|
231
|
+
routes.exclude.push("/__og-image__/static/*");
|
|
232
|
+
if (preSize !== routes.exclude.length) {
|
|
233
|
+
logger.info(`Optimizing CloudFlare \`_routes.json\` for prerendered OG Images ${gray(`(${100 - Math.round(routes.exclude.length / preSize * 100)}% smaller)`)}`);
|
|
234
|
+
}
|
|
235
|
+
await writeFile(routesPath, JSON.stringify(routes, void 0, 2));
|
|
236
|
+
}
|
|
237
|
+
const contents = await readFile(serverEntry, "utf-8");
|
|
238
|
+
const resvgHash = await resolveFilePathSha1("@resvg/resvg-wasm/index_bg.wasm");
|
|
239
|
+
const yogaHash = await resolveFilePathSha1("yoga-wasm-web/dist/yoga.wasm");
|
|
240
|
+
const cssInlineHash = await resolveFilePathSha1("@css-inline/css-inline-wasm/index_bg.wasm");
|
|
241
|
+
const postfix = target === "vercel-edge" ? "?module" : "";
|
|
242
|
+
const path = isCloudflarePagesOrModule ? `../wasm/` : `./wasm/`;
|
|
243
|
+
await writeFile(serverEntry, contents.replaceAll('"@resvg/resvg-wasm/index_bg.wasm?module"', `"${path}index_bg-${resvgHash}.wasm${postfix}"`).replaceAll('"@css-inline/css-inline-wasm/index_bg.wasm?module"', `"${path}index_bg-${cssInlineHash}.wasm${postfix}"`).replaceAll('"yoga-wasm-web/dist/yoga.wasm?module"', `"${path}yoga-${yogaHash}.wasm${postfix}"`), { encoding: "utf-8" });
|
|
244
|
+
});
|
|
235
245
|
});
|
|
236
246
|
}
|
|
237
|
-
function
|
|
238
|
-
|
|
247
|
+
async function resolveFilePathSha1(path) {
|
|
248
|
+
const _path = await resolvePath(path);
|
|
249
|
+
return sha1(existsSync(_path) ? await readFile(_path) : path);
|
|
250
|
+
}
|
|
251
|
+
function sha1(source) {
|
|
252
|
+
return createHash("sha1").update(source).digest("hex").slice(0, 16);
|
|
253
|
+
}
|
|
254
|
+
|
|
255
|
+
function setupDevHandler(options, resolve, nuxt = useNuxt()) {
|
|
256
|
+
nuxt.hooks.hook("nitro:config", async (nitroConfig) => {
|
|
257
|
+
await applyNitroPresetCompatibility(nitroConfig, { compatibility: options.compatibility?.dev, resolve });
|
|
258
|
+
});
|
|
239
259
|
}
|
|
240
260
|
|
|
241
261
|
const DEVTOOLS_UI_ROUTE = "/__nuxt-og-image";
|
|
@@ -266,7 +286,7 @@ function setupDevToolsUI(options, resolve, nuxt = useNuxt()) {
|
|
|
266
286
|
onDevToolsInitialized(async () => {
|
|
267
287
|
const rpc = extendServerRpc("nuxt-og-image", {});
|
|
268
288
|
nuxt.hook("builder:watch", (e, path) => {
|
|
269
|
-
path = relative
|
|
289
|
+
path = relative(nuxt.options.srcDir, resolve(nuxt.options.srcDir, path));
|
|
270
290
|
if ((e === "change" || e.includes("link")) && path.startsWith("pages")) {
|
|
271
291
|
rpc.broadcast.refreshRouteData(path).catch(() => {
|
|
272
292
|
});
|
|
@@ -299,12 +319,6 @@ function setupDevToolsUI(options, resolve, nuxt = useNuxt()) {
|
|
|
299
319
|
});
|
|
300
320
|
}
|
|
301
321
|
|
|
302
|
-
function setupDevHandler(options, resolve, nuxt = useNuxt()) {
|
|
303
|
-
nuxt.hooks.hook("nitro:config", async (nitroConfig) => {
|
|
304
|
-
await applyNitroPresetCompatibility(nitroConfig, { compatibility: options.compatibility?.dev, resolve });
|
|
305
|
-
});
|
|
306
|
-
}
|
|
307
|
-
|
|
308
322
|
function setupGenerateHandler(options, resolve, nuxt = useNuxt()) {
|
|
309
323
|
nuxt.hooks.hook("nitro:config", async (nitroConfig) => {
|
|
310
324
|
await applyNitroPresetCompatibility(nitroConfig, {
|
|
@@ -343,48 +357,138 @@ function setupPrerenderHandler(options, resolve, nuxt = useNuxt()) {
|
|
|
343
357
|
});
|
|
344
358
|
}
|
|
345
359
|
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
if (
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
360
|
+
function isVue(id, opts = {}) {
|
|
361
|
+
const { search } = parseURL(decodeURIComponent(pathToFileURL(id).href));
|
|
362
|
+
if (id.endsWith(".vue") && !search) {
|
|
363
|
+
return true;
|
|
364
|
+
}
|
|
365
|
+
if (!search) {
|
|
366
|
+
return false;
|
|
367
|
+
}
|
|
368
|
+
const query = parseQuery(search);
|
|
369
|
+
if (query.nuxt_component) {
|
|
370
|
+
return false;
|
|
371
|
+
}
|
|
372
|
+
if (query.macro && (search === "?macro=true" || !opts.type || opts.type.includes("script"))) {
|
|
373
|
+
return true;
|
|
374
|
+
}
|
|
375
|
+
const type = "setup" in query ? "script" : query.type;
|
|
376
|
+
if (!("vue" in query) || opts.type && !opts.type.includes(type)) {
|
|
377
|
+
return false;
|
|
378
|
+
}
|
|
379
|
+
return true;
|
|
380
|
+
}
|
|
381
|
+
const JS_RE = /\.(?:[cm]?j|t)sx?$/;
|
|
382
|
+
function isJS(id) {
|
|
383
|
+
const { pathname } = parseURL(decodeURIComponent(pathToFileURL(id).href));
|
|
384
|
+
return JS_RE.test(pathname);
|
|
385
|
+
}
|
|
386
|
+
const TreeShakeComposablesPlugin = createUnplugin(() => {
|
|
387
|
+
const composableNames = [
|
|
388
|
+
"defineOgImage",
|
|
389
|
+
"defineOgImageComponent",
|
|
390
|
+
"defineOgImageScreenshot"
|
|
391
|
+
];
|
|
392
|
+
const regexp = `(^\\s*)(${composableNames.join("|")})(?=\\((?!\\) \\{))`;
|
|
393
|
+
const COMPOSABLE_RE = new RegExp(regexp, "m");
|
|
394
|
+
const COMPOSABLE_RE_GLOBAL = new RegExp(regexp, "gm");
|
|
395
|
+
return {
|
|
396
|
+
name: "nuxt-og-image:zero-runtime:transform",
|
|
397
|
+
enforce: "pre",
|
|
398
|
+
transformInclude(id) {
|
|
399
|
+
return isVue(id, { type: ["script"] }) || isJS(id);
|
|
400
|
+
},
|
|
401
|
+
transform(code, id) {
|
|
402
|
+
const s = new MagicString(code);
|
|
403
|
+
if (id.endsWith("components.islands.mjs")) {
|
|
404
|
+
for (const match of code.matchAll(/"OgImage.*": defineAsyncComponent\(.*\),?/g)) {
|
|
405
|
+
s.overwrite(match.index, match.index + match[0].length, "");
|
|
406
|
+
}
|
|
407
|
+
} else {
|
|
408
|
+
const strippedCode = stripLiteral(code);
|
|
409
|
+
if (!COMPOSABLE_RE.test(code)) {
|
|
410
|
+
return;
|
|
411
|
+
}
|
|
412
|
+
for (const match of strippedCode.matchAll(COMPOSABLE_RE_GLOBAL)) {
|
|
413
|
+
s.overwrite(match.index, match.index + match[0].length, `${match[1]} import.meta.prerender && ${match[2]}`);
|
|
414
|
+
}
|
|
371
415
|
}
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
416
|
+
if (s.hasChanged()) {
|
|
417
|
+
return {
|
|
418
|
+
code: s.toString(),
|
|
419
|
+
map: s.generateMap({ hires: true })
|
|
420
|
+
};
|
|
421
|
+
}
|
|
422
|
+
}
|
|
423
|
+
};
|
|
424
|
+
});
|
|
425
|
+
|
|
426
|
+
async function getNuxtModuleOptions(module, nuxt = useNuxt()) {
|
|
427
|
+
const moduleMeta = (typeof module === "string" ? { name: module } : await module.getMeta?.()) || {};
|
|
428
|
+
const { nuxtModule } = await loadNuxtModuleInstance(module, nuxt);
|
|
429
|
+
let moduleEntry;
|
|
430
|
+
for (const m of nuxt.options.modules) {
|
|
431
|
+
if (Array.isArray(m) && m.length >= 2) {
|
|
432
|
+
const _module = m[0];
|
|
433
|
+
const _moduleEntryName = typeof _module === "string" ? _module : (await _module.getMeta?.())?.name || "";
|
|
434
|
+
if (_moduleEntryName === moduleMeta.name)
|
|
435
|
+
moduleEntry = m;
|
|
436
|
+
}
|
|
437
|
+
}
|
|
438
|
+
let inlineOptions = {};
|
|
439
|
+
if (moduleEntry)
|
|
440
|
+
inlineOptions = moduleEntry[1];
|
|
441
|
+
if (nuxtModule.getOptions)
|
|
442
|
+
return nuxtModule.getOptions(inlineOptions, nuxt);
|
|
443
|
+
return inlineOptions;
|
|
444
|
+
}
|
|
445
|
+
function extendTypes(module, template) {
|
|
446
|
+
const nuxt = useNuxt();
|
|
447
|
+
const { resolve } = createResolver(import.meta.url);
|
|
448
|
+
addTemplate({
|
|
449
|
+
filename: `module/${module}.d.ts`,
|
|
450
|
+
getContents: async () => {
|
|
451
|
+
const typesPath = relative$1(resolve(nuxt.options.rootDir, nuxt.options.buildDir, "module"), resolve("runtime/types"));
|
|
452
|
+
const s = await template({ typesPath });
|
|
453
|
+
return `// Generated by ${module}
|
|
454
|
+
${s}
|
|
455
|
+
export {}
|
|
456
|
+
`;
|
|
457
|
+
}
|
|
458
|
+
});
|
|
459
|
+
nuxt.hooks.hook("prepare:types", ({ references }) => {
|
|
460
|
+
references.push({ path: resolve(nuxt.options.buildDir, `module/${module}.d.ts`) });
|
|
461
|
+
});
|
|
462
|
+
nuxt.hooks.hook("nitro:config", (config) => {
|
|
463
|
+
config.typescript = config.typescript || {};
|
|
464
|
+
config.typescript.tsConfig = config.typescript.tsConfig || {};
|
|
465
|
+
config.typescript.tsConfig.include = config.typescript.tsConfig.include || [];
|
|
466
|
+
config.typescript.tsConfig.include.push(`./module/${module}.d.ts`);
|
|
380
467
|
});
|
|
381
468
|
}
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
return sha1(existsSync(_path) ? await readFile(_path) : path);
|
|
469
|
+
function isNuxtGenerate(nuxt = useNuxt()) {
|
|
470
|
+
return nuxt.options._generate || nuxt.options.nitro.static || nuxt.options.nitro.preset === "static";
|
|
385
471
|
}
|
|
386
|
-
|
|
387
|
-
|
|
472
|
+
|
|
473
|
+
function normaliseFontInput(fonts) {
|
|
474
|
+
return fonts.map((f) => {
|
|
475
|
+
if (typeof f === "string") {
|
|
476
|
+
const [name, weight] = f.split(":");
|
|
477
|
+
return {
|
|
478
|
+
cacheKey: f,
|
|
479
|
+
name,
|
|
480
|
+
weight: weight || 400,
|
|
481
|
+
style: "normal",
|
|
482
|
+
path: void 0
|
|
483
|
+
};
|
|
484
|
+
}
|
|
485
|
+
return {
|
|
486
|
+
cacheKey: f.key || `${f.name}:${f.weight}`,
|
|
487
|
+
style: "normal",
|
|
488
|
+
weight: 400,
|
|
489
|
+
...f
|
|
490
|
+
};
|
|
491
|
+
});
|
|
388
492
|
}
|
|
389
493
|
|
|
390
494
|
const isUndefinedOrTruthy = (v) => typeof v === "undefined" || v !== false;
|
|
@@ -429,27 +533,6 @@ async function downloadFont(font, storage, mirror) {
|
|
|
429
533
|
return false;
|
|
430
534
|
}
|
|
431
535
|
|
|
432
|
-
function normaliseFontInput(fonts) {
|
|
433
|
-
return fonts.map((f) => {
|
|
434
|
-
if (typeof f === "string") {
|
|
435
|
-
const [name, weight] = f.split(":");
|
|
436
|
-
return {
|
|
437
|
-
cacheKey: f,
|
|
438
|
-
name,
|
|
439
|
-
weight: weight || 400,
|
|
440
|
-
style: "normal",
|
|
441
|
-
path: void 0
|
|
442
|
-
};
|
|
443
|
-
}
|
|
444
|
-
return {
|
|
445
|
-
cacheKey: f.key || `${f.name}:${f.weight}`,
|
|
446
|
-
style: "normal",
|
|
447
|
-
weight: 400,
|
|
448
|
-
...f
|
|
449
|
-
};
|
|
450
|
-
});
|
|
451
|
-
}
|
|
452
|
-
|
|
453
536
|
const module = defineNuxtModule({
|
|
454
537
|
meta: {
|
|
455
538
|
name: "nuxt-og-image",
|
|
@@ -494,9 +577,23 @@ const module = defineNuxtModule({
|
|
|
494
577
|
logger.warn("Nuxt OG Image is enabled but SSR is disabled.\n\nYou should enable SSR (`ssr: true`) or disable the module (`ogImage: { enabled: false }`).");
|
|
495
578
|
return;
|
|
496
579
|
}
|
|
497
|
-
nuxt.options.
|
|
580
|
+
nuxt.options.alias["#nuxt-og-image-utils"] = resolve("./runtime/shared");
|
|
581
|
+
nuxt.options.alias["#nuxt-og-image-cache"] = resolve("./runtime/nitro/og-image/cache/lru");
|
|
498
582
|
const preset = resolveNitroPreset(nuxt.options.nitro);
|
|
499
583
|
const targetCompatibility = getPresetNitroPresetCompatibility(preset);
|
|
584
|
+
if (config.zeroRuntime) {
|
|
585
|
+
config.compatibility = defu(config.compatibility, {
|
|
586
|
+
runtime: {
|
|
587
|
+
chromium: false,
|
|
588
|
+
// should already be false
|
|
589
|
+
satori: false
|
|
590
|
+
}
|
|
591
|
+
});
|
|
592
|
+
if (!nuxt.options.dev) {
|
|
593
|
+
addBuildPlugin(TreeShakeComposablesPlugin, { server: true, client: true, build: true });
|
|
594
|
+
nuxt.options.alias["#nuxt-og-image-cache"] = resolve("./runtime/nitro/og-image/cache/mock");
|
|
595
|
+
}
|
|
596
|
+
}
|
|
500
597
|
let isUsingSharp = false;
|
|
501
598
|
const userConfiguredExtension = config.defaults.extension;
|
|
502
599
|
const hasConfiguredJpegs = userConfiguredExtension && ["jpeg", "jpg"].includes(userConfiguredExtension);
|
|
@@ -560,8 +657,9 @@ const module = defineNuxtModule({
|
|
|
560
657
|
}
|
|
561
658
|
});
|
|
562
659
|
await installNuxtSiteConfig();
|
|
563
|
-
if (hasNuxtModule("@nuxt/content"))
|
|
660
|
+
if (hasNuxtModule("@nuxt/content")) {
|
|
564
661
|
addServerPlugin(resolve("./runtime/nitro/plugins/nuxt-content"));
|
|
662
|
+
}
|
|
565
663
|
if (!config.fonts.length) {
|
|
566
664
|
config.fonts = [
|
|
567
665
|
{ name: "Inter", weight: 400, path: resolve("./runtime/assets/Inter-400.ttf.base64"), absolutePath: true },
|
|
@@ -610,13 +708,22 @@ const module = defineNuxtModule({
|
|
|
610
708
|
}
|
|
611
709
|
return f;
|
|
612
710
|
}))).filter(Boolean);
|
|
613
|
-
|
|
614
|
-
|
|
711
|
+
const fontKeys = config.fonts.map((f) => f.key?.split(":").pop());
|
|
712
|
+
const fontStorageKeys = await fontStorage.keys();
|
|
713
|
+
await Promise.all(fontStorageKeys.filter((key) => !fontKeys.includes(key)).map(async (key) => {
|
|
714
|
+
logger.info(`Nuxt OG Image removing outdated cached font file \`${key}\``);
|
|
715
|
+
await fontStorage.removeItem(key);
|
|
716
|
+
}));
|
|
717
|
+
if (!config.zeroRuntime) {
|
|
718
|
+
nuxt.options.nitro.serverAssets = nuxt.options.nitro.serverAssets || [];
|
|
719
|
+
nuxt.options.nitro.serverAssets.push({ baseName: "nuxt-og-image:fonts", dir: serverFontsDir });
|
|
720
|
+
}
|
|
615
721
|
nuxt.options.experimental.componentIslands = true;
|
|
722
|
+
const basePath = config.zeroRuntime ? "./runtime/nitro/routes/__zero-runtime" : "./runtime/nitro/routes";
|
|
616
723
|
addServerHandler({
|
|
617
724
|
lazy: true,
|
|
618
725
|
route: "/__og-image__/font/**",
|
|
619
|
-
handler: resolve(
|
|
726
|
+
handler: resolve(`${basePath}/font`)
|
|
620
727
|
});
|
|
621
728
|
if (config.debug || nuxt.options.dev) {
|
|
622
729
|
addServerHandler({
|
|
@@ -628,7 +735,12 @@ const module = defineNuxtModule({
|
|
|
628
735
|
addServerHandler({
|
|
629
736
|
lazy: true,
|
|
630
737
|
route: "/__og-image__/image/**",
|
|
631
|
-
handler: resolve(
|
|
738
|
+
handler: resolve(`${basePath}/image`)
|
|
739
|
+
});
|
|
740
|
+
addServerHandler({
|
|
741
|
+
lazy: true,
|
|
742
|
+
route: "/__og-image__/static/**",
|
|
743
|
+
handler: resolve(`${basePath}/image`)
|
|
632
744
|
});
|
|
633
745
|
nuxt.options.optimization.treeShake.composables.client["nuxt-og-image"] = [];
|
|
634
746
|
["defineOgImage", "defineOgImageComponent", "defineOgImageScreenshot"].forEach((name2) => {
|
|
@@ -638,11 +750,13 @@ const module = defineNuxtModule({
|
|
|
638
750
|
});
|
|
639
751
|
nuxt.options.optimization.treeShake.composables.client["nuxt-og-image"].push(name2);
|
|
640
752
|
});
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
753
|
+
if (!config.zeroRuntime || nuxt.options.dev) {
|
|
754
|
+
await addComponentsDir({
|
|
755
|
+
path: resolve("./runtime/nuxt/components/Templates/Community"),
|
|
756
|
+
island: true
|
|
757
|
+
// watch: true,
|
|
758
|
+
});
|
|
759
|
+
}
|
|
646
760
|
[
|
|
647
761
|
// new
|
|
648
762
|
"OgImage",
|
|
@@ -654,8 +768,9 @@ const module = defineNuxtModule({
|
|
|
654
768
|
...config.componentOptions
|
|
655
769
|
});
|
|
656
770
|
});
|
|
657
|
-
|
|
658
|
-
addPlugin({ mode: "server", src: resolve(
|
|
771
|
+
const basePluginPath = `./runtime/nuxt/plugins${config.zeroRuntime ? "/__zero-runtime" : ""}`;
|
|
772
|
+
addPlugin({ mode: "server", src: resolve(`${basePluginPath}/route-rule-og-image.server`) });
|
|
773
|
+
addPlugin({ mode: "server", src: resolve(`${basePluginPath}/og-image-canonical-urls.server`) });
|
|
659
774
|
const ogImageComponentCtx = { components: [] };
|
|
660
775
|
nuxt.hook("components:extend", (components) => {
|
|
661
776
|
ogImageComponentCtx.components = [];
|
|
@@ -712,7 +827,7 @@ const module = defineNuxtModule({
|
|
|
712
827
|
};
|
|
713
828
|
extendTypes("nuxt-og-image", ({ typesPath }) => {
|
|
714
829
|
const componentImports = ogImageComponentCtx.components.map((component) => {
|
|
715
|
-
const relativeComponentPath = relative(resolve(nuxt.options.rootDir, nuxt.options.buildDir, "module"), component.path);
|
|
830
|
+
const relativeComponentPath = relative$1(resolve(nuxt.options.rootDir, nuxt.options.buildDir, "module"), component.path);
|
|
716
831
|
const name2 = config.componentDirs.sort((a, b) => b.length - a.length).reduce((name3, dir) => {
|
|
717
832
|
return name3.replace(new RegExp(`^${dir}`), "");
|
|
718
833
|
}, component.pascalName);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import playwrightCore from "playwright-core";
|
|
2
1
|
import { Launcher } from "chrome-launcher";
|
|
2
|
+
import playwrightCore from "playwright-core";
|
|
3
3
|
const chromePath = Launcher.getFirstInstallation();
|
|
4
4
|
export async function createBrowser() {
|
|
5
5
|
return playwrightCore.chromium.launch({
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
+
import { init } from "satori";
|
|
1
2
|
import _satori from "satori/wasm";
|
|
2
3
|
import initYoga from "yoga-wasm-web";
|
|
3
|
-
import { init } from "satori";
|
|
4
4
|
const wasm = import("yoga-wasm-web/dist/yoga.wasm?module").then(async (yoga) => await initYoga(yoga.default || yoga));
|
|
5
5
|
export default {
|
|
6
6
|
initWasmPromise: new Promise((resolve) => {
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
import type { Storage } from 'unstorage';
|
|
2
|
-
import type { OgImageOptions } from '
|
|
2
|
+
import type { OgImageOptions } from '../../../types.js';
|
|
3
3
|
export declare const htmlPayloadCache: Storage<{
|
|
4
4
|
expiresAt: number;
|
|
5
5
|
value: OgImageOptions;
|
|
6
6
|
}>;
|
|
7
7
|
export declare const prerenderOptionsCache: Storage<OgImageOptions> | undefined;
|
|
8
|
+
export declare const fontCache: Storage<BufferSource>;
|
|
9
|
+
export declare const emojiCache: Storage<string>;
|
|
@@ -7,3 +7,9 @@ export const htmlPayloadCache = createStorage({
|
|
|
7
7
|
export const prerenderOptionsCache = import.meta.prerender ? createStorage({
|
|
8
8
|
driver: lruCacheDriver({ max: 1e4 })
|
|
9
9
|
}) : void 0;
|
|
10
|
+
export const fontCache = createStorage({
|
|
11
|
+
driver: lruCacheDriver({ max: 10 })
|
|
12
|
+
});
|
|
13
|
+
export const emojiCache = createStorage({
|
|
14
|
+
driver: lruCacheDriver({ max: 1e3 })
|
|
15
|
+
});
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { Storage } from 'unstorage';
|
|
2
|
+
import type { OgImageOptions } from '../../../types.js';
|
|
3
|
+
export declare const htmlPayloadCache: Storage<{
|
|
4
|
+
expiresAt: number;
|
|
5
|
+
value: OgImageOptions;
|
|
6
|
+
}>;
|
|
7
|
+
export declare const prerenderOptionsCache: Storage<OgImageOptions> | undefined;
|
|
8
|
+
export declare const fontCache: Storage<OgImageOptions<"NuxtSeo">>;
|
|
9
|
+
export declare const emojiCache: Storage<string>;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { createStorage } from "unstorage";
|
|
2
|
+
import memoryDriver from "unstorage/drivers/memory";
|
|
3
|
+
const storage = createStorage({
|
|
4
|
+
driver: memoryDriver()
|
|
5
|
+
});
|
|
6
|
+
export const htmlPayloadCache = storage;
|
|
7
|
+
export const prerenderOptionsCache = storage;
|
|
8
|
+
export const fontCache = storage;
|
|
9
|
+
export const emojiCache = storage;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
+
import { createBrowser } from "#nuxt-og-image/bindings/chromium";
|
|
1
2
|
import { createError } from "h3";
|
|
2
3
|
import { createScreenshot } from "./screenshot.js";
|
|
3
|
-
import { createBrowser } from "#nuxt-og-image/bindings/chromium";
|
|
4
4
|
const ChromiumRenderer = {
|
|
5
5
|
name: "chromium",
|
|
6
6
|
supportedFormats: ["png", "jpeg", "jpg"],
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
+
import { useNitroOrigin } from "#imports";
|
|
1
2
|
import { joinURL, withQuery } from "ufo";
|
|
2
3
|
import { useOgImageRuntimeConfig } from "../../../shared.js";
|
|
3
|
-
import { useNitroOrigin } from "#imports";
|
|
4
4
|
export async function createScreenshot({ basePath, e, options, extension }, browser) {
|
|
5
5
|
const { colorPreference } = useOgImageRuntimeConfig();
|
|
6
6
|
const path = options.component === "PageScreenshot" ? basePath : joinURL("/__og-image__/image", basePath, `og.html`);
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { createError, getQuery } from "h3";
|
|
1
|
+
import { htmlPayloadCache, prerenderOptionsCache } from "#nuxt-og-image-cache";
|
|
3
2
|
import { defu } from "defu";
|
|
4
|
-
import { normalizeKey } from "unstorage";
|
|
5
|
-
import { hash } from "ohash";
|
|
6
|
-
import { useNitroApp } from "nitropack/runtime";
|
|
7
3
|
import { parse } from "devalue";
|
|
4
|
+
import { createError, getQuery } from "h3";
|
|
5
|
+
import { useNitroApp } from "nitropack/runtime";
|
|
6
|
+
import { hash } from "ohash";
|
|
7
|
+
import { parseURL, withoutLeadingSlash, withoutTrailingSlash, withQuery } from "ufo";
|
|
8
|
+
import { normalizeKey } from "unstorage";
|
|
8
9
|
import { separateProps, useOgImageRuntimeConfig } from "../../shared.js";
|
|
9
|
-
import { createNitroRouteRuleMatcher } from "../util/kit.js";
|
|
10
10
|
import { decodeObjectHtmlEntities } from "../util/encoding.js";
|
|
11
|
-
import {
|
|
11
|
+
import { createNitroRouteRuleMatcher } from "../util/kit.js";
|
|
12
12
|
import { useChromiumRenderer, useSatoriRenderer } from "./instances.js";
|
|
13
13
|
export function resolvePathCacheKey(e, path) {
|
|
14
14
|
const siteConfig = e.context.siteConfig.get();
|
|
@@ -42,7 +42,7 @@ export async function resolveContext(e) {
|
|
|
42
42
|
queryParams.props = JSON.parse(queryParams.props || "{}");
|
|
43
43
|
queryParams = separateProps(queryParams);
|
|
44
44
|
let basePath = withoutTrailingSlash(
|
|
45
|
-
path.replace(`/__og-image__/image`, "").replace(`/og.${extension}`, "")
|
|
45
|
+
path.replace(`/__og-image__/image`, "").replace(`/__og-image__/static`, "").replace(`/og.${extension}`, "")
|
|
46
46
|
);
|
|
47
47
|
if (queryParams._query)
|
|
48
48
|
basePath = withQuery(basePath, JSON.parse(queryParams._query));
|
|
@@ -1,2 +1,3 @@
|
|
|
1
1
|
import type { OgImageRenderEventContext, ResolvedFontConfig } from '../../../types.js';
|
|
2
|
+
export declare const assets: import("unstorage").Storage<import("unstorage").StorageValue>;
|
|
2
3
|
export declare function loadFont({ e, publicStoragePath }: OgImageRenderEventContext, font: ResolvedFontConfig): Promise<ResolvedFontConfig>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { prefixStorage } from "unstorage";
|
|
2
1
|
import { useNitroOrigin, useStorage } from "#imports";
|
|
3
|
-
|
|
2
|
+
import { prefixStorage } from "unstorage";
|
|
3
|
+
export const assets = prefixStorage(useStorage(), "/assets");
|
|
4
4
|
export async function loadFont({ e, publicStoragePath }, font) {
|
|
5
5
|
const { name, weight } = font;
|
|
6
6
|
if (font.data)
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type _sharp from 'sharp';
|
|
2
1
|
import type _satori from 'satori';
|
|
2
|
+
import type _sharp from 'sharp';
|
|
3
3
|
export declare function useResvg(): Promise<new (svg: Uint8Array | string, options?: import("@resvg/resvg-wasm").ResvgRenderOptions) => {
|
|
4
4
|
free(): void;
|
|
5
5
|
render(): {
|