jrs-react 1.2.10 → 1.2.12
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/build/index.es.js +152 -91
- package/build/index.js +152 -91
- package/package.json +1 -1
- package/src/components/JRInput/JRButton.jsx +2 -0
- package/src/components/JRWindow/TitleBar.jsx +3 -3
package/build/index.es.js
CHANGED
|
@@ -2807,7 +2807,7 @@ function requireReact () {
|
|
|
2807
2807
|
}
|
|
2808
2808
|
|
|
2809
2809
|
var reactExports = requireReact();
|
|
2810
|
-
var React
|
|
2810
|
+
var React = /*@__PURE__*/getDefaultExportFromCjs(reactExports);
|
|
2811
2811
|
|
|
2812
2812
|
function bind(fn, thisArg) {
|
|
2813
2813
|
return function wrap() {
|
|
@@ -6066,7 +6066,7 @@ const whatType = ({
|
|
|
6066
6066
|
// const style=flexType(typeStyle,me,{},{})
|
|
6067
6067
|
// return 'type'
|
|
6068
6068
|
const typeStyle = typeof _typeStyle === 'function' ? _typeStyle?.bind(me)() : _typeStyle;
|
|
6069
|
-
return /*#__PURE__*/React
|
|
6069
|
+
return /*#__PURE__*/React.createElement(type, {
|
|
6070
6070
|
style: typeStyle
|
|
6071
6071
|
});
|
|
6072
6072
|
} else if (render) {
|
|
@@ -6217,9 +6217,9 @@ const StyledCover = styled.div`
|
|
|
6217
6217
|
const Cover = ({
|
|
6218
6218
|
children
|
|
6219
6219
|
}) => {
|
|
6220
|
-
return /*#__PURE__*/React
|
|
6220
|
+
return /*#__PURE__*/React.createElement(StyledCover, null, children);
|
|
6221
6221
|
};
|
|
6222
|
-
class JRSubmit extends React
|
|
6222
|
+
class JRSubmit extends React.Component {
|
|
6223
6223
|
#methods = ['get', 'post', 'put', 'patch', 'delete', 'download'];
|
|
6224
6224
|
constructor(props) {
|
|
6225
6225
|
super(props);
|
|
@@ -6476,7 +6476,7 @@ class JRSubmit extends React$1.Component {
|
|
|
6476
6476
|
return;
|
|
6477
6477
|
}
|
|
6478
6478
|
render() {
|
|
6479
|
-
return this.props.cover != null && this.state?.lodaing ? /*#__PURE__*/React
|
|
6479
|
+
return this.props.cover != null && this.state?.lodaing ? /*#__PURE__*/React.createElement(Cover, null, flexType(this.props.cover, this, null, null)) : this.renderer();
|
|
6480
6480
|
}
|
|
6481
6481
|
}
|
|
6482
6482
|
|
|
@@ -6494,12 +6494,12 @@ const FreeType$1 = ({
|
|
|
6494
6494
|
const content = config.bind(me)({
|
|
6495
6495
|
setStyle
|
|
6496
6496
|
});
|
|
6497
|
-
return /*#__PURE__*/React
|
|
6497
|
+
return /*#__PURE__*/React.createElement(Tag, {
|
|
6498
6498
|
className: className,
|
|
6499
6499
|
style: style
|
|
6500
6500
|
}, content);
|
|
6501
6501
|
} else if (typeof config === 'string') {
|
|
6502
|
-
return /*#__PURE__*/React
|
|
6502
|
+
return /*#__PURE__*/React.createElement(Tag, {
|
|
6503
6503
|
className: className
|
|
6504
6504
|
}, config);
|
|
6505
6505
|
}
|
|
@@ -6541,33 +6541,33 @@ const StyledJRFrame$1 = styled.div`
|
|
|
6541
6541
|
`;
|
|
6542
6542
|
class JRFrame extends JRSubmit {
|
|
6543
6543
|
renderer() {
|
|
6544
|
-
return /*#__PURE__*/React
|
|
6544
|
+
return /*#__PURE__*/React.createElement(StyledJRFrame$1, {
|
|
6545
6545
|
style: this.props.style,
|
|
6546
6546
|
className: `${this.props.className} jr-frame`
|
|
6547
|
-
}, /*#__PURE__*/React
|
|
6547
|
+
}, /*#__PURE__*/React.createElement(FreeType$1, {
|
|
6548
6548
|
tag: "div",
|
|
6549
6549
|
config: this.props.start,
|
|
6550
6550
|
me: this,
|
|
6551
6551
|
className: 'start'
|
|
6552
|
-
}), /*#__PURE__*/React
|
|
6552
|
+
}), /*#__PURE__*/React.createElement("main", null, /*#__PURE__*/React.createElement(FreeType$1, {
|
|
6553
6553
|
tag: "header",
|
|
6554
6554
|
config: this.props.top,
|
|
6555
6555
|
me: this
|
|
6556
|
-
}), /*#__PURE__*/React
|
|
6556
|
+
}), /*#__PURE__*/React.createElement("main", null, /*#__PURE__*/React.createElement(FreeType$1, {
|
|
6557
6557
|
tag: "div",
|
|
6558
6558
|
config: this.props.left,
|
|
6559
6559
|
me: this,
|
|
6560
6560
|
className: 'left'
|
|
6561
|
-
}), this.renderMe?.() ?? this.props.children, /*#__PURE__*/React
|
|
6561
|
+
}), this.renderMe?.() ?? this.props.children, /*#__PURE__*/React.createElement(FreeType$1, {
|
|
6562
6562
|
tag: "div",
|
|
6563
6563
|
config: this.props.right,
|
|
6564
6564
|
me: this,
|
|
6565
6565
|
className: 'right'
|
|
6566
|
-
})), /*#__PURE__*/React
|
|
6566
|
+
})), /*#__PURE__*/React.createElement(FreeType$1, {
|
|
6567
6567
|
tag: "footer",
|
|
6568
6568
|
config: this.props.bottom,
|
|
6569
6569
|
me: this
|
|
6570
|
-
})), /*#__PURE__*/React
|
|
6570
|
+
})), /*#__PURE__*/React.createElement(FreeType$1, {
|
|
6571
6571
|
tag: "div",
|
|
6572
6572
|
config: this.props.end,
|
|
6573
6573
|
me: this,
|
|
@@ -6594,10 +6594,10 @@ const StyledSlider$1 = styled.div`
|
|
|
6594
6594
|
border-right:1px dashed gray;
|
|
6595
6595
|
}
|
|
6596
6596
|
`;
|
|
6597
|
-
class Slider$1 extends React
|
|
6597
|
+
class Slider$1 extends React.Component {
|
|
6598
6598
|
constructor() {
|
|
6599
6599
|
super();
|
|
6600
|
-
this.sliderRef = /*#__PURE__*/React
|
|
6600
|
+
this.sliderRef = /*#__PURE__*/React.createRef();
|
|
6601
6601
|
}
|
|
6602
6602
|
stop = e => {
|
|
6603
6603
|
this.sliderRef.current.classList.remove('resizing');
|
|
@@ -6646,7 +6646,7 @@ class Slider$1 extends React$1.Component {
|
|
|
6646
6646
|
}
|
|
6647
6647
|
render() {
|
|
6648
6648
|
const column = this.props.column;
|
|
6649
|
-
return /*#__PURE__*/React
|
|
6649
|
+
return /*#__PURE__*/React.createElement(StyledSlider$1, {
|
|
6650
6650
|
ref: this.sliderRef,
|
|
6651
6651
|
onMouseDown: e => {
|
|
6652
6652
|
this.start(this.props.thRef, column);
|
|
@@ -6659,7 +6659,7 @@ const Colgroup = ({
|
|
|
6659
6659
|
leafColumns,
|
|
6660
6660
|
colGroupRef
|
|
6661
6661
|
}) => {
|
|
6662
|
-
return /*#__PURE__*/React
|
|
6662
|
+
return /*#__PURE__*/React.createElement("colgroup", {
|
|
6663
6663
|
ref: colGroupRef
|
|
6664
6664
|
}, leafColumns?.map((_column, index) => {
|
|
6665
6665
|
const {
|
|
@@ -6669,7 +6669,7 @@ const Colgroup = ({
|
|
|
6669
6669
|
const style = {
|
|
6670
6670
|
width
|
|
6671
6671
|
};
|
|
6672
|
-
return /*#__PURE__*/React
|
|
6672
|
+
return /*#__PURE__*/React.createElement("col", {
|
|
6673
6673
|
style: style,
|
|
6674
6674
|
key: index
|
|
6675
6675
|
});
|
|
@@ -6682,13 +6682,13 @@ const Ths$1 = ({
|
|
|
6682
6682
|
table
|
|
6683
6683
|
}) => {
|
|
6684
6684
|
return rowColumn?.map((column, colIndex) => {
|
|
6685
|
-
const thRef = /*#__PURE__*/React
|
|
6686
|
-
return /*#__PURE__*/React
|
|
6685
|
+
const thRef = /*#__PURE__*/React.createRef();
|
|
6686
|
+
return /*#__PURE__*/React.createElement("th", {
|
|
6687
6687
|
key: colIndex,
|
|
6688
6688
|
ref: thRef,
|
|
6689
6689
|
colSpan: column.colSpan,
|
|
6690
6690
|
rowSpan: column.rowSpan ?? (column.isLeaf && deep > rowIndex ? deep - rowIndex + 1 : null)
|
|
6691
|
-
}, flexType(column.label, table), table.props.resizableColumns === true && /*#__PURE__*/React
|
|
6691
|
+
}, flexType(column.label, table), table.props.resizableColumns === true && /*#__PURE__*/React.createElement(Slider$1, {
|
|
6692
6692
|
table: table,
|
|
6693
6693
|
thRef: thRef,
|
|
6694
6694
|
column: column
|
|
@@ -6702,10 +6702,10 @@ const HeadTrs = ({
|
|
|
6702
6702
|
}) => {
|
|
6703
6703
|
const columns = Array.isArray(_columns?.[0]) ? _columns : [_columns];
|
|
6704
6704
|
return columns?.map((rowColumn, rowIndex) => {
|
|
6705
|
-
return /*#__PURE__*/React
|
|
6705
|
+
return /*#__PURE__*/React.createElement("tr", {
|
|
6706
6706
|
className: trClassName,
|
|
6707
6707
|
key: rowIndex
|
|
6708
|
-
}, /*#__PURE__*/React
|
|
6708
|
+
}, /*#__PURE__*/React.createElement(Ths$1, {
|
|
6709
6709
|
deep: columns.length - 1,
|
|
6710
6710
|
rowColumn: rowColumn,
|
|
6711
6711
|
rowIndex: rowIndex,
|
|
@@ -6718,10 +6718,10 @@ const THead = ({
|
|
|
6718
6718
|
leafColumns,
|
|
6719
6719
|
table
|
|
6720
6720
|
}) => {
|
|
6721
|
-
return /*#__PURE__*/React
|
|
6721
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("thead", null, /*#__PURE__*/React.createElement(HeadTrs, {
|
|
6722
6722
|
columns: columns,
|
|
6723
6723
|
table: table
|
|
6724
|
-
})), /*#__PURE__*/React
|
|
6724
|
+
})), /*#__PURE__*/React.createElement(Colgroup, {
|
|
6725
6725
|
leafColumns: leafColumns,
|
|
6726
6726
|
colGroupRef: table.colGroupRef
|
|
6727
6727
|
}));
|
|
@@ -6746,7 +6746,7 @@ const FootThs = ({
|
|
|
6746
6746
|
// }
|
|
6747
6747
|
let style = flexType(column.style, table, {}, {});
|
|
6748
6748
|
const content = whatType(column, table, column.label);
|
|
6749
|
-
return /*#__PURE__*/React
|
|
6749
|
+
return /*#__PURE__*/React.createElement("th", {
|
|
6750
6750
|
style: style,
|
|
6751
6751
|
colSpan: column.colSpan,
|
|
6752
6752
|
rowSpan: column.rowSpan
|
|
@@ -6758,24 +6758,24 @@ const TFoot = ({
|
|
|
6758
6758
|
columns
|
|
6759
6759
|
}) => {
|
|
6760
6760
|
const trs = columns?.map((rowColumn, rowIndex) => {
|
|
6761
|
-
return /*#__PURE__*/React
|
|
6761
|
+
return /*#__PURE__*/React.createElement("tr", {
|
|
6762
6762
|
key: rowIndex
|
|
6763
|
-
}, /*#__PURE__*/React
|
|
6763
|
+
}, /*#__PURE__*/React.createElement(FootThs, {
|
|
6764
6764
|
columns: rowColumn,
|
|
6765
6765
|
table: table
|
|
6766
6766
|
}));
|
|
6767
6767
|
});
|
|
6768
|
-
return /*#__PURE__*/React
|
|
6768
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("tfoot", null, trs));
|
|
6769
6769
|
};
|
|
6770
6770
|
|
|
6771
|
-
function _extends() {
|
|
6772
|
-
return _extends = Object.assign ? Object.assign.bind() : function (n) {
|
|
6771
|
+
function _extends$3() {
|
|
6772
|
+
return _extends$3 = Object.assign ? Object.assign.bind() : function (n) {
|
|
6773
6773
|
for (var e = 1; e < arguments.length; e++) {
|
|
6774
6774
|
var t = arguments[e];
|
|
6775
6775
|
for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]);
|
|
6776
6776
|
}
|
|
6777
6777
|
return n;
|
|
6778
|
-
}, _extends.apply(null, arguments);
|
|
6778
|
+
}, _extends$3.apply(null, arguments);
|
|
6779
6779
|
}
|
|
6780
6780
|
|
|
6781
6781
|
styled.tbody`
|
|
@@ -6816,7 +6816,7 @@ const Ths = ({
|
|
|
6816
6816
|
content = column.label;
|
|
6817
6817
|
}
|
|
6818
6818
|
// style.textAlign=align
|
|
6819
|
-
return /*#__PURE__*/React
|
|
6819
|
+
return /*#__PURE__*/React.createElement("th", {
|
|
6820
6820
|
key: colIndex,
|
|
6821
6821
|
style: {
|
|
6822
6822
|
textAlign: align,
|
|
@@ -6836,10 +6836,10 @@ const GroupColumns = ({
|
|
|
6836
6836
|
}) => {
|
|
6837
6837
|
const columns = Array.isArray(_columns?.[0]) ? _columns : [_columns];
|
|
6838
6838
|
return columns?.map((rowColumn, rowIndex) => {
|
|
6839
|
-
return /*#__PURE__*/React
|
|
6839
|
+
return /*#__PURE__*/React.createElement("tr", {
|
|
6840
6840
|
className: trClassName,
|
|
6841
6841
|
key: rowIndex
|
|
6842
|
-
}, /*#__PURE__*/React
|
|
6842
|
+
}, /*#__PURE__*/React.createElement(Ths, {
|
|
6843
6843
|
table: table,
|
|
6844
6844
|
groupData: groupData,
|
|
6845
6845
|
groupIndex: tbodyIndex,
|
|
@@ -6859,7 +6859,7 @@ styled.tr`
|
|
|
6859
6859
|
}
|
|
6860
6860
|
`;
|
|
6861
6861
|
const GroupHeader = props => {
|
|
6862
|
-
return /*#__PURE__*/React
|
|
6862
|
+
return /*#__PURE__*/React.createElement(GroupColumns, _extends$3({
|
|
6863
6863
|
trClassName: 'jr-group-header'
|
|
6864
6864
|
}, props));
|
|
6865
6865
|
};
|
|
@@ -6870,7 +6870,7 @@ styled.tr`
|
|
|
6870
6870
|
}
|
|
6871
6871
|
`;
|
|
6872
6872
|
const GroupFooter = props => {
|
|
6873
|
-
return /*#__PURE__*/React
|
|
6873
|
+
return /*#__PURE__*/React.createElement(GroupColumns, _extends$3({
|
|
6874
6874
|
trClassName: 'jr-group-footer'
|
|
6875
6875
|
}, props));
|
|
6876
6876
|
};
|
|
@@ -6917,7 +6917,7 @@ const Td = ({
|
|
|
6917
6917
|
const typeStyle = flexType(_typeStyle, table, {
|
|
6918
6918
|
record
|
|
6919
6919
|
}, {});
|
|
6920
|
-
content = /*#__PURE__*/React
|
|
6920
|
+
content = /*#__PURE__*/React.createElement(type, {
|
|
6921
6921
|
onChange: _onChange ? e => {
|
|
6922
6922
|
_onChange?.bind(table)(e, {
|
|
6923
6923
|
value,
|
|
@@ -6945,7 +6945,7 @@ const Td = ({
|
|
|
6945
6945
|
} else {
|
|
6946
6946
|
content = value;
|
|
6947
6947
|
}
|
|
6948
|
-
return /*#__PURE__*/React
|
|
6948
|
+
return /*#__PURE__*/React.createElement("td", {
|
|
6949
6949
|
colSpan: style.colSpan,
|
|
6950
6950
|
rowSpan: style.rowSpan,
|
|
6951
6951
|
style: {
|
|
@@ -6964,7 +6964,7 @@ const Tds = ({
|
|
|
6964
6964
|
trIndex
|
|
6965
6965
|
}) => {
|
|
6966
6966
|
return leafColumns?.map((column, tdIndex) => {
|
|
6967
|
-
return /*#__PURE__*/React
|
|
6967
|
+
return /*#__PURE__*/React.createElement(Td, {
|
|
6968
6968
|
column: column,
|
|
6969
6969
|
key: tdIndex,
|
|
6970
6970
|
record: record,
|
|
@@ -6989,14 +6989,14 @@ const TBody = ({
|
|
|
6989
6989
|
table,
|
|
6990
6990
|
tbodyIndex
|
|
6991
6991
|
};
|
|
6992
|
-
return /*#__PURE__*/React
|
|
6992
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("tbody", {
|
|
6993
6993
|
key: `tbody${tbodyIndex}`
|
|
6994
|
-
}, groupData?.length > 0 && /*#__PURE__*/React
|
|
6994
|
+
}, groupData?.length > 0 && /*#__PURE__*/React.createElement(GroupHeader, _extends$3({
|
|
6995
6995
|
groupData: groupData,
|
|
6996
6996
|
columns: groupHeader
|
|
6997
6997
|
}, neededProps)), groupData?.map?.((record, trIndex) => {
|
|
6998
6998
|
const onRowClick = table.props.onRowClick?.bind(table);
|
|
6999
|
-
return /*#__PURE__*/React
|
|
6999
|
+
return /*#__PURE__*/React.createElement("tr", {
|
|
7000
7000
|
key: trIndex,
|
|
7001
7001
|
onClick: () => {
|
|
7002
7002
|
onRowClick?.({
|
|
@@ -7005,13 +7005,13 @@ const TBody = ({
|
|
|
7005
7005
|
groupIndex: tbodyIndex
|
|
7006
7006
|
});
|
|
7007
7007
|
}
|
|
7008
|
-
}, /*#__PURE__*/React
|
|
7008
|
+
}, /*#__PURE__*/React.createElement(Tds, _extends$3({
|
|
7009
7009
|
record: record,
|
|
7010
7010
|
trIndex: trIndex
|
|
7011
7011
|
}, neededProps, {
|
|
7012
7012
|
leafColumns: leafColumns
|
|
7013
7013
|
})));
|
|
7014
|
-
}), groupData?.length > 0 && /*#__PURE__*/React
|
|
7014
|
+
}), groupData?.length > 0 && /*#__PURE__*/React.createElement(GroupFooter, _extends$3({
|
|
7015
7015
|
groupData: groupData,
|
|
7016
7016
|
columns: groupFooter
|
|
7017
7017
|
}, neededProps))));
|
|
@@ -7029,7 +7029,7 @@ const TBodies = ({
|
|
|
7029
7029
|
|
|
7030
7030
|
// po('dataSource',dataSource)
|
|
7031
7031
|
return dataSource?.map((groupData, tbodyIndex, c) => {
|
|
7032
|
-
return /*#__PURE__*/React
|
|
7032
|
+
return /*#__PURE__*/React.createElement(TBody, {
|
|
7033
7033
|
key: `tbody${tbodyIndex}`,
|
|
7034
7034
|
table: table
|
|
7035
7035
|
// dataSource={dataSource}
|
|
@@ -7177,6 +7177,62 @@ const StyledJRTable = styled.div`
|
|
|
7177
7177
|
}
|
|
7178
7178
|
`;
|
|
7179
7179
|
|
|
7180
|
+
var _path$1;
|
|
7181
|
+
function _extends$2() { return _extends$2 = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends$2.apply(null, arguments); }
|
|
7182
|
+
var SvgX = function SvgX(props) {
|
|
7183
|
+
return /*#__PURE__*/reactExports.createElement("svg", _extends$2({
|
|
7184
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
7185
|
+
width: 24,
|
|
7186
|
+
height: 24,
|
|
7187
|
+
fill: "none",
|
|
7188
|
+
stroke: "currentColor",
|
|
7189
|
+
strokeLinecap: "round",
|
|
7190
|
+
strokeLinejoin: "round",
|
|
7191
|
+
strokeWidth: 2
|
|
7192
|
+
}, props), _path$1 || (_path$1 = /*#__PURE__*/reactExports.createElement("path", {
|
|
7193
|
+
d: "M18 6 6 18M6 6l12 12"
|
|
7194
|
+
})));
|
|
7195
|
+
};
|
|
7196
|
+
|
|
7197
|
+
var _rect;
|
|
7198
|
+
function _extends$1() { return _extends$1 = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends$1.apply(null, arguments); }
|
|
7199
|
+
var SvgSquare = function SvgSquare(props) {
|
|
7200
|
+
return /*#__PURE__*/reactExports.createElement("svg", _extends$1({
|
|
7201
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
7202
|
+
width: 24,
|
|
7203
|
+
height: 24,
|
|
7204
|
+
fill: "none",
|
|
7205
|
+
stroke: "currentColor",
|
|
7206
|
+
strokeLinecap: "round",
|
|
7207
|
+
strokeLinejoin: "round",
|
|
7208
|
+
strokeWidth: 2
|
|
7209
|
+
}, props), _rect || (_rect = /*#__PURE__*/reactExports.createElement("rect", {
|
|
7210
|
+
width: 18,
|
|
7211
|
+
height: 18,
|
|
7212
|
+
x: 3,
|
|
7213
|
+
y: 3,
|
|
7214
|
+
rx: 2,
|
|
7215
|
+
ry: 2
|
|
7216
|
+
})));
|
|
7217
|
+
};
|
|
7218
|
+
|
|
7219
|
+
var _path;
|
|
7220
|
+
function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
|
|
7221
|
+
var SvgMinus = function SvgMinus(props) {
|
|
7222
|
+
return /*#__PURE__*/reactExports.createElement("svg", _extends({
|
|
7223
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
7224
|
+
width: 24,
|
|
7225
|
+
height: 24,
|
|
7226
|
+
fill: "none",
|
|
7227
|
+
stroke: "currentColor",
|
|
7228
|
+
strokeLinecap: "round",
|
|
7229
|
+
strokeLinejoin: "round",
|
|
7230
|
+
strokeWidth: 2
|
|
7231
|
+
}, props), _path || (_path = /*#__PURE__*/reactExports.createElement("path", {
|
|
7232
|
+
d: "M5 12h14"
|
|
7233
|
+
})));
|
|
7234
|
+
};
|
|
7235
|
+
|
|
7180
7236
|
function JRButton({
|
|
7181
7237
|
icon,
|
|
7182
7238
|
children,
|
|
@@ -7242,7 +7298,7 @@ const StyledTitle = styled.div`
|
|
|
7242
7298
|
}
|
|
7243
7299
|
}
|
|
7244
7300
|
`;
|
|
7245
|
-
class TitleBar extends React
|
|
7301
|
+
class TitleBar extends React.Component {
|
|
7246
7302
|
pos1 = 0;
|
|
7247
7303
|
pos2 = 0;
|
|
7248
7304
|
pos3 = 0;
|
|
@@ -7320,18 +7376,23 @@ class TitleBar extends React$1.Component {
|
|
|
7320
7376
|
window.addEventListener('mouseup', this.stop);
|
|
7321
7377
|
}
|
|
7322
7378
|
render() {
|
|
7323
|
-
return /*#__PURE__*/React
|
|
7379
|
+
return /*#__PURE__*/React.createElement(StyledTitle, {
|
|
7324
7380
|
ref: this.props.titleBarRef,
|
|
7325
7381
|
draggable: "false",
|
|
7326
7382
|
onMouseDown: e => {
|
|
7327
7383
|
this.start(e);
|
|
7328
7384
|
}
|
|
7329
|
-
}, /*#__PURE__*/React
|
|
7385
|
+
}, /*#__PURE__*/React.createElement(FreeType$1, {
|
|
7330
7386
|
tag: "div",
|
|
7331
7387
|
config: this.props.title ?? '',
|
|
7332
7388
|
me: this.props.window,
|
|
7333
7389
|
className: 'title'
|
|
7334
|
-
}), /*#__PURE__*/React
|
|
7390
|
+
}), /*#__PURE__*/React.createElement("nav", null, /*#__PURE__*/React.createElement(JRButton, {
|
|
7391
|
+
icon: /*#__PURE__*/React.createElement(SvgMinus, null)
|
|
7392
|
+
}), /*#__PURE__*/React.createElement(JRButton, {
|
|
7393
|
+
icon: /*#__PURE__*/React.createElement(SvgSquare, null)
|
|
7394
|
+
}), this.props.window.props.setOpen ? /*#__PURE__*/React.createElement(JRButton, {
|
|
7395
|
+
icon: /*#__PURE__*/React.createElement(SvgX, null),
|
|
7335
7396
|
className: 'danger',
|
|
7336
7397
|
onClick: () => {
|
|
7337
7398
|
this.props.window.props.setOpen(false);
|
|
@@ -7341,9 +7402,9 @@ class TitleBar extends React$1.Component {
|
|
|
7341
7402
|
}
|
|
7342
7403
|
|
|
7343
7404
|
const directions = ['n', 'e', 's', 'w', 'nww', 'nnw', 'nne', 'nee', 'sse', 'see', 'sww', 'ssw'];
|
|
7344
|
-
class Sliders extends React
|
|
7405
|
+
class Sliders extends React.Component {
|
|
7345
7406
|
render() {
|
|
7346
|
-
return directions.map((direction, index) => /*#__PURE__*/React
|
|
7407
|
+
return directions.map((direction, index) => /*#__PURE__*/React.createElement(Slider, {
|
|
7347
7408
|
direction: direction,
|
|
7348
7409
|
thick: this.props.thick,
|
|
7349
7410
|
windowRef: this.props.windowRef,
|
|
@@ -7408,13 +7469,13 @@ const StyledSlider = styled.div`
|
|
|
7408
7469
|
user-select: none;
|
|
7409
7470
|
|
|
7410
7471
|
`;
|
|
7411
|
-
class Slider extends React
|
|
7472
|
+
class Slider extends React.Component {
|
|
7412
7473
|
width = '3px';
|
|
7413
7474
|
borderWidth = 'px';
|
|
7414
7475
|
borderLong = 30;
|
|
7415
7476
|
constructor(props) {
|
|
7416
7477
|
super(props);
|
|
7417
|
-
this.sliderRef = /*#__PURE__*/React
|
|
7478
|
+
this.sliderRef = /*#__PURE__*/React.createRef();
|
|
7418
7479
|
}
|
|
7419
7480
|
directions = {
|
|
7420
7481
|
n: {
|
|
@@ -7711,7 +7772,7 @@ class Slider extends React$1.Component {
|
|
|
7711
7772
|
window.addEventListener('mouseup', this.stop);
|
|
7712
7773
|
};
|
|
7713
7774
|
render() {
|
|
7714
|
-
return /*#__PURE__*/React
|
|
7775
|
+
return /*#__PURE__*/React.createElement(StyledSlider, {
|
|
7715
7776
|
$direction: this.directions[this.props.direction],
|
|
7716
7777
|
$padding: this.props.padding,
|
|
7717
7778
|
onMouseDown: e => {
|
|
@@ -7776,8 +7837,8 @@ class JRWindow extends JRFrame {
|
|
|
7776
7837
|
thick = 5;
|
|
7777
7838
|
constructor(props) {
|
|
7778
7839
|
super(props);
|
|
7779
|
-
this.ref = /*#__PURE__*/React
|
|
7780
|
-
this.titleBarRef = /*#__PURE__*/React
|
|
7840
|
+
this.ref = /*#__PURE__*/React.createRef();
|
|
7841
|
+
this.titleBarRef = /*#__PURE__*/React.createRef();
|
|
7781
7842
|
this.init();
|
|
7782
7843
|
}
|
|
7783
7844
|
componentWillUpdate(prevProps, prevState, snapshot) {
|
|
@@ -7792,7 +7853,7 @@ class JRWindow extends JRFrame {
|
|
|
7792
7853
|
this.y = this.props.y ?? (window.innerHeight - (this.height ?? 300)) / 2;
|
|
7793
7854
|
}
|
|
7794
7855
|
renderer() {
|
|
7795
|
-
return this.props.popup === true ? this.props.open === true ? /*#__PURE__*/React
|
|
7856
|
+
return this.props.popup === true ? this.props.open === true ? /*#__PURE__*/React.createElement(StyledJRWindow, {
|
|
7796
7857
|
ref: this.ref,
|
|
7797
7858
|
className: `jr-window ${this.props.className ?? ''}`,
|
|
7798
7859
|
$x: this.x,
|
|
@@ -7800,13 +7861,13 @@ class JRWindow extends JRFrame {
|
|
|
7800
7861
|
$width: this.width,
|
|
7801
7862
|
$height: this.height,
|
|
7802
7863
|
$thick: this.thick
|
|
7803
|
-
}, /*#__PURE__*/React
|
|
7864
|
+
}, /*#__PURE__*/React.createElement("main", null, /*#__PURE__*/React.createElement(TitleBar, {
|
|
7804
7865
|
titleBarRef: this.titleBarRef,
|
|
7805
7866
|
windowRef: this.ref,
|
|
7806
7867
|
window: this,
|
|
7807
7868
|
title: this.props.title,
|
|
7808
7869
|
thick: this.thick
|
|
7809
|
-
}), /*#__PURE__*/React
|
|
7870
|
+
}), /*#__PURE__*/React.createElement("main", null, super.renderer())), /*#__PURE__*/React.createElement(Sliders, {
|
|
7810
7871
|
thick: this.thick,
|
|
7811
7872
|
windowRef: this.ref,
|
|
7812
7873
|
window: this,
|
|
@@ -7837,7 +7898,7 @@ const setMapObject = (map, names, value) => {
|
|
|
7837
7898
|
class JRTable extends JRWindow {
|
|
7838
7899
|
constructor(props) {
|
|
7839
7900
|
super(props);
|
|
7840
|
-
this.colGroupRef = /*#__PURE__*/React
|
|
7901
|
+
this.colGroupRef = /*#__PURE__*/React.createRef();
|
|
7841
7902
|
}
|
|
7842
7903
|
UNSAFE_componentWillMount() {
|
|
7843
7904
|
this.setColumns(this.props.columns ?? []);
|
|
@@ -7854,7 +7915,7 @@ class JRTable extends JRWindow {
|
|
|
7854
7915
|
value,
|
|
7855
7916
|
onChange
|
|
7856
7917
|
}) {
|
|
7857
|
-
return /*#__PURE__*/React
|
|
7918
|
+
return /*#__PURE__*/React.createElement("checkbox", {
|
|
7858
7919
|
checked: value,
|
|
7859
7920
|
onChange: e => {
|
|
7860
7921
|
onChange(e.target.checked);
|
|
@@ -7893,7 +7954,7 @@ class JRTable extends JRWindow {
|
|
|
7893
7954
|
value,
|
|
7894
7955
|
onChange
|
|
7895
7956
|
}) {
|
|
7896
|
-
return /*#__PURE__*/React
|
|
7957
|
+
return /*#__PURE__*/React.createElement("checkbox", {
|
|
7897
7958
|
checked: value,
|
|
7898
7959
|
onChange: e => {
|
|
7899
7960
|
onChange(e.target.checked);
|
|
@@ -7903,7 +7964,7 @@ class JRTable extends JRWindow {
|
|
|
7903
7964
|
align: 'center',
|
|
7904
7965
|
name,
|
|
7905
7966
|
label() {
|
|
7906
|
-
return /*#__PURE__*/React
|
|
7967
|
+
return /*#__PURE__*/React.createElement("button", {
|
|
7907
7968
|
onClick: () => {
|
|
7908
7969
|
const value = this.props.delete.value ?? this.getDataSource()?.filter(record => record[name]).map(record => sendValue ? record[sendValue] : record);
|
|
7909
7970
|
const callback = this.props.delete.callback ?? function (a, b, c) {
|
|
@@ -8026,25 +8087,25 @@ class JRTable extends JRWindow {
|
|
|
8026
8087
|
}
|
|
8027
8088
|
//------------------------------------------------------------------------------------
|
|
8028
8089
|
renderMe() {
|
|
8029
|
-
return /*#__PURE__*/React
|
|
8090
|
+
return /*#__PURE__*/React.createElement(StyledJRTable, {
|
|
8030
8091
|
className: `${this.props.className ?? ''} jr-table ${this.props.onRowClick ? 'row-highlightable' : ''}`
|
|
8031
|
-
}, /*#__PURE__*/React
|
|
8092
|
+
}, /*#__PURE__*/React.createElement("table", {
|
|
8032
8093
|
className: 'jr-table-table'
|
|
8033
|
-
}, /*#__PURE__*/React
|
|
8094
|
+
}, /*#__PURE__*/React.createElement(TBodies, {
|
|
8034
8095
|
table: this,
|
|
8035
8096
|
leafColumns: this.state.leafColumns,
|
|
8036
8097
|
groupHeader: this.props.groupHeader,
|
|
8037
8098
|
groupFooter: this.props.groupFooter,
|
|
8038
8099
|
dataSource: this.getDataSource(),
|
|
8039
8100
|
onRowClick: this.props.onRowClick
|
|
8040
|
-
}), /*#__PURE__*/React
|
|
8101
|
+
}), /*#__PURE__*/React.createElement(TFoot, {
|
|
8041
8102
|
columns: this.props.footColumns,
|
|
8042
8103
|
table: this
|
|
8043
|
-
}), /*#__PURE__*/React
|
|
8104
|
+
}), /*#__PURE__*/React.createElement(THead, {
|
|
8044
8105
|
columns: this.state.columns,
|
|
8045
8106
|
leafColumns: this.state.leafColumns,
|
|
8046
8107
|
table: this
|
|
8047
|
-
})), /*#__PURE__*/React
|
|
8108
|
+
})), /*#__PURE__*/React.createElement("div", {
|
|
8048
8109
|
className: 'empty'
|
|
8049
8110
|
}, this.noData() && '無資料'));
|
|
8050
8111
|
}
|
|
@@ -8393,12 +8454,12 @@ class JRFields extends JRWindow {
|
|
|
8393
8454
|
}
|
|
8394
8455
|
if (type) {
|
|
8395
8456
|
const typeStyle = flexType(_typeStyle, this, null);
|
|
8396
|
-
content = /*#__PURE__*/React
|
|
8457
|
+
content = /*#__PURE__*/React.createElement(StyledColumnValue, {
|
|
8397
8458
|
className: 'jr-column-value',
|
|
8398
8459
|
style: {
|
|
8399
8460
|
gridColumn: label == null ? 'span 2' : null
|
|
8400
8461
|
}
|
|
8401
|
-
}, /*#__PURE__*/React
|
|
8462
|
+
}, /*#__PURE__*/React.createElement(type, {
|
|
8402
8463
|
value: value,
|
|
8403
8464
|
onChange,
|
|
8404
8465
|
record: parentValue,
|
|
@@ -8409,13 +8470,13 @@ class JRFields extends JRWindow {
|
|
|
8409
8470
|
...column
|
|
8410
8471
|
}));
|
|
8411
8472
|
} else if (column.columns) {
|
|
8412
|
-
content = /*#__PURE__*/React
|
|
8473
|
+
content = /*#__PURE__*/React.createElement(StyledGrid, {
|
|
8413
8474
|
cols: column.cols,
|
|
8414
8475
|
className: 'jr-grid',
|
|
8415
8476
|
$gap: gap
|
|
8416
8477
|
}, this.createColumns(value, column.columns, _parentName, fullname));
|
|
8417
8478
|
} else if (name || column.render) {
|
|
8418
|
-
content = /*#__PURE__*/React
|
|
8479
|
+
content = /*#__PURE__*/React.createElement(StyledColumnValue, {
|
|
8419
8480
|
className: 'jr-column-value',
|
|
8420
8481
|
style: {
|
|
8421
8482
|
gridColumn: label == null ? 'span 2' : null,
|
|
@@ -8429,7 +8490,7 @@ class JRFields extends JRWindow {
|
|
|
8429
8490
|
}
|
|
8430
8491
|
const layout = column.labelProps?.layout === undefined ? this.props.labelProps?.layout : column.labelProps?.layout;
|
|
8431
8492
|
const labelStyle = column.labelProps?.style ?? this.props.labelProps?.style ?? {};
|
|
8432
|
-
return /*#__PURE__*/React
|
|
8493
|
+
return /*#__PURE__*/React.createElement(StyledColumn, {
|
|
8433
8494
|
$layout: layout,
|
|
8434
8495
|
$hasLabel: label != null,
|
|
8435
8496
|
key: `f${index}`,
|
|
@@ -8437,18 +8498,18 @@ class JRFields extends JRWindow {
|
|
|
8437
8498
|
className: 'jr-column',
|
|
8438
8499
|
$labelWidth: column.labelProps?.width ?? this.props.labelProps?.width ?? '120px',
|
|
8439
8500
|
$valueWidth: column.valueProps?.width ?? this.props.valueProps?.width ?? '1fr'
|
|
8440
|
-
}, label != null && /*#__PURE__*/React
|
|
8501
|
+
}, label != null && /*#__PURE__*/React.createElement(StyledColumnLabel, {
|
|
8441
8502
|
style: labelStyle,
|
|
8442
8503
|
$required: required,
|
|
8443
8504
|
className: 'label',
|
|
8444
8505
|
$layout: layout,
|
|
8445
8506
|
$colon: column.labelProps?.colon === undefined ? this.colon : column.labelProps?.colon
|
|
8446
|
-
}, label), content, this.props.debugMode && /*#__PURE__*/React
|
|
8507
|
+
}, label), content, this.props.debugMode && /*#__PURE__*/React.createElement(StyledColumnFooter, null, /*#__PURE__*/React.createElement("div", {
|
|
8447
8508
|
className: "left"
|
|
8448
|
-
}, /*#__PURE__*/React
|
|
8509
|
+
}, /*#__PURE__*/React.createElement(ColumnMessage, {
|
|
8449
8510
|
value: this.getValidateValue(_parentName.join('.')),
|
|
8450
8511
|
record: this.getValue()
|
|
8451
|
-
})), /*#__PURE__*/React
|
|
8512
|
+
})), /*#__PURE__*/React.createElement("div", {
|
|
8452
8513
|
className: "right"
|
|
8453
8514
|
}))
|
|
8454
8515
|
// validateValue?.[name]!==undefined && <StyledColumnFooter $layout={layout}>
|
|
@@ -8463,10 +8524,10 @@ class JRFields extends JRWindow {
|
|
|
8463
8524
|
});
|
|
8464
8525
|
}
|
|
8465
8526
|
renderMe() {
|
|
8466
|
-
return /*#__PURE__*/React
|
|
8527
|
+
return /*#__PURE__*/React.createElement(StyleJRFields, {
|
|
8467
8528
|
className: 'jr-fields',
|
|
8468
8529
|
style: this.props.typeStyle
|
|
8469
|
-
}, /*#__PURE__*/React
|
|
8530
|
+
}, /*#__PURE__*/React.createElement(StyledGrid, {
|
|
8470
8531
|
cols: this.props.cols,
|
|
8471
8532
|
style: this.props.gridStyle,
|
|
8472
8533
|
className: 'jr-grid',
|
|
@@ -8528,7 +8589,7 @@ const FreeType = ({
|
|
|
8528
8589
|
const content = config.bind(me)({
|
|
8529
8590
|
setStyle
|
|
8530
8591
|
});
|
|
8531
|
-
return /*#__PURE__*/React
|
|
8592
|
+
return /*#__PURE__*/React.createElement(Tag, {
|
|
8532
8593
|
className: className,
|
|
8533
8594
|
style: style
|
|
8534
8595
|
}, content);
|
|
@@ -8536,33 +8597,33 @@ const FreeType = ({
|
|
|
8536
8597
|
};
|
|
8537
8598
|
class JRTestReact extends JRSubmit {
|
|
8538
8599
|
renderer() {
|
|
8539
|
-
return /*#__PURE__*/React
|
|
8600
|
+
return /*#__PURE__*/React.createElement(StyledJRFrame, {
|
|
8540
8601
|
style: this.props.style,
|
|
8541
8602
|
className: `${this.props.className} jr-frame`
|
|
8542
|
-
}, /*#__PURE__*/React
|
|
8603
|
+
}, /*#__PURE__*/React.createElement(FreeType, {
|
|
8543
8604
|
tag: "div",
|
|
8544
8605
|
config: this.props.start,
|
|
8545
8606
|
me: this,
|
|
8546
8607
|
className: 'start'
|
|
8547
|
-
}), /*#__PURE__*/React
|
|
8608
|
+
}), /*#__PURE__*/React.createElement("main", null, /*#__PURE__*/React.createElement(FreeType, {
|
|
8548
8609
|
tag: "header",
|
|
8549
8610
|
config: this.props.top,
|
|
8550
8611
|
me: this
|
|
8551
|
-
}), /*#__PURE__*/React
|
|
8612
|
+
}), /*#__PURE__*/React.createElement("main", null, /*#__PURE__*/React.createElement(FreeType, {
|
|
8552
8613
|
tag: "div",
|
|
8553
8614
|
config: this.props.left,
|
|
8554
8615
|
me: this,
|
|
8555
8616
|
className: 'left'
|
|
8556
|
-
}), this.renderMe(), /*#__PURE__*/React
|
|
8617
|
+
}), this.renderMe(), /*#__PURE__*/React.createElement(FreeType, {
|
|
8557
8618
|
tag: "div",
|
|
8558
8619
|
config: this.props.right,
|
|
8559
8620
|
me: this,
|
|
8560
8621
|
className: 'right'
|
|
8561
|
-
})), /*#__PURE__*/React
|
|
8622
|
+
})), /*#__PURE__*/React.createElement(FreeType, {
|
|
8562
8623
|
tag: "footer",
|
|
8563
8624
|
config: this.props.bottom,
|
|
8564
8625
|
me: this
|
|
8565
|
-
})), /*#__PURE__*/React
|
|
8626
|
+
})), /*#__PURE__*/React.createElement(FreeType, {
|
|
8566
8627
|
tag: "div",
|
|
8567
8628
|
config: this.props.end,
|
|
8568
8629
|
me: this,
|
|
@@ -8570,7 +8631,7 @@ class JRTestReact extends JRSubmit {
|
|
|
8570
8631
|
}));
|
|
8571
8632
|
}
|
|
8572
8633
|
renderMe() {
|
|
8573
|
-
return /*#__PURE__*/React
|
|
8634
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
8574
8635
|
style: {
|
|
8575
8636
|
flex: 1
|
|
8576
8637
|
}
|