Skip to content

Commit 44eaf9d

Browse files
committed
Enhance PricingAddons component with monthly pricing, improved feature details, and layout adjustments in Pricing section
Signed-off-by: Lee Calcote <lee.calcote@layer5.io>
1 parent 77b2471 commit 44eaf9d

3 files changed

Lines changed: 245 additions & 250 deletions

File tree

src/components/PlanCard/collapsible-details.js

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -65,15 +65,15 @@ const FeatureDetailsWrapper = styled.div`
6565
}
6666
`;
6767

68-
const FeatureDetails = ({ category, description, tier }) => {
68+
const FeatureDetails = ({ category, description, tier, children }) => {
6969
const [expand, setExpand] = React.useState(false);
7070

7171
const BetaTag = () => <span className="beta-tag">Coming Soon</span>;
7272

7373
return (
7474
<FeatureDetailsWrapper>
7575
<div onClick={() => setExpand(!expand)}>
76-
{description && (
76+
{(description || children) && (
7777
<div className="toggle-btn">
7878
{expand ? (
7979
<MdExpandMore
@@ -93,9 +93,16 @@ const FeatureDetails = ({ category, description, tier }) => {
9393
{tier === "Team-Beta" && <BetaTag />}
9494
</h5>
9595
<div className="details">
96-
<p className={`closed ${expand ? "open" : ""}`}
97-
dangerouslySetInnerHTML={{ __html: description }}>
98-
</p>
96+
{description && (
97+
<p className={`closed ${expand ? "open" : ""}`}
98+
dangerouslySetInnerHTML={{ __html: description }}>
99+
</p>
100+
)}
101+
{children && (
102+
<div className={`closed ${expand ? "open" : ""}`}>
103+
{children}
104+
</div>
105+
)}
99106
</div>
100107
</div>
101108
</FeatureDetailsWrapper>

0 commit comments

Comments
 (0)