Skip to content

Commit

Permalink
Update: display padlock for locked items (fixes #209) (#210)
Browse files Browse the repository at this point in the history
  • Loading branch information
kirsty-hames authored Mar 21, 2024
1 parent 3575a4e commit cee2782
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 2 deletions.
16 changes: 14 additions & 2 deletions less/pageLevelProgress.less
Original file line number Diff line number Diff line change
Expand Up @@ -14,15 +14,27 @@
&__item-btn {
display: flex;
align-items: center;
justify-content: center;
justify-content: space-between;
}

&__item-title {
width: 75%;
}

&__indicator {
margin: 0 calc(~'12.5% - 1rem');
margin-inline-start: calc(~'25% - 1rem');
}

&__item-btn:not(.is-locked) .pagelevelprogress__item-icon {
display: none;
}

&__item-btn.is-locked .pagelevelprogress__item-icon .icon {
.icon-padlock-locked;
}

&__item-btn.is-locked .pagelevelprogress__indicator {
display: none;
}

&__item-optional {
Expand Down
4 changes: 4 additions & 0 deletions templates/pageLevelProgressItem.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,10 @@ export default function PageLevelProgressItem(props) {
</span>
}

<span className='pagelevelprogress__item-icon'>
<span className='icon' aria-hidden="true"></span>
</span>

</button>
<div className='pagelevelprogress__item-children'>
<div role="list" className="js-children">
Expand Down

0 comments on commit cee2782

Please sign in to comment.