Skip to content

Commit

Permalink
change(card): Reserve space for meta section
Browse files Browse the repository at this point in the history
  • Loading branch information
kreafox committed Nov 18, 2022
1 parent b727a11 commit f3c581b
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/components/UniversalCard/fragments/CardMeta.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,11 @@ const CardMeta = (props) => {
const locale = config.settings.dateLocale || 'en-gb';
const showDate = itemModel.hasDate !== false && EffectiveDate !== 'None';
const showMeta = !!(head_title || (itemModel?.hasMetaType && item['@type']));
const show = showDate || showMeta;
// const show = showDate || showMeta;

// TODO: <EEAFormattedDate data={EffectiveDate} />

return show ? (
return (
<UiCard.Meta>
{showMeta && (
<span className="text-left">{head_title || item['Type']}</span>
Expand All @@ -32,7 +32,7 @@ const CardMeta = (props) => {
</span>
)}
</UiCard.Meta>
) : null;
);
};

export default CardMeta;
4 changes: 4 additions & 0 deletions src/less/listing-cards.less
Original file line number Diff line number Diff line change
Expand Up @@ -186,6 +186,10 @@ each(range(5), {
}

.ui.card.u-card {
.meta:after {
content: '\200b';
}

.description {
display: -webkit-box;
overflow: hidden;
Expand Down

0 comments on commit f3c581b

Please sign in to comment.