Skip to content

Commit ab11001

Browse files
authored
fix(ui5-popup): adjust default header height (#3506)
1 parent 9646c3e commit ab11001

File tree

4 files changed

+17
-4
lines changed

4 files changed

+17
-4
lines changed

packages/main/src/themes/PopupsCommon.css

+3-3
Original file line numberDiff line numberDiff line change
@@ -68,9 +68,9 @@
6868
:host([header-text]) .ui5-popup-header-text {
6969
padding: 0 0.25rem;
7070
text-align: center;
71-
min-height: 3rem;
72-
max-height: 3rem;
73-
line-height: 3rem;
71+
min-height: var(--_ui5_popup_default_header_height);
72+
max-height: var(--_ui5_popup_default_header_height);
73+
line-height: var(--_ui5_popup_default_header_height);
7474
text-overflow: ellipsis;
7575
overflow: hidden;
7676
white-space: nowrap;

packages/main/src/themes/base/sizes-parameters.css

+7
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,10 @@
3939
--_ui5_list_item_selection_btn_margin_top: calc(-1 * var(--_ui5_checkbox_wrapper_padding));
4040
--_ui5_list_busy_row_height: 3rem;
4141
--_ui5_month_picker_item_height: 3rem;
42+
43+
/* Popup subclasses */
44+
--_ui5_popup_default_header_height: 2.75rem;
45+
4246
--_ui5_year_picker_item_height: 3rem;
4347
--_ui5_tokenizer_root_padding: 0.1875rem;
4448
--_ui5_token_height: 1.625rem;
@@ -158,6 +162,9 @@
158162
--_ui5_input_icon_padding: .25rem .5rem;
159163
--_ui5_input_value_state_icon_padding: .1875rem .5rem;
160164

165+
/* Popup subclasses */
166+
--_ui5_popup_default_header_height: 2.5rem;
167+
161168
/* TextArea */
162169
--_ui5_textarea_padding: .1875rem .5rem;
163170

packages/main/test/pages/Dialog.html

+6
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,8 @@
2525
</head>
2626

2727
<body>
28+
<ui5-checkbox text="Compact size" id="cbCompact"></ui5-checkbox>
29+
<br>
2830
<ui5-button id="btnOpenDialog">Open Streched Dialog</ui5-button>
2931
<br>
3032
<br>
@@ -368,6 +370,10 @@
368370
<ui5-dialog id="empty-dialog">Empty</ui5-dialog>
369371

370372
<script>
373+
cbCompact.addEventListener("change", function () {
374+
document.body.classList.toggle("ui5-content-density-compact", cbCompact.checked);
375+
});
376+
371377
let preventClosing = true;
372378

373379
btnOpenDialog.addEventListener("click", function () {

packages/theme-base/hash.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
uvoNQhv6oafzulJZx8BIAfGhmME=
1+
ldK1ja/5Q2Vh5wwiveJGYLCZDSA=

0 commit comments

Comments
 (0)