Skip to content

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

[#43842] fix qa issues

Eric Schubert812a01af8749
diff --git a/frontend/src/app/shared/components/modals/confirm-dialog/confirm-dialog.modal.html b/frontend/src/app/shared/components/modals/confirm-dialog/confirm-dialog.modal.html
index e1b4144755b..7cb583db08b 100644
--- a/frontend/src/app/shared/components/modals/confirm-dialog/confirm-dialog.modal.html
+++ b/frontend/src/app/shared/components/modals/confirm-dialog/confirm-dialog.modal.html
@@ -31,17 +31,8 @@
data-qa-selector="confirmation-modal--cancel"
(click)="closeMe($event)"
>
- <op-icon
- *ngIf="icon.cancel as clazz"
- icon-classes="button--icon spot-icon spot-icon_{{clazz}}"
- class="op-icon--wrapper">
- <i
- class="button--icon spot-icon spot-icon_{{clazz}}"
- ></i>
- </op-icon>
- <span
- class="button--text"
- >{{text.button_cancel}}</span>
+ <span *ngIf="icon.cancel as clazz" class="spot-icon spot-icon_{{clazz}}"></span>
+ <span>{{text.button_cancel}}</span>
</button>
<button
type="button"
@@ -50,17 +41,8 @@
[ngClass]="dangerHighlighting ? '-danger': '-highlight'"
(click)="confirmAndClose($event)"
>
- <op-icon
- *ngIf="icon.continue as clazz"
- icon-classes="button--icon spot-icon spot-icon_{{clazz}}"
- class="op-icon--wrapper">
- <i
- class="button--icon spot-icon spot-icon_{{clazz}}"
- ></i>
- </op-icon>
- <span
- class="button--text"
- >{{text.button_continue}}</span>
+ <span *ngIf="icon.continue as clazz" class="spot-icon spot-icon_{{clazz}}"></span>
+ <span>{{text.button_continue}}</span>
</button>
</div>
</div>
diff --git a/frontend/src/app/shared/components/modals/wp-destroy-modal/wp-destroy.modal.html b/frontend/src/app/shared/components/modals/wp-destroy-modal/wp-destroy.modal.html
index 31c1d22c562..2e2d256b018 100644
--- a/frontend/src/app/shared/components/modals/wp-destroy-modal/wp-destroy.modal.html
+++ b/frontend/src/app/shared/components/modals/wp-destroy-modal/wp-destroy.modal.html
@@ -8,13 +8,9 @@
<div class="spot-modal--body spot-container">
<ng-container *ngIf="singleWorkPackage">
<p>
- <span [textContent]="text.single_text"></span>
- <strong>
-
- {{ singleWorkPackage.subject }}
- #{{ singleWorkPackage.id }}
- </strong>
- ?
+ <span [textContent]="text.single_text"></span>
+ <strong> {{ singleWorkPackage.subject }} #{{ singleWorkPackage.id }}</strong>
+ <span>?</span>
</p>
<div *ngIf="singleWorkPackageChildren && singleWorkPackageChildren.length > 0">
<p class="danger-zone--warning">
diff --git a/frontend/src/app/spot/styles/sass/components/action-bar.sass b/frontend/src/app/spot/styles/sass/components/action-bar.sass
index 0509235d51b..68913adf01a 100644
--- a/frontend/src/app/spot/styles/sass/components/action-bar.sass
+++ b/frontend/src/app/spot/styles/sass/components/action-bar.sass
@@ -1,7 +1,7 @@
.spot-action-bar
display: grid
grid-template-columns: 1fr
- padding: $spot-spacing-1
+ padding: $spot-spacing-0_75 $spot-spacing-1
background-color: $spot-color-basic-gray-6
&--left,
diff --git a/frontend/src/global_styles/content/_buttons.sass b/frontend/src/global_styles/content/_buttons.sass
index e1b67a16b35..9911ce37a6b 100644
--- a/frontend/src/global_styles/content/_buttons.sass
+++ b/frontend/src/global_styles/content/_buttons.sass
@@ -53,6 +53,7 @@ a.button
background: var(--content-form-danger-zone-bg-color)
color: var(--content-form-danger-zone-font-color)
border-color: var(--content-form-danger-zone-bg-color)
+
&.icon:before,
&.icon-context:before
color: var(--content-form-danger-zone-font-color)
@@ -107,6 +108,7 @@ a.button
&.-small
@include button-size(small)
+
&.-with-icon:before
vertical-align: initial
@@ -127,6 +129,21 @@ a.button
&_no-margin
margin: 0
+ .spot-icon
+ // Add rules for using new spot icons boxed within the old buttons
+ font-size: 0.875rem
+ width: 1.5rem
+ height: 1.5rem
+ // prevent icon box to inflate button height
+ margin-top: -1rem
+ margin-bottom: -1rem
+
+ &:not(:last-child)
+ margin-right: 0.25rem
+
+ &:not(:first-child)
+ margin-left: 0.25rem
+
.button--icon
@include icon-common
diff --git a/frontend/src/global_styles/openproject/_settings.scss b/frontend/src/global_styles/openproject/_settings.scss
index 43bd9b96df9..b17bad36253 100644
--- a/frontend/src/global_styles/openproject/_settings.scss
+++ b/frontend/src/global_styles/openproject/_settings.scss
@@ -242,7 +242,7 @@ $breakpoint-classes: (tiny small medium large xlarge xxlarge xxxlarge);
// 6. Button
// - - - - - - - - - - - - - - -
-$button-padding: 0.65em;
+$button-padding: 0.375rem 0.5rem;
// $button-margin: 0 $global-padding $global-padding 0;
// $button-style: solid;
// $button-background: $primary-color;
@@ -612,4 +612,4 @@ $label-color: var(--gray-dark);
// left: 'left',
// right: 'right',
// title: 'title',
-// );
\ No newline at end of file
+// );
diff --git a/frontend/src/global_styles/vendor/foundation-apps/scss/components/_button.scss b/frontend/src/global_styles/vendor/foundation-apps/scss/components/_button.scss
index 147b4e68f95..dec5dbc761c 100644
--- a/frontend/src/global_styles/vendor/foundation-apps/scss/components/_button.scss
+++ b/frontend/src/global_styles/vendor/foundation-apps/scss/components/_button.scss
@@ -1,205 +1,205 @@
-/// @Foundation.settings
-// Button
-$button-padding: 0.85em 1em !default;
-$button-margin: 0 $global-padding $global-padding 0 !default;
-$button-style: solid !default;
-$button-background: $primary-color !default;
-$button-background-hover: scale-color($button-background, $lightness: -15%) !default;
-$button-color: auto !default;
-$button-radius: 0 !default;
-$button-sizes: (
- tiny: 0.7,
- small: 0.8,
- medium: 1,
- large: 1.3,
-) !default;
-$button-font-size: 0.9rem !default;
-$button-opacity-disabled: 0.5 !default;
-$button-tag-selector: false !default;
-///
-
-%button {
- display: inline-block;
- border: 0;
- text-align: center;
- line-height: 1;
- cursor: pointer;
- -webkit-appearance: none;
- -webkit-font-smoothing: antialiased;
- transition: background 0.25s ease-out;
- vertical-align: middle;
-
- padding: $button-padding;
- margin: $button-margin;
- font-size: $button-font-size;
- border-radius: $button-radius;
-
- // Dropdown arrow
- // TODO: Change to class and mixin because now the toggle is 'fa-open' which is too generic
- // &[data-popup-toggle] {
- // position: relative;
- // padding-right: 2em; // Placeholder
-
- // &::after {
- // @include css-triangle(6px, black, top);
- // position: absolute;
- // right: 0.7em;
- // top: 50%;
- // margin-top: -3px;
- // }
- // }
-}
-
-@mixin button-size($size: medium, $expand: false) {
- $size: $button-font-size * map-get($button-sizes, $size);
- font-size: $size;
-
- @if $expand {
- @include button-expand;
- }
-
- @if using(iconic) {
- .iconic {
- width: 1em;
- height: 1em;
- vertical-align: middle;
- margin-right: 0.25em;
- margin-top: -2px; // The icons are oddly misaligned
- }
- }
-}
-
-@mixin button-expand($expand: true) {
- @if $expand {
- display: block;
- width: 100%;
- margin-left: 0;
- margin-right: 0;
- }
- @else {
- display: inline-block;
- width: auto;
- margin: $button-margin;
- }
-}
-
-@mixin button-style(
- $background: $button-background,
- $background-hover: $button-background-hover,
- $color: $button-color,
- $style: $button-style,
- $radius: $button-radius,
- $btngroup: false
-){
- @if $style == hollow {
- border: 1px solid $background;
- background: transparent;
- color: $background;
-
- &:hover, &:focus {
- border-color: scale-color($background, $lightness: 25%);
- background: transparent;
- color: scale-color($background, $lightness: 25%);
- }
- }
- // Solid is the default
- @else {
- @if $color == auto {
- $color: isitlight($background);
- }
-
- background: $background;
- color: $color;
-
- &:hover, &:focus {
- @if $background-hover == auto {
- background: scale-color($background, $lightness: -15%);
- }
- @else {
- background: $background-hover;
- }
- color: $color;
- }
- }
-
- @if $btngroup {
- border-color: $background;
- &:hover, &:focus {
- border-color: scale-color($background, $lightness: -25%);
- }
- }
-
- @if using(iconic) {
- @if $style == hollow {
- .iconic {
- @include color-icon($background);
- }
- &:hover .iconic {
- @include color-icon(scale-color($background, $lightness: 25%));
- }
- }
- @else {
- .iconic {
- @include color-icon($color);
- }
- }
- }
-}
-
-@mixin button-disabled() {
- opacity: $button-opacity-disabled;
- cursor: default;
- pointer-events: none;
-}
-
-@mixin button(
- $size: medium,
- $expand: false,
- $background: $button-background,
- $background-hover: $button-background-hover,
- $color: $button-color,
- $style: $button-style,
- $radius: $button-radius
-) {
- @extend %button;
- @include button-size($size);
- @include button-expand($expand);
- @include button-style($background, $background-hover, $color, $style);
-}
-
-@include exports(button) {
- .button {
- @include button;
-
- &.tiny { @include button-size(tiny); }
- &.small { @include button-size(small); }
- &.large { @include button-size(large); }
- &.expand { @include button-expand; }
-
- &.secondary { @include button-style($secondary-color, auto) }
- &.success { @include button-style($success-color, auto) }
- &.warning { @include button-style($warning-color, auto) }
- &.alert { @include button-style($alert-color, auto) }
- &.info { @include button-style($info-color, auto) }
- &.dark { @include button-style($dark-color, auto) }
-
- @if $button-style != hollow {
- &.hollow { @include button-style($style: hollow);
- &.secondary { @include button-style($secondary-color, $style: hollow); }
- &.success { @include button-style($success-color, $style: hollow); }
- &.warning { @include button-style($warning-color, $style: hollow); }
- &.alert { @include button-style($alert-color, $style: hollow); }
- &.info { @include button-style($info-color, $style: hollow); }
- &.dark { @include button-style($dark-color, $style: hollow); }
- }
- }
-
- &.disabled { @include button-disabled; }
- }
-
- @if $button-tag-selector {
- button {
- @extend .button;
- }
- }
-}
+/// @Foundation.settings
+// Button
+$button-padding: 0.85em 1em !default;
+$button-margin: 0 $global-padding $global-padding 0 !default;
+$button-style: solid !default;
+$button-background: $primary-color !default;
+$button-background-hover: scale-color($button-background, $lightness: -15%) !default;
+$button-color: auto !default;
+$button-radius: 0 !default;
+$button-sizes: (
+ tiny: 0.7,
+ small: 0.8,
+ medium: 1,
+ large: 1.3,
+) !default;
+$button-font-size: 0.875rem !default;
+$button-opacity-disabled: 0.5 !default;
+$button-tag-selector: false !default;
+///
+
+%button {
+ display: inline-block;
+ border: 0;
+ text-align: center;
+ line-height: 1.25rem;
+ cursor: pointer;
+ -webkit-appearance: none;
+ -webkit-font-smoothing: antialiased;
+ transition: background 0.25s ease-out;
+ vertical-align: middle;
+
+ padding: $button-padding;
+ margin: $button-margin;
+ font-size: $button-font-size;
+ border-radius: $button-radius;
+
+ // Dropdown arrow
+ // TODO: Change to class and mixin because now the toggle is 'fa-open' which is too generic
+ // &[data-popup-toggle] {
+ // position: relative;
+ // padding-right: 2em; // Placeholder
+
+ // &::after {
+ // @include css-triangle(6px, black, top);
+ // position: absolute;
+ // right: 0.7em;
+ // top: 50%;
+ // margin-top: -3px;
+ // }
+ // }
+}
+
+@mixin button-size($size: medium, $expand: false) {
+ $size: $button-font-size * map-get($button-sizes, $size);
+ font-size: $size;
+
+ @if $expand {
+ @include button-expand;
+ }
+
+ @if using(iconic) {
+ .iconic {
+ width: 1em;
+ height: 1em;
+ vertical-align: middle;
+ margin-right: 0.25em;
+ margin-top: -2px; // The icons are oddly misaligned
+ }
+ }
+}
+
+@mixin button-expand($expand: true) {
+ @if $expand {
+ display: block;
+ width: 100%;
+ margin-left: 0;
+ margin-right: 0;
+ }
+ @else {
+ display: inline-block;
+ width: auto;
+ margin: $button-margin;
+ }
+}
+
+@mixin button-style(
+ $background: $button-background,
+ $background-hover: $button-background-hover,
+ $color: $button-color,
+ $style: $button-style,
+ $radius: $button-radius,
+ $btngroup: false
+){
+ @if $style == hollow {
+ border: 1px solid $background;
+ background: transparent;
+ color: $background;
+
+ &:hover, &:focus {
+ border-color: scale-color($background, $lightness: 25%);
+ background: transparent;
+ color: scale-color($background, $lightness: 25%);
+ }
+ }
+ // Solid is the default
+ @else {
+ @if $color == auto {
+ $color: isitlight($background);
+ }
+
+ background: $background;
+ color: $color;
+
+ &:hover, &:focus {
+ @if $background-hover == auto {
+ background: scale-color($background, $lightness: -15%);
+ }
+ @else {
+ background: $background-hover;
+ }
+ color: $color;
+ }
+ }
+
+ @if $btngroup {
+ border-color: $background;
+ &:hover, &:focus {
+ border-color: scale-color($background, $lightness: -25%);
+ }
+ }
+
+ @if using(iconic) {
+ @if $style == hollow {
+ .iconic {
+ @include color-icon($background);
+ }
+ &:hover .iconic {
+ @include color-icon(scale-color($background, $lightness: 25%));
+ }
+ }
+ @else {
+ .iconic {
+ @include color-icon($color);
+ }
+ }
+ }
+}
+
+@mixin button-disabled() {
+ opacity: $button-opacity-disabled;
+ cursor: default;
+ pointer-events: none;
+}
+
+@mixin button(
+ $size: medium,
+ $expand: false,
+ $background: $button-background,
+ $background-hover: $button-background-hover,
+ $color: $button-color,
+ $style: $button-style,
+ $radius: $button-radius
+) {
+ @extend %button;
+ @include button-size($size);
+ @include button-expand($expand);
+ @include button-style($background, $background-hover, $color, $style);
+}
+
+@include exports(button) {
+ .button {
+ @include button;
+
+ &.tiny { @include button-size(tiny); }
+ &.small { @include button-size(small); }
+ &.large { @include button-size(large); }
+ &.expand { @include button-expand; }
+
+ &.secondary { @include button-style($secondary-color, auto) }
+ &.success { @include button-style($success-color, auto) }
+ &.warning { @include button-style($warning-color, auto) }
+ &.alert { @include button-style($alert-color, auto) }
+ &.info { @include button-style($info-color, auto) }
+ &.dark { @include button-style($dark-color, auto) }
+
+ @if $button-style != hollow {
+ &.hollow { @include button-style($style: hollow);
+ &.secondary { @include button-style($secondary-color, $style: hollow); }
+ &.success { @include button-style($success-color, $style: hollow); }
+ &.warning { @include button-style($warning-color, $style: hollow); }
+ &.alert { @include button-style($alert-color, $style: hollow); }
+ &.info { @include button-style($info-color, $style: hollow); }
+ &.dark { @include button-style($dark-color, $style: hollow); }
+ }
+ }
+
+ &.disabled { @include button-disabled; }
+ }
+
+ @if $button-tag-selector {
+ button {
+ @extend .button;
+ }
+ }
+}