Skip to content

Commit 52fa482

Browse files
committed
styles: Rename .scss files back to .css.
css-loader@4 broke @import statements referencing files with extensions other than .css, unless those @import statements are compiled away by another loader. Upstream is more interested in arguing that such @import statements are semantically incorrect than applying the one line fix. webpack-contrib/css-loader#1164 Signed-off-by: Anders Kaseorg <[email protected]>
1 parent 4c2a0c7 commit 52fa482

Some content is hidden

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

53 files changed

+154
-155
lines changed

.editorconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ indent_style = space
77
insert_final_newline = true
88
trim_trailing_whitespace = true
99

10-
[*.{sh,py,pyi,xml,css,scss,hbs,html}]
10+
[*.{sh,py,pyi,xml,css,hbs,html}]
1111
indent_size = 4
1212

1313
[{*.{js,json,ts},check-openapi}]

docs/subsystems/html-css.md

Lines changed: 5 additions & 5 deletions

package.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,6 @@
5050
"postcss-extend-rule": "^3.0.0",
5151
"postcss-loader": "^3.0.0",
5252
"postcss-nested": "^4.1.2",
53-
"postcss-scss": "^2.0.0",
5453
"postcss-simple-vars": "^5.0.2",
5554
"regenerator-runtime": "^0.13.3",
5655
"script-loader": "^0.7.2",

postcss.config.js

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
"use strict";
22

3-
module.exports = ({file}) => ({
4-
parser: file.extname === ".scss" ? "postcss-scss" : false,
3+
module.exports = {
54
plugins: {
65
// Warning: despite appearances, order is significant
76
"postcss-nested": {},
@@ -10,4 +9,4 @@ module.exports = ({file}) => ({
109
"postcss-calc": {},
1110
autoprefixer: {},
1211
},
13-
});
12+
};

static/js/bundles/app.js

Lines changed: 25 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -202,31 +202,31 @@ import "spectrum-colorpicker/spectrum.css";
202202
import "katex/dist/katex.css";
203203
import "flatpickr/dist/flatpickr.css";
204204
import "flatpickr/dist/plugins/confirmDate/confirmDate.css";
205-
import "../../styles/components.scss";
206-
import "../../styles/app_components.scss";
207-
import "../../styles/rendered_markdown.scss";
208-
import "../../styles/zulip.scss";
209-
import "../../styles/alerts.scss";
210-
import "../../styles/settings.scss";
211-
import "../../styles/image_upload_widget.scss";
212-
import "../../styles/subscriptions.scss";
213-
import "../../styles/drafts.scss";
214-
import "../../styles/input_pill.scss";
215-
import "../../styles/informational-overlays.scss";
216-
import "../../styles/compose.scss";
217-
import "../../styles/message_edit_history.scss";
218-
import "../../styles/reactions.scss";
219-
import "../../styles/user_circles.scss";
220-
import "../../styles/left-sidebar.scss";
221-
import "../../styles/right-sidebar.scss";
222-
import "../../styles/lightbox.scss";
223-
import "../../styles/popovers.scss";
224-
import "../../styles/recent_topics.scss";
225-
import "../../styles/typing_notifications.scss";
226-
import "../../styles/hotspots.scss";
227-
import "../../styles/night_mode.scss";
228-
import "../../styles/user_status.scss";
229-
import "../../styles/widgets.scss";
205+
import "../../styles/components.css";
206+
import "../../styles/app_components.css";
207+
import "../../styles/rendered_markdown.css";
208+
import "../../styles/zulip.css";
209+
import "../../styles/alerts.css";
210+
import "../../styles/settings.css";
211+
import "../../styles/image_upload_widget.css";
212+
import "../../styles/subscriptions.css";
213+
import "../../styles/drafts.css";
214+
import "../../styles/input_pill.css";
215+
import "../../styles/informational-overlays.css";
216+
import "../../styles/compose.css";
217+
import "../../styles/message_edit_history.css";
218+
import "../../styles/reactions.css";
219+
import "../../styles/user_circles.css";
220+
import "../../styles/left-sidebar.css";
221+
import "../../styles/right-sidebar.css";
222+
import "../../styles/lightbox.css";
223+
import "../../styles/popovers.css";
224+
import "../../styles/recent_topics.css";
225+
import "../../styles/typing_notifications.css";
226+
import "../../styles/hotspots.css";
227+
import "../../styles/night_mode.css";
228+
import "../../styles/user_status.css";
229+
import "../../styles/widgets.css";
230230

231231
// This should be last.
232232
import "../ready";

static/js/bundles/common.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,6 @@ import "simplebar/dist/simplebar.css";
1313
import "font-awesome/css/font-awesome.css";
1414
import "../../assets/icons/zulip-icons.font";
1515
import "source-sans-pro/source-sans-pro.css";
16-
import "../../styles/pygments.scss";
16+
import "../../styles/pygments.css";
1717
import "@uppy/core/dist/style.css";
1818
import "@uppy/progress-bar/dist/style.css";

static/js/bundles/portico.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@ import "./common";
22
import "../i18n";
33
import "../portico/header";
44
import "../portico/google-analytics";
5-
import "../../styles/portico/portico-styles.scss";
5+
import "../../styles/portico/portico-styles.css";

static/js/message_viewport.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -306,7 +306,7 @@ exports.is_narrow = function () {
306306
// This basically returns true when we hide the right sidebar for
307307
// the left_side_userlist skinny mode. It would be nice to have a less brittle
308308
// test for this. See the "@media (max-width: 1165px)" section in
309-
// media.scss.
309+
// media.css.
310310
return window.innerWidth <= 1165;
311311
};
312312

static/js/overlays.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ exports.recent_topics_open = function () {
4545
// To address bugs where mouse might apply to the streams/settings
4646
// overlays underneath an open modal within those settings UI, we add
4747
// this inline style to '.overlay.show', overriding the
48-
// "pointer-events: all" style in app_components.scss.
48+
// "pointer-events: all" style in app_components.css.
4949
//
5050
// This is kinda hacky; it only works for modals within overlays, and
5151
// we need to make sure it gets re-enabled when the modal closes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

static/styles/compose.scss renamed to static/styles/compose.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,7 @@
168168

169169
#compose-container {
170170
width: 100%;
171-
// This should match the value for .app-main
171+
/* This should match the value for .app-main */
172172
max-width: 1400px;
173173
margin: auto;
174174
}
File renamed without changes.
File renamed without changes.

static/styles/image_upload_widget.scss renamed to static/styles/image_upload_widget.css

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@
112112
}
113113
}
114114

115-
/* SCSS related to settings page user avatar upload widget only */
115+
/* CSS related to settings page user avatar upload widget only */
116116
#user-avatar-upload-widget {
117117
.image_upload_button {
118118
border-radius: 5px;
@@ -159,7 +159,7 @@
159159
}
160160
}
161161

162-
/* SCSS related to settings page realm icon upload widget only */
162+
/* CSS related to settings page realm icon upload widget only */
163163
#realm-icon-upload-widget {
164164
width: 100px;
165165
height: 100px;
@@ -190,7 +190,7 @@
190190
display: inline-block;
191191
}
192192

193-
/* SCSS related to settings page realm day/night logo upload widget only */
193+
/* CSS related to settings page realm day/night logo upload widget only */
194194
#realm-day-logo-upload-widget,
195195
#realm-night-logo-upload-widget {
196196
width: 220px;

static/styles/informational-overlays.scss renamed to static/styles/informational-overlays.css

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@
6363
display: table;
6464

6565
td.definition {
66-
// keeps dividing line at same width for all tables in model.
66+
/* keeps dividing line at same width for all tables in model. */
6767
width: calc(50% - 11px);
6868
text-align: right;
6969
}
@@ -104,7 +104,7 @@
104104
th {
105105
width: 245px;
106106
text-align: center;
107-
// aligns table name with dividing line
107+
/* aligns table name with dividing line */
108108
}
109109

110110
td:not(.definition) {
File renamed without changes.
File renamed without changes.
File renamed without changes.

static/styles/night_mode.scss renamed to static/styles/night_mode.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -492,7 +492,7 @@ on a dark background, and don't change the dark labels dark either. */
492492
}
493493

494494
#invite_user_form .modal-footer {
495-
// no transparency prevents overlap issues
495+
/* no transparency prevents overlap issues */
496496
background-color: hsl(211, 28%, 14%);
497497
}
498498

File renamed without changes.

static/styles/portico/markdown.scss renamed to static/styles/portico/markdown.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -297,7 +297,7 @@
297297
}
298298

299299
code {
300-
/* Copied from rendered_markdown.scss */
300+
/* Copied from rendered_markdown.css */
301301
font-size: 0.857em;
302302
unicode-bidi: embed;
303303
direction: ltr;

static/styles/portico/portico-signin.scss renamed to static/styles/portico/portico-signin.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -686,7 +686,7 @@ button.login-social-button {
686686

687687
button#login_auth_button_gitlab,
688688
button#register_auth_button_gitlab {
689-
// GitLab icon size looks a bit inconsistent with others. This fixes it.
689+
/* GitLab icon size looks a bit inconsistent with others. This fixes it. */
690690
background-size: auto 90%;
691691
background-position-x: 3px;
692692
}
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
@import "../components.css";
2+
@import "portico.css";
3+
@import "portico-signin.css";
4+
@import "markdown.css";

static/styles/portico/portico-styles.scss

Lines changed: 0 additions & 4 deletions
This file was deleted.

static/styles/portico/portico.scss renamed to static/styles/portico/portico.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -255,7 +255,7 @@ html {
255255
margin-left: -40px;
256256
padding-left: 40px;
257257

258-
// Don't show the focus outline for the highlighted page.
258+
/* Don't show the focus outline for the highlighted page. */
259259
outline: 0;
260260
}
261261
}
File renamed without changes.
File renamed without changes.
File renamed without changes.

static/styles/recent_topics.scss renamed to static/styles/recent_topics.css

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@
109109
}
110110

111111
.table_fix_head table {
112-
// To keep border properties to the thead th.
112+
/* To keep border properties to the thead th. */
113113
border-collapse: separate;
114114
}
115115

@@ -131,7 +131,7 @@
131131
}
132132

133133
.clear_search_button {
134-
// Overrides app_components.scss property.
134+
/* Overrides app_components.css property. */
135135
padding-top: 6px !important;
136136
}
137137

@@ -284,9 +284,9 @@
284284
}
285285

286286
@media (max-width: 750px) {
287-
// Hide participants and last message time
288-
// on smaller screens. This ensures user always
289-
// has a nice UI experience.
287+
/* Hide participants and last message time
288+
on smaller screens. This ensures user always
289+
has a nice UI experience. */
290290
.recent_topic_users,
291291
.recent_topic_timestamp,
292292
thead .participants_header,
File renamed without changes.

static/styles/settings.scss renamed to static/styles/settings.css

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -293,7 +293,7 @@ td .button {
293293
}
294294
}
295295

296-
// Force the actions column to use the minimum space necessary
296+
/* Force the actions column to use the minimum space necessary */
297297
.actions {
298298
width: 1%;
299299
white-space: nowrap;
@@ -1565,7 +1565,7 @@ body:not(.night-mode) #settings_page .custom_user_field .datepicker {
15651565
margin: 0 5px;
15661566

15671567
&.dropdown_list_reset_button {
1568-
// Prevent night mode from overriding background.
1568+
/* Prevent night mode from overriding background. */
15691569
background: unset !important;
15701570
border: none;
15711571

@@ -1583,7 +1583,7 @@ body:not(.night-mode) #settings_page .custom_user_field .datepicker {
15831583
}
15841584

15851585
.dropdown-menu {
1586-
top: -7px; // -(margin+padding), both are set by bootstrap.
1586+
top: -7px; /* -(margin+padding), both are set by bootstrap. */
15871587
bottom: auto;
15881588
}
15891589

@@ -1757,11 +1757,11 @@ body:not(.night-mode) #settings_page .custom_user_field .datepicker {
17571757
}
17581758
}
17591759

1760-
// This value needs to match with the same in subscriptions.scss, as
1761-
// we have some shared styles declared there
1760+
/* This value needs to match with the same in subscriptions.css, as
1761+
we have some shared styles declared there */
17621762
@media (max-width: 750px) {
17631763
#settings_overlay_container {
1764-
// this variable allows JavaScript to detect this media query
1764+
/* this variable allows JavaScript to detect this media query */
17651765
--single-column: yes;
17661766
}
17671767

@@ -1770,7 +1770,7 @@ body:not(.night-mode) #settings_page .custom_user_field .datepicker {
17701770
display: block;
17711771

17721772
&:not(.slide-left) .section {
1773-
// When viewing the settings list we hide the active section.
1773+
/* When viewing the settings list we hide the active section. */
17741774
display: none;
17751775
}
17761776
}
@@ -1796,7 +1796,7 @@ body:not(.night-mode) #settings_page .custom_user_field .datepicker {
17961796
height: 100%;
17971797

17981798
li.active {
1799-
// Don't highlight the active section in the settings list.
1799+
/* Don't highlight the active section in the settings list. */
18001800
background: inherit;
18011801
border-bottom: 1px solid hsl(0, 0%, 93%);
18021802
}
@@ -1856,8 +1856,8 @@ body:not(.night-mode) #settings_page .custom_user_field .datepicker {
18561856
}
18571857

18581858
@media (max-width: 430px) {
1859-
// selects the label (inline-block)
1860-
// immediately following the checkbox
1859+
/* selects the label (inline-block)
1860+
immediately following the checkbox */
18611861
.settings-box .checkbox + .inline-block {
18621862
width: calc(100% - 25px);
18631863
}

static/styles/subscriptions.scss renamed to static/styles/subscriptions.css

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1113,11 +1113,11 @@ ul.grey-box {
11131113
}
11141114
}
11151115

1116-
// Note that this block has settings_page CSS as well, and thus needs
1117-
// to match the media queries in settings.scss.
1118-
//
1119-
// Longer-term we should extract this logic two-column-overlay class
1120-
// to read more naturally.
1116+
/* Note that this block has settings_page CSS as well, and thus needs
1117+
to match the media queries in settings.css.
1118+
1119+
Longer-term we should extract this logic two-column-overlay class
1120+
to read more naturally. */
11211121
@media (max-width: 750px) {
11221122
.subscriptions-container {
11231123
position: relative;

static/styles/user_circles.scss renamed to static/styles/user_circles.css

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,9 +39,9 @@
3939
&::after {
4040
content: "";
4141
background: hsl(0, 0%, 50%);
42-
height: 1.5px; // 1px is too thin, 2px is too thick
42+
height: 1.5px; /* 1px is too thin, 2px is too thick */
4343
width: 6px;
4444
display: block;
45-
margin: 3.25px auto 0 auto; // (total height - line height) / 2 = 3.25px
45+
margin: 3.25px auto 0 auto; /* (total height - line height) / 2 = 3.25px */
4646
}
4747
}
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)