You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

807 lines
26 KiB

  1. ---
  2. layout : 'default'
  3. css : 'dropdown'
  4. title : 'Dropdown'
  5. description : 'A dropdown is a hidden list of selections that a user can choose to have appear'
  6. type : 'UI Module'
  7. element : 'dropdown'
  8. elementType : 'module'
  9. themes : ['Default']
  10. ---
  11. <link rel="stylesheet/less" type="text/css" href="/build/less/definitions/modules/dropdown.less" />
  12. <script src="/javascript/dropdown.js"></script>
  13. <%- @partial('header', { tabs: 'module' }) %>
  14. <div class="main container">
  15. <div class="ui active tab" data-tab="definition">
  16. <div class="peek">
  17. <div class="ui vertical pointing secondary menu">
  18. <a class="active item">Types</a>
  19. <a class="item">Variations</a>
  20. <a class="item">States</a>
  21. </div>
  22. </div>
  23. <h2 class="ui dividing header">Types</h2>
  24. <div class="dropdown example">
  25. <h4 class="ui header">Dropdown</h4>
  26. <p>A basic dropdown has no special formatting of its own</p>
  27. <div class="ui dropdown">
  28. <div class="text">Select</div>
  29. <i class="dropdown icon"></i>
  30. <div class="menu">
  31. <div class="item">Edit</div>
  32. <div class="item">Remove</div>
  33. <div class="item">Hide</div>
  34. </div>
  35. </div>
  36. </div>
  37. <div class="dropdown example">
  38. <h4 class="ui header">Inline</h4>
  39. <p>A dropdown can be formatted to appear inline in other content</p>
  40. <div>Show me posts trending
  41. <div class="ui inline dropdown">
  42. <div class="text">today</div>
  43. <i class="dropdown icon"></i>
  44. <div class="menu">
  45. <div class="item" data-text="today">Today</div>
  46. <div class="item" data-text="this week">This Week</div>
  47. <div class="item" data-text="this month">This Month</div>
  48. </div>
  49. </div>
  50. </div>
  51. </div>
  52. <div class="dropdown example">
  53. <h4 class="ui header">Selection</h4>
  54. <p>A dropdown can point to other content to show its relationship</p>
  55. <div class="ui selection dropdown">
  56. <input type="hidden" name="gender">
  57. <div class="default text">Gender</div>
  58. <i class="dropdown icon"></i>
  59. <div class="menu">
  60. <div class="item" data-value="1">Male</div>
  61. <div class="item" data-value="0">Female</div>
  62. <div class="item" data-value="2">Unknown</div>
  63. </div>
  64. </div>
  65. </div>
  66. <div class="button example">
  67. <h4 class="ui header">Floating</h4>
  68. <p>A dropdown menu can appear to be floating below an element.</p>
  69. <div class="ui teal buttons">
  70. <div class="ui button">Save</div>
  71. <div class="ui floating dropdown icon button">
  72. <i class="dropdown icon"></i>
  73. <div class="menu">
  74. <div class="item"><i class="edit icon"></i>Edit Post</div>
  75. <div class="item"><i class="delete icon"></i>Remove Post</div>
  76. <div class="item"><i class="hide icon"></i>Hide Post</div>
  77. </div>
  78. </div>
  79. </div>
  80. </div>
  81. <div class="hover example">
  82. <h4 class="ui header">Pointing</h4>
  83. <p>A dropdown can be formatted so that its menu is pointing</p>
  84. <div class="ui compact menu">
  85. <div class="menu">
  86. <a class="active item">
  87. <i class="home icon"></i> Home
  88. </a>
  89. <div class="ui pointing dropdown link item">
  90. <i class="icon mail"></i> Messages <i class="dropdown icon"></i>
  91. <div class="menu">
  92. <a class="item"><i class="mail icon"></i>Inbox</a>
  93. <a class="item"><i class="book icon"></i>Archive</a>
  94. </div>
  95. </div>
  96. <a class="item">
  97. <i class="user icon"></i> Browse
  98. </a>
  99. <a class="item">
  100. <i class="question icon"></i> Help
  101. </a>
  102. </div>
  103. </div>
  104. </div>
  105. <div class="another button example">
  106. <div class="ui blue labeled icon top left pointing dropdown button">
  107. <i class="settings icon"></i>
  108. <span class="text">Settings</span>
  109. <div class="menu">
  110. <div class="item"><i class="edit icon"></i>Edit</div>
  111. <div class="item"><i class="delete icon"></i>Remove</div>
  112. <div class="item"><i class="hide icon"></i>Hide</div>
  113. </div>
  114. </div>
  115. <div class="ui red labeled icon top right pointing dropdown button">
  116. <i class="settings icon"></i>
  117. <span class="text">Settings</span>
  118. <div class="menu">
  119. <div class="item"><i class="edit icon"></i>Edit</div>
  120. <div class="item"><i class="delete icon"></i>Remove</div>
  121. <div class="item"><i class="hide icon"></i>Hide</div>
  122. </div>
  123. </div>
  124. </div>
  125. <div class="another button example">
  126. <div class="ui right pointing dropdown icon button">
  127. <i class="settings icon"></i>
  128. <div class="menu">
  129. <div class="item"><i class="edit icon"></i>Edit</div>
  130. <div class="item"><i class="delete icon"></i>Remove</div>
  131. <div class="item"><i class="hide icon"></i>Hide</div>
  132. </div>
  133. </div>
  134. <div class="ui left pointing dropdown icon button">
  135. <i class="settings icon"></i>
  136. <div class="menu">
  137. <div class="item"><i class="edit icon"></i>Edit</div>
  138. <div class="item"><i class="delete icon"></i>Remove</div>
  139. <div class="item"><i class="hide icon"></i>Hide</div>
  140. </div>
  141. </div>
  142. </div>
  143. <div class="example">
  144. <h4 class="ui header">Simple</h4>
  145. <p>A simple dropdown can open without javascript</p>
  146. <div class="ui compact menu">
  147. <div class="ui simple dropdown item">
  148. Dropdown <i class="dropdown icon"></i>
  149. <div class="menu">
  150. <div class="item">Choice 1</div>
  151. <div class="item">Choice 2</div>
  152. <div class="item">Choice 3</div>
  153. </div>
  154. </div>
  155. </div>
  156. </div>
  157. <h2 class="ui dividing header">Variations</h2>
  158. <div class="dropdown example">
  159. <h4 class="ui header">Fluid</h4>
  160. <p>A dropdown can take the full width of its parent</p>
  161. <div class="ui vertical menu">
  162. <a class="item">Link 1</a>
  163. <a class="item">Link 2</a>
  164. <div class="header item">All Sections</div>
  165. <div class="ui item">
  166. <div class="ui fluid selection dropdown">
  167. <div class="text">More</div>
  168. <i class="dropdown icon"></i>
  169. <div class="menu">
  170. <div class="item">Choice 1</div>
  171. <div class="item">Choice 2</div>
  172. <div class="item">Choice 3</div>
  173. </div>
  174. </div>
  175. </div>
  176. </div>
  177. </div>
  178. <h2 class="ui dividing header">States</h2>
  179. <div class="dropdown example">
  180. <h4 class="ui header">Error</h4>
  181. <p>An errored dropddown can alert a user to a problem</p>
  182. <div class="ui floating dropdown error">
  183. Dropdown <i class="dropdown icon"></i>
  184. <div class="menu">
  185. <div class="item">Choice 1</div>
  186. <div class="item">Choice 2</div>
  187. <div class="item">Choice 3</div>
  188. </div>
  189. </div>
  190. <br><br>
  191. <div class="ui selection dropdown error">
  192. Dropdown <i class="dropdown icon"></i>
  193. <div class="menu">
  194. <div class="item">Choice 1</div>
  195. <div class="item">Choice 2</div>
  196. <div class="item">Choice 3</div>
  197. </div>
  198. </div>
  199. </div>
  200. <h4 class="ui header">Simple Dropdown (No Javascript)</h4>
  201. <div class="example">
  202. <h4 class="ui header">Active</h4>
  203. <p>An active dropdown has its menu open</p>
  204. <div class="ui info message">An active state will only affect a simple dropdown. To activate a menu on a dropdown module use <code>$('.ui.dropdown').dropdown('show');</code></div>
  205. <div class="ui simple active dropdown">
  206. Dropdown <i class="dropdown icon"></i>
  207. <div class="menu">
  208. <div class="item">Choice 1</div>
  209. <div class="item">Choice 2</div>
  210. </div>
  211. </div>
  212. </div>
  213. <div class="example">
  214. <h4 class="ui header">Disabled</h4>
  215. <p>A disabled dropdown menu will not open or close</p>
  216. <div class="ui info message">A disabled state will only affect a simple dropdown. To disable a dropdown module use <code>$('.ui.dropdown').dropdown('destroy');</code></div>
  217. <div class="ui simple disabled dropdown">
  218. Dropdown <i class="dropdown icon"></i>
  219. <div class="menu">
  220. <div class="item">Choice 1</div>
  221. <div class="item">Choice 2</div>
  222. <div class="item">Choice 3</div>
  223. </div>
  224. </div>
  225. </div>
  226. </div>
  227. <div class="ui tab" data-tab="usage">
  228. <h2 class="ui dividing header">Initializing</h2>
  229. <h3 class="ui header">Initializing a dropdown</h3>
  230. <div class="code" data-label="HTML" data-type="html">
  231. <div class="ui dropdown">
  232. <div class="text">Select</div>
  233. <i class="dropdown icon"></i>
  234. <div class="menu">
  235. <div class="item" data-value="option1">Option 1</div>
  236. <div class="item" data-value="option2">Option 2</div>
  237. </div>
  238. </div>
  239. </div>
  240. <div class="code" data-label="Javascript" data-type="javascript">
  241. $('.ui.dropdown')
  242. .dropdown()
  243. ;
  244. </div>
  245. <h2 class="ui dividing header">Behavior</h2>
  246. <p>All the following <a href="/module.html#/behavior">behaviors</a> can be called using the syntax:</p>
  247. <div class="code">
  248. $('.your.element')
  249. .dropdown('behavior name', argumentOne, argumentTwo)
  250. ;
  251. </div>
  252. <table class="ui definition sortable celled table segment">
  253. <thead>
  254. <tr>
  255. <th>Behavior</th>
  256. <th>Description</th>
  257. </tr>
  258. </thead>
  259. <tbody>
  260. <tr>
  261. <td>toggle</td>
  262. <td>Toggles current visibility of dropdown</td>
  263. </tr>
  264. <tr>
  265. <td>show</td>
  266. <td>Shows dropdown</td>
  267. </tr>
  268. <tr>
  269. <td>hide</td>
  270. <td>Hides dropdown</td>
  271. </tr>
  272. <tr>
  273. <td>hide others</td>
  274. <td>Hides all other dropdowns that is not current dropdown</td>
  275. </tr>
  276. <tr>
  277. <td>restore defaults</td>
  278. <td>Restores dropdown text and value to its value on page load</td>
  279. </tr>
  280. <tr>
  281. <td>restore default text</td>
  282. <td>Restores dropdown text to its value on page load</td>
  283. </tr>
  284. <tr>
  285. <td>restore default value</td>
  286. <td>Restores dropdown value to its value on page load</td>
  287. </tr>
  288. <tr>
  289. <td>save defaults</td>
  290. <td>Saves current text and value as new defaults (for use with restore)</td>
  291. </tr>
  292. <tr>
  293. <td>set selected(value)</td>
  294. <td>Sets selected state to a given value</td>
  295. </tr>
  296. <tr>
  297. <td>set text(text)</td>
  298. <td>Sets dropdown text to a value</td>
  299. </tr>
  300. <tr>
  301. <td>set value(value)</td>
  302. <td>Sets dropdown input to value</td>
  303. </tr>
  304. <tr>
  305. <td>get text</td>
  306. <td>Returns current dropdown text</td>
  307. </tr>
  308. <tr>
  309. <td>get value</td>
  310. <td>Returns current dropdown input value</td>
  311. </tr>
  312. <tr>
  313. <td>get item(value)</td>
  314. <td>Returns DOM element that matches a given input value</td>
  315. </tr>
  316. <tr>
  317. <td>bind touch events</td>
  318. <td>Adds touch events to element</td>
  319. </tr>
  320. <tr>
  321. <td>mouse events</td>
  322. <td>Adds mouse events to element</td>
  323. </tr>
  324. <tr>
  325. <td>bind intent</td>
  326. <td>Binds a click to document to determine if you click away from a dropdown</td>
  327. </tr>
  328. <tr>
  329. <td>unbind intent</td>
  330. <td>Unbinds document intent click</td>
  331. </tr>
  332. <tr>
  333. <td>determine intent</td>
  334. <td>Returns whether event occurred inside dropdown</td>
  335. </tr>
  336. <tr>
  337. <td>determine select action(text, value)</td>
  338. <td>Triggers preset item selection action based on settings passing text/value</td>
  339. </tr>
  340. <tr>
  341. <td>set active</td>
  342. <td>Sets dropdown to active state
  343. <tr>
  344. <td>set visible</td>
  345. <td>Sets dropdown to visible state</td>
  346. </tr>
  347. <tr>
  348. <td>remove active</td>
  349. <td>rRemoves dropdown active state
  350. <tr>
  351. <td>remove visible</td>
  352. <td>Removes dropdown visible state</td>
  353. </tr>
  354. <tr>
  355. <td>is selection</td>
  356. <td>Returns whether dropdown is a selection dropdown</td>
  357. </tr>
  358. <tr>
  359. <td>is animated</td>
  360. <td>Returns whether dropdown is animated</td>
  361. </tr>
  362. <tr>
  363. <td>is visible</td>
  364. <td>Returns whether dropdown is visible</td>
  365. </tr>
  366. <tr>
  367. <td>is hidden</td>
  368. <td>Returns whether dropdown is hidden</td>
  369. </tr>
  370. </tbody>
  371. </table>
  372. </div>
  373. <div class="ui tab" data-tab="examples">
  374. <h2 class="ui dividing header">Examples</h2>
  375. <div class="dropdown example">
  376. <h3 class="ui header">Re-selecting values</h3>
  377. <p>A dropdown will automatically select on page load any menu item that includes the currently value of <code>text</code> or your dropdown's hidden input value. This is used to preserve a user's selection on page navigation and will automatically remove and default text placeholder formatting.</p>
  378. Current action: <div class="ui inline dropdown">
  379. <div class="text">Hide</div>
  380. <i class="dropdown icon"></i>
  381. <div class="menu">
  382. <div class="item">Edit</div>
  383. <div class="item">Remove</div>
  384. <div class="item">Hide</div>
  385. </div>
  386. </div>
  387. </div>
  388. <div class="dropdown example">
  389. <h3 class="ui header">Button Group</h3>
  390. <p>A <a href="/elements/button.html">button group</a> can be formatted to show additional content as a dropdown</p>
  391. <div class="ui icon buttons">
  392. <div class="ui top left pointing dropdown button">
  393. <i class="user icon"></i>
  394. <div class="menu">
  395. <div class="item"><i class="edit icon"></i>Edit User</div>
  396. <div class="item"><i class="delete icon"></i>Remove User</div>
  397. <div class="item"><i class="hide icon"></i>Make Invisible</div>
  398. </div>
  399. </div>
  400. <div class="ui top left pointing dropdown button">
  401. <i class="users icon"></i>
  402. <div class="menu">
  403. <div class="item"><i class="edit icon"></i>Edit Group</div>
  404. <div class="item"><i class="delete icon"></i>Remove Group</div>
  405. <div class="item"><i class="hide icon"></i>Hide from Group</div>
  406. </div>
  407. </div>
  408. <div class="ui top right pointing dropdown button">
  409. <i class="settings icon"></i>
  410. <div class="menu">
  411. <div class="item"><i class="edit icon"></i>Edit</div>
  412. <div class="item"><i class="delete icon"></i>Remove</div>
  413. <div class="item"><i class="hide icon"></i>Hide</div>
  414. </div>
  415. </div>
  416. </div>
  417. </div>
  418. <div class="button example">
  419. <h3 class="ui header">Combo Button</h3>
  420. <p>A <a href="/elements/button.html">button</a> can be formatted with a dropdown</p>
  421. <div class="ui teal buttons">
  422. <div class="ui button">Update Post</div>
  423. <div class="ui dropdown icon button">
  424. <i class="dropdown icon"></i>
  425. <div class="menu">
  426. <div class="item"><i class="edit icon"></i>Edit Post</div>
  427. <div class="item"><i class="delete icon"></i>Remove Post</div>
  428. <div class="item"><i class="hide icon"></i>Hide Post</div>
  429. </div>
  430. </div>
  431. </div>
  432. </div>
  433. <div class="dropdown example">
  434. <h3 class="ui header">Multiple Levels</h3>
  435. <p>A dropdown menu can also contain sub menus inside of it</p>
  436. My favorite animal breed is <div class="ui inline dropdown">
  437. <input type="hidden" name="gender">
  438. <div class="text">Shiba Inu</div>
  439. <i class="dropdown icon"></i>
  440. <div class="menu">
  441. <div class="item">
  442. <i class="dropdown icon"></i>
  443. Dogs
  444. <div class="menu">
  445. <div class="item">Shiba Inu</div>
  446. <div class="item">Poodle</div>
  447. <div class="item">Labrador</div>
  448. </div>
  449. </div>
  450. <div class="item">
  451. <i class="dropdown icon"></i>
  452. Cats
  453. <div class="menu">
  454. <div class="item">Aegean</div>
  455. <div class="item">Balinese</div>
  456. <div class="item">Persian</div>
  457. </div>
  458. </div>
  459. </div>
  460. </div>
  461. </div>
  462. <div class="hover example">
  463. <h3 class="ui header">Menu</h3>
  464. <p>A <a href="/collections/menu.html">menu</a> element can contain a dropdown</p>
  465. <div class="ui compact tiered purple inverted menu">
  466. <div class="menu">
  467. <a class="active item">
  468. <i class="icon home"></i> Home
  469. </a>
  470. <a class="ui dropdown item">
  471. <i class="icon mail"></i> Messages <i class="dropdown icon"></i>
  472. <div class="menu">
  473. <div class="item">
  474. <i class="mail icon"></i>Categories
  475. <div class="menu">
  476. <div class="item">Unread</div>
  477. <div class="item">Promotions</div>
  478. <div class="item">Updates</div>
  479. </div>
  480. </div>
  481. <div class="item"><i class="book icon"></i>Archive</div>
  482. </div>
  483. </a>
  484. <a class="item">
  485. <i class="user icon"></i> Browse
  486. </a>
  487. </div>
  488. <div class="sub menu">
  489. <a class="item">Activity Feed</a>
  490. <a class="item">Profile</a>
  491. <a class="item">Events</a>
  492. </div>
  493. </div>
  494. </div>
  495. <div class="dropdown example">
  496. <h3 class="ui header">Form</h3>
  497. <p>A dropdown can be formatted to allow selection inside a <a href="/collections/form.html">form</a></p>
  498. <div class="ui form segment">
  499. <p>Let's go ahead and get you signed up.</p>
  500. <div class="two fields">
  501. <div class="field">
  502. <label>First Name</label>
  503. <input placeholder="First Name" type="text">
  504. </div>
  505. <div class="field">
  506. <label>Last Name</label>
  507. <input placeholder="Last Name" type="text">
  508. </div>
  509. </div>
  510. <div class="field">
  511. <label>Gender</label>
  512. <div class="ui dropdown selection">
  513. <input type="hidden" name="gender">
  514. <div class="default text">...</div>
  515. <i class="dropdown icon"></i>
  516. <div class="menu">
  517. <div class="item" data-value="male">Male</div>
  518. <div class="item" data-value="female">Female</div>
  519. </div>
  520. </div>
  521. </div>
  522. </div>
  523. </div>
  524. <div class="transition example">
  525. <h3 class="ui header">Transitions</h3>
  526. <p>A dropdown can have different <a href="/modules/transition.html">transitions</a>.</p>
  527. <div class="ui teal buttons">
  528. <div class="ui button">Toggle</div>
  529. <div class="ui floating dropdown icon button">
  530. <i class="dropdown icon"></i>
  531. <div class="menu">
  532. <div class="item" data-value="horizontal flip">Horizontal Flip</div>
  533. <div class="item" data-value="fade up">Fade Up</div>
  534. <div class="item" data-value="scale">Scale</div>
  535. </div>
  536. </div>
  537. </div>
  538. </div>
  539. </div>
  540. <div class="ui tab" data-tab="settings">
  541. <h3 class="ui header">
  542. Dropdown Settings
  543. <div class="sub header">Dropdown settings modify the dropdown's behavior</div>
  544. </h3>
  545. <table class="ui celled sortable definition table segment">
  546. <thead>
  547. <tr>
  548. <th>Setting</th>
  549. <th class="four wide">Default</th>
  550. <th>Description</th>
  551. </tr>
  552. </thead>
  553. <tbody>
  554. <tr>
  555. <td>on</td>
  556. <td>click</td>
  557. <td>Event used to trigger dropdown (Hover, Click)</td>
  558. </tr>
  559. <tr>
  560. <td>delay</td>
  561. <td>
  562. <div class="code">
  563. delay: {
  564. show: 50,
  565. hide: 300
  566. }
  567. </div>
  568. </td>
  569. <td>Time in milliseconds to debounce show or hide behavior when <code>on: hover</code> is used.</td>
  570. </tr>
  571. <tr>
  572. <td>transition</td>
  573. <td>
  574. slide down
  575. </td>
  576. <td>Named transition to use when animating menu in and out. Fade and slide down are available without including <a href="/modules/transition.html">ui transitions</a></td>
  577. </tr>
  578. <tr>
  579. <td>duration</td>
  580. <td>
  581. 250
  582. </td>
  583. <td>Duration of animation events</td>
  584. </tr>
  585. <tr>
  586. <td>action</td>
  587. <td>auto</td>
  588. <td>Sets a default action to occur.
  589. <div class="ui vertical divided list">
  590. <div class="item">
  591. <div class="header">activate</div>
  592. <div class="description">Most likely action will be determined by type of dropdown, for example a selection dropdown will automatically use updateForm</div>
  593. </div>
  594. <div class="item">
  595. <div class="header">combo</div>
  596. <div class="description">changes text of previous element matching text selector</div>
  597. </div>
  598. <div class="item">
  599. <div class="header">select</div>
  600. <div class="description">activates menu item but does not change text</div>
  601. </div>
  602. <div class="item">
  603. <div class="header">nothing</div>
  604. <div class="description">no action occurs</div>
  605. </div>
  606. <div class="item">
  607. <div class="header">hide</div>
  608. <div class="description">Dropdown menu is hidden</div>
  609. </div>
  610. <div class="item">
  611. <div class="header">function(){}</div>
  612. <div class="description">custom function is executed</div>
  613. </div>
  614. </div>
  615. </tr>
  616. </tbody>
  617. </table>
  618. <div class="ui horizontal section divider"><i class="icon setting"></i></div>
  619. <h3 class="ui header">
  620. Callbacks
  621. <div class="sub header">Callbacks specify a function to occur after a specific behavior.</div>
  622. </h3>
  623. <table class="ui celled sortable definition table segment">
  624. <thead>
  625. <tr>
  626. <th class="four wide">Setting</th>
  627. <th>Context</th>
  628. <th>Description</th>
  629. </tr>
  630. </thead>
  631. <tbody>
  632. <tr>
  633. <td>onChange(value, text)</td>
  634. <td>Dropdown</td>
  635. <td>Is called after a dropdown item is selected. receives the name and value of selection.</td>
  636. </tr>
  637. <tr>
  638. <td>onShow</td>
  639. <td>Dropdown</td>
  640. <td>Is called after a dropdown is shown.</td>
  641. </tr>
  642. <tr>
  643. <td>onHide</td>
  644. <td>Dropdown</td>
  645. <td>Is called after a dropdown is hidden.</td>
  646. </tr>
  647. </tbody>
  648. </table>
  649. <h3 class="ui header">
  650. DOM Settings
  651. <div class="sub header">DOM settings specify how this module should interface with the DOM</div>
  652. </h3>
  653. <table class="ui celled sortable definition table segment">
  654. <thead>
  655. <tr>
  656. <th>Setting</th>
  657. <th class="four wide">Default</th>
  658. <th>Description</th>
  659. </tr>
  660. </thead>
  661. <tbody>
  662. <tr>
  663. <td>namespace</td>
  664. <td>dropdown</td>
  665. <td>Event namespace. Makes sure module teardown does not effect other events attached to an element.</td>
  666. </tr>
  667. <tr>
  668. <td>selector</td>
  669. <td colspan="2">
  670. <div class="code">
  671. selector : {
  672. input : '> input[type="hidden"]',
  673. item : '.menu > .item',
  674. menu : '.menu',
  675. text : '> .text'
  676. }
  677. </div>
  678. </td>
  679. </tr>
  680. <tr>
  681. <td>metadata</td>
  682. <td colspan="2">
  683. <div class="code">
  684. metadata: {
  685. text : 'text',
  686. value : 'value'
  687. }
  688. </div>
  689. </td>
  690. </tr>
  691. <tr>
  692. <td>className</td>
  693. <td colspan="2">
  694. <div class="code">
  695. className : {
  696. active : 'active',
  697. disabled : 'disabled',
  698. placeholder : 'default',
  699. visible : 'visible'
  700. }
  701. </div>
  702. </td>
  703. </tr>
  704. </tbody>
  705. </table>
  706. <h3 class="ui header">
  707. Debug Settings
  708. <div class="sub header">Debug settings controls debug output to the console</div>
  709. </h3>
  710. <table class="ui celled sortable definition table segment">
  711. <thead>
  712. <tr>
  713. <th>Setting</th>
  714. <th class="four wide">Default</th>
  715. <th>Description</th>
  716. </tr>
  717. </thead>
  718. <tbody>
  719. <tr>
  720. <td>name</td>
  721. <td>Dropdown</td>
  722. <td>Name used in debug logs</td>
  723. </tr>
  724. <tr>
  725. <td>debug</td>
  726. <td>True</td>
  727. <td>Provides standard debug output to console</td>
  728. </tr>
  729. <tr>
  730. <td>performance</td>
  731. <td>True</td>
  732. <td>Provides standard debug output to console</td>
  733. </tr>
  734. <tr>
  735. <td>verbose</td>
  736. <td>True</td>
  737. <td>Provides ancillary debug output to console</td>
  738. </tr>
  739. <tr>
  740. <td>error</td>
  741. <td colspan="2">
  742. <div class="code">
  743. error : {
  744. action : 'You called a dropdown action that was not defined',
  745. method : 'The method you called is not defined.',
  746. transition : 'The requested transition was not found'
  747. }
  748. </div>
  749. </td>
  750. </tr>
  751. </tbody>
  752. </table>
  753. </div>
  754. </div>