@parca/profile 0.16.116 → 0.16.118

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 (93) hide show
  1. package/CHANGELOG.md +10 -0
  2. package/dist/Callgraph/index.js +4 -4
  3. package/dist/Callgraph/utils.d.ts +1 -1
  4. package/dist/GraphTooltip/index.d.ts +1 -1
  5. package/dist/GraphTooltip/index.js +2 -2
  6. package/dist/MatchersInput/SuggestionItem.js +1 -1
  7. package/dist/MatchersInput/SuggestionsList.js +1 -1
  8. package/dist/MatchersInput/index.d.ts +1 -1
  9. package/dist/MatchersInput/index.js +2 -2
  10. package/dist/MetricsGraph/MetricsTooltip/index.js +1 -1
  11. package/dist/MetricsGraph/index.d.ts +1 -1
  12. package/dist/MetricsGraph/index.js +2 -3
  13. package/dist/ProfileExplorer/ProfileExplorerCompare.d.ts +1 -1
  14. package/dist/ProfileExplorer/ProfileExplorerSingle.d.ts +1 -1
  15. package/dist/ProfileExplorer/ProfileExplorerSingle.js +1 -1
  16. package/dist/ProfileExplorer/index.js +5 -5
  17. package/dist/ProfileIcicleGraph/IcicleGraph/ColorStackLegend.js +3 -3
  18. package/dist/ProfileIcicleGraph/IcicleGraph/IcicleGraphNodes.d.ts +1 -1
  19. package/dist/ProfileIcicleGraph/IcicleGraph/IcicleGraphNodes.js +3 -3
  20. package/dist/ProfileIcicleGraph/IcicleGraph/index.d.ts +1 -1
  21. package/dist/ProfileIcicleGraph/IcicleGraph/index.js +7 -7
  22. package/dist/ProfileIcicleGraph/IcicleGraph/useColoredGraph.js +2 -2
  23. package/dist/ProfileIcicleGraph/IcicleGraph/useNodeColor.js +1 -1
  24. package/dist/ProfileIcicleGraph/IcicleGraph/utils.d.ts +2 -2
  25. package/dist/ProfileIcicleGraph/IcicleGraph/utils.js +1 -1
  26. package/dist/ProfileIcicleGraph/index.d.ts +1 -1
  27. package/dist/ProfileIcicleGraph/index.js +14 -2
  28. package/dist/ProfileMetricsGraph/index.d.ts +2 -2
  29. package/dist/ProfileMetricsGraph/index.js +4 -4
  30. package/dist/ProfileSelector/index.d.ts +1 -1
  31. package/dist/ProfileSelector/index.js +6 -6
  32. package/dist/ProfileSource.d.ts +1 -1
  33. package/dist/ProfileSource.js +2 -2
  34. package/dist/ProfileTypeSelector/index.d.ts +1 -1
  35. package/dist/ProfileView/FilterByFunctionButton.js +2 -2
  36. package/dist/ProfileView/ViewSelector.js +12 -0
  37. package/dist/ProfileView/index.d.ts +1 -2
  38. package/dist/ProfileView/index.js +9 -10
  39. package/dist/ProfileViewWithData.d.ts +1 -1
  40. package/dist/ProfileViewWithData.js +3 -3
  41. package/dist/TopTable/index.d.ts +2 -3
  42. package/dist/TopTable/index.js +2 -3
  43. package/dist/components/DiffLegend.js +2 -2
  44. package/dist/components/ProfileShareButton/ResultBox.js +2 -2
  45. package/dist/components/ProfileShareButton/index.js +1 -1
  46. package/dist/index.d.ts +1 -1
  47. package/dist/styles.css +1 -1
  48. package/dist/useQuery.d.ts +1 -1
  49. package/dist/utils.d.ts +1 -1
  50. package/package.json +8 -8
  51. package/src/Callgraph/index.tsx +9 -7
  52. package/src/Callgraph/utils.ts +3 -1
  53. package/src/GraphTooltip/index.tsx +7 -5
  54. package/src/MatchersInput/SuggestionItem.tsx +2 -1
  55. package/src/MatchersInput/SuggestionsList.tsx +4 -1
  56. package/src/MatchersInput/index.tsx +4 -3
  57. package/src/MetricsGraph/MetricsTooltip/index.tsx +4 -3
  58. package/src/MetricsGraph/index.tsx +10 -5
  59. package/src/ProfileExplorer/ProfileExplorerCompare.tsx +2 -2
  60. package/src/ProfileExplorer/ProfileExplorerSingle.tsx +3 -3
  61. package/src/ProfileExplorer/index.tsx +9 -6
  62. package/src/ProfileIcicleGraph/IcicleGraph/ColorStackLegend.tsx +6 -4
  63. package/src/ProfileIcicleGraph/IcicleGraph/IcicleGraphNodes.tsx +7 -5
  64. package/src/ProfileIcicleGraph/IcicleGraph/index.tsx +8 -9
  65. package/src/ProfileIcicleGraph/IcicleGraph/useColoredGraph.ts +12 -4
  66. package/src/ProfileIcicleGraph/IcicleGraph/useNodeColor.ts +3 -1
  67. package/src/ProfileIcicleGraph/IcicleGraph/utils.ts +4 -4
  68. package/src/ProfileIcicleGraph/ProfileIcicleGraph.stories.mdx +5 -3
  69. package/src/ProfileIcicleGraph/index.tsx +3 -3
  70. package/src/ProfileMetricsGraph/index.tsx +8 -5
  71. package/src/ProfileSelector/CompareButton.tsx +2 -0
  72. package/src/ProfileSelector/index.tsx +14 -11
  73. package/src/ProfileSource.tsx +4 -4
  74. package/src/ProfileTypeSelector/index.tsx +4 -3
  75. package/src/ProfileView/FilterByFunctionButton.tsx +4 -2
  76. package/src/ProfileView/ViewSelector.tsx +1 -2
  77. package/src/ProfileView/index.tsx +17 -13
  78. package/src/ProfileViewWithData.tsx +8 -7
  79. package/src/TopTable/index.tsx +10 -7
  80. package/src/__tests__/suffix_params.test.ts +1 -1
  81. package/src/components/DiffLegend.tsx +4 -2
  82. package/src/components/ProfileShareButton/ResultBox.tsx +4 -2
  83. package/src/components/ProfileShareButton/index.tsx +4 -1
  84. package/src/index.tsx +3 -1
  85. package/src/useGrpcQuery/index.ts +1 -1
  86. package/src/useQuery.tsx +2 -1
  87. package/src/utils.ts +2 -1
  88. package/dist/ProfileSVG.module.css +0 -3
  89. package/dist/ProfileView.styles.css +0 -3
  90. package/dist/TopTable.styles.css +0 -7
  91. package/src/ProfileSVG.module.css +0 -3
  92. package/src/ProfileView.styles.css +0 -3
  93. package/src/TopTable.styles.css +0 -7
@@ -23,10 +23,10 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
23
23
  // See the License for the specific language governing permissions and
24
24
  // limitations under the License.
25
25
  import { useState } from 'react';
26
- import cx from 'classnames';
27
26
  import { Icon } from '@iconify/react';
28
- import { Button } from '@parca/components';
27
+ import cx from 'classnames';
29
28
  import { CopyToClipboard } from 'react-copy-to-clipboard';
29
+ import { Button } from '@parca/components';
30
30
  var timeoutHandle = null;
31
31
  var ResultBox = function (_a) {
32
32
  var _b;
@@ -59,8 +59,8 @@ import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-run
59
59
  // See the License for the specific language governing permissions and
60
60
  // limitations under the License.
61
61
  import { useState } from 'react';
62
- import { Button, Modal, useGrpcMetadata } from '@parca/components';
63
62
  import { Icon } from '@iconify/react';
63
+ import { Button, Modal, useGrpcMetadata } from '@parca/components';
64
64
  import ResultBox from './ResultBox';
65
65
  var ProfileShareModal = function (_a) {
66
66
  var isOpen = _a.isOpen, closeModal = _a.closeModal, queryRequest = _a.queryRequest, queryClient = _a.queryClient;
package/dist/index.d.ts CHANGED
@@ -1,9 +1,9 @@
1
1
  /// <reference types="react" />
2
+ import { QueryServiceClient } from '@parca/client';
2
3
  import type { Props as CallgraphProps } from '@parca/profile/src/Callgraph';
3
4
  import ProfileExplorer from './ProfileExplorer';
4
5
  import ProfileTypeSelector from './ProfileTypeSelector';
5
6
  import type { FlamegraphData, TopTableData } from './ProfileView';
6
- import { QueryServiceClient } from '@parca/client';
7
7
  export * from './ProfileIcicleGraph/IcicleGraph';
8
8
  export * from './ProfileIcicleGraph';
9
9
  export * from './ProfileSource';
package/dist/styles.css CHANGED
@@ -1 +1 @@
1
- /*! tailwindcss v3.2.4 | MIT License | https://tailwindcss.com*/*,:after,:before{border:0 solid #e5e7eb;box-sizing:border-box}:after,:before{--tw-content:""}html{-webkit-text-size-adjust:100%;font-feature-settings:normal;font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;line-height:1.5;-moz-tab-size:4;-o-tab-size:4;tab-size:4}body{line-height:inherit;margin:0}hr{border-top-width:1px;color:inherit;height:0}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,pre,samp{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{border-collapse:collapse;border-color:inherit;text-indent:0}button,input,optgroup,select,textarea{color:inherit;font-family:inherit;font-size:100%;font-weight:inherit;line-height:inherit;margin:0;padding:0}button,select{text-transform:none}[type=button],[type=reset],[type=submit],button{-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dd,dl,figure,h1,h2,h3,h4,h5,h6,hr,p,pre{margin:0}fieldset{margin:0}fieldset,legend{padding:0}menu,ol,ul{list-style:none;margin:0;padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{color:#9ca3af;opacity:1}input::placeholder,textarea::placeholder{color:#9ca3af;opacity:1}[role=button],button{cursor:pointer}:disabled{cursor:default}audio,canvas,embed,iframe,img,object,svg,video{display:block;vertical-align:middle}img,video{height:auto;max-width:100%}[hidden]{display:none}*,:after,:before{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }::backdrop{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }.container{width:100%}@media (min-width:640px){.container{max-width:640px}}@media (min-width:768px){.container{max-width:768px}}@media (min-width:1024px){.container{max-width:1024px}}@media (min-width:1280px){.container{max-width:1280px}}@media (min-width:1536px){.container{max-width:1536px}}.visible{visibility:visible}.invisible{visibility:hidden}.absolute{position:absolute}.relative{position:relative}.left-\[25px\]{left:25px}.left-0{left:0}.top-\[-46px\]{top:-46px}.right-0{right:0}.top-\[-45px\]{top:-45px}.top-\[-48px\]{top:-48px}.top-\[-69px\]{top:-69px}.top-\[-54px\]{top:-54px}.top-\[-70px\]{top:-70px}.z-50{z-index:50}.z-10{z-index:10}.m-auto{margin:auto}.m-0{margin:0}.m-2{margin:.5rem}.my-2{margin-bottom:.5rem;margin-top:.5rem}.my-20{margin-bottom:5rem;margin-top:5rem}.mx-2{margin-left:.5rem;margin-right:.5rem}.my-6{margin-bottom:1.5rem;margin-top:1.5rem}.ml-2{margin-left:.5rem}.mr-6{margin-right:1.5rem}.mt-2{margin-top:.5rem}.mt-1{margin-top:.25rem}.ml-auto{margin-left:auto}.mb-2{margin-bottom:.5rem}.mr-3{margin-right:.75rem}.mr-1{margin-right:.25rem}.mt-3{margin-top:.75rem}.mt-4{margin-top:1rem}.mt-8{margin-top:2rem}.block{display:block}.inline-block{display:inline-block}.flex{display:flex}.table{display:table}.grid{display:grid}.h-36{height:9rem}.h-1{height:.25rem}.h-\[80vh\]{height:80vh}.h-4{height:1rem}.max-h-\[400px\]{max-height:400px}.w-auto{width:auto}.w-1\/5{width:20%}.w-4\/5{width:80%}.w-full{width:100%}.w-40{width:10rem}.w-2\/5{width:40%}.w-1\/2{width:50%}.w-8{width:2rem}.w-1\/4{width:25%}.w-3\/4{width:75%}.w-4{width:1rem}.w-16{width:4rem}.w-fit{width:-moz-fit-content;width:fit-content}.w-\[420px\]{width:420px}.min-w-\[300px\]{min-width:300px}.max-w-md{max-width:28rem}.flex-1{flex:1 1 0%}.flex-grow{flex-grow:1}.table-auto{table-layout:auto}.table-fixed{table-layout:fixed}.translate-y-1{--tw-translate-y:0.25rem}.translate-y-0,.translate-y-1{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.translate-y-0{--tw-translate-y:0px}.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.cursor-pointer{cursor:pointer}.cursor-default{cursor:default}.cursor-not-allowed{cursor:not-allowed}.select-none{-webkit-user-select:none;-moz-user-select:none;user-select:none}.grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.grid-cols-1{grid-template-columns:repeat(1,minmax(0,1fr))}.flex-row{flex-direction:row}.flex-wrap{flex-wrap:wrap}.items-center{align-items:center}.justify-start{justify-content:flex-start}.justify-end{justify-content:flex-end}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-2{gap:.5rem}.gap-1{gap:.25rem}.space-x-2>:not([hidden])~:not([hidden]){--tw-space-x-reverse:0;margin-left:calc(.5rem*(1 - var(--tw-space-x-reverse)));margin-right:calc(.5rem*var(--tw-space-x-reverse))}.space-y-1>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-bottom:calc(.25rem*var(--tw-space-y-reverse));margin-top:calc(.25rem*(1 - var(--tw-space-y-reverse)))}.space-x-4>:not([hidden])~:not([hidden]){--tw-space-x-reverse:0;margin-left:calc(1rem*(1 - var(--tw-space-x-reverse)));margin-right:calc(1rem*var(--tw-space-x-reverse))}.space-x-1>:not([hidden])~:not([hidden]){--tw-space-x-reverse:0;margin-left:calc(.25rem*(1 - var(--tw-space-x-reverse)));margin-right:calc(.25rem*var(--tw-space-x-reverse))}.overflow-auto{overflow:auto}.overflow-hidden{overflow:hidden}.overflow-scroll{overflow:scroll}.text-ellipsis{text-overflow:ellipsis}.whitespace-nowrap{white-space:nowrap}.break-all{word-break:break-all}.rounded{border-radius:.25rem}.rounded-lg{border-radius:.5rem}.rounded-md{border-radius:.375rem}.rounded-none{border-radius:0}.rounded-l{border-bottom-left-radius:.25rem;border-top-left-radius:.25rem}.rounded-r{border-bottom-right-radius:.25rem;border-top-right-radius:.25rem}.border{border-width:1px}.border-r-0{border-right-width:0}.border-l-0{border-left-width:0}.border-gray-300{--tw-border-opacity:1;border-color:rgb(209 213 219/var(--tw-border-opacity))}.border-red-400{--tw-border-opacity:1;border-color:rgb(248 113 113/var(--tw-border-opacity))}.bg-gray-50{--tw-bg-opacity:1;background-color:rgb(249 250 251/var(--tw-bg-opacity))}.bg-indigo-600{--tw-bg-opacity:1;background-color:rgb(79 70 229/var(--tw-bg-opacity))}.bg-red-100{--tw-bg-opacity:1;background-color:rgb(254 226 226/var(--tw-bg-opacity))}.bg-black{--tw-bg-opacity:1;background-color:rgb(0 0 0/var(--tw-bg-opacity))}.bg-gray-200{--tw-bg-opacity:1;background-color:rgb(229 231 235/var(--tw-bg-opacity))}.bg-white{--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity))}.bg-gray-800{--tw-bg-opacity:1;background-color:rgb(31 41 55/var(--tw-bg-opacity))}.bg-inherit{background-color:inherit}.fill-transparent{fill:transparent}.fill-current{fill:currentColor}.p-3{padding:.75rem}.p-10{padding:2.5rem}.p-4{padding:1rem}.p-1{padding:.25rem}.py-2{padding-bottom:.5rem;padding-top:.5rem}.px-2{padding-left:.5rem;padding-right:.5rem}.px-4{padding-left:1rem;padding-right:1rem}.py-3{padding-bottom:.75rem;padding-top:.75rem}.py-20{padding-bottom:5rem;padding-top:5rem}.px-3{padding-left:.75rem;padding-right:.75rem}.py-1{padding-bottom:.25rem;padding-top:.25rem}.px-1{padding-left:.25rem;padding-right:.25rem}.pl-3{padding-left:.75rem}.pr-9{padding-right:2.25rem}.pt-2{padding-top:.5rem}.pb-4{padding-bottom:1rem}.pr-2{padding-right:.5rem}.pl-2{padding-left:.5rem}.pb-2{padding-bottom:.5rem}.text-left{text-align:left}.text-center{text-align:center}.font-mono{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.text-xs{font-size:.75rem;line-height:1rem}.text-base{font-size:1rem;line-height:1.5rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xl{font-size:1.25rem;line-height:1.75rem}.font-semibold{font-weight:600}.font-bold{font-weight:700}.text-gray-700{--tw-text-opacity:1;color:rgb(55 65 81/var(--tw-text-opacity))}.text-gray-500{--tw-text-opacity:1;color:rgb(107 114 128/var(--tw-text-opacity))}.text-white{--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity))}.text-red-700{--tw-text-opacity:1;color:rgb(185 28 28/var(--tw-text-opacity))}.text-black{--tw-text-opacity:1;color:rgb(0 0 0/var(--tw-text-opacity))}.\!text-indigo-600{--tw-text-opacity:1!important;color:rgb(79 70 229/var(--tw-text-opacity))!important}.opacity-90{opacity:.9}.opacity-100{opacity:1}.opacity-0{opacity:0}.opacity-50{opacity:.5}.shadow-lg{--tw-shadow:0 10px 15px -3px rgba(0,0,0,.1),0 4px 6px -4px rgba(0,0,0,.1);--tw-shadow-colored:0 10px 15px -3px var(--tw-shadow-color),0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.outline-none{outline:2px solid transparent;outline-offset:2px}.ring-1{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}.ring-black{--tw-ring-opacity:1;--tw-ring-color:rgb(0 0 0/var(--tw-ring-opacity))}.ring-opacity-5{--tw-ring-opacity:0.05}.blur{--tw-blur:blur(8px)}.blur,.invert{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.invert{--tw-invert:invert(100%)}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.transition{transition-duration:.15s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,-webkit-backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter,-webkit-backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1)}.duration-100{transition-duration:.1s}.duration-200{transition-duration:.2s}.duration-150{transition-duration:.15s}.ease-in{transition-timing-function:cubic-bezier(.4,0,1,1)}.ease-out{transition-timing-function:cubic-bezier(0,0,.2,1)}.focus\:outline-none:focus{outline:2px solid transparent;outline-offset:2px}.focus\:ring-indigo-800:focus{--tw-ring-opacity:1;--tw-ring-color:rgb(55 48 163/var(--tw-ring-opacity))}[class~=theme-dark] .dark\:border-gray-500{--tw-border-opacity:1;border-color:rgb(107 114 128/var(--tw-border-opacity))}[class~=theme-dark] .dark\:bg-gray-900{--tw-bg-opacity:1;background-color:rgb(17 24 39/var(--tw-bg-opacity))}[class~=theme-dark] .dark\:bg-gray-700{--tw-bg-opacity:1;background-color:rgb(55 65 81/var(--tw-bg-opacity))}[class~=theme-dark] .dark\:bg-gray-800{--tw-bg-opacity:1;background-color:rgb(31 41 55/var(--tw-bg-opacity))}[class~=theme-dark] .dark\:text-gray-300{--tw-text-opacity:1;color:rgb(209 213 219/var(--tw-text-opacity))}[class~=theme-dark] .dark\:text-gray-50{--tw-text-opacity:1;color:rgb(249 250 251/var(--tw-text-opacity))}[class~=theme-dark] .dark\:text-gray-400{--tw-text-opacity:1;color:rgb(156 163 175/var(--tw-text-opacity))}[class~=theme-dark] .dark\:\!text-indigo-400{--tw-text-opacity:1!important;color:rgb(129 140 248/var(--tw-text-opacity))!important}@media (min-width:640px){.sm\:inline{display:inline}.sm\:text-sm{font-size:.875rem;line-height:1.25rem}}
1
+ /*! tailwindcss v3.2.6 | MIT License | https://tailwindcss.com*/*,:after,:before{border:0 solid #e5e7eb;box-sizing:border-box}:after,:before{--tw-content:""}html{-webkit-text-size-adjust:100%;font-feature-settings:normal;font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;line-height:1.5;-moz-tab-size:4;-o-tab-size:4;tab-size:4}body{line-height:inherit;margin:0}hr{border-top-width:1px;color:inherit;height:0}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,pre,samp{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{border-collapse:collapse;border-color:inherit;text-indent:0}button,input,optgroup,select,textarea{color:inherit;font-family:inherit;font-size:100%;font-weight:inherit;line-height:inherit;margin:0;padding:0}button,select{text-transform:none}[type=button],[type=reset],[type=submit],button{-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dd,dl,figure,h1,h2,h3,h4,h5,h6,hr,p,pre{margin:0}fieldset{margin:0}fieldset,legend{padding:0}menu,ol,ul{list-style:none;margin:0;padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{color:#9ca3af;opacity:1}input::placeholder,textarea::placeholder{color:#9ca3af;opacity:1}[role=button],button{cursor:pointer}:disabled{cursor:default}audio,canvas,embed,iframe,img,object,svg,video{display:block;vertical-align:middle}img,video{height:auto;max-width:100%}[hidden]{display:none}*,:after,:before{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }::backdrop{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }.container{width:100%}@media (min-width:640px){.container{max-width:640px}}@media (min-width:768px){.container{max-width:768px}}@media (min-width:1024px){.container{max-width:1024px}}@media (min-width:1280px){.container{max-width:1280px}}@media (min-width:1536px){.container{max-width:1536px}}.visible{visibility:visible}.invisible{visibility:hidden}.absolute{position:absolute}.relative{position:relative}.left-0{left:0}.left-\[25px\]{left:25px}.right-0{right:0}.top-\[-45px\]{top:-45px}.top-\[-46px\]{top:-46px}.top-\[-48px\]{top:-48px}.top-\[-54px\]{top:-54px}.top-\[-69px\]{top:-69px}.top-\[-70px\]{top:-70px}.z-10{z-index:10}.z-50{z-index:50}.m-0{margin:0}.m-2{margin:.5rem}.m-auto{margin:auto}.mx-2{margin-left:.5rem;margin-right:.5rem}.my-2{margin-bottom:.5rem;margin-top:.5rem}.my-20{margin-bottom:5rem;margin-top:5rem}.my-6{margin-bottom:1.5rem;margin-top:1.5rem}.mb-2{margin-bottom:.5rem}.ml-2{margin-left:.5rem}.ml-auto{margin-left:auto}.mr-1{margin-right:.25rem}.mr-3{margin-right:.75rem}.mr-6{margin-right:1.5rem}.mt-1{margin-top:.25rem}.mt-2{margin-top:.5rem}.mt-3{margin-top:.75rem}.mt-4{margin-top:1rem}.mt-8{margin-top:2rem}.block{display:block}.inline-block{display:inline-block}.flex{display:flex}.table{display:table}.grid{display:grid}.h-1{height:.25rem}.h-36{height:9rem}.h-4{height:1rem}.h-\[80vh\]{height:80vh}.max-h-\[400px\]{max-height:400px}.w-1\/2{width:50%}.w-1\/4{width:25%}.w-1\/5{width:20%}.w-16{width:4rem}.w-2\/5{width:40%}.w-3\/4{width:75%}.w-4{width:1rem}.w-4\/5{width:80%}.w-40{width:10rem}.w-8{width:2rem}.w-\[420px\]{width:420px}.w-auto{width:auto}.w-fit{width:-moz-fit-content;width:fit-content}.w-full{width:100%}.min-w-\[300px\]{min-width:300px}.max-w-md{max-width:28rem}.flex-1{flex:1 1 0%}.flex-grow{flex-grow:1}.table-auto{table-layout:auto}.table-fixed{table-layout:fixed}.translate-y-0{--tw-translate-y:0px}.translate-y-0,.translate-y-1{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.translate-y-1{--tw-translate-y:0.25rem}.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.cursor-default{cursor:default}.cursor-not-allowed{cursor:not-allowed}.cursor-pointer{cursor:pointer}.select-none{-webkit-user-select:none;-moz-user-select:none;user-select:none}.grid-cols-1{grid-template-columns:repeat(1,minmax(0,1fr))}.grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.flex-row{flex-direction:row}.flex-wrap{flex-wrap:wrap}.items-center{align-items:center}.justify-start{justify-content:flex-start}.justify-end{justify-content:flex-end}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-1{gap:.25rem}.gap-2{gap:.5rem}.space-x-1>:not([hidden])~:not([hidden]){--tw-space-x-reverse:0;margin-left:calc(.25rem*(1 - var(--tw-space-x-reverse)));margin-right:calc(.25rem*var(--tw-space-x-reverse))}.space-x-2>:not([hidden])~:not([hidden]){--tw-space-x-reverse:0;margin-left:calc(.5rem*(1 - var(--tw-space-x-reverse)));margin-right:calc(.5rem*var(--tw-space-x-reverse))}.space-x-4>:not([hidden])~:not([hidden]){--tw-space-x-reverse:0;margin-left:calc(1rem*(1 - var(--tw-space-x-reverse)));margin-right:calc(1rem*var(--tw-space-x-reverse))}.space-y-1>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-bottom:calc(.25rem*var(--tw-space-y-reverse));margin-top:calc(.25rem*(1 - var(--tw-space-y-reverse)))}.overflow-auto{overflow:auto}.overflow-hidden{overflow:hidden}.overflow-scroll{overflow:scroll}.text-ellipsis{text-overflow:ellipsis}.whitespace-nowrap{white-space:nowrap}.break-all{word-break:break-all}.rounded{border-radius:.25rem}.rounded-lg{border-radius:.5rem}.rounded-md{border-radius:.375rem}.rounded-none{border-radius:0}.rounded-l{border-bottom-left-radius:.25rem;border-top-left-radius:.25rem}.rounded-r{border-bottom-right-radius:.25rem;border-top-right-radius:.25rem}.border{border-width:1px}.border-l-0{border-left-width:0}.border-r-0{border-right-width:0}.border-gray-300{--tw-border-opacity:1;border-color:rgb(209 213 219/var(--tw-border-opacity))}.border-red-400{--tw-border-opacity:1;border-color:rgb(248 113 113/var(--tw-border-opacity))}.bg-black{--tw-bg-opacity:1;background-color:rgb(0 0 0/var(--tw-bg-opacity))}.bg-gray-200{--tw-bg-opacity:1;background-color:rgb(229 231 235/var(--tw-bg-opacity))}.bg-gray-50{--tw-bg-opacity:1;background-color:rgb(249 250 251/var(--tw-bg-opacity))}.bg-gray-800{--tw-bg-opacity:1;background-color:rgb(31 41 55/var(--tw-bg-opacity))}.bg-indigo-600{--tw-bg-opacity:1;background-color:rgb(79 70 229/var(--tw-bg-opacity))}.bg-inherit{background-color:inherit}.bg-red-100{--tw-bg-opacity:1;background-color:rgb(254 226 226/var(--tw-bg-opacity))}.bg-white{--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity))}.fill-current{fill:currentColor}.fill-transparent{fill:transparent}.p-1{padding:.25rem}.p-10{padding:2.5rem}.p-3{padding:.75rem}.p-4{padding:1rem}.px-1{padding-left:.25rem;padding-right:.25rem}.px-2{padding-left:.5rem;padding-right:.5rem}.px-3{padding-left:.75rem;padding-right:.75rem}.px-4{padding-left:1rem;padding-right:1rem}.py-1{padding-bottom:.25rem;padding-top:.25rem}.py-2{padding-bottom:.5rem;padding-top:.5rem}.py-20{padding-bottom:5rem;padding-top:5rem}.py-3{padding-bottom:.75rem;padding-top:.75rem}.pb-2{padding-bottom:.5rem}.pb-4{padding-bottom:1rem}.pl-2{padding-left:.5rem}.pl-3{padding-left:.75rem}.pr-2{padding-right:.5rem}.pr-9{padding-right:2.25rem}.pt-2{padding-top:.5rem}.text-left{text-align:left}.text-center{text-align:center}.font-mono{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.text-base{font-size:1rem;line-height:1.5rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xl{font-size:1.25rem;line-height:1.75rem}.text-xs{font-size:.75rem;line-height:1rem}.font-bold{font-weight:700}.font-semibold{font-weight:600}.\!text-indigo-600{--tw-text-opacity:1!important;color:rgb(79 70 229/var(--tw-text-opacity))!important}.text-black{--tw-text-opacity:1;color:rgb(0 0 0/var(--tw-text-opacity))}.text-gray-500{--tw-text-opacity:1;color:rgb(107 114 128/var(--tw-text-opacity))}.text-gray-700{--tw-text-opacity:1;color:rgb(55 65 81/var(--tw-text-opacity))}.text-red-700{--tw-text-opacity:1;color:rgb(185 28 28/var(--tw-text-opacity))}.text-white{--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity))}.opacity-0{opacity:0}.opacity-100{opacity:1}.opacity-50{opacity:.5}.opacity-90{opacity:.9}.shadow-lg{--tw-shadow:0 10px 15px -3px rgba(0,0,0,.1),0 4px 6px -4px rgba(0,0,0,.1);--tw-shadow-colored:0 10px 15px -3px var(--tw-shadow-color),0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.outline-none{outline:2px solid transparent;outline-offset:2px}.ring-1{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}.ring-black{--tw-ring-opacity:1;--tw-ring-color:rgb(0 0 0/var(--tw-ring-opacity))}.ring-opacity-5{--tw-ring-opacity:0.05}.blur{--tw-blur:blur(8px)}.blur,.invert{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.invert{--tw-invert:invert(100%)}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.transition{transition-duration:.15s;transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,-webkit-backdrop-filter;transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter,-webkit-backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1)}.duration-100{transition-duration:.1s}.duration-150{transition-duration:.15s}.duration-200{transition-duration:.2s}.ease-in{transition-timing-function:cubic-bezier(.4,0,1,1)}.ease-out{transition-timing-function:cubic-bezier(0,0,.2,1)}.focus\:outline-none:focus{outline:2px solid transparent;outline-offset:2px}.focus\:ring-indigo-800:focus{--tw-ring-opacity:1;--tw-ring-color:rgb(55 48 163/var(--tw-ring-opacity))}[class~=theme-dark] .dark\:border-gray-500{--tw-border-opacity:1;border-color:rgb(107 114 128/var(--tw-border-opacity))}[class~=theme-dark] .dark\:bg-gray-700{--tw-bg-opacity:1;background-color:rgb(55 65 81/var(--tw-bg-opacity))}[class~=theme-dark] .dark\:bg-gray-800{--tw-bg-opacity:1;background-color:rgb(31 41 55/var(--tw-bg-opacity))}[class~=theme-dark] .dark\:bg-gray-900{--tw-bg-opacity:1;background-color:rgb(17 24 39/var(--tw-bg-opacity))}[class~=theme-dark] .dark\:\!text-indigo-400{--tw-text-opacity:1!important;color:rgb(129 140 248/var(--tw-text-opacity))!important}[class~=theme-dark] .dark\:text-gray-300{--tw-text-opacity:1;color:rgb(209 213 219/var(--tw-text-opacity))}[class~=theme-dark] .dark\:text-gray-400{--tw-text-opacity:1;color:rgb(156 163 175/var(--tw-text-opacity))}[class~=theme-dark] .dark\:text-gray-50{--tw-text-opacity:1;color:rgb(249 250 251/var(--tw-text-opacity))}@media (min-width:640px){.sm\:inline{display:inline}.sm\:text-sm{font-size:.875rem;line-height:1.25rem}}
@@ -1,5 +1,5 @@
1
- import { QueryServiceClient, QueryResponse, QueryRequest_ReportType } from '@parca/client';
2
1
  import { RpcError } from '@protobuf-ts/runtime-rpc';
2
+ import { QueryRequest_ReportType, QueryResponse, QueryServiceClient } from '@parca/client';
3
3
  import { ProfileSource } from './ProfileSource';
4
4
  export interface IQueryResult {
5
5
  response: QueryResponse | null;
package/dist/utils.d.ts CHANGED
@@ -1,5 +1,5 @@
1
- import { QueryRequest, QueryServiceClient } from '@parca/client';
2
1
  import type { RpcMetadata } from '@protobuf-ts/runtime-rpc';
2
+ import { QueryRequest, QueryServiceClient } from '@parca/client';
3
3
  export declare const hexifyAddress: (address?: string) => string;
4
4
  export declare const downloadPprof: (request: QueryRequest, queryClient: QueryServiceClient, metadata: RpcMetadata) => Promise<Blob>;
5
5
  export declare const truncateString: (str: string, num: number) => string;
package/package.json CHANGED
@@ -1,14 +1,14 @@
1
1
  {
2
2
  "name": "@parca/profile",
3
- "version": "0.16.116",
3
+ "version": "0.16.118",
4
4
  "description": "Profile viewing libraries",
5
5
  "dependencies": {
6
6
  "@parca/client": "^0.16.63",
7
- "@parca/components": "^0.16.97",
8
- "@parca/dynamicsize": "^0.16.52",
9
- "@parca/functions": "^0.16.61",
10
- "@parca/parser": "^0.16.53",
11
- "@parca/store": "^0.16.57",
7
+ "@parca/components": "^0.16.99",
8
+ "@parca/dynamicsize": "^0.16.53",
9
+ "@parca/functions": "^0.16.62",
10
+ "@parca/parser": "^0.16.54",
11
+ "@parca/store": "^0.16.58",
12
12
  "@types/react-beautiful-dnd": "^13.1.3",
13
13
  "d3": "7.8.2",
14
14
  "d3-scale": "^4.0.2",
@@ -36,7 +36,7 @@
36
36
  "prepublish": "yarn build",
37
37
  "build": "tsc && yarn compile:styles",
38
38
  "watch": "tsc-watch --onSuccess 'yarn compile:styles'",
39
- "compile:styles": "tailwindcss -o dist/styles.css --minify && cp src/*.css ./dist/"
39
+ "compile:styles": "tailwindcss -o dist/styles.css --minify"
40
40
  },
41
41
  "keywords": [],
42
42
  "author": "",
@@ -45,5 +45,5 @@
45
45
  "access": "public",
46
46
  "registry": "https://registry.npmjs.org/"
47
47
  },
48
- "gitHead": "e9b6f88b6388b9b9889de093cd83939c79af8e6e"
48
+ "gitHead": "232661da5c7237631cbc9d55eefbab4a08ea6dd4"
49
49
  }
@@ -11,19 +11,21 @@
11
11
  // See the License for the specific language governing permissions and
12
12
  // limitations under the License.
13
13
 
14
- import {useState, useEffect, useRef} from 'react';
14
+ import {useEffect, useRef, useState} from 'react';
15
+
15
16
  import cx from 'classnames';
16
- import graphviz from 'graphviz-wasm';
17
17
  import * as d3 from 'd3';
18
- import {Stage, Layer, Rect, Arrow, Text, Label} from 'react-konva';
18
+ import graphviz from 'graphviz-wasm';
19
19
  import type {KonvaEventObject} from 'konva/lib/Node';
20
+ import {Arrow, Label, Layer, Rect, Stage, Text} from 'react-konva';
21
+
22
+ import {CallgraphEdge, CallgraphNode, Callgraph as CallgraphType} from '@parca/client';
20
23
  import {Button, useURLState} from '@parca/components';
21
- import {CallgraphNode, CallgraphEdge, Callgraph as CallgraphType} from '@parca/client';
22
- import {jsonToDot, getCurvePoints} from './utils';
23
- import type {HoveringNode} from '../GraphTooltip';
24
24
  import {isSearchMatch, selectQueryParam} from '@parca/functions';
25
- import Tooltip from '../GraphTooltip';
25
+
26
+ import Tooltip, {type HoveringNode} from '../GraphTooltip';
26
27
  import {DEFAULT_NODE_HEIGHT, GRAPH_MARGIN} from './constants';
28
+ import {getCurvePoints, jsonToDot} from './utils';
27
29
 
28
30
  interface NodeProps {
29
31
  node: INode;
@@ -12,7 +12,9 @@
12
12
  // limitations under the License.
13
13
 
14
14
  import * as d3 from 'd3';
15
- import {CallgraphNode, CallgraphEdge} from '@parca/client';
15
+
16
+ import {CallgraphEdge, CallgraphNode} from '@parca/client';
17
+
16
18
  import {DEFAULT_NODE_HEIGHT} from './constants';
17
19
 
18
20
  export const pixelsToInches = (pixels: number): number => pixels / 96;
@@ -11,19 +11,21 @@
11
11
  // See the License for the specific language governing permissions and
12
12
  // limitations under the License.
13
13
 
14
+ import {useEffect, useState} from 'react';
15
+
14
16
  import {CopyToClipboard} from 'react-copy-to-clipboard';
15
- import {useState, useEffect} from 'react';
16
17
  import {usePopper} from 'react-popper';
17
18
 
18
19
  import {CallgraphNode, FlamegraphNode, FlamegraphNodeMeta, FlamegraphRootNode} from '@parca/client';
19
- import {getLastItem, valueFormatter} from '@parca/functions';
20
- import {hexifyAddress, truncateString} from '../';
21
- import {useKeyDown} from '@parca/components';
22
20
  import {
23
- Function as ParcaFunction,
24
21
  Location,
25
22
  Mapping,
23
+ Function as ParcaFunction,
26
24
  } from '@parca/client/dist/parca/metastore/v1alpha1/metastore';
25
+ import {useKeyDown} from '@parca/components';
26
+ import {getLastItem, valueFormatter} from '@parca/functions';
27
+
28
+ import {hexifyAddress, truncateString} from '../';
27
29
 
28
30
  interface GraphTooltipProps {
29
31
  x: number;
@@ -11,9 +11,10 @@
11
11
  // See the License for the specific language governing permissions and
12
12
  // limitations under the License.
13
13
 
14
- import cx from 'classnames';
15
14
  import {useEffect, useRef} from 'react';
16
15
 
16
+ import cx from 'classnames';
17
+
17
18
  interface Props {
18
19
  isHighlighted: boolean;
19
20
  onHighlight: () => void;
@@ -12,11 +12,14 @@
12
12
  // limitations under the License.
13
13
 
14
14
  import {Fragment, useCallback, useEffect, useState} from 'react';
15
+
15
16
  import {Transition} from '@headlessui/react';
16
- import SuggestionItem from './SuggestionItem';
17
17
  import {usePopper} from 'react-popper';
18
+
18
19
  import {useParcaContext} from '@parca/components';
19
20
 
21
+ import SuggestionItem from './SuggestionItem';
22
+
20
23
  export class Suggestion {
21
24
  type: string;
22
25
  typeahead: string;
@@ -11,14 +11,15 @@
11
11
  // See the License for the specific language governing permissions and
12
12
  // limitations under the License.
13
13
 
14
- import React, {useState, useEffect, useMemo, useRef} from 'react';
15
- import TextareaAutosize from 'react-textarea-autosize';
14
+ import React, {useEffect, useMemo, useRef, useState} from 'react';
15
+
16
16
  import cx from 'classnames';
17
+ import TextareaAutosize from 'react-textarea-autosize';
17
18
 
19
+ import {LabelsResponse, QueryServiceClient} from '@parca/client';
18
20
  import {useGrpcMetadata} from '@parca/components';
19
21
  import {sanitizeLabelValue} from '@parca/functions';
20
22
  import {Query} from '@parca/parser';
21
- import {LabelsResponse, QueryServiceClient} from '@parca/client';
22
23
 
23
24
  import SuggestionsList, {Suggestion, Suggestions} from './SuggestionsList';
24
25
 
@@ -12,15 +12,16 @@
12
12
  // limitations under the License.
13
13
 
14
14
  import {useEffect, useState} from 'react';
15
- import {usePopper} from 'react-popper';
15
+
16
16
  import type {VirtualElement} from '@popperjs/core';
17
+ import {usePopper} from 'react-popper';
17
18
 
18
19
  import {Label} from '@parca/client';
19
20
  import {TextWithTooltip} from '@parca/components';
20
- import {valueFormatter, formatDate} from '@parca/functions';
21
+ import {formatDate, valueFormatter} from '@parca/functions';
21
22
 
22
- import {timeFormat} from '../../';
23
23
  import {HighlightedSeries} from '../';
24
+ import {timeFormat} from '../../';
24
25
 
25
26
  interface Props {
26
27
  x: number;
@@ -12,20 +12,25 @@
12
12
  // limitations under the License.
13
13
 
14
14
  import React, {useRef, useState} from 'react';
15
+
15
16
  import * as d3 from 'd3';
16
17
  import {pointer} from 'd3-selection';
17
18
  import throttle from 'lodash.throttle';
18
19
 
20
+ import {Label, MetricsSample, MetricsSeries as MetricsSeriesPb} from '@parca/client';
19
21
  import {DateTimeRange, useKeyDown} from '@parca/components';
20
22
  import {useContainerDimensions} from '@parca/dynamicsize';
21
- import {formatForTimespan} from '@parca/functions';
22
- import {MetricsSeries as MetricsSeriesPb, MetricsSample, Label} from '@parca/client';
23
- import {valueFormatter, formatDate, sanitizeHighlightedValues} from '@parca/functions';
23
+ import {
24
+ formatDate,
25
+ formatForTimespan,
26
+ sanitizeHighlightedValues,
27
+ valueFormatter,
28
+ } from '@parca/functions';
24
29
 
25
- import MetricsSeries from '../MetricsSeries';
30
+ import {MergedProfileSelection} from '..';
26
31
  import MetricsCircle from '../MetricsCircle';
32
+ import MetricsSeries from '../MetricsSeries';
27
33
  import MetricsTooltip from './MetricsTooltip';
28
- import {MergedProfileSelection} from '..';
29
34
 
30
35
  interface Props {
31
36
  data: MetricsSeriesPb[];
@@ -11,11 +11,11 @@
11
11
  // See the License for the specific language governing permissions and
12
12
  // limitations under the License.
13
13
 
14
+ import {QueryServiceClient} from '@parca/client';
14
15
  import type {NavigateFunction} from '@parca/functions';
15
16
  import {Query} from '@parca/parser';
16
- import {QueryServiceClient} from '@parca/client';
17
- import {ProfileDiffSource, ProfileSelection, ProfileViewWithData} from '..';
18
17
 
18
+ import {ProfileDiffSource, ProfileSelection, ProfileViewWithData} from '..';
19
19
  import ProfileSelector, {QuerySelection} from '../ProfileSelector';
20
20
 
21
21
  interface ProfileExplorerCompareProps {
@@ -11,12 +11,12 @@
11
11
  // See the License for the specific language governing permissions and
12
12
  // limitations under the License.
13
13
 
14
- import type {NavigateFunction} from '@parca/functions';
15
14
  import {QueryServiceClient} from '@parca/client';
16
- import {ProfileSelection, ProfileViewWithData} from '..';
15
+ import {KeyDownProvider} from '@parca/components';
16
+ import type {NavigateFunction} from '@parca/functions';
17
17
 
18
+ import {ProfileSelection, ProfileViewWithData} from '..';
18
19
  import ProfileSelector, {QuerySelection} from '../ProfileSelector';
19
- import {KeyDownProvider} from '@parca/components';
20
20
 
21
21
  interface ProfileExplorerSingleProps {
22
22
  queryClient: QueryServiceClient;
@@ -12,15 +12,18 @@
12
12
  // limitations under the License.
13
13
 
14
14
  import {useEffect, useState} from 'react';
15
- import {QuerySelection, useProfileTypes} from '../ProfileSelector';
16
- import {ProfileSelection, ProfileSelectionFromParams, SuffixParams} from '..';
17
- import ProfileExplorerSingle from './ProfileExplorerSingle';
18
- import ProfileExplorerCompare from './ProfileExplorerCompare';
19
- import {QueryServiceClient} from '@parca/client';
20
- import {store} from '@parca/store';
15
+
21
16
  import {Provider} from 'react-redux';
17
+
18
+ import {QueryServiceClient} from '@parca/client';
22
19
  import {DateTimeRange, useParcaContext} from '@parca/components';
23
20
  import type {NavigateFunction} from '@parca/functions';
21
+ import {store} from '@parca/store';
22
+
23
+ import {ProfileSelection, ProfileSelectionFromParams, SuffixParams} from '..';
24
+ import {QuerySelection, useProfileTypes} from '../ProfileSelector';
25
+ import ProfileExplorerCompare from './ProfileExplorerCompare';
26
+ import ProfileExplorerSingle from './ProfileExplorerSingle';
24
27
 
25
28
  interface ProfileExplorerProps {
26
29
  queryClient: QueryServiceClient;
@@ -11,13 +11,15 @@
11
11
  // See the License for the specific language governing permissions and
12
12
  // limitations under the License.
13
13
 
14
- import cx from 'classnames';
15
- import {Icon} from '@iconify/react';
16
- import useUserPreference, {USER_PREFERENCES} from '@parca/functions/useUserPreference';
17
- import {EVERYTHING_ELSE, selectStackColors, useAppSelector} from '@parca/store';
18
14
  import {useMemo} from 'react';
15
+
16
+ import {Icon} from '@iconify/react';
17
+ import cx from 'classnames';
18
+
19
19
  import {useURLState} from '@parca/components';
20
20
  import type {NavigateFunction} from '@parca/functions';
21
+ import useUserPreference, {USER_PREFERENCES} from '@parca/functions/useUserPreference';
22
+ import {EVERYTHING_ELSE, selectStackColors, useAppSelector} from '@parca/store';
21
23
 
22
24
  interface Props {
23
25
  navigateTo?: NavigateFunction;
@@ -15,17 +15,19 @@ import React, {useMemo} from 'react';
15
15
 
16
16
  import cx from 'classnames';
17
17
  import {scaleLinear} from 'd3-scale';
18
+
19
+ import {FlamegraphNode, FlamegraphRootNode} from '@parca/client';
18
20
  import {
21
+ Location,
19
22
  Mapping,
20
23
  Function as ParcaFunction,
21
- Location,
22
24
  } from '@parca/client/dist/parca/metastore/v1alpha1/metastore';
25
+ import {useKeyDown} from '@parca/components';
23
26
  import {isSearchMatch} from '@parca/functions';
24
- import {FlamegraphNode, FlamegraphRootNode} from '@parca/client';
25
- import {useAppSelector, selectBinaries} from '@parca/store';
26
- import {nodeLabel} from './utils';
27
+ import {selectBinaries, useAppSelector} from '@parca/store';
28
+
27
29
  import useNodeColor from './useNodeColor';
28
- import {useKeyDown} from '@parca/components';
30
+ import {nodeLabel} from './utils';
29
31
 
30
32
  export const RowHeight = 26;
31
33
 
@@ -14,20 +14,19 @@
14
14
  import React, {memo, useEffect, useMemo, useRef, useState} from 'react';
15
15
 
16
16
  import cx from 'classnames';
17
- import {throttle} from 'lodash';
18
- import {pointer} from 'd3-selection';
19
17
  import {scaleLinear} from 'd3-scale';
18
+ import {pointer} from 'd3-selection';
19
+ import {throttle} from 'lodash';
20
20
 
21
21
  import {Flamegraph, FlamegraphNode, FlamegraphRootNode} from '@parca/client';
22
- import type {HoveringNode} from '../../GraphTooltip';
23
- import GraphTooltip from '../../GraphTooltip';
24
22
  import {Button, useURLState} from '@parca/components';
23
+ import {selectQueryParam, type NavigateFunction} from '@parca/functions';
24
+ import useUserPreference, {USER_PREFERENCES} from '@parca/functions/useUserPreference';
25
+
26
+ import GraphTooltip, {type HoveringNode} from '../../GraphTooltip';
27
+ import ColorStackLegend from './ColorStackLegend';
25
28
  import {IcicleNode, RowHeight} from './IcicleGraphNodes';
26
29
  import useColoredGraph from './useColoredGraph';
27
- import {selectQueryParam} from '@parca/functions';
28
- import type {NavigateFunction} from '@parca/functions';
29
- import ColorStackLegend from './ColorStackLegend';
30
- import useUserPreference, {USER_PREFERENCES} from '@parca/functions/useUserPreference';
31
30
 
32
31
  interface IcicleGraphProps {
33
32
  graph: Flamegraph;
@@ -114,7 +113,7 @@ export const IcicleGraph = memo(function IcicleGraph({
114
113
  <div
115
114
  className={cx('flex justify-start absolute', {
116
115
  'top-[-48px]': dashboardItems.length <= 1 && !isTrimmed && !isColorStackLegendVisible,
117
- 'top-[-69px]': dashboardItems.length <= 1 && !isTrimmed,
116
+ 'top-[-69px]': dashboardItems.length <= 1 && !isTrimmed && isColorStackLegendVisible,
118
117
  'top-[-54px]': dashboardItems.length <= 1 && isTrimmed && isColorStackLegendVisible,
119
118
  'top-[-54px] ': dashboardItems.length <= 1 && isTrimmed && !isColorStackLegendVisible,
120
119
  'top-[-54px] left-[25px]':
@@ -11,17 +11,25 @@
11
11
  // See the License for the specific language governing permissions and
12
12
  // limitations under the License.
13
13
 
14
+ import {useEffect, useMemo} from 'react';
15
+
14
16
  import {Flamegraph, FlamegraphNode, FlamegraphRootNode} from '@parca/client';
15
17
  import {
18
+ Location,
16
19
  Mapping,
17
20
  Function as ParcaFunction,
18
- Location,
19
21
  } from '@parca/client/dist/parca/metastore/v1alpha1/metastore';
20
22
  import type {ColorProfileName} from '@parca/functions';
21
23
  import useUserPreference, {USER_PREFERENCES} from '@parca/functions/useUserPreference';
22
- import {setFeatures, useAppDispatch, useAppSelector, selectDarkMode} from '@parca/store';
23
- import type {FeatureType, FeaturesMap} from '@parca/store';
24
- import {useEffect, useMemo} from 'react';
24
+ import {
25
+ selectDarkMode,
26
+ setFeatures,
27
+ useAppDispatch,
28
+ useAppSelector,
29
+ type FeatureType,
30
+ type FeaturesMap,
31
+ } from '@parca/store';
32
+
25
33
  import {extractFeature} from './utils';
26
34
 
27
35
  export interface ColoredFlamegraphNode extends FlamegraphNode {
@@ -11,9 +11,11 @@
11
11
  // See the License for the specific language governing permissions and
12
12
  // limitations under the License.
13
13
 
14
+ import {useMemo} from 'react';
15
+
14
16
  import {diffColor} from '@parca/functions';
15
17
  import {EVERYTHING_ELSE, selectDarkMode, selectStackColors, useAppSelector} from '@parca/store';
16
- import {useMemo} from 'react';
18
+
17
19
  import type {ColoredFlamegraphNode} from './useColoredGraph';
18
20
 
19
21
  interface Props {
@@ -11,16 +11,16 @@
11
11
  // See the License for the specific language governing permissions and
12
12
  // limitations under the License.
13
13
 
14
- import {getLastItem} from '@parca/functions';
15
14
  import {FlamegraphNode} from '@parca/client';
16
15
  import {
16
+ Location,
17
17
  Mapping,
18
18
  Function as ParcaFunction,
19
- Location,
20
19
  } from '@parca/client/dist/parca/metastore/v1alpha1/metastore';
20
+ import {getLastItem} from '@parca/functions';
21
+ import {EVERYTHING_ELSE, FEATURE_TYPES, type Feature} from '@parca/store';
22
+
21
23
  import {hexifyAddress} from '../../utils';
22
- import {EVERYTHING_ELSE, FEATURE_TYPES} from '@parca/store';
23
- import type {Feature} from '@parca/store';
24
24
 
25
25
  export const getBinaryName = (
26
26
  node: FlamegraphNode,
@@ -1,9 +1,11 @@
1
1
  import {action} from '@storybook/addon-actions';
2
- import {Meta, Story, Canvas} from '@storybook/addon-docs';
3
- import ProfileIcicleGraph from './ProfileIcicleGraph';
2
+ import {Canvas, Meta, Story} from '@storybook/addon-docs';
3
+
4
4
  import {QueryResponse} from '@parca/client';
5
- import queryResponseSimple from './testdata/fg-simple.json';
5
+
6
+ import ProfileIcicleGraph from './ProfileIcicleGraph';
6
7
  import queryResponseDiff from './testdata/fg-diff.json';
8
+ import queryResponseSimple from './testdata/fg-simple.json';
7
9
 
8
10
  <Meta title="template/ProfileIcicleGraph" component={ProfileIcicleGraph} />
9
11
 
@@ -11,14 +11,14 @@
11
11
  // See the License for the specific language governing permissions and
12
12
  // limitations under the License.
13
13
 
14
+ import {useEffect, useMemo} from 'react';
15
+
14
16
  import {Flamegraph} from '@parca/client';
15
17
  import {useContainerDimensions} from '@parca/dynamicsize';
18
+ import {selectQueryParam, type NavigateFunction} from '@parca/functions';
16
19
 
17
20
  import DiffLegend from '../components/DiffLegend';
18
21
  import IcicleGraph from './IcicleGraph';
19
- import {selectQueryParam} from '@parca/functions';
20
- import type {NavigateFunction} from '@parca/functions';
21
- import {useEffect, useMemo} from 'react';
22
22
 
23
23
  const numberFormatter = new Intl.NumberFormat('en-US');
24
24
 
@@ -11,15 +11,18 @@
11
11
  // See the License for the specific language governing permissions and
12
12
  // limitations under the License.
13
13
 
14
- import {useState, useEffect} from 'react';
15
- import MetricsGraph from '../MetricsGraph';
16
- import {MergedProfileSelection, ProfileSelection} from '..';
17
- import {QueryServiceClient, QueryRangeResponse, Label, Timestamp, Duration} from '@parca/client';
14
+ import {useEffect, useState} from 'react';
15
+
18
16
  import {RpcError} from '@protobuf-ts/runtime-rpc';
17
+
18
+ import {Duration, Label, QueryRangeResponse, QueryServiceClient, Timestamp} from '@parca/client';
19
19
  import {DateTimeRange, useGrpcMetadata, useParcaContext} from '@parca/components';
20
+ import {getStepDuration} from '@parca/functions';
20
21
  import {Query} from '@parca/parser';
22
+
23
+ import {MergedProfileSelection, ProfileSelection} from '..';
24
+ import MetricsGraph from '../MetricsGraph';
21
25
  import useDelayedLoader from '../useDelayedLoader';
22
- import {getStepDuration} from '@parca/functions';
23
26
 
24
27
  interface ProfileMetricsGraphProps {
25
28
  queryClient: QueryServiceClient;
@@ -12,7 +12,9 @@
12
12
  // limitations under the License.
13
13
 
14
14
  import {useState} from 'react';
15
+
15
16
  import {usePopper} from 'react-popper';
17
+
16
18
  import {Button} from '@parca/components';
17
19
 
18
20
  const CompareButton = ({