Compare commits

...

2 Commits

  1. 10
      bibcite_footnotes.info.yml
  2. 26
      bibcite_footnotes.module
  3. 1
      css/reference_footnote.css

10
bibcite_footnotes.info.yml

@ -9,7 +9,13 @@ dependencies:
- footnotes:footnotes
# Information added by Drupal.org packaging script on 2018-07-30
version: '8.x-1.0-alpha5'
# version: '8.x-1.0-alpha5'
# core: '8.x'
# project: 'bibcite_footnotes'
# datestamp: 1532941092
# Information added by Drupal.org packaging script on 2018-10-17
version: '8.x-1.0-beta1'
core: '8.x'
project: 'bibcite_footnotes'
datestamp: 1532941092
datestamp: 1539801484

26
bibcite_footnotes.module

@ -5,6 +5,7 @@
* Contains bibcite_footnotes.module.
*/
use Drupal\Core\Form\FormStateInterface;
use Drupal\Core\Routing\RouteMatchInterface;
use Drupal\Core\Url;
use Drupal\Core\Link;
@ -194,3 +195,28 @@ function bibcite_footnotes_theme_footnote_list($footnotes) {
return $str;
}
function bibcite_footnotes_form_filter_format_edit_form_alter(&$form, &$form_state, $form_id) {
$form['filters']['settings']['filters_footnotes']['bibcite_footnotes'] = [
'#type' => 'fieldset',
'#title' => t('Bibliography and Citation SettingsE'),
'#collapsible' => FALSE,
'#collapsed' => FALSE,
];
$form['filters']['settings']['filter_footnotes']['bibcite_footnotes']['notes_section_label'] = [
'#type' => 'textfield',
'#title' => t('Notes section label'),
'#default_value' => \Drupal::config('filters.filter_footnotes.settings.bibcite_footnotes')->get('notes_section_label'),
];
$form['filters']['settings']['filter_footnotes']['bibcite_footnotes']['references_section_label'] = [
'#type' => 'textfield',
'#title' => t('References section label'),
'#default_value' => \Drupal::config('filters.filter_footnotes.settings.bibcite_footnotes')->get('references_section_label'),
];
$form['actions']['submit']['#submit'][] = 'bibcite_footnotes_filter_settings_form_submit';
}
function bibcite_footnotes_filter_settings_form_submit($form, FormStateInterface $form_state) {
$config = \Drupal::service('config.factory')->getEditable('filters.filter_footnotes.settings.bibcite_footnotes');
//$config->set('notes_section_label') =
}

1
css/reference_footnote.css

@ -5,4 +5,3 @@
.footnotes .footnote .footnote-link::after {
content: " ";
white-space: pre;
}
Loading…
Cancel
Save