Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 27 additions & 0 deletions COPYING.annotator
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
Copyright 2014, The Annotator project contributors.
# Annotator licensing terms
http://annotatorjs.org

Annotator is free software, and you may use it under the terms of either the
MIT or the GNU GPL licenses:

## GNU GPLv3

You can redistribute this program and/or modify it under the terms of the
GNU General Public License as published by the Free Software Foundation,
either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program. See LICENSE-GPL, or, if this file is missing,
<http://www.gnu.org/licenses/>.

## MIT

You may use the software under the terms of the MIT license, which can be
found in LICENSE-MIT, or, if this file is missing,
<http://www.opensource.org/licenses/mit-license>.
34 changes: 34 additions & 0 deletions COPYING.showdown
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
Copyright (c) 2007, John Fraser
<http://www.attacklab.net/>
All rights reserved.

Original Markdown copyright (c) 2004, John Gruber
<http://daringfireball.net/>
All rights reserved.

Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are
met:

* Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimer.

* Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.

* Neither the name "Markdown" nor the names of its contributors may
be used to endorse or promote products derived from this software
without specific prior written permission.

This software is provided by the copyright holders and contributors "as
is" and any express or implied warranties, including, but not limited
to, the implied warranties of merchantability and fitness for a
particular purpose are disclaimed. In no event shall the copyright owner
or contributors be liable for any direct, indirect, incidental, special,
exemplary, or consequential damages (including, but not limited to,
procurement of substitute goods or services; loss of use, data, or
profits; or business interruption) however caused and on any theory of
liability, whether in contract, strict liability, or tort (including
negligence or otherwise) arising in any way out of the use of this
software, even if advised of the possibility of such damage.
8 changes: 8 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -541,3 +541,11 @@ in the COPYING file distributed along with this README.
Mustard ships a copy of jQuery in views/public/, which is licensed
under the MIT license (see COPYING.jquery for more information about
the license).

Mustard ships a copy of Annotator in views/public/, which is licensed
under the MIT license (see COPYING.annotator for more information about
the license).

Mustard ships a copy of Showdown.js in views/public/, which is licensed
under a BSD-style license (see COPYING.showdown for more information about
the license).
26 changes: 26 additions & 0 deletions views/layout.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,12 @@
<head>
<title>{{tree.project.title or 'Unnamed Mustard Project'}}</title>
<link rel="stylesheet" type="text/css" href="{{tree.state.app.base_url}}public/style.css"/>
<link rel="stylesheet" href="{{tree.state.app.base_url}}public/annotator.min.css">
<link rel="shortcut icon" type="image/x-icon" href="{{tree.state.app.base_url}}public/favicon.ico"/>
<script type="text/javascript" src="{{tree.state.app.base_url}}public/jquery-1.8.2.min.js"></script>
<script type="text/javascript" src="{{tree.state.app.base_url}}public/effects.js"></script>
<script type="text/javascript" src="{{tree.state.app.base_url}}public/showdown.js"></script>
<script type="text/javascript" src="{{tree.state.app.base_url}}public/annotator-full.min.js"></script>
</head>
<body>
<div id="body">
Expand Down Expand Up @@ -69,5 +72,28 @@
</div>
</div>
<p class="center">Mustard &copy; 2012-2014 Codethink Ltd{{!' &#8212; Content &copy; %s' % tree.project.copyright if tree.project.copyright else ''}}</p>
<script>
var content = $(document.body).annotator();
content.annotator('addPlugin', 'Tags');
content.annotator('addPlugin', 'Filter');
content.annotator('addPlugin', 'Markdown');
content.annotator('addPlugin', 'Store', {
// The endpoint of the store on your server.
prefix: window.location.protocol + '//' + window.location.hostname + ':5000',

// Attach the uri of the current page to all annotations to allow search.
annotationData: {
'uri': document.URL
},

// This will perform a "search" action rather than "read" when the plugin
// loads. Will request the last 20 annotations for the current url.
// eg. /store/endpoint/search?limit=20&uri=http://this/document/only
loadFromSearch: {
'limit': 2000,
'uri': document.URL
}
});
</script>
</body>
</html>
11 changes: 11 additions & 0 deletions views/public/annotator-full.min.js

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions views/public/annotator.min.css

Large diffs are not rendered by default.

62 changes: 62 additions & 0 deletions views/public/showdown.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.