472 Commits

Author SHA1 Message Date
OpenProject Actions CI c28ee43cfe update locales from crowdin [ci skip] 2026-06-03 04:37:13 +00:00
Alexander Brandon Coles 86e40ffffe Adapt specs to capybara_accessible_selectors 0.16
Refactors the custom `:list`/`:list_item` selectors onto CAS's
`add_role_selector` and drops the now-native `Capybara::Node::Simple#role`
hack. `:list_item` resolves the listitem role, so specs matching
non-listitem `<li>` are updated (`have_row` for the custom field table,
presentation dividers via CSS).

CAS 0.16 also resolves role selectors by computed role and accessible
name, which our CSS-styled tables and Primer menus do not expose through
plain markup. Affected feature specs switch to robust locators:
Capybara's `:table_row`, the FullCalendar `data-date`, and the action
menu's real accessible name ("Edit status").

The `:columnheader` `colindex` filter lost its off-by-one offset and now
uses the true 1-based `th` position. Also fixes Webhooks `RowComponent`
spec capitalization.
2026-05-29 20:41:25 +02:00
Alexander Brandon Coles 0812f6f8bf Merge branch 'dev' into housekeeping/bump-jquery-4.0.0 2026-05-27 09:15:25 +02:00
Ivan Kuchin e3afba4465 follow yamllint except key ordering 2026-05-26 16:33:15 +02:00
Alexander Brandon Coles 6a86c267f4 [#68734] Migrate webhooks form jQuery to Stimulus
Replaces jQuery-based enable/disable logic in the webhooks admin form
with a new Stimulus controller `disable-when-value-selected`.

This change was originally deferred from PR #20884 as it was planned to
be addressed in Work Package #69436 / PR #21227. Since that work has
been put on hold and jQuery removal is progressing, this commit
completes the migration now.

Changes:
- Add DisableWhenValueSelectedController for declarative form toggling
- Add toggleEnabled/enableElement/disableElement helpers to dom-helpers
- Remove jQuery code from webhooks admin form
- Apply Stimulus controller to project selection fieldset

Related to opf/openproject#20884

https://community.openproject.org/wp/68734
2026-05-26 12:03:20 +02:00
OpenProject Actions CI 3ca0c4d361 update locales from crowdin [ci skip] 2026-05-26 04:28:22 +00:00
OpenProject Actions CI d5b027b04b update locales from crowdin [ci skip] 2026-05-19 04:31:41 +00:00
OpenProject Actions CI bda5ed1cdc update locales from crowdin [ci skip] 2026-05-10 04:24:16 +00:00
Alexander Brandon Coles e8767481e9 [#70166] Fix accessibility errors found by ERB Lint (#21503)
* Fix GitHub/NoTitleAttribute, LinkHasHref errors

- Replaces `title` attribute with `aria-label` for interactive elements.
- Removes `title` from non-interactive elements.
- Converts `<a>` tags without proper `href` to `<button>` elements,
  using Primer `Button`/`IconButton` where possible.

# Conflicts:
#	app/views/custom_fields/_custom_options.html.erb
#	spec/features/admin/custom_fields/shared_custom_field_expectations.rb
#	spec/features/admin/custom_fields/work_packages/list_spec.rb

* Fix Autocomplete missing errors

* Fix GitHub/NoPositiveTabIndex errors

Removes all positive `tabindex` values.

* Fix Rails/LinkToBlank errors

* Replace toast with Primer Banner on LDAP form

* Add frozen_string_literal

* Ignore erb lint for deprecated files

* Fix linting errors in repository module

* Fix linting errors in budgets and custom actions

* Fix linting errors in member form and 2fa

* Fix linting errors in mcost types and wiki help and storages

* Fix linting errors in multi select filters, ifc viewer, and unsupported browser banner

* Fix failing spec

* Use Primer banner instead of op-toast where ever it is possible

* Use octicon instead of op_icon

* Fix failing tests

* Use no-decoration-on-hover for button links and change the button with only an icon to primer icon button

* Keep webhook response modal activation selector class-based

* use icon button for edit of hourly rate

---------

Co-authored-by: Behrokh Satarnejad <b.satarnejad@openproject.com>
2026-05-07 10:31:10 +02:00
OpenProject Actions CI 0e4437def6 update locales from crowdin [ci skip] 2026-05-06 04:21:38 +00:00
OpenProject Actions CI 4e56e47774 update locales from crowdin [ci skip] 2026-04-24 04:10:24 +00:00
Pavel Balashou 181efda9c6 Ensure tempfile is always removed.
Co-authored-by: Andrej Sandorf <77627197+as-op@users.noreply.github.com>
2026-04-21 13:25:15 +02:00
Pavel Balashou 53e33770c2 Use ssrf filtering in Jira Import. 2026-04-21 10:29:45 +02:00
OpenProject Actions CI dd7f45a05e update locales from crowdin [ci skip] 2026-04-14 04:04:43 +00:00
OpenProject Actions CI f97f227f12 update locales from crowdin [ci skip] 2026-04-13 04:08:47 +00:00
OpenProject Actions CI 8c154d623d update locales from crowdin [ci skip] 2026-04-12 12:45:29 +00:00
OpenProject Actions CI 13e368f21e update locales from crowdin [ci skip] 2026-04-12 04:06:25 +00:00
OpenProject Actions CI dfa27ffad1 update locales from crowdin [ci skip] 2026-04-10 04:04:05 +00:00
OpenProject Actions CI 10937badb2 update locales from crowdin [ci skip] 2026-04-09 11:38:47 +00:00
OpenProject Actions CI 8157603028 update locales from crowdin [ci skip] 2026-04-09 03:59:36 +00:00
OpenProject Actions CI a9b1d7920e update locales from crowdin [ci skip] 2026-04-08 04:07:10 +00:00
OpenProject Actions CI b4e20c2e37 update locales from crowdin [ci skip] 2026-03-31 04:01:36 +00:00
Jan Sandbrink f9d8bc6614 Introduce SubclassResponsibility error
This error is intended for cases when a method is
intentionally not implemented, because the module/class defining
it expects a subclass (or class including the module) to implement
the method.

This is intended to distinguish it from other cases, such as:
* feature not implemented yet
* edge case of a method call not yet supported

Notably it avoids the misuse of the Ruby-defined NotImplementedError,
which is only intended for much more specific scenarios:

> Raised when a feature is not implemented on the current platform. For example, methods depending on the fsync or fork system calls may raise this exception [...]

Also see https://docs.ruby-lang.org/en/master/NotImplementedError.html
2026-03-27 08:14:56 +01:00
OpenProject Actions CI 905cc4f873 update locales from crowdin [ci skip] 2026-03-26 07:50:33 +00:00
Oliver Günther d3f543ddd4 Alter i18n links to avoid inconsistency 2026-03-20 09:49:11 +01:00
Oliver Günther 4d731dcab6 Replace raw and explicit html_safe calls 2026-03-20 09:49:10 +01:00
Jan Sandbrink 46786b5085 Address minor style details after community contribution
Those were too small for me to point out and thus block the
corresponding PR further. But I wanted to address them anyways:

* actor should be exposed the same way as resource for consistency
* usage of actor can be simplified
* one regression test didn't need repetition for actor case
2026-03-19 14:45:02 +01:00
Jan Sandbrink 9875e98cb7 Merge pull request #21341 from cheezzz/fix/webhook-user-attribution
Fix: Webhooks show work package author instead of actual updater
2026-03-19 14:41:25 +01:00
Johlan Pretorius c6efb1ac5b Refactor: Move actor to base class with optional keyword argument
Move actor resolution to the caller and actor representation to
RepresentedWebhookJob, keeping WorkPackageWebhookJob simple.
The caller extracts the actor from the journal and passes it as
an optional `actor:` keyword argument, making the feature available
to all webhook types without changing existing method signatures.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-19 13:09:06 +02:00
OpenProject Actions CI 97f9bd5db5 Merge branch 'release/17.2' into dev 2026-03-17 04:18:23 +00:00
Oliver Günther 8f6c7d2a73 Use different structure for content type header
https://community.openproject.org/projects/openproject/work_packages/73145/activity
2026-03-16 15:48:19 +01:00
Johlan Pretorius 9be22f95c4 Fix: Add explicit actor field to webhook payloads
Work package webhooks now include a top-level `actor` field identifying
the user who triggered the event (the journal author), separate from the
work package's `author` (the original creator).

  {
    "action": "work_package:updated",
    "actor": { "id": 5, "name": "Jane Smith", "_type": "User", ... },
    "work_package": { ... }
  }

The representer continues to use User.system for payload generation,
preserving custom field visibility. The actor is sourced from the
journal passed to WorkPackageWebhookJob.

Resolves: https://community.openproject.org/wp/69658

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-16 16:41:10 +02:00
Markus Kahl f64e45eec7 SSRF protection update to work with ssrf_filter 1.3, explicitly pin gem version 2026-03-10 16:12:40 +00:00
Markus Kahl c131ef9737 rubocop 2026-03-09 16:11:33 +00:00
Markus Kahl 333c9c6b46 refactor wh service test 2026-03-09 16:05:59 +00:00
Markus Kahl 47021aa605 fix webhook specs 2026-03-09 15:54:16 +00:00
Markus Kahl a52f5e4469 rubocop 2026-03-09 14:55:10 +00:00
Markus Kahl 2a6d53ef81 include hint to OPENPROJECT_SSRF_PROTECTION_IP_ALLOWLIST in error log 2026-03-09 14:55:10 +00:00
Markus Kahl 1bbd53cf65 test webhooks to private IPs are blocked 2026-03-09 14:55:10 +00:00
Markus Kahl 7c36ee2ede use ssrf filter for webhook request 2026-03-09 14:55:10 +00:00
Markus Kahl df548fe8ad amend webhook service spec 2026-03-09 14:55:09 +00:00
Dombi Attila c389018b1e Remove es-AR translation 2026-02-16 14:34:07 +02:00
OpenProject Actions CI 82420f0f09 update locales from crowdin [ci skip] 2026-02-16 08:09:09 +00:00
OpenProject Actions CI 5c7c9ecb95 update locales from crowdin [ci skip] 2026-02-15 03:53:21 +00:00
OpenProject Actions CI 691d56b177 update locales from crowdin [ci skip] 2026-02-10 04:06:56 +00:00
OpenProject Actions CI 9fb06a8ab8 update locales from crowdin [ci skip] 2026-02-06 03:51:00 +00:00
OpenProject Actions CI 22f84cea86 update locales from crowdin [ci skip] 2026-01-30 03:49:34 +00:00
Behrokh Satarnejad 66269ee57f Replace inline message component 2026-01-23 16:22:38 +01:00
Alexander Brandon Coles 07ae586e1a Rename WarningText to InlineMessageComponent
Aligns implementation with Primer React's InlineMessage component.

See: https://primer.style/product/components/inline-message/
2026-01-14 05:43:58 -03:00
OpenProject Actions CI 5d266cb1cb update locales from crowdin [ci skip] 2026-01-13 03:39:18 +00:00