@@ -244,91 +244,93 @@ panelview {
244
244
245
245
/* Tweaks for menupopups hanging off toolbar buttons to make them feel like panels */
246
246
247
- .toolbar-menupopup {
248
- & ,
249
- menupopup {
250
- appearance : none;
251
- border : none;
252
- font : menu;
253
- background-color : transparent;
254
- --panel-background : var (--arrowpanel-background );
255
- --panel-color : var (--arrowpanel-color );
256
- --panel-border-color : var (--arrowpanel-border-color );
257
- --panel-border-radius : var (--arrowpanel-border-radius );
258
- --panel-padding : var (--panel-subview-body-padding );
259
- }
260
-
261
- menupopup {
262
- /* Align non top-level menupopup's first menuitem with the menuitem that opened it.
263
- * The 1px is for the menupopup's border. */
264
- margin-top : calc (-1 * (var (--panel-subview-body-padding-block ) + var (--panel-shadow-margin ) + 1px ));
265
- }
266
-
267
- : is (menu , menuitem ) {
268
- & [disabled ] {
269
- color : var (--panel-disabled-color );
247
+ @media (-moz-bool-pref : "widget.non-native-theme.enabled" ) {
248
+ .toolbar-menupopup {
249
+ & ,
250
+ menupopup {
251
+ appearance : none;
252
+ border : none;
253
+ font : menu;
254
+ background-color : transparent;
255
+ --panel-background : var (--arrowpanel-background );
256
+ --panel-color : var (--arrowpanel-color );
257
+ --panel-border-color : var (--arrowpanel-border-color );
258
+ --panel-border-radius : var (--arrowpanel-border-radius );
259
+ --panel-padding : var (--panel-subview-body-padding );
270
260
}
271
-
272
- & : not ([disabled ])[_moz-menuactive ] {
273
- color : inherit;
274
- background-color : var (--panel-item-hover-bgcolor );
275
-
276
- & : active {
261
+
262
+ menupopup {
263
+ /* Align non top-level menupopup's first menuitem with the menuitem that opened it.
264
+ * The 1px is for the menupopup's border. */
265
+ margin-top : calc (-1 * (var (--panel-subview-body-padding-block ) + var (--panel-shadow-margin ) + 1px ));
266
+ }
267
+
268
+ : is (menu , menuitem ) {
269
+ & [disabled ] {
270
+ color : var (--panel-disabled-color );
271
+ }
272
+
273
+ & : not ([disabled ])[_moz-menuactive ] {
277
274
color : inherit;
278
- background-color : var (--panel-item-active-bgcolor );
275
+ background-color : var (--panel-item-hover-bgcolor );
276
+
277
+ & : active {
278
+ color : inherit;
279
+ background-color : var (--panel-item-active-bgcolor );
280
+ }
281
+ }
282
+
283
+ & ::before ,
284
+ & ::after {
285
+ content : none; /* Reset's macOS' checkmark spacing */
279
286
}
280
287
}
281
-
282
- & ::before ,
283
- & ::after {
284
- content : none; /* Reset's macOS' checkmark spacing */
288
+
289
+ .menu-text ,
290
+ .menu-iconic-text ,
291
+ .menu-iconic-icon ,
292
+ .menu-iconic-left ,
293
+ .menu-iconic-accel ,
294
+ .menu-accel-container ,
295
+ .menu-accel ,
296
+ .menu-right {
297
+ /* Reset every spacing and appearance set by the platforms' menu.css
298
+ * and set the ones we need in the following rules. */
299
+ margin : 0 ;
300
+ padding : 0 ;
301
+ appearance : none;
285
302
}
286
- }
287
-
288
- .menu-text ,
289
- .menu-iconic-text ,
290
- .menu-iconic-icon ,
291
- .menu-iconic-left ,
292
- .menu-iconic-accel ,
293
- .menu-accel-container ,
294
- .menu-accel ,
295
- .menu-right {
296
- /* Reset every spacing and appearance set by the platforms' menu.css
297
- * and set the ones we need in the following rules. */
298
- margin : 0 ;
299
- padding : 0 ;
300
- appearance : none;
301
- }
302
-
303
- : is (.menu-iconic , .menuitem-iconic ) > .menu-iconic-left {
304
- margin-inline-end : 8px ;
305
- }
306
-
307
- : is (.menu-accel , .menu-iconic-accel ) {
308
- margin-inline-start : 16px ;
309
-
310
- @media not (prefers-contrast) {
311
- menuitem : not ([disabled ]) > .menu-accel-container > & {
312
- color : var (--panel-disabled-color );
303
+
304
+ : is (.menu-iconic , .menuitem-iconic ) > .menu-iconic-left {
305
+ margin-inline-end : 8px ;
306
+ }
307
+
308
+ : is (.menu-accel , .menu-iconic-accel ) {
309
+ margin-inline-start : 16px ;
310
+
311
+ @media not (prefers-contrast) {
312
+ menuitem : not ([disabled ]) > .menu-accel-container > & {
313
+ color : var (--panel-disabled-color );
314
+ }
313
315
}
314
316
}
315
- }
316
-
317
- menu > .menu-right {
318
- list-style-image : url (chrome://global/skin/icons/arrow-right.svg);
319
- -moz-context-properties : fill, fill-opacity;
320
- fill : currentColor;
321
- fill-opacity : 0.6 ;
322
- width : unset;
323
- height : unset;
324
-
325
- & : -moz-locale-dir (rtl ) {
326
- list-style-image : url (chrome://global/skin/icons/arrow-left.svg);
317
+
318
+ menu > .menu-right {
319
+ list-style-image : url (chrome://global/skin/icons/arrow-right.svg);
320
+ -moz-context-properties : fill, fill-opacity;
321
+ fill : currentColor;
322
+ fill-opacity : 0.6 ;
323
+ width : unset;
324
+ height : unset;
325
+
326
+ & : -moz-locale-dir (rtl ) {
327
+ list-style-image : url (chrome://global/skin/icons/arrow-left.svg);
328
+ }
329
+ }
330
+
331
+ menuseparator {
332
+ padding : var (--panel-separator-margin );
327
333
}
328
- }
329
-
330
- menuseparator {
331
- padding : var (--panel-separator-margin );
332
334
}
333
335
}
334
336
@@ -1008,7 +1010,6 @@ panelmultiview[mainViewId="PanelUI-fxa"] #PanelUI-remotetabs-syncnow {
1008
1010
display : none;
1009
1011
}
1010
1012
1011
- .toolbar-menupopup : is (menu , menuitem ),
1012
1013
.subview-subheader ,
1013
1014
panelview .toolbarbutton-1 ,
1014
1015
.subviewbutton ,
@@ -1022,6 +1023,18 @@ panelview .toolbarbutton-1,
1022
1023
flex-shrink : 0 ;
1023
1024
}
1024
1025
1026
+ @media (-moz-bool-pref : "widget.non-native-theme.enabled" ) {
1027
+ .toolbar-menupopup : is (menu , menuitem ) {
1028
+ appearance : none;
1029
+ margin : var (--arrowpanel-menuitem-margin );
1030
+ min-height : 24px ;
1031
+ padding : var (--arrowpanel-menuitem-padding );
1032
+ border-radius : var (--arrowpanel-menuitem-border-radius );
1033
+ background-color : transparent;
1034
+ flex-shrink : 0 ;
1035
+ }
1036
+ }
1037
+
1025
1038
.subview-subheader {
1026
1039
font-size : 11px ;
1027
1040
font-weight : inherit;
0 commit comments