musae 0.3.1 → 0.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (42) hide show
  1. package/dist/components/icon/icons/action/index.cjs +18 -1
  2. package/dist/components/icon/icons/action/index.d.ts +16 -0
  3. package/dist/components/icon/icons/action/index.mjs +31 -13
  4. package/dist/components/icon/icons/alert/index.cjs +12 -1
  5. package/dist/components/icon/icons/alert/index.d.ts +10 -0
  6. package/dist/components/icon/icons/alert/index.mjs +19 -7
  7. package/dist/components/icon/icons/content/index.cjs +10 -1
  8. package/dist/components/icon/icons/content/index.d.ts +8 -0
  9. package/dist/components/icon/icons/content/index.mjs +15 -5
  10. package/dist/components/icon/icons/editor/index.cjs +14 -1
  11. package/dist/components/icon/icons/editor/index.d.ts +12 -0
  12. package/dist/components/icon/icons/editor/index.mjs +23 -9
  13. package/dist/components/icon/icons/hardware/index.cjs +11 -1
  14. package/dist/components/icon/icons/hardware/index.d.ts +9 -0
  15. package/dist/components/icon/icons/hardware/index.mjs +17 -6
  16. package/dist/components/icon/icons/image/index.cjs +16 -1
  17. package/dist/components/icon/icons/image/index.d.ts +14 -0
  18. package/dist/components/icon/icons/image/index.mjs +27 -11
  19. package/dist/components/icon/icons/mock/index.cjs +7 -1
  20. package/dist/components/icon/icons/mock/index.d.ts +5 -0
  21. package/dist/components/icon/icons/mock/index.mjs +9 -2
  22. package/dist/components/icon/icons/navigation/index.cjs +10 -1
  23. package/dist/components/icon/icons/navigation/index.d.ts +8 -0
  24. package/dist/components/icon/icons/navigation/index.mjs +15 -5
  25. package/dist/components/icon/icons/toggle/index.cjs +8 -1
  26. package/dist/components/icon/icons/toggle/index.d.ts +6 -0
  27. package/dist/components/icon/icons/toggle/index.mjs +11 -3
  28. package/dist/components/pagination/hooks.cjs +24 -15
  29. package/dist/components/pagination/hooks.d.ts +7 -4
  30. package/dist/components/pagination/hooks.mjs +25 -16
  31. package/dist/components/pagination/item.cjs +9 -9
  32. package/dist/components/pagination/item.d.ts +2 -2
  33. package/dist/components/pagination/item.mjs +9 -9
  34. package/dist/components/pagination/pagination.cjs +16 -10
  35. package/dist/components/pagination/pagination.d.ts +2 -2
  36. package/dist/components/pagination/pagination.mjs +16 -10
  37. package/dist/index.cjs +1 -1
  38. package/dist/index.mjs +1 -1
  39. package/dist/{components/pagination/types.d.ts → types/pagination.d.ts} +20 -9
  40. package/package.json +2 -2
  41. package/dist/components/pagination/types.cjs +0 -11
  42. package/dist/components/pagination/types.mjs +0 -13
@@ -1,3 +1,5 @@
1
+ Object.defineProperty(exports, '__esModule', { value: true });
2
+
1
3
  var visibility = require('./visibility.cjs');
2
4
  var visibilityOff = require('./visibility-off.cjs');
3
5
  var checkCircleOutline = require('./check-circle-outline.cjs');
@@ -12,7 +14,21 @@ var translate = require('./translate.cjs');
12
14
  var code = require('./code.cjs');
13
15
  var openInNew = require('./open-in-new.cjs');
14
16
 
15
-
17
+ var _ = {
18
+ Visibility: visibility.default,
19
+ VisibilityOff: visibilityOff.default,
20
+ CheckCircleOutline: checkCircleOutline.default,
21
+ Done: done.default,
22
+ CheckCircle: checkCircle.default,
23
+ SwapHoriz: swapHoriz.default,
24
+ SwapVert: swapVert.default,
25
+ ZoomOut: zoomOut.default,
26
+ ZoomIn: zoomIn.default,
27
+ DoneOutline: doneOutline.default,
28
+ Translate: translate.default,
29
+ Code: code.default,
30
+ OpenInNew: openInNew.default
31
+ };
16
32
 
17
33
  exports.Visibility = visibility.default;
18
34
  exports.VisibilityOff = visibilityOff.default;
@@ -27,3 +43,4 @@ exports.DoneOutline = doneOutline.default;
27
43
  exports.Translate = translate.default;
28
44
  exports.Code = code.default;
29
45
  exports.OpenInNew = openInNew.default;
46
+ exports.default = _;
@@ -11,4 +11,20 @@ import DoneOutline from "./done-outline";
11
11
  import Translate from "./translate";
12
12
  import Code from "./code";
13
13
  import OpenInNew from "./open-in-new";
14
+ declare const _: {
15
+ Visibility: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
16
+ VisibilityOff: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
17
+ CheckCircleOutline: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
18
+ Done: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
19
+ CheckCircle: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
20
+ SwapHoriz: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
21
+ SwapVert: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
22
+ ZoomOut: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
23
+ ZoomIn: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
24
+ DoneOutline: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
25
+ Translate: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
26
+ Code: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
27
+ OpenInNew: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
28
+ };
29
+ export default _;
14
30
  export { Visibility, VisibilityOff, CheckCircleOutline, Done, CheckCircle, SwapHoriz, SwapVert, ZoomOut, ZoomIn, DoneOutline, Translate, Code, OpenInNew, };
@@ -1,13 +1,31 @@
1
- export { default as Visibility } from './visibility.mjs';
2
- export { default as VisibilityOff } from './visibility-off.mjs';
3
- export { default as CheckCircleOutline } from './check-circle-outline.mjs';
4
- export { default as Done } from './done.mjs';
5
- export { default as CheckCircle } from './check-circle.mjs';
6
- export { default as SwapHoriz } from './swap-horiz.mjs';
7
- export { default as SwapVert } from './swap-vert.mjs';
8
- export { default as ZoomOut } from './zoom-out.mjs';
9
- export { default as ZoomIn } from './zoom-in.mjs';
10
- export { default as DoneOutline } from './done-outline.mjs';
11
- export { default as Translate } from './translate.mjs';
12
- export { default as Code } from './code.mjs';
13
- export { default as OpenInNew } from './open-in-new.mjs';
1
+ import Visibility from './visibility.mjs';
2
+ import VisibilityOff from './visibility-off.mjs';
3
+ import CheckCircleOutline from './check-circle-outline.mjs';
4
+ import Done from './done.mjs';
5
+ import CheckCircle from './check-circle.mjs';
6
+ import SwapHoriz from './swap-horiz.mjs';
7
+ import SwapVert from './swap-vert.mjs';
8
+ import ZoomOut from './zoom-out.mjs';
9
+ import ZoomIn from './zoom-in.mjs';
10
+ import DoneOutline from './done-outline.mjs';
11
+ import Translate from './translate.mjs';
12
+ import Code from './code.mjs';
13
+ import OpenInNew from './open-in-new.mjs';
14
+
15
+ var _ = {
16
+ Visibility: Visibility,
17
+ VisibilityOff: VisibilityOff,
18
+ CheckCircleOutline: CheckCircleOutline,
19
+ Done: Done,
20
+ CheckCircle: CheckCircle,
21
+ SwapHoriz: SwapHoriz,
22
+ SwapVert: SwapVert,
23
+ ZoomOut: ZoomOut,
24
+ ZoomIn: ZoomIn,
25
+ DoneOutline: DoneOutline,
26
+ Translate: Translate,
27
+ Code: Code,
28
+ OpenInNew: OpenInNew
29
+ };
30
+
31
+ export { CheckCircle, CheckCircleOutline, Code, Done, DoneOutline, OpenInNew, SwapHoriz, SwapVert, Translate, Visibility, VisibilityOff, ZoomIn, ZoomOut, _ as default };
@@ -1,3 +1,5 @@
1
+ Object.defineProperty(exports, '__esModule', { value: true });
2
+
1
3
  var errorOutline = require('./error-outline.cjs');
2
4
  var addAlert = require('./add-alert.cjs');
3
5
  var autoDelete = require('./auto-delete.cjs');
@@ -6,7 +8,15 @@ var notificationImportant = require('./notification-important.cjs');
6
8
  var warning = require('./warning.cjs');
7
9
  var warningAmber = require('./warning-amber.cjs');
8
10
 
9
-
11
+ var _ = {
12
+ ErrorOutline: errorOutline.default,
13
+ AddAlert: addAlert.default,
14
+ AutoDelete: autoDelete.default,
15
+ Error: error.default,
16
+ NotificationImportant: notificationImportant.default,
17
+ Warning: warning.default,
18
+ WarningAmber: warningAmber.default
19
+ };
10
20
 
11
21
  exports.ErrorOutline = errorOutline.default;
12
22
  exports.AddAlert = addAlert.default;
@@ -15,3 +25,4 @@ exports.Error = error.default;
15
25
  exports.NotificationImportant = notificationImportant.default;
16
26
  exports.Warning = warning.default;
17
27
  exports.WarningAmber = warningAmber.default;
28
+ exports.default = _;
@@ -5,4 +5,14 @@ import Error from "./error";
5
5
  import NotificationImportant from "./notification-important";
6
6
  import Warning from "./warning";
7
7
  import WarningAmber from "./warning-amber";
8
+ declare const _: {
9
+ ErrorOutline: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
10
+ AddAlert: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
11
+ AutoDelete: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
12
+ Error: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
13
+ NotificationImportant: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
14
+ Warning: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
15
+ WarningAmber: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
16
+ };
17
+ export default _;
8
18
  export { ErrorOutline, AddAlert, AutoDelete, Error, NotificationImportant, Warning, WarningAmber };
@@ -1,7 +1,19 @@
1
- export { default as ErrorOutline } from './error-outline.mjs';
2
- export { default as AddAlert } from './add-alert.mjs';
3
- export { default as AutoDelete } from './auto-delete.mjs';
4
- export { default as Error } from './error.mjs';
5
- export { default as NotificationImportant } from './notification-important.mjs';
6
- export { default as Warning } from './warning.mjs';
7
- export { default as WarningAmber } from './warning-amber.mjs';
1
+ import ErrorOutline from './error-outline.mjs';
2
+ import AddAlert from './add-alert.mjs';
3
+ import AutoDelete from './auto-delete.mjs';
4
+ import Error from './error.mjs';
5
+ import NotificationImportant from './notification-important.mjs';
6
+ import Warning from './warning.mjs';
7
+ import WarningAmber from './warning-amber.mjs';
8
+
9
+ var _ = {
10
+ ErrorOutline: ErrorOutline,
11
+ AddAlert: AddAlert,
12
+ AutoDelete: AutoDelete,
13
+ Error: Error,
14
+ NotificationImportant: NotificationImportant,
15
+ Warning: Warning,
16
+ WarningAmber: WarningAmber
17
+ };
18
+
19
+ export { AddAlert, AutoDelete, Error, ErrorOutline, NotificationImportant, Warning, WarningAmber, _ as default };
@@ -1,13 +1,22 @@
1
+ Object.defineProperty(exports, '__esModule', { value: true });
2
+
1
3
  var clear = require('./clear.cjs');
2
4
  var redo = require('./redo.cjs');
3
5
  var undo = require('./undo.cjs');
4
6
  var linkOff = require('./link-off.cjs');
5
7
  var fontDownload = require('./font-download.cjs');
6
8
 
7
-
9
+ var _ = {
10
+ Clear: clear.default,
11
+ Redo: redo.default,
12
+ Undo: undo.default,
13
+ LinkOff: linkOff.default,
14
+ FontDownload: fontDownload.default
15
+ };
8
16
 
9
17
  exports.Clear = clear.default;
10
18
  exports.Redo = redo.default;
11
19
  exports.Undo = undo.default;
12
20
  exports.LinkOff = linkOff.default;
13
21
  exports.FontDownload = fontDownload.default;
22
+ exports.default = _;
@@ -3,4 +3,12 @@ import Redo from "./redo";
3
3
  import Undo from "./undo";
4
4
  import LinkOff from "./link-off";
5
5
  import FontDownload from "./font-download";
6
+ declare const _: {
7
+ Clear: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
8
+ Redo: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
9
+ Undo: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
10
+ LinkOff: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
11
+ FontDownload: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
12
+ };
13
+ export default _;
6
14
  export { Clear, Redo, Undo, LinkOff, FontDownload };
@@ -1,5 +1,15 @@
1
- export { default as Clear } from './clear.mjs';
2
- export { default as Redo } from './redo.mjs';
3
- export { default as Undo } from './undo.mjs';
4
- export { default as LinkOff } from './link-off.mjs';
5
- export { default as FontDownload } from './font-download.mjs';
1
+ import Redo from './clear.mjs';
2
+ import Clear from './redo.mjs';
3
+ import Undo from './undo.mjs';
4
+ import LinkOff from './link-off.mjs';
5
+ import FontDownload from './font-download.mjs';
6
+
7
+ var _ = {
8
+ Clear: Redo,
9
+ Redo: Clear,
10
+ Undo: Undo,
11
+ LinkOff: LinkOff,
12
+ FontDownload: FontDownload
13
+ };
14
+
15
+ export { Redo as Clear, FontDownload, LinkOff, Clear as Redo, Undo, _ as default };
@@ -1,3 +1,5 @@
1
+ Object.defineProperty(exports, '__esModule', { value: true });
2
+
1
3
  var formatBold = require('./format-bold.cjs');
2
4
  var formatItalic = require('./format-italic.cjs');
3
5
  var formatUnderlined = require('./format-underlined.cjs');
@@ -8,7 +10,17 @@ var superscript = require('./superscript.cjs');
8
10
  var notes = require('./notes.cjs');
9
11
  var checklist = require('./checklist.cjs');
10
12
 
11
-
13
+ var _ = {
14
+ FormatBold: formatBold.default,
15
+ FormatItalic: formatItalic.default,
16
+ FormatUnderlined: formatUnderlined.default,
17
+ InsertLink: insertLink.default,
18
+ FormatStrikethrough: formatStrikethrough.default,
19
+ Subscript: subscript.default,
20
+ Superscript: superscript.default,
21
+ Notes: notes.default,
22
+ Checklist: checklist.default
23
+ };
12
24
 
13
25
  exports.FormatBold = formatBold.default;
14
26
  exports.FormatItalic = formatItalic.default;
@@ -19,3 +31,4 @@ exports.Subscript = subscript.default;
19
31
  exports.Superscript = superscript.default;
20
32
  exports.Notes = notes.default;
21
33
  exports.Checklist = checklist.default;
34
+ exports.default = _;
@@ -7,4 +7,16 @@ import Subscript from "./subscript";
7
7
  import Superscript from "./superscript";
8
8
  import Notes from "./notes";
9
9
  import Checklist from "./checklist";
10
+ declare const _: {
11
+ FormatBold: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
12
+ FormatItalic: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
13
+ FormatUnderlined: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
14
+ InsertLink: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
15
+ FormatStrikethrough: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
16
+ Subscript: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
17
+ Superscript: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
18
+ Notes: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
19
+ Checklist: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
20
+ };
21
+ export default _;
10
22
  export { FormatBold, FormatItalic, FormatUnderlined, InsertLink, FormatStrikethrough, Subscript, Superscript, Notes, Checklist, };
@@ -1,9 +1,23 @@
1
- export { default as FormatBold } from './format-bold.mjs';
2
- export { default as FormatItalic } from './format-italic.mjs';
3
- export { default as FormatUnderlined } from './format-underlined.mjs';
4
- export { default as InsertLink } from './insert-link.mjs';
5
- export { default as FormatStrikethrough } from './format-strikethrough.mjs';
6
- export { default as Subscript } from './subscript.mjs';
7
- export { default as Superscript } from './superscript.mjs';
8
- export { default as Notes } from './notes.mjs';
9
- export { default as Checklist } from './checklist.mjs';
1
+ import FormatBold from './format-bold.mjs';
2
+ import FormatItalic from './format-italic.mjs';
3
+ import FormatUnderlined from './format-underlined.mjs';
4
+ import InsertLink from './insert-link.mjs';
5
+ import FormatStrikethrough from './format-strikethrough.mjs';
6
+ import Subscript from './subscript.mjs';
7
+ import Superscript from './superscript.mjs';
8
+ import Notes from './notes.mjs';
9
+ import Checklist from './checklist.mjs';
10
+
11
+ var _ = {
12
+ FormatBold: FormatBold,
13
+ FormatItalic: FormatItalic,
14
+ FormatUnderlined: FormatUnderlined,
15
+ InsertLink: InsertLink,
16
+ FormatStrikethrough: FormatStrikethrough,
17
+ Subscript: Subscript,
18
+ Superscript: Superscript,
19
+ Notes: Notes,
20
+ Checklist: Checklist
21
+ };
22
+
23
+ export { Checklist, FormatBold, FormatItalic, FormatStrikethrough, FormatUnderlined, InsertLink, Notes, Subscript, Superscript, _ as default };
@@ -1,3 +1,5 @@
1
+ Object.defineProperty(exports, '__esModule', { value: true });
2
+
1
3
  var keyboardDoubleArrowLeft = require('./keyboard-double-arrow-left.cjs');
2
4
  var keyboardDoubleArrowRight = require('./keyboard-double-arrow-right.cjs');
3
5
  var keyboardArrowLeft = require('./keyboard-arrow-left.cjs');
@@ -5,7 +7,14 @@ var keyboardArrowRight = require('./keyboard-arrow-right.cjs');
5
7
  var keyboardArrowUp = require('./keyboard-arrow-up.cjs');
6
8
  var keyboardArrowDown = require('./keyboard-arrow-down.cjs');
7
9
 
8
-
10
+ var _ = {
11
+ KeyboardDoubleArrowLeft: keyboardDoubleArrowLeft.default,
12
+ KeyboardArrowDown: keyboardArrowDown.default,
13
+ KeyboardArrowLeft: keyboardArrowLeft.default,
14
+ KeyboardArrowRight: keyboardArrowRight.default,
15
+ KeyboardArrowUp: keyboardArrowUp.default,
16
+ KeyboardDoubleArrowRight: keyboardDoubleArrowRight.default
17
+ };
9
18
 
10
19
  exports.KeyboardDoubleArrowLeft = keyboardDoubleArrowLeft.default;
11
20
  exports.KeyboardDoubleArrowRight = keyboardDoubleArrowRight.default;
@@ -13,3 +22,4 @@ exports.KeyboardArrowLeft = keyboardArrowLeft.default;
13
22
  exports.KeyboardArrowRight = keyboardArrowRight.default;
14
23
  exports.KeyboardArrowUp = keyboardArrowUp.default;
15
24
  exports.KeyboardArrowDown = keyboardArrowDown.default;
25
+ exports.default = _;
@@ -4,4 +4,13 @@ import KeyboardArrowLeft from "./keyboard-arrow-left";
4
4
  import KeyboardArrowRight from "./keyboard-arrow-right";
5
5
  import KeyboardArrowUp from "./keyboard-arrow-up";
6
6
  import KeyboardArrowDown from "./keyboard-arrow-down";
7
+ declare const _: {
8
+ KeyboardDoubleArrowLeft: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
9
+ KeyboardArrowDown: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
10
+ KeyboardArrowLeft: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
11
+ KeyboardArrowRight: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
12
+ KeyboardArrowUp: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
13
+ KeyboardDoubleArrowRight: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
14
+ };
15
+ export default _;
7
16
  export { KeyboardDoubleArrowLeft, KeyboardArrowDown, KeyboardArrowLeft, KeyboardArrowRight, KeyboardArrowUp, KeyboardDoubleArrowRight, };
@@ -1,6 +1,17 @@
1
- export { default as KeyboardDoubleArrowLeft } from './keyboard-double-arrow-left.mjs';
2
- export { default as KeyboardDoubleArrowRight } from './keyboard-double-arrow-right.mjs';
3
- export { default as KeyboardArrowLeft } from './keyboard-arrow-left.mjs';
4
- export { default as KeyboardArrowRight } from './keyboard-arrow-right.mjs';
5
- export { default as KeyboardArrowUp } from './keyboard-arrow-up.mjs';
6
- export { default as KeyboardArrowDown } from './keyboard-arrow-down.mjs';
1
+ import KeyboardDoubleArrowLeft from './keyboard-double-arrow-left.mjs';
2
+ import KeyboardDoubleArrowRight from './keyboard-double-arrow-right.mjs';
3
+ import KeyboardArrowLeft from './keyboard-arrow-left.mjs';
4
+ import KeyboardArrowRight from './keyboard-arrow-right.mjs';
5
+ import KeyboardArrowUp from './keyboard-arrow-up.mjs';
6
+ import KeyboardArrowDown from './keyboard-arrow-down.mjs';
7
+
8
+ var _ = {
9
+ KeyboardDoubleArrowLeft: KeyboardDoubleArrowLeft,
10
+ KeyboardArrowDown: KeyboardArrowDown,
11
+ KeyboardArrowLeft: KeyboardArrowLeft,
12
+ KeyboardArrowRight: KeyboardArrowRight,
13
+ KeyboardArrowUp: KeyboardArrowUp,
14
+ KeyboardDoubleArrowRight: KeyboardDoubleArrowRight
15
+ };
16
+
17
+ export { KeyboardArrowDown, KeyboardArrowLeft, KeyboardArrowRight, KeyboardArrowUp, KeyboardDoubleArrowLeft, KeyboardDoubleArrowRight, _ as default };
@@ -1,3 +1,5 @@
1
+ Object.defineProperty(exports, '__esModule', { value: true });
2
+
1
3
  var bedtime = require('./bedtime.cjs');
2
4
  var wbSunny = require('./wb-sunny.cjs');
3
5
  var rotateLeft = require('./rotate-left.cjs');
@@ -10,7 +12,19 @@ var looksFive = require('./looks-five.cjs');
10
12
  var looksSix = require('./looks-six.cjs');
11
13
  var edit = require('./edit.cjs');
12
14
 
13
-
15
+ var _ = {
16
+ Bedtime: bedtime.default,
17
+ RotateLeft: rotateLeft.default,
18
+ RotateRight: rotateRight.default,
19
+ WbSunny: wbSunny.default,
20
+ LooksOne: looksOne.default,
21
+ LooksTwo: looksTwo.default,
22
+ LooksThree: looksThree.default,
23
+ LooksFour: looksFour.default,
24
+ LooksFive: looksFive.default,
25
+ LooksSix: looksSix.default,
26
+ Edit: edit.default
27
+ };
14
28
 
15
29
  exports.Bedtime = bedtime.default;
16
30
  exports.WbSunny = wbSunny.default;
@@ -23,3 +37,4 @@ exports.LooksFour = looksFour.default;
23
37
  exports.LooksFive = looksFive.default;
24
38
  exports.LooksSix = looksSix.default;
25
39
  exports.Edit = edit.default;
40
+ exports.default = _;
@@ -9,4 +9,18 @@ import LooksFour from "./looks-four";
9
9
  import LooksFive from "./looks-five";
10
10
  import LooksSix from "./looks-six";
11
11
  import Edit from "./edit";
12
+ declare const _: {
13
+ Bedtime: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
14
+ RotateLeft: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
15
+ RotateRight: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
16
+ WbSunny: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
17
+ LooksOne: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
18
+ LooksTwo: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
19
+ LooksThree: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
20
+ LooksFour: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
21
+ LooksFive: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
22
+ LooksSix: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
23
+ Edit: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
24
+ };
25
+ export default _;
12
26
  export { Bedtime, RotateLeft, RotateRight, WbSunny, LooksOne, LooksTwo, LooksThree, LooksFour, LooksFive, LooksSix, Edit, };
@@ -1,11 +1,27 @@
1
- export { default as Bedtime } from './bedtime.mjs';
2
- export { default as WbSunny } from './wb-sunny.mjs';
3
- export { default as RotateLeft } from './rotate-left.mjs';
4
- export { default as RotateRight } from './rotate-right.mjs';
5
- export { default as LooksOne } from './looks-one.mjs';
6
- export { default as LooksTwo } from './looks-two.mjs';
7
- export { default as LooksThree } from './looks-three.mjs';
8
- export { default as LooksFour } from './looks-four.mjs';
9
- export { default as LooksFive } from './looks-five.mjs';
10
- export { default as LooksSix } from './looks-six.mjs';
11
- export { default as Edit } from './edit.mjs';
1
+ import Bedtime from './bedtime.mjs';
2
+ import Bedtime$1 from './wb-sunny.mjs';
3
+ import RotateLeft from './rotate-left.mjs';
4
+ import RotateRight from './rotate-right.mjs';
5
+ import LooksOne from './looks-one.mjs';
6
+ import LooksTwo from './looks-two.mjs';
7
+ import LooksThree from './looks-three.mjs';
8
+ import LooksFour from './looks-four.mjs';
9
+ import LooksFive from './looks-five.mjs';
10
+ import LooksSix from './looks-six.mjs';
11
+ import Edit from './edit.mjs';
12
+
13
+ var _ = {
14
+ Bedtime: Bedtime,
15
+ RotateLeft: RotateLeft,
16
+ RotateRight: RotateRight,
17
+ WbSunny: Bedtime$1,
18
+ LooksOne: LooksOne,
19
+ LooksTwo: LooksTwo,
20
+ LooksThree: LooksThree,
21
+ LooksFour: LooksFour,
22
+ LooksFive: LooksFive,
23
+ LooksSix: LooksSix,
24
+ Edit: Edit
25
+ };
26
+
27
+ export { Bedtime, Edit, LooksFive, LooksFour, LooksOne, LooksSix, LooksThree, LooksTwo, RotateLeft, RotateRight, Bedtime$1 as WbSunny, _ as default };
@@ -1,7 +1,13 @@
1
+ Object.defineProperty(exports, '__esModule', { value: true });
2
+
1
3
  var github = require('./github.cjs');
2
4
  var loading = require('./loading.cjs');
3
5
 
4
-
6
+ var _ = {
7
+ Github: github.default,
8
+ Loading: loading.default
9
+ };
5
10
 
6
11
  exports.Github = github.default;
7
12
  exports.Loading = loading.default;
13
+ exports.default = _;
@@ -1,3 +1,8 @@
1
1
  import Github from "./github";
2
2
  import Loading from "./loading";
3
+ declare const _: {
4
+ Github: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
5
+ Loading: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
6
+ };
7
+ export default _;
3
8
  export { Github, Loading };
@@ -1,2 +1,9 @@
1
- export { default as Github } from './github.mjs';
2
- export { default as Loading } from './loading.mjs';
1
+ import Github from './github.mjs';
2
+ import Loading from './loading.mjs';
3
+
4
+ var _ = {
5
+ Github: Github,
6
+ Loading: Loading
7
+ };
8
+
9
+ export { Github, Loading, _ as default };
@@ -1,13 +1,22 @@
1
+ Object.defineProperty(exports, '__esModule', { value: true });
2
+
1
3
  var cancel = require('./cancel.cjs');
2
4
  var moreHoriz = require('./more-horiz.cjs');
3
5
  var close = require('./close.cjs');
4
6
  var check = require('./check.cjs');
5
7
  var unfoldMore = require('./unfold-more.cjs');
6
8
 
7
-
9
+ var _ = {
10
+ Cancel: cancel.default,
11
+ Close: close.default,
12
+ MoreHoriz: moreHoriz.default,
13
+ Check: check.default,
14
+ UnfoldMore: unfoldMore.default
15
+ };
8
16
 
9
17
  exports.Cancel = cancel.default;
10
18
  exports.MoreHoriz = moreHoriz.default;
11
19
  exports.Close = close.default;
12
20
  exports.Check = check.default;
13
21
  exports.UnfoldMore = unfoldMore.default;
22
+ exports.default = _;
@@ -3,4 +3,12 @@ import MoreHoriz from "./more-horiz";
3
3
  import Close from "./close";
4
4
  import Check from "./check";
5
5
  import UnfoldMore from "./unfold-more";
6
+ declare const _: {
7
+ Cancel: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
8
+ Close: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
9
+ MoreHoriz: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
10
+ Check: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
11
+ UnfoldMore: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
12
+ };
13
+ export default _;
6
14
  export { Cancel, Close, MoreHoriz, Check, UnfoldMore };
@@ -1,5 +1,15 @@
1
- export { default as Cancel } from './cancel.mjs';
2
- export { default as MoreHoriz } from './more-horiz.mjs';
3
- export { default as Close } from './close.mjs';
4
- export { default as Check } from './check.mjs';
5
- export { default as UnfoldMore } from './unfold-more.mjs';
1
+ import Cancel from './cancel.mjs';
2
+ import MoreHoriz from './more-horiz.mjs';
3
+ import Close from './close.mjs';
4
+ import Check from './check.mjs';
5
+ import UnfoldMore from './unfold-more.mjs';
6
+
7
+ var _ = {
8
+ Cancel: Cancel,
9
+ Close: Close,
10
+ MoreHoriz: MoreHoriz,
11
+ Check: Check,
12
+ UnfoldMore: UnfoldMore
13
+ };
14
+
15
+ export { Cancel, Check, Close, MoreHoriz, UnfoldMore, _ as default };
@@ -1,9 +1,16 @@
1
+ Object.defineProperty(exports, '__esModule', { value: true });
2
+
1
3
  var star = require('./star.cjs');
2
4
  var starHalf = require('./star-half.cjs');
3
5
  var starOutline = require('./star-outline.cjs');
4
6
 
5
-
7
+ var _ = {
8
+ Star: star.default,
9
+ StarHalf: starHalf.default,
10
+ StarOutline: starOutline.default
11
+ };
6
12
 
7
13
  exports.Star = star.default;
8
14
  exports.StarHalf = starHalf.default;
9
15
  exports.StarOutline = starOutline.default;
16
+ exports.default = _;
@@ -1,4 +1,10 @@
1
1
  import Star from "./star";
2
2
  import StarHalf from "./star-half";
3
3
  import StarOutline from "./star-outline";
4
+ declare const _: {
5
+ Star: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
6
+ StarHalf: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
7
+ StarOutline: (props: Omit<import("../..").IconProps, "as">) => import("react").FunctionComponentElement<import("../..").IconProps>;
8
+ };
9
+ export default _;
4
10
  export { Star, StarHalf, StarOutline };
@@ -1,3 +1,11 @@
1
- export { default as Star } from './star.mjs';
2
- export { default as StarHalf } from './star-half.mjs';
3
- export { default as StarOutline } from './star-outline.mjs';
1
+ import Star from './star.mjs';
2
+ import StarHalf from './star-half.mjs';
3
+ import StarOutline from './star-outline.mjs';
4
+
5
+ var _ = {
6
+ Star: Star,
7
+ StarHalf: StarHalf,
8
+ StarOutline: StarOutline
9
+ };
10
+
11
+ export { Star, StarHalf, StarOutline, _ as default };
@@ -2,7 +2,6 @@ var _toConsumableArray = require('@babel/runtime/helpers/toConsumableArray');
2
2
  var _slicedToArray = require('@babel/runtime/helpers/slicedToArray');
3
3
  var relax = require('@aiszlab/relax');
4
4
  var React = require('react');
5
- var types = require('./types.cjs');
6
5
 
7
6
  /**
8
7
  * @author murukal
@@ -14,22 +13,27 @@ var usePagiantion = function usePagiantion(_ref) {
14
13
  var total = _ref.total,
15
14
  siblings = _ref.siblings,
16
15
  boundaries = _ref.boundaries,
17
- _pageSize = _ref.pageSize;
16
+ _pageSize = _ref.pageSize,
17
+ _at = _ref.at,
18
+ _onChange = _ref.onChange,
19
+ _onPageSizeChange = _ref.onPageSizeChange;
18
20
  var _useControlledState = relax.useControlledState(_pageSize, {
19
21
  defaultState: 10
20
22
  }),
21
23
  _useControlledState2 = _slicedToArray(_useControlledState, 2),
22
24
  pageSize = _useControlledState2[0],
23
25
  setPageSize = _useControlledState2[1];
26
+ // convert total into page count
27
+ // at least 1 page
24
28
  var pages = React.useMemo(function () {
25
- return Math.ceil(total / Math.max(1, pageSize));
29
+ return Math.max(1, Math.ceil(total / Math.max(1, pageSize)));
26
30
  }, [total, pageSize]);
27
- var _useCounter = relax.useCounter(1, {
31
+ var _useCounter = relax.useCounter(_at, {
28
32
  min: 1,
29
33
  max: pages
30
34
  }),
31
35
  _useCounter2 = _slicedToArray(_useCounter, 2),
32
- page = _useCounter2[0],
36
+ at = _useCounter2[0],
33
37
  _useCounter2$ = _useCounter2[1],
34
38
  add = _useCounter2$.add,
35
39
  subtract = _useCounter2$.subtract,
@@ -38,28 +42,33 @@ var usePagiantion = function usePagiantion(_ref) {
38
42
  // max renderable pages
39
43
  var renderable = siblings * 2 + 3 + boundaries * 2;
40
44
  if (renderable > pages) {
41
- return [types.PaginationItemType.Prev].concat(_toConsumableArray(relax.range(1, pages)), [types.PaginationItemType.Next]);
45
+ return ["prev"].concat(_toConsumableArray(relax.range(1, pages)), ["next"]);
42
46
  }
43
- var focusedAt = relax.clamp(page, boundaries + 3, pages - (boundaries + 2));
47
+ var focusedAt = relax.clamp(at, boundaries + 3, pages - (boundaries + 2));
44
48
  var from = Math.max(focusedAt - siblings, boundaries);
45
49
  var to = Math.min(focusedAt + siblings, pages - (boundaries - 1));
46
50
  var hasPrevMore = from > boundaries + 2;
47
51
  var hasNextMore = to < pages - (boundaries + 1);
48
- return [types.PaginationItemType.Prev].concat(_toConsumableArray(relax.range(1, boundaries)), _toConsumableArray(hasPrevMore ? [types.PaginationItemType.MorePrev] : [boundaries + 1]), _toConsumableArray(relax.range(from, to)), _toConsumableArray(hasNextMore ? [types.PaginationItemType.MoreNext] : [pages - boundaries]), _toConsumableArray(relax.range(pages - (boundaries - 1), pages)), [types.PaginationItemType.Next]);
49
- }, [boundaries, page, pages, siblings]);
52
+ return ["prev"].concat(_toConsumableArray(relax.range(1, boundaries)), _toConsumableArray(hasPrevMore ? ["more-prev"] : [boundaries + 1]), _toConsumableArray(relax.range(from, to)), _toConsumableArray(hasNextMore ? ["more-next"] : [pages - boundaries]), _toConsumableArray(relax.range(pages - (boundaries - 1), pages)), ["next"]);
53
+ }, [boundaries, at, pages, siblings]);
50
54
  // whether prev button is usable
51
- var hasPrev = page > 1;
55
+ var hasPrev = at > 1;
52
56
  // whether next button is usable
53
- var hasNext = page < pages;
54
- var onPageSizeChange = function onPageSizeChange(pageSize) {
57
+ var hasNext = at < pages;
58
+ var onChange = relax.useEvent(function (at) {
59
+ _onChange === null || _onChange === void 0 || _onChange(at);
60
+ setCount(at);
61
+ });
62
+ var onPageSizeChange = relax.useEvent(function (pageSize) {
63
+ _onPageSizeChange === null || _onPageSizeChange === void 0 || _onPageSizeChange(pageSize);
55
64
  setPageSize(pageSize);
56
- };
65
+ });
57
66
  return {
58
67
  paginationItems: paginationItems,
59
68
  add: add,
60
69
  subtract: subtract,
61
- changePage: setCount,
62
- page: page,
70
+ onChange: onChange,
71
+ at: at,
63
72
  hasPrev: hasPrev,
64
73
  hasNext: hasNext,
65
74
  pageSize: pageSize,
@@ -1,21 +1,24 @@
1
- import { type PaginationItems } from "./types";
1
+ import type { PaginationItems } from "musae/types/pagination";
2
2
  /**
3
3
  * @author murukal
4
4
  *
5
5
  * @description
6
6
  * use pagination
7
7
  */
8
- export declare const usePagiantion: ({ total, siblings, boundaries, pageSize: _pageSize, }: {
8
+ export declare const usePagiantion: ({ total, siblings, boundaries, pageSize: _pageSize, at: _at, onChange: _onChange, onPageSizeChange: _onPageSizeChange, }: {
9
9
  total: number;
10
10
  siblings: number;
11
11
  boundaries: number;
12
12
  pageSize?: number;
13
+ at?: number;
14
+ onChange?: (at: number) => void;
15
+ onPageSizeChange?: (pageSize: number) => void;
13
16
  }) => {
14
17
  paginationItems: PaginationItems;
15
18
  add: (step?: number) => void;
16
19
  subtract: (step?: number) => void;
17
- changePage: import("react").Dispatch<import("react").SetStateAction<number>>;
18
- page: number;
20
+ onChange: (at: number) => void;
21
+ at: number;
19
22
  hasPrev: boolean;
20
23
  hasNext: boolean;
21
24
  pageSize: number;
@@ -1,8 +1,7 @@
1
1
  import _toConsumableArray from '@babel/runtime/helpers/toConsumableArray';
2
2
  import _slicedToArray from '@babel/runtime/helpers/slicedToArray';
3
- import { useControlledState, useCounter, range, clamp } from '@aiszlab/relax';
3
+ import { useControlledState, useCounter, range, clamp, useEvent } from '@aiszlab/relax';
4
4
  import { useMemo } from 'react';
5
- import { PaginationItemType } from './types.mjs';
6
5
 
7
6
  /**
8
7
  * @author murukal
@@ -14,22 +13,27 @@ var usePagiantion = function usePagiantion(_ref) {
14
13
  var total = _ref.total,
15
14
  siblings = _ref.siblings,
16
15
  boundaries = _ref.boundaries,
17
- _pageSize = _ref.pageSize;
16
+ _pageSize = _ref.pageSize,
17
+ _at = _ref.at,
18
+ _onChange = _ref.onChange,
19
+ _onPageSizeChange = _ref.onPageSizeChange;
18
20
  var _useControlledState = useControlledState(_pageSize, {
19
21
  defaultState: 10
20
22
  }),
21
23
  _useControlledState2 = _slicedToArray(_useControlledState, 2),
22
24
  pageSize = _useControlledState2[0],
23
25
  setPageSize = _useControlledState2[1];
26
+ // convert total into page count
27
+ // at least 1 page
24
28
  var pages = useMemo(function () {
25
- return Math.ceil(total / Math.max(1, pageSize));
29
+ return Math.max(1, Math.ceil(total / Math.max(1, pageSize)));
26
30
  }, [total, pageSize]);
27
- var _useCounter = useCounter(1, {
31
+ var _useCounter = useCounter(_at, {
28
32
  min: 1,
29
33
  max: pages
30
34
  }),
31
35
  _useCounter2 = _slicedToArray(_useCounter, 2),
32
- page = _useCounter2[0],
36
+ at = _useCounter2[0],
33
37
  _useCounter2$ = _useCounter2[1],
34
38
  add = _useCounter2$.add,
35
39
  subtract = _useCounter2$.subtract,
@@ -38,28 +42,33 @@ var usePagiantion = function usePagiantion(_ref) {
38
42
  // max renderable pages
39
43
  var renderable = siblings * 2 + 3 + boundaries * 2;
40
44
  if (renderable > pages) {
41
- return [PaginationItemType.Prev].concat(_toConsumableArray(range(1, pages)), [PaginationItemType.Next]);
45
+ return ["prev"].concat(_toConsumableArray(range(1, pages)), ["next"]);
42
46
  }
43
- var focusedAt = clamp(page, boundaries + 3, pages - (boundaries + 2));
47
+ var focusedAt = clamp(at, boundaries + 3, pages - (boundaries + 2));
44
48
  var from = Math.max(focusedAt - siblings, boundaries);
45
49
  var to = Math.min(focusedAt + siblings, pages - (boundaries - 1));
46
50
  var hasPrevMore = from > boundaries + 2;
47
51
  var hasNextMore = to < pages - (boundaries + 1);
48
- return [PaginationItemType.Prev].concat(_toConsumableArray(range(1, boundaries)), _toConsumableArray(hasPrevMore ? [PaginationItemType.MorePrev] : [boundaries + 1]), _toConsumableArray(range(from, to)), _toConsumableArray(hasNextMore ? [PaginationItemType.MoreNext] : [pages - boundaries]), _toConsumableArray(range(pages - (boundaries - 1), pages)), [PaginationItemType.Next]);
49
- }, [boundaries, page, pages, siblings]);
52
+ return ["prev"].concat(_toConsumableArray(range(1, boundaries)), _toConsumableArray(hasPrevMore ? ["more-prev"] : [boundaries + 1]), _toConsumableArray(range(from, to)), _toConsumableArray(hasNextMore ? ["more-next"] : [pages - boundaries]), _toConsumableArray(range(pages - (boundaries - 1), pages)), ["next"]);
53
+ }, [boundaries, at, pages, siblings]);
50
54
  // whether prev button is usable
51
- var hasPrev = page > 1;
55
+ var hasPrev = at > 1;
52
56
  // whether next button is usable
53
- var hasNext = page < pages;
54
- var onPageSizeChange = function onPageSizeChange(pageSize) {
57
+ var hasNext = at < pages;
58
+ var onChange = useEvent(function (at) {
59
+ _onChange === null || _onChange === void 0 || _onChange(at);
60
+ setCount(at);
61
+ });
62
+ var onPageSizeChange = useEvent(function (pageSize) {
63
+ _onPageSizeChange === null || _onPageSizeChange === void 0 || _onPageSizeChange(pageSize);
55
64
  setPageSize(pageSize);
56
- };
65
+ });
57
66
  return {
58
67
  paginationItems: paginationItems,
59
68
  add: add,
60
69
  subtract: subtract,
61
- changePage: setCount,
62
- page: page,
70
+ onChange: onChange,
71
+ at: at,
63
72
  hasPrev: hasPrev,
64
73
  hasNext: hasNext,
65
74
  pageSize: pageSize,
@@ -1,7 +1,6 @@
1
1
  Object.defineProperty(exports, '__esModule', { value: true });
2
2
 
3
3
  var React = require('react');
4
- var types = require('./types.cjs');
5
4
  var button = require('../button/button.cjs');
6
5
  var keyboardArrowLeft = require('../icon/icons/hardware/keyboard-arrow-left.cjs');
7
6
  var keyboardArrowRight = require('../icon/icons/hardware/keyboard-arrow-right.cjs');
@@ -11,13 +10,13 @@ var keyboardDoubleArrowRight = require('../icon/icons/hardware/keyboard-double-a
11
10
 
12
11
  var Item = function Item(_ref) {
13
12
  var value = _ref.value,
14
- onPageChange = _ref.onPageChange,
13
+ _onClick = _ref.onClick,
15
14
  add = _ref.add,
16
15
  subtract = _ref.subtract,
17
16
  checked = _ref.checked,
18
17
  hasNext = _ref.hasNext,
19
18
  hasPrev = _ref.hasPrev;
20
- if (value === types.PaginationItemType.Prev) {
19
+ if (value === "prev") {
21
20
  return /*#__PURE__*/React.createElement(button.Button, {
22
21
  onClick: function onClick() {
23
22
  return subtract();
@@ -28,7 +27,7 @@ var Item = function Item(_ref) {
28
27
  disabled: !hasPrev
29
28
  }, /*#__PURE__*/React.createElement(keyboardArrowLeft.default, null));
30
29
  }
31
- if (value === types.PaginationItemType.Next) {
30
+ if (value === "next") {
32
31
  return /*#__PURE__*/React.createElement(button.Button, {
33
32
  onClick: function onClick() {
34
33
  return add();
@@ -39,13 +38,14 @@ var Item = function Item(_ref) {
39
38
  disabled: !hasNext
40
39
  }, /*#__PURE__*/React.createElement(keyboardArrowRight.default, null));
41
40
  }
42
- if (value === types.PaginationItemType.MorePrev || value === types.PaginationItemType.MoreNext) {
41
+ var isMorePrev = value === "more-prev";
42
+ var isMoreNext = value === "more-next";
43
+ if (isMorePrev || isMoreNext) {
43
44
  var styled = {
44
45
  more: {
45
46
  className: "musaex-1aldg33 musaex-1oew0n0"
46
47
  }
47
48
  };
48
- var isNegative = value === types.PaginationItemType.MorePrev;
49
49
  return /*#__PURE__*/React.createElement(button.Button, {
50
50
  shape: "circular",
51
51
  variant: "text",
@@ -53,11 +53,11 @@ var Item = function Item(_ref) {
53
53
  className: styled.more.className,
54
54
  style: styled.more.style,
55
55
  onClick: function onClick() {
56
- isNegative ? subtract(5) : add(5);
56
+ isMorePrev ? subtract(5) : add(5);
57
57
  }
58
58
  }, /*#__PURE__*/React.createElement(moreHoriz.default, {
59
59
  role: "separator"
60
- }), /*#__PURE__*/React.createElement(isNegative ? keyboardDoubleArrowLeft.default : keyboardDoubleArrowRight.default, {
60
+ }), /*#__PURE__*/React.createElement(isMorePrev ? keyboardDoubleArrowLeft.default : keyboardDoubleArrowRight.default, {
61
61
  role: "button"
62
62
  }));
63
63
  }
@@ -66,7 +66,7 @@ var Item = function Item(_ref) {
66
66
  color: checked ? "primary" : "secondary",
67
67
  variant: checked ? "filled" : "text",
68
68
  onClick: function onClick() {
69
- onPageChange(value);
69
+ _onClick(value);
70
70
  }
71
71
  }, value);
72
72
  };
@@ -1,4 +1,4 @@
1
1
  import React from "react";
2
- import { type PaginationItemProps } from "./types";
3
- declare const Item: ({ value, onPageChange, add, subtract, checked, hasNext, hasPrev }: PaginationItemProps) => React.JSX.Element;
2
+ import type { PaginationItemProps } from "musae/types/pagination";
3
+ declare const Item: ({ value, onClick, add, subtract, checked, hasNext, hasPrev, }: PaginationItemProps) => React.JSX.Element;
4
4
  export default Item;
@@ -1,5 +1,4 @@
1
1
  import React, { createElement } from 'react';
2
- import { PaginationItemType } from './types.mjs';
3
2
  import { Button } from '../button/button.mjs';
4
3
  import KeyboardArrowLeft from '../icon/icons/hardware/keyboard-arrow-left.mjs';
5
4
  import KeyboardArrowRight from '../icon/icons/hardware/keyboard-arrow-right.mjs';
@@ -9,13 +8,13 @@ import KeyboardDoubleArrowRight from '../icon/icons/hardware/keyboard-double-arr
9
8
 
10
9
  var Item = function Item(_ref) {
11
10
  var value = _ref.value,
12
- onPageChange = _ref.onPageChange,
11
+ _onClick = _ref.onClick,
13
12
  add = _ref.add,
14
13
  subtract = _ref.subtract,
15
14
  checked = _ref.checked,
16
15
  hasNext = _ref.hasNext,
17
16
  hasPrev = _ref.hasPrev;
18
- if (value === PaginationItemType.Prev) {
17
+ if (value === "prev") {
19
18
  return /*#__PURE__*/React.createElement(Button, {
20
19
  onClick: function onClick() {
21
20
  return subtract();
@@ -26,7 +25,7 @@ var Item = function Item(_ref) {
26
25
  disabled: !hasPrev
27
26
  }, /*#__PURE__*/React.createElement(KeyboardArrowLeft, null));
28
27
  }
29
- if (value === PaginationItemType.Next) {
28
+ if (value === "next") {
30
29
  return /*#__PURE__*/React.createElement(Button, {
31
30
  onClick: function onClick() {
32
31
  return add();
@@ -37,13 +36,14 @@ var Item = function Item(_ref) {
37
36
  disabled: !hasNext
38
37
  }, /*#__PURE__*/React.createElement(KeyboardArrowRight, null));
39
38
  }
40
- if (value === PaginationItemType.MorePrev || value === PaginationItemType.MoreNext) {
39
+ var isMorePrev = value === "more-prev";
40
+ var isMoreNext = value === "more-next";
41
+ if (isMorePrev || isMoreNext) {
41
42
  var styled = {
42
43
  more: {
43
44
  className: "musaex-1aldg33 musaex-1oew0n0"
44
45
  }
45
46
  };
46
- var isNegative = value === PaginationItemType.MorePrev;
47
47
  return /*#__PURE__*/React.createElement(Button, {
48
48
  shape: "circular",
49
49
  variant: "text",
@@ -51,11 +51,11 @@ var Item = function Item(_ref) {
51
51
  className: styled.more.className,
52
52
  style: styled.more.style,
53
53
  onClick: function onClick() {
54
- isNegative ? subtract(5) : add(5);
54
+ isMorePrev ? subtract(5) : add(5);
55
55
  }
56
56
  }, /*#__PURE__*/React.createElement(MoreHoriz, {
57
57
  role: "separator"
58
- }), /*#__PURE__*/createElement(isNegative ? KeyboardDoubleArrowLeft : KeyboardDoubleArrowRight, {
58
+ }), /*#__PURE__*/createElement(isMorePrev ? KeyboardDoubleArrowLeft : KeyboardDoubleArrowRight, {
59
59
  role: "button"
60
60
  }));
61
61
  }
@@ -64,7 +64,7 @@ var Item = function Item(_ref) {
64
64
  color: checked ? "primary" : "secondary",
65
65
  variant: checked ? "filled" : "text",
66
66
  onClick: function onClick() {
67
- onPageChange(value);
67
+ _onClick(value);
68
68
  }
69
69
  }, value);
70
70
  };
@@ -20,18 +20,28 @@ var Pagination = function Pagination(_ref) {
20
20
  boundaries = _ref$boundaries === void 0 ? 1 : _ref$boundaries,
21
21
  _pageSize = _ref.pageSize,
22
22
  _ref$pageSizes = _ref.pageSizes,
23
- pageSizes = _ref$pageSizes === void 0 ? [10, 20, 50, 100] : _ref$pageSizes;
23
+ pageSizes = _ref$pageSizes === void 0 ? [10, 20, 50, 100] : _ref$pageSizes,
24
+ _at = _ref.at,
25
+ _onChange = _ref.onChange,
26
+ _onPageSizeChange = _ref.onPageSizeChange;
27
+ var classNames = useClassNames.useClassNames(componentToken.ComponentToken.Pagination);
28
+ var _useLocale = useLocale.useLocale(componentToken.ComponentToken.Pagination),
29
+ _useLocale2 = _slicedToArray(_useLocale, 1),
30
+ locale = _useLocale2[0];
24
31
  var _usePagiantion = hooks.usePagiantion({
25
32
  boundaries: boundaries,
26
33
  pageSize: _pageSize,
27
34
  siblings: siblings,
28
- total: total
35
+ total: total,
36
+ at: _at,
37
+ onChange: _onChange,
38
+ onPageSizeChange: _onPageSizeChange
29
39
  }),
30
40
  paginationItems = _usePagiantion.paginationItems,
31
41
  add = _usePagiantion.add,
32
42
  subtract = _usePagiantion.subtract,
33
- changePage = _usePagiantion.changePage,
34
- page = _usePagiantion.page,
43
+ onChange = _usePagiantion.onChange,
44
+ at = _usePagiantion.at,
35
45
  hasNext = _usePagiantion.hasNext,
36
46
  hasPrev = _usePagiantion.hasPrev,
37
47
  pageSize = _usePagiantion.pageSize,
@@ -44,10 +54,6 @@ var Pagination = function Pagination(_ref) {
44
54
  className: "musaex-78zum5 musaex-6s0dn4"
45
55
  }
46
56
  };
47
- var classNames = useClassNames.useClassNames(componentToken.ComponentToken.Pagination);
48
- var _useLocale = useLocale.useLocale(componentToken.ComponentToken.Pagination),
49
- _useLocale2 = _slicedToArray(_useLocale, 1),
50
- locale = _useLocale2[0];
51
57
  var sizeOptions = React.useMemo(function () {
52
58
  return Array.from(new Set(pageSizes)).map(function (size) {
53
59
  return {
@@ -69,8 +75,8 @@ var Pagination = function Pagination(_ref) {
69
75
  value: item$1,
70
76
  add: add,
71
77
  subtract: subtract,
72
- onPageChange: changePage,
73
- checked: page === item$1,
78
+ onClick: onChange,
79
+ checked: at === item$1,
74
80
  hasNext: hasNext,
75
81
  hasPrev: hasPrev
76
82
  }));
@@ -1,4 +1,4 @@
1
1
  import React from "react";
2
- import type { PagiantionProps } from "./types";
3
- declare const Pagination: ({ total, siblings, boundaries, pageSize: _pageSize, pageSizes, }: PagiantionProps) => React.JSX.Element;
2
+ import type { PagiantionProps } from "musae/types/pagination";
3
+ declare const Pagination: ({ total, siblings, boundaries, pageSize: _pageSize, pageSizes, at: _at, onChange: _onChange, onPageSizeChange: _onPageSizeChange, }: PagiantionProps) => React.JSX.Element;
4
4
  export default Pagination;
@@ -18,18 +18,28 @@ var Pagination = function Pagination(_ref) {
18
18
  boundaries = _ref$boundaries === void 0 ? 1 : _ref$boundaries,
19
19
  _pageSize = _ref.pageSize,
20
20
  _ref$pageSizes = _ref.pageSizes,
21
- pageSizes = _ref$pageSizes === void 0 ? [10, 20, 50, 100] : _ref$pageSizes;
21
+ pageSizes = _ref$pageSizes === void 0 ? [10, 20, 50, 100] : _ref$pageSizes,
22
+ _at = _ref.at,
23
+ _onChange = _ref.onChange,
24
+ _onPageSizeChange = _ref.onPageSizeChange;
25
+ var classNames = useClassNames(ComponentToken.Pagination);
26
+ var _useLocale = useLocale(ComponentToken.Pagination),
27
+ _useLocale2 = _slicedToArray(_useLocale, 1),
28
+ locale = _useLocale2[0];
22
29
  var _usePagiantion = usePagiantion({
23
30
  boundaries: boundaries,
24
31
  pageSize: _pageSize,
25
32
  siblings: siblings,
26
- total: total
33
+ total: total,
34
+ at: _at,
35
+ onChange: _onChange,
36
+ onPageSizeChange: _onPageSizeChange
27
37
  }),
28
38
  paginationItems = _usePagiantion.paginationItems,
29
39
  add = _usePagiantion.add,
30
40
  subtract = _usePagiantion.subtract,
31
- changePage = _usePagiantion.changePage,
32
- page = _usePagiantion.page,
41
+ onChange = _usePagiantion.onChange,
42
+ at = _usePagiantion.at,
33
43
  hasNext = _usePagiantion.hasNext,
34
44
  hasPrev = _usePagiantion.hasPrev,
35
45
  pageSize = _usePagiantion.pageSize,
@@ -42,10 +52,6 @@ var Pagination = function Pagination(_ref) {
42
52
  className: "musaex-78zum5 musaex-6s0dn4"
43
53
  }
44
54
  };
45
- var classNames = useClassNames(ComponentToken.Pagination);
46
- var _useLocale = useLocale(ComponentToken.Pagination),
47
- _useLocale2 = _slicedToArray(_useLocale, 1),
48
- locale = _useLocale2[0];
49
55
  var sizeOptions = useMemo(function () {
50
56
  return Array.from(new Set(pageSizes)).map(function (size) {
51
57
  return {
@@ -67,8 +73,8 @@ var Pagination = function Pagination(_ref) {
67
73
  value: item,
68
74
  add: add,
69
75
  subtract: subtract,
70
- onPageChange: changePage,
71
- checked: page === item,
76
+ onClick: onChange,
77
+ checked: at === item,
72
78
  hasNext: hasNext,
73
79
  hasPrev: hasPrev
74
80
  }));
package/dist/index.cjs CHANGED
@@ -1,4 +1,4 @@
1
- import "musae/styles.css";
1
+ require("musae/styles")
2
2
  var index = require('./components/avatar/index.cjs');
3
3
  var index$1 = require('./components/radio/index.cjs');
4
4
  var index$2 = require('./components/checkbox/index.cjs');
package/dist/index.mjs CHANGED
@@ -1,4 +1,4 @@
1
- import "musae/styles.css";
1
+ import "musae/styles";
2
2
  export { Avatar } from './components/avatar/index.mjs';
3
3
  export { Radio } from './components/radio/index.mjs';
4
4
  export { Checkbox } from './components/checkbox/index.mjs';
@@ -4,12 +4,7 @@ type UsedCounter = ReturnType<typeof useCounter>;
4
4
  * @description
5
5
  * pagiantion item type
6
6
  */
7
- export declare enum PaginationItemType {
8
- Prev = "prev",
9
- Next = "next",
10
- MorePrev = "more-prev",
11
- MoreNext = "more-next"
12
- }
7
+ export type PaginationItemType = "prev" | "next" | "more-prev" | "more-next";
13
8
  /**
14
9
  * @author murukal
15
10
  *
@@ -47,8 +42,24 @@ export type PagiantionProps = {
47
42
  * @default [10, 20, 50, 100]
48
43
  */
49
44
  pageSizes?: number[];
45
+ /**
46
+ * @description
47
+ * current page at
48
+ * @default 1
49
+ */
50
+ at?: number;
51
+ /**
52
+ * @description
53
+ * change handler when current page `at` changed
54
+ */
55
+ onChange?: (at: number) => void;
56
+ /**
57
+ * @description
58
+ * change handler when `pageSize` changed
59
+ */
60
+ onPageSizeChange?: (pageSize: number) => void;
50
61
  };
51
- export type PaginationItems = [PaginationItemType.Prev, ...(PaginationItemType | number)[], PaginationItemType.Next];
62
+ export type PaginationItems = (PaginationItemType | number)[];
52
63
  /**
53
64
  * @description
54
65
  * pagination item props
@@ -71,9 +82,9 @@ export type PaginationItemProps = {
71
82
  subtract: UsedCounter[1]["subtract"];
72
83
  /**
73
84
  * @description
74
- * change
85
+ * click handler
75
86
  */
76
- onPageChange: (page: number) => void;
87
+ onClick: (page: number) => void;
77
88
  /**
78
89
  * @description
79
90
  * checked
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "musae",
3
- "version": "0.3.1",
3
+ "version": "0.3.2",
4
4
  "description": "musae-ui",
5
5
  "author": "tutu@fantufantu.com",
6
6
  "license": "MIT",
@@ -24,7 +24,7 @@
24
24
  "import": "./dist/index.mjs",
25
25
  "default": "./dist/index.mjs"
26
26
  },
27
- "./styles.css": "./dist/styles.css",
27
+ "./styles": "./dist/styles.css",
28
28
  "./locales": {
29
29
  "types": "./dist/locale/locales/index.d.ts",
30
30
  "require": "./dist/locale/locales/index.cjs",
@@ -1,11 +0,0 @@
1
- /**
2
- * @description
3
- * pagiantion item type
4
- */
5
- exports.PaginationItemType = void 0;
6
- (function (PaginationItemType) {
7
- PaginationItemType["Prev"] = "prev";
8
- PaginationItemType["Next"] = "next";
9
- PaginationItemType["MorePrev"] = "more-prev";
10
- PaginationItemType["MoreNext"] = "more-next";
11
- })(exports.PaginationItemType || (exports.PaginationItemType = {}));
@@ -1,13 +0,0 @@
1
- /**
2
- * @description
3
- * pagiantion item type
4
- */
5
- var PaginationItemType;
6
- (function (PaginationItemType) {
7
- PaginationItemType["Prev"] = "prev";
8
- PaginationItemType["Next"] = "next";
9
- PaginationItemType["MorePrev"] = "more-prev";
10
- PaginationItemType["MoreNext"] = "more-next";
11
- })(PaginationItemType || (PaginationItemType = {}));
12
-
13
- export { PaginationItemType };