@oliasoft-open-source/react-ui-library 4.7.2-beta-7 → 4.7.2-beta-8

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 (133) hide show
  1. package/dist/assets/{index-zmbFJmOv.js → index-7PLAdoQ9.js} +183 -702
  2. package/dist/assets/{index-gESxyZjr.css → index-Oe0PlEED.css} +0 -35
  3. package/dist/index.d.ts +1 -1
  4. package/dist/index.html +1 -1
  5. package/dist/index.js +3 -3
  6. package/dist/index.js.map +1 -1
  7. package/dist/storybook/assets/Color-KGDBMAHA-DlviuZHV.js +1 -0
  8. package/dist/storybook/assets/DocsRenderer-PKQXORMH--T8weHN2.js +1 -0
  9. package/dist/storybook/assets/{accordion-BiuI_LCA.js → accordion-6ouB0WTt.js} +1 -1
  10. package/dist/storybook/assets/{accordion.stories-sb-Y7MMb.js → accordion.stories-DlFZNmdv.js} +2 -2
  11. package/dist/storybook/assets/{actions-4w-EOz3m.js → actions-Cu_0szZ4.js} +1 -1
  12. package/dist/storybook/assets/{actions.stories-CtocfSW4.js → actions.stories-SCPuAp0T.js} +1 -1
  13. package/dist/storybook/assets/{afe.stories--E_j7kET.js → afe.stories-G3SzS3sg.js} +2 -2
  14. package/dist/storybook/assets/{badge.stories-CKnNQLZ5.js → badge.stories-DGYA6_1I.js} +1 -1
  15. package/dist/storybook/assets/{blowout.stories-AxiXaQQ-.js → blowout.stories-P0LHuXSY.js} +1 -1
  16. package/dist/storybook/assets/{button-CdEIDAx8.js → button-_0DiND6h.js} +1 -1
  17. package/dist/storybook/assets/{button-group-BIUVa0X9.js → button-group-BYiHMljF.js} +1 -1
  18. package/dist/storybook/assets/{button-group.stories-B0Gb9kNs.js → button-group.stories-Bz6NHaeB.js} +1 -1
  19. package/dist/storybook/assets/{button.stories-CHt71NKu.js → button.stories-vVBGddVf.js} +2 -2
  20. package/dist/storybook/assets/{buttons-and-links-BHLN948A.js → buttons-and-links-qaJ-_9Ao.js} +2 -2
  21. package/dist/storybook/assets/{card.stories-Cddrprok.js → card.stories-DIlqxO94.js} +1 -1
  22. package/dist/storybook/assets/{casing-loads.stories-EZlP6XsN.js → casing-loads.stories-0T--WlaD.js} +2 -2
  23. package/dist/storybook/assets/{cell.stories-D9KrTmCA.js → cell.stories-C5Tkxyfr.js} +2 -2
  24. package/dist/storybook/assets/{check-box-2fHPdAZG.js → check-box-DkdQxC5c.js} +1 -1
  25. package/dist/storybook/assets/{check-box.stories-Do-GOmLf.js → check-box.stories-D8C12IQo.js} +1 -1
  26. package/dist/storybook/assets/{chunk-HLWAVYOI-C3Nc_Hl_.js → chunk-HLWAVYOI-DBaaUqte.js} +1 -1
  27. package/dist/storybook/assets/color-D8lo1sI7.js +25 -0
  28. package/dist/storybook/assets/{column.stories-rKyxUTAG.js → column.stories-C1Sxwh4f.js} +1 -1
  29. package/dist/storybook/assets/{dialog-B-R6eAnf.js → dialog-CAWCUmp3.js} +1 -1
  30. package/dist/storybook/assets/{drawer-BOl7GxGI.js → drawer-vbDFqa4U.js} +1 -1
  31. package/dist/storybook/assets/{drawer.stories-qH2nYW2a.js → drawer.stories-CmbGsKmS.js} +4 -4
  32. package/dist/storybook/assets/{empty.stories-BKEXzh9o.js → empty.stories-iHPKKy4z.js} +1 -1
  33. package/dist/storybook/assets/extends-CF3RwP-h.js +1 -0
  34. package/dist/storybook/assets/{field-nInV3MuR.js → field-DwLk_uWj.js} +1 -1
  35. package/dist/storybook/assets/{field.stories-eRSYmEtA.js → field.stories-s-0LQVbp.js} +1 -1
  36. package/dist/storybook/assets/{file-button.stories-CH6kxEKM.js → file-button.stories-C90kcfbw.js} +1 -1
  37. package/dist/storybook/assets/{file-input-Amcc9o5I.js → file-input-C_2w1dKj.js} +1 -1
  38. package/dist/storybook/assets/{file-input.stories-aiTQE5UN.js → file-input.stories-BEsZox6U.js} +1 -1
  39. package/dist/storybook/assets/{flex.stories-CT6o2gii.js → flex.stories-D-QN0gkk.js} +1 -1
  40. package/dist/storybook/assets/footer.stories-U_zMDmxF.js +3 -0
  41. package/dist/storybook/assets/form.stories-1L75MGpX.js +49 -0
  42. package/dist/storybook/assets/formation.stories-YHpXrXvC.js +74 -0
  43. package/dist/storybook/assets/{heading-EzI5s4VN.js → heading-DkSFysAb.js} +1 -1
  44. package/dist/storybook/assets/{heading.stories-D5x1-mKs.js → heading.stories-Dtq7LNlB.js} +1 -1
  45. package/dist/storybook/assets/{help-icon-CfV3_Ais.js → help-icon-LfPZiYla.js} +1 -1
  46. package/dist/storybook/assets/{help-icon.stories-D4KS1wlT.js → help-icon.stories-Dh2ylnGq.js} +1 -1
  47. package/dist/storybook/assets/icon-BP4BO6-k.js +8 -0
  48. package/dist/storybook/assets/{icon.stories-C1hZXIMX.js → icon.stories-B-tKaIKA.js} +1 -1
  49. package/dist/storybook/assets/iframe-DTq8HQN_.js +2 -0
  50. package/dist/storybook/assets/{index-BwF95xBr.js → index-BffEsnEA.js} +8 -8
  51. package/dist/storybook/assets/index-u5yugdxL.js +1 -0
  52. package/dist/storybook/assets/{index.es-DazXb-ul.js → index.es-D2piFfFj.js} +4 -4
  53. package/dist/storybook/assets/inheritsLoose-DR8r8Ogv.js +1 -0
  54. package/dist/storybook/assets/{input-group.stories-hHCmTbtu.js → input-group.stories-BcoORZ9x.js} +2 -2
  55. package/dist/storybook/assets/{input-validation-CvKyplhN.js → input-validation-DfC4m7rW.js} +2 -2
  56. package/dist/storybook/assets/{inputs-DhUf5Lzj.js → inputs-BiftI9DC.js} +4 -4
  57. package/dist/storybook/assets/{label-Cz6TT90s.js → label-tWjEmTQJ.js} +1 -1
  58. package/dist/storybook/assets/{label.stories-BzSzxxM-.js → label.stories-BTA8N7tD.js} +1 -1
  59. package/dist/storybook/assets/layout-forms-BAIz7zgE.js +16 -0
  60. package/dist/storybook/assets/{layout-general-CnLft8nK.js → layout-general-CWhovZnB.js} +2 -2
  61. package/dist/storybook/assets/{list-BtA0jYMp.js → list-BpVed6Pw.js} +1 -1
  62. package/dist/storybook/assets/{list.stories-CmJsmJZJ.js → list.stories-CiT9J_FH.js} +2 -2
  63. package/dist/storybook/assets/{list.stories-data-C_w1DX5i.js → list.stories-data-CnVYk3eo.js} +1 -1
  64. package/dist/storybook/assets/{loader.stories-CA2m3EFj.js → loader.stories-BKBFctQ1.js} +1 -1
  65. package/dist/storybook/assets/{menu.stories-Bc2kf356.js → menu.stories-Bp8L83xx.js} +2 -2
  66. package/dist/storybook/assets/{message-ZenLdkrf.js → message-ttrR1AaP.js} +1 -1
  67. package/dist/storybook/assets/{message.stories-CXOrrAOR.js → message.stories-C8YRT7nL.js} +1 -1
  68. package/dist/storybook/assets/{meta-content-BdypOdcN.js → meta-content-Djgg-tiF.js} +1 -1
  69. package/dist/storybook/assets/{modal.stories-ChRLG9ud.js → modal.stories-BoVj2EsX.js} +2 -2
  70. package/dist/storybook/assets/{number-input.stories-COWyMRAs.js → number-input.stories-CcNTeD25.js} +2 -2
  71. package/dist/storybook/assets/{option-dropdown.stories-DvgAgTHQ.js → option-dropdown.stories-COGmMWEl.js} +1 -1
  72. package/dist/storybook/assets/{padding-and-spacing-J82LpJ4b.js → padding-and-spacing-BBGMEHS0.js} +2 -2
  73. package/dist/storybook/assets/{page.stories-DdAfcsOc.js → page.stories-BB3g1zwB.js} +1 -1
  74. package/dist/storybook/assets/{pagination-0wY_w1xz.js → pagination-DSQeMPG_.js} +1 -1
  75. package/dist/storybook/assets/{pagination.stories-BagAIIz3.js → pagination.stories-DjIohcDx.js} +2 -2
  76. package/dist/storybook/assets/{pop-confirm.stories-D4L3erpj.js → pop-confirm.stories-Cr_ZBbLn.js} +1 -1
  77. package/dist/storybook/assets/{popover-CvS_kBVF.js → popover-Dq3iC_lM.js} +1 -1
  78. package/dist/storybook/assets/popover.stories-CoWCb2Mn.js +10 -0
  79. package/dist/storybook/assets/preview-BEkR6e06.js +2 -0
  80. package/dist/storybook/assets/{preview-CM5CE7B2.js → preview-Dc_WvvGi.js} +2 -2
  81. package/dist/storybook/assets/projects.stories-BesbPJ8Z.js +47 -0
  82. package/dist/storybook/assets/{radio-button-J4oEQdxt.js → radio-button-BD7pi0ao.js} +1 -1
  83. package/dist/storybook/assets/{radio-button.stories-BFp_qyyE.js → radio-button.stories-B84Ip3NV.js} +1 -1
  84. package/dist/storybook/assets/react-router-dom-CMITYWBH.js +8 -0
  85. package/dist/storybook/assets/{reservoirs.stories-DywuU8EY.js → reservoirs.stories-kxVBoa7Y.js} +2 -2
  86. package/dist/storybook/assets/{rich-text-input.stories-Cw_6EJx8.js → rich-text-input.stories-C5pcIbSa.js} +3 -3
  87. package/dist/storybook/assets/{row.stories-D7V0fxhq.js → row.stories-ATsrjumb.js} +2 -2
  88. package/dist/storybook/assets/{select-yqiMF9-4.js → select-78sreKsp.js} +2 -2
  89. package/dist/storybook/assets/{select.stories-VMcOn7Ri.js → select.stories-CZwsHVDB.js} +2 -2
  90. package/dist/storybook/assets/{side-bar-DAMfASqb.js → side-bar-WsK6pkmj.js} +1 -1
  91. package/dist/storybook/assets/{side-bar.stories-BlEIOckL.js → side-bar.stories-Bu2q_b_w.js} +1 -1
  92. package/dist/storybook/assets/{site.stories-Kk57nhAn.js → site.stories-Yh4uNi3Q.js} +2 -2
  93. package/dist/storybook/assets/{slider-BLU39INk.js → slider-CxVlS0fh.js} +4 -4
  94. package/dist/storybook/assets/{slider.stories-DdVxUAfH.js → slider.stories-_wS70xsm.js} +2 -2
  95. package/dist/storybook/assets/{smart-upload-modal.stories-Cot88l9r.js → smart-upload-modal.stories-DDlO9y2j.js} +1 -1
  96. package/dist/storybook/assets/{spacer.stories-Dd1QMhoc.js → spacer.stories-B3LrTr7b.js} +1 -1
  97. package/dist/storybook/assets/{table-DmwpXp_Q.js → table-DPvzYjoq.js} +1 -1
  98. package/dist/storybook/assets/{table.stories-DKcZk5JR.js → table.stories-BGQ1O9nw.js} +2 -2
  99. package/dist/storybook/assets/{table.stories-data-C6x-UHeN.js → table.stories-data-2STKbgzG.js} +1 -1
  100. package/dist/storybook/assets/text-link.stories-BsuVBOWo.js +14 -0
  101. package/dist/storybook/assets/{title.stories-CKbl0CB2.js → title.stories-CVRTXggL.js} +2 -2
  102. package/dist/storybook/assets/{toaster-B8A3xIYu.js → toaster-DPbde9Mi.js} +1 -1
  103. package/dist/storybook/assets/{toaster.stories-DuE6vvV6.js → toaster.stories-DfbfDavp.js} +1 -1
  104. package/dist/storybook/assets/{toggle-D0yzyALV.js → toggle-t1iTuSL7.js} +1 -1
  105. package/dist/storybook/assets/{toggle.stories-Cre2gnIB.js → toggle.stories-D44S3Nix.js} +1 -1
  106. package/dist/storybook/assets/{tooltip.test-case.stories-BWJhZQg8.js → tooltip.test-case.stories-BtrJUImB.js} +1 -1
  107. package/dist/storybook/assets/{top-bar-mKg-xcLh.js → top-bar-R-CjhJ21.js} +1 -1
  108. package/dist/storybook/assets/top-bar.stories-BYN9rcUw.js +21 -0
  109. package/dist/storybook/assets/{top-bar.testcase.stories-BlbsX9By.js → top-bar.testcase.stories-ZPaSRyIh.js} +1 -1
  110. package/dist/storybook/assets/{tree.stories-CkYwGe0X.js → tree.stories-Ghxps-dL.js} +1 -1
  111. package/dist/storybook/assets/{unit-input.stories-BzMia-WR.js → unit-input.stories-D_6ljfJQ.js} +23 -23
  112. package/dist/storybook/assets/unit-table.stories-DXies3fA.js +150 -0
  113. package/dist/storybook/iframe.html +1 -1
  114. package/dist/storybook/project.json +1 -1
  115. package/package.json +1 -1
  116. package/dist/storybook/assets/Color-KGDBMAHA-Cvq3XQg3.js +0 -1
  117. package/dist/storybook/assets/DocsRenderer-PKQXORMH-Copxu6Si.js +0 -1
  118. package/dist/storybook/assets/color-ClG_lSfj.js +0 -25
  119. package/dist/storybook/assets/footer.stories-B5zvZawz.js +0 -3
  120. package/dist/storybook/assets/form.stories-D58sdhOk.js +0 -49
  121. package/dist/storybook/assets/formation.stories-OtA8Hcp6.js +0 -74
  122. package/dist/storybook/assets/icon-BSFY3vDO.js +0 -8
  123. package/dist/storybook/assets/iframe-ud1XJtGn.js +0 -2
  124. package/dist/storybook/assets/index-q5GJvRDd.js +0 -1
  125. package/dist/storybook/assets/inheritsLoose-DP0QEDDI.js +0 -1
  126. package/dist/storybook/assets/layout-forms-NapA4Ibs.js +0 -16
  127. package/dist/storybook/assets/popover.stories-ChwzGOlc.js +0 -10
  128. package/dist/storybook/assets/preview-CJK2YTz-.js +0 -2
  129. package/dist/storybook/assets/projects.stories-ApHyZURX.js +0 -47
  130. package/dist/storybook/assets/react-router-dom-Ck2Y_Fzc.js +0 -8
  131. package/dist/storybook/assets/text-link.stories-BQAkVO-W.js +0 -14
  132. package/dist/storybook/assets/top-bar.stories-CFZoJq-r.js +0 -21
  133. package/dist/storybook/assets/unit-table.stories-BoNWlaAe.js +0 -150
@@ -1,8 +0,0 @@
1
- import{_ as F,a as V}from"./inheritsLoose-DP0QEDDI.js";import{g as st,R as w}from"./index-DhsZuJvc.js";import{P as Be}from"./index-CEuq6vkz.js";import{i as Y}from"./tiny-invariant-DqLgxztJ.js";import{_ as ce}from"./objectWithoutPropertiesLoose-CAYKN5F1.js";function ie(e){return e.charAt(0)==="/"}function Pe(e,t){for(var i=t,r=i+1,n=e.length;r<n;i+=1,r+=1)e[i]=e[r];e.pop()}function ct(e,t){t===void 0&&(t="");var i=e&&e.split("/")||[],r=t&&t.split("/")||[],n=e&&ie(e),o=t&&ie(t),u=n||o;if(e&&ie(e)?r=i:i.length&&(r.pop(),r=r.concat(i)),!r.length)return"/";var c;if(r.length){var l=r[r.length-1];c=l==="."||l===".."||l===""}else c=!1;for(var a=0,s=r.length;s>=0;s--){var f=r[s];f==="."?Pe(r,s):f===".."?(Pe(r,s),a++):a&&(Pe(r,s),a--)}if(!u)for(;a--;a)r.unshift("..");u&&r[0]!==""&&(!r[0]||!ie(r[0]))&&r.unshift("");var h=r.join("/");return c&&h.substr(-1)!=="/"&&(h+="/"),h}function re(e){return e.charAt(0)==="/"?e:"/"+e}function Ne(e){return e.charAt(0)==="/"?e.substr(1):e}function ut(e,t){return e.toLowerCase().indexOf(t.toLowerCase())===0&&"/?#".indexOf(e.charAt(t.length))!==-1}function Qe(e,t){return ut(e,t)?e.substr(t.length):e}function Ye(e){return e.charAt(e.length-1)==="/"?e.slice(0,-1):e}function ft(e){var t=e||"/",i="",r="",n=t.indexOf("#");n!==-1&&(r=t.substr(n),t=t.substr(0,n));var o=t.indexOf("?");return o!==-1&&(i=t.substr(o),t=t.substr(0,o)),{pathname:t,search:i==="?"?"":i,hash:r==="#"?"":r}}function B(e){var t=e.pathname,i=e.search,r=e.hash,n=t||"/";return i&&i!=="?"&&(n+=i.charAt(0)==="?"?i:"?"+i),r&&r!=="#"&&(n+=r.charAt(0)==="#"?r:"#"+r),n}function W(e,t,i,r){var n;typeof e=="string"?(n=ft(e),n.state=t):(n=F({},e),n.pathname===void 0&&(n.pathname=""),n.search?n.search.charAt(0)!=="?"&&(n.search="?"+n.search):n.search="",n.hash?n.hash.charAt(0)!=="#"&&(n.hash="#"+n.hash):n.hash="",t!==void 0&&n.state===void 0&&(n.state=t));try{n.pathname=decodeURI(n.pathname)}catch(o){throw o instanceof URIError?new URIError('Pathname "'+n.pathname+'" could not be decoded. This is likely caused by an invalid percent-encoding.'):o}return i&&(n.key=i),r?n.pathname?n.pathname.charAt(0)!=="/"&&(n.pathname=ct(n.pathname,r.pathname)):n.pathname=r.pathname:n.pathname||(n.pathname="/"),n}function Ae(){var e=null;function t(u){return e=u,function(){e===u&&(e=null)}}function i(u,c,l,a){if(e!=null){var s=typeof e=="function"?e(u,c):e;typeof s=="string"?typeof l=="function"?l(s,a):a(!0):a(s!==!1)}else a(!0)}var r=[];function n(u){var c=!0;function l(){c&&u.apply(void 0,arguments)}return r.push(l),function(){c=!1,r=r.filter(function(a){return a!==l})}}function o(){for(var u=arguments.length,c=new Array(u),l=0;l<u;l++)c[l]=arguments[l];r.forEach(function(a){return a.apply(void 0,c)})}return{setPrompt:t,confirmTransitionTo:i,appendListener:n,notifyListeners:o}}var Ze=!!(typeof window<"u"&&window.document&&window.document.createElement);function ke(e,t){t(window.confirm(e))}function lt(){var e=window.navigator.userAgent;return(e.indexOf("Android 2.")!==-1||e.indexOf("Android 4.0")!==-1)&&e.indexOf("Mobile Safari")!==-1&&e.indexOf("Chrome")===-1&&e.indexOf("Windows Phone")===-1?!1:window.history&&"pushState"in window.history}function ht(){return window.navigator.userAgent.indexOf("Trident")===-1}function pt(){return window.navigator.userAgent.indexOf("Firefox")===-1}function vt(e){return e.state===void 0&&navigator.userAgent.indexOf("CriOS")===-1}var je="popstate",We="hashchange";function Fe(){try{return window.history.state||{}}catch{return{}}}function dt(e){e===void 0&&(e={}),Ze||Y();var t=window.history,i=lt(),r=!ht(),n=e,o=n.forceRefresh,u=o===void 0?!1:o,c=n.getUserConfirmation,l=c===void 0?ke:c,a=n.keyLength,s=a===void 0?6:a,f=e.basename?Ye(re(e.basename)):"";function h(d){var p=d||{},x=p.key,m=p.state,C=window.location,U=C.pathname,j=C.search,G=C.hash,z=U+j+G;return f&&(z=Qe(z,f)),W(z,m,x)}function v(){return Math.random().toString(36).substr(2,s)}var g=Ae();function E(d){F(q,d),q.length=t.length,g.notifyListeners(q.location,q.action)}function S(d){vt(d)||_(h(d.state))}function A(){_(h(Fe()))}var O=!1;function _(d){if(O)O=!1,E();else{var p="POP";g.confirmTransitionTo(d,p,l,function(x){x?E({action:p,location:d}):D(d)})}}function D(d){var p=q.location,x=T.indexOf(p.key);x===-1&&(x=0);var m=T.indexOf(d.key);m===-1&&(m=0);var C=x-m;C&&(O=!0,R(C))}var H=h(Fe()),T=[H.key];function y(d){return f+B(d)}function P(d,p){var x="PUSH",m=W(d,p,v(),q.location);g.confirmTransitionTo(m,x,l,function(C){if(C){var U=y(m),j=m.key,G=m.state;if(i)if(t.pushState({key:j,state:G},null,U),u)window.location.href=U;else{var z=T.indexOf(q.location.key),Q=T.slice(0,z+1);Q.push(m.key),T=Q,E({action:x,location:m})}else window.location.href=U}})}function M(d,p){var x="REPLACE",m=W(d,p,v(),q.location);g.confirmTransitionTo(m,x,l,function(C){if(C){var U=y(m),j=m.key,G=m.state;if(i)if(t.replaceState({key:j,state:G},null,U),u)window.location.replace(U);else{var z=T.indexOf(q.location.key);z!==-1&&(T[z]=m.key),E({action:x,location:m})}else window.location.replace(U)}})}function R(d){t.go(d)}function L(){R(-1)}function J(){R(1)}var X=0;function N(d){X+=d,X===1&&d===1?(window.addEventListener(je,S),r&&window.addEventListener(We,A)):X===0&&(window.removeEventListener(je,S),r&&window.removeEventListener(We,A))}var I=!1;function Z(d){d===void 0&&(d=!1);var p=g.setPrompt(d);return I||(N(1),I=!0),function(){return I&&(I=!1,N(-1)),p()}}function we(d){var p=g.appendListener(d);return N(1),function(){N(-1),p()}}var q={length:t.length,action:"POP",location:H,createHref:y,push:P,replace:M,go:R,goBack:L,goForward:J,block:Z,listen:we};return q}var Ke="hashchange",mt={hashbang:{encodePath:function(t){return t.charAt(0)==="!"?t:"!/"+Ne(t)},decodePath:function(t){return t.charAt(0)==="!"?t.substr(1):t}},noslash:{encodePath:Ne,decodePath:re},slash:{encodePath:re,decodePath:re}};function et(e){var t=e.indexOf("#");return t===-1?e:e.slice(0,t)}function ne(){var e=window.location.href,t=e.indexOf("#");return t===-1?"":e.substring(t+1)}function gt(e){window.location.hash=e}function be(e){window.location.replace(et(window.location.href)+"#"+e)}function yt(e){e===void 0&&(e={}),Ze||Y();var t=window.history;pt();var i=e,r=i.getUserConfirmation,n=r===void 0?ke:r,o=i.hashType,u=o===void 0?"slash":o,c=e.basename?Ye(re(e.basename)):"",l=mt[u],a=l.encodePath,s=l.decodePath;function f(){var p=s(ne());return c&&(p=Qe(p,c)),W(p)}var h=Ae();function v(p){F(d,p),d.length=t.length,h.notifyListeners(d.location,d.action)}var g=!1,E=null;function S(p,x){return p.pathname===x.pathname&&p.search===x.search&&p.hash===x.hash}function A(){var p=ne(),x=a(p);if(p!==x)be(x);else{var m=f(),C=d.location;if(!g&&S(C,m)||E===B(m))return;E=null,O(m)}}function O(p){if(g)g=!1,v();else{var x="POP";h.confirmTransitionTo(p,x,n,function(m){m?v({action:x,location:p}):_(p)})}}function _(p){var x=d.location,m=y.lastIndexOf(B(x));m===-1&&(m=0);var C=y.lastIndexOf(B(p));C===-1&&(C=0);var U=m-C;U&&(g=!0,L(U))}var D=ne(),H=a(D);D!==H&&be(H);var T=f(),y=[B(T)];function P(p){var x=document.querySelector("base"),m="";return x&&x.getAttribute("href")&&(m=et(window.location.href)),m+"#"+a(c+B(p))}function M(p,x){var m="PUSH",C=W(p,void 0,void 0,d.location);h.confirmTransitionTo(C,m,n,function(U){if(U){var j=B(C),G=a(c+j),z=ne()!==G;if(z){E=j,gt(G);var Q=y.lastIndexOf(B(d.location)),De=y.slice(0,Q+1);De.push(j),y=De,v({action:m,location:C})}else v()}})}function R(p,x){var m="REPLACE",C=W(p,void 0,void 0,d.location);h.confirmTransitionTo(C,m,n,function(U){if(U){var j=B(C),G=a(c+j),z=ne()!==G;z&&(E=j,be(G));var Q=y.indexOf(B(d.location));Q!==-1&&(y[Q]=j),v({action:m,location:C})}})}function L(p){t.go(p)}function J(){L(-1)}function X(){L(1)}var N=0;function I(p){N+=p,N===1&&p===1?window.addEventListener(Ke,A):N===0&&window.removeEventListener(Ke,A)}var Z=!1;function we(p){p===void 0&&(p=!1);var x=h.setPrompt(p);return Z||(I(1),Z=!0),function(){return Z&&(Z=!1,I(-1)),x()}}function q(p){var x=h.appendListener(p);return I(1),function(){I(-1),x()}}var d={length:t.length,action:"POP",location:T,createHref:P,push:M,replace:R,go:L,goBack:J,goForward:X,block:we,listen:q};return d}function qe(e,t,i){return Math.min(Math.max(e,t),i)}function xt(e){e===void 0&&(e={});var t=e,i=t.getUserConfirmation,r=t.initialEntries,n=r===void 0?["/"]:r,o=t.initialIndex,u=o===void 0?0:o,c=t.keyLength,l=c===void 0?6:c,a=Ae();function s(P){F(y,P),y.length=y.entries.length,a.notifyListeners(y.location,y.action)}function f(){return Math.random().toString(36).substr(2,l)}var h=qe(u,0,n.length-1),v=n.map(function(P){return typeof P=="string"?W(P,void 0,f()):W(P,void 0,P.key||f())}),g=B;function E(P,M){var R="PUSH",L=W(P,M,f(),y.location);a.confirmTransitionTo(L,R,i,function(J){if(J){var X=y.index,N=X+1,I=y.entries.slice(0);I.length>N?I.splice(N,I.length-N,L):I.push(L),s({action:R,location:L,index:N,entries:I})}})}function S(P,M){var R="REPLACE",L=W(P,M,f(),y.location);a.confirmTransitionTo(L,R,i,function(J){J&&(y.entries[y.index]=L,s({action:R,location:L}))})}function A(P){var M=qe(y.index+P,0,y.entries.length-1),R="POP",L=y.entries[M];a.confirmTransitionTo(L,R,i,function(J){J?s({action:R,location:L,index:M}):s()})}function O(){A(-1)}function _(){A(1)}function D(P){var M=y.index+P;return M>=0&&M<y.entries.length}function H(P){return P===void 0&&(P=!1),a.setPrompt(P)}function T(P){return a.appendListener(P)}var y={length:v.length,action:"POP",location:v[h],index:h,entries:v,createHref:g,push:E,replace:S,go:A,goBack:O,goForward:_,canGo:D,block:H,listen:T};return y}var te={exports:{}},wt=Array.isArray||function(e){return Object.prototype.toString.call(e)=="[object Array]"},ae=wt;te.exports=rt;te.exports.parse=Re;te.exports.compile=bt;te.exports.tokensToFunction=tt;te.exports.tokensToRegExp=nt;var Pt=new RegExp(["(\\\\.)","([\\/.])?(?:(?:\\:(\\w+)(?:\\(((?:\\\\.|[^\\\\()])+)\\))?|\\(((?:\\\\.|[^\\\\()])+)\\))([+*?])?|(\\*))"].join("|"),"g");function Re(e,t){for(var i=[],r=0,n=0,o="",u=t&&t.delimiter||"/",c;(c=Pt.exec(e))!=null;){var l=c[0],a=c[1],s=c.index;if(o+=e.slice(n,s),n=s+l.length,a){o+=a[1];continue}var f=e[n],h=c[2],v=c[3],g=c[4],E=c[5],S=c[6],A=c[7];o&&(i.push(o),o="");var O=h!=null&&f!=null&&f!==h,_=S==="+"||S==="*",D=S==="?"||S==="*",H=c[2]||u,T=g||E;i.push({name:v||r++,prefix:h||"",delimiter:H,optional:D,repeat:_,partial:O,asterisk:!!A,pattern:T?St(T):A?".*":"[^"+oe(H)+"]+?"})}return n<e.length&&(o+=e.substr(n)),o&&i.push(o),i}function bt(e,t){return tt(Re(e,t),t)}function Ct(e){return encodeURI(e).replace(/[\/?#]/g,function(t){return"%"+t.charCodeAt(0).toString(16).toUpperCase()})}function Et(e){return encodeURI(e).replace(/[?#]/g,function(t){return"%"+t.charCodeAt(0).toString(16).toUpperCase()})}function tt(e,t){for(var i=new Array(e.length),r=0;r<e.length;r++)typeof e[r]=="object"&&(i[r]=new RegExp("^(?:"+e[r].pattern+")$",$e(t)));return function(n,o){for(var u="",c=n||{},l=o||{},a=l.pretty?Ct:encodeURIComponent,s=0;s<e.length;s++){var f=e[s];if(typeof f=="string"){u+=f;continue}var h=c[f.name],v;if(h==null)if(f.optional){f.partial&&(u+=f.prefix);continue}else throw new TypeError('Expected "'+f.name+'" to be defined');if(ae(h)){if(!f.repeat)throw new TypeError('Expected "'+f.name+'" to not repeat, but received `'+JSON.stringify(h)+"`");if(h.length===0){if(f.optional)continue;throw new TypeError('Expected "'+f.name+'" to not be empty')}for(var g=0;g<h.length;g++){if(v=a(h[g]),!i[s].test(v))throw new TypeError('Expected all "'+f.name+'" to match "'+f.pattern+'", but received `'+JSON.stringify(v)+"`");u+=(g===0?f.prefix:f.delimiter)+v}continue}if(v=f.asterisk?Et(h):a(h),!i[s].test(v))throw new TypeError('Expected "'+f.name+'" to match "'+f.pattern+'", but received "'+v+'"');u+=f.prefix+v}return u}}function oe(e){return e.replace(/([.+*?=^!:${}()[\]|\/\\])/g,"\\$1")}function St(e){return e.replace(/([=!:$\/()])/g,"\\$1")}function Le(e,t){return e.keys=t,e}function $e(e){return e&&e.sensitive?"":"i"}function Tt(e,t){var i=e.source.match(/\((?!\?)/g);if(i)for(var r=0;r<i.length;r++)t.push({name:r,prefix:null,delimiter:null,optional:!1,repeat:!1,partial:!1,asterisk:!1,pattern:null});return Le(e,t)}function At(e,t,i){for(var r=[],n=0;n<e.length;n++)r.push(rt(e[n],t,i).source);var o=new RegExp("(?:"+r.join("|")+")",$e(i));return Le(o,t)}function Rt(e,t,i){return nt(Re(e,i),t,i)}function nt(e,t,i){ae(t)||(i=t||i,t=[]),i=i||{};for(var r=i.strict,n=i.end!==!1,o="",u=0;u<e.length;u++){var c=e[u];if(typeof c=="string")o+=oe(c);else{var l=oe(c.prefix),a="(?:"+c.pattern+")";t.push(c),c.repeat&&(a+="(?:"+l+a+")*"),c.optional?c.partial?a=l+"("+a+")?":a="(?:"+l+"("+a+"))?":a=l+"("+a+")",o+=a}}var s=oe(i.delimiter||"/"),f=o.slice(-s.length)===s;return r||(o=(f?o.slice(0,-s.length):o)+"(?:"+s+"(?=$))?"),n?o+="$":o+=r&&f?"":"(?="+s+"|$)",Le(new RegExp("^"+o,$e(i)),t)}function rt(e,t,i){return ae(t)||(i=t||i,t=[]),i=i||{},e instanceof RegExp?Tt(e,t):ae(e)?At(e,t,i):Rt(e,t,i)}var Lt=te.exports;const $t=st(Lt);var b={};/** @license React v16.13.1
2
- * react-is.production.min.js
3
- *
4
- * Copyright (c) Facebook, Inc. and its affiliates.
5
- *
6
- * This source code is licensed under the MIT license found in the
7
- * LICENSE file in the root directory of this source tree.
8
- */var $=typeof Symbol=="function"&&Symbol.for,Me=$?Symbol.for("react.element"):60103,Oe=$?Symbol.for("react.portal"):60106,ue=$?Symbol.for("react.fragment"):60107,fe=$?Symbol.for("react.strict_mode"):60108,le=$?Symbol.for("react.profiler"):60114,he=$?Symbol.for("react.provider"):60109,pe=$?Symbol.for("react.context"):60110,Ue=$?Symbol.for("react.async_mode"):60111,ve=$?Symbol.for("react.concurrent_mode"):60111,de=$?Symbol.for("react.forward_ref"):60112,me=$?Symbol.for("react.suspense"):60113,Mt=$?Symbol.for("react.suspense_list"):60120,ge=$?Symbol.for("react.memo"):60115,ye=$?Symbol.for("react.lazy"):60116,Ot=$?Symbol.for("react.block"):60121,Ut=$?Symbol.for("react.fundamental"):60117,Ht=$?Symbol.for("react.responder"):60118,It=$?Symbol.for("react.scope"):60119;function K(e){if(typeof e=="object"&&e!==null){var t=e.$$typeof;switch(t){case Me:switch(e=e.type,e){case Ue:case ve:case ue:case le:case fe:case me:return e;default:switch(e=e&&e.$$typeof,e){case pe:case de:case ye:case ge:case he:return e;default:return t}}case Oe:return t}}}function it(e){return K(e)===ve}b.AsyncMode=Ue;b.ConcurrentMode=ve;b.ContextConsumer=pe;b.ContextProvider=he;b.Element=Me;b.ForwardRef=de;b.Fragment=ue;b.Lazy=ye;b.Memo=ge;b.Portal=Oe;b.Profiler=le;b.StrictMode=fe;b.Suspense=me;b.isAsyncMode=function(e){return it(e)||K(e)===Ue};b.isConcurrentMode=it;b.isContextConsumer=function(e){return K(e)===pe};b.isContextProvider=function(e){return K(e)===he};b.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===Me};b.isForwardRef=function(e){return K(e)===de};b.isFragment=function(e){return K(e)===ue};b.isLazy=function(e){return K(e)===ye};b.isMemo=function(e){return K(e)===ge};b.isPortal=function(e){return K(e)===Oe};b.isProfiler=function(e){return K(e)===le};b.isStrictMode=function(e){return K(e)===fe};b.isSuspense=function(e){return K(e)===me};b.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===ue||e===ve||e===le||e===fe||e===me||e===Mt||typeof e=="object"&&e!==null&&(e.$$typeof===ye||e.$$typeof===ge||e.$$typeof===he||e.$$typeof===pe||e.$$typeof===de||e.$$typeof===Ut||e.$$typeof===Ht||e.$$typeof===It||e.$$typeof===Ot)};b.typeOf=K;var Ce=1073741823,ze=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:{};function _t(){var e="__global_unique_id__";return ze[e]=(ze[e]||0)+1}function Dt(e,t){return e===t?e!==0||1/e===1/t:e!==e&&t!==t}function Bt(e){var t=[];return{on:function(r){t.push(r)},off:function(r){t=t.filter(function(n){return n!==r})},get:function(){return e},set:function(r,n){e=r,t.forEach(function(o){return o(e,n)})}}}function Nt(e){return Array.isArray(e)?e[0]:e}function jt(e,t){var i,r,n="__create-react-context-"+_t()+"__",o=function(c){V(l,c);function l(){for(var s,f=arguments.length,h=new Array(f),v=0;v<f;v++)h[v]=arguments[v];return s=c.call.apply(c,[this].concat(h))||this,s.emitter=Bt(s.props.value),s}var a=l.prototype;return a.getChildContext=function(){var f;return f={},f[n]=this.emitter,f},a.componentWillReceiveProps=function(f){if(this.props.value!==f.value){var h=this.props.value,v=f.value,g;Dt(h,v)?g=0:(g=typeof t=="function"?t(h,v):Ce,g|=0,g!==0&&this.emitter.set(f.value,g))}},a.render=function(){return this.props.children},l}(w.Component);o.childContextTypes=(i={},i[n]=Be.object.isRequired,i);var u=function(c){V(l,c);function l(){for(var s,f=arguments.length,h=new Array(f),v=0;v<f;v++)h[v]=arguments[v];return s=c.call.apply(c,[this].concat(h))||this,s.observedBits=void 0,s.state={value:s.getValue()},s.onUpdate=function(g,E){var S=s.observedBits|0;S&E&&s.setState({value:s.getValue()})},s}var a=l.prototype;return a.componentWillReceiveProps=function(f){var h=f.observedBits;this.observedBits=h??Ce},a.componentDidMount=function(){this.context[n]&&this.context[n].on(this.onUpdate);var f=this.props.observedBits;this.observedBits=f??Ce},a.componentWillUnmount=function(){this.context[n]&&this.context[n].off(this.onUpdate)},a.getValue=function(){return this.context[n]?this.context[n].get():e},a.render=function(){return Nt(this.props.children)(this.state.value)},l}(w.Component);return u.contextTypes=(r={},r[n]=Be.object,r),{Provider:o,Consumer:u}}var Wt=w.createContext||jt,ot=function(t){var i=Wt();return i.displayName=t,i},Ft=ot("Router-History"),k=ot("Router"),xe=function(e){V(t,e),t.computeRootMatch=function(n){return{path:"/",url:"/",params:{},isExact:n==="/"}};function t(r){var n;return n=e.call(this,r)||this,n.state={location:r.history.location},n._isMounted=!1,n._pendingLocation=null,r.staticContext||(n.unlisten=r.history.listen(function(o){n._pendingLocation=o})),n}var i=t.prototype;return i.componentDidMount=function(){var n=this;this._isMounted=!0,this.unlisten&&this.unlisten(),this.props.staticContext||(this.unlisten=this.props.history.listen(function(o){n._isMounted&&n.setState({location:o})})),this._pendingLocation&&this.setState({location:this._pendingLocation})},i.componentWillUnmount=function(){this.unlisten&&(this.unlisten(),this._isMounted=!1,this._pendingLocation=null)},i.render=function(){return w.createElement(k.Provider,{value:{history:this.props.history,location:this.state.location,match:t.computeRootMatch(this.state.location.pathname),staticContext:this.props.staticContext}},w.createElement(Ft.Provider,{children:this.props.children||null,value:this.props.history}))},t}(w.Component);w.Component;w.Component;var Ge={},Kt=1e4,Ve=0;function qt(e,t){var i=""+t.end+t.strict+t.sensitive,r=Ge[i]||(Ge[i]={});if(r[e])return r[e];var n=[],o=$t(e,n,t),u={regexp:o,keys:n};return Ve<Kt&&(r[e]=u,Ve++),u}function He(e,t){t===void 0&&(t={}),(typeof t=="string"||Array.isArray(t))&&(t={path:t});var i=t,r=i.path,n=i.exact,o=n===void 0?!1:n,u=i.strict,c=u===void 0?!1:u,l=i.sensitive,a=l===void 0?!1:l,s=[].concat(r);return s.reduce(function(f,h){if(!h&&h!=="")return null;if(f)return f;var v=qt(h,{end:o,strict:c,sensitive:a}),g=v.regexp,E=v.keys,S=g.exec(e);if(!S)return null;var A=S[0],O=S.slice(1),_=e===A;return o&&!_?null:{path:h,url:h==="/"&&A===""?"/":A,isExact:_,params:E.reduce(function(D,H,T){return D[H.name]=O[T],D},{})}},null)}function zt(e){return w.Children.count(e)===0}var rn=function(e){V(t,e);function t(){return e.apply(this,arguments)||this}var i=t.prototype;return i.render=function(){var n=this;return w.createElement(k.Consumer,null,function(o){o||Y();var u=n.props.location||o.location,c=n.props.computedMatch?n.props.computedMatch:n.props.path?He(u.pathname,n.props):o.match,l=F({},o,{location:u,match:c}),a=n.props,s=a.children,f=a.component,h=a.render;return Array.isArray(s)&&zt(s)&&(s=null),w.createElement(k.Provider,{value:l},l.match?s?typeof s=="function"?s(l):s:f?w.createElement(f,l):h?h(l):null:typeof s=="function"?s(l):null)})},t}(w.Component);function Ie(e){return e.charAt(0)==="/"?e:"/"+e}function Gt(e,t){return e?F({},t,{pathname:Ie(e)+t.pathname}):t}function Vt(e,t){if(!e)return t;var i=Ie(e);return t.pathname.indexOf(i)!==0?t:F({},t,{pathname:t.pathname.substr(i.length)})}function Je(e){return typeof e=="string"?e:B(e)}function Ee(e){return function(){Y()}}function Xe(){}w.Component;var on=function(e){V(t,e);function t(){return e.apply(this,arguments)||this}var i=t.prototype;return i.render=function(){var n=this;return w.createElement(k.Consumer,null,function(o){o||Y();var u=n.props.location||o.location,c,l;return w.Children.forEach(n.props.children,function(a){if(l==null&&w.isValidElement(a)){c=a;var s=a.props.path||a.props.from;l=s?He(u.pathname,F({},a.props,{path:s})):o.match}}),l?w.cloneElement(c,{location:u,computedMatch:l}):null})},t}(w.Component);w.useContext;w.Component;var an=function(e){V(t,e);function t(){for(var r,n=arguments.length,o=new Array(n),u=0;u<n;u++)o[u]=arguments[u];return r=e.call.apply(e,[this].concat(o))||this,r.history=yt(r.props),r}var i=t.prototype;return i.render=function(){return w.createElement(xe,{history:this.history,children:this.props.children})},t}(w.Component),Se=function(t,i){return typeof t=="function"?t(i):t},Te=function(t,i){return typeof t=="string"?W(t,null,null,i):t},_e=function(t){return t},ee=w.forwardRef;typeof ee>"u"&&(ee=_e);function Jt(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}var Xt=ee(function(e,t){var i=e.innerRef,r=e.navigate,n=e.onClick,o=ce(e,["innerRef","navigate","onClick"]),u=o.target,c=F({},o,{onClick:function(a){try{n&&n(a)}catch(s){throw a.preventDefault(),s}!a.defaultPrevented&&a.button===0&&(!u||u==="_self")&&!Jt(a)&&(a.preventDefault(),r())}});return _e!==ee?c.ref=t||i:c.ref=i,w.createElement("a",c)}),Qt=ee(function(e,t){var i=e.component,r=i===void 0?Xt:i,n=e.replace,o=e.to,u=e.innerRef,c=ce(e,["component","replace","to","innerRef"]);return w.createElement(k.Consumer,null,function(l){l||Y();var a=l.history,s=Te(Se(o,l.location),l.location),f=s?a.createHref(s):"",h=F({},c,{href:f,navigate:function(){var g=Se(o,l.location),E=B(l.location)===B(Te(g)),S=n||E?a.replace:a.push;S(g)}});return _e!==ee?h.ref=t||u:h.innerRef=u,w.createElement(r,h)})}),at=function(t){return t},se=w.forwardRef;typeof se>"u"&&(se=at);function Yt(){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];return t.filter(function(r){return r}).join(" ")}se(function(e,t){var i=e["aria-current"],r=i===void 0?"page":i,n=e.activeClassName,o=n===void 0?"active":n,u=e.activeStyle,c=e.className,l=e.exact,a=e.isActive,s=e.location,f=e.sensitive,h=e.strict,v=e.style,g=e.to,E=e.innerRef,S=ce(e,["aria-current","activeClassName","activeStyle","className","exact","isActive","location","sensitive","strict","style","to","innerRef"]);return w.createElement(k.Consumer,null,function(A){A||Y();var O=s||A.location,_=Te(Se(g,O),O),D=_.pathname,H=D&&D.replace(/([.+*?=^!:${}()[\]|/\\])/g,"\\$1"),T=H?He(O.pathname,{path:H,exact:l,sensitive:f,strict:h}):null,y=!!(a?a(T,O):T),P=typeof c=="function"?c(y):c,M=typeof v=="function"?v(y):v;y&&(P=Yt(P,o),M=F({},M,u));var R=F({"aria-current":y&&r||null,className:P,style:M,to:_},S);return at!==se?R.ref=t||E:R.innerRef=E,w.createElement(Qt,R)})});export{an as H,Qt as L,rn as R,on as S};
@@ -1,14 +0,0 @@
1
- import{j as e}from"./jsx-runtime-eps93zm2.js";import{H as E,L as i,S as j,R as c}from"./react-router-dom-Ck2Y_Fzc.js";import{F as y}from"./flex-EllkLxgO.js";import{T as S}from"./text-B3-TSWok.js";import"./index-DhsZuJvc.js";import"./inheritsLoose-DP0QEDDI.js";import"./index-CEuq6vkz.js";import"./tiny-invariant-DqLgxztJ.js";import"./objectWithoutPropertiesLoose-CAYKN5F1.js";import"./index-Bk2sglWO.js";const r=({children:a,href:o=void 0,target:T=void 0,testId:R,onClick:L,component:v="a"})=>e.jsx(v,{href:o,to:o,target:T,onClick:L,"data-testid":R,children:e.jsx(S,{link:!0,children:a})});r.__docgenInfo={description:"",methods:[],displayName:"TextLink",props:{href:{required:!1,tsType:{name:"string"},description:"",defaultValue:{value:"undefined",computed:!0}},target:{required:!1,tsType:{name:"string"},description:"",defaultValue:{value:"undefined",computed:!0}},testId:{required:!1,tsType:{name:"string"},description:""},onClick:{required:!1,tsType:{name:"signature",type:"function",raw:"(e: React.MouseEvent<HTMLAnchorElement, MouseEvent>) => void",signature:{arguments:[{type:{name:"ReactMouseEvent",raw:"React.MouseEvent<HTMLAnchorElement, MouseEvent>",elements:[{name:"HTMLAnchorElement"},{name:"MouseEvent"}]},name:"e"}],return:{name:"void"}}},description:""},children:{required:!1,tsType:{name:"ReactReactNode",raw:"React.ReactNode"},description:""},component:{required:!1,tsType:{name:"ReactElementType",raw:"React.ElementType"},description:"",defaultValue:{value:"'a'",computed:!1}}}};const N={title:"Basic/TextLink",component:r,args:{children:"Link text goes here",href:"http://oliasoft.com"}},k=a=>e.jsx(r,{...a}),n=k.bind({}),t=k.bind({});t.args={href:void 0,onClick:()=>console.log("Clicked!")};const s=()=>e.jsxs(E,{children:[e.jsxs(y,{gap:!0,children:[e.jsx(r,{component:i,href:"/dashboard",children:"Dashboard"}),e.jsx(r,{component:i,href:"/settings",children:"Settings"})]}),e.jsxs(j,{children:[e.jsx(c,{path:"/dashboard",children:"Dashboard"}),e.jsx(c,{path:"/settings",children:"Settings"})]})]});s.__docgenInfo={description:"",methods:[],displayName:"AsRouterLink"};var d,p,m;n.parameters={...n.parameters,docs:{...(d=n.parameters)==null?void 0:d.docs,source:{originalSource:"args => <TextLink {...args} />",...(m=(p=n.parameters)==null?void 0:p.docs)==null?void 0:m.source}}};var u,l,h;t.parameters={...t.parameters,docs:{...(u=t.parameters)==null?void 0:u.docs,source:{originalSource:"args => <TextLink {...args} />",...(h=(l=t.parameters)==null?void 0:l.docs)==null?void 0:h.source}}};var g,f,x;s.parameters={...s.parameters,docs:{...(g=s.parameters)==null?void 0:g.docs,source:{originalSource:`() => <HashRouter>
2
- <Flex gap>
3
- <TextLink component={Link} href="/dashboard">
4
- Dashboard
5
- </TextLink>
6
- <TextLink component={Link} href="/settings">
7
- Settings
8
- </TextLink>
9
- </Flex>
10
- <Switch>
11
- <Route path="/dashboard">Dashboard</Route>
12
- <Route path="/settings">Settings</Route>
13
- </Switch>
14
- </HashRouter>`,...(x=(f=s.parameters)==null?void 0:f.docs)==null?void 0:x.source}}};const I=["Default","OnClick","AsRouterLink"];export{s as AsRouterLink,n as Default,t as OnClick,I as __namedExportsOrder,N as default};
@@ -1,21 +0,0 @@
1
- import{j as e}from"./jsx-runtime-eps93zm2.js";import{H as I,L as c,S as D,R as l}from"./react-router-dom-Ck2Y_Fzc.js";import{I as O,T as A}from"./common-types-Sih75Sav.js";import{T as p}from"./top-bar-mKg-xcLh.js";import{P as w}from"./page-7SSpdYhb.js";import{M as N}from"./actions-4w-EOz3m.js";import{B as m}from"./button-CdEIDAx8.js";import{B as P}from"./badge-CLQ59MDF.js";import{L as v}from"./logo-BVP9045W.js";import{s as H}from"./icon-custom-Xcl4YkWP.js";import{M as s}from"./types-BmbYqTX_.js";import"./index-DhsZuJvc.js";import"./inheritsLoose-DP0QEDDI.js";import"./index-CEuq6vkz.js";import"./tiny-invariant-DqLgxztJ.js";import"./objectWithoutPropertiesLoose-CAYKN5F1.js";import"./index-Bk2sglWO.js";import"./icon-BSFY3vDO.js";import"./disabled-context-rmpd7YJS.js";import"./lodash-BHd_uQHh.js";import"./tooltip-C_E_6ym5.js";import"./index-CUZDtIZe.js";import"./types-UmZ4Y_CR.js";import"./spinner-AWUe4xwQ.js";const M=[{type:"Link",label:"Link",onClick:()=>{}},{type:"Link",label:"Active",active:!0,onClick:()=>{}},{type:"Link",label:"Disabled",disabled:!0,onClick:()=>{}},{type:"Menu",label:"Dropdown",onClick:()=>{},sections:[{type:"Option",label:"Alpacas",onClick:()=>{}},{type:"Option",label:"Llamas",onClick:()=>{}}]},{type:"Button",label:"Save",colored:!0,onClick:()=>{},testId:"top-bar-button-save"}],E=[{type:"Component",component:e.jsx(P,{title:"3",small:!0,margin:"5px",children:e.jsx(m,{icon:O.NOTIFICATION,round:!0,onClick:()=>{}})})},{type:"Component",component:e.jsx(N,{menu:{trigger:A.COMPONENT,fullHeightTrigger:!0,placement:"bottom-end",component:e.jsx(m,{label:"TU",round:!0,onClick:()=>{}}),sections:[{type:s.HEADING,label:"Test User"},{type:s.OPTION,label:"Profile",icon:"user",onClick:()=>{}},{type:s.DIVIDER},{type:s.OPTION,label:"Sign out",icon:"lock",onClick:()=>{}}]}})}],ce={title:"Navigation/TopBar",component:p,parameters:{layout:"fullscreen",docs:{story:{inline:!1,iframeHeight:400}}},argTypes:{height:{control:"text"}},args:{title:{logo:e.jsx("img",{src:v,alt:"logo"}),onClick:()=>{}},content:M,contentRight:E}},i=j=>e.jsx(p,{...j}),n=i.bind({}),t=i.bind({});t.args={warning:"Application update available. Please refresh your browser."};const r=i.bind({});r.args={title:{label:"Text Branding",onClick:()=>{}}};const o=i.bind({});o.args={appSwitcher:{icon:H,onClick:()=>{}}};const a=()=>e.jsx(I,{children:e.jsxs(w,{left:0,children:[e.jsx(p,{content:[{type:"Link",label:"Dashboard",component:c,url:"/dashboard"},{type:"Link",label:"Settings",component:c,url:"/settings"}]}),e.jsxs(D,{children:[e.jsx(l,{path:"/dashboard",children:"Dashboard"}),e.jsx(l,{path:"/settings",children:"Settings"})]})]})});a.__docgenInfo={description:"",methods:[],displayName:"AsRouterLink"};var d,u,g;n.parameters={...n.parameters,docs:{...(d=n.parameters)==null?void 0:d.docs,source:{originalSource:"args => <TopBar {...args} />",...(g=(u=n.parameters)==null?void 0:u.docs)==null?void 0:g.source}}};var h,b,k;t.parameters={...t.parameters,docs:{...(h=t.parameters)==null?void 0:h.docs,source:{originalSource:"args => <TopBar {...args} />",...(k=(b=t.parameters)==null?void 0:b.docs)==null?void 0:k.source}}};var T,y,f;r.parameters={...r.parameters,docs:{...(T=r.parameters)==null?void 0:T.docs,source:{originalSource:"args => <TopBar {...args} />",...(f=(y=r.parameters)==null?void 0:y.docs)==null?void 0:f.source}}};var x,S,C;o.parameters={...o.parameters,docs:{...(x=o.parameters)==null?void 0:x.docs,source:{originalSource:"args => <TopBar {...args} />",...(C=(S=o.parameters)==null?void 0:S.docs)==null?void 0:C.source}}};var L,B,R;a.parameters={...a.parameters,docs:{...(L=a.parameters)==null?void 0:L.docs,source:{originalSource:`() => {
2
- return <HashRouter>
3
- <Page left={0}>
4
- <TopBar content={[{
5
- type: 'Link',
6
- label: 'Dashboard',
7
- component: Link,
8
- url: '/dashboard'
9
- }, {
10
- type: 'Link',
11
- label: 'Settings',
12
- component: Link,
13
- url: '/settings'
14
- }]} />
15
- <Switch>
16
- <Route path="/dashboard">Dashboard</Route>
17
- <Route path="/settings">Settings</Route>
18
- </Switch>
19
- </Page>
20
- </HashRouter>;
21
- }`,...(R=(B=a.parameters)==null?void 0:B.docs)==null?void 0:R.source}}};const le=["Default","WithWarning","TextBranding","AppSwitcher","AsRouterLink"];export{o as AppSwitcher,a as AsRouterLink,n as Default,r as TextBranding,t as WithWarning,le as __namedExportsOrder,ce as default};
@@ -1,150 +0,0 @@
1
- import{j as n}from"./jsx-runtime-eps93zm2.js";import{r as v}from"./index-DhsZuJvc.js";import{f as z}from"./immer.esm-BwVl9PS2.js";import{d as U}from"./index-DQs5XS8h.js";import{G as Z}from"./grid-B6LFPf51.js";import{S as ee}from"./spacer-BWoNR27H.js";import{C as F}from"./card-EcjmryU9.js";import{F as L}from"./field-nInV3MuR.js";import{H as W}from"./heading-EzI5s4VN.js";import{S as P}from"./select-yqiMF9-4.js";import{T as I}from"./toggle-D0yzyALV.js";import{l as te}from"./lodash-BHd_uQHh.js";import{u as ne}from"./use-previous-D775JrO6.js";import{T as ae,C as _}from"./table-DmwpXp_Q.js";import"./index-DRSy5Ssd.js";import"./styled-components.browser.esm-Bf0q9Yjk.js";import"./index-Bk2sglWO.js";import"./label-Cz6TT90s.js";import"./common-types-Sih75Sav.js";import"./help-icon-CfV3_Ais.js";import"./tooltip-C_E_6ym5.js";import"./index-CUZDtIZe.js";import"./icon-BSFY3vDO.js";import"./objectWithoutPropertiesLoose-CAYKN5F1.js";import"./inheritsLoose-DP0QEDDI.js";import"./index-CEuq6vkz.js";import"./disabled-context-rmpd7YJS.js";import"./types-UmZ4Y_CR.js";import"./assertThisInitialized-B9jnkVVz.js";import"./memoize-one.esm-CcMeOnPo.js";import"./types-BmbYqTX_.js";import"./text-B3-TSWok.js";import"./actions-4w-EOz3m.js";import"./button-CdEIDAx8.js";import"./spinner-AWUe4xwQ.js";import"./badge-CLQ59MDF.js";import"./select.input-DIKP56UZ.js";import"./index.es-DazXb-ul.js";import"./redux-tRgGMjwY.js";import"./objectSpread2-DW4nTBoq.js";import"./tiny-invariant-DqLgxztJ.js";import"./pagination-0wY_w1xz.js";import"./input-D97ganXq.js";import"./input-group-BaRSJAEN.js";import"./input-group-addon-D68iUKV2.js";import"./number-input-B-Nmya5O.js";import"./check-box-2fHPdAZG.js";import"./slider-BLU39INk.js";import"./index-BI4_Bp97.js";import"./popover-CvS_kBVF.js";const ie=l=>l.reduce(({preferredUnits:i,storageUnits:r},{unitKey:s,preferredUnit:a,storageUnit:h})=>(i[s]=a,r[s]=h,{preferredUnits:i,storageUnits:r}),{preferredUnits:{},storageUnits:{}}),re=({headers:l,rows:i,selectedUnits:r,storageUnits:s,onChangeUnit:a,convertBackToStorageUnit:h,enableCosmeticRounding:g,enableDisplayRounding:y})=>{const u=l?l.map(d=>({...d,cells:d.cells.map(c=>{var t;if(c.type===_.AUTO_UNIT){const{testId:C,unitKey:p}=c;return{value:r[p],type:_.SELECT,searchable:!1,options:(t=U.getUnitsForQuantity(p))==null?void 0:t.map(T=>({label:U.label(T),value:T})),native:c.native,onChange:T=>a({unitKey:p,value:T.target.value}),testId:C}}return c})})):[],o=i?i.map((d,c)=>({...d,cells:d.cells.map((t,C)=>{if("autoUnit"in t&&(t!=null&&t.autoUnit)&&(typeof(t==null?void 0:t.value)=="string"||typeof(t==null?void 0:t.value)=="number")){const{unitKey:p,value:T,formatDisplayValue:w}=t,j=y&&"roundDisplayValue"in t?t==null?void 0:t.roundDisplayValue:null,m=r[p],b=s[p],e=m!==b,f=e?U.convertAndGetValue(T,m,b):t.value,x=U.isScientificStringNum(T),D=g&&(e||!x)?U.roundToPrecision(f,14):f,R=w?w(D):D;return{...t,value:R,enableCosmeticRounding:g,enableDisplayRounding:y,roundDisplayValue:j,onChange:S=>{const{value:B}=S.target,A=s[p],E=r[p],N=E!==A,k=h?A:E,$=N?U.convertAndGetValue(B,k,E):B;if("onChange"in t){const{onChange:X}=t,Y={...S,target:{...S.target,value:String($),rowIndex:c,cellIndex:C,unit:k}};X(Y)}}}}return t})})):[];return{convertedHeaders:u,convertedRows:o}},M=({table:l,unitConfig:i,convertBackToStorageUnit:r=!0,enableCosmeticRounding:s=!0,enableDisplayRounding:a=!0})=>{const{rows:h,headers:g,...y}=l,{storageUnits:u,preferredUnits:o}=ie(i),d=ne(o),[c,t]=v.useState(o),C=({unitKey:m,value:b})=>{t({...c,[m]:b});const e=i.find(f=>f.unitKey===m);e&&typeof e.onChange=="function"&&e.onChange({oldUnit:c[m],newUnit:b,unitKey:m})},p=m=>re({headers:g,rows:h,selectedUnits:m,storageUnits:u,onChangeUnit:C,convertBackToStorageUnit:r,enableCosmeticRounding:s,enableDisplayRounding:a}),T=p(c),[w,j]=v.useState(T);return v.useEffect(()=>{!te.isEqual(o,d)&&(Object.keys(o).forEach(b=>{const e=d==null?void 0:d[b],f=o[b];e!==f&&C({unitKey:b,value:f})}),j(p(o)))},[i]),v.useEffect(()=>{j(p(c))},[l,c]),n.jsx(ae,{table:{...y,headers:w.convertedHeaders,rows:w.convertedRows}})};M.__docgenInfo={description:"",methods:[],displayName:"UnitTable",props:{table:{required:!0,tsType:{name:"IUnitTable"},description:""},unitConfig:{required:!0,tsType:{name:"Array",elements:[{name:"IUnitConfigItem"}],raw:"IUnitConfigItem[]"},description:""},convertBackToStorageUnit:{required:!1,tsType:{name:"boolean"},description:"",defaultValue:{value:"true",computed:!1}},enableCosmeticRounding:{required:!1,tsType:{name:"boolean"},description:"",defaultValue:{value:"true",computed:!1}},enableDisplayRounding:{required:!1,tsType:{name:"boolean"},description:"",defaultValue:{value:"true",computed:!1}}},composes:["Omit"]};const ct={title:"Basic/UnitTable",args:{}},oe=!0,le=!0,se=!0,ue=!1,H="m",J="C",de=3,ce=(l,i,r)=>{const s=[i,i,r],a=[...Array(l)].map((h,g)=>{const y=g,u=g+1.25,o=4+g*.25;return[String(y),String(u),String(o)]});return[s,...a]},pe=ce(de,H,J),ge=({reduxTable:l,value:i,unit:r,rowIndex:s,cellIndex:a})=>z(l,h=>{const g=h[0][a],y=(u,o)=>o===0;return h.forEach((u,o)=>{if(y(u,o)){u[a]=r;return}if(o===s+1){u[a]=String(i);return}const d=U.convertAndGetValue(u[a],r,g);u[a]=String(d)}),h}),me=({reduxTable:l,value:i,rowIndex:r,cellIndex:s})=>z(l,a=>{a[r+1][s]=i}),V=()=>{var m,b;const[l,i]=v.useState(H),[r,s]=v.useState(J),[a,h]=v.useState(pe),[g,y]=v.useState(oe),[u,o]=v.useState(se),[d,c]=v.useState(le),[t,C]=v.useState(ue),[p,T]=v.useState(H),w=e=>{const{rowIndex:f,cellIndex:x,value:D,unit:R}=e.target,S=t?ge({reduxTable:a,value:D,unit:R,rowIndex:f,cellIndex:x}):me({reduxTable:a,value:D,rowIndex:f,cellIndex:x});h(S)},j=a.reduce((e,f,x)=>(x===0?e.headers=[{cells:[{value:"From"},{value:"To"},{value:"Temperature"}]},{cells:[{type:"AutoUnit",unitKey:"length"},{type:"AutoUnit",unitKey:"length"},{type:"AutoUnit",unitKey:"temperature",testId:"table-unit-selector-3"}]}]:e.rows=e.rows.concat({cells:f.map((D,R)=>{const S=x===1&&R===1;return{value:D,type:S?"Text":"NumberInput",unitKey:R===2?"temperature":"length",onChange:w,roundDisplayValue:x===3&&R===2?k=>U.roundByMagnitude(k,2):null,formatDisplayValue:S?k=>`T* ${k}`:null,autoUnit:!0}})}),e),{headers:[],rows:[]});return n.jsxs(Z,{columns:"1fr 1fr",gap:!0,children:[n.jsxs(F,{heading:n.jsx(W,{children:"Settings"}),children:[n.jsx(L,{label:"Convert back to storage unit:",labelLeft:!0,labelWidth:200,children:n.jsx(I,{checked:g,onChange:e=>y(e.target.checked)})}),n.jsx(L,{label:"Enable display rounding:",labelLeft:!0,labelWidth:200,children:n.jsx(I,{checked:u,onChange:e=>o(e.target.checked)})}),n.jsx(L,{label:"Enable cosmetic rounding:",labelLeft:!0,labelWidth:200,children:n.jsx(I,{checked:d,onChange:e=>c(e.target.checked)})}),n.jsx(L,{label:"Convert whole table:",labelLeft:!0,labelWidth:200,children:n.jsx(I,{checked:t,onChange:e=>C(e.target.checked)})})]}),n.jsxs(F,{heading:n.jsx(W,{children:"Unit template"}),children:[n.jsx(L,{label:"Length unit:",labelLeft:!0,labelWidth:120,children:n.jsx(P,{options:(m=U.getUnitsForQuantity("length"))==null?void 0:m.map(e=>({value:e,label:U.label(e)})),value:{value:l},onChange:e=>i(e.target.value),width:"100px"})}),n.jsx(L,{label:"Temperature unit:",labelLeft:!0,labelWidth:120,children:n.jsx(P,{options:(b=U.getUnitsForQuantity("temperature"))==null?void 0:b.map(e=>({value:e,label:U.label(e)})),value:{value:r},onChange:e=>s(e.target.value),width:"100px"})})]}),n.jsx(F,{heading:n.jsx(W,{children:"Storage State (Redux)"}),children:n.jsx("pre",{children:n.jsx("code",{children:JSON.stringify(a,null,2)})})}),n.jsxs(F,{heading:n.jsx(W,{children:"UnitTable"}),children:[n.jsx(M,{table:j,unitConfig:[{unitKey:"length",storageUnit:a[0][0],preferredUnit:l,onChange:({newUnit:e})=>T(e)},{unitKey:"temperature",storageUnit:a[0][2],preferredUnit:r}],convertBackToStorageUnit:g,enableDisplayRounding:u,enableCosmeticRounding:d}),n.jsx(ee,{height:20}),n.jsx(L,{label:"Displayed length unit:",labelLeft:!0,labelWidth:150,children:p})]})]})};V.__docgenInfo={description:"",methods:[],displayName:"UnitTablePrototype"};var K,G,O,q,Q;V.parameters={...V.parameters,docs:{...(K=V.parameters)==null?void 0:K.docs,source:{originalSource:`() => {
2
- const [preferredLengthUnit, setPreferredLengthUnit] = useState(initialLengthUnit);
3
- const [preferredTemperatureUnit, setPreferredTemperatureUnit] = useState(initialTemperatureUnit);
4
- const [reduxTable, setReduxTable] = useState<TTable>(initialTable);
5
- const [convertBackToStorageUnit, setConvertBackToStorageUnit] = useState(initialConvertBackToStorageUnit);
6
- const [enableDisplayRounding, setEnableDisplayRounding] = useState(initialEnableDisplayRounding);
7
- const [enableCosmeticRounding, setEnableCosmeticRounding] = useState(initialEnableCosmeticRounding);
8
- const [convertWholeTable, setConvertWholeTable] = useState(initialConvertWholeTable);
9
- const [displayedLengthUnit, setDisplayedLengthUnit] = useState(initialLengthUnit);
10
-
11
- /*********************************************************************************************************************
12
- Cell onChange handler
13
- *********************************************************************************************************************/
14
- const onUpdateCell = (evt: IUnitTableOnChangeEvent) => {
15
- const {
16
- rowIndex,
17
- cellIndex,
18
- value,
19
- unit
20
- } = evt.target;
21
- const nextTable = convertWholeTable ? convertStorageTable({
22
- reduxTable,
23
- value,
24
- unit,
25
- rowIndex,
26
- cellIndex
27
- }) : updateCell({
28
- reduxTable,
29
- value,
30
- rowIndex,
31
- cellIndex
32
- });
33
- setReduxTable(nextTable);
34
- };
35
-
36
- /*********************************************************************************************************************
37
- Construct table view data (same as old Table component, with a new props)
38
- *********************************************************************************************************************/
39
- const tableViewData = reduxTable.reduce((acc, row, rowIndex) => {
40
- if (rowIndex === 0) {
41
- acc.headers = [{
42
- cells: [{
43
- value: 'From'
44
- }, {
45
- value: 'To'
46
- }, {
47
- value: 'Temperature'
48
- }]
49
- }, {
50
- cells: [{
51
- type: 'AutoUnit',
52
- unitKey: 'length'
53
- }, {
54
- type: 'AutoUnit',
55
- unitKey: 'length'
56
- }, {
57
- type: 'AutoUnit',
58
- unitKey: 'temperature',
59
- testId: 'table-unit-selector-3'
60
- }]
61
- }];
62
- } else {
63
- acc.rows = acc.rows.concat({
64
- cells: row.map((cell, cellIndex) => {
65
- const specialCell = rowIndex === 1 && cellIndex === 1;
66
- const type = specialCell ? 'Text' : 'NumberInput';
67
- const formatDisplayValue = specialCell ? (value: number | string) => \`T* \${value}\` : null;
68
- const customDisplayRounding = rowIndex === 3 && cellIndex === 2 ? (value: TStringNumberNull) => roundByMagnitude(value, 2) : null;
69
- const value = cell;
70
- return {
71
- value,
72
- type,
73
- unitKey: cellIndex === 2 ? 'temperature' : 'length',
74
- onChange: onUpdateCell,
75
- roundDisplayValue: customDisplayRounding,
76
- // optionally customize the display rounding of specific columns/cells
77
- formatDisplayValue,
78
- // optionally extend/customize the display formatting of specific columns/cells
79
- autoUnit: true
80
- };
81
- })
82
- });
83
- }
84
- return acc;
85
- }, {
86
- headers: ([] as any[]),
87
- rows: ([] as IUnitTableRow[])
88
- });
89
- return <Grid columns="1fr 1fr" gap>
90
- <Card heading={<Heading>Settings</Heading>}>
91
- <Field label="Convert back to storage unit:" labelLeft labelWidth={200}>
92
- <Toggle checked={convertBackToStorageUnit} onChange={evt => setConvertBackToStorageUnit(evt.target.checked)} />
93
- </Field>
94
- <Field label="Enable display rounding:" labelLeft labelWidth={200}>
95
- <Toggle checked={enableDisplayRounding} onChange={evt => setEnableDisplayRounding(evt.target.checked)} />
96
- </Field>
97
- <Field label="Enable cosmetic rounding:" labelLeft labelWidth={200}>
98
- <Toggle checked={enableCosmeticRounding} onChange={evt => setEnableCosmeticRounding(evt.target.checked)} />
99
- </Field>
100
- <Field label="Convert whole table:" labelLeft labelWidth={200}>
101
- <Toggle checked={convertWholeTable} onChange={evt => setConvertWholeTable(evt.target.checked)} />
102
- </Field>
103
- </Card>
104
- <Card heading={<Heading>Unit template</Heading>}>
105
- <Field label="Length unit:" labelLeft labelWidth={120}>
106
- <Select options={getUnitsForQuantity('length')?.map(unit => ({
107
- value: unit,
108
- label: label(unit)
109
- }))} value={{
110
- value: preferredLengthUnit
111
- }} onChange={evt => setPreferredLengthUnit(evt.target.value)} width="100px" />
112
- </Field>
113
- <Field label="Temperature unit:" labelLeft labelWidth={120}>
114
- <Select options={getUnitsForQuantity('temperature')?.map(unit => ({
115
- value: unit,
116
- label: label(unit)
117
- }))} value={{
118
- value: preferredTemperatureUnit
119
- }} onChange={evt => setPreferredTemperatureUnit(evt.target.value)} width="100px" />
120
- </Field>
121
- </Card>
122
- <Card heading={<Heading>Storage State (Redux)</Heading>}>
123
- <pre>
124
- <code>{JSON.stringify(reduxTable, null, 2)}</code>
125
- </pre>
126
- </Card>
127
- <Card heading={<Heading>UnitTable</Heading>}>
128
- <UnitTable table={tableViewData}
129
- //New props:
130
- unitConfig={[{
131
- unitKey: 'length',
132
- storageUnit: reduxTable[0][0],
133
- preferredUnit: preferredLengthUnit,
134
- onChange: ({
135
- newUnit
136
- }) => setDisplayedLengthUnit(newUnit)
137
- }, {
138
- unitKey: 'temperature',
139
- storageUnit: reduxTable[0][2],
140
- preferredUnit: preferredTemperatureUnit
141
- }]}
142
- //Most tables should just use the default values here (true):
143
- convertBackToStorageUnit={convertBackToStorageUnit} enableDisplayRounding={enableDisplayRounding} enableCosmeticRounding={enableCosmeticRounding} />
144
- <Spacer height={20} />
145
- <Field label="Displayed length unit:" labelLeft labelWidth={150}>
146
- {displayedLengthUnit}
147
- </Field>
148
- </Card>
149
- </Grid>;
150
- }`,...(O=(G=V.parameters)==null?void 0:G.docs)==null?void 0:O.source},description:{story:"Story",...(Q=(q=V.parameters)==null?void 0:q.docs)==null?void 0:Q.description}}};const pt=["UnitTablePrototype"];export{V as UnitTablePrototype,pt as __namedExportsOrder,ct as default};