fomantic-ui 2.8.8-beta.99 → 2.9.0-beta.100
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/.all-contributorsrc +188 -3
- package/.github/dependabot.yml +17 -0
- package/.github/workflows/ci.yml +1 -1
- package/CHANGELOG.md +139 -0
- package/CONTRIBUTING.md +1 -1
- package/CONTRIBUTORS.md +71 -37
- package/README.md +3 -3
- package/dist/components/accordion.css +50 -6
- package/dist/components/accordion.js +1 -1
- package/dist/components/accordion.min.css +2 -2
- package/dist/components/accordion.min.js +3 -3
- package/dist/components/ad.css +1 -1
- package/dist/components/ad.min.css +1 -1
- package/dist/components/api.js +26 -24
- package/dist/components/api.min.js +4 -4
- package/dist/components/breadcrumb.css +1 -1
- package/dist/components/breadcrumb.min.css +1 -1
- package/dist/components/button.css +81 -81
- package/dist/components/button.min.css +2 -2
- package/dist/components/calendar.css +1 -1
- package/dist/components/calendar.js +110 -11
- package/dist/components/calendar.min.css +1 -1
- package/dist/components/calendar.min.js +4 -4
- package/dist/components/card.css +26 -19
- package/dist/components/card.min.css +2 -2
- package/dist/components/checkbox.css +6 -4
- package/dist/components/checkbox.js +17 -11
- package/dist/components/checkbox.min.css +2 -2
- package/dist/components/checkbox.min.js +4 -4
- package/dist/components/comment.css +11 -11
- package/dist/components/comment.min.css +1 -1
- package/dist/components/container.css +3 -4
- package/dist/components/container.min.css +2 -2
- package/dist/components/dimmer.css +28 -14
- package/dist/components/dimmer.js +15 -12
- package/dist/components/dimmer.min.css +2 -2
- package/dist/components/dimmer.min.js +4 -4
- package/dist/components/divider.css +1 -1
- package/dist/components/divider.min.css +1 -1
- package/dist/components/dropdown.css +54 -7
- package/dist/components/dropdown.js +107 -77
- package/dist/components/dropdown.min.css +2 -2
- package/dist/components/dropdown.min.js +4 -4
- package/dist/components/embed.css +1 -1
- package/dist/components/embed.js +1 -1
- package/dist/components/embed.min.css +1 -1
- package/dist/components/embed.min.js +3 -3
- package/dist/components/emoji.css +2 -2
- package/dist/components/feed.css +28 -28
- package/dist/components/feed.min.css +2 -2
- package/dist/components/flag.css +731 -625
- package/dist/components/flag.min.css +2 -2
- package/dist/components/form.css +119 -54
- package/dist/components/form.js +51 -70
- package/dist/components/form.min.css +2 -2
- package/dist/components/form.min.js +4 -4
- package/dist/components/grid.css +13 -11
- package/dist/components/grid.min.css +2 -2
- package/dist/components/header.css +3 -3
- package/dist/components/header.min.css +2 -2
- package/dist/components/icon.css +86 -5
- package/dist/components/icon.min.css +2 -2
- package/dist/components/image.css +1 -1
- package/dist/components/image.min.css +1 -1
- package/dist/components/input.css +17 -2
- package/dist/components/input.min.css +2 -2
- package/dist/components/item.css +13 -13
- 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 +39 -37
- package/dist/components/loader.min.css +2 -2
- package/dist/components/menu.css +37 -11
- package/dist/components/menu.min.css +1 -1
- package/dist/components/message.css +78 -34
- package/dist/components/message.min.css +2 -2
- package/dist/components/modal.css +7 -5
- package/dist/components/modal.js +237 -41
- package/dist/components/modal.min.css +2 -2
- package/dist/components/modal.min.js +4 -4
- package/dist/components/nag.css +168 -16
- package/dist/components/nag.js +131 -65
- package/dist/components/nag.min.css +2 -2
- package/dist/components/nag.min.js +4 -4
- package/dist/components/placeholder.css +1 -1
- package/dist/components/placeholder.min.css +1 -1
- package/dist/components/popup.css +5 -3
- package/dist/components/popup.js +5 -5
- package/dist/components/popup.min.css +2 -2
- package/dist/components/popup.min.js +4 -4
- package/dist/components/progress.css +2 -1
- package/dist/components/progress.js +3 -3
- package/dist/components/progress.min.css +2 -2
- package/dist/components/progress.min.js +4 -4
- package/dist/components/rail.css +1 -1
- package/dist/components/rail.min.css +1 -1
- package/dist/components/rating.css +8 -62
- package/dist/components/rating.js +1 -1
- package/dist/components/rating.min.css +2 -2
- package/dist/components/rating.min.js +3 -3
- package/dist/components/reset.css +2 -3
- package/dist/components/reset.min.css +2 -2
- 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 +15 -13
- package/dist/components/search.min.css +1 -1
- package/dist/components/search.min.js +4 -4
- package/dist/components/segment.css +36 -6
- package/dist/components/segment.min.css +2 -2
- package/dist/components/shape.css +1 -1
- package/dist/components/shape.js +1 -1
- package/dist/components/shape.min.css +1 -1
- package/dist/components/shape.min.js +3 -3
- package/dist/components/sidebar.css +4 -2
- package/dist/components/sidebar.js +1 -1
- package/dist/components/sidebar.min.css +2 -2
- package/dist/components/sidebar.min.js +3 -3
- package/dist/components/site.css +61 -39
- package/dist/components/site.js +1 -1
- package/dist/components/site.min.css +2 -2
- package/dist/components/site.min.js +3 -3
- package/dist/components/slider.js +1 -1
- package/dist/components/slider.min.js +3 -3
- package/dist/components/state.js +1 -1
- package/dist/components/state.min.js +3 -3
- package/dist/components/statistic.css +1 -1
- package/dist/components/statistic.min.css +1 -1
- package/dist/components/step.css +4 -4
- package/dist/components/step.min.css +2 -2
- package/dist/components/sticky.css +1 -2
- package/dist/components/sticky.js +2 -2
- package/dist/components/sticky.min.css +2 -2
- package/dist/components/sticky.min.js +4 -4
- 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 +3 -3
- package/dist/components/table.css +5 -3
- package/dist/components/table.min.css +2 -2
- package/dist/components/text.css +1 -1
- package/dist/components/text.min.css +1 -1
- package/dist/components/toast.css +123 -10
- package/dist/components/toast.js +54 -27
- package/dist/components/toast.min.css +2 -2
- package/dist/components/toast.min.js +4 -4
- package/dist/components/transition.css +1 -1
- package/dist/components/transition.js +2 -2
- package/dist/components/transition.min.css +1 -1
- package/dist/components/transition.min.js +4 -4
- package/dist/components/visibility.js +2 -2
- package/dist/components/visibility.min.js +3 -3
- package/dist/semantic.css +2004 -1124
- package/dist/semantic.js +789 -377
- package/dist/semantic.min.css +4 -397
- package/dist/semantic.min.js +4 -4
- package/examples/assets/library/iframe-content.js +8 -8
- package/examples/assets/library/iframe.js +3 -3
- package/package.json +5 -5
- package/scripts/nightly-version.js +23 -8
- package/src/definitions/behaviors/api.js +25 -23
- package/src/definitions/behaviors/form.js +50 -69
- package/src/definitions/behaviors/visibility.js +1 -1
- package/src/definitions/collections/form.less +200 -142
- package/src/definitions/collections/grid.less +717 -681
- package/src/definitions/collections/menu.less +177 -128
- package/src/definitions/collections/message.less +77 -44
- package/src/definitions/collections/table.less +255 -242
- package/src/definitions/elements/button.less +360 -347
- package/src/definitions/elements/container.less +16 -8
- package/src/definitions/elements/emoji.less +15 -9
- package/src/definitions/elements/flag.less +7 -17
- package/src/definitions/elements/header.less +44 -37
- package/src/definitions/elements/icon.less +121 -43
- package/src/definitions/elements/input.less +23 -7
- package/src/definitions/elements/label.less +92 -91
- package/src/definitions/elements/list.less +55 -45
- package/src/definitions/elements/loader.less +38 -35
- package/src/definitions/elements/segment.less +51 -23
- package/src/definitions/elements/step.less +52 -48
- package/src/definitions/elements/text.less +17 -15
- package/src/definitions/globals/site.less +23 -2
- package/src/definitions/modules/accordion.less +55 -5
- package/src/definitions/modules/calendar.js +109 -10
- package/src/definitions/modules/checkbox.js +16 -10
- package/src/definitions/modules/checkbox.less +44 -186
- package/src/definitions/modules/dimmer.js +14 -11
- package/src/definitions/modules/dimmer.less +21 -8
- package/src/definitions/modules/dropdown.js +106 -76
- package/src/definitions/modules/dropdown.less +148 -89
- package/src/definitions/modules/modal.js +236 -40
- package/src/definitions/modules/modal.less +6 -4
- package/src/definitions/modules/nag.js +130 -64
- package/src/definitions/modules/nag.less +105 -40
- package/src/definitions/modules/popup.js +4 -4
- package/src/definitions/modules/popup.less +5 -1
- package/src/definitions/modules/progress.js +2 -2
- package/src/definitions/modules/progress.less +20 -18
- package/src/definitions/modules/rating.less +50 -42
- package/src/definitions/modules/search.js +14 -12
- package/src/definitions/modules/search.less +32 -16
- package/src/definitions/modules/sidebar.less +33 -19
- package/src/definitions/modules/slider.less +43 -42
- package/src/definitions/modules/sticky.js +1 -1
- package/src/definitions/modules/toast.js +53 -26
- package/src/definitions/modules/toast.less +139 -25
- package/src/definitions/modules/transition.js +1 -1
- package/src/definitions/views/card.less +402 -361
- package/src/definitions/views/comment.less +92 -81
- package/src/definitions/views/feed.less +164 -144
- package/src/definitions/views/item.less +249 -196
- package/src/definitions/views/statistic.less +90 -88
- package/src/themes/default/collections/grid.variables +8 -8
- package/src/themes/default/collections/menu.variables +6 -0
- package/src/themes/default/collections/table.variables +1 -1
- package/src/themes/default/elements/button.variables +2 -1
- package/src/themes/default/elements/flag.overrides +1635 -986
- package/src/themes/default/elements/flag.variables +7 -5
- package/src/themes/default/elements/header.variables +2 -2
- package/src/themes/default/elements/icon.overrides +35 -28
- package/src/themes/default/elements/icon.variables +4 -0
- package/src/themes/default/elements/list.variables +1 -1
- package/src/themes/default/elements/step.overrides +1 -1
- package/src/themes/default/globals/colors.less +7 -7
- package/src/themes/default/globals/site.variables +19 -9
- package/src/themes/default/globals/variation.variables +119 -6
- package/src/themes/default/modules/accordion.variables +15 -0
- package/src/themes/default/modules/checkbox.variables +16 -16
- package/src/themes/default/modules/dimmer.variables +1 -1
- package/src/themes/default/modules/dropdown.variables +12 -5
- package/src/themes/default/modules/modal.variables +2 -2
- package/src/themes/default/modules/nag.variables +3 -1
- package/src/themes/default/modules/toast.variables +5 -1
- package/src/themes/default/views/card.variables +1 -1
- package/src/themes/famfamfam/elements/flag.overrides +1026 -0
- package/src/themes/famfamfam/elements/flag.variables +13 -0
- package/tasks/admin/components/init.js +2 -2
- package/tasks/admin/distributions/init.js +2 -2
- package/tasks/build/css.js +6 -1
- package/tasks/config/project/release.js +2 -2
- package/tasks/config/tasks.js +13 -9
- package/test/helpers/sinon.js +1 -1
@@ -1,11 +1,11 @@
|
|
1
|
-
|
2
|
-
* # Fomantic UI - 2.
|
1
|
+
/*
|
2
|
+
* # Fomantic UI - 2.9.0-beta.100
|
3
3
|
* https://github.com/fomantic/Fomantic-UI
|
4
4
|
* http://fomantic-ui.com/
|
5
5
|
*
|
6
|
-
* Copyright
|
6
|
+
* Copyright 2021 Contributors
|
7
7
|
* Released under the MIT license
|
8
8
|
* http://opensource.org/licenses/MIT
|
9
9
|
*
|
10
10
|
*/
|
11
|
-
!function(V,W,M,z){"use strict";V.isFunction=V.isFunction||function(t){return"function"==typeof t&&"number"!=typeof t.nodeType},W=void 0!==W&&W.Math==Math?W:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")(),V.fn.popup=function(x){var E,t=V(this),k=V(M),S=V(W),A=V("body"),F=t.selector||"",O="ontouchstart"in M.documentElement?"touchstart":"click",D=(new Date).getTime(),j=[],R=x,H="string"==typeof R,N=[].slice.call(arguments,1);return t.each(function(){var u,c,t,e,o,d,f=V.isPlainObject(x)?V.extend(!0,{},V.fn.popup.settings,x):V.extend({},V.fn.popup.settings),i=f.selector,h=f.className,g=f.error,m=f.metadata,n=f.namespace,r="."+f.namespace,a="module-"+n,v=V(this),s=V(f.context),p=V(f.scrollContext),b=V(f.boundary),w=f.target?V(f.target):v,y=0,l=!1,P=!1,C=this,T=v.data(a);d={initialize:function(){d.debug("Initializing",v),d.createID(),d.bind.events(),!d.exists()&&f.preserve&&d.create(),f.observeChanges&&d.observeChanges(),d.instantiate()},instantiate:function(){d.verbose("Storing instance",d),T=d,v.data(a,T)},observeChanges:function(){"MutationObserver"in W&&((t=new MutationObserver(d.event.documentChanged)).observe(M,{childList:!0,subtree:!0}),d.debug("Setting up mutation observer",t))},refresh:function(){f.popup?u=V(f.popup).eq(0):f.inline&&(u=w.nextAll(i.popup).eq(0),f.popup=u),f.popup?(u.addClass(h.loading),c=d.get.offsetParent(),u.removeClass(h.loading),f.movePopup&&d.has.popup()&&d.get.offsetParent(u)[0]!==c[0]&&(d.debug("Moving popup to the same offset parent as target"),u.detach().appendTo(c))):c=f.inline?d.get.offsetParent(w):d.has.popup()?d.get.offsetParent(u):A,c.is("html")&&c[0]!==A[0]&&(d.debug("Setting page as offset parent"),c=A),d.get.variation()&&d.set.variation()},reposition:function(){d.refresh(),d.set.position()},destroy:function(){d.debug("Destroying previous module"),t&&t.disconnect(),u&&!f.preserve&&d.removePopup(),clearTimeout(d.hideTimer),clearTimeout(d.showTimer),d.unbind.close(),d.unbind.events(),v.removeData(a)},event:{start:function(t){var e=V.isPlainObject(f.delay)?f.delay.show:f.delay;clearTimeout(d.hideTimer),(!P||P&&f.addTouchEvents)&&(d.showTimer=setTimeout(d.show,e))},end:function(){var t=V.isPlainObject(f.delay)?f.delay.hide:f.delay;clearTimeout(d.showTimer),d.hideTimer=setTimeout(d.hide,t)},touchstart:function(t){P=!0,f.addTouchEvents&&d.show()},resize:function(){d.is.visible()&&d.set.position()},documentChanged:function(t){[].forEach.call(t,function(t){t.removedNodes&&[].forEach.call(t.removedNodes,function(t){(t==C||0<V(t).find(C).length)&&(d.debug("Element removed from DOM, tearing down events"),d.destroy())})})},hideGracefully:function(t){var e=V(t.target),o=V.contains(M.documentElement,t.target),n=0<e.closest(i.popup).length;t&&!n&&o?(d.debug("Click occurred outside popup hiding popup"),d.hide()):d.debug("Click was inside popup, keeping popup open")}},create:function(){var t=d.get.html(),e=d.get.title(),o=d.get.content();t||o||e?(d.debug("Creating pop-up html"),t=t||f.templates.popup({title:e,content:o}),u=V("<div/>").addClass(h.popup).data(m.activator,v).html(t),f.inline?(d.verbose("Inserting popup element inline",u),u.insertAfter(v)):(d.verbose("Appending popup element to body",u),u.appendTo(s)),d.refresh(),d.set.variation(),f.hoverable&&d.bind.popup(),f.onCreate.call(u,C)):f.popup?(V(f.popup).data(m.activator,v),d.verbose("Used popup specified in settings"),d.refresh(),f.hoverable&&d.bind.popup()):0!==w.next(i.popup).length?(d.verbose("Pre-existing popup found"),f.inline=!0,f.popup=w.next(i.popup).data(m.activator,v),d.refresh(),f.hoverable&&d.bind.popup()):d.debug("No content specified skipping display",C)},createID:function(){o=(Math.random().toString(16)+"000000000").substr(2,8),e="."+o,d.verbose("Creating unique id for element",o)},toggle:function(){d.debug("Toggling pop-up"),d.is.hidden()?(d.debug("Popup is hidden, showing pop-up"),d.unbind.close(),d.show()):(d.debug("Popup is visible, hiding pop-up"),d.hide())},show:function(t){if(t=t||function(){},d.debug("Showing pop-up",f.transition),d.is.hidden()&&(!d.is.active()||!d.is.dropdown())){if(d.exists()||d.create(),!1===f.onShow.call(u,C))return void d.debug("onShow callback returned false, cancelling popup animation");f.preserve||f.popup||d.refresh(),u&&d.set.position()&&(d.save.conditions(),f.exclusive&&d.hideAll(),d.animate.show(t))}},hide:function(t){if(t=t||function(){},d.is.visible()||d.is.animating()){if(!1===f.onHide.call(u,C))return void d.debug("onHide callback returned false, cancelling popup animation");d.remove.visible(),d.unbind.close(),d.restore.conditions(),d.animate.hide(t)}},hideAll:function(){V(i.popup).filter("."+h.popupVisible).each(function(){V(this).data(m.activator).popup("hide")})},exists:function(){return!!u&&(f.inline||f.popup?d.has.popup():1<=u.closest(s).length)},removePopup:function(){d.has.popup()&&!f.popup&&(d.debug("Removing popup",u),u.remove(),u=z,f.onRemove.call(u,C))},save:{conditions:function(){d.cache={title:v.attr("title")},d.cache.title&&v.removeAttr("title"),d.verbose("Saving original attributes",d.cache.title)}},restore:{conditions:function(){return d.cache&&d.cache.title&&(v.attr("title",d.cache.title),d.verbose("Restoring original attributes",d.cache.title)),!0}},supports:{svg:function(){return"undefined"!=typeof SVGGraphicsElement}},animate:{show:function(t){t=V.isFunction(t)?t:function(){},f.transition&&V.fn.transition!==z&&v.transition("is supported")?(d.set.visible(),u.transition({animation:f.transition+" in",queue:!1,debug:f.debug,verbose:f.verbose,duration:f.duration,onComplete:function(){d.bind.close(),t.call(u,C),f.onVisible.call(u,C)}})):d.error(g.noTransition)},hide:function(t){t=V.isFunction(t)?t:function(){},d.debug("Hiding pop-up"),f.transition&&V.fn.transition!==z&&v.transition("is supported")?u.transition({animation:f.transition+" out",queue:!1,duration:f.duration,debug:f.debug,verbose:f.verbose,onComplete:function(){d.reset(),t.call(u,C),f.onHidden.call(u,C)}}):d.error(g.noTransition)}},change:{content:function(t){u.html(t)}},get:{html:function(){return v.removeData(m.html),v.data(m.html)||f.html},title:function(){return v.removeData(m.title),v.data(m.title)||f.title},content:function(){return v.removeData(m.content),v.data(m.content)||f.content||v.attr("title")},variation:function(){return v.removeData(m.variation),v.data(m.variation)||f.variation},popup:function(){return u},popupOffset:function(){return u.offset()},calculations:function(){var t,e=d.get.offsetParent(u),o=w[0],n=b[0]==W,i=w.offset(),r=f.inline||f.popup&&f.movePopup?w.offsetParent().offset():{top:0,left:0},a=n?{top:0,left:0}:b.offset(),s={},p=n?{top:S.scrollTop(),left:S.scrollLeft()}:{top:0,left:0};if(s={target:{element:w[0],width:w.outerWidth(),height:w.outerHeight(),top:i.top-r.top,left:i.left-r.left,margin:{}},popup:{width:u.outerWidth(),height:u.outerHeight()},parent:{width:c.outerWidth(),height:c.outerHeight()},screen:{top:a.top,left:a.left,scroll:{top:p.top,left:p.left},width:b.width(),height:b.height()}},e.get(0)!==c.get(0)){var l=e.offset();s.target.top-=l.top,s.target.left-=l.left,s.parent.width=e.outerWidth(),s.parent.height=e.outerHeight()}return f.setFluidWidth&&d.is.fluid()&&(s.container={width:u.parent().outerWidth()},s.popup.width=s.container.width),s.target.margin.top=f.inline?parseInt(W.getComputedStyle(o).getPropertyValue("margin-top"),10):0,s.target.margin.left=f.inline?d.is.rtl()?parseInt(W.getComputedStyle(o).getPropertyValue("margin-right"),10):parseInt(W.getComputedStyle(o).getPropertyValue("margin-left"),10):0,t=s.screen,s.boundary={top:t.top+t.scroll.top,bottom:t.top+t.scroll.top+t.height,left:t.left+t.scroll.left,right:t.left+t.scroll.left+t.width},s},id:function(){return o},startEvent:function(){return"hover"==f.on?"mouseenter":"focus"==f.on&&"focus"},scrollEvent:function(){return"scroll"},endEvent:function(){return"hover"==f.on?"mouseleave":"focus"==f.on&&"blur"},distanceFromBoundary:function(t,e){var o,n,i={};return o=(e=e||d.get.calculations()).popup,n=e.boundary,t&&(i={top:t.top-n.top,left:t.left-n.left,right:n.right-(t.left+o.width),bottom:n.bottom-(t.top+o.height)},d.verbose("Distance from boundaries determined",t,i)),i},offsetParent:function(t){var e=(t!==z?t[0]:w[0]).parentNode,o=V(e);if(e)for(var n="none"===o.css("transform"),i="static"===o.css("position"),r=o.is("body");e&&!r&&i&&n;)e=e.parentNode,n="none"===(o=V(e)).css("transform"),i="static"===o.css("position"),r=o.is("body");return o&&0<o.length?o:V()},positions:function(){return{"top left":!1,"top center":!1,"top right":!1,"bottom left":!1,"bottom center":!1,"bottom right":!1,"left center":!1,"right center":!1}},nextPosition:function(t){var e=t.split(" "),o=e[0],n=e[1],i="top"==o||"bottom"==o,r=!1,a=!1,s=!1;return l||(d.verbose("All available positions available"),l=d.get.positions()),d.debug("Recording last position tried",t),l[t]=!0,"opposite"===f.prefer&&(s=(s=[{top:"bottom",bottom:"top",left:"right",right:"left"}[o],n]).join(" "),r=!0===l[s],d.debug("Trying opposite strategy",s)),"adjacent"===f.prefer&&i&&(s=(s=[o,{left:"center",center:"right",right:"left"}[n]]).join(" "),a=!0===l[s],d.debug("Trying adjacent strategy",s)),(a||r)&&(d.debug("Using backup position",s),s={"top left":"top center","top center":"top right","top right":"right center","right center":"bottom right","bottom right":"bottom center","bottom center":"bottom left","bottom left":"left center","left center":"top left"}[t]),s}},set:{position:function(t,e){if(0!==w.length&&0!==u.length){var o,n,i,r,a,s,p,l;if(e=e||d.get.calculations(),t=t||v.data(m.position)||f.position,o=v.data(m.offset)||f.offset,n=f.distanceAway,i=e.target,r=e.popup,a=e.parent,d.should.centerArrow(e)&&(d.verbose("Adjusting offset to center arrow on small target element"),"top left"!=t&&"bottom left"!=t||(o+=i.width/2,o-=f.arrowPixelsFromEdge),"top right"!=t&&"bottom right"!=t||(o-=i.width/2,o+=f.arrowPixelsFromEdge)),0===i.width&&0===i.height&&!d.is.svg(i.element))return d.debug("Popup target is hidden, no action taken"),!1;switch(f.inline&&(d.debug("Adding margin to calculation",i.margin),"left center"==t||"right center"==t?(o+=i.margin.top,n+=-i.margin.left):"top left"==t||"top center"==t||"top right"==t?(o+=i.margin.left,n-=i.margin.top):(o+=i.margin.left,n+=i.margin.top)),d.debug("Determining popup position from calculations",t,e),d.is.rtl()&&(t=t.replace(/left|right/g,function(t){return"left"==t?"right":"left"}),d.debug("RTL: Popup position updated",t)),y==f.maxSearchDepth&&"string"==typeof f.lastResort&&(t=f.lastResort),t){case"top left":s={top:"auto",bottom:a.height-i.top+n,left:i.left+o,right:"auto"};break;case"top center":s={bottom:a.height-i.top+n,left:i.left+i.width/2-r.width/2+o,top:"auto",right:"auto"};break;case"top right":s={bottom:a.height-i.top+n,right:a.width-i.left-i.width-o,top:"auto",left:"auto"};break;case"left center":s={top:i.top+i.height/2-r.height/2+o,right:a.width-i.left+n,left:"auto",bottom:"auto"};break;case"right center":s={top:i.top+i.height/2-r.height/2+o,left:i.left+i.width+n,bottom:"auto",right:"auto"};break;case"bottom left":s={top:i.top+i.height+n,left:i.left+o,bottom:"auto",right:"auto"};break;case"bottom center":s={top:i.top+i.height+n,left:i.left+i.width/2-r.width/2+o,bottom:"auto",right:"auto"};break;case"bottom right":s={top:i.top+i.height+n,right:a.width-i.left-i.width-o,left:"auto",bottom:"auto"}}if(s===z&&d.error(g.invalidPosition,t),d.debug("Calculated popup positioning values",s),u.css(s).removeClass(h.position).addClass(t).addClass(h.loading),p=d.get.popupOffset(),l=d.get.distanceFromBoundary(p,e),!f.forcePosition&&d.is.offstage(l,t)){if(d.debug("Position is outside viewport",t),y<f.maxSearchDepth)return y++,t=d.get.nextPosition(t),d.debug("Trying new position",t),!!u&&d.set.position(t,e);if(!f.lastResort)return d.debug("Popup could not find a position to display",u),d.error(g.cannotPlace,C),d.remove.attempts(),d.remove.loading(),d.reset(),f.onUnplaceable.call(u,C),!1;d.debug("No position found, showing with last position")}return d.debug("Position is on stage",t),d.remove.attempts(),d.remove.loading(),f.setFluidWidth&&d.is.fluid()&&d.set.fluidWidth(e),!0}d.error(g.notFound)},fluidWidth:function(t){t=t||d.get.calculations(),d.debug("Automatically setting element width to parent width",t.parent.width),u.css("width",t.container.width)},variation:function(t){(t=t||d.get.variation())&&d.has.popup()&&(d.verbose("Adding variation to popup",t),u.addClass(t))},visible:function(){v.addClass(h.visible)}},remove:{loading:function(){u.removeClass(h.loading)},variation:function(t){(t=t||d.get.variation())&&(d.verbose("Removing variation",t),u.removeClass(t))},visible:function(){v.removeClass(h.visible)},attempts:function(){d.verbose("Resetting all searched positions"),y=0,l=!1}},bind:{events:function(){d.debug("Binding popup events to module"),"click"==f.on&&v.on(O+r,d.toggle),"hover"==f.on&&v.on("touchstart"+r,d.event.touchstart),d.get.startEvent()&&v.on(d.get.startEvent()+r,d.event.start).on(d.get.endEvent()+r,d.event.end),f.target&&d.debug("Target set to element",w),S.on("resize"+e,d.event.resize)},popup:function(){d.verbose("Allowing hover events on popup to prevent closing"),u&&d.has.popup()&&u.on("mouseenter"+r,d.event.start).on("mouseleave"+r,d.event.end)},close:function(){(!0===f.hideOnScroll||"auto"==f.hideOnScroll&&"click"!=f.on)&&d.bind.closeOnScroll(),d.is.closable()?d.bind.clickaway():"hover"==f.on&&P&&d.bind.touchClose()},closeOnScroll:function(){d.verbose("Binding scroll close event to document"),p.one(d.get.scrollEvent()+e,d.event.hideGracefully)},touchClose:function(){d.verbose("Binding popup touchclose event to document"),k.on("touchstart"+e,function(t){d.verbose("Touched away from popup"),d.event.hideGracefully.call(C,t)})},clickaway:function(){d.verbose("Binding popup close event to document"),k.on(O+e,function(t){d.verbose("Clicked away from popup"),d.event.hideGracefully.call(C,t)})}},unbind:{events:function(){S.off(e),v.off(r)},close:function(){k.off(e),p.off(e)}},has:{popup:function(){return u&&0<u.length}},should:{centerArrow:function(t){return!d.is.basic()&&t.target.width<=2*f.arrowPixelsFromEdge}},is:{closable:function(){return"auto"==f.closable?"hover"!=f.on:f.closable},offstage:function(t,o){var n=[];return V.each(t,function(t,e){e<-f.jitter&&(d.debug("Position exceeds allowable distance from edge",t,e,o),n.push(t))}),0<n.length},svg:function(t){return d.supports.svg()&&t instanceof SVGGraphicsElement},basic:function(){return v.hasClass(h.basic)},active:function(){return v.hasClass(h.active)},animating:function(){return u!==z&&u.hasClass(h.animating)},fluid:function(){return u!==z&&u.hasClass(h.fluid)},visible:function(){return u!==z&&u.hasClass(h.popupVisible)},dropdown:function(){return v.hasClass(h.dropdown)},hidden:function(){return!d.is.visible()},rtl:function(){return"rtl"===v.attr("dir")||"rtl"===v.css("direction")}},reset:function(){d.remove.visible(),f.preserve?V.fn.transition!==z&&u.transition("remove transition"):d.removePopup()},setting:function(t,e){if(V.isPlainObject(t))V.extend(!0,f,t);else{if(e===z)return f[t];f[t]=e}},internal:function(t,e){if(V.isPlainObject(t))V.extend(!0,d,t);else{if(e===z)return d[t];d[t]=e}},debug:function(){!f.silent&&f.debug&&(f.performance?d.performance.log(arguments):(d.debug=Function.prototype.bind.call(console.info,console,f.name+":"),d.debug.apply(console,arguments)))},verbose:function(){!f.silent&&f.verbose&&f.debug&&(f.performance?d.performance.log(arguments):(d.verbose=Function.prototype.bind.call(console.info,console,f.name+":"),d.verbose.apply(console,arguments)))},error:function(){f.silent||(d.error=Function.prototype.bind.call(console.error,console,f.name+":"),d.error.apply(console,arguments))},performance:{log:function(t){var e,o;f.performance&&(o=(e=(new Date).getTime())-(D||e),D=e,j.push({Name:t[0],Arguments:[].slice.call(t,1)||"",Element:C,"Execution Time":o})),clearTimeout(d.performance.timer),d.performance.timer=setTimeout(d.performance.display,500)},display:function(){var t=f.name+":",o=0;D=!1,clearTimeout(d.performance.timer),V.each(j,function(t,e){o+=e["Execution Time"]}),t+=" "+o+"ms",F&&(t+=" '"+F+"'"),(console.group!==z||console.table!==z)&&0<j.length&&(console.groupCollapsed(t),console.table?console.table(j):V.each(j,function(t,e){console.log(e.Name+": "+e["Execution Time"]+"ms")}),console.groupEnd()),j=[]}},invoke:function(n,t,e){var i,r,o,a=T;return t=t||N,e=C||e,"string"==typeof n&&a!==z&&(n=n.split(/[\. ]/),i=n.length-1,V.each(n,function(t,e){var o=t!=i?e+n[t+1].charAt(0).toUpperCase()+n[t+1].slice(1):n;if(V.isPlainObject(a[o])&&t!=i)a=a[o];else{if(a[o]!==z)return r=a[o],!1;if(!V.isPlainObject(a[e])||t==i)return a[e]!==z&&(r=a[e]),!1;a=a[e]}})),V.isFunction(r)?o=r.apply(e,t):r!==z&&(o=r),Array.isArray(E)?E.push(o):E!==z?E=[E,o]:o!==z&&(E=o),r}},H?(T===z&&d.initialize(),d.invoke(R)):(T!==z&&T.invoke("destroy"),d.initialize())}),E!==z?E:this},V.fn.popup.settings={name:"Popup",silent:!1,debug:!1,verbose:!1,performance:!0,namespace:"popup",observeChanges:!0,onCreate:function(){},onRemove:function(){},onShow:function(){},onVisible:function(){},onHide:function(){},onUnplaceable:function(){},onHidden:function(){},on:"hover",boundary:W,addTouchEvents:!0,position:"top left",forcePosition:!1,variation:"",movePopup:!0,target:!1,popup:!1,inline:!1,preserve:!1,hoverable:!1,content:!1,html:!1,title:!1,closable:!0,hideOnScroll:"auto",exclusive:!1,context:"body",scrollContext:W,prefer:"opposite",lastResort:!1,arrowPixelsFromEdge:20,delay:{show:50,hide:70},setFluidWidth:!0,duration:200,transition:"scale",distanceAway:0,jitter:2,offset:0,maxSearchDepth:15,error:{invalidPosition:"The position you specified is not a valid position",cannotPlace:"Popup does not fit within the boundaries of the viewport",method:"The method you called is not defined.",noTransition:"This module requires ui transitions <https://github.com/Semantic-Org/UI-Transition>",notFound:"The target or popup you specified does not exist on the page"},metadata:{activator:"activator",content:"content",html:"html",offset:"offset",position:"position",title:"title",variation:"variation"},className:{active:"active",basic:"basic",animating:"animating",dropdown:"dropdown",fluid:"fluid",loading:"loading",popup:"ui popup",position:"top left center bottom right",visible:"visible",popupVisible:"visible"},selector:{popup:".ui.popup"},templates:{escape:function(t){var e={"<":"<",">":">",'"':""","'":"'","`":"`"};return/[&<>"'`]/.test(t)?(t=t.replace(/&(?![a-z0-9#]{1,6};)/,"&")).replace(/[<>"'`]/g,function(t){return e[t]}):t},popup:function(t){var e="",o=V.fn.popup.settings.templates.escape;return typeof t!==z&&(typeof t.title!==z&&t.title&&(t.title=o(t.title),e+='<div class="header">'+t.title+"</div>"),typeof t.content!==z&&t.content&&(t.content=o(t.content),e+='<div class="content">'+t.content+"</div>")),e}}}}(jQuery,window,document);
|
11
|
+
!function(N,V,W,z){"use strict";N.isFunction=N.isFunction||function(t){return"function"==typeof t&&"number"!=typeof t.nodeType},V=void 0!==V&&V.Math==Math?V:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")(),N.fn.popup=function(x){var E,t=N(this),k=N(W),S=N(V),A=N("body"),F=t.selector||"",D="ontouchstart"in W.documentElement?"touchstart":"click",O=(new Date).getTime(),j=[],R=x,M="string"==typeof R,H=[].slice.call(arguments,1);return t.each(function(){var u,c,t,e,o,d,f=N.isPlainObject(x)?N.extend(!0,{},N.fn.popup.settings,x):N.extend({},N.fn.popup.settings),i=f.selector,h=f.className,g=f.error,m=f.metadata,n=f.namespace,r="."+f.namespace,a="module-"+n,v=N(this),s=N(f.context),p=N(f.scrollContext),b=N(f.boundary),w=f.target?N(f.target):v,y=0,l=!1,P=!1,C=this,T=v.data(a);d={initialize:function(){d.debug("Initializing",v),d.createID(),d.bind.events(),!d.exists()&&f.preserve&&d.create(),f.observeChanges&&d.observeChanges(),d.instantiate()},instantiate:function(){d.verbose("Storing instance",d),T=d,v.data(a,T)},observeChanges:function(){"MutationObserver"in V&&((t=new MutationObserver(d.event.documentChanged)).observe(W,{childList:!0,subtree:!0}),d.debug("Setting up mutation observer",t))},refresh:function(){f.popup?u=N(f.popup).eq(0):f.inline&&(u=w.nextAll(i.popup).eq(0),f.popup=u),f.popup?(u.addClass(h.loading),c=d.get.offsetParent(),u.removeClass(h.loading),f.movePopup&&d.has.popup()&&d.get.offsetParent(u)[0]!==c[0]&&(d.debug("Moving popup to the same offset parent as target"),u.detach().appendTo(c))):c=f.inline?d.get.offsetParent(w):d.has.popup()?d.get.offsetParent(u):A,c.is("html")&&c[0]!==A[0]&&(d.debug("Setting page as offset parent"),c=A),d.get.variation()&&d.set.variation()},reposition:function(){d.refresh(),d.set.position()},destroy:function(){d.debug("Destroying previous module"),t&&t.disconnect(),u&&!f.preserve&&d.removePopup(),clearTimeout(d.hideTimer),clearTimeout(d.showTimer),d.unbind.close(),d.unbind.events(),v.removeData(a)},event:{start:function(t){var e=N.isPlainObject(f.delay)?f.delay.show:f.delay;clearTimeout(d.hideTimer),(!P||P&&f.addTouchEvents)&&(d.showTimer=setTimeout(d.show,e))},end:function(){var t=N.isPlainObject(f.delay)?f.delay.hide:f.delay;clearTimeout(d.showTimer),d.hideTimer=setTimeout(d.hide,t)},touchstart:function(t){P=!0,f.addTouchEvents&&d.show()},resize:function(){d.is.visible()&&d.set.position()},documentChanged:function(t){[].forEach.call(t,function(t){t.removedNodes&&[].forEach.call(t.removedNodes,function(t){(t==C||0<N(t).find(C).length)&&(d.debug("Element removed from DOM, tearing down events"),d.destroy())})})},hideGracefully:function(t){var e=N(t.target),o=N.contains(W.documentElement,t.target),n=0<e.closest(i.popup).length;t&&!n&&o?(d.debug("Click occurred outside popup hiding popup"),d.hide()):d.debug("Click was inside popup, keeping popup open")}},create:function(){var t=d.get.html(),e=d.get.title(),o=d.get.content();t||o||e?(d.debug("Creating pop-up html"),t=t||f.templates.popup({title:e,content:o}),u=N("<div/>").addClass(h.popup).data(m.activator,v).html(t),f.inline?(d.verbose("Inserting popup element inline",u),u.insertAfter(v)):(d.verbose("Appending popup element to body",u),u.appendTo(s)),d.refresh(),d.set.variation(),f.hoverable&&d.bind.popup(),f.onCreate.call(u,C)):f.popup?(N(f.popup).data(m.activator,v),d.verbose("Used popup specified in settings"),d.refresh(),f.hoverable&&d.bind.popup()):0!==w.next(i.popup).length?(d.verbose("Pre-existing popup found"),f.inline=!0,f.popup=w.next(i.popup).data(m.activator,v),d.refresh(),f.hoverable&&d.bind.popup()):d.debug("No content specified skipping display",C)},createID:function(){o=(Math.random().toString(16)+"000000000").substr(2,8),e="."+o,d.verbose("Creating unique id for element",o)},toggle:function(){d.debug("Toggling pop-up"),d.is.hidden()?(d.debug("Popup is hidden, showing pop-up"),d.unbind.close(),d.show()):(d.debug("Popup is visible, hiding pop-up"),d.hide())},show:function(t){if(t=t||function(){},d.debug("Showing pop-up",f.transition),d.is.hidden()&&(!d.is.active()||!d.is.dropdown())){if(d.exists()||d.create(),!1===f.onShow.call(u,C))return void d.debug("onShow callback returned false, cancelling popup animation");f.preserve||f.popup||d.refresh(),u&&d.set.position()&&(d.save.conditions(),f.exclusive&&d.hideAll(),d.animate.show(t))}},hide:function(t){if(t=t||function(){},d.is.visible()||d.is.animating()){if(!1===f.onHide.call(u,C))return void d.debug("onHide callback returned false, cancelling popup animation");d.remove.visible(),d.unbind.close(),d.restore.conditions(),d.animate.hide(t)}},hideAll:function(){N(i.popup).filter("."+h.popupVisible).each(function(){N(this).data(m.activator).popup("hide")})},exists:function(){return!!u&&(f.inline||f.popup?d.has.popup():1<=u.closest(s).length)},removePopup:function(){d.has.popup()&&!f.popup&&(d.debug("Removing popup",u),u.remove(),u=z,f.onRemove.call(u,C))},save:{conditions:function(){d.cache={title:v.attr("title")},d.cache.title&&v.removeAttr("title"),d.verbose("Saving original attributes",d.cache.title)}},restore:{conditions:function(){return d.cache&&d.cache.title&&(v.attr("title",d.cache.title),d.verbose("Restoring original attributes",d.cache.title)),!0}},supports:{svg:function(){return"undefined"!=typeof SVGGraphicsElement}},animate:{show:function(t){t=N.isFunction(t)?t:function(){},f.transition&&N.fn.transition!==z&&v.transition("is supported")?(d.set.visible(),u.transition({animation:(f.transition.showMethod||f.transition)+" in",queue:!1,debug:f.debug,verbose:f.verbose,duration:f.transition.showDuration||f.duration,onComplete:function(){d.bind.close(),t.call(u,C),f.onVisible.call(u,C)}})):d.error(g.noTransition)},hide:function(t){t=N.isFunction(t)?t:function(){},d.debug("Hiding pop-up"),f.transition&&N.fn.transition!==z&&v.transition("is supported")?u.transition({animation:(f.transition.hideMethod||f.transition)+" out",queue:!1,duration:f.transition.hideDuration||f.duration,debug:f.debug,verbose:f.verbose,onComplete:function(){d.reset(),t.call(u,C),f.onHidden.call(u,C)}}):d.error(g.noTransition)}},change:{content:function(t){u.html(t)}},get:{html:function(){return v.removeData(m.html),v.data(m.html)||f.html},title:function(){return v.removeData(m.title),v.data(m.title)||f.title},content:function(){return v.removeData(m.content),v.data(m.content)||f.content||v.attr("title")},variation:function(){return v.removeData(m.variation),v.data(m.variation)||f.variation},popup:function(){return u},popupOffset:function(){return u.offset()},calculations:function(){var t,e=d.get.offsetParent(u),o=w[0],n=b[0]==V,i=w.offset(),r=f.inline||f.popup&&f.movePopup?w.offsetParent().offset():{top:0,left:0},a=n?{top:0,left:0}:b.offset(),s={},p=n?{top:S.scrollTop(),left:S.scrollLeft()}:{top:0,left:0};if(s={target:{element:w[0],width:w.outerWidth(),height:w.outerHeight(),top:i.top-r.top,left:i.left-r.left,margin:{}},popup:{width:u.outerWidth(),height:u.outerHeight()},parent:{width:c.outerWidth(),height:c.outerHeight()},screen:{top:a.top,left:a.left,scroll:{top:p.top,left:p.left},width:b.width(),height:b.height()}},e.get(0)!==c.get(0)){var l=e.offset();s.target.top-=l.top,s.target.left-=l.left,s.parent.width=e.outerWidth(),s.parent.height=e.outerHeight()}return f.setFluidWidth&&d.is.fluid()&&(s.container={width:u.parent().outerWidth()},s.popup.width=s.container.width),s.target.margin.top=f.inline?parseInt(V.getComputedStyle(o).getPropertyValue("margin-top"),10):0,s.target.margin.left=f.inline?d.is.rtl()?parseInt(V.getComputedStyle(o).getPropertyValue("margin-right"),10):parseInt(V.getComputedStyle(o).getPropertyValue("margin-left"),10):0,t=s.screen,s.boundary={top:t.top+t.scroll.top,bottom:t.top+t.scroll.top+t.height,left:t.left+t.scroll.left,right:t.left+t.scroll.left+t.width},s},id:function(){return o},startEvent:function(){return"hover"==f.on?"mouseenter":"focus"==f.on&&"focus"},scrollEvent:function(){return"scroll"},endEvent:function(){return"hover"==f.on?"mouseleave":"focus"==f.on&&"blur"},distanceFromBoundary:function(t,e){var o,n,i={};return o=(e=e||d.get.calculations()).popup,n=e.boundary,t&&(i={top:t.top-n.top,left:t.left-n.left,right:n.right-(t.left+o.width),bottom:n.bottom-(t.top+o.height)},d.verbose("Distance from boundaries determined",t,i)),i},offsetParent:function(t){var e=(t!==z?t[0]:w[0]).parentNode,o=N(e);if(e)for(var n="none"===o.css("transform"),i="static"===o.css("position"),r=o.is("body");e&&!r&&i&&n;)e=e.parentNode,n="none"===(o=N(e)).css("transform"),i="static"===o.css("position"),r=o.is("body");return o&&0<o.length?o:N()},positions:function(){return{"top left":!1,"top center":!1,"top right":!1,"bottom left":!1,"bottom center":!1,"bottom right":!1,"left center":!1,"right center":!1}},nextPosition:function(t){var e=t.split(" "),o=e[0],n=e[1],i="top"==o||"bottom"==o,r=!1,a=!1,s=!1;return l||(d.verbose("All available positions available"),l=d.get.positions()),d.debug("Recording last position tried",t),l[t]=!0,"opposite"===f.prefer&&(s=(s=[{top:"bottom",bottom:"top",left:"right",right:"left"}[o],n]).join(" "),r=!0===l[s],d.debug("Trying opposite strategy",s)),"adjacent"===f.prefer&&i&&(s=(s=[o,{left:"center",center:"right",right:"left"}[n]]).join(" "),a=!0===l[s],d.debug("Trying adjacent strategy",s)),(a||r)&&(d.debug("Using backup position",s),s={"top left":"top center","top center":"top right","top right":"right center","right center":"bottom right","bottom right":"bottom center","bottom center":"bottom left","bottom left":"left center","left center":"top left"}[t]),s}},set:{position:function(t,e){if(0!==w.length&&0!==u.length){var o,n,i,r,a,s,p,l;if(e=e||d.get.calculations(),t=t||v.data(m.position)||f.position,o=v.data(m.offset)||f.offset,n=f.distanceAway,i=e.target,r=e.popup,a=e.parent,d.should.centerArrow(e)&&(d.verbose("Adjusting offset to center arrow on small target element"),"top left"!=t&&"bottom left"!=t||(o+=i.width/2,o-=f.arrowPixelsFromEdge),"top right"!=t&&"bottom right"!=t||(o-=i.width/2,o+=f.arrowPixelsFromEdge)),0===i.width&&0===i.height&&!d.is.svg(i.element))return d.debug("Popup target is hidden, no action taken"),!1;switch(f.inline&&(d.debug("Adding margin to calculation",i.margin),"left center"==t||"right center"==t?(o+=i.margin.top,n+=-i.margin.left):"top left"==t||"top center"==t||"top right"==t?(o+=i.margin.left,n-=i.margin.top):(o+=i.margin.left,n+=i.margin.top)),d.debug("Determining popup position from calculations",t,e),d.is.rtl()&&(t=t.replace(/left|right/g,function(t){return"left"==t?"right":"left"}),d.debug("RTL: Popup position updated",t)),y==f.maxSearchDepth&&"string"==typeof f.lastResort&&(t=f.lastResort),t){case"top left":s={top:"auto",bottom:a.height-i.top+n,left:i.left+o,right:"auto"};break;case"top center":s={bottom:a.height-i.top+n,left:i.left+i.width/2-r.width/2+o,top:"auto",right:"auto"};break;case"top right":s={bottom:a.height-i.top+n,right:a.width-i.left-i.width-o,top:"auto",left:"auto"};break;case"left center":s={top:i.top+i.height/2-r.height/2+o,right:a.width-i.left+n,left:"auto",bottom:"auto"};break;case"right center":s={top:i.top+i.height/2-r.height/2+o,left:i.left+i.width+n,bottom:"auto",right:"auto"};break;case"bottom left":s={top:i.top+i.height+n,left:i.left+o,bottom:"auto",right:"auto"};break;case"bottom center":s={top:i.top+i.height+n,left:i.left+i.width/2-r.width/2+o,bottom:"auto",right:"auto"};break;case"bottom right":s={top:i.top+i.height+n,right:a.width-i.left-i.width-o,left:"auto",bottom:"auto"}}if(s===z&&d.error(g.invalidPosition,t),d.debug("Calculated popup positioning values",s),u.css(s).removeClass(h.position).addClass(t).addClass(h.loading),p=d.get.popupOffset(),l=d.get.distanceFromBoundary(p,e),!f.forcePosition&&d.is.offstage(l,t)){if(d.debug("Position is outside viewport",t),y<f.maxSearchDepth)return y++,t=d.get.nextPosition(t),d.debug("Trying new position",t),!!u&&d.set.position(t,e);if(!f.lastResort)return d.debug("Popup could not find a position to display",u),d.error(g.cannotPlace,C),d.remove.attempts(),d.remove.loading(),d.reset(),f.onUnplaceable.call(u,C),!1;d.debug("No position found, showing with last position")}return d.debug("Position is on stage",t),d.remove.attempts(),d.remove.loading(),f.setFluidWidth&&d.is.fluid()&&d.set.fluidWidth(e),!0}d.error(g.notFound)},fluidWidth:function(t){t=t||d.get.calculations(),d.debug("Automatically setting element width to parent width",t.parent.width),u.css("width",t.container.width)},variation:function(t){(t=t||d.get.variation())&&d.has.popup()&&(d.verbose("Adding variation to popup",t),u.addClass(t))},visible:function(){v.addClass(h.visible)}},remove:{loading:function(){u.removeClass(h.loading)},variation:function(t){(t=t||d.get.variation())&&(d.verbose("Removing variation",t),u.removeClass(t))},visible:function(){v.removeClass(h.visible)},attempts:function(){d.verbose("Resetting all searched positions"),y=0,l=!1}},bind:{events:function(){d.debug("Binding popup events to module"),"click"==f.on&&v.on(D+r,d.toggle),"hover"==f.on&&v.on("touchstart"+r,d.event.touchstart),d.get.startEvent()&&v.on(d.get.startEvent()+r,d.event.start).on(d.get.endEvent()+r,d.event.end),f.target&&d.debug("Target set to element",w),S.on("resize"+e,d.event.resize)},popup:function(){d.verbose("Allowing hover events on popup to prevent closing"),u&&d.has.popup()&&u.on("mouseenter"+r,d.event.start).on("mouseleave"+r,d.event.end)},close:function(){(!0===f.hideOnScroll||"auto"==f.hideOnScroll&&"click"!=f.on)&&d.bind.closeOnScroll(),d.is.closable()?d.bind.clickaway():"hover"==f.on&&P&&d.bind.touchClose()},closeOnScroll:function(){d.verbose("Binding scroll close event to document"),p.one(d.get.scrollEvent()+e,d.event.hideGracefully)},touchClose:function(){d.verbose("Binding popup touchclose event to document"),k.on("touchstart"+e,function(t){d.verbose("Touched away from popup"),d.event.hideGracefully.call(C,t)})},clickaway:function(){d.verbose("Binding popup close event to document"),k.on(D+e,function(t){d.verbose("Clicked away from popup"),d.event.hideGracefully.call(C,t)})}},unbind:{events:function(){S.off(e),v.off(r)},close:function(){k.off(e),p.off(e)}},has:{popup:function(){return u&&0<u.length}},should:{centerArrow:function(t){return!d.is.basic()&&t.target.width<=2*f.arrowPixelsFromEdge}},is:{closable:function(){return"auto"==f.closable?"hover"!=f.on:f.closable},offstage:function(t,o){var n=[];return N.each(t,function(t,e){e<-f.jitter&&(d.debug("Position exceeds allowable distance from edge",t,e,o),n.push(t))}),0<n.length},svg:function(t){return d.supports.svg()&&t instanceof SVGGraphicsElement},basic:function(){return v.hasClass(h.basic)},active:function(){return v.hasClass(h.active)},animating:function(){return u!==z&&u.hasClass(h.animating)},fluid:function(){return u!==z&&u.hasClass(h.fluid)},visible:function(){return u!==z&&u.hasClass(h.popupVisible)},dropdown:function(){return v.hasClass(h.dropdown)},hidden:function(){return!d.is.visible()},rtl:function(){return"rtl"===v.attr("dir")||"rtl"===v.css("direction")}},reset:function(){d.remove.visible(),f.preserve?N.fn.transition!==z&&u.transition("remove transition"):d.removePopup()},setting:function(t,e){if(N.isPlainObject(t))N.extend(!0,f,t);else{if(e===z)return f[t];f[t]=e}},internal:function(t,e){if(N.isPlainObject(t))N.extend(!0,d,t);else{if(e===z)return d[t];d[t]=e}},debug:function(){!f.silent&&f.debug&&(f.performance?d.performance.log(arguments):(d.debug=Function.prototype.bind.call(console.info,console,f.name+":"),d.debug.apply(console,arguments)))},verbose:function(){!f.silent&&f.verbose&&f.debug&&(f.performance?d.performance.log(arguments):(d.verbose=Function.prototype.bind.call(console.info,console,f.name+":"),d.verbose.apply(console,arguments)))},error:function(){f.silent||(d.error=Function.prototype.bind.call(console.error,console,f.name+":"),d.error.apply(console,arguments))},performance:{log:function(t){var e,o;f.performance&&(o=(e=(new Date).getTime())-(O||e),O=e,j.push({Name:t[0],Arguments:[].slice.call(t,1)||"",Element:C,"Execution Time":o})),clearTimeout(d.performance.timer),d.performance.timer=setTimeout(d.performance.display,500)},display:function(){var t=f.name+":",o=0;O=!1,clearTimeout(d.performance.timer),N.each(j,function(t,e){o+=e["Execution Time"]}),t+=" "+o+"ms",F&&(t+=" '"+F+"'"),(console.group!==z||console.table!==z)&&0<j.length&&(console.groupCollapsed(t),console.table?console.table(j):N.each(j,function(t,e){console.log(e.Name+": "+e["Execution Time"]+"ms")}),console.groupEnd()),j=[]}},invoke:function(n,t,e){var i,r,o,a=T;return t=t||H,e=C||e,"string"==typeof n&&a!==z&&(n=n.split(/[\. ]/),i=n.length-1,N.each(n,function(t,e){var o=t!=i?e+n[t+1].charAt(0).toUpperCase()+n[t+1].slice(1):n;if(N.isPlainObject(a[o])&&t!=i)a=a[o];else{if(a[o]!==z)return r=a[o],!1;if(!N.isPlainObject(a[e])||t==i)return a[e]!==z&&(r=a[e]),!1;a=a[e]}})),N.isFunction(r)?o=r.apply(e,t):r!==z&&(o=r),Array.isArray(E)?E.push(o):E!==z?E=[E,o]:o!==z&&(E=o),r}},M?(T===z&&d.initialize(),d.invoke(R)):(T!==z&&T.invoke("destroy"),d.initialize())}),E!==z?E:this},N.fn.popup.settings={name:"Popup",silent:!1,debug:!1,verbose:!1,performance:!0,namespace:"popup",observeChanges:!0,onCreate:function(){},onRemove:function(){},onShow:function(){},onVisible:function(){},onHide:function(){},onUnplaceable:function(){},onHidden:function(){},on:"hover",boundary:V,addTouchEvents:!0,position:"top left",forcePosition:!1,variation:"",movePopup:!0,target:!1,popup:!1,inline:!1,preserve:!1,hoverable:!1,content:!1,html:!1,title:!1,closable:!0,hideOnScroll:"auto",exclusive:!1,context:"body",scrollContext:V,prefer:"opposite",lastResort:!1,arrowPixelsFromEdge:20,delay:{show:50,hide:70},setFluidWidth:!0,duration:200,transition:"scale",distanceAway:0,jitter:2,offset:0,maxSearchDepth:15,error:{invalidPosition:"The position you specified is not a valid position",cannotPlace:"Popup does not fit within the boundaries of the viewport",method:"The method you called is not defined.",noTransition:"This module requires ui transitions <https://github.com/Semantic-Org/UI-Transition>",notFound:"The target or popup you specified does not exist on the page"},metadata:{activator:"activator",content:"content",html:"html",offset:"offset",position:"position",title:"title",variation:"variation"},className:{active:"active",basic:"basic",animating:"animating",dropdown:"dropdown",fluid:"fluid",loading:"loading",popup:"ui popup",position:"top left center bottom right",visible:"visible",popupVisible:"visible"},selector:{popup:".ui.popup"},templates:{escape:function(t){var e={"<":"<",">":">",'"':""","'":"'","`":"`"};return/[&<>"'`]/.test(t)?(t=t.replace(/&(?![a-z0-9#]{1,6};)/,"&")).replace(/[<>"'`]/g,function(t){return e[t]}):t},popup:function(t){var e="",o=N.fn.popup.settings.templates.escape;return typeof t!==z&&(typeof t.title!==z&&t.title&&(t.title=o(t.title),e+='<div class="header">'+t.title+"</div>"),typeof t.content!==z&&t.content&&(t.content=o(t.content),e+='<div class="content">'+t.content+"</div>")),e}}}}(jQuery,window,document);
|
@@ -1,5 +1,5 @@
|
|
1
1
|
/*!
|
2
|
-
* # Fomantic-UI - Progress Bar
|
2
|
+
* # Fomantic-UI 2.9.0-beta.100 - Progress Bar
|
3
3
|
* http://github.com/fomantic/Fomantic-UI/
|
4
4
|
*
|
5
5
|
*
|
@@ -676,6 +676,7 @@
|
|
676
676
|
.ui.progress .bar .centered.progress {
|
677
677
|
text-align: center;
|
678
678
|
position: relative;
|
679
|
+
right: 0;
|
679
680
|
}
|
680
681
|
.ui.indeterminate.progress .bar::before {
|
681
682
|
content: '';
|
@@ -1,5 +1,5 @@
|
|
1
1
|
/*!
|
2
|
-
* # Fomantic-UI - Progress
|
2
|
+
* # Fomantic-UI 2.9.0-beta.100 - Progress
|
3
3
|
* http://github.com/fomantic/Fomantic-UI/
|
4
4
|
*
|
5
5
|
*
|
@@ -93,7 +93,7 @@ $.fn.progress = function(parameters) {
|
|
93
93
|
*
|
94
94
|
* @param min A minimum value within multiple values
|
95
95
|
* @param total A total amount of multiple values
|
96
|
-
* @returns {number} A
|
96
|
+
* @returns {number} A precision. Could be 1, 10, 100, ... 1e+10.
|
97
97
|
*/
|
98
98
|
derivePrecision: function(min, total) {
|
99
99
|
var precisionPower = 0
|
@@ -991,7 +991,7 @@ $.fn.progress.settings = {
|
|
991
991
|
nonNumeric : 'Progress value is non numeric',
|
992
992
|
tooHigh : 'Value specified is above 100%',
|
993
993
|
tooLow : 'Value specified is below 0%',
|
994
|
-
sumExceedsTotal : 'Sum of
|
994
|
+
sumExceedsTotal : 'Sum of multiple values exceed total',
|
995
995
|
},
|
996
996
|
|
997
997
|
regExp: {
|
@@ -1,9 +1,9 @@
|
|
1
1
|
/*!
|
2
|
-
* # Fomantic-UI - Progress Bar
|
2
|
+
* # Fomantic-UI 2.9.0-beta.100 - Progress Bar
|
3
3
|
* http://github.com/fomantic/Fomantic-UI/
|
4
4
|
*
|
5
5
|
*
|
6
6
|
* Released under the MIT license
|
7
7
|
* http://opensource.org/licenses/MIT
|
8
8
|
*
|
9
|
-
*/.ui.progress{position:relative;display:-webkit-box;display:-ms-flexbox;display:flex;max-width:100%;border:none;margin:1em 0 2.5em;-webkit-box-shadow:none;box-shadow:none;background:rgba(0,0,0,.1);padding:0;border-radius:.28571429rem}.ui.progress:first-child{margin:0 0 2.5em}.ui.progress:last-child{margin:0 0 1.5em}.ui.progress .bar{display:block;line-height:1;position:relative;width:0;min-width:2em;background:#888;border-radius:.28571429rem;-webkit-transition:width .1s ease,background-color .1s ease;transition:width .1s ease,background-color .1s ease;overflow:hidden}.ui.ui.ui.progress:not([data-percent]):not(.indeterminate) .bar,.ui.ui.ui.progress[data-percent="0"]:not(.indeterminate) .bar{background:0 0}.ui.progress[data-percent="0"] .bar .progress{color:rgba(0,0,0,.87)}.ui.inverted.progress[data-percent="0"] .bar .progress{color:rgba(255,255,255,.9)}.ui.progress .bar>.progress{white-space:nowrap;position:absolute;width:auto;font-size:.92857143em;top:50%;right:.5em;left:auto;bottom:auto;color:rgba(255,255,255,.7);text-shadow:none;margin-top:-.5em;font-weight:700;text-align:left}.ui.right.aligned.progress{-webkit-box-pack:end;-ms-flex-pack:end;justify-content:flex-end}.ui.right.aligned.progress .bar>.progress{left:.5em;right:auto}.ui.progress>.label{position:absolute;width:100%;font-size:1em;top:100%;right:auto;left:0;bottom:auto;color:rgba(0,0,0,.87);font-weight:700;text-shadow:none;margin-top:.2em;text-align:center;-webkit-transition:color .4s ease;transition:color .4s ease}.ui.indicating.progress[data-percent^="1"] .bar,.ui.indicating.progress[data-percent^="2"] .bar{background-color:#d95c5c}.ui.indicating.progress[data-percent^="3"] .bar{background-color:#efbc72}.ui.indicating.progress[data-percent^="4"] .bar,.ui.indicating.progress[data-percent^="5"] .bar{background-color:#e6bb48}.ui.indicating.progress[data-percent^="6"] .bar{background-color:#ddc928}.ui.indicating.progress[data-percent^="7"] .bar,.ui.indicating.progress[data-percent^="8"] .bar{background-color:#b4d95c}.ui.indicating.progress[data-percent^="100"] .bar,.ui.indicating.progress[data-percent^="9"] .bar{background-color:#66da81}.ui.indicating.progress[data-percent^="1"] .label,.ui.indicating.progress[data-percent^="2"] .label{color:rgba(0,0,0,.87)}.ui.indicating.progress[data-percent^="3"] .label{color:rgba(0,0,0,.87)}.ui.indicating.progress[data-percent^="4"] .label,.ui.indicating.progress[data-percent^="5"] .label{color:rgba(0,0,0,.87)}.ui.indicating.progress[data-percent^="6"] .label{color:rgba(0,0,0,.87)}.ui.indicating.progress[data-percent^="7"] .label,.ui.indicating.progress[data-percent^="8"] .label{color:rgba(0,0,0,.87)}.ui.indicating.progress[data-percent^="100"] .label,.ui.indicating.progress[data-percent^="9"] .label{color:rgba(0,0,0,.87)}.ui.inverted.indicating.progress[data-percent^="1"] .label,.ui.inverted.indicating.progress[data-percent^="2"] .label{color:rgba(255,255,255,.9)}.ui.inverted.indicating.progress[data-percent^="3"] .label{color:rgba(255,255,255,.9)}.ui.inverted.indicating.progress[data-percent^="4"] .label,.ui.inverted.indicating.progress[data-percent^="5"] .label{color:rgba(255,255,255,.9)}.ui.inverted.indicating.progress[data-percent^="6"] .label{color:rgba(255,255,255,.9)}.ui.inverted.indicating.progress[data-percent^="7"] .label,.ui.inverted.indicating.progress[data-percent^="8"] .label{color:rgba(255,255,255,.9)}.ui.inverted.indicating.progress[data-percent^="100"] .label,.ui.inverted.indicating.progress[data-percent^="9"] .label{color:rgba(255,255,255,.9)}.ui.indicating.progress[data-percent="1"] .bar,.ui.indicating.progress[data-percent="2"] .bar,.ui.indicating.progress[data-percent="3"] .bar,.ui.indicating.progress[data-percent="4"] .bar,.ui.indicating.progress[data-percent="5"] .bar,.ui.indicating.progress[data-percent="6"] .bar,.ui.indicating.progress[data-percent="7"] .bar,.ui.indicating.progress[data-percent="8"] .bar,.ui.indicating.progress[data-percent="9"] .bar,.ui.indicating.progress[data-percent^="1."] .bar,.ui.indicating.progress[data-percent^="2."] .bar,.ui.indicating.progress[data-percent^="3."] .bar,.ui.indicating.progress[data-percent^="4."] .bar,.ui.indicating.progress[data-percent^="5."] .bar,.ui.indicating.progress[data-percent^="6."] .bar,.ui.indicating.progress[data-percent^="7."] .bar,.ui.indicating.progress[data-percent^="8."] .bar,.ui.indicating.progress[data-percent^="9."] .bar{background-color:#d95c5c}.ui.indicating.progress[data-percent="0"] .label,.ui.indicating.progress[data-percent="1"] .label,.ui.indicating.progress[data-percent="2"] .label,.ui.indicating.progress[data-percent="3"] .label,.ui.indicating.progress[data-percent="4"] .label,.ui.indicating.progress[data-percent="5"] .label,.ui.indicating.progress[data-percent="6"] .label,.ui.indicating.progress[data-percent="7"] .label,.ui.indicating.progress[data-percent="8"] .label,.ui.indicating.progress[data-percent="9"] .label,.ui.indicating.progress[data-percent^="0."] .label,.ui.indicating.progress[data-percent^="1."] .label,.ui.indicating.progress[data-percent^="2."] .label,.ui.indicating.progress[data-percent^="3."] .label,.ui.indicating.progress[data-percent^="4."] .label,.ui.indicating.progress[data-percent^="5."] .label,.ui.indicating.progress[data-percent^="6."] .label,.ui.indicating.progress[data-percent^="7."] .label,.ui.indicating.progress[data-percent^="8."] .label,.ui.indicating.progress[data-percent^="9."] .label{color:rgba(0,0,0,.87)}.ui.inverted.indicating.progress[data-percent="0"] .label,.ui.inverted.indicating.progress[data-percent="1"] .label,.ui.inverted.indicating.progress[data-percent="2"] .label,.ui.inverted.indicating.progress[data-percent="3"] .label,.ui.inverted.indicating.progress[data-percent="4"] .label,.ui.inverted.indicating.progress[data-percent="5"] .label,.ui.inverted.indicating.progress[data-percent="6"] .label,.ui.inverted.indicating.progress[data-percent="7"] .label,.ui.inverted.indicating.progress[data-percent="8"] .label,.ui.inverted.indicating.progress[data-percent="9"] .label,.ui.inverted.indicating.progress[data-percent^="0."] .label,.ui.inverted.indicating.progress[data-percent^="1."] .label,.ui.inverted.indicating.progress[data-percent^="2."] .label,.ui.inverted.indicating.progress[data-percent^="3."] .label,.ui.inverted.indicating.progress[data-percent^="4."] .label,.ui.inverted.indicating.progress[data-percent^="5."] .label,.ui.inverted.indicating.progress[data-percent^="6."] .label,.ui.inverted.indicating.progress[data-percent^="7."] .label,.ui.inverted.indicating.progress[data-percent^="8."] .label,.ui.inverted.indicating.progress[data-percent^="9."] .label{color:rgba(255,255,255,.9)}.ui.ui.indicating.progress.success .label{color:#1a531b}.ui.ui.progress.success .bar{background-color:#21ba45}.ui.ui.progress.success .bar,.ui.ui.progress.success .bar::after{-webkit-animation:none;animation:none}.ui.progress.success>.label{color:#1a531b}.ui.ui.progress.warning .bar{background-color:#f2c037}.ui.ui.progress.warning .bar,.ui.ui.progress.warning .bar::after{-webkit-animation:none;animation:none}.ui.progress.warning>.label{color:#794b02}.ui.ui.progress.error .bar{background-color:#db2828}.ui.ui.progress.error .bar,.ui.ui.progress.error .bar::after{-webkit-animation:none;animation:none}.ui.progress.error>.label{color:#912d2b}.ui.active.progress .bar{position:relative;min-width:2em}.ui.active.progress .bar::after{content:'';opacity:0;position:absolute;top:0;left:0;right:0;bottom:0;background:#fff;border-radius:.28571429rem;-webkit-animation:progress-active 2s ease infinite;animation:progress-active 2s ease infinite;-webkit-transform-origin:left;transform-origin:left}.ui.active.right.aligned.progress .bar::after{-webkit-transform-origin:right;transform-origin:right}@-webkit-keyframes progress-active{0%{opacity:.3;-webkit-transform:scale(0,1);transform:scale(0,1)}100%{opacity:0;-webkit-transform:scale(1);transform:scale(1)}}@keyframes progress-active{0%{opacity:.3;-webkit-transform:scale(0,1);transform:scale(0,1)}100%{opacity:0;-webkit-transform:scale(1);transform:scale(1)}}.ui.disabled.progress{opacity:.35}.ui.ui.disabled.progress .bar,.ui.ui.disabled.progress .bar::after{-webkit-animation:none;animation:none}.ui.inverted.progress{background:rgba(255,255,255,.08);border:none}.ui.inverted.progress .bar{background:#888}.ui.inverted.progress .bar>.progress{color:#1b1c1d}.ui.inverted.progress>.label{color:#fff}.ui.inverted.progress.success>.label{color:#21ba45}.ui.inverted.progress.warning>.label{color:#f2c037}.ui.inverted.progress.error>.label{color:#db2828}.ui.progress.attached{background:0 0;position:relative;border:none;margin:0}.ui.progress.attached,.ui.progress.attached .bar{height:.2rem;padding:0;overflow:hidden;border-radius:0 0 .28571429rem .28571429rem}.ui.progress.attached .bar{border-radius:0}.ui.progress.top.attached,.ui.progress.top.attached .bar{top:0;border-radius:.28571429rem .28571429rem 0 0}.ui.progress.top.attached .bar{border-radius:0}.ui.card>.ui.attached.progress,.ui.segment>.ui.attached.progress{position:absolute;top:auto;left:0;bottom:100%;width:100%}.ui.card>.ui.bottom.attached.progress,.ui.segment>.ui.bottom.attached.progress{top:100%;bottom:auto}.ui.indeterminate.primary.progress .bar::before,.ui.primary.progress .bar,.ui.progress .primary.bar{background-color:#2185d0}.ui.inverted.indeterminate.primary.progress .bar::before,.ui.inverted.progress .primary.bar,.ui.primary.inverted.progress .bar{background-color:#54c8ff}.ui.indeterminate.secondary.progress .bar::before,.ui.progress .secondary.bar,.ui.secondary.progress .bar{background-color:#1b1c1d}.ui.inverted.indeterminate.secondary.progress .bar::before,.ui.inverted.progress .secondary.bar,.ui.secondary.inverted.progress .bar{background-color:#545454}.ui.indeterminate.red.progress .bar::before,.ui.progress .red.bar,.ui.red.progress .bar{background-color:#db2828}.ui.inverted.indeterminate.red.progress .bar::before,.ui.inverted.progress .red.bar,.ui.red.inverted.progress .bar{background-color:#ff695e}.ui.indeterminate.orange.progress .bar::before,.ui.orange.progress .bar,.ui.progress .orange.bar{background-color:#f2711c}.ui.inverted.indeterminate.orange.progress .bar::before,.ui.inverted.progress .orange.bar,.ui.orange.inverted.progress .bar{background-color:#ff851b}.ui.indeterminate.yellow.progress .bar::before,.ui.progress .yellow.bar,.ui.yellow.progress .bar{background-color:#fbbd08}.ui.inverted.indeterminate.yellow.progress .bar::before,.ui.inverted.progress .yellow.bar,.ui.yellow.inverted.progress .bar{background-color:#ffe21f}.ui.indeterminate.olive.progress .bar::before,.ui.olive.progress .bar,.ui.progress .olive.bar{background-color:#b5cc18}.ui.inverted.indeterminate.olive.progress .bar::before,.ui.inverted.progress .olive.bar,.ui.olive.inverted.progress .bar{background-color:#d9e778}.ui.green.progress .bar,.ui.indeterminate.green.progress .bar::before,.ui.progress .green.bar{background-color:#21ba45}.ui.green.inverted.progress .bar,.ui.inverted.indeterminate.green.progress .bar::before,.ui.inverted.progress .green.bar{background-color:#2ecc40}.ui.indeterminate.teal.progress .bar::before,.ui.progress .teal.bar,.ui.teal.progress .bar{background-color:#00b5ad}.ui.inverted.indeterminate.teal.progress .bar::before,.ui.inverted.progress .teal.bar,.ui.teal.inverted.progress .bar{background-color:#6dffff}.ui.blue.progress .bar,.ui.indeterminate.blue.progress .bar::before,.ui.progress .blue.bar{background-color:#2185d0}.ui.blue.inverted.progress .bar,.ui.inverted.indeterminate.blue.progress .bar::before,.ui.inverted.progress .blue.bar{background-color:#54c8ff}.ui.indeterminate.violet.progress .bar::before,.ui.progress .violet.bar,.ui.violet.progress .bar{background-color:#6435c9}.ui.inverted.indeterminate.violet.progress .bar::before,.ui.inverted.progress .violet.bar,.ui.violet.inverted.progress .bar{background-color:#a291fb}.ui.indeterminate.purple.progress .bar::before,.ui.progress .purple.bar,.ui.purple.progress .bar{background-color:#a333c8}.ui.inverted.indeterminate.purple.progress .bar::before,.ui.inverted.progress .purple.bar,.ui.purple.inverted.progress .bar{background-color:#dc73ff}.ui.indeterminate.pink.progress .bar::before,.ui.pink.progress .bar,.ui.progress .pink.bar{background-color:#e03997}.ui.inverted.indeterminate.pink.progress .bar::before,.ui.inverted.progress .pink.bar,.ui.pink.inverted.progress .bar{background-color:#ff8edf}.ui.brown.progress .bar,.ui.indeterminate.brown.progress .bar::before,.ui.progress .brown.bar{background-color:#a5673f}.ui.brown.inverted.progress .bar,.ui.inverted.indeterminate.brown.progress .bar::before,.ui.inverted.progress .brown.bar{background-color:#d67c1c}.ui.grey.progress .bar,.ui.indeterminate.grey.progress .bar::before,.ui.progress .grey.bar{background-color:#767676}.ui.grey.inverted.progress .bar,.ui.inverted.indeterminate.grey.progress .bar::before,.ui.inverted.progress .grey.bar{background-color:#dcddde}.ui.black.progress .bar,.ui.indeterminate.black.progress .bar::before,.ui.progress .black.bar{background-color:#1b1c1d}.ui.black.inverted.progress .bar,.ui.inverted.indeterminate.black.progress .bar::before,.ui.inverted.progress .black.bar{background-color:#545454}.ui.progress{font-size:1rem}.ui.progress .bar{height:1.75em}.ui.mini.progress{font-size:.78571429rem}.ui.mini.progress .bar{height:.3em}.ui.tiny.progress{font-size:.85714286rem}.ui.tiny.progress .bar{height:.5em}.ui.small.progress{font-size:.92857143rem}.ui.small.progress .bar{height:1em}.ui.large.progress{font-size:1.14285714rem}.ui.large.progress .bar{height:2.5em}.ui.big.progress{font-size:1.28571429rem}.ui.big.progress .bar{height:3.5em}.ui.huge.progress{font-size:1.42857143rem}.ui.huge.progress .bar{height:4em}.ui.massive.progress{font-size:1.71428571rem}.ui.massive.progress .bar{height:5em}.ui.indeterminate.progress .bar{width:100%}.ui.indeterminate.progress .bar .progress,.ui.progress .bar .centered.progress{text-align:center;position:relative}.ui.indeterminate.progress .bar::before{content:'';position:absolute;top:0;bottom:0;border-radius:.28571429rem;-webkit-animation:progress-pulsating 2s ease infinite;animation:progress-pulsating 2s ease infinite;-webkit-transform-origin:center;transform-origin:center;width:100%}.ui.slow.indeterminate.progress .bar::before{-webkit-animation-duration:4s;animation-duration:4s}.ui.fast.indeterminate.progress .bar::before{-webkit-animation-duration:1s;animation-duration:1s}.ui.swinging.indeterminate.progress .bar::before{-webkit-transform-origin:left;transform-origin:left;-webkit-animation-name:progress-swinging;animation-name:progress-swinging}.ui.sliding.indeterminate.progress .bar::before{-webkit-transform-origin:left;transform-origin:left;-webkit-animation-name:progress-sliding;animation-name:progress-sliding}.ui.filling.indeterminate.progress .bar::before{-webkit-animation-name:progress-filling;animation-name:progress-filling}.ui.indeterminate.progress:not(.sliding):not(.filling):not(.swinging) .bar::before{background:#fff}.ui.filling.indeterminate.progress .bar,.ui.sliding.indeterminate.progress .bar,.ui.swinging.indeterminate.progress .bar{background:rgba(0,0,0,.1)}.ui.sliding.indeterminate.progress .bar .progress,.ui.swinging.indeterminate.progress .bar .progress{color:#1b1c1d}.ui.inverted.filling.indeterminate.progress .bar,.ui.inverted.sliding.indeterminate.progress .bar,.ui.inverted.swinging.indeterminate.progress .bar{background:rgba(255,255,255,.08)}.ui.inverted.sliding.indeterminate.progress .bar .progress,.ui.inverted.swinging.indeterminate.progress .bar .progress{color:rgba(255,255,255,.7)}@-webkit-keyframes progress-swinging{0%,100%{width:10%;left:-25%}25%,65%{width:70%}50%{width:10%;left:100%}}@keyframes progress-swinging{0%,100%{width:10%;left:-25%}25%,65%{width:70%}50%{width:10%;left:100%}}@-webkit-keyframes progress-sliding{0%{width:10%;left:-25%}50%{width:70%}100%{width:10%;left:100%}}@keyframes progress-sliding{0%{width:10%;left:-25%}50%{width:70%}100%{width:10%;left:100%}}@-webkit-keyframes progress-filling{0%{-webkit-transform:scale(0,1);transform:scale(0,1)}80%{-webkit-transform:scale(1);transform:scale(1);opacity:1}100%{opacity:0}}@keyframes progress-filling{0%{-webkit-transform:scale(0,1);transform:scale(0,1)}80%{-webkit-transform:scale(1);transform:scale(1);opacity:1}100%{opacity:0}}@-webkit-keyframes progress-pulsating{0%{-webkit-transform:scale(0,1);transform:scale(0,1);opacity:.7}100%{-webkit-transform:scale(1);transform:scale(1);opacity:0}}@keyframes progress-pulsating{0%{-webkit-transform:scale(0,1);transform:scale(0,1);opacity:.7}100%{-webkit-transform:scale(1);transform:scale(1);opacity:0}}
|
9
|
+
*/.ui.progress{position:relative;display:-webkit-box;display:-ms-flexbox;display:flex;max-width:100%;border:none;margin:1em 0 2.5em;-webkit-box-shadow:none;box-shadow:none;background:rgba(0,0,0,.1);padding:0;border-radius:.28571429rem}.ui.progress:first-child{margin:0 0 2.5em}.ui.progress:last-child{margin:0 0 1.5em}.ui.progress .bar{display:block;line-height:1;position:relative;width:0;min-width:2em;background:#888;border-radius:.28571429rem;-webkit-transition:width .1s ease,background-color .1s ease;transition:width .1s ease,background-color .1s ease;overflow:hidden}.ui.ui.ui.progress:not([data-percent]):not(.indeterminate) .bar,.ui.ui.ui.progress[data-percent="0"]:not(.indeterminate) .bar{background:0 0}.ui.progress[data-percent="0"] .bar .progress{color:rgba(0,0,0,.87)}.ui.inverted.progress[data-percent="0"] .bar .progress{color:rgba(255,255,255,.9)}.ui.progress .bar>.progress{white-space:nowrap;position:absolute;width:auto;font-size:.92857143em;top:50%;right:.5em;left:auto;bottom:auto;color:rgba(255,255,255,.7);text-shadow:none;margin-top:-.5em;font-weight:700;text-align:left}.ui.right.aligned.progress{-webkit-box-pack:end;-ms-flex-pack:end;justify-content:flex-end}.ui.right.aligned.progress .bar>.progress{left:.5em;right:auto}.ui.progress>.label{position:absolute;width:100%;font-size:1em;top:100%;right:auto;left:0;bottom:auto;color:rgba(0,0,0,.87);font-weight:700;text-shadow:none;margin-top:.2em;text-align:center;-webkit-transition:color .4s ease;transition:color .4s ease}.ui.indicating.progress[data-percent^="1"] .bar,.ui.indicating.progress[data-percent^="2"] .bar{background-color:#d95c5c}.ui.indicating.progress[data-percent^="3"] .bar{background-color:#efbc72}.ui.indicating.progress[data-percent^="4"] .bar,.ui.indicating.progress[data-percent^="5"] .bar{background-color:#e6bb48}.ui.indicating.progress[data-percent^="6"] .bar{background-color:#ddc928}.ui.indicating.progress[data-percent^="7"] .bar,.ui.indicating.progress[data-percent^="8"] .bar{background-color:#b4d95c}.ui.indicating.progress[data-percent^="100"] .bar,.ui.indicating.progress[data-percent^="9"] .bar{background-color:#66da81}.ui.indicating.progress[data-percent^="1"] .label,.ui.indicating.progress[data-percent^="2"] .label{color:rgba(0,0,0,.87)}.ui.indicating.progress[data-percent^="3"] .label{color:rgba(0,0,0,.87)}.ui.indicating.progress[data-percent^="4"] .label,.ui.indicating.progress[data-percent^="5"] .label{color:rgba(0,0,0,.87)}.ui.indicating.progress[data-percent^="6"] .label{color:rgba(0,0,0,.87)}.ui.indicating.progress[data-percent^="7"] .label,.ui.indicating.progress[data-percent^="8"] .label{color:rgba(0,0,0,.87)}.ui.indicating.progress[data-percent^="100"] .label,.ui.indicating.progress[data-percent^="9"] .label{color:rgba(0,0,0,.87)}.ui.inverted.indicating.progress[data-percent^="1"] .label,.ui.inverted.indicating.progress[data-percent^="2"] .label{color:rgba(255,255,255,.9)}.ui.inverted.indicating.progress[data-percent^="3"] .label{color:rgba(255,255,255,.9)}.ui.inverted.indicating.progress[data-percent^="4"] .label,.ui.inverted.indicating.progress[data-percent^="5"] .label{color:rgba(255,255,255,.9)}.ui.inverted.indicating.progress[data-percent^="6"] .label{color:rgba(255,255,255,.9)}.ui.inverted.indicating.progress[data-percent^="7"] .label,.ui.inverted.indicating.progress[data-percent^="8"] .label{color:rgba(255,255,255,.9)}.ui.inverted.indicating.progress[data-percent^="100"] .label,.ui.inverted.indicating.progress[data-percent^="9"] .label{color:rgba(255,255,255,.9)}.ui.indicating.progress[data-percent="1"] .bar,.ui.indicating.progress[data-percent="2"] .bar,.ui.indicating.progress[data-percent="3"] .bar,.ui.indicating.progress[data-percent="4"] .bar,.ui.indicating.progress[data-percent="5"] .bar,.ui.indicating.progress[data-percent="6"] .bar,.ui.indicating.progress[data-percent="7"] .bar,.ui.indicating.progress[data-percent="8"] .bar,.ui.indicating.progress[data-percent="9"] .bar,.ui.indicating.progress[data-percent^="1."] .bar,.ui.indicating.progress[data-percent^="2."] .bar,.ui.indicating.progress[data-percent^="3."] .bar,.ui.indicating.progress[data-percent^="4."] .bar,.ui.indicating.progress[data-percent^="5."] .bar,.ui.indicating.progress[data-percent^="6."] .bar,.ui.indicating.progress[data-percent^="7."] .bar,.ui.indicating.progress[data-percent^="8."] .bar,.ui.indicating.progress[data-percent^="9."] .bar{background-color:#d95c5c}.ui.indicating.progress[data-percent="0"] .label,.ui.indicating.progress[data-percent="1"] .label,.ui.indicating.progress[data-percent="2"] .label,.ui.indicating.progress[data-percent="3"] .label,.ui.indicating.progress[data-percent="4"] .label,.ui.indicating.progress[data-percent="5"] .label,.ui.indicating.progress[data-percent="6"] .label,.ui.indicating.progress[data-percent="7"] .label,.ui.indicating.progress[data-percent="8"] .label,.ui.indicating.progress[data-percent="9"] .label,.ui.indicating.progress[data-percent^="0."] .label,.ui.indicating.progress[data-percent^="1."] .label,.ui.indicating.progress[data-percent^="2."] .label,.ui.indicating.progress[data-percent^="3."] .label,.ui.indicating.progress[data-percent^="4."] .label,.ui.indicating.progress[data-percent^="5."] .label,.ui.indicating.progress[data-percent^="6."] .label,.ui.indicating.progress[data-percent^="7."] .label,.ui.indicating.progress[data-percent^="8."] .label,.ui.indicating.progress[data-percent^="9."] .label{color:rgba(0,0,0,.87)}.ui.inverted.indicating.progress[data-percent="0"] .label,.ui.inverted.indicating.progress[data-percent="1"] .label,.ui.inverted.indicating.progress[data-percent="2"] .label,.ui.inverted.indicating.progress[data-percent="3"] .label,.ui.inverted.indicating.progress[data-percent="4"] .label,.ui.inverted.indicating.progress[data-percent="5"] .label,.ui.inverted.indicating.progress[data-percent="6"] .label,.ui.inverted.indicating.progress[data-percent="7"] .label,.ui.inverted.indicating.progress[data-percent="8"] .label,.ui.inverted.indicating.progress[data-percent="9"] .label,.ui.inverted.indicating.progress[data-percent^="0."] .label,.ui.inverted.indicating.progress[data-percent^="1."] .label,.ui.inverted.indicating.progress[data-percent^="2."] .label,.ui.inverted.indicating.progress[data-percent^="3."] .label,.ui.inverted.indicating.progress[data-percent^="4."] .label,.ui.inverted.indicating.progress[data-percent^="5."] .label,.ui.inverted.indicating.progress[data-percent^="6."] .label,.ui.inverted.indicating.progress[data-percent^="7."] .label,.ui.inverted.indicating.progress[data-percent^="8."] .label,.ui.inverted.indicating.progress[data-percent^="9."] .label{color:rgba(255,255,255,.9)}.ui.ui.indicating.progress.success .label{color:#1a531b}.ui.ui.progress.success .bar{background-color:#21ba45}.ui.ui.progress.success .bar,.ui.ui.progress.success .bar::after{-webkit-animation:none;animation:none}.ui.progress.success>.label{color:#1a531b}.ui.ui.progress.warning .bar{background-color:#f2c037}.ui.ui.progress.warning .bar,.ui.ui.progress.warning .bar::after{-webkit-animation:none;animation:none}.ui.progress.warning>.label{color:#794b02}.ui.ui.progress.error .bar{background-color:#db2828}.ui.ui.progress.error .bar,.ui.ui.progress.error .bar::after{-webkit-animation:none;animation:none}.ui.progress.error>.label{color:#912d2b}.ui.active.progress .bar{position:relative;min-width:2em}.ui.active.progress .bar::after{content:'';opacity:0;position:absolute;top:0;left:0;right:0;bottom:0;background:#fff;border-radius:.28571429rem;-webkit-animation:progress-active 2s ease infinite;animation:progress-active 2s ease infinite;-webkit-transform-origin:left;transform-origin:left}.ui.active.right.aligned.progress .bar::after{-webkit-transform-origin:right;transform-origin:right}@-webkit-keyframes progress-active{0%{opacity:.3;-webkit-transform:scale(0,1);transform:scale(0,1)}100%{opacity:0;-webkit-transform:scale(1);transform:scale(1)}}@keyframes progress-active{0%{opacity:.3;-webkit-transform:scale(0,1);transform:scale(0,1)}100%{opacity:0;-webkit-transform:scale(1);transform:scale(1)}}.ui.disabled.progress{opacity:.35}.ui.ui.disabled.progress .bar,.ui.ui.disabled.progress .bar::after{-webkit-animation:none;animation:none}.ui.inverted.progress{background:rgba(255,255,255,.08);border:none}.ui.inverted.progress .bar{background:#888}.ui.inverted.progress .bar>.progress{color:#1b1c1d}.ui.inverted.progress>.label{color:#fff}.ui.inverted.progress.success>.label{color:#21ba45}.ui.inverted.progress.warning>.label{color:#f2c037}.ui.inverted.progress.error>.label{color:#db2828}.ui.progress.attached{background:0 0;position:relative;border:none;margin:0}.ui.progress.attached,.ui.progress.attached .bar{height:.2rem;padding:0;overflow:hidden;border-radius:0 0 .28571429rem .28571429rem}.ui.progress.attached .bar{border-radius:0}.ui.progress.top.attached,.ui.progress.top.attached .bar{top:0;border-radius:.28571429rem .28571429rem 0 0}.ui.progress.top.attached .bar{border-radius:0}.ui.card>.ui.attached.progress,.ui.segment>.ui.attached.progress{position:absolute;top:auto;left:0;bottom:100%;width:100%}.ui.card>.ui.bottom.attached.progress,.ui.segment>.ui.bottom.attached.progress{top:100%;bottom:auto}.ui.indeterminate.primary.progress .bar::before,.ui.primary.progress .bar,.ui.progress .primary.bar{background-color:#2185d0}.ui.inverted.indeterminate.primary.progress .bar::before,.ui.inverted.progress .primary.bar,.ui.primary.inverted.progress .bar{background-color:#54c8ff}.ui.indeterminate.secondary.progress .bar::before,.ui.progress .secondary.bar,.ui.secondary.progress .bar{background-color:#1b1c1d}.ui.inverted.indeterminate.secondary.progress .bar::before,.ui.inverted.progress .secondary.bar,.ui.secondary.inverted.progress .bar{background-color:#545454}.ui.indeterminate.red.progress .bar::before,.ui.progress .red.bar,.ui.red.progress .bar{background-color:#db2828}.ui.inverted.indeterminate.red.progress .bar::before,.ui.inverted.progress .red.bar,.ui.red.inverted.progress .bar{background-color:#ff695e}.ui.indeterminate.orange.progress .bar::before,.ui.orange.progress .bar,.ui.progress .orange.bar{background-color:#f2711c}.ui.inverted.indeterminate.orange.progress .bar::before,.ui.inverted.progress .orange.bar,.ui.orange.inverted.progress .bar{background-color:#ff851b}.ui.indeterminate.yellow.progress .bar::before,.ui.progress .yellow.bar,.ui.yellow.progress .bar{background-color:#fbbd08}.ui.inverted.indeterminate.yellow.progress .bar::before,.ui.inverted.progress .yellow.bar,.ui.yellow.inverted.progress .bar{background-color:#ffe21f}.ui.indeterminate.olive.progress .bar::before,.ui.olive.progress .bar,.ui.progress .olive.bar{background-color:#b5cc18}.ui.inverted.indeterminate.olive.progress .bar::before,.ui.inverted.progress .olive.bar,.ui.olive.inverted.progress .bar{background-color:#d9e778}.ui.green.progress .bar,.ui.indeterminate.green.progress .bar::before,.ui.progress .green.bar{background-color:#21ba45}.ui.green.inverted.progress .bar,.ui.inverted.indeterminate.green.progress .bar::before,.ui.inverted.progress .green.bar{background-color:#2ecc40}.ui.indeterminate.teal.progress .bar::before,.ui.progress .teal.bar,.ui.teal.progress .bar{background-color:#00b5ad}.ui.inverted.indeterminate.teal.progress .bar::before,.ui.inverted.progress .teal.bar,.ui.teal.inverted.progress .bar{background-color:#6dffff}.ui.blue.progress .bar,.ui.indeterminate.blue.progress .bar::before,.ui.progress .blue.bar{background-color:#2185d0}.ui.blue.inverted.progress .bar,.ui.inverted.indeterminate.blue.progress .bar::before,.ui.inverted.progress .blue.bar{background-color:#54c8ff}.ui.indeterminate.violet.progress .bar::before,.ui.progress .violet.bar,.ui.violet.progress .bar{background-color:#6435c9}.ui.inverted.indeterminate.violet.progress .bar::before,.ui.inverted.progress .violet.bar,.ui.violet.inverted.progress .bar{background-color:#a291fb}.ui.indeterminate.purple.progress .bar::before,.ui.progress .purple.bar,.ui.purple.progress .bar{background-color:#a333c8}.ui.inverted.indeterminate.purple.progress .bar::before,.ui.inverted.progress .purple.bar,.ui.purple.inverted.progress .bar{background-color:#dc73ff}.ui.indeterminate.pink.progress .bar::before,.ui.pink.progress .bar,.ui.progress .pink.bar{background-color:#e03997}.ui.inverted.indeterminate.pink.progress .bar::before,.ui.inverted.progress .pink.bar,.ui.pink.inverted.progress .bar{background-color:#ff8edf}.ui.brown.progress .bar,.ui.indeterminate.brown.progress .bar::before,.ui.progress .brown.bar{background-color:#a5673f}.ui.brown.inverted.progress .bar,.ui.inverted.indeterminate.brown.progress .bar::before,.ui.inverted.progress .brown.bar{background-color:#d67c1c}.ui.grey.progress .bar,.ui.indeterminate.grey.progress .bar::before,.ui.progress .grey.bar{background-color:#767676}.ui.grey.inverted.progress .bar,.ui.inverted.indeterminate.grey.progress .bar::before,.ui.inverted.progress .grey.bar{background-color:#dcddde}.ui.black.progress .bar,.ui.indeterminate.black.progress .bar::before,.ui.progress .black.bar{background-color:#1b1c1d}.ui.black.inverted.progress .bar,.ui.inverted.indeterminate.black.progress .bar::before,.ui.inverted.progress .black.bar{background-color:#545454}.ui.progress{font-size:1rem}.ui.progress .bar{height:1.75em}.ui.mini.progress{font-size:.78571429rem}.ui.mini.progress .bar{height:.3em}.ui.tiny.progress{font-size:.85714286rem}.ui.tiny.progress .bar{height:.5em}.ui.small.progress{font-size:.92857143rem}.ui.small.progress .bar{height:1em}.ui.large.progress{font-size:1.14285714rem}.ui.large.progress .bar{height:2.5em}.ui.big.progress{font-size:1.28571429rem}.ui.big.progress .bar{height:3.5em}.ui.huge.progress{font-size:1.42857143rem}.ui.huge.progress .bar{height:4em}.ui.massive.progress{font-size:1.71428571rem}.ui.massive.progress .bar{height:5em}.ui.indeterminate.progress .bar{width:100%}.ui.indeterminate.progress .bar .progress,.ui.progress .bar .centered.progress{text-align:center;position:relative;right:0}.ui.indeterminate.progress .bar::before{content:'';position:absolute;top:0;bottom:0;border-radius:.28571429rem;-webkit-animation:progress-pulsating 2s ease infinite;animation:progress-pulsating 2s ease infinite;-webkit-transform-origin:center;transform-origin:center;width:100%}.ui.slow.indeterminate.progress .bar::before{-webkit-animation-duration:4s;animation-duration:4s}.ui.fast.indeterminate.progress .bar::before{-webkit-animation-duration:1s;animation-duration:1s}.ui.swinging.indeterminate.progress .bar::before{-webkit-transform-origin:left;transform-origin:left;-webkit-animation-name:progress-swinging;animation-name:progress-swinging}.ui.sliding.indeterminate.progress .bar::before{-webkit-transform-origin:left;transform-origin:left;-webkit-animation-name:progress-sliding;animation-name:progress-sliding}.ui.filling.indeterminate.progress .bar::before{-webkit-animation-name:progress-filling;animation-name:progress-filling}.ui.indeterminate.progress:not(.sliding):not(.filling):not(.swinging) .bar::before{background:#fff}.ui.filling.indeterminate.progress .bar,.ui.sliding.indeterminate.progress .bar,.ui.swinging.indeterminate.progress .bar{background:rgba(0,0,0,.1)}.ui.sliding.indeterminate.progress .bar .progress,.ui.swinging.indeterminate.progress .bar .progress{color:#1b1c1d}.ui.inverted.filling.indeterminate.progress .bar,.ui.inverted.sliding.indeterminate.progress .bar,.ui.inverted.swinging.indeterminate.progress .bar{background:rgba(255,255,255,.08)}.ui.inverted.sliding.indeterminate.progress .bar .progress,.ui.inverted.swinging.indeterminate.progress .bar .progress{color:rgba(255,255,255,.7)}@-webkit-keyframes progress-swinging{0%,100%{width:10%;left:-25%}25%,65%{width:70%}50%{width:10%;left:100%}}@keyframes progress-swinging{0%,100%{width:10%;left:-25%}25%,65%{width:70%}50%{width:10%;left:100%}}@-webkit-keyframes progress-sliding{0%{width:10%;left:-25%}50%{width:70%}100%{width:10%;left:100%}}@keyframes progress-sliding{0%{width:10%;left:-25%}50%{width:70%}100%{width:10%;left:100%}}@-webkit-keyframes progress-filling{0%{-webkit-transform:scale(0,1);transform:scale(0,1)}80%{-webkit-transform:scale(1);transform:scale(1);opacity:1}100%{opacity:0}}@keyframes progress-filling{0%{-webkit-transform:scale(0,1);transform:scale(0,1)}80%{-webkit-transform:scale(1);transform:scale(1);opacity:1}100%{opacity:0}}@-webkit-keyframes progress-pulsating{0%{-webkit-transform:scale(0,1);transform:scale(0,1);opacity:.7}100%{-webkit-transform:scale(1);transform:scale(1);opacity:0}}@keyframes progress-pulsating{0%{-webkit-transform:scale(0,1);transform:scale(0,1);opacity:.7}100%{-webkit-transform:scale(1);transform:scale(1);opacity:0}}
|
@@ -1,11 +1,11 @@
|
|
1
|
-
|
2
|
-
* # Fomantic UI - 2.
|
1
|
+
/*
|
2
|
+
* # Fomantic UI - 2.9.0-beta.100
|
3
3
|
* https://github.com/fomantic/Fomantic-UI
|
4
4
|
* http://fomantic-ui.com/
|
5
5
|
*
|
6
|
-
* Copyright
|
6
|
+
* Copyright 2021 Contributors
|
7
7
|
* Released under the MIT license
|
8
8
|
* http://opensource.org/licenses/MIT
|
9
9
|
*
|
10
10
|
*/
|
11
|
-
!function(E,e,T,P){"use strict";E.isFunction=E.isFunction||function(e){return"function"==typeof e&&"number"!=typeof e.nodeType},e=void 0!==e&&e.Math==Math?e:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")(),E.fn.progress=function(m){var b,e=E(this),h=e.selector||"",x=(new Date).getTime(),y=[],w=m,A="string"==typeof w,V=[].slice.call(arguments,1);return e.each(function(){var c,s=E.isPlainObject(m)?E.extend(!0,{},E.fn.progress.settings,m):E.extend({},E.fn.progress.settings),n=s.className,t=s.metadata,e=s.namespace,r=s.selector,l=s.error,a="."+e,o="module-"+e,u=E(this),p=E(this).find(r.bar),i=E(this).find(r.progress),d=E(this).find(r.label),g=this,v=u.data(o),f=!1;c={helper:{sum:function(e){return Array.isArray(e)?e.reduce(function(e,t){return e+Number(t)},0):0},derivePrecision:function(e,t){for(var n=0,r=1,a=e/t;n<10&&!(1<(a*=r));)r=Math.pow(10,n++);return r},forceArray:function(e){return Array.isArray(e)?e:isNaN(e)?"string"==typeof e?e.split(","):[]:[e]}},initialize:function(){c.set.duration(),c.set.transitionEvent(),c.debug(g),c.read.metadata(),c.read.settings(),c.instantiate()},instantiate:function(){c.verbose("Storing instance of progress",c),v=c,u.data(o,c)},destroy:function(){c.verbose("Destroying previous progress for",u),clearInterval(v.interval),c.remove.state(),u.removeData(o),v=P},reset:function(){c.remove.nextValue(),c.update.progress(0)},complete:function(e){(c.percent===P||c.percent<100)&&(c.remove.progressPoll(),!0!==e&&c.set.percent(100))},read:{metadata:function(){var e={percent:c.helper.forceArray(u.data(t.percent)),total:u.data(t.total),value:c.helper.forceArray(u.data(t.value))};e.total!==P&&(c.debug("Total value set from metadata",e.total),c.set.total(e.total)),0<e.value.length&&(c.debug("Current value set from metadata",e.value),c.set.value(e.value),c.set.progress(e.value)),0<e.percent.length&&(c.debug("Current percent value set from metadata",e.percent),c.set.percent(e.percent))},settings:function(){!1!==s.total&&(c.debug("Current total set in settings",s.total),c.set.total(s.total)),!1!==s.value&&(c.debug("Current value set in settings",s.value),c.set.value(s.value),c.set.progress(c.value)),!1!==s.percent&&(c.debug("Current percent set in settings",s.percent),c.set.percent(s.percent))}},bind:{transitionEnd:function(t){var e=c.get.transitionEnd();p.one(e+a,function(e){clearTimeout(c.failSafeTimer),t.call(this,e)}),c.failSafeTimer=setTimeout(function(){p.triggerHandler(e)},s.duration+s.failSafeDelay),c.verbose("Adding fail safe timer",c.timer)}},increment:function(e){var t,n;e=c.has.total()?(t=c.get.value(),e||1):(t=c.get.percent(),e||c.get.randomValue()),n=t+e,c.debug("Incrementing percentage by",t,n,e),n=c.get.normalizedValue(n),c.set.progress(n)},decrement:function(e){var t,n;c.get.total()?(n=(t=c.get.value())-(e=e||1),c.debug("Decrementing value by",e,t)):(n=(t=c.get.percent())-(e=e||c.get.randomValue()),c.debug("Decrementing percentage by",e,t)),n=c.get.normalizedValue(n),c.set.progress(n)},has:{progressPoll:function(){return c.progressPoll},total:function(){return!1!==c.get.total()}},get:{text:function(e,t){var n=t||0,r=c.get.value(n),a=c.get.total(),o=f?c.get.displayPercent(n):c.get.percent(n),i=!1!==a?Math.max(0,a-r):100-o;return e=(e=e||"").replace("{value}",r).replace("{total}",a||0).replace("{left}",i).replace("{percent}",o).replace("{bar}",s.text.bars[n]||""),c.verbose("Adding variables to progress bar text",e),e},normalizedValue:function(e){if(e<0)return c.debug("Value cannot decrement below 0"),0;if(c.has.total()){if(e>c.total)return c.debug("Value cannot increment above total",c.total),c.total}else if(100<e)return c.debug("Value cannot increment above 100 percent"),100;return e},updateInterval:function(){return"auto"==s.updateInterval?s.duration:s.updateInterval},randomValue:function(){return c.debug("Generating random increment percentage"),Math.floor(Math.random()*s.random.max+s.random.min)},numericValue:function(e){return"string"==typeof e?""!==e.replace(/[^\d.]/g,"")&&+e.replace(/[^\d.]/g,""):e},transitionEnd:function(){var e,t=T.createElement("element"),n={transition:"transitionend",OTransition:"oTransitionEnd",MozTransition:"transitionend",WebkitTransition:"webkitTransitionEnd"};for(e in n)if(t.style[e]!==P)return n[e]},displayPercent:function(e){var t=E(p[e]),n=t.width(),r=u.width(),a=parseInt(t.css("min-width"),10)<n?n/r*100:c.percent;return 0<s.precision?Math.round(a*(10*s.precision))/(10*s.precision):Math.round(a)},percent:function(e){return c.percent&&c.percent[e||0]||0},value:function(e){return c.nextValue||c.value&&c.value[e||0]||0},total:function(){return c.total!==P&&c.total}},create:{progressPoll:function(){c.progressPoll=setTimeout(function(){c.update.toNextValue(),c.remove.progressPoll()},c.get.updateInterval())}},is:{complete:function(){return c.is.success()||c.is.warning()||c.is.error()},success:function(){return u.hasClass(n.success)},warning:function(){return u.hasClass(n.warning)},error:function(){return u.hasClass(n.error)},active:function(){return u.hasClass(n.active)},visible:function(){return u.is(":visible")}},remove:{progressPoll:function(){c.verbose("Removing progress poll timer"),c.progressPoll&&(clearTimeout(c.progressPoll),delete c.progressPoll)},nextValue:function(){c.verbose("Removing progress value stored for next update"),delete c.nextValue},state:function(){c.verbose("Removing stored state"),delete c.total,delete c.percent,delete c.value},active:function(){c.verbose("Removing active state"),u.removeClass(n.active)},success:function(){c.verbose("Removing success state"),u.removeClass(n.success)},warning:function(){c.verbose("Removing warning state"),u.removeClass(n.warning)},error:function(){c.verbose("Removing error state"),u.removeClass(n.error)}},set:{barWidth:function(e){c.debug("set bar width with ",e),e=c.helper.forceArray(e);var a=-1,o=-1,i=c.helper.sum(e),s=p.length,l=1<s,t=e.map(function(e,t){var n=t===s-1&&0===i,r=E(p[t]);return 0===e&&l&&!n?r.css("display","none"):(l&&n&&r.css("background","transparent"),-1==a&&(a=t),o=t,r.css({display:"block",width:e+"%"})),parseFloat(e)});e.forEach(function(e,t){E(p[t]).css({borderTopLeftRadius:t==a?"":0,borderBottomLeftRadius:t==a?"":0,borderTopRightRadius:t==o?"":0,borderBottomRightRadius:t==o?"":0})}),u.attr("data-percent",t)},duration:function(e){e="number"==typeof(e=e||s.duration)?e+"ms":e,c.verbose("Setting progress bar transition duration",e),p.css({"transition-duration":e})},percent:function(e){e=c.helper.forceArray(e).map(function(e){return e="string"==typeof e?+e.replace("%",""):e,s.limitValues?Math.max(0,Math.min(100,e)):e});var t=c.has.total(),n=c.helper.sum(e),r=1<e.length&&t,a=c.helper.sum(c.helper.forceArray(c.value));if(r&&a>c.total)c.error(l.sumExceedsTotal,a,c.total);else if(!r&&100<n)c.error(l.tooHigh,n);else if(n<0)c.error(l.tooLow,n);else{var o=0<s.precision?s.precision:r?c.helper.derivePrecision(Math.min.apply(null,c.value),c.total):0,i=e.map(function(e){return 0<o?Math.round(e*(10*o))/(10*o):Math.round(e)});c.percent=i,t&&(c.value=e.map(function(e){return 0<o?Math.round(e/100*c.total*(10*o))/(10*o):Math.round(e/100*c.total*10)/10})),c.set.barWidth(e),c.set.labelInterval()}s.onChange.call(g,e,c.value,c.total)},labelInterval:function(){clearInterval(c.interval),c.bind.transitionEnd(function(){c.verbose("Bar finished animating, removing continuous label updates"),clearInterval(c.interval),f=!1,c.set.labels()}),f=!0,c.interval=setInterval(function(){E.contains(T.documentElement,g)||(clearInterval(c.interval),f=!1),c.set.labels()},s.framerate)},labels:function(){c.verbose("Setting both bar progress and outer label text"),c.set.barLabel(),c.set.state()},label:function(e){(e=e||"")&&(e=c.get.text(e),c.verbose("Setting label to text",e),d.text(e))},state:function(e){100===(e=e!==P?e:c.helper.sum(c.percent))?s.autoSuccess&&1===p.length&&!(c.is.warning()||c.is.error()||c.is.success())?(c.set.success(),c.debug("Automatically triggering success at 100%")):(c.verbose("Reached 100% removing active state"),c.remove.active(),c.remove.progressPoll()):0<e?(c.verbose("Adjusting active progress bar label",e),c.set.active()):(c.remove.active(),c.set.label(s.text.active))},barLabel:function(r){i.map(function(e,t){var n=E(t);r!==P?n.text(c.get.text(r,e)):"ratio"==s.label&&c.has.total()?(c.verbose("Adding ratio to bar label"),n.text(c.get.text(s.text.ratio,e))):"percent"==s.label&&(c.verbose("Adding percentage to bar label"),n.text(c.get.text(s.text.percent,e)))})},active:function(e){e=e||s.text.active,c.debug("Setting active state"),s.showActivity&&!c.is.active()&&u.addClass(n.active),c.remove.warning(),c.remove.error(),c.remove.success(),(e=s.onLabelUpdate("active",e,c.value,c.total))&&c.set.label(e),c.bind.transitionEnd(function(){s.onActive.call(g,c.value,c.total)})},success:function(e,t){e=e||s.text.success||s.text.active,c.debug("Setting success state"),u.addClass(n.success),c.remove.active(),c.remove.warning(),c.remove.error(),c.complete(t),e=s.text.success?s.onLabelUpdate("success",e,c.value,c.total):s.onLabelUpdate("active",e,c.value,c.total),c.set.label(e),c.bind.transitionEnd(function(){s.onSuccess.call(g,c.total)})},warning:function(e,t){e=e||s.text.warning,c.debug("Setting warning state"),u.addClass(n.warning),c.remove.active(),c.remove.success(),c.remove.error(),c.complete(t),(e=s.onLabelUpdate("warning",e,c.value,c.total))&&c.set.label(e),c.bind.transitionEnd(function(){s.onWarning.call(g,c.value,c.total)})},error:function(e,t){e=e||s.text.error,c.debug("Setting error state"),u.addClass(n.error),c.remove.active(),c.remove.success(),c.remove.warning(),c.complete(t),(e=s.onLabelUpdate("error",e,c.value,c.total))&&c.set.label(e),c.bind.transitionEnd(function(){s.onError.call(g,c.value,c.total)})},transitionEvent:function(){c.get.transitionEnd()},total:function(e){c.total=e},value:function(e){c.value=c.helper.forceArray(e)},progress:function(e){c.has.progressPoll()?(c.debug("Updated within interval, setting next update to use new value",e),c.set.nextValue(e)):(c.debug("First update in progress update interval, immediately updating",e),c.update.progress(e),c.create.progressPoll())},nextValue:function(e){c.nextValue=e}},update:{toNextValue:function(){var e=c.nextValue;e&&(c.debug("Update interval complete using last updated value",e),c.update.progress(e),c.remove.nextValue())},progress:function(e){var n=c.has.total();n&&c.set.value(e);var t=c.helper.forceArray(e).map(function(e){var t;return!1===(e=c.get.numericValue(e))&&c.error(l.nonNumeric,e),e=c.get.normalizedValue(e),n?(t=0<c.total?e/c.total*100:100,c.debug("Calculating percent complete from total",t)):(t=e,c.debug("Setting value to exact percentage value",t)),t});c.set.percent(t)}},setting:function(e,t){if(c.debug("Changing setting",e,t),E.isPlainObject(e))E.extend(!0,s,e);else{if(t===P)return s[e];E.isPlainObject(s[e])?E.extend(!0,s[e],t):s[e]=t}},internal:function(e,t){if(E.isPlainObject(e))E.extend(!0,c,e);else{if(t===P)return c[e];c[e]=t}},debug:function(){!s.silent&&s.debug&&(s.performance?c.performance.log(arguments):(c.debug=Function.prototype.bind.call(console.info,console,s.name+":"),c.debug.apply(console,arguments)))},verbose:function(){!s.silent&&s.verbose&&s.debug&&(s.performance?c.performance.log(arguments):(c.verbose=Function.prototype.bind.call(console.info,console,s.name+":"),c.verbose.apply(console,arguments)))},error:function(){s.silent||(c.error=Function.prototype.bind.call(console.error,console,s.name+":"),c.error.apply(console,arguments))},performance:{log:function(e){var t,n;s.performance&&(n=(t=(new Date).getTime())-(x||t),x=t,y.push({Name:e[0],Arguments:[].slice.call(e,1)||"",Element:g,"Execution Time":n})),clearTimeout(c.performance.timer),c.performance.timer=setTimeout(c.performance.display,500)},display:function(){var e=s.name+":",n=0;x=!1,clearTimeout(c.performance.timer),E.each(y,function(e,t){n+=t["Execution Time"]}),e+=" "+n+"ms",h&&(e+=" '"+h+"'"),(console.group!==P||console.table!==P)&&0<y.length&&(console.groupCollapsed(e),console.table?console.table(y):E.each(y,function(e,t){console.log(t.Name+": "+t["Execution Time"]+"ms")}),console.groupEnd()),y=[]}},invoke:function(r,e,t){var a,o,n,i=v;return e=e||V,t=g||t,"string"==typeof r&&i!==P&&(r=r.split(/[\. ]/),a=r.length-1,E.each(r,function(e,t){var n=e!=a?t+r[e+1].charAt(0).toUpperCase()+r[e+1].slice(1):r;if(E.isPlainObject(i[n])&&e!=a)i=i[n];else{if(i[n]!==P)return o=i[n],!1;if(!E.isPlainObject(i[t])||e==a)return i[t]!==P?o=i[t]:c.error(l.method,r),!1;i=i[t]}})),E.isFunction(o)?n=o.apply(t,e):o!==P&&(n=o),Array.isArray(b)?b.push(n):b!==P?b=[b,n]:n!==P&&(b=n),o}},A?(v===P&&c.initialize(),c.invoke(w)):(v!==P&&v.invoke("destroy"),c.initialize())}),b!==P?b:this},E.fn.progress.settings={name:"Progress",namespace:"progress",silent:!1,debug:!1,verbose:!1,performance:!0,random:{min:2,max:5},duration:300,updateInterval:"auto",autoSuccess:!0,showActivity:!0,limitValues:!0,label:"percent",precision:0,framerate:1e3/30,percent:!1,total:!1,value:!1,failSafeDelay:100,onLabelUpdate:function(e,t,n,r){return t},onChange:function(e,t,n){},onSuccess:function(e){},onActive:function(e,t){},onError:function(e,t){},onWarning:function(e,t){},error:{method:"The method you called is not defined.",nonNumeric:"Progress value is non numeric",tooHigh:"Value specified is above 100%",tooLow:"Value specified is below 0%",sumExceedsTotal:"Sum of multple values exceed total"},regExp:{variable:/\{\$*[A-z0-9]+\}/g},metadata:{percent:"percent",total:"total",value:"value"},selector:{bar:"> .bar",label:"> .label",progress:".bar > .progress"},text:{active:!1,error:!1,success:!1,warning:!1,percent:"{percent}%",ratio:"{value} of {total}",bars:[""]},className:{active:"active",error:"error",success:"success",warning:"warning"}}}(jQuery,window,document);
|
11
|
+
!function(E,e,T,P){"use strict";E.isFunction=E.isFunction||function(e){return"function"==typeof e&&"number"!=typeof e.nodeType},e=void 0!==e&&e.Math==Math?e:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")(),E.fn.progress=function(m){var b,e=E(this),h=e.selector||"",x=(new Date).getTime(),y=[],w=m,A="string"==typeof w,V=[].slice.call(arguments,1);return e.each(function(){var c,s=E.isPlainObject(m)?E.extend(!0,{},E.fn.progress.settings,m):E.extend({},E.fn.progress.settings),n=s.className,t=s.metadata,e=s.namespace,r=s.selector,l=s.error,a="."+e,o="module-"+e,u=E(this),p=E(this).find(r.bar),i=E(this).find(r.progress),d=E(this).find(r.label),g=this,v=u.data(o),f=!1;c={helper:{sum:function(e){return Array.isArray(e)?e.reduce(function(e,t){return e+Number(t)},0):0},derivePrecision:function(e,t){for(var n=0,r=1,a=e/t;n<10&&!(1<(a*=r));)r=Math.pow(10,n++);return r},forceArray:function(e){return Array.isArray(e)?e:isNaN(e)?"string"==typeof e?e.split(","):[]:[e]}},initialize:function(){c.set.duration(),c.set.transitionEvent(),c.debug(g),c.read.metadata(),c.read.settings(),c.instantiate()},instantiate:function(){c.verbose("Storing instance of progress",c),v=c,u.data(o,c)},destroy:function(){c.verbose("Destroying previous progress for",u),clearInterval(v.interval),c.remove.state(),u.removeData(o),v=P},reset:function(){c.remove.nextValue(),c.update.progress(0)},complete:function(e){(c.percent===P||c.percent<100)&&(c.remove.progressPoll(),!0!==e&&c.set.percent(100))},read:{metadata:function(){var e={percent:c.helper.forceArray(u.data(t.percent)),total:u.data(t.total),value:c.helper.forceArray(u.data(t.value))};e.total!==P&&(c.debug("Total value set from metadata",e.total),c.set.total(e.total)),0<e.value.length&&(c.debug("Current value set from metadata",e.value),c.set.value(e.value),c.set.progress(e.value)),0<e.percent.length&&(c.debug("Current percent value set from metadata",e.percent),c.set.percent(e.percent))},settings:function(){!1!==s.total&&(c.debug("Current total set in settings",s.total),c.set.total(s.total)),!1!==s.value&&(c.debug("Current value set in settings",s.value),c.set.value(s.value),c.set.progress(c.value)),!1!==s.percent&&(c.debug("Current percent set in settings",s.percent),c.set.percent(s.percent))}},bind:{transitionEnd:function(t){var e=c.get.transitionEnd();p.one(e+a,function(e){clearTimeout(c.failSafeTimer),t.call(this,e)}),c.failSafeTimer=setTimeout(function(){p.triggerHandler(e)},s.duration+s.failSafeDelay),c.verbose("Adding fail safe timer",c.timer)}},increment:function(e){var t,n;e=c.has.total()?(t=c.get.value(),e||1):(t=c.get.percent(),e||c.get.randomValue()),n=t+e,c.debug("Incrementing percentage by",t,n,e),n=c.get.normalizedValue(n),c.set.progress(n)},decrement:function(e){var t,n;c.get.total()?(n=(t=c.get.value())-(e=e||1),c.debug("Decrementing value by",e,t)):(n=(t=c.get.percent())-(e=e||c.get.randomValue()),c.debug("Decrementing percentage by",e,t)),n=c.get.normalizedValue(n),c.set.progress(n)},has:{progressPoll:function(){return c.progressPoll},total:function(){return!1!==c.get.total()}},get:{text:function(e,t){var n=t||0,r=c.get.value(n),a=c.get.total(),o=f?c.get.displayPercent(n):c.get.percent(n),i=!1!==a?Math.max(0,a-r):100-o;return e=(e=e||"").replace("{value}",r).replace("{total}",a||0).replace("{left}",i).replace("{percent}",o).replace("{bar}",s.text.bars[n]||""),c.verbose("Adding variables to progress bar text",e),e},normalizedValue:function(e){if(e<0)return c.debug("Value cannot decrement below 0"),0;if(c.has.total()){if(e>c.total)return c.debug("Value cannot increment above total",c.total),c.total}else if(100<e)return c.debug("Value cannot increment above 100 percent"),100;return e},updateInterval:function(){return"auto"==s.updateInterval?s.duration:s.updateInterval},randomValue:function(){return c.debug("Generating random increment percentage"),Math.floor(Math.random()*s.random.max+s.random.min)},numericValue:function(e){return"string"==typeof e?""!==e.replace(/[^\d.]/g,"")&&+e.replace(/[^\d.]/g,""):e},transitionEnd:function(){var e,t=T.createElement("element"),n={transition:"transitionend",OTransition:"oTransitionEnd",MozTransition:"transitionend",WebkitTransition:"webkitTransitionEnd"};for(e in n)if(t.style[e]!==P)return n[e]},displayPercent:function(e){var t=E(p[e]),n=t.width(),r=u.width(),a=parseInt(t.css("min-width"),10)<n?n/r*100:c.percent;return 0<s.precision?Math.round(a*(10*s.precision))/(10*s.precision):Math.round(a)},percent:function(e){return c.percent&&c.percent[e||0]||0},value:function(e){return c.nextValue||c.value&&c.value[e||0]||0},total:function(){return c.total!==P&&c.total}},create:{progressPoll:function(){c.progressPoll=setTimeout(function(){c.update.toNextValue(),c.remove.progressPoll()},c.get.updateInterval())}},is:{complete:function(){return c.is.success()||c.is.warning()||c.is.error()},success:function(){return u.hasClass(n.success)},warning:function(){return u.hasClass(n.warning)},error:function(){return u.hasClass(n.error)},active:function(){return u.hasClass(n.active)},visible:function(){return u.is(":visible")}},remove:{progressPoll:function(){c.verbose("Removing progress poll timer"),c.progressPoll&&(clearTimeout(c.progressPoll),delete c.progressPoll)},nextValue:function(){c.verbose("Removing progress value stored for next update"),delete c.nextValue},state:function(){c.verbose("Removing stored state"),delete c.total,delete c.percent,delete c.value},active:function(){c.verbose("Removing active state"),u.removeClass(n.active)},success:function(){c.verbose("Removing success state"),u.removeClass(n.success)},warning:function(){c.verbose("Removing warning state"),u.removeClass(n.warning)},error:function(){c.verbose("Removing error state"),u.removeClass(n.error)}},set:{barWidth:function(e){c.debug("set bar width with ",e),e=c.helper.forceArray(e);var a=-1,o=-1,i=c.helper.sum(e),s=p.length,l=1<s,t=e.map(function(e,t){var n=t===s-1&&0===i,r=E(p[t]);return 0===e&&l&&!n?r.css("display","none"):(l&&n&&r.css("background","transparent"),-1==a&&(a=t),o=t,r.css({display:"block",width:e+"%"})),parseFloat(e)});e.forEach(function(e,t){E(p[t]).css({borderTopLeftRadius:t==a?"":0,borderBottomLeftRadius:t==a?"":0,borderTopRightRadius:t==o?"":0,borderBottomRightRadius:t==o?"":0})}),u.attr("data-percent",t)},duration:function(e){e="number"==typeof(e=e||s.duration)?e+"ms":e,c.verbose("Setting progress bar transition duration",e),p.css({"transition-duration":e})},percent:function(e){e=c.helper.forceArray(e).map(function(e){return e="string"==typeof e?+e.replace("%",""):e,s.limitValues?Math.max(0,Math.min(100,e)):e});var t=c.has.total(),n=c.helper.sum(e),r=1<e.length&&t,a=c.helper.sum(c.helper.forceArray(c.value));if(r&&a>c.total)c.error(l.sumExceedsTotal,a,c.total);else if(!r&&100<n)c.error(l.tooHigh,n);else if(n<0)c.error(l.tooLow,n);else{var o=0<s.precision?s.precision:r?c.helper.derivePrecision(Math.min.apply(null,c.value),c.total):0,i=e.map(function(e){return 0<o?Math.round(e*(10*o))/(10*o):Math.round(e)});c.percent=i,t&&(c.value=e.map(function(e){return 0<o?Math.round(e/100*c.total*(10*o))/(10*o):Math.round(e/100*c.total*10)/10})),c.set.barWidth(e),c.set.labelInterval()}s.onChange.call(g,e,c.value,c.total)},labelInterval:function(){clearInterval(c.interval),c.bind.transitionEnd(function(){c.verbose("Bar finished animating, removing continuous label updates"),clearInterval(c.interval),f=!1,c.set.labels()}),f=!0,c.interval=setInterval(function(){E.contains(T.documentElement,g)||(clearInterval(c.interval),f=!1),c.set.labels()},s.framerate)},labels:function(){c.verbose("Setting both bar progress and outer label text"),c.set.barLabel(),c.set.state()},label:function(e){(e=e||"")&&(e=c.get.text(e),c.verbose("Setting label to text",e),d.text(e))},state:function(e){100===(e=e!==P?e:c.helper.sum(c.percent))?s.autoSuccess&&1===p.length&&!(c.is.warning()||c.is.error()||c.is.success())?(c.set.success(),c.debug("Automatically triggering success at 100%")):(c.verbose("Reached 100% removing active state"),c.remove.active(),c.remove.progressPoll()):0<e?(c.verbose("Adjusting active progress bar label",e),c.set.active()):(c.remove.active(),c.set.label(s.text.active))},barLabel:function(r){i.map(function(e,t){var n=E(t);r!==P?n.text(c.get.text(r,e)):"ratio"==s.label&&c.has.total()?(c.verbose("Adding ratio to bar label"),n.text(c.get.text(s.text.ratio,e))):"percent"==s.label&&(c.verbose("Adding percentage to bar label"),n.text(c.get.text(s.text.percent,e)))})},active:function(e){e=e||s.text.active,c.debug("Setting active state"),s.showActivity&&!c.is.active()&&u.addClass(n.active),c.remove.warning(),c.remove.error(),c.remove.success(),(e=s.onLabelUpdate("active",e,c.value,c.total))&&c.set.label(e),c.bind.transitionEnd(function(){s.onActive.call(g,c.value,c.total)})},success:function(e,t){e=e||s.text.success||s.text.active,c.debug("Setting success state"),u.addClass(n.success),c.remove.active(),c.remove.warning(),c.remove.error(),c.complete(t),e=s.text.success?s.onLabelUpdate("success",e,c.value,c.total):s.onLabelUpdate("active",e,c.value,c.total),c.set.label(e),c.bind.transitionEnd(function(){s.onSuccess.call(g,c.total)})},warning:function(e,t){e=e||s.text.warning,c.debug("Setting warning state"),u.addClass(n.warning),c.remove.active(),c.remove.success(),c.remove.error(),c.complete(t),(e=s.onLabelUpdate("warning",e,c.value,c.total))&&c.set.label(e),c.bind.transitionEnd(function(){s.onWarning.call(g,c.value,c.total)})},error:function(e,t){e=e||s.text.error,c.debug("Setting error state"),u.addClass(n.error),c.remove.active(),c.remove.success(),c.remove.warning(),c.complete(t),(e=s.onLabelUpdate("error",e,c.value,c.total))&&c.set.label(e),c.bind.transitionEnd(function(){s.onError.call(g,c.value,c.total)})},transitionEvent:function(){c.get.transitionEnd()},total:function(e){c.total=e},value:function(e){c.value=c.helper.forceArray(e)},progress:function(e){c.has.progressPoll()?(c.debug("Updated within interval, setting next update to use new value",e),c.set.nextValue(e)):(c.debug("First update in progress update interval, immediately updating",e),c.update.progress(e),c.create.progressPoll())},nextValue:function(e){c.nextValue=e}},update:{toNextValue:function(){var e=c.nextValue;e&&(c.debug("Update interval complete using last updated value",e),c.update.progress(e),c.remove.nextValue())},progress:function(e){var n=c.has.total();n&&c.set.value(e);var t=c.helper.forceArray(e).map(function(e){var t;return!1===(e=c.get.numericValue(e))&&c.error(l.nonNumeric,e),e=c.get.normalizedValue(e),n?(t=0<c.total?e/c.total*100:100,c.debug("Calculating percent complete from total",t)):(t=e,c.debug("Setting value to exact percentage value",t)),t});c.set.percent(t)}},setting:function(e,t){if(c.debug("Changing setting",e,t),E.isPlainObject(e))E.extend(!0,s,e);else{if(t===P)return s[e];E.isPlainObject(s[e])?E.extend(!0,s[e],t):s[e]=t}},internal:function(e,t){if(E.isPlainObject(e))E.extend(!0,c,e);else{if(t===P)return c[e];c[e]=t}},debug:function(){!s.silent&&s.debug&&(s.performance?c.performance.log(arguments):(c.debug=Function.prototype.bind.call(console.info,console,s.name+":"),c.debug.apply(console,arguments)))},verbose:function(){!s.silent&&s.verbose&&s.debug&&(s.performance?c.performance.log(arguments):(c.verbose=Function.prototype.bind.call(console.info,console,s.name+":"),c.verbose.apply(console,arguments)))},error:function(){s.silent||(c.error=Function.prototype.bind.call(console.error,console,s.name+":"),c.error.apply(console,arguments))},performance:{log:function(e){var t,n;s.performance&&(n=(t=(new Date).getTime())-(x||t),x=t,y.push({Name:e[0],Arguments:[].slice.call(e,1)||"",Element:g,"Execution Time":n})),clearTimeout(c.performance.timer),c.performance.timer=setTimeout(c.performance.display,500)},display:function(){var e=s.name+":",n=0;x=!1,clearTimeout(c.performance.timer),E.each(y,function(e,t){n+=t["Execution Time"]}),e+=" "+n+"ms",h&&(e+=" '"+h+"'"),(console.group!==P||console.table!==P)&&0<y.length&&(console.groupCollapsed(e),console.table?console.table(y):E.each(y,function(e,t){console.log(t.Name+": "+t["Execution Time"]+"ms")}),console.groupEnd()),y=[]}},invoke:function(r,e,t){var a,o,n,i=v;return e=e||V,t=g||t,"string"==typeof r&&i!==P&&(r=r.split(/[\. ]/),a=r.length-1,E.each(r,function(e,t){var n=e!=a?t+r[e+1].charAt(0).toUpperCase()+r[e+1].slice(1):r;if(E.isPlainObject(i[n])&&e!=a)i=i[n];else{if(i[n]!==P)return o=i[n],!1;if(!E.isPlainObject(i[t])||e==a)return i[t]!==P?o=i[t]:c.error(l.method,r),!1;i=i[t]}})),E.isFunction(o)?n=o.apply(t,e):o!==P&&(n=o),Array.isArray(b)?b.push(n):b!==P?b=[b,n]:n!==P&&(b=n),o}},A?(v===P&&c.initialize(),c.invoke(w)):(v!==P&&v.invoke("destroy"),c.initialize())}),b!==P?b:this},E.fn.progress.settings={name:"Progress",namespace:"progress",silent:!1,debug:!1,verbose:!1,performance:!0,random:{min:2,max:5},duration:300,updateInterval:"auto",autoSuccess:!0,showActivity:!0,limitValues:!0,label:"percent",precision:0,framerate:1e3/30,percent:!1,total:!1,value:!1,failSafeDelay:100,onLabelUpdate:function(e,t,n,r){return t},onChange:function(e,t,n){},onSuccess:function(e){},onActive:function(e,t){},onError:function(e,t){},onWarning:function(e,t){},error:{method:"The method you called is not defined.",nonNumeric:"Progress value is non numeric",tooHigh:"Value specified is above 100%",tooLow:"Value specified is below 0%",sumExceedsTotal:"Sum of multiple values exceed total"},regExp:{variable:/\{\$*[A-z0-9]+\}/g},metadata:{percent:"percent",total:"total",value:"value"},selector:{bar:"> .bar",label:"> .label",progress:".bar > .progress"},text:{active:!1,error:!1,success:!1,warning:!1,percent:"{percent}%",ratio:"{value} of {total}",bars:[""]},className:{active:"active",error:"error",success:"success",warning:"warning"}}}(jQuery,window,document);
|
package/dist/components/rail.css
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
/*!
|
2
|
-
* # Fomantic-UI - Rating
|
2
|
+
* # Fomantic-UI 2.9.0-beta.100 - Rating
|
3
3
|
* http://github.com/fomantic/Fomantic-UI/
|
4
4
|
*
|
5
5
|
*
|
@@ -72,9 +72,14 @@
|
|
72
72
|
background: -webkit-gradient(linear, left top, right top, from(rgba(0, 0, 0, 0.85)), to(rgba(0, 0, 0, 0.15)));
|
73
73
|
background: -webkit-linear-gradient(left, rgba(0, 0, 0, 0.85) 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
74
74
|
background: linear-gradient(to right, rgba(0, 0, 0, 0.85) 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
75
|
+
}
|
76
|
+
|
77
|
+
/* central override for colors */
|
78
|
+
.ui.ui.rating .icon.partial.active {
|
75
79
|
-webkit-background-clip: text;
|
76
|
-
|
80
|
+
background-clip: text;
|
77
81
|
color: transparent;
|
82
|
+
text-shadow: none;
|
78
83
|
}
|
79
84
|
|
80
85
|
/* Selected Icon */
|
@@ -107,11 +112,7 @@
|
|
107
112
|
background: -webkit-gradient(linear, left top, right top, from(#54C8FF), to(rgba(0, 0, 0, 0.15)));
|
108
113
|
background: -webkit-linear-gradient(left, #54C8FF 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
109
114
|
background: linear-gradient(to right, #54C8FF 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
110
|
-
text-shadow: none;
|
111
115
|
-webkit-text-stroke: #2185D0 0.78px;
|
112
|
-
-webkit-background-clip: text;
|
113
|
-
background-clip: text;
|
114
|
-
color: transparent;
|
115
116
|
}
|
116
117
|
.ui.secondary.rating .active.icon {
|
117
118
|
color: #545454;
|
@@ -130,11 +131,7 @@
|
|
130
131
|
background: -webkit-gradient(linear, left top, right top, from(#545454), to(rgba(0, 0, 0, 0.15)));
|
131
132
|
background: -webkit-linear-gradient(left, #545454 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
132
133
|
background: linear-gradient(to right, #545454 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
133
|
-
text-shadow: none;
|
134
134
|
-webkit-text-stroke: #1B1C1D 0.78px;
|
135
|
-
-webkit-background-clip: text;
|
136
|
-
background-clip: text;
|
137
|
-
color: transparent;
|
138
135
|
}
|
139
136
|
.ui.red.rating .active.icon {
|
140
137
|
color: #FF695E;
|
@@ -153,11 +150,7 @@
|
|
153
150
|
background: -webkit-gradient(linear, left top, right top, from(#FF695E), to(rgba(0, 0, 0, 0.15)));
|
154
151
|
background: -webkit-linear-gradient(left, #FF695E 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
155
152
|
background: linear-gradient(to right, #FF695E 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
156
|
-
text-shadow: none;
|
157
153
|
-webkit-text-stroke: #DB2828 0.78px;
|
158
|
-
-webkit-background-clip: text;
|
159
|
-
background-clip: text;
|
160
|
-
color: transparent;
|
161
154
|
}
|
162
155
|
.ui.orange.rating .active.icon {
|
163
156
|
color: #FF851B;
|
@@ -176,11 +169,7 @@
|
|
176
169
|
background: -webkit-gradient(linear, left top, right top, from(#FF851B), to(rgba(0, 0, 0, 0.15)));
|
177
170
|
background: -webkit-linear-gradient(left, #FF851B 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
178
171
|
background: linear-gradient(to right, #FF851B 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
179
|
-
text-shadow: none;
|
180
172
|
-webkit-text-stroke: #F2711C 0.78px;
|
181
|
-
-webkit-background-clip: text;
|
182
|
-
background-clip: text;
|
183
|
-
color: transparent;
|
184
173
|
}
|
185
174
|
.ui.yellow.rating .active.icon {
|
186
175
|
color: #FFE21F;
|
@@ -199,11 +188,7 @@
|
|
199
188
|
background: -webkit-gradient(linear, left top, right top, from(#FFE21F), to(rgba(0, 0, 0, 0.15)));
|
200
189
|
background: -webkit-linear-gradient(left, #FFE21F 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
201
190
|
background: linear-gradient(to right, #FFE21F 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
202
|
-
text-shadow: none;
|
203
191
|
-webkit-text-stroke: #FBBD08 0.78px;
|
204
|
-
-webkit-background-clip: text;
|
205
|
-
background-clip: text;
|
206
|
-
color: transparent;
|
207
192
|
}
|
208
193
|
.ui.olive.rating .active.icon {
|
209
194
|
color: #D9E778;
|
@@ -222,11 +207,7 @@
|
|
222
207
|
background: -webkit-gradient(linear, left top, right top, from(#D9E778), to(rgba(0, 0, 0, 0.15)));
|
223
208
|
background: -webkit-linear-gradient(left, #D9E778 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
224
209
|
background: linear-gradient(to right, #D9E778 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
225
|
-
text-shadow: none;
|
226
210
|
-webkit-text-stroke: #B5CC18 0.78px;
|
227
|
-
-webkit-background-clip: text;
|
228
|
-
background-clip: text;
|
229
|
-
color: transparent;
|
230
211
|
}
|
231
212
|
.ui.green.rating .active.icon {
|
232
213
|
color: #2ECC40;
|
@@ -245,11 +226,7 @@
|
|
245
226
|
background: -webkit-gradient(linear, left top, right top, from(#2ECC40), to(rgba(0, 0, 0, 0.15)));
|
246
227
|
background: -webkit-linear-gradient(left, #2ECC40 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
247
228
|
background: linear-gradient(to right, #2ECC40 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
248
|
-
text-shadow: none;
|
249
229
|
-webkit-text-stroke: #21BA45 0.78px;
|
250
|
-
-webkit-background-clip: text;
|
251
|
-
background-clip: text;
|
252
|
-
color: transparent;
|
253
230
|
}
|
254
231
|
.ui.teal.rating .active.icon {
|
255
232
|
color: #6DFFFF;
|
@@ -268,11 +245,7 @@
|
|
268
245
|
background: -webkit-gradient(linear, left top, right top, from(#6DFFFF), to(rgba(0, 0, 0, 0.15)));
|
269
246
|
background: -webkit-linear-gradient(left, #6DFFFF 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
270
247
|
background: linear-gradient(to right, #6DFFFF 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
271
|
-
text-shadow: none;
|
272
248
|
-webkit-text-stroke: #00B5AD 0.78px;
|
273
|
-
-webkit-background-clip: text;
|
274
|
-
background-clip: text;
|
275
|
-
color: transparent;
|
276
249
|
}
|
277
250
|
.ui.blue.rating .active.icon {
|
278
251
|
color: #54C8FF;
|
@@ -291,11 +264,7 @@
|
|
291
264
|
background: -webkit-gradient(linear, left top, right top, from(#54C8FF), to(rgba(0, 0, 0, 0.15)));
|
292
265
|
background: -webkit-linear-gradient(left, #54C8FF 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
293
266
|
background: linear-gradient(to right, #54C8FF 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
294
|
-
text-shadow: none;
|
295
267
|
-webkit-text-stroke: #2185D0 0.78px;
|
296
|
-
-webkit-background-clip: text;
|
297
|
-
background-clip: text;
|
298
|
-
color: transparent;
|
299
268
|
}
|
300
269
|
.ui.violet.rating .active.icon {
|
301
270
|
color: #A291FB;
|
@@ -314,11 +283,7 @@
|
|
314
283
|
background: -webkit-gradient(linear, left top, right top, from(#A291FB), to(rgba(0, 0, 0, 0.15)));
|
315
284
|
background: -webkit-linear-gradient(left, #A291FB 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
316
285
|
background: linear-gradient(to right, #A291FB 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
317
|
-
text-shadow: none;
|
318
286
|
-webkit-text-stroke: #6435C9 0.78px;
|
319
|
-
-webkit-background-clip: text;
|
320
|
-
background-clip: text;
|
321
|
-
color: transparent;
|
322
287
|
}
|
323
288
|
.ui.purple.rating .active.icon {
|
324
289
|
color: #DC73FF;
|
@@ -337,11 +302,7 @@
|
|
337
302
|
background: -webkit-gradient(linear, left top, right top, from(#DC73FF), to(rgba(0, 0, 0, 0.15)));
|
338
303
|
background: -webkit-linear-gradient(left, #DC73FF 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
339
304
|
background: linear-gradient(to right, #DC73FF 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
340
|
-
text-shadow: none;
|
341
305
|
-webkit-text-stroke: #A333C8 0.78px;
|
342
|
-
-webkit-background-clip: text;
|
343
|
-
background-clip: text;
|
344
|
-
color: transparent;
|
345
306
|
}
|
346
307
|
.ui.pink.rating .active.icon {
|
347
308
|
color: #FF8EDF;
|
@@ -360,11 +321,7 @@
|
|
360
321
|
background: -webkit-gradient(linear, left top, right top, from(#FF8EDF), to(rgba(0, 0, 0, 0.15)));
|
361
322
|
background: -webkit-linear-gradient(left, #FF8EDF 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
362
323
|
background: linear-gradient(to right, #FF8EDF 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
363
|
-
text-shadow: none;
|
364
324
|
-webkit-text-stroke: #E03997 0.78px;
|
365
|
-
-webkit-background-clip: text;
|
366
|
-
background-clip: text;
|
367
|
-
color: transparent;
|
368
325
|
}
|
369
326
|
.ui.brown.rating .active.icon {
|
370
327
|
color: #D67C1C;
|
@@ -383,11 +340,7 @@
|
|
383
340
|
background: -webkit-gradient(linear, left top, right top, from(#D67C1C), to(rgba(0, 0, 0, 0.15)));
|
384
341
|
background: -webkit-linear-gradient(left, #D67C1C 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
385
342
|
background: linear-gradient(to right, #D67C1C 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
386
|
-
text-shadow: none;
|
387
343
|
-webkit-text-stroke: #A5673F 0.78px;
|
388
|
-
-webkit-background-clip: text;
|
389
|
-
background-clip: text;
|
390
|
-
color: transparent;
|
391
344
|
}
|
392
345
|
.ui.grey.rating .active.icon {
|
393
346
|
color: #DCDDDE;
|
@@ -406,11 +359,7 @@
|
|
406
359
|
background: -webkit-gradient(linear, left top, right top, from(#DCDDDE), to(rgba(0, 0, 0, 0.15)));
|
407
360
|
background: -webkit-linear-gradient(left, #DCDDDE 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
408
361
|
background: linear-gradient(to right, #DCDDDE 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
409
|
-
text-shadow: none;
|
410
362
|
-webkit-text-stroke: #767676 0.78px;
|
411
|
-
-webkit-background-clip: text;
|
412
|
-
background-clip: text;
|
413
|
-
color: transparent;
|
414
363
|
}
|
415
364
|
.ui.black.rating .active.icon {
|
416
365
|
color: #545454;
|
@@ -429,11 +378,7 @@
|
|
429
378
|
background: -webkit-gradient(linear, left top, right top, from(#545454), to(rgba(0, 0, 0, 0.15)));
|
430
379
|
background: -webkit-linear-gradient(left, #545454 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
431
380
|
background: linear-gradient(to right, #545454 0% var(--full), rgba(0, 0, 0, 0.15) var(--full) 100%);
|
432
|
-
text-shadow: none;
|
433
381
|
-webkit-text-stroke: #1B1C1D 0.78px;
|
434
|
-
-webkit-background-clip: text;
|
435
|
-
background-clip: text;
|
436
|
-
color: transparent;
|
437
382
|
}
|
438
383
|
|
439
384
|
|
@@ -450,6 +395,7 @@
|
|
450
395
|
/* disabled rating */
|
451
396
|
.ui.disabled.rating .icon {
|
452
397
|
cursor: default;
|
398
|
+
pointer-events: none;
|
453
399
|
}
|
454
400
|
|
455
401
|
/*-------------------
|