Skip to content

Commit c76cbca

Browse files
authored
Frontend performance improvements (#36)
* Compress images, move images from public to assets * Update paths * Add changelog
1 parent c0f59a9 commit c76cbca

9 files changed

Lines changed: 16 additions & 4 deletions

File tree

‎CHANGELOG.rst‎

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,14 @@
22
Changelog
33
=========
44

5+
Version 0.5.2
6+
==========================
7+
8+
* Some performance improvements:
9+
* Compress images
10+
* Move images from `public` to `src/assets` to allow for better bundling and caching with Vite.
11+
12+
513

614
Version 0.5.1
715
==========================

‎public/FiQCI-logo.png‎

-62 KB
Binary file not shown.

‎public/aalto-q20.jpg‎

-105 KB
Binary file not shown.

‎public/vtt-q50.jpg‎

-1.02 MB
Binary file not shown.

‎src/assets/FiQCI-logo.png‎

23.4 KB
Loading

‎src/assets/aalto-q20.jpg‎

45.8 KB
Loading

‎src/assets/vtt-q50.jpg‎

88.7 KB
Loading

‎src/components/DeviceSelector.jsx‎

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
import React from 'react';
2+
import vttQ50Image from '../assets/vtt-q50.jpg';
3+
import aaltoQ20Image from '../assets/aalto-q20.jpg';
24

35
const fontFamily = '-apple-system,BlinkMacSystemFont,"Roboto","Segoe UI","Helvetica Neue","Lucida Grande",Arial,sans-serif';
46

@@ -122,13 +124,13 @@ const DeviceSelector = ({ selectedDevice, onDeviceSelect }) => {
122124
<div style={gridStyle}>
123125
<DeviceCard
124126
title="VTT Q50"
125-
image="./vtt-q50.jpg"
127+
image={vttQ50Image}
126128
isSelected={selectedDevice === 'vtt-q50'}
127129
onClick={() => onDeviceSelect('vtt-q50')}
128130
/>
129131
<DeviceCard
130132
title="Aalto Q20"
131-
image="./aalto-q20.jpg"
133+
image={aaltoQ20Image}
132134
isSelected={selectedDevice === 'aalto-q20'}
133135
onClick={() => onDeviceSelect('aalto-q20')}
134136
/>

‎src/components/Header.jsx‎

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import React from 'react';
2-
import fiqciLogo from '/FiQCI-logo.png';
2+
import fiqciLogo from '../assets/FiQCI-logo.png';
33
import { DocumentationButton } from './Documentation';
44

55
const Header = ({ onOpenDocumentation }) => {
@@ -34,7 +34,9 @@ const Header = ({ onOpenDocumentation }) => {
3434
<img
3535
src={fiqciLogo}
3636
alt="FiQCI Logo"
37-
style={{height: '2.5rem'}}
37+
width="340"
38+
height="100"
39+
style={{height: '2.5rem', width: 'auto'}}
3840
/>
3941
</div>
4042
<h1 style={{

0 commit comments

Comments
 (0)