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 Oct 18, 2023
2 parents 6eb0acc + f08417e commit d038cde
Show file tree
Hide file tree
Showing 10 changed files with 55 additions and 27 deletions.
7 changes: 3 additions & 4 deletions config/sync/views.view.policies.yml
Original file line number Diff line number Diff line change
Expand Up @@ -287,16 +287,15 @@ display:
entity_type: node
entity_field: nid
plugin_id: node_nid
default_action: ignore
default_action: default
exception:
value: all
title_enable: false
title: All
title_enable: false
title: ''
default_argument_type: fixed
default_argument_options:
argument: ''
default_argument_type: node
default_argument_options: { }
default_argument_skip_url: false
summary_options:
base_path: ''
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ favicon:
logo:
use_default: true
brand_bar_variant: default
global_footer_variant: default
lockup:
option: a
line1: Jumpstart
Expand Down
2 changes: 1 addition & 1 deletion themes/stanford_basic/dist/css/base.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion themes/stanford_basic/dist/css/content/policy.css

Large diffs are not rendered by default.

24 changes: 24 additions & 0 deletions themes/stanford_basic/src/scss/base/_breadcrumb.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
@charset 'UTF-8';

//Breadcrumbs.
.breadcrumb {
@include responsive-spacing('padding-top', 0);

ol {
list-style: none;
}

li {
display: inline-block;

&::before {
content: " / ";
}

&:first-of-type {
&::before {
content: " ";
}
}
}
}
3 changes: 2 additions & 1 deletion themes/stanford_basic/src/scss/base/index.scss
Original file line number Diff line number Diff line change
Expand Up @@ -28,4 +28,5 @@
// Roll up partial imports.
@import
'table',
'typography';
'typography',
'breadcrumb';
17 changes: 0 additions & 17 deletions themes/stanford_basic/src/scss/content/policy/_policy.scss
Original file line number Diff line number Diff line change
Expand Up @@ -9,23 +9,6 @@
}
}

//Breadcrumbs.
.breadcrumb {
@include responsive-spacing('padding-top', 0);

li {
&::before {
content: " / ";
}

&:first-of-type {
&::before {
content: " ";
}
}
}
}

// Previous and Next
.book-forward-back {
a {
Expand Down
4 changes: 4 additions & 0 deletions themes/stanford_basic/stanford_basic.theme
Original file line number Diff line number Diff line change
Expand Up @@ -256,6 +256,10 @@ function stanford_basic_preprocess_page(&$vars) {
if ($bbv !== "none") {
$vars['brand_bar_variant'] = 'su-brand-bar--' . $bbv;
}
// Variant setting for the global footer.
if ($global_footer_variant = theme_get_setting('global_footer_variant')) {
$vars['global_footer_variant'] = 'su-global-footer--' . $global_footer_variant;
}

// Prepares non node/panel pages to be in a single column.
_stanford_basic_preprocess_not_nodes($vars);
Expand Down
6 changes: 3 additions & 3 deletions themes/stanford_basic/templates/page.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,8 @@
{%- block block_help -%}
{{ page.help }}
{%- endblock -%}
<section>

<section class="su-masthead--inner">
{{ page.header }}
{{ page.search }}
{{ page.menu }}
Expand All @@ -65,7 +65,7 @@
{%- block block_footer -%}
<footer id="footer">
{{ page.footer }}
{%- include template_global_footer -%}
{%- include template_global_footer with { modifier_class : global_footer_variant } -%}
</footer>
{%- endblock -%}

Expand Down
16 changes: 16 additions & 0 deletions themes/stanford_basic/theme-settings.php
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,22 @@ function stanford_basic_form_system_theme_settings_alter(array &$form, FormState
'#default_value' => theme_get_setting('brand_bar_variant'),
];

// Global footer support.
$form['options_settings']['stanford_basic_global_footer'] = [
'#type' => 'fieldset',
'#title' => t('Global Footer Settings'),
];

$form['options_settings']['stanford_basic_global_footer']['global_footer_variant'] = [
'#type' => 'select',
'#title' => t('Global Footer Variant'),
'#options' => [
'dark' => t('Dark'),
],
'#empty_option' => t('- Default -'),
'#default_value' => theme_get_setting('global_footer_variant'),
];

$img = '<img src="' . base_path() . \Drupal::service('extension.list.theme')
->getPath('stanford_basic') . '/dist/assets/img/lockup-example.png" />';
$decanter = Link::fromTextAndUrl('Decanter Lockup Component', Url::fromUri('https://decanter.stanford.edu/component/identity-lockup/'))
Expand Down

0 comments on commit d038cde

Please sign in to comment.