@flatbiz/antd 3.2.21 → 3.2.22

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index.d.ts CHANGED
@@ -1709,6 +1709,15 @@ export interface RichTextEditorProps extends Omit<IAllProps, "onChange" | "init"
1709
1709
  /** 图片点击预览 */
1710
1710
  imgPreview?: boolean;
1711
1711
  init?: IAllProps["init"] & {
1712
+ /**
1713
+ * 通过粘贴图片创建的img标签,显示压缩比例,此处min、max是和指图片宽度
1714
+ * 1. 默认值值:[{ min: 0, max: 1000, ratio: 0.5 }, { min: 1000, ratio: 0.3 }]
1715
+ */
1716
+ img_ratio?: {
1717
+ min: number;
1718
+ max?: number;
1719
+ ratio: number;
1720
+ }[];
1712
1721
  /** 插件添加;自定义plugins后失效 */
1713
1722
  plugins_append?: string;
1714
1723
  /** 工具栏添加;自定义toolbar后失效 */
@@ -1728,6 +1737,8 @@ export interface RichTextEditorProps extends Omit<IAllProps, "onChange" | "init"
1728
1737
  * 5. 可通过设置 init.plugins、init.toolbar 完全自定义插件、工具栏
1729
1738
  * 6. 其他插件
1730
1739
  * emoticons 表情插件
1740
+ * 7. 可通过设置 init.img_ratio 设置通过粘贴上传的图片压缩显示比例
1741
+ * 默认比例:[{ min: 0, max: 1000, ratio: 0.5 }, { min: 1000, ratio: 0.3 }]
1731
1742
  * ```
1732
1743
  */
1733
1744
  export declare const RichTextEditor: (props: RichTextEditorProps) => JSX.Element;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@flatbiz/antd",
3
- "version": "3.2.21",
3
+ "version": "3.2.22",
4
4
  "description": "flat-biz oss ui components",
5
5
  "main": "index.js",
6
6
  "typings": "index.d.ts",