Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
D
douban-api-proxy
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
captainwong
douban-api-proxy
Commits
30c9aa3d
Commit
30c9aa3d
authored
May 09, 2020
by
jvoisin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Minor fixes to caliBlur.js
- Add alt attributes to images - Fix a broken tag
parent
189243a9
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
caliBlur.js
cps/static/js/caliBlur.js
+3
-3
No files found.
cps/static/js/caliBlur.js
View file @
30c9aa3d
...
@@ -140,9 +140,9 @@ if ( $( 'body.book' ).length > 0 ) {
...
@@ -140,9 +140,9 @@ if ( $( 'body.book' ).length > 0 ) {
// Sexy blurred backgrounds
// Sexy blurred backgrounds
cover
=
$
(
'.cover img'
).
attr
(
'src'
);
cover
=
$
(
'.cover img'
).
attr
(
'src'
);
$
(
'#loader + .container-fluid'
)
$
(
'#loader + .container-fluid'
)
.
prepend
(
'<div class="blur-wrapper"></div'
);
.
prepend
(
'<div class="blur-wrapper"></div
>
'
);
$
(
'.blur-wrapper'
)
$
(
'.blur-wrapper'
)
.
prepend
(
'<div><img class="bg-blur" src="'
+
cover
+
'"></div>'
);
.
prepend
(
'<div><img
alt="Blurred cover"
class="bg-blur" src="'
+
cover
+
'"></div>'
);
// Fix-up book detail headings
// Fix-up book detail headings
publisher
=
$
(
'.publishers p span'
).
text
().
split
(
':'
);
publisher
=
$
(
'.publishers p span'
).
text
().
split
(
':'
);
...
@@ -442,7 +442,7 @@ if ( $( 'body.author' ).length >0 ) {
...
@@ -442,7 +442,7 @@ if ( $( 'body.author' ).length >0 ) {
cover
=
$
(
'.author-bio img'
).
attr
(
'src'
);
cover
=
$
(
'.author-bio img'
).
attr
(
'src'
);
$
(
'#loader + .container-fluid'
)
$
(
'#loader + .container-fluid'
)
.
prepend
(
'<div class="blur-wrapper"></div>'
);
.
prepend
(
'<div class="blur-wrapper"></div>'
);
$
(
'.blur-wrapper'
).
prepend
(
'<img class="bg-blur" src="'
+
cover
+
'">'
);
$
(
'.blur-wrapper'
).
prepend
(
'<img
alt="Blurred author bio"
class="bg-blur" src="'
+
cover
+
'">'
);
// Place undefined cover images inside container
// Place undefined cover images inside container
if
(
$
(
'.bg-blur[src="undefined"]'
).
length
>
0
)
{
if
(
$
(
'.bg-blur[src="undefined"]'
).
length
>
0
)
{
$
(
'.bg-blur'
).
before
(
'<div class="bg-blur undefined-img"></div>'
);
$
(
'.bg-blur'
).
before
(
'<div class="bg-blur undefined-img"></div>'
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment