Adds placeholder text for js disabled browsers. Refs #1292.
This commit is contained in:
parent
9fd6464a74
commit
bddfe007b6
2 changed files with 6 additions and 6 deletions
|
|
@ -594,7 +594,8 @@ compiler.
|
||||||
|
|
||||||
.. raw:: html
|
.. raw:: html
|
||||||
|
|
||||||
<div id="officialPkgList"></div>
|
<div id="officialPkgList"><b>If you are reading this you are missing
|
||||||
|
babelpkglist.js or have javascript disabled in your browser.</b></div>
|
||||||
|
|
||||||
Unofficial packages
|
Unofficial packages
|
||||||
-------------------
|
-------------------
|
||||||
|
|
@ -605,7 +606,8 @@ Nimrod programming language.
|
||||||
|
|
||||||
.. raw:: html
|
.. raw:: html
|
||||||
|
|
||||||
<div id="unofficialPkgList"></div>
|
<div id="unofficialPkgList"><b>If you are reading this you are missing
|
||||||
|
babelpkglist.js or have javascript disabled in your browser.</b></div>
|
||||||
|
|
||||||
<script type="text/javascript" src="babelpkglist.js"></script>
|
<script type="text/javascript" src="babelpkglist.js"></script>
|
||||||
<script type="text/javascript" src="http://build.nimrod-lang.org/packages?callback=gotPackageList"></script>
|
<script type="text/javascript" src="http://build.nimrod-lang.org/packages?callback=gotPackageList"></script>
|
||||||
|
|
|
||||||
|
|
@ -50,19 +50,17 @@ proc processContent(content: string) =
|
||||||
|
|
||||||
var officialPkgListDiv = document.getElementById("officialPkgList")
|
var officialPkgListDiv = document.getElementById("officialPkgList")
|
||||||
|
|
||||||
officialPkgListDiv.innerHTML.add(
|
officialPkgListDiv.innerHTML =
|
||||||
p("There are currently " & $officialCount &
|
p("There are currently " & $officialCount &
|
||||||
" official packages in the Babel package repository.") &
|
" official packages in the Babel package repository.") &
|
||||||
ul(officialList)
|
ul(officialList)
|
||||||
)
|
|
||||||
|
|
||||||
var unofficialPkgListDiv = document.getElementById("unofficialPkgList")
|
var unofficialPkgListDiv = document.getElementById("unofficialPkgList")
|
||||||
|
|
||||||
unofficialPkgListDiv.innerHTML.add(
|
unofficialPkgListDiv.innerHTML =
|
||||||
p("There are currently " & $unofficialCount &
|
p("There are currently " & $unofficialCount &
|
||||||
" unofficial packages in the Babel package repository.") &
|
" unofficial packages in the Babel package repository.") &
|
||||||
ul(unofficialList)
|
ul(unofficialList)
|
||||||
)
|
|
||||||
|
|
||||||
proc gotPackageList(apiReply: TData) {.exportc.} =
|
proc gotPackageList(apiReply: TData) {.exportc.} =
|
||||||
let decoded = decodeContent($apiReply.content)
|
let decoded = decodeContent($apiReply.content)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue