react-science 12.0.0 → 13.0.0

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 (168) hide show
  1. package/README.md +11 -3
  2. package/lib/components/accordion/accordion.d.ts +2 -2
  3. package/lib/components/accordion/accordion.d.ts.map +1 -1
  4. package/lib/components/accordion/accordion.js +26 -42
  5. package/lib/components/accordion/accordion.js.map +1 -1
  6. package/lib/components/accordion/accordion_context.d.ts +1 -1
  7. package/lib/components/accordion/accordion_context.js +1 -1
  8. package/lib/components/accordion/accordion_context.provider.d.ts +9 -2
  9. package/lib/components/accordion/accordion_context.provider.d.ts.map +1 -1
  10. package/lib/components/accordion/accordion_context.provider.js +49 -32
  11. package/lib/components/accordion/accordion_context.provider.js.map +1 -1
  12. package/lib/components/accordion/accordion_context.utils.d.ts +23 -0
  13. package/lib/components/accordion/accordion_context.utils.d.ts.map +1 -0
  14. package/lib/components/accordion/accordion_context.utils.js +40 -0
  15. package/lib/components/accordion/accordion_context.utils.js.map +1 -0
  16. package/lib/components/accordion/index.d.ts +1 -1
  17. package/lib/components/accordion/index.js +1 -1
  18. package/lib/components/activity_bar/activity_bar.d.ts.map +1 -1
  19. package/lib/components/activity_bar/activity_bar.js +6 -4
  20. package/lib/components/activity_bar/activity_bar.js.map +1 -1
  21. package/lib/components/button/Button.d.ts +2 -3
  22. package/lib/components/button/Button.d.ts.map +1 -1
  23. package/lib/components/button/Button.js +31 -27
  24. package/lib/components/button/Button.js.map +1 -1
  25. package/lib/components/color-picker/gradient_select/gradient_select.d.ts +1 -1
  26. package/lib/components/color-picker/gradient_select/gradient_select.d.ts.map +1 -1
  27. package/lib/components/color-picker/gradient_select/gradient_select.js +8 -9
  28. package/lib/components/color-picker/gradient_select/gradient_select.js.map +1 -1
  29. package/lib/components/color-picker/react-color/ColorPicker.d.ts.map +1 -1
  30. package/lib/components/color-picker/react-color/ColorPicker.js +5 -5
  31. package/lib/components/color-picker/react-color/ColorPicker.js.map +1 -1
  32. package/lib/components/color-picker/react-color/common/Saturation.js +5 -5
  33. package/lib/components/color-picker/react-color/common/Saturation.js.map +1 -1
  34. package/lib/components/color-picker/react-color/helpers/color.d.ts.map +1 -1
  35. package/lib/components/color-picker/react-color/helpers/color.js +2 -3
  36. package/lib/components/color-picker/react-color/helpers/color.js.map +1 -1
  37. package/lib/components/dialog/ConfirmDialog.d.ts +1 -2
  38. package/lib/components/dialog/ConfirmDialog.d.ts.map +1 -1
  39. package/lib/components/dialog/ConfirmDialog.js +12 -9
  40. package/lib/components/dialog/ConfirmDialog.js.map +1 -1
  41. package/lib/components/drop-zone/DropZone.d.ts.map +1 -1
  42. package/lib/components/drop-zone/DropZone.js +3 -7
  43. package/lib/components/drop-zone/DropZone.js.map +1 -1
  44. package/lib/components/forms/radio-button-group/RadioButton.d.ts +1 -2
  45. package/lib/components/forms/radio-button-group/RadioButton.d.ts.map +1 -1
  46. package/lib/components/forms/radio-button-group/RadioButton.js +5 -4
  47. package/lib/components/forms/radio-button-group/RadioButton.js.map +1 -1
  48. package/lib/components/forms/radio-button-group/RadioButtonGroup.d.ts +1 -2
  49. package/lib/components/forms/radio-button-group/RadioButtonGroup.d.ts.map +1 -1
  50. package/lib/components/forms/radio-button-group/RadioButtonGroup.js +3 -1
  51. package/lib/components/forms/radio-button-group/RadioButtonGroup.js.map +1 -1
  52. package/lib/components/header/Header.d.ts +1 -1
  53. package/lib/components/header/Header.d.ts.map +1 -1
  54. package/lib/components/header/Header.js +11 -14
  55. package/lib/components/header/Header.js.map +1 -1
  56. package/lib/components/header/PanelHeader.d.ts +1 -1
  57. package/lib/components/header/PanelHeader.d.ts.map +1 -1
  58. package/lib/components/header/PanelHeader.js +22 -23
  59. package/lib/components/header/PanelHeader.js.map +1 -1
  60. package/lib/components/info-panel/InfoPanel.d.ts +1 -1
  61. package/lib/components/info-panel/InfoPanel.d.ts.map +1 -1
  62. package/lib/components/info-panel/InfoPanel.js +35 -30
  63. package/lib/components/info-panel/InfoPanel.js.map +1 -1
  64. package/lib/components/inline_editable_renderer/index.d.ts +2 -0
  65. package/lib/components/inline_editable_renderer/index.d.ts.map +1 -0
  66. package/lib/components/inline_editable_renderer/index.js +2 -0
  67. package/lib/components/inline_editable_renderer/index.js.map +1 -0
  68. package/lib/components/inline_editable_renderer/inline_editable_renderer.d.ts +24 -0
  69. package/lib/components/inline_editable_renderer/inline_editable_renderer.d.ts.map +1 -0
  70. package/lib/components/inline_editable_renderer/inline_editable_renderer.js +52 -0
  71. package/lib/components/inline_editable_renderer/inline_editable_renderer.js.map +1 -0
  72. package/lib/components/logger/FifoLoggerDialog.d.ts +1 -2
  73. package/lib/components/logger/FifoLoggerDialog.d.ts.map +1 -1
  74. package/lib/components/logger/FifoLoggerDialog.js +8 -9
  75. package/lib/components/logger/FifoLoggerDialog.js.map +1 -1
  76. package/lib/components/root-layout/css-reset/customPreflight.d.ts.map +1 -1
  77. package/lib/components/root-layout/css-reset/customPreflight.js +1 -2
  78. package/lib/components/root-layout/css-reset/customPreflight.js.map +1 -1
  79. package/lib/components/split-pane/SplitPane.d.ts +36 -19
  80. package/lib/components/split-pane/SplitPane.d.ts.map +1 -1
  81. package/lib/components/split-pane/SplitPane.js +69 -79
  82. package/lib/components/split-pane/SplitPane.js.map +1 -1
  83. package/lib/components/table/table_body.js +1 -0
  84. package/lib/components/table/table_body.js.map +1 -1
  85. package/lib/components/table/table_root.d.ts +20 -4
  86. package/lib/components/table/table_root.d.ts.map +1 -1
  87. package/lib/components/table/table_root.js +41 -7
  88. package/lib/components/table/table_root.js.map +1 -1
  89. package/lib/components/table/table_utils.d.ts +8 -0
  90. package/lib/components/table/table_utils.d.ts.map +1 -1
  91. package/lib/components/table/table_utils.js.map +1 -1
  92. package/lib/components/table/use_table_scroll.d.ts +5 -0
  93. package/lib/components/table/use_table_scroll.d.ts.map +1 -0
  94. package/lib/components/table/use_table_scroll.js +36 -0
  95. package/lib/components/table/use_table_scroll.js.map +1 -0
  96. package/lib/components/toolbar/PanelPreferencesToolbar.d.ts +1 -1
  97. package/lib/components/toolbar/PanelPreferencesToolbar.d.ts.map +1 -1
  98. package/lib/components/toolbar/PanelPreferencesToolbar.js +24 -27
  99. package/lib/components/toolbar/PanelPreferencesToolbar.js.map +1 -1
  100. package/lib/components/toolbar/Toolbar.d.ts +4 -5
  101. package/lib/components/toolbar/Toolbar.d.ts.map +1 -1
  102. package/lib/components/toolbar/Toolbar.js +27 -32
  103. package/lib/components/toolbar/Toolbar.js.map +1 -1
  104. package/lib/components/utils/debounce.d.ts +2 -0
  105. package/lib/components/utils/debounce.d.ts.map +1 -0
  106. package/lib/components/utils/debounce.js +12 -0
  107. package/lib/components/utils/debounce.js.map +1 -0
  108. package/lib/components/utils/index.d.ts +2 -0
  109. package/lib/components/utils/index.d.ts.map +1 -1
  110. package/lib/components/utils/index.js +2 -0
  111. package/lib/components/utils/index.js.map +1 -1
  112. package/lib/components/utils/throttle.d.ts +2 -0
  113. package/lib/components/utils/throttle.d.ts.map +1 -0
  114. package/lib/components/utils/throttle.js +14 -0
  115. package/lib/components/utils/throttle.js.map +1 -0
  116. package/lib/components/value-renderers/Color.d.ts +1 -1
  117. package/lib/components/value-renderers/Color.d.ts.map +1 -1
  118. package/lib/components/value-renderers/Color.js +7 -13
  119. package/lib/components/value-renderers/Color.js.map +1 -1
  120. package/lib/components/value-renderers/Text.d.ts +1 -1
  121. package/lib/components/value-renderers/Text.d.ts.map +1 -1
  122. package/lib/components/value-renderers/Text.js +6 -9
  123. package/lib/components/value-renderers/Text.js.map +1 -1
  124. package/lib/components/value-renderers/Title.d.ts +1 -1
  125. package/lib/components/value-renderers/Title.d.ts.map +1 -1
  126. package/lib/components/value-renderers/Title.js +6 -9
  127. package/lib/components/value-renderers/Title.js.map +1 -1
  128. package/package.json +42 -37
  129. package/src/components/accordion/accordion.tsx +28 -48
  130. package/src/components/accordion/accordion_context.provider.tsx +74 -36
  131. package/src/components/accordion/accordion_context.ts +2 -2
  132. package/src/components/accordion/accordion_context.utils.ts +66 -0
  133. package/src/components/accordion/index.ts +1 -1
  134. package/src/components/activity_bar/activity_bar.tsx +6 -4
  135. package/src/components/button/Button.tsx +47 -35
  136. package/src/components/color-picker/gradient_select/gradient_select.tsx +9 -11
  137. package/src/components/color-picker/react-color/ColorPicker.tsx +6 -6
  138. package/src/components/color-picker/react-color/common/Saturation.tsx +6 -6
  139. package/src/components/color-picker/react-color/helpers/color.ts +4 -3
  140. package/src/components/dialog/ConfirmDialog.tsx +14 -11
  141. package/src/components/drop-zone/DropZone.tsx +3 -7
  142. package/src/components/forms/radio-button-group/RadioButton.tsx +4 -4
  143. package/src/components/forms/radio-button-group/RadioButtonGroup.tsx +2 -1
  144. package/src/components/header/Header.tsx +11 -16
  145. package/src/components/header/PanelHeader.tsx +26 -30
  146. package/src/components/info-panel/InfoPanel.tsx +43 -39
  147. package/src/components/inline_editable_renderer/index.ts +1 -0
  148. package/src/components/inline_editable_renderer/inline_editable_renderer.tsx +86 -0
  149. package/src/components/logger/FifoLoggerDialog.tsx +9 -11
  150. package/src/components/root-layout/css-reset/customPreflight.ts +1 -2
  151. package/src/components/split-pane/SplitPane.tsx +144 -117
  152. package/src/components/table/table_body.tsx +1 -0
  153. package/src/components/table/table_root.tsx +71 -7
  154. package/src/components/table/table_utils.ts +11 -0
  155. package/src/components/table/use_table_scroll.ts +55 -0
  156. package/src/components/toolbar/PanelPreferencesToolbar.tsx +30 -30
  157. package/src/components/toolbar/Toolbar.tsx +33 -37
  158. package/src/components/utils/debounce.ts +16 -0
  159. package/src/components/utils/index.ts +2 -0
  160. package/src/components/utils/throttle.ts +19 -0
  161. package/src/components/value-renderers/Color.tsx +8 -13
  162. package/src/components/value-renderers/Text.tsx +6 -12
  163. package/src/components/value-renderers/Title.tsx +6 -12
  164. package/lib/components/accordion/accordion_context.state.d.ts +0 -26
  165. package/lib/components/accordion/accordion_context.state.d.ts.map +0 -1
  166. package/lib/components/accordion/accordion_context.state.js +0 -47
  167. package/lib/components/accordion/accordion_context.state.js.map +0 -1
  168. package/src/components/accordion/accordion_context.state.ts +0 -84
@@ -1 +1 @@
1
- {"version":3,"file":"Toolbar.d.ts","sourceRoot":"","sources":["../../../src/components/toolbar/Toolbar.tsx"],"names":[],"mappings":"AAAA,sCAAsC;AACtC,OAAO,KAAK,EACV,gBAAgB,EAChB,MAAM,EACN,YAAY,EACZ,YAAY,EACb,MAAM,mBAAmB,CAAC;AAG3B,OAAO,KAAK,EAAE,UAAU,EAAa,MAAM,OAAO,CAAC;AAGnD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAMtD,MAAM,MAAM,sBAAsB,GAC9B,OAAO,GACP,OAAO,GACP,cAAc,GACd,cAAc,CAAC;AAEnB,UAAU,gBAAgB;IACxB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AACD,MAAM,WAAW,YACf,SAAQ,gBAAgB,EACtB,IAAI,CAAC,gBAAgB,EAAE,UAAU,GAAG,UAAU,CAAC;IACjD;;;;;OAKG;IACH,sBAAsB,CAAC,EAAE,sBAAsB,CAAC;CACjD;AAED,MAAM,WAAW,gBACf,SAAQ,gBAAgB,EACtB,IAAI,CAAC,WAAW,EAAE,IAAI,GAAG,MAAM,GAAG,QAAQ,GAAG,KAAK,GAAG,UAAU,CAAC;IAClE,OAAO,CAAC,EAAE,YAAY,CAAC,SAAS,CAAC,CAAC;IAClC,YAAY,CAAC,EAAE,IAAI,CAAC,YAAY,EAAE,SAAS,CAAC,CAAC;IAC7C,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,UAAU,KAAK,IAAI,CAAC;CACvC;AAMD,MAAM,WAAW,uBAAwB,SAAQ,YAAY;IAC3D,SAAS,EAAE,gBAAgB,CAAC;CAC7B;AAID,wBAAgB,OAAO,CAAC,KAAK,EAAE,YAAY,oDA+D1C;yBA/De,OAAO;;6BA+Kd,uBAAuB;;AA9GhC,iBAAS,WAAW,CAAC,KAAK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@ -1,10 +1,25 @@
1
- import { jsx as _jsx, jsxs as _jsxs } from "@emotion/react/jsx-runtime";
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { ButtonGroup, Classes, Colors, Icon, Popover } from '@blueprintjs/core';
3
- import { css } from '@emotion/react';
3
+ import styled from '@emotion/styled';
4
4
  import { cloneElement, useLayoutEffect, useMemo, useRef } from 'react';
5
5
  import { Button } from '../button/index.js';
6
6
  import { toolbarContext, useToolbarContext } from './toolbarContext.js';
7
7
  const border = '1px solid rgb(247, 247, 247)';
8
+ const ToolbarButton = styled(Button) `
9
+ .${Classes.ICON} {
10
+ color: ${Colors.DARK_GRAY3};
11
+ width: 16px;
12
+ height: 16px;
13
+ font-size: 12px;
14
+ }
15
+
16
+ .${Classes.TAG} {
17
+ font-size: 10px;
18
+ line-height: 12px;
19
+ min-width: 12px;
20
+ min-height: 12px;
21
+ }
22
+ `;
8
23
  export function Toolbar(props) {
9
24
  const { children, disabled, intent, vertical, popoverInteractionKind } = props;
10
25
  const contextValue = useMemo(() => ({
@@ -59,29 +74,14 @@ function ToolbarItemInternal(props) {
59
74
  ? icon
60
75
  : cloneElement(icon, {
61
76
  className: icon.props.className
62
- ? `${icon.props.className} bp5-icon`
63
- : 'bp5-icon',
77
+ ? `${icon.props.className} ${Classes.ICON}`
78
+ : Classes.ICON,
64
79
  });
65
- return (_jsx(Button, { alignText: isPopover ? 'left' : undefined, disabled: disabled, css: css `
66
- .${Classes.ICON} {
67
- color: ${Colors.DARK_GRAY3};
68
- }
69
- .bp5-icon {
70
- width: 16px;
71
- height: 16px;
72
- font-size: 12px;
73
- }
74
- .bp5-tag {
75
- font-size: 10px;
76
- line-height: 12px;
77
- min-width: 12px;
78
- min-height: 12px;
79
- }
80
- `, intent: intent, style: {
80
+ return (_jsx(ToolbarButton, { alignText: isPopover ? 'left' : undefined, disabled: disabled, intent: intent, type: "button", active: active, style: {
81
81
  position: 'relative',
82
82
  fontSize: '1.125em',
83
83
  width: 'fit-content',
84
- }, type: "button", active: active, icon: _jsxs("div", { style: {
84
+ }, icon: _jsxs("div", { style: {
85
85
  display: 'flex',
86
86
  justifyContent: 'center',
87
87
  alignItems: 'center',
@@ -107,20 +107,15 @@ function ToolbarItemInternal(props) {
107
107
  }, ...other }));
108
108
  }
109
109
  Toolbar.Item = ToolbarItem;
110
+ const ToolbarPopover = styled(Popover) `
111
+ .${Classes.ICON} {
112
+ color: ${Colors.DARK_GRAY3};
113
+ }
114
+ `;
110
115
  Toolbar.PopoverItem = function ToolbarPopoverItem(props) {
111
116
  const { itemProps, ...other } = props;
112
117
  const { disabled, vertical, popoverInteractionKind } = useToolbarContext();
113
- return (_jsx(Popover, { minimal: true, disabled: disabled, placement: vertical ? 'right-start' : 'bottom-start', interactionKind: popoverInteractionKind, hasBackdrop: popoverInteractionKind === 'click', hoverCloseDelay: 0, css: css `
114
- .${Classes.ICON} {
115
- color: ${Colors.DARK_GRAY3};
116
- }
117
- `, targetProps: {
118
- style: {
119
- fontSize: '1.125em',
120
- width: 'fit-content',
121
- height: 'fit-content',
122
- },
123
- }, renderTarget: ({ isOpen, className, ...targetProps }) => (_jsx("span", { ...targetProps, style: { flex: '0 0 auto' }, children: _jsx(ToolbarItemInternal, { isPopover: true, ...itemProps }) })), ...other }));
118
+ return (_jsx(ToolbarPopover, { minimal: true, disabled: disabled, placement: vertical ? 'right-start' : 'bottom-start', interactionKind: popoverInteractionKind, hasBackdrop: popoverInteractionKind === 'click', hoverCloseDelay: 0, renderTarget: ({ isOpen, className, ...targetProps }) => (_jsx("span", { ...targetProps, style: { flex: '0 0 auto' }, children: _jsx(ToolbarItemInternal, { isPopover: true, ...itemProps }) })), ...other }));
124
119
  };
125
120
  function ToolbarProvider(props) {
126
121
  return (_jsx(toolbarContext.Provider, { value: props.value, children: props.children }));
@@ -1 +1 @@
1
- {"version":3,"file":"Toolbar.js","sourceRoot":"","sources":["../../../src/components/toolbar/Toolbar.tsx"],"names":[],"mappings":";AAOA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,CAAC,IAAI;aACJ,MAAM,CAAC,UAAU;;CAE7B,CAAC;AAEF,OAAO,CAAC,WAAW,GAAG,SAAS,kBAAkB,CAC/C,KAA8B;IAE9B,MAAM,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,GAAG,KAAK,CAAC;IACtC,MAAM,EAAE,QAAQ,EAAE,QAAQ,EAAE,sBAAsB,EAAE,GAAG,iBAAiB,EAAE,CAAC;IAE3E,OAAO,CACL,KAAC,cAAc,IACb,OAAO,QACP,QAAQ,EAAE,QAAQ,EAClB,SAAS,EAAE,QAAQ,CAAC,CAAC,CAAC,aAAa,CAAC,CAAC,CAAC,cAAc,EACpD,eAAe,EAAE,sBAAsB,EACvC,WAAW,EAAE,sBAAsB,KAAK,OAAO,EAC/C,eAAe,EAAE,CAAC,EAClB,YAAY,EAAE,CAAC,EAAE,MAAM,EAAE,SAAS,EAAE,GAAG,WAAW,EAAE,EAAE,EAAE,CAAC,CACvD,kBAAU,WAAW,EAAE,KAAK,EAAE,EAAE,IAAI,EAAE,UAAU,EAAE,YAChD,KAAC,mBAAmB,IAAC,SAAS,WAAK,SAAS,GAAI,GAC3C,CACR,KACG,KAAK,GACT,CACH,CAAC;AACJ,CAAC,CAAC;AAEF,SAAS,eAAe,CAAC,KAGxB;IACC,OAAO,CACL,KAAC,cAAc,CAAC,QAAQ,IAAC,KAAK,EAAE,KAAK,CAAC,KAAK,YACxC,KAAK,CAAC,QAAQ,GACS,CAC3B,CAAC;AACJ,CAAC"}
@@ -0,0 +1,2 @@
1
+ export declare function debounce<T extends (...args: any[]) => any>(func: T, wait: number): (...args: Parameters<T>) => void;
2
+ //# sourceMappingURL=debounce.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"debounce.d.ts","sourceRoot":"","sources":["../../../src/components/utils/debounce.ts"],"names":[],"mappings":"AAAA,wBAAgB,QAAQ,CAAC,CAAC,SAAS,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,GAAG,EACxD,IAAI,EAAE,CAAC,EACP,IAAI,EAAE,MAAM,GACX,CAAC,GAAG,IAAI,EAAE,UAAU,CAAC,CAAC,CAAC,KAAK,IAAI,CAYlC"}
@@ -0,0 +1,12 @@
1
+ export function debounce(func, wait) {
2
+ let timeout;
3
+ return (...args) => {
4
+ if (timeout) {
5
+ clearTimeout(timeout);
6
+ }
7
+ timeout = setTimeout(() => {
8
+ func.apply({}, args);
9
+ }, wait);
10
+ };
11
+ }
12
+ //# sourceMappingURL=debounce.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"debounce.js","sourceRoot":"","sources":["../../../src/components/utils/debounce.ts"],"names":[],"mappings":"AAAA,MAAM,UAAU,QAAQ,CACtB,IAAO,EACP,IAAY;IAEZ,IAAI,OAA6C,CAAC;IAElD,OAAO,CAAC,GAAG,IAAmB,EAAE,EAAE;QAChC,IAAI,OAAO,EAAE,CAAC;YACZ,YAAY,CAAC,OAAO,CAAC,CAAC;QACxB,CAAC;QAED,OAAO,GAAG,UAAU,CAAC,GAAG,EAAE;YACxB,IAAI,CAAC,KAAK,CAAC,EAAE,EAAE,IAAI,CAAC,CAAC;QACvB,CAAC,EAAE,IAAI,CAAC,CAAC;IACX,CAAC,CAAC;AACJ,CAAC"}
@@ -1,2 +1,4 @@
1
1
  export * from './assert.js';
2
+ export * from './debounce.js';
3
+ export * from './throttle.js';
2
4
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/utils/index.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/utils/index.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAC;AAC5B,cAAc,eAAe,CAAC;AAC9B,cAAc,eAAe,CAAC"}
@@ -1,2 +1,4 @@
1
1
  export * from './assert.js';
2
+ export * from './debounce.js';
3
+ export * from './throttle.js';
2
4
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/utils/index.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/utils/index.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAC;AAC5B,cAAc,eAAe,CAAC;AAC9B,cAAc,eAAe,CAAC"}
@@ -0,0 +1,2 @@
1
+ export declare function throttle<T extends (...args: any[]) => void>(func: T, limit: number): T;
2
+ //# sourceMappingURL=throttle.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"throttle.d.ts","sourceRoot":"","sources":["../../../src/components/utils/throttle.ts"],"names":[],"mappings":"AAAA,wBAAgB,QAAQ,CAAC,CAAC,SAAS,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,IAAI,EACzD,IAAI,EAAE,CAAC,EACP,KAAK,EAAE,MAAM,GACZ,CAAC,CAeH"}
@@ -0,0 +1,14 @@
1
+ export function throttle(func, limit) {
2
+ let inThrottle;
3
+ const fun = (...args) => {
4
+ if (!inThrottle) {
5
+ func.apply({}, args);
6
+ inThrottle = true;
7
+ setTimeout(() => {
8
+ inThrottle = false;
9
+ }, limit);
10
+ }
11
+ };
12
+ return fun;
13
+ }
14
+ //# sourceMappingURL=throttle.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"throttle.js","sourceRoot":"","sources":["../../../src/components/utils/throttle.ts"],"names":[],"mappings":"AAAA,MAAM,UAAU,QAAQ,CACtB,IAAO,EACP,KAAa;IAEb,IAAI,UAAmB,CAAC;IAExB,MAAM,GAAG,GAAG,CAAC,GAAG,IAAW,EAAE,EAAE;QAC7B,IAAI,CAAC,UAAU,EAAE,CAAC;YAChB,IAAI,CAAC,KAAK,CAAC,EAAE,EAAE,IAAI,CAAC,CAAC;YACrB,UAAU,GAAG,IAAI,CAAC;YAElB,UAAU,CAAC,GAAG,EAAE;gBACd,UAAU,GAAG,KAAK,CAAC;YACrB,CAAC,EAAE,KAAK,CAAC,CAAC;QACZ,CAAC;IACH,CAAC,CAAC;IAEF,OAAO,GAAQ,CAAC;AAClB,CAAC"}
@@ -2,6 +2,6 @@ import type { ValueRenderersProps } from './index.js';
2
2
  interface ColorProps extends ValueRenderersProps {
3
3
  value?: string;
4
4
  }
5
- export declare function Color({ value, style, onClick }: ColorProps): import("@emotion/react/jsx-runtime").JSX.Element;
5
+ export declare function Color({ value, style, onClick }: ColorProps): import("react/jsx-runtime").JSX.Element;
6
6
  export {};
7
7
  //# sourceMappingURL=Color.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Color.d.ts","sourceRoot":"","sources":["../../../src/components/value-renderers/Color.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,YAAY,CAAC;AAEtD,UAAU,UAAW,SAAQ,mBAAmB;IAC9C,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAUD,wBAAgB,KAAK,CAAC,EAAE,KAAK,EAAE,KAAK,EAAE,OAAO,EAAE,EAAE,UAAU,oDAW1D"}
1
+ {"version":3,"file":"Color.d.ts","sourceRoot":"","sources":["../../../src/components/value-renderers/Color.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,YAAY,CAAC;AAEtD,UAAU,UAAW,SAAQ,mBAAmB;IAC9C,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAOD,wBAAgB,KAAK,CAAC,EAAE,KAAK,EAAE,KAAK,EAAE,OAAO,EAAE,EAAE,UAAU,2CAU1D"}
@@ -1,17 +1,11 @@
1
- import { jsx as _jsx } from "@emotion/react/jsx-runtime";
2
- /** @jsxImportSource @emotion/react */
3
- import { css } from '@emotion/react';
4
- const styles = {
5
- color: css({
6
- position: 'absolute',
7
- top: '2px',
8
- left: '2px',
9
- right: '2px',
10
- bottom: '2px',
11
- }),
12
- };
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ import styled from '@emotion/styled';
3
+ const ColorContainer = styled.div `
4
+ position: absolute;
5
+ inset: 2px;
6
+ `;
13
7
  export function Color({ value, style, onClick }) {
14
- return (_jsx("div", { onClick: onClick, css: styles.color, style: {
8
+ return (_jsx(ColorContainer, { onClick: onClick, style: {
15
9
  background: value,
16
10
  ...style,
17
11
  } }));
@@ -1 +1 @@
1
- {"version":3,"file":"Color.js","sourceRoot":"","sources":["../../../src/components/value-renderers/Color.tsx"],"names":[],"mappings":";AAAA,sCAAsC;AACtC,OAAO,EAAE,GAAG,EAAE,MAAM,gBAAgB,CAAC;AAOrC,MAAM,MAAM,GAAG;IACb,KAAK,EAAE,GAAG,CAAC;QACT,QAAQ,EAAE,UAAU;QACpB,GAAG,EAAE,KAAK;QACV,IAAI,EAAE,KAAK;QACX,KAAK,EAAE,KAAK;QACZ,MAAM,EAAE,KAAK;KACd,CAAC;CACH,CAAC;AACF,MAAM,UAAU,KAAK,CAAC,EAAE,KAAK,EAAE,KAAK,EAAE,OAAO,EAAc;IACzD,OAAO,CACL,cACE,OAAO,EAAE,OAAO,EAChB,GAAG,EAAE,MAAM,CAAC,KAAK,EACjB,KAAK,EAAE;YACL,UAAU,EAAE,KAAK;YACjB,GAAG,KAAK;SACT,GACD,CACH,CAAC;AACJ,CAAC"}
1
+ {"version":3,"file":"Color.js","sourceRoot":"","sources":["../../../src/components/value-renderers/Color.tsx"],"names":[],"mappings":";AAAA,OAAO,MAAM,MAAM,iBAAiB,CAAC;AAQrC,MAAM,cAAc,GAAG,MAAM,CAAC,GAAG,CAAA;;;CAGhC,CAAC;AAEF,MAAM,UAAU,KAAK,CAAC,EAAE,KAAK,EAAE,KAAK,EAAE,OAAO,EAAc;IACzD,OAAO,CACL,KAAC,cAAc,IACb,OAAO,EAAE,OAAO,EAChB,KAAK,EAAE;YACL,UAAU,EAAE,KAAK;YACjB,GAAG,KAAK;SACT,GACD,CACH,CAAC;AACJ,CAAC"}
@@ -2,6 +2,6 @@ import type { ValueRenderersProps } from './index.js';
2
2
  interface TextProps extends ValueRenderersProps {
3
3
  value?: string;
4
4
  }
5
- export declare function Text({ value, ...other }: TextProps): import("@emotion/react/jsx-runtime").JSX.Element;
5
+ export declare function Text({ value, ...other }: TextProps): import("react/jsx-runtime").JSX.Element;
6
6
  export {};
7
7
  //# sourceMappingURL=Text.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Text.d.ts","sourceRoot":"","sources":["../../../src/components/value-renderers/Text.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,YAAY,CAAC;AAEtD,UAAU,SAAU,SAAQ,mBAAmB;IAC7C,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAOD,wBAAgB,IAAI,CAAC,EAAE,KAAK,EAAE,GAAG,KAAK,EAAE,EAAE,SAAS,oDAMlD"}
1
+ {"version":3,"file":"Text.d.ts","sourceRoot":"","sources":["../../../src/components/value-renderers/Text.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,YAAY,CAAC;AAEtD,UAAU,SAAU,SAAQ,mBAAmB;IAC7C,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAMD,wBAAgB,IAAI,CAAC,EAAE,KAAK,EAAE,GAAG,KAAK,EAAE,EAAE,SAAS,2CAElD"}
@@ -1,12 +1,9 @@
1
- import { jsx as _jsx } from "@emotion/react/jsx-runtime";
2
- /** @jsxImportSource @emotion/react */
3
- import { css } from '@emotion/react';
4
- const styles = {
5
- text: css({
6
- textOverflow: 'ellipsis',
7
- }),
8
- };
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ import styled from '@emotion/styled';
3
+ const TextContainer = styled.div `
4
+ text-overflow: ellipsis;
5
+ `;
9
6
  export function Text({ value, ...other }) {
10
- return (_jsx("div", { ...other, css: styles.text, children: value }));
7
+ return _jsx(TextContainer, { ...other, children: value });
11
8
  }
12
9
  //# sourceMappingURL=Text.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Text.js","sourceRoot":"","sources":["../../../src/components/value-renderers/Text.tsx"],"names":[],"mappings":";AAAA,sCAAsC;AACtC,OAAO,EAAE,GAAG,EAAE,MAAM,gBAAgB,CAAC;AAOrC,MAAM,MAAM,GAAG;IACb,IAAI,EAAE,GAAG,CAAC;QACR,YAAY,EAAE,UAAU;KACzB,CAAC;CACH,CAAC;AAEF,MAAM,UAAU,IAAI,CAAC,EAAE,KAAK,EAAE,GAAG,KAAK,EAAa;IACjD,OAAO,CACL,iBAAS,KAAK,EAAE,GAAG,EAAE,MAAM,CAAC,IAAI,YAC7B,KAAK,GACF,CACP,CAAC;AACJ,CAAC"}
1
+ {"version":3,"file":"Text.js","sourceRoot":"","sources":["../../../src/components/value-renderers/Text.tsx"],"names":[],"mappings":";AAAA,OAAO,MAAM,MAAM,iBAAiB,CAAC;AAQrC,MAAM,aAAa,GAAG,MAAM,CAAC,GAAG,CAAA;;CAE/B,CAAC;AAEF,MAAM,UAAU,IAAI,CAAC,EAAE,KAAK,EAAE,GAAG,KAAK,EAAa;IACjD,OAAO,KAAC,aAAa,OAAK,KAAK,YAAG,KAAK,GAAiB,CAAC;AAC3D,CAAC"}
@@ -2,5 +2,5 @@ import type { ValueRenderersProps } from './index.js';
2
2
  export interface TitleProps extends ValueRenderersProps {
3
3
  value?: string;
4
4
  }
5
- export declare function Title({ value, ...other }: TitleProps): import("@emotion/react/jsx-runtime").JSX.Element;
5
+ export declare function Title({ value, ...other }: TitleProps): import("react/jsx-runtime").JSX.Element;
6
6
  //# sourceMappingURL=Title.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Title.d.ts","sourceRoot":"","sources":["../../../src/components/value-renderers/Title.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,YAAY,CAAC;AAEtD,MAAM,WAAW,UAAW,SAAQ,mBAAmB;IACrD,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAOD,wBAAgB,KAAK,CAAC,EAAE,KAAK,EAAE,GAAG,KAAK,EAAE,EAAE,UAAU,oDAMpD"}
1
+ {"version":3,"file":"Title.d.ts","sourceRoot":"","sources":["../../../src/components/value-renderers/Title.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,YAAY,CAAC;AAEtD,MAAM,WAAW,UAAW,SAAQ,mBAAmB;IACrD,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAMD,wBAAgB,KAAK,CAAC,EAAE,KAAK,EAAE,GAAG,KAAK,EAAE,EAAE,UAAU,2CAEpD"}
@@ -1,12 +1,9 @@
1
- import { jsx as _jsx } from "@emotion/react/jsx-runtime";
2
- /** @jsxImportSource @emotion/react */
3
- import { css } from '@emotion/react';
4
- const styles = {
5
- title: css({
6
- fontWeight: 'bold',
7
- }),
8
- };
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ import styled from '@emotion/styled';
3
+ const TitleContainer = styled.div `
4
+ font-weight: bold;
5
+ `;
9
6
  export function Title({ value, ...other }) {
10
- return (_jsx("div", { ...other, css: styles.title, children: value }));
7
+ return _jsx(TitleContainer, { ...other, children: value });
11
8
  }
12
9
  //# sourceMappingURL=Title.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Title.js","sourceRoot":"","sources":["../../../src/components/value-renderers/Title.tsx"],"names":[],"mappings":";AAAA,sCAAsC;AACtC,OAAO,EAAE,GAAG,EAAE,MAAM,gBAAgB,CAAC;AAQrC,MAAM,MAAM,GAAG;IACb,KAAK,EAAE,GAAG,CAAC;QACT,UAAU,EAAE,MAAM;KACnB,CAAC;CACH,CAAC;AACF,MAAM,UAAU,KAAK,CAAC,EAAE,KAAK,EAAE,GAAG,KAAK,EAAc;IACnD,OAAO,CACL,iBAAS,KAAK,EAAE,GAAG,EAAE,MAAM,CAAC,KAAK,YAC9B,KAAK,GACF,CACP,CAAC;AACJ,CAAC"}
1
+ {"version":3,"file":"Title.js","sourceRoot":"","sources":["../../../src/components/value-renderers/Title.tsx"],"names":[],"mappings":";AAAA,OAAO,MAAM,MAAM,iBAAiB,CAAC;AAQrC,MAAM,cAAc,GAAG,MAAM,CAAC,GAAG,CAAA;;CAEhC,CAAC;AAEF,MAAM,UAAU,KAAK,CAAC,EAAE,KAAK,EAAE,GAAG,KAAK,EAAc;IACnD,OAAO,KAAC,cAAc,OAAK,KAAK,YAAG,KAAK,GAAkB,CAAC;AAC7D,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-science",
3
- "version": "12.0.0",
3
+ "version": "13.0.0",
4
4
  "description": "React components to build scientific applications UI",
5
5
  "type": "module",
6
6
  "exports": {
@@ -33,7 +33,9 @@
33
33
  "prettier-write": "prettier --write .",
34
34
  "serve": "vite preview",
35
35
  "storybook": "storybook dev -p 6006",
36
- "test": "npm run playwright && npm run test-only && npm run eslint && npm run prettier && npm run check-types",
36
+ "stylelint": "stylelint src stories styles",
37
+ "stylelint-fix": "npm run stylelint -- --fix",
38
+ "test": "npm run playwright && npm run test-only && npm run check-types && npm run stylelint && npm run eslint && npm run prettier",
37
39
  "test-only": "vitest run --coverage "
38
40
  },
39
41
  "repository": {
@@ -48,80 +50,83 @@
48
50
  "peerDependencies": {
49
51
  "@blueprintjs/core": "^5.16.0",
50
52
  "@blueprintjs/icons": "^5.15.0",
53
+ "@blueprintjs/select": "^5.3.5",
51
54
  "fifo-logger": "^1.0.0",
52
55
  "react": ">=18.0.0",
53
56
  "react-dom": ">=18.0.0"
54
57
  },
55
58
  "dependencies": {
56
- "@blueprintjs/select": "^5.3.5",
57
- "@emotion/react": "^11.13.5",
58
- "@emotion/styled": "^11.13.5",
59
- "@tanstack/react-table": "^8.20.5",
60
- "@tanstack/react-virtual": "^3.10.9",
59
+ "@emotion/styled": "^11.14.0",
60
+ "@radix-ui/react-use-controllable-state": "^1.1.0",
61
+ "@tanstack/react-table": "^8.20.6",
62
+ "@tanstack/react-virtual": "^3.12.0",
61
63
  "d3-scale-chromatic": "^3.1.0",
62
- "immer": "^10.1.1",
63
- "lodash": "^4.17.21",
64
64
  "react-dropzone": "14.3.5",
65
- "react-icons": "^5.3.0",
65
+ "react-icons": "^5.4.0",
66
66
  "react-inspector": "^6.0.2",
67
67
  "tinycolor2": "^1.6.0",
68
- "ts-pattern": "^5.5.0",
68
+ "ts-pattern": "^5.6.2",
69
69
  "use-resize-observer": "^9.1.0"
70
70
  },
71
71
  "devDependencies": {
72
- "@blueprintjs/core": "^5.16.0",
73
- "@blueprintjs/icons": "^5.15.0",
74
- "@floating-ui/react": "^0.26.28",
75
- "@playwright/experimental-ct-react": "^1.49.0",
76
- "@playwright/test": "^1.49.0",
77
- "@storybook/addon-essentials": "^8.4.5",
78
- "@storybook/addon-storysource": "^8.4.5",
79
- "@storybook/blocks": "^8.4.5",
80
- "@storybook/react": "^8.4.5",
81
- "@storybook/react-vite": "^8.4.5",
82
- "@tanstack/react-query": "^5.62.3",
72
+ "@blueprintjs/core": "^5.16.4",
73
+ "@blueprintjs/icons": "^5.17.1",
74
+ "@blueprintjs/select": "^5.3.9",
75
+ "@floating-ui/react": "^0.27.3",
76
+ "@playwright/experimental-ct-react": "^1.50.1",
77
+ "@playwright/test": "^1.50.1",
78
+ "@storybook/addon-actions": "^8.5.8",
79
+ "@storybook/addon-essentials": "^8.5.8",
80
+ "@storybook/addon-storysource": "^8.5.8",
81
+ "@storybook/blocks": "^8.5.8",
82
+ "@storybook/react": "^8.5.8",
83
+ "@storybook/react-vite": "^8.5.8",
84
+ "@tanstack/react-query": "^5.66.0",
83
85
  "@types/babel__core": "^7.20.5",
84
86
  "@types/d3-scale-chromatic": "^3.1.0",
85
- "@types/lodash": "^4.17.13",
87
+ "@types/node": "^22.13.1",
86
88
  "@types/react": "^18.3.12",
87
89
  "@types/react-dom": "^18.3.1",
88
- "@types/react-inspector": "^4.0.6",
89
90
  "@types/tinycolor2": "^1.4.6",
90
91
  "@vitejs/plugin-react": "^4.3.4",
91
- "@vitest/coverage-v8": "^2.1.6",
92
+ "@vitest/coverage-v8": "^3.0.5",
92
93
  "biologic-converter": "^0.6.0",
93
94
  "cheminfo-font": "^1.13.1",
94
95
  "cheminfo-types": "^1.8.1",
95
96
  "cross-env": "^7.0.3",
96
- "eslint": "^9.15.0",
97
+ "eslint": "^9.19.0",
97
98
  "eslint-config-zakodium": "^14.0.0",
98
- "eslint-plugin-storybook": "^0.11.1",
99
+ "eslint-plugin-storybook": "^0.11.2",
99
100
  "fifo-logger": "^1.0.0",
100
101
  "filelist-utils": "^1.11.2",
101
- "jcampconverter": "^10.0.1",
102
+ "immer": "^10.1.1",
103
+ "jcampconverter": "^10.0.2",
102
104
  "ml-gsd": "^12.1.8",
103
105
  "ml-peak-shape-generator": "^4.1.4",
104
106
  "ml-signal-processing": "^1.2.0",
105
- "ml-spectra-processing": "^14.7.0",
106
- "ms-spectrum": "^3.7.0",
107
+ "ml-spectra-processing": "^14.9.2",
108
+ "ms-spectrum": "^3.7.6",
107
109
  "netcdfjs": "^3.0.0",
108
- "prettier": "^3.4.1",
110
+ "postcss-styled-syntax": "^0.7.1",
111
+ "prettier": "^3.4.2",
109
112
  "react": "^18.3.1",
110
113
  "react-d3-utils": "^3.0.0",
111
114
  "react-dom": "^18.3.1",
112
- "react-error-boundary": "^4.1.2",
115
+ "react-error-boundary": "^5.0.0",
113
116
  "react-kbs": "^2.1.1",
114
117
  "react-ocl": "^7.0.2",
115
118
  "react-plot": "^3.0.0",
116
119
  "rimraf": "^6.0.1",
117
120
  "spc-parser": "^1.0.0",
118
- "storybook": "^8.4.5",
119
- "typescript": "^5.7.2",
120
- "vite": "^5.4.11",
121
- "vitest": "^2.1.6",
121
+ "storybook": "^8.5.3",
122
+ "stylelint": "^16.14.1",
123
+ "stylelint-config-standard": "^37.0.0",
124
+ "typescript": "^5.7.3",
125
+ "vite": "^6.1.0",
126
+ "vitest": "^3.0.5",
122
127
  "wdf-parser": "^0.3.0"
123
128
  },
124
129
  "volta": {
125
- "node": "22.11.0"
130
+ "node": "22.13.1"
126
131
  }
127
132
  }
@@ -1,5 +1,4 @@
1
- /** @jsxImportSource @emotion/react */
2
- import { css } from '@emotion/react';
1
+ import styled from '@emotion/styled';
3
2
  import type {
4
3
  MouseEvent as ReactMouseEvent,
5
4
  ReactElement,
@@ -29,40 +28,32 @@ export interface AccordionItemProps {
29
28
  toolbar?: ReactNode;
30
29
  }
31
30
 
32
- const styles = {
33
- container: css({
34
- display: 'flex',
35
- flexDirection: 'column',
36
- height: '100%',
37
- width: '100%',
38
- }),
39
- item: (isOpen: boolean) => {
40
- return css([
41
- {
42
- display: 'flex',
43
- flexDirection: 'column',
44
- },
45
- isOpen && { flex: '1 1 0%' },
46
- ]);
47
- },
48
- header: css({
49
- cursor: 'pointer',
50
- padding: '5px 12px',
51
- display: 'flex',
52
- alignItems: 'center',
53
- borderColor: 'rgb(213, 213, 213) currentcolor currentcolor',
54
- borderStyle: 'solid none none',
55
- color: 'rgb(45, 45, 45)',
56
- fontWeight: 'bold',
57
- textDecoration: 'none',
58
- textShadow: 'rgb(255, 255, 255) 0px 1px 0px',
59
- background:
60
- 'rgb(255, 255, 255) linear-gradient(rgb(240, 240, 240) 5%, rgb(225, 225, 225) 100%) repeat scroll 0% 0%',
61
- }),
62
- };
31
+ const AccordionItemHeader = styled.div`
32
+ cursor: pointer;
33
+ display: flex;
34
+ align-items: center;
35
+ border-color: #d5d5d5 currentcolor currentcolor;
36
+ border-style: solid none none;
37
+ color: #2d2d2d;
38
+ font-weight: bold;
39
+ text-decoration: none;
40
+ text-shadow: white 0 1px 0;
41
+ background: white linear-gradient(#f0f0f0 5%, white 100%) repeat scroll 0 0;
42
+ width: 100%;
43
+ user-select: none;
44
+ justify-content: space-between;
45
+ padding: 0 12px;
46
+ `;
47
+
48
+ const AccordionContainer = styled.div`
49
+ display: flex;
50
+ flex-direction: column;
51
+ height: 100%;
52
+ width: 100%;
53
+ `;
63
54
 
64
55
  export function Accordion(props: AccordionProps) {
65
- return <div css={styles.container}>{props.children}</div>;
56
+ return <AccordionContainer>{props.children}</AccordionContainer>;
66
57
  }
67
58
 
68
59
  Accordion.Item = function AccordionItem(props: AccordionItemProps) {
@@ -76,6 +67,7 @@ Accordion.Item = function AccordionItem(props: AccordionItemProps) {
76
67
  props.unmountChildren === undefined
77
68
  ? unmountChildren
78
69
  : props.unmountChildren;
70
+
79
71
  const onClickHandle = useCallback(
80
72
  (event: ReactMouseEvent<HTMLDivElement>) => {
81
73
  if (event.shiftKey) {
@@ -96,19 +88,7 @@ Accordion.Item = function AccordionItem(props: AccordionItemProps) {
96
88
  isolation: 'isolate',
97
89
  }}
98
90
  >
99
- <div
100
- onClick={onClickHandle}
101
- role="button"
102
- style={{
103
- display: 'flex',
104
- alignItems: 'center',
105
- width: '100%',
106
- userSelect: 'none',
107
- justifyContent: 'space-between',
108
- padding: '0px 12px',
109
- }}
110
- css={styles.header}
111
- >
91
+ <AccordionItemHeader onClick={onClickHandle} role="button">
112
92
  <div
113
93
  style={{
114
94
  padding: '5px 0px',
@@ -117,7 +97,7 @@ Accordion.Item = function AccordionItem(props: AccordionItemProps) {
117
97
  {title}
118
98
  </div>
119
99
  {toolbar}
120
- </div>
100
+ </AccordionItemHeader>
121
101
  {!item?.isOpen && shouldUnmountChildren ? null : (
122
102
  <div
123
103
  style={{