@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.
- package/LICENSE +202 -0
- package/README.md +12 -48
- package/lib/assets/index.d.ts +1 -0
- package/lib/assets/localization/en/index.d.ts +191 -16
- package/lib/assets/localization/index.d.ts +292 -13
- package/lib/assets/localization/zh/index.d.ts +110 -8
- package/lib/atoms/Checkbox/index.d.ts +3 -3
- package/lib/atoms/CheckboxField/index.d.ts +2 -0
- package/lib/atoms/FixedTrashText/index.d.ts +1 -0
- package/lib/atoms/InlineNotification/index.d.ts +1 -1
- package/lib/atoms/ListButton/index.d.ts +2 -2
- package/lib/atoms/MenuList/OverflowBtn.d.ts +2 -2
- package/lib/atoms/Slider/index.d.ts +14 -0
- package/lib/atoms/StepMeter/__tests__/StepMeter.test.d.ts +1 -1
- package/lib/atoms/StepMeter/index.d.ts +1 -2
- package/lib/atoms/StyledText/LegacyStyledText.d.ts +3 -1
- package/lib/atoms/StyledText/PlaceholderStyledText.d.ts +14 -0
- package/lib/atoms/StyledText/StyledText.d.ts +1 -0
- package/lib/atoms/StyledText/index.d.ts +1 -0
- package/lib/atoms/Tag/index.d.ts +1 -1
- package/lib/atoms/buttons/AlertPrimaryButton.d.ts +3 -1
- package/lib/atoms/buttons/AltPrimaryButton.d.ts +3 -1
- package/lib/atoms/buttons/PrimaryButton.d.ts +2 -1
- package/lib/atoms/buttons/TertiaryButton.d.ts +8 -3
- package/lib/atoms/index.d.ts +2 -1
- package/lib/buttons/Button.d.ts +3 -3
- package/lib/controls/ToggleButton.d.ts +1 -1
- package/lib/forms/DeprecatedCheckboxField.d.ts +2 -2
- package/lib/forms/FormGroup.d.ts +4 -4
- package/lib/forms/LegacyInputField.d.ts +5 -5
- package/lib/forms/RadioGroup.d.ts +2 -2
- package/lib/forms/ToggleField.d.ts +1 -1
- package/lib/hardware-sim/BaseDeck/BaseDeck.d.ts +19 -11
- package/lib/hardware-sim/BaseDeck/SingleSlotFixture.d.ts +2 -0
- package/lib/hardware-sim/BaseDeck/StackedBadge.d.ts +1 -0
- package/lib/hardware-sim/BaseDeck/StagingAreaFixture.d.ts +1 -0
- package/lib/hardware-sim/BaseDeck/WasteChuteStagingAreaFixture.d.ts +1 -0
- package/lib/hardware-sim/Deck/MoveLabwareOnDeck.d.ts +3 -2
- package/lib/hardware-sim/Deck/RobotCoordsForeignDiv.d.ts +6 -5
- package/lib/hardware-sim/Deck/RobotCoordsForeignObject.d.ts +8 -5
- package/lib/hardware-sim/Deck/RobotWorkSpace.d.ts +2 -3
- package/lib/hardware-sim/DeckConfigurator/VacuumModuleItem.d.ts +11 -0
- package/lib/hardware-sim/DeckConfigurator/constants.d.ts +5 -0
- package/lib/hardware-sim/Labware/Labware.d.ts +3 -3
- package/lib/hardware-sim/Labware/LabwareAdapter/GenericLid.d.ts +9 -0
- package/lib/hardware-sim/Labware/LabwareAdapter/OpentronsUniversalFlatAdapterTypeB.d.ts +1 -0
- package/lib/hardware-sim/Labware/LabwareAdapter/index.d.ts +11 -3
- package/lib/hardware-sim/Labware/LabwareRender.d.ts +9 -9
- package/lib/hardware-sim/Labware/index.d.ts +1 -1
- package/lib/hardware-sim/Labware/labwareInternals/LabwareOutline.d.ts +1 -1
- package/lib/hardware-sim/Labware/labwareInternals/LabwareWellLabels.d.ts +1 -1
- package/lib/hardware-sim/Labware/labwareInternals/StaticLabware.d.ts +7 -2
- package/lib/hardware-sim/Labware/labwareInternals/Tips/InaccessibleTip.d.ts +3 -0
- package/lib/hardware-sim/Labware/labwareInternals/Tips/NewTip.d.ts +4 -0
- package/lib/hardware-sim/Labware/labwareInternals/Tips/TipStatus.d.ts +11 -0
- package/lib/hardware-sim/Labware/labwareInternals/Tips/UsedTip.d.ts +4 -0
- package/lib/hardware-sim/Labware/labwareInternals/Tips/__tests__/TipStatus.test.d.ts +1 -0
- package/lib/hardware-sim/Labware/labwareInternals/Tips/constants.d.ts +11 -0
- package/lib/hardware-sim/Labware/labwareInternals/Tips/index.d.ts +2 -0
- package/lib/hardware-sim/Labware/labwareInternals/Wells/EmptyWell.d.ts +10 -0
- package/lib/hardware-sim/Labware/labwareInternals/{FilledWells.d.ts → Wells/FilledWells.d.ts} +3 -3
- package/lib/hardware-sim/Labware/labwareInternals/Wells/SelectedWell.d.ts +13 -0
- package/lib/hardware-sim/Labware/labwareInternals/{StrokedWells.d.ts → Wells/StrokedWells.d.ts} +2 -2
- package/lib/hardware-sim/Labware/labwareInternals/{StyledWells.d.ts → Wells/StyledWells.d.ts} +1 -1
- package/lib/hardware-sim/Labware/labwareInternals/{Well.d.ts → Wells/Well.d.ts} +2 -3
- package/lib/hardware-sim/Labware/labwareInternals/{WellLabels.d.ts → Wells/WellLabels.d.ts} +2 -2
- package/lib/hardware-sim/Labware/labwareInternals/Wells/WellStatus.d.ts +12 -0
- package/lib/hardware-sim/Labware/labwareInternals/Wells/constants.d.ts +21 -0
- package/lib/hardware-sim/Labware/labwareInternals/Wells/index.d.ts +9 -0
- package/lib/hardware-sim/Labware/labwareInternals/Wells/utils.d.ts +2 -0
- package/lib/hardware-sim/Labware/labwareInternals/index.d.ts +2 -5
- package/lib/hardware-sim/Labware/labwareInternals/types.d.ts +10 -12
- package/lib/hardware-sim/Module/Vacuum.d.ts +1 -0
- package/lib/hardware-sim/Module/index.d.ts +40 -5
- package/lib/hardware-sim/Pipette/StrokedNozzles.d.ts +10 -0
- package/lib/hardware-sim/Pipette/constants.d.ts +3 -0
- package/lib/hardware-sim/Pipette/index.d.ts +1 -0
- package/lib/hardware-sim/RobotCoordinateSpace/RobotCoordinateSpace.d.ts +5 -3
- package/lib/hardware-sim/RobotCoordinateSpace/RobotCoordinateSpaceWithRef.d.ts +5 -4
- package/lib/hardware-sim/alignment/AlignToModuleChildSlot.d.ts +25 -0
- package/lib/hardware-sim/alignment/CenterLabwareInModuleChildSlot.d.ts +33 -0
- package/lib/hardware-sim/alignment/CenterLabwareInSlot.d.ts +11 -0
- package/lib/hardware-sim/alignment/index.d.ts +4 -0
- package/lib/hardware-sim/index.d.ts +1 -0
- package/lib/helix-design-system/colors.d.ts +1 -0
- package/lib/hocs/withStyleProps.d.ts +1 -1
- package/lib/hooks/__tests__/useCommandTypeSummaries.test.d.ts +1 -0
- package/lib/hooks/index.d.ts +2 -1
- package/lib/hooks/testHelpers/index.d.ts +2 -0
- package/lib/hooks/useCommandTypeSummaries.d.ts +2 -0
- package/lib/hooks/useConditionalConfirm.d.ts +5 -9
- package/lib/i18n.d.ts +4 -0
- package/lib/icons/ModuleIcon.d.ts +5 -4
- package/lib/icons/icon-data.d.ts +702 -4
- package/lib/index.d.ts +2 -1
- package/lib/index.js +557 -0
- package/lib/index.mjs +30626 -28730
- package/lib/interaction-enhancers/HandleKeypress.d.ts +2 -2
- package/lib/legacy-hardware-sim/LabwareNameOverlay.d.ts +1 -1
- package/lib/legacy-hardware-sim/index.d.ts +0 -1
- package/lib/modals/AlertModal.d.ts +1 -1
- package/lib/molecules/CustomizeExpandButton/index.d.ts +2 -2
- package/lib/molecules/DeckInfoLabel/index.d.ts +8 -20
- package/lib/molecules/DeckLabel/index.d.ts +9 -2
- package/lib/molecules/DropdownMenu/index.d.ts +5 -4
- package/lib/molecules/IconButton/index.d.ts +45 -0
- package/lib/molecules/InfoScreen/index.d.ts +3 -1
- package/lib/molecules/InputField/__tests__/InputField.test.d.ts +1 -0
- package/lib/{atoms → molecules}/InputField/index.d.ts +13 -12
- package/lib/molecules/LiquidIcon/index.d.ts +2 -1
- package/lib/molecules/RobotInfoLabel/__tests__/RobotInfoLabel.test.d.ts +1 -0
- package/lib/molecules/RobotInfoLabel/index.d.ts +12 -0
- package/lib/molecules/StepGroup/__tests__/StepGroup.test.d.ts +1 -0
- package/lib/molecules/StepGroup/index.d.ts +11 -0
- package/lib/molecules/TextAreaField/__tests__/TextAreaField.test.d.ts +1 -0
- package/lib/molecules/TextAreaField/index.d.ts +34 -0
- package/lib/molecules/TimelineScrubber/TrackSlider.d.ts +10 -0
- package/lib/molecules/TimelineScrubber/index.d.ts +6 -0
- package/lib/molecules/TouchInputField/__tests__/TouchInputField.test.d.ts +1 -0
- package/lib/molecules/TouchInputField/index.d.ts +56 -0
- package/lib/molecules/WizardHeader/__tests__/WizardHeader.test.d.ts +1 -0
- package/lib/molecules/WizardHeader/index.d.ts +11 -0
- package/lib/molecules/index.d.ts +8 -1
- package/lib/organisms/CommandText/getCommandData.d.ts +3 -0
- package/lib/organisms/CommandText/index.d.ts +2 -1
- package/lib/organisms/CommandText/useCommandTextString/index.d.ts +8 -3
- package/lib/organisms/CommandText/useCommandTextString/utils/commandText/__tests__/getTipStateCommandText.test.d.ts +1 -0
- package/lib/organisms/CommandText/useCommandTextString/utils/commandText/getConcurrentCommandText.d.ts +3 -0
- package/lib/organisms/CommandText/useCommandTextString/utils/commandText/getHSConcurrentShakeSpeedCommandTex.d.ts +3 -0
- package/lib/organisms/CommandText/useCommandTextString/utils/commandText/getRobotDevicesCommandText.d.ts +3 -0
- package/lib/organisms/CommandText/useCommandTextString/utils/commandText/getTCStartRunExtendedProfileCommandText.d.ts +4 -0
- package/lib/organisms/CommandText/useCommandTextString/utils/commandText/getTipStateCommandText.d.ts +3 -0
- package/lib/organisms/CommandText/useCommandTextString/utils/commandText/index.d.ts +5 -0
- package/lib/organisms/CommandText/useCommandTextString/utils/getLabwareDisplayLocation.d.ts +2 -0
- package/lib/organisms/CommandText/useCommandTextString/utils/getLiquidDisplayName.d.ts +2 -1
- package/lib/organisms/CommandText/useCommandTextString/utils/types.d.ts +2 -1
- package/lib/organisms/DeckLabelSet/index.d.ts +1 -0
- package/lib/organisms/FixtureOption/index.d.ts +0 -1
- package/lib/organisms/LabwareDetailsWithCount/__tests__/LabwareDetailsWithCount.test.d.ts +1 -0
- package/lib/organisms/LabwareDetailsWithCount/index.d.ts +7 -0
- package/lib/organisms/LabwareInfoOverlay/__tests__/LabwareInfoOverlay.test.d.ts +1 -0
- package/lib/organisms/LabwareInfoOverlay/index.d.ts +12 -0
- package/lib/organisms/ProtocolDeck/index.d.ts +1 -0
- package/lib/organisms/Toolbox/index.d.ts +2 -0
- package/lib/organisms/index.d.ts +4 -3
- package/lib/primitives/Box.d.ts +3 -7
- package/lib/primitives/Btn.d.ts +2 -55
- package/lib/primitives/Buttons/NewPrimaryBtn.d.ts +8 -0
- package/lib/primitives/Buttons/NewSecondaryBtn.d.ts +8 -0
- package/lib/primitives/Flex.d.ts +3 -7
- package/lib/primitives/ForeignObject.d.ts +8 -18
- package/lib/primitives/Link.d.ts +3 -7
- package/lib/primitives/Svg.d.ts +4 -13
- package/lib/primitives/Text.d.ts +5 -7
- package/lib/primitives/index.d.ts +2 -0
- package/lib/primitives/style-props.d.ts +3 -3
- package/lib/primitives/types.d.ts +10 -3
- package/lib/src/alerts/alerts.module.css +103 -0
- package/lib/src/atoms/StyledText/placeholderstyledtext.module.css +26 -0
- package/lib/src/buttons/buttons.module.css +428 -0
- package/lib/src/controls/styles.module.css +103 -0
- package/lib/src/forms/Select.module.css +118 -0
- package/lib/src/forms/SelectField.module.css +16 -0
- package/lib/src/forms/forms.module.css +240 -0
- package/lib/src/hardware-sim/BaseDeck/basedeck.module.css +20 -0
- package/lib/src/hardware-sim/Deck/deck.module.css +54 -0
- package/lib/src/hardware-sim/Labware/labware.module.css +8 -0
- package/lib/src/hardware-sim/RobotCoordinateSpace/robotcoordinatespace.module.css +3 -0
- package/lib/src/icons/icon.module.css +10 -0
- package/lib/src/index.module.css +9 -0
- package/lib/src/instrument/PipetteSelect.module.css +14 -0
- package/lib/src/legacy-hardware-sim/LabwareNameOverlay.module.css +20 -0
- package/lib/src/legacy-hardware-sim/ModuleItem.module.css +98 -0
- package/lib/src/lists/lists.module.css +171 -0
- package/lib/src/modals/modals.module.css +275 -0
- package/lib/src/molecules/DeckInfoLabel/deckinfolabel.module.css +42 -0
- package/lib/src/molecules/ReleaseNotes/styles.module.css +66 -0
- package/lib/src/nav/SidePanel.module.css +34 -0
- package/lib/src/slotmap/styles.module.css +18 -0
- package/lib/src/structure/Pill.module.css +16 -0
- package/lib/src/structure/Splash.module.css +16 -0
- package/lib/src/structure/structure.module.css +114 -0
- package/lib/src/styles/borders.module.css +20 -0
- package/lib/src/styles/colors.module.css +58 -0
- package/lib/src/styles/global.css +179 -0
- package/lib/src/styles/index.module.css +8 -0
- package/lib/src/styles/typography.module.css +23 -0
- package/lib/src/tooltips/tooltips.module.css +72 -0
- package/lib/structure/Pill.d.ts +3 -3
- package/lib/style.css +1 -1
- package/lib/testing/utils/matchers.d.ts +0 -1
- package/lib/utils/__tests__/setRefs.test.d.ts +1 -0
- package/lib/utils/__tests__/truncateString.test.d.ts +1 -0
- package/lib/utils/humanizeLabwareType.d.ts +1 -0
- package/lib/utils/index.d.ts +4 -0
- package/lib/utils/setRefs.d.ts +2 -0
- package/lib/{utils.d.ts → utils/truncateString.d.ts} +0 -2
- package/lib/utils/wellNameSplit.d.ts +1 -0
- package/package.json +21 -26
- package/src/index.module.css +9 -0
- package/src/styles/borders.module.css +20 -0
- package/src/styles/borders.ts +16 -0
- package/src/styles/colors.module.css +52 -0
- package/src/styles/colors.ts +58 -0
- package/src/styles/cursor.ts +12 -0
- package/src/styles/flexbox.ts +39 -0
- package/src/styles/global.css +180 -0
- package/src/styles/index.module.css +8 -0
- package/src/styles/index.ts +8 -0
- package/src/styles/layout.ts +31 -0
- package/src/styles/position.ts +5 -0
- package/src/styles/spacing.ts +11 -0
- package/src/styles/typography.module.css +23 -0
- package/src/styles/typography.ts +90 -0
- package/lib/legacy-hardware-sim/ModuleItem.d.ts +0 -17
- /package/lib/{__tests__/utils.test.d.ts → atoms/Slider/__tests__/Slider.test.d.ts} +0 -0
- /package/lib/{atoms/InputField/__tests__/InputField.test.d.ts → hardware-sim/DeckConfigurator/__tests__/VacuumModuleItem.test.d.ts} +0 -0
- /package/lib/hardware-sim/Labware/labwareInternals/{__tests__ → Wells/__tests__}/StrokedWells.test.d.ts +0 -0
- /package/lib/hardware-sim/Labware/labwareInternals/{__tests__ → Wells/__tests__}/WellLabels.test.d.ts +0 -0
|
@@ -5,6 +5,7 @@ interface ProtocolDeckProps {
|
|
|
5
5
|
protocolAnalysis: CompletedProtocolAnalysis | ProtocolAnalysisOutput | null;
|
|
6
6
|
/** extra props to pass through to BaseDeck component */
|
|
7
7
|
baseDeckProps?: Partial<ComponentProps<typeof BaseDeck>>;
|
|
8
|
+
showLabwareLabels?: boolean;
|
|
8
9
|
}
|
|
9
10
|
export declare function ProtocolDeck(props: ProtocolDeckProps): JSX.Element | null;
|
|
10
11
|
export {};
|
|
@@ -11,6 +11,8 @@ export interface ToolboxProps extends StyleProps {
|
|
|
11
11
|
closeButton?: JSX.Element;
|
|
12
12
|
titlePadding?: string;
|
|
13
13
|
childrenPadding?: string;
|
|
14
|
+
/** Optional test id for the scrollable children container. */
|
|
15
|
+
childrenContainerTestId?: string;
|
|
14
16
|
subHeader?: JSX.Element | null;
|
|
15
17
|
secondaryHeaderButton?: JSX.Element;
|
|
16
18
|
}
|
package/lib/organisms/index.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
export * from './DeckLabelSet';
|
|
2
|
-
export * from './Toolbox';
|
|
3
|
-
export * from './ProtocolTimelineScrubber';
|
|
4
1
|
export * from './CommandText';
|
|
2
|
+
export * from './DeckLabelSet';
|
|
5
3
|
export * from './FixtureOption';
|
|
4
|
+
export * from './LabwareDetailsWithCount';
|
|
5
|
+
export * from './LabwareInfoOverlay';
|
|
6
6
|
export * from './ProtocolDeck';
|
|
7
|
+
export * from './Toolbox';
|
package/lib/primitives/Box.d.ts
CHANGED
|
@@ -1,7 +1,3 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
*
|
|
5
|
-
* @component
|
|
6
|
-
*/
|
|
7
|
-
export declare const Box: PrimitiveComponent<'div'>;
|
|
1
|
+
import type { ComponentProps, FC } from 'react';
|
|
2
|
+
import type { StyleProps } from './types';
|
|
3
|
+
export declare const Box: FC<ComponentProps<'div'> & StyleProps>;
|
package/lib/primitives/Btn.d.ts
CHANGED
|
@@ -1,59 +1,6 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { ComponentProps, FC } from 'react';
|
|
2
2
|
import type { StyleProps } from './types';
|
|
3
3
|
export declare const BUTTON_TYPE_SUBMIT: 'submit';
|
|
4
4
|
export declare const BUTTON_TYPE_RESET: 'reset';
|
|
5
5
|
export declare const BUTTON_TYPE_BUTTON: 'button';
|
|
6
|
-
|
|
7
|
-
* Button primitive
|
|
8
|
-
*
|
|
9
|
-
* @component
|
|
10
|
-
*/
|
|
11
|
-
export declare const Btn: StyledComponent<'button', any, StyleProps, any>;
|
|
12
|
-
/**
|
|
13
|
-
* Primary button variant
|
|
14
|
-
*
|
|
15
|
-
* @component
|
|
16
|
-
*/
|
|
17
|
-
export declare const PrimaryBtn: StyledComponent<"button", any, StyleProps, any>;
|
|
18
|
-
/**
|
|
19
|
-
* Secondary button variant
|
|
20
|
-
*
|
|
21
|
-
* @component
|
|
22
|
-
*/
|
|
23
|
-
export declare const SecondaryBtn: StyledComponent<"button", any, StyleProps, any>;
|
|
24
|
-
/**
|
|
25
|
-
* New primary button variant used in app
|
|
26
|
-
*
|
|
27
|
-
* @component
|
|
28
|
-
*/
|
|
29
|
-
export declare const NewPrimaryBtn: StyledComponent<"button", any, StyleProps, any>;
|
|
30
|
-
/**
|
|
31
|
-
* New secondary button variant used in app
|
|
32
|
-
*
|
|
33
|
-
* @component
|
|
34
|
-
*/
|
|
35
|
-
export declare const NewSecondaryBtn: StyledComponent<"button", any, StyleProps, any>;
|
|
36
|
-
/**
|
|
37
|
-
* Red primary button variant used in app
|
|
38
|
-
*
|
|
39
|
-
* @component
|
|
40
|
-
*/
|
|
41
|
-
export declare const NewAlertPrimaryBtn: StyledComponent<"button", any, StyleProps, any>;
|
|
42
|
-
/**
|
|
43
|
-
* Red secondary button variant used in app
|
|
44
|
-
*
|
|
45
|
-
* @component
|
|
46
|
-
*/
|
|
47
|
-
export declare const NewAlertSecondaryBtn: StyledComponent<"button", any, StyleProps, any>;
|
|
48
|
-
/**
|
|
49
|
-
* Light secondary button variant
|
|
50
|
-
*
|
|
51
|
-
* @component
|
|
52
|
-
*/
|
|
53
|
-
export declare const LightSecondaryBtn: StyledComponent<"button", any, StyleProps, any>;
|
|
54
|
-
/**
|
|
55
|
-
* Tertiary button variant
|
|
56
|
-
*
|
|
57
|
-
* @component
|
|
58
|
-
*/
|
|
59
|
-
export declare const TertiaryBtn: StyledComponent<"button", any, StyleProps, any>;
|
|
6
|
+
export declare const Btn: FC<ComponentProps<'button'> & StyleProps>;
|
package/lib/primitives/Flex.d.ts
CHANGED
|
@@ -1,7 +1,3 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
*
|
|
5
|
-
* @component
|
|
6
|
-
*/
|
|
7
|
-
export declare const Flex: PrimitiveComponent<'div'>;
|
|
1
|
+
import type { ComponentProps, FC } from 'react';
|
|
2
|
+
import type { StyleProps } from './types';
|
|
3
|
+
export declare const Flex: FC<ComponentProps<'div'> & StyleProps>;
|
|
@@ -1,23 +1,13 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
export interface ForeignObjectProps
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
* internal helper prop to remap width style-prop to CSS
|
|
9
|
-
* @internal
|
|
10
|
-
*/
|
|
11
|
-
_cssWidth?: string | number;
|
|
12
|
-
/**
|
|
13
|
-
* internal helper prop to remap height style-prop to CSS
|
|
14
|
-
* @internal
|
|
15
|
-
*/
|
|
16
|
-
_cssHeight?: string | number;
|
|
1
|
+
import type { ReactElement, ReactNode } from 'react';
|
|
2
|
+
export interface ForeignObjectProps {
|
|
3
|
+
width: string | number;
|
|
4
|
+
height: string | number;
|
|
5
|
+
x: string | number;
|
|
6
|
+
y: string | number;
|
|
7
|
+
children?: ReactNode;
|
|
17
8
|
}
|
|
18
9
|
/**
|
|
19
10
|
* Foreign Object styled atomic component
|
|
20
|
-
*
|
|
21
11
|
* @component
|
|
22
12
|
*/
|
|
23
|
-
export declare const ForeignObject:
|
|
13
|
+
export declare const ForeignObject: ({ width, height, x, y, children, }: ForeignObjectProps) => ReactElement;
|
package/lib/primitives/Link.d.ts
CHANGED
|
@@ -1,11 +1,7 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { ComponentProps, FC } from 'react';
|
|
2
|
+
import type { StyleProps } from './types';
|
|
2
3
|
export interface LinkProps extends StyleProps {
|
|
3
4
|
/** render link with target="_blank" */
|
|
4
5
|
external?: boolean;
|
|
5
6
|
}
|
|
6
|
-
|
|
7
|
-
* Link primitive
|
|
8
|
-
*
|
|
9
|
-
* @component
|
|
10
|
-
*/
|
|
11
|
-
export declare const Link: PrimitiveComponent<'a', LinkProps>;
|
|
7
|
+
export declare const Link: FC<ComponentProps<'a'> & LinkProps>;
|
package/lib/primitives/Svg.d.ts
CHANGED
|
@@ -1,23 +1,14 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { ComponentProps, FC } from 'react';
|
|
2
|
+
import type { StyleProps } from './types';
|
|
2
3
|
export interface SvgProps extends StyleProps {
|
|
3
4
|
/** attach a width attribute to the <svg> element */
|
|
4
5
|
svgWidth?: string | number;
|
|
5
6
|
/** attach a height attribute to the <svg> element */
|
|
6
7
|
svgHeight?: string | number;
|
|
7
|
-
/**
|
|
8
|
-
* internal helper prop to remap width style-prop to CSS
|
|
9
|
-
* @internal
|
|
10
|
-
*/
|
|
11
|
-
_cssWidth?: string | number;
|
|
12
|
-
/**
|
|
13
|
-
* internal helper prop to remap height style-prop to CSS
|
|
14
|
-
* @internal
|
|
15
|
-
*/
|
|
16
|
-
_cssHeight?: string | number;
|
|
17
8
|
}
|
|
18
9
|
/**
|
|
19
|
-
* SVG primitive
|
|
10
|
+
* SVG primitive with style props support
|
|
20
11
|
*
|
|
21
12
|
* @component
|
|
22
13
|
*/
|
|
23
|
-
export declare const Svg:
|
|
14
|
+
export declare const Svg: FC<ComponentProps<'svg'> & SvgProps>;
|
package/lib/primitives/Text.d.ts
CHANGED
|
@@ -1,7 +1,5 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
*/
|
|
7
|
-
export declare const Text: PrimitiveComponent<'p'>;
|
|
1
|
+
import type { ComponentProps, FC } from 'react';
|
|
2
|
+
import type { StyleProps } from './types';
|
|
3
|
+
export declare const Text: FC<ComponentProps<'p'> & StyleProps & {
|
|
4
|
+
as?: string;
|
|
5
|
+
}>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { CSSProperties } from 'react';
|
|
2
2
|
import type * as Types from './types';
|
|
3
3
|
type Text = string | number;
|
|
4
|
-
export declare const STYLE_PROPS: ("
|
|
5
|
-
export declare const styleProps: (props: Types.StyleProps) =>
|
|
4
|
+
export declare const STYLE_PROPS: ("top" | "bottom" | "left" | "right" | "height" | "filter" | "width" | "position" | "overflow" | "overflowX" | "overflowY" | "cursor" | "transformOrigin" | "color" | "backgroundColor" | "opacity" | "fontSize" | "fontWeight" | "fontStyle" | "lineHeight" | "textAlign" | "textTransform" | "textDecoration" | "textOverflow" | "margin" | "marginX" | "marginY" | "marginTop" | "marginRight" | "marginBottom" | "marginLeft" | "padding" | "paddingX" | "paddingY" | "paddingTop" | "paddingRight" | "paddingBottom" | "paddingLeft" | "border" | "borderTop" | "borderRight" | "borderBottom" | "borderLeft" | "borderRadius" | "borderWidth" | "borderColor" | "boxShadow" | "flex" | "alignItems" | "alignSelf" | "alignContent" | "justifyContent" | "justifyItems" | "justifySelf" | "flexDirection" | "flexWrap" | "flexGrow" | "whiteSpace" | "columnGap" | "gridGap" | "gap" | "gridTemplateAreas" | "gridTemplateRows" | "gridTemplateColumns" | "gridArea" | "gridRow" | "gridColumn" | "display" | "visibility" | "size" | "minWidth" | "maxWidth" | "minHeight" | "maxHeight" | "wordSpacing" | "overflowWrap" | "zIndex" | "transform" | "rowGap" | "transition")[];
|
|
5
|
+
export declare const styleProps: (props: Types.StyleProps) => CSSProperties;
|
|
6
6
|
export declare const isntStyleProp: (prop: string | Text) => boolean;
|
|
7
7
|
export {};
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
import type { ComponentType } from 'react';
|
|
1
|
+
import type { ComponentType, CSSProperties } from 'react';
|
|
3
2
|
export interface ColorProps {
|
|
4
3
|
color?: string;
|
|
5
4
|
backgroundColor?: string;
|
|
@@ -13,6 +12,7 @@ export interface TypographyProps {
|
|
|
13
12
|
textAlign?: string;
|
|
14
13
|
textTransform?: string;
|
|
15
14
|
textDecoration?: string;
|
|
15
|
+
textOverflow?: string;
|
|
16
16
|
}
|
|
17
17
|
export interface SpacingProps {
|
|
18
18
|
margin?: string | number;
|
|
@@ -45,14 +45,20 @@ export interface FlexboxProps {
|
|
|
45
45
|
flex?: string | number;
|
|
46
46
|
alignItems?: string;
|
|
47
47
|
alignSelf?: string;
|
|
48
|
+
alignContent?: string;
|
|
48
49
|
justifyContent?: string;
|
|
50
|
+
justifyItems?: string;
|
|
51
|
+
justifySelf?: string;
|
|
49
52
|
flexDirection?: string;
|
|
50
53
|
flexWrap?: string;
|
|
54
|
+
flexShrink?: string | number;
|
|
55
|
+
flexGrow?: string | number;
|
|
51
56
|
whiteSpace?: string;
|
|
52
57
|
}
|
|
53
58
|
export interface GridProps {
|
|
54
59
|
columnGap?: string | number;
|
|
55
60
|
gridGap?: string | number;
|
|
61
|
+
gap?: string | number;
|
|
56
62
|
gridTemplateAreas?: string;
|
|
57
63
|
gridTemplateRows?: string;
|
|
58
64
|
gridTemplateColumns?: string;
|
|
@@ -62,6 +68,7 @@ export interface GridProps {
|
|
|
62
68
|
}
|
|
63
69
|
export interface LayoutProps {
|
|
64
70
|
display?: string;
|
|
71
|
+
visibility?: string;
|
|
65
72
|
size?: string | number;
|
|
66
73
|
width?: string | number;
|
|
67
74
|
minWidth?: string | number;
|
|
@@ -93,4 +100,4 @@ export interface TransitionProps {
|
|
|
93
100
|
export interface StyleProps extends ColorProps, TypographyProps, SpacingProps, BorderProps, FlexboxProps, GridProps, LayoutProps, PositionProps, TransitionProps {
|
|
94
101
|
className?: string;
|
|
95
102
|
}
|
|
96
|
-
export type PrimitiveComponent<Instance extends keyof JSX.IntrinsicElements | ComponentType<any>, Props extends StyleProps = StyleProps> =
|
|
103
|
+
export type PrimitiveComponent<Instance extends keyof JSX.IntrinsicElements | ComponentType<any>, Props extends StyleProps = StyleProps> = ComponentType<Instance extends keyof JSX.IntrinsicElements ? JSX.IntrinsicElements[Instance] & Props : Instance extends ComponentType<infer P> ? P & Props : Props>;
|
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
@import '../index.module.css';
|
|
2
|
+
|
|
3
|
+
.alert {
|
|
4
|
+
font-size: var(--fs-body-2);
|
|
5
|
+
font-weight: var(--fw-regular);
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
.alert:not(:first-of-type) {
|
|
9
|
+
border-top: none;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
.title_bar {
|
|
13
|
+
display: flex;
|
|
14
|
+
flex-direction: row;
|
|
15
|
+
align-items: center;
|
|
16
|
+
justify-content: space-between;
|
|
17
|
+
padding: 0.5rem 1rem;
|
|
18
|
+
font-weight: var(--fw-semibold);
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
.title {
|
|
22
|
+
width: 100%;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
.success {
|
|
26
|
+
border: 1px solid var(--c-success);
|
|
27
|
+
|
|
28
|
+
& > .title_bar {
|
|
29
|
+
background-color: var(--c-bg-success);
|
|
30
|
+
color: var(--c-success);
|
|
31
|
+
|
|
32
|
+
& svg {
|
|
33
|
+
color: var(--c-success);
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.info {
|
|
39
|
+
border: 1px solid var(--c-highlight);
|
|
40
|
+
|
|
41
|
+
& > .title_bar {
|
|
42
|
+
background-color: var(--c-bg-selected);
|
|
43
|
+
color: var(--c-selected-dark);
|
|
44
|
+
|
|
45
|
+
& svg {
|
|
46
|
+
color: var(--c-highlight);
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
.warning {
|
|
52
|
+
border: 1px solid var(--c-warning);
|
|
53
|
+
|
|
54
|
+
& > .title_bar {
|
|
55
|
+
background-color: var(--c-warning-light);
|
|
56
|
+
color: var(--c-warning-dark);
|
|
57
|
+
|
|
58
|
+
& svg {
|
|
59
|
+
fill: var(--c-warning);
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
.error {
|
|
65
|
+
border: 1px solid var(--c-error);
|
|
66
|
+
|
|
67
|
+
& > .title_bar {
|
|
68
|
+
background-color: var(--c-error-light);
|
|
69
|
+
color: var(--c-error-dark);
|
|
70
|
+
|
|
71
|
+
& svg {
|
|
72
|
+
fill: var(--c-error);
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
.message {
|
|
78
|
+
padding: 1rem 3rem;
|
|
79
|
+
background-color: white;
|
|
80
|
+
|
|
81
|
+
& a {
|
|
82
|
+
color: inherit;
|
|
83
|
+
text-decoration: underline;
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
&:empty {
|
|
87
|
+
padding: 0;
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
.icon {
|
|
92
|
+
width: 1.5rem;
|
|
93
|
+
margin-right: 0.5rem;
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
.close {
|
|
97
|
+
width: 2rem;
|
|
98
|
+
padding: 0.125rem;
|
|
99
|
+
|
|
100
|
+
&:hover {
|
|
101
|
+
background-color: rgba(100, 100, 100, 0.1);
|
|
102
|
+
}
|
|
103
|
+
}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
@media not all and (width: 1024px) and (height: 600px) {
|
|
2
|
+
.heading_small_bold {
|
|
3
|
+
font-size: 1.125rem;
|
|
4
|
+
font-weight: var(--font-weight-bold);
|
|
5
|
+
line-height: var(--line-height-24);
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
.caption_bold {
|
|
9
|
+
font-size: 0.75rem;
|
|
10
|
+
font-weight: var(--font-weight-bold);
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.body_default_semi_bold {
|
|
14
|
+
font-size: var(--font-size-16);
|
|
15
|
+
font-weight: var(--font-weight-semi-bold);
|
|
16
|
+
line-height: var(--line-height-24);
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
@media (width: 1024px) and (height: 600px) {
|
|
21
|
+
.small_body_text_bold {
|
|
22
|
+
font-size: var(--font-size-20);
|
|
23
|
+
font-weight: var(--font-weight-bold);
|
|
24
|
+
line-height: var(--font-height-24);
|
|
25
|
+
}
|
|
26
|
+
}
|