Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

We’re showing branches in this repository, but you can also compare across forks.

base fork: KayEss/beanbag
base: 76e4167be0
...
head fork: KayEss/beanbag
compare: acec12eb71
  • 3 commits
  • 4 files changed
  • 0 commit comments
  • 1 contributor
14 usr/share/beanbag/wiki/database.json
View
@@ -5,8 +5,20 @@
},
"test" : {
"" : {
- "content" : "<p>We now have some test content in here... Will this work as it should?</p>",
+ "content" : "<p>We now have some test content in here... <a href=\"#/test/one\">Will this work as it should?</a></p>\n<p>&nbsp;</p>",
"title" : "Another page (test)"
+ },
+ "one" : {
+ "" : {
+ "content" : "<p>A sub-page of test created by adding a <a href=\"#/\">link</a> and getting the <a href=\"#/test/two\">edit</a> view.</p>",
+ "title" : "One"
+ }
+ },
+ "two" : {
+ "" : {
+ "content" : "<p>Another page, another test.</p>\n<p>Just checking to see what happens.</p>",
+ "title" : "Two"
+ }
}
}
}
1  usr/share/beanbag/wiki/media/page.html
View
@@ -11,7 +11,6 @@
<link rel="stylesheet" type="text/css" href="/_/wiki.css" />
</head>
<body ng:controller="WikiController">
- <p class="crumbs"><a href="/">Home</a></p>
<ng:switch on="tab">
<form class="title" ng:switch-when="edit" ng:submit="savepage()">
<input type="text" ng:model="page.title">
16 usr/share/beanbag/wiki/media/wiki.js
View
@@ -44,6 +44,13 @@ WikiController.$inject = ['$location', '$http'];
// http://jsfiddle.net/ProLoser/nTzRA/
angular.directive('ui:tinymce', function(expression, config) {
return function(element) {
+ var callback = function() {
+ if (this.isDirty()) {
+ this.save();
+ element.trigger('change');
+ }
+ return true;
+ };
element.tinymce({
// Location of TinyMCE script
script_url: '/_/tinymce/jscripts/tiny_mce/tiny_mce.js',
@@ -53,13 +60,8 @@ angular.directive('ui:tinymce', function(expression, config) {
plugins: "inlinepopups",
// Update Textarea and Trigger change event
- handle_event_callback: function(e) {
- if (this.isDirty()) {
- this.save();
- element.trigger('change');
- }
- return true;
- }
+ onchange_callback: callback,
+ handle_event_callback: callback,
});
};
});
1  usr/share/beanbag/wiki/template.html
View
@@ -12,6 +12,7 @@
<link rel="stylesheet" type="text/css" href="/_/wiki.css" />
</head>
<body ng:controller="RouteWatcher">
+ <p class="crumbs"><a href="/">Home</a></p>
<ng:view></ng:view>
</body>
</html>

No commit comments for this range

Something went wrong with that request. Please try again.