Problem/Motivation

Drupal 10.1 made some fairly major changes to the bulk operations form which VBO seems to be inheriting. It is now a floating bar that appears at the bottom of the page. (issue link to come) - Tested on Claro.

2 Issues are present:

The "Apply to selected items" button text is grey, leading to bad contrast with the blue background. - core issue #3378091: Disabled primary button in views area has grey text on blue background (bad contrast)

The Selected items dropdown and checkbox are pretty broken - these probably need a new home.

Bulk operations

Steps to reproduce

Install Standard profile on 10.1.x
Install VBO
Swap bulk operations on admin/content to VBO version
Tick "Always show selection info"
Create some content
Visit admin/content

Proposed resolution

TBC

Comments

acbramley created an issue. See original summary.

acbramley’s picture

Issue summary: View changes
StatusFileSize
new86.25 KB
acbramley’s picture

Looks like the grey button text is coming from claro's disabled button styling.

acbramley’s picture

acbramley’s picture

Issue summary: View changes
graber’s picture

Priority: Normal » Major

Hopefully some frontend dev can help here 🙏
I can do any backend changes if requested.

acbramley’s picture

There doesn't seem to be a way to turn the selection section off completely without custom code, using a form_alter hook we can remove them for now:

function my_module_form_alter(array &$form, FormStateInterface $form_state, string $form_id): void {
    if (!str_starts_with($form_id, 'views_form') || !isset($form['header']['views_bulk_operations_bulk_form'])) {
      return;
    }

    // Hide the Select all checkbox, and the "Selected items" accordion.
    $form['header']['views_bulk_operations_bulk_form']['select_all']['#access'] = FALSE;
    $form['header']['views_bulk_operations_bulk_form']['multipage']['#access'] = FALSE;
  }
edmund.dunn’s picture

We are going to address this. Working with our designer to get comp to work from. More to follow.

edmund.dunn’s picture

Here is the patch.
screen shot of fixes

edmund.dunn’s picture

Status: Active » Needs review
acbramley’s picture

Status: Needs review » Reviewed & tested by the community

Great work, huge improvement! The list still looks a bit clunky when the Selected items are expanded but not sure if there's much we can do about that.

  • Graber committed 539779ba on 4.2.x authored by edmund.dunn
    Issue #3378090 by edmund.dunn, acbramley: Styling broken in VBO form on...
graber’s picture

Status: Reviewed & tested by the community » Fixed

Nice one, thank you, will release this soon along with some other updates.

graber’s picture

Ahh, almost forgot.. we could make that expandable details area an overlay if needed but that can be a follow-up.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.