Skip to content

Instantly share code, notes, and snippets.

@fago
Last active October 11, 2021 21:53
Show Gist options
  • Save fago/32041b33e260aeb1a3393edbd08a9739 to your computer and use it in GitHub Desktop.
Save fago/32041b33e260aeb1a3393edbd08a9739 to your computer and use it in GitHub Desktop.
Patch off-canvas dialog with.
Index: lib/Drupal/Core/Ajax/OpenOffCanvasDialogCommand.php
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
diff --git a/lib/Drupal/Core/Ajax/OpenOffCanvasDialogCommand.php b/lib/Drupal/Core/Ajax/OpenOffCanvasDialogCommand.php
--- a/lib/Drupal/Core/Ajax/OpenOffCanvasDialogCommand.php
+++ b/lib/Drupal/Core/Ajax/OpenOffCanvasDialogCommand.php (date 1633988933771)
@@ -57,6 +57,8 @@
if (!isset($this->dialogOptions['width'])) {
$this->dialogOptions['width'] = static::DEFAULT_DIALOG_WIDTH;
}
+ // Patched by ldp-core: Always use 45% width for off-canvas dialogs.
+ $this->dialogOptions['width'] = '45%';
}
/**
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment