mirror of
https://github.com/xiaoqidun/ofdgo.git
synced 2026-10-29 14:31:12 +08:00
This commit is contained in:
1 parent
13eced8dd8
commit
2cc6c121f8
6 files changed
+225
-40
No files matched your search
@@ -1075,8 +1075,8 @@ func changePage(args []js.Value) (any, error) {
|
||||
return editorPageInfo{info, index}, nil
|
||||
}
|
||||
|
||||
// batchPages 按页码范围批量复制、删除或移动页面
|
||||
// 入参: args 操作、页码表达式及原页面序列中的插入位置
|
||||
// batchPages 按页码范围批量复制、删除、移动或调整页面尺寸
|
||||
// 入参: args 操作、页码表达式及插入位置或宽高
|
||||
// 返回: any 文档信息及目标页, error 错误信息
|
||||
func batchPages(args []js.Value) (any, error) {
|
||||
index := 0
|
||||
@@ -1113,6 +1113,9 @@ func batchPages(args []js.Value) (any, error) {
|
||||
}
|
||||
}
|
||||
return currentEditor.MovePages(indexes, index)
|
||||
case "resize":
|
||||
index = indexes[0]
|
||||
return currentEditor.ResizePages(indexes, args[2].Float(), args[3].Float())
|
||||
default:
|
||||
return fmt.Errorf("unsupported page action %q", args[0].String())
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user