@clake/react-bootstrap4-window 0.7.7 → 1.0.1
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/dist/react-bootstrap4-window.js +4 -4
- package/lib/CTable.js +190 -203
- package/lib/CTable.js.map +3 -3
- package/lib/CTableInput.js +18 -24
- package/lib/CTableInput.js.map +3 -3
- package/lib/Drag.js +63 -27
- package/lib/Drag.js.map +3 -3
- package/lib/IconButton.js +22 -24
- package/lib/IconButton.js.map +3 -3
- package/lib/PageBar.js +9 -21
- package/lib/PageBar.js.map +3 -3
- package/lib/TopMenu.js +104 -107
- package/lib/TopMenu.js.map +3 -3
- package/lib/WCalendar.js +17 -20
- package/lib/WCalendar.js.map +3 -3
- package/lib/WCombo.js +14 -9
- package/lib/WCombo.js.map +3 -3
- package/lib/WModal.js +118 -79
- package/lib/WModal.js.map +3 -3
- package/lib/Window.js +58 -40
- package/lib/Window.js.map +3 -3
- package/lib/WindowGroup.js +19 -11
- package/lib/WindowGroup.js.map +3 -3
- package/lib/i18n/CTable.js +4 -4
- package/lib/i18n/CTable.js.map +3 -3
- package/lib/index.js +59 -36
- package/lib/index.js.map +3 -3
- package/lib/types/gulpfile.babel.d.ts +2 -0
- package/lib/types/gulpfile.babel.d.ts.map +1 -0
- package/lib/types/src/CTable.d.ts +224 -0
- package/lib/types/src/CTable.d.ts.map +1 -0
- package/lib/types/src/CTableInput.d.ts +41 -0
- package/lib/types/src/CTableInput.d.ts.map +1 -0
- package/lib/types/src/Drag.d.ts +50 -0
- package/lib/types/src/Drag.d.ts.map +1 -0
- package/lib/types/src/IconButton.d.ts +19 -0
- package/lib/types/src/IconButton.d.ts.map +1 -0
- package/lib/types/src/PageBar.d.ts +27 -0
- package/lib/types/src/PageBar.d.ts.map +1 -0
- package/lib/types/src/TopMenu.d.ts +42 -0
- package/lib/types/src/TopMenu.d.ts.map +1 -0
- package/lib/types/src/WCalendar.d.ts +32 -0
- package/lib/types/src/WCalendar.d.ts.map +1 -0
- package/lib/types/src/WCombo.d.ts +28 -0
- package/lib/types/src/WCombo.d.ts.map +1 -0
- package/lib/types/src/WModal.d.ts +106 -0
- package/lib/types/src/WModal.d.ts.map +1 -0
- package/lib/types/src/Window.d.ts +79 -0
- package/lib/types/src/Window.d.ts.map +1 -0
- package/lib/types/src/WindowGroup.d.ts +28 -0
- package/lib/types/src/WindowGroup.d.ts.map +1 -0
- package/lib/types/src/i18n/CTable.d.ts +3 -0
- package/lib/types/src/i18n/CTable.d.ts.map +1 -0
- package/lib/types/src/index.d.ts +6 -0
- package/lib/types/src/index.d.ts.map +1 -0
- package/lib/types/webpack.common.d.ts +55 -0
- package/lib/types/webpack.common.d.ts.map +1 -0
- package/lib/types/webpack.dev.d.ts +3 -0
- package/lib/types/webpack.dev.d.ts.map +1 -0
- package/lib/types/webpack.prod.d.ts +3 -0
- package/lib/types/webpack.prod.d.ts.map +1 -0
- package/package.json +17 -9
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import './css/Window.less';
|
|
3
|
+
import Drag from './Drag';
|
|
4
|
+
import { ComponentProps } from '@clake/react-bootstrap4';
|
|
5
|
+
interface Props extends ComponentProps {
|
|
6
|
+
title?: string;
|
|
7
|
+
width?: string;
|
|
8
|
+
height?: string;
|
|
9
|
+
x?: string;
|
|
10
|
+
y?: string;
|
|
11
|
+
backColor?: string;
|
|
12
|
+
name?: string;
|
|
13
|
+
parent?: any;
|
|
14
|
+
marginTop?: any;
|
|
15
|
+
isMaxBtn?: boolean;
|
|
16
|
+
isCloseBtn?: boolean;
|
|
17
|
+
isMinBtn?: boolean;
|
|
18
|
+
}
|
|
19
|
+
interface State {
|
|
20
|
+
close: boolean;
|
|
21
|
+
}
|
|
22
|
+
export interface ShowOptions {
|
|
23
|
+
params?: any;
|
|
24
|
+
x?: number;
|
|
25
|
+
y?: number;
|
|
26
|
+
}
|
|
27
|
+
export declare class Window extends React.PureComponent<Props, State> {
|
|
28
|
+
static EVT_RESIZE: string;
|
|
29
|
+
static EVT_MAXWINDOW: string;
|
|
30
|
+
static EVT_SHOW: string;
|
|
31
|
+
static EVT_CLOSE: string;
|
|
32
|
+
static EVT_BEFORE_CLOSE: string;
|
|
33
|
+
static defaultProps: {
|
|
34
|
+
isCloseBtn: boolean;
|
|
35
|
+
isMaxBtn: boolean;
|
|
36
|
+
};
|
|
37
|
+
parent: any;
|
|
38
|
+
data: any;
|
|
39
|
+
evts: any;
|
|
40
|
+
is_before: boolean;
|
|
41
|
+
is_max: boolean;
|
|
42
|
+
max_position: any;
|
|
43
|
+
drag: Drag | undefined;
|
|
44
|
+
dragDom: HTMLElement;
|
|
45
|
+
domHeader: HTMLElement;
|
|
46
|
+
dom: HTMLElement;
|
|
47
|
+
params: any;
|
|
48
|
+
constructor(props: any);
|
|
49
|
+
componentDidMount(): void;
|
|
50
|
+
componentWillUnmount(): void;
|
|
51
|
+
show(option: ShowOptions): void;
|
|
52
|
+
close: () => void;
|
|
53
|
+
hide: () => void;
|
|
54
|
+
move(x: number, y: number): void;
|
|
55
|
+
max(flag: boolean): void;
|
|
56
|
+
setIndex(index: any): void;
|
|
57
|
+
setActive(active: boolean): void;
|
|
58
|
+
getPosition(): {
|
|
59
|
+
top: number;
|
|
60
|
+
left: number;
|
|
61
|
+
height: number;
|
|
62
|
+
width: number;
|
|
63
|
+
};
|
|
64
|
+
maxHandler: (e: any) => void;
|
|
65
|
+
showHandler: (e: any) => void;
|
|
66
|
+
closeHandler: (e?: any) => void;
|
|
67
|
+
beforeCloseHandler: (e: any) => void;
|
|
68
|
+
on(fn_name: string, fn: any): void;
|
|
69
|
+
off(fn_name: string): void;
|
|
70
|
+
trigger(fn_name: string, val: any): void;
|
|
71
|
+
clearEvent(): void;
|
|
72
|
+
getClasses(): string;
|
|
73
|
+
getStyles(shadow?: boolean): any;
|
|
74
|
+
render(): React.ReactPortal;
|
|
75
|
+
renderContent(): any;
|
|
76
|
+
renderEmpty(): null;
|
|
77
|
+
}
|
|
78
|
+
export default Window;
|
|
79
|
+
//# sourceMappingURL=Window.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Window.d.ts","sourceRoot":"","sources":["../../../src/Window.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,OAAO,mBAAmB,CAAC;AAE3B,OAAO,IAAI,MAAM,QAAQ,CAAC;AAE1B,OAAO,EAEH,cAAc,EACjB,MAAM,yBAAyB,CAAC;AAEjC,UAAU,KAAM,SAAQ,cAAc;IAClC,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,CAAC,CAAC,EAAE,MAAM,CAAA;IACV,CAAC,CAAC,EAAE,MAAM,CAAA;IACV,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,MAAM,CAAC,EAAE,GAAG,CAAA;IACZ,SAAS,CAAC,EAAE,GAAG,CAAA;IACf,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,UAAU,CAAC,EAAE,OAAO,CAAA;IACpB,QAAQ,CAAC,EAAE,OAAO,CAAA;CACrB;AAED,UAAU,KAAK;IACX,KAAK,EAAC,OAAO,CAAA;CAChB;AAED,MAAM,WAAW,WAAW;IACxB,MAAM,CAAC,EAAE,GAAG,CAAA;IACZ,CAAC,CAAC,EAAC,MAAM,CAAA;IACT,CAAC,CAAC,EAAC,MAAM,CAAA;CACZ;AAED,qBAAa,MAAO,SAAQ,KAAK,CAAC,aAAa,CAAC,KAAK,EAAC,KAAK,CAAC;IACxD,MAAM,CAAC,UAAU,EAAC,MAAM,CAAA;IACxB,MAAM,CAAC,aAAa,EAAC,MAAM,CAAA;IAC3B,MAAM,CAAC,QAAQ,EAAC,MAAM,CAAA;IACtB,MAAM,CAAC,SAAS,EAAC,MAAM,CAAA;IACvB,MAAM,CA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 'react';
|
|
3
|
+
interface Props extends ComponentProps {
|
|
4
|
+
}
|
|
5
|
+
interface State {
|
|
6
|
+
showWindows: any[];
|
|
7
|
+
}
|
|
8
|
+
export declare class WindowGroup extends React.Component<Props, State> {
|
|
9
|
+
windows: any;
|
|
10
|
+
opens: string[];
|
|
11
|
+
windowList: any;
|
|
12
|
+
currentActive: string;
|
|
13
|
+
constructor(props: any);
|
|
14
|
+
componentDidMount(): void;
|
|
15
|
+
/**
|
|
16
|
+
* open window
|
|
17
|
+
* @param name string
|
|
18
|
+
* @param params object
|
|
19
|
+
*/
|
|
20
|
+
open(name: string, params: any): void;
|
|
21
|
+
show(name: string, params: any): void;
|
|
22
|
+
changeWindowIndex(name: string): void;
|
|
23
|
+
removeWindowOpens(name: string): void;
|
|
24
|
+
close(name: string): void;
|
|
25
|
+
render(): React.DetailedReactHTMLElement<any, HTMLElement>[];
|
|
26
|
+
}
|
|
27
|
+
export default WindowGroup;
|
|
28
|
+
//# sourceMappingURL=WindowGroup.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"WindowGroup.d.ts","sourceRoot":"","sources":["../../../src/WindowGroup.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAC;AACzD,OAAO,KAAK,MAAM,OAAO,CAAC;AAI1B,UAAU,KAAM,SAAQ,cAAc;CAErC;AAED,UAAU,KAAK;IACX,WAAW,EAAC,GAAG,EAAE,CAAA;CACpB;AAED,qBAAa,WAAY,SAAQ,KAAK,CAAC,SAAS,CAAC,KAAK,EAAC,KAAK,CAAC;IACzD,OAAO,EAAC,GAAG,CAAA;IACX,KAAK,EAAC,MAAM,EAAE,CAAA;IACd,UAAU,EAAC,GAAG,CAAA;IACd,aAAa,EAAC,MAAM,CAAA;gBACR,KAAK,EAAC,GAAG;IAoBrB,iBAAiB;IAIjB;;;;OAIG;IACH,IAAI,CAAC,IAAI,EAAC,MAAM,EAAC,MAAM,EAAC,GAAG;IA4B3B,IAAI,CAAC,IAAI,EAAC,MAAM,EAAC,MAAM,EAAC,GAAG;IAW3B,iBAAiB,CAAC,IAAI,EAAC,MAAM;IAa7B,iBAAiB,CAAC,IAAI,EAAC,MAAM;IAY7B,KAAK,CAAC,IAAI,EAAC,MAAM;IAMjB,MAAM;CAgBT;AAED,eAAe,WAAW,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CTable.d.ts","sourceRoot":"","sources":["../../../../src/i18n/CTable.ts"],"names":[],"mappings":"AAkCA,QAAA,MAAM,UAAU,EAAC,GAGhB,CAAC;AAGF,eAAe,UAAU,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/index.js"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
declare namespace _default {
|
|
2
|
+
let plugins: any[];
|
|
3
|
+
namespace output {
|
|
4
|
+
let path: string;
|
|
5
|
+
let filename: string;
|
|
6
|
+
let chunkFilename: string;
|
|
7
|
+
let libraryTarget: string;
|
|
8
|
+
let library: string;
|
|
9
|
+
}
|
|
10
|
+
namespace module {
|
|
11
|
+
let rules: ({
|
|
12
|
+
test: RegExp;
|
|
13
|
+
use: string[];
|
|
14
|
+
exclude?: undefined;
|
|
15
|
+
} | {
|
|
16
|
+
test: RegExp;
|
|
17
|
+
use: string;
|
|
18
|
+
exclude?: undefined;
|
|
19
|
+
} | {
|
|
20
|
+
test: RegExp;
|
|
21
|
+
use: {
|
|
22
|
+
loader: string;
|
|
23
|
+
query: {
|
|
24
|
+
presets: string[];
|
|
25
|
+
};
|
|
26
|
+
};
|
|
27
|
+
exclude: RegExp;
|
|
28
|
+
} | {
|
|
29
|
+
test: RegExp;
|
|
30
|
+
use: (string | {
|
|
31
|
+
loader: string;
|
|
32
|
+
query: {
|
|
33
|
+
presets: string[];
|
|
34
|
+
};
|
|
35
|
+
})[];
|
|
36
|
+
exclude: RegExp;
|
|
37
|
+
})[];
|
|
38
|
+
}
|
|
39
|
+
namespace resolve {
|
|
40
|
+
let extensions: string[];
|
|
41
|
+
}
|
|
42
|
+
namespace node {
|
|
43
|
+
let fs: string;
|
|
44
|
+
}
|
|
45
|
+
let externals: {
|
|
46
|
+
jquery: string;
|
|
47
|
+
react: string;
|
|
48
|
+
"react-dom": string;
|
|
49
|
+
zepto: string;
|
|
50
|
+
marked: string;
|
|
51
|
+
moment: string;
|
|
52
|
+
};
|
|
53
|
+
}
|
|
54
|
+
export default _default;
|
|
55
|
+
//# sourceMappingURL=webpack.common.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"webpack.common.d.ts","sourceRoot":"","sources":["../../webpack.common.js"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"webpack.dev.d.ts","sourceRoot":"","sources":["../../webpack.dev.js"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"webpack.prod.d.ts","sourceRoot":"","sources":["../../webpack.prod.js"],"names":[],"mappings":""}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@clake/react-bootstrap4-window",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "1.0.1",
|
|
4
4
|
"description": "react bootstrap v4 window",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"unpkg": "./dist/react-bootstrap4-window.js",
|
|
@@ -8,6 +8,7 @@
|
|
|
8
8
|
"./dist",
|
|
9
9
|
"./lib"
|
|
10
10
|
],
|
|
11
|
+
"types": "./lib/types/src",
|
|
11
12
|
"scripts": {
|
|
12
13
|
"test": "test",
|
|
13
14
|
"clean": "gulp clean",
|
|
@@ -15,8 +16,9 @@
|
|
|
15
16
|
"start-win": "set NODE_ENV=development&gulp",
|
|
16
17
|
"build": "NODE_OPTIONS=--openssl-legacy-provider NODE_ENV=production gulp build",
|
|
17
18
|
"build-win": "set NODE_ENV=production&gulp build",
|
|
18
|
-
"build-publish": "NODE_OPTIONS=--openssl-legacy-provider gulp build-publish",
|
|
19
|
-
"publish-package": "NODE_OPTIONS=--openssl-legacy-provider gulp publish"
|
|
19
|
+
"build-publish": "NODE_OPTIONS=--openssl-legacy-provider gulp build-publish && tsc -d --declarationDir lib/types --declarationMap --emitDeclarationOnly",
|
|
20
|
+
"publish-package": "NODE_OPTIONS=--openssl-legacy-provider gulp publish",
|
|
21
|
+
"build:types": "tsc -d --declarationDir lib/types --declarationMap --emitDeclarationOnly"
|
|
20
22
|
},
|
|
21
23
|
"repository": {
|
|
22
24
|
"type": "git",
|
|
@@ -44,18 +46,24 @@
|
|
|
44
46
|
"@babel/plugin-transform-runtime": "^7.3.4",
|
|
45
47
|
"@babel/preset-env": "^7.3.4",
|
|
46
48
|
"@babel/preset-react": "^7.0.0",
|
|
49
|
+
"@babel/preset-typescript": "^7.24.1",
|
|
47
50
|
"@babel/register": "^7.0.0",
|
|
48
51
|
"@babel/runtime": "^7.3.4",
|
|
52
|
+
"@types/bootstrap": "^5.2.10",
|
|
53
|
+
"@types/react-dom": "^18.2.22",
|
|
49
54
|
"@types/react-router-dom": "^5.3.3",
|
|
55
|
+
"@typescript-eslint/eslint-plugin": "^5.25.0",
|
|
56
|
+
"@typescript-eslint/parser": "^5.25.0",
|
|
50
57
|
"babel-loader": "^8.0.5",
|
|
51
58
|
"browser-sync": "^2.24.5",
|
|
52
59
|
"connect-history-api-fallback": "^1.5.0",
|
|
53
60
|
"css-loader": "^0.28.7",
|
|
54
61
|
"del": "^3.0.0",
|
|
55
62
|
"es6-promise": "^4.2.8",
|
|
56
|
-
"eslint": "^
|
|
57
|
-
"eslint-
|
|
58
|
-
"eslint-plugin-react
|
|
63
|
+
"eslint": "^7.1.0",
|
|
64
|
+
"eslint-loader": "^4.0.2",
|
|
65
|
+
"eslint-plugin-react": "^7.30.0",
|
|
66
|
+
"eslint-plugin-react-hooks": "^4.5.0",
|
|
59
67
|
"file-loader": "^1.1.5",
|
|
60
68
|
"gulp": "^4.0.2",
|
|
61
69
|
"gulp-babel": "^8.0.0",
|
|
@@ -70,8 +78,8 @@
|
|
|
70
78
|
"path": "^0.12.7",
|
|
71
79
|
"process": "^0.11.10",
|
|
72
80
|
"prop-types": "^15.7.2",
|
|
73
|
-
"react": "^
|
|
74
|
-
"react-dom": "^
|
|
81
|
+
"react": "^18.2.0",
|
|
82
|
+
"react-dom": "^18.2.0",
|
|
75
83
|
"react-hot-loader": "^4.12.19",
|
|
76
84
|
"react-router": "^4.3.1",
|
|
77
85
|
"react-router-dom": "^4.3.1",
|
|
@@ -83,7 +91,7 @@
|
|
|
83
91
|
"whatwg-fetch": "^3.0.0"
|
|
84
92
|
},
|
|
85
93
|
"dependencies": {
|
|
86
|
-
"@clake/react-bootstrap4": "^2.
|
|
94
|
+
"@clake/react-bootstrap4": "^2.1.1",
|
|
87
95
|
"classnames": "^2.2.5",
|
|
88
96
|
"natives": "^1.1.6"
|
|
89
97
|
}
|