Add gist embedding
This commit is contained in:
parent
e92d0cd82c
commit
f4affdacc2
@ -2,6 +2,7 @@ seaweedchan:
|
||||
- Fix various embedding issues
|
||||
- Fix Link Title depending on Embedding
|
||||
- Added favicons to links that can be embedded
|
||||
- Add gist embedding
|
||||
|
||||
### 1.1.4 - 2013-04-29
|
||||
seaweedchan:
|
||||
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -923,4 +923,8 @@ a:only-of-type > .remove {
|
||||
.linkify.pastebin {
|
||||
background: transparent url('data:image/png;base64,<%= grunt.file.read("src/General/img/links/pastebin.png", {encoding: "base64"}) %>') center left no-repeat!important;
|
||||
padding-left: 18px;
|
||||
}
|
||||
.linkify.gist {
|
||||
background: transparent url('data:image/png;base64,<%= grunt.file.read("src/General/img/links/gist.png", {encoding: "base64"}) %>') center left no-repeat!important;
|
||||
padding-left: 18px;
|
||||
}
|
||||
BIN
src/General/img/links/gist.png
Normal file
BIN
src/General/img/links/gist.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 683 B |
@ -206,6 +206,13 @@ Linkify =
|
||||
div = $.el 'iframe',
|
||||
src: "http://pastebin.com/embed_iframe.php?i=#{@name}"
|
||||
|
||||
gist:
|
||||
regExp: /.*(?:gist.github.com\/.*\/)([^#\&\?]*).*/
|
||||
el: ->
|
||||
div = $.el 'iframe',
|
||||
# Github doesn't allow embedding straight from the site, so we use an external site to bypass that.
|
||||
src: "http://www.purplegene.com/script?url=https://gist.github.com/#{@name}.js"
|
||||
|
||||
embedder: (a) ->
|
||||
return [a] unless Conf['Link Title']
|
||||
titles = {}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user