Skip to content

Commit c6feb2b

Browse files
committed
Reduce features image size
1 parent 7ad25df commit c6feb2b

File tree

8 files changed

+15
-8
lines changed

8 files changed

+15
-8
lines changed

src/components/HomepageFeatures/index.tsx

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ type FeatureItem = {
1212
const FeatureList: FeatureItem[] = [
1313
{
1414
title: 'Modular Component System',
15-
image: '/img/features/modular-component-system.png',
15+
image: '/img/features/modular-component-system-480p.png',
1616
description: (
1717
<>
1818
Decouple interface definitions from implementations using provider traits.
@@ -22,7 +22,7 @@ const FeatureList: FeatureItem[] = [
2222
},
2323
{
2424
title: 'Highly Expressive Macros',
25-
image: '/img/features/highly-expressive-macros.png',
25+
image: '/img/features/highly-expressive-macros-480p.png',
2626
description: (
2727
<>
2828
Write abstract programs generic over contexts without managing long lists
@@ -32,7 +32,7 @@ const FeatureList: FeatureItem[] = [
3232
},
3333
{
3434
title: 'Type-Safe Composition',
35-
image: '/img/features/type-safe-composition.png',
35+
image: '/img/features/type-safe-composition-480p.png',
3636
description: (
3737
<>
3838
All component wiring is verified at compile time. Missing dependencies are
@@ -42,7 +42,7 @@ const FeatureList: FeatureItem[] = [
4242
},
4343
{
4444
title: 'No-Std Friendly',
45-
image: '/img/features/no-std-friendly.png',
45+
image: '/img/features/no-std-friendly-480p.png',
4646
description: (
4747
<>
4848
Build fully abstract programs without concrete dependencies. Deploy to
@@ -52,7 +52,7 @@ const FeatureList: FeatureItem[] = [
5252
},
5353
{
5454
title: 'Zero-Cost Abstraction',
55-
image: '/img/features/zero-cost-abstraction.png',
55+
image: '/img/features/zero-cost-abstraction-480p.png',
5656
description: (
5757
<>
5858
All CGP operations happen at compile time using Rust's type system.
@@ -62,7 +62,7 @@ const FeatureList: FeatureItem[] = [
6262
},
6363
{
6464
title: 'Bypass Coherence Rules',
65-
image: '/img/features/bypass-coherence-rules.png',
65+
image: '/img/features/bypass-coherence-rules-480p.png',
6666
description: (
6767
<>
6868
Enable overlapping and orphan trait implementations without restriction.

src/pages/index.tsx

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -75,20 +75,27 @@ function CodeExampleSection() {
7575
<div className="col col--6">
7676
<div className={styles.codeExample}>
7777
<CodeBlock language="rust">
78-
{`#[cgp_component(HashProvider)]
78+
{
79+
`#[cgp_component(HashProvider)]
7980
pub trait Hash { ... }
8081
82+
// Named overlappable implementation with provider trait
8183
#[cgp_impl(HashWithDisplay)]
8284
impl HashProvider
8385
where
8486
Self: Display,
8587
{ ... }
8688
89+
pub struct MyData { ... }
90+
impl Display for MyData { ... }
91+
8792
delegate_components! {
8893
MyData {
94+
// Implements Hash automatically
8995
HashProviderComponent: HashWithDisplay,
9096
}
91-
}`}
97+
}`
98+
}
9299
</CodeBlock>
93100
</div>
94101
</div>
303 KB
Loading
307 KB
Loading
271 KB
Loading
260 KB
Loading
284 KB
Loading
351 KB
Loading

0 commit comments

Comments
 (0)