保存一下

This commit is contained in:
2025-09-02 11:54:06 +08:00
parent d2b5b0e865
commit 981d93d28f
6 changed files with 768 additions and 441 deletions

View File

@@ -6,6 +6,8 @@ import type { IWindowFormConfig } from '@/core/window/types/IWindowFormConfig.ts
import type { WindowFormPos } from '@/core/window/types/WindowFormTypes.ts'
import { processManager } from '@/core/process/ProcessManager.ts'
import { Draggable } from '@/core/utils/Draggable.ts'
import { Resizable } from '@/core/utils/Resizable.ts'
import { DraggableResizable } from '@/core/utils/DraggableResizable.ts'
export default class WindowFormImpl implements IWindowForm {
private readonly _id: string = uuidV4();
@@ -46,9 +48,22 @@ export default class WindowFormImpl implements IWindowForm {
dom.style.height = `${this.height}px`;
dom.style.zIndex = '100';
dom.style.backgroundColor = 'white';
new Draggable( {
handle: dom,
// new Draggable( {
// handle: dom,
// target: dom,
// mode: 'position',
// snapThreshold: 20,
// boundary: document.body
// })
// new Resizable({
// target: dom,
// onResizeEnd: (data) => {
// console.log(data)
// }
// })
new DraggableResizable({
target: dom,
handle: dom,
mode: 'position',
snapThreshold: 20,
boundary: document.body