PHPackages                             weiwait/dcat-cropper - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. weiwait/dcat-cropper

Abandoned → [weiwait/dcat-vue](/?search=weiwait%2Fdcat-vue)Library[Utility &amp; Helpers](/categories/utility)

weiwait/dcat-cropper
====================

Dcat-admin 表单单图裁剪

1.1.8(4y ago)339895[1 issues](https://github.com/weiwait/dcat-cropper/issues)MITJavaScriptPHP &gt;=7.1.0

Since Aug 9Pushed 3y ago1 watchersCompare

[ Source](https://github.com/weiwait/dcat-cropper)[ Packagist](https://packagist.org/packages/weiwait/dcat-cropper)[ Docs](https://github.com/weiwait/dcat-cropper)[ RSS](/packages/weiwait-dcat-cropper/feed)WikiDiscussions master Synced 1w ago

READMEChangelog (10)Dependencies (1)Versions (18)Used By (0)

Dcat Admin Extension
====================

[](#dcat-admin-extension)

### 演示地址

[](#演示地址)

[demo: http://dcat.weiwait.cn (admin:admin)](http://dcat.weiwait.cn/admin/demo-distpickers/create "user: admin psw: admin")

### 通过 composer 安装扩展

[](#通过-composer-安装扩展)

```
  composer require weiwait/dcat-cropper
```

### 发布静态资源

[](#发布静态资源)

```
  php artisan vendor:publish --tag=weiwait.dcat-cropper --force
```

### 更新 dcat-admin ide-helper

[](#更新-dcat-admin-ide-helper)

```
  php artisan admin:ide-helper
```

```
    $form->cropper('column', 'label')
        ->jpeg(0.5) // 0 ~ 1
        ->useBase64() // 采用base64编码图片统一提交
        ->ratio(16/9) // 快捷裁剪选项配置（裁剪比率）
        ->resolution(1920, 1080)
        ->ratio(1)
        ->resolution(100) // 等比
        ->ratio(['1:1' => 1, '16:9' => 16/9, '自定义' => null]) // 多预设
        ->resolution(['1:1' => [300, 300], '16:9' => [1920, 1080]])
        ->options([
            // https://github.com/fengyuanchen/cropperjs
            // 裁剪选项
            'cropper' => [
                'aspectRatio' = 16/9,
                'background' => false,
            ]
        ])

    $form->multipleCropper('column', 'label')
        ->limit(5) // 默认为框架默认值10
        ->ratio(16/9) // 快捷裁剪选项配置（裁剪比率）
        ->resolution(1920, 1080)
        ->ratio(1)
        ->resolution(100) // 等比
        ->ratio(['1:1' => 1, '16:9' => 16/9, '自定义' => null]) // 多预设
        ->resolution(['1:1' => [300, 300], '16:9' => [1920, 1080]])
        ->options([
            // https://github.com/fengyuanchen/cropperjs
            // 裁剪选项
            'cropper' => [
                'aspectRatio' = 16/9,
                'background' => false,
            ]
        ])
        ->accept('png')
        ->compress() // intervention/image 功能（dcat）
```

[![示例图片](https://github.com/weiwait/images/raw/main/dcat-cropper.png?raw=true)](https://github.com/weiwait/images/blob/main/dcat-cropper.png?raw=true)

### Dcat-admin 扩展列表

[](#dcat-admin-扩展列表)

1. [新版裁剪](https://github.com/weiwait/dcat-vue)
2. [区划级联+坐标拾取](https://github.com/weiwait/dcat-distpicker)
3. [smtp快速便捷配置](https://github.com/weiwait/dcat-smtp)
4. [sms channel 快速便捷配置](https://github.com/weiwait/dcat-easy-sms)

###  Health Score

31

—

LowBetter than 68% of packages

Maintenance19

Infrequent updates — may be unmaintained

Popularity27

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity55

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~15 days

Recently: every ~1 days

Total

17

Last Release

1490d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/74e0a539fde4f31941cf773ea8504fa105f6c48dd8d3665c3f5ea13304c82292?d=identicon)[weiwait](/maintainers/weiwait)

---

Top Contributors

[![weiwait](https://avatars.githubusercontent.com/u/17488095?v=4)](https://github.com/weiwait "weiwait (1 commits)")

---

Tags

extensiondcat admin

### Embed Badge

![Health badge](/badges/weiwait-dcat-cropper/health.svg)

```
[![Health](https://phpackages.com/badges/weiwait-dcat-cropper/health.svg)](https://phpackages.com/packages/weiwait-dcat-cropper)
```

###  Alternatives

[sparkinzy/dcat-distpicker

省市区地址选择器，支持select2

272.7k1](/packages/sparkinzy-dcat-distpicker)[sparkinzy/dcat-marketplace

Dcat扩展市场

381.3k](/packages/sparkinzy-dcat-marketplace)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
