@maccesar/aiskills 1.9.2 → 1.10.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +5 -1
- package/package.json +1 -1
- package/skills/refactoring-ui/SKILL.md +31 -32
- package/skills/refactoring-ui/references/01-foundations.md +69 -0
- package/skills/refactoring-ui/references/02-page-mechanics.md +204 -0
- package/skills/refactoring-ui/references/03-visual-treatment.md +242 -0
- package/skills/refactoring-ui/references/04-polish.md +96 -0
- package/skills/stitch-showcase/SKILL.md +15 -11
- package/skills/refactoring-ui/references/01-design-process.md +0 -72
- package/skills/refactoring-ui/references/02-visual-hierarchy.md +0 -84
- package/skills/refactoring-ui/references/03-layout-spacing.md +0 -69
- package/skills/refactoring-ui/references/04-typography.md +0 -70
- package/skills/refactoring-ui/references/05-color.md +0 -96
- package/skills/refactoring-ui/references/06-depth-shadows.md +0 -74
- package/skills/refactoring-ui/references/07-images.md +0 -75
- package/skills/refactoring-ui/references/08-finishing-touches.md +0 -91
|
@@ -1,75 +0,0 @@
|
|
|
1
|
-
# Ch7 — Working with Images
|
|
2
|
-
|
|
3
|
-
Source: "Refactoring UI" by Adam Wathan & Steve Schoger
|
|
4
|
-
|
|
5
|
-
---
|
|
6
|
-
|
|
7
|
-
## Use Real Images From Day One
|
|
8
|
-
|
|
9
|
-
- Never design with placeholder images (grey boxes, lorem ipsum images)
|
|
10
|
-
- Placeholder images lie about how real content will look — especially for products, people, and covers
|
|
11
|
-
- Hire a photographer or use quality stock photo services (e.g., Unsplash)
|
|
12
|
-
- The visual design must work with actual images, not idealized placeholders
|
|
13
|
-
|
|
14
|
-
## Text Over Images
|
|
15
|
-
|
|
16
|
-
Option 1: **Semi-transparent overlay**
|
|
17
|
-
- Add a dark overlay (black) for light-colored text on top of a photo
|
|
18
|
-
- Add a light overlay (white) for dark-colored text on top of a photo
|
|
19
|
-
- Overlay controls how much of the image shows through
|
|
20
|
-
|
|
21
|
-
Option 2: **Lower image contrast + adjust brightness**
|
|
22
|
-
- Reduce contrast on the image itself so text has a more uniform background
|
|
23
|
-
- Brighten or darken the whole image to create a consistently light/dark canvas for text
|
|
24
|
-
|
|
25
|
-
Option 3: **Colorize the image**
|
|
26
|
-
- Desaturate the image (remove color)
|
|
27
|
-
- Apply a solid fill layer using "multiply" blend mode in your design tool
|
|
28
|
-
- Result: a single-color tone that text can sit on top of
|
|
29
|
-
|
|
30
|
-
Option 4: **Text shadow**
|
|
31
|
-
- Use a large blur, no offset text-shadow behind the text
|
|
32
|
-
- Creates a soft halo that separates text from the image background
|
|
33
|
-
- Best for small amounts of text (headlines, labels)
|
|
34
|
-
|
|
35
|
-
## Icons at Scale
|
|
36
|
-
|
|
37
|
-
- Icons designed at 16–24px look chunky and blurry when scaled to 3–4×
|
|
38
|
-
- At large sizes, use a **shaped container** with a background color instead of a raw oversized icon
|
|
39
|
-
- Put the icon inside a circle, rounded square, or other shape
|
|
40
|
-
- Scale the container to the needed size; keep the icon at its native size (or slightly larger)
|
|
41
|
-
- This prevents the "blown up icon" problem while adding visual polish
|
|
42
|
-
|
|
43
|
-
## Screenshots
|
|
44
|
-
|
|
45
|
-
Three problems with using screenshots at full scale:
|
|
46
|
-
- At 70% scale, 16px font becomes ~11px — unreadable
|
|
47
|
-
- At 50% scale, 16px font becomes 8px — completely illegible
|
|
48
|
-
|
|
49
|
-
Solutions:
|
|
50
|
-
1. **Use a tablet/narrow layout screenshot** instead of a full desktop one — content scales better
|
|
51
|
-
2. **Take a partial screenshot** — crop to just the relevant portion
|
|
52
|
-
3. **Draw a simplified version** — remove most UI, keep only what illustrates the point
|
|
53
|
-
4. Never rely on the viewer being able to read or understand text in a thumbnail screenshot
|
|
54
|
-
|
|
55
|
-
## Favicons
|
|
56
|
-
|
|
57
|
-
- A 128px logo shrunk to 16px is unrecognizable — too much detail is lost
|
|
58
|
-
- **Redraw the favicon at target size** from scratch (16×16, 32×32)
|
|
59
|
-
- Keep it to 1–2 elements; use just the icon mark, not the full wordmark
|
|
60
|
-
- Test it at 1× actual size while designing — what looks good at 128px often looks like noise at 16px
|
|
61
|
-
|
|
62
|
-
## User-Uploaded Images
|
|
63
|
-
|
|
64
|
-
Two problems: aspect ratio and background bleed.
|
|
65
|
-
|
|
66
|
-
**Aspect ratio:** User uploads won't match your layout's expected proportions.
|
|
67
|
-
- Use fixed containers (set width and height)
|
|
68
|
-
- Apply `background-size: cover` (or the equivalent `object-fit: cover`)
|
|
69
|
-
- Let the browser/engine center and crop to fill the container
|
|
70
|
-
|
|
71
|
-
**Background bleed:** Images with white or light backgrounds bleed into light-colored page backgrounds.
|
|
72
|
-
- Don't use a visible border — it creates a box outline that looks heavy
|
|
73
|
-
- Instead, add a subtle **inner box-shadow** (inset): `box-shadow: inset 0 0 0 1px rgba(0,0,0,0.1)`
|
|
74
|
-
- This creates a soft inner ring that defines the edge without a harsh border
|
|
75
|
-
- Works across all image background colors since it sits on top of the image
|
|
@@ -1,91 +0,0 @@
|
|
|
1
|
-
# Ch8+9 — Finishing Touches & Leveling Up
|
|
2
|
-
|
|
3
|
-
Source: "Refactoring UI" by Adam Wathan & Steve Schoger
|
|
4
|
-
|
|
5
|
-
---
|
|
6
|
-
|
|
7
|
-
## Replace Bullets with Icons
|
|
8
|
-
|
|
9
|
-
- Default bullet points feel generic and low-effort
|
|
10
|
-
- Replace with icons that match the content:
|
|
11
|
-
- Checkmarks for feature lists or completed items
|
|
12
|
-
- Arrows for directional or sequential lists
|
|
13
|
-
- Content-specific icons (e.g., lock icon for "secure", globe for "worldwide")
|
|
14
|
-
- Icons add visual interest and reinforce meaning simultaneously
|
|
15
|
-
|
|
16
|
-
## Promote Quotation Marks as Visual Elements
|
|
17
|
-
|
|
18
|
-
- Large, decorative quotation marks can become a design element in testimonials and pull quotes
|
|
19
|
-
- Make them large, colorful (use an accent color), and position them prominently
|
|
20
|
-
- The quote mark becomes part of the visual design, not just punctuation
|
|
21
|
-
|
|
22
|
-
## Style Links Intentionally
|
|
23
|
-
|
|
24
|
-
Two approaches depending on context:
|
|
25
|
-
1. **Color + weight:** The standard blue link, but use brand color + slightly heavier font weight
|
|
26
|
-
2. **Thick colorful underline:** A thick border-bottom (2–4px) in an accent color that partially overlaps the bottom of the text
|
|
27
|
-
- Creates visual interest while remaining clearly a link
|
|
28
|
-
- Can use a different color from the text for contrast
|
|
29
|
-
|
|
30
|
-
## Custom Checkboxes and Radio Buttons
|
|
31
|
-
|
|
32
|
-
- Browser default inputs look generic and don't match brand identity
|
|
33
|
-
- Replace with custom-styled equivalents using brand color for the checked state
|
|
34
|
-
- Common pattern: custom checkbox with a checkmark SVG on a colored background
|
|
35
|
-
- Worth the extra markup for polished forms
|
|
36
|
-
|
|
37
|
-
## Accent Borders
|
|
38
|
-
|
|
39
|
-
Use a short, thick accent-color border as a decorative element:
|
|
40
|
-
- **Top of card:** a colored bar at the top edge of a card or panel
|
|
41
|
-
- **Left side of active nav item:** indicates current page/section
|
|
42
|
-
- **Left side of alert message:** differentiates alert types (red=danger, yellow=warning, green=success)
|
|
43
|
-
- **Under a headline:** a short thick underline using brand color
|
|
44
|
-
- **Top of the entire page layout:** thin color strip across the very top
|
|
45
|
-
|
|
46
|
-
These are simple, high-impact touches that add brand identity without complexity.
|
|
47
|
-
|
|
48
|
-
## Background Decoration
|
|
49
|
-
|
|
50
|
-
Options for making backgrounds interesting:
|
|
51
|
-
1. **Solid color change:** Switch from white to a brand color or neutral tint
|
|
52
|
-
2. **Gradient:** Use two hues that are no more than 30° apart on the color wheel — closer = more natural, farther = jarring
|
|
53
|
-
3. **Low-contrast repeating pattern:** Subtle geometric pattern (dots, lines, hatching) at low opacity
|
|
54
|
-
4. **Geometric shapes:** Abstract colored shapes or blobs in the background at low opacity
|
|
55
|
-
|
|
56
|
-
Key rule for gradients: keep hues within 30° of each other for a natural look.
|
|
57
|
-
|
|
58
|
-
## Empty States Are a Priority, Not an Afterthought
|
|
59
|
-
|
|
60
|
-
- Most UIs look broken or confusing when completely empty
|
|
61
|
-
- Design the empty state before adding content — it's often the first thing new users see
|
|
62
|
-
|
|
63
|
-
Good empty state components:
|
|
64
|
-
- Illustration or icon that's contextually relevant
|
|
65
|
-
- Brief, friendly explanation of what belongs here
|
|
66
|
-
- Clear call-to-action (e.g., "Add your first project" button)
|
|
67
|
-
|
|
68
|
-
Additional rule: **hide irrelevant UI until it has content**
|
|
69
|
-
- Tabs with no content, filters with no items, pagination with one page — all look broken empty
|
|
70
|
-
- Don't render those elements until there's content that makes them useful
|
|
71
|
-
|
|
72
|
-
## Alternatives to Borders
|
|
73
|
-
|
|
74
|
-
Borders are often overused. Replace them with:
|
|
75
|
-
1. **Box shadow:** `box-shadow: 0 1px 3px rgba(0,0,0,0.1)` — creates separation without a hard line
|
|
76
|
-
2. **Two different background colors:** alternating section backgrounds communicate separation without borders
|
|
77
|
-
3. **Extra spacing:** more white space between sections often eliminates the need for a border entirely
|
|
78
|
-
|
|
79
|
-
## Think Outside the Box
|
|
80
|
-
|
|
81
|
-
Don't default to generic UI patterns when something more engaging is possible:
|
|
82
|
-
|
|
83
|
-
- **Enriched dropdowns:** add icons, sections, descriptions, or two-column layouts inside dropdowns
|
|
84
|
-
- **Table column hierarchy:** instead of flat equal-weight columns, apply visual hierarchy within cells (primary value large/dark, secondary value small/grey)
|
|
85
|
-
- **Selectable cards instead of radio buttons:** replace radio button groups with styled card options that highlight on selection — more visual, easier to scan
|
|
86
|
-
|
|
87
|
-
## Leveling Up Your Eye
|
|
88
|
-
|
|
89
|
-
Two practices from the book:
|
|
90
|
-
1. **Study unintuitive decisions in good designs:** Look at polished UIs and ask "why did they do that?" Notice the specific, non-obvious choices — the things you wouldn't have thought of
|
|
91
|
-
2. **Rebuild interfaces without DevTools:** Pick a UI from a product you admire and recreate it from scratch, without inspecting the original. Forces you to make real design decisions rather than copying values
|