Skip to content

[pull] dev from opf:dev #523

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 8 commits into from
Apr 1, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
end

start_date.with_row(classes: "wp-datepicker-dialog-date-form--text-field-container") do
render(Primer::Alpha::TextField.new(**text_field_options(name: :start_date, label: start_date_label)))
render(Primer::Alpha::TextField.new(**text_field_options(name: :start_date, label: start_date_label), aria: { live: :polite }))
end
start_date.with_row(classes: "wp-datepicker-dialog-set-today-link") do
render_today_link(name: :start_date)
Expand All @@ -45,7 +45,7 @@
end

due_date.with_row(classes: "wp-datepicker-dialog-date-form--text-field-container") do
render(Primer::Alpha::TextField.new(**text_field_options(name: :due_date, label: I18n.t("attributes.due_date"))))
render(Primer::Alpha::TextField.new(**text_field_options(name: :due_date, label: I18n.t("attributes.due_date")), aria: { live: :polite }))
end
due_date.with_row(classes: "wp-datepicker-dialog-set-today-link") do
render_today_link(name: :due_date)
Expand All @@ -54,7 +54,7 @@
end

body.with_column(classes: "wp-datepicker-dialog-date-form--duration") do
render(Primer::Alpha::TextField.new(**text_field_options(name: :duration, label: WorkPackage.human_attribute_name("duration"))))
render(Primer::Alpha::TextField.new(**text_field_options(name: :duration, label: WorkPackage.human_attribute_name("duration")), aria: { live: :polite }))
end
end
end
Expand Down
3 changes: 2 additions & 1 deletion app/controllers/errors_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,10 @@ def not_found
render_404
end

# this may be called on CSRF validation failure
def unacceptable
render file: "#{Rails.public_path.join('422.html')}",
status: :not_acceptable,
status: :unprocessable_entity,
layout: false
end

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
<op-icon icon-classes="{{ iconClass }} button--icon"></op-icon>
<span class="button--text">
{{ buttonText }}
<span class="badge -secondary" *ngIf="initialized" [textContent]="filterCount"></span>
<span class="badge" *ngIf="initialized" [textContent]="filterCount"></span>
</span>
<span class="spot-icon spot-icon_dropdown"></span>
</button>
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
size="small"
></svg>
<span class="button--text" *ngIf="(shareCount$ | async) as shareCount">
<span class="badge -secondary"
<span class="badge"
[textContent]="shareCount"></span>
</span>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ export class RelationCellbuilder {
badge.classList.add('wp-table--relation-count');

badge.textContent = count.toString();
badge.classList.add('badge', '-border-only');
badge.classList.add('badge');

return badge;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ export class ResourcesDisplayField extends DisplayField {
content.appendChild(abridged);

if (values.length > 2) {
const badge = this.optionDiv(values.length.toString(), 'badge', '-secondary');
const badge = this.optionDiv(values.length.toString(), 'badge');
content.appendChild(badge);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ export class PrincipalRendererService {

if (users.length > maxCount) {
const badge = document.createElement('span');
badge.classList.add('op-principal-list--badge', 'badge', '-secondary');
badge.classList.add('op-principal-list--badge', 'badge');
badge.textContent = users.length.toString();
wrapper.appendChild(badge);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
{{ text.toggle_title }}
<span
*ngIf="(numberOfProjectsInFilter$ | async) as count"
class="badge -secondary"
class="badge"
[textContent]="count"
>
</span>
Expand Down
14 changes: 2 additions & 12 deletions frontend/src/global_styles/content/_badges.sass
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,7 @@
//++

$badge-diameter: 1.25rem
$badge-background: var(--buttonCounter-default-bgColor-rest)
$badge-secondary-background: var(--buttonCounter-default-bgColor-rest)
$badge-background: var(--bgColor-neutral-muted)
$badge-color: var(--fgColor-default)

@mixin badge-layout($diameter: $badge-diameter)
Expand All @@ -40,6 +39,7 @@ $badge-color: var(--fgColor-default)
color: $color

.badge
font-size: var(--text-body-size-small)
display: inline-flex
align-items: center
justify-content: center
Expand All @@ -51,13 +51,3 @@ $badge-color: var(--fgColor-default)
min-width: 1.25rem
padding-left: 0.3rem
padding-right: 0.3rem

&.-secondary
@include badge-style($badge-secondary-background, $badge-color)

&.-border-only
border-color: var(--button-default-borderColor-rest)
color: var(--body-font-color)
background: transparent
border-width: 1px
border-style: solid
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,8 @@ body
@extend .icon-arrow-up1

// Add some margin between badge and indicator
.wp-table--relation-count.-border-only
.wp-table--relation-count
margin-right: 5px
background: white

// Override default left-align of cells
.wp-table--relation-cell-td
Expand Down
3 changes: 0 additions & 3 deletions frontend/src/global_styles/layout/_toolbar.sass
Original file line number Diff line number Diff line change
Expand Up @@ -138,10 +138,7 @@ $nm-color-success-background: #d8fdd1
margin-left: 0.2em

.badge
font-size: 14px
vertical-align: 1px

font-size: 14px
line-height: 1

i
Expand Down
4 changes: 2 additions & 2 deletions frontend/src/vendor/ckeditor/ckeditor.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion frontend/src/vendor/ckeditor/ckeditor.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion frontend/src/vendor/ckeditor/translations/af.js

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

2 changes: 1 addition & 1 deletion frontend/src/vendor/ckeditor/translations/ar.js

Large diffs are not rendered by default.

Loading
Loading