@opentrons/components 0.2.1-alpha.0 → 0.3.0-alpha.1

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 (219) hide show
  1. package/LICENSE +202 -0
  2. package/README.md +12 -48
  3. package/lib/assets/index.d.ts +1 -0
  4. package/lib/assets/localization/en/index.d.ts +191 -16
  5. package/lib/assets/localization/index.d.ts +292 -13
  6. package/lib/assets/localization/zh/index.d.ts +110 -8
  7. package/lib/atoms/Checkbox/index.d.ts +3 -3
  8. package/lib/atoms/CheckboxField/index.d.ts +2 -0
  9. package/lib/atoms/FixedTrashText/index.d.ts +1 -0
  10. package/lib/atoms/InlineNotification/index.d.ts +1 -1
  11. package/lib/atoms/ListButton/index.d.ts +2 -2
  12. package/lib/atoms/MenuList/OverflowBtn.d.ts +2 -2
  13. package/lib/atoms/Slider/index.d.ts +14 -0
  14. package/lib/atoms/StepMeter/__tests__/StepMeter.test.d.ts +1 -1
  15. package/lib/atoms/StepMeter/index.d.ts +1 -2
  16. package/lib/atoms/StyledText/LegacyStyledText.d.ts +3 -1
  17. package/lib/atoms/StyledText/PlaceholderStyledText.d.ts +14 -0
  18. package/lib/atoms/StyledText/StyledText.d.ts +1 -0
  19. package/lib/atoms/StyledText/index.d.ts +1 -0
  20. package/lib/atoms/Tag/index.d.ts +1 -1
  21. package/lib/atoms/buttons/AlertPrimaryButton.d.ts +3 -1
  22. package/lib/atoms/buttons/AltPrimaryButton.d.ts +3 -1
  23. package/lib/atoms/buttons/PrimaryButton.d.ts +2 -1
  24. package/lib/atoms/buttons/TertiaryButton.d.ts +8 -3
  25. package/lib/atoms/index.d.ts +2 -1
  26. package/lib/buttons/Button.d.ts +3 -3
  27. package/lib/controls/ToggleButton.d.ts +1 -1
  28. package/lib/forms/DeprecatedCheckboxField.d.ts +2 -2
  29. package/lib/forms/FormGroup.d.ts +4 -4
  30. package/lib/forms/LegacyInputField.d.ts +5 -5
  31. package/lib/forms/RadioGroup.d.ts +2 -2
  32. package/lib/forms/ToggleField.d.ts +1 -1
  33. package/lib/hardware-sim/BaseDeck/BaseDeck.d.ts +19 -11
  34. package/lib/hardware-sim/BaseDeck/SingleSlotFixture.d.ts +2 -0
  35. package/lib/hardware-sim/BaseDeck/StackedBadge.d.ts +1 -0
  36. package/lib/hardware-sim/BaseDeck/StagingAreaFixture.d.ts +1 -0
  37. package/lib/hardware-sim/BaseDeck/WasteChuteStagingAreaFixture.d.ts +1 -0
  38. package/lib/hardware-sim/Deck/MoveLabwareOnDeck.d.ts +3 -2
  39. package/lib/hardware-sim/Deck/RobotCoordsForeignDiv.d.ts +6 -5
  40. package/lib/hardware-sim/Deck/RobotCoordsForeignObject.d.ts +8 -5
  41. package/lib/hardware-sim/Deck/RobotWorkSpace.d.ts +2 -3
  42. package/lib/hardware-sim/DeckConfigurator/VacuumModuleItem.d.ts +11 -0
  43. package/lib/hardware-sim/DeckConfigurator/constants.d.ts +5 -0
  44. package/lib/hardware-sim/Labware/Labware.d.ts +3 -3
  45. package/lib/hardware-sim/Labware/LabwareAdapter/GenericLid.d.ts +9 -0
  46. package/lib/hardware-sim/Labware/LabwareAdapter/OpentronsUniversalFlatAdapterTypeB.d.ts +1 -0
  47. package/lib/hardware-sim/Labware/LabwareAdapter/index.d.ts +11 -3
  48. package/lib/hardware-sim/Labware/LabwareRender.d.ts +9 -9
  49. package/lib/hardware-sim/Labware/index.d.ts +1 -1
  50. package/lib/hardware-sim/Labware/labwareInternals/LabwareOutline.d.ts +1 -1
  51. package/lib/hardware-sim/Labware/labwareInternals/LabwareWellLabels.d.ts +1 -1
  52. package/lib/hardware-sim/Labware/labwareInternals/StaticLabware.d.ts +7 -2
  53. package/lib/hardware-sim/Labware/labwareInternals/Tips/InaccessibleTip.d.ts +3 -0
  54. package/lib/hardware-sim/Labware/labwareInternals/Tips/NewTip.d.ts +4 -0
  55. package/lib/hardware-sim/Labware/labwareInternals/Tips/TipStatus.d.ts +11 -0
  56. package/lib/hardware-sim/Labware/labwareInternals/Tips/UsedTip.d.ts +4 -0
  57. package/lib/hardware-sim/Labware/labwareInternals/Tips/__tests__/TipStatus.test.d.ts +1 -0
  58. package/lib/hardware-sim/Labware/labwareInternals/Tips/constants.d.ts +11 -0
  59. package/lib/hardware-sim/Labware/labwareInternals/Tips/index.d.ts +2 -0
  60. package/lib/hardware-sim/Labware/labwareInternals/Wells/EmptyWell.d.ts +10 -0
  61. package/lib/hardware-sim/Labware/labwareInternals/{FilledWells.d.ts → Wells/FilledWells.d.ts} +3 -3
  62. package/lib/hardware-sim/Labware/labwareInternals/Wells/SelectedWell.d.ts +13 -0
  63. package/lib/hardware-sim/Labware/labwareInternals/{StrokedWells.d.ts → Wells/StrokedWells.d.ts} +2 -2
  64. package/lib/hardware-sim/Labware/labwareInternals/{StyledWells.d.ts → Wells/StyledWells.d.ts} +1 -1
  65. package/lib/hardware-sim/Labware/labwareInternals/{Well.d.ts → Wells/Well.d.ts} +2 -3
  66. package/lib/hardware-sim/Labware/labwareInternals/{WellLabels.d.ts → Wells/WellLabels.d.ts} +2 -2
  67. package/lib/hardware-sim/Labware/labwareInternals/Wells/WellStatus.d.ts +12 -0
  68. package/lib/hardware-sim/Labware/labwareInternals/Wells/constants.d.ts +21 -0
  69. package/lib/hardware-sim/Labware/labwareInternals/Wells/index.d.ts +9 -0
  70. package/lib/hardware-sim/Labware/labwareInternals/Wells/utils.d.ts +2 -0
  71. package/lib/hardware-sim/Labware/labwareInternals/index.d.ts +2 -5
  72. package/lib/hardware-sim/Labware/labwareInternals/types.d.ts +10 -12
  73. package/lib/hardware-sim/Module/Vacuum.d.ts +1 -0
  74. package/lib/hardware-sim/Module/index.d.ts +40 -5
  75. package/lib/hardware-sim/Pipette/StrokedNozzles.d.ts +10 -0
  76. package/lib/hardware-sim/Pipette/constants.d.ts +3 -0
  77. package/lib/hardware-sim/Pipette/index.d.ts +1 -0
  78. package/lib/hardware-sim/RobotCoordinateSpace/RobotCoordinateSpace.d.ts +5 -3
  79. package/lib/hardware-sim/RobotCoordinateSpace/RobotCoordinateSpaceWithRef.d.ts +5 -4
  80. package/lib/hardware-sim/alignment/AlignToModuleChildSlot.d.ts +25 -0
  81. package/lib/hardware-sim/alignment/CenterLabwareInModuleChildSlot.d.ts +33 -0
  82. package/lib/hardware-sim/alignment/CenterLabwareInSlot.d.ts +11 -0
  83. package/lib/hardware-sim/alignment/index.d.ts +4 -0
  84. package/lib/hardware-sim/index.d.ts +1 -0
  85. package/lib/helix-design-system/colors.d.ts +1 -0
  86. package/lib/hocs/withStyleProps.d.ts +1 -1
  87. package/lib/hooks/__tests__/useCommandTypeSummaries.test.d.ts +1 -0
  88. package/lib/hooks/index.d.ts +2 -1
  89. package/lib/hooks/testHelpers/index.d.ts +2 -0
  90. package/lib/hooks/useCommandTypeSummaries.d.ts +2 -0
  91. package/lib/hooks/useConditionalConfirm.d.ts +5 -9
  92. package/lib/i18n.d.ts +4 -0
  93. package/lib/icons/ModuleIcon.d.ts +5 -4
  94. package/lib/icons/icon-data.d.ts +702 -4
  95. package/lib/index.d.ts +2 -1
  96. package/lib/index.js +557 -0
  97. package/lib/index.mjs +30626 -28730
  98. package/lib/interaction-enhancers/HandleKeypress.d.ts +2 -2
  99. package/lib/legacy-hardware-sim/LabwareNameOverlay.d.ts +1 -1
  100. package/lib/legacy-hardware-sim/index.d.ts +0 -1
  101. package/lib/modals/AlertModal.d.ts +1 -1
  102. package/lib/molecules/CustomizeExpandButton/index.d.ts +2 -2
  103. package/lib/molecules/DeckInfoLabel/index.d.ts +8 -20
  104. package/lib/molecules/DeckLabel/index.d.ts +9 -2
  105. package/lib/molecules/DropdownMenu/index.d.ts +5 -4
  106. package/lib/molecules/IconButton/index.d.ts +45 -0
  107. package/lib/molecules/InfoScreen/index.d.ts +3 -1
  108. package/lib/molecules/InputField/__tests__/InputField.test.d.ts +1 -0
  109. package/lib/{atoms → molecules}/InputField/index.d.ts +13 -12
  110. package/lib/molecules/LiquidIcon/index.d.ts +2 -1
  111. package/lib/molecules/RobotInfoLabel/__tests__/RobotInfoLabel.test.d.ts +1 -0
  112. package/lib/molecules/RobotInfoLabel/index.d.ts +12 -0
  113. package/lib/molecules/StepGroup/__tests__/StepGroup.test.d.ts +1 -0
  114. package/lib/molecules/StepGroup/index.d.ts +11 -0
  115. package/lib/molecules/TextAreaField/__tests__/TextAreaField.test.d.ts +1 -0
  116. package/lib/molecules/TextAreaField/index.d.ts +34 -0
  117. package/lib/molecules/TimelineScrubber/TrackSlider.d.ts +10 -0
  118. package/lib/molecules/TimelineScrubber/index.d.ts +6 -0
  119. package/lib/molecules/TouchInputField/__tests__/TouchInputField.test.d.ts +1 -0
  120. package/lib/molecules/TouchInputField/index.d.ts +56 -0
  121. package/lib/molecules/WizardHeader/__tests__/WizardHeader.test.d.ts +1 -0
  122. package/lib/molecules/WizardHeader/index.d.ts +11 -0
  123. package/lib/molecules/index.d.ts +8 -1
  124. package/lib/organisms/CommandText/getCommandData.d.ts +3 -0
  125. package/lib/organisms/CommandText/index.d.ts +2 -1
  126. package/lib/organisms/CommandText/useCommandTextString/index.d.ts +8 -3
  127. package/lib/organisms/CommandText/useCommandTextString/utils/commandText/__tests__/getTipStateCommandText.test.d.ts +1 -0
  128. package/lib/organisms/CommandText/useCommandTextString/utils/commandText/getConcurrentCommandText.d.ts +3 -0
  129. package/lib/organisms/CommandText/useCommandTextString/utils/commandText/getHSConcurrentShakeSpeedCommandTex.d.ts +3 -0
  130. package/lib/organisms/CommandText/useCommandTextString/utils/commandText/getRobotDevicesCommandText.d.ts +3 -0
  131. package/lib/organisms/CommandText/useCommandTextString/utils/commandText/getTCStartRunExtendedProfileCommandText.d.ts +4 -0
  132. package/lib/organisms/CommandText/useCommandTextString/utils/commandText/getTipStateCommandText.d.ts +3 -0
  133. package/lib/organisms/CommandText/useCommandTextString/utils/commandText/index.d.ts +5 -0
  134. package/lib/organisms/CommandText/useCommandTextString/utils/getLabwareDisplayLocation.d.ts +2 -0
  135. package/lib/organisms/CommandText/useCommandTextString/utils/getLiquidDisplayName.d.ts +2 -1
  136. package/lib/organisms/CommandText/useCommandTextString/utils/types.d.ts +2 -1
  137. package/lib/organisms/DeckLabelSet/index.d.ts +1 -0
  138. package/lib/organisms/FixtureOption/index.d.ts +0 -1
  139. package/lib/organisms/LabwareDetailsWithCount/__tests__/LabwareDetailsWithCount.test.d.ts +1 -0
  140. package/lib/organisms/LabwareDetailsWithCount/index.d.ts +7 -0
  141. package/lib/organisms/LabwareInfoOverlay/__tests__/LabwareInfoOverlay.test.d.ts +1 -0
  142. package/lib/organisms/LabwareInfoOverlay/index.d.ts +12 -0
  143. package/lib/organisms/ProtocolDeck/index.d.ts +1 -0
  144. package/lib/organisms/Toolbox/index.d.ts +2 -0
  145. package/lib/organisms/index.d.ts +4 -3
  146. package/lib/primitives/Box.d.ts +3 -7
  147. package/lib/primitives/Btn.d.ts +2 -55
  148. package/lib/primitives/Buttons/NewPrimaryBtn.d.ts +8 -0
  149. package/lib/primitives/Buttons/NewSecondaryBtn.d.ts +8 -0
  150. package/lib/primitives/Flex.d.ts +3 -7
  151. package/lib/primitives/ForeignObject.d.ts +8 -18
  152. package/lib/primitives/Link.d.ts +3 -7
  153. package/lib/primitives/Svg.d.ts +4 -13
  154. package/lib/primitives/Text.d.ts +5 -7
  155. package/lib/primitives/index.d.ts +2 -0
  156. package/lib/primitives/style-props.d.ts +3 -3
  157. package/lib/primitives/types.d.ts +10 -3
  158. package/lib/src/alerts/alerts.module.css +103 -0
  159. package/lib/src/atoms/StyledText/placeholderstyledtext.module.css +26 -0
  160. package/lib/src/buttons/buttons.module.css +428 -0
  161. package/lib/src/controls/styles.module.css +103 -0
  162. package/lib/src/forms/Select.module.css +118 -0
  163. package/lib/src/forms/SelectField.module.css +16 -0
  164. package/lib/src/forms/forms.module.css +240 -0
  165. package/lib/src/hardware-sim/BaseDeck/basedeck.module.css +20 -0
  166. package/lib/src/hardware-sim/Deck/deck.module.css +54 -0
  167. package/lib/src/hardware-sim/Labware/labware.module.css +8 -0
  168. package/lib/src/hardware-sim/RobotCoordinateSpace/robotcoordinatespace.module.css +3 -0
  169. package/lib/src/icons/icon.module.css +10 -0
  170. package/lib/src/index.module.css +9 -0
  171. package/lib/src/instrument/PipetteSelect.module.css +14 -0
  172. package/lib/src/legacy-hardware-sim/LabwareNameOverlay.module.css +20 -0
  173. package/lib/src/legacy-hardware-sim/ModuleItem.module.css +98 -0
  174. package/lib/src/lists/lists.module.css +171 -0
  175. package/lib/src/modals/modals.module.css +275 -0
  176. package/lib/src/molecules/DeckInfoLabel/deckinfolabel.module.css +42 -0
  177. package/lib/src/molecules/ReleaseNotes/styles.module.css +66 -0
  178. package/lib/src/nav/SidePanel.module.css +34 -0
  179. package/lib/src/slotmap/styles.module.css +18 -0
  180. package/lib/src/structure/Pill.module.css +16 -0
  181. package/lib/src/structure/Splash.module.css +16 -0
  182. package/lib/src/structure/structure.module.css +114 -0
  183. package/lib/src/styles/borders.module.css +20 -0
  184. package/lib/src/styles/colors.module.css +58 -0
  185. package/lib/src/styles/global.css +179 -0
  186. package/lib/src/styles/index.module.css +8 -0
  187. package/lib/src/styles/typography.module.css +23 -0
  188. package/lib/src/tooltips/tooltips.module.css +72 -0
  189. package/lib/structure/Pill.d.ts +3 -3
  190. package/lib/style.css +1 -1
  191. package/lib/testing/utils/matchers.d.ts +0 -1
  192. package/lib/utils/__tests__/setRefs.test.d.ts +1 -0
  193. package/lib/utils/__tests__/truncateString.test.d.ts +1 -0
  194. package/lib/utils/humanizeLabwareType.d.ts +1 -0
  195. package/lib/utils/index.d.ts +4 -0
  196. package/lib/utils/setRefs.d.ts +2 -0
  197. package/lib/{utils.d.ts → utils/truncateString.d.ts} +0 -2
  198. package/lib/utils/wellNameSplit.d.ts +1 -0
  199. package/package.json +21 -26
  200. package/src/index.module.css +9 -0
  201. package/src/styles/borders.module.css +20 -0
  202. package/src/styles/borders.ts +16 -0
  203. package/src/styles/colors.module.css +52 -0
  204. package/src/styles/colors.ts +58 -0
  205. package/src/styles/cursor.ts +12 -0
  206. package/src/styles/flexbox.ts +39 -0
  207. package/src/styles/global.css +180 -0
  208. package/src/styles/index.module.css +8 -0
  209. package/src/styles/index.ts +8 -0
  210. package/src/styles/layout.ts +31 -0
  211. package/src/styles/position.ts +5 -0
  212. package/src/styles/spacing.ts +11 -0
  213. package/src/styles/typography.module.css +23 -0
  214. package/src/styles/typography.ts +90 -0
  215. package/lib/legacy-hardware-sim/ModuleItem.d.ts +0 -17
  216. /package/lib/{__tests__/utils.test.d.ts → atoms/Slider/__tests__/Slider.test.d.ts} +0 -0
  217. /package/lib/{atoms/InputField/__tests__/InputField.test.d.ts → hardware-sim/DeckConfigurator/__tests__/VacuumModuleItem.test.d.ts} +0 -0
  218. /package/lib/hardware-sim/Labware/labwareInternals/{__tests__ → Wells/__tests__}/StrokedWells.test.d.ts +0 -0
  219. /package/lib/hardware-sim/Labware/labwareInternals/{__tests__ → Wells/__tests__}/WellLabels.test.d.ts +0 -0
@@ -2,14 +2,14 @@ import { Component } from 'react';
2
2
  import type { ReactNode } from 'react';
3
3
  export interface KeypressHandler {
4
4
  key: string;
5
- shiftKey?: boolean | null | undefined;
5
+ shiftKey?: boolean | null;
6
6
  onPress: () => unknown;
7
7
  }
8
8
  export interface HandleKeypressProps {
9
9
  /** array of keypress handlers to attach to the window */
10
10
  handlers: KeypressHandler[];
11
11
  /** optionally call event.preventDefault if keypress is handled */
12
- preventDefault?: boolean | null | undefined;
12
+ preventDefault?: boolean | null;
13
13
  /** wrapped children */
14
14
  children?: ReactNode;
15
15
  }
@@ -1,6 +1,6 @@
1
1
  export interface LabwareNameOverlayProps {
2
2
  title: string;
3
- subtitle?: string | null | undefined;
3
+ subtitle?: string | null;
4
4
  className?: string;
5
5
  }
6
6
  /** @deprecated use LabwareDisplayName or custom RobotCoordsForeignDiv */
@@ -1,2 +1 @@
1
1
  export * from './LabwareNameOverlay';
2
- export * from './ModuleItem';
@@ -17,7 +17,7 @@ export interface AlertModalProps {
17
17
  /** lightens overlay (alert modal over existing modal) */
18
18
  alertOverlay?: boolean;
19
19
  /** override default alert icon */
20
- iconName?: IconName | null | undefined;
20
+ iconName?: IconName | null;
21
21
  /** restricts scroll outside of Modal when open, true by default */
22
22
  restrictOuterScroll?: boolean;
23
23
  }
@@ -13,12 +13,12 @@ export interface StackingProps {
13
13
  checkboxCaption?: string;
14
14
  }
15
15
  interface CustomizeExpandButtonProps extends StyleProps {
16
- enableStackingFF: boolean;
17
16
  allowInputField: boolean;
18
- loadName: string;
17
+ isNestedDefALid: boolean;
19
18
  buttonText: string;
20
19
  buttonValue: string | number;
21
20
  onChange: ChangeEventHandler<HTMLInputElement>;
21
+ customStackLimit?: number;
22
22
  stackingProps?: StackingProps;
23
23
  disabled?: boolean;
24
24
  isSelected?: boolean;
@@ -1,23 +1,11 @@
1
- import type { IconName, ModuleIconName } from '../../icons';
2
- import type { StyleProps } from '../../primitives';
3
- interface DeckLabelProps extends StyleProps {
4
- /** deck label to display */
5
- deckLabel: string;
6
- /** deck info label icon name */
7
- iconName?: IconName;
8
- /** deck info label size large is for header text */
9
- /** when use large, need to set svgSize to 1.25rem */
10
- size?: 'default' | 'large';
11
- }
12
- interface HardwareIconProps extends StyleProps {
13
- /** hardware icon name */
14
- iconName: ModuleIconName | 'stacked';
1
+ export interface DeckInfoLabelProps {
15
2
  deckLabel?: string;
16
- }
17
- export type DeckInfoLabelProps = (DeckLabelProps | HardwareIconProps) & {
3
+ iconName?: string;
18
4
  highlight?: boolean;
5
+ size?: 'large' | 'default';
6
+ height?: string | number;
7
+ width?: string | number;
19
8
  svgSize?: string | number;
20
- };
21
- export declare const DeckInfoLabel: import("styled-components").StyledComponent<typeof DeckInfoLabelComponent, any, {}, never>;
22
- declare function DeckInfoLabelComponent({ deckLabel, iconName, highlight, size, ...styleProps }: DeckInfoLabelProps): JSX.Element;
23
- export {};
9
+ transform?: string;
10
+ }
11
+ export declare function DeckInfoLabel({ deckLabel, iconName, highlight, size, height, width, transform, svgSize, }: DeckInfoLabelProps): JSX.Element;
@@ -1,11 +1,18 @@
1
1
  import type { ModuleModel } from '@opentrons/shared-data';
2
2
  export interface DeckLabelProps {
3
- isZoomed: boolean;
3
+ /** Visible label text. */
4
4
  text: string;
5
+ /** Applies selected-state styling. */
5
6
  isSelected: boolean;
7
+ /** Renders compact styling and icon sizing for zoomed deck view. */
8
+ isZoomed: boolean;
9
+ /** Optional module model used to render a module icon in zoomed view. */
6
10
  moduleModel?: ModuleModel;
11
+ /** Optional maximum width constraint for the label container. */
7
12
  maxWidth?: string;
13
+ /** Optional border-radius value applied to label edges. */
8
14
  labelBorderRadius?: string;
15
+ /** Whether this label is the last item in a grouped sequence. */
9
16
  isLast?: boolean;
10
17
  }
11
- export declare function DeckLabel({ text, isSelected, labelBorderRadius, moduleModel, maxWidth, isLast, isZoomed, }: DeckLabelProps): JSX.Element;
18
+ export declare function DeckLabel({ text, isSelected, isZoomed, moduleModel, maxWidth, labelBorderRadius, isLast, }: DeckLabelProps): JSX.Element;
@@ -17,7 +17,7 @@ export interface DropdownOption {
17
17
  tooltipText?: string | null;
18
18
  }
19
19
  export type DropdownBorder = 'rounded' | 'neutral';
20
- type MenuPlacement = 'auto' | 'top' | 'bottom';
20
+ export type MenuPlacement = 'auto' | 'top' | 'bottom';
21
21
  export interface DropdownMenuProps {
22
22
  /** dropdown options */
23
23
  filterOptions: DropdownOption[];
@@ -40,9 +40,9 @@ export interface DropdownMenuProps {
40
40
  /** optional error */
41
41
  error?: string | null;
42
42
  /** focus handler */
43
- onFocus?: FocusEventHandler<HTMLButtonElement>;
43
+ onFocus?: FocusEventHandler<HTMLElement>;
44
44
  /** blur handler */
45
- onBlur?: FocusEventHandler<HTMLButtonElement>;
45
+ onBlur?: FocusEventHandler<HTMLElement>;
46
46
  /** optional disabled */
47
47
  disabled?: boolean;
48
48
  /** optional placement of the menu */
@@ -51,7 +51,8 @@ export interface DropdownMenuProps {
51
51
  onEnter?: (id: string) => void;
52
52
  /** optional exit handler */
53
53
  onExit?: () => void;
54
+ /** optional test id */
55
+ testId?: string;
54
56
  }
55
57
  export declare function DropdownMenu(props: DropdownMenuProps): JSX.Element;
56
58
  export declare const LINE_CLAMP_TEXT_STYLE: (lineClamp?: number, wordBreak?: boolean) => FlattenSimpleInterpolation;
57
- export {};
@@ -0,0 +1,45 @@
1
+ import type { IconName } from '../../icons';
2
+ /**
3
+ * Defines the color variants available for the IconButton.
4
+ * Can be either 'primary' or 'alert'.
5
+ */
6
+ type Variant = 'primary' | 'alert';
7
+ interface IconButtonProps {
8
+ /**
9
+ * The color variant of the button.
10
+ */
11
+ variant: Variant;
12
+ /**
13
+ * The name of the icon to be displayed.
14
+ */
15
+ iconName: IconName;
16
+ /**
17
+ * The size of the icon (e.g., '16px', '2rem').
18
+ */
19
+ iconSize: string;
20
+ /**
21
+ * The color of the icon.
22
+ */
23
+ iconColor: string;
24
+ /**
25
+ * The size of the button (width and height).
26
+ */
27
+ size: string;
28
+ /**
29
+ * The function to call when the button is clicked.
30
+ */
31
+ onClick: () => void;
32
+ /**
33
+ * Accessible label for the button.
34
+ */
35
+ ariaLabel?: string;
36
+ }
37
+ /**
38
+ * A round button component that displays a centered icon.
39
+ * It supports different color variants and sizes.
40
+ *
41
+ * @param {IconButtonProps} props The props for the component.
42
+ * @returns {JSX.Element} The rendered IconButton component.
43
+ */
44
+ export declare function NewIconButton({ variant, iconName, iconSize, iconColor, size, onClick, ariaLabel, }: IconButtonProps): JSX.Element;
45
+ export {};
@@ -1,8 +1,10 @@
1
+ import type { IconName } from '../../icons';
1
2
  interface InfoScreenProps {
2
3
  content: string;
3
4
  subContent?: string;
4
5
  backgroundColor?: string;
5
6
  height?: string;
7
+ iconName?: IconName;
6
8
  }
7
- export declare function InfoScreen({ content, subContent, backgroundColor, height, }: InfoScreenProps): JSX.Element;
9
+ export declare function InfoScreen({ content, subContent, backgroundColor, height, iconName, }: InfoScreenProps): JSX.Element;
8
10
  export {};
@@ -1,6 +1,5 @@
1
1
  import { TYPOGRAPHY } from '../../ui-style-constants';
2
- import type { ChangeEventHandler, FocusEvent, MouseEvent, MutableRefObject, ReactNode } from 'react';
3
- import type { IconName } from '../../icons';
2
+ import type { ChangeEventHandler, FocusEvent, MouseEvent, ReactNode } from 'react';
4
3
  export declare const INPUT_TYPE_NUMBER: "number";
5
4
  export declare const LEGACY_INPUT_TYPE_TEXT: "text";
6
5
  export declare const LEGACY_INPUT_TYPE_PASSWORD: "password";
@@ -30,7 +29,7 @@ export interface InputFieldProps {
30
29
  /** optional input type (default "text") */
31
30
  type?: typeof LEGACY_INPUT_TYPE_TEXT | typeof LEGACY_INPUT_TYPE_PASSWORD | typeof INPUT_TYPE_NUMBER;
32
31
  /** mouse click handler */
33
- onClick?: (event: MouseEvent<HTMLInputElement>) => unknown;
32
+ onClick?: (event: MouseEvent<HTMLElement>) => unknown;
34
33
  /** focus handler */
35
34
  onFocus?: (event: FocusEvent<HTMLInputElement>) => unknown;
36
35
  /** blur handler */
@@ -50,19 +49,21 @@ export interface InputFieldProps {
50
49
  textAlign?: typeof TYPOGRAPHY.textAlignLeft | typeof TYPOGRAPHY.textAlignCenter;
51
50
  /** small or medium input field height, relevant only */
52
51
  size?: 'medium' | 'small';
53
- /** react useRef to control input field instead of react event */
54
- ref?: MutableRefObject<HTMLInputElement | null>;
55
- /** optional IconName to display icon aligned to left of input field */
56
- leftIcon?: IconName;
57
- /** if true, show delete icon aligned to right of input field */
58
- showDeleteIcon?: boolean;
59
- /** callback passed to optional delete icon onClick */
60
- onDelete?: () => void;
52
+ /** optional element to display aligned to the left of the input field */
53
+ leftElement?: ReactNode;
54
+ /** optional element to display aligned to the right of the input field */
55
+ rightElement?: ReactNode;
61
56
  /** if true, style the background of input field to error state */
62
57
  hasBackgroundError?: boolean;
63
58
  /** optional prop to override input field border radius */
64
59
  borderRadius?: string;
65
60
  /** optional prop to override input field padding */
66
61
  padding?: string;
62
+ /** optional props for data-testid */
63
+ testId?: string;
67
64
  }
68
- export declare const InputField: import("react").ForwardRefExoticComponent<Omit<InputFieldProps, "ref"> & import("react").RefAttributes<HTMLInputElement>>;
65
+ /**
66
+ * InputField is for the Desktop application and web applications
67
+ * Please do not use this for the touchscreen application
68
+ */
69
+ export declare const InputField: import("react").ForwardRefExoticComponent<InputFieldProps & import("react").RefAttributes<HTMLInputElement>>;
@@ -1,8 +1,9 @@
1
+ import type { MouseEvent } from 'react';
1
2
  type LiquidIconSize = 'xSmall' | 'small' | 'medium';
2
3
  export interface LiquidIconProps {
3
4
  color: string;
4
5
  size?: LiquidIconSize;
5
- onClick?: () => void;
6
+ onClick?: (e: MouseEvent<HTMLButtonElement | HTMLDivElement>) => void;
6
7
  hasError?: boolean;
7
8
  }
8
9
  export declare function LiquidIcon(props: LiquidIconProps): JSX.Element;
@@ -0,0 +1,12 @@
1
+ import type { IconName } from '../../icons';
2
+ export interface RobotInfoLabelProps {
3
+ deckLabel?: string;
4
+ iconName?: IconName;
5
+ highlight?: boolean;
6
+ size?: 'large' | 'default' | 'extraLarge';
7
+ height?: string | number;
8
+ width?: string | number;
9
+ svgSize?: string | number;
10
+ transform?: string;
11
+ }
12
+ export declare function RobotInfoLabel({ deckLabel, iconName, highlight, size, height, width, transform, svgSize, }: RobotInfoLabelProps): JSX.Element;
@@ -0,0 +1,11 @@
1
+ import type { ReactNode } from 'react';
2
+ interface StepGroupProps {
3
+ title: string;
4
+ isExpand: boolean;
5
+ isActive: boolean;
6
+ handleClick: () => void;
7
+ children: ReactNode;
8
+ subtitle?: string;
9
+ }
10
+ export declare function StepGroup(props: StepGroupProps): JSX.Element;
11
+ export {};
@@ -0,0 +1,34 @@
1
+ import type { ComponentPropsWithoutRef, CSSProperties, MouseEventHandler, ReactNode } from 'react';
2
+ type NativeTextareaProps = Omit<ComponentPropsWithoutRef<'textarea'>, 'title'>;
3
+ interface TextAreaFieldProps extends NativeTextareaProps {
4
+ /** optional label */
5
+ label?: string | null;
6
+ /** if included, TextAreaField will use error style and display error instead of caption */
7
+ error?: string | null;
8
+ /** optional text for tooltip */
9
+ tooltipText?: string;
10
+ /** optional caption. hidden when `error` is given */
11
+ caption?: string | null;
12
+ /** horizontal text alignment for title, textarea, and (sub)captions */
13
+ textAlign?: 'left' | 'center';
14
+ /** optional element to display aligned to the left of the input field */
15
+ leftElement?: ReactNode;
16
+ /** optional element to display aligned to the right of the input field */
17
+ rightElement?: ReactNode;
18
+ /** if true, style the background of textarea field to error state */
19
+ hasBackgroundError?: boolean;
20
+ /** optional prop to support focus when tapping text area */
21
+ onWrapperClick?: MouseEventHandler<HTMLDivElement>;
22
+ /** optional prop to override textarea field border radius */
23
+ borderRadius?: CSSProperties['borderRadius'];
24
+ /** optional prop to override textarea field padding */
25
+ padding?: CSSProperties['padding'];
26
+ /** optional prop to override textarea field height */
27
+ height?: CSSProperties['height'];
28
+ /** optional prop to override textarea field resize default is none */
29
+ resize?: CSSProperties['resize'];
30
+ /** if true, clear out value and add '-' placeholder */
31
+ isIndeterminate?: boolean;
32
+ }
33
+ export declare const TextAreaField: import("react").ForwardRefExoticComponent<TextAreaFieldProps & import("react").RefAttributes<HTMLTextAreaElement>>;
34
+ export {};
@@ -0,0 +1,10 @@
1
+ export interface TrackData {
2
+ id: string;
3
+ value: number;
4
+ }
5
+ interface TrackSliderProps {
6
+ track: TrackData;
7
+ onChange: (id: string, newValue: number) => void;
8
+ }
9
+ export declare function TrackSlider({ track, onChange, }: TrackSliderProps): JSX.Element;
10
+ export {};
@@ -0,0 +1,6 @@
1
+ import type { TrackData } from './TrackSlider';
2
+ export interface TimelineScrubberProps {
3
+ tracks: TrackData[];
4
+ onTrackChange: (updatedTrack: TrackData) => void;
5
+ }
6
+ export declare function TimelineScrubber({ tracks, onTrackChange, }: TimelineScrubberProps): JSX.Element;
@@ -0,0 +1,56 @@
1
+ import { TYPOGRAPHY } from '../../ui-style-constants';
2
+ import type { ChangeEventHandler, FocusEvent, MouseEvent, ReactNode } from 'react';
3
+ export interface TouchInputFieldProps {
4
+ /** field is disabled if value is true */
5
+ disabled?: boolean;
6
+ /** change handler */
7
+ onChange?: ChangeEventHandler<HTMLInputElement>;
8
+ /** name of field in form */
9
+ name?: string;
10
+ /** optional ID of <input> element */
11
+ id?: string;
12
+ /** placeholder text */
13
+ placeholder?: string;
14
+ /** optional suffix component, appears to the right of input text */
15
+ units?: ReactNode;
16
+ /** current value of text in box, defaults to '' */
17
+ value?: string | number | null;
18
+ /** if included, InputField will use error style and display error instead of caption */
19
+ error?: string | null;
20
+ /** optional label */
21
+ label?: string | null;
22
+ /** optional caption */
23
+ caption?: string | null;
24
+ /** mouse click handler */
25
+ onClick?: (event: MouseEvent<HTMLElement>) => unknown;
26
+ /** focus handler */
27
+ onFocus?: (event: FocusEvent<HTMLInputElement>) => unknown;
28
+ /** blur handler */
29
+ onBlur?: (event: FocusEvent<HTMLInputElement>) => unknown;
30
+ /** makes input field read-only */
31
+ readOnly?: boolean;
32
+ /** html tabindex property */
33
+ tabIndex?: number;
34
+ /** automatically focus field on renders */
35
+ autoFocus?: boolean;
36
+ /** if true, clear out value and add '-' placeholder */
37
+ isIndeterminate?: boolean;
38
+ /** if input type is number, these are the min and max values */
39
+ max?: number | string;
40
+ min?: number | string;
41
+ /** horizontal text alignment for label, input, and (sub)captions */
42
+ textAlign?: typeof TYPOGRAPHY.textAlignLeft | typeof TYPOGRAPHY.textAlignCenter;
43
+ /** small or medium input field height */
44
+ size?: 'medium' | 'small';
45
+ /** if true, style the background of input field to error state */
46
+ hasBackgroundError?: boolean;
47
+ /** optional prop to override input field border radius */
48
+ borderRadius?: string;
49
+ /** optional prop to override input field padding */
50
+ padding?: string;
51
+ /** optional input type */
52
+ type?: 'text' | 'password' | 'number';
53
+ /** optional props for data-testid */
54
+ testId?: string;
55
+ }
56
+ export declare const TouchInputField: import("react").ForwardRefExoticComponent<TouchInputFieldProps & import("react").RefAttributes<HTMLInputElement>>;
@@ -0,0 +1 @@
1
+ import '@testing-library/jest-dom/vitest';
@@ -0,0 +1,11 @@
1
+ interface WizardHeaderProps {
2
+ title: string;
3
+ onExit?: (() => void) | null;
4
+ exitButtonCopy?: string;
5
+ totalSteps?: number | null;
6
+ currentStep?: number | null;
7
+ exitDisabled?: boolean;
8
+ hideStepText?: boolean;
9
+ }
10
+ export declare const WizardHeader: (props: WizardHeaderProps) => JSX.Element;
11
+ export {};
@@ -1,12 +1,19 @@
1
1
  export * from './Banner';
2
2
  export * from './CustomizeExpandButton';
3
- export * from './DeckInfoLabel';
4
3
  export * from './DeckLabel';
5
4
  export * from './DropdownMenu';
5
+ export * from './IconButton';
6
6
  export * from './InfoScreen';
7
+ export * from './InputField';
7
8
  export * from './LiquidIcon';
8
9
  export * from './ListAccordion';
9
10
  export * from './ParametersTable';
10
11
  export * from './ReleaseNotes';
12
+ export * from './RobotInfoLabel';
13
+ export * from './StepGroup';
11
14
  export * from './Tabs';
15
+ export * from './TextAreaField';
12
16
  export * from './TextListTableContent';
17
+ export * from './TimelineScrubber';
18
+ export * from './TouchInputField';
19
+ export * from './WizardHeader';
@@ -0,0 +1,3 @@
1
+ import type { CompletedProtocolAnalysis, ProtocolAnalysisOutput, RunTimeCommand } from '@opentrons/shared-data';
2
+ import type { CommandTextData } from './useCommandTextString';
3
+ export declare function getCommandTextData(protocolData: CompletedProtocolAnalysis | ProtocolAnalysisOutput, protocolCommands?: RunTimeCommand[]): CommandTextData;
@@ -2,8 +2,9 @@ import { LegacyStyledText, StyledText } from '../../atoms';
2
2
  import type { ComponentProps } from 'react';
3
3
  import type { LabwareDefinition, RobotType, RunTimeCommand } from '@opentrons/shared-data';
4
4
  import type { StyleProps } from '../../primitives';
5
- import type { CommandTextData } from '../ProtocolTimelineScrubber/types';
5
+ import type { CommandTextData } from './useCommandTextString';
6
6
  export * from './useCommandTextString';
7
+ export * from './getCommandData';
7
8
  interface LegacySTProps {
8
9
  as?: ComponentProps<typeof LegacyStyledText>['as'];
9
10
  modernStyledTextDefaults?: false;
@@ -1,12 +1,12 @@
1
+ import * as utils from './utils';
1
2
  import type { TFunction } from 'i18next';
2
3
  import type { LabwareDefinition, RobotType, RunTimeCommand } from '@opentrons/shared-data';
3
- import type { CommandTextData } from '../../ProtocolTimelineScrubber/types';
4
4
  import type { TCProfileCycleText, TCProfileStepText } from './utils';
5
5
  export * from './utils';
6
6
  export interface UseCommandTextStringParams {
7
7
  command: RunTimeCommand | null;
8
8
  allRunDefs: LabwareDefinition[];
9
- commandTextData: CommandTextData | null;
9
+ commandTextData: utils.CommandTextData | null;
10
10
  robotType: RobotType;
11
11
  }
12
12
  export type GetCommandText = UseCommandTextStringParams & {
@@ -26,5 +26,10 @@ export interface GetTCRunExtendedProfileCommandTextResult {
26
26
  commandText: string;
27
27
  profileElementTexts: Array<TCProfileStepText | TCProfileCycleText>;
28
28
  }
29
- export type GetCommandTextResult = GetGenericCommandTextResult | GetTCRunProfileCommandTextResult | GetTCRunExtendedProfileCommandTextResult;
29
+ export interface GetTCStartRunExtendedProfileCommandTextResult {
30
+ kind: 'thermocycler/startRunExtendedProfile';
31
+ commandText: string;
32
+ profileElementTexts: Array<TCProfileStepText | TCProfileCycleText>;
33
+ }
34
+ export type GetCommandTextResult = GetGenericCommandTextResult | GetTCRunProfileCommandTextResult | GetTCRunExtendedProfileCommandTextResult | GetTCStartRunExtendedProfileCommandTextResult;
30
35
  export declare function useCommandTextString(params: UseCommandTextStringParams): GetCommandTextResult;
@@ -0,0 +1,3 @@
1
+ import type { ConcurrentRunTimeCommand } from '@opentrons/shared-data/command';
2
+ import type { HandlesCommands } from '../types';
3
+ export declare function getConcurrentCommandText({ command, t, }: HandlesCommands<ConcurrentRunTimeCommand>): string;
@@ -0,0 +1,3 @@
1
+ import type { HeaterShakerSetShakeSpeedRunTimeCommand } from '@opentrons/shared-data/command';
2
+ import type { HandlesCommands } from '../types';
3
+ export declare function getHSConcurrentShakeSpeedCommandText({ command, t, }: HandlesCommands<HeaterShakerSetShakeSpeedRunTimeCommand>): string;
@@ -0,0 +1,3 @@
1
+ import type { RobotDevicesRunTimeCommand } from '@opentrons/shared-data/command';
2
+ import type { HandlesCommands } from '../types';
3
+ export declare function getRobotDevicesCommandText({ command, t, }: HandlesCommands<RobotDevicesRunTimeCommand>): string;
@@ -0,0 +1,4 @@
1
+ import type { TCStartRunExtendedProfileRunTimeCommand } from '@opentrons/shared-data/command';
2
+ import type { GetTCStartRunExtendedProfileCommandTextResult } from '../..';
3
+ import type { HandlesCommands } from '../types';
4
+ export declare function getTCStartRunExtendedProfileCommandText({ command, t, }: HandlesCommands<TCStartRunExtendedProfileRunTimeCommand>): GetTCStartRunExtendedProfileCommandTextResult;
@@ -0,0 +1,3 @@
1
+ import type { SetTipStateRunTimeCommand } from '@opentrons/shared-data/command';
2
+ import type { HandlesCommands } from '../types';
3
+ export declare function getTipStateCommandText({ command, allRunDefs, t, commandTextData, }: HandlesCommands<SetTipStateRunTimeCommand>): string;
@@ -2,7 +2,9 @@ export * from './getLoadCommandText';
2
2
  export * from './getTemperatureCommandText';
3
3
  export * from './getTCRunProfileCommandText';
4
4
  export * from './getTCRunExtendedProfileCommandText';
5
+ export * from './getTCStartRunExtendedProfileCommandText';
5
6
  export * from './getHSShakeSpeedCommandText';
7
+ export * from './getHSConcurrentShakeSpeedCommandTex';
6
8
  export * from './getMoveToSlotCommandText';
7
9
  export * from './getMoveRelativeCommandText';
8
10
  export * from './getMoveToCoordinatesCommandText';
@@ -26,3 +28,6 @@ export * from './getRailLightsCommandText';
26
28
  export * from './getAbsorbanceReaderCommandText';
27
29
  export * from './getFlexStackerCommandText';
28
30
  export * from './getRobotCommandText';
31
+ export * from './getConcurrentCommandText';
32
+ export * from './getTipStateCommandText';
33
+ export * from './getRobotDevicesCommandText';
@@ -4,11 +4,13 @@ import type { LocationFullParams, LocationSlotOnlyParams } from './getLabwareLoc
4
4
  export interface DisplayLocationSlotOnlyParams extends Omit<LocationSlotOnlyParams, 'location'> {
5
5
  t: TFunction;
6
6
  isOnDevice?: boolean;
7
+ includeSlotText?: boolean;
7
8
  location?: LabwareLocation | LabwareLocationSequence | null;
8
9
  }
9
10
  export interface DisplayLocationFullParams extends Omit<LocationFullParams, 'location'> {
10
11
  t: TFunction;
11
12
  isOnDevice?: boolean;
13
+ includeSlotText?: boolean;
12
14
  location?: LabwareLocation | LabwareLocationSequence | null;
13
15
  }
14
16
  export type DisplayLocationParams = DisplayLocationSlotOnlyParams | DisplayLocationFullParams;
@@ -1,2 +1,3 @@
1
+ import type { TFunction } from 'i18next';
1
2
  import type { Liquid } from '@opentrons/shared-data';
2
- export declare function getLiquidDisplayName(liquids: Liquid[], liquidId: string): string;
3
+ export declare function getLiquidDisplayName(liquids: Liquid[], liquidId: string, t: TFunction): string;
@@ -1,4 +1,4 @@
1
- import type { LoadedLabware, LoadedModule, LoadedPipette, RunTimeCommand } from '@opentrons/shared-data';
1
+ import type { CompletedProtocolAnalysis, LoadedLabware, LoadedModule, LoadedPipette, RunTimeCommand } from '@opentrons/shared-data';
2
2
  import type { GetCommandText, UseCommandTextStringParams } from '..';
3
3
  export type HandlesCommands<T extends RunTimeCommand> = Omit<GetCommandText, 'command'> & UseCommandTextStringParams & {
4
4
  command: T;
@@ -6,3 +6,4 @@ export type HandlesCommands<T extends RunTimeCommand> = Omit<GetCommandText, 'co
6
6
  export type LoadedPipettes = LoadedPipette[] | Record<string, LoadedPipette>;
7
7
  export type LoadedLabwares = LoadedLabware[] | Record<string, LoadedLabware>;
8
8
  export type LoadedModules = LoadedModule[] | Record<string, LoadedModule>;
9
+ export type CommandTextData = Pick<CompletedProtocolAnalysis, 'pipettes' | 'labware' | 'modules' | 'liquids' | 'commands'>;
@@ -8,6 +8,7 @@ interface DeckLabelSetProps {
8
8
  height: number;
9
9
  invert?: boolean;
10
10
  showModuleIcon?: boolean;
11
+ showBorder?: boolean;
11
12
  }
12
13
  export declare const DeckLabelSet: import("react").ForwardRefExoticComponent<DeckLabelSetProps & import("react").RefAttributes<HTMLDivElement>>;
13
14
  export {};
@@ -5,7 +5,6 @@ interface FixtureOptionProps {
5
5
  optionName: string;
6
6
  secondaryButtonText?: string;
7
7
  buttonText: string;
8
- isOnDevice: boolean;
9
8
  }
10
9
  export declare function FixtureOption(props: FixtureOptionProps): JSX.Element;
11
10
  export {};
@@ -0,0 +1,7 @@
1
+ interface LabwareDetailsWithCountProps {
2
+ title: string;
3
+ subTitle?: string;
4
+ quantity?: number;
5
+ }
6
+ export declare function LabwareDetailsWithCount({ title, subTitle, quantity: label, }: LabwareDetailsWithCountProps): JSX.Element;
7
+ export {};
@@ -0,0 +1,12 @@
1
+ import type { LabwareDefinition } from '@opentrons/shared-data';
2
+ interface LabwareInfoOverlayProps {
3
+ definition: LabwareDefinition;
4
+ labwareId: string;
5
+ displayName: string;
6
+ labwareHasLiquid?: boolean;
7
+ hover?: boolean;
8
+ xOffset?: number;
9
+ yOffset?: number;
10
+ }
11
+ export declare const LabwareInfoOverlay: (props: LabwareInfoOverlayProps) => JSX.Element;
12
+ export {};