Skip to content

Commit

Permalink
Merge pull request #1027 from geoadmin/fix-sass-warnings
Browse files Browse the repository at this point in the history
Fix SASS warning from code and revert to 1.77.6 waiting on bootstrap - #patch
  • Loading branch information
pakb authored Aug 22, 2024
2 parents 54a765c + 0eefc74 commit a9516df
Show file tree
Hide file tree
Showing 13 changed files with 39 additions and 40 deletions.
8 changes: 4 additions & 4 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@
"prettier": "^3.3.3",
"prettier-plugin-jsdoc": "^1.3.0",
"rimraf": "^5.0.10",
"sass": "^1.77.8",
"sass": "1.77.6",
"start-server-and-test": "^2.0.5",
"typescript": "^5.5.4",
"vite": "^5.3.5",
Expand Down
2 changes: 1 addition & 1 deletion src/modules/drawing/components/DrawingToolbox.vue
Original file line number Diff line number Diff line change
Expand Up @@ -248,10 +248,10 @@ $zindex-drawing-toolbox: -1;
transition: opacity $animation-time;
}
&-closed {
transform: translate(0px, calc(-100% + #{$openCloseButtonHeight}));
.drawing-toolbox-content {
opacity: 0;
}
transform: translate(0px, calc(-100% + #{$openCloseButtonHeight}));
}
&-disclaimer {
display: block;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -200,18 +200,17 @@ export default {
.marker-icon-select-box {
max-height: 10rem;
overflow-y: scroll;
display: grid;
grid-template-columns: 1fr 1fr 1fr 1fr 1fr 1fr;
transition: max-height 0.3s linear;
&.one-line {
max-height: 2rem;
overflow-y: hidden;
}
display: grid;
grid-template-columns: 1fr 1fr 1fr 1fr 1fr 1fr;
transition: max-height 0.3s linear;
.marker-icon-image {
width: 2rem;
height: 2rem;
}
button {
--bs-btn-padding-x: 0.25rem;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,8 @@ $square-button-radius: 8px;
$opened-width: calc($square-button-width / 2.5);
$cropper-opened-width: calc($opened-width - 2 * $bg-selector-button-border);
border-radius: $square-button-radius;
transition: width $bg-selector-transition-duration;
$inner-radius: calc($square-button-radius - $bg-selector-button-border);
&.opened {
width: $opened-width;
}
Expand All @@ -108,8 +110,6 @@ $square-button-radius: 8px;
width: $cropper-opened-width;
}
}
transition: width $bg-selector-transition-duration;
$inner-radius: calc($square-button-radius - $bg-selector-button-border);
&-image-cropper {
border-radius: $inner-radius;
transition: all $bg-selector-transition-duration;
Expand Down
4 changes: 2 additions & 2 deletions src/modules/menu/MenuModule.vue
Original file line number Diff line number Diff line change
Expand Up @@ -143,16 +143,16 @@ $openCloseButtonHeight: 2.5rem;
pointer-events: all;
}
&.desktop-mode {
max-width: $menu-tray-width;
.menu-tray-content {
transition: opacity $animation-time;
}
max-width: $menu-tray-width;
}
&.desktop-menu-closed {
transform: translate(0px, calc(-100% + #{$openCloseButtonHeight}));
.menu-tray-content {
opacity: 0;
}
transform: translate(0px, calc(-100% + #{$openCloseButtonHeight}));
}
.button-open-close-desktop-menu {
pointer-events: all;
Expand Down
4 changes: 2 additions & 2 deletions src/modules/menu/components/LayerCatalogueItem.vue
Original file line number Diff line number Diff line change
Expand Up @@ -337,11 +337,11 @@ function containsLayer(layers, searchText) {
&-title {
@extend .menu-title;
cursor: pointer;
border-bottom-width: 1px;
border-bottom-color: $gray-400;
&.active {
color: $primary;
}
border-bottom-width: 1px;
border-bottom-color: $gray-400;
&.group {
border-bottom-style: solid;
}
Expand Down
4 changes: 2 additions & 2 deletions src/scss/main.scss
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@
@import '@/scss/tippy-theme';

body {
// preventing a long press to select the entire window/app, and all element of the UI in the process
@extend .no-ios-long-press-select;
// disabling double tap = zoom the UI on iOS
touch-action: manipulation;
// preventing a long press to select the entire window/app, and all element of the UI in the process
@extend .no-ios-long-press-select;
}
input,
p,
Expand Down
11 changes: 5 additions & 6 deletions src/utils/components/ErrorWindow.vue
Original file line number Diff line number Diff line change
Expand Up @@ -73,23 +73,22 @@ const emit = defineEmits(['close'])
position: fixed;
top: $top-margin;
right: 4rem;
width: max-content;
max-width: 400px;
max-height: calc(100vh - $top-margin);
@include respond-below(phone) {
$top-margin: $header-height;
&.dev-disclaimer-present {
$top-margin: calc($header-height + $dev-disclaimer-height);
}
top: $top-margin;
left: 50%;
right: unset;
transform: translate(-50%, 0%);
max-height: calc(100vh - $top-margin);
max-width: 100vw;
&.dev-disclaimer-present {
$top-margin: calc($header-height + $dev-disclaimer-height);
}
}
.card-body {
// Allow text selection
Expand Down
11 changes: 6 additions & 5 deletions src/utils/components/ModalWithBackdrop.vue
Original file line number Diff line number Diff line change
Expand Up @@ -151,6 +151,12 @@ export default {
.card {
width: max-content;
max-width: 100vw;
// dvh takes into account the user interface in mobile browsers (with vh part of the modal is
// not visible if ui is shown). Is recognized by browsers from 2022 or newer. If the browser
// is older, 90vh will normally be used, which is a bit less clean but good enough.
max-height: 90vh;
max-height: 100dvh;
&:not(.modal-popup-fluid) {
// only setting a width if the modal content shouldn't be fluid
width: 80vw;
Expand All @@ -160,11 +166,6 @@ export default {
border-radius: unset;
}
}
// dvh takes into account the user interface in mobile browsers (with vh part of the modal is
// not visible if ui is shown). Is recognized by browsers from 2022 or newer. If the browser
// is older, 90vh will normally be used, which is a bit less clean but good enough.
max-height: 90vh;
max-height: 100dvh;
@include respond-above(phone) {
// But for desktop we let the size be dynamic with max to 90% of the view
max-width: 80vw;
Expand Down
10 changes: 5 additions & 5 deletions src/utils/components/SimpleWindow.vue
Original file line number Diff line number Diff line change
Expand Up @@ -70,23 +70,23 @@ const emit = defineEmits(['close'])
position: fixed;
top: $top-margin;
right: 4rem;
width: max-content;
max-width: 400px;
max-height: calc(100vh - $top-margin);
@include respond-below(phone) {
$top-margin: $header-height;
&.dev-disclaimer-present {
$top-margin: calc($header-height + $dev-disclaimer-height);
}
top: $top-margin;
left: 50%;
right: unset;
transform: translate(-50%, 0%);
max-height: calc(100vh - $top-margin);
max-width: 100vw;
&.dev-disclaimer-present {
top: calc($top-margin + $dev-disclaimer-height);
}
}
.card-body {
overflow-y: auto;
Expand Down
10 changes: 5 additions & 5 deletions src/utils/components/WarningWindow.vue
Original file line number Diff line number Diff line change
Expand Up @@ -70,23 +70,23 @@ const emit = defineEmits(['close'])
position: fixed;
top: $top-margin;
right: 4rem;
width: max-content;
max-width: 400px;
max-height: calc(100vh - $top-margin);
@include respond-below(phone) {
$top-margin: $header-height;
&.dev-disclaimer-present {
$top-margin: calc($header-height + $dev-disclaimer-height);
}
top: $top-margin;
left: 50%;
right: unset;
transform: translate(-50%, 0%);
max-height: calc(100vh - $top-margin);
max-width: 100vw;
&.dev-disclaimer-present {
$top-margin: calc($header-height + $dev-disclaimer-height);
}
}
.card-body {
// Allow text selection
Expand Down
2 changes: 1 addition & 1 deletion tests/cypress/tests-e2e/reportProblem.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ describe('Testing the report problem form', () => {
cy.log('It is not possible to report a problem without filling the message')
cy.openMenuIfMobile()
openForm()
cy.get('[data-cy="text-area-input"').should('be.empty')
cy.get('[data-cy="text-area-input"]').should('be.empty')
cy.get('[data-cy="email-input"]').type(validEmail)
cy.get('[data-cy="submit-button"]:visible').click()
cy.get('[data-cy="email-input"]').should('have.class', 'is-valid')
Expand Down

0 comments on commit a9516df

Please sign in to comment.