Title: Theme Image Block
Author: Happy Prime
Published: <strong>16 دسامبر 2025</strong>
Last modified: 20 فوریه 2026

---

جستجوی افزونه‌ها

![](https://s.w.org/plugins/geopattern-icon/theme-image-block.svg)

# Theme Image Block

 توسط [Happy Prime](https://profiles.wordpress.org/happyprime/)

[دانلود](https://downloads.wordpress.org/plugin/theme-image-block.1.1.1.zip)

 * [جزئیات](https://fa.wordpress.org/plugins/theme-image-block/#description)
 * [نقد و بررسی‌ها](https://fa.wordpress.org/plugins/theme-image-block/#reviews)
 *  [نصب](https://fa.wordpress.org/plugins/theme-image-block/#installation)
 * [توسعه](https://fa.wordpress.org/plugins/theme-image-block/#developers)

 [پشتیبانی](https://wordpress.org/support/plugin/theme-image-block/)

## توضیحات

The Theme Image Block plugin allows you to register images from your theme and make
them available as blocks in the WordPress editor. This is useful for logos, icons,
and other images that are part of your theme’s design system.

### Usage

### Registering Theme Images

Theme images should be registered using `HappyPrime\ThemeImageBlock\register_theme_image()`.
This is likely best done on the `init` or `after_setup_theme` action.

    ```
    HappyPrime\ThemeImageBlock\register_theme_image(
        'happy-prime-logo',
        [
            'title' => 'Happy Prime Logo',
            'description' => 'The Happy Prime logo.',
            'alt' => 'Happy Prime',
            'path' => 'images/happy-prime-logo.svg',
            'width' => '300',
            'height' => '',
            'variations' => [
                'small' => [
                    'path'   => 'images/happy-prime-logo-small.svg',
                    'width'  => '100',
                    'height' => '100',
                ],
                'medium' => [
                    'path'   => 'images/happy-prime-logo-medium.svg',
                    'width'  => '200',
                    'height' => '200',
                ],
                'large' => [
                    'path'   => 'images/happy-prime-logo-large.svg',
                    'width'  => '300',
                    'height' => '300',
                ],
            ],
            'sizes' => '(max-width: 600px) 100vw, 300px',
        ]
    );
    ```

### Registering Theme Image Styles

Theme image styles should be registered using `HappyPrime\ThemeImageBlock\register_theme_image_style()`.
This is likely best done on the `init` or `after_setup_theme` action.

    ```
    HappyPrime\ThemeImageBlock\register_theme_image_style(
        'hero',
        [
            'name'   => 'Hero',
            'width'  => 'clamp(10rem, 100vw, 60rem)',
            'height' => 'auto',
        ]
    );
    ```

## بلوک‌ها

این افزونه 1 بلوک ارائه می‌دهد.

 *   Theme Image Display an image from the theme's images directory.

## نصب

 1. Install and activate the plugin.
 2. Register theme images using the `register_theme_image()` function.
 3. Register theme image styles using the `register_theme_image_style()` function.
 4. Use the Theme Image block in the editor to insert registered images.

## نقد و بررسی‌ها

نقد و بررسی‌ای برای این افزونه یافت نشد.

## توسعه دهندگان و همکاران

“Theme Image Block” نرم افزار متن باز است. افراد زیر در این افزونه مشارکت کرده‌اند.

مشارکت کنندگان

 *   [ Happy Prime ](https://profiles.wordpress.org/happyprime/)
 *   [ Jeremy Felt ](https://profiles.wordpress.org/jeremyfelt/)
 *   [ slocker ](https://profiles.wordpress.org/slocker/)
 *   [ philcable ](https://profiles.wordpress.org/philcable/)

[ترجمه “Theme Image Block” به زبان شما.](https://translate.wordpress.org/projects/wp-plugins/theme-image-block)

### علاقه‌ مند به توسعه هستید؟

[Browse the code](https://plugins.trac.wordpress.org/browser/theme-image-block/),
check out the [SVN repository](https://plugins.svn.wordpress.org/theme-image-block/),
or subscribe to the [development log](https://plugins.trac.wordpress.org/log/theme-image-block/)
by [RSS](https://plugins.trac.wordpress.org/log/theme-image-block/?limit=100&mode=stop_on_copy&format=rss).

## گزارش تغییرات

### 1.1.1

 * Prevent fatal error on activation.
 * Improve HTML processing when rendering output.
 * Fix reference to renamed global JavaScript variable.
 * Fix textdomain mismatch.
 * Improve support for multiple theme image blocks in one editor view.

### 1.1.0

 * Initial release on wp.org.

### 1.0.0

 * Initial release.

## اطلاعات

 *  نگارش **1.1.1**
 *  Last updated **3 ماه پیش**
 *  نصب‌های فعال **کمتر از 10**
 *  نگارش وردپرس ** 6.8 یا بالاتر **
 *  Tested up to **6.9.4**
 *  نگارش PHP ** 7.4 یا بالاتر **
 *  زبان
 * [English (US)](https://wordpress.org/plugins/theme-image-block/)
 * Tags
 * [images](https://fa.wordpress.org/plugins/tags/images/)[media](https://fa.wordpress.org/plugins/tags/media/)
 *  [نمایش پیشرفته](https://fa.wordpress.org/plugins/theme-image-block/advanced/)

## امتیازها

هنوز هیچ نقدی ارسال نشده است.

[Your review](https://wordpress.org/support/plugin/theme-image-block/reviews/#new-post)

[مشاهده همه بررسی‌ها](https://wordpress.org/support/plugin/theme-image-block/reviews/)

## مشارکت کنندگان

 *   [ Happy Prime ](https://profiles.wordpress.org/happyprime/)
 *   [ Jeremy Felt ](https://profiles.wordpress.org/jeremyfelt/)
 *   [ slocker ](https://profiles.wordpress.org/slocker/)
 *   [ philcable ](https://profiles.wordpress.org/philcable/)

## پشتیبانی

چیزی برای گفتن دارید؟ نیاز به کمک دارید؟

 [مشاهده انجمن پشتیبانی](https://wordpress.org/support/plugin/theme-image-block/)