Skip to content

Commit eae400f

Browse files
committedSep 28, 2021
fixes
1 parent 6a10b64 commit eae400f

10 files changed

+45
-0
lines changed
 

‎.idea/.gitignore

+5
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎dist/index.d.ts

+28
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
interface ProgressBarConfig {
2+
/**
3+
* The size (height) of the progress bar.
4+
* Numeric values get converted to px. */
5+
size: number | string;
6+
/**
7+
* Color of the progress bar. Also used for the glow
8+
* around the bar. */
9+
color: string;
10+
/**
11+
* Class name used for the progress bar element. */
12+
className: string;
13+
/**
14+
* Class name used for the progress bar element. */
15+
container: string;
16+
/**
17+
* How many milliseconds to wait before the progress bar
18+
* animation starts after calling .start(). */
19+
delay: number;
20+
}
21+
export default class ProgressBar {
22+
/** Show the progress bar and begin animating it. */
23+
start: () => void;
24+
/** End the progress bar animation. */
25+
finish: () => void;
26+
constructor(options?: Partial<ProgressBarConfig>);
27+
}
28+
export {};

‎dist/index.js

+2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎dist/index.js.map

+1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎dist/index.mjs

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
var e=function(e){this.start=void 0,this.finish=void 0;var t=function(e,t){Object.keys(t).forEach(function(o){e[o]=t[o]})},o={size:2,color:"#29e",className:"bar-of-progress",delay:80,container:"body"};e&&t(o,e);var i,a,s={position:"fixed",top:0,left:0,margin:0,padding:0,border:"none",borderRadius:0,backgroundColor:"currentColor",zIndex:1e4,height:"number"==typeof o.size?o.size+"px":o.size,color:o.color,opacity:0,width:"0%"},n={opacity:1,width:"99%",transition:"width 10s cubic-bezier(0.1, 0.05, 0, 1)"},r={opacity:0,width:"100%",transition:"width 0.1s ease-out, opacity 0.5s ease 0.2s"},l={opacity:.4,boxShadow:"3px 0 8px",height:"100%"};this.start=function(){if(null!==document.querySelector(o.container)){a&&a.parentNode&&a.parentNode.removeChild(a),(a=document.querySelector(o.container).appendChild(document.createElement("div"))).className=o.className+" stopped",t(a.style,s);var e=a.appendChild(document.createElement("div"));e.className="glow",t(e.style,l),null!=i&&clearTimeout(i),i=setTimeout(function(){i=null,a.className=o.className+" started",t(a.style,n)},o.delay),a.scrollTop=0}},this.finish=function(){null!=i&&(clearTimeout(i),i=null),a&&(a.className=o.className+" finished",t(a.style,r))}};export{e as default};
2+
//# sourceMappingURL=index.mjs.map

‎dist/index.mjs.map

+1
Original file line numberDiff line numberDiff line change

‎dist/index.modern.js

+2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)