1
0
forked from mirror/misskey

fix(client): Consider safe-area-inset-bottom on global widgets area

Fix #9052
This commit is contained in:
tamaina 2023-04-10 17:11:44 +00:00
parent 567c66567e
commit 83bcdb8ede
3 changed files with 9 additions and 4 deletions

View File

@ -250,6 +250,7 @@ onMounted(() => {
> .widgets {
//--panelBorder: none;
width: 300px;
padding-bottom: calc(var(--margin) + env(safe-area-inset-bottom, 0px));
@media (max-width: $widgets-hide-threshold) {
display: none;
@ -304,7 +305,7 @@ onMounted(() => {
right: 0;
z-index: 1001;
height: 100dvh;
padding: var(--margin);
padding: var(--margin) var(--margin) calc(var(--margin) + env(safe-area-inset-bottom, 0px));
box-sizing: border-box;
overflow: auto;
background: var(--bg);

View File

@ -296,7 +296,7 @@ $widgets-hide-threshold: 1090px;
}
.widgets {
padding: 0 var(--margin);
padding: 0 var(--margin) calc(var(--margin) + env(safe-area-inset-bottom, 0px));
border-left: solid 0.5px var(--divider);
background: var(--bg);
@ -329,7 +329,7 @@ $widgets-hide-threshold: 1090px;
right: 0;
z-index: 1001;
height: 100dvh;
padding: var(--margin) !important;
padding: var(--margin) var(--margin) calc(var(--margin) + env(safe-area-inset-bottom, 0px)) !important;
box-sizing: border-box;
overflow: auto;
overscroll-behavior: contain;

View File

@ -3,7 +3,7 @@
<XWidgets :class="$style.widgets" :edit="editMode" :widgets="widgets" @add-widget="addWidget" @remove-widget="removeWidget" @update-widget="updateWidget" @update-widgets="updateWidgets" @exit="editMode = false"/>
<button v-if="editMode" class="_textButton" style="font-size: 0.9em;" @click="editMode = false"><i class="ti ti-check"></i> {{ i18n.ts.editWidgetsExit }}</button>
<button v-else class="_textButton mk-widget-edit" style="font-size: 0.9em;" @click="editMode = true"><i class="ti ti-pencil"></i> {{ i18n.ts.editWidgets }}</button>
<button v-else class="_textButton mk-widget-edit" :class="$style.edit" style="font-size: 0.9em;" @click="editMode = true"><i class="ti ti-pencil"></i> {{ i18n.ts.editWidgets }}</button>
</div>
</template>
@ -91,4 +91,8 @@ function updateWidgets(thisWidgets) {
.widgets {
width: 300px;
}
.edit {
width: 100%;
}
</style>