Commit 7130ec8e by t0ng7u

๐Ÿ› fix(PricingCardView): hide placeholder dash when no custom tags

Previously, the card view displayed a โ€œ-โ€ whenever a model had no custom tags,
because `renderLimitedItems` returned a dash for an empty array.
Now the function is only invoked when `customTags.length > 0`, removing the
unwanted placeholder and keeping the UI clean.

File affected:
- web/src/components/table/model-pricing/view/card/PricingCardView.jsx
parent c79b6cea
...@@ -171,7 +171,7 @@ const PricingCardView = ({ ...@@ -171,7 +171,7 @@ const PricingCardView = ({
{billingTag} {billingTag}
</div> </div>
<div className="flex items-center gap-1"> <div className="flex items-center gap-1">
{renderLimitedItems({ {customTags.length > 0 && renderLimitedItems({
items: customTags.map((tag, idx) => ({ key: `custom-${idx}`, element: tag })), items: customTags.map((tag, idx) => ({ key: `custom-${idx}`, element: tag })),
renderItem: (item, idx) => item.element, renderItem: (item, idx) => item.element,
maxDisplay: 3 maxDisplay: 3
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment