react-alp-loading-bar 9.0.2 → 9.0.3

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.
@@ -1,7 +1,7 @@
1
- import type { ReactElement } from "react";
1
+ import type { ComponentType, ReactElement } from "react";
2
2
  import { PureComponent } from "react";
3
3
  interface LoadingBarProps {
4
- LoadingBarComponent: React.ComponentType<{
4
+ LoadingBarComponent: ComponentType<{
5
5
  progress: number;
6
6
  }>;
7
7
  websocket: WebsocketInterface;
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,OAAO,CAAC;AAC1C,OAAO,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAmCtC,UAAU,eAAe;IACvB,mBAAmB,EAAE,KAAK,CAAC,aAAa,CAAC;QAAE,QAAQ,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;IAC/D,SAAS,EAAE,kBAAkB,CAAC;CAC/B;AAED,UAAU,eAAe;IACvB,OAAO,EAAE,OAAO,CAAC;IACjB,MAAM,EAAE,OAAO,CAAC;IAChB,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED,UAAU,kBAAkB;IAC1B,WAAW,EAAE,MAAM,OAAO,CAAC;IAC3B,EAAE,EAAE,CAAC,KAAK,EAAE,SAAS,GAAG,YAAY,EAAE,QAAQ,EAAE,MAAM,OAAO,KAAK,IAAI,CAAC;CACxE;AAED,MAAM,CAAC,OAAO,OAAO,UAAW,SAAQ,aAAa,CACnD,eAAe,EACf,eAAe,CAChB;IACU,KAAK;;;;MAIZ;IAEF,cAAc,CAAC,EAAE,UAAU,CAAC,OAAO,UAAU,CAAC,CAAC;IAE/C,YAAY,CAAC,EAAE,UAAU,CAAC,OAAO,UAAU,CAAC,CAAC;IAE7C,cAAc,CAAC,EAAE,UAAU,CAAC,OAAO,UAAU,CAAC,CAAC;IAE/C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B,IAAI,IAAI;IAgBzB,kBAAkB,CACzB,SAAS,EAAE,eAAe,EAC1B,SAAS,EAAE,eAAe,GACzB,IAAI;IAaE,oBAAoB,IAAI,IAAI;IAOrC,OAAO,CAAC,OAAO;IAgBf,OAAO,CAAC,OAAO;IAkBN,MAAM,IAAI,YAAY;CAmBhC"}
@@ -11,14 +11,15 @@ const calculatePercent = (percent) => {
11
11
  else return percent;
12
12
  };
13
13
  class LoadingBar extends PureComponent {
14
- constructor() {
15
- super(...arguments);
16
- this.state = {
17
- loading: true,
18
- hidden: true,
19
- progress: 1
20
- };
21
- }
14
+ state = {
15
+ loading: true,
16
+ hidden: true,
17
+ progress: 1
18
+ };
19
+ fadeOffTimeout;
20
+ resetTimeout;
21
+ first20Timeout;
22
+ progressTimer;
22
23
  componentDidMount() {
23
24
  if (this.props.websocket.isConnected()) {
24
25
  this.setState((prevState) => ({
@@ -1 +1 @@
1
- {"version":3,"file":"index-browser.es.js","sources":["../src/index.tsx"],"sourcesContent":["/* eslint-disable react/destructuring-assignment */\nimport type { ReactElement } from \"react\";\nimport { PureComponent } from \"react\";\n\n/*\nExample with antd:\nimport { Progress } from 'antd';\n\nconst LoadingBarComponent = ({ progress }) => (\n <Progress\n type=\"line\"\n status=\"active\"\n percent={progress}\n showInfo={false}\n />\n);\n*/\n\n/* number between 0 and 1 */\nconst random = (): number => Math.ceil(Math.random() * 100) / 100;\n\n/**\n * around:\n * at 100ms 20%\n * at 1s 40%\n * at 2s 60%\n * at 3s 80%\n */\nconst calculatePercent = (percent: number): number => {\n if (percent < 60) return percent + random() * 10 + 5;\n if (percent < 70) return percent + random() * 10 + 3;\n else if (percent < 80) return percent + random() + 5;\n else if (percent < 90) return percent + random() + 1;\n else if (percent < 95) return percent + 0.1;\n else return percent;\n};\n\ninterface LoadingBarProps {\n LoadingBarComponent: React.ComponentType<{ progress: number }>;\n websocket: WebsocketInterface;\n}\n\ninterface LoadingBarState {\n loading: boolean;\n hidden: boolean;\n progress: number;\n}\n\ninterface WebsocketInterface {\n isConnected: () => boolean;\n on: (event: \"connect\" | \"disconnect\", callback: () => unknown) => void;\n}\n\nexport default class LoadingBar extends PureComponent<\n LoadingBarProps,\n LoadingBarState\n> {\n override state = {\n loading: true,\n hidden: true,\n progress: 1,\n };\n\n fadeOffTimeout?: ReturnType<typeof setTimeout>;\n\n resetTimeout?: ReturnType<typeof setTimeout>;\n\n first20Timeout?: ReturnType<typeof setTimeout>;\n\n progressTimer?: ReturnType<typeof setTimeout>;\n\n override componentDidMount(): void {\n if (this.props.websocket.isConnected()) {\n this.setState((prevState) => ({\n loading: false,\n progress: 100,\n hidden: prevState.hidden || prevState.progress === 100,\n }));\n }\n this.props.websocket.on(\"connect\", () => {\n this.setState({ loading: false });\n });\n this.props.websocket.on(\"disconnect\", () => {\n this.setState({ loading: true, progress: 1, hidden: false });\n });\n }\n\n override componentDidUpdate(\n prevProps: LoadingBarProps,\n prevState: LoadingBarState,\n ): void {\n if (this.props.websocket !== prevProps.websocket) {\n throw new Error(\"Unsupported at the moment\");\n }\n if (this.state.loading !== prevState.loading) {\n if (this.state.loading) {\n this.showBar();\n } else {\n this.hideBar();\n }\n }\n }\n\n override componentWillUnmount(): void {\n if (this.fadeOffTimeout) clearTimeout(this.fadeOffTimeout);\n if (this.resetTimeout) clearTimeout(this.resetTimeout);\n if (this.first20Timeout) clearTimeout(this.first20Timeout);\n if (this.progressTimer) clearInterval(this.progressTimer);\n }\n\n private showBar(): void {\n if (this.fadeOffTimeout) clearTimeout(this.fadeOffTimeout);\n if (this.resetTimeout) clearTimeout(this.resetTimeout);\n\n this.first20Timeout = setTimeout(() => {\n this.setState({ progress: 20 });\n }, 100);\n\n this.progressTimer = setInterval(() => {\n this.setState((prevState) => {\n const newValue = calculatePercent(prevState.progress);\n return { progress: newValue };\n });\n }, 500);\n }\n\n private hideBar(): void {\n if (this.first20Timeout) clearTimeout(this.first20Timeout);\n if (this.progressTimer) clearInterval(this.progressTimer);\n\n this.fadeOffTimeout = setTimeout(() => {\n this.setState({\n progress: 100,\n });\n }, 500);\n\n this.resetTimeout = setTimeout(() => {\n this.setState({\n hidden: true,\n progress: 1,\n });\n }, 1000);\n }\n\n override render(): ReactElement {\n const LoadingBarComponent = this.props.LoadingBarComponent;\n\n return (\n <div\n hidden={this.state.hidden}\n style={{\n position: \"fixed\",\n top: 0,\n left: 0,\n right: 0,\n zIndex: 4,\n pointerEvents: \"none\",\n }}\n >\n <LoadingBarComponent progress={this.state.progress} />\n </div>\n );\n }\n}\n"],"names":[],"mappings":";;;AAmBA,MAAM,MAAA,GAAS,MAAc,IAAA,CAAK,IAAA,CAAK,KAAK,MAAA,EAAO,GAAI,GAAG,CAAA,GAAI,GAAA;AAS9D,MAAM,gBAAA,GAAmB,CAAC,OAAA,KAA4B;AACpD,EAAA,IAAI,UAAU,EAAA,EAAI,OAAO,OAAA,GAAU,MAAA,KAAW,EAAA,GAAK,CAAA;AACnD,EAAA,IAAI,UAAU,EAAA,EAAI,OAAO,OAAA,GAAU,MAAA,KAAW,EAAA,GAAK,CAAA;AAAA,OAAA,IAC1C,OAAA,GAAU,EAAA,EAAI,OAAO,OAAA,GAAU,QAAO,GAAI,CAAA;AAAA,OAAA,IAC1C,OAAA,GAAU,EAAA,EAAI,OAAO,OAAA,GAAU,QAAO,GAAI,CAAA;AAAA,OAAA,IAC1C,OAAA,GAAU,EAAA,EAAI,OAAO,OAAA,GAAU,GAAA;AAAA,OACnC,OAAO,OAAA;AACd,CAAA;AAkBA,MAAqB,mBAAmB,aAAA,CAGtC;AAAA,EAHF,WAAA,GAAA;AAAA,IAAA,KAAA,CAAA,GAAA,SAAA,CAAA;AAIE,IAAA,IAAA,CAAS,KAAA,GAAQ;AAAA,MACf,OAAA,EAAS,IAAA;AAAA,MACT,MAAA,EAAQ,IAAA;AAAA,MACR,QAAA,EAAU;AAAA,KACZ;AAAA,EAAA;AAAA,EAUS,iBAAA,GAA0B;AACjC,IAAA,IAAI,IAAA,CAAK,KAAA,CAAM,SAA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AAS;AAAA,QACZ,MAAA,EAAQ,IAAA;AAAA,QACR,QAAA,EAAU;AAAA,OACX,CAAA;AAAA,IACH,GAAG,GAAI,CAAA;AAAA,EACT;AAAA,EAES,MAAA,GAAuB;AAC9B,IAAA,MAAM,mBAAA,GAAsB,KAAK,KAAA,CAAM,mBAAA;AAEvC,IAAA,uBACE,GAAA;AAAA,MAAC,KAAA;AAAA,MAAA;AAAA,QACC,MAAA,EAAQ,KAAK,KAAA,CAAM,MAAA;AAAA,QACnB,KAAA,EAAO;AAAA,UACL,QAAA,EAAU,OAAA;AAAA,UACV,GAAA,EAAK,CAAA;AAAA,UACL,IAAA,EAAM,CAAA;AAAA,UACN,KAAA,EAAO,CAAA;AAAA,UACP,MAAA,EAAQ,CAAA;AAAA,UACR,aAAA,EAAe;AAAA,SACjB;AAAA,QAEA,QAAA,kBAAA,GAAA,CAAC,mBAAA,EAAA,EAAoB,QAAA,EAAU,IAAA,CAAK,MAAM,QAAA,EAAU;AAAA;AAAA,KACtD;AAAA,EAEJ;AACF;;;;"}
1
+ {"version":3,"file":"index-browser.es.js","sources":["../src/index.tsx"],"sourcesContent":["/* eslint-disable react/destructuring-assignment */\nimport type { ComponentType, ReactElement } from \"react\";\nimport { PureComponent } from \"react\";\n\n/*\nExample with antd:\nimport { Progress } from 'antd';\n\nconst LoadingBarComponent = ({ progress }) => (\n <Progress\n type=\"line\"\n status=\"active\"\n percent={progress}\n showInfo={false}\n />\n);\n*/\n\n/* number between 0 and 1 */\nconst random = (): number => Math.ceil(Math.random() * 100) / 100;\n\n/**\n * around:\n * at 100ms 20%\n * at 1s 40%\n * at 2s 60%\n * at 3s 80%\n */\nconst calculatePercent = (percent: number): number => {\n if (percent < 60) return percent + random() * 10 + 5;\n if (percent < 70) return percent + random() * 10 + 3;\n else if (percent < 80) return percent + random() + 5;\n else if (percent < 90) return percent + random() + 1;\n else if (percent < 95) return percent + 0.1;\n else return percent;\n};\n\ninterface LoadingBarProps {\n LoadingBarComponent: ComponentType<{ progress: number }>;\n websocket: WebsocketInterface;\n}\n\ninterface LoadingBarState {\n loading: boolean;\n hidden: boolean;\n progress: number;\n}\n\ninterface WebsocketInterface {\n isConnected: () => boolean;\n on: (event: \"connect\" | \"disconnect\", callback: () => unknown) => void;\n}\n\nexport default class LoadingBar extends PureComponent<\n LoadingBarProps,\n LoadingBarState\n> {\n override state = {\n loading: true,\n hidden: true,\n progress: 1,\n };\n\n fadeOffTimeout?: ReturnType<typeof setTimeout>;\n\n resetTimeout?: ReturnType<typeof setTimeout>;\n\n first20Timeout?: ReturnType<typeof setTimeout>;\n\n progressTimer?: ReturnType<typeof setTimeout>;\n\n override componentDidMount(): void {\n if (this.props.websocket.isConnected()) {\n this.setState((prevState) => ({\n loading: false,\n progress: 100,\n hidden: prevState.hidden || prevState.progress === 100,\n }));\n }\n this.props.websocket.on(\"connect\", () => {\n this.setState({ loading: false });\n });\n this.props.websocket.on(\"disconnect\", () => {\n this.setState({ loading: true, progress: 1, hidden: false });\n });\n }\n\n override componentDidUpdate(\n prevProps: LoadingBarProps,\n prevState: LoadingBarState,\n ): void {\n if (this.props.websocket !== prevProps.websocket) {\n throw new Error(\"Unsupported at the moment\");\n }\n if (this.state.loading !== prevState.loading) {\n if (this.state.loading) {\n this.showBar();\n } else {\n this.hideBar();\n }\n }\n }\n\n override componentWillUnmount(): void {\n if (this.fadeOffTimeout) clearTimeout(this.fadeOffTimeout);\n if (this.resetTimeout) clearTimeout(this.resetTimeout);\n if (this.first20Timeout) clearTimeout(this.first20Timeout);\n if (this.progressTimer) clearInterval(this.progressTimer);\n }\n\n private showBar(): void {\n if (this.fadeOffTimeout) clearTimeout(this.fadeOffTimeout);\n if (this.resetTimeout) clearTimeout(this.resetTimeout);\n\n this.first20Timeout = setTimeout(() => {\n this.setState({ progress: 20 });\n }, 100);\n\n this.progressTimer = setInterval(() => {\n this.setState((prevState) => {\n const newValue = calculatePercent(prevState.progress);\n return { progress: newValue };\n });\n }, 500);\n }\n\n private hideBar(): void {\n if (this.first20Timeout) clearTimeout(this.first20Timeout);\n if (this.progressTimer) clearInterval(this.progressTimer);\n\n this.fadeOffTimeout = setTimeout(() => {\n this.setState({\n progress: 100,\n });\n }, 500);\n\n this.resetTimeout = setTimeout(() => {\n this.setState({\n hidden: true,\n progress: 1,\n });\n }, 1000);\n }\n\n override render(): ReactElement {\n const LoadingBarComponent = this.props.LoadingBarComponent;\n\n return (\n <div\n hidden={this.state.hidden}\n style={{\n position: \"fixed\",\n top: 0,\n left: 0,\n right: 0,\n zIndex: 4,\n pointerEvents: \"none\",\n }}\n >\n <LoadingBarComponent progress={this.state.progress} />\n </div>\n );\n }\n}\n"],"names":[],"mappings":";;;AAmBA,MAAM,MAAA,GAAS,MAAc,IAAA,CAAK,IAAA,CAAK,KAAK,MAAA,EAAO,GAAI,GAAG,CAAA,GAAI,GAAA;AAS9D,MAAM,gBAAA,GAAmB,CAAC,OAAA,KAA4B;AACpD,EAAA,IAAI,UAAU,EAAA,EAAI,OAAO,OAAA,GAAU,MAAA,KAAW,EAAA,GAAK,CAAA;AACnD,EAAA,IAAI,UAAU,EAAA,EAAI,OAAO,OAAA,GAAU,MAAA,KAAW,EAAA,GAAK,CAAA;AAAA,OAAA,IAC1C,OAAA,GAAU,EAAA,EAAI,OAAO,OAAA,GAAU,QAAO,GAAI,CAAA;AAAA,OAAA,IAC1C,OAAA,GAAU,EAAA,EAAI,OAAO,OAAA,GAAU,QAAO,GAAI,CAAA;AAAA,OAAA,IAC1C,OAAA,GAAU,EAAA,EAAI,OAAO,OAAA,GAAU,GAAA;AAAA,OACnC,OAAO,OAAA;AACd,CAAA;AAkBA,MAAqB,mBAAmB,aAAA,CAGtC;AAAA,EACS,KAAA,GAAQ;AAAA,IACf,OAAA,EAAS,IAAA;AAAA,IACT,MAAA,EAAQ,IAAA;AAAA,IACR,QAAA,EAAU;AAAA,GACZ;AAAA,EAEA,cAAA;AAAA,EAEA,YAAA;AAAA,EAEA,cAAA;AAAA,EAEA,aAAA;A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A,IAAA,CAAK,YAAA,GAAe,WAAW,MAAM;AACnC,MAAA,IAAA,CAAK,QAAA,CAAS;AAAA,QACZ,MAAA,EAAQ,IAAA;AAAA,QACR,QAAA,EAAU;AAAA,OACX,CAAA;AAAA,IACH,GAAG,GAAI,CAAA;AAAA,EACT;AAAA,EAES,MAAA,GAAuB;AAC9B,IAAA,MAAM,mBAAA,GAAsB,KAAK,KAAA,CAAM,mBAAA;AAEvC,IAAA,uBACE,GAAA;AAAA,MAAC,KAAA;AAAA,MAAA;AAAA,QACC,MAAA,EAAQ,KAAK,KAAA,CAAM,MAAA;AAAA,QACnB,KAAA,EAAO;AAAA,UACL,QAAA,EAAU,OAAA;AAAA,UACV,GAAA,EAAK,CAAA;AAAA,UACL,IAAA,EAAM,CAAA;AAAA,UACN,KAAA,EAAO,CAAA;AAAA,UACP,MAAA,EAAQ,CAAA;AAAA,UACR,aAAA,EAAe;AAAA,SACjB;AAAA,QAEA,QAAA,kBAAA,GAAA,CAAC,mBAAA,EAAA,EAAoB,QAAA,EAAU,IAAA,CAAK,MAAM,QAAA,EAAU;AAAA;AAAA,KACtD;AAAA,EAEJ;AACF;;;;"}
@@ -11,14 +11,15 @@ const calculatePercent = (percent) => {
11
11
  else return percent;
12
12
  };
13
13
  class LoadingBar extends PureComponent {
14
- constructor() {
15
- super(...arguments);
16
- this.state = {
17
- loading: true,
18
- hidden: true,
19
- progress: 1
20
- };
21
- }
14
+ state = {
15
+ loading: true,
16
+ hidden: true,
17
+ progress: 1
18
+ };
19
+ fadeOffTimeout;
20
+ resetTimeout;
21
+ first20Timeout;
22
+ progressTimer;
22
23
  componentDidMount() {
23
24
  if (this.props.websocket.isConnected()) {
24
25
  this.setState((prevState) => ({
@@ -1 +1 @@
1
- {"version":3,"file":"index-node22.mjs","sources":["../src/index.tsx"],"sourcesContent":["/* eslint-disable react/destructuring-assignment */\nimport type { ReactElement } from \"react\";\nimport { PureComponent } from \"react\";\n\n/*\nExample with antd:\nimport { Progress } from 'antd';\n\nconst LoadingBarComponent = ({ progress }) => (\n <Progress\n type=\"line\"\n status=\"active\"\n percent={progress}\n showInfo={false}\n />\n);\n*/\n\n/* number between 0 and 1 */\nconst random = (): number => Math.ceil(Math.random() * 100) / 100;\n\n/**\n * around:\n * at 100ms 20%\n * at 1s 40%\n * at 2s 60%\n * at 3s 80%\n */\nconst calculatePercent = (percent: number): number => {\n if (percent < 60) return percent + random() * 10 + 5;\n if (percent < 70) return percent + random() * 10 + 3;\n else if (percent < 80) return percent + random() + 5;\n else if (percent < 90) return percent + random() + 1;\n else if (percent < 95) return percent + 0.1;\n else return percent;\n};\n\ninterface LoadingBarProps {\n LoadingBarComponent: React.ComponentType<{ progress: number }>;\n websocket: WebsocketInterface;\n}\n\ninterface LoadingBarState {\n loading: boolean;\n hidden: boolean;\n progress: number;\n}\n\ninterface WebsocketInterface {\n isConnected: () => boolean;\n on: (event: \"connect\" | \"disconnect\", callback: () => unknown) => void;\n}\n\nexport default class LoadingBar extends PureComponent<\n LoadingBarProps,\n LoadingBarState\n> {\n override state = {\n loading: true,\n hidden: true,\n progress: 1,\n };\n\n fadeOffTimeout?: ReturnType<typeof setTimeout>;\n\n resetTimeout?: ReturnType<typeof setTimeout>;\n\n first20Timeout?: ReturnType<typeof setTimeout>;\n\n progressTimer?: ReturnType<typeof setTimeout>;\n\n override componentDidMount(): void {\n if (this.props.websocket.isConnected()) {\n this.setState((prevState) => ({\n loading: false,\n progress: 100,\n hidden: prevState.hidden || prevState.progress === 100,\n }));\n }\n this.props.websocket.on(\"connect\", () => {\n this.setState({ loading: false });\n });\n this.props.websocket.on(\"disconnect\", () => {\n this.setState({ loading: true, progress: 1, hidden: false });\n });\n }\n\n override componentDidUpdate(\n prevProps: LoadingBarProps,\n prevState: LoadingBarState,\n ): void {\n if (this.props.websocket !== prevProps.websocket) {\n throw new Error(\"Unsupported at the moment\");\n }\n if (this.state.loading !== prevState.loading) {\n if (this.state.loading) {\n this.showBar();\n } else {\n this.hideBar();\n }\n }\n }\n\n override componentWillUnmount(): void {\n if (this.fadeOffTimeout) clearTimeout(this.fadeOffTimeout);\n if (this.resetTimeout) clearTimeout(this.resetTimeout);\n if (this.first20Timeout) clearTimeout(this.first20Timeout);\n if (this.progressTimer) clearInterval(this.progressTimer);\n }\n\n private showBar(): void {\n if (this.fadeOffTimeout) clearTimeout(this.fadeOffTimeout);\n if (this.resetTimeout) clearTimeout(this.resetTimeout);\n\n this.first20Timeout = setTimeout(() => {\n this.setState({ progress: 20 });\n }, 100);\n\n this.progressTimer = setInterval(() => {\n this.setState((prevState) => {\n const newValue = calculatePercent(prevState.progress);\n return { progress: newValue };\n });\n }, 500);\n }\n\n private hideBar(): void {\n if (this.first20Timeout) clearTimeout(this.first20Timeout);\n if (this.progressTimer) clearInterval(this.progressTimer);\n\n this.fadeOffTimeout = setTimeout(() => {\n this.setState({\n progress: 100,\n });\n }, 500);\n\n this.resetTimeout = setTimeout(() => {\n this.setState({\n hidden: true,\n progress: 1,\n });\n }, 1000);\n }\n\n override render(): ReactElement {\n const LoadingBarComponent = this.props.LoadingBarComponent;\n\n return (\n <div\n hidden={this.state.hidden}\n style={{\n position: \"fixed\",\n top: 0,\n left: 0,\n right: 0,\n zIndex: 4,\n pointerEvents: \"none\",\n }}\n >\n <LoadingBarComponent progress={this.state.progress} />\n </div>\n );\n }\n}\n"],"names":[],"mappings":";;;AAmBA,MAAM,MAAA,GAAS,MAAc,IAAA,CAAK,IAAA,CAAK,KAAK,MAAA,EAAO,GAAI,GAAG,CAAA,GAAI,GAAA;AAS9D,MAAM,gBAAA,GAAmB,CAAC,OAAA,KAA4B;AACpD,EAAA,IAAI,UAAU,EAAA,EAAI,OAAO,OAAA,GAAU,MAAA,KAAW,EAAA,GAAK,CAAA;AACnD,EAAA,IAAI,UAAU,EAAA,EAAI,OAAO,OAAA,GAAU,MAAA,KAAW,EAAA,GAAK,CAAA;AAAA,OAAA,IAC1C,OAAA,GAAU,EAAA,EAAI,OAAO,OAAA,GAAU,QAA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ructuring-assignment */\nimport type { ComponentType, ReactElement } from \"react\";\nimport { PureComponent } from \"react\";\n\n/*\nExample with antd:\nimport { Progress } from 'antd';\n\nconst LoadingBarComponent = ({ progress }) => (\n <Progress\n type=\"line\"\n status=\"active\"\n percent={progress}\n showInfo={false}\n />\n);\n*/\n\n/* number between 0 and 1 */\nconst random = (): number => Math.ceil(Math.random() * 100) / 100;\n\n/**\n * around:\n * at 100ms 20%\n * at 1s 40%\n * at 2s 60%\n * at 3s 80%\n */\nconst calculatePercent = (percent: number): number => {\n if (percent < 60) return percent + random() * 10 + 5;\n if (percent < 70) return percent + random() * 10 + 3;\n else if (percent < 80) return percent + random() + 5;\n else if (percent < 90) return percent + random() + 1;\n else if (percent < 95) return percent + 0.1;\n else return percent;\n};\n\ninterface LoadingBarProps {\n LoadingBarComponent: ComponentType<{ progress: number }>;\n websocket: WebsocketInterface;\n}\n\ninterface LoadingBarState {\n loading: boolean;\n hidden: boolean;\n progress: number;\n}\n\ninterface WebsocketInterface {\n isConnected: () => boolean;\n on: (event: \"connect\" | \"disconnect\", callback: () => unknown) => void;\n}\n\nexport default class LoadingBar extends PureComponent<\n LoadingBarProps,\n LoadingBarState\n> {\n override state = {\n loading: true,\n hidden: true,\n progress: 1,\n };\n\n fadeOffTimeout?: ReturnType<typeof setTimeout>;\n\n resetTimeout?: ReturnType<typeof setTimeout>;\n\n first20Timeout?: ReturnType<typeof setTimeout>;\n\n progressTimer?: ReturnType<typeof setTimeout>;\n\n override componentDidMount(): void {\n if (this.props.websocket.isConnected()) {\n this.setState((prevState) => ({\n loading: false,\n progress: 100,\n hidden: prevState.hidden || prevState.progress === 100,\n }));\n }\n this.props.websocket.on(\"connect\", () => {\n this.setState({ loading: false });\n });\n this.props.websocket.on(\"disconnect\", () => {\n this.setState({ loading: true, progress: 1, hidden: false });\n });\n }\n\n override componentDidUpdate(\n prevProps: LoadingBarProps,\n prevState: LoadingBarState,\n ): void {\n if (this.props.websocket !== prevProps.websocket) {\n throw new Error(\"Unsupported at the moment\");\n }\n if (this.state.loading !== prevState.loading) {\n if (this.state.loading) {\n this.showBar();\n } else {\n this.hideBar();\n }\n }\n }\n\n override componentWillUnmount(): void {\n if (this.fadeOffTimeout) clearTimeout(this.fadeOffTimeout);\n if (this.resetTimeout) clearTimeout(this.resetTimeout);\n if (this.first20Timeout) clearTimeout(this.first20Timeout);\n if (this.progressTimer) clearInterval(this.progressTimer);\n }\n\n private showBar(): void {\n if (this.fadeOffTimeout) clearTimeout(this.fadeOffTimeout);\n if (this.resetTimeout) clearTimeout(this.resetTimeout);\n\n this.first20Timeout = setTimeout(() => {\n this.setState({ progress: 20 });\n }, 100);\n\n this.progressTimer = setInterval(() => {\n this.setState((prevState) => {\n const newValue = calculatePercent(prevState.progress);\n return { progress: newValue };\n });\n }, 500);\n }\n\n private hideBar(): void {\n if (this.first20Timeout) clearTimeout(this.first20Timeout);\n if (this.progressTimer) clearInterval(this.progressTimer);\n\n this.fadeOffTimeout = setTimeout(() => {\n this.setState({\n progress: 100,\n });\n }, 500);\n\n this.resetTimeout = setTimeout(() => {\n this.setState({\n hidden: true,\n progress: 1,\n });\n }, 1000);\n }\n\n override render(): ReactElement {\n const LoadingBarComponent = this.props.LoadingBarComponent;\n\n return (\n <div\n hidden={this.state.hidden}\n style={{\n position: \"fixed\",\n top: 0,\n left: 0,\n right: 0,\n zIndex: 4,\n pointerEvents: \"none\",\n }}\n >\n <LoadingBarComponent progress={this.state.progress} />\n </div>\n );\n }\n}\n"],"names":[],"mappings":";;;AAmBA,MAAM,MAAA,GAAS,MAAc,IAAA,CAAK,IAAA,CAAK,KAAK,MAAA,EAAO,GAAI,GAAG,CAAA,GAAI,GAAA;AAS9D,MAAM,gBAAA,GAAmB,CAAC,OAAA,KAA4B;AACpD,EAAA,IAAI,UAAU,EAAA,EAAI,OAAO,OAAA,GAAU,MAAA,KAAW,EAAA,GAAK,CAAA;AACnD,EAAA,IAAI,UAAU,EAAA,EAAI,OAAO,OAAA,GAAU,MAAA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
package/package.json CHANGED
@@ -1,25 +1,29 @@
1
1
  {
2
2
  "name": "react-alp-loading-bar",
3
- "version": "9.0.2",
3
+ "version": "9.0.3",
4
4
  "description": "loading bar",
5
5
  "keywords": [],
6
- "author": "Christophe Hurpeau <christophe@hurpeau.com> (https://christophe.hurpeau.com)",
6
+ "homepage": "https://github.com/christophehurpeau/alp",
7
+ "bugs": {
8
+ "url": "https://github.com/christophehurpeau/alp/issues"
9
+ },
7
10
  "license": "ISC",
11
+ "author": "Christophe Hurpeau <christophe@hurpeau.com> (https://christophe.hurpeau.com)",
8
12
  "repository": {
9
13
  "type": "git",
10
14
  "url": "https://github.com/christophehurpeau/alp.git",
11
15
  "directory": "packages/react-alp-loading-bar"
12
16
  },
13
- "homepage": "https://github.com/christophehurpeau/alp",
17
+ "files": [
18
+ "src",
19
+ "dist"
20
+ ],
14
21
  "type": "module",
15
- "engines": {
16
- "node": ">=22.18.0"
17
- },
18
22
  "sideEffects": false,
19
23
  "main": "./dist/index-node22.mjs",
20
- "types": "./dist/definitions/index.d.ts",
21
24
  "module": "./dist/index-browser.es.js",
22
25
  "browser": "./dist/index-browser.es.js",
26
+ "types": "./dist/definitions/index.d.ts",
23
27
  "exports": {
24
28
  "./package.json": "./package.json",
25
29
  ".": {
@@ -32,18 +36,13 @@
32
36
  }
33
37
  }
34
38
  },
35
- "files": [
36
- "src",
37
- "dist"
38
- ],
39
- "scripts": {
40
- "build": "yarn clean:build && rollup --config rollup.config.mjs && yarn run build:definitions",
41
- "build:definitions": "tsc -p tsconfig.json",
42
- "clean": "yarn clean:build",
43
- "clean:build": "pob-esbuild-clean-out dist",
44
- "lint": "yarn run lint:eslint",
45
- "lint:eslint": "yarn ../.. run eslint --quiet packages/react-alp-loading-bar",
46
- "watch": "yarn clean:build && rollup --config rollup.config.mjs --watch"
39
+ "devDependencies": {
40
+ "@pob/rollup-esbuild": "9.1.1",
41
+ "react": "19.1.1",
42
+ "typescript": "6.0.3"
43
+ },
44
+ "peerDependencies": {
45
+ "react": "^19.0.0"
47
46
  },
48
47
  "browserslist": {
49
48
  "production": [
@@ -54,6 +53,9 @@
54
53
  "not ios_saf < 10"
55
54
  ]
56
55
  },
56
+ "engines": {
57
+ "node": ">=22.18.0"
58
+ },
57
59
  "pob": {
58
60
  "bundler": "rollup-esbuild",
59
61
  "entries": [
@@ -71,13 +73,14 @@
71
73
  "jsx": true,
72
74
  "typescript": true
73
75
  },
74
- "prettier": "@pob/root/prettier-config",
75
- "peerDependencies": {
76
- "react": "^19.0.0"
77
- },
78
- "devDependencies": {
79
- "@pob/rollup-esbuild": "7.3.2",
80
- "react": "19.1.1",
81
- "typescript": "5.9.3"
76
+ "scripts": {
77
+ "build": "yarn run clean:build && rollup --config rollup.config.mjs && yarn run build:definitions",
78
+ "build:definitions": "tsc -p tsconfig.json",
79
+ "clean": "yarn clean:build",
80
+ "clean:build": "pob-esbuild-clean-out dist",
81
+ "lint": "yarn run lint:eslint",
82
+ "lint:eslint": "yarn '../..' run eslint --quiet 'packages/react-alp-loading-bar'",
83
+ "tsc": "tsc",
84
+ "watch": "yarn clean:build && rollup --config rollup.config.mjs --watch"
82
85
  }
83
86
  }
package/src/index.tsx CHANGED
@@ -1,5 +1,5 @@
1
1
  /* eslint-disable react/destructuring-assignment */
2
- import type { ReactElement } from "react";
2
+ import type { ComponentType, ReactElement } from "react";
3
3
  import { PureComponent } from "react";
4
4
 
5
5
  /*
@@ -36,7 +36,7 @@ const calculatePercent = (percent: number): number => {
36
36
  };
37
37
 
38
38
  interface LoadingBarProps {
39
- LoadingBarComponent: React.ComponentType<{ progress: number }>;
39
+ LoadingBarComponent: ComponentType<{ progress: number }>;
40
40
  websocket: WebsocketInterface;
41
41
  }
42
42
 
package/CHANGELOG.md DELETED
@@ -1,455 +0,0 @@
1
- # Changelog
2
-
3
- All notable changes to this project will be documented in this file.
4
- See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
-
6
- ## [9.0.2](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@9.0.1...react-alp-loading-bar@9.0.2) (2025-11-12)
7
-
8
- Note: no notable changes
9
-
10
-
11
- ## [9.0.1](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@9.0.0...react-alp-loading-bar@9.0.1) (2025-11-12)
12
-
13
- Note: no notable changes
14
-
15
-
16
- ## [9.0.0](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@8.0.0...react-alp-loading-bar@9.0.0) (2025-10-27)
17
-
18
- ### ⚠ BREAKING CHANGES
19
-
20
- * drop node 20 and build using esbuild
21
-
22
- ### Features
23
-
24
- * drop node 20 and build using esbuild ([812c4c1](https://github.com/christophehurpeau/alp/commit/812c4c1b0ad19984e389af4382a8d1e60643e4f1))
25
-
26
- ## [8.0.0](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@7.0.0...react-alp-loading-bar@8.0.0) (2025-08-02)
27
-
28
- ### ⚠ BREAKING CHANGES
29
-
30
- * update dependencies and drop node 20
31
- * update dev dependencies, replace parse-json-object-as-map with native JSON.parse, update koa
32
-
33
- ### Features
34
-
35
- * update babel ([a4bf455](https://github.com/christophehurpeau/alp/commit/a4bf455c715134973c56693b7425aa05de5b10f9))
36
- * update dependencies and drop node 20 ([fc5b322](https://github.com/christophehurpeau/alp/commit/fc5b322e076e9a3c7c4a235d16734b89fd85e211))
37
- * update dev dependencies, replace parse-json-object-as-map with native JSON.parse, update koa ([5ae7723](https://github.com/christophehurpeau/alp/commit/5ae77238cafc573fe72c5eb63b103802b8b2e537))
38
-
39
- ### Bug Fixes
40
-
41
- * **deps:** update react monorepo ([#611](https://github.com/christophehurpeau/alp/issues/611)) ([b9ece4d](https://github.com/christophehurpeau/alp/commit/b9ece4dc070bcd49fa6c4a40534162d10087405b))
42
-
43
- ## [7.0.0](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@6.1.1...react-alp-loading-bar@7.0.0) (2024-01-06)
44
-
45
-
46
- ### ⚠ BREAKING CHANGES
47
-
48
- * merge to alp-node to improve maintenability, remove alp-types
49
-
50
- ### Features
51
-
52
- * merge to alp-node to improve maintenability, remove alp-types ([ead9a2f](https://github.com/christophehurpeau/alp/commit/ead9a2fd1bcbedce0be29ea0e444c5cead99c64d))
53
-
54
-
55
-
56
-
57
- ## [6.1.1](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@6.1.0...react-alp-loading-bar@6.1.1) (2024-01-06)
58
-
59
- Note: no notable changes
60
-
61
- Version bump for dependency: react-alp-context
62
-
63
-
64
- ## [6.1.0](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@6.0.0...react-alp-loading-bar@6.1.0) (2023-12-25)
65
-
66
-
67
- ### Features
68
-
69
- * update dependencies ([ddc8f92](https://github.com/christophehurpeau/alp/commit/ddc8f92cccacf6ed2baabf8555f0b37fe281ce9d))
70
-
71
- Version bump for dependency: alp-types
72
- Version bump for dependency: react-alp-context
73
-
74
-
75
- ## [6.0.0](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@5.2.0...react-alp-loading-bar@6.0.0) (2023-07-29)
76
-
77
-
78
- ### ⚠ BREAKING CHANGES
79
-
80
- * drop node 16
81
-
82
- ### Code Refactoring
83
-
84
- * update to node 18 ([26280d6](https://github.com/christophehurpeau/alp/commit/26280d638aba1bd46fa42ad5a571b9626f1fff6d))
85
-
86
-
87
-
88
- ## [5.2.0](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@5.1.2...react-alp-loading-bar@5.2.0) (2023-03-19)
89
-
90
-
91
- ### Features
92
-
93
- * update dev dependencies ([9d7e24f](https://github.com/christophehurpeau/alp/commit/9d7e24f8e504d47feae64ca618dc2b3a69babc38))
94
-
95
-
96
-
97
- ## [5.1.2](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@5.1.1...react-alp-loading-bar@5.1.2) (2023-01-31)
98
-
99
- **Note:** Version bump only for package react-alp-loading-bar
100
-
101
-
102
-
103
-
104
-
105
- ## [5.1.1](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@5.1.0...react-alp-loading-bar@5.1.1) (2023-01-31)
106
-
107
- **Note:** Version bump only for package react-alp-loading-bar
108
-
109
-
110
-
111
-
112
-
113
- # [5.1.0](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@5.0.0...react-alp-loading-bar@5.1.0) (2023-01-29)
114
-
115
-
116
- ### Features
117
-
118
- * update configs ([e9cbde7](https://github.com/christophehurpeau/alp/commit/e9cbde74ddbbb730bc2b65bb6d0b87f2bba8006e))
119
-
120
-
121
-
122
-
123
-
124
- # [5.0.0](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@4.1.2...react-alp-loading-bar@5.0.0) (2022-11-27)
125
-
126
-
127
- ### Features
128
-
129
- * drop node 14 ([5d5f90b](https://github.com/christophehurpeau/alp/commit/5d5f90b09d8532278aba75a97f10ea90bbb27919))
130
-
131
-
132
- ### BREAKING CHANGES
133
-
134
- * drop node 14
135
-
136
-
137
-
138
-
139
-
140
- ## [4.1.2](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@4.1.1...react-alp-loading-bar@4.1.2) (2022-10-29)
141
-
142
- **Note:** Version bump only for package react-alp-loading-bar
143
-
144
-
145
-
146
-
147
-
148
- ## [4.1.1](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@4.1.0...react-alp-loading-bar@4.1.1) (2022-10-19)
149
-
150
- **Note:** Version bump only for package react-alp-loading-bar
151
-
152
-
153
-
154
-
155
-
156
- # [4.1.0](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@4.0.6...react-alp-loading-bar@4.1.0) (2022-10-16)
157
-
158
-
159
- ### Features
160
-
161
- * update to react 18 ([6ac42b8](https://github.com/christophehurpeau/alp/commit/6ac42b84b80bf76853773f3b93819666684327d1))
162
-
163
-
164
-
165
-
166
-
167
- ## [4.0.6](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@4.0.5...react-alp-loading-bar@4.0.6) (2022-10-13)
168
-
169
- **Note:** Version bump only for package react-alp-loading-bar
170
-
171
-
172
-
173
-
174
-
175
- ## [4.0.5](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@4.0.4...react-alp-loading-bar@4.0.5) (2022-03-05)
176
-
177
- **Note:** Version bump only for package react-alp-loading-bar
178
-
179
-
180
-
181
-
182
-
183
- ## [4.0.4](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@4.0.3...react-alp-loading-bar@4.0.4) (2022-02-20)
184
-
185
- **Note:** Version bump only for package react-alp-loading-bar
186
-
187
-
188
-
189
-
190
-
191
- ## [4.0.3](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@4.0.2...react-alp-loading-bar@4.0.3) (2022-02-13)
192
-
193
-
194
- ### Bug Fixes
195
-
196
- * dont override react/react-in-jsx-scope ([5d21c9e](https://github.com/christophehurpeau/alp/commit/5d21c9ece092cd3397d1794211dae17cea6649f8))
197
-
198
-
199
-
200
-
201
-
202
- ## [4.0.2](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@4.0.1...react-alp-loading-bar@4.0.2) (2022-02-06)
203
-
204
- **Note:** Version bump only for package react-alp-loading-bar
205
-
206
-
207
-
208
-
209
-
210
- ## [4.0.1](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@4.0.0...react-alp-loading-bar@4.0.1) (2022-01-15)
211
-
212
- **Note:** Version bump only for package react-alp-loading-bar
213
-
214
-
215
-
216
-
217
-
218
- # [4.0.0](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@3.1.3...react-alp-loading-bar@4.0.0) (2022-01-02)
219
-
220
-
221
- ### Bug Fixes
222
-
223
- * update nightingale and fix tests ([3691716](https://github.com/christophehurpeau/alp/commit/36917162d0ee3dccc07384caf018b7760d98b744))
224
-
225
-
226
- ### Features
227
-
228
- * use ESM and drop node 12 ([f45054e](https://github.com/christophehurpeau/alp/commit/f45054e931eea88451d183722797eba057511236))
229
-
230
-
231
- ### BREAKING CHANGES
232
-
233
- * requires node 14 and ESM
234
-
235
-
236
-
237
-
238
-
239
- ## [3.1.3](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@3.1.2...react-alp-loading-bar@3.1.3) (2021-04-10)
240
-
241
- **Note:** Version bump only for package react-alp-loading-bar
242
-
243
-
244
-
245
-
246
-
247
- ## [3.1.2](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@3.1.1...react-alp-loading-bar@3.1.2) (2021-03-28)
248
-
249
- **Note:** Version bump only for package react-alp-loading-bar
250
-
251
-
252
-
253
-
254
-
255
- ## [3.1.1](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@3.1.0...react-alp-loading-bar@3.1.1) (2021-03-28)
256
-
257
- **Note:** Version bump only for package react-alp-loading-bar
258
-
259
-
260
-
261
-
262
-
263
- # [3.1.0](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@3.0.2...react-alp-loading-bar@3.1.0) (2021-03-21)
264
-
265
-
266
- ### Features
267
-
268
- * update dependencies and browserlist config ([ec17710](https://github.com/christophehurpeau/alp/commit/ec177106dbfb094fface3d2791800916929305fc))
269
-
270
-
271
-
272
-
273
-
274
- ## [3.0.2](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@3.0.1...react-alp-loading-bar@3.0.2) (2021-01-18)
275
-
276
-
277
- ### Bug Fixes
278
-
279
- * deps and export import browser ([c8e51a6](https://github.com/christophehurpeau/alp/commit/c8e51a61befee852cbdbfb7697c7fd273a8d49ef))
280
- * multiple stuff ([e914474](https://github.com/christophehurpeau/alp/commit/e9144747913b8edae7dc1ba94767d03e085cbdcd))
281
-
282
-
283
-
284
-
285
-
286
- ## [3.0.1](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@3.0.0...react-alp-loading-bar@3.0.1) (2021-01-17)
287
-
288
- **Note:** Version bump only for package react-alp-loading-bar
289
-
290
-
291
-
292
-
293
-
294
- # [3.0.0](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@2.1.3...react-alp-loading-bar@3.0.0) (2021-01-17)
295
-
296
-
297
- ### Code Refactoring
298
-
299
- * update dev deps and typescript and eslint ([8cdc20e](https://github.com/christophehurpeau/alp/commit/8cdc20e030769d98d637b9580931cc5cc608278d))
300
-
301
-
302
- ### BREAKING CHANGES
303
-
304
- * requires node 12
305
-
306
-
307
-
308
-
309
-
310
- ## [2.1.3](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@2.1.2...react-alp-loading-bar@2.1.3) (2021-01-12)
311
-
312
- **Note:** Version bump only for package react-alp-loading-bar
313
-
314
-
315
-
316
-
317
-
318
- ## [2.1.2](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@2.1.1...react-alp-loading-bar@2.1.2) (2020-08-09)
319
-
320
- **Note:** Version bump only for package react-alp-loading-bar
321
-
322
-
323
-
324
-
325
-
326
- ## [2.1.1](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@2.1.0...react-alp-loading-bar@2.1.1) (2020-08-08)
327
-
328
- **Note:** Version bump only for package react-alp-loading-bar
329
-
330
-
331
-
332
-
333
-
334
- # [2.1.0](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@2.0.3...react-alp-loading-bar@2.1.0) (2020-05-30)
335
-
336
-
337
- ### Features
338
-
339
- * update dependencies ([70b1f7f](https://github.com/christophehurpeau/alp/commit/70b1f7f))
340
-
341
-
342
-
343
-
344
-
345
- ## [2.0.3](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@2.0.2...react-alp-loading-bar@2.0.3) (2020-05-02)
346
-
347
- **Note:** Version bump only for package react-alp-loading-bar
348
-
349
-
350
-
351
-
352
-
353
- ## [2.0.2](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@2.0.1...react-alp-loading-bar@2.0.2) (2019-12-16)
354
-
355
-
356
- ### Bug Fixes
357
-
358
- * update pobpack ([6e0b501](https://github.com/christophehurpeau/alp/commit/6e0b501))
359
-
360
-
361
-
362
-
363
-
364
- ## [2.0.1](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@2.0.0...react-alp-loading-bar@2.0.1) (2019-12-15)
365
-
366
- **Note:** Version bump only for package react-alp-loading-bar
367
-
368
-
369
-
370
-
371
-
372
- # [2.0.0](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@1.3.1...react-alp-loading-bar@2.0.0) (2019-12-15)
373
-
374
-
375
- ### Features
376
-
377
- * update dependencies ([2d1539c](https://github.com/christophehurpeau/alp/commit/2d1539c))
378
- * update dependencies and pob ([edee8ce](https://github.com/christophehurpeau/alp/commit/edee8ce))
379
-
380
-
381
- ### BREAKING CHANGES
382
-
383
- * drop node 8
384
-
385
-
386
-
387
-
388
-
389
- ## [1.3.1](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@1.3.0...react-alp-loading-bar@1.3.1) (2019-09-15)
390
-
391
- **Note:** Version bump only for package react-alp-loading-bar
392
-
393
-
394
-
395
-
396
-
397
- # [1.3.0](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@1.2.2...react-alp-loading-bar@1.3.0) (2019-09-13)
398
-
399
-
400
- ### Features
401
-
402
- * add react-alp-antd-form and update dependencies ([6f60e46](https://github.com/christophehurpeau/alp/commit/6f60e46))
403
-
404
-
405
-
406
-
407
-
408
- ## [1.2.2](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@1.2.1...react-alp-loading-bar@1.2.2) (2019-09-09)
409
-
410
-
411
- ### Bug Fixes
412
-
413
- * pob update ([ffe6857](https://github.com/christophehurpeau/alp/commit/ffe6857))
414
- * typescript issues ([23246f6](https://github.com/christophehurpeau/alp/commit/23246f6))
415
-
416
-
417
-
418
-
419
-
420
- ## [1.2.1](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@1.2.0...react-alp-loading-bar@1.2.1) (2019-05-01)
421
-
422
-
423
- ### Bug Fixes
424
-
425
- * hot loader ([c880769](https://github.com/christophehurpeau/alp/commit/c880769))
426
-
427
-
428
-
429
-
430
-
431
- # [1.2.0](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@1.1.1...react-alp-loading-bar@1.2.0) (2019-05-01)
432
-
433
-
434
- ### Features
435
-
436
- * update deps and pobpack ([1e19ea4](https://github.com/christophehurpeau/alp/commit/1e19ea4))
437
-
438
-
439
-
440
-
441
-
442
- ## [1.1.1](https://github.com/christophehurpeau/alp/compare/react-alp-loading-bar@1.1.0...react-alp-loading-bar@1.1.1) (2019-04-28)
443
-
444
- **Note:** Version bump only for package react-alp-loading-bar
445
-
446
-
447
-
448
-
449
-
450
- # 1.1.0 (2019-04-20)
451
-
452
-
453
- ### Features
454
-
455
- * add react-alp-loading-bar ([5c849b4](https://github.com/christophehurpeau/alp/commit/5c849b4))