Switch notification switch to use et2-button-toggle in mobile templates

This commit is contained in:
nathan 2024-10-17 16:04:30 -06:00
parent 0d401c2e6d
commit 853d6ddd89
4 changed files with 30 additions and 3 deletions

View File

@ -194,8 +194,8 @@
<et2-button-icon statustext="delete this entry" id="button[delete]" onclick="et2_dialog.confirm(widget,'Delete this entry','Delete');" image="delete" span="all"></et2-button-icon>
<et2-button-icon statustext="Find free timeslots where the selected participants are available for the given timespan"
id="freetime" label="Freetime" onclick="app.calendar.freetime_search" image="clock-history" noSubmit="true"></et2-button-icon>
<et2-checkbox id="no_notifications" class="notification_check" toggleOn=" " toggleOff=" "></et2-checkbox>
<et2-textbox type="hidden" id="delete_exceptions"></et2-textbox>
<et2-button-toggle label="notifications" id="no_notifications" class="notification_check" onIcon="bell-fill" offIcon="bell-slash"/>
<et2-textbox type="hidden" id="delete_exceptions"></et2-textbox>
</et2-hbox>
</row>
<row disabled="!@showsearchbuttons" class="dialogHeadbar">

View File

@ -141,7 +141,7 @@
<et2-button-icon statustext="Apply the changes" id="button[apply]" image="apply"></et2-button-icon>
<et2-button-icon statustext="delete this entry" id="button[delete]" onclick="if($cont[info_anz_subs]) return $cont[info_anz_subs]; et2_dialog.confirm(widget,'Delete this entry','Delete');" image="delete" span="all"></et2-button-icon>
<et2-button-timestamp statustext="Insert timestamp into description field" id="timestamp" class="infologExtraButton infologTimestamp" image="timesheet" target="info_des"></et2-button-timestamp>
<et2-switch label="notifications" id="no_notifications" class="notification_check" toggleOn=" " toggleOff=" "/>
<et2-button-toggle label="notifications" id="no_notifications" class="notification_check" onIcon="bell-fill" offIcon="bell-slash"/>
<et2-number id="info_number" readonly="true" class="entry_id" precision="0"></et2-number>
</et2-hbox>
</row>

View File

@ -9085,6 +9085,18 @@ table.egwGridView_grid img.et2_appicon {
background: transparent;
border: transparent;
}
body .dialogHeadbar et2-button-toggle {
--indicator-color: var(--sl-color-neutral-0);
font-size: 2.3em;
}
body .dialogHeadbar et2-button-toggle::part(form-control-label) {
position: absolute;
top: -100%;
}
body .dialogHeadbar et2-button-toggle::part(control) {
border: none;
background: none;
}
body .dialogHeadbar button[class*="et2_button_with_image"]:not([class*="et2_toolbar_hasCaption"]) {
-webkit-filter: brightness(0) invert(1) !important;
filter: brightness(0) invert(1) !important;

View File

@ -1292,6 +1292,21 @@
border: transparent;
}
et2-button-toggle {
--indicator-color: var(--sl-color-neutral-0);
font-size: 2.3em;
&::part(form-control-label) {
position: absolute;
top: -100%;
}
&::part(control) {
border: none;
background: none;
}
}
button[class*="et2_button_with_image"]:not([class*="et2_toolbar_hasCaption"]) {
.white-svg;
padding-right: 15px;