@airporting/tech-app 0.0.119 → 0.0.120

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.
Files changed (199) hide show
  1. package/dist/mf/{2436.js → 1330.1484499663.js} +3 -3
  2. package/dist/mf/1558.e66a54e73d.js +1 -0
  3. package/dist/mf/2338.94e69795ff.js +1 -0
  4. package/dist/mf/2538.1c194a4bcd.js +1 -0
  5. package/dist/mf/2717.8f7084b540.js +10 -0
  6. package/dist/mf/{2588.js → 3235.0c4841ef2f.js} +3 -3
  7. package/dist/mf/3548.a2ac3faf5f.js +1 -0
  8. package/dist/mf/{2014.js → 3711.906c609c43.js} +3 -3
  9. package/dist/mf/3887.56ec961d24.js +33 -0
  10. package/dist/mf/{9439.js → 409.46a4910f4b.js} +2 -2
  11. package/dist/mf/5098.4ad55bcb49.js +10 -0
  12. package/dist/mf/5105.2a1806dc50.js +1 -0
  13. package/dist/mf/537.b7edba1af9.js +14 -0
  14. package/dist/mf/5429.eecc07ae26.js +1 -0
  15. package/dist/mf/5564.042f491bc7.js +1 -0
  16. package/dist/mf/{5732.js → 5616.daffd848ee.js} +3 -3
  17. package/dist/mf/{4153.js → 6237.60683e513e.js} +3 -3
  18. package/dist/mf/668.a271d6c3a3.js +1 -0
  19. package/dist/mf/6755.3b2751c6d2.js +1 -0
  20. package/dist/mf/690.0d77cae419.js +1 -0
  21. package/dist/mf/7486.84364f2d01.js +10 -0
  22. package/dist/mf/758.f1fe1bef41.js +10 -0
  23. package/dist/mf/7770.9beba1af8b.js +1 -0
  24. package/dist/mf/7883.45585213d9.js +1 -0
  25. package/dist/mf/8083.a86dc5cbbe.js +1 -0
  26. package/dist/mf/8473.91f080bae1.js +10 -0
  27. package/dist/mf/854.1a1d1ce0ec.js +10 -0
  28. package/dist/mf/8853.a8b3155879.js +18 -0
  29. package/dist/mf/8949.3f7e30e10c.js +10 -0
  30. package/dist/mf/9415.f2a6811f8c.js +1 -0
  31. package/dist/mf/9698.34be02ab76.js +26 -0
  32. package/dist/mf/{index.css → 9698.78f690ae77.css} +105 -77
  33. package/dist/mf/@mf-types.zip +0 -0
  34. package/dist/mf/__federation_expose_amex.9b5f7a13cf.js +10 -0
  35. package/dist/mf/__federation_expose_bnpp.9e26515b6b.js +10 -0
  36. package/dist/mf/__federation_expose_credmut.e8f19cfe8a.js +10 -0
  37. package/dist/mf/__federation_expose_dashboard.be190d6c02.js +10 -0
  38. package/dist/mf/__federation_expose_etat_saisie.645bdc16bc.js +10 -0
  39. package/dist/mf/__federation_expose_finance_jobs.944394079e.js +1 -0
  40. package/dist/mf/__federation_expose_github.707a6236f7.js +10 -0
  41. package/dist/mf/__federation_expose_mcp_access.82a422dded.js +10 -0
  42. package/dist/mf/__federation_expose_mcp_access.82a422dded.js.LICENSE.txt +9 -0
  43. package/dist/mf/__federation_expose_payfit.515eac3595.js +10 -0
  44. package/dist/mf/__federation_expose_payfit.515eac3595.js.LICENSE.txt +9 -0
  45. package/dist/mf/__federation_expose_sales.b781a94a8a.js +10 -0
  46. package/dist/mf/__federation_expose_sales.b781a94a8a.js.LICENSE.txt +9 -0
  47. package/dist/mf/__federation_expose_scrapers.ec2bebbb38.js +10 -0
  48. package/dist/mf/__federation_expose_scrapers.ec2bebbb38.js.LICENSE.txt +9 -0
  49. package/dist/mf/__federation_expose_spendesk.f36a6189d1.js +10 -0
  50. package/dist/mf/__federation_expose_spendesk.f36a6189d1.js.LICENSE.txt +9 -0
  51. package/dist/mf/__federation_expose_spreadsheet.552786fca7.js +1 -0
  52. package/dist/mf/__federation_expose_synchro.a358d53b47.js +10 -0
  53. package/dist/mf/__federation_expose_synchro.a358d53b47.js.LICENSE.txt +9 -0
  54. package/dist/mf/__federation_expose_usage.61e16f490e.js +10 -0
  55. package/dist/mf/__federation_expose_usage.61e16f490e.js.LICENSE.txt +9 -0
  56. package/dist/mf/__federation_expose_wise.b31a4dcd88.js +10 -0
  57. package/dist/mf/__federation_expose_wise.b31a4dcd88.js.LICENSE.txt +9 -0
  58. package/dist/mf/index.71e639cd3c.css +2 -0
  59. package/dist/mf/index.973c391254.js +6 -0
  60. package/dist/mf/mf-manifest.json +229 -199
  61. package/dist/mf/mf-stats.json +255 -207
  62. package/dist/mf/tech_app.970d9761d3.js +6 -0
  63. package/package.json +11 -11
  64. package/dist/mf/1.js +0 -1
  65. package/dist/mf/1659.js +0 -1
  66. package/dist/mf/2880.js +0 -1
  67. package/dist/mf/3080.js +0 -1
  68. package/dist/mf/3364.js +0 -14
  69. package/dist/mf/3429.js +0 -33
  70. package/dist/mf/3724.js +0 -1
  71. package/dist/mf/5178.js +0 -1
  72. package/dist/mf/5182.js +0 -10
  73. package/dist/mf/5772.js +0 -10
  74. package/dist/mf/6110.js +0 -18
  75. package/dist/mf/6548.js +0 -10
  76. package/dist/mf/7364.js +0 -1
  77. package/dist/mf/7378.js +0 -10
  78. package/dist/mf/7380.js +0 -1
  79. package/dist/mf/7541.js +0 -1
  80. package/dist/mf/7832.js +0 -10
  81. package/dist/mf/7906.js +0 -1
  82. package/dist/mf/8119.js +0 -1
  83. package/dist/mf/9186.js +0 -1
  84. package/dist/mf/9260.js +0 -1
  85. package/dist/mf/9622.js +0 -10
  86. package/dist/mf/9669.js +0 -10
  87. package/dist/mf/__federation_expose_amex.js +0 -10
  88. package/dist/mf/__federation_expose_bnpp.js +0 -10
  89. package/dist/mf/__federation_expose_credmut.js +0 -10
  90. package/dist/mf/__federation_expose_dashboard.js +0 -1
  91. package/dist/mf/__federation_expose_etat_saisie.js +0 -1
  92. package/dist/mf/__federation_expose_finance_jobs.js +0 -1
  93. package/dist/mf/__federation_expose_github.js +0 -1
  94. package/dist/mf/__federation_expose_mcp_access.js +0 -1
  95. package/dist/mf/__federation_expose_payfit.js +0 -10
  96. package/dist/mf/__federation_expose_sales.js +0 -1
  97. package/dist/mf/__federation_expose_scrapers.js +0 -1
  98. package/dist/mf/__federation_expose_spendesk.js +0 -10
  99. package/dist/mf/__federation_expose_spreadsheet.js +0 -1
  100. package/dist/mf/__federation_expose_synchro.js +0 -1
  101. package/dist/mf/__federation_expose_usage.js +0 -1
  102. package/dist/mf/__federation_expose_wise.js +0 -10
  103. package/dist/mf/index.js +0 -30
  104. package/dist/mf/tech_app.js +0 -5
  105. /package/dist/mf/{2014.js.LICENSE.txt → 1330.1484499663.js.LICENSE.txt} +0 -0
  106. /package/dist/mf/{5182.js.LICENSE.txt → 2717.8f7084b540.js.LICENSE.txt} +0 -0
  107. /package/dist/mf/{2436.js.LICENSE.txt → 3235.0c4841ef2f.js.LICENSE.txt} +0 -0
  108. /package/dist/mf/{2588.js.LICENSE.txt → 3711.906c609c43.js.LICENSE.txt} +0 -0
  109. /package/dist/mf/{3429.js.LICENSE.txt → 3887.56ec961d24.js.LICENSE.txt} +0 -0
  110. /package/dist/mf/{9439.js.LICENSE.txt → 409.46a4910f4b.js.LICENSE.txt} +0 -0
  111. /package/dist/mf/{9622.js.LICENSE.txt → 5098.4ad55bcb49.js.LICENSE.txt} +0 -0
  112. /package/dist/mf/{5732.js.LICENSE.txt → 5616.daffd848ee.js.LICENSE.txt} +0 -0
  113. /package/dist/mf/{4153.js.LICENSE.txt → 6237.60683e513e.js.LICENSE.txt} +0 -0
  114. /package/dist/mf/{5772.js.LICENSE.txt → 7486.84364f2d01.js.LICENSE.txt} +0 -0
  115. /package/dist/mf/{6548.js.LICENSE.txt → 758.f1fe1bef41.js.LICENSE.txt} +0 -0
  116. /package/dist/mf/{7378.js.LICENSE.txt → 8473.91f080bae1.js.LICENSE.txt} +0 -0
  117. /package/dist/mf/{7832.js.LICENSE.txt → 854.1a1d1ce0ec.js.LICENSE.txt} +0 -0
  118. /package/dist/mf/{6110.js.LICENSE.txt → 8853.a8b3155879.js.LICENSE.txt} +0 -0
  119. /package/dist/mf/{9669.js.LICENSE.txt → 8949.3f7e30e10c.js.LICENSE.txt} +0 -0
  120. /package/dist/mf/{index.js.LICENSE.txt → 9698.34be02ab76.js.LICENSE.txt} +0 -0
  121. /package/dist/mf/{__federation_expose_amex.js.LICENSE.txt → __federation_expose_amex.9b5f7a13cf.js.LICENSE.txt} +0 -0
  122. /package/dist/mf/{__federation_expose_bnpp.js.LICENSE.txt → __federation_expose_bnpp.9e26515b6b.js.LICENSE.txt} +0 -0
  123. /package/dist/mf/{__federation_expose_credmut.js.LICENSE.txt → __federation_expose_credmut.e8f19cfe8a.js.LICENSE.txt} +0 -0
  124. /package/dist/mf/{__federation_expose_payfit.js.LICENSE.txt → __federation_expose_dashboard.be190d6c02.js.LICENSE.txt} +0 -0
  125. /package/dist/mf/{__federation_expose_spendesk.js.LICENSE.txt → __federation_expose_etat_saisie.645bdc16bc.js.LICENSE.txt} +0 -0
  126. /package/dist/mf/{__federation_expose_wise.js.LICENSE.txt → __federation_expose_github.707a6236f7.js.LICENSE.txt} +0 -0
  127. /package/dist/mf/static/font/{HostGrotesk-VariableFont_wght.ttf → HostGrotesk-VariableFont_wght.5248a50f8f.ttf} +0 -0
  128. /package/dist/mf/static/font/{IBMPlexSans-VariableFont_wdth,wght.ttf → IBMPlexSans-VariableFont_wdth,wght.b9dbc346df.ttf} +0 -0
  129. /package/dist/mf/static/svg/{ad.svg → ad.b565cad3b9.svg} +0 -0
  130. /package/dist/mf/static/svg/{af.svg → af.c6050ccd88.svg} +0 -0
  131. /package/dist/mf/static/svg/{arab.svg → arab.979580f271.svg} +0 -0
  132. /package/dist/mf/static/svg/{as.svg → as.01647fade1.svg} +0 -0
  133. /package/dist/mf/static/svg/{aw.svg → aw.38f249536e.svg} +0 -0
  134. /package/dist/mf/static/svg/{bm.svg → bm.a27098d2f0.svg} +0 -0
  135. /package/dist/mf/static/svg/{bn.svg → bn.c13ab93d4e.svg} +0 -0
  136. /package/dist/mf/static/svg/{bo.svg → bo.9eafaa771a.svg} +0 -0
  137. /package/dist/mf/static/svg/{br.svg → br.67a6502fcc.svg} +0 -0
  138. /package/dist/mf/static/svg/{bt.svg → bt.1a35bb5790.svg} +0 -0
  139. /package/dist/mf/static/svg/{bz.svg → bz.07b1393a39.svg} +0 -0
  140. /package/dist/mf/static/svg/{cy.svg → cy.239da48548.svg} +0 -0
  141. /package/dist/mf/static/svg/{dg.svg → dg.2de1a54797.svg} +0 -0
  142. /package/dist/mf/static/svg/{dm.svg → dm.c3205e29a5.svg} +0 -0
  143. /package/dist/mf/static/svg/{do.svg → do.5dff1c5f2d.svg} +0 -0
  144. /package/dist/mf/static/svg/{eac.svg → eac.8d4776f547.svg} +0 -0
  145. /package/dist/mf/static/svg/{ec.svg → ec.fe749fb472.svg} +0 -0
  146. /package/dist/mf/static/svg/{eg.svg → eg.047d5d7822.svg} +0 -0
  147. /package/dist/mf/static/svg/{es-ga.svg → es-ga.13ecfea239.svg} +0 -0
  148. /package/dist/mf/static/svg/{es.svg → es.b74b736606.svg} +0 -0
  149. /package/dist/mf/static/svg/{fj.svg → fj.a7cdc5d921.svg} +0 -0
  150. /package/dist/mf/static/svg/{fk.svg → fk.2fa702939b.svg} +0 -0
  151. /package/dist/mf/static/svg/{gb-nir.svg → gb-nir.8ec547f4f5.svg} +0 -0
  152. /package/dist/mf/static/svg/{gb-wls.svg → gb-wls.1cf3d9cc10.svg} +0 -0
  153. /package/dist/mf/static/svg/{gq.svg → gq.c572f675c8.svg} +0 -0
  154. /package/dist/mf/static/svg/{gs.svg → gs.fe3374bb83.svg} +0 -0
  155. /package/dist/mf/static/svg/{gt.svg → gt.097451fc17.svg} +0 -0
  156. /package/dist/mf/static/svg/{gu.svg → gu.b033e7a688.svg} +0 -0
  157. /package/dist/mf/static/svg/{hr.svg → hr.f0c84cca2a.svg} +0 -0
  158. /package/dist/mf/static/svg/{ht.svg → ht.9f91507754.svg} +0 -0
  159. /package/dist/mf/static/svg/{im.svg → im.479ad3e9b6.svg} +0 -0
  160. /package/dist/mf/static/svg/{io.svg → io.fc7eebc158.svg} +0 -0
  161. /package/dist/mf/static/svg/{ir.svg → ir.801fbb847c.svg} +0 -0
  162. /package/dist/mf/static/svg/{je.svg → je.2b7a276f75.svg} +0 -0
  163. /package/dist/mf/static/svg/{kg.svg → kg.994fed1d50.svg} +0 -0
  164. /package/dist/mf/static/svg/{kh.svg → kh.e67aa6fd5c.svg} +0 -0
  165. /package/dist/mf/static/svg/{ki.svg → ki.9e4e595c2f.svg} +0 -0
  166. /package/dist/mf/static/svg/{ky.svg → ky.c6d5a8d576.svg} +0 -0
  167. /package/dist/mf/static/svg/{kz.svg → kz.07b60b89d0.svg} +0 -0
  168. /package/dist/mf/static/svg/{li.svg → li.5cded3252c.svg} +0 -0
  169. /package/dist/mf/static/svg/{lk.svg → lk.23166e8c77.svg} +0 -0
  170. /package/dist/mf/static/svg/{md.svg → md.dba4c7fc54.svg} +0 -0
  171. /package/dist/mf/static/svg/{me.svg → me.7e20b942ca.svg} +0 -0
  172. /package/dist/mf/static/svg/{mp.svg → mp.8842d0ea8c.svg} +0 -0
  173. /package/dist/mf/static/svg/{ms.svg → ms.2e19586bd0.svg} +0 -0
  174. /package/dist/mf/static/svg/{mt.svg → mt.b8ab0ef5e2.svg} +0 -0
  175. /package/dist/mf/static/svg/{mx.svg → mx.bc25957663.svg} +0 -0
  176. /package/dist/mf/static/svg/{nf.svg → nf.407d2ab842.svg} +0 -0
  177. /package/dist/mf/static/svg/{ni.svg → ni.bf7fcea52d.svg} +0 -0
  178. /package/dist/mf/static/svg/{om.svg → om.449f75b209.svg} +0 -0
  179. /package/dist/mf/static/svg/{pn.svg → pn.b4e1ab6aa7.svg} +0 -0
  180. /package/dist/mf/static/svg/{pt.svg → pt.acd403c018.svg} +0 -0
  181. /package/dist/mf/static/svg/{py.svg → py.6523d7909b.svg} +0 -0
  182. /package/dist/mf/static/svg/{rs.svg → rs.0f45ed27ff.svg} +0 -0
  183. /package/dist/mf/static/svg/{sa.svg → sa.9a769000dc.svg} +0 -0
  184. /package/dist/mf/static/svg/{sh-ac.svg → sh-ac.103f8fd9a6.svg} +0 -0
  185. /package/dist/mf/static/svg/{sh-hl.svg → sh-hl.664afc561d.svg} +0 -0
  186. /package/dist/mf/static/svg/{sh-ta.svg → sh-ta.9e06bc08e4.svg} +0 -0
  187. /package/dist/mf/static/svg/{sm.svg → sm.9f3be35f44.svg} +0 -0
  188. /package/dist/mf/static/svg/{sv.svg → sv.4a7ef34153.svg} +0 -0
  189. /package/dist/mf/static/svg/{sx.svg → sx.ba3ea51fe1.svg} +0 -0
  190. /package/dist/mf/static/svg/{sz.svg → sz.61ba2742e1.svg} +0 -0
  191. /package/dist/mf/static/svg/{tc.svg → tc.1d40ce70d6.svg} +0 -0
  192. /package/dist/mf/static/svg/{tm.svg → tm.6a8ec56b96.svg} +0 -0
  193. /package/dist/mf/static/svg/{un.svg → un.98053442eb.svg} +0 -0
  194. /package/dist/mf/static/svg/{va.svg → va.959875d92d.svg} +0 -0
  195. /package/dist/mf/static/svg/{vg.svg → vg.56b7d72255.svg} +0 -0
  196. /package/dist/mf/static/svg/{vi.svg → vi.aaeab1462a.svg} +0 -0
  197. /package/dist/mf/static/svg/{xk.svg → xk.961776b909.svg} +0 -0
  198. /package/dist/mf/static/svg/{zm.svg → zm.ef3a9aef9f.svg} +0 -0
  199. /package/dist/mf/static/svg/{zw.svg → zw.3e71d5a4d2.svg} +0 -0
@@ -0,0 +1,10 @@
1
+ /*! LICENSE: __federation_expose_spendesk.f36a6189d1.js.LICENSE.txt */
2
+ "use strict";(globalThis["chunk_tech_app "]||=[]).push([[3556],{9698(__unused_rspack_module,exports){/**
3
+ * @license React
4
+ * react-jsx-runtime.production.js
5
+ *
6
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
7
+ *
8
+ * This source code is licensed under the MIT license found in the
9
+ * LICENSE file in the root directory of this source tree.
10
+ */var REACT_ELEMENT_TYPE=Symbol.for("react.transitional.element"),REACT_FRAGMENT_TYPE=Symbol.for("react.fragment");function jsxProd(type,config,maybeKey){var key=null;void 0!==maybeKey&&(key=""+maybeKey);void 0!==config.key&&(key=""+config.key);if("key"in config){maybeKey={};for(var propName in config)"key"!==propName&&(maybeKey[propName]=config[propName])}else maybeKey=config;config=maybeKey.ref;return{$$typeof:REACT_ELEMENT_TYPE,type:type,key:key,ref:void 0!==config?config:null,props:maybeKey}}exports.Fragment=REACT_FRAGMENT_TYPE;exports.jsx=jsxProd;exports.jsxs=jsxProd},4848(module,__unused_rspack_exports,__webpack_require__){module.exports=__webpack_require__(9698)},7785(__unused_rspack_module,__webpack_exports__,__webpack_require__){var react__rspack_import_0=__webpack_require__(814);const AppConfigCtx=(0,react__rspack_import_0.createContext)(null);const AppConfigProvider=AppConfigCtx.Provider;function useAppConfig(){const config=(0,react__rspack_import_0.useContext)(AppConfigCtx);if(!config)throw new Error("Called `useAppConfig` outside a `<AppConfigProvider />`");return config}__webpack_require__.d(__webpack_exports__,{r:()=>useAppConfig},{X:AppConfigProvider})},9528(__unused_rspack_module,__webpack_exports__,__webpack_require__){var react_jsx_runtime__rspack_import_0=__webpack_require__(4848);var _airporting_app_front__rspack_import_1=__webpack_require__(5456);var _mantine_core__rspack_import_2=__webpack_require__(4618);var _mantine_modals__rspack_import_3=__webpack_require__(3536);var _mantine_notifications__rspack_import_4=__webpack_require__(7250);var _tanstack_react_query__rspack_import_5=__webpack_require__(3411);var radash__rspack_import_6=__webpack_require__(5551);var _hooks_useAppConfig__rspack_import_7=__webpack_require__(7785);const theme=(0,_mantine_core__rspack_import_2.createTheme)((0,radash__rspack_import_6.assign)(_airporting_app_front__rspack_import_1.theme,{components:{}}));const cssVarResolver=x=>(0,radash__rspack_import_6.assign)(_airporting_app_front__rspack_import_1.cssVarResolver(x),{dark:{},light:{},variables:{}});function Providers(props){const{children,config,mantine,tanstack}=props;return/*#__PURE__*/(0,react_jsx_runtime__rspack_import_0.jsx)(_hooks_useAppConfig__rspack_import_7.X,{value:config,children:/*#__PURE__*/(0,react_jsx_runtime__rspack_import_0.jsx)(_tanstack_react_query__rspack_import_5.QueryClientProvider,{client:tanstack?.queryClient??new _tanstack_react_query__rspack_import_5.QueryClient,children:/*#__PURE__*/(0,react_jsx_runtime__rspack_import_0.jsx)(_mantine_core__rspack_import_2.MantineProvider,{theme:theme,cssVariablesResolver:cssVarResolver,defaultColorScheme:mantine?.defaultColorScheme,forceColorScheme:mantine?.forceColorScheme,children:/*#__PURE__*/(0,react_jsx_runtime__rspack_import_0.jsxs)(_mantine_modals__rspack_import_3.ModalsProvider,{children:[/*#__PURE__*/(0,react_jsx_runtime__rspack_import_0.jsx)(_mantine_notifications__rspack_import_4.Notifications,{}),children]})})})})}__webpack_require__.d(__webpack_exports__,{b:()=>Providers})},9579(__unused_rspack_module,__webpack_exports__,__webpack_require__){__webpack_require__.r(__webpack_exports__);__webpack_require__.d(__webpack_exports__,{default:()=>Spendesk});var jsx_runtime=__webpack_require__(4848);var index_js_=__webpack_require__(814);var providers=__webpack_require__(9528);var index_mjs_=__webpack_require__(4618);function SpendeskApp(){return/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Container,{my:"md",children:/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Title,{order:2,my:"md",children:"Spendesk - soon"})})}function Spendesk(props){return/*#__PURE__*/(0,jsx_runtime.jsx)(index_js_.StrictMode,{children:/*#__PURE__*/(0,jsx_runtime.jsx)(providers.b,{...props,children:/*#__PURE__*/(0,jsx_runtime.jsx)(SpendeskApp,{})})})}}}]);
@@ -0,0 +1,9 @@
1
+ /**
2
+ * @license React
3
+ * react-jsx-runtime.production.js
4
+ *
5
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
6
+ *
7
+ * This source code is licensed under the MIT license found in the
8
+ * LICENSE file in the root directory of this source tree.
9
+ */
@@ -0,0 +1 @@
1
+ "use strict";(globalThis["chunk_tech_app "]||=[]).push([[9243],{4754(__unused_rspack_module,__webpack_exports__,__webpack_require__){var _tanstack_react_query__rspack_import_0=__webpack_require__(3411);var _useApi__rspack_import_1=__webpack_require__(4691);function useGsheetStock(filters={}){const api=(0,_useApi__rspack_import_1.g)();const query={...filters.period&&{period:filters.period}};return(0,_tanstack_react_query__rspack_import_0.useQuery)({queryKey:["tech","gsheet","stock",filters],queryFn:async()=>(await api.gsheet.getStockV1({query})).data,refetchInterval:3e4,refetchIntervalInBackground:false,refetchOnWindowFocus:true})}__webpack_require__.d(__webpack_exports__,{s:()=>useGsheetStock})},1239(__unused_rspack_module,__webpack_exports__,__webpack_require__){var react_jsx_runtime__rspack_import_0=__webpack_require__(4848);var _mantine_core__rspack_import_1=__webpack_require__(4618);var _src_components_logoDev_ts__rspack_import_2=__webpack_require__(2137);function BrandLogo({domain,alt,size=24}){return/*#__PURE__*/(0,react_jsx_runtime__rspack_import_0.jsx)(_mantine_core__rspack_import_1.Image,{src:(0,_src_components_logoDev_ts__rspack_import_2.w)(domain),alt:alt,title:alt,w:size,h:size,fit:"contain",radius:"sm",style:{aspectRatio:1}})}__webpack_require__.d(__webpack_exports__,{F:()=>BrandLogo})},2137(__unused_rspack_module,__webpack_exports__,__webpack_require__){const LOGO_DEV_TOKEN="pk_BVN4OQv0Qs-bnqjdIgTppg";function logoDevUrl(domain){return`https://img.logo.dev/${domain}?token=${LOGO_DEV_TOKEN}`}__webpack_require__.d(__webpack_exports__,{w:()=>logoDevUrl})},9871(__unused_rspack_module,__webpack_exports__,__webpack_require__){__webpack_require__.r(__webpack_exports__);__webpack_require__.d(__webpack_exports__,{default:()=>Spreadsheet});var jsx_runtime=__webpack_require__(4848);var index_js_=__webpack_require__(814);var providers=__webpack_require__(9528);var QueueDashboard=__webpack_require__(5029);var index_mjs_=__webpack_require__(4618);var tabler_icons_react_mjs_=__webpack_require__(2638);var gsheetStockQuery=__webpack_require__(4754);var modern_index_js_=__webpack_require__(3411);var useApi=__webpack_require__(4691);function useGsheetTasks(filters){const api=(0,useApi.g)();const service=filters.service?.toLowerCase()==="all"?void 0:filters.service;const owner=filters.owner?.toLowerCase()==="all"?void 0:filters.owner;const query={...service&&{service},...owner&&{owner},...filters.state&&{state:filters.state},...filters.period&&{period:filters.period},...void 0!==filters.take&&{take:String(filters.take)},...void 0!==filters.skip&&{skip:String(filters.skip)}};return(0,modern_index_js_.useQuery)({queryKey:["tech","gsheet","tasks",filters],queryFn:async()=>(await api.gsheet.listTasksV1(query)).data,refetchOnWindowFocus:false})}function useInvalidate(){const queryClient=(0,modern_index_js_.useQueryClient)();return()=>queryClient.invalidateQueries({queryKey:["tech","gsheet"]})}function useUnstickTask(){const api=(0,useApi.g)();const invalidate=useInvalidate();return(0,modern_index_js_.useMutation)({mutationFn:async id=>(await api.gsheet.unstickV1({id:String(id)})).data,onSuccess:invalidate})}function useDiscardTask(){const api=(0,useApi.g)();const invalidate=useInvalidate();return(0,modern_index_js_.useMutation)({mutationFn:async id=>(await api.gsheet.discardV1({id:String(id)})).data,onSuccess:invalidate})}function useSetTaskOwner(){const api=(0,useApi.g)();const invalidate=useInvalidate();return(0,modern_index_js_.useMutation)({mutationFn:async({id,owner})=>(await api.gsheet.setOwnerV1({id:String(id)},{owner})).data,onSuccess:invalidate})}function useDeleteRedisLock(){const api=(0,useApi.g)();const invalidate=useInvalidate();return(0,modern_index_js_.useMutation)({mutationFn:async id=>(await api.gsheet.deleteRedisLockV1({id:String(id)})).data,onSuccess:invalidate})}var jobLogsContext=__webpack_require__(7495);var esm_index_mjs_=__webpack_require__(7250);function grafanaUrl(traceId){return`https://airporting.grafana.net/d/beegyy3vsp8n4c/recipes?var-trace=${encodeURIComponent(traceId)}&orgId=1&from=now-7d&to=now&timezone=browser&showCategory=Logs&refresh=7d`}function notify(title,message,color){esm_index_mjs_.notifications.show({title,message,color})}function RowActions({taskId,currentOwner,service,spreadsheet,worksheet,githubJob,traceId,onShowLogs}){const[confirm,setConfirm]=(0,index_js_.useState)(null);const[ownerModalOpen,setOwnerModalOpen]=(0,index_js_.useState)(false);const[ownerInput,setOwnerInput]=(0,index_js_.useState)(currentOwner??"");const unstick=useUnstickTask();const discard=useDiscardTask();const setOwner=useSetTaskOwner();const deleteLock=useDeleteRedisLock();const runUnstick=()=>unstick.mutate(taskId,{onSuccess:()=>notify("Unstuck",`Task #${taskId} reset`,"green"),onError:e=>notify("Failed",e?.message??"Unstick failed","red")});const runDiscard=()=>{setConfirm(null);discard.mutate(taskId,{onSuccess:()=>notify("Discarded",`Task #${taskId} marked done`,"green"),onError:e=>notify("Failed",e?.message??"Discard failed","red")})};const runSetOwner=()=>{setOwnerModalOpen(false);setOwner.mutate({id:taskId,owner:ownerInput},{onSuccess:()=>notify("Owner updated",`Task #${taskId} → ${ownerInput}`,"green"),onError:e=>notify("Failed",e?.message??"Set owner failed","red")})};const runDeleteLock=()=>{setConfirm(null);deleteLock.mutate(taskId,{onSuccess:data=>notify("Redis lock",data.existed?`Deleted ${data.key}`:`No lock found (${data.key})`,"green"),onError:e=>notify("Failed",e?.message??"Redis delete failed","red")})};const getWorksheetUrl=()=>{if(!spreadsheet)return null;return"excel"===service?`https://airporting.sharepoint.com/:x:/g/personal/airporting_com/ER${spreadsheet}`:`https://docs.google.com/spreadsheets/d/${spreadsheet}/edit`};const worksheetUrl=getWorksheetUrl();return/*#__PURE__*/(0,jsx_runtime.jsxs)(jsx_runtime.Fragment,{children:[/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Group,{gap:"xs",children:[worksheetUrl&&/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Tooltip,{label:"Ouvrir le tableur",children:/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.ActionIcon,{component:"a",href:worksheetUrl,target:"_blank",rel:"noopener noreferrer",variant:"subtle","aria-label":"Ouvrir le tableur",children:/*#__PURE__*/(0,jsx_runtime.jsx)(tabler_icons_react_mjs_.IconFileSpreadsheet,{size:16})})}),githubJob&&/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Tooltip,{label:"GitHub Actions logs",children:/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.ActionIcon,{variant:"subtle",onClick:()=>onShowLogs(githubJob),"aria-label":"GitHub Actions logs",children:/*#__PURE__*/(0,jsx_runtime.jsx)(tabler_icons_react_mjs_.IconTerminal,{size:16})})}),traceId&&/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Tooltip,{label:"Grafana Loki logs",children:/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.ActionIcon,{component:"a",href:grafanaUrl(traceId),target:"_blank",rel:"noopener noreferrer",variant:"subtle","aria-label":"Grafana Loki logs",children:/*#__PURE__*/(0,jsx_runtime.jsx)(tabler_icons_react_mjs_.IconFileText,{size:16})})}),/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Menu,{position:"bottom-end",withArrow:true,shadow:"md",children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Menu.Target,{children:/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.ActionIcon,{variant:"default","aria-label":"Actions",children:"⋮"})}),/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Menu.Dropdown,{children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Menu.Item,{onClick:runUnstick,children:"Unstick"}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Menu.Item,{onClick:()=>{setOwnerInput(currentOwner??"");setOwnerModalOpen(true)},children:"Set owner…"}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Menu.Item,{onClick:()=>setConfirm("redis"),children:"Delete Redis lock"}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Menu.Divider,{}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Menu.Item,{color:"red",onClick:()=>setConfirm("discard"),children:"Discard"})]})]})]}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Modal,{opened:"discard"===confirm,onClose:()=>setConfirm(null),title:"Discard task",children:/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Stack,{children:[/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Text,{size:"sm",style:{wordBreak:"break-all"},children:["Mark task #",taskId," (",spreadsheet,worksheet?`:${worksheet}`:"",") as ",/*#__PURE__*/(0,jsx_runtime.jsx)("b",{children:"done"})," with step=",/*#__PURE__*/(0,jsx_runtime.jsx)("code",{children:"discarded"}),". The task will not be processed by the runner."]}),/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Group,{justify:"flex-end",children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Button,{variant:"default",onClick:()=>setConfirm(null),children:"Cancel"}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Button,{color:"red",onClick:runDiscard,loading:discard.isPending,children:"Discard"})]})]})}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Modal,{opened:"redis"===confirm,onClose:()=>setConfirm(null),title:"Delete Redis lock",children:/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Stack,{children:[/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Text,{size:"sm",style:{wordBreak:"break-all"},children:["Delete the Redis running-lock for ",spreadsheet,worksheet?`:${worksheet}`:"",". The runner will be able to pick up the worksheet again on the next iteration."]}),/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Group,{justify:"flex-end",children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Button,{variant:"default",onClick:()=>setConfirm(null),children:"Cancel"}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Button,{color:"orange",onClick:runDeleteLock,loading:deleteLock.isPending,children:"Delete lock"})]})]})}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Modal,{opened:ownerModalOpen,onClose:()=>setOwnerModalOpen(false),title:`Set owner for task #${taskId}`,children:/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Stack,{children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.TextInput,{label:"Owner email",value:ownerInput,onChange:e=>setOwnerInput(e.currentTarget.value),placeholder:"bob@airporting.com"}),/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Group,{justify:"flex-end",children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Button,{variant:"default",onClick:()=>setOwnerModalOpen(false),children:"Cancel"}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Button,{onClick:runSetOwner,loading:setOwner.isPending,disabled:!ownerInput.trim(),children:"Save"})]})]})})]})}var BrandLogo=__webpack_require__(1239);const SERVICE_DOMAIN={gsheet:"google.com",excel:"microsoft.com"};const SERVICE_LABEL={gsheet:"Google Sheets",excel:"Excel"};function ServiceLogo({service,size=18}){const domain=SERVICE_DOMAIN[service];const label=SERVICE_LABEL[service]??service;if(!domain)return/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Badge,{size:"xs",variant:"light",color:"gray",title:service,children:service.slice(0,2).toUpperCase()});return/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Group,{gap:6,wrap:"nowrap",children:[/*#__PURE__*/(0,jsx_runtime.jsx)(BrandLogo.F,{domain:domain,alt:label,size:size}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Text,{size:"sm",children:label})]})}const STATE_COLORS={pending:"gray",running:"blue",stuck:"orange",errored:"red",done:"green"};const STATE_LABELS={pending:"En attente",running:"En cours",stuck:"Bloquée",errored:"En erreur",done:"Terminée"};function fmt(d){return d?new Date(d).toLocaleString("fr-FR"):"—"}function GsheetRowActions({item}){const openLogs=(0,jobLogsContext.c)();return/*#__PURE__*/(0,jsx_runtime.jsx)(RowActions,{taskId:item.id,currentOwner:item.owner,service:item.service,spreadsheet:item.spreadsheet,worksheet:item.worksheet,githubJob:item.github_job,traceId:item.trace_id,onShowLogs:openLogs})}async function runBulk(ids,fn){const results=await Promise.allSettled(ids.map(fn));const ok=results.filter(r=>"fulfilled"===r.status).length;return{ok,failed:results.length-ok}}function useGsheetConfig(){const unstick=useUnstickTask();const discard=useDiscardTask();const setOwner=useSetTaskOwner();const deleteLock=useDeleteRedisLock();return(0,index_js_.useMemo)(()=>({title:"Worksheets : état des lieux des copies sur tableurs",source:{useStock:({period})=>(0,gsheetStockQuery.s)({period:period??void 0}),useTasks:({service,owner,state,period},pagination)=>useGsheetTasks({service:service??void 0,owner:owner??void 0,state,period:period??void 0,skip:pagination.skip,take:pagination.take})},initialFilters:{service:null,owner:null,state:"pending",period:"today",search:""},kpis:[{key:"pending",label:"En attente",value:s=>s?.pending??0,filter:{state:"pending"}},{key:"running",label:"En cours",value:s=>s?.running??0,filter:{state:"running"}},{key:"stuck",label:"Bloquées",value:s=>s?.stuck??0,tone:s=>(s?.stuck??0)>0?"warn":"neutral",filter:{state:"stuck"}},{key:"errored",label:"En erreur",value:s=>s?.errored??0,tone:s=>(s?.errored??0)>0?"bad":"neutral",filter:{state:"errored"}},{key:"done_today",label:"Terminées",value:s=>s?.done_today??0,filter:{state:"done"}},{key:"oldest",label:"Plus ancienne en attente",value:s=>s?.oldest?`${s.oldest.ageHours}h`:"—"}],filters:[{kind:"select",key:"service",label:"Service",options:()=>["all","gsheet","excel"],width:240},{kind:"select",key:"owner",label:"Propriétaire",options:s=>["all",...(s?.byOwner??[]).map(e=>e.key)],width:240},{kind:"select",key:"state",label:"État",options:()=>["pending","running","stuck","errored","done","all"],clearable:false,width:140},{kind:"select",key:"period",label:"Période",options:()=>[{value:"today",label:"Aujourd'hui"},{value:"7d",label:"7 jours"},{value:"30d",label:"30 jours"},{value:"all",label:"Tout"}],clearable:false,width:130},{kind:"search",key:"search",label:"Recherche",placeholder:"id, owner, spreadsheet…",width:240}],columns:[{key:"service",label:"Service",render:t=>/*#__PURE__*/(0,jsx_runtime.jsx)(ServiceLogo,{service:t.service})},{key:"spreadsheet",label:"ID tableur",render:t=>/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Text,{size:"sm",style:{wordBreak:"break-all"},children:t.spreadsheet})},{key:"worksheet",label:"Onglet",render:t=>/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Text,{size:"sm",style:{wordBreak:"break-all"},children:t.worksheet??"—"})},{key:"company_display_name",label:"Entreprise",render:t=>/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Text,{size:"sm",children:t.company_display_name??"—"})},{key:"trigger_source",label:"Type",render:t=>/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Group,{gap:"xs",wrap:"nowrap",children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.ThemeIcon,{variant:"transparent",color:"gray",size:"sm",children:"manual"===t.trigger_source?/*#__PURE__*/(0,jsx_runtime.jsx)(tabler_icons_react_mjs_.IconUser,{size:16,stroke:1.5}):/*#__PURE__*/(0,jsx_runtime.jsx)(tabler_icons_react_mjs_.IconRobot,{size:16,stroke:1.5})}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Text,{size:"sm",children:"manual"===t.trigger_source?t.owner??"Manuel":"Planifié"})]})},{key:"state",label:"État",render:t=>{const badge=/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Badge,{color:STATE_COLORS[t.state],children:STATE_LABELS[t.state]});return t.error?/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Tooltip,{label:t.error,multiline:true,maw:420,withArrow:true,children:badge}):badge}},{key:"created",label:"Créée",render:t=>/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Text,{size:"sm",children:fmt(t.created)})},{key:"started",label:"Démarrée",render:t=>/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Text,{size:"sm",children:fmt(t.started)})},{key:"finished_at",label:"Terminée",render:t=>/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Text,{size:"sm",children:fmt(t.finished_at)})}],rowActions:[{key:"actions",render:item=>/*#__PURE__*/(0,jsx_runtime.jsx)(GsheetRowActions,{item:item})}],bulkActions:[{key:"unstick",label:"Débloquer",run:ids=>runBulk(ids,id=>unstick.mutateAsync(id))},{key:"set-owner",label:"Changer le propriétaire…",prompt:{label:"E-mail du propriétaire",placeholder:"bob@airporting.com"},run:(ids,owner)=>{if(!owner)return Promise.resolve({ok:0,failed:ids.length});return runBulk(ids,id=>setOwner.mutateAsync({id,owner}))}},{key:"delete-lock",label:"Supprimer le verrou Redis",color:"orange",confirm:{title:"Supprimer le verrou Redis pour {count} tâche(s)",body:/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Tooltip,{label:"fm-task-node-<id>",disabled:true,children:/*#__PURE__*/(0,jsx_runtime.jsxs)("span",{children:["Suppression du verrou Redis pour ","{count}"," tâche(s)."]})})},run:ids=>runBulk(ids,id=>deleteLock.mutateAsync(id))},{key:"discard",label:"Abandonner",color:"red",confirm:{title:"Abandonner {count} tâche(s)",body:"Les tâches seront marquées comme terminées/abandonnées."},run:ids=>runBulk(ids,id=>discard.mutateAsync(id))}],getRowId:t=>t.id,searchMatches:(t,q)=>String(t.id).includes(q)||(t.owner??"").toLowerCase().includes(q)||(t.spreadsheet??"").toLowerCase().includes(q)||(t.worksheet??"").toLowerCase().includes(q)||(t.service??"").toLowerCase().includes(q)||(t.company_display_name??"").toLowerCase().includes(q)}),[unstick,discard,setOwner,deleteLock])}function SpreadsheetApp(){const config=useGsheetConfig();return/*#__PURE__*/(0,jsx_runtime.jsx)(QueueDashboard.M,{config:config})}function Spreadsheet(props){return/*#__PURE__*/(0,jsx_runtime.jsx)(index_js_.StrictMode,{children:/*#__PURE__*/(0,jsx_runtime.jsx)(providers.b,{...props,children:/*#__PURE__*/(0,jsx_runtime.jsx)(SpreadsheetApp,{})})})}}}]);
@@ -0,0 +1,10 @@
1
+ /*! LICENSE: __federation_expose_synchro.a358d53b47.js.LICENSE.txt */
2
+ "use strict";(globalThis["chunk_tech_app "]||=[]).push([[403],{9698(__unused_rspack_module,exports){/**
3
+ * @license React
4
+ * react-jsx-runtime.production.js
5
+ *
6
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
7
+ *
8
+ * This source code is licensed under the MIT license found in the
9
+ * LICENSE file in the root directory of this source tree.
10
+ */var REACT_ELEMENT_TYPE=Symbol.for("react.transitional.element"),REACT_FRAGMENT_TYPE=Symbol.for("react.fragment");function jsxProd(type,config,maybeKey){var key=null;void 0!==maybeKey&&(key=""+maybeKey);void 0!==config.key&&(key=""+config.key);if("key"in config){maybeKey={};for(var propName in config)"key"!==propName&&(maybeKey[propName]=config[propName])}else maybeKey=config;config=maybeKey.ref;return{$$typeof:REACT_ELEMENT_TYPE,type:type,key:key,ref:void 0!==config?config:null,props:maybeKey}}exports.Fragment=REACT_FRAGMENT_TYPE;exports.jsx=jsxProd;exports.jsxs=jsxProd},4848(module,__unused_rspack_exports,__webpack_require__){module.exports=__webpack_require__(9698)},4394(__unused_rspack_module,__webpack_exports__,__webpack_require__){var react_jsx_runtime__rspack_import_0=__webpack_require__(4848);function IconGithub({color="currentColor",size=20,marker,...props}){return/*#__PURE__*/(0,react_jsx_runtime__rspack_import_0.jsx)("svg",{width:size,height:size,viewBox:"0 0 24 24",fill:color,xmlns:"http://www.w3.org/2000/svg",...props,children:/*#__PURE__*/(0,react_jsx_runtime__rspack_import_0.jsx)("path",{d:"M12 0.297C5.373 0.297 0 5.67 0 12.297c0 5.292 3.438 9.787 8.205 11.387.6.111.82-.261.82-.58\n 0-.287-.011-1.244-.016-2.255-3.338.726-4.042-1.609-4.042-1.609-.546-1.389-1.333-1.759-1.333-1.759-1.089-.745.083-.73.083-.73\n 1.205.085 1.84 1.236 1.84 1.236 1.07 1.834 2.807 1.304 3.492.997.107-.775.419-1.305.762-1.605-2.665-.304-5.466-1.332-5.466-5.931\n 0-1.311.469-2.381 1.236-3.221-.124-.303-.536-1.524.116-3.176 0 0 1.008-.322 3.301 1.23a11.51 11.51 0 0 1 3.004-.404\n c1.019.005 2.047.138 3.004.404 2.291-1.552 3.297-1.23 3.297-1.23.655 1.652.243 2.873.119 3.176.77.84\n 1.235 1.91 1.235 3.221 0 4.61-2.805 5.624-5.476 5.921.43.372.823 1.104.823 2.223\n 0 1.606-.015 2.896-.015 3.293 0 .321.216.697.825.578C20.565 22.08 24 17.585 24 12.297\n 24 5.67 18.627.297 12 .297z"})})}__webpack_require__.d(__webpack_exports__,{Z:()=>IconGithub})},1441(__unused_rspack_module,__webpack_exports__,__webpack_require__){__webpack_require__.r(__webpack_exports__);__webpack_require__.d(__webpack_exports__,{default:()=>Synchro});var jsx_runtime=__webpack_require__(4848);var index_js_=__webpack_require__(814);var providers=__webpack_require__(9528);var index_mjs_=__webpack_require__(4618);var esm_index_mjs_=__webpack_require__(2506);var modern_index_js_=__webpack_require__(3411);var useApi=__webpack_require__(4691);function useSynchroStatsQuery(){const api=(0,useApi.g)();const query=(0,modern_index_js_.useQuery)({queryKey:["tech","synchro","stats"],queryFn:async()=>await api.synchro.getRunStatsV1().then(x=>x.data),refetchInterval:6e4,refetchIntervalInBackground:false,refetchOnWindowFocus:true,refetchOnReconnect:true});return query}var tabler_icons_react_mjs_=__webpack_require__(2638);var notifications_esm_index_mjs_=__webpack_require__(7250);function useResetStatsMutation(){const api=(0,useApi.g)();const query=(0,modern_index_js_.useMutation)({mutationFn:async values=>await api.synchro.resetOwnerStatsV1(values).then(x=>x.data),onSuccess:()=>{notifications_esm_index_mjs_.notifications.show({title:"Cible remise à niveau",message:"C'est reparti comme en 40"})},onError:(error,variables,context)=>{console.error(error,variables,context);notifications_esm_index_mjs_.notifications.show({color:"red",title:"Erreur !",message:"Nous rencontrons un soucis technique. Veuillez réessayer plus tard."})}});return query}function useSynchroTasks({gas,dateRange,companies,jobs}){const api=(0,useApi.g)();return(0,modern_index_js_.useQuery)({queryKey:["tech","synchro","tasks","list",{gas,dateRange,companies,jobs}],queryFn:async()=>await api.synchro.getTasksV1({...gas&&{gas},...dateRange&&{dateStart:dateRange[0]??void 0,dateEnd:dateRange[1]??void 0,companyIds:companies?.map(x=>+x),jobNames:jobs}}).then(x=>x.data),refetchInterval:6e4,refetchIntervalInBackground:false,refetchOnWindowFocus:true,refetchOnReconnect:true})}var IconGithub=__webpack_require__(4394);var dist_index_js_=__webpack_require__(5456);var date_fns_index_js_=__webpack_require__(1917);function useCompaniesQuery(){const api=(0,useApi.g)();const query=(0,modern_index_js_.useQuery)({queryKey:["tech","companies"],queryFn:async()=>await api.getCompanies().then(x=>x.data)});return query}function useJobsDefaultQuery(){const api=(0,useApi.g)();const query=(0,modern_index_js_.useQuery)({queryKey:["tech","jobs","defaults"],queryFn:async()=>await api.synchro.getJobsDefaultsV1().then(x=>x.data)});return query}function SynchroApp(){const[gasOnly,setGasOnly]=(0,index_js_.useState)("nodejs");const[dateRange,setDateRange]=(0,index_js_.useState)([(0,date_fns_index_js_.formatISO)((0,date_fns_index_js_.startOfDay)(new Date)),(0,date_fns_index_js_.formatISO)((0,date_fns_index_js_.endOfDay)(new Date))]);const[companies,setCompanies]=(0,index_js_.useState)([]);const[jobs,setJobs]=(0,index_js_.useState)([]);const companiesResult=useCompaniesQuery();const companiesList=(companiesResult.data?.list??[]).map(company=>({value:company.id.toString(),label:company.display_name??company.id.toString()}));const jobsDefaultResult=useJobsDefaultQuery();const jobsDefaultList=(jobsDefaultResult.data?.list??[]).map(jobDefault=>jobDefault.task);const statsResult=useSynchroStatsQuery();const stats=statsResult.data;const tasksListResult=useSynchroTasks({gas:gasOnly,dateRange,companies,jobs});const tasksList=tasksListResult.data;const resetFn=useResetStatsMutation();function resolveStatus(element){if(!element.ready)return"en attente";if(element.need_gas)return element.gas_started?"GAS en cours":"GAS en attente";return element.finished?"fini":"en cours"}const rows=(tasksList?.tasks??[]).map(element=>/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Table.Tr,{children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Td,{children:element.id}),/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Table.Td,{children:[element.need_gas?/*#__PURE__*/(0,jsx_runtime.jsx)(tabler_icons_react_mjs_.IconOld,{title:"papi GAS"}):/*#__PURE__*/(0,jsx_runtime.jsx)(tabler_icons_react_mjs_.IconBolt,{title:"fougueux nodejs"})," ",element.job_name,/*#__PURE__*/(0,jsx_runtime.jsx)("br",{}),/*#__PURE__*/(0,jsx_runtime.jsx)("small",{children:element.job_name_fr})]}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Td,{children:(0,date_fns_index_js_.format)(element.created,"dd/MM/yyyy HH:mm:ss")}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Td,{children:element.startedAt?(0,date_fns_index_js_.format)(element.startedAt,"dd/MM/yyyy HH:mm:ss"):""}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Td,{children:resolveStatus(element)}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Td,{children:element.owner}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Td,{children:element.main_company?.display_name}),/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Table.Th,{children:[/*#__PURE__*/(0,jsx_runtime.jsx)(dist_index_js_.AirButton,{variant:"subtle",color:"gray",href:element.github_job,title:"Github runner",children:/*#__PURE__*/(0,jsx_runtime.jsx)(IconGithub.Z,{size:20})}),/*#__PURE__*/(0,jsx_runtime.jsx)(dist_index_js_.AirButton,{variant:"subtle",color:"gray",href:`https://airporting.grafana.net/d/beegyy3vsp8n4c/recipes?var-trace=${element.recipe_uuid}-${element.id}&orgId=1&from=now-7d&to=now&timezone=browser&showCategory=Logs&refresh=7d`,children:/*#__PURE__*/(0,jsx_runtime.jsx)(tabler_icons_react_mjs_.IconFileText,{title:"Logs",size:20})}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Button,{variant:"subtle",color:"gray",size:"compact-sm",onClick:()=>console.log(`coucou ${element.id}`),children:"log"}),element.finished?/*#__PURE__*/(0,jsx_runtime.jsx)(jsx_runtime.Fragment,{}):/*#__PURE__*/(0,jsx_runtime.jsx)(dist_index_js_.AirButton,{variant:"subtle",color:"gray",onClick:async()=>{console.log("stop",element.id)},children:/*#__PURE__*/(0,jsx_runtime.jsx)(tabler_icons_react_mjs_.IconHandStop,{title:"Stop",size:20})})]})]},element.id));return/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Container,{my:"md",children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Title,{order:2,my:"md",children:"Synchro"}),/*#__PURE__*/(0,jsx_runtime.jsx)("ul",{children:stats&&Object.entries(stats.currentJobsCounters).map(([key,value])=>/*#__PURE__*/(0,jsx_runtime.jsxs)("li",{children:[key,": ",value.db," db, ",value.redis," redis",/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Button,{variant:"subtle",color:value.db!=value.redis?"red":"green",onClick:async()=>{await resetFn.mutateAsync({owner:key,value:(value.db??0).toString()});await statsResult.refetch()},children:/*#__PURE__*/(0,jsx_runtime.jsx)(tabler_icons_react_mjs_.IconRefreshDot,{size:20})})]},key))}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Stack,{gap:"sm",my:"md",children:/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Group,{align:"flex-end",wrap:"wrap",children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Select,{label:"GAS et/ou nodejs",data:[{value:"all",label:"Toutes"},{value:"nodejs",label:"nodejs seulement"},{value:"gas",label:"GAS seulement"}],value:gasOnly,onChange:v=>setGasOnly(v??"nodejs"),w:140}),/*#__PURE__*/(0,jsx_runtime.jsx)(esm_index_mjs_.DatePickerInput,{leftSection:/*#__PURE__*/(0,jsx_runtime.jsx)(tabler_icons_react_mjs_.IconCalendar,{size:18}),type:"range",label:"Date de création",placeholder:"Sélectionner une plage",value:dateRange,onChange:setDateRange,clearable:true,allowSingleDateInRange:true,w:260}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.MultiSelect,{label:"Client",placeholder:"Sélectionner un ou plusieurs clients",data:companiesList,onChange:setCompanies,searchable:true,clearable:true}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.MultiSelect,{label:"Fonction",placeholder:"Sélectionner une ou plusieurs fonctions",data:jobsDefaultList,onChange:setJobs,searchable:true,clearable:true})]})}),/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Table,{stickyHeader:true,striped:true,highlightOnHover:true,withTableBorder:true,withColumnBorders:true,children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Thead,{children:/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Table.Tr,{children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Th,{children:"ID"}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Th,{children:"Fonction"}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Th,{children:"Demandée"}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Th,{children:"Démarée"}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Th,{children:"Statut"}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Th,{children:"Owner"}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Th,{children:"Client"}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Th,{children:"Liens"})]})}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Tbody,{children:rows})]})]})}function Synchro(props){return/*#__PURE__*/(0,jsx_runtime.jsx)(index_js_.StrictMode,{children:/*#__PURE__*/(0,jsx_runtime.jsx)(providers.b,{...props,children:/*#__PURE__*/(0,jsx_runtime.jsx)(SynchroApp,{})})})}}}]);
@@ -0,0 +1,9 @@
1
+ /**
2
+ * @license React
3
+ * react-jsx-runtime.production.js
4
+ *
5
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
6
+ *
7
+ * This source code is licensed under the MIT license found in the
8
+ * LICENSE file in the root directory of this source tree.
9
+ */
@@ -0,0 +1,10 @@
1
+ /*! LICENSE: __federation_expose_usage.61e16f490e.js.LICENSE.txt */
2
+ "use strict";(globalThis["chunk_tech_app "]||=[]).push([[3270],{9698(__unused_rspack_module,exports){/**
3
+ * @license React
4
+ * react-jsx-runtime.production.js
5
+ *
6
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
7
+ *
8
+ * This source code is licensed under the MIT license found in the
9
+ * LICENSE file in the root directory of this source tree.
10
+ */var REACT_ELEMENT_TYPE=Symbol.for("react.transitional.element"),REACT_FRAGMENT_TYPE=Symbol.for("react.fragment");function jsxProd(type,config,maybeKey){var key=null;void 0!==maybeKey&&(key=""+maybeKey);void 0!==config.key&&(key=""+config.key);if("key"in config){maybeKey={};for(var propName in config)"key"!==propName&&(maybeKey[propName]=config[propName])}else maybeKey=config;config=maybeKey.ref;return{$$typeof:REACT_ELEMENT_TYPE,type:type,key:key,ref:void 0!==config?config:null,props:maybeKey}}exports.Fragment=REACT_FRAGMENT_TYPE;exports.jsx=jsxProd;exports.jsxs=jsxProd},4848(module,__unused_rspack_exports,__webpack_require__){module.exports=__webpack_require__(9698)},7483(__unused_rspack_module,__webpack_exports__,__webpack_require__){var react_jsx_runtime__rspack_import_0=__webpack_require__(4848);var _mantine_core__rspack_import_1=__webpack_require__(4618);var _tabler_icons_react__rspack_import_2=__webpack_require__(2638);var react__rspack_import_3=__webpack_require__(814);function formatRelative(now,then){const seconds=Math.max(0,Math.floor((now-then)/1e3));if(seconds<5)return"à l’instant";if(seconds<60)return`il y a ${seconds}s`;const minutes=Math.floor(seconds/60);if(minutes<60)return`il y a ${minutes} min`;const hours=Math.floor(minutes/60);return`il y a ${hours} h`}function PageHeader({title,leading,badge,updatedAt,isFetching,isError,onRefresh,actions}){const[now,setNow]=(0,react__rspack_import_3.useState)(()=>Date.now());(0,react__rspack_import_3.useEffect)(()=>{if(!updatedAt)return;const id=window.setInterval(()=>setNow(Date.now()),1e3);return()=>window.clearInterval(id)},[updatedAt]);const relative=updatedAt?formatRelative(now,updatedAt):null;const color=isError?"orange":isFetching?"teal":"dimmed";return/*#__PURE__*/(0,react_jsx_runtime__rspack_import_0.jsxs)(_mantine_core__rspack_import_1.Group,{justify:"space-between",align:"center",mih:48,mb:"md",children:[/*#__PURE__*/(0,react_jsx_runtime__rspack_import_0.jsxs)(_mantine_core__rspack_import_1.Group,{gap:"sm",align:"center",children:[leading,/*#__PURE__*/(0,react_jsx_runtime__rspack_import_0.jsx)(_mantine_core__rspack_import_1.Title,{order:2,children:title}),badge]}),/*#__PURE__*/(0,react_jsx_runtime__rspack_import_0.jsxs)(_mantine_core__rspack_import_1.Group,{gap:"sm",align:"center",children:[relative&&/*#__PURE__*/(0,react_jsx_runtime__rspack_import_0.jsx)(_mantine_core__rspack_import_1.Text,{size:"xs",c:color,fw:isFetching?600:400,"data-testid":"page-header-freshness",children:isError?"échec maj":isFetching?"maj…":relative}),onRefresh&&/*#__PURE__*/(0,react_jsx_runtime__rspack_import_0.jsx)(_mantine_core__rspack_import_1.Tooltip,{label:"Rafraîchir",children:/*#__PURE__*/(0,react_jsx_runtime__rspack_import_0.jsx)(_mantine_core__rspack_import_1.ActionIcon,{variant:"default",size:"md",onClick:onRefresh,loading:isFetching,"aria-label":"Refresh",children:/*#__PURE__*/(0,react_jsx_runtime__rspack_import_0.jsx)(_tabler_icons_react__rspack_import_2.IconRefresh,{size:16})})}),actions]})]})}__webpack_require__.d(__webpack_exports__,{z:()=>PageHeader})},6066(__unused_rspack_module,__webpack_exports__,__webpack_require__){__webpack_require__.r(__webpack_exports__);__webpack_require__.d(__webpack_exports__,{default:()=>Usage});var jsx_runtime=__webpack_require__(4848);var index_js_=__webpack_require__(814);var providers=__webpack_require__(9528);var index_mjs_=__webpack_require__(4618);var tabler_icons_react_mjs_=__webpack_require__(2638);var modern_index_js_=__webpack_require__(3411);var useApi=__webpack_require__(4691);const STALE_MS=6e4;const DAY_REFETCH_MS=3e5;function chargeKey(view,trigger,at){return["tech","usage","charge",view,trigger,at??null]}function chargeParams(view,trigger,at){return{view,..."all"===trigger?{}:{trigger},...at?{at}:{}}}function useUsageCharge(view,trigger,at){const api=(0,useApi.g)();return(0,modern_index_js_.useQuery)({queryKey:chargeKey(view,trigger,at),queryFn:async()=>{const response=await api.http.request({path:"/v1/usage/charge",method:"GET",query:chargeParams(view,trigger,at),format:"json"});return response.data},placeholderData:modern_index_js_.keepPreviousData,staleTime:STALE_MS,refetchInterval:"day"===view?DAY_REFETCH_MS:false,refetchOnWindowFocus:false})}function useUsageChargePrefetch(){const api=(0,useApi.g)();const queryClient=(0,modern_index_js_.useQueryClient)();return(view,trigger,at)=>{queryClient.prefetchQuery({queryKey:chargeKey(view,trigger,at),queryFn:async()=>{const response=await api.http.request({path:"/v1/usage/charge",method:"GET",query:chargeParams(view,trigger,at),format:"json"});return response.data},staleTime:STALE_MS})}}var PageHeader=__webpack_require__(7483);const OPTIONS=[{value:"all",label:/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Text,{size:"sm",children:"Tout"})},{value:"auto",label:/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Group,{gap:6,wrap:"nowrap",children:[/*#__PURE__*/(0,jsx_runtime.jsx)(tabler_icons_react_mjs_.IconRobot,{size:16,stroke:1.5}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Text,{size:"sm",children:"Robots"})]})},{value:"human",label:/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Group,{gap:6,wrap:"nowrap",children:[/*#__PURE__*/(0,jsx_runtime.jsx)(tabler_icons_react_mjs_.IconUser,{size:16,stroke:1.5}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Text,{size:"sm",children:"Humains"})]})}];const HINT="Robots = planificateur et crons dédiés. Humains = run lancé depuis l’app ; c’est un plancher, les runs passés par l’ancienne API sont comptés comme planifiés.";function TriggerFilter(props){return/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Tooltip,{label:HINT,multiline:true,w:320,withArrow:true,position:"bottom",children:/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.SegmentedControl,{value:props.value,onChange:next=>props.onChange(next),data:OPTIONS,size:"xs"})})}const USAGE_COLORS={productive:"#3987e5",errored:"#d03b3b",noop:"#fab219"};const AXIS_INK="#898781";function formatHours(hours){if(hours>=100)return`${Math.round(hours)} h`;return`${hours.toFixed(1).replace(".",",")} h`}function formatCount(value){return new Intl.NumberFormat("fr-FR").format(value)}function formatCompactCount(value){return new Intl.NumberFormat("fr-FR",{notation:"compact",maximumFractionDigits:1}).format(value)}function servicePercent(under,measured){if(measured<=0)return 0;return Math.round(under/measured*100)}function wastePercent(kpis){if(kpis.computeHours<=0)return 0;return Math.round((kpis.erroredHours+kpis.noopHours)/kpis.computeHours*100)}function UsageKpiRow(props){const{kpis}=props;const tiles=[{key:"compute",label:"Compute",value:formatHours(kpis.computeHours),hint:`${formatCount(kpis.tasks)} t\xe2ches, dont ${formatCount(kpis.worksheetTasks)} worksheets`},{key:"companies",label:"Entreprises actives",value:formatCount(kpis.companies),hint:`${formatCount(kpis.distinctJobs)} connecteurs distincts`},{key:"waste",label:"Compute non productif",value:`${formatHours(kpis.erroredHours+kpis.noopHours)} \xb7 ${wastePercent(kpis)} %`,hint:`${formatHours(kpis.erroredHours)} en erreur (${formatCount(kpis.erroredTasks)} t\xe2ches), ${formatHours(kpis.noopHours)} sans r\xe9sultat`,accent:USAGE_COLORS.errored},{key:"concurrency",label:"Concurrence max",value:null===kpis.maxConcurrent?"—":`${formatCount(kpis.maxConcurrent)} t\xe2ches`,hint:null===kpis.maxConcurrent?"Non calculé sur 12 mois : trop coûteux à recouvrir":"Pic de tâches simultanées, durée bornée à 110 min"},{key:"service",label:"Démarrage < 15 min",value:kpis.waitMeasured>0?`${servicePercent(kpis.waitLe15,kpis.waitMeasured)} %`:"—",hint:kpis.waitMeasured>0?`${servicePercent(kpis.waitLe30,kpis.waitMeasured)} % sous 30 min, ${servicePercent(kpis.waitLe60,kpis.waitMeasured)} % sous 1 h, ${servicePercent(kpis.waitLe240,kpis.waitMeasured)} % sous 4 h — sur ${formatCount(kpis.waitMeasured)} t\xe2ches r\xe9ellement ex\xe9cut\xe9es`:"Aucune tâche exécutée sur la période"},{key:"abandoned",label:"Synchros perdues",value:formatCount(kpis.abandonedTasks),hint:0===kpis.abandonedTasks?"Aucune synchro abandonnée sur la période":`Abandonn\xe9es apr\xe8s 3 d\xe9blocages, sans jamais avoir tourn\xe9. ${formatHours(kpis.abandonedFabricatedHours)} de dur\xe9e fictive exclues du compute.`,accent:kpis.abandonedTasks>0?USAGE_COLORS.errored:void 0},{key:"rows",label:"Lignes synchronisées",value:formatCompactCount(kpis.rowsSynced),hint:"Somme des compteurs renvoyés par les jobs — proxy de tendance"}];return/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.SimpleGrid,{cols:{base:1,sm:2,md:3,lg:4,xl:7},spacing:"md",children:tiles.map(tile=>/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Paper,{withBorder:true,radius:"md",p:"md",children:[/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Group,{gap:6,align:"center",mb:6,children:[tile.accent?/*#__PURE__*/(0,jsx_runtime.jsx)("span",{"aria-hidden":true,style:{width:8,height:8,borderRadius:2,background:tile.accent,display:"inline-block"}}):null,/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Text,{size:"xs",c:"dimmed",tt:"uppercase",fw:700,children:tile.label})]}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Tooltip,{label:tile.hint,withArrow:true,multiline:true,w:260,children:/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Text,{fz:26,fw:600,lh:1.1,children:tile.value})}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Text,{size:"xs",c:"dimmed",mt:6,lineClamp:2,children:tile.hint})]},tile.key))})}var esm_index_mjs_=__webpack_require__(7194);const PARIS_TZ="Europe/Paris";const minuteFormatter=new Intl.DateTimeFormat("fr-FR",{timeZone:PARIS_TZ,hour:"2-digit",minute:"2-digit"});const weekDayFormatter=new Intl.DateTimeFormat("fr-FR",{timeZone:PARIS_TZ,weekday:"short",day:"numeric"});const monthFormatter=new Intl.DateTimeFormat("fr-FR",{timeZone:PARIS_TZ,month:"short",year:"2-digit"});const fullDayFormatter=new Intl.DateTimeFormat("fr-FR",{timeZone:PARIS_TZ,weekday:"long",day:"numeric",month:"long"});function bucketDate(t){if(7===t.length)return new Date(`${t}-15T12:00:00Z`);return new Date(`${t}T12:00:00Z`)}function formatMinuteTick(iso){return minuteFormatter.format(new Date(iso))}function formatBucketTick(t,view){if("year"===view)return monthFormatter.format(bucketDate(t));if("month"===view)return String(bucketDate(t).getUTCDate());return weekDayFormatter.format(bucketDate(t))}function formatBucketLong(t,view){if("year"===view)return monthFormatter.format(bucketDate(t));return fullDayFormatter.format(bucketDate(t))}function formatWindow(from,to,view){if("day"===view)return fullDayFormatter.format(new Date(from));if("year"===view){const start=monthFormatter.format(new Date(from));const end=monthFormatter.format(new Date(new Date(to).getTime()-1));return`${start} → ${end}`}const start=fullDayFormatter.format(new Date(from));const end=fullDayFormatter.format(new Date(new Date(to).getTime()-1));return`${start} → ${end}`}function ConcurrencyTooltip({payload}){const point=payload?.[0]?.payload;if(!point)return null;return/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Paper,{px:"md",py:"sm",withBorder:true,shadow:"md",radius:"md",children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Text,{fw:600,mb:4,children:formatMinuteTick(point.t)}),/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Text,{size:"sm",children:[point.concurrent," tâche",point.concurrent>1?"s":""," en cours"]}),/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Text,{size:"sm",c:"dimmed",children:[point.started," démarrage",point.started>1?"s":""]}),point.errored>0?/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Text,{size:"sm",c:USAGE_COLORS.errored,children:[point.errored," en erreur"]}):null]})}function ConcurrencyChart(props){const{data}=props;if(0===data.length)return/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Text,{c:"dimmed",size:"sm",children:"Aucune tâche sur la journée."});return/*#__PURE__*/(0,jsx_runtime.jsx)(esm_index_mjs_.AreaChart,{h:260,data:data,dataKey:"t",withDots:false,strokeWidth:2,curveType:"linear",gridAxis:"y",tickLine:"none",series:[{name:"concurrent",label:"Tâches en cours",color:USAGE_COLORS.productive}],xAxisProps:{tickFormatter:formatMinuteTick,minTickGap:48,stroke:AXIS_INK},yAxisProps:{allowDecimals:false,stroke:AXIS_INK,width:32},tooltipProps:{content:ConcurrencyTooltip},tooltipAnimationDuration:0})}const SURFACE="var(--mantine-color-body)";const SERIES=[{name:"productiveHours",label:"Productif",color:USAGE_COLORS.productive},{name:"noopHours",label:"Sans résultat",color:USAGE_COLORS.noop},{name:"erroredHours",label:"En erreur",color:USAGE_COLORS.errored}];const TOP_SERIES=SERIES[SERIES.length-1].name;function makeTooltip(view){return function({payload}){const bucket=payload?.[0]?.payload;if(!bucket)return null;return/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Paper,{px:"md",py:"sm",withBorder:true,shadow:"md",radius:"md",children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Text,{fw:600,mb:4,children:formatBucketLong(bucket.t,view)}),/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Text,{size:"sm",children:[formatHours(bucket.computeHours)," de compute"]}),/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Text,{size:"sm",c:USAGE_COLORS.errored,children:["dont ",formatHours(bucket.erroredHours)," en erreur (",formatCount(bucket.erroredTasks)," tâches)"]}),/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Text,{size:"sm",c:"dimmed",children:["dont ",formatHours(bucket.noopHours)," sans résultat"]}),/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Text,{size:"sm",c:"dimmed",mt:4,children:[formatCount(bucket.tasks)," tâches ·"," ",formatCount(bucket.worksheetTasks)," worksheets"]}),bucket.waitMaxMinutes?/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Text,{size:"sm",c:"dimmed",children:["attente max ",Math.round(bucket.waitMaxMinutes)," min"]}):null]})}}function ChargeStack(props){const{buckets,view}=props;if(0===buckets.length)return/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Text,{c:"dimmed",size:"sm",children:"Aucune tâche sur la période."});return/*#__PURE__*/(0,jsx_runtime.jsx)(esm_index_mjs_.BarChart,{h:300,data:buckets,dataKey:"t",type:"stacked",withLegend:true,legendProps:{verticalAlign:"top",height:32},gridAxis:"y",tickLine:"none",unit:" h",series:SERIES,barProps:item=>({stroke:SURFACE,strokeWidth:1.5,strokeOpacity:1,radius:item.name===TOP_SERIES?[4,4,0,0]:0}),xAxisProps:{tickFormatter:t=>formatBucketTick(t,view),stroke:AXIS_INK,minTickGap:4},yAxisProps:{stroke:AXIS_INK,width:44},tooltipProps:{content:makeTooltip(view)},tooltipAnimationDuration:0})}function AbandonedChart_makeTooltip(view){return function({payload}){const bucket=payload?.[0]?.payload;if(!bucket)return null;return/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Paper,{px:"md",py:"sm",withBorder:true,shadow:"md",radius:"md",children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Text,{fw:600,mb:4,children:formatBucketLong(bucket.t,view)}),/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Text,{size:"sm",c:USAGE_COLORS.errored,children:[formatCount(bucket.abandonedTasks)," synchro",bucket.abandonedTasks>1?"s":""," perdue",bucket.abandonedTasks>1?"s":""]}),/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Text,{size:"sm",c:"dimmed",children:["sur ",formatCount(bucket.tasks)," tâches créées"]})]})}}function AbandonedChart(props){const{buckets,view}=props;return/*#__PURE__*/(0,jsx_runtime.jsx)(esm_index_mjs_.BarChart,{h:180,data:buckets,dataKey:"t",gridAxis:"y",tickLine:"none",series:[{name:"abandonedTasks",label:"Synchros perdues",color:USAGE_COLORS.errored}],barProps:{radius:[4,4,0,0]},xAxisProps:{tickFormatter:t=>formatBucketTick(t,view),stroke:AXIS_INK,minTickGap:4},yAxisProps:{stroke:AXIS_INK,width:44,allowDecimals:false},tooltipProps:{content:AbandonedChart_makeTooltip(view)},tooltipAnimationDuration:0})}function toPoints(buckets){return buckets.map(b=>({t:b.t,service:servicePercent(b.waitLe15,b.waitMeasured),under30:servicePercent(b.waitLe30,b.waitMeasured),under60:servicePercent(b.waitLe60,b.waitMeasured),measured:b.waitMeasured}))}function ServiceLevelChart_makeTooltip(view){return function({payload}){const point=payload?.[0]?.payload;if(!point)return null;return/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Paper,{px:"md",py:"sm",withBorder:true,shadow:"md",radius:"md",children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Text,{fw:600,mb:4,children:formatBucketLong(point.t,view)}),/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Text,{size:"sm",c:USAGE_COLORS.productive,children:[point.service," % démarrées sous ",15," min"]}),/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Text,{size:"sm",c:"dimmed",children:[point.under30," % sous 30 min · ",point.under60," % sous 1 h"]}),/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Text,{size:"sm",c:"dimmed",mt:4,children:["sur ",formatCount(point.measured)," tâches exécutées"]})]})}}function ServiceLevelChart(props){const{buckets,view}=props;return/*#__PURE__*/(0,jsx_runtime.jsx)(esm_index_mjs_.LineChart,{h:180,data:toPoints(buckets),dataKey:"t",gridAxis:"y",tickLine:"none",unit:" %",withDots:buckets.length<=40,series:[{name:"service",label:"Démarrées sous 15 min",color:USAGE_COLORS.productive}],xAxisProps:{tickFormatter:t=>formatBucketTick(t,view),stroke:AXIS_INK,minTickGap:4},yAxisProps:{stroke:AXIS_INK,width:48,domain:[0,100],allowDecimals:false},tooltipProps:{content:ServiceLevelChart_makeTooltip(view)},tooltipAnimationDuration:0})}const TRACTION_SERIES=[{name:"companies",label:"Entreprises actives",color:"#3987e5"},{name:"distinctJobs",label:"Connecteurs distincts",color:"#d95926"}];function TractionTooltip({payload}){const bucket=payload?.[0]?.payload;if(!bucket)return null;return/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Paper,{px:"md",py:"sm",withBorder:true,shadow:"md",radius:"md",children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Text,{fw:600,mb:4,children:formatBucketLong(bucket.t,"year")}),/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Text,{size:"sm",children:[bucket.companies??0," entreprises actives"]}),/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Text,{size:"sm",children:[bucket.distinctJobs??0," connecteurs distincts"]})]})}function TractionChart(props){const{buckets}=props;if(0===buckets.length)return/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Text,{c:"dimmed",size:"sm",children:"Pas d'historique sur la période."});return/*#__PURE__*/(0,jsx_runtime.jsx)(esm_index_mjs_.LineChart,{h:240,data:buckets,dataKey:"t",withLegend:true,legendProps:{verticalAlign:"top",height:32},strokeWidth:2,dotProps:{r:4},activeDotProps:{r:6},gridAxis:"y",tickLine:"none",series:TRACTION_SERIES,xAxisProps:{tickFormatter:t=>formatBucketTick(t,"year"),stroke:AXIS_INK},yAxisProps:{allowDecimals:false,stroke:AXIS_INK,width:40},tooltipProps:{content:TractionTooltip},tooltipAnimationDuration:0})}function ShareBar(props){const{hours,erroredHours,max}=props;if(max<=0)return null;const total=hours/max*100;const errored=Math.min(erroredHours,hours)/max*100;return/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Progress.Root,{size:"md",w:140,children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Progress.Section,{value:Math.max(total-errored,0),color:USAGE_COLORS.productive}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Progress.Section,{value:errored,color:USAGE_COLORS.errored})]})}function LostCell(props){if(0===props.count)return/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Td,{ta:"right",c:"dimmed",children:"—"});return/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Td,{ta:"right",style:{fontVariantNumeric:"tabular-nums",color:USAGE_COLORS.errored,fontWeight:600},children:formatCount(props.count)})}function TopCompaniesTable(props){const{rows,totalHours}=props;const max=rows.length>0?rows[0].computeHours:0;return/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Table,{highlightOnHover:true,striped:false,verticalSpacing:"xs",children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Thead,{children:/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Table.Tr,{children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Th,{w:32,children:"#"}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Th,{children:"Entreprise"}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Th,{w:150,children:"Part"}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Th,{w:90,ta:"right",children:"Compute"}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Th,{w:70,ta:"right",children:"% total"}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Th,{w:100,ta:"right",children:"Tâches"}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Th,{w:80,ta:"right",children:"Perdues"})]})}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Tbody,{children:rows.map((row,index)=>/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Table.Tr,{children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Td,{c:"dimmed",children:index+1}),/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Table.Td,{children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Text,{size:"sm",fw:500,children:row.displayName??row.slug??`#${row.companyId}`}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Text,{size:"xs",c:"dimmed",children:row.slug??`company ${row.companyId}`})]}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Td,{children:/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Tooltip,{withArrow:true,label:`${formatHours(row.erroredHours)} en erreur sur ${formatHours(row.computeHours)}`,children:/*#__PURE__*/(0,jsx_runtime.jsx)("div",{children:/*#__PURE__*/(0,jsx_runtime.jsx)(ShareBar,{hours:row.computeHours,erroredHours:row.erroredHours,max:max})})})}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Td,{ta:"right",style:{fontVariantNumeric:"tabular-nums"},children:formatHours(row.computeHours)}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Td,{ta:"right",c:"dimmed",style:{fontVariantNumeric:"tabular-nums"},children:totalHours>0?`${Math.round(row.computeHours/totalHours*100)} %`:"—"}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Td,{ta:"right",c:"dimmed",style:{fontVariantNumeric:"tabular-nums"},children:formatCount(row.tasks)}),/*#__PURE__*/(0,jsx_runtime.jsx)(LostCell,{count:row.abandonedTasks})]},row.companyId))})]})}function TopJobsTable(props){const{rows,totalHours}=props;const max=rows.length>0?rows[0].computeHours:0;return/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Table,{highlightOnHover:true,verticalSpacing:"xs",children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Thead,{children:/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Table.Tr,{children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Th,{w:32,children:"#"}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Th,{children:"Connecteur"}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Th,{w:150,children:"Part"}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Th,{w:90,ta:"right",children:"Compute"}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Th,{w:70,ta:"right",children:"% total"}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Th,{w:110,ta:"right",children:"h / entreprise"}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Th,{w:80,ta:"right",children:"Perdues"})]})}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Tbody,{children:rows.map((row,index)=>/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Table.Tr,{children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Td,{c:"dimmed",children:index+1}),/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Table.Td,{children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Text,{size:"sm",fw:500,children:row.jobName}),/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Text,{size:"xs",c:"dimmed",children:[formatCount(row.companies)," entreprise",row.companies>1?"s":""," · ",formatCount(row.tasks)," tâches"]})]}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Td,{children:/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Tooltip,{withArrow:true,label:`${formatHours(row.erroredHours)} en erreur sur ${formatHours(row.computeHours)}`,children:/*#__PURE__*/(0,jsx_runtime.jsx)("div",{children:/*#__PURE__*/(0,jsx_runtime.jsx)(ShareBar,{hours:row.computeHours,erroredHours:row.erroredHours,max:max})})})}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Td,{ta:"right",style:{fontVariantNumeric:"tabular-nums"},children:formatHours(row.computeHours)}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Td,{ta:"right",c:"dimmed",style:{fontVariantNumeric:"tabular-nums"},children:totalHours>0?`${Math.round(row.computeHours/totalHours*100)} %`:"—"}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Table.Td,{ta:"right",c:"dimmed",style:{fontVariantNumeric:"tabular-nums"},children:row.companies>0?formatHours(row.computeHours/row.companies):"—"}),/*#__PURE__*/(0,jsx_runtime.jsx)(LostCell,{count:row.abandonedTasks})]},row.jobName))})]})}var date_fns_index_js_=__webpack_require__(1917);function shiftPeriod(view,at,direction){if("week"===view)return(0,date_fns_index_js_.addWeeks)(at,direction);if("month"===view)return(0,date_fns_index_js_.addMonths)(at,direction);if("year"===view)return(0,date_fns_index_js_.addMonths)(at,12*direction);return(0,date_fns_index_js_.addDays)(at,direction)}function canGoForward(view,at,now){return shiftPeriod(view,at,1).getTime()<=now.getTime()}const RESET_LABEL={day:"Aujourd'hui",week:"Cette semaine",month:"Ce mois",year:"12 derniers mois"};const VIEW_OPTIONS=[{value:"day",label:"Jour"},{value:"week",label:"Semaine"},{value:"month",label:"Mois"},{value:"year",label:"12 mois"}];const CHART_TITLES={day:"Tâches simultanées, minute par minute",week:"Compute par jour (lundi → dimanche)",month:"Compute par jour du mois",year:"Compute par mois"};function SectionTitle(props){return/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Group,{justify:"space-between",align:"baseline",mb:"xs",children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Text,{size:"sm",fw:600,children:props.children}),props.hint?/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Text,{size:"xs",c:"dimmed",children:props.hint}):null]})}function UsageApp(){const[view,setView]=(0,index_js_.useState)("day");const[at,setAt]=(0,index_js_.useState)(null);const[trigger,setTrigger]=(0,index_js_.useState)("all");const charge=useUsageCharge(view,trigger,at?at.toISOString():void 0);const prefetch=useUsageChargePrefetch();const data=charge.data;const reference=at??new Date;const forwardDisabled=null===at||!canGoForward(view,reference,new Date);(0,index_js_.useEffect)(()=>{if(charge.isFetching)return;const previous=shiftPeriod(view,at??new Date,-1);prefetch(view,trigger,previous.toISOString())},[view,at,trigger,charge.isFetching]);const goto=direction=>{const next=shiftPeriod(view,reference,direction);setAt(next)};const changeView=next=>{setView(next);setAt(null)};return/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Container,{fluid:true,my:"md",children:/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Stack,{gap:"lg",children:[/*#__PURE__*/(0,jsx_runtime.jsx)(PageHeader.z,{title:"Usage & charge",updatedAt:charge.dataUpdatedAt,isFetching:charge.isFetching,isError:charge.isError,onRefresh:()=>charge.refetch()}),/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Group,{justify:"space-between",align:"center",wrap:"wrap",children:[/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Group,{gap:"md",align:"center",wrap:"wrap",children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.SegmentedControl,{value:view,onChange:value=>changeView(value),data:VIEW_OPTIONS}),/*#__PURE__*/(0,jsx_runtime.jsx)(TriggerFilter,{value:trigger,onChange:setTrigger})]}),/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Group,{gap:"xs",align:"center",children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.ActionIcon,{variant:"default",size:"lg","aria-label":"Période précédente",onClick:()=>goto(-1),children:/*#__PURE__*/(0,jsx_runtime.jsx)(tabler_icons_react_mjs_.IconChevronLeft,{size:18})}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Text,{size:"sm",c:"dimmed",ta:"center",miw:280,children:data?`${formatWindow(data.from,data.to,data.view)} \xb7 heure de Paris`:"…"}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.ActionIcon,{variant:"default",size:"lg","aria-label":"Période suivante",disabled:forwardDisabled,onClick:()=>goto(1),children:/*#__PURE__*/(0,jsx_runtime.jsx)(tabler_icons_react_mjs_.IconChevronRight,{size:18})}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Button,{variant:"subtle",color:"gray",size:"xs",disabled:null===at,onClick:()=>setAt(null),children:RESET_LABEL[view]})]})]}),charge.isError?/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Alert,{color:"red",title:"Impossible de charger la charge",children:String(charge.error)}):null,data?/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Stack,{gap:"lg",style:{opacity:charge.isPlaceholderData?.45:1,transition:"opacity 150ms ease",pointerEvents:charge.isPlaceholderData?"none":void 0},children:[/*#__PURE__*/(0,jsx_runtime.jsx)(UsageKpiRow,{kpis:data.kpis}),/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Paper,{withBorder:true,radius:"md",p:"md",children:[/*#__PURE__*/(0,jsx_runtime.jsx)(SectionTitle,{hint:"day"===view?"durée bornée à 110 min — au-delà, une tâche est perdue, pas en cours":"heures de compute, décomposées par issue",children:CHART_TITLES[view]}),"day"===view?/*#__PURE__*/(0,jsx_runtime.jsx)(ConcurrencyChart,{data:data.concurrency}):/*#__PURE__*/(0,jsx_runtime.jsx)(ChargeStack,{buckets:data.buckets,view:data.view})]}),"year"===view?/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Paper,{withBorder:true,radius:"md",p:"md",children:[/*#__PURE__*/(0,jsx_runtime.jsx)(SectionTitle,{hint:"deux dénombrements, un seul axe",children:"Traction — entreprises actives et connecteurs"}),/*#__PURE__*/(0,jsx_runtime.jsx)(TractionChart,{buckets:data.buckets})]}):null,"day"===view&&data.buckets.length>0?/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Paper,{withBorder:true,radius:"md",p:"md",children:[/*#__PURE__*/(0,jsx_runtime.jsx)(SectionTitle,{hint:"décomposition du compute de la journée",children:"Compute de la journée"}),/*#__PURE__*/(0,jsx_runtime.jsx)(ChargeStack,{buckets:data.buckets,view:data.view})]}):null,data.buckets.length>1?/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Paper,{withBorder:true,radius:"md",p:"md",children:[/*#__PURE__*/(0,jsx_runtime.jsx)(SectionTitle,{hint:"création → exécution, sur les tâches réellement exécutées",children:"Délai de mise en route"}),/*#__PURE__*/(0,jsx_runtime.jsx)(ServiceLevelChart,{buckets:data.buckets,view:data.view})]}):null,data.kpis.abandonedTasks>0?/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Paper,{withBorder:true,radius:"md",p:"md",children:[/*#__PURE__*/(0,jsx_runtime.jsx)(SectionTitle,{hint:"abandonnées après 3 déblocages, sans jamais avoir tourné",children:"Synchros perdues"}),/*#__PURE__*/(0,jsx_runtime.jsx)(AbandonedChart,{buckets:data.buckets,view:data.view})]}):null,/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Divider,{}),/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Grid,{children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Grid.Col,{span:{base:12,lg:6},children:/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Paper,{withBorder:true,radius:"md",p:"md",h:"100%",children:[/*#__PURE__*/(0,jsx_runtime.jsx)(SectionTitle,{hint:"classement, pas de moyenne",children:"Top consommateurs"}),/*#__PURE__*/(0,jsx_runtime.jsx)(TopCompaniesTable,{rows:data.topCompanies,totalHours:data.kpis.computeHours})]})}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Grid.Col,{span:{base:12,lg:6},children:/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Paper,{withBorder:true,radius:"md",p:"md",h:"100%",children:[/*#__PURE__*/(0,jsx_runtime.jsx)(SectionTitle,{hint:"brique de tarification du free",children:"Coût par connecteur"}),/*#__PURE__*/(0,jsx_runtime.jsx)(TopJobsTable,{rows:data.topJobs,totalHours:data.kpis.computeHours})]})})]})]}):/*#__PURE__*/(0,jsx_runtime.jsxs)(index_mjs_.Stack,{gap:"md",children:[/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Skeleton,{height:96}),/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Skeleton,{height:300})]})]})})}function Usage(props){return/*#__PURE__*/(0,jsx_runtime.jsx)(index_js_.StrictMode,{children:/*#__PURE__*/(0,jsx_runtime.jsx)(providers.b,{...props,children:/*#__PURE__*/(0,jsx_runtime.jsx)(UsageApp,{})})})}}}]);
@@ -0,0 +1,9 @@
1
+ /**
2
+ * @license React
3
+ * react-jsx-runtime.production.js
4
+ *
5
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
6
+ *
7
+ * This source code is licensed under the MIT license found in the
8
+ * LICENSE file in the root directory of this source tree.
9
+ */
@@ -0,0 +1,10 @@
1
+ /*! LICENSE: __federation_expose_wise.b31a4dcd88.js.LICENSE.txt */
2
+ "use strict";(globalThis["chunk_tech_app "]||=[]).push([[7193],{9698(__unused_rspack_module,exports){/**
3
+ * @license React
4
+ * react-jsx-runtime.production.js
5
+ *
6
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
7
+ *
8
+ * This source code is licensed under the MIT license found in the
9
+ * LICENSE file in the root directory of this source tree.
10
+ */var REACT_ELEMENT_TYPE=Symbol.for("react.transitional.element"),REACT_FRAGMENT_TYPE=Symbol.for("react.fragment");function jsxProd(type,config,maybeKey){var key=null;void 0!==maybeKey&&(key=""+maybeKey);void 0!==config.key&&(key=""+config.key);if("key"in config){maybeKey={};for(var propName in config)"key"!==propName&&(maybeKey[propName]=config[propName])}else maybeKey=config;config=maybeKey.ref;return{$$typeof:REACT_ELEMENT_TYPE,type:type,key:key,ref:void 0!==config?config:null,props:maybeKey}}exports.Fragment=REACT_FRAGMENT_TYPE;exports.jsx=jsxProd;exports.jsxs=jsxProd},4848(module,__unused_rspack_exports,__webpack_require__){module.exports=__webpack_require__(9698)},7785(__unused_rspack_module,__webpack_exports__,__webpack_require__){var react__rspack_import_0=__webpack_require__(814);const AppConfigCtx=(0,react__rspack_import_0.createContext)(null);const AppConfigProvider=AppConfigCtx.Provider;function useAppConfig(){const config=(0,react__rspack_import_0.useContext)(AppConfigCtx);if(!config)throw new Error("Called `useAppConfig` outside a `<AppConfigProvider />`");return config}__webpack_require__.d(__webpack_exports__,{r:()=>useAppConfig},{X:AppConfigProvider})},9528(__unused_rspack_module,__webpack_exports__,__webpack_require__){var react_jsx_runtime__rspack_import_0=__webpack_require__(4848);var _airporting_app_front__rspack_import_1=__webpack_require__(5456);var _mantine_core__rspack_import_2=__webpack_require__(4618);var _mantine_modals__rspack_import_3=__webpack_require__(3536);var _mantine_notifications__rspack_import_4=__webpack_require__(7250);var _tanstack_react_query__rspack_import_5=__webpack_require__(3411);var radash__rspack_import_6=__webpack_require__(5551);var _hooks_useAppConfig__rspack_import_7=__webpack_require__(7785);const theme=(0,_mantine_core__rspack_import_2.createTheme)((0,radash__rspack_import_6.assign)(_airporting_app_front__rspack_import_1.theme,{components:{}}));const cssVarResolver=x=>(0,radash__rspack_import_6.assign)(_airporting_app_front__rspack_import_1.cssVarResolver(x),{dark:{},light:{},variables:{}});function Providers(props){const{children,config,mantine,tanstack}=props;return/*#__PURE__*/(0,react_jsx_runtime__rspack_import_0.jsx)(_hooks_useAppConfig__rspack_import_7.X,{value:config,children:/*#__PURE__*/(0,react_jsx_runtime__rspack_import_0.jsx)(_tanstack_react_query__rspack_import_5.QueryClientProvider,{client:tanstack?.queryClient??new _tanstack_react_query__rspack_import_5.QueryClient,children:/*#__PURE__*/(0,react_jsx_runtime__rspack_import_0.jsx)(_mantine_core__rspack_import_2.MantineProvider,{theme:theme,cssVariablesResolver:cssVarResolver,defaultColorScheme:mantine?.defaultColorScheme,forceColorScheme:mantine?.forceColorScheme,children:/*#__PURE__*/(0,react_jsx_runtime__rspack_import_0.jsxs)(_mantine_modals__rspack_import_3.ModalsProvider,{children:[/*#__PURE__*/(0,react_jsx_runtime__rspack_import_0.jsx)(_mantine_notifications__rspack_import_4.Notifications,{}),children]})})})})}__webpack_require__.d(__webpack_exports__,{b:()=>Providers})},8635(__unused_rspack_module,__webpack_exports__,__webpack_require__){__webpack_require__.r(__webpack_exports__);__webpack_require__.d(__webpack_exports__,{default:()=>Wise});var jsx_runtime=__webpack_require__(4848);var index_js_=__webpack_require__(814);var providers=__webpack_require__(9528);var index_mjs_=__webpack_require__(4618);function WiseApp(){return/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Container,{my:"md",children:/*#__PURE__*/(0,jsx_runtime.jsx)(index_mjs_.Title,{order:2,my:"md",children:"Wise - soon"})})}function Wise(props){return/*#__PURE__*/(0,jsx_runtime.jsx)(index_js_.StrictMode,{children:/*#__PURE__*/(0,jsx_runtime.jsx)(providers.b,{...props,children:/*#__PURE__*/(0,jsx_runtime.jsx)(WiseApp,{})})})}}}]);
@@ -0,0 +1,9 @@
1
+ /**
2
+ * @license React
3
+ * react-jsx-runtime.production.js
4
+ *
5
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
6
+ *
7
+ * This source code is licensed under the MIT license found in the
8
+ * LICENSE file in the root directory of this source tree.
9
+ */
@@ -0,0 +1,2 @@
1
+
2
+