index.html 27 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta http-equiv="X-UA-Compatible" content="IE=edge" />
  5. <title>Loading...</title>
  6. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  7. <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  8. <link href="vendor/bootstrap.min.css" rel="stylesheet" media="screen">
  9. <link href="vendor/prettify.css" rel="stylesheet" media="screen">
  10. <link href="css/style.css" rel="stylesheet" media="screen, print">
  11. <link href="img/favicon.ico" rel="icon" type="image/x-icon">
  12. <script src="vendor/polyfill.js"></script>
  13. </head>
  14. <body>
  15. <script id="template-sidenav" type="text/x-handlebars-template">
  16. <nav id="scrollingNav">
  17. <div class="sidenav-search">
  18. <input class="form-control search" type="text" placeholder="{{__ "Filter..."}}">
  19. <span class="search-reset">x</span>
  20. </div>
  21. <ul class="sidenav nav nav-list list">
  22. {{#each nav}}
  23. {{#if title}}
  24. {{#if isHeader}}
  25. {{#if isFixed}}
  26. <li class="nav-fixed nav-header navbar-btn nav-list-item" data-group="{{group}}"><a href="#api-{{group}}">{{underscoreToSpace title}}</a></li>
  27. {{else}}
  28. <li class="nav-header nav-list-item" data-group="{{group}}"><a href="#api-{{group}}">{{underscoreToSpace title}}</a></li>
  29. {{/if}}
  30. {{else}}
  31. <li class="{{#if hidden}}hide {{/if}}" data-group="{{group}}" data-name="{{name}}" data-version="{{version}}">
  32. <a href="#api-{{group}}-{{name}}" class="nav-list-item">{{title}}</a>
  33. </li>
  34. {{/if}}
  35. {{/if}}
  36. {{/each}}
  37. </ul>
  38. </nav>
  39. </script>
  40. <script id="template-project" type="text/x-handlebars-template">
  41. <div class="pull-left">
  42. <h1>{{name}}</h1>
  43. {{#if description}}<h2>{{{nl2br description}}}</h2>{{/if}}
  44. </div>
  45. {{#if template.withCompare}}
  46. <div class="pull-right">
  47. <div class="btn-group">
  48. <button id="version" class="btn btn-lg btn-default dropdown-toggle" data-toggle="dropdown">
  49. <strong>{{version}}</strong>&nbsp;<span class="caret"></span>
  50. </button>
  51. <ul id="versions" class="dropdown-menu open-left">
  52. <li><a id="compareAllWithPredecessor" href="#">{{__ "Compare all with predecessor"}}</a></li>
  53. <li class="divider"></li>
  54. <li class="disabled"><a href="#">{{__ "show up to version:"}}</a></li>
  55. {{#each versions}}
  56. <li class="version"><a href="#">{{this}}</a></li>
  57. {{/each}}
  58. </ul>
  59. </div>
  60. </div>
  61. {{/if}}
  62. <div class="clearfix"></div>
  63. </script>
  64. <script id="template-header" type="text/x-handlebars-template">
  65. {{#if content}}
  66. <div id="api-_">{{{content}}}</div>
  67. {{/if}}
  68. </script>
  69. <script id="template-footer" type="text/x-handlebars-template">
  70. {{#if content}}
  71. <div id="api-_footer">{{{content}}}</div>
  72. {{/if}}
  73. </script>
  74. <script id="template-generator" type="text/x-handlebars-template">
  75. {{#if template.withGenerator}}
  76. {{#if generator}}
  77. <div class="content">
  78. {{__ "Generated with"}} <a href="{{{generator.url}}}">{{{generator.name}}}</a> {{{generator.version}}} - {{{generator.time}}}
  79. </div>
  80. {{/if}}
  81. {{/if}}
  82. </script>
  83. <script id="template-sections" type="text/x-handlebars-template">
  84. <section id="api-{{group}}">
  85. <h1>{{underscoreToSpace title}}</h1>
  86. {{#if description}}
  87. <p>{{{nl2br description}}}</p>
  88. {{/if}}
  89. {{#each articles}}
  90. <div id="api-{{group}}-{{name}}">
  91. {{{article}}}
  92. </div>
  93. {{/each}}
  94. </section>
  95. </script>
  96. <script id="template-article" type="text/x-handlebars-template">
  97. <article id="api-{{article.group}}-{{article.name}}-{{article.version}}" {{#if hidden}}class="hide"{{/if}} data-group="{{article.group}}" data-name="{{article.name}}" data-version="{{article.version}}">
  98. <div class="pull-left">
  99. <h1>{{article.groupTitle}}{{#if article.title}} - {{article.title}}{{/if}}</h1>
  100. </div>
  101. {{#if template.withCompare}}
  102. <div class="pull-right">
  103. <div class="btn-group">
  104. <button class="version btn btn-default dropdown-toggle" data-toggle="dropdown">
  105. <strong>{{article.version}}</strong>&nbsp;<span class="caret"></span>
  106. </button>
  107. <ul class="versions dropdown-menu open-left">
  108. <li class="disabled"><a href="#">{{__ "compare changes to:"}}</a></li>
  109. {{#each versions}}
  110. <li class="version"><a href="#">{{this}}</a></li>
  111. {{/each}}
  112. </ul>
  113. </div>
  114. </div>
  115. {{/if}}
  116. <div class="clearfix"></div>
  117. {{#if article.deprecated}}
  118. <p class="deprecated"><span>{{__ "DEPRECATED"}}</span>
  119. {{{markdown article.deprecated.content}}}
  120. </p>
  121. {{/if}}
  122. {{#if article.description}}
  123. <p>{{{nl2br article.description}}}</p>
  124. {{/if}}
  125. <span class="type type__{{toLowerCase article.type}}">{{toLowerCase article.type}}</span>
  126. <pre class="prettyprint language-html" data-type="{{toLowerCase article.type}}"><code>{{article.url}}</code></pre>
  127. {{#if article.permission}}
  128. <p>
  129. {{__ "Permission:"}}
  130. {{#each article.permission}}
  131. {{name}}
  132. {{#if title}}
  133. <button type="button" class="btn btn-info btn-xs" data-title="{{title}}" data-content="{{nl2br description}}" data-html="true" data-toggle="popover" data-placement="right" data-trigger="hover">
  134. <span class="glyphicon glyphicon-info-sign" aria-hidden="true"></span>
  135. </button>
  136. {{/if}}
  137. {{/each}}
  138. </p>
  139. {{/if}}
  140. {{#if_gt article.examples.length compare=0}}
  141. <ul class="nav nav-tabs nav-tabs-examples">
  142. {{#each article.examples}}
  143. <li{{#if_eq @index compare=0}} class="active"{{/if_eq}}>
  144. <a href="#examples-{{../id}}-{{@index}}">{{title}}</a>
  145. </li>
  146. {{/each}}
  147. </ul>
  148. <div class="tab-content">
  149. {{#each article.examples}}
  150. <div class="tab-pane{{#if_eq @index compare=0}} active{{/if_eq}}" id="examples-{{../id}}-{{@index}}">
  151. <pre class="prettyprint language-{{type}}" data-type="{{type}}"><code>{{content}}</code></pre>
  152. </div>
  153. {{/each}}
  154. </div>
  155. {{/if_gt}}
  156. {{subTemplate "article-param-block" params=article.header _hasType=_hasTypeInHeaderFields section="header"}}
  157. {{subTemplate "article-param-block" params=article.parameter _hasType=_hasTypeInParameterFields section="parameter"}}
  158. {{subTemplate "article-param-block" params=article.success _hasType=_hasTypeInSuccessFields section="success"}}
  159. {{subTemplate "article-param-block" params=article.error _col1="Name" _hasType=_hasTypeInErrorFields section="error"}}
  160. {{subTemplate "article-sample-request" article=article id=id}}
  161. </article>
  162. </script>
  163. <script id="template-article-param-block" type="text/x-handlebars-template">
  164. {{#if params}}
  165. {{#each params.fields}}
  166. <h2>{{__ @key}}</h2>
  167. <table>
  168. <thead>
  169. <tr>
  170. <th style="width: 30%">{{#if ../_col1}}{{__ ../_col1}}{{else}}{{__ "Field"}}{{/if}}</th>
  171. {{#if ../_hasType}}<th style="width: 10%">{{__ "Type"}}</th>{{/if}}
  172. <th style="width: {{#if ../_hasType}}60%{{else}}70%{{/if}}">{{__ "Description"}}</th>
  173. </tr>
  174. </thead>
  175. <tbody>
  176. {{#each this}}
  177. <tr>
  178. <td class="code">{{{splitFill field "." "&nbsp;&nbsp;"}}}{{#if optional}} <span class="label label-optional">{{__ "optional"}}</span>{{/if}}</td>
  179. {{#if ../../_hasType}}
  180. <td>
  181. {{{type}}}
  182. </td>
  183. {{/if}}
  184. <td>
  185. {{{nl2br description}}}
  186. {{#if defaultValue}}<p class="default-value">{{__ "Default value:"}} <code>{{{defaultValue}}}</code></p>{{/if}}
  187. {{#if size}}<p class="type-size">{{__ "Size range:"}} <code>{{{size}}}</code></p>{{/if}}
  188. {{#if allowedValues}}<p class="type-size">{{__ "Allowed values:"}}
  189. {{#each allowedValues}}
  190. <code>{{{this}}}</code>{{#unless @last}}, {{/unless}}
  191. {{/each}}
  192. </p>
  193. {{/if}}
  194. </td>
  195. </tr>
  196. {{/each}}
  197. </tbody>
  198. </table>
  199. {{/each}}
  200. {{#if_gt params.examples.length compare=0}}
  201. <ul class="nav nav-tabs nav-tabs-examples">
  202. {{#each params.examples}}
  203. <li{{#if_eq @index compare=0}} class="active"{{/if_eq}}>
  204. <a href="#{{../section}}-examples-{{../id}}-{{@index}}">{{title}}</a>
  205. </li>
  206. {{/each}}
  207. </ul>
  208. <div class="tab-content">
  209. {{#each params.examples}}
  210. <div class="tab-pane{{#if_eq @index compare=0}} active{{/if_eq}}" id="{{../section}}-examples-{{../id}}-{{@index}}">
  211. <pre class="prettyprint language-{{type}}" data-type="{{type}}"><code>{{reformat content type}}</code></pre>
  212. </div>
  213. {{/each}}
  214. </div>
  215. {{/if_gt}}
  216. {{/if}}
  217. </script>
  218. <script id="template-article-sample-request" type="text/x-handlebars-template">
  219. {{#if article.sampleRequest}}
  220. <h2>{{__ "Send a Sample Request"}}</h2>
  221. <form class="form-horizontal">
  222. <fieldset>
  223. <div class="form-group">
  224. <label class="col-md-3 control-label" for="{{../id}}-sample-request-url"></label>
  225. <div class="input-group">
  226. <input id="{{../id}}-sample-request-url" type="text" class="form-control sample-request-url" value="{{article.sampleRequest.0.url}}" />
  227. <span class="input-group-addon">{{__ "url"}}</span>
  228. </div>
  229. </div>
  230. {{#if article.header}}
  231. {{#if article.header.fields}}
  232. <h3>{{__ "Headers"}}</h3>
  233. {{#each article.header.fields}}
  234. <h4><input type="radio" data-sample-request-header-group-id="sample-request-header-{{@index}}" name="{{../id}}-sample-request-header" value="{{@index}}" class="sample-request-header sample-request-switch" {{#if_eq @index compare=0}} checked{{/if_eq}} />{{@key}}</h4>
  235. <div class="{{../id}}-sample-request-header-fields{{#if_gt @index compare=0}} hide{{/if_gt}}">
  236. {{#each this}}
  237. <div class="form-group">
  238. <label class="col-md-3 control-label" for="sample-request-header-field-{{field}}">{{field}}</label>
  239. <div class="input-group">
  240. <input type="text" placeholder="{{field}}" id="sample-request-header-field-{{field}}" class="form-control sample-request-header" data-sample-request-header-name="{{field}}" data-sample-request-header-group="sample-request-header-{{@../index}}">
  241. <span class="input-group-addon">{{{type}}}</span>
  242. </div>
  243. </div>
  244. {{/each}}
  245. </div>
  246. {{/each}}
  247. {{/if}}
  248. {{/if}}
  249. {{#if article.parameter}}
  250. {{#if article.parameter.fields}}
  251. <h3>{{__ "Parameters"}}</h3>
  252. {{#each article.parameter.fields}}
  253. <h4><input type="radio" data-sample-request-param-group-id="sample-request-param-{{@index}}" name="{{../id}}-sample-request-param" value="{{@index}}" class="sample-request-param sample-request-switch" {{#if_eq @index compare=0}} checked{{/if_eq}} />{{@key}}</h4>
  254. <div class="form-group {{../id}}-sample-request-param-fields{{#if_gt @index compare=0}} hide{{/if_gt}}">
  255. {{#each this}}
  256. <label class="col-md-3 control-label" for="sample-request-param-field-{{field}}">{{field}}</label>
  257. <div class="input-group">
  258. <input id="sample-request-param-field-{{field}}" type="text" placeholder="{{field}}" class="form-control sample-request-param" data-sample-request-param-name="{{field}}" data-sample-request-param-group="sample-request-param-{{@../index}}" {{#if optional}}data-sample-request-param-optional="true"{{/if}}>
  259. <div class="input-group-addon">{{{type}}}</div>
  260. </div>
  261. {{/each}}
  262. </div>
  263. {{/each}}
  264. {{/if}}
  265. {{/if}}
  266. <div class="form-group">
  267. <div class="controls pull-right">
  268. <button class="btn btn-primary sample-request-send" data-sample-request-type="{{article.type}}">{{__ "Send"}}</button>
  269. </div>
  270. </div>
  271. <div class="form-group sample-request-response" style="display: none;">
  272. <h3>
  273. {{__ "Response"}}
  274. <button class="btn btn-default btn-xs pull-right sample-request-clear">X</button>
  275. </h3>
  276. <pre class="prettyprint language-json" data-type="json"><code class="sample-request-response-json"></code></pre>
  277. </div>
  278. </fieldset>
  279. </form>
  280. {{/if}}
  281. </script>
  282. <script id="template-compare-article" type="text/x-handlebars-template">
  283. <article id="api-{{article.group}}-{{article.name}}-{{article.version}}" {{#if hidden}}class="hide"{{/if}} data-group="{{article.group}}" data-name="{{article.name}}" data-version="{{article.version}}" data-compare-version="{{compare.version}}">
  284. <div class="pull-left">
  285. <h1>{{underscoreToSpace article.group}} - {{{showDiff article.title compare.title}}}</h1>
  286. </div>
  287. <div class="pull-right">
  288. <div class="btn-group">
  289. <button class="btn btn-success" disabled>
  290. <strong>{{article.version}}</strong> {{__ "compared to"}}
  291. </button>
  292. <button class="version btn btn-danger dropdown-toggle" data-toggle="dropdown">
  293. <strong>{{compare.version}}</strong>&nbsp;<span class="caret"></span>
  294. </button>
  295. <ul class="versions dropdown-menu open-left">
  296. <li class="disabled"><a href="#">{{__ "compare changes to:"}}</a></li>
  297. <li class="divider"></li>
  298. {{#each versions}}
  299. <li class="version"><a href="#">{{this}}</a></li>
  300. {{/each}}
  301. </ul>
  302. </div>
  303. </div>
  304. <div class="clearfix"></div>
  305. {{#if article.description}}
  306. <p>{{{showDiff article.description compare.description "nl2br"}}}</p>
  307. {{else}}
  308. {{#if compare.description}}
  309. <p>{{{showDiff "" compare.description "nl2br"}}}</p>
  310. {{/if}}
  311. {{/if}}
  312. <pre class="prettyprint language-html" data-type="{{toLowerCase article.type}}"><code>{{{showDiff article.url compare.url}}}</code></pre>
  313. {{subTemplate "article-compare-permission" article=article compare=compare}}
  314. <ul class="nav nav-tabs nav-tabs-examples">
  315. {{#each_compare_title article.examples compare.examples}}
  316. {{#if typeSame}}
  317. <li{{#if_eq index compare=0}} class="active"{{/if_eq}}>
  318. <a href="#compare-examples-{{../../article.id}}-{{index}}">{{{showDiff source.title compare.title}}}</a>
  319. </li>
  320. {{/if}}
  321. {{#if typeIns}}
  322. <li{{#if_eq index compare=0}} class="active"{{/if_eq}}>
  323. <a href="#compare-examples-{{../../article.id}}-{{index}}"><ins>{{{source.title}}}</ins></a>
  324. </li>
  325. {{/if}}
  326. {{#if typeDel}}
  327. <li{{#if_eq index compare=0}} class="active"{{/if_eq}}>
  328. <a href="#compare-examples-{{../../article.id}}-{{index}}"><del>{{{compare.title}}}</del></a>
  329. </li>
  330. {{/if}}
  331. {{/each_compare_title}}
  332. </ul>
  333. <div class="tab-content">
  334. {{#each_compare_title article.examples compare.examples}}
  335. {{#if typeSame}}
  336. <div class="tab-pane{{#if_eq index compare=0}} active{{/if_eq}}" id="compare-examples-{{../../article.id}}-{{index}}">
  337. <pre class="prettyprint language-{{source.type}}" data-type="{{source.type}}"><code>{{{showDiff source.content compare.content}}}</code></pre>
  338. </div>
  339. {{/if}}
  340. {{#if typeIns}}
  341. <div class="tab-pane{{#if_eq index compare=0}} active{{/if_eq}}" id="compare-examples-{{../../article.id}}-{{index}}">
  342. <pre class="prettyprint language-{{source.type}}" data-type="{{source.type}}"><code>{{{source.content}}}</code></pre>
  343. </div>
  344. {{/if}}
  345. {{#if typeDel}}
  346. <div class="tab-pane{{#if_eq index compare=0}} active{{/if_eq}}" id="compare-examples-{{../../article.id}}-{{index}}">
  347. <pre class="prettyprint language-{{source.type}}" data-type="{{compare.type}}"><code>{{{compare.content}}}</code></pre>
  348. </div>
  349. {{/if}}
  350. {{/each_compare_title}}
  351. </div>
  352. {{subTemplate "article-compare-param-block" source=article.parameter compare=compare.parameter _hasType=_hasTypeInParameterFields section="parameter"}}
  353. {{subTemplate "article-compare-param-block" source=article.success compare=compare.success _hasType=_hasTypeInSuccessFields section="success"}}
  354. {{subTemplate "article-compare-param-block" source=article.error compare=compare.error _col1="Name" _hasType=_hasTypeInErrorFields section="error"}}
  355. {{subTemplate "article-sample-request" article=article id=id}}
  356. </article>
  357. </script>
  358. <script id="template-article-compare-permission" type="text/x-handlebars-template">
  359. <p>
  360. {{__ "Permission:"}}
  361. {{#each_compare_list_field article.permission compare.permission field="name"}}
  362. {{#if source}}
  363. {{#if typeSame}}
  364. {{source.name}}
  365. {{#if source.title}}
  366. <button type="button" class="btn btn-info btn-xs" data-title="{{source.title}}" data-content="{{nl2br source.description}}" data-html="true" data-toggle="popover" data-placement="right" data-trigger="hover">
  367. <span class="glyphicon glyphicon-info-sign" aria-hidden="true"></span>
  368. </button>
  369. {{#unless _last}}, {{/unless}}
  370. {{/if}}
  371. {{/if}}
  372. {{#if typeIns}}
  373. <ins>{{source.name}}</ins>
  374. {{#if source.title}}
  375. <button type="button" class="btn btn-info btn-xs" data-title="{{source.title}}" data-content="{{nl2br source.description}}" data-html="true" data-toggle="popover" data-placement="right" data-trigger="hover">
  376. <span class="glyphicon glyphicon-info-sign" aria-hidden="true"></span>
  377. </button>
  378. {{#unless _last}}, {{/unless}}
  379. {{/if}}
  380. {{/if}}
  381. {{#if typeDel}}
  382. <del>{{source.name}}</del>
  383. {{#if source.title}}
  384. <button type="button" class="btn btn-info btn-xs" data-title="{{source.title}}" data-content="{{nl2br source.description}}" data-html="true" data-toggle="popover" data-placement="right" data-trigger="hover">
  385. <span class="glyphicon glyphicon-info-sign" aria-hidden="true"></span>
  386. </button>
  387. {{#unless _last}}, {{/unless}}
  388. {{/if}}
  389. {{/if}}
  390. {{else}}
  391. {{#if typeSame}}
  392. {{compare.name}}
  393. {{#if compare.title}}
  394. <button type="button" class="btn btn-info btn-xs" data-title="{{compare.title}}" data-content="{{nl2br compare.description}}" data-html="true" data-toggle="popover" data-placement="right" data-trigger="hover">
  395. <span class="glyphicon glyphicon-info-sign" aria-hidden="true"></span>
  396. </button>
  397. {{#unless _last}}, {{/unless}}
  398. {{/if}}
  399. {{/if}}
  400. {{#if typeIns}}
  401. <ins>{{compare.name}}</ins>
  402. {{#if compare.title}}
  403. <button type="button" class="btn btn-info btn-xs" data-title="{{compare.title}}" data-content="{{nl2br compare.description}}" data-html="true" data-toggle="popover" data-placement="right" data-trigger="hover">
  404. <span class="glyphicon glyphicon-info-sign" aria-hidden="true"></span>
  405. </button>
  406. {{#unless _last}}, {{/unless}}
  407. {{/if}}
  408. {{/if}}
  409. {{#if typeDel}}
  410. <del>{{compare.name}}</del>
  411. {{#if compare.title}}
  412. <button type="button" class="btn btn-info btn-xs" data-title="{{compare.title}}" data-content="{{nl2br compare.description}}" data-html="true" data-toggle="popover" data-placement="right" data-trigger="hover">
  413. <span class="glyphicon glyphicon-info-sign" aria-hidden="true"></span>
  414. </button>
  415. {{#unless _last}}, {{/unless}}
  416. {{/if}}
  417. {{/if}}
  418. {{/if}}
  419. {{/each_compare_list_field}}
  420. </p>
  421. </script>
  422. <script id="template-article-compare-param-block" type="text/x-handlebars-template">
  423. {{#if source}}
  424. {{#each_compare_keys source.fields compare.fields}}
  425. {{#if typeSame}}
  426. <h2>{{__ source.key}}</h2>
  427. <table>
  428. <thead>
  429. <tr>
  430. <th style="width: 30%">{{#if ../_col1}}{{__ ../_col1}}{{else}}{{__ "Field"}}{{/if}}</th>
  431. {{#if ../_hasType}}<th style="width: 10%">{{__ "Type"}}</th>{{/if}}
  432. <th style="width: {{#if ../_hasType}}60%{{else}}70%{{/if}}">{{__ "Description"}}</th>
  433. </tr>
  434. </thead>
  435. {{subTemplate "article-compare-param-block-body" source=source.value compare=compare.value _hasType=../_hasType}}
  436. </table>
  437. {{/if}}
  438. {{#if typeIns}}
  439. <h2><ins>{{__ source.key}}</ins></h2>
  440. <table class="ins">
  441. <thead>
  442. <tr>
  443. <th style="width: 30%">{{#if ../_col1}}{{__ ../_col1}}{{else}}{{__ "Field"}}{{/if}}</th>
  444. {{#if ../_hasType}}<th style="width: 10%">{{__ "Type"}}</th>{{/if}}
  445. <th style="width: {{#if ../_hasType}}60%{{else}}70%{{/if}}">{{__ "Description"}}</th>
  446. </tr>
  447. </thead>
  448. {{subTemplate "article-compare-param-block-body" source=source.value compare=source.value _hasType=../_hasType}}
  449. </table>
  450. {{/if}}
  451. {{#if typeDel}}
  452. <h2><del>{{__ compare.key}}</del></h2>
  453. <table class="del">
  454. <thead>
  455. <tr>
  456. <th style="width: 30%">{{#if ../_col1}}{{__ ../_col1}}{{else}}{{__ "Field"}}{{/if}}</th>
  457. {{#if ../_hasType}}<th style="width: 10%">{{__ "Type"}}</th>{{/if}}
  458. <th style="width: {{#if ../_hasType}}60%{{else}}70%{{/if}}">{{__ "Description"}}</th>
  459. </tr>
  460. </thead>
  461. {{subTemplate "article-compare-param-block-body" source=compare.value compare=compare.value _hasType=../_hasType}}
  462. </table>
  463. {{/if}}
  464. {{/each_compare_keys}}
  465. {{#if source.examples}}
  466. <ul class="nav nav-tabs nav-tabs-examples">
  467. {{#each_compare_title source.examples compare.examples}}
  468. {{#if typeSame}}
  469. <li{{#if_eq index compare=0}} class="active"{{/if_eq}}>
  470. <a href="#{{../../section}}-compare-examples-{{../../article.id}}-{{index}}">{{{showDiff source.title compare.title}}}</a>
  471. </li>
  472. {{/if}}
  473. {{#if typeIns}}
  474. <li{{#if_eq index compare=0}} class="active"{{/if_eq}}>
  475. <a href="#{{../../section}}-compare-examples-{{../../article.id}}-{{index}}"><ins>{{{source.title}}}</ins></a>
  476. </li>
  477. {{/if}}
  478. {{#if typeDel}}
  479. <li{{#if_eq index compare=0}} class="active"{{/if_eq}}>
  480. <a href="#{{../../section}}-compare-examples-{{../../article.id}}-{{index}}"><del>{{{compare.title}}}</del></a>
  481. </li>
  482. {{/if}}
  483. {{/each_compare_title}}
  484. </ul>
  485. <div class="tab-content">
  486. {{#each_compare_title source.examples compare.examples}}
  487. {{#if typeSame}}
  488. <div class="tab-pane{{#if_eq index compare=0}} active{{/if_eq}}" id="{{../../section}}-compare-examples-{{../../article.id}}-{{index}}">
  489. <pre class="prettyprint language-{{source.type}}" data-type="{{source.type}}"><code>{{{showDiff source.content compare.content}}}</code></pre>
  490. </div>
  491. {{/if}}
  492. {{#if typeIns}}
  493. <div class="tab-pane{{#if_eq index compare=0}} active{{/if_eq}}" id="{{../../section}}-compare-examples-{{../../article.id}}-{{index}}">
  494. <pre class="prettyprint language-{{source.type}}" data-type="{{source.type}}"><code>{{{source.content}}}</code></pre>
  495. </div>
  496. {{/if}}
  497. {{#if typeDel}}
  498. <div class="tab-pane{{#if_eq index compare=0}} active{{/if_eq}}" id="{{../../section}}-compare-examples-{{../../article.id}}-{{index}}">
  499. <pre class="prettyprint language-{{source.type}}" data-type="{{compare.type}}"><code>{{{compare.content}}}</code></pre>
  500. </div>
  501. {{/if}}
  502. {{/each_compare_title}}
  503. </div>
  504. {{/if}}
  505. {{/if}}
  506. </script>
  507. <script id="template-article-compare-param-block-body" type="text/x-handlebars-template">
  508. <tbody>
  509. {{#each_compare_field source compare}}
  510. {{#if typeSame}}
  511. <tr>
  512. <td class="code">
  513. {{{splitFill source.field "." "&nbsp;&nbsp;"}}}
  514. {{#if source.optional}}
  515. {{#if compare.optional}} <span class="label label-optional">{{__ "optional"}}</span>
  516. {{else}} <span class="label label-optional label-ins">{{__ "optional"}}</span>
  517. {{/if}}
  518. {{else}}
  519. {{#if compare.optional}} <span class="label label-optional label-del">{{__ "optional"}}</span>{{/if}}
  520. {{/if}}
  521. </td>
  522. {{#if source.type}}
  523. {{#if compare.type}}
  524. <td>{{{showDiff source.type compare.type}}}</td>
  525. {{else}}
  526. <td>{{{source.type}}}</td>
  527. {{/if}}
  528. {{else}}
  529. {{#if compare.type}}
  530. <td>{{{compare.type}}}</td>
  531. {{else}}
  532. {{#if ../../../../_hasType}}<td></td>{{/if}}
  533. {{/if}}
  534. {{/if}}
  535. <td>
  536. {{{showDiff source.description compare.description "nl2br"}}}
  537. {{#if source.defaultValue}}<p class="default-value">{{__ "Default value:"}} <code>{{{showDiff source.defaultValue compare.defaultValue}}}</code><p>{{/if}}
  538. </td>
  539. </tr>
  540. {{/if}}
  541. {{#if typeIns}}
  542. <tr class="ins">
  543. <td class="code">
  544. {{{splitFill source.field "." "&nbsp;&nbsp;"}}}
  545. {{#if source.optional}} <span class="label label-optional label-ins">{{__ "optional"}}</span>{{/if}}
  546. </td>
  547. {{#if source.type}}
  548. <td>{{{source.type}}}</td>
  549. {{else}}
  550. {{{typRowTd}}}
  551. {{/if}}
  552. <td>
  553. {{{nl2br source.description}}}
  554. {{#if source.defaultValue}}<p class="default-value">{{__ "Default value:"}} <code>{{{source.defaultValue}}}</code><p>{{/if}}
  555. </td>
  556. </tr>
  557. {{/if}}
  558. {{#if typeDel}}
  559. <tr class="del">
  560. <td class="code">
  561. {{{splitFill compare.field "." "&nbsp;&nbsp;"}}}
  562. {{#if compare.optional}} <span class="label label-optional label-del">{{__ "optional"}}</span>{{/if}}
  563. </td>
  564. {{#if compare.type}}
  565. <td>{{{compare.type}}}</td>
  566. {{else}}
  567. {{{typRowTd}}}
  568. {{/if}}
  569. <td>
  570. {{{nl2br compare.description}}}
  571. {{#if compare.defaultValue}}<p class="default-value">{{__ "Default value:"}} <code>{{{compare.defaultValue}}}</code><p>{{/if}}
  572. </td>
  573. </tr>
  574. {{/if}}
  575. {{/each_compare_field}}
  576. </tbody>
  577. </script>
  578. <div class="container-fluid">
  579. <div class="row">
  580. <div id="sidenav" class="span2"></div>
  581. <div id="content">
  582. <div id="project"></div>
  583. <div id="header"></div>
  584. <div id="sections"></div>
  585. <div id="footer"></div>
  586. <div id="generator"></div>
  587. </div>
  588. </div>
  589. </div>
  590. <div id="loader">
  591. <div class="spinner">
  592. <div class="spinner-container container1">
  593. <div class="circle1"></div><div class="circle2"></div><div class="circle3"></div><div class="circle4"></div>
  594. </div>
  595. <div class="spinner-container container2">
  596. <div class="circle1"></div><div class="circle2"></div><div class="circle3"></div><div class="circle4"></div>
  597. </div>
  598. <div class="spinner-container container3">
  599. <div class="circle1"></div><div class="circle2"></div><div class="circle3"></div><div class="circle4"></div>
  600. </div>
  601. <p>Loading...</p>
  602. </div>
  603. </div>
  604. <script data-main="main.js" src="vendor/require.min.js"></script>
  605. </body>
  606. </html>