Skip to content

Commit

Permalink
Merge branch '11.x' of https://github.com/SU-SWS/stanford_profile int…
Browse files Browse the repository at this point in the history
…o 10.x
  • Loading branch information
pookmish committed Mar 5, 2025
2 parents a3f4bde + 754bc9e commit f34d14d
Show file tree
Hide file tree
Showing 25 changed files with 140 additions and 88 deletions.
2 changes: 2 additions & 0 deletions config/sync/config_ignore.settings.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ ignored_config_entities:
- 'next.next_entity_type_config.*'
- 'next.next_site.*'
- 'samlauth.authentication:map_users_roles'
- 'stage_file_proxy.settings:origin'
- 'stage_file_proxy.settings:origin_dir'
- 'system.action.user_add_role_action.custm_*'
- 'system.action.user_remove_role_action.custm_*'
- 'system.theme:default'
Expand Down
9 changes: 5 additions & 4 deletions config/sync/config_split.config_split.dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,16 @@ no_patching: false
storage: folder
folder: ../config/envs/dev
module:
shield: 0
acquia_purge: 0
purge_queuer_coretags: 0
purge_processor_lateruntime: 0
paranoia: 0
purge: 0
purge_processor_cron: 0
purge_drush: 0
purge_processor_cron: 0
purge_processor_lateruntime: 0
purge_queuer_coretags: 0
purge_tokens: 0
shield: 0
stage_file_proxy: 0
update: 0
stage_file_proxy: 0
theme: { }
Expand Down
7 changes: 3 additions & 4 deletions config/sync/config_split.config_split.stage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,13 @@ no_patching: false
storage: folder
folder: ../config/envs/stage
module:
shield: 0
acquia_purge: 0
purge_queuer_coretags: 0
purge_processor_lateruntime: 0
paranoia: 0
purge: 0
purge_processor_cron: 0
purge_drush: 0
purge_processor_cron: 0
purge_processor_lateruntime: 0
purge_queuer_coretags: 0
purge_tokens: 0
stage_file_proxy: 0
theme: { }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ content:
placeholder: ''
third_party_settings:
maxlength:
maxlength_js: 1000
maxlength_js: 2000
maxlength_js_label: 'Content limited to @limit characters, remaining: <strong>@remaining</strong>'
maxlength_js_enforce: true
change_labels:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,15 @@ content:
size: 60
placeholder: ''
third_party_settings: { }
status:
type: boolean_checkbox
weight: 1
region: content
settings:
display_label: true
third_party_settings: { }
hidden:
description: true
path: true
publish_on: true
status: true
unpublish_on: true
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,15 @@ content:
size: 60
placeholder: ''
third_party_settings: { }
status:
type: boolean_checkbox
weight: 2
region: content
settings:
display_label: true
third_party_settings: { }
hidden:
layout_builder__layout: true
path: true
publish_on: true
status: true
unpublish_on: true
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,15 @@ content:
size: 60
placeholder: ''
third_party_settings: { }
status:
type: boolean_checkbox
weight: 2
region: content
settings:
display_label: true
third_party_settings: { }
hidden:
layout_builder__layout: true
path: true
publish_on: true
status: true
unpublish_on: true
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,15 @@ content:
size: 60
placeholder: ''
third_party_settings: { }
status:
type: boolean_checkbox
weight: 2
region: content
settings:
display_label: true
third_party_settings: { }
hidden:
layout_builder__layout: true
path: true
publish_on: true
status: true
unpublish_on: true
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,15 @@ content:
size: 60
placeholder: ''
third_party_settings: { }
status:
type: boolean_checkbox
weight: 2
region: content
settings:
display_label: true
third_party_settings: { }
hidden:
layout_builder__layout: true
path: true
publish_on: true
status: true
unpublish_on: true
Original file line number Diff line number Diff line change
Expand Up @@ -7,18 +7,20 @@ label: 'citation su_article_journal validation'
entity_type: citation
bundle: su_article_journal
field_validation_rules:
da067b26-a15e-4df5-bd66-b9605c7c2121:
id: regex_field_validation_rule
4e08bc2f-aa62-4360-b503-80d9aefc88dc:
uuid: 4e08bc2f-aa62-4360-b503-80d9aefc88dc
id: regex_constraint_rule
title: 'DOI does not include http'
data:
setting: '/^((?!http).)*$/'
weight: 1
uuid: da067b26-a15e-4df5-bd66-b9605c7c2121
weight: 2
field_name: su_doi
column: value
error_message: 'DOI must not be the full url.'
error_message: ''
roles: { }
condition:
field: ''
operator: ''
value: ''
data:
pattern: '/^((?!http).)*$/'
message: 'DOI must not be the full url.'
validate_mode: direct
16 changes: 9 additions & 7 deletions config/sync/field_validation.rule_set.citation_su_book.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,18 +7,20 @@ label: 'citation su_book validation'
entity_type: citation
bundle: su_book
field_validation_rules:
7358cbb2-1a51-4ad6-a16d-b3fc1a55438e:
id: regex_field_validation_rule
c342a2f2-78b1-43b5-80f2-a170b175b91a:
uuid: c342a2f2-78b1-43b5-80f2-a170b175b91a
id: regex_constraint_rule
title: 'DOI does not include http'
data:
setting: '/^((?!http).)*$/'
weight: 1
uuid: 7358cbb2-1a51-4ad6-a16d-b3fc1a55438e
weight: 2
field_name: su_doi
column: value
error_message: 'DOI must not be the full url.'
error_message: ''
roles: { }
condition:
field: ''
operator: ''
value: ''
data:
pattern: '/^((?!http).)*$/'
message: 'DOI must not be the full url.'
validate_mode: direct
16 changes: 9 additions & 7 deletions config/sync/field_validation.rule_set.citation_su_thesis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,18 +7,20 @@ label: 'citation su_thesis validation'
entity_type: citation
bundle: su_thesis
field_validation_rules:
dbb80b6e-70b6-490c-9d08-acf34997819b:
id: regex_field_validation_rule
8a5122eb-5456-47a5-89a4-0c1fc0f4fe2b:
uuid: 8a5122eb-5456-47a5-89a4-0c1fc0f4fe2b
id: regex_constraint_rule
title: 'DOI does not include http'
data:
setting: '/^((?!http).)*$/'
weight: 1
uuid: dbb80b6e-70b6-490c-9d08-acf34997819b
weight: 2
field_name: su_doi
column: value
error_message: 'DOI must not be the full url.'
error_message: ''
roles: { }
condition:
field: ''
operator: ''
value: ''
data:
pattern: '/^((?!http).)*$/'
message: 'DOI must not be the full url.'
validate_mode: direct
Original file line number Diff line number Diff line change
Expand Up @@ -3,45 +3,19 @@ langcode: en
status: true
dependencies:
module:
- field_validation_legacy
- stanford_samlauth
name: config_pages_stanford_basic_site_settings
label: 'config_pages stanford_basic_site_settings validation'
entity_type: config_pages
bundle: stanford_basic_site_settings
field_validation_rules:
a24c3b48-8555-4b09-8ab7-12f3a60cc543:
uuid: a24c3b48-8555-4b09-8ab7-12f3a60cc543
id: regex_field_validation_rule
title: 'Google Analytics'
weight: '1'
field_name: su_google_analytics
column: value
error_message: 'A valid Google Analytics Web Property ID is case sensitive and formatted like UA-xxxxxxx-yy or G-xxxxxxxxxx.'
roles: { }
condition: { }
data:
setting: '/(?:UA|G|AW|DC)-[0-9a-zA-Z]{5,}(?:-[0-9]{1,})?/'
56d4b822-4038-43ef-864b-0465236bd395:
uuid: 56d4b822-4038-43ef-864b-0465236bd395
id: regex_field_validation_rule
title: 'Algolia JS File Path'
weight: '2'
field_name: su_site_algolia_file
column: value
error_message: 'Js file must be either an absolute server path or a url.'
roles: { }
condition:
field: ''
operator: ''
value: ''
data:
setting: /^(\/|http)/
1bb527fd-c2b5-4065-9ff0-1bfe4bbd9547:
message: 'This is not a valid SunetID.'
validate_mode: default
uuid: 1bb527fd-c2b5-4065-9ff0-1bfe4bbd9547
id: valid_sunetid_constraint_rule
title: 'Validate SunetID'
weight: 3
weight: '3'
field_name: su_site_sunetid
column: value
error_message: ''
Expand All @@ -53,3 +27,20 @@ field_validation_rules:
data:
message: 'This is not a valid SunetID.'
validate_mode: default
fab483e9-0ed4-4087-94ab-f134f4f9fa2c:
uuid: fab483e9-0ed4-4087-94ab-f134f4f9fa2c
id: regex_constraint_rule
title: 'Google Analytics'
weight: '4'
field_name: su_google_analytics
column: value
error_message: ''
roles: { }
condition:
field: ''
operator: ''
value: ''
data:
pattern: '/(?:UA|G|AW|DC)-[0-9a-zA-Z]{5,}(?:-[0-9]{1,})?/'
message: 'A valid Google Analytics Web Property ID is case sensitive and formatted like UA-xxxxxxx-yy or G-xxxxxxxxxx.'
validate_mode: direct
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,20 @@ label: 'config_pages stanford_events_importer validation'
entity_type: config_pages
bundle: stanford_events_importer
field_validation_rules:
40e20165-85e8-40f2-bb3f-40b23d710bba:
id: regex_field_validation_rule
3ec31e72-486a-48d3-bd90-d35db20c04c0:
uuid: 3ec31e72-486a-48d3-bd90-d35db20c04c0
id: regex_constraint_rule
title: 'Bookmarked Feed'
data:
setting: '/https:\/\/events-legacy\.stanford.edu\/bookmark\/feed\.php\?slug=/'
weight: 1
uuid: 40e20165-85e8-40f2-bb3f-40b23d710bba
weight: 2
field_name: su_localist_bookmark
column: uri
error_message: 'Url must be a bookmark feed url.'
error_message: ''
roles: { }
condition: { }
condition:
field: ''
operator: ''
value: ''
data:
pattern: '/https:\/\/events-legacy\.stanford.edu\/bookmark\/feed\.php\?slug=/'
message: 'Url must be a bookmark feed url.'
validate_mode: direct
Original file line number Diff line number Diff line change
Expand Up @@ -7,18 +7,20 @@ label: 'config_pages stanford_local_footer validation'
entity_type: config_pages
bundle: stanford_local_footer
field_validation_rules:
d8d3f70a-89e9-451a-9d4a-336dc7400835:
id: regex_field_validation_rule
929a9985-e3c7-4a86-9ff1-d9f349df4932:
uuid: 929a9985-e3c7-4a86-9ff1-d9f349df4932
id: regex_constraint_rule
title: 'Supported Social Links'
data:
setting: /(google|twitter|bsky|github|threads|flickr|mastodon|instagram|linkedin|youtube|x|facebook)\.(com|app|org|net)/
weight: 1
uuid: d8d3f70a-89e9-451a-9d4a-336dc7400835
weight: 2
field_name: su_local_foot_social
column: uri
error_message: 'Social URL is not supported.'
error_message: ''
roles: { }
condition:
field: ''
operator: ''
value: ''
data:
pattern: /(google|twitter|bsky|github|threads|flickr|mastodon|instagram|linkedin|youtube|x|facebook)\.(com|app|org|net)/
message: 'Social URL is not supported.'
validate_mode: direct
2 changes: 1 addition & 1 deletion config/sync/trash.settings.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@ _core:
enabled_entity_types:
node: { }
auto_purge:
enabled: false
enabled: true
after: '30 days'
4 changes: 2 additions & 2 deletions tests/codeception/acceptance/Content/BasicPageCest.php
Original file line number Diff line number Diff line change
Expand Up @@ -368,7 +368,7 @@ public function testMetaData(AcceptanceTester $I) {
* @group search-results
*/
public function testSearchResult(AcceptanceTester $I) {
$text = $this->faker->paragraphs(2, TRUE);
$text = 'Two things are infinite: the universe and human stupidity; and I\'m not sure about the universe.';
$wysiwyg = $I->createEntity([
'type' => 'stanford_wysiwyg',
'su_wysiwyg_text' => ['value' => $text, 'format' => 'stanford_html'],
Expand All @@ -383,7 +383,7 @@ public function testSearchResult(AcceptanceTester $I) {
$I->click('Save');
$I->canSee($node->label(), 'h1');

$I->fillField('Search this site', $node->label());
$I->fillField('Search this site', 'human stupidity');
$I->click('Submit Search');
$I->canSee($node->label(), 'h2');

Expand Down
2 changes: 1 addition & 1 deletion tests/codeception/acceptance/Content/EventsCest.php
Original file line number Diff line number Diff line change
Expand Up @@ -302,7 +302,7 @@ public function testTermPublishing(AcceptanceTester $I) {
'name' => $this->faker->word,
], 'taxonomy_term');
$I->amOnPage($term->toUrl('edit-form')->toString());
$I->cantSee('Published');
$I->canSeeCheckboxIsChecked('Published');
}

/**
Expand Down
2 changes: 1 addition & 1 deletion tests/codeception/acceptance/Content/NewsCest.php
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ public function testTermPublishing(AcceptanceTester $I) {
'name' => $this->faker->word,
], 'taxonomy_term');
$I->amOnPage($term->toUrl('edit-form')->toString());
$I->cantSee('Published');
$I->canSeeCheckboxIsChecked('Published');
}

/**
Expand Down
Loading

0 comments on commit f34d14d

Please sign in to comment.