fomantic-ui 2.10.0-beta.6 → 2.10.0-beta.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (227) hide show
  1. package/.eslintrc.js +0 -10
  2. package/README.md +4 -5
  3. package/changelog-setup.js +64 -70
  4. package/dist/components/accordion.css +1 -1
  5. package/dist/components/accordion.js +94 -131
  6. package/dist/components/accordion.min.css +1 -1
  7. package/dist/components/accordion.min.js +2 -2
  8. package/dist/components/ad.css +1 -1
  9. package/dist/components/ad.min.css +1 -1
  10. package/dist/components/api.js +152 -205
  11. package/dist/components/api.min.js +2 -2
  12. package/dist/components/breadcrumb.css +1 -1
  13. package/dist/components/breadcrumb.min.css +1 -1
  14. package/dist/components/button.css +1 -1
  15. package/dist/components/button.min.css +1 -1
  16. package/dist/components/calendar.css +1 -1
  17. package/dist/components/calendar.js +305 -341
  18. package/dist/components/calendar.min.css +1 -1
  19. package/dist/components/calendar.min.js +2 -2
  20. package/dist/components/card.css +1 -1
  21. package/dist/components/card.min.css +1 -1
  22. package/dist/components/checkbox.css +1 -1
  23. package/dist/components/checkbox.js +76 -116
  24. package/dist/components/checkbox.min.css +1 -1
  25. package/dist/components/checkbox.min.js +2 -2
  26. package/dist/components/comment.css +1 -1
  27. package/dist/components/comment.min.css +1 -1
  28. package/dist/components/container.css +1 -1
  29. package/dist/components/container.min.css +1 -1
  30. package/dist/components/dimmer.css +1 -1
  31. package/dist/components/dimmer.js +58 -91
  32. package/dist/components/dimmer.min.css +1 -1
  33. package/dist/components/dimmer.min.js +2 -2
  34. package/dist/components/divider.css +1 -1
  35. package/dist/components/divider.min.css +1 -1
  36. package/dist/components/dropdown.css +1 -1
  37. package/dist/components/dropdown.js +674 -977
  38. package/dist/components/dropdown.min.css +1 -1
  39. package/dist/components/dropdown.min.js +2 -2
  40. package/dist/components/embed.css +1 -1
  41. package/dist/components/embed.js +80 -127
  42. package/dist/components/embed.min.css +1 -1
  43. package/dist/components/embed.min.js +2 -2
  44. package/dist/components/emoji.css +1 -1
  45. package/dist/components/emoji.min.css +1 -1
  46. package/dist/components/feed.css +1 -1
  47. package/dist/components/feed.min.css +1 -1
  48. package/dist/components/flag.css +1 -1
  49. package/dist/components/flag.min.css +1 -1
  50. package/dist/components/flyout.css +1 -1
  51. package/dist/components/flyout.js +192 -274
  52. package/dist/components/flyout.min.css +1 -1
  53. package/dist/components/flyout.min.js +2 -2
  54. package/dist/components/form.css +1 -1
  55. package/dist/components/form.js +325 -429
  56. package/dist/components/form.min.css +1 -1
  57. package/dist/components/form.min.js +2 -2
  58. package/dist/components/grid.css +1 -1
  59. package/dist/components/grid.min.css +1 -1
  60. package/dist/components/header.css +1 -1
  61. package/dist/components/header.min.css +1 -1
  62. package/dist/components/icon.css +1 -1
  63. package/dist/components/icon.min.css +1 -1
  64. package/dist/components/image.css +1 -1
  65. package/dist/components/image.min.css +1 -1
  66. package/dist/components/input.css +1 -1
  67. package/dist/components/input.min.css +1 -1
  68. package/dist/components/item.css +1 -1
  69. package/dist/components/item.min.css +1 -1
  70. package/dist/components/label.css +1 -1
  71. package/dist/components/label.min.css +1 -1
  72. package/dist/components/list.css +1 -1
  73. package/dist/components/list.min.css +1 -1
  74. package/dist/components/loader.css +1 -1
  75. package/dist/components/loader.min.css +1 -1
  76. package/dist/components/menu.css +1 -1
  77. package/dist/components/menu.min.css +1 -1
  78. package/dist/components/message.css +1 -1
  79. package/dist/components/message.min.css +1 -1
  80. package/dist/components/modal.css +1 -1
  81. package/dist/components/modal.js +221 -313
  82. package/dist/components/modal.min.css +1 -1
  83. package/dist/components/modal.min.js +2 -2
  84. package/dist/components/nag.css +1 -1
  85. package/dist/components/nag.js +67 -97
  86. package/dist/components/nag.min.css +1 -1
  87. package/dist/components/nag.min.js +2 -2
  88. package/dist/components/placeholder.css +1 -1
  89. package/dist/components/placeholder.min.css +1 -1
  90. package/dist/components/popup.css +1 -1
  91. package/dist/components/popup.js +185 -254
  92. package/dist/components/popup.min.css +1 -1
  93. package/dist/components/popup.min.js +2 -2
  94. package/dist/components/progress.css +1 -1
  95. package/dist/components/progress.js +103 -138
  96. package/dist/components/progress.min.css +1 -1
  97. package/dist/components/progress.min.js +2 -2
  98. package/dist/components/rail.css +1 -1
  99. package/dist/components/rail.min.css +1 -1
  100. package/dist/components/rating.css +1 -1
  101. package/dist/components/rating.js +89 -139
  102. package/dist/components/rating.min.css +1 -1
  103. package/dist/components/rating.min.js +2 -2
  104. package/dist/components/reset.css +1 -1
  105. package/dist/components/reset.min.css +1 -1
  106. package/dist/components/reveal.css +1 -1
  107. package/dist/components/reveal.min.css +1 -1
  108. package/dist/components/search.css +1 -1
  109. package/dist/components/search.js +253 -352
  110. package/dist/components/search.min.css +1 -1
  111. package/dist/components/search.min.js +2 -2
  112. package/dist/components/segment.css +1 -1
  113. package/dist/components/segment.min.css +1 -1
  114. package/dist/components/shape.css +1 -1
  115. package/dist/components/shape.js +157 -223
  116. package/dist/components/shape.min.css +1 -1
  117. package/dist/components/shape.min.js +2 -2
  118. package/dist/components/sidebar.css +1 -1
  119. package/dist/components/sidebar.js +122 -163
  120. package/dist/components/sidebar.min.css +1 -1
  121. package/dist/components/sidebar.min.js +2 -2
  122. package/dist/components/site.css +1 -1
  123. package/dist/components/site.js +38 -57
  124. package/dist/components/site.min.css +1 -1
  125. package/dist/components/site.min.js +2 -2
  126. package/dist/components/slider.css +1 -1
  127. package/dist/components/slider.js +242 -325
  128. package/dist/components/slider.min.css +1 -1
  129. package/dist/components/slider.min.js +2 -2
  130. package/dist/components/state.js +68 -98
  131. package/dist/components/state.min.js +2 -2
  132. package/dist/components/statistic.css +1 -1
  133. package/dist/components/statistic.min.css +1 -1
  134. package/dist/components/step.css +1 -1
  135. package/dist/components/step.min.css +1 -1
  136. package/dist/components/sticky.css +1 -1
  137. package/dist/components/sticky.js +116 -159
  138. package/dist/components/sticky.min.css +1 -1
  139. package/dist/components/sticky.min.js +2 -2
  140. package/dist/components/tab.css +1 -1
  141. package/dist/components/tab.js +168 -233
  142. package/dist/components/tab.min.css +1 -1
  143. package/dist/components/tab.min.js +2 -2
  144. package/dist/components/table.css +1 -1
  145. package/dist/components/table.min.css +1 -1
  146. package/dist/components/text.css +1 -1
  147. package/dist/components/text.min.css +1 -1
  148. package/dist/components/toast.css +1 -1
  149. package/dist/components/toast.js +99 -132
  150. package/dist/components/toast.min.css +1 -1
  151. package/dist/components/toast.min.js +2 -2
  152. package/dist/components/transition.css +1 -1
  153. package/dist/components/transition.js +86 -141
  154. package/dist/components/transition.min.css +1 -1
  155. package/dist/components/transition.min.js +2 -2
  156. package/dist/components/visibility.js +134 -210
  157. package/dist/components/visibility.min.js +2 -2
  158. package/dist/semantic.css +53 -53
  159. package/dist/semantic.js +4100 -5721
  160. package/dist/semantic.min.css +1 -1
  161. package/dist/semantic.min.js +2 -2
  162. package/examples/assets/show-examples.js +2 -4
  163. package/gulpfile.js +5 -7
  164. package/package.json +1 -1
  165. package/scripts/nightly-version.js +7 -10
  166. package/src/definitions/behaviors/api.js +151 -204
  167. package/src/definitions/behaviors/form.js +324 -428
  168. package/src/definitions/behaviors/state.js +67 -97
  169. package/src/definitions/behaviors/visibility.js +133 -209
  170. package/src/definitions/globals/site.js +37 -56
  171. package/src/definitions/modules/accordion.js +93 -130
  172. package/src/definitions/modules/calendar.js +304 -340
  173. package/src/definitions/modules/checkbox.js +75 -115
  174. package/src/definitions/modules/dimmer.js +57 -90
  175. package/src/definitions/modules/dropdown.js +673 -976
  176. package/src/definitions/modules/embed.js +79 -126
  177. package/src/definitions/modules/flyout.js +191 -273
  178. package/src/definitions/modules/modal.js +220 -312
  179. package/src/definitions/modules/nag.js +66 -96
  180. package/src/definitions/modules/popup.js +184 -253
  181. package/src/definitions/modules/progress.js +102 -137
  182. package/src/definitions/modules/rating.js +88 -138
  183. package/src/definitions/modules/search.js +252 -351
  184. package/src/definitions/modules/shape.js +156 -222
  185. package/src/definitions/modules/sidebar.js +121 -162
  186. package/src/definitions/modules/slider.js +241 -324
  187. package/src/definitions/modules/sticky.js +115 -158
  188. package/src/definitions/modules/tab.js +167 -232
  189. package/src/definitions/modules/toast.js +98 -131
  190. package/src/definitions/modules/transition.js +85 -140
  191. package/tasks/admin/components/create.js +88 -108
  192. package/tasks/admin/components/init.js +26 -32
  193. package/tasks/admin/components/update.js +46 -53
  194. package/tasks/admin/distributions/create.js +71 -101
  195. package/tasks/admin/distributions/init.js +27 -33
  196. package/tasks/admin/distributions/update.js +45 -52
  197. package/tasks/admin/register.js +11 -15
  198. package/tasks/build/assets.js +14 -18
  199. package/tasks/build/css.js +54 -63
  200. package/tasks/build/javascript.js +45 -53
  201. package/tasks/build.js +4 -6
  202. package/tasks/check-install.js +5 -7
  203. package/tasks/clean.js +2 -4
  204. package/tasks/collections/admin.js +13 -15
  205. package/tasks/collections/build.js +6 -8
  206. package/tasks/collections/docs.js +2 -4
  207. package/tasks/collections/install.js +2 -4
  208. package/tasks/collections/rtl.js +2 -4
  209. package/tasks/collections/various.js +2 -4
  210. package/tasks/config/admin/github.js +7 -9
  211. package/tasks/config/admin/templates/css-package.js +1 -3
  212. package/tasks/config/admin/templates/less-package.js +1 -3
  213. package/tasks/config/npm/gulpfile.js +4 -6
  214. package/tasks/config/project/config.js +22 -30
  215. package/tasks/config/project/install.js +56 -70
  216. package/tasks/config/project/release.js +6 -8
  217. package/tasks/config/tasks.js +8 -12
  218. package/tasks/config/user.js +13 -17
  219. package/tasks/docs/build.js +26 -31
  220. package/tasks/docs/metadata.js +24 -30
  221. package/tasks/docs/serve.js +20 -26
  222. package/tasks/install.js +71 -98
  223. package/tasks/rtl/build.js +2 -4
  224. package/tasks/rtl/watch.js +2 -4
  225. package/tasks/watch.js +9 -11
  226. package/test/meteor/fonts.js +1 -2
  227. package/test/modules/module.spec.js +16 -18
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * # Fomantic-UI 2.10.0-beta.6+42a411a - Modal
2
+ * # Fomantic-UI 2.10.0-beta.8+62e258f - Modal
3
3
  * https://github.com/fomantic/Fomantic-UI/
4
4
  *
5
5
  *
@@ -1,5 +1,5 @@
1
1
  /*
2
- * # Fomantic UI - 2.10.0-beta.6+42a411a
2
+ * # Fomantic UI - 2.10.0-beta.8+62e258f
3
3
  * https://github.com/fomantic/Fomantic-UI
4
4
  * https://fomantic-ui.com/
5
5
  *
@@ -8,4 +8,4 @@
8
8
  * https://opensource.org/licenses/MIT
9
9
  *
10
10
  */
11
- !function(V,X,_){"use strict";function Q(e){return"function"==typeof e&&"number"!=typeof e.nodeType}X=void 0!==X&&X.Math===Math?X:globalThis,V.fn.modal=function(L){var z,e=V(this),q=V(X),I=V(_),B=V("body"),W=Date.now(),j=[],P=L,K="string"==typeof P,R=[].slice.call(arguments,1),U=function(e,t){var n;return 0<=[X,_].indexOf(e)?n=B:0===(n=V(t.document).find(e)).length&&(n=t.frameElement?U(e,t.parent):B),n};return e.each(function(){var n,o,a,e,i,t,s,r,c,l,d,u=V.isPlainObject(L)?V.extend(!0,{},V.fn.modal.settings,L):V.extend({},V.fn.modal.settings),f=u.selector,m=u.className,h=u.namespace,g=u.fields,v=u.error,p="."+h,b="module-"+h,y=V(this),k=U(u.context,X),x=k[0]===B[0],w=y.find(f.closeIcon),C=y.hasClass("modal"),S=this,M=C?y.data(b):void 0,A=!1,D="",T="",H=!1,F=!1,N=!1,O=!1,E={initialize:function(){var a;E.create.id(),C||(E.create.modal(),Q(u.onHidden)||(u.onHidden=function(){E.destroy(),y.remove()})),y.addClass(u.class),""!==u.title&&y.find(f.title).html(E.helpers.escape(u.title,u)).addClass(u.classTitle),""!==u.content&&y.find(f.content).html(E.helpers.escape(u.content,u)).addClass(u.classContent),E.has.configActions()&&(0===(a=y.find(f.actions).addClass(u.classActions)).length?a=V("<div/>",{class:m.actions+" "+(u.classActions||"")}).appendTo(y):a.empty(),u.actions.forEach(function(e){var t=e[g.icon]?"<i "+(e[g.text]?'aria-hidden="true"':"")+' class="'+E.helpers.escape(e[g.icon])+' icon"></i>':"",n=E.helpers.escape(e[g.text]||"",u),i=E.helpers.escape(e[g.class]||""),o=e[g.click]&&Q(e[g.click])?e[g.click]:function(){};a.append(V("<button/>",{html:t+n,"aria-label":(e[g.text]||e[g.icon]||"").replace(/<[^>]+(>|$)/g,""),class:m.button+" "+i,on:{click:function(){var e=V(this);e.is(f.approve)||e.is(f.deny)||!1===o.call(S,y)||E.hide()}}}))})),E.cache={},E.verbose("Initializing dimmer",k),E.create.dimmer(),u.allowMultiple&&E.create.innerDimmer(),u.centered||y.addClass("top aligned"),E.refreshModals(),E.bind.events(),E.observeChanges(),E.instantiate(),u.autoShow&&E.show()},instantiate:function(){E.verbose("Storing instance of modal"),M=E,y.data(b,M)},create:{modal:function(){var e;y=V("<div/>",{class:m.modal,role:"dialog","aria-modal":!0}),u.closeIcon&&(w=V("<i/>",{class:m.close,role:"button",tabindex:0,"aria-label":u.text.close}),y.append(w)),""!==u.title&&(e="_"+E.get.id()+"title",y.attr("aria-labelledby",e),V("<div/>",{class:m.title,id:e}).appendTo(y)),""!==u.content&&(e="_"+E.get.id()+"desc",y.attr("aria-describedby",e),V("<div/>",{class:m.content,id:e}).appendTo(y)),E.has.configActions()&&V("<div/>",{class:m.actions}).appendTo(y),k.append(y),S=y[0]},dimmer:function(){var e={debug:u.debug,dimmerName:"modals"},e=V.extend(!0,e,u.dimmerSettings);void 0===V.fn.dimmer?E.error(v.dimmer):(E.debug("Creating dimmer"),i=k.dimmer(e),H=E.is.scrolling(),u.detachable?(E.verbose("Modal is detachable, moving content into dimmer"),i.dimmer("add content",y)):E.set.undetached(),t=i.dimmer("get dimmer"))},id:function(){l=(Math.random().toString(16)+"000000000").slice(2,10),c="."+l,E.verbose("Creating unique id for element",l)},innerDimmer:function(){0===y.find(f.dimmer).length&&V("<div/>",{class:m.innerDimmer}).prependTo(y)}},destroy:function(){d&&d.disconnect(),E.verbose("Destroying previous modal"),y.removeData(b).off(p),q.off(c),k.off(c),t.off(c),w.off(c),n&&n.off(c),k.dimmer("destroy")},observeChanges:function(){"MutationObserver"in X&&((d=new MutationObserver(function(e){function o(e){for(var t=[],n=0,i=e.length;n<i;n++)Array.prototype.push.apply(t,o(e[n].childNodes)),t.push(e[n]);return t}var n=!1,i=!1,a=!0;e.every(function(e){var t;return"attributes"===e.type?O&&("disabled"===e.attributeName||0<V(e.target).find(":input").addBack(":input").filter(":visible").length)&&(i=!0):(n=!0,t=V(o(e.addedNodes)).filter("a[href], [tabindex], :input:enabled").filter(":visible"),e=V(o(e.removedNodes)).filter("a[href], [tabindex], :input"),(0<t.length||0<e.length)&&(i=!0,(0<t.filter(":input").length||0<e.filter(":input").length)&&(a=!1))),!i}),n&&u.observeChanges&&(E.debug("DOM tree modified, refreshing"),E.refresh()),i&&E.refreshInputs(a)})).observe(S,{attributeFilter:["class","disabled"],attributes:!0,childList:!0,subtree:!0}),E.debug("Setting up mutation observer",d))},refresh:function(){E.remove.scrolling(),E.cacheSizes(),E.can.useFlex()||E.set.modalOffset(),E.set.screenHeight(),E.set.type()},refreshModals:function(){a=y.siblings(f.modal),o=a.add(y)},refreshInputs:function(e){n&&n.off("keydown"+c),0===(n=y.find("a[href], [tabindex], :input:enabled").filter(":visible").filter(function(){return 0===V(this).closest(".disabled").length})).filter(":input").length?(n=y.add(n),y.attr("tabindex",-1)):y.removeAttr("tabindex"),n.first().on("keydown"+c,E.event.inputKeyDown.first),n.last().on("keydown"+c,E.event.inputKeyDown.last),!e&&u.autofocus&&0===n.filter(":focus").length&&E.set.autofocus()},attachEvents:function(e,t){var n=V(e);t=Q(E[t])?E[t]:E.toggle,0<n.length?(E.debug("Attaching modal events to element",e,t),n.off(p).on("click"+p,t)):E.error(v.notFound,e)},bind:{events:function(){E.verbose("Attaching events"),y.on("click"+p,f.close,E.event.close).on("click"+p,f.approve,E.event.approve).on("click"+p,f.deny,E.event.deny),w.on("keyup"+c,E.event.closeKeyUp),q.on("resize"+c,E.event.resize).on("focus"+c,E.event.focus),k.on("click"+c,E.event.click)},scrollLock:function(){i[0].addEventListener("touchmove",E.event.preventScroll,{passive:!1})}},unbind:{scrollLock:function(){i[0].removeEventListener("touchmove",E.event.preventScroll,{passive:!1})}},get:{id:function(){return l},element:function(){return y},settings:function(){return u}},event:{approve:function(){A||!1===u.onApprove.call(S,V(this))?E.verbose("Approve callback returned false cancelling hide"):(A=!0,E.hide(function(){A=!1}))},preventScroll:function(e){-1!==e.target.className.indexOf("dimmer")&&e.preventDefault()},deny:function(){A||!1===u.onDeny.call(S,V(this))?E.verbose("Deny callback returned false cancelling hide"):(A=!0,E.hide(function(){A=!1}))},close:function(){E.hide()},closeKeyUp:function(e){e=e.which;e!==u.keys.enter&&e!==u.keys.space||!y.hasClass(m.front)||E.hide()},inputKeyDown:{first:function(e){e.which===u.keys.tab&&e.shiftKey&&(n.last().trigger("focus"),e.preventDefault())},last:function(e){e.which!==u.keys.tab||e.shiftKey||(n.first().trigger("focus"),e.preventDefault())}},mousedown:function(e){var t=V(e.target),n=E.is.rtl();(s=0<t.closest(f.modal).length)&&E.verbose("Mouse down event registered inside the modal"),(r=E.is.scrolling()&&(!n&&q.outerWidth()-u.scrollbarWidth<=e.clientX||n&&u.scrollbarWidth>=e.clientX))&&E.verbose("Mouse down event registered inside the scrollbar")},mouseup:function(e){if(u.closable)if(s)E.debug("Dimmer clicked but mouse down was initially registered inside the modal");else if(r)E.debug("Dimmer clicked but mouse down was initially registered inside the scrollbar");else{var t=0<V(e.target).closest(f.modal).length,e=V.contains(_.documentElement,e.target);if(!t&&e&&E.is.active()&&y.hasClass(m.front)){if(E.debug("Dimmer clicked, hiding all modals"),u.allowMultiple){if(!E.hideAll())return}else if(!E.hide())return;E.remove.clickaway()}}else E.verbose("Dimmer clicked but closable setting is disabled")},debounce:function(e,t){clearTimeout(E.timer),E.timer=setTimeout(function(){e()},t)},keyboard:function(e){e.which===u.keys.escape&&(u.closable?(E.debug("Escape key pressed hiding modal"),y.hasClass(m.front)&&E.hide()):E.debug("Escape key pressed, but closable is set to false"),e.preventDefault())},resize:function(){i.dimmer("is active")&&(E.is.animating()||E.is.active())&&requestAnimationFrame(E.refresh)},focus:function(){N=!0},click:function(e){N&&_.activeElement!==e.target&&i.dimmer("is active")&&E.is.active()&&u.autofocus&&0===V(_.activeElement).closest(f.modal).length&&requestAnimationFrame(E.set.autofocus),N=!1}},toggle:function(){E.is.active()||E.is.animating()?E.hide():E.show()},show:function(e){e=Q(e)?e:function(){},E.refreshModals(),E.set.dimmerSettings(),E.set.dimmerStyles(),E.showModal(e)},hide:function(e){return e=Q(e)?e:function(){},E.refreshModals(),E.hideModal(e)},showModal:function(e){e=Q(e)?e:function(){},E.is.animating()||!E.is.active()?!1===u.onShow.call(S)?E.verbose("Show callback returned false cancelling show"):(F=E.has.scrollbar(),E.showDimmer(),E.cacheSizes(),F&&E.set.bodyMargin(),E.can.useFlex()?E.remove.legacy():(E.set.legacy(),E.set.modalOffset(),E.debug("Using non-flex legacy modal positioning.")),E.set.screenHeight(),E.set.type(),E.set.clickaway(),!u.allowMultiple&&E.others.active()?E.hideOthers(E.showModal):(A=!1,u.allowMultiple&&(E.others.active()&&a.filter("."+m.active).find(f.dimmer).removeClass("out").addClass("transition fade in active"),u.detachable&&y.detach().appendTo(t)),u.transition&&void 0!==V.fn.transition?(E.debug("Showing modal with css animations"),E.set.observeAttributes(!1),y.transition({debug:u.debug,verbose:u.verbose,silent:u.silent,animation:(u.transition.showMethod||u.transition)+" in",queue:u.queue,duration:u.transition.showDuration||u.duration,useFailSafe:!0,onComplete:function(){u.onVisible.apply(S),u.keyboardShortcuts&&E.add.keyboardShortcuts(),E.save.focus(),E.set.active(),E.refreshInputs(),requestAnimationFrame(E.set.observeAttributes),e()}})):E.error(v.noTransition))):E.debug("Modal is already visible")},hideModal:function(e,t,n){var i=a.filter("."+m.active).last();if(e=Q(e)?e:function(){},!1===u.onHide.call(S,V(this)))return E.verbose("Hide callback returned false cancelling hide"),A=!1;(E.is.animating()||E.is.active())&&(E.debug("Hiding modal"),u.transition&&void 0!==V.fn.transition?(E.remove.active(),E.set.observeAttributes(!1),y.transition({debug:u.debug,verbose:u.verbose,silent:u.silent,animation:(u.transition.hideMethod||u.transition)+" out",queue:u.queue,duration:u.transition.hideDuration||u.duration,useFailSafe:!0,onStart:function(){E.others.active()||E.others.animating()||t?u.allowMultiple&&(n?o:i).find(f.dimmer).removeClass("in").addClass("out"):E.hideDimmer(),u.keyboardShortcuts&&!E.others.active()&&E.remove.keyboardShortcuts()},onComplete:function(){E.unbind.scrollLock(),E.remove.active(),u.allowMultiple&&(i.addClass(m.front),y.removeClass(m.front),(n?o:i).find(f.dimmer).removeClass("active")),Q(u.onHidden)&&u.onHidden.call(S),E.remove.dimmerStyles(),E.restore.focus(),e()}})):E.error(v.noTransition))},showDimmer:function(){i.dimmer("is animating")||!i.dimmer("is active")?(F&&(x||t.css("top",i.scrollTop()),E.save.bodyMargin()),E.debug("Showing dimmer"),i.dimmer("show")):E.debug("Dimmer already visible")},hideDimmer:function(){i.dimmer("is animating")||i.dimmer("is active")?(E.unbind.scrollLock(),i.dimmer("hide",function(){F&&E.restore.bodyMargin(),E.remove.clickaway(),E.remove.screenHeight()})):E.debug("Dimmer is not visible cannot hide")},hideAll:function(n){var i,e=o.filter("."+m.active+", ."+m.animating);if(n=Q(n)?n:function(){},0<e.length)return E.debug("Hiding all visible modals"),i=!0,V(e.get().reverse()).each(function(e,t){i=i&&V(t).modal("hide modal",n,!1,!0)}),i&&E.hideDimmer(),i},hideOthers:function(e){var t=a.filter("."+m.active+", ."+m.animating);e=Q(e)?e:function(){},0<t.length&&(E.debug("Hiding other modals",a),t.modal("hide modal",e,!0))},others:{active:function(){return 0<a.filter("."+m.active).length},animating:function(){return 0<a.filter("."+m.animating).length}},add:{keyboardShortcuts:function(){E.verbose("Adding keyboard shortcuts"),I.on("keydown"+p,E.event.keyboard)}},save:{focus:function(){0<V(_.activeElement).closest(y).length||(e=V(_.activeElement).trigger("blur"))},bodyMargin:function(){D=k.css((x?"margin-":"padding-")+(E.can.leftBodyScrollbar()?"left":"right"));var e=parseInt(D.replace(/[^\d.]/g,""),10),t=x?X.innerWidth-_.documentElement.clientWidth:k[0].offsetWidth-k[0].clientWidth;T=e+t}},restore:{focus:function(){e&&0<e.length&&u.restoreFocus&&e.trigger("focus")},bodyMargin:function(){var n=E.can.leftBodyScrollbar()?"left":"right";k.css((x?"margin-":"padding-")+n,D),k.find(f.bodyFixed.replace("right",n)).each(function(){var e=V(this),t="fixed"===e.css("position")?"padding-"+n:n;e.css(t,"")})}},remove:{active:function(){y.removeClass(m.active)},legacy:function(){y.removeClass(m.legacy)},clickaway:function(){u.detachable||y.off("mousedown"+c),t.off("mousedown"+c),t.off("mouseup"+c)},dimmerStyles:function(){t.removeClass(m.inverted),i.removeClass(m.blurring)},bodyStyle:function(){""===k.attr("style")&&(E.verbose("Removing style attribute"),k.removeAttr("style"))},screenHeight:function(){E.debug("Removing page height"),k.css("height",""),E.remove.bodyStyle()},keyboardShortcuts:function(){E.verbose("Removing keyboard shortcuts"),I.off("keydown"+p)},scrolling:function(){H||i.removeClass(m.scrolling),y.removeClass(m.scrolling)}},cacheSizes:function(){y.addClass(m.loading);var e=y.prop("scrollHeight"),t=y.outerWidth(),n=y.outerHeight();void 0!==E.cache.pageHeight&&0===n||(V.extend(E.cache,{pageHeight:I.outerHeight(),width:t,height:n+u.offset,scrollHeight:e+u.offset,contextHeight:(x?q:i).height()}),E.cache.topOffset=-E.cache.height/2),y.removeClass(m.loading),E.debug("Caching modal and container sizes",E.cache)},helpers:{escape:function(e,t){if(void 0!==t&&t.preserveHTML)return e;var n={"<":"&lt;",">":"&gt;",'"':"&quot;","'":"&apos;"};return e=/["&'<>]/.test(e)?(e=e.replace(/&(?![\d#a-z]{1,12};)/gi,"&amp;")).replace(/["'<>]/g,function(e){return n[e]}):e}},can:{leftBodyScrollbar:function(){return void 0===E.cache.leftBodyScrollbar&&(E.cache.leftBodyScrollbar=E.is.rtl()&&(E.is.iframe&&!E.is.firefox()||E.is.safari())),E.cache.leftBodyScrollbar},useFlex:function(){return"auto"===u.useFlex?u.detachable:(u.useFlex&&!u.detachable&&E.debug("useFlex true in combination with detachable false is not supported"),u.useFlex)},fit:function(){var e=E.cache.contextHeight,t=E.cache.contextHeight/2,n=E.cache.topOffset,i=E.cache.scrollHeight,o=E.cache.height,a=u.padding;return o<i?t+n+i+a<e:o+2*a<e}},has:{configActions:function(){return Array.isArray(u.actions)&&0<u.actions.length},scrollbar:function(){return x||"hidden"!==k.css("overflow-y")}},is:{active:function(){return y.hasClass(m.active)},animating:function(){return y.transition("is animating")},scrolling:function(){return i.hasClass(m.scrolling)},rtl:function(){return void 0===E.cache.isRTL&&(E.cache.isRTL="rtl"===y.attr("dir")||"rtl"===y.css("direction")||"rtl"===B.attr("dir")||"rtl"===B.css("direction")||"rtl"===k.attr("dir")||"rtl"===k.css("direction")),E.cache.isRTL},safari:function(){return void 0===E.cache.isSafari&&(E.cache.isSafari=/constructor/i.test(X.HTMLElement)||!!X.ApplePaySession),E.cache.isSafari},firefox:function(){return void 0===E.cache.isFirefox&&(E.cache.isFirefox=!!X.InstallTrigger),E.cache.isFirefox},iframe:function(){return!(self===top)}},set:{observeAttributes:function(e){O=!1!==e},autofocus:function(){var e=n.filter("[autofocus]"),t=n.filter(":input");(0<e.length?e:0<t.length?t:y).first().trigger("focus")},bodyMargin:function(){var n=E.can.leftBodyScrollbar()?"left":"right";(u.detachable||E.can.fit())&&k.css((x?"margin-":"padding-")+n,T+"px"),k.find(f.bodyFixed.replace("right",n)).each(function(){var e=V(this),t="fixed"===e.css("position")?"padding-"+n:n;e.css(t,"calc("+e.css(t)+" + "+T+"px)")})},clickaway:function(){u.detachable||y.on("mousedown"+c,E.event.mousedown),t.on("mousedown"+c,E.event.mousedown),t.on("mouseup"+c,E.event.mouseup)},dimmerSettings:function(){var e;void 0===V.fn.dimmer?E.error(v.dimmer):(e={debug:u.debug,dimmerName:"modals",closable:"auto",useFlex:E.can.useFlex(),duration:{show:u.transition.showDuration||u.duration,hide:u.transition.hideDuration||u.duration}},e=V.extend(!0,e,u.dimmerSettings),u.inverted&&(e.variation=void 0!==e.variation?e.variation+" inverted":"inverted"),k.dimmer("setting",e))},dimmerStyles:function(){u.inverted?t.addClass(m.inverted):t.removeClass(m.inverted),u.blurring?i.addClass(m.blurring):i.removeClass(m.blurring)},modalOffset:function(){var e;u.detachable?y.css({marginTop:!y.hasClass("aligned")&&E.can.fit()?-E.cache.height/2:u.padding/2,marginLeft:-E.cache.width/2}):(e=E.can.fit(),y.css({top:!y.hasClass("aligned")&&e?I.scrollTop()+(E.cache.contextHeight-E.cache.height)/2:!e||y.hasClass("top")?I.scrollTop()+u.padding:I.scrollTop()+(E.cache.contextHeight-E.cache.height-u.padding),marginLeft:-E.cache.width/2})),E.verbose("Setting modal offset for legacy mode")},screenHeight:function(){E.can.fit()?k.css("height",""):y.hasClass("bottom")||(E.debug("Modal is taller than page content, resizing page height"),k.css("height",E.cache.height+2*u.padding+"px"))},active:function(){y.addClass(m.active+" "+m.front),a.filter("."+m.active).removeClass(m.front)},scrolling:function(){i.addClass(m.scrolling),y.addClass(m.scrolling),E.unbind.scrollLock()},legacy:function(){y.addClass(m.legacy)},type:function(){E.can.fit()?(E.verbose("Modal fits on screen"),E.others.active()||E.others.animating()||(E.remove.scrolling(),E.bind.scrollLock())):y.hasClass("bottom")?E.verbose("Bottom aligned modal not fitting on screen is unsupported for scrolling"):(E.verbose("Modal cannot fit on screen setting to scrolling"),E.set.scrolling())},undetached:function(){i.addClass(m.undetached)}},setting:function(e,t){if(E.debug("Changing setting",e,t),V.isPlainObject(e))V.extend(!0,u,e);else{if(void 0===t)return u[e];V.isPlainObject(u[e])?V.extend(!0,u[e],t):u[e]=t}},internal:function(e,t){if(V.isPlainObject(e))V.extend(!0,E,e);else{if(void 0===t)return E[e];E[e]=t}},debug:function(){!u.silent&&u.debug&&(u.performance?E.performance.log(arguments):(E.debug=Function.prototype.bind.call(console.info,console,u.name+":"),E.debug.apply(console,arguments)))},verbose:function(){!u.silent&&u.verbose&&u.debug&&(u.performance?E.performance.log(arguments):(E.verbose=Function.prototype.bind.call(console.info,console,u.name+":"),E.verbose.apply(console,arguments)))},error:function(){u.silent||(E.error=Function.prototype.bind.call(console.error,console,u.name+":"),E.error.apply(console,arguments))},performance:{log:function(e){var t,n;u.performance&&(n=(t=Date.now())-(W||t),W=t,j.push({Name:e[0],Arguments:[].slice.call(e,1)||"",Element:S,"Execution Time":n})),clearTimeout(E.performance.timer),E.performance.timer=setTimeout(function(){E.performance.display()},500)},display:function(){var e=u.name+":",n=0;W=!1,clearTimeout(E.performance.timer),V.each(j,function(e,t){n+=t["Execution Time"]}),e+=" "+n+"ms",0<j.length&&(console.groupCollapsed(e),console.table?console.table(j):V.each(j,function(e,t){console.log(t.Name+": "+t["Execution Time"]+"ms")}),console.groupEnd()),j=[]}},invoke:function(i,e,t){var o,a,n,s=M;return e=e||R,t=t||S,"string"==typeof i&&void 0!==s&&(i=i.split(/[ .]/),o=i.length-1,V.each(i,function(e,t){var n=e!==o?t+i[e+1].charAt(0).toUpperCase()+i[e+1].slice(1):i;if(V.isPlainObject(s[n])&&e!==o)s=s[n];else{if(void 0!==s[n])return a=s[n],!1;{if(!V.isPlainObject(s[t])||e===o)return void 0!==s[t]?a=s[t]:E.error(v.method,i),!1;s=s[t]}}})),Q(a)?n=a.apply(t,e):void 0!==a&&(n=a),Array.isArray(z)?z.push(n):void 0!==z?z=[z,n]:void 0!==n&&(z=n),a}};K?(void 0===M&&(Q(u.templates[P])&&(u.autoShow=!0,u.className.modal=u.className.template,u=V.extend(!0,{},u,u.templates[P].apply(E,R)),m=u.className,u.namespace,g=u.fields,v=u.error),E.initialize()),Q(u.templates[P])||E.invoke(P)):(void 0!==M&&M.invoke("destroy"),E.initialize(),z=y)}),void 0!==z?z:this},V.modal=V.fn.modal,V.fn.modal.settings={name:"Modal",namespace:"modal",useFlex:"auto",offset:0,silent:!1,debug:!1,verbose:!1,performance:!0,observeChanges:!1,allowMultiple:!1,detachable:!0,closable:!0,autofocus:!0,restoreFocus:!0,autoShow:!1,inverted:!1,blurring:!1,centered:!0,dimmerSettings:{closable:!1,useCSS:!0},keyboardShortcuts:!0,context:"body",queue:!1,duration:500,transition:"scale",padding:50,scrollbarWidth:10,title:"",content:"",class:"",classTitle:"",classContent:"",classActions:"",closeIcon:!1,actions:!1,preserveHTML:!1,fields:{class:"class",text:"text",icon:"icon",click:"click"},onShow:function(){},onVisible:function(){},onHide:function(){return!0},onHidden:!1,onApprove:function(){return!0},onDeny:function(){return!0},keys:{space:32,enter:13,escape:27,tab:9},selector:{title:"> .header",content:"> .content",actions:"> .actions",close:"> .close",closeIcon:"> .close",approve:".actions .positive, .actions .approve, .actions .ok",deny:".actions .negative, .actions .deny, .actions .cancel",modal:".ui.modal",dimmer:"> .ui.dimmer",bodyFixed:"> .ui.fixed.menu, > .ui.right.toast-container, > .ui.right.sidebar, > .ui.fixed.nag, > .ui.fixed.nag > .close",prompt:".ui.input > input"},error:{dimmer:"UI Dimmer, a required component is not included in this page",method:"The method you called is not defined.",notFound:"The element you specified could not be found"},className:{active:"active",animating:"animating",blurring:"blurring",inverted:"inverted",legacy:"legacy",loading:"loading",scrolling:"scrolling",undetached:"undetached",front:"front",close:"close icon",button:"ui button",modal:"ui modal",title:"header",content:"content",actions:"actions",template:"ui tiny modal",ok:"positive",cancel:"negative",prompt:"ui fluid input",innerDimmer:"ui inverted dimmer"},text:{ok:"Ok",cancel:"Cancel",close:"Close"}},V.fn.modal.settings.templates={getArguments:function(e){e=[].slice.call(e);return V.isPlainObject(e[0])?V.extend({handler:function(){},content:"",title:""},e[0]):(Q(e[e.length-1])||e.push(function(){}),{handler:e.pop(),content:e.pop()||"",title:e.pop()||""})},alert:function(){var e=this.get.settings(),t=e.templates.getArguments(arguments),n=t.handler;return{title:t.title,content:t.content,onApprove:n,actions:[{text:e.text.ok,class:e.className.ok,click:n}]}},confirm:function(){function e(){i.handler(!0)}function t(){i.handler(!1)}var n=this.get.settings(),i=n.templates.getArguments(arguments);return{title:i.title,content:i.content,onApprove:e,onDeny:t,actions:[{text:n.text.ok,class:n.className.ok,click:e},{text:n.text.cancel,class:n.className.cancel,click:t}]}},prompt:function(){function e(){var e=n.get.settings(),e=n.get.element().find(e.selector.prompt)[0];o.handler(V(e).val())}function t(){o.handler(null)}var n=this,i=this.get.settings(),o=i.templates.getArguments(arguments);return 0===V(V.parseHTML(o.content)).filter(".ui.input").length&&(o.content+='<p><div class="'+this.helpers.escape(i.className.prompt)+'"><input placeholder="'+this.helpers.escape(o.placeholder||"")+'" type="text" value="'+this.helpers.escape(o.defaultValue||"")+'"></div></p>'),{title:o.title,content:o.content,onApprove:e,onDeny:t,actions:[{text:i.text.ok,class:i.className.ok,click:e},{text:i.text.cancel,class:i.className.cancel,click:t}]}}}}(jQuery,window,document);
11
+ !function(V,X,_){"use strict";function Q(e){return"function"==typeof e&&"number"!=typeof e.nodeType}X=void 0!==X&&X.Math===Math?X:globalThis,V.fn.modal=function(L){let e=V(this),z=V(X),q=V(_),I=V("body"),B=Date.now(),W=[],j=L,P="string"==typeof j,K=[].slice.call(arguments,1),R=function(e,t){let n;return 0<=[X,_].indexOf(e)?n=I:0===(n=V(t.document).find(e)).length&&(n=t.frameElement?R(e,t.parent):I),n},U;return e.each(function(){let r=V.isPlainObject(L)?V.extend(!0,{},V.fn.modal.settings,L):V.extend({},V.fn.modal.settings),a=r.selector,c=r.className;var e=r.namespace;let l=r.fields,d=r.error,i="."+e,t="module-"+e,u=V(this),o=R(r.context,X),s=o[0]===I[0],n=u.find(a.closeIcon),f,m,h,g,p,v,b=u.hasClass("modal"),y=this,k=b?u.data(t):void 0,x=!1,w,C,S="",M="",A=!1,D=!1,T=!1,H,F,N,O=!1,E;E={initialize:function(){if(E.create.id(),b||(E.create.modal(),Q(r.onHidden)||(r.onHidden=function(){E.destroy(),u.remove()})),u.addClass(r.class),""!==r.title&&u.find(a.title).html(E.helpers.escape(r.title,r)).addClass(r.classTitle),""!==r.content&&u.find(a.content).html(E.helpers.escape(r.content,r)).addClass(r.classContent),E.has.configActions()){let s=u.find(a.actions).addClass(r.classActions);0===s.length?s=V("<div/>",{class:c.actions+" "+(r.classActions||"")}).appendTo(u):s.empty(),r.actions.forEach(function(e){var t=e[l.icon]?"<i "+(e[l.text]?'aria-hidden="true"':"")+' class="'+E.helpers.escape(e[l.icon])+' icon"></i>':"",n=E.helpers.escape(e[l.text]||"",r),i=E.helpers.escape(e[l.class]||"");let o=e[l.click]&&Q(e[l.click])?e[l.click]:function(){};s.append(V("<button/>",{html:t+n,"aria-label":(e[l.text]||e[l.icon]||"").replace(/<[^>]+(>|$)/g,""),class:c.button+" "+i,on:{click:function(){let e=V(this);e.is(a.approve)||e.is(a.deny)||!1===o.call(y,u)||E.hide()}}}))})}E.cache={},E.verbose("Initializing dimmer",o),E.create.dimmer(),r.allowMultiple&&E.create.innerDimmer(),r.centered||u.addClass("top aligned"),E.refreshModals(),E.bind.events(),E.observeChanges(),E.instantiate(),r.autoShow&&E.show()},instantiate:function(){E.verbose("Storing instance of modal"),k=E,u.data(t,k)},create:{modal:function(){var e;u=V("<div/>",{class:c.modal,role:"dialog","aria-modal":!0}),r.closeIcon&&(n=V("<i/>",{class:c.close,role:"button",tabindex:0,"aria-label":r.text.close}),u.append(n)),""!==r.title&&(e="_"+E.get.id()+"title",u.attr("aria-labelledby",e),V("<div/>",{class:c.title,id:e}).appendTo(u)),""!==r.content&&(e="_"+E.get.id()+"desc",u.attr("aria-describedby",e),V("<div/>",{class:c.content,id:e}).appendTo(u)),E.has.configActions()&&V("<div/>",{class:c.actions}).appendTo(u),o.append(u),y=u[0]},dimmer:function(){var e={debug:r.debug,dimmerName:"modals"},e=V.extend(!0,e,r.dimmerSettings);void 0===V.fn.dimmer?E.error(d.dimmer):(E.debug("Creating dimmer"),p=o.dimmer(e),A=E.is.scrolling(),r.detachable?(E.verbose("Modal is detachable, moving content into dimmer"),p.dimmer("add content",u)):E.set.undetached(),v=p.dimmer("get dimmer"))},id:function(){F=(Math.random().toString(16)+"000000000").slice(2,10),H="."+F,E.verbose("Creating unique id for element",F)},innerDimmer:function(){0===u.find(a.dimmer).length&&V("<div/>",{class:c.innerDimmer}).prependTo(u)}},destroy:function(){N&&N.disconnect(),E.verbose("Destroying previous modal"),u.removeData(t).off(i),z.off(H),o.off(H),v.off(H),n.off(H),f&&f.off(H),o.dimmer("destroy")},observeChanges:function(){"MutationObserver"in X&&((N=new MutationObserver(function(e){function o(n){let i=[];for(let e=0,t=n.length;e<t;e++)Array.prototype.push.apply(i,o(n[e].childNodes)),i.push(n[e]);return i}let i=!1,s=!1,a=!0;e.every(function(n){if("attributes"===n.type)O&&("disabled"===n.attributeName||0<V(n.target).find(":input").addBack(":input").filter(":visible").length)&&(s=!0);else{i=!0;let e=V(o(n.addedNodes)).filter("a[href], [tabindex], :input:enabled").filter(":visible"),t=V(o(n.removedNodes)).filter("a[href], [tabindex], :input");(0<e.length||0<t.length)&&(s=!0,(0<e.filter(":input").length||0<t.filter(":input").length)&&(a=!1))}return!s}),i&&r.observeChanges&&(E.debug("DOM tree modified, refreshing"),E.refresh()),s&&E.refreshInputs(a)})).observe(y,{attributeFilter:["class","disabled"],attributes:!0,childList:!0,subtree:!0}),E.debug("Setting up mutation observer",N))},refresh:function(){E.remove.scrolling(),E.cacheSizes(),E.can.useFlex()||E.set.modalOffset(),E.set.screenHeight(),E.set.type()},refreshModals:function(){h=u.siblings(a.modal),m=h.add(u)},refreshInputs:function(e){f&&f.off("keydown"+H),0===(f=u.find("a[href], [tabindex], :input:enabled").filter(":visible").filter(function(){return 0===V(this).closest(".disabled").length})).filter(":input").length?(f=u.add(f),u.attr("tabindex",-1)):u.removeAttr("tabindex"),f.first().on("keydown"+H,E.event.inputKeyDown.first),f.last().on("keydown"+H,E.event.inputKeyDown.last),!e&&r.autofocus&&0===f.filter(":focus").length&&E.set.autofocus()},attachEvents:function(e,t){let n=V(e);t=Q(E[t])?E[t]:E.toggle,0<n.length?(E.debug("Attaching modal events to element",e,t),n.off(i).on("click"+i,t)):E.error(d.notFound,e)},bind:{events:function(){E.verbose("Attaching events"),u.on("click"+i,a.close,E.event.close).on("click"+i,a.approve,E.event.approve).on("click"+i,a.deny,E.event.deny),n.on("keyup"+H,E.event.closeKeyUp),z.on("resize"+H,E.event.resize).on("focus"+H,E.event.focus),o.on("click"+H,E.event.click)},scrollLock:function(){p[0].addEventListener("touchmove",E.event.preventScroll,{passive:!1})}},unbind:{scrollLock:function(){p[0].removeEventListener("touchmove",E.event.preventScroll,{passive:!1})}},get:{id:function(){return F},element:function(){return u},settings:function(){return r}},event:{approve:function(){x||!1===r.onApprove.call(y,V(this))?E.verbose("Approve callback returned false cancelling hide"):(x=!0,E.hide(function(){x=!1}))},preventScroll:function(e){-1!==e.target.className.indexOf("dimmer")&&e.preventDefault()},deny:function(){x||!1===r.onDeny.call(y,V(this))?E.verbose("Deny callback returned false cancelling hide"):(x=!0,E.hide(function(){x=!1}))},close:function(){E.hide()},closeKeyUp:function(e){e=e.which;e!==r.keys.enter&&e!==r.keys.space||!u.hasClass(c.front)||E.hide()},inputKeyDown:{first:function(e){e.which===r.keys.tab&&e.shiftKey&&(f.last().trigger("focus"),e.preventDefault())},last:function(e){e.which!==r.keys.tab||e.shiftKey||(f.first().trigger("focus"),e.preventDefault())}},mousedown:function(e){let t=V(e.target);var n=E.is.rtl();(w=0<t.closest(a.modal).length)&&E.verbose("Mouse down event registered inside the modal"),(C=E.is.scrolling()&&(!n&&z.outerWidth()-r.scrollbarWidth<=e.clientX||n&&r.scrollbarWidth>=e.clientX))&&E.verbose("Mouse down event registered inside the scrollbar")},mouseup:function(t){if(r.closable)if(w)E.debug("Dimmer clicked but mouse down was initially registered inside the modal");else if(C)E.debug("Dimmer clicked but mouse down was initially registered inside the scrollbar");else{let e=V(t.target);var n=0<e.closest(a.modal).length,t=V.contains(_.documentElement,t.target);if(!n&&t&&E.is.active()&&u.hasClass(c.front)){if(E.debug("Dimmer clicked, hiding all modals"),r.allowMultiple){if(!E.hideAll())return}else if(!E.hide())return;E.remove.clickaway()}}else E.verbose("Dimmer clicked but closable setting is disabled")},debounce:function(e,t){clearTimeout(E.timer),E.timer=setTimeout(function(){e()},t)},keyboard:function(e){e.which===r.keys.escape&&(r.closable?(E.debug("Escape key pressed hiding modal"),u.hasClass(c.front)&&E.hide()):E.debug("Escape key pressed, but closable is set to false"),e.preventDefault())},resize:function(){p.dimmer("is active")&&(E.is.animating()||E.is.active())&&requestAnimationFrame(E.refresh)},focus:function(){T=!0},click:function(e){T&&_.activeElement!==e.target&&p.dimmer("is active")&&E.is.active()&&r.autofocus&&0===V(_.activeElement).closest(a.modal).length&&requestAnimationFrame(E.set.autofocus),T=!1}},toggle:function(){E.is.active()||E.is.animating()?E.hide():E.show()},show:function(e){e=Q(e)?e:function(){},E.refreshModals(),E.set.dimmerSettings(),E.set.dimmerStyles(),E.showModal(e)},hide:function(e){return e=Q(e)?e:function(){},E.refreshModals(),E.hideModal(e)},showModal:function(e){e=Q(e)?e:function(){},E.is.animating()||!E.is.active()?!1===r.onShow.call(y)?E.verbose("Show callback returned false cancelling show"):(D=E.has.scrollbar(),E.showDimmer(),E.cacheSizes(),D&&E.set.bodyMargin(),E.can.useFlex()?E.remove.legacy():(E.set.legacy(),E.set.modalOffset(),E.debug("Using non-flex legacy modal positioning.")),E.set.screenHeight(),E.set.type(),E.set.clickaway(),!r.allowMultiple&&E.others.active()?E.hideOthers(E.showModal):(x=!1,r.allowMultiple&&(E.others.active()&&h.filter("."+c.active).find(a.dimmer).removeClass("out").addClass("transition fade in active"),r.detachable&&u.detach().appendTo(v)),r.transition&&void 0!==V.fn.transition?(E.debug("Showing modal with css animations"),E.set.observeAttributes(!1),u.transition({debug:r.debug,verbose:r.verbose,silent:r.silent,animation:(r.transition.showMethod||r.transition)+" in",queue:r.queue,duration:r.transition.showDuration||r.duration,useFailSafe:!0,onComplete:function(){r.onVisible.apply(y),r.keyboardShortcuts&&E.add.keyboardShortcuts(),E.save.focus(),E.set.active(),E.refreshInputs(),requestAnimationFrame(E.set.observeAttributes),e()}})):E.error(d.noTransition))):E.debug("Modal is already visible")},hideModal:function(e,t,n){let i=h.filter("."+c.active).last();if(e=Q(e)?e:function(){},!1===r.onHide.call(y,V(this)))return E.verbose("Hide callback returned false cancelling hide"),x=!1;(E.is.animating()||E.is.active())&&(E.debug("Hiding modal"),r.transition&&void 0!==V.fn.transition?(E.remove.active(),E.set.observeAttributes(!1),u.transition({debug:r.debug,verbose:r.verbose,silent:r.silent,animation:(r.transition.hideMethod||r.transition)+" out",queue:r.queue,duration:r.transition.hideDuration||r.duration,useFailSafe:!0,onStart:function(){E.others.active()||E.others.animating()||t?r.allowMultiple&&(n?m:i).find(a.dimmer).removeClass("in").addClass("out"):E.hideDimmer(),r.keyboardShortcuts&&!E.others.active()&&E.remove.keyboardShortcuts()},onComplete:function(){E.unbind.scrollLock(),E.remove.active(),r.allowMultiple&&(i.addClass(c.front),u.removeClass(c.front),(n?m:i).find(a.dimmer).removeClass("active")),Q(r.onHidden)&&r.onHidden.call(y),E.remove.dimmerStyles(),E.restore.focus(),e()}})):E.error(d.noTransition))},showDimmer:function(){p.dimmer("is animating")||!p.dimmer("is active")?(D&&(s||v.css("top",p.scrollTop()),E.save.bodyMargin()),E.debug("Showing dimmer"),p.dimmer("show")):E.debug("Dimmer already visible")},hideDimmer:function(){p.dimmer("is animating")||p.dimmer("is active")?(E.unbind.scrollLock(),p.dimmer("hide",function(){D&&E.restore.bodyMargin(),E.remove.clickaway(),E.remove.screenHeight()})):E.debug("Dimmer is not visible cannot hide")},hideAll:function(i){let e=m.filter("."+c.active+", ."+c.animating);if(i=Q(i)?i:function(){},0<e.length){E.debug("Hiding all visible modals");let n=!0;return V(e.get().reverse()).each(function(e,t){n=n&&V(t).modal("hide modal",i,!1,!0)}),n&&E.hideDimmer(),n}},hideOthers:function(e){let t=h.filter("."+c.active+", ."+c.animating);e=Q(e)?e:function(){},0<t.length&&(E.debug("Hiding other modals",h),t.modal("hide modal",e,!0))},others:{active:function(){return 0<h.filter("."+c.active).length},animating:function(){return 0<h.filter("."+c.animating).length}},add:{keyboardShortcuts:function(){E.verbose("Adding keyboard shortcuts"),q.on("keydown"+i,E.event.keyboard)}},save:{focus:function(){let e=V(_.activeElement);0<e.closest(u).length||(g=V(_.activeElement).trigger("blur"))},bodyMargin:function(){S=o.css((s?"margin-":"padding-")+(E.can.leftBodyScrollbar()?"left":"right"));var e=parseInt(S.replace(/[^\d.]/g,""),10),t=s?X.innerWidth-_.documentElement.clientWidth:o[0].offsetWidth-o[0].clientWidth;M=e+t}},restore:{focus:function(){g&&0<g.length&&r.restoreFocus&&g.trigger("focus")},bodyMargin:function(){let n=E.can.leftBodyScrollbar()?"left":"right";o.css((s?"margin-":"padding-")+n,S),o.find(a.bodyFixed.replace("right",n)).each(function(){let e=V(this);var t="fixed"===e.css("position")?"padding-"+n:n;e.css(t,"")})}},remove:{active:function(){u.removeClass(c.active)},legacy:function(){u.removeClass(c.legacy)},clickaway:function(){r.detachable||u.off("mousedown"+H),v.off("mousedown"+H),v.off("mouseup"+H)},dimmerStyles:function(){v.removeClass(c.inverted),p.removeClass(c.blurring)},bodyStyle:function(){""===o.attr("style")&&(E.verbose("Removing style attribute"),o.removeAttr("style"))},screenHeight:function(){E.debug("Removing page height"),o.css("height",""),E.remove.bodyStyle()},keyboardShortcuts:function(){E.verbose("Removing keyboard shortcuts"),q.off("keydown"+i)},scrolling:function(){A||p.removeClass(c.scrolling),u.removeClass(c.scrolling)}},cacheSizes:function(){u.addClass(c.loading);var e=u.prop("scrollHeight"),t=u.outerWidth(),n=u.outerHeight();void 0!==E.cache.pageHeight&&0===n||(V.extend(E.cache,{pageHeight:q.outerHeight(),width:t,height:n+r.offset,scrollHeight:e+r.offset,contextHeight:(s?z:p).height()}),E.cache.topOffset=-E.cache.height/2),u.removeClass(c.loading),E.debug("Caching modal and container sizes",E.cache)},helpers:{escape:function(e,t){if(void 0!==t&&t.preserveHTML)return e;const n={'"':"&quot;","&":"&amp;","'":"&apos;","<":"&lt;",">":"&gt;"};return e.replace(/["'<>]|&(?![\d#A-Za-z]{1,12};)/g,e=>n[e])}},can:{leftBodyScrollbar:function(){return void 0===E.cache.leftBodyScrollbar&&(E.cache.leftBodyScrollbar=E.is.rtl()&&(E.is.iframe&&!E.is.firefox()||E.is.safari())),E.cache.leftBodyScrollbar},useFlex:function(){return"auto"===r.useFlex?r.detachable:(r.useFlex&&!r.detachable&&E.debug("useFlex true in combination with detachable false is not supported"),r.useFlex)},fit:function(){var e=E.cache.contextHeight,t=E.cache.contextHeight/2,n=E.cache.topOffset,i=E.cache.scrollHeight,o=E.cache.height,s=r.padding;return o<i?t+n+i+s<e:o+2*s<e}},has:{configActions:function(){return Array.isArray(r.actions)&&0<r.actions.length},scrollbar:function(){return s||"hidden"!==o.css("overflow-y")}},is:{active:function(){return u.hasClass(c.active)},animating:function(){return u.transition("is animating")},scrolling:function(){return p.hasClass(c.scrolling)},rtl:function(){return void 0===E.cache.isRTL&&(E.cache.isRTL="rtl"===u.attr("dir")||"rtl"===u.css("direction")||"rtl"===I.attr("dir")||"rtl"===I.css("direction")||"rtl"===o.attr("dir")||"rtl"===o.css("direction")),E.cache.isRTL},safari:function(){return void 0===E.cache.isSafari&&(E.cache.isSafari=/constructor/i.test(X.HTMLElement)||!!X.ApplePaySession),E.cache.isSafari},firefox:function(){return void 0===E.cache.isFirefox&&(E.cache.isFirefox=!!X.InstallTrigger),E.cache.isFirefox},iframe:function(){return!(self===top)}},set:{observeAttributes:function(e){O=!1!==e},autofocus:function(){let e=f.filter("[autofocus]"),t=f.filter(":input"),n=(0<e.length?e:0<t.length?t:u).first();n.trigger("focus")},bodyMargin:function(){let n=E.can.leftBodyScrollbar()?"left":"right";(r.detachable||E.can.fit())&&o.css((s?"margin-":"padding-")+n,M+"px"),o.find(a.bodyFixed.replace("right",n)).each(function(){let e=V(this);var t="fixed"===e.css("position")?"padding-"+n:n;e.css(t,"calc("+e.css(t)+" + "+M+"px)")})},clickaway:function(){r.detachable||u.on("mousedown"+H,E.event.mousedown),v.on("mousedown"+H,E.event.mousedown),v.on("mouseup"+H,E.event.mouseup)},dimmerSettings:function(){if(void 0===V.fn.dimmer)E.error(d.dimmer);else{var t={debug:r.debug,dimmerName:"modals",closable:"auto",useFlex:E.can.useFlex(),duration:{show:r.transition.showDuration||r.duration,hide:r.transition.hideDuration||r.duration}};let e=V.extend(!0,t,r.dimmerSettings);r.inverted&&(e.variation=void 0!==e.variation?e.variation+" inverted":"inverted"),o.dimmer("setting",e)}},dimmerStyles:function(){r.inverted?v.addClass(c.inverted):v.removeClass(c.inverted),r.blurring?p.addClass(c.blurring):p.removeClass(c.blurring)},modalOffset:function(){var e;r.detachable?u.css({marginTop:!u.hasClass("aligned")&&E.can.fit()?-E.cache.height/2:r.padding/2,marginLeft:-E.cache.width/2}):(e=E.can.fit(),u.css({top:!u.hasClass("aligned")&&e?q.scrollTop()+(E.cache.contextHeight-E.cache.height)/2:!e||u.hasClass("top")?q.scrollTop()+r.padding:q.scrollTop()+(E.cache.contextHeight-E.cache.height-r.padding),marginLeft:-E.cache.width/2})),E.verbose("Setting modal offset for legacy mode")},screenHeight:function(){E.can.fit()?o.css("height",""):u.hasClass("bottom")||(E.debug("Modal is taller than page content, resizing page height"),o.css("height",E.cache.height+2*r.padding+"px"))},active:function(){u.addClass(c.active+" "+c.front),h.filter("."+c.active).removeClass(c.front)},scrolling:function(){p.addClass(c.scrolling),u.addClass(c.scrolling),E.unbind.scrollLock()},legacy:function(){u.addClass(c.legacy)},type:function(){E.can.fit()?(E.verbose("Modal fits on screen"),E.others.active()||E.others.animating()||(E.remove.scrolling(),E.bind.scrollLock())):u.hasClass("bottom")?E.verbose("Bottom aligned modal not fitting on screen is unsupported for scrolling"):(E.verbose("Modal cannot fit on screen setting to scrolling"),E.set.scrolling())},undetached:function(){p.addClass(c.undetached)}},setting:function(e,t){if(E.debug("Changing setting",e,t),V.isPlainObject(e))V.extend(!0,r,e);else{if(void 0===t)return r[e];V.isPlainObject(r[e])?V.extend(!0,r[e],t):r[e]=t}},internal:function(e,t){if(V.isPlainObject(e))V.extend(!0,E,e);else{if(void 0===t)return E[e];E[e]=t}},debug:function(){!r.silent&&r.debug&&(r.performance?E.performance.log(arguments):(E.debug=Function.prototype.bind.call(console.info,console,r.name+":"),E.debug.apply(console,arguments)))},verbose:function(){!r.silent&&r.verbose&&r.debug&&(r.performance?E.performance.log(arguments):(E.verbose=Function.prototype.bind.call(console.info,console,r.name+":"),E.verbose.apply(console,arguments)))},error:function(){r.silent||(E.error=Function.prototype.bind.call(console.error,console,r.name+":"),E.error.apply(console,arguments))},performance:{log:function(e){var t,n;r.performance&&(n=(t=Date.now())-(B||t),B=t,W.push({Name:e[0],Arguments:[].slice.call(e,1)||"",Element:y,"Execution Time":n})),clearTimeout(E.performance.timer),E.performance.timer=setTimeout(function(){E.performance.display()},500)},display:function(){var e=r.name+":";let n=0;B=!1,clearTimeout(E.performance.timer),V.each(W,function(e,t){n+=t["Execution Time"]}),e+=" "+n+"ms",0<W.length&&(console.groupCollapsed(e),console.table?console.table(W):V.each(W,function(e,t){console.log(t.Name+": "+t["Execution Time"]+"ms")}),console.groupEnd()),W=[]}},invoke:function(i,e,t){let o=k,s,a,n;return e=e||K,t=t||y,"string"==typeof i&&void 0!==o&&(i=i.split(/[ .]/),s=i.length-1,V.each(i,function(e,t){var n=e!==s?t+i[e+1].charAt(0).toUpperCase()+i[e+1].slice(1):i;if(V.isPlainObject(o[n])&&e!==s)o=o[n];else{if(void 0!==o[n])return a=o[n],!1;{if(!V.isPlainObject(o[t])||e===s)return void 0!==o[t]?a=o[t]:E.error(d.method,i),!1;o=o[t]}}})),Q(a)?n=a.apply(t,e):void 0!==a&&(n=a),Array.isArray(U)?U.push(n):void 0!==U?U=[U,n]:void 0!==n&&(U=n),a}},P?(void 0===k&&(Q(r.templates[j])&&(r.autoShow=!0,r.className.modal=r.className.template,r=V.extend(!0,{},r,r.templates[j].apply(E,K)),c=r.className,r.namespace,l=r.fields,d=r.error),E.initialize()),Q(r.templates[j])||E.invoke(j)):(void 0!==k&&k.invoke("destroy"),E.initialize(),U=u)}),void 0!==U?U:this},V.modal=V.fn.modal,V.fn.modal.settings={name:"Modal",namespace:"modal",useFlex:"auto",offset:0,silent:!1,debug:!1,verbose:!1,performance:!0,observeChanges:!1,allowMultiple:!1,detachable:!0,closable:!0,autofocus:!0,restoreFocus:!0,autoShow:!1,inverted:!1,blurring:!1,centered:!0,dimmerSettings:{closable:!1,useCSS:!0},keyboardShortcuts:!0,context:"body",queue:!1,duration:500,transition:"scale",padding:50,scrollbarWidth:10,title:"",content:"",class:"",classTitle:"",classContent:"",classActions:"",closeIcon:!1,actions:!1,preserveHTML:!1,fields:{class:"class",text:"text",icon:"icon",click:"click"},onShow:function(){},onVisible:function(){},onHide:function(){return!0},onHidden:!1,onApprove:function(){return!0},onDeny:function(){return!0},keys:{space:32,enter:13,escape:27,tab:9},selector:{title:"> .header",content:"> .content",actions:"> .actions",close:"> .close",closeIcon:"> .close",approve:".actions .positive, .actions .approve, .actions .ok",deny:".actions .negative, .actions .deny, .actions .cancel",modal:".ui.modal",dimmer:"> .ui.dimmer",bodyFixed:"> .ui.fixed.menu, > .ui.right.toast-container, > .ui.right.sidebar, > .ui.fixed.nag, > .ui.fixed.nag > .close",prompt:".ui.input > input"},error:{dimmer:"UI Dimmer, a required component is not included in this page",method:"The method you called is not defined.",notFound:"The element you specified could not be found"},className:{active:"active",animating:"animating",blurring:"blurring",inverted:"inverted",legacy:"legacy",loading:"loading",scrolling:"scrolling",undetached:"undetached",front:"front",close:"close icon",button:"ui button",modal:"ui modal",title:"header",content:"content",actions:"actions",template:"ui tiny modal",ok:"positive",cancel:"negative",prompt:"ui fluid input",innerDimmer:"ui inverted dimmer"},text:{ok:"Ok",cancel:"Cancel",close:"Close"}},V.fn.modal.settings.templates={getArguments:function(e){let t=[].slice.call(e);return V.isPlainObject(t[0])?V.extend({handler:function(){},content:"",title:""},t[0]):(Q(t[t.length-1])||t.push(function(){}),{handler:t.pop(),content:t.pop()||"",title:t.pop()||""})},alert:function(){let e=this.get.settings();var t=e.templates.getArguments(arguments),n=t.handler;return{title:t.title,content:t.content,onApprove:n,actions:[{text:e.text.ok,class:e.className.ok,click:n}]}},confirm:function(){let e=this.get.settings(),t=e.templates.getArguments(arguments);function n(){t.handler(!0)}function i(){t.handler(!1)}return{title:t.title,content:t.content,onApprove:n,onDeny:i,actions:[{text:e.text.ok,class:e.className.ok,click:n},{text:e.text.cancel,class:e.className.cancel,click:i}]}},prompt:function(){let t=this,e=this.get.settings(),n=e.templates.getArguments(arguments);function i(){var e=t.get.settings(),e=t.get.element().find(e.selector.prompt)[0];n.handler(V(e).val())}function o(){n.handler(null)}return 0===V(V.parseHTML(n.content)).filter(".ui.input").length&&(n.content+='<p><div class="'+this.helpers.escape(e.className.prompt)+'"><input placeholder="'+this.helpers.escape(n.placeholder||"")+'" type="text" value="'+this.helpers.escape(n.defaultValue||"")+'"></div></p>'),{title:n.title,content:n.content,onApprove:i,onDeny:o,actions:[{text:e.text.ok,class:e.className.ok,click:i},{text:e.text.cancel,class:e.className.cancel,click:o}]}}}}(jQuery,window,document);
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * # Fomantic-UI 2.10.0-beta.6+42a411a - Nag
2
+ * # Fomantic-UI 2.10.0-beta.8+62e258f - Nag
3
3
  * https://github.com/fomantic/Fomantic-UI/
4
4
  *
5
5
  *
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * # Fomantic-UI 2.10.0-beta.6+42a411a - Nag
2
+ * # Fomantic-UI 2.10.0-beta.8+62e258f - Nag
3
3
  * https://github.com/fomantic/Fomantic-UI/
4
4
  *
5
5
  *
@@ -20,53 +20,49 @@
20
20
  : globalThis;
21
21
 
22
22
  $.fn.nag = function (parameters) {
23
- var
24
- $allModules = $(this),
25
- $body = $('body'),
26
-
27
- time = Date.now(),
28
- performance = [],
29
-
30
- query = arguments[0],
31
- methodInvoked = typeof query === 'string',
32
- queryArguments = [].slice.call(arguments, 1),
33
- contextCheck = function (context, win) {
34
- var $context;
35
- if ([window, document].indexOf(context) >= 0) {
36
- $context = $(context);
37
- } else {
38
- $context = $(win.document).find(context);
39
- if ($context.length === 0) {
40
- $context = win.frameElement ? contextCheck(context, win.parent) : $body;
41
- }
23
+ let $allModules = $(this);
24
+ let $body = $('body');
25
+
26
+ let time = Date.now();
27
+ let performance = [];
28
+
29
+ let query = arguments[0];
30
+ let methodInvoked = typeof query === 'string';
31
+ let queryArguments = [].slice.call(arguments, 1);
32
+ let contextCheck = function (context, win) {
33
+ let $context;
34
+ if ([window, document].indexOf(context) >= 0) {
35
+ $context = $(context);
36
+ } else {
37
+ $context = $(win.document).find(context);
38
+ if ($context.length === 0) {
39
+ $context = win.frameElement ? contextCheck(context, win.parent) : $body;
42
40
  }
41
+ }
43
42
 
44
- return $context;
45
- },
46
- returnedValue
47
- ;
43
+ return $context;
44
+ };
45
+ let returnedValue;
48
46
  $allModules.each(function () {
49
- var
50
- settings = $.isPlainObject(parameters)
51
- ? $.extend(true, {}, $.fn.nag.settings, parameters)
52
- : $.extend({}, $.fn.nag.settings),
47
+ let settings = $.isPlainObject(parameters)
48
+ ? $.extend(true, {}, $.fn.nag.settings, parameters)
49
+ : $.extend({}, $.fn.nag.settings);
53
50
 
54
- selector = settings.selector,
55
- error = settings.error,
56
- namespace = settings.namespace,
51
+ let selector = settings.selector;
52
+ let error = settings.error;
53
+ let namespace = settings.namespace;
57
54
 
58
- eventNamespace = '.' + namespace,
59
- moduleNamespace = namespace + '-module',
55
+ let eventNamespace = '.' + namespace;
56
+ let moduleNamespace = namespace + '-module';
60
57
 
61
- $module = $(this),
58
+ let $module = $(this);
62
59
 
63
- $context = settings.context ? contextCheck(settings.context, window) : $body,
60
+ let $context = settings.context ? contextCheck(settings.context, window) : $body;
64
61
 
65
- element = this,
66
- instance = $module.data(moduleNamespace),
67
- storage,
68
- module
69
- ;
62
+ let element = this;
63
+ let instance = $module.data(moduleNamespace);
64
+ let storage;
65
+ let module;
70
66
  module = {
71
67
 
72
68
  initialize: function () {
@@ -77,14 +73,12 @@
77
73
  storage = module.get.storage();
78
74
  $module
79
75
  .on('click' + eventNamespace, selector.close, module.dismiss)
80
- .data(moduleNamespace, module)
81
- ;
76
+ .data(moduleNamespace, module);
82
77
 
83
78
  if (settings.detachable && $module.parent()[0] !== $context[0]) {
84
79
  $module
85
80
  .detach()
86
- .prependTo($context)
87
- ;
81
+ .prependTo($context);
88
82
  }
89
83
 
90
84
  if (settings.displayTime > 0) {
@@ -99,8 +93,7 @@
99
93
  module.verbose('Destroying instance');
100
94
  $module
101
95
  .removeData(moduleNamespace)
102
- .off(eventNamespace)
103
- ;
96
+ .off(eventNamespace);
104
97
  },
105
98
 
106
99
  show: function () {
@@ -113,12 +106,10 @@
113
106
  module.debug('Showing nag', settings.animation.show);
114
107
  if (settings.animation.show === 'fade') {
115
108
  $module
116
- .fadeIn(settings.duration, settings.easing, settings.onVisible)
117
- ;
109
+ .fadeIn(settings.duration, settings.easing, settings.onVisible);
118
110
  } else {
119
111
  $module
120
- .slideDown(settings.duration, settings.easing, settings.onVisible)
121
- ;
112
+ .slideDown(settings.duration, settings.easing, settings.onVisible);
122
113
  }
123
114
  }
124
115
  },
@@ -132,12 +123,10 @@
132
123
  module.debug('Hiding nag', settings.animation.hide);
133
124
  if (settings.animation.hide === 'fade') {
134
125
  $module
135
- .fadeOut(settings.duration, settings.easing, settings.onHidden)
136
- ;
126
+ .fadeOut(settings.duration, settings.easing, settings.onHidden);
137
127
  } else {
138
128
  $module
139
- .slideUp(settings.duration, settings.easing, settings.onHidden)
140
- ;
129
+ .slideUp(settings.duration, settings.easing, settings.onHidden);
141
130
  }
142
131
  },
143
132
 
@@ -200,14 +189,12 @@
200
189
  // RFC6265 compliant encoding
201
190
  key = encodeURIComponent(key)
202
191
  .replace(/%(2[346B]|5E|60|7C)/g, decodeURIComponent)
203
- .replace(/[()]/g, escape)
204
- ;
192
+ .replace(/[()]/g, escape);
205
193
  value = encodeURIComponent(value)
206
- .replace(/%(2[346BF]|3[AC-F]|40|5[BDE]|60|7[B-D])/g, decodeURIComponent)
207
- ;
194
+ .replace(/%(2[346BF]|3[AC-F]|40|5[BDE]|60|7[B-D])/g, decodeURIComponent);
208
195
 
209
- var cookieOptions = '';
210
- for (var option in options) {
196
+ let cookieOptions = '';
197
+ for (let option in options) {
211
198
  if (Object.prototype.hasOwnProperty.call(options, option)) {
212
199
  cookieOptions += '; ' + option;
213
200
  if (typeof options[option] === 'string') {
@@ -218,12 +205,10 @@
218
205
  document.cookie = key + '=' + value + cookieOptions;
219
206
  },
220
207
  getItem: function (key) {
221
- var cookies = document.cookie.split('; ');
222
- for (var i = 0, il = cookies.length; i < il; i++) {
223
- var
224
- parts = cookies[i].split('='),
225
- foundKey = parts[0].replace(/(%[\da-f]{2})+/gi, decodeURIComponent)
226
- ;
208
+ let cookies = document.cookie.split('; ');
209
+ for (let i = 0, il = cookies.length; i < il; i++) {
210
+ let parts = cookies[i].split('=');
211
+ let foundKey = parts[0].replace(/(%[\da-f]{2})+/gi, decodeURIComponent);
227
212
  if (key === foundKey) {
228
213
  return parts[1] || '';
229
214
  }
@@ -238,9 +223,7 @@
238
223
  module.error(error.noStorage);
239
224
  },
240
225
  storageOptions: function () {
241
- var
242
- options = {}
243
- ;
226
+ let options = {};
244
227
  if (settings.expires) {
245
228
  options.expires = module.get.expirationDate(settings.expires);
246
229
  }
@@ -267,9 +250,7 @@
267
250
 
268
251
  storage: {
269
252
  set: function (key, value) {
270
- var
271
- options = module.get.storageOptions()
272
- ;
253
+ let options = module.get.storageOptions();
273
254
  if (storage === window.localStorage && options.expires) {
274
255
  module.debug('Storing expiration value in localStorage', key, options.expires);
275
256
  storage.setItem(key + settings.expirationKey, options.expires);
@@ -282,12 +263,10 @@
282
263
  }
283
264
  },
284
265
  get: function (key) {
285
- var
286
- storedValue
287
- ;
266
+ let storedValue;
288
267
  storedValue = storage.getItem(key);
289
268
  if (storage === window.localStorage) {
290
- var expiration = storage.getItem(key + settings.expirationKey);
269
+ let expiration = storage.getItem(key + settings.expirationKey);
291
270
  if (expiration !== null && expiration !== undefined && new Date(expiration) < new Date()) {
292
271
  module.debug('Value in localStorage has expired. Deleting key', key);
293
272
  module.storage.remove(key);
@@ -301,9 +280,7 @@
301
280
  return storedValue;
302
281
  },
303
282
  remove: function (key) {
304
- var
305
- options = module.get.storageOptions()
306
- ;
283
+ let options = module.get.storageOptions();
307
284
  options.expires = module.get.expirationDate(-1);
308
285
  if (storage === window.localStorage) {
309
286
  storage.removeItem(key + settings.expirationKey);
@@ -363,11 +340,9 @@
363
340
  },
364
341
  performance: {
365
342
  log: function (message) {
366
- var
367
- currentTime,
368
- executionTime,
369
- previousTime
370
- ;
343
+ let currentTime;
344
+ let executionTime;
345
+ let previousTime;
371
346
  if (settings.performance) {
372
347
  currentTime = Date.now();
373
348
  previousTime = time || currentTime;
@@ -386,10 +361,8 @@
386
361
  }, 500);
387
362
  },
388
363
  display: function () {
389
- var
390
- title = settings.name + ':',
391
- totalTime = 0
392
- ;
364
+ let title = settings.name + ':';
365
+ let totalTime = 0;
393
366
  time = false;
394
367
  clearTimeout(module.performance.timer);
395
368
  $.each(performance, function (index, data) {
@@ -411,22 +384,19 @@
411
384
  },
412
385
  },
413
386
  invoke: function (query, passedArguments, context) {
414
- var
415
- object = instance,
416
- maxDepth,
417
- found,
418
- response
419
- ;
387
+ let object = instance;
388
+ let maxDepth;
389
+ let found;
390
+ let response;
420
391
  passedArguments = passedArguments || queryArguments;
421
392
  context = context || element;
422
393
  if (typeof query === 'string' && object !== undefined) {
423
394
  query = query.split(/[ .]/);
424
395
  maxDepth = query.length - 1;
425
396
  $.each(query, function (depth, value) {
426
- var camelCaseValue = depth !== maxDepth
397
+ let camelCaseValue = depth !== maxDepth
427
398
  ? value + query[depth + 1].charAt(0).toUpperCase() + query[depth + 1].slice(1)
428
- : query
429
- ;
399
+ : query;
430
400
  if ($.isPlainObject(object[camelCaseValue]) && (depth !== maxDepth)) {
431
401
  object = object[camelCaseValue];
432
402
  } else if (object[camelCaseValue] !== undefined) {
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * # Fomantic-UI 2.10.0-beta.6+42a411a - Nag
2
+ * # Fomantic-UI 2.10.0-beta.8+62e258f - Nag
3
3
  * https://github.com/fomantic/Fomantic-UI/
4
4
  *
5
5
  *
@@ -1,5 +1,5 @@
1
1
  /*
2
- * # Fomantic UI - 2.10.0-beta.6+42a411a
2
+ * # Fomantic UI - 2.10.0-beta.8+62e258f
3
3
  * https://github.com/fomantic/Fomantic-UI
4
4
  * https://fomantic-ui.com/
5
5
  *
@@ -8,4 +8,4 @@
8
8
  * https://opensource.org/licenses/MIT
9
9
  *
10
10
  */
11
- !function(w,S,D){"use strict";S=void 0!==S&&S.Math===Math?S:globalThis,w.fn.nag=function(g){var p,e=w(this),m=w("body"),f=Date.now(),h=[],v=g,b="string"==typeof v,y=[].slice.call(arguments,1),x=function(e,n){var o;return 0<=[S,D].indexOf(e)?o=w(e):0===(o=w(n.document).find(e)).length&&(o=n.frameElement?x(e,n.parent):m),o};return e.each(function(){var t,i=w.isPlainObject(g)?w.extend(!0,{},w.fn.nag.settings,g):w.extend({},w.fn.nag.settings),e=i.selector,c=i.error,n=i.namespace,o="."+n,a=n+"-module",r=w(this),s=i.context?x(i.context,S):m,l=this,d=r.data(a),u={initialize:function(){u.verbose("Initializing element"),"string"!=typeof i.value&&(i.value=JSON.stringify(i.value)),t=u.get.storage(),r.on("click"+o,e.close,u.dismiss).data(a,u),i.detachable&&r.parent()[0]!==s[0]&&r.detach().prependTo(s),0<i.displayTime&&setTimeout(function(){u.hide()},i.displayTime),u.show()},destroy:function(){u.verbose("Destroying instance"),r.removeData(a).off(o)},show:function(){if(u.should.show()&&!r.is(":visible")){if(!1===i.onShow.call(l))return u.debug("onShow callback returned false, cancelling nag animation"),!1;u.debug("Showing nag",i.animation.show),"fade"===i.animation.show?r.fadeIn(i.duration,i.easing,i.onVisible):r.slideDown(i.duration,i.easing,i.onVisible)}},hide:function(){if(!1===i.onHide.call(l))return u.debug("onHide callback returned false, cancelling nag animation"),!1;u.debug("Hiding nag",i.animation.hide),"fade"===i.animation.hide?r.fadeOut(i.duration,i.easing,i.onHidden):r.slideUp(i.duration,i.easing,i.onHidden)},dismiss:function(e){!1!==u.hide()&&i.storageMethod&&(u.debug("Dismissing nag",i.storageMethod,i.key,i.value,i.expires),u.storage.set(i.key,i.value)),e&&(e.stopImmediatePropagation(),e.preventDefault())},should:{show:function(){return i.persist?(u.debug("Persistent nag is set, can show nag"),!0):u.storage.get(i.key)!=i.value.toString()?(u.debug("Stored value is not set, can show nag",u.storage.get(i.key)),!0):(u.debug("Stored value is set, cannot show nag",u.storage.get(i.key)),!1)}},get:{expirationDate:function(e){if((e="number"==typeof e?new Date(Date.now()+864e5*e):e)instanceof Date&&e.getTime())return e.toUTCString();u.error(c.expiresFormat)},storage:function(){return"localstorage"===i.storageMethod&&void 0!==S.localStorage?(u.debug("Using local storage"),S.localStorage):"sessionstorage"===i.storageMethod&&void 0!==S.sessionStorage?(u.debug("Using session storage"),S.sessionStorage):"cookie"in D?(u.debug("Using cookie"),{setItem:function(e,n,o){e=encodeURIComponent(e).replace(/%(2[346B]|5E|60|7C)/g,decodeURIComponent).replace(/[()]/g,escape),n=encodeURIComponent(n).replace(/%(2[346BF]|3[AC-F]|40|5[BDE]|60|7[B-D])/g,decodeURIComponent);var t,i="";for(t in o)Object.prototype.hasOwnProperty.call(o,t)&&(i+="; "+t,"string"==typeof o[t]&&(i+="="+o[t].split(";")[0]));D.cookie=e+"="+n+i},getItem:function(e){for(var n=D.cookie.split("; "),o=0,t=n.length;o<t;o++){var i=n[o].split("=");if(e===i[0].replace(/(%[\da-f]{2})+/gi,decodeURIComponent))return i[1]||""}},removeItem:function(e,n){t.setItem(e,"",n)}}):void u.error(c.noStorage)},storageOptions:function(){var e={};return i.expires&&(e.expires=u.get.expirationDate(i.expires)),i.domain&&(e.domain=i.domain),i.path&&(e.path=i.path),i.secure&&(e.secure=i.secure),i.samesite&&(e.samesite=i.samesite),e}},clear:function(){u.storage.remove(i.key)},storage:{set:function(e,n){var o=u.get.storageOptions();t===S.localStorage&&o.expires&&(u.debug("Storing expiration value in localStorage",e,o.expires),t.setItem(e+i.expirationKey,o.expires)),u.debug("Value stored",e,n);try{t.setItem(e,n,o)}catch(e){u.error(c.setItem,e)}},get:function(e){var n,o=t.getItem(e);return t===S.localStorage&&null!=(n=t.getItem(e+i.expirationKey))&&new Date(n)<new Date&&(u.debug("Value in localStorage has expired. Deleting key",e),u.storage.remove(e),o=null),o="undefined"!==o&&"null"!==o&&null!=o?o:void 0},remove:function(e){var n=u.get.storageOptions();n.expires=u.get.expirationDate(-1),t===S.localStorage&&t.removeItem(e+i.expirationKey),t.removeItem(e,n)}},setting:function(e,n){if(u.debug("Changing setting",e,n),w.isPlainObject(e))w.extend(!0,i,e);else{if(void 0===n)return i[e];w.isPlainObject(i[e])?w.extend(!0,i[e],n):i[e]=n}},internal:function(e,n){if(w.isPlainObject(e))w.extend(!0,u,e);else{if(void 0===n)return u[e];u[e]=n}},debug:function(){!i.silent&&i.debug&&(i.performance?u.performance.log(arguments):(u.debug=Function.prototype.bind.call(console.info,console,i.name+":"),u.debug.apply(console,arguments)))},verbose:function(){!i.silent&&i.verbose&&i.debug&&(i.performance?u.performance.log(arguments):(u.verbose=Function.prototype.bind.call(console.info,console,i.name+":"),u.verbose.apply(console,arguments)))},error:function(){i.silent||(u.error=Function.prototype.bind.call(console.error,console,i.name+":"),u.error.apply(console,arguments))},performance:{log:function(e){var n,o;i.performance&&(o=(n=Date.now())-(f||n),f=n,h.push({Name:e[0],Arguments:[].slice.call(e,1)||"",Element:l,"Execution Time":o})),clearTimeout(u.performance.timer),u.performance.timer=setTimeout(function(){u.performance.display()},500)},display:function(){var e=i.name+":",o=0;f=!1,clearTimeout(u.performance.timer),w.each(h,function(e,n){o+=n["Execution Time"]}),e+=" "+o+"ms",0<h.length&&(console.groupCollapsed(e),console.table?console.table(h):w.each(h,function(e,n){console.log(n.Name+": "+n["Execution Time"]+"ms")}),console.groupEnd()),h=[]}},invoke:function(t,e,n){var i,a,o,r,s=d;return e=e||y,n=n||l,"string"==typeof t&&void 0!==s&&(t=t.split(/[ .]/),i=t.length-1,w.each(t,function(e,n){var o=e!==i?n+t[e+1].charAt(0).toUpperCase()+t[e+1].slice(1):t;if(w.isPlainObject(s[o])&&e!==i)s=s[o];else{if(void 0!==s[o])return a=s[o],!1;{if(!w.isPlainObject(s[n])||e===i)return void 0!==s[n]?a=s[n]:u.error(c.method,t),!1;s=s[n]}}})),"function"==typeof(r=a)&&"number"!=typeof r.nodeType?o=a.apply(n,e):void 0!==a&&(o=a),Array.isArray(p)?p.push(o):void 0!==p?p=[p,o]:void 0!==o&&(p=o),a}};b?(void 0===d&&u.initialize(),u.invoke(v)):(void 0!==d&&d.invoke("destroy"),u.initialize())}),void 0!==p?p:this},w.fn.nag.settings={name:"Nag",silent:!1,debug:!1,verbose:!1,performance:!0,namespace:"Nag",persist:!1,displayTime:0,animation:{show:"slide",hide:"slide"},context:!1,detachable:!1,expires:30,domain:!1,path:"/",secure:!1,samesite:!1,storageMethod:"cookie",key:"nag",value:"dismiss",expirationKey:"ExpirationDate",error:{noStorage:"Unsupported storage method",method:"The method you called is not defined.",setItem:"Unexpected error while setting value",expiresFormat:'"expires" must be a number of days or a Date Object'},className:{bottom:"bottom",fixed:"fixed"},selector:{close:"> .close.icon"},duration:500,easing:"easeOutQuad",onShow:function(){},onVisible:function(){},onHide:function(){},onHidden:function(){}},w.extend(w.easing,{easeOutQuad:function(e){return 1-(1-e)*(1-e)}})}(jQuery,window,document);
11
+ !function(w,S,D){"use strict";S=void 0!==S&&S.Math===Math?S:globalThis,w.fn.nag=function(g){let e=w(this),p=w("body"),m=Date.now(),f=[],h=g,b="string"==typeof h,v=[].slice.call(arguments,1),y=function(e,t){let n;return 0<=[S,D].indexOf(e)?n=w(e):0===(n=w(t.document).find(e)).length&&(n=t.frameElement?y(e,t.parent):p),n},x;return e.each(function(){let o=w.isPlainObject(g)?w.extend(!0,{},w.fn.nag.settings,g):w.extend({},w.fn.nag.settings),e=o.selector,l=o.error;var t=o.namespace;let n="."+t,i=t+"-module",a=w(this),r=o.context?y(o.context,S):p,c=this,d=a.data(i),s,u;u={initialize:function(){u.verbose("Initializing element"),"string"!=typeof o.value&&(o.value=JSON.stringify(o.value)),s=u.get.storage(),a.on("click"+n,e.close,u.dismiss).data(i,u),o.detachable&&a.parent()[0]!==r[0]&&a.detach().prependTo(r),0<o.displayTime&&setTimeout(function(){u.hide()},o.displayTime),u.show()},destroy:function(){u.verbose("Destroying instance"),a.removeData(i).off(n)},show:function(){if(u.should.show()&&!a.is(":visible")){if(!1===o.onShow.call(c))return u.debug("onShow callback returned false, cancelling nag animation"),!1;u.debug("Showing nag",o.animation.show),"fade"===o.animation.show?a.fadeIn(o.duration,o.easing,o.onVisible):a.slideDown(o.duration,o.easing,o.onVisible)}},hide:function(){if(!1===o.onHide.call(c))return u.debug("onHide callback returned false, cancelling nag animation"),!1;u.debug("Hiding nag",o.animation.hide),"fade"===o.animation.hide?a.fadeOut(o.duration,o.easing,o.onHidden):a.slideUp(o.duration,o.easing,o.onHidden)},dismiss:function(e){!1!==u.hide()&&o.storageMethod&&(u.debug("Dismissing nag",o.storageMethod,o.key,o.value,o.expires),u.storage.set(o.key,o.value)),e&&(e.stopImmediatePropagation(),e.preventDefault())},should:{show:function(){return o.persist?(u.debug("Persistent nag is set, can show nag"),!0):u.storage.get(o.key)!=o.value.toString()?(u.debug("Stored value is not set, can show nag",u.storage.get(o.key)),!0):(u.debug("Stored value is set, cannot show nag",u.storage.get(o.key)),!1)}},get:{expirationDate:function(e){if((e="number"==typeof e?new Date(Date.now()+864e5*e):e)instanceof Date&&e.getTime())return e.toUTCString();u.error(l.expiresFormat)},storage:function(){return"localstorage"===o.storageMethod&&void 0!==S.localStorage?(u.debug("Using local storage"),S.localStorage):"sessionstorage"===o.storageMethod&&void 0!==S.sessionStorage?(u.debug("Using session storage"),S.sessionStorage):"cookie"in D?(u.debug("Using cookie"),{setItem:function(e,t,n){e=encodeURIComponent(e).replace(/%(2[346B]|5E|60|7C)/g,decodeURIComponent).replace(/[()]/g,escape),t=encodeURIComponent(t).replace(/%(2[346BF]|3[AC-F]|40|5[BDE]|60|7[B-D])/g,decodeURIComponent);let o="";for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(o+="; "+i,"string"==typeof n[i]&&(o+="="+n[i].split(";")[0]));D.cookie=e+"="+t+o},getItem:function(n){let o=D.cookie.split("; ");for(let t=0,e=o.length;t<e;t++){let e=o[t].split("=");if(n===e[0].replace(/(%[\da-f]{2})+/gi,decodeURIComponent))return e[1]||""}},removeItem:function(e,t){s.setItem(e,"",t)}}):void u.error(l.noStorage)},storageOptions:function(){let e={};return o.expires&&(e.expires=u.get.expirationDate(o.expires)),o.domain&&(e.domain=o.domain),o.path&&(e.path=o.path),o.secure&&(e.secure=o.secure),o.samesite&&(e.samesite=o.samesite),e}},clear:function(){u.storage.remove(o.key)},storage:{set:function(e,t){var n=u.get.storageOptions();s===S.localStorage&&n.expires&&(u.debug("Storing expiration value in localStorage",e,n.expires),s.setItem(e+o.expirationKey,n.expires)),u.debug("Value stored",e,t);try{s.setItem(e,t,n)}catch(e){u.error(l.setItem,e)}},get:function(e){let t;var n;return t=s.getItem(e),s===S.localStorage&&null!=(n=s.getItem(e+o.expirationKey))&&new Date(n)<new Date&&(u.debug("Value in localStorage has expired. Deleting key",e),u.storage.remove(e),t=null),t="undefined"!==t&&"null"!==t&&void 0!==t&&null!==t?t:void 0},remove:function(e){let t=u.get.storageOptions();t.expires=u.get.expirationDate(-1),s===S.localStorage&&s.removeItem(e+o.expirationKey),s.removeItem(e,t)}},setting:function(e,t){if(u.debug("Changing setting",e,t),w.isPlainObject(e))w.extend(!0,o,e);else{if(void 0===t)return o[e];w.isPlainObject(o[e])?w.extend(!0,o[e],t):o[e]=t}},internal:function(e,t){if(w.isPlainObject(e))w.extend(!0,u,e);else{if(void 0===t)return u[e];u[e]=t}},debug:function(){!o.silent&&o.debug&&(o.performance?u.performance.log(arguments):(u.debug=Function.prototype.bind.call(console.info,console,o.name+":"),u.debug.apply(console,arguments)))},verbose:function(){!o.silent&&o.verbose&&o.debug&&(o.performance?u.performance.log(arguments):(u.verbose=Function.prototype.bind.call(console.info,console,o.name+":"),u.verbose.apply(console,arguments)))},error:function(){o.silent||(u.error=Function.prototype.bind.call(console.error,console,o.name+":"),u.error.apply(console,arguments))},performance:{log:function(e){var t,n;o.performance&&(n=(t=Date.now())-(m||t),m=t,f.push({Name:e[0],Arguments:[].slice.call(e,1)||"",Element:c,"Execution Time":n})),clearTimeout(u.performance.timer),u.performance.timer=setTimeout(function(){u.performance.display()},500)},display:function(){var e=o.name+":";let n=0;m=!1,clearTimeout(u.performance.timer),w.each(f,function(e,t){n+=t["Execution Time"]}),e+=" "+n+"ms",0<f.length&&(console.groupCollapsed(e),console.table?console.table(f):w.each(f,function(e,t){console.log(t.Name+": "+t["Execution Time"]+"ms")}),console.groupEnd()),f=[]}},invoke:function(o,e,t){let i=d,a,r,n;var s;return e=e||v,t=t||c,"string"==typeof o&&void 0!==i&&(o=o.split(/[ .]/),a=o.length-1,w.each(o,function(e,t){var n=e!==a?t+o[e+1].charAt(0).toUpperCase()+o[e+1].slice(1):o;if(w.isPlainObject(i[n])&&e!==a)i=i[n];else{if(void 0!==i[n])return r=i[n],!1;{if(!w.isPlainObject(i[t])||e===a)return void 0!==i[t]?r=i[t]:u.error(l.method,o),!1;i=i[t]}}})),"function"==typeof(s=r)&&"number"!=typeof s.nodeType?n=r.apply(t,e):void 0!==r&&(n=r),Array.isArray(x)?x.push(n):void 0!==x?x=[x,n]:void 0!==n&&(x=n),r}},b?(void 0===d&&u.initialize(),u.invoke(h)):(void 0!==d&&d.invoke("destroy"),u.initialize())}),void 0!==x?x:this},w.fn.nag.settings={name:"Nag",silent:!1,debug:!1,verbose:!1,performance:!0,namespace:"Nag",persist:!1,displayTime:0,animation:{show:"slide",hide:"slide"},context:!1,detachable:!1,expires:30,domain:!1,path:"/",secure:!1,samesite:!1,storageMethod:"cookie",key:"nag",value:"dismiss",expirationKey:"ExpirationDate",error:{noStorage:"Unsupported storage method",method:"The method you called is not defined.",setItem:"Unexpected error while setting value",expiresFormat:'"expires" must be a number of days or a Date Object'},className:{bottom:"bottom",fixed:"fixed"},selector:{close:"> .close.icon"},duration:500,easing:"easeOutQuad",onShow:function(){},onVisible:function(){},onHide:function(){},onHidden:function(){}},w.extend(w.easing,{easeOutQuad:function(e){return 1-(1-e)*(1-e)}})}(jQuery,window,document);
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * # Fomantic-UI 2.10.0-beta.6+42a411a - Placeholder
2
+ * # Fomantic-UI 2.10.0-beta.8+62e258f - Placeholder
3
3
  * https://github.com/fomantic/Fomantic-UI/
4
4
  *
5
5
  *
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * # Fomantic-UI 2.10.0-beta.6+42a411a - Placeholder
2
+ * # Fomantic-UI 2.10.0-beta.8+62e258f - Placeholder
3
3
  * https://github.com/fomantic/Fomantic-UI/
4
4
  *
5
5
  *
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * # Fomantic-UI 2.10.0-beta.6+42a411a - Popup
2
+ * # Fomantic-UI 2.10.0-beta.8+62e258f - Popup
3
3
  * https://github.com/fomantic/Fomantic-UI/
4
4
  *
5
5
  *