Skip to content

Commit dd415a4

Browse files
committed
Merge branch 'dash-export-offline'
2 parents baf6424 + 14049ac commit dd415a4

File tree

4 files changed

+23
-3
lines changed

4 files changed

+23
-3
lines changed

lib/utils.js

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,19 @@ module.exports.buildDashDocSet = function (input) {
2424
require('../templates/dash/plist.hbs')(input)
2525
);
2626

27-
db.serialize(function() {
27+
[
28+
'bootstrap/bootstrap.min.css',
29+
'highlight.js/github.min.css'
30+
].forEach(function (resource) {
31+
32+
zip.addLocalFile(
33+
path.join(__dirname, '../templates/dash/resources/' + resource),
34+
input.title + '.docset/Contents/Resources/Documents/resources/' + path.dirname(resource)
35+
);
36+
37+
});
38+
39+
db.serialize(function () {
2840

2941
db.run('CREATE TABLE searchIndex(id INTEGER PRIMARY KEY, name TEXT, type TEXT, path TEXT);');
3042
db.run('CREATE UNIQUE INDEX anchor ON searchIndex (name, type, path);');

templates/dash/index.hbs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@
44
<meta charset="utf-8">
55
<meta name="viewport" content="initial-scale=1">
66
<title>{{title}}</title>
7-
<link rel="stylesheet" href="http://maxcdn.bootstrapcdn.com/bootstrap/3.3.1/css/bootstrap.min.css">
8-
<link rel="stylesheet" href="http://cdnjs.cloudflare.com/ajax/libs/highlight.js/8.4/styles/github.min.css">
7+
<link rel="stylesheet" href="resources/bootstrap/bootstrap.min.css">
8+
<link rel="stylesheet" href="resources/highlight.js/github.min.css">
99
<style>
1010
1111
.wrap {

templates/dash/resources/bootstrap/bootstrap.min.css

Lines changed: 6 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

templates/dash/resources/highlight.js/github.min.css

Lines changed: 2 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)