Image Zoom

approved

by liominsb

This plugin has not been manually reviewed by Obsidian staff. Lightweight image zoom and drag viewing plugin, supports wheel zoom and mouse drag panning.

23 downloadsUpdated 14d agoMIT

Image Zoom - Obsidian ͼƬ��������ק���

һ���������� Obsidian ͼƬ�鿴�����֧�ֹ������ź������קƽ�ƣ�������ʧ�޵� Image Toolkit��

? ��������

  • ����Ŵ������Ķ�ģʽ��ʵʱԤ��ģʽ�µ��ͼƬ����ȫ���鿴
  • ����������֧���������޼����ţ������ָ��λ��Ϊ����
  • ��קƽ�����Ŵ��ɰ�ס��������ק�ƶ�ͼƬ
  • �����˳����� Esc ��������ɫ�������ɹر�
  • ����������ԭ��ʵ�֣��޵������������������д���
  • �����Ż���ʹ�� requestAnimationFrame ��������֤˿������
  • ��ʽ������CSS ����ʹ��Ψһǰ׺������Ⱦ Obsidian ԭ����ʽ

? ��װ����

����һ���ֶ���װ���Ƽ���

  1. ���ز���ļ�

    �����������ļ�׼���ã�

    • manifest.json
    • main.js����Ҫ�������ɣ�
    • styles.css
  2. �ҵ� Obsidian ���Ŀ¼

    • �� Obsidian ���� �� ��������� �� ��ȫģʽ���رգ�
    • ����ļ���ͼ��򿪲��Ŀ¼
    • ·��ͨ��Ϊ��<��IJֿ�>/.obsidian/plugins/
  3. ����������

    �� plugins Ŀ¼�´������ļ��У�image-zoom

  4. �����ļ�

    �� manifest.json��main.js��styles.css �����ļ����Ƶ� image-zoom �ļ�����

  5. ���ò��

    • ���� Obsidian
    • �������� �� ���������
    • �ҵ� "Image Zoom & Pan" ������

������������ģʽ��װ

  1. ��¡�����ر���Ŀ

    git clone <repository-url>
    cd image-zoom-pan
    
  2. ��װ����

    npm install
    
  3. ������

    npm run build
    
  4. ���ӵ� Obsidian

    ���������ļ����Ƶ���� Obsidian �ֿ�IJ��Ŀ¼��

    <��IJֿ�>/.obsidian/plugins/image-zoom-pan/
    
  5. ���ò��

    �� Obsidian ���������ò��

?? ����ָ��

����Ҫ��

  • Node.js >= 16
  • npm �� yarn

��������

# ��װ����
npm install

# ����ģʽ���Զ����룩
npm run dev

# ��������
npm run build

��Ŀ�ṹ

image-zoom/
������ manifest.json    # ��������ļ�
������ main.ts          # ����ҵ���߼�
������ styles.css       # ��ʽ�ļ�
������ package.json     # ��Ŀ����
������ tsconfig.json    # TypeScript ����
������ esbuild.config.mjs  # ��������
������ README.md        # ˵���ĵ�

? ʹ��˵��

  1. ���Ķ�ģʽ��ʵʱԤ��ģʽ�£���������ͼƬ
  2. ͼƬ���ں�ɫ��͸�������Ͼ�����ʾ
  3. �������������������ַŴ�/��СͼƬ�������λ��Ϊ���ģ�
  4. ��ק�ƶ����Ŵ�󣬰�ס��������ק���ƶ�ͼƬ
  5. �˳��鿴��
    • �� Esc ��
    • �����ɫ�����հ�����

?? ����ʵ��

  • ��ԭ��ʵ������ʹ�� TypeScript + DOM API���޵����� UI ��
  • �����Ż�����ק������ʹ�� requestAnimationFrame ����
  • ��ʽ���������� CSS ����ʹ�� my-custom-zoom- ǰ׺
  • ��������֧�� Obsidian v1.5+ �����ϰ汾

? ���ⷴ��

����������⣬���飺

  1. Obsidian �汾�Ƿ� >= 1.5.0
  2. ����Ƿ���ȷ��װ������
  3. �Ƿ����Ķ�ģʽ��ʵʱԤ��ģʽ�²���

? ����֤

MIT License

? ��л

�����Դ�� Image Toolkit ����������Ϊ�����������������

For plugin developers

Search results and similarity scores are powered by semantic analysis of your plugin's README. If your plugin isn't appearing for searches you'd expect, try updating your README to clearly describe your plugin's purpose, features, and use cases.