Wiki source code of $services.localization.render('help.macros.title')
Show last authors
author | version | line-number | content |
---|---|---|---|
1 | {{include reference="Help.Code.VelocityMacros" /}} | ||
2 | |||
3 | {{velocity output="false"}} | ||
4 | #if ($hasAdmin) | ||
5 | #set ($section = 'XWiki.Extensions') | ||
6 | #if (!$xwiki.exists($section)) | ||
7 | ## Support for pre-9.2RC1 Administration Application | ||
8 | #set ($section = 'XWiki.AddExtensions') | ||
9 | #end | ||
10 | #set ($browseMacrosURL = $xwiki.getURL('XWiki.XWikiPreferences', 'admin', "section=${section}&search=macro&repo=")) | ||
11 | #else | ||
12 | #set ($browseMacrosURL = 'https://extensions.xwiki.org/xwiki/bin/view/Extension/#%7Ct=extensions&p=1&l=30&s=doc.creationDate&d=desc&category=macro') | ||
13 | #end | ||
14 | |||
15 | #set ($actionCards = [{ | ||
16 | 'title': $services.localization.render('help.macros.useMacros.title'), | ||
17 | 'description': $services.localization.render('help.macros.useMacros.description'), | ||
18 | 'tip':$services.localization.render('help.macros.useMacros.tip', ["<a href='https://extensions.xwiki.org/xwiki/bin/view/Extension/CKEditor+Integration' class='wikiexternallink'>",'</a>', $services.icon.renderHTML('cog')]), | ||
19 | 'thumbnail': 'Macro', | ||
20 | 'actions': [{ | ||
21 | 'label': $services.localization.render('help.try.label'), | ||
22 | 'type': 'success', | ||
23 | 'url': $xwiki.getURL('Sandbox.TestPage1', 'edit', 'editor=wysiwyg') | ||
24 | }] | ||
25 | }, { | ||
26 | 'title': $services.localization.render('help.macros.browseMacros.title'), | ||
27 | 'description': $services.localization.render('help.macros.browseMacros.description'), | ||
28 | 'tip': $services.localization.render('help.macros.browseMacros.tip', ["<a href='#if($xwiki.exists('XWiki.XWikiSyntaxMacrosList'))$xwiki.getURL('XWiki.XWikiSyntaxMacrosList')#{else}$xwiki.getURL('XWiki.WikiMacros')#end'>",'</a>']), | ||
29 | 'thumbnail': 'EM', | ||
30 | 'actions': [{ | ||
31 | 'label': $services.localization.render('help.browse.label'), | ||
32 | 'url': $browseMacrosURL | ||
33 | }, { | ||
34 | 'label': $services.localization.render('help.more.label'), | ||
35 | 'url': 'https://platform.xwiki.org/xwiki/bin/view/DevGuide/WikiMacroTutorial' | ||
36 | }] | ||
37 | }]) | ||
38 | |||
39 | #set ($exampleCards = [{ | ||
40 | 'title': $services.localization.render('help.macros.box.title'), | ||
41 | 'description': $services.localization.render('help.macros.box.description'), | ||
42 | 'documentation': 'https://extensions.xwiki.org/xwiki/bin/view/Extension/Box+Macro', | ||
43 | 'examples': 'Help.Macros.Box.WebHome', | ||
44 | 'thumbnail': 'Help.Macros.Box.WebHome@box.png' | ||
45 | }, { | ||
46 | 'title': $services.localization.render('help.macros.toc.title'), | ||
47 | 'description': $services.localization.render('help.macros.toc.description'), | ||
48 | 'documentation': 'https://extensions.xwiki.org/xwiki/bin/view/Extension/TOC+Macro', | ||
49 | 'examples': 'Help.Macros.ToC.WebHome', | ||
50 | 'thumbnail': 'Help.Macros.ToC.WebHome@toc.png' | ||
51 | }, { | ||
52 | 'title': $services.localization.render('help.macros.gallery.title'), | ||
53 | 'description': $services.localization.render('help.macros.gallery.description'), | ||
54 | 'documentation': 'https://extensions.xwiki.org/xwiki/bin/view/Extension/Gallery+Macro', | ||
55 | 'examples': 'Help.Macros.Gallery.WebHome', | ||
56 | 'thumbnail': 'Help.Macros.Gallery.WebHome@gallery.png' | ||
57 | }, { | ||
58 | 'title': $services.localization.render('help.macros.chart.title') , | ||
59 | 'description': $services.localization.render('help.macros.chart.description'), | ||
60 | 'documentation': 'https://extensions.xwiki.org/xwiki/bin/view/Extension/Chart+Macro', | ||
61 | 'examples': 'Help.Macros.Chart.WebHome', | ||
62 | 'thumbnail': 'Help.Macros.Chart.WebHome@chart.png' | ||
63 | }, { | ||
64 | 'title': $services.localization.render('help.macros.tree.title') , | ||
65 | 'description': $services.localization.render('help.macros.tree.description'), | ||
66 | 'documentation': 'https://extensions.xwiki.org/xwiki/bin/view/Extension/Document+Tree+Macro', | ||
67 | 'examples': 'Help.Macros.Tree.WebHome', | ||
68 | 'thumbnail': 'Help.Macros.Tree.WebHome@tree.png' | ||
69 | }, { | ||
70 | 'title': $services.localization.render('help.macros.notifications.title') , | ||
71 | 'description': $services.localization.render('help.macros.notifications.description'), | ||
72 | 'documentation': 'https://extensions.xwiki.org/xwiki/bin/view/Extension/Notifications%20Application/#HNotificationsMacro', | ||
73 | 'examples': 'Help.Macros.Notifications.WebHome', | ||
74 | 'thumbnail': 'Help.Macros.Notifications.WebHome@notifications.png' | ||
75 | }]) | ||
76 | {{/velocity}} | ||
77 | |||
78 | {{velocity}} | ||
79 | {{html clean="false"}} | ||
80 | <div class="row"> | ||
81 | #foreach ($card in $actionCards) | ||
82 | ## See http://getbootstrap.com/css/#grid-responsive-resets . | ||
83 | #if ($foreach.index > 0 && $foreach.index % 2 == 0) | ||
84 | <div class="clearfix visible-sm-block visible-md-block visible-lg-block"></div> | ||
85 | #end | ||
86 | <div class="col-xs-12 col-sm-6"> | ||
87 | #helpActionCard($card) | ||
88 | </div> | ||
89 | #end | ||
90 | </div> | ||
91 | <h3 id="HExamples">Examples</h3> | ||
92 | <p>Need help or confused with some of our macros? Check out their documentation and find out more about their functionality.</p> | ||
93 | <div class="row"> | ||
94 | #foreach ($card in $exampleCards) | ||
95 | ## See http://getbootstrap.com/css/#grid-responsive-resets . | ||
96 | #if ($foreach.index > 0 && $foreach.index % 2 == 0) | ||
97 | <div class="clearfix visible-sm-block "></div> | ||
98 | #end | ||
99 | #if ($foreach.index > 0 && $foreach.index % 3 == 0) | ||
100 | <div class="clearfix visible-md-block visible-lg-block"></div> | ||
101 | #end | ||
102 | <div class="col-xs-12 col-sm-6 col-md-4"> | ||
103 | #helpExampleCard($card) | ||
104 | </div> | ||
105 | #end | ||
106 | </div> | ||
107 | <p><a href="https://extensions.xwiki.org/xwiki/bin/view/Main/#%7Ct=extensions&p=1&l=30&s=doc.creationDate&d=desc&category=macro" class="wikiexternallink">$services.localization.render('help.macros.more')</a></p> | ||
108 | {{/html}} | ||
109 | {{/velocity}} |