Skip to content

Commit 42ec5f3

Browse files
authored
Merge pull request #212 from RRZE-Webteam/dev
v1.23.1
2 parents 33ca576 + b328fd2 commit 42ec5f3

21 files changed

+146
-396
lines changed

assets/css/_alerts.scss

+40
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
border: 1px solid transparent;
88
font-weight: normal;
99
background-color: #e9edf2;
10+
overflow: hidden;
1011
strong {
1112
color: inherit;
1213
}
@@ -58,4 +59,43 @@
5859
.alert.alert-danger p {
5960
font-size: 1rem;
6061
line-height: 1.5;
62+
}
63+
64+
.alert-example,
65+
#content .alert-example {
66+
margin: 30px 20px 40px;
67+
padding: 30px 10px 5px;
68+
position: relative;
69+
background: #fff;
70+
overflow: initial;
71+
border: 1px dashed var(--color-TextLight, $medium-grey);
72+
border-radius: 3px;
73+
&:after {
74+
background: #fff;
75+
border: 1px dashed var(--color-TextLight, $medium-grey);
76+
color: var(--color-Text);
77+
content: "Beispiel";
78+
font-family: sans-serif;
79+
font-size: .8rem;
80+
line-height: inherit;
81+
font-weight: 700;
82+
padding: 3px 10px;
83+
position: absolute;
84+
right: 20px;
85+
text-transform: uppercase;
86+
top: -1.2rem;
87+
z-index: 1;
88+
overflow: auto;
89+
:lang(en) & {
90+
content: 'Example';
91+
}
92+
.fau-events & {
93+
width: auto;
94+
height: auto;
95+
visibility: initial;
96+
}
97+
}
98+
&[title]:after {
99+
content: attr(title);
100+
}
61101
}

assets/css/_textcolumns.scss

+9
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
.elements-textcolumns {
2+
column-gap: 2em;
3+
padding-bottom: 1em;
4+
figure {
5+
-webkit-column-break-inside: avoid;
6+
page-break-inside: avoid;
7+
break-inside: avoid;
8+
}
9+
}

assets/css/rrze-elements.css

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

assets/css/rrze-elements.css.map

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

assets/css/rrze-elements.scss

+4-1
Original file line numberDiff line numberDiff line change
@@ -56,4 +56,7 @@
5656
@import "latex";
5757

5858
//Font-Awesome-Icons
59-
@import "icons";
59+
@import "icons";
60+
61+
//Text-Columns (Fließtext in Spalten)
62+
//@import "textcolumns";

includes/Accordion/Accordion.php

+8-5
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,12 @@
99
*/
1010
class Accordion
1111
{
12-
/**
12+
protected $pluginFile;
13+
14+
/**
1315
* [__construct description]
1416
*/
15-
public function __construct()
17+
public function __construct($pluginFile)
1618
{
1719
add_shortcode('collapsibles', [$this, 'shortcodeCollapsibles']);
1820
add_shortcode('accordion', [$this, 'shortcodeCollapsibles']);
@@ -23,6 +25,7 @@ public function __construct()
2325
add_action('wp_enqueue_scripts', [$this, 'enqueueScripts']);
2426
add_action('wp_enqueue_scripts', [$this, 'enqueueScriptTranslations'], 100);
2527

28+
$this->pluginFile = $pluginFile;
2629
}
2730

2831
/**
@@ -172,12 +175,12 @@ public static function enqueueScripts() {
172175
plugins_url('assets/js/rrze-accordion.min.js', plugin_basename(__FILE__)),
173176
//plugins_url('assets/js/rrze-accordion.js', plugin_basename(__FILE__)),
174177
['jquery', 'wp-i18n'],
175-
'1.23.0'
178+
'1.23.1'
176179
);
177180
}
178181

179-
public static function enqueueScriptTranslations()
182+
public function enqueueScriptTranslations()
180183
{
181-
wp_set_script_translations('rrze-accordions', 'rrze-elements');
184+
wp_set_script_translations('rrze-accordions', 'rrze-elements',plugin_dir_path( $this->pluginFile ) . 'languages/');
182185
}
183186
}

includes/Accordion/assets/js/rrze-accordion.js

-2
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,6 @@ jQuery(document).ready(function($) {
1717
var open = $(this).find(".accordion-body.open");
1818
if (items.length == open.length) {
1919
$(this).find('button.expand-all').attr("data-status", 'open').data('status', 'open').html(__('Collapse All', 'rrze-elements'));
20-
//$(this).find('button.expand-all').attr("data-status", 'open').data('status', 'open').html(accordionToggle.collapse_all);
21-
//console.log("items = " + items.length + " open = " + open.length);
2220
}
2321
}
2422
});

0 commit comments

Comments
 (0)