Commit e2703140 authored by Vladimir Roudakov's avatar Vladimir Roudakov Committed by Vladimir Roudakov
Browse files

Issue #3301223 by VladimirAus: Drupal 10 compatibility

parent 23e837e9
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
name: Bootstrap5
type: theme
description: 'Theme with Bootstrap 5 css library'
core_version_requirement: ^8.9 || ^9
core_version_requirement: ^9.2 || ^10
base theme: classy

libraries:
@@ -10,6 +10,8 @@ libraries:

ckeditor_stylesheets:
  - css/style.css
ckeditor5-stylesheets:
  - css/style.css

stylesheets-remove:
  - '@classy/css/components/tabs.css'
+1 −1
Original line number Diff line number Diff line
@@ -16,7 +16,7 @@ drupal.nav-tabs:
    - core/matchmedia
    - core/jquery
    - core/drupal
    - core/jquery.once
    - core/once
    - core/drupal.debounce
    - core/collapse

+5 −6
Original line number Diff line number Diff line
@@ -2,9 +2,10 @@
 * @file
 * Responsive navigation tabs (local tasks)
 *
 * Element requires to have class .is-collapsible and attribute [data-drupal-nav-tabs]
 * Element requires to have class .is-collapsible and attribute
 *   [data-drupal-nav-tabs]
 */
(($, Drupal) => {
(($, Drupal, once) => {
  function init(i, tab) {
    const $tab = $(tab);
    const $target = $tab.find('[data-drupal-nav-tabs-target]');
@@ -25,12 +26,10 @@
   */
  Drupal.behaviors.navTabs = {
    attach(context) {
      $(context)
        .find('[data-drupal-nav-tabs].is-collapsible')
        .once('nav-tabs')
      once('nav-tabs', '[data-drupal-nav-tabs].is-collapsible', context)
        .each((i, value) => {
          $(value).each(init);
        });
    },
  };
})(jQuery, Drupal);
})(jQuery, Drupal, once);
+3 −3
Original line number Diff line number Diff line
@@ -5,7 +5,7 @@
* @preserve
**/

(function ($, Drupal) {
(function ($, Drupal, once) {
  function init(i, tab) {
    var $tab = $(tab);
    var $target = $tab.find('[data-drupal-nav-tabs-target]');
@@ -23,9 +23,9 @@

  Drupal.behaviors.navTabs = {
    attach: function attach(context) {
      $(context).find('[data-drupal-nav-tabs].is-collapsible').once('nav-tabs').each(function (i, value) {
      once('nav-tabs', '[data-drupal-nav-tabs].is-collapsible', context).each(function (i, value) {
        $(value).each(init);
      });
    }
  };
})(jQuery, Drupal);
 No newline at end of file
})(jQuery, Drupal, once);
+2 −2
Original line number Diff line number Diff line
@@ -10,7 +10,7 @@
 * @see template_preprocess_select()
 */
#}
{% spaceless %}
{% apply spaceless %}
  <select{{ attributes.addClass('form-control') }}>
    {% for option in options %}
      {% if option.type == 'optgroup' %}
@@ -24,4 +24,4 @@
      {% endif %}
    {% endfor %}
  </select>
{% endspaceless %}
{% endapply %}