Skip to content
This repository was archived by the owner on Mar 29, 2021. It is now read-only.

Commit 263ab84

Browse files
committed
Fix PubMed issue related to HTML character encoding. Closes #65
1 parent f2b14bd commit 263ab84

File tree

11 files changed

+519
-515
lines changed

11 files changed

+519
-515
lines changed

.stylintrc

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
{
2+
"borderNone": true,
3+
"brackets": true,
4+
"colons": true,
5+
"colors": true,
6+
"commaSpace": true,
7+
"commentSpace": true,
8+
"cssLiteral": false,
9+
"depthLimit": false,
10+
"duplicates": false,
11+
"efficient": true,
12+
"emoji": true,
13+
"enforceBlockStyle": false,
14+
"enforceVarStyle": true,
15+
"extendPref": "extend",
16+
"globalDupe": true,
17+
"indentSpaces": 4,
18+
"leadingZero": true,
19+
"maxWarnings": 10,
20+
"maxWarningsKill": false,
21+
"mixed": false,
22+
"namingConvention": "lowercase-dash",
23+
"namingConventionStrict": false,
24+
"parenSpace": false,
25+
"placeholders": true,
26+
"quotePref": "single",
27+
"semicolons": true,
28+
"sortOrder": false,
29+
"stackedProperties": true,
30+
"universal": true,
31+
"valid": false,
32+
"whitespace": true,
33+
"zeroUnits": true,
34+
"zIndexDuplicates": false,
35+
"zIndexNormalize": false
36+
}

CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
# Changelog
22

3+
### 3.1.5
4+
- Fix PubMed bug that resulted in citations with ampersands in the title to be parsed as `&`. HT @Da5idHatch
5+
36
### 3.1.4
47
- Fix issue that caused peer reviews that contain special characters to confuse WordPress.
58

academic-bloggers-toolkit.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
* Plugin Name: Academic Blogger's Toolkit
55
* Plugin URI: https://wordpress.org/plugins/academic-bloggers-toolkit/
66
* Description: A plugin extending the functionality of Wordpress for academic blogging
7-
* Version: 3.1.4
7+
* Version: 3.1.5
88
* Author: Derek P Sifford
99
* Author URI: https://github.com/dsifford
1010
* License: GPL3 or later

gulpfile.js

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,20 @@
11
/* eslint-env node, es6 */
2+
23
const gulp = require('gulp');
3-
const uglify = require('gulp-uglify');
44
const browserSync = require('browser-sync').create();
55
const del = require('del');
6+
const replace = require('gulp-replace');
7+
// PHP
68
const jade = require('gulp-jade2php');
79
const gfi = require('gulp-file-insert');
10+
const rename = require('gulp-rename');
11+
// Styles
812
const stylus = require('gulp-stylus');
913
const poststylus = require('poststylus');
1014
const autoprefixer = require('autoprefixer')({ browsers: ['last 2 versions'] });
11-
const rename = require('gulp-rename');
12-
13-
const replace = require('gulp-replace');
1415
const sourcemaps = require('gulp-sourcemaps');
16+
// JS
17+
const uglify = require('gulp-uglify');
1518
const webpack = require('webpack-stream');
1619
const webpackConfig = require('./webpack.config.js');
1720
const webpackDevConfig = Object.assign({}, webpackConfig, {
@@ -93,7 +96,7 @@ gulp.task('static', () =>
9396

9497
gulp.task('stylus:dev', () =>
9598
gulp.src([
96-
'lib/css/*.styl',
99+
'lib/**/*.styl',
97100
], { base: './', })
98101
.pipe(sourcemaps.init())
99102
.pipe(stylus({
@@ -107,7 +110,7 @@ gulp.task('stylus:dev', () =>
107110

108111
gulp.task('stylus:prod', () =>
109112
gulp.src([
110-
'lib/css/*.styl',
113+
'lib/**/*.styl',
111114
], { base: './', })
112115
.pipe(stylus({
113116
use: [ poststylus([autoprefixer]), ],

lib/css/admin.styl

Lines changed: 98 additions & 149 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,21 @@
1+
$f5 = #f5f5f5
2+
$555 = #555
3+
$white = #fff
4+
$555d66 = #555d66
5+
$ebebeb = #ebebeb
6+
$a0a5aa = a0a5aa
7+
$c9 = #c9c9c9
8+
$f9 = #f9f9f9
9+
110
#abt_menubutton
2-
&::after
3-
content: ' '
4-
height: 24px
5-
position: absolute
11+
&::after
12+
content ' '
13+
height 24px
14+
position absolute
615

716

817
i.mce-i-abt_menu
9-
font: normal 25px/1 'dashicons'
18+
font normal 25px/1 'dashicons'
1019

1120

1221
#abt_menubutton.mce-active,
@@ -17,163 +26,103 @@ i.mce-i-abt_menu
1726
#abt_refgenerator.mce-active *,
1827
#abt_refgenerator:hover,
1928
#abt_refgenerator:hover *
20-
color: rgb(50, 55, 60)
29+
color: rgb(50, 55, 60)
2130

2231

2332
.abt-reflist-button
24-
background: 0
25-
border: 1px solid #f5f5f5
26-
border-radius: 2px
27-
color: #555
28-
cursor: pointer
29-
height: 30px
30-
outline: 0
31-
min-width: 40px
32-
33-
&:hover
34-
box-shadow: inset 0 1px 0 #fff,0 1px 0 rgba(0,0,0,.08)
35-
border: 1px solid #555d66
36-
37-
&:active
38-
@extend .abt-reflist-button:hover
39-
background: #ebebeb
40-
box-shadow: inset 0 2px 5px -3px rgba(0,0,0,.3)
41-
42-
&:disabled
43-
color: #a0a5aa
44-
box-shadow: none
45-
border: 1px solid #f5f5f5
46-
cursor: default
47-
pointer-events: none
33+
background 0
34+
border 1px solid $f5
35+
border-radius 2px
36+
color $555
37+
cursor pointer
38+
height 30px
39+
outline 0
40+
min-width 40px
41+
42+
&:hover
43+
box-shadow inset 0 1px 0 $white,0 1px 0 rgba(0,0,0,.08)
44+
border 1px solid $555d66
45+
46+
&:active
47+
@extend .abt-reflist-button:hover
48+
background $ebebeb
49+
box-shadow inset 0 2px 5px -3px rgba(0,0,0,.3)
50+
51+
&:disabled
52+
color $a0a5aa
53+
box-shadow none
54+
border 1px solid $f5
55+
cursor default
56+
pointer-events none
4857

4958

5059
// ========== Loading Spinner ===========
5160
.sk-circle
52-
border: 5px solid #f5f5f5
53-
margin-left: auto
54-
margin-right: auto
55-
width: 40px
56-
height: 40px
57-
position: relative
58-
59-
.sk-child
60-
width: 100%
61-
height: 100%
62-
position: absolute
63-
left: 0
64-
top: 0
65-
66-
&:before
67-
content: ''
68-
display: block
69-
margin: 0 auto
70-
width: 15%
71-
height: 15%
72-
background-color: #555d66
73-
border-radius: 100%
74-
animation: sk-circleBounceDelay 1.2s infinite ease-in-out both
75-
76-
.sk-circle2
77-
transform: rotate(30deg)
78-
79-
&:before
80-
animation-delay: -1.1s
81-
82-
.sk-circle3
83-
transform: rotate(60deg)
84-
85-
&:before
86-
animation-delay: -1s
87-
88-
.sk-circle4
89-
transform: rotate(90deg)
90-
91-
&:before
92-
animation-delay: -0.9s
93-
94-
.sk-circle5
95-
transform: rotate(120deg)
96-
97-
&:before
98-
animation-delay: -0.8s
99-
100-
.sk-circle6
101-
transform: rotate(150deg)
102-
103-
&:before
104-
animation-delay: -0.7s
105-
106-
.sk-circle7
107-
transform: rotate(180deg)
108-
109-
&:before
110-
animation-delay: -0.6s
111-
112-
.sk-circle8
113-
transform: rotate(210deg)
114-
115-
&:before
116-
animation-delay: -0.5s
117-
118-
.sk-circle9
119-
transform: rotate(240deg)
120-
121-
&:before
122-
animation-delay: -0.4s
123-
124-
.sk-circle10
125-
transform: rotate(270deg)
126-
127-
&:before
128-
animation-delay: -0.3s
129-
130-
.sk-circle11
131-
transform: rotate(300deg)
132-
133-
&:before
134-
animation-delay: -0.2s
135-
136-
.sk-circle12
137-
transform: rotate(330deg)
138-
139-
&:before
140-
animation-delay: -0.1s
61+
border 5px solid $f5
62+
margin-left auto
63+
margin-right auto
64+
width 40px
65+
height 40px
66+
position relative
67+
68+
.sk-child
69+
width 100%
70+
height 100%
71+
position absolute
72+
left 0
73+
top 0
74+
75+
&:before
76+
content ''
77+
display block
78+
margin 0 auto
79+
width 15%
80+
height 15%
81+
background-color $555d66
82+
border-radius 100%
83+
animation sk-circleBounceDelay 1.2s infinite ease-in-out both
84+
85+
for num in 2 3 4 5 6 7 8 9 10 11 12
86+
.sk-circle{num}
87+
transform 'rotate(%sdeg)' % (30 * (num - 1))
88+
&:before
89+
animation-delay '%ss' % (-2.2 + (1 + (num - 1) * .1))
14190

14291

14392
@keyframes sk-circleBounceDelay
144-
0%,
145-
100%,
146-
80%
147-
transform: scale(0)
93+
0%,
94+
100%,
95+
80%
96+
transform: scale(0)
14897

149-
40%
150-
transform: scale(1)
98+
40%
99+
transform: scale(1)
151100

152101
// ================================
153102
// PeerReviewMetabox.tsx
154103
// ================================
155104
.row-container
156-
display: flex
157-
flex-direction: column
158-
159-
.row
160-
display: flex
161-
padding: 15px 10px 15px 0
162-
border-right: 1px solid #C9C9C9
163-
border-left: 1px solid #C9C9C9
164-
align-items: center
165-
166-
.even
167-
background-color: #f9f9f9
168-
169-
.flex1
170-
flex: 1
171-
padding: 0 5px
172-
173-
.bordered
174-
border: 1px solid #C9C9C9
175-
border-bottom: 0
176-
177-
label
178-
white-space: nowrap
179-
padding: 0 10px
105+
display flex
106+
flex-direction column
107+
108+
.row
109+
display flex
110+
padding 15px 10px 15px 0
111+
border-right 1px solid $c9
112+
border-left 1px solid $c9
113+
align-items center
114+
115+
.even
116+
background-color $f9
117+
118+
.flex1
119+
flex 1
120+
padding 0 5px
121+
122+
.bordered
123+
border 1px solid $c9
124+
border-bottom 0
125+
126+
label
127+
white-space nowrap
128+
padding 0 10px

0 commit comments

Comments
 (0)