arengibook 1.0.5-select → 1.1.0-main
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/index.js +411 -419
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -2,346 +2,6 @@ import * as React from 'react';
|
|
|
2
2
|
import React__default, { useContext, useState, useRef, useEffect, isValidElement, cloneElement, Children, forwardRef, Fragment, useMemo, useCallback } from 'react';
|
|
3
3
|
import ReactDOM from 'react-dom';
|
|
4
4
|
|
|
5
|
-
var devises = [{
|
|
6
|
-
value: 'EUR',
|
|
7
|
-
code: 'EUR',
|
|
8
|
-
label: '€',
|
|
9
|
-
currency: '1'
|
|
10
|
-
}, {
|
|
11
|
-
value: 'USD',
|
|
12
|
-
code: 'USD',
|
|
13
|
-
label: '$',
|
|
14
|
-
currency: '1.08'
|
|
15
|
-
}, {
|
|
16
|
-
value: 'GBP',
|
|
17
|
-
code: 'GBP',
|
|
18
|
-
label: '£',
|
|
19
|
-
currency: '0.86'
|
|
20
|
-
}];
|
|
21
|
-
var currencyEUR = devises.find(function (d) {
|
|
22
|
-
return d.value === 'EUR';
|
|
23
|
-
});
|
|
24
|
-
var statutOptions = [{
|
|
25
|
-
value: 'actif',
|
|
26
|
-
label: 'Actif',
|
|
27
|
-
color: '#27AE60'
|
|
28
|
-
}, {
|
|
29
|
-
value: 'inactif',
|
|
30
|
-
label: 'Inactif',
|
|
31
|
-
color: '#E67E22'
|
|
32
|
-
}, {
|
|
33
|
-
value: 'archive',
|
|
34
|
-
label: 'Archivé',
|
|
35
|
-
color: '#95A5A6'
|
|
36
|
-
}];
|
|
37
|
-
var serviceTree = [{
|
|
38
|
-
key: 'tech',
|
|
39
|
-
label: 'Technologie',
|
|
40
|
-
children: [{
|
|
41
|
-
key: 'tech-dev',
|
|
42
|
-
label: 'Développement'
|
|
43
|
-
}, {
|
|
44
|
-
key: 'tech-infra',
|
|
45
|
-
label: 'Infrastructure'
|
|
46
|
-
}, {
|
|
47
|
-
key: 'tech-secu',
|
|
48
|
-
label: 'Sécurité'
|
|
49
|
-
}]
|
|
50
|
-
}, {
|
|
51
|
-
key: 'metier',
|
|
52
|
-
label: 'Métier',
|
|
53
|
-
children: [{
|
|
54
|
-
key: 'metier-rh',
|
|
55
|
-
label: 'RH'
|
|
56
|
-
}, {
|
|
57
|
-
key: 'metier-compta',
|
|
58
|
-
label: 'Comptabilité'
|
|
59
|
-
}, {
|
|
60
|
-
key: 'metier-jur',
|
|
61
|
-
label: 'Juridique'
|
|
62
|
-
}]
|
|
63
|
-
}, {
|
|
64
|
-
key: 'support',
|
|
65
|
-
label: 'Support'
|
|
66
|
-
}];
|
|
67
|
-
var competencesOptions = [{
|
|
68
|
-
value: 'react',
|
|
69
|
-
label: 'React',
|
|
70
|
-
color: '#61DAFB'
|
|
71
|
-
}, {
|
|
72
|
-
value: 'symfony',
|
|
73
|
-
label: 'Symfony',
|
|
74
|
-
color: '#1A171B'
|
|
75
|
-
}, {
|
|
76
|
-
value: 'sql',
|
|
77
|
-
label: 'SQL',
|
|
78
|
-
color: '#336791'
|
|
79
|
-
}, {
|
|
80
|
-
value: 'devops',
|
|
81
|
-
label: 'DevOps',
|
|
82
|
-
color: '#EE4C2C'
|
|
83
|
-
}, {
|
|
84
|
-
value: 'design',
|
|
85
|
-
label: 'Design',
|
|
86
|
-
color: '#FF61F6'
|
|
87
|
-
}];
|
|
88
|
-
var dataTyped = [{
|
|
89
|
-
id: 1,
|
|
90
|
-
nom: 'Alice Martin',
|
|
91
|
-
dateInscription: '2023-04-12',
|
|
92
|
-
dateNaissance: '1990-07-22',
|
|
93
|
-
statut: 'actif',
|
|
94
|
-
categorie: 'client',
|
|
95
|
-
categorieColor: '#2980B9',
|
|
96
|
-
niveau: 'Élevé',
|
|
97
|
-
niveauPicto: '/bundles/arengimain/img/picto/eleve.png',
|
|
98
|
-
competences: ['react', 'symfony'],
|
|
99
|
-
budget: 12500,
|
|
100
|
-
score: null,
|
|
101
|
-
fichiers: [{
|
|
102
|
-
id: 1,
|
|
103
|
-
name: 'contrat.pdf',
|
|
104
|
-
url: '#'
|
|
105
|
-
}],
|
|
106
|
-
montant: {
|
|
107
|
-
value: 12500,
|
|
108
|
-
devise: devises.find(function (d) {
|
|
109
|
-
return d.value === 'EUR';
|
|
110
|
-
})
|
|
111
|
-
},
|
|
112
|
-
service: 'tech-dev'
|
|
113
|
-
}, {
|
|
114
|
-
id: 2,
|
|
115
|
-
nom: 'Bob Dupont',
|
|
116
|
-
dateInscription: '2024-01-05',
|
|
117
|
-
dateNaissance: '1985-11-03',
|
|
118
|
-
statut: 'inactif',
|
|
119
|
-
categorie: 'prospect',
|
|
120
|
-
categorieColor: '#E67E22',
|
|
121
|
-
niveau: 'Moyen',
|
|
122
|
-
niveauPicto: '/bundles/arengimain/img/picto/moyen.png',
|
|
123
|
-
competences: ['sql'],
|
|
124
|
-
budget: 4800,
|
|
125
|
-
score: null,
|
|
126
|
-
fichiers: [{
|
|
127
|
-
id: 2,
|
|
128
|
-
name: 'devis.xlsx',
|
|
129
|
-
url: '#'
|
|
130
|
-
}, {
|
|
131
|
-
id: 3,
|
|
132
|
-
name: 'facture.pdf',
|
|
133
|
-
url: '#'
|
|
134
|
-
}],
|
|
135
|
-
montant: {
|
|
136
|
-
value: 5200,
|
|
137
|
-
devise: devises.find(function (d) {
|
|
138
|
-
return d.value === 'USD';
|
|
139
|
-
})
|
|
140
|
-
},
|
|
141
|
-
service: 'metier-compta'
|
|
142
|
-
}, {
|
|
143
|
-
id: 3,
|
|
144
|
-
nom: 'Clara Leroy',
|
|
145
|
-
dateInscription: '2022-09-30',
|
|
146
|
-
dateNaissance: '1995-02-14',
|
|
147
|
-
statut: 'actif',
|
|
148
|
-
categorie: 'partenaire',
|
|
149
|
-
categorieColor: '#8E44AD',
|
|
150
|
-
niveau: 'Faible',
|
|
151
|
-
niveauPicto: '/bundles/arengimain/img/picto/faible.png',
|
|
152
|
-
competences: ['design', 'react'],
|
|
153
|
-
budget: 31000,
|
|
154
|
-
score: null,
|
|
155
|
-
fichiers: [],
|
|
156
|
-
montant: {
|
|
157
|
-
value: 28000,
|
|
158
|
-
devise: devises.find(function (d) {
|
|
159
|
-
return d.value === 'GBP';
|
|
160
|
-
})
|
|
161
|
-
},
|
|
162
|
-
service: 'support'
|
|
163
|
-
}, {
|
|
164
|
-
id: 4,
|
|
165
|
-
nom: 'David Bernard',
|
|
166
|
-
dateInscription: '2023-11-18',
|
|
167
|
-
dateNaissance: '1978-06-01',
|
|
168
|
-
statut: 'archive',
|
|
169
|
-
categorie: 'client',
|
|
170
|
-
categorieColor: '#2980B9',
|
|
171
|
-
niveau: 'Élevé',
|
|
172
|
-
niveauPicto: '/bundles/arengimain/img/picto/eleve.png',
|
|
173
|
-
competences: ['devops', 'sql', 'symfony'],
|
|
174
|
-
budget: null,
|
|
175
|
-
score: null,
|
|
176
|
-
fichiers: [],
|
|
177
|
-
montant: null,
|
|
178
|
-
service: 'tech-infra'
|
|
179
|
-
}, {
|
|
180
|
-
id: 5,
|
|
181
|
-
nom: 'Emma Petit',
|
|
182
|
-
dateInscription: '2024-03-22',
|
|
183
|
-
dateNaissance: '2001-12-09',
|
|
184
|
-
statut: 'actif',
|
|
185
|
-
categorie: 'prospect',
|
|
186
|
-
categorieColor: '#E67E22',
|
|
187
|
-
niveau: null,
|
|
188
|
-
niveauPicto: null,
|
|
189
|
-
competences: [],
|
|
190
|
-
budget: 7200,
|
|
191
|
-
score: null,
|
|
192
|
-
fichiers: [{
|
|
193
|
-
id: 4,
|
|
194
|
-
name: 'rapport.docx',
|
|
195
|
-
url: '#'
|
|
196
|
-
}],
|
|
197
|
-
montant: {
|
|
198
|
-
value: 7200,
|
|
199
|
-
devise: devises.find(function (d) {
|
|
200
|
-
return d.value === 'EUR';
|
|
201
|
-
})
|
|
202
|
-
},
|
|
203
|
-
service: null
|
|
204
|
-
}, {
|
|
205
|
-
id: 6,
|
|
206
|
-
nom: 'François Morel',
|
|
207
|
-
dateInscription: '2021-06-15',
|
|
208
|
-
dateNaissance: '1969-08-27',
|
|
209
|
-
statut: 'inactif',
|
|
210
|
-
categorie: 'client',
|
|
211
|
-
categorieColor: '#2980B9',
|
|
212
|
-
niveau: 'Moyen',
|
|
213
|
-
niveauPicto: '/bundles/arengimain/img/picto/moyen.png',
|
|
214
|
-
competences: ['react', 'devops', 'design'],
|
|
215
|
-
budget: 18750,
|
|
216
|
-
score: null,
|
|
217
|
-
fichiers: [],
|
|
218
|
-
montant: {
|
|
219
|
-
value: 18750,
|
|
220
|
-
devise: devises.find(function (d) {
|
|
221
|
-
return d.value === 'EUR';
|
|
222
|
-
})
|
|
223
|
-
},
|
|
224
|
-
service: 'metier-rh'
|
|
225
|
-
}, {
|
|
226
|
-
id: 7,
|
|
227
|
-
nom: 'Grace Rousseau',
|
|
228
|
-
dateInscription: '2025-02-01',
|
|
229
|
-
dateNaissance: '1993-03-18',
|
|
230
|
-
statut: 'actif',
|
|
231
|
-
categorie: 'partenaire',
|
|
232
|
-
categorieColor: '#8E44AD',
|
|
233
|
-
niveau: 'Faible',
|
|
234
|
-
niveauPicto: '/bundles/arengimain/img/picto/faible.png',
|
|
235
|
-
competences: ['symfony', 'sql'],
|
|
236
|
-
budget: 9300,
|
|
237
|
-
score: null,
|
|
238
|
-
fichiers: [{
|
|
239
|
-
id: 5,
|
|
240
|
-
name: 'annexe1.pdf',
|
|
241
|
-
url: '#'
|
|
242
|
-
}, {
|
|
243
|
-
id: 6,
|
|
244
|
-
name: 'annexe2.pdf',
|
|
245
|
-
url: '#'
|
|
246
|
-
}, {
|
|
247
|
-
id: 7,
|
|
248
|
-
name: 'annexe3.pdf',
|
|
249
|
-
url: '#'
|
|
250
|
-
}],
|
|
251
|
-
montant: {
|
|
252
|
-
value: 9800,
|
|
253
|
-
devise: devises.find(function (d) {
|
|
254
|
-
return d.value === 'USD';
|
|
255
|
-
})
|
|
256
|
-
},
|
|
257
|
-
service: 'tech-secu'
|
|
258
|
-
}];
|
|
259
|
-
var columnsTyped = [{
|
|
260
|
-
field: 'nom',
|
|
261
|
-
header: 'Nom',
|
|
262
|
-
type: 'link',
|
|
263
|
-
href: function href(row) {
|
|
264
|
-
return "/risques/".concat(row.id);
|
|
265
|
-
}
|
|
266
|
-
}, {
|
|
267
|
-
field: 'dateInscription',
|
|
268
|
-
header: 'Inscription',
|
|
269
|
-
type: 'date'
|
|
270
|
-
}, {
|
|
271
|
-
field: 'dateNaissance',
|
|
272
|
-
header: 'Naissance',
|
|
273
|
-
type: 'date',
|
|
274
|
-
hidden: true
|
|
275
|
-
}, {
|
|
276
|
-
field: 'statut',
|
|
277
|
-
header: 'Statut',
|
|
278
|
-
type: 'select',
|
|
279
|
-
options: statutOptions
|
|
280
|
-
}, {
|
|
281
|
-
field: 'categorie',
|
|
282
|
-
header: 'Catégorie',
|
|
283
|
-
type: 'colorText'
|
|
284
|
-
}, {
|
|
285
|
-
field: 'niveau',
|
|
286
|
-
header: 'Niveau',
|
|
287
|
-
type: 'picto'
|
|
288
|
-
}, {
|
|
289
|
-
field: 'competences',
|
|
290
|
-
header: 'Compétences',
|
|
291
|
-
type: 'selectMultiple',
|
|
292
|
-
options: competencesOptions
|
|
293
|
-
}, {
|
|
294
|
-
field: 'budget',
|
|
295
|
-
header: 'Budget (€)',
|
|
296
|
-
type: 'numeric',
|
|
297
|
-
min: 0
|
|
298
|
-
}, {
|
|
299
|
-
field: 'score',
|
|
300
|
-
header: 'Score calculé',
|
|
301
|
-
type: 'calcul',
|
|
302
|
-
render: function render(row) {
|
|
303
|
-
return row.budget != null ? "".concat(Math.round(row.budget / 1000), " pts") : '—';
|
|
304
|
-
}
|
|
305
|
-
}, {
|
|
306
|
-
field: 'fichiers',
|
|
307
|
-
header: 'Fichiers',
|
|
308
|
-
type: 'documents',
|
|
309
|
-
uploadUrl: '/api/upload'
|
|
310
|
-
}, {
|
|
311
|
-
field: 'montant',
|
|
312
|
-
header: 'Montant',
|
|
313
|
-
type: 'devise',
|
|
314
|
-
currency: currencyEUR,
|
|
315
|
-
devises: devises,
|
|
316
|
-
decimal: 2
|
|
317
|
-
}, {
|
|
318
|
-
field: 'service',
|
|
319
|
-
header: 'Service',
|
|
320
|
-
type: 'treeSelect',
|
|
321
|
-
options: serviceTree,
|
|
322
|
-
selectionMode: 'single',
|
|
323
|
-
filter: true
|
|
324
|
-
}];
|
|
325
|
-
var TablePresets = {
|
|
326
|
-
Base: {
|
|
327
|
-
value: dataTyped,
|
|
328
|
-
columns: columnsTyped,
|
|
329
|
-
editable: true
|
|
330
|
-
}
|
|
331
|
-
};
|
|
332
|
-
|
|
333
|
-
({
|
|
334
|
-
Scrollable: {
|
|
335
|
-
tabs: Array.from({
|
|
336
|
-
length: 20
|
|
337
|
-
}, function (_, i) {
|
|
338
|
-
return {
|
|
339
|
-
header: "Onglet ".concat(i + 1),
|
|
340
|
-
content: "<p>Contenu ".concat(i + 1, "</p>")
|
|
341
|
-
};
|
|
342
|
-
})
|
|
343
|
-
}});
|
|
344
|
-
|
|
345
5
|
function styleInject(css, ref) {
|
|
346
6
|
if ( ref === void 0 ) ref = {};
|
|
347
7
|
var insertAt = ref.insertAt;
|
|
@@ -38926,81 +38586,6 @@ var DropdownPresets = {
|
|
|
38926
38586
|
}
|
|
38927
38587
|
};
|
|
38928
38588
|
|
|
38929
|
-
var simulateNetworkDelay = function simulateNetworkDelay() {
|
|
38930
|
-
return new Promise(function (res) {
|
|
38931
|
-
return setTimeout(res, 400);
|
|
38932
|
-
});
|
|
38933
|
-
};
|
|
38934
|
-
var createFakeOptions = function createFakeOptions(start, length) {
|
|
38935
|
-
var options = [];
|
|
38936
|
-
for (var i = start; i < start + length; i++) {
|
|
38937
|
-
options.push({
|
|
38938
|
-
value: i,
|
|
38939
|
-
label: "Option ".concat(i),
|
|
38940
|
-
color: 'black'
|
|
38941
|
-
});
|
|
38942
|
-
}
|
|
38943
|
-
return options;
|
|
38944
|
-
};
|
|
38945
|
-
var DropdownSelectMetaAsyncPresets = {
|
|
38946
|
-
SelectMetaAsync: {
|
|
38947
|
-
options: function () {
|
|
38948
|
-
var _options = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee() {
|
|
38949
|
-
var search,
|
|
38950
|
-
_ref,
|
|
38951
|
-
page,
|
|
38952
|
-
allOptions,
|
|
38953
|
-
filtered,
|
|
38954
|
-
pageSize,
|
|
38955
|
-
start,
|
|
38956
|
-
_args = arguments;
|
|
38957
|
-
return _regenerator().w(function (_context) {
|
|
38958
|
-
while (1) switch (_context.n) {
|
|
38959
|
-
case 0:
|
|
38960
|
-
search = _args.length > 0 && _args[0] !== undefined ? _args[0] : '';
|
|
38961
|
-
_ref = _args.length > 2 ? _args[2] : undefined, page = _ref.page;
|
|
38962
|
-
_context.n = 1;
|
|
38963
|
-
return simulateNetworkDelay();
|
|
38964
|
-
case 1:
|
|
38965
|
-
allOptions = createFakeOptions(0, 100);
|
|
38966
|
-
filtered = allOptions.filter(function (opt) {
|
|
38967
|
-
return opt.label.toLowerCase().includes(search.toLowerCase());
|
|
38968
|
-
});
|
|
38969
|
-
pageSize = 30;
|
|
38970
|
-
start = (page - 1) * pageSize;
|
|
38971
|
-
return _context.a(2, {
|
|
38972
|
-
options: filtered.slice(start, start + pageSize),
|
|
38973
|
-
hasMore: start + pageSize < filtered.length,
|
|
38974
|
-
additional: {
|
|
38975
|
-
page: page + 1
|
|
38976
|
-
}
|
|
38977
|
-
});
|
|
38978
|
-
}
|
|
38979
|
-
}, _callee);
|
|
38980
|
-
}));
|
|
38981
|
-
function options() {
|
|
38982
|
-
return _options.apply(this, arguments);
|
|
38983
|
-
}
|
|
38984
|
-
return options;
|
|
38985
|
-
}(),
|
|
38986
|
-
value: 3,
|
|
38987
|
-
editable: true,
|
|
38988
|
-
filter: false,
|
|
38989
|
-
// a gérer
|
|
38990
|
-
valueStyle: {
|
|
38991
|
-
fontSize: '19px',
|
|
38992
|
-
fontFamily: 'Arial'
|
|
38993
|
-
},
|
|
38994
|
-
selectMetaConfig: {
|
|
38995
|
-
generalIcon: 'pi pi-circle-fill'
|
|
38996
|
-
},
|
|
38997
|
-
optionStyle: {
|
|
38998
|
-
fontSize: '14px',
|
|
38999
|
-
fontFamily: 'Arial'
|
|
39000
|
-
}
|
|
39001
|
-
}
|
|
39002
|
-
};
|
|
39003
|
-
|
|
39004
38589
|
function _extends$7() {
|
|
39005
38590
|
return _extends$7 = Object.assign ? Object.assign.bind() : function (n) {
|
|
39006
38591
|
for (var e = 1; e < arguments.length; e++) {
|
|
@@ -43693,6 +43278,81 @@ var MultiSelectMetaAsyncPresets = {
|
|
|
43693
43278
|
}
|
|
43694
43279
|
};
|
|
43695
43280
|
|
|
43281
|
+
var simulateNetworkDelay = function simulateNetworkDelay() {
|
|
43282
|
+
return new Promise(function (res) {
|
|
43283
|
+
return setTimeout(res, 400);
|
|
43284
|
+
});
|
|
43285
|
+
};
|
|
43286
|
+
var createFakeOptions = function createFakeOptions(start, length) {
|
|
43287
|
+
var options = [];
|
|
43288
|
+
for (var i = start; i < start + length; i++) {
|
|
43289
|
+
options.push({
|
|
43290
|
+
value: i,
|
|
43291
|
+
label: "Option ".concat(i),
|
|
43292
|
+
color: 'black'
|
|
43293
|
+
});
|
|
43294
|
+
}
|
|
43295
|
+
return options;
|
|
43296
|
+
};
|
|
43297
|
+
var DropdownSelectMetaAsyncPresets = {
|
|
43298
|
+
SelectMetaAsync: {
|
|
43299
|
+
options: function () {
|
|
43300
|
+
var _options = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee() {
|
|
43301
|
+
var search,
|
|
43302
|
+
_ref,
|
|
43303
|
+
page,
|
|
43304
|
+
allOptions,
|
|
43305
|
+
filtered,
|
|
43306
|
+
pageSize,
|
|
43307
|
+
start,
|
|
43308
|
+
_args = arguments;
|
|
43309
|
+
return _regenerator().w(function (_context) {
|
|
43310
|
+
while (1) switch (_context.n) {
|
|
43311
|
+
case 0:
|
|
43312
|
+
search = _args.length > 0 && _args[0] !== undefined ? _args[0] : '';
|
|
43313
|
+
_ref = _args.length > 2 ? _args[2] : undefined, page = _ref.page;
|
|
43314
|
+
_context.n = 1;
|
|
43315
|
+
return simulateNetworkDelay();
|
|
43316
|
+
case 1:
|
|
43317
|
+
allOptions = createFakeOptions(0, 100);
|
|
43318
|
+
filtered = allOptions.filter(function (opt) {
|
|
43319
|
+
return opt.label.toLowerCase().includes(search.toLowerCase());
|
|
43320
|
+
});
|
|
43321
|
+
pageSize = 30;
|
|
43322
|
+
start = (page - 1) * pageSize;
|
|
43323
|
+
return _context.a(2, {
|
|
43324
|
+
options: filtered.slice(start, start + pageSize),
|
|
43325
|
+
hasMore: start + pageSize < filtered.length,
|
|
43326
|
+
additional: {
|
|
43327
|
+
page: page + 1
|
|
43328
|
+
}
|
|
43329
|
+
});
|
|
43330
|
+
}
|
|
43331
|
+
}, _callee);
|
|
43332
|
+
}));
|
|
43333
|
+
function options() {
|
|
43334
|
+
return _options.apply(this, arguments);
|
|
43335
|
+
}
|
|
43336
|
+
return options;
|
|
43337
|
+
}(),
|
|
43338
|
+
value: 3,
|
|
43339
|
+
editable: true,
|
|
43340
|
+
filter: false,
|
|
43341
|
+
// a gérer
|
|
43342
|
+
valueStyle: {
|
|
43343
|
+
fontSize: '19px',
|
|
43344
|
+
fontFamily: 'Arial'
|
|
43345
|
+
},
|
|
43346
|
+
selectMetaConfig: {
|
|
43347
|
+
generalIcon: 'pi pi-circle-fill'
|
|
43348
|
+
},
|
|
43349
|
+
optionStyle: {
|
|
43350
|
+
fontSize: '14px',
|
|
43351
|
+
fontFamily: 'Arial'
|
|
43352
|
+
}
|
|
43353
|
+
}
|
|
43354
|
+
};
|
|
43355
|
+
|
|
43696
43356
|
function _extends$5() {
|
|
43697
43357
|
return _extends$5 = Object.assign ? Object.assign.bind() : function (n) {
|
|
43698
43358
|
for (var e = 1; e < arguments.length; e++) {
|
|
@@ -44522,6 +44182,7 @@ var ToastContent = function ToastContent(_ref) {
|
|
|
44522
44182
|
}
|
|
44523
44183
|
} : undefined;
|
|
44524
44184
|
var showToggleBtn = sizeModulable && (size === "S" || size === "L");
|
|
44185
|
+
var reserveToggleSpace = !sizeModulable && size === "S";
|
|
44525
44186
|
return /*#__PURE__*/React__default.createElement("div", {
|
|
44526
44187
|
className: "toast-root"
|
|
44527
44188
|
}, /*#__PURE__*/React__default.createElement("div", {
|
|
@@ -44596,8 +44257,11 @@ var ToastContent = function ToastContent(_ref) {
|
|
|
44596
44257
|
style: {
|
|
44597
44258
|
width: "".concat(percentage, "%")
|
|
44598
44259
|
}
|
|
44599
|
-
})))), showToggleBtn && /*#__PURE__*/React__default.createElement("div", {
|
|
44600
|
-
className: "toast-actions-top"
|
|
44260
|
+
})))), (showToggleBtn || reserveToggleSpace) && /*#__PURE__*/React__default.createElement("div", {
|
|
44261
|
+
className: "toast-actions-top",
|
|
44262
|
+
style: reserveToggleSpace ? {
|
|
44263
|
+
visibility: 'hidden'
|
|
44264
|
+
} : undefined
|
|
44601
44265
|
}, /*#__PURE__*/React__default.createElement("button", {
|
|
44602
44266
|
type: "button",
|
|
44603
44267
|
onClick: onToggleSize,
|
|
@@ -44648,7 +44312,7 @@ var Toast = function Toast(_ref3) {
|
|
|
44648
44312
|
(_toastRef$current = toastRef.current) === null || _toastRef$current === void 0 || _toastRef$current.clear();
|
|
44649
44313
|
onSizeChange(size === "S" ? "L" : "S");
|
|
44650
44314
|
};
|
|
44651
|
-
var sizeClass =
|
|
44315
|
+
var sizeClass = size === "S" ? "toast_s--compact" : sizeModulable && size === "L" ? "toast_s--large" : "";
|
|
44652
44316
|
useEffect(function () {
|
|
44653
44317
|
if (!toastRef.current || !autoShow) return;
|
|
44654
44318
|
if (hasShownRef.current && !reShowOnPropsChange) return;
|
|
@@ -44783,7 +44447,7 @@ var showToast = function showToast() {
|
|
|
44783
44447
|
var currentSize = size;
|
|
44784
44448
|
var _showWithSize = function showWithSize(sz) {
|
|
44785
44449
|
var _toastRef2;
|
|
44786
|
-
var sizeClass =
|
|
44450
|
+
var sizeClass = sz === "S" ? "toast_s--compact" : sizeModulable && sz === "L" ? "toast_s--large" : "";
|
|
44787
44451
|
var expanded = sz === "L";
|
|
44788
44452
|
var handleToggleSize = function handleToggleSize() {
|
|
44789
44453
|
var _toastRef;
|
|
@@ -49367,6 +49031,334 @@ var Table = function Table(_ref1) {
|
|
|
49367
49031
|
})));
|
|
49368
49032
|
};
|
|
49369
49033
|
|
|
49034
|
+
var devises = [{
|
|
49035
|
+
value: 'EUR',
|
|
49036
|
+
code: 'EUR',
|
|
49037
|
+
label: '€',
|
|
49038
|
+
currency: '1'
|
|
49039
|
+
}, {
|
|
49040
|
+
value: 'USD',
|
|
49041
|
+
code: 'USD',
|
|
49042
|
+
label: '$',
|
|
49043
|
+
currency: '1.08'
|
|
49044
|
+
}, {
|
|
49045
|
+
value: 'GBP',
|
|
49046
|
+
code: 'GBP',
|
|
49047
|
+
label: '£',
|
|
49048
|
+
currency: '0.86'
|
|
49049
|
+
}];
|
|
49050
|
+
var currencyEUR = devises.find(function (d) {
|
|
49051
|
+
return d.value === 'EUR';
|
|
49052
|
+
});
|
|
49053
|
+
var statutOptions = [{
|
|
49054
|
+
value: 'actif',
|
|
49055
|
+
label: 'Actif',
|
|
49056
|
+
color: '#27AE60'
|
|
49057
|
+
}, {
|
|
49058
|
+
value: 'inactif',
|
|
49059
|
+
label: 'Inactif',
|
|
49060
|
+
color: '#E67E22'
|
|
49061
|
+
}, {
|
|
49062
|
+
value: 'archive',
|
|
49063
|
+
label: 'Archivé',
|
|
49064
|
+
color: '#95A5A6'
|
|
49065
|
+
}];
|
|
49066
|
+
var serviceTree = [{
|
|
49067
|
+
key: 'tech',
|
|
49068
|
+
label: 'Technologie',
|
|
49069
|
+
children: [{
|
|
49070
|
+
key: 'tech-dev',
|
|
49071
|
+
label: 'Développement'
|
|
49072
|
+
}, {
|
|
49073
|
+
key: 'tech-infra',
|
|
49074
|
+
label: 'Infrastructure'
|
|
49075
|
+
}, {
|
|
49076
|
+
key: 'tech-secu',
|
|
49077
|
+
label: 'Sécurité'
|
|
49078
|
+
}]
|
|
49079
|
+
}, {
|
|
49080
|
+
key: 'metier',
|
|
49081
|
+
label: 'Métier',
|
|
49082
|
+
children: [{
|
|
49083
|
+
key: 'metier-rh',
|
|
49084
|
+
label: 'RH'
|
|
49085
|
+
}, {
|
|
49086
|
+
key: 'metier-compta',
|
|
49087
|
+
label: 'Comptabilité'
|
|
49088
|
+
}, {
|
|
49089
|
+
key: 'metier-jur',
|
|
49090
|
+
label: 'Juridique'
|
|
49091
|
+
}]
|
|
49092
|
+
}, {
|
|
49093
|
+
key: 'support',
|
|
49094
|
+
label: 'Support'
|
|
49095
|
+
}];
|
|
49096
|
+
var competencesOptions = [{
|
|
49097
|
+
value: 'react',
|
|
49098
|
+
label: 'React',
|
|
49099
|
+
color: '#61DAFB'
|
|
49100
|
+
}, {
|
|
49101
|
+
value: 'symfony',
|
|
49102
|
+
label: 'Symfony',
|
|
49103
|
+
color: '#1A171B'
|
|
49104
|
+
}, {
|
|
49105
|
+
value: 'sql',
|
|
49106
|
+
label: 'SQL',
|
|
49107
|
+
color: '#336791'
|
|
49108
|
+
}, {
|
|
49109
|
+
value: 'devops',
|
|
49110
|
+
label: 'DevOps',
|
|
49111
|
+
color: '#EE4C2C'
|
|
49112
|
+
}, {
|
|
49113
|
+
value: 'design',
|
|
49114
|
+
label: 'Design',
|
|
49115
|
+
color: '#FF61F6'
|
|
49116
|
+
}];
|
|
49117
|
+
var dataTyped = [{
|
|
49118
|
+
id: 1,
|
|
49119
|
+
nom: 'Alice Martin',
|
|
49120
|
+
dateInscription: '2023-04-12',
|
|
49121
|
+
dateNaissance: '1990-07-22',
|
|
49122
|
+
statut: 'actif',
|
|
49123
|
+
categorie: 'client',
|
|
49124
|
+
categorieColor: '#2980B9',
|
|
49125
|
+
niveau: 'Élevé',
|
|
49126
|
+
niveauPicto: '/bundles/arengimain/img/picto/eleve.png',
|
|
49127
|
+
competences: ['react', 'symfony'],
|
|
49128
|
+
budget: 12500,
|
|
49129
|
+
score: null,
|
|
49130
|
+
fichiers: [{
|
|
49131
|
+
id: 1,
|
|
49132
|
+
name: 'contrat.pdf',
|
|
49133
|
+
url: '#'
|
|
49134
|
+
}],
|
|
49135
|
+
montant: {
|
|
49136
|
+
value: 12500,
|
|
49137
|
+
devise: devises.find(function (d) {
|
|
49138
|
+
return d.value === 'EUR';
|
|
49139
|
+
})
|
|
49140
|
+
},
|
|
49141
|
+
service: 'tech-dev'
|
|
49142
|
+
}, {
|
|
49143
|
+
id: 2,
|
|
49144
|
+
nom: 'Bob Dupont',
|
|
49145
|
+
dateInscription: '2024-01-05',
|
|
49146
|
+
dateNaissance: '1985-11-03',
|
|
49147
|
+
statut: 'inactif',
|
|
49148
|
+
categorie: 'prospect',
|
|
49149
|
+
categorieColor: '#E67E22',
|
|
49150
|
+
niveau: 'Moyen',
|
|
49151
|
+
niveauPicto: '/bundles/arengimain/img/picto/moyen.png',
|
|
49152
|
+
competences: ['sql'],
|
|
49153
|
+
budget: 4800,
|
|
49154
|
+
score: null,
|
|
49155
|
+
fichiers: [{
|
|
49156
|
+
id: 2,
|
|
49157
|
+
name: 'devis.xlsx',
|
|
49158
|
+
url: '#'
|
|
49159
|
+
}, {
|
|
49160
|
+
id: 3,
|
|
49161
|
+
name: 'facture.pdf',
|
|
49162
|
+
url: '#'
|
|
49163
|
+
}],
|
|
49164
|
+
montant: {
|
|
49165
|
+
value: 5200,
|
|
49166
|
+
devise: devises.find(function (d) {
|
|
49167
|
+
return d.value === 'USD';
|
|
49168
|
+
})
|
|
49169
|
+
},
|
|
49170
|
+
service: 'metier-compta'
|
|
49171
|
+
}, {
|
|
49172
|
+
id: 3,
|
|
49173
|
+
nom: 'Clara Leroy',
|
|
49174
|
+
dateInscription: '2022-09-30',
|
|
49175
|
+
dateNaissance: '1995-02-14',
|
|
49176
|
+
statut: 'actif',
|
|
49177
|
+
categorie: 'partenaire',
|
|
49178
|
+
categorieColor: '#8E44AD',
|
|
49179
|
+
niveau: 'Faible',
|
|
49180
|
+
niveauPicto: '/bundles/arengimain/img/picto/faible.png',
|
|
49181
|
+
competences: ['design', 'react'],
|
|
49182
|
+
budget: 31000,
|
|
49183
|
+
score: null,
|
|
49184
|
+
fichiers: [],
|
|
49185
|
+
montant: {
|
|
49186
|
+
value: 28000,
|
|
49187
|
+
devise: devises.find(function (d) {
|
|
49188
|
+
return d.value === 'GBP';
|
|
49189
|
+
})
|
|
49190
|
+
},
|
|
49191
|
+
service: 'support'
|
|
49192
|
+
}, {
|
|
49193
|
+
id: 4,
|
|
49194
|
+
nom: 'David Bernard',
|
|
49195
|
+
dateInscription: '2023-11-18',
|
|
49196
|
+
dateNaissance: '1978-06-01',
|
|
49197
|
+
statut: 'archive',
|
|
49198
|
+
categorie: 'client',
|
|
49199
|
+
categorieColor: '#2980B9',
|
|
49200
|
+
niveau: 'Élevé',
|
|
49201
|
+
niveauPicto: '/bundles/arengimain/img/picto/eleve.png',
|
|
49202
|
+
competences: ['devops', 'sql', 'symfony'],
|
|
49203
|
+
budget: null,
|
|
49204
|
+
score: null,
|
|
49205
|
+
fichiers: [],
|
|
49206
|
+
montant: null,
|
|
49207
|
+
service: 'tech-infra'
|
|
49208
|
+
}, {
|
|
49209
|
+
id: 5,
|
|
49210
|
+
nom: 'Emma Petit',
|
|
49211
|
+
dateInscription: '2024-03-22',
|
|
49212
|
+
dateNaissance: '2001-12-09',
|
|
49213
|
+
statut: 'actif',
|
|
49214
|
+
categorie: 'prospect',
|
|
49215
|
+
categorieColor: '#E67E22',
|
|
49216
|
+
niveau: null,
|
|
49217
|
+
niveauPicto: null,
|
|
49218
|
+
competences: [],
|
|
49219
|
+
budget: 7200,
|
|
49220
|
+
score: null,
|
|
49221
|
+
fichiers: [{
|
|
49222
|
+
id: 4,
|
|
49223
|
+
name: 'rapport.docx',
|
|
49224
|
+
url: '#'
|
|
49225
|
+
}],
|
|
49226
|
+
montant: {
|
|
49227
|
+
value: 7200,
|
|
49228
|
+
devise: devises.find(function (d) {
|
|
49229
|
+
return d.value === 'EUR';
|
|
49230
|
+
})
|
|
49231
|
+
},
|
|
49232
|
+
service: null
|
|
49233
|
+
}, {
|
|
49234
|
+
id: 6,
|
|
49235
|
+
nom: 'François Morel',
|
|
49236
|
+
dateInscription: '2021-06-15',
|
|
49237
|
+
dateNaissance: '1969-08-27',
|
|
49238
|
+
statut: 'inactif',
|
|
49239
|
+
categorie: 'client',
|
|
49240
|
+
categorieColor: '#2980B9',
|
|
49241
|
+
niveau: 'Moyen',
|
|
49242
|
+
niveauPicto: '/bundles/arengimain/img/picto/moyen.png',
|
|
49243
|
+
competences: ['react', 'devops', 'design'],
|
|
49244
|
+
budget: 18750,
|
|
49245
|
+
score: null,
|
|
49246
|
+
fichiers: [],
|
|
49247
|
+
montant: {
|
|
49248
|
+
value: 18750,
|
|
49249
|
+
devise: devises.find(function (d) {
|
|
49250
|
+
return d.value === 'EUR';
|
|
49251
|
+
})
|
|
49252
|
+
},
|
|
49253
|
+
service: 'metier-rh'
|
|
49254
|
+
}, {
|
|
49255
|
+
id: 7,
|
|
49256
|
+
nom: 'Grace Rousseau',
|
|
49257
|
+
dateInscription: '2025-02-01',
|
|
49258
|
+
dateNaissance: '1993-03-18',
|
|
49259
|
+
statut: 'actif',
|
|
49260
|
+
categorie: 'partenaire',
|
|
49261
|
+
categorieColor: '#8E44AD',
|
|
49262
|
+
niveau: 'Faible',
|
|
49263
|
+
niveauPicto: '/bundles/arengimain/img/picto/faible.png',
|
|
49264
|
+
competences: ['symfony', 'sql'],
|
|
49265
|
+
budget: 9300,
|
|
49266
|
+
score: null,
|
|
49267
|
+
fichiers: [{
|
|
49268
|
+
id: 5,
|
|
49269
|
+
name: 'annexe1.pdf',
|
|
49270
|
+
url: '#'
|
|
49271
|
+
}, {
|
|
49272
|
+
id: 6,
|
|
49273
|
+
name: 'annexe2.pdf',
|
|
49274
|
+
url: '#'
|
|
49275
|
+
}, {
|
|
49276
|
+
id: 7,
|
|
49277
|
+
name: 'annexe3.pdf',
|
|
49278
|
+
url: '#'
|
|
49279
|
+
}],
|
|
49280
|
+
montant: {
|
|
49281
|
+
value: 9800,
|
|
49282
|
+
devise: devises.find(function (d) {
|
|
49283
|
+
return d.value === 'USD';
|
|
49284
|
+
})
|
|
49285
|
+
},
|
|
49286
|
+
service: 'tech-secu'
|
|
49287
|
+
}];
|
|
49288
|
+
var columnsTyped = [{
|
|
49289
|
+
field: 'nom',
|
|
49290
|
+
header: 'Nom',
|
|
49291
|
+
type: 'link',
|
|
49292
|
+
href: function href(row) {
|
|
49293
|
+
return "/risques/".concat(row.id);
|
|
49294
|
+
}
|
|
49295
|
+
}, {
|
|
49296
|
+
field: 'dateInscription',
|
|
49297
|
+
header: 'Inscription',
|
|
49298
|
+
type: 'date'
|
|
49299
|
+
}, {
|
|
49300
|
+
field: 'dateNaissance',
|
|
49301
|
+
header: 'Naissance',
|
|
49302
|
+
type: 'date',
|
|
49303
|
+
hidden: true
|
|
49304
|
+
}, {
|
|
49305
|
+
field: 'statut',
|
|
49306
|
+
header: 'Statut',
|
|
49307
|
+
type: 'select',
|
|
49308
|
+
options: statutOptions
|
|
49309
|
+
}, {
|
|
49310
|
+
field: 'categorie',
|
|
49311
|
+
header: 'Catégorie',
|
|
49312
|
+
type: 'colorText'
|
|
49313
|
+
}, {
|
|
49314
|
+
field: 'niveau',
|
|
49315
|
+
header: 'Niveau',
|
|
49316
|
+
type: 'picto'
|
|
49317
|
+
}, {
|
|
49318
|
+
field: 'competences',
|
|
49319
|
+
header: 'Compétences',
|
|
49320
|
+
type: 'selectMultiple',
|
|
49321
|
+
options: competencesOptions
|
|
49322
|
+
}, {
|
|
49323
|
+
field: 'budget',
|
|
49324
|
+
header: 'Budget (€)',
|
|
49325
|
+
type: 'numeric',
|
|
49326
|
+
min: 0
|
|
49327
|
+
}, {
|
|
49328
|
+
field: 'score',
|
|
49329
|
+
header: 'Score calculé',
|
|
49330
|
+
type: 'calcul',
|
|
49331
|
+
render: function render(row) {
|
|
49332
|
+
return row.budget != null ? "".concat(Math.round(row.budget / 1000), " pts") : '—';
|
|
49333
|
+
}
|
|
49334
|
+
}, {
|
|
49335
|
+
field: 'fichiers',
|
|
49336
|
+
header: 'Fichiers',
|
|
49337
|
+
type: 'documents',
|
|
49338
|
+
uploadUrl: '/api/upload'
|
|
49339
|
+
}, {
|
|
49340
|
+
field: 'montant',
|
|
49341
|
+
header: 'Montant',
|
|
49342
|
+
type: 'devise',
|
|
49343
|
+
currency: currencyEUR,
|
|
49344
|
+
devises: devises,
|
|
49345
|
+
decimal: 2
|
|
49346
|
+
}, {
|
|
49347
|
+
field: 'service',
|
|
49348
|
+
header: 'Service',
|
|
49349
|
+
type: 'treeSelect',
|
|
49350
|
+
options: serviceTree,
|
|
49351
|
+
selectionMode: 'single',
|
|
49352
|
+
filter: true
|
|
49353
|
+
}];
|
|
49354
|
+
var TablePresets = {
|
|
49355
|
+
Base: {
|
|
49356
|
+
value: dataTyped,
|
|
49357
|
+
columns: columnsTyped,
|
|
49358
|
+
editable: true
|
|
49359
|
+
}
|
|
49360
|
+
};
|
|
49361
|
+
|
|
49370
49362
|
// ── Données d'exemple : organisations avec couleur + idFonctionnel ────────────
|
|
49371
49363
|
// Structure identique à ce que retourne l'API Symfony (data['organisations'] de jqtree)
|
|
49372
49364
|
// Chaque nœud possède : key (= id stringify), label (= name), couleur (hex sans #),
|