Skip to content

Commit

Permalink
Merge branch 'develop' into yalb-1164-1461
Browse files Browse the repository at this point in the history
  • Loading branch information
joetower committed Jul 24, 2023
2 parents bd9a0cc + 299ac57 commit c9a6de4
Show file tree
Hide file tree
Showing 15 changed files with 160 additions and 63 deletions.
15 changes: 13 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,9 @@
"cweagans/composer-patches": "^1.7",
"drupal/core-composer-scaffold": "^9.2",
"drupal/core-recommended": "^9.2",
"drush/drush": "^10",
"drush/drush": "^11 || ^12",
"pantheon-systems/drupal-integrations": "^9",
"wikimedia/composer-merge-plugin": "^2.1",
"yalesites-org/yalesites_profile": "*"
},
"require-dev": {
Expand Down Expand Up @@ -93,6 +94,14 @@
"composer-exit-on-patch-failure": true,
"patchLevel": {
"drupal/core": "-p2"
},
"allow-plugins": {
"JJJ/chosen": true
},
"merge-plugin": {
"include": [
"web/modules/contrib/chosen/composer.libraries.json"
]
}
},
"config": {
Expand All @@ -106,7 +115,9 @@
"composer/installers": true,
"cweagans/composer-patches": true,
"drupal/core-composer-scaffold": true,
"drupal/console-extend-plugin": true
"drupal/console-extend-plugin": true,
"wikimedia/composer-merge-plugin": true,
"oomphinc/composer-installers-extender": true
}
},
"scripts": {
Expand Down
14 changes: 12 additions & 2 deletions web/profiles/custom/yalesites_profile/composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"drupal/calendar_link": "^3.0",
"drupal/captcha": "^1.8",
"drupal/cas": "^2.0",
"drupal/chosen": "^3.0",
"drupal/chosen": "^4.0",
"drupal/components": "^3.0",
"drupal/config_filter": "^2.4",
"drupal/config_ignore": "^3.0",
Expand Down Expand Up @@ -82,19 +82,29 @@
"drupal/webform": "^6.2@beta",
"drupal/wingsuit_companion": "^2.0@RC",
"yalesites-org/atomic": "1.16.3",
"oomphinc/composer-installers-extender": "^2.0",
"wikimedia/composer-merge-plugin": "^2.1",
"yalesites-org/yale_cas": "^1.0"
},
"minimum-stability": "dev",
"prefer-stable": true,
"config": {
"sort-packages": true
"sort-packages": true,
"allow-plugins": {
"composer/installers": true,
"oomphinc/composer-installers-extender": true,
"wikimedia/composer-merge-plugin": true
}
},
"extra": {
"enable-patching": true,
"composer-exit-on-patch-failure": true,
"patchLevel": {
"drupal/core": "-p2"
},
"installer-paths": {
"../../../../web/core": ["type:drupal-core"]
},
"patches": {
"drupal/layout_paragraphs": {
"save close tweaks": "https://git.drupalcode.org/project/layout_paragraphs/-/merge_requests/80.patch"
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
_core:
default_config_hash: exRaKE0s6uZbfQrl_2WFEcTlc_1t81xEqCLuCCteUSk
minimum_single: 20
minimum_multiple: 20
disable_search_threshold: 0
minimum_width: 0
use_relative_width: false
jquery_selector: 'select:visible'
search_contains: false
disable_search: false
allow_single_deselect: false
placeholder_text_multiple: 'Choose some options'
placeholder_text_single: 'Choose an option'
no_results_text: 'No results match'
max_shown_results: null
disabled_themes: { }
chosen_include: 2
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ dependencies:
- node.type.event
module:
- allowed_formats
- chosen_field
- field_group
- link
- maxlength
Expand Down Expand Up @@ -87,14 +88,10 @@ bundle: event
mode: default
content:
field_category:
type: entity_reference_autocomplete_tags
type: chosen_select
weight: 1
region: content
settings:
match_operator: CONTAINS
match_limit: 10
size: 60
placeholder: ''
settings: { }
third_party_settings: { }
field_event_cta:
type: link_default
Expand Down Expand Up @@ -142,14 +139,10 @@ content:
use_details: true
third_party_settings: { }
field_tags:
type: entity_reference_autocomplete_tags
type: chosen_select
weight: 2
region: content
settings:
match_operator: CONTAINS
match_limit: 10
size: 60
placeholder: ''
settings: { }
third_party_settings: { }
field_teaser_media:
type: media_library_widget
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ dependencies:
- node.type.page
module:
- allowed_formats
- chosen_field
- field_group
- maxlength
- media_library
Expand Down Expand Up @@ -74,14 +75,10 @@ content:
use_details: true
third_party_settings: { }
field_tags:
type: entity_reference_autocomplete_tags
type: chosen_select
weight: 1
region: content
settings:
match_operator: CONTAINS
match_limit: 10
size: 60
placeholder: ''
settings: { }
third_party_settings: { }
field_teaser_media:
type: media_library_widget
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ dependencies:
- node.type.post
module:
- allowed_formats
- chosen_field
- datetime
- field_group
- maxlength
Expand Down Expand Up @@ -72,14 +73,10 @@ content:
placeholder: ''
third_party_settings: { }
field_category:
type: entity_reference_autocomplete_tags
type: chosen_select
weight: 3
region: content
settings:
match_operator: CONTAINS
match_limit: 10
size: 60
placeholder: ''
settings: { }
third_party_settings: { }
field_login_required:
type: boolean_checkbox
Expand All @@ -103,14 +100,10 @@ content:
settings: { }
third_party_settings: { }
field_tags:
type: entity_reference_autocomplete_tags
type: chosen_select
weight: 4
region: content
settings:
match_operator: CONTAINS
match_limit: 10
size: 60
placeholder: ''
settings: { }
third_party_settings: { }
field_teaser_media:
type: media_library_widget
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@ module:
captcha: 0
cas: 0
cas_attributes: 0
chosen: 0
chosen_field: 0
chosen_lib: 0
ckeditor: 0
components: 0
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ field_name: field_category
entity_type: node
bundle: event
label: Category
description: 'Separate categories with commas. Categories will autocomplete if one exists.'
description: 'Categories will autocomplete as you type. Choose from pre-created options only. To add a new category, go to ''Content->Manage Taxonomy->Event Categories''.'
required: false
translatable: false
default_value: { }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ field_name: field_tags
entity_type: node
bundle: event
label: Tags
description: 'Separate tags with commas. Tags will autocomplete if one exists.'
description: 'Tags will autocomplete as you type. Choose from pre-created options only. To add a new tag, go to ''Content->Manage Taxonomy->Tags''.'
required: false
translatable: true
default_value: { }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ field_name: field_tags
entity_type: node
bundle: page
label: Tags
description: 'Separate tags with commas. Tags will autocomplete if one exists.'
description: 'Tags will autocomplete as you type. Choose from pre-created options only. To add a new tag, go to ''Content->Manage Taxonomy->Tags''.'
required: false
translatable: false
default_value: { }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ field_name: field_category
entity_type: node
bundle: post
label: Category
description: 'Separate categories with commas. Categories will autocomplete if one exists.'
description: 'Categories will autocomplete as you type. Choose from pre-created options only. To add a new category, go to ''Content->Manage Taxonomy->Post Categories''.'
required: false
translatable: true
default_value: { }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ field_name: field_tags
entity_type: node
bundle: post
label: Tags
description: 'Separate tags with commas. Tags will autocomplete if one exists.'
description: 'Tags will autocomplete as you type. Choose from pre-created options only. To add a new tag, go to ''Content->Manage Taxonomy->Tags''.'
required: false
translatable: true
default_value: { }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,23 @@
width: 100%;
}

/* chosen-specific */
.chosen-container-multi .chosen-choices {
border: unset;
border-radius: unset;
}

/* Chosen dropdown selected color contrast fix */
/* ******************************************* */
.chosen-container .chosen-results {
color: var(--gin-color-info);
}

.chosen-container-multi .chosen-drop .result-selected {
color: var(--gin-color-green);
}
/* ************ Contrast fix end ************ */

/* visually hide the inputs */
.layout-builder-configure-block .grouped-items .glb-form-type--radio input {
border: 0;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -214,34 +214,24 @@ public function formElement(

$form['group_user_selection']['filter_and_sort']['terms_include'] = [
'#title' => $this->t('Include content that uses the following terms'),
'#type' => 'entity_autocomplete',
'#type' => 'select',
'#options' => $this->viewsBasicManager->getAllTags(),
'#chosen' => TRUE,
'#multiple' => TRUE,
'#tags' => TRUE,
'#target_type' => 'taxonomy_term',
'#default_value' => ($items[$delta]->params) ? $this->viewsBasicManager->getDefaultParamValue('terms_include', $items[$delta]->params) : [],
'#selection_handler' => 'views',
'#selection_settings' => [
'view' => [
'view_name' => 'taxonomy_lookup',
'display_name' => 'entity_reference_1',
'arguments' => [],
],
],
];

$form['group_user_selection']['filter_and_sort']['terms_exclude'] = [
'#title' => $this->t('Exclude content that uses the following terms'),
'#type' => 'entity_autocomplete',
'#type' => 'select',
'#options' => $this->viewsBasicManager->getAllTags(),
'#multiple' => TRUE,
'#chosen' => TRUE,
'#tags' => TRUE,
'#target_type' => 'taxonomy_term',
'#default_value' => ($items[$delta]->params) ? $this->viewsBasicManager->getDefaultParamValue('terms_exclude', $items[$delta]->params) : [],
'#selection_handler' => 'views',
'#selection_settings' => [
'view' => [
'view_name' => 'taxonomy_lookup',
'display_name' => 'entity_reference_1',
'arguments' => [],
],
],
];

// Gets the view mode options based on Ajax callbacks or initial load.
Expand Down
Loading

0 comments on commit c9a6de4

Please sign in to comment.