OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub
Ruby agile-developmentangularbcfboardsbug-trackerganttgantt-chartifcissue-trackerjira-alternativekanbanopenprojectproduct-managementproject-managementproject-planningroadmaprubyscrumtimelineworkflows
[#46325] Header cut off in Filepicker on mobile iOS 15.3 Safari
Andreas Pfohl64b44e65cf86
diff --git a/frontend/src/app/shared/components/modal/modal.component.ts b/frontend/src/app/shared/components/modal/modal.component.tsindex d706b3a2c02..3ce186a3788 100644--- a/frontend/src/app/shared/components/modal/modal.component.ts+++ b/frontend/src/app/shared/components/modal/modal.component.ts@@ -27,18 +27,13 @@//++import {- ChangeDetectorRef,- Directive,- ElementRef,- EventEmitter,- Inject,- OnDestroy,- OnInit,+ ChangeDetectorRef, Directive, ElementRef, EventEmitter, Inject, OnDestroy, OnInit,} from '@angular/core';import { OpModalLocalsMap } from 'core-app/shared/components/modal/modal.types';import { UntilDestroyedMixin } from 'core-app/shared/helpers/angular/until-destroyed.mixin';import { OpModalLocalsToken, OpModalService } from 'core-app/shared/components/modal/modal.service';+import { debounce } from 'lodash';@Directive()export abstract class OpModalComponent extends UntilDestroyedMixin implements OnInit, OnDestroy {@@ -70,6 +65,8 @@ export abstract class OpModalComponent extends UntilDestroyedMixin implements OnngOnDestroy():void {this.closingEvent.complete();this.openingEvent.complete();+ window.removeEventListener('resize', this.onResize);+ window.removeEventListener('orientationchange', this.onResize);}/**@@ -93,10 +90,22 @@ export abstract class OpModalComponent extends UntilDestroyedMixin implements Onpublic onOpen():void {this.openingEvent.emit();+ this.updateAppHeight();this.cdRef.detectChanges();++ window.addEventListener('resize', this.onResize);+ window.addEventListener('orientationchange', this.onResize);}protected get afterFocusOn():HTMLElement {return this.$element;}++ private onResize = debounce(() => this.updateAppHeight(), 10);++ private updateAppHeight = () =>+ document+ .documentElement+ .style+ .setProperty('--app-height', `${window.innerHeight}px`);}diff --git a/frontend/src/app/spot/styles/sass/components/modal-overrides.sass b/frontend/src/app/spot/styles/sass/components/modal-overrides.sassindex 7bcb16016d1..8c995148c3e 100644--- a/frontend/src/app/spot/styles/sass/components/modal-overrides.sass+++ b/frontend/src/app/spot/styles/sass/components/modal-overrides.sass@@ -4,7 +4,7 @@.spot-modal > .form:only-childdisplay: flexflex-direction: column- max-height: 100vh+ max-height: var(--app-height).modal-delivery-elementdisplay: nonediff --git a/frontend/src/app/spot/styles/sass/components/modal.sass b/frontend/src/app/spot/styles/sass/components/modal.sassindex c8b449c129d..2dd200457ea 100644--- a/frontend/src/app/spot/styles/sass/components/modal.sass+++ b/frontend/src/app/spot/styles/sass/components/modal.sass@@ -15,15 +15,15 @@width: 40remmax-width: calc(100vw - 2rem)- max-height: calc(100vh - 2rem)+ max-height: calc(#{var(--app-height)} - 2rem)@media #{$spot-mq-mobile}width: calc(100vw - 2rem)- max-height: calc(100vh - 5rem)+ max-height: calc(#{var(--app-height)} - 5rem)overflow-y: auto@media (max-height: 480px)- max-height: calc(100vh - 2rem)+ max-height: calc(#{var(--app-height)} - 2rem)max-width: calc(100vw - 6rem)&_widediff --git a/frontend/src/global_styles/content/work_packages/shared/_file_picker.sass b/frontend/src/global_styles/content/work_packages/shared/_file_picker.sassindex 559103ee5a3..29cccf4851e 100644--- a/frontend/src/global_styles/content/work_packages/shared/_file_picker.sass+++ b/frontend/src/global_styles/content/work_packages/shared/_file_picker.sass@@ -35,11 +35,11 @@@media #{$spot-mq-mobile}&.spot-modal- min-height: calc(100vh - 5rem)+ min-height: calc(#{var(--app-height)} - 5rem)&--modal-body@media #{$spot-mq-desktop}- height: 50vh+ height: calc(#{var(--app-height)} / 2)max-height: 32rem&--emptydiff --git a/frontend/src/global_styles/vendor/foundation-apps/scss/components/_modal.scss b/frontend/src/global_styles/vendor/foundation-apps/scss/components/_modal.scssindex 5336f29e54c..d8c5bc2a604 100644--- a/frontend/src/global_styles/vendor/foundation-apps/scss/components/_modal.scss+++ b/frontend/src/global_styles/vendor/foundation-apps/scss/components/_modal.scss@@ -1,126 +1,126 @@-/*- MODAL- ------- The humble modal hides off-canvas until summoned with an fa-open directive. Modals appear over an overlay that darkens the rest of the page, and have a maximum width. You can construct a grid inside a modal, or attach panels to it.-- Note that the modal overlay is hardcoded into the CSS, because whether or not you build your modal semantically, the overlay is always required and will always look the same.-*/--/// @Foundation.settings-// Modal-$modal-background: #fff !default;-$modal-border: 0 !default;-$modal-radius: 0px !default;-$modal-shadow: none !default;-$modal-zindex: 1000 !default;-$modal-sizes: (- tiny: 300px,- small: 500px,- medium: 600px,- large: 800px,-) !default;--$modal-overlay-class: 'modal-overlay' !default;-$modal-overlay-background: rgba(#333, 0.7) !default;-///--%modal {- position: relative;- z-index: $modal-zindex + 1;- background: $modal-background;- flex: 0 0 auto;- width: 100%;- height: 100vh;- max-height: 100%;- overflow: hidden;- padding: $global-padding;-- @include breakpoint(medium) {- height: auto;- max-width: map-get($modal-sizes, medium);- }-- .grid-content, .grid-block {- margin: 0;- }-- .close-button, [fa-close] {- z-index: $modal-zindex + 1;- }-}--@mixin modal-dialog() {- height: auto;-}-@mixin modal-layout(- $width: map-get($modal-sizes, medium),- $dialog: false-) {- max-width: $width;-}-@mixin modal-style(- $border: $modal-border,- $radius: $modal-radius,- $shadow: $modal-shadow-) {- @if $border != 0 {- border: $border;- }- @if $radius != 0px {- border-radius: $radius;- }- @if $shadow != none {- box-shadow: $shadow;- }-}--@mixin modal(- $width: map-get($modal-sizes, medium),- $border: $modal-border,- $radius: $modal-radius,- $shadow: $modal-shadow-) {- @extend %modal;- @include modal-layout($width);- @include modal-style($border, $radius, $shadow);-}--@include exports(modal) {- .modal {- @include modal;-- @each $size in map-keys($modal-sizes) {- $width: map-get($modal-sizes, $size);- @if $size != medium {- .#{$size} > & { @include modal-layout($width); }- }- }-- .dialog > & {- @include modal-dialog;- }- .collapse > & {- padding: 0;- }- }-- .#{$modal-overlay-class} {- position: fixed;- top: 0;- right: 0;- bottom: 0;- left: 0;- z-index: $modal-zindex;- display: none;- background-color: $modal-overlay-background;-- // Horizontally and vertically center the modal- align-items: center;- justify-content: center;-- &.is-active {- display: flex;- }- }-}+/*+ MODAL+ -----++ The humble modal hides off-canvas until summoned with an fa-open directive. Modals appear over an overlay that darkens the rest of the page, and have a maximum width. You can construct a grid inside a modal, or attach panels to it.++ Note that the modal overlay is hardcoded into the CSS, because whether or not you build your modal semantically, the overlay is always required and will always look the same.+*/++/// @Foundation.settings+// Modal+$modal-background: #fff !default;+$modal-border: 0 !default;+$modal-radius: 0px !default;+$modal-shadow: none !default;+$modal-zindex: 1000 !default;+$modal-sizes: (+ tiny: 300px,+ small: 500px,+ medium: 600px,+ large: 800px,+) !default;++$modal-overlay-class: 'modal-overlay' !default;+$modal-overlay-background: rgba(#333, 0.7) !default;+///++%modal {+ position: relative;+ z-index: $modal-zindex + 1;+ background: $modal-background;+ flex: 0 0 auto;+ width: 100%;+ height: var(--app-height);+ max-height: 100%;+ overflow: hidden;+ padding: $global-padding;++ @include breakpoint(medium) {+ height: auto;+ max-width: map-get($modal-sizes, medium);+ }++ .grid-content, .grid-block {+ margin: 0;+ }++ .close-button, [fa-close] {+ z-index: $modal-zindex + 1;+ }+}++@mixin modal-dialog() {+ height: auto;+}+@mixin modal-layout(+ $width: map-get($modal-sizes, medium),+ $dialog: false+) {+ max-width: $width;+}+@mixin modal-style(+ $border: $modal-border,+ $radius: $modal-radius,+ $shadow: $modal-shadow+) {+ @if $border != 0 {+ border: $border;+ }+ @if $radius != 0px {+ border-radius: $radius;+ }+ @if $shadow != none {+ box-shadow: $shadow;+ }+}++@mixin modal(+ $width: map-get($modal-sizes, medium),+ $border: $modal-border,+ $radius: $modal-radius,+ $shadow: $modal-shadow+) {+ @extend %modal;+ @include modal-layout($width);+ @include modal-style($border, $radius, $shadow);+}++@include exports(modal) {+ .modal {+ @include modal;++ @each $size in map-keys($modal-sizes) {+ $width: map-get($modal-sizes, $size);+ @if $size != medium {+ .#{$size} > & { @include modal-layout($width); }+ }+ }++ .dialog > & {+ @include modal-dialog;+ }+ .collapse > & {+ padding: 0;+ }+ }++ .#{$modal-overlay-class} {+ position: fixed;+ top: 0;+ right: 0;+ bottom: 0;+ left: 0;+ z-index: $modal-zindex;+ display: none;+ background-color: $modal-overlay-background;++ // Horizontally and vertically center the modal+ align-items: center;+ justify-content: center;++ &.is-active {+ display: flex;+ }+ }+}