Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(tile): compact link icon layout #2082

Open
wants to merge 23 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 3 commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
9cbd20a
fix(tile): compact link icon layout
bennypowers Dec 9, 2024
d24cdf1
docs(tile): icon and image
bennypowers Dec 9, 2024
66603c0
docs(tile): compact icon and fullwidth image
bennypowers Dec 9, 2024
0992e8f
fix(tile): layout for default slot content
bennypowers Dec 11, 2024
047b75c
docs(tile): elaborate on slots
bennypowers Dec 11, 2024
0ba8da4
style(tile): whitespace
bennypowers Dec 11, 2024
3eb8ca6
docs(tile): demo
bennypowers Dec 11, 2024
b26d33a
Merge branch 'main' into fix/tile/compact-link-icon-layout
bennypowers Dec 11, 2024
24722c2
docs(tile): clarify some js in demo
bennypowers Dec 12, 2024
b44596f
Merge branch 'main' into fix/tile/compact-link-icon-layout
bennypowers Jan 6, 2025
8316b73
fix(tile): compact layouts
bennypowers Jan 7, 2025
23d2be7
docs(tile): compact layouts
bennypowers Jan 7, 2025
bccd3f6
Merge branch 'main' into fix/tile/compact-link-icon-layout
bennypowers Jan 27, 2025
3e37eec
docs(tile): more icon and image demos
bennypowers Jan 27, 2025
e7a1c49
fix(tile): margin for icons
bennypowers Jan 27, 2025
30154b3
perf(tile): remove shadow styles from lightdom sheet
bennypowers Jan 27, 2025
a4caf71
Merge branch 'main' into fix/tile/compact-link-icon-layout
bennypowers Feb 9, 2025
425a2a7
Merge branch 'main' into fix/tile/compact-link-icon-layout
bennypowers Feb 19, 2025
b1f6d89
docs(tile): icon slot
bennypowers Feb 27, 2025
30e22a7
Merge branch 'main' into fix/tile/compact-link-icon-layout
bennypowers Feb 27, 2025
6a2f9ff
docs(tile): slotted icon in desaturated heading
bennypowers Feb 27, 2025
57c54fe
fix(tile): default background
bennypowers Feb 27, 2025
56d8433
fix(tile): color palette attr in context
bennypowers Feb 27, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .changeset/clever-webs-appear.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
---
"@rhds/elements": patch
---
`<rh-tile>`: fixed layout of compact link tiles with icons
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
<rh-tile compact bleed>
<rh-icon slot="icon" set="standard" icon="mug"></rh-icon>
<svg slot="image" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 320 120">
<title>A placeholder image in a card header slot</title>
<rect x="0"
y="0"
width="320"
height="120"
fill="var(--rh-color-interactive-primary-default)"
fill-opacity="0.2"
stroke="var(--rh-color-interactive-primary-hover)"
stroke-width="1"
stroke-dasharray="1 1"
/>
</svg>
<h2 slot="headline"><a href="#top">Compact link tile</a></h2>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam eleifend elit set est egestat, a sollicitudn mauris tincidunt.</p>
</rh-tile>


<script type="module">
import '@rhds/elements/rh-tile/rh-tile.js';
</script>

<link rel="stylesheet" href="../rh-tile-lightdom.css">

<style>
rh-tile rh-icon {
color: var(--rh-color-brand-red);
}
</style>

18 changes: 18 additions & 0 deletions elements/rh-tile/demo/compact-link-with-icon.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
<rh-tile compact desaturated>
<h2 slot="headline"><a href="#top">Compact link tile</a></h2>
<rh-icon slot="icon" set="standard" icon="mug"></rh-icon>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam eleifend elit set est egestat, a sollicitudn mauris tincidunt.</p>
</rh-tile>

<script type="module">
import '@rhds/elements/rh-tile/rh-tile.js';
</script>

<link rel="stylesheet" href="../rh-tile-lightdom.css">

<style>
rh-tile rh-icon {
color: var(--rh-color-brand-red);
}
</style>

32 changes: 32 additions & 0 deletions elements/rh-tile/demo/compact-link-with-image-and-icon.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
<rh-tile compact>
<rh-icon slot="icon" set="standard" icon="mug"></rh-icon>
<svg slot="image" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 320 120">
<title>A placeholder image in a card header slot</title>
<rect x="0"
y="0"
width="320"
height="120"
fill="var(--rh-color-interactive-primary-default)"
fill-opacity="0.2"
stroke="var(--rh-color-interactive-primary-hover)"
stroke-width="1"
stroke-dasharray="1 1"
/>
</svg>
<h2 slot="headline"><a href="#top">Compact link tile</a></h2>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam eleifend elit set est egestat, a sollicitudn mauris tincidunt.</p>
</rh-tile>


<script type="module">
import '@rhds/elements/rh-tile/rh-tile.js';
</script>

<link rel="stylesheet" href="../rh-tile-lightdom.css">

<style>
rh-tile rh-icon {
color: var(--rh-color-brand-red);
}
</style>

18 changes: 18 additions & 0 deletions elements/rh-tile/demo/compact-link-with-image.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
<rh-tile compact desaturated>
<h2 slot="headline"><a href="#top">Compact link tile</a></h2>
<rh-icon slot="icon" set="standard" icon="mug"></rh-icon>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam eleifend elit set est egestat, a sollicitudn mauris tincidunt.</p>
</rh-tile>

<script type="module">
import '@rhds/elements/rh-tile/rh-tile.js';
</script>

<link rel="stylesheet" href="../rh-tile-lightdom.css">

<style>
rh-tile rh-icon {
color: var(--rh-color-brand-red);
}
</style>

6 changes: 5 additions & 1 deletion elements/rh-tile/rh-tile.css
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,11 @@
#inner,
#content {
display: flex;
flex-flow: column;
flex-direction: column;
}

.compact #inner {
flex-direction: row;
}

#outer,
Expand Down
Loading