Skip to content

Commit e42a26b

Browse files
authored
feat: clean up stylesheets (#1845)
The SDK stylesheet had a lot of icons used in our sample apps, unnecessarily increasing the size of the shipped CSS. This PR moves those icons to the appropriate sample applications and trims around 50KB of SDK CSS. As part of this refactor, a few more improvements are made: - Vendored CSS properties are sorted correctly, so they don't take precedence - updates to the latest `sass` version
1 parent a99de4c commit e42a26b

File tree

65 files changed

+591
-424
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

65 files changed

+591
-424
lines changed

packages/styling/index.scss

Lines changed: 25 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -4,28 +4,28 @@
44
@use 'src/global-theme-variables';
55
@use 'src/utils';
66

7-
@import 'src/Avatar';
8-
@import 'src/Button';
9-
@import 'src/BackgroundFilters';
10-
@import 'src/CallControls';
11-
@import 'src/CallLayout';
12-
@import 'src/CallParticipantList';
13-
@import 'src/CallPreview';
14-
@import 'src/CallRecodingList';
15-
@import 'src/CallStats';
16-
@import 'src/DeviceSettings';
17-
@import 'src/DropdownSelect';
18-
@import 'src/Icon';
19-
@import 'src/LoadingIndicator';
20-
@import 'src/Menu';
21-
@import 'src/Notification';
22-
@import 'src/ParticipantView';
23-
@import 'src/Permissions';
24-
@import 'src/Reaction';
25-
@import 'src/RingingCall';
26-
@import 'src/ScreenShareOverlay';
27-
@import 'src/Search';
28-
@import 'src/StreamCall';
29-
@import 'src/Tooltip';
30-
@import 'src/Video';
31-
@import 'src/VideoPreview';
7+
@use 'src/Avatar';
8+
@use 'src/Button';
9+
@use 'src/BackgroundFilters';
10+
@use 'src/CallControls';
11+
@use 'src/CallLayout';
12+
@use 'src/CallParticipantList';
13+
@use 'src/CallPreview';
14+
@use 'src/CallRecodingList';
15+
@use 'src/CallStats';
16+
@use 'src/DeviceSettings';
17+
@use 'src/DropdownSelect';
18+
@use 'src/Icon';
19+
@use 'src/LoadingIndicator';
20+
@use 'src/Menu';
21+
@use 'src/Notification';
22+
@use 'src/ParticipantView';
23+
@use 'src/Permissions';
24+
@use 'src/Reaction';
25+
@use 'src/RingingCall';
26+
@use 'src/ScreenShareOverlay';
27+
@use 'src/Search';
28+
@use 'src/StreamCall';
29+
@use 'src/Tooltip';
30+
@use 'src/Video';
31+
@use 'src/VideoPreview';

packages/styling/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,6 @@
99
},
1010
"devDependencies": {
1111
"rimraf": "^6.0.1",
12-
"sass": "^1.69.5"
12+
"sass": "^1.89.2"
1313
}
1414
}
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
@import "Avatar-layout";
2-
@import "Avatar-theme";
1+
@use 'Avatar-layout';
2+
@use 'Avatar-theme';
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
@import 'BackgroundFilters-layout';
1+
@use 'BackgroundFilters-layout';
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
@import "Button-layout";
2-
@import "Button-theme";
1+
@use 'Button-layout';
2+
@use 'Button-theme';
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
@import 'CallControls-layout';
2-
@import 'CancelCallButton';
1+
@use 'CallControls-layout';
2+
@use 'CancelCallButton';
Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
@import './LivestreamLayout-layout';
2-
@import './PaginatedGridLayout-layout';
3-
@import './SpeakerLayout-layout';
4-
@import './PipLayout-layout.scss';
5-
@import './PipLayout-theme.scss';
1+
@use 'LivestreamLayout-layout';
2+
@use 'PaginatedGridLayout-layout';
3+
@use 'SpeakerLayout-layout';
4+
@use 'PipLayout-layout.scss';
5+
@use 'PipLayout-theme.scss';

packages/styling/src/CallParticipantList/CallParticipantList-layout.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,8 +78,8 @@ $scope-name: 'str-video__participant-list';
7878
$indicator-size: 3rem;
7979
height: $indicator-size;
8080
width: $indicator-size;
81-
mask-size: $indicator-size;
8281
-webkit-mask-size: $indicator-size;
82+
mask-size: $indicator-size;
8383
}
8484
}
8585

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
@import "CallParticipantList-layout";
2-
@import "CallParticipantList-theme";
3-
@import "CallParticiantListingItem-layout";
4-
@import "CallParticiantListingItem-theme";
1+
@use 'CallParticipantList-layout';
2+
@use 'CallParticipantList-theme';
3+
@use 'CallParticiantListingItem-layout';
4+
@use 'CallParticiantListingItem-theme';
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
@import 'CallPreview-layout';
1+
@use 'CallPreview-layout';

0 commit comments

Comments
 (0)