star-horse-lowcode 3.1.5 → 3.1.7

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.
Files changed (38) hide show
  1. package/README.md +11 -0
  2. package/dist/api/star_horse_apis.d.ts +1 -1
  3. package/dist/api/star_horse_utils.d.ts +7 -5
  4. package/dist/api/system.d.ts +3 -3
  5. package/dist/assets/index.css +1 -1
  6. package/dist/components/comp/StarHorseDataSelector.vue.d.ts +2 -2
  7. package/dist/components/comp/utils/DataPicker.vue.d.ts +0 -45
  8. package/dist/components/formcomp/utils/ItemRelationEventUtils.d.ts +13 -3
  9. package/dist/components/types/ApiUrls.d.ts +20 -0
  10. package/dist/components/types/ItemPreps.d.ts +155 -2
  11. package/dist/components/types/PageFieldInfo.d.ts +8 -0
  12. package/dist/index.es.js +6 -6
  13. package/dist/lang/en_US.d.ts +16 -0
  14. package/dist/lang/zh_CN.d.ts +16 -0
  15. package/dist/store/FormDataCache.d.ts +252 -0
  16. package/dist/store/SelfOperation.d.ts +30 -0
  17. package/dist/store/StoreManager.d.ts +564 -0
  18. package/dist/types/api/star_horse_apis.d.ts +1 -1
  19. package/dist/types/api/star_horse_utils.d.ts +7 -6
  20. package/dist/types/api/system.d.ts +3 -3
  21. package/dist/types/components/comp/StarHorseDataSelector.vue.d.ts +2 -2
  22. package/dist/types/components/comp/StarHorseTableComp.vue.d.ts +1 -1
  23. package/dist/types/components/comp/StarHorseTree.vue.d.ts +2 -2
  24. package/dist/types/components/comp/utils/DataPicker.vue.d.ts +0 -45
  25. package/dist/types/components/formcomp/utils/ItemRelationEventUtils.d.ts +13 -3
  26. package/dist/types/components/system/PageConfig.vue.d.ts +1 -1
  27. package/dist/types/components/system/code-editor/ApiConfigDialog.vue.d.ts +2 -2
  28. package/dist/types/components/types/ApiUrls.d.ts +20 -0
  29. package/dist/types/components/types/ItemPreps.d.ts +155 -2
  30. package/dist/types/components/types/PageFieldInfo.d.ts +8 -0
  31. package/dist/types/lang/en_US.d.ts +16 -0
  32. package/dist/types/lang/zh_CN.d.ts +16 -0
  33. package/dist/types/store/FormDataCache.d.ts +252 -0
  34. package/dist/types/store/SelfOperation.d.ts +30 -0
  35. package/dist/types/store/StoreManager.d.ts +564 -0
  36. package/dist/types/utils/ImagePreview.d.ts +105 -0
  37. package/dist/utils/ImagePreview.d.ts +105 -0
  38. package/package.json +13 -12
@@ -0,0 +1,105 @@
1
+ /**
2
+ * ImagePreview - 可配置的图片预览工具
3
+ * 支持淡入淡出、3D翻转等过渡动画,支持丰富的配置项
4
+ */
5
+ /** 过渡动画类型 */
6
+ export type ImageTransition = "fade" | "slide" | "zoom" | "flip3d" | "none";
7
+ /** 图片预览配置 */
8
+ export interface ImagePreviewOptions {
9
+ /** 过渡动画类型,默认 fade */
10
+ transition?: ImageTransition;
11
+ /** 过渡动画时长(ms),默认 300 */
12
+ transitionDuration?: number;
13
+ /** 背景色,默认 rgba(0,0,0,0.85) */
14
+ overlayBackground?: string;
15
+ /** 是否显示工具栏,默认 true */
16
+ showToolbar?: boolean;
17
+ /** 是否显示缩略图栏,默认 true(多图时) */
18
+ showThumbnails?: boolean;
19
+ /** 是否显示左右箭头,默认 true(多图时) */
20
+ showArrows?: boolean;
21
+ /** 是否启用键盘导航,默认 true */
22
+ keyboardNavigation?: boolean;
23
+ /** 是否启用鼠标滚轮缩放,默认 true */
24
+ wheelZoom?: boolean;
25
+ /** 是否启用拖拽平移,默认 true */
26
+ draggable?: boolean;
27
+ /** 初始索引,默认 0 */
28
+ initialIndex?: number;
29
+ /** 缩略图高度(px),默认 48 */
30
+ thumbnailSize?: number;
31
+ /** 箭头大小(px),默认 52 */
32
+ arrowSize?: number;
33
+ /** 关闭回调 */
34
+ onClose?: () => void;
35
+ /** 切换回调 */
36
+ onSwitch?: (index: number) => void;
37
+ }
38
+ export declare class ImagePreview {
39
+ private images;
40
+ private options;
41
+ private currentIndex;
42
+ private scale;
43
+ private rotation;
44
+ private translateX;
45
+ private translateY;
46
+ private isDragging;
47
+ private dragStartX;
48
+ private dragStartY;
49
+ private isTransitioning;
50
+ private overlay;
51
+ private imgWrap;
52
+ private img;
53
+ private imgBack;
54
+ private toolbar;
55
+ private thumbBar;
56
+ private counter;
57
+ private arrowLeft;
58
+ private arrowRight;
59
+ private prevBtn;
60
+ private nextBtn;
61
+ private thumbs;
62
+ private boundOnMouseMove;
63
+ private boundOnMouseUp;
64
+ private boundOnKeydown;
65
+ constructor(images: string | string[], options?: ImagePreviewOptions);
66
+ /** 关闭预览 */
67
+ close(): void;
68
+ /** 切换到指定索引 */
69
+ goTo(index: number): void;
70
+ /** 上一张 */
71
+ prev(): void;
72
+ /** 下一张 */
73
+ next(): void;
74
+ private build;
75
+ private buildToolbar;
76
+ private buildThumbnails;
77
+ private buildArrows;
78
+ private loadImage;
79
+ /** 淡入淡出 */
80
+ private transitionFade;
81
+ /** 滑动切换 */
82
+ private transitionSlide;
83
+ /** 缩放切换 */
84
+ private transitionZoom;
85
+ /** 3D翻转 */
86
+ private transitionFlip3d;
87
+ private bindEvents;
88
+ private onMouseMove;
89
+ private onMouseUp;
90
+ private onKeydown;
91
+ private resetTransform;
92
+ private updateImgTransform;
93
+ private updateUI;
94
+ private updateThumbActive;
95
+ private downloadImage;
96
+ private cleanup;
97
+ private el;
98
+ private createBtn;
99
+ }
100
+ /**
101
+ * 兼容旧接口 - 图片预览
102
+ * @param images 图片URL数组或单个URL
103
+ * @param options 预览配置
104
+ */
105
+ export declare function imagesPreview(images: Array<string> | string, options?: ImagePreviewOptions): ImagePreview;
@@ -0,0 +1,105 @@
1
+ /**
2
+ * ImagePreview - 可配置的图片预览工具
3
+ * 支持淡入淡出、3D翻转等过渡动画,支持丰富的配置项
4
+ */
5
+ /** 过渡动画类型 */
6
+ export type ImageTransition = "fade" | "slide" | "zoom" | "flip3d" | "none";
7
+ /** 图片预览配置 */
8
+ export interface ImagePreviewOptions {
9
+ /** 过渡动画类型,默认 fade */
10
+ transition?: ImageTransition;
11
+ /** 过渡动画时长(ms),默认 300 */
12
+ transitionDuration?: number;
13
+ /** 背景色,默认 rgba(0,0,0,0.85) */
14
+ overlayBackground?: string;
15
+ /** 是否显示工具栏,默认 true */
16
+ showToolbar?: boolean;
17
+ /** 是否显示缩略图栏,默认 true(多图时) */
18
+ showThumbnails?: boolean;
19
+ /** 是否显示左右箭头,默认 true(多图时) */
20
+ showArrows?: boolean;
21
+ /** 是否启用键盘导航,默认 true */
22
+ keyboardNavigation?: boolean;
23
+ /** 是否启用鼠标滚轮缩放,默认 true */
24
+ wheelZoom?: boolean;
25
+ /** 是否启用拖拽平移,默认 true */
26
+ draggable?: boolean;
27
+ /** 初始索引,默认 0 */
28
+ initialIndex?: number;
29
+ /** 缩略图高度(px),默认 48 */
30
+ thumbnailSize?: number;
31
+ /** 箭头大小(px),默认 52 */
32
+ arrowSize?: number;
33
+ /** 关闭回调 */
34
+ onClose?: () => void;
35
+ /** 切换回调 */
36
+ onSwitch?: (index: number) => void;
37
+ }
38
+ export declare class ImagePreview {
39
+ private images;
40
+ private options;
41
+ private currentIndex;
42
+ private scale;
43
+ private rotation;
44
+ private translateX;
45
+ private translateY;
46
+ private isDragging;
47
+ private dragStartX;
48
+ private dragStartY;
49
+ private isTransitioning;
50
+ private overlay;
51
+ private imgWrap;
52
+ private img;
53
+ private imgBack;
54
+ private toolbar;
55
+ private thumbBar;
56
+ private counter;
57
+ private arrowLeft;
58
+ private arrowRight;
59
+ private prevBtn;
60
+ private nextBtn;
61
+ private thumbs;
62
+ private boundOnMouseMove;
63
+ private boundOnMouseUp;
64
+ private boundOnKeydown;
65
+ constructor(images: string | string[], options?: ImagePreviewOptions);
66
+ /** 关闭预览 */
67
+ close(): void;
68
+ /** 切换到指定索引 */
69
+ goTo(index: number): void;
70
+ /** 上一张 */
71
+ prev(): void;
72
+ /** 下一张 */
73
+ next(): void;
74
+ private build;
75
+ private buildToolbar;
76
+ private buildThumbnails;
77
+ private buildArrows;
78
+ private loadImage;
79
+ /** 淡入淡出 */
80
+ private transitionFade;
81
+ /** 滑动切换 */
82
+ private transitionSlide;
83
+ /** 缩放切换 */
84
+ private transitionZoom;
85
+ /** 3D翻转 */
86
+ private transitionFlip3d;
87
+ private bindEvents;
88
+ private onMouseMove;
89
+ private onMouseUp;
90
+ private onKeydown;
91
+ private resetTransform;
92
+ private updateImgTransform;
93
+ private updateUI;
94
+ private updateThumbActive;
95
+ private downloadImage;
96
+ private cleanup;
97
+ private el;
98
+ private createBtn;
99
+ }
100
+ /**
101
+ * 兼容旧接口 - 图片预览
102
+ * @param images 图片URL数组或单个URL
103
+ * @param options 预览配置
104
+ */
105
+ export declare function imagesPreview(images: Array<string> | string, options?: ImagePreviewOptions): ImagePreview;
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "star-horse-lowcode",
3
3
  "private": false,
4
4
  "author": "l_1019@163.com",
5
- "version": "3.1.5",
5
+ "version": "3.1.7",
6
6
  "type": "module",
7
7
  "description": "星马低代码核心库,提供了低代码平台的基础功能和组件库。此库可引用到您的项目中,快速构建表单和列表。",
8
8
  "keywords": [
@@ -75,34 +75,35 @@
75
75
  "@codemirror/lang-xml": "^6.1.0",
76
76
  "@codemirror/lang-yaml": "^6.1.3",
77
77
  "@codemirror/theme-one-dark": "^6.1.3",
78
+ "@element-plus/icons-vue": "^2.3.2",
78
79
  "@monaco-editor/react": "^4.7.0",
79
80
  "@replit/codemirror-minimap": "^0.5.2",
80
81
  "@selemondev/vue3-signature-pad": "^1.9.0",
81
82
  "@vueuse/core": "^14.3.0",
82
83
  "@wangeditor/editor": "^5.1.23",
83
84
  "@wangeditor/editor-for-vue": "^5.1.12",
84
- "axios": "^1.18.0",
85
+ "axios": "^1.18.1",
86
+ "camelcase": "^9.0.0",
85
87
  "codemirror": "^6.0.2",
86
88
  "element-plus": "^2.14.2",
87
89
  "jquery": "^4.0.0",
88
90
  "json5": "^2.2.3",
89
91
  "markdown-it": "^14.2.0",
90
- "md-editor-v3": "^6.5.1",
92
+ "md-editor-v3": "^6.5.3",
91
93
  "monaco-editor": "^0.55.1",
92
94
  "path": "^0.12.7",
93
95
  "pinia": "^3.0.4",
94
96
  "pinia-plugin-persistedstate": "^4.7.1",
95
- "preview-image-js": "^1.2.1",
96
97
  "qrcode.vue": "^3.10.0",
97
98
  "smooth-signature": "^1.1.0",
98
99
  "sortablejs": "^1.15.7",
99
- "sql-formatter": "^15.8.1",
100
+ "sql-formatter": "^15.8.2",
100
101
  "tailwindcss": "^4.3.1",
101
102
  "thememirror": "^2.0.1",
102
- "uuid": "^14.0.0",
103
+ "uuid": "^14.0.1",
103
104
  "vanilla-jsoneditor": "^3.12.0",
104
105
  "vue": "^3.5.38",
105
- "vue-i18n": "^11.4.5",
106
+ "vue-i18n": "^11.4.6",
106
107
  "vue-m-message": "^4.0.2",
107
108
  "vue-router": "^5.1.0",
108
109
  "vue3-barcode": "^1.0.1",
@@ -116,23 +117,23 @@
116
117
  "@rollup/plugin-inject": "^5.0.5",
117
118
  "@tailwindcss/vite": "^4.3.1",
118
119
  "@types/jquery": "^4.0.1",
119
- "@types/node": "^25.9.3",
120
+ "@types/node": "^26.0.0",
120
121
  "@types/prismjs": "^1.26.6",
121
122
  "@types/sortablejs": "^1.15.9",
122
- "@typescript-eslint/eslint-plugin": "^8.61.1",
123
- "@typescript-eslint/parser": "^8.61.1",
123
+ "@typescript-eslint/eslint-plugin": "^8.62.0",
124
+ "@typescript-eslint/parser": "^8.62.0",
124
125
  "@typescript/typescript6": "^6.0.1",
125
126
  "@vitejs/plugin-vue": "^6.0.7",
126
127
  "@vue/language-core": "^3.3.5",
127
128
  "eslint": "^10.5.0",
128
129
  "eslint-plugin-vue": "^10.9.2",
129
- "globals": "^17.6.0",
130
+ "globals": "^17.7.0",
130
131
  "prettier": "^3.8.4",
131
132
  "sass-embedded": "^1.100.0",
132
133
  "terser": "^5.48.0",
133
134
  "unplugin-auto-import": "^21.0.0",
134
135
  "unplugin-vue-components": "^32.1.0",
135
- "vite": "^8.0.16",
136
+ "vite": "^8.1.0",
136
137
  "vite-plugin-dts": "^5.0.2",
137
138
  "vue-eslint-parser": "^10.4.1"
138
139
  },