diff options
| author | Armand Philippot <git@armandphilippot.com> | 2022-01-06 19:27:45 +0100 |
|---|---|---|
| committer | Armand Philippot <git@armandphilippot.com> | 2022-01-06 19:30:06 +0100 |
| commit | 722ec20bad64d8c69b173c163011d37ad0b55591 (patch) | |
| tree | 0470e54f758d9383fff3fdb4c9b685faa3bde6ae /src/components/Sharing | |
| parent | 1494985a636fe22417615648062f17bc82c35655 (diff) | |
chore: move Main grid to its children
This way I can use full width background for some blocks.
Diffstat (limited to 'src/components/Sharing')
| -rw-r--r-- | src/components/Sharing/Sharing.module.scss | 14 | ||||
| -rw-r--r-- | src/components/Sharing/Sharing.tsx | 5 |
2 files changed, 13 insertions, 6 deletions
diff --git a/src/components/Sharing/Sharing.module.scss b/src/components/Sharing/Sharing.module.scss index 3186675..fe13125 100644 --- a/src/components/Sharing/Sharing.module.scss +++ b/src/components/Sharing/Sharing.module.scss @@ -2,11 +2,18 @@ @use "@styles/abstracts/mixins" as mix; @use "@styles/abstracts/placeholders"; +.wrapper { + max-height: 100vh; + padding-bottom: var(--spacing-sm); + position: sticky; + top: 0; + overflow-y: auto; +} + .list { @extend %flex-list; gap: var(--spacing-sm); - margin-bottom: var(--spacing-md); } .link { @@ -55,9 +62,8 @@ filter: drop-shadow( #{fun.convert-px(1)} #{fun.convert-px(1)} #{fun.convert-px(1)} hsl(0, 0%, 0%) ); - width: 2ex; - height: 2ex; - margin-right: var(--spacing-2xs); + width: fun.convert-px(30); + height: fun.convert-px(30); } &--diaspora { diff --git a/src/components/Sharing/Sharing.tsx b/src/components/Sharing/Sharing.tsx index 4bcad5d..4df8e0d 100644 --- a/src/components/Sharing/Sharing.tsx +++ b/src/components/Sharing/Sharing.tsx @@ -90,9 +90,10 @@ const Sharing = ({ excerpt, title }: { excerpt: string; title: string }) => { <li key={id}> <a href={sharingUrl} + title={name} className={`${styles.link} ${styles[linkModifier]}`} > - {name} + <span className="screen-reader-text">{name}</span> </a> </li> ); @@ -100,7 +101,7 @@ const Sharing = ({ excerpt, title }: { excerpt: string; title: string }) => { }; return ( - <div> + <div className={styles.wrapper}> <h2>{t`Share`}</h2> <ul className={styles.list}>{getItems()}</ul> </div> |
