Skip to content

Commit

Permalink
docs(cropperjs): add exported modules section
Browse files Browse the repository at this point in the history
  • Loading branch information
fengyuanchen committed Apr 21, 2024
1 parent 003ffa0 commit 5b6ed96
Show file tree
Hide file tree
Showing 2 changed files with 40 additions and 0 deletions.
20 changes: 20 additions & 0 deletions docs/api/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -122,3 +122,23 @@ Get the `<cropper-selection>` element in the Cropper container.
- The `<cropper-selection>` element if any.

Get all the `<cropper-selection>` elements in the Cropper container when there are multiple selections.

## Exported Modules

```js
import {
// Constants
DEFAULT_TEMPLATE,

// Elements
CropperElement,
CropperCanvas,
CropperImage,
CropperShade,
CropperHandle,
CropperSelection,
CropperGrid,
CropperCrosshair,
CropperViewer,
} from 'cropperjs';
```
20 changes: 20 additions & 0 deletions docs/zh/api/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -122,3 +122,23 @@ Cropper 的默认模板:
- `<cropper-selection>` 元素(如果有)。

当有多个选择时,获取 Cropper 容器中的所有 `<cropper-selection>` 元素。

## 导出的模块

```js
import {
// 常量
DEFAULT_TEMPLATE,

// 元素
CropperElement,
CropperCanvas,
CropperImage,
CropperShade,
CropperHandle,
CropperSelection,
CropperGrid,
CropperCrosshair,
CropperViewer,
} from 'cropperjs';
```

0 comments on commit 5b6ed96

Please sign in to comment.