Skip to content

Commit

Permalink
Merge branch 'main' into fix-ds-sidebar-empty-links-202312
Browse files Browse the repository at this point in the history
  • Loading branch information
Fupete authored Dec 14, 2023
2 parents ada0bcd + ecf2633 commit f61cf7b
Show file tree
Hide file tree
Showing 4 changed files with 42 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,14 @@ function ListArchiveAllTags({ background, noSpace }) {
addonClasses="align-items-start border-bottom-0 pt-3 px-0 px-sm-2 px-md-4"
>
<Chip label={tag.fieldValue} size="lg" color="primary">
<span className="ms-2 badge neutral-2-bg text-secondary my-0 pb-1">
<span className="ms-2 badge bg-primary rounded-pill">
<span className="visually-hidden">[</span>
{tag.totalCount}
{tag.totalCount === 1 ? (
<span className="visually-hidden"> scheda ]</span>
) : (
<span className="visually-hidden"> schede ]</span>
)}
</span>
</Chip>
</ListItem>
Expand Down
8 changes: 7 additions & 1 deletion src/components/list-archive-ds-tags/list-archive-ds-tags.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,14 @@ function ListArchiveDSTags() {
color="primary"
path="design-system/componenti/utili-per"
>
<span className="ms-2 badge neutral-2-bg text-secondary my-0 pb-1">
<span className="ms-2 badge bg-primary rounded-pill small">
<span className="visually-hidden">[</span>
{tag.totalCount}
{tag.totalCount === 1 ? (
<span className="visually-hidden"> componente ]</span>
) : (
<span className="visually-hidden"> componenti ]</span>
)}
</span>
</Chip>
</ListItem>
Expand Down
8 changes: 4 additions & 4 deletions src/data/content/design-system/fondamenti/griglia.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ components:
- text: 540px
- text: 720px
- text: 960px
- text: 1184px
- text: 1176px
- text: 1320px
- cols:
- text: Contenitore responsive (small)
Expand All @@ -159,7 +159,7 @@ components:
- text: 100%
- text: 720px
- text: 960px
- text: 1184px
- text: 1176px
- text: 1320px
- cols:
- text: Contenitore responsive (medium)
Expand All @@ -168,7 +168,7 @@ components:
- text: 100%
- text: 100%
- text: 960px
- text: 1184px
- text: 1176px
- text: 1320px
- cols:
- text: Contenitore responsive (large)
Expand All @@ -177,7 +177,7 @@ components:
- text: 100%
- text: 100%
- text: 100%
- text: 1184px
- text: 1176px
- text: 1320px
- cols:
- text: Contenitore responsive (extra large)
Expand Down
24 changes: 24 additions & 0 deletions src/scss/custom.scss
Original file line number Diff line number Diff line change
Expand Up @@ -61,3 +61,27 @@ div.chips-list-wrapper {
}
scroll-margin-top: $header-center-max-height-mob + 48;
}

// special chips with numeric rounded-pill badge inside ("argomenti")
.chips-list-wrapper {
.chips-list {
.chip-simple {
span.badge {
&.rounded-pill {
transform: translateY(-1px);
}
}

&:hover {
span.badge {
&.rounded-pill {
&.bg-primary {
background-color: white !important;
color: var(--primary-color);
}
}
}
}
}
}
}

0 comments on commit f61cf7b

Please sign in to comment.