Skip to content

Commit 4b2fdcd

Browse files
committed
Update icon sizes on Terraform component, add instructions about using our Icon, Button, and List components
1 parent 83e8fbd commit 4b2fdcd

2 files changed

Lines changed: 10 additions & 2 deletions

File tree

‎.github/instructions/general.instructions.md‎

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,14 @@ applyTo: "**"
2323
- Preact exists only for the Markdown E2E harness under `src/lib/markdown/__tests__/e2e`; all production UI components must use Lit web components instead of Preact.
2424
- Z-index: never hard-code numeric z-index values (including Tailwind `z-*` utilities). Always use the CSS variables in `src/styles/index.css` (e.g., `z-index: var(--z-nav)` or `z-(--z-nav)`). If no existing token fits, ask the user what z-layer to use before adding/changing tokens.
2525

26+
## Component Reuse Policy
27+
28+
- Prefer existing `List`, `Icon`, and `Button` components whenever possible.
29+
- `List`: use an existing list layout first. If no layout fits, ask the user before adding a new layout.
30+
- `Icon`: use existing icons first. If a new icon is needed, ask the user first and describe the icon you plan to add.
31+
- `Button`: use the shared `Button` component when the current API supports the use case.
32+
- If a button would require adding `Button` props or forcing behavior that does not match the component, ask the user before using a raw HTML `<button>`/`<a>`, and explain why.
33+
2634
## Tailwind CSS variable shorthand
2735

2836
- Our linting rules (Tailwind ESLint) require using Tailwind's custom property shorthand form: `fill-(--my-brand-color)`.

‎src/components/Animations/Terraform/index.astro‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -202,14 +202,14 @@ import Icon from '@components/Icon/index.astro'
202202
data-animation-icon="pause"
203203
class="flex h-12 w-12 items-center justify-center bg-transparent"
204204
>
205-
<Icon icon="pause" size={20} color="primary-inverse" />
205+
<Icon icon="pause" size={6} color="primary-inverse" />
206206
</span>
207207
<span
208208
data-animation-icon="play"
209209
class="flex h-12 w-12 items-center justify-center bg-transparent"
210210
style="display: none;"
211211
>
212-
<Icon icon="play" size={20} color="primary-inverse" />
212+
<Icon icon="play" size={6} color="primary-inverse" />
213213
</span>
214214
</button>
215215
</div>

0 commit comments

Comments
 (0)