tenjin-ui-kit 0.3.72 → 0.3.73
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/common/hooks/apiHooks.js +14 -54
- package/common/hooks/newApiHook.js +32 -81
- package/components/Canvas.js +27 -32
- package/components/DragBox/index.js +16 -21
- package/components/InputWithChip/index.js +31 -43
- package/components/RightContext/index.js +6 -21
- package/components/WorkFlow.js +16 -21
- package/components/WorkFlowBuilder.js +22 -31
- package/components/alert/index.js +3 -7
- package/components/attachment/index.js +6 -4
- package/components/authenticationProvider/index.js +11 -27
- package/components/avatar/index.js +12 -10
- package/components/avatar/styles.js +4 -2
- package/components/breadCrumbs/index.js +39 -53
- package/components/browsingTestCaseLayout/DetailsViewLayout/DetailsViewContent/index.js +3 -1
- package/components/browsingTestCaseLayout/DetailsViewLayout/DetailsViewHeader/index.js +4 -2
- package/components/browsingTestCaseLayout/TreeViewLayout/TreeViewContent/Index.js +5 -3
- package/components/browsingTestCaseLayout/TreeViewLayout/TreeViewHeader/Index.js +4 -2
- package/components/browsingTestCaseLayout/TreeViewLayout/TreeViewHeader/style.js +1 -1
- package/components/browsingTestCaseLayout/index.js +14 -25
- package/components/button/index.js +26 -30
- package/components/chatBotModal/index.js +16 -28
- package/components/checkBox/index.js +4 -5
- package/components/combobox/index.js +37 -50
- package/components/divider/index.js +3 -8
- package/components/editableField/index.js +8 -26
- package/components/errorBoundary/index.js +7 -11
- package/components/fileUploader/index.js +28 -35
- package/components/fileUploader/style.js +1 -1
- package/components/filter/ValueSelector.js +47 -70
- package/components/filter/index.js +27 -43
- package/components/input/index.js +45 -52
- package/components/layout/index.js +22 -31
- package/components/layout/main/index.js +4 -2
- package/components/layout/pageContent/index.js +3 -1
- package/components/layout/sidebar/FlatMenu.js +10 -6
- package/components/layout/sidebar/GroupedIconMenu.js +145 -157
- package/components/layout/sidebar/GroupedMenu.js +9 -4
- package/components/layout/sidebar/ProjectMenu.js +134 -147
- package/components/layout/sidebar/index.js +14 -10
- package/components/layout/sidebar/style.js +6 -6
- package/components/layout/topBar/ProjectTopbar.js +15 -31
- package/components/layout/topBar/UserAvatar.js +12 -19
- package/components/layout/topBar/index.js +8 -15
- package/components/menu/index.js +7 -17
- package/components/modal/index.js +10 -11
- package/components/modal/style.js +1 -1
- package/components/optionMenu/index.js +8 -16
- package/components/pagination/index.js +7 -12
- package/components/paginationUpdated/index.js +15 -19
- package/components/paper/index.js +9 -10
- package/components/paper/style.js +2 -2
- package/components/reactSelect/index.js +36 -52
- package/components/reactSelect/style.js +37 -24
- package/components/richTextEditor/index.js +9 -14
- package/components/select/GroupedSelect.js +78 -65
- package/components/select/SimpleSelect.js +28 -40
- package/components/select/index.js +25 -22
- package/components/simpleSelect/index.js +10 -11
- package/components/sort/index.js +13 -23
- package/components/switch/index.js +9 -9
- package/components/switch/style.js +6 -6
- package/components/switch/switch.js +22 -33
- package/components/table/ReactTable.js +16 -23
- package/components/table/SimpleTable.js +17 -22
- package/components/table/index.js +100 -131
- package/components/text/index.js +16 -22
- package/components/topBar/index.js +12 -21
- package/components/tree/index.js +9 -19
- package/components/tree/style.js +1 -1
- package/components/valuePicker/ValueSelector.js +31 -45
- package/components/valuePicker/index.js +20 -33
- package/components/wrapperLayout/layout/index.js +5 -3
- package/components/wrapperLayout/main/index.js +5 -3
- package/components/wrapperLayout/main/pageContainer/index.js +3 -1
- package/components/wrapperLayout/main/sideBar/index.js +101 -115
- package/components/wrapperLayout/main/sideBar/style.js +1 -1
- package/components/wrapperLayout/topBar/UserAvatar.js +3 -1
- package/components/wrapperLayout/topBar/avatar.js +7 -8
- package/components/wrapperLayout/topBar/index.js +17 -23
- package/components/wrapperLayout/topBar/menuIcon.js +3 -1
- package/components/wrapperLayout/topBar/style.js +4 -2
- package/http/index.js +13 -16
- package/package.json +2 -1
- package/templates/listPage/index.js +148 -155
|
@@ -11,17 +11,6 @@ var _button = _interopRequireDefault(require("../../components/button"));
|
|
|
11
11
|
var _input = _interopRequireDefault(require("../../components/input"));
|
|
12
12
|
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
13
13
|
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function (e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != typeof e && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (const t in e) "default" !== t && {}.hasOwnProperty.call(e, t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, t)) && (i.get || i.set) ? o(f, t, i) : f[t] = e[t]); return f; })(e, t); }
|
|
14
|
-
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
15
|
-
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
16
|
-
function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
|
|
17
|
-
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : i + ""; }
|
|
18
|
-
function _toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != typeof i) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
19
|
-
function _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); }
|
|
20
|
-
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
21
|
-
function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
|
|
22
|
-
function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
|
|
23
|
-
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
24
|
-
function _arrayWithHoles(r) { if (Array.isArray(r)) return r; }
|
|
25
14
|
const columns = [{
|
|
26
15
|
name: "id",
|
|
27
16
|
displayName: "User ID"
|
|
@@ -51,166 +40,169 @@ const columns = [{
|
|
|
51
40
|
render: d => d.company.name
|
|
52
41
|
}];
|
|
53
42
|
const ListPage = _ref => {
|
|
54
|
-
let
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
phone: "1-770-736-8031 x56442",
|
|
74
|
-
website: "hildegard.org",
|
|
75
|
-
company: {
|
|
76
|
-
name: "Romaguera-Crona",
|
|
77
|
-
catchPhrase: "Multi-layered client-server neural-net",
|
|
78
|
-
bs: "harness real-time e-markets"
|
|
43
|
+
let {
|
|
44
|
+
pageTitle
|
|
45
|
+
} = _ref;
|
|
46
|
+
const [data, setData] = (0, _react.useState)({
|
|
47
|
+
filtered: [],
|
|
48
|
+
filter: null,
|
|
49
|
+
unfiltered: [{
|
|
50
|
+
id: 1,
|
|
51
|
+
name: "Leanne Graham",
|
|
52
|
+
username: "Bret",
|
|
53
|
+
email: "Sincere@april.biz",
|
|
54
|
+
address: {
|
|
55
|
+
street: "Kulas Light",
|
|
56
|
+
suite: "Apt. 556",
|
|
57
|
+
city: "Gwenborough",
|
|
58
|
+
zipcode: "92998-3874",
|
|
59
|
+
geo: {
|
|
60
|
+
lat: "-37.3159",
|
|
61
|
+
lng: "81.1496"
|
|
79
62
|
}
|
|
80
|
-
},
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
63
|
+
},
|
|
64
|
+
phone: "1-770-736-8031 x56442",
|
|
65
|
+
website: "hildegard.org",
|
|
66
|
+
company: {
|
|
67
|
+
name: "Romaguera-Crona",
|
|
68
|
+
catchPhrase: "Multi-layered client-server neural-net",
|
|
69
|
+
bs: "harness real-time e-markets"
|
|
70
|
+
}
|
|
71
|
+
}, {
|
|
72
|
+
id: 2,
|
|
73
|
+
name: "Ervin Howell",
|
|
74
|
+
username: "Antonette",
|
|
75
|
+
email: "Shanna@melissa.tv",
|
|
76
|
+
address: {
|
|
77
|
+
street: "Victor Plains",
|
|
78
|
+
suite: "Suite 879",
|
|
79
|
+
city: "Wisokyburgh",
|
|
80
|
+
zipcode: "90566-7771",
|
|
81
|
+
geo: {
|
|
82
|
+
lat: "-43.9509",
|
|
83
|
+
lng: "-34.4618"
|
|
101
84
|
}
|
|
102
|
-
},
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
85
|
+
},
|
|
86
|
+
phone: "010-692-6593 x09125",
|
|
87
|
+
website: "anastasia.net",
|
|
88
|
+
company: {
|
|
89
|
+
name: "Deckow-Crist",
|
|
90
|
+
catchPhrase: "Proactive didactic contingency",
|
|
91
|
+
bs: "synergize scalable supply-chains"
|
|
92
|
+
}
|
|
93
|
+
}, {
|
|
94
|
+
id: 3,
|
|
95
|
+
name: "Clementine Bauch",
|
|
96
|
+
username: "Samantha",
|
|
97
|
+
email: "Nathan@yesenia.net",
|
|
98
|
+
address: {
|
|
99
|
+
street: "Douglas Extension",
|
|
100
|
+
suite: "Suite 847",
|
|
101
|
+
city: "McKenziehaven",
|
|
102
|
+
zipcode: "59590-4157",
|
|
103
|
+
geo: {
|
|
104
|
+
lat: "-68.6102",
|
|
105
|
+
lng: "-47.0653"
|
|
123
106
|
}
|
|
124
|
-
},
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
107
|
+
},
|
|
108
|
+
phone: "1-463-123-4447",
|
|
109
|
+
website: "ramiro.info",
|
|
110
|
+
company: {
|
|
111
|
+
name: "Romaguera-Jacobson",
|
|
112
|
+
catchPhrase: "Face to face bifurcated interface",
|
|
113
|
+
bs: "e-enable strategic applications"
|
|
114
|
+
}
|
|
115
|
+
}, {
|
|
116
|
+
id: 4,
|
|
117
|
+
name: "Patricia Lebsack",
|
|
118
|
+
username: "Karianne",
|
|
119
|
+
email: "Julianne.OConner@kory.org",
|
|
120
|
+
address: {
|
|
121
|
+
street: "Hoeger Mall",
|
|
122
|
+
suite: "Apt. 692",
|
|
123
|
+
city: "South Elvis",
|
|
124
|
+
zipcode: "53919-4257",
|
|
125
|
+
geo: {
|
|
126
|
+
lat: "29.4572",
|
|
127
|
+
lng: "-164.2990"
|
|
145
128
|
}
|
|
146
|
-
},
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
129
|
+
},
|
|
130
|
+
phone: "493-170-9623 x156",
|
|
131
|
+
website: "kale.biz",
|
|
132
|
+
company: {
|
|
133
|
+
name: "Robel-Corkery",
|
|
134
|
+
catchPhrase: "Multi-tiered zero tolerance productivity",
|
|
135
|
+
bs: "transition cutting-edge web services"
|
|
136
|
+
}
|
|
137
|
+
}, {
|
|
138
|
+
id: 5,
|
|
139
|
+
name: "Chelsey Dietrich",
|
|
140
|
+
username: "Kamren",
|
|
141
|
+
email: "Lucio_Hettinger@annie.ca",
|
|
142
|
+
address: {
|
|
143
|
+
street: "Skiles Walks",
|
|
144
|
+
suite: "Suite 351",
|
|
145
|
+
city: "Roscoeview",
|
|
146
|
+
zipcode: "33263",
|
|
147
|
+
geo: {
|
|
148
|
+
lat: "-31.8129",
|
|
149
|
+
lng: "62.5342"
|
|
167
150
|
}
|
|
168
|
-
},
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
151
|
+
},
|
|
152
|
+
phone: "(254)954-1289",
|
|
153
|
+
website: "demarco.info",
|
|
154
|
+
company: {
|
|
155
|
+
name: "Keebler LLC",
|
|
156
|
+
catchPhrase: "User-centric fault-tolerant solution",
|
|
157
|
+
bs: "revolutionize end-to-end systems"
|
|
158
|
+
}
|
|
159
|
+
}, {
|
|
160
|
+
id: 6,
|
|
161
|
+
name: "Mrs. Dennis Schulist",
|
|
162
|
+
username: "Leopoldo_Corkery",
|
|
163
|
+
email: "Karley_Dach@jasper.info",
|
|
164
|
+
address: {
|
|
165
|
+
street: "Norberto Crossing",
|
|
166
|
+
suite: "Apt. 950",
|
|
167
|
+
city: "South Christy",
|
|
168
|
+
zipcode: "23505-1337",
|
|
169
|
+
geo: {
|
|
170
|
+
lat: "-71.4197",
|
|
171
|
+
lng: "71.7478"
|
|
189
172
|
}
|
|
190
|
-
}
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
173
|
+
},
|
|
174
|
+
phone: "1-477-935-8478 x6430",
|
|
175
|
+
website: "ola.org",
|
|
176
|
+
company: {
|
|
177
|
+
name: "Considine-Lockman",
|
|
178
|
+
catchPhrase: "Synchronised bottom-line interface",
|
|
179
|
+
bs: "e-enable innovative applications"
|
|
180
|
+
}
|
|
181
|
+
}]
|
|
182
|
+
});
|
|
195
183
|
(0, _react.useEffect)(() => {
|
|
196
184
|
search();
|
|
197
185
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
198
186
|
}, [data.unfiltered, data.filter]);
|
|
199
187
|
const search = () => {
|
|
200
188
|
if (data.filter) {
|
|
201
|
-
const
|
|
202
|
-
|
|
189
|
+
const {
|
|
190
|
+
filter,
|
|
191
|
+
unfiltered
|
|
192
|
+
} = data;
|
|
203
193
|
let newFiltered = unfiltered.filter(u => {
|
|
204
|
-
let mergedData =
|
|
194
|
+
let mergedData = `${u.id}${u.username.toLowerCase()}${u.email.toLowerCase()}`;
|
|
205
195
|
return mergedData.includes(filter.toLowerCase());
|
|
206
196
|
});
|
|
207
|
-
setData(
|
|
197
|
+
setData({
|
|
198
|
+
...data,
|
|
208
199
|
filtered: newFiltered
|
|
209
|
-
})
|
|
200
|
+
});
|
|
210
201
|
} else {
|
|
211
|
-
setData(
|
|
202
|
+
setData({
|
|
203
|
+
...data,
|
|
212
204
|
filtered: [...data.unfiltered]
|
|
213
|
-
})
|
|
205
|
+
});
|
|
214
206
|
}
|
|
215
207
|
};
|
|
216
208
|
return /*#__PURE__*/_react.default.createElement(_material.Grid, {
|
|
@@ -256,9 +248,10 @@ const ListPage = _ref => {
|
|
|
256
248
|
}, /*#__PURE__*/_react.default.createElement(_input.default, {
|
|
257
249
|
fullWidth: true,
|
|
258
250
|
placeholder: "Search by ID, name or Email",
|
|
259
|
-
onChange: e => setData(
|
|
251
|
+
onChange: e => setData({
|
|
252
|
+
...data,
|
|
260
253
|
filter: e.target.value
|
|
261
|
-
})
|
|
254
|
+
}),
|
|
262
255
|
value: data.filter,
|
|
263
256
|
disableAutocomplete: true,
|
|
264
257
|
startIcon: /*#__PURE__*/_react.default.createElement(_fi.FiSearch, null)
|