fomantic-ui 2.9.2-beta.7 → 2.9.2-beta.9
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.
- package/dist/components/accordion.css +1 -1
- package/dist/components/accordion.js +4 -4
- package/dist/components/accordion.min.css +1 -1
- package/dist/components/accordion.min.js +2 -2
- package/dist/components/ad.css +1 -1
- package/dist/components/ad.min.css +1 -1
- package/dist/components/api.js +1 -1
- package/dist/components/api.min.js +1 -1
- package/dist/components/breadcrumb.css +1 -1
- package/dist/components/breadcrumb.min.css +1 -1
- package/dist/components/button.css +1 -1
- package/dist/components/button.min.css +1 -1
- package/dist/components/calendar.css +1 -1
- package/dist/components/calendar.js +1 -1
- package/dist/components/calendar.min.css +1 -1
- package/dist/components/calendar.min.js +1 -1
- package/dist/components/card.css +1 -1
- package/dist/components/card.min.css +1 -1
- package/dist/components/checkbox.css +1 -1
- package/dist/components/checkbox.js +1 -1
- package/dist/components/checkbox.min.css +1 -1
- package/dist/components/checkbox.min.js +1 -1
- package/dist/components/comment.css +1 -1
- package/dist/components/comment.min.css +1 -1
- package/dist/components/container.css +1 -1
- package/dist/components/container.min.css +1 -1
- package/dist/components/dimmer.css +1 -1
- package/dist/components/dimmer.js +3 -3
- package/dist/components/dimmer.min.css +1 -1
- package/dist/components/dimmer.min.js +2 -2
- package/dist/components/divider.css +1 -1
- package/dist/components/divider.min.css +1 -1
- package/dist/components/dropdown.css +1 -1
- package/dist/components/dropdown.js +3 -3
- package/dist/components/dropdown.min.css +1 -1
- package/dist/components/dropdown.min.js +2 -2
- package/dist/components/embed.css +1 -1
- package/dist/components/embed.js +2 -2
- package/dist/components/embed.min.css +1 -1
- package/dist/components/embed.min.js +2 -2
- package/dist/components/feed.css +1 -1
- package/dist/components/feed.min.css +1 -1
- package/dist/components/flag.css +1 -1
- package/dist/components/flag.min.css +1 -1
- package/dist/components/flyout.css +1 -1
- package/dist/components/flyout.js +18 -30
- package/dist/components/flyout.min.css +1 -1
- package/dist/components/flyout.min.js +2 -2
- package/dist/components/form.css +1 -1
- package/dist/components/form.js +3 -3
- package/dist/components/form.min.css +1 -1
- package/dist/components/form.min.js +2 -2
- package/dist/components/grid.css +1 -1
- package/dist/components/grid.min.css +1 -1
- package/dist/components/header.css +1 -1
- package/dist/components/header.min.css +1 -1
- package/dist/components/icon.css +1 -1
- package/dist/components/icon.min.css +1 -1
- package/dist/components/image.css +1 -1
- package/dist/components/image.min.css +1 -1
- package/dist/components/input.css +1 -1
- package/dist/components/input.min.css +1 -1
- package/dist/components/item.css +1 -1
- package/dist/components/item.min.css +1 -1
- package/dist/components/label.css +1 -1
- package/dist/components/label.min.css +1 -1
- package/dist/components/list.css +1 -1
- package/dist/components/list.min.css +1 -1
- package/dist/components/loader.css +1 -1
- package/dist/components/loader.min.css +1 -1
- package/dist/components/message.css +1 -1
- package/dist/components/message.min.css +1 -1
- package/dist/components/modal.css +1 -1
- package/dist/components/modal.js +14 -8
- package/dist/components/modal.min.css +1 -1
- package/dist/components/modal.min.js +2 -2
- package/dist/components/nag.css +1 -1
- package/dist/components/nag.js +1 -1
- package/dist/components/nag.min.css +1 -1
- package/dist/components/nag.min.js +1 -1
- package/dist/components/placeholder.css +1 -1
- package/dist/components/placeholder.min.css +1 -1
- package/dist/components/popup.css +147 -2
- package/dist/components/popup.js +20 -8
- package/dist/components/popup.min.css +2 -2
- package/dist/components/popup.min.js +2 -2
- package/dist/components/progress.css +1 -1
- package/dist/components/progress.js +3 -29
- package/dist/components/progress.min.css +1 -1
- package/dist/components/progress.min.js +2 -2
- package/dist/components/rail.css +1 -1
- package/dist/components/rail.min.css +1 -1
- package/dist/components/rating.css +1 -1
- package/dist/components/rating.js +1 -1
- package/dist/components/rating.min.css +1 -1
- package/dist/components/rating.min.js +1 -1
- package/dist/components/reset.css +1 -1
- package/dist/components/reset.min.css +1 -1
- package/dist/components/reveal.css +1 -1
- package/dist/components/reveal.min.css +1 -1
- package/dist/components/search.css +1 -1
- package/dist/components/search.js +2 -2
- package/dist/components/search.min.css +1 -1
- package/dist/components/search.min.js +2 -2
- package/dist/components/segment.css +1 -1
- package/dist/components/segment.min.css +1 -1
- package/dist/components/shape.css +1 -1
- package/dist/components/shape.js +15 -37
- package/dist/components/shape.min.css +1 -1
- package/dist/components/shape.min.js +2 -2
- package/dist/components/sidebar.css +1 -1
- package/dist/components/sidebar.js +7 -27
- package/dist/components/sidebar.min.css +1 -1
- package/dist/components/sidebar.min.js +2 -2
- package/dist/components/site.css +1 -1
- package/dist/components/site.js +1 -1
- package/dist/components/site.min.css +1 -1
- package/dist/components/site.min.js +1 -1
- package/dist/components/slider.js +1 -1
- package/dist/components/slider.min.js +1 -1
- package/dist/components/state.js +1 -1
- package/dist/components/state.min.js +1 -1
- package/dist/components/statistic.css +1 -1
- package/dist/components/statistic.min.css +1 -1
- package/dist/components/step.css +1 -1
- package/dist/components/step.min.css +1 -1
- package/dist/components/sticky.css +1 -1
- package/dist/components/sticky.js +1 -1
- package/dist/components/sticky.min.css +1 -1
- package/dist/components/sticky.min.js +1 -1
- package/dist/components/tab.css +1 -1
- package/dist/components/tab.js +1 -1
- package/dist/components/tab.min.css +1 -1
- package/dist/components/tab.min.js +1 -1
- package/dist/components/table.css +1 -1
- package/dist/components/table.min.css +1 -1
- package/dist/components/text.css +1 -1
- package/dist/components/text.min.css +1 -1
- package/dist/components/toast.css +1 -1
- package/dist/components/toast.js +3 -3
- package/dist/components/toast.min.css +1 -1
- package/dist/components/toast.min.js +2 -2
- package/dist/components/transition.css +1 -1
- package/dist/components/transition.js +9 -57
- package/dist/components/transition.min.css +1 -1
- package/dist/components/transition.min.js +2 -2
- package/dist/components/visibility.js +1 -1
- package/dist/components/visibility.min.js +1 -1
- package/dist/semantic.css +229 -51
- package/dist/semantic.js +118 -228
- package/dist/semantic.min.css +2 -2
- package/dist/semantic.min.js +2 -2
- package/package.json +1 -1
- package/src/definitions/behaviors/form.js +2 -2
- package/src/definitions/modules/accordion.js +3 -3
- package/src/definitions/modules/dimmer.js +2 -2
- package/src/definitions/modules/dropdown.js +2 -2
- package/src/definitions/modules/embed.js +1 -1
- package/src/definitions/modules/flyout.js +17 -29
- package/src/definitions/modules/modal.js +13 -7
- package/src/definitions/modules/popup.js +19 -7
- package/src/definitions/modules/popup.less +47 -3
- package/src/definitions/modules/progress.js +2 -28
- package/src/definitions/modules/search.js +1 -1
- package/src/definitions/modules/shape.js +14 -36
- package/src/definitions/modules/sidebar.js +6 -26
- package/src/definitions/modules/toast.js +2 -2
- package/src/definitions/modules/transition.js +8 -56
- package/src/themes/default/modules/popup.variables +8 -0
@@ -1,5 +1,5 @@
|
|
1
1
|
/*
|
2
|
-
* # Fomantic UI - 2.9.2-beta.
|
2
|
+
* # Fomantic UI - 2.9.2-beta.9+f3fb845
|
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(Q,X,R){"use strict";function U(e){return"function"==typeof e&&"number"!=typeof e.nodeType}X=void 0!==X&&X.Math===Math?X:globalThis,Q.fn.modal=function(E){var L,e=Q(this),N=Q(X),I=Q(R),j=Q("body"),z=e.selector||"",q=Date.now(),B=[],W=E,P="string"==typeof W,K=[].slice.call(arguments,1);return e.each(function(){var i,o,s,e,n,t,a,r,c,l,d,u=Q.isPlainObject(E)?Q.extend(!0,{},Q.fn.modal.settings,E):Q.extend({},Q.fn.modal.settings),f=u.selector,m=u.className,h=u.namespace,g=u.fields,v=u.error,p="."+h,b="module-"+h,y=Q(this),x=[X,R].indexOf(u.context)<0?I.find(u.context):j,k=x[0]===j[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,O={initialize:function(){var s;O.create.id(),C||(O.create.modal(),U(u.onHidden)||(u.onHidden=function(){O.destroy(),y.remove()})),y.addClass(u.class),""!==u.title&&y.find(f.title).html(O.helpers.escape(u.title,u.preserveHTML)).addClass(u.classTitle),""!==u.content&&y.find(f.content).html(O.helpers.escape(u.content,u.preserveHTML)).addClass(u.classContent),O.has.configActions()&&(0===(s=y.find(f.actions).addClass(u.classActions)).length?s=Q("<div/>",{class:m.actions+" "+(u.classActions||"")}).appendTo(y):s.empty(),u.actions.forEach(function(e){var t=e[g.icon]?"<i "+(e[g.text]?'aria-hidden="true"':"")+' class="'+O.helpers.deQuote(e[g.icon])+' icon"></i>':"",i=O.helpers.escape(e[g.text]||"",u.preserveHTML),n=O.helpers.deQuote(e[g.class]||""),o=e[g.click]&&U(e[g.click])?e[g.click]:function(){};s.append(Q("<button/>",{html:t+i,"aria-label":(e[g.text]||e[g.icon]||"").replace(/<[^>]+(>|$)/g,""),class:m.button+" "+n,on:{click:function(){var e=Q(this);e.is(f.approve)||e.is(f.deny)||!1===o.call(S,y)||O.hide()}}}))})),O.cache={},O.verbose("Initializing dimmer",x),O.create.dimmer(),u.allowMultiple&&O.create.innerDimmer(),u.centered||y.addClass("top aligned"),O.refreshModals(),O.bind.events(),O.observeChanges(),O.instantiate(),u.autoShow&&O.show()},instantiate:function(){O.verbose("Storing instance of modal"),M=O,y.data(b,M)},create:{modal:function(){var e;y=Q("<div/>",{class:m.modal,role:"dialog","aria-modal":!0}),u.closeIcon&&(w=Q("<i/>",{class:m.close,role:"button",tabindex:0,"aria-label":u.text.close}),y.append(w)),""!==u.title&&(e="_"+O.get.id()+"title",y.attr("aria-labelledby",e),Q("<div/>",{class:m.title,id:e}).appendTo(y)),""!==u.content&&(e="_"+O.get.id()+"desc",y.attr("aria-describedby",e),Q("<div/>",{class:m.content,id:e}).appendTo(y)),O.has.configActions()&&Q("<div/>",{class:m.actions}).appendTo(y),x.append(y),S=y[0]},dimmer:function(){var e={debug:u.debug,dimmerName:"modals"},e=Q.extend(!0,e,u.dimmerSettings);void 0===Q.fn.dimmer?O.error(v.dimmer):(O.debug("Creating dimmer"),n=x.dimmer(e),H=O.is.scrolling(),u.detachable?(O.verbose("Modal is detachable, moving content into dimmer"),n.dimmer("add content",y)):O.set.undetached(),t=n.dimmer("get dimmer"))},id:function(){l=(Math.random().toString(16)+"000000000").slice(2,10),c="."+l,O.verbose("Creating unique id for element",l)},innerDimmer:function(){0===y.find(f.dimmer).length&&Q("<div/>",{class:m.innerDimmer}).prependTo(y)}},destroy:function(){d&&d.disconnect(),O.verbose("Destroying previous modal"),y.removeData(b).off(p),N.off(c),t.off(c),w.off(c),i&&i.off(c),x.dimmer("destroy")},observeChanges:function(){"MutationObserver"in X&&((d=new MutationObserver(function(e){function o(e){for(var t=[],i=0,n=e.length;i<n;i++)Array.prototype.push.apply(t,o(e[i].childNodes)),t.push(e[i]);return t}var i=!1,n=!1;e.every(function(e){var t;return"attributes"===e.type?"disabled"!==e.attributeName&&!Q(e.target).find(":input").addBack(":input")||(n=!0):(i=!0,t=Q(o(e.addedNodes)).filter("a[href], [tabindex], :input:enabled").filter(":visible"),e=Q(o(e.removedNodes)).filter("a[href], [tabindex], :input"),(0<t.length||0<e.length)&&(n=!0)),!n}),i&&u.observeChanges&&(O.debug("DOM tree modified, refreshing"),O.refresh()),n&&O.refreshInputs()})).observe(S,{attributeFilter:["class","disabled"],attributes:!0,childList:!0,subtree:!0}),O.debug("Setting up mutation observer",d))},refresh:function(){O.remove.scrolling(),O.cacheSizes(),O.can.useFlex()||O.set.modalOffset(),O.set.screenHeight(),O.set.type()},refreshModals:function(){s=y.siblings(f.modal),o=s.add(y)},refreshInputs:function(){i&&i.off("keydown"+c),i=y.find("a[href], [tabindex], :input:enabled").filter(":visible").filter(function(){return 0===Q(this).closest(".disabled").length}),y.removeAttr("tabindex"),0===i.length&&(i=y).attr("tabindex",-1),i.first().on("keydown"+c,O.event.inputKeyDown.first),i.last().on("keydown"+c,O.event.inputKeyDown.last),u.autofocus&&0===i.filter(":focus").length&&O.set.autofocus()},attachEvents:function(e,t){var i=Q(e);t=U(O[t])?O[t]:O.toggle,0<i.length?(O.debug("Attaching modal events to element",e,t),i.off(p).on("click"+p,t)):O.error(v.notFound,e)},bind:{events:function(){O.verbose("Attaching events"),y.on("click"+p,f.close,O.event.close).on("click"+p,f.approve,O.event.approve).on("click"+p,f.deny,O.event.deny),w.on("keyup"+c,O.event.closeKeyUp),N.on("resize"+c,O.event.resize).on("focus"+c,O.event.focus)},scrollLock:function(){n[0].addEventListener("touchmove",O.event.preventScroll,{passive:!1})}},unbind:{scrollLock:function(){n[0].removeEventListener("touchmove",O.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,Q(this))?O.verbose("Approve callback returned false cancelling hide"):(A=!0,O.hide(function(){A=!1}))},preventScroll:function(e){-1!==e.target.className.indexOf("dimmer")&&e.preventDefault()},deny:function(){A||!1===u.onDeny.call(S,Q(this))?O.verbose("Deny callback returned false cancelling hide"):(A=!0,O.hide(function(){A=!1}))},close:function(){O.hide()},closeKeyUp:function(e){e=e.which;e!==u.keys.enter&&e!==u.keys.space||!y.hasClass(m.front)||O.hide()},inputKeyDown:{first:function(e){e.which===u.keys.tab&&e.shiftKey&&(i.last().trigger("focus"),e.preventDefault())},last:function(e){e.which!==u.keys.tab||e.shiftKey||(i.first().trigger("focus"),e.preventDefault())}},mousedown:function(e){var t=Q(e.target),i=O.is.rtl();(a=0<t.closest(f.modal).length)&&O.verbose("Mouse down event registered inside the modal"),(r=O.is.scrolling()&&(!i&&N.outerWidth()-u.scrollbarWidth<=e.clientX||i&&u.scrollbarWidth>=e.clientX))&&O.verbose("Mouse down event registered inside the scrollbar")},mouseup:function(e){if(u.closable)if(a)O.debug("Dimmer clicked but mouse down was initially registered inside the modal");else if(r)O.debug("Dimmer clicked but mouse down was initially registered inside the scrollbar");else{var t=0<Q(e.target).closest(f.modal).length,e=Q.contains(R.documentElement,e.target);if(!t&&e&&O.is.active()&&y.hasClass(m.front)){if(O.debug("Dimmer clicked, hiding all modals"),u.allowMultiple){if(!O.hideAll())return}else if(!O.hide())return;O.remove.clickaway()}}else O.verbose("Dimmer clicked but closable setting is disabled")},debounce:function(e,t){clearTimeout(O.timer),O.timer=setTimeout(e,t)},keyboard:function(e){e.which===u.keys.escape&&(u.closable?(O.debug("Escape key pressed hiding modal"),y.hasClass(m.front)&&O.hide()):O.debug("Escape key pressed, but closable is set to false"),e.preventDefault())},resize:function(){n.dimmer("is active")&&(O.is.animating()||O.is.active())&&requestAnimationFrame(O.refresh)},focus:function(){n.dimmer("is active")&&O.is.active()&&u.autofocus&&requestAnimationFrame(O.set.autofocus)}},toggle:function(){O.is.active()||O.is.animating()?O.hide():O.show()},show:function(e){e=U(e)?e:function(){},O.refreshModals(),O.set.dimmerSettings(),O.set.dimmerStyles(),O.showModal(e)},hide:function(e){return e=U(e)?e:function(){},O.refreshModals(),O.hideModal(e)},showModal:function(e){e=U(e)?e:function(){},O.is.animating()||!O.is.active()?!1===u.onShow.call(S)?O.verbose("Show callback returned false cancelling show"):(F=O.has.scrollbar(),O.showDimmer(),O.cacheSizes(),F&&O.set.bodyMargin(),O.can.useFlex()?O.remove.legacy():(O.set.legacy(),O.set.modalOffset(),O.debug("Using non-flex legacy modal positioning.")),O.set.screenHeight(),O.set.type(),O.set.clickaway(),!u.allowMultiple&&O.others.active()?O.hideOthers(O.showModal):(A=!1,u.allowMultiple&&(O.others.active()&&s.filter("."+m.active).find(f.dimmer).addClass("active"),u.detachable&&y.detach().appendTo(t)),u.transition&&void 0!==Q.fn.transition&&y.transition("is supported")?(O.debug("Showing modal with css animations"),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&&O.add.keyboardShortcuts(),O.save.focus(),O.set.active(),O.refreshInputs(),e()}})):O.error(v.noTransition))):O.debug("Modal is already visible")},hideModal:function(e,t,i){var n=s.filter("."+m.active).last();if(e=U(e)?e:function(){},!1===u.onHide.call(S,Q(this)))return O.verbose("Hide callback returned false cancelling hide"),A=!1;(O.is.animating()||O.is.active())&&(O.debug("Hiding modal"),u.transition&&void 0!==Q.fn.transition&&y.transition("is supported")?(O.remove.active(),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(){O.others.active()||O.others.animating()||t||O.hideDimmer(),u.keyboardShortcuts&&!O.others.active()&&O.remove.keyboardShortcuts()},onComplete:function(){O.unbind.scrollLock(),O.remove.active(),u.allowMultiple&&(n.addClass(m.front),y.removeClass(m.front),(i?o:n).find(f.dimmer).removeClass("active")),U(u.onHidden)&&u.onHidden.call(S),O.remove.dimmerStyles(),O.restore.focus(),e()}})):O.error(v.noTransition))},showDimmer:function(){n.dimmer("is animating")||!n.dimmer("is active")?(F&&(k||t.css("top",n.scrollTop()),O.save.bodyMargin()),O.debug("Showing dimmer"),n.dimmer("show")):O.debug("Dimmer already visible")},hideDimmer:function(){n.dimmer("is animating")||n.dimmer("is active")?(O.unbind.scrollLock(),n.dimmer("hide",function(){F&&O.restore.bodyMargin(),O.remove.clickaway(),O.remove.screenHeight()})):O.debug("Dimmer is not visible cannot hide")},hideAll:function(i){var n,e=o.filter("."+m.active+", ."+m.animating);if(i=U(i)?i:function(){},0<e.length)return O.debug("Hiding all visible modals"),n=!0,Q(e.get().reverse()).each(function(e,t){n=n&&Q(t).modal("hide modal",i,!1,!0)}),n&&O.hideDimmer(),n},hideOthers:function(e){var t=s.filter("."+m.active+", ."+m.animating);e=U(e)?e:function(){},0<t.length&&(O.debug("Hiding other modals",s),t.modal("hide modal",e,!0))},others:{active:function(){return 0<s.filter("."+m.active).length},animating:function(){return 0<s.filter("."+m.animating).length}},add:{keyboardShortcuts:function(){O.verbose("Adding keyboard shortcuts"),I.on("keydown"+p,O.event.keyboard)}},save:{focus:function(){0<Q(R.activeElement).closest(y).length||(e=Q(R.activeElement).trigger("blur"))},bodyMargin:function(){D=x.css((k?"margin-":"padding-")+(O.can.leftBodyScrollbar()?"left":"right"));var e=parseInt(D.replace(/[^\d.]/g,""),10),t=k?X.innerWidth-R.documentElement.clientWidth:x[0].offsetWidth-x[0].clientWidth;T=e+t}},restore:{focus:function(){e&&0<e.length&&u.restoreFocus&&e.trigger("focus")},bodyMargin:function(){var i=O.can.leftBodyScrollbar()?"left":"right";x.css((k?"margin-":"padding-")+i,D),x.find(f.bodyFixed.replace("right",i)).each(function(){var e=Q(this),t="fixed"===e.css("position")?"padding-"+i:i;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),n.removeClass(m.blurring)},bodyStyle:function(){""===x.attr("style")&&(O.verbose("Removing style attribute"),x.removeAttr("style"))},screenHeight:function(){O.debug("Removing page height"),x.css("height",""),O.remove.bodyStyle()},keyboardShortcuts:function(){O.verbose("Removing keyboard shortcuts"),I.off("keydown"+p)},scrolling:function(){H||n.removeClass(m.scrolling),y.removeClass(m.scrolling)}},cacheSizes:function(){y.addClass(m.loading);var e=y.prop("scrollHeight"),t=y.outerWidth(),i=y.outerHeight();void 0!==O.cache.pageHeight&&0===i||(Q.extend(O.cache,{pageHeight:I.outerHeight(),width:t,height:i+u.offset,scrollHeight:e+u.offset,contextHeight:(k?N:n).height()}),O.cache.topOffset=-O.cache.height/2),y.removeClass(m.loading),O.debug("Caching modal and container sizes",O.cache)},helpers:{deQuote:function(e){return String(e).replace(/"/g,"")},escape:function(e,t){if(t)return e;var i={"<":"<",">":">",'"':""","'":"'","`":"`"};return/["&'<>`]/.test(e)?(e=e.replace(/&(?![\d#a-z]{1,12};)/gi,"&")).replace(/["'<>`]/g,function(e){return i[e]}):e}},can:{leftBodyScrollbar:function(){return void 0===O.cache.leftBodyScrollbar&&(O.cache.leftBodyScrollbar=O.is.rtl()&&(O.is.iframe&&!O.is.firefox()||O.is.safari()||O.is.edge()||O.is.ie())),O.cache.leftBodyScrollbar},useFlex:function(){return"auto"===u.useFlex?u.detachable&&!O.is.ie():(u.useFlex&&O.is.ie()?O.debug("useFlex true is not supported in IE"):u.useFlex&&!u.detachable&&O.debug("useFlex true in combination with detachable false is not supported"),u.useFlex)},fit:function(){var e=O.cache.contextHeight,t=O.cache.contextHeight/2,i=O.cache.topOffset,n=O.cache.scrollHeight,o=O.cache.height,s=u.padding;return o<n?t+i+n+s<e:o+2*s<e}},has:{configActions:function(){return Array.isArray(u.actions)&&0<u.actions.length},scrollbar:function(){return k||"hidden"!==x.css("overflow-y")}},is:{active:function(){return y.hasClass(m.active)},ie:function(){var e,t;return void 0===O.cache.isIE&&(e=!X.ActiveXObject&&"ActiveXObject"in X,t="ActiveXObject"in X,O.cache.isIE=e||t),O.cache.isIE},animating:function(){return y.transition("is supported")?y.transition("is animating"):y.is(":visible")},scrolling:function(){return n.hasClass(m.scrolling)},modernBrowser:function(){return!(X.ActiveXObject||"ActiveXObject"in X)},rtl:function(){return void 0===O.cache.isRTL&&(O.cache.isRTL="rtl"===y.attr("dir")||"rtl"===y.css("direction")||"rtl"===j.attr("dir")||"rtl"===j.css("direction")||"rtl"===x.attr("dir")||"rtl"===x.css("direction")),O.cache.isRTL},safari:function(){return void 0===O.cache.isSafari&&(O.cache.isSafari=/constructor/i.test(X.HTMLElement)||!!X.ApplePaySession),O.cache.isSafari},edge:function(){return void 0===O.cache.isEdge&&(O.cache.isEdge=!!X.setImmediate&&!O.is.ie()),O.cache.isEdge},firefox:function(){return void 0===O.cache.isFirefox&&(O.cache.isFirefox=!!X.InstallTrigger),O.cache.isFirefox},iframe:function(){return!(self===top)}},set:{autofocus:function(){var e=i.filter("[autofocus]"),t=i.filter(":input"),e=(0<e.length?e:0<t.length?t:i.filter(":not(i.close)")).first();0<(e=0===e.length&&0<i.length?i.first():e).length&&e.trigger("focus")},bodyMargin:function(){var i=O.can.leftBodyScrollbar()?"left":"right";(u.detachable||O.can.fit())&&x.css((k?"margin-":"padding-")+i,T+"px"),x.find(f.bodyFixed.replace("right",i)).each(function(){var e=Q(this),t="fixed"===e.css("position")?"padding-"+i:i;e.css(t,"calc("+e.css(t)+" + "+T+"px)")})},clickaway:function(){u.detachable||y.on("mousedown"+c,O.event.mousedown),t.on("mousedown"+c,O.event.mousedown),t.on("mouseup"+c,O.event.mouseup)},dimmerSettings:function(){var e;void 0===Q.fn.dimmer?O.error(v.dimmer):(e={debug:u.debug,dimmerName:"modals",closable:"auto",useFlex:O.can.useFlex(),duration:{show:u.transition.showDuration||u.duration,hide:u.transition.hideDuration||u.duration}},e=Q.extend(!0,e,u.dimmerSettings),u.inverted&&(e.variation=void 0!==e.variation?e.variation+" inverted":"inverted"),x.dimmer("setting",e))},dimmerStyles:function(){u.inverted?t.addClass(m.inverted):t.removeClass(m.inverted),u.blurring?n.addClass(m.blurring):n.removeClass(m.blurring)},modalOffset:function(){var e;u.detachable?y.css({marginTop:!y.hasClass("aligned")&&O.can.fit()?-O.cache.height/2:u.padding/2,marginLeft:-O.cache.width/2}):(e=O.can.fit(),y.css({top:!y.hasClass("aligned")&&e?I.scrollTop()+(O.cache.contextHeight-O.cache.height)/2:!e||y.hasClass("top")?I.scrollTop()+u.padding:I.scrollTop()+(O.cache.contextHeight-O.cache.height-u.padding),marginLeft:-O.cache.width/2})),O.verbose("Setting modal offset for legacy mode")},screenHeight:function(){O.can.fit()?x.css("height",""):y.hasClass("bottom")||(O.debug("Modal is taller than page content, resizing page height"),x.css("height",O.cache.height+2*u.padding+"px"))},active:function(){y.addClass(m.active+" "+m.front),s.filter("."+m.active).removeClass(m.front)},scrolling:function(){n.addClass(m.scrolling),y.addClass(m.scrolling),O.unbind.scrollLock()},legacy:function(){y.addClass(m.legacy)},type:function(){O.can.fit()?(O.verbose("Modal fits on screen"),O.others.active()||O.others.animating()||(O.remove.scrolling(),O.bind.scrollLock())):y.hasClass("bottom")?O.verbose("Bottom aligned modal not fitting on screen is unsupported for scrolling"):(O.verbose("Modal cannot fit on screen setting to scrolling"),O.set.scrolling())},undetached:function(){n.addClass(m.undetached)}},setting:function(e,t){if(O.debug("Changing setting",e,t),Q.isPlainObject(e))Q.extend(!0,u,e);else{if(void 0===t)return u[e];Q.isPlainObject(u[e])?Q.extend(!0,u[e],t):u[e]=t}},internal:function(e,t){if(Q.isPlainObject(e))Q.extend(!0,O,e);else{if(void 0===t)return O[e];O[e]=t}},debug:function(){!u.silent&&u.debug&&(u.performance?O.performance.log(arguments):(O.debug=Function.prototype.bind.call(console.info,console,u.name+":"),O.debug.apply(console,arguments)))},verbose:function(){!u.silent&&u.verbose&&u.debug&&(u.performance?O.performance.log(arguments):(O.verbose=Function.prototype.bind.call(console.info,console,u.name+":"),O.verbose.apply(console,arguments)))},error:function(){u.silent||(O.error=Function.prototype.bind.call(console.error,console,u.name+":"),O.error.apply(console,arguments))},performance:{log:function(e){var t,i;u.performance&&(i=(t=Date.now())-(q||t),q=t,B.push({Name:e[0],Arguments:[].slice.call(e,1)||"",Element:S,"Execution Time":i})),clearTimeout(O.performance.timer),O.performance.timer=setTimeout(O.performance.display,500)},display:function(){var e=u.name+":",i=0;q=!1,clearTimeout(O.performance.timer),Q.each(B,function(e,t){i+=t["Execution Time"]}),e+=" "+i+"ms",z&&(e+=" '"+z+"'"),0<B.length&&(console.groupCollapsed(e),console.table?console.table(B):Q.each(B,function(e,t){console.log(t.Name+": "+t["Execution Time"]+"ms")}),console.groupEnd()),B=[]}},invoke:function(n,e,t){var o,s,i,a=M;return e=e||K,t=t||S,"string"==typeof n&&void 0!==a&&(n=n.split(/[ .]/),o=n.length-1,Q.each(n,function(e,t){var i=e!==o?t+n[e+1].charAt(0).toUpperCase()+n[e+1].slice(1):n;if(Q.isPlainObject(a[i])&&e!==o)a=a[i];else{if(void 0!==a[i])return s=a[i],!1;{if(!Q.isPlainObject(a[t])||e===o)return void 0!==a[t]?s=a[t]:O.error(v.method,n),!1;a=a[t]}}})),U(s)?i=s.apply(t,e):void 0!==s&&(i=s),Array.isArray(L)?L.push(i):void 0!==L?L=[L,i]:void 0!==i&&(L=i),s}};P?(void 0===M&&(U(u.templates[W])&&(u.autoShow=!0,u.className.modal=u.className.template,u=Q.extend(!0,{},u,u.templates[W].apply(O,K)),m=u.className,u.namespace,g=u.fields,v=u.error),O.initialize()),U(u.templates[W])||O.invoke(W)):(void 0!==M&&M.invoke("destroy"),O.initialize(),L=y)}),void 0!==L?L:this},Q.modal=Q.fn.modal,Q.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:!0,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"}},Q.fn.modal.settings.templates={getArguments:function(e){e=[].slice.call(e);return Q.isPlainObject(e[0])?Q.extend({handler:function(){},content:"",title:""},e[0]):(U(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),i=t.handler;return{title:t.title,content:t.content,onApprove:i,actions:[{text:e.text.ok,class:e.className.ok,click:i}]}},confirm:function(){function e(){n.handler(!0)}function t(){n.handler(!1)}var i=this.get.settings(),n=i.templates.getArguments(arguments);return{title:n.title,content:n.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}]}},prompt:function(){function e(){var e=i.get.settings(),e=i.get.element().find(e.selector.prompt)[0];o.handler(Q(e).val())}function t(){o.handler(null)}var i=this,n=this.get.settings(),o=n.templates.getArguments(arguments);return 0===Q(Q.parseHTML(o.content)).filter(".ui.input").length&&(o.content+='<p><div class="'+this.helpers.deQuote(n.className.prompt)+'"><input placeholder="'+this.helpers.deQuote(o.placeholder||"")+'" type="text" value="'+this.helpers.deQuote(o.defaultValue||"")+'"></div></p>'),{title:o.title,content:o.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}]}}}}(jQuery,window,document);
|
11
|
+
!function(X,R,U){"use strict";function V(e){return"function"==typeof e&&"number"!=typeof e.nodeType}R=void 0!==R&&R.Math===Math?R:globalThis,X.fn.modal=function(L){var N,e=X(this),I=X(R),j=X(U),z=X("body"),q=e.selector||"",B=Date.now(),W=[],P=L,K="string"==typeof P,Q=[].slice.call(arguments,1);return e.each(function(){var i,o,s,e,n,t,a,r,c,l,d,u=X.isPlainObject(L)?X.extend(!0,{},X.fn.modal.settings,L):X.extend({},X.fn.modal.settings),f=u.selector,m=u.className,h=u.namespace,g=u.fields,v=u.error,p="."+h,b="module-"+h,y=X(this),x=[R,U].indexOf(u.context)<0?j.find(u.context):z,k=x[0]===z[0],w=y.find(f.closeIcon),C=y.hasClass("modal"),S=this,A=C?y.data(b):void 0,M=!1,D="",T="",H=!1,F=!1,O=!1,E={initialize:function(){var s;E.create.id(),C||(E.create.modal(),V(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.preserveHTML)).addClass(u.classTitle),""!==u.content&&y.find(f.content).html(E.helpers.escape(u.content,u.preserveHTML)).addClass(u.classContent),E.has.configActions()&&(0===(s=y.find(f.actions).addClass(u.classActions)).length?s=X("<div/>",{class:m.actions+" "+(u.classActions||"")}).appendTo(y):s.empty(),u.actions.forEach(function(e){var t=e[g.icon]?"<i "+(e[g.text]?'aria-hidden="true"':"")+' class="'+E.helpers.deQuote(e[g.icon])+' icon"></i>':"",i=E.helpers.escape(e[g.text]||"",u.preserveHTML),n=E.helpers.deQuote(e[g.class]||""),o=e[g.click]&&V(e[g.click])?e[g.click]:function(){};s.append(X("<button/>",{html:t+i,"aria-label":(e[g.text]||e[g.icon]||"").replace(/<[^>]+(>|$)/g,""),class:m.button+" "+n,on:{click:function(){var e=X(this);e.is(f.approve)||e.is(f.deny)||!1===o.call(S,y)||E.hide()}}}))})),E.cache={},E.verbose("Initializing dimmer",x),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"),A=E,y.data(b,A)},create:{modal:function(){var e;y=X("<div/>",{class:m.modal,role:"dialog","aria-modal":!0}),u.closeIcon&&(w=X("<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),X("<div/>",{class:m.title,id:e}).appendTo(y)),""!==u.content&&(e="_"+E.get.id()+"desc",y.attr("aria-describedby",e),X("<div/>",{class:m.content,id:e}).appendTo(y)),E.has.configActions()&&X("<div/>",{class:m.actions}).appendTo(y),x.append(y),S=y[0]},dimmer:function(){var e={debug:u.debug,dimmerName:"modals"},e=X.extend(!0,e,u.dimmerSettings);void 0===X.fn.dimmer?E.error(v.dimmer):(E.debug("Creating dimmer"),n=x.dimmer(e),H=E.is.scrolling(),u.detachable?(E.verbose("Modal is detachable, moving content into dimmer"),n.dimmer("add content",y)):E.set.undetached(),t=n.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&&X("<div/>",{class:m.innerDimmer}).prependTo(y)}},destroy:function(){d&&d.disconnect(),E.verbose("Destroying previous modal"),y.removeData(b).off(p),I.off(c),t.off(c),w.off(c),i&&i.off(c),x.dimmer("destroy")},observeChanges:function(){"MutationObserver"in R&&((d=new MutationObserver(function(e){function o(e){for(var t=[],i=0,n=e.length;i<n;i++)Array.prototype.push.apply(t,o(e[i].childNodes)),t.push(e[i]);return t}var i=!1,n=!1;e.every(function(e){var t;return"attributes"===e.type?O&&("disabled"===e.attributeName||0<X(e.target).find(":input").addBack(":input").length)&&(n=!0):(i=!0,t=X(o(e.addedNodes)).filter("a[href], [tabindex], :input:enabled").filter(":visible"),e=X(o(e.removedNodes)).filter("a[href], [tabindex], :input"),(0<t.length||0<e.length)&&(n=!0)),!n}),i&&u.observeChanges&&(E.debug("DOM tree modified, refreshing"),E.refresh()),n&&E.refreshInputs()})).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(){s=y.siblings(f.modal),o=s.add(y)},refreshInputs:function(){i&&i.off("keydown"+c),0===(i=y.find("a[href], [tabindex], :input:enabled").filter(":visible").filter(function(){return 0===X(this).closest(".disabled").length})).length?(i=y).attr("tabindex",-1):y.removeAttr("tabindex"),i.first().on("keydown"+c,E.event.inputKeyDown.first),i.last().on("keydown"+c,E.event.inputKeyDown.last),u.autofocus&&0===i.filter(":focus").length&&E.set.autofocus()},attachEvents:function(e,t){var i=X(e);t=V(E[t])?E[t]:E.toggle,0<i.length?(E.debug("Attaching modal events to element",e,t),i.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),I.on("resize"+c,E.event.resize).on("focus"+c,E.event.focus)},scrollLock:function(){n[0].addEventListener("touchmove",E.event.preventScroll,{passive:!1})}},unbind:{scrollLock:function(){n[0].removeEventListener("touchmove",E.event.preventScroll,{passive:!1})}},get:{id:function(){return l},element:function(){return y},settings:function(){return u}},event:{approve:function(){M||!1===u.onApprove.call(S,X(this))?E.verbose("Approve callback returned false cancelling hide"):(M=!0,E.hide(function(){M=!1}))},preventScroll:function(e){-1!==e.target.className.indexOf("dimmer")&&e.preventDefault()},deny:function(){M||!1===u.onDeny.call(S,X(this))?E.verbose("Deny callback returned false cancelling hide"):(M=!0,E.hide(function(){M=!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&&(i.last().trigger("focus"),e.preventDefault())},last:function(e){e.which!==u.keys.tab||e.shiftKey||(i.first().trigger("focus"),e.preventDefault())}},mousedown:function(e){var t=X(e.target),i=E.is.rtl();(a=0<t.closest(f.modal).length)&&E.verbose("Mouse down event registered inside the modal"),(r=E.is.scrolling()&&(!i&&I.outerWidth()-u.scrollbarWidth<=e.clientX||i&&u.scrollbarWidth>=e.clientX))&&E.verbose("Mouse down event registered inside the scrollbar")},mouseup:function(e){if(u.closable)if(a)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<X(e.target).closest(f.modal).length,e=X.contains(U.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(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(){n.dimmer("is active")&&(E.is.animating()||E.is.active())&&requestAnimationFrame(E.refresh)},focus:function(){n.dimmer("is active")&&E.is.active()&&u.autofocus&&requestAnimationFrame(E.set.autofocus)}},toggle:function(){E.is.active()||E.is.animating()?E.hide():E.show()},show:function(e){e=V(e)?e:function(){},E.refreshModals(),E.set.dimmerSettings(),E.set.dimmerStyles(),E.showModal(e)},hide:function(e){return e=V(e)?e:function(){},E.refreshModals(),E.hideModal(e)},showModal:function(e){e=V(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):(M=!1,u.allowMultiple&&(E.others.active()&&s.filter("."+m.active).find(f.dimmer).addClass("active"),u.detachable&&y.detach().appendTo(t)),u.transition&&void 0!==X.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,i){var n=s.filter("."+m.active).last();if(e=V(e)?e:function(){},!1===u.onHide.call(S,X(this)))return E.verbose("Hide callback returned false cancelling hide"),M=!1;(E.is.animating()||E.is.active())&&(E.debug("Hiding modal"),u.transition&&void 0!==X.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||E.hideDimmer(),u.keyboardShortcuts&&!E.others.active()&&E.remove.keyboardShortcuts()},onComplete:function(){E.unbind.scrollLock(),E.remove.active(),u.allowMultiple&&(n.addClass(m.front),y.removeClass(m.front),(i?o:n).find(f.dimmer).removeClass("active")),V(u.onHidden)&&u.onHidden.call(S),E.remove.dimmerStyles(),E.restore.focus(),e()}})):E.error(v.noTransition))},showDimmer:function(){n.dimmer("is animating")||!n.dimmer("is active")?(F&&(k||t.css("top",n.scrollTop()),E.save.bodyMargin()),E.debug("Showing dimmer"),n.dimmer("show")):E.debug("Dimmer already visible")},hideDimmer:function(){n.dimmer("is animating")||n.dimmer("is active")?(E.unbind.scrollLock(),n.dimmer("hide",function(){F&&E.restore.bodyMargin(),E.remove.clickaway(),E.remove.screenHeight()})):E.debug("Dimmer is not visible cannot hide")},hideAll:function(i){var n,e=o.filter("."+m.active+", ."+m.animating);if(i=V(i)?i:function(){},0<e.length)return E.debug("Hiding all visible modals"),n=!0,X(e.get().reverse()).each(function(e,t){n=n&&X(t).modal("hide modal",i,!1,!0)}),n&&E.hideDimmer(),n},hideOthers:function(e){var t=s.filter("."+m.active+", ."+m.animating);e=V(e)?e:function(){},0<t.length&&(E.debug("Hiding other modals",s),t.modal("hide modal",e,!0))},others:{active:function(){return 0<s.filter("."+m.active).length},animating:function(){return 0<s.filter("."+m.animating).length}},add:{keyboardShortcuts:function(){E.verbose("Adding keyboard shortcuts"),j.on("keydown"+p,E.event.keyboard)}},save:{focus:function(){0<X(U.activeElement).closest(y).length||(e=X(U.activeElement).trigger("blur"))},bodyMargin:function(){D=x.css((k?"margin-":"padding-")+(E.can.leftBodyScrollbar()?"left":"right"));var e=parseInt(D.replace(/[^\d.]/g,""),10),t=k?R.innerWidth-U.documentElement.clientWidth:x[0].offsetWidth-x[0].clientWidth;T=e+t}},restore:{focus:function(){e&&0<e.length&&u.restoreFocus&&e.trigger("focus")},bodyMargin:function(){var i=E.can.leftBodyScrollbar()?"left":"right";x.css((k?"margin-":"padding-")+i,D),x.find(f.bodyFixed.replace("right",i)).each(function(){var e=X(this),t="fixed"===e.css("position")?"padding-"+i:i;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),n.removeClass(m.blurring)},bodyStyle:function(){""===x.attr("style")&&(E.verbose("Removing style attribute"),x.removeAttr("style"))},screenHeight:function(){E.debug("Removing page height"),x.css("height",""),E.remove.bodyStyle()},keyboardShortcuts:function(){E.verbose("Removing keyboard shortcuts"),j.off("keydown"+p)},scrolling:function(){H||n.removeClass(m.scrolling),y.removeClass(m.scrolling)}},cacheSizes:function(){y.addClass(m.loading);var e=y.prop("scrollHeight"),t=y.outerWidth(),i=y.outerHeight();void 0!==E.cache.pageHeight&&0===i||(X.extend(E.cache,{pageHeight:j.outerHeight(),width:t,height:i+u.offset,scrollHeight:e+u.offset,contextHeight:(k?I:n).height()}),E.cache.topOffset=-E.cache.height/2),y.removeClass(m.loading),E.debug("Caching modal and container sizes",E.cache)},helpers:{deQuote:function(e){return String(e).replace(/"/g,"")},escape:function(e,t){if(t)return e;var i={"<":"<",">":">",'"':""","'":"'","`":"`"};return/["&'<>`]/.test(e)?(e=e.replace(/&(?![\d#a-z]{1,12};)/gi,"&")).replace(/["'<>`]/g,function(e){return i[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.is.edge()||E.is.ie())),E.cache.leftBodyScrollbar},useFlex:function(){return"auto"===u.useFlex?u.detachable&&!E.is.ie():(u.useFlex&&E.is.ie()?E.debug("useFlex true is not supported in IE"):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,i=E.cache.topOffset,n=E.cache.scrollHeight,o=E.cache.height,s=u.padding;return o<n?t+i+n+s<e:o+2*s<e}},has:{configActions:function(){return Array.isArray(u.actions)&&0<u.actions.length},scrollbar:function(){return k||"hidden"!==x.css("overflow-y")}},is:{active:function(){return y.hasClass(m.active)},ie:function(){var e,t;return void 0===E.cache.isIE&&(e=!R.ActiveXObject&&"ActiveXObject"in R,t="ActiveXObject"in R,E.cache.isIE=e||t),E.cache.isIE},animating:function(){return y.transition("is animating")},scrolling:function(){return n.hasClass(m.scrolling)},modernBrowser:function(){return!(R.ActiveXObject||"ActiveXObject"in R)},rtl:function(){return void 0===E.cache.isRTL&&(E.cache.isRTL="rtl"===y.attr("dir")||"rtl"===y.css("direction")||"rtl"===z.attr("dir")||"rtl"===z.css("direction")||"rtl"===x.attr("dir")||"rtl"===x.css("direction")),E.cache.isRTL},safari:function(){return void 0===E.cache.isSafari&&(E.cache.isSafari=/constructor/i.test(R.HTMLElement)||!!R.ApplePaySession),E.cache.isSafari},edge:function(){return void 0===E.cache.isEdge&&(E.cache.isEdge=!!R.setImmediate&&!E.is.ie()),E.cache.isEdge},firefox:function(){return void 0===E.cache.isFirefox&&(E.cache.isFirefox=!!R.InstallTrigger),E.cache.isFirefox},iframe:function(){return!(self===top)}},set:{observeAttributes:function(e){O=!1!==e},autofocus:function(){var e=i.filter("[autofocus]"),t=i.filter(":input"),e=(0<e.length?e:0<t.length?t:i.filter(":not(i.close)")).first();0<(e=0===e.length&&0<i.length?i.first():e).length&&e.trigger("focus")},bodyMargin:function(){var i=E.can.leftBodyScrollbar()?"left":"right";(u.detachable||E.can.fit())&&x.css((k?"margin-":"padding-")+i,T+"px"),x.find(f.bodyFixed.replace("right",i)).each(function(){var e=X(this),t="fixed"===e.css("position")?"padding-"+i:i;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===X.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=X.extend(!0,e,u.dimmerSettings),u.inverted&&(e.variation=void 0!==e.variation?e.variation+" inverted":"inverted"),x.dimmer("setting",e))},dimmerStyles:function(){u.inverted?t.addClass(m.inverted):t.removeClass(m.inverted),u.blurring?n.addClass(m.blurring):n.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?j.scrollTop()+(E.cache.contextHeight-E.cache.height)/2:!e||y.hasClass("top")?j.scrollTop()+u.padding:j.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()?x.css("height",""):y.hasClass("bottom")||(E.debug("Modal is taller than page content, resizing page height"),x.css("height",E.cache.height+2*u.padding+"px"))},active:function(){y.addClass(m.active+" "+m.front),s.filter("."+m.active).removeClass(m.front)},scrolling:function(){n.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(){n.addClass(m.undetached)}},setting:function(e,t){if(E.debug("Changing setting",e,t),X.isPlainObject(e))X.extend(!0,u,e);else{if(void 0===t)return u[e];X.isPlainObject(u[e])?X.extend(!0,u[e],t):u[e]=t}},internal:function(e,t){if(X.isPlainObject(e))X.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,i;u.performance&&(i=(t=Date.now())-(B||t),B=t,W.push({Name:e[0],Arguments:[].slice.call(e,1)||"",Element:S,"Execution Time":i})),clearTimeout(E.performance.timer),E.performance.timer=setTimeout(E.performance.display,500)},display:function(){var e=u.name+":",i=0;B=!1,clearTimeout(E.performance.timer),X.each(W,function(e,t){i+=t["Execution Time"]}),e+=" "+i+"ms",q&&(e+=" '"+q+"'"),0<W.length&&(console.groupCollapsed(e),console.table?console.table(W):X.each(W,function(e,t){console.log(t.Name+": "+t["Execution Time"]+"ms")}),console.groupEnd()),W=[]}},invoke:function(n,e,t){var o,s,i,a=A;return e=e||Q,t=t||S,"string"==typeof n&&void 0!==a&&(n=n.split(/[ .]/),o=n.length-1,X.each(n,function(e,t){var i=e!==o?t+n[e+1].charAt(0).toUpperCase()+n[e+1].slice(1):n;if(X.isPlainObject(a[i])&&e!==o)a=a[i];else{if(void 0!==a[i])return s=a[i],!1;{if(!X.isPlainObject(a[t])||e===o)return void 0!==a[t]?s=a[t]:E.error(v.method,n),!1;a=a[t]}}})),V(s)?i=s.apply(t,e):void 0!==s&&(i=s),Array.isArray(N)?N.push(i):void 0!==N?N=[N,i]:void 0!==i&&(N=i),s}};K?(void 0===A&&(V(u.templates[P])&&(u.autoShow=!0,u.className.modal=u.className.template,u=X.extend(!0,{},u,u.templates[P].apply(E,Q)),m=u.className,u.namespace,g=u.fields,v=u.error),E.initialize()),V(u.templates[P])||E.invoke(P)):(void 0!==A&&A.invoke("destroy"),E.initialize(),N=y)}),void 0!==N?N:this},X.modal=X.fn.modal,X.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:!0,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"}},X.fn.modal.settings.templates={getArguments:function(e){e=[].slice.call(e);return X.isPlainObject(e[0])?X.extend({handler:function(){},content:"",title:""},e[0]):(V(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),i=t.handler;return{title:t.title,content:t.content,onApprove:i,actions:[{text:e.text.ok,class:e.className.ok,click:i}]}},confirm:function(){function e(){n.handler(!0)}function t(){n.handler(!1)}var i=this.get.settings(),n=i.templates.getArguments(arguments);return{title:n.title,content:n.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}]}},prompt:function(){function e(){var e=i.get.settings(),e=i.get.element().find(e.selector.prompt)[0];o.handler(X(e).val())}function t(){o.handler(null)}var i=this,n=this.get.settings(),o=n.templates.getArguments(arguments);return 0===X(X.parseHTML(o.content)).filter(".ui.input").length&&(o.content+='<p><div class="'+this.helpers.deQuote(n.className.prompt)+'"><input placeholder="'+this.helpers.deQuote(o.placeholder||"")+'" type="text" value="'+this.helpers.deQuote(o.defaultValue||"")+'"></div></p>'),{title:o.title,content:o.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}]}}}}(jQuery,window,document);
|
package/dist/components/nag.css
CHANGED
package/dist/components/nag.js
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
/*!
|
2
|
-
* # Fomantic-UI 2.9.2-beta.
|
2
|
+
* # Fomantic-UI 2.9.2-beta.9+f3fb845 - Popup
|
3
3
|
* https://github.com/fomantic/Fomantic-UI/
|
4
4
|
*
|
5
5
|
*
|
@@ -594,8 +594,33 @@
|
|
594
594
|
*******************************/
|
595
595
|
|
596
596
|
.ui.loading.popup {
|
597
|
+
cursor: default;
|
598
|
+
pointer-events: none;
|
599
|
+
-webkit-user-select: none;
|
600
|
+
-ms-user-select: none;
|
601
|
+
user-select: none;
|
602
|
+
}
|
603
|
+
.ui.loading.popup * {
|
604
|
+
opacity: 0.3;
|
605
|
+
}
|
606
|
+
.ui.loading.popup::after {
|
607
|
+
position: absolute;
|
608
|
+
content: "";
|
609
|
+
top: 50%;
|
610
|
+
left: 50%;
|
611
|
+
margin: -1em 0 0 -1em;
|
612
|
+
width: 2em;
|
613
|
+
height: 2em;
|
614
|
+
animation: loader 0.6s infinite linear;
|
615
|
+
border: 0.2em solid #767676;
|
616
|
+
border-radius: 500rem;
|
617
|
+
box-shadow: 0 0 0 1px transparent;
|
618
|
+
visibility: visible;
|
619
|
+
z-index: 101;
|
620
|
+
}
|
621
|
+
.ui.invisible.popup {
|
597
622
|
display: block;
|
598
|
-
visibility: hidden;
|
623
|
+
visibility: hidden !important;
|
599
624
|
z-index: -1;
|
600
625
|
}
|
601
626
|
.ui.animating.popup,
|
@@ -685,6 +710,10 @@
|
|
685
710
|
color: #fff;
|
686
711
|
border: none;
|
687
712
|
}
|
713
|
+
.ui.ui.ui.primary.loading.popup::before,
|
714
|
+
.ui.primary.loading.popup {
|
715
|
+
background: #9bcbef;
|
716
|
+
}
|
688
717
|
.ui.ui.ui.primary.popup::before,
|
689
718
|
[data-tooltip][data-variation~="primary"]::before {
|
690
719
|
box-shadow: none;
|
@@ -696,6 +725,10 @@
|
|
696
725
|
background: #54c8ff;
|
697
726
|
color: #1b1c1d;
|
698
727
|
}
|
728
|
+
.ui.ui.ui.inverted.primary.loading.popup::before,
|
729
|
+
.ui.inverted.primary.loading.popup {
|
730
|
+
background: #007eba;
|
731
|
+
}
|
699
732
|
.ui.ui.ui.secondary.popup::before,
|
700
733
|
.ui.secondary.popup,
|
701
734
|
[data-tooltip][data-variation~="secondary"]::after,
|
@@ -704,6 +737,10 @@
|
|
704
737
|
color: #fff;
|
705
738
|
border: none;
|
706
739
|
}
|
740
|
+
.ui.ui.ui.secondary.loading.popup::before,
|
741
|
+
.ui.secondary.loading.popup {
|
742
|
+
background: #65696c;
|
743
|
+
}
|
707
744
|
.ui.ui.ui.secondary.popup::before,
|
708
745
|
[data-tooltip][data-variation~="secondary"]::before {
|
709
746
|
box-shadow: none;
|
@@ -715,6 +752,10 @@
|
|
715
752
|
background: #545454;
|
716
753
|
color: #1b1c1d;
|
717
754
|
}
|
755
|
+
.ui.ui.ui.inverted.secondary.loading.popup::before,
|
756
|
+
.ui.inverted.secondary.loading.popup {
|
757
|
+
background: #080808;
|
758
|
+
}
|
718
759
|
.ui.ui.ui.red.popup::before,
|
719
760
|
.ui.red.popup,
|
720
761
|
[data-tooltip][data-variation~="red"]::after,
|
@@ -723,6 +764,10 @@
|
|
723
764
|
color: #fff;
|
724
765
|
border: none;
|
725
766
|
}
|
767
|
+
.ui.ui.ui.red.loading.popup::before,
|
768
|
+
.ui.red.loading.popup {
|
769
|
+
background: #f1abab;
|
770
|
+
}
|
726
771
|
.ui.ui.ui.red.popup::before,
|
727
772
|
[data-tooltip][data-variation~="red"]::before {
|
728
773
|
box-shadow: none;
|
@@ -734,6 +779,10 @@
|
|
734
779
|
background: #ff695e;
|
735
780
|
color: #1b1c1d;
|
736
781
|
}
|
782
|
+
.ui.ui.ui.inverted.red.loading.popup::before,
|
783
|
+
.ui.inverted.red.loading.popup {
|
784
|
+
background: #c40d00;
|
785
|
+
}
|
737
786
|
.ui.ui.ui.orange.popup::before,
|
738
787
|
.ui.orange.popup,
|
739
788
|
[data-tooltip][data-variation~="orange"]::after,
|
@@ -742,6 +791,10 @@
|
|
742
791
|
color: #fff;
|
743
792
|
border: none;
|
744
793
|
}
|
794
|
+
.ui.ui.ui.orange.loading.popup::before,
|
795
|
+
.ui.orange.loading.popup {
|
796
|
+
background: #faccad;
|
797
|
+
}
|
745
798
|
.ui.ui.ui.orange.popup::before,
|
746
799
|
[data-tooltip][data-variation~="orange"]::before {
|
747
800
|
box-shadow: none;
|
@@ -753,6 +806,10 @@
|
|
753
806
|
background: #ff851b;
|
754
807
|
color: #1b1c1d;
|
755
808
|
}
|
809
|
+
.ui.ui.ui.inverted.orange.loading.popup::before,
|
810
|
+
.ui.inverted.orange.loading.popup {
|
811
|
+
background: #813c00;
|
812
|
+
}
|
756
813
|
.ui.ui.ui.yellow.popup::before,
|
757
814
|
.ui.yellow.popup,
|
758
815
|
[data-tooltip][data-variation~="yellow"]::after,
|
@@ -761,6 +818,10 @@
|
|
761
818
|
color: #fff;
|
762
819
|
border: none;
|
763
820
|
}
|
821
|
+
.ui.ui.ui.yellow.loading.popup::before,
|
822
|
+
.ui.yellow.loading.popup {
|
823
|
+
background: #fde59f;
|
824
|
+
}
|
764
825
|
.ui.ui.ui.yellow.popup::before,
|
765
826
|
[data-tooltip][data-variation~="yellow"]::before {
|
766
827
|
box-shadow: none;
|
@@ -772,6 +833,10 @@
|
|
772
833
|
background: #ffe21f;
|
773
834
|
color: #1b1c1d;
|
774
835
|
}
|
836
|
+
.ui.ui.ui.inverted.yellow.loading.popup::before,
|
837
|
+
.ui.inverted.yellow.loading.popup {
|
838
|
+
background: #857400;
|
839
|
+
}
|
775
840
|
.ui.ui.ui.olive.popup::before,
|
776
841
|
.ui.olive.popup,
|
777
842
|
[data-tooltip][data-variation~="olive"]::after,
|
@@ -780,6 +845,10 @@
|
|
780
845
|
color: #fff;
|
781
846
|
border: none;
|
782
847
|
}
|
848
|
+
.ui.ui.ui.olive.loading.popup::before,
|
849
|
+
.ui.olive.loading.popup {
|
850
|
+
background: #e4f18c;
|
851
|
+
}
|
783
852
|
.ui.ui.ui.olive.popup::before,
|
784
853
|
[data-tooltip][data-variation~="olive"]::before {
|
785
854
|
box-shadow: none;
|
@@ -791,6 +860,10 @@
|
|
791
860
|
background: #d9e778;
|
792
861
|
color: #1b1c1d;
|
793
862
|
}
|
863
|
+
.ui.ui.ui.inverted.olive.loading.popup::before,
|
864
|
+
.ui.inverted.olive.loading.popup {
|
865
|
+
background: #97a81e;
|
866
|
+
}
|
794
867
|
.ui.ui.ui.green.popup::before,
|
795
868
|
.ui.green.popup,
|
796
869
|
[data-tooltip][data-variation~="green"]::after,
|
@@ -799,6 +872,10 @@
|
|
799
872
|
color: #fff;
|
800
873
|
border: none;
|
801
874
|
}
|
875
|
+
.ui.ui.ui.green.loading.popup::before,
|
876
|
+
.ui.green.loading.popup {
|
877
|
+
background: #8aeaa0;
|
878
|
+
}
|
802
879
|
.ui.ui.ui.green.popup::before,
|
803
880
|
[data-tooltip][data-variation~="green"]::before {
|
804
881
|
box-shadow: none;
|
@@ -810,6 +887,10 @@
|
|
810
887
|
background: #2ecc40;
|
811
888
|
color: #1b1c1d;
|
812
889
|
}
|
890
|
+
.ui.ui.ui.inverted.green.loading.popup::before,
|
891
|
+
.ui.inverted.green.loading.popup {
|
892
|
+
background: #124f19;
|
893
|
+
}
|
813
894
|
.ui.ui.ui.teal.popup::before,
|
814
895
|
.ui.teal.popup,
|
815
896
|
[data-tooltip][data-variation~="teal"]::after,
|
@@ -818,6 +899,10 @@
|
|
818
899
|
color: #fff;
|
819
900
|
border: none;
|
820
901
|
}
|
902
|
+
.ui.ui.ui.teal.loading.popup::before,
|
903
|
+
.ui.teal.loading.popup {
|
904
|
+
background: #4ffff7;
|
905
|
+
}
|
821
906
|
.ui.ui.ui.teal.popup::before,
|
822
907
|
[data-tooltip][data-variation~="teal"]::before {
|
823
908
|
box-shadow: none;
|
@@ -829,6 +914,10 @@
|
|
829
914
|
background: #6dffff;
|
830
915
|
color: #1b1c1d;
|
831
916
|
}
|
917
|
+
.ui.ui.ui.inverted.teal.loading.popup::before,
|
918
|
+
.ui.inverted.teal.loading.popup {
|
919
|
+
background: #00d3d3;
|
920
|
+
}
|
832
921
|
.ui.ui.ui.blue.popup::before,
|
833
922
|
.ui.blue.popup,
|
834
923
|
[data-tooltip][data-variation~="blue"]::after,
|
@@ -837,6 +926,10 @@
|
|
837
926
|
color: #fff;
|
838
927
|
border: none;
|
839
928
|
}
|
929
|
+
.ui.ui.ui.blue.loading.popup::before,
|
930
|
+
.ui.blue.loading.popup {
|
931
|
+
background: #9bcbef;
|
932
|
+
}
|
840
933
|
.ui.ui.ui.blue.popup::before,
|
841
934
|
[data-tooltip][data-variation~="blue"]::before {
|
842
935
|
box-shadow: none;
|
@@ -848,6 +941,10 @@
|
|
848
941
|
background: #54c8ff;
|
849
942
|
color: #1b1c1d;
|
850
943
|
}
|
944
|
+
.ui.ui.ui.inverted.blue.loading.popup::before,
|
945
|
+
.ui.inverted.blue.loading.popup {
|
946
|
+
background: #007eba;
|
947
|
+
}
|
851
948
|
.ui.ui.ui.violet.popup::before,
|
852
949
|
.ui.violet.popup,
|
853
950
|
[data-tooltip][data-variation~="violet"]::after,
|
@@ -856,6 +953,10 @@
|
|
856
953
|
color: #fff;
|
857
954
|
border: none;
|
858
955
|
}
|
956
|
+
.ui.ui.ui.violet.loading.popup::before,
|
957
|
+
.ui.violet.loading.popup {
|
958
|
+
background: #c1adea;
|
959
|
+
}
|
859
960
|
.ui.ui.ui.violet.popup::before,
|
860
961
|
[data-tooltip][data-variation~="violet"]::before {
|
861
962
|
box-shadow: none;
|
@@ -867,6 +968,10 @@
|
|
867
968
|
background: #a291fb;
|
868
969
|
color: #1b1c1d;
|
869
970
|
}
|
971
|
+
.ui.ui.ui.inverted.violet.loading.popup::before,
|
972
|
+
.ui.inverted.violet.loading.popup {
|
973
|
+
background: #2d09ea;
|
974
|
+
}
|
870
975
|
.ui.ui.ui.purple.popup::before,
|
871
976
|
.ui.purple.popup,
|
872
977
|
[data-tooltip][data-variation~="purple"]::after,
|
@@ -875,6 +980,10 @@
|
|
875
980
|
color: #fff;
|
876
981
|
border: none;
|
877
982
|
}
|
983
|
+
.ui.ui.ui.purple.loading.popup::before,
|
984
|
+
.ui.purple.loading.popup {
|
985
|
+
background: #daabe9;
|
986
|
+
}
|
878
987
|
.ui.ui.ui.purple.popup::before,
|
879
988
|
[data-tooltip][data-variation~="purple"]::before {
|
880
989
|
box-shadow: none;
|
@@ -886,6 +995,10 @@
|
|
886
995
|
background: #dc73ff;
|
887
996
|
color: #1b1c1d;
|
888
997
|
}
|
998
|
+
.ui.ui.ui.inverted.purple.loading.popup::before,
|
999
|
+
.ui.inverted.purple.loading.popup {
|
1000
|
+
background: #a300d9;
|
1001
|
+
}
|
889
1002
|
.ui.ui.ui.pink.popup::before,
|
890
1003
|
.ui.pink.popup,
|
891
1004
|
[data-tooltip][data-variation~="pink"]::after,
|
@@ -894,6 +1007,10 @@
|
|
894
1007
|
color: #fff;
|
895
1008
|
border: none;
|
896
1009
|
}
|
1010
|
+
.ui.ui.ui.pink.loading.popup::before,
|
1011
|
+
.ui.pink.loading.popup {
|
1012
|
+
background: #f5bddc;
|
1013
|
+
}
|
897
1014
|
.ui.ui.ui.pink.popup::before,
|
898
1015
|
[data-tooltip][data-variation~="pink"]::before {
|
899
1016
|
box-shadow: none;
|
@@ -905,6 +1022,10 @@
|
|
905
1022
|
background: #ff8edf;
|
906
1023
|
color: #1b1c1d;
|
907
1024
|
}
|
1025
|
+
.ui.ui.ui.inverted.pink.loading.popup::before,
|
1026
|
+
.ui.inverted.pink.loading.popup {
|
1027
|
+
background: #f400af;
|
1028
|
+
}
|
908
1029
|
.ui.ui.ui.brown.popup::before,
|
909
1030
|
.ui.brown.popup,
|
910
1031
|
[data-tooltip][data-variation~="brown"]::after,
|
@@ -913,6 +1034,10 @@
|
|
913
1034
|
color: #fff;
|
914
1035
|
border: none;
|
915
1036
|
}
|
1037
|
+
.ui.ui.ui.brown.loading.popup::before,
|
1038
|
+
.ui.brown.loading.popup {
|
1039
|
+
background: #dbb8a2;
|
1040
|
+
}
|
916
1041
|
.ui.ui.ui.brown.popup::before,
|
917
1042
|
[data-tooltip][data-variation~="brown"]::before {
|
918
1043
|
box-shadow: none;
|
@@ -924,6 +1049,10 @@
|
|
924
1049
|
background: #d67c1c;
|
925
1050
|
color: #1b1c1d;
|
926
1051
|
}
|
1052
|
+
.ui.ui.ui.inverted.brown.loading.popup::before,
|
1053
|
+
.ui.inverted.brown.loading.popup {
|
1054
|
+
background: #4f2e0a;
|
1055
|
+
}
|
927
1056
|
.ui.ui.ui.grey.popup::before,
|
928
1057
|
.ui.grey.popup,
|
929
1058
|
[data-tooltip][data-variation~="grey"]::after,
|
@@ -932,6 +1061,10 @@
|
|
932
1061
|
color: #fff;
|
933
1062
|
border: none;
|
934
1063
|
}
|
1064
|
+
.ui.ui.ui.grey.loading.popup::before,
|
1065
|
+
.ui.grey.loading.popup {
|
1066
|
+
background: #c3c3c3;
|
1067
|
+
}
|
935
1068
|
.ui.ui.ui.grey.popup::before,
|
936
1069
|
[data-tooltip][data-variation~="grey"]::before {
|
937
1070
|
box-shadow: none;
|
@@ -943,6 +1076,10 @@
|
|
943
1076
|
background: #dcddde;
|
944
1077
|
color: #1b1c1d;
|
945
1078
|
}
|
1079
|
+
.ui.ui.ui.inverted.grey.loading.popup::before,
|
1080
|
+
.ui.inverted.grey.loading.popup {
|
1081
|
+
background: #8d9194;
|
1082
|
+
}
|
946
1083
|
.ui.ui.ui.black.popup::before,
|
947
1084
|
.ui.black.popup,
|
948
1085
|
[data-tooltip][data-variation~="black"]::after,
|
@@ -951,6 +1088,10 @@
|
|
951
1088
|
color: #fff;
|
952
1089
|
border: none;
|
953
1090
|
}
|
1091
|
+
.ui.ui.ui.black.loading.popup::before,
|
1092
|
+
.ui.black.loading.popup {
|
1093
|
+
background: #65696c;
|
1094
|
+
}
|
954
1095
|
.ui.ui.ui.black.popup::before,
|
955
1096
|
[data-tooltip][data-variation~="black"]::before {
|
956
1097
|
box-shadow: none;
|
@@ -962,6 +1103,10 @@
|
|
962
1103
|
background: #545454;
|
963
1104
|
color: #1b1c1d;
|
964
1105
|
}
|
1106
|
+
.ui.ui.ui.inverted.black.loading.popup::before,
|
1107
|
+
.ui.inverted.black.loading.popup {
|
1108
|
+
background: #080808;
|
1109
|
+
}
|
965
1110
|
|
966
1111
|
/* --------------
|
967
1112
|
Flowing
|
package/dist/components/popup.js
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
/*!
|
2
|
-
* # Fomantic-UI 2.9.2-beta.
|
2
|
+
* # Fomantic-UI 2.9.2-beta.9+f3fb845 - Popup
|
3
3
|
* https://github.com/fomantic/Fomantic-UI/
|
4
4
|
*
|
5
5
|
*
|
@@ -125,9 +125,9 @@
|
|
125
125
|
}
|
126
126
|
}
|
127
127
|
if (settings.popup) {
|
128
|
-
|
128
|
+
module.set.invisible();
|
129
129
|
$offsetParent = module.get.offsetParent();
|
130
|
-
|
130
|
+
module.remove.invisible();
|
131
131
|
if (settings.movePopup && module.has.popup() && module.get.offsetParent($popup)[0] !== $offsetParent[0]) {
|
132
132
|
module.debug('Moving popup to the same offset parent as target');
|
133
133
|
$popup
|
@@ -414,7 +414,7 @@
|
|
414
414
|
animate: {
|
415
415
|
show: function (callback) {
|
416
416
|
callback = isFunction(callback) ? callback : function () {};
|
417
|
-
if (settings.transition && module.can.useElement('transition')
|
417
|
+
if (settings.transition && module.can.useElement('transition')) {
|
418
418
|
module.set.visible();
|
419
419
|
$popup
|
420
420
|
.transition({
|
@@ -436,7 +436,7 @@
|
|
436
436
|
hide: function (callback) {
|
437
437
|
callback = isFunction(callback) ? callback : function () {};
|
438
438
|
module.debug('Hiding pop-up');
|
439
|
-
if (settings.transition && $.fn.transition !== undefined
|
439
|
+
if (settings.transition && $.fn.transition !== undefined) {
|
440
440
|
$popup
|
441
441
|
.transition({
|
442
442
|
animation: (settings.transition.hideMethod || settings.transition) + ' out',
|
@@ -901,8 +901,8 @@
|
|
901
901
|
.css(positioning)
|
902
902
|
.removeClass(className.position)
|
903
903
|
.addClass(position)
|
904
|
-
.addClass(className.loading)
|
905
904
|
;
|
905
|
+
module.set.invisible();
|
906
906
|
|
907
907
|
popupOffset = module.get.popupOffset();
|
908
908
|
|
@@ -926,7 +926,7 @@
|
|
926
926
|
module.debug('Popup could not find a position to display', $popup);
|
927
927
|
module.error(error.cannotPlace, element);
|
928
928
|
module.remove.attempts();
|
929
|
-
module.remove.
|
929
|
+
module.remove.invisible();
|
930
930
|
module.reset();
|
931
931
|
settings.onUnplaceable.call($popup, element);
|
932
932
|
|
@@ -935,7 +935,7 @@
|
|
935
935
|
}
|
936
936
|
module.debug('Position is on stage', position);
|
937
937
|
module.remove.attempts();
|
938
|
-
module.remove.
|
938
|
+
module.remove.invisible();
|
939
939
|
if (settings.setFluidWidth && module.is.fluid()) {
|
940
940
|
module.set.fluidWidth(calculations);
|
941
941
|
}
|
@@ -949,6 +949,14 @@
|
|
949
949
|
$popup.css('width', calculations.container.width);
|
950
950
|
},
|
951
951
|
|
952
|
+
loading: function () {
|
953
|
+
$popup.addClass(className.loading);
|
954
|
+
},
|
955
|
+
|
956
|
+
invisible: function () {
|
957
|
+
$popup.addClass(className.invisible);
|
958
|
+
},
|
959
|
+
|
952
960
|
variation: function (variation) {
|
953
961
|
variation = variation || module.get.variation();
|
954
962
|
if (variation && module.has.popup()) {
|
@@ -966,6 +974,9 @@
|
|
966
974
|
loading: function () {
|
967
975
|
$popup.removeClass(className.loading);
|
968
976
|
},
|
977
|
+
invisible: function () {
|
978
|
+
$popup.removeClass(className.invisible);
|
979
|
+
},
|
969
980
|
variation: function (variation) {
|
970
981
|
variation = variation || module.get.variation();
|
971
982
|
if (variation) {
|
@@ -1475,6 +1486,7 @@
|
|
1475
1486
|
basic: 'basic',
|
1476
1487
|
animating: 'animating',
|
1477
1488
|
dropdown: 'dropdown',
|
1489
|
+
invisible: 'invisible',
|
1478
1490
|
fluid: 'fluid',
|
1479
1491
|
loading: 'loading',
|
1480
1492
|
popup: 'ui popup',
|