@opentrons/components 0.1.6-alpha.7 → 0.1.6-alpha.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/alerts/AlertItem.d.ts +1 -1
- package/lib/atoms/Checkbox/index.d.ts +24 -0
- package/lib/atoms/CheckboxField/index.d.ts +1 -1
- package/lib/atoms/Chip/index.d.ts +1 -1
- package/lib/atoms/Divider/index.d.ts +5 -0
- package/lib/atoms/InputField/index.d.ts +68 -0
- package/lib/atoms/ListButton/ListButtonChildren/ListButtonAccordion.d.ts +10 -0
- package/lib/atoms/ListButton/ListButtonChildren/ListButtonAccordionContainer.d.ts +7 -0
- package/lib/atoms/ListButton/ListButtonChildren/ListButtonRadioButton.d.ts +14 -0
- package/lib/atoms/ListButton/ListButtonChildren/index.d.ts +3 -0
- package/lib/atoms/ListButton/__tests__/ListButton.test.d.ts +1 -0
- package/lib/atoms/ListButton/index.d.ts +11 -0
- package/lib/atoms/ListItem/ListItemChildren/ListItemCustomize.d.ts +15 -0
- package/lib/atoms/ListItem/ListItemChildren/ListItemDescriptor.d.ts +7 -0
- package/lib/atoms/ListItem/ListItemChildren/index.d.ts +2 -0
- package/lib/atoms/ListItem/__tests__/ListItem.test.d.ts +1 -0
- package/lib/atoms/ListItem/index.d.ts +14 -0
- package/lib/atoms/MenuList/MenuItem.d.ts +7 -0
- package/lib/atoms/MenuList/OverflowBtn.d.ts +7 -0
- package/lib/atoms/MenuList/__tests__/MenuItem.test.d.ts +1 -0
- package/lib/atoms/MenuList/__tests__/MenuList.test.d.ts +1 -0
- package/lib/atoms/MenuList/__tests__/OverflowBtn.test.d.ts +1 -0
- package/lib/atoms/MenuList/index.d.ts +8 -0
- package/lib/atoms/Snackbar/__tests__/Snackbar.test.d.ts +1 -0
- package/lib/atoms/Snackbar/index.d.ts +7 -0
- package/lib/atoms/StyledText/LegacyStyledText.d.ts +6 -0
- package/lib/atoms/StyledText/StyledText.d.ts +154 -0
- package/lib/atoms/StyledText/index.d.ts +2 -6
- package/lib/atoms/Tag/__tests__/Tag.test.d.ts +1 -0
- package/lib/atoms/Tag/index.d.ts +13 -0
- package/lib/atoms/Toast/__tests__/ODDToast.test.d.ts +1 -0
- package/lib/atoms/Toast/__tests__/Toast.test.d.ts +1 -0
- package/lib/atoms/Toast/index.d.ts +25 -0
- package/lib/atoms/ToggleGroup/__tests__/ToggleGroup.test.d.ts +1 -0
- package/lib/atoms/ToggleGroup/index.d.ts +9 -0
- package/lib/atoms/Tooltip/__tests__/Tooltip.test.d.ts +1 -0
- package/lib/atoms/Tooltip/index.d.ts +11 -0
- package/lib/atoms/buttons/AltPrimaryButton.d.ts +1 -0
- package/lib/atoms/buttons/EmptySelectorButton.d.ts +10 -0
- package/lib/atoms/buttons/LargeButton.d.ts +17 -0
- package/lib/atoms/buttons/RadioButton.d.ts +21 -0
- package/lib/atoms/buttons/__tests__/AltPrimaryButton.test.d.ts +1 -0
- package/lib/atoms/buttons/__tests__/EmptySelectorButton.test.d.ts +1 -0
- package/lib/atoms/buttons/__tests__/LargeButton.test.d.ts +1 -0
- package/lib/atoms/buttons/__tests__/RadioButton.test.d.ts +1 -0
- package/lib/atoms/buttons/index.d.ts +3 -0
- package/lib/atoms/index.d.ts +14 -0
- package/lib/buttons/Button.d.ts +3 -2
- package/lib/controls/ControlInfo.d.ts +1 -1
- package/lib/controls/LabeledButton.d.ts +1 -1
- package/lib/controls/LabeledCheckbox.d.ts +1 -1
- package/lib/controls/LabeledControl.d.ts +1 -1
- package/lib/controls/LabeledRadioGroup.d.ts +1 -1
- package/lib/controls/LabeledSelect.d.ts +1 -1
- package/lib/controls/LabeledToggle.d.ts +1 -1
- package/lib/controls/StackedLabeledControl.d.ts +1 -1
- package/lib/forms/DeprecatedCheckboxField.d.ts +1 -1
- package/lib/forms/DropdownField.d.ts +3 -3
- package/lib/forms/FormGroup.d.ts +1 -1
- package/lib/forms/{InputField.d.ts → LegacyInputField.d.ts} +4 -4
- package/lib/forms/RadioGroup.d.ts +1 -1
- package/lib/forms/Select.d.ts +1 -1
- package/lib/forms/SelectField.d.ts +1 -1
- package/lib/forms/ToggleField.d.ts +1 -1
- package/lib/forms/index.d.ts +1 -1
- package/lib/hardware-sim/BaseDeck/BaseDeck.d.ts +9 -2
- package/lib/hardware-sim/BaseDeck/SingleSlotFixture.d.ts +1 -1
- package/lib/hardware-sim/BaseDeck/SlotBase.d.ts +1 -1
- package/lib/hardware-sim/BaseDeck/SlotClip.d.ts +1 -1
- package/lib/hardware-sim/BaseDeck/StagingAreaFixture.d.ts +1 -1
- package/lib/hardware-sim/BaseDeck/WasteChuteFixture.d.ts +2 -3
- package/lib/hardware-sim/BaseDeck/WasteChuteStagingAreaFixture.d.ts +1 -1
- package/lib/hardware-sim/Deck/MoveLabwareOnDeck.d.ts +1 -2
- package/lib/hardware-sim/Deck/RobotCoordsForeignDiv.d.ts +1 -1
- package/lib/hardware-sim/Deck/RobotCoordsForeignObject.d.ts +1 -1
- package/lib/hardware-sim/Deck/RobotCoordsText.d.ts +1 -1
- package/lib/hardware-sim/Deck/RobotWorkSpace.d.ts +1 -1
- package/lib/hardware-sim/DeckConfigurator/AbsorbanceReaderFixture.d.ts +10 -0
- package/lib/hardware-sim/DeckConfigurator/index.d.ts +1 -1
- package/lib/hardware-sim/DeckSlotLocation/index.d.ts +1 -1
- package/lib/hardware-sim/Labware/Labware.d.ts +39 -0
- package/lib/hardware-sim/Labware/LabwareAdapter/OpentronsAutoclavableDeckRiser.d.ts +1 -0
- package/lib/hardware-sim/Labware/LabwareAdapter/OpentronsToughPCRAutoSealingLid.d.ts +1 -0
- package/lib/hardware-sim/Labware/LabwareAdapter/index.d.ts +8 -0
- package/lib/hardware-sim/Labware/LabwareRender.d.ts +6 -2
- package/lib/hardware-sim/Labware/LabwareStackRender.d.ts +20 -0
- package/lib/hardware-sim/Labware/__tests__/Labware.test.d.ts +1 -0
- package/lib/hardware-sim/Labware/index.d.ts +2 -0
- package/lib/hardware-sim/Labware/labwareInternals/FilledWells.d.ts +1 -0
- package/lib/hardware-sim/Labware/labwareInternals/LabwareOutline.d.ts +4 -0
- package/lib/hardware-sim/Labware/labwareInternals/LabwareWellLabels.d.ts +15 -0
- package/lib/hardware-sim/Labware/labwareInternals/StaticLabware.d.ts +9 -1
- package/lib/hardware-sim/Labware/labwareInternals/Well.d.ts +2 -0
- package/lib/hardware-sim/Labware/labwareInternals/WellLabels.d.ts +1 -1
- package/lib/hardware-sim/Labware/labwareInternals/__tests__/LabwareWellLabels.test.d.ts +1 -0
- package/lib/hardware-sim/Labware/labwareInternals/index.d.ts +1 -0
- package/lib/hardware-sim/Labware/labwareInternals/types.d.ts +1 -1
- package/lib/hardware-sim/Module/ModuleTag.d.ts +1 -1
- package/lib/hardware-sim/Module/PlateReader.d.ts +1 -0
- package/lib/hardware-sim/Module/Thermocycler/index.d.ts +1 -1
- package/lib/hardware-sim/Module/index.d.ts +2 -2
- package/lib/hardware-sim/Pipette/PipetteRender.d.ts +1 -1
- package/lib/hardware-sim/ProtocolDeck/LabwareInfo.d.ts +2 -2
- package/lib/hardware-sim/ProtocolDeck/index.d.ts +4 -2
- package/lib/hardware-sim/ProtocolDeck/utils/index.d.ts +1 -0
- package/lib/hardware-sim/RobotCoordinateSpace/RobotCoordinateSpace.d.ts +1 -1
- package/lib/hardware-sim/RobotCoordinateSpace/RobotCoordinateSpaceWithRef.d.ts +3 -2
- package/lib/hardware-sim/utils.d.ts +1 -1
- package/lib/helix-design-system/colors.d.ts +11 -0
- package/lib/helix-design-system/index.d.ts +2 -0
- package/lib/helix-design-system/product/index.d.ts +1 -0
- package/lib/helix-design-system/product/typography.d.ts +79 -0
- package/lib/helix-design-system/style.d.ts +1 -0
- package/lib/hooks/index.d.ts +1 -0
- package/lib/hooks/useConditionalConfirm.d.ts +3 -2
- package/lib/hooks/useDrag.d.ts +1 -1
- package/lib/hooks/useLongPress.d.ts +1 -1
- package/lib/hooks/useMenuHandleClickOutside.d.ts +9 -0
- package/lib/hooks/useSelectDeckLocation/index.d.ts +1 -2
- package/lib/hooks/useSwipe.d.ts +1 -1
- package/lib/icons/Icon.d.ts +1 -1
- package/lib/icons/ModuleIcon.d.ts +2 -2
- package/lib/icons/icon-data.d.ts +4 -586
- package/lib/index.d.ts +1 -1
- package/lib/{index.mjs → index.js} +8783 -6217
- package/lib/instrument/InstrumentDiagram.d.ts +1 -1
- package/lib/instrument/InstrumentInfo.d.ts +1 -1
- package/lib/lists/SidePanelGroup.d.ts +1 -1
- package/lib/lists/index.d.ts +0 -1
- package/lib/modals/AlertModal.d.ts +2 -1
- package/lib/modals/ContinueModal.d.ts +1 -0
- package/lib/modals/LegacyModal.d.ts +24 -0
- package/lib/modals/Modal.d.ts +21 -20
- package/lib/modals/ModalHeader.d.ts +13 -0
- package/lib/modals/ModalShell.d.ts +11 -2
- package/lib/modals/Overlay.d.ts +1 -1
- package/lib/modals/SpinnerModal.d.ts +1 -0
- package/lib/modals/SpinnerModalPage.d.ts +2 -1
- package/lib/modals/__tests__/Modal.test.d.ts +1 -0
- package/lib/modals/__tests__/ModalHeader.test.d.ts +1 -0
- package/lib/modals/__tests__/ModalShell.test.d.ts +1 -0
- package/lib/modals/index.d.ts +5 -5
- package/lib/molecules/Banner/__tests__/Banner.test.d.ts +1 -0
- package/lib/molecules/Banner/index.d.ts +23 -0
- package/lib/molecules/DeckInfoLabel/__tests__/DeckInfoLabel.test.d.ts +1 -0
- package/lib/molecules/DeckInfoLabel/index.d.ts +19 -0
- package/lib/molecules/DeckLabel/__tests__/DeckLabel.test.d.ts +1 -0
- package/lib/molecules/DeckLabel/index.d.ts +10 -0
- package/lib/molecules/DropdownMenu/__tests__/DropdownMenu.test.d.ts +1 -0
- package/lib/molecules/DropdownMenu/index.d.ts +41 -0
- package/lib/molecules/InfoScreen/__tests__/InfoScreen.test.d.ts +1 -0
- package/lib/molecules/InfoScreen/index.d.ts +6 -0
- package/lib/molecules/LiquidIcon/__tests__/LiquidIcon.test.d.ts +1 -0
- package/lib/molecules/LiquidIcon/index.d.ts +9 -0
- package/lib/molecules/Tabs/__tests__/Tabs.test.d.ts +1 -0
- package/lib/molecules/Tabs/index.d.ts +10 -0
- package/lib/molecules/index.d.ts +7 -3
- package/lib/nav/SidePanel.d.ts +1 -1
- package/lib/organisms/DeckLabelSet/__tests__/DeckLabelSet.test.d.ts +1 -0
- package/lib/organisms/DeckLabelSet/index.d.ts +11 -0
- package/lib/organisms/EndUserAgreementFooter/__tests__/EndUserAgreementFooter.test.d.ts +1 -0
- package/lib/organisms/EndUserAgreementFooter/index.d.ts +1 -0
- package/lib/organisms/Toolbox/__tests__/Toolbox.test.d.ts +1 -0
- package/lib/organisms/Toolbox/index.d.ts +20 -0
- package/lib/organisms/index.d.ts +3 -0
- package/lib/primitives/Btn.d.ts +1 -1
- package/lib/structure/Card.d.ts +1 -1
- package/lib/structure/LabeledValue.d.ts +1 -1
- package/lib/structure/Pill.d.ts +1 -1
- package/lib/structure/TitleBar.d.ts +2 -2
- package/lib/structure/index.d.ts +0 -1
- package/lib/style.css +3786 -0
- package/lib/styles/cursor.d.ts +10 -0
- package/lib/styles/flexbox.d.ts +5 -0
- package/lib/styles/index.d.ts +1 -0
- package/lib/styles/layout.d.ts +1 -0
- package/lib/testing/utils/renderWithProviders.d.ts +2 -3
- package/lib/tooltips/DeprecatedTooltip.d.ts +1 -1
- package/lib/tooltips/{Tooltip.d.ts → LegacyTooltip.d.ts} +2 -2
- package/lib/tooltips/index.d.ts +1 -1
- package/lib/ui-style-constants/responsiveness.d.ts +1 -0
- package/lib/ui-style-constants/typography.d.ts +1 -0
- package/package.json +5 -7
- package/tsconfig.json +5 -2
- package/{vite.config.ts → vite.config.mts} +19 -6
- package/lib/lists/ListItem.d.ts +0 -37
- package/lib/modals/BaseModal.d.ts +0 -26
- package/lib/modals/ModalPage.d.ts +0 -16
- package/lib/molecules/LocationIcon/index.d.ts +0 -15
- package/lib/molecules/ParametersTable/InfoScreen.d.ts +0 -6
- package/lib/molecules/RoundTab.d.ts +0 -8
- package/lib/structure/PageTabs.d.ts +0 -11
- package/lib/tabbedNav/NavTab.d.ts +0 -25
- package/lib/tabbedNav/OutsideLinkTab.d.ts +0 -24
- package/lib/tabbedNav/TabbedNavBar.d.ts +0 -7
- package/lib/tabbedNav/index.d.ts +0 -3
- /package/lib/atoms/{StyledText/__tests__/StyledText.test.d.ts → Checkbox/__tests__/Checkbox.test.d.ts} +0 -0
- /package/lib/{modals/__tests__/BaseModal.test.d.ts → atoms/InputField/__tests__/InputField.test.d.ts} +0 -0
- /package/lib/{molecules/LocationIcon/__tests__/LocationIcon.test.d.ts → atoms/ListButton/__tests__/ListButtonAccordion.test.d.ts} +0 -0
- /package/lib/{molecules/ParametersTable/__tests__/InfoScreen.test.d.ts → atoms/ListButton/__tests__/ListButtonRadioButton.test.d.ts} +0 -0
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export declare const CURSOR_AUTO = "auto";
|
|
2
|
+
export declare const CURSOR_CROSSHAIR = "crosshair";
|
|
3
|
+
export declare const CURSOR_DEFAULT = "default";
|
|
4
|
+
export declare const CURSOR_GRAB = "grab";
|
|
5
|
+
export declare const CURSOR_GRABBING = "grabbing";
|
|
6
|
+
export declare const CURSOR_HELP = "help";
|
|
7
|
+
export declare const CURSOR_NOT_ALLOWED = "not-allowed";
|
|
8
|
+
export declare const CURSOR_POINTER = "pointer";
|
|
9
|
+
export declare const CURSOR_ZOOM_IN = "zoom-in";
|
|
10
|
+
export declare const CURSOR_WAIT = "wait";
|
package/lib/styles/flexbox.d.ts
CHANGED
|
@@ -27,3 +27,8 @@ export declare const DIRECTION_COLUMN_REVERSE = "column-reverse";
|
|
|
27
27
|
export declare const WRAP = "wrap";
|
|
28
28
|
export declare const NO_WRAP = "nowrap";
|
|
29
29
|
export declare const WRAP_REVERSE = "wrap-reverse";
|
|
30
|
+
export declare const WHITE_SPACE_NORMAL = "normal";
|
|
31
|
+
export declare const WHITE_SPACE_PRE = "pre";
|
|
32
|
+
export declare const WHITE_SPACE_PRE_WRAP = "pre-wrap";
|
|
33
|
+
export declare const WHITE_SPACE_PRE_LINE = "pre-line";
|
|
34
|
+
export declare const WHITE_SPACE_BREAK_SPACES = "break-spaces";
|
package/lib/styles/index.d.ts
CHANGED
package/lib/styles/layout.d.ts
CHANGED
|
@@ -6,6 +6,7 @@ export declare const DISPLAY_FLEX = "flex";
|
|
|
6
6
|
export declare const DISPLAY_TABLE = "table";
|
|
7
7
|
export declare const DISPLAY_TABLE_ROW = "table-row";
|
|
8
8
|
export declare const DISPLAY_TABLE_CELL = "table-cell";
|
|
9
|
+
export declare const DISPLAY_GRID = "grid";
|
|
9
10
|
export declare const SIZE_AUTO = "auto";
|
|
10
11
|
export declare const SIZE_1 = "1rem";
|
|
11
12
|
export declare const SIZE_2 = "2rem";
|
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
1
|
+
import type * as React from 'react';
|
|
2
2
|
import { I18nextProvider } from 'react-i18next';
|
|
3
|
-
import { RenderResult } from '@testing-library/react';
|
|
3
|
+
import type { RenderResult, RenderOptions } from '@testing-library/react';
|
|
4
4
|
import type { Store } from 'redux';
|
|
5
|
-
import type { RenderOptions } from '@testing-library/react';
|
|
6
5
|
export interface RenderWithProvidersOptions<State> extends RenderOptions {
|
|
7
6
|
initialState?: State;
|
|
8
7
|
i18nInstance: React.ComponentProps<typeof I18nextProvider>['i18n'];
|
|
@@ -2,7 +2,7 @@ import * as React from 'react';
|
|
|
2
2
|
import type { CSSProperties } from 'react';
|
|
3
3
|
import type { Placement } from './types';
|
|
4
4
|
import type { StyleProps } from '../primitives';
|
|
5
|
-
export interface
|
|
5
|
+
export interface LegacyTooltipProps extends StyleProps {
|
|
6
6
|
/** Whether or not the tooltip should be rendered */
|
|
7
7
|
visible: boolean;
|
|
8
8
|
/** Contents of the tooltip */
|
|
@@ -25,7 +25,7 @@ export interface TooltipProps extends StyleProps {
|
|
|
25
25
|
* Tooltip component that renders based on its `visible` prop. For use with the
|
|
26
26
|
* `useTooltip` and `useHoverTooltip` hooks. See examples in `Tooltip.md`.
|
|
27
27
|
*/
|
|
28
|
-
export declare const
|
|
28
|
+
export declare const LegacyTooltip: React.ForwardRefExoticComponent<LegacyTooltipProps & React.RefAttributes<HTMLDivElement>>;
|
|
29
29
|
export interface ArrowProps {
|
|
30
30
|
placement: Placement | null;
|
|
31
31
|
arrowRef: React.RefCallback<HTMLElement>;
|
package/lib/tooltips/index.d.ts
CHANGED
|
@@ -26,6 +26,7 @@ export declare const lineHeight20 = "1.25rem";
|
|
|
26
26
|
export declare const lineHeight18 = "1.125rem";
|
|
27
27
|
export declare const lineHeight16 = "1rem";
|
|
28
28
|
export declare const lineHeight12 = "0.75rem";
|
|
29
|
+
export declare const lineHeightNormal = "normal";
|
|
29
30
|
export declare const fontStyleNormal = "normal";
|
|
30
31
|
export declare const fontStyleItalic = "italic";
|
|
31
32
|
export declare const textTransformNone = "none";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@opentrons/components",
|
|
3
|
-
"version": "0.1.6-alpha.
|
|
3
|
+
"version": "0.1.6-alpha.8",
|
|
4
4
|
"description": "React components library for Opentrons' projects",
|
|
5
5
|
"source": "src/index.ts",
|
|
6
6
|
"types": "lib/index.d.ts",
|
|
@@ -20,11 +20,10 @@
|
|
|
20
20
|
"peerDependencies": {
|
|
21
21
|
"react": "18.2.0",
|
|
22
22
|
"react-dom": "18.2.0",
|
|
23
|
-
"
|
|
24
|
-
"@types/react-router-dom": "5.3.3"
|
|
23
|
+
"styled-components": "5.3.6"
|
|
25
24
|
},
|
|
26
25
|
"dependencies": {
|
|
27
|
-
"@opentrons/shared-data": "0.1.6-alpha.
|
|
26
|
+
"@opentrons/shared-data": "0.1.6-alpha.8",
|
|
28
27
|
"@popperjs/core": "2.1.1",
|
|
29
28
|
"@react-spring/types": "9.6.1",
|
|
30
29
|
"@react-spring/web": "9.6.1",
|
|
@@ -33,12 +32,11 @@
|
|
|
33
32
|
"@types/styled-components": "^5.1.26",
|
|
34
33
|
"@types/webpack-env": "^1.16.0",
|
|
35
34
|
"classnames": "2.2.5",
|
|
36
|
-
"interactjs": "^1.10.
|
|
35
|
+
"interactjs": "^1.10.27",
|
|
37
36
|
"lodash": "4.17.21",
|
|
38
|
-
"react-i18next": "
|
|
37
|
+
"react-i18next": "14.0.0",
|
|
39
38
|
"react-popper": "1.0.0",
|
|
40
39
|
"react-remove-scroll": "2.4.3",
|
|
41
|
-
"react-router-dom": "5.3.4",
|
|
42
40
|
"react-select": "5.4.0",
|
|
43
41
|
"redux": "4.0.5",
|
|
44
42
|
"styled-components": "5.3.6"
|
package/tsconfig.json
CHANGED
|
@@ -9,7 +9,10 @@
|
|
|
9
9
|
"composite": true,
|
|
10
10
|
"rootDir": "src",
|
|
11
11
|
"outDir": "lib",
|
|
12
|
+
"declarationDir": "lib",
|
|
13
|
+
"noEmit": false,
|
|
14
|
+
"jsx": "preserve"
|
|
12
15
|
},
|
|
13
16
|
"include": ["typings", "src"],
|
|
14
|
-
"exclude": ["**/*.stories.tsx"]
|
|
15
|
-
}
|
|
17
|
+
"exclude": ["**/*.stories.tsx", "dist"]
|
|
18
|
+
}
|
|
@@ -9,11 +9,21 @@ import lostCss from 'lost'
|
|
|
9
9
|
|
|
10
10
|
export default defineConfig({
|
|
11
11
|
build: {
|
|
12
|
-
// Relative to the root
|
|
13
12
|
ssr: 'src/index.ts',
|
|
14
13
|
outDir: 'lib',
|
|
15
|
-
|
|
16
|
-
|
|
14
|
+
emptyOutDir: false, // Keep the outDir to avoid removing TS types
|
|
15
|
+
lib: {
|
|
16
|
+
entry: 'src/index.ts',
|
|
17
|
+
formats: ['es', 'cjs'],
|
|
18
|
+
fileName: (format) => (format === 'es' ? 'index.mjs' : 'index.cjs'),
|
|
19
|
+
},
|
|
20
|
+
rollupOptions: {
|
|
21
|
+
external: ['react', 'react-dom', 'styled-components'], // Avoid bundling dependencies
|
|
22
|
+
output: {
|
|
23
|
+
assetFileNames: '[name].[ext]', // Ensure asset names are kept clean
|
|
24
|
+
entryFileNames: '[name].js', // Ensure only compiled JS is output
|
|
25
|
+
},
|
|
26
|
+
},
|
|
17
27
|
commonjsOptions: {
|
|
18
28
|
transformMixedEsModules: true,
|
|
19
29
|
esmExternals: true,
|
|
@@ -23,7 +33,6 @@ export default defineConfig({
|
|
|
23
33
|
react({
|
|
24
34
|
include: '**/*.tsx',
|
|
25
35
|
babel: {
|
|
26
|
-
// Use babel.config.js files
|
|
27
36
|
configFile: true,
|
|
28
37
|
},
|
|
29
38
|
}),
|
|
@@ -32,6 +41,7 @@ export default defineConfig({
|
|
|
32
41
|
esbuildOptions: {
|
|
33
42
|
target: 'es2020',
|
|
34
43
|
},
|
|
44
|
+
exclude: ['styled-components'],
|
|
35
45
|
},
|
|
36
46
|
css: {
|
|
37
47
|
postcss: {
|
|
@@ -45,8 +55,11 @@ export default defineConfig({
|
|
|
45
55
|
},
|
|
46
56
|
},
|
|
47
57
|
define: {
|
|
48
|
-
'process.env':
|
|
49
|
-
|
|
58
|
+
'process.env': {
|
|
59
|
+
NODE_ENV: process.env.NODE_ENV,
|
|
60
|
+
OPENTRONS_PROJECT: process.env.OPENTRONS_PROJECT,
|
|
61
|
+
},
|
|
62
|
+
global: 'globalThis', // Ensure compatibility with global variables
|
|
50
63
|
},
|
|
51
64
|
resolve: {
|
|
52
65
|
alias: {
|
package/lib/lists/ListItem.d.ts
DELETED
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import type { IconName } from '../icons';
|
|
3
|
-
interface ListItemProps {
|
|
4
|
-
/** click handler */
|
|
5
|
-
onClick?: (event: React.SyntheticEvent) => unknown;
|
|
6
|
-
/** mouse enter handler */
|
|
7
|
-
onMouseEnter?: (event: React.MouseEvent) => unknown;
|
|
8
|
-
/** mouse leave handler */
|
|
9
|
-
onMouseLeave?: (event: React.MouseEvent) => unknown;
|
|
10
|
-
/** mouse enter handler */
|
|
11
|
-
onPointerEnter?: (event: React.PointerEvent) => unknown;
|
|
12
|
-
/** mouse leave handler */
|
|
13
|
-
onPointerLeave?: (event: React.PointerEvent) => unknown;
|
|
14
|
-
/** if URL is specified, ListItem is wrapped in a React Router NavLink */
|
|
15
|
-
url?: string | null;
|
|
16
|
-
/** if URL is specified NavLink can receive an active class name */
|
|
17
|
-
activeClassName?: string;
|
|
18
|
-
/** if URL is specified NavLink can receive an exact property for matching routes */
|
|
19
|
-
exact?: boolean;
|
|
20
|
-
/** Additional class name */
|
|
21
|
-
className?: string;
|
|
22
|
-
/** if disabled, the onClick handler will be disabled */
|
|
23
|
-
isDisabled?: boolean;
|
|
24
|
-
/** name constant of the icon to display */
|
|
25
|
-
iconName?: IconName;
|
|
26
|
-
'aria-describedby'?: string;
|
|
27
|
-
ref?: {
|
|
28
|
-
current: Element | null;
|
|
29
|
-
} | ((current: Element | null) => unknown);
|
|
30
|
-
children?: React.ReactNode;
|
|
31
|
-
}
|
|
32
|
-
/**
|
|
33
|
-
* A styled `<li>` with an optional icon, and an optional url for a React Router `NavLink`
|
|
34
|
-
*
|
|
35
|
-
*/
|
|
36
|
-
export declare const ListItem: React.ForwardRefExoticComponent<Omit<ListItemProps, "ref"> & React.RefAttributes<HTMLLIElement>>;
|
|
37
|
-
export {};
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import type { StyleProps } from '../primitives';
|
|
3
|
-
export interface BaseModalProps extends StyleProps {
|
|
4
|
-
/** Overlay color, defaults to `OVERLAY_GRAY_90` */
|
|
5
|
-
overlayColor?: string;
|
|
6
|
-
/** Optional close on outside click **/
|
|
7
|
-
onOutsideClick?: React.MouseEventHandler;
|
|
8
|
-
/** Optional sticky header */
|
|
9
|
-
header?: React.ReactNode;
|
|
10
|
-
/** Option to turn off headerStyles */
|
|
11
|
-
noHeaderStyles?: boolean;
|
|
12
|
-
/** Optional sticky footer */
|
|
13
|
-
footer?: React.ReactNode;
|
|
14
|
-
/** Modal content */
|
|
15
|
-
children?: React.ReactNode;
|
|
16
|
-
}
|
|
17
|
-
/**
|
|
18
|
-
* A BaseModal is a layout component for building more specific modals.
|
|
19
|
-
*
|
|
20
|
-
* It includes:
|
|
21
|
-
* - An overlay, customizable with the `overlayColor` prop
|
|
22
|
-
* - A content area, with `overflow-y: auto` and customizable with style props
|
|
23
|
-
* - An optional sticky header
|
|
24
|
-
* - An optional sticky footer
|
|
25
|
-
*/
|
|
26
|
-
export declare function BaseModal(props: BaseModalProps): JSX.Element;
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { Box } from '../primitives';
|
|
3
|
-
import type { TitleBarProps } from '../structure';
|
|
4
|
-
export interface ModalPageProps {
|
|
5
|
-
/** Props for title bar at top of modal page */
|
|
6
|
-
titleBar: TitleBarProps;
|
|
7
|
-
contentsClassName?: string;
|
|
8
|
-
heading?: React.ReactNode;
|
|
9
|
-
children?: React.ReactNode;
|
|
10
|
-
innerProps?: React.ComponentProps<typeof Box>;
|
|
11
|
-
outerProps?: React.ComponentProps<typeof Box>;
|
|
12
|
-
}
|
|
13
|
-
/**
|
|
14
|
-
* @deprecated Use `Interstitial` instead
|
|
15
|
-
*/
|
|
16
|
-
export declare function ModalPage(props: ModalPageProps): JSX.Element;
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import type { IconName } from '../../icons';
|
|
2
|
-
import type { StyleProps } from '../../primitives';
|
|
3
|
-
interface SlotLocationProps extends StyleProps {
|
|
4
|
-
/** name constant of the slot to display */
|
|
5
|
-
slotName: string;
|
|
6
|
-
iconName?: undefined;
|
|
7
|
-
}
|
|
8
|
-
interface HardwareIconProps extends StyleProps {
|
|
9
|
-
/** hardware icon name */
|
|
10
|
-
iconName: IconName;
|
|
11
|
-
slotName?: undefined;
|
|
12
|
-
}
|
|
13
|
-
type LocationIconProps = SlotLocationProps | HardwareIconProps;
|
|
14
|
-
export declare function LocationIcon({ slotName, iconName, color, ...styleProps }: LocationIconProps): JSX.Element;
|
|
15
|
-
export {};
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { Btn } from '../primitives';
|
|
3
|
-
interface RoundTabProps extends React.ComponentProps<typeof Btn> {
|
|
4
|
-
isCurrent: boolean;
|
|
5
|
-
disabled?: boolean;
|
|
6
|
-
}
|
|
7
|
-
export declare function RoundTab({ isCurrent, children, disabled, ...restProps }: RoundTabProps): JSX.Element;
|
|
8
|
-
export {};
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import type { IconName } from '../icons';
|
|
3
|
-
export interface NavTabProps {
|
|
4
|
-
/** optional click event for nav button */
|
|
5
|
-
onClick?: React.MouseEventHandler;
|
|
6
|
-
/** optional url for nav button route */
|
|
7
|
-
url?: string;
|
|
8
|
-
/** position a single button on the bottom of the page */
|
|
9
|
-
isBottom?: boolean;
|
|
10
|
-
/** classes to apply */
|
|
11
|
-
className?: string;
|
|
12
|
-
/** id */
|
|
13
|
-
id?: string;
|
|
14
|
-
/** disabled attribute (setting disabled removes onClick) */
|
|
15
|
-
disabled?: boolean;
|
|
16
|
-
/** optional title to display below the icon */
|
|
17
|
-
title?: string;
|
|
18
|
-
/** Icon name for button's icon */
|
|
19
|
-
iconName: IconName;
|
|
20
|
-
/** Display a notification dot */
|
|
21
|
-
notification?: boolean;
|
|
22
|
-
/** selected styling (can also use react-router & `activeClassName`) */
|
|
23
|
-
selected?: boolean;
|
|
24
|
-
}
|
|
25
|
-
export declare function NavTab(props: NavTabProps): JSX.Element;
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import type { IconName } from '../icons';
|
|
3
|
-
export interface OutsideLinkTabProps {
|
|
4
|
-
/** optional click event for nav button */
|
|
5
|
-
onClick?: React.MouseEventHandler;
|
|
6
|
-
/** link to outside URL */
|
|
7
|
-
to: string;
|
|
8
|
-
/** position a single button on the bottom of the page */
|
|
9
|
-
isBottom?: boolean;
|
|
10
|
-
/** classes to apply */
|
|
11
|
-
className?: string;
|
|
12
|
-
/** disabled attribute (setting disabled removes onClick) */
|
|
13
|
-
disabled?: boolean;
|
|
14
|
-
/** optional title to display below the icon */
|
|
15
|
-
title?: string;
|
|
16
|
-
/** Icon name for button's icon */
|
|
17
|
-
iconName: IconName;
|
|
18
|
-
/** Display a notification dot */
|
|
19
|
-
notification?: boolean;
|
|
20
|
-
/** selected styling (can also use react-router & `activeClassName`) */
|
|
21
|
-
selected?: boolean;
|
|
22
|
-
}
|
|
23
|
-
/** Very much like NavTab, but used for opening external links in a new tab/window */
|
|
24
|
-
export declare function OutsideLinkTab(props: OutsideLinkTabProps): JSX.Element;
|
package/lib/tabbedNav/index.d.ts
DELETED
|
File without changes
|
|
File without changes
|
|
File without changes
|