{children}
{onOnlySelection && !disabled && (
-
+
{onlySelectionText}
-
+
)}
-
+
);
};
diff --git a/packages/orbit-components/src/ChoiceGroup/index.tsx b/packages/orbit-components/src/ChoiceGroup/index.tsx
index fe8b924046..d17f0218dc 100644
--- a/packages/orbit-components/src/ChoiceGroup/index.tsx
+++ b/packages/orbit-components/src/ChoiceGroup/index.tsx
@@ -1,14 +1,13 @@
"use client";
import * as React from "react";
-import styled from "styled-components";
+import cx from "clsx";
import Heading from "../Heading";
import type { Type } from "../Heading/types";
import Stack from "../Stack";
import { LABEL_SIZES, LABEL_ELEMENTS } from "./consts";
-import Feedback, { StyledFormFeedback } from "./components/Feedback";
-import defaultTheme from "../defaultTheme";
+import Feedback from "./components/Feedback";
import FilterWrapper from "./components/FilterWrapper";
import useRandomId from "../hooks/useRandomId";
import useTheme from "../hooks/useTheme";
@@ -23,22 +22,6 @@ const getHeadingSize = (size: Size): Type => {
return SIZES[size];
};
-const StyledChoiceGroup = styled.div`
- width: 100%;
- display: flex;
- flex-direction: column;
-
- ${StyledFormFeedback} {
- position: relative;
- margin-top: ${({ theme }) => theme.orbit.spaceXSmall};
- top: initial;
- }
-`;
-
-StyledChoiceGroup.defaultProps = {
- theme: defaultTheme,
-};
-
const ItemContainer =
({ filter, itemProps, onOnlySelection, onlySelectionText }) =>
({ children }) => {
@@ -87,12 +70,16 @@ const ChoiceGroup = React.forwardRef