Furaffinity-Submission-Image-Viewer

Library for creating custom image elements on Furaffinity

This script should not be not be installed directly. It is a library for other scripts to include with the meta directive // @require https://update.greasyfork.org/scripts/492931/1849457/Furaffinity-Submission-Image-Viewer.js

You will need to install an extension such as Tampermonkey, Greasemonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Userscripts to install this script.

You will need to install an extension such as Tampermonkey to install this script.

You will need to install a user script manager extension to install this script.

(I already have a user script manager, let me install it!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(I already have a user style manager, let me install it!)

Аўтар
Midori Dragon
Версія
1.3.2
Створаны
19.04.2024
Абноўлены
12.06.2026
Памер
46.6 КБ
Ліцэнзія
MIT

Furaffinity Custom Image Viewer

Library for creating image elements on FurAffinity.

See documentation on Furaffinity-Submission-Image-Viewer.

How to use

  • @require this script

  • Create a new Custom Image Viewer:

    const baseElem = document.createElement("div");
    const faImageViewer = new FAImageViewer(baseElem, imgSrc, prevSrc);
    faImageViewer.load(); // starts loading the image
    
  • Optional: Subscribe to Events:

    faImageViewer.onImageLoad(() => doSomething()); // occurs if the image is fully loaded
    faImageViewer.onImageLoadStart(() => doSomething()); // occurs if the image started loading
    faImageViewer.onPreviewImageLoad(() => doSomething()); // occurs if the preview image fully loaded
    ⠀
    faImageViewer.addEventListener("image-load", () => doSomething()); // alternative to onImageLoad
    faImageViewer.addEventListener("image-load-start", () => doSomething()); // alternative to onImageLoadStart
    faImageViewer.addEventListener("preview-image-load", () => doSomething()); // alternative to onPreviewImageLoad
    

Feature Roadmap

Feature Status
Support preview image ✅ Completed
Have different events for image loading ✅ Completed
Zooming and panning via panzoom ✅ Completed