Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
officejs
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
officejs
Commits
27df6f8c
Commit
27df6f8c
authored
May 18, 2012
by
Sebastien Robin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
show how we can directly define gadget to define directly in index.html
parent
06cbf15b
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
4 deletions
+6
-4
poc/renderjs/index.html
poc/renderjs/index.html
+3
-3
poc/renderjs/js/renderjs_poc.js
poc/renderjs/js/renderjs_poc.js
+3
-1
No files found.
poc/renderjs/index.html
View file @
27df6f8c
...
...
@@ -25,14 +25,14 @@
<div
class=
"wrapper"
>
<!-- not needed? up to you: http://camendesign.com/code/developpeurs_sans_frontieres -->
<!-- here we show example of gadget definition directly defined in html-->
<header>
<div
id=
"gadget-header"
/>
<div
id=
"gadget-header"
gadget=
"gadget/cached_navigation.html"
/>
</header>
<article>
<!-- here we will show example of adding gadget through javascript code-->
<div
id=
"gadget-article"
>
</article>
</div>
...
...
poc/renderjs/js/renderjs_poc.js
View file @
27df6f8c
/* trigger when page is ready */
$
(
document
).
ready
(
function
(){
RenderJs
.
TabbularGadget
.
addNewTabGadget
(
'
gadget-header
'
,
'
gadget/cached_navigation.html
'
);
// Only bootstrap a div wich define a gadget
RenderJs
.
bootstrap
(
$
(
"
#gadget-header
"
));
// Here we add gadget to an existing div with javascript code
RenderJs
.
TabbularGadget
.
addNewTabGadget
(
'
gadget-article
'
,
'
gadget/article.html
'
);
});
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment