@sikt/sds-pagination 0.1.0 → 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.css +1 -1
- package/dist/index.css.map +1 -1
- package/dist/index.d.ts +4 -4
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/package.json +6 -3
package/dist/index.css
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
.sds-
|
|
1
|
+
.sds-pagination{--pagination-background-color:#0000;--pagination-border-color:var(--sds-color-surface-action)}.sds-pagination__list-item{align-items:center;display:inline-flex;justify-content:center;margin-right:var(--sds-size-base-s)}.sds-pagination__list-item:last-of-type{margin-right:0}.sds-pagination__button{align-items:center;background-color:var(--pagination-background-color);border:var(--sds-border-size-regular) solid var(--pagination-border-color);border-radius:var(--sds-border-radius-full);color:var(--sds-color-text-default);cursor:pointer;display:inline-flex;font-size:var(--sds-size-text-s2);height:var(--sds-size-text-l);justify-content:center;line-height:var(--sds-size-text-m);padding:0;text-align:center;width:var(--sds-size-text-l)}.sds-pagination__button:hover{--pagination-border-color:var(--sds-color-surface-action-hover)}.sds-pagination__button:focus-visible{--pagination-border-color:#0000;outline:var(--sds-size-base-xxs) dashed var(--sds-color-text-info)}.sds-pagination__button:active{--pagination-border-color:var(--sds-color-surface-action-active)}.sds-pagination__button[aria-current]{--pagination-background-color:var(--sds-color-surface-action);color:var(--sds-color-text-onsurface-action)}.sds-pagination__button--spacer,.sds-pagination__button[aria-current],.sds-pagination__button[disabled]{cursor:inherit}.sds-pagination__button--spacer:active,.sds-pagination__button--spacer:focus-visible,.sds-pagination__button--spacer:hover,.sds-pagination__button[aria-current]:active,.sds-pagination__button[aria-current]:focus-visible,.sds-pagination__button[aria-current]:hover,.sds-pagination__button[disabled]:active,.sds-pagination__button[disabled]:focus-visible,.sds-pagination__button[disabled]:hover{--pagination-border-color:var(--sds-color-surface-action)}
|
|
2
2
|
/*# sourceMappingURL=index.css.map */
|
package/dist/index.css.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["
|
|
1
|
+
{"version":3,"sources":["pagination.pcss"],"names":[],"mappings":"AAAA,gBACE,mCAA0C,CAC1C,yDA6DF,CA3DE,2BACE,kBAAmB,CACnB,mBAAoB,CACpB,sBAAuB,CACvB,mCAKF,CAHE,wCACE,cACF,CAGF,wBACE,kBAAmB,CAGnB,mDAAoD,CACpD,0EAA2E,CAC3E,2CAA4C,CAC5C,mCAAoC,CACpC,cAAe,CANf,mBAAoB,CAOpB,iCAAkC,CAIlC,6BAA8B,CAV9B,sBAAuB,CAOvB,kCAAmC,CAInC,SAAU,CAHV,iBAAkB,CAClB,4BAmCF,CA/BE,8BACE,+DACF,CAEA,sCACE,+BAAsC,CAEtC,kEACF,CAEA,+BACE,gEACF,CAEA,sCACE,6DAA8D,CAE9D,4CACF,CAEA,wGAGE,cAOF,CALE,yYAGE,yDACF","file":"index.css","sourcesContent":[".sds-pagination {\n --pagination-background-color: transparent;\n --pagination-border-color: var(--sds-color-surface-action);\n\n &__list-item {\n align-items: center;\n display: inline-flex;\n justify-content: center;\n margin-right: var(--sds-size-base-s);\n\n &:last-of-type {\n margin-right: 0;\n }\n }\n\n &__button {\n align-items: center;\n display: inline-flex;\n justify-content: center;\n background-color: var(--pagination-background-color);\n border: var(--sds-border-size-regular) solid var(--pagination-border-color);\n border-radius: var(--sds-border-radius-full);\n color: var(--sds-color-text-default);\n cursor: pointer;\n font-size: var(--sds-size-text-s2);\n line-height: var(--sds-size-text-m);\n text-align: center;\n width: var(--sds-size-text-l);\n height: var(--sds-size-text-l);\n padding: 0;\n\n &:hover {\n --pagination-border-color: var(--sds-color-surface-action-hover);\n }\n\n &:focus-visible {\n --pagination-border-color: transparent;\n\n outline: var(--sds-size-base-xxs) dashed var(--sds-color-text-info);\n }\n\n &:active {\n --pagination-border-color: var(--sds-color-surface-action-active);\n }\n\n &[aria-current] {\n --pagination-background-color: var(--sds-color-surface-action);\n\n color: var(--sds-color-text-onsurface-action);\n }\n\n &[aria-current],\n &[disabled],\n &--spacer {\n cursor: inherit;\n\n &:active,\n &:hover,\n &:focus-visible {\n --pagination-border-color: var(--sds-color-surface-action);\n }\n }\n }\n}\n"]}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { HTMLAttributes } from "react";
|
|
3
3
|
interface PaginationProps extends HTMLAttributes<HTMLElement> {
|
|
4
|
-
|
|
5
|
-
ariaLabel: string;
|
|
4
|
+
"aria-label": string;
|
|
6
5
|
ariaLabelPrevious?: string;
|
|
7
6
|
ariaLabelNext?: string;
|
|
8
7
|
ariaLabelItem?: string;
|
|
9
8
|
count: number;
|
|
10
9
|
currentIndex: number;
|
|
11
|
-
/** Total limit of elements, this includes previous/next/first/last. */
|
|
10
|
+
/** Total limit of elements, this includes previous/next/first/last. Minimum is 7 (previous/next/first/last/current/) */
|
|
12
11
|
limit?: number;
|
|
13
12
|
handleClick: (index: number) => void;
|
|
13
|
+
className?: string;
|
|
14
14
|
}
|
|
15
|
-
declare const Pagination: ({ ariaLabel, ariaLabelNext, ariaLabelPrevious, ariaLabelItem, count, currentIndex, limit, handleClick, className, ...rest }: PaginationProps) => JSX.Element;
|
|
15
|
+
declare const Pagination: ({ "aria-label": ariaLabel, ariaLabelNext, ariaLabelPrevious, ariaLabelItem, count, currentIndex, limit, handleClick, className, ...rest }: PaginationProps) => JSX.Element;
|
|
16
16
|
export type { PaginationProps };
|
|
17
17
|
export { Pagination };
|
package/dist/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{jsx as C,jsxs as a}from"react/jsx-runtime";import l,{clsx as i}from"clsx";import"react";const s=({icon:a,className:i,...s})=>C("svg",{className:l("sds-icon",i),"aria-hidden":"true",...s,children:C("use",{href:`data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3C!DOCTYPE%20svg%20PUBLIC%20%22-%2F%2FW3C%2F%2FDTD%20SVG%201.1%2F%2FEN%22%20%22http%3A%2F%2Fwww.w3.org%2FGraphics%2FSVG%2F1.1%2FDTD%2Fsvg11.dtd%22%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20xmlns%3Axlink%3D%22http%3A%2F%2Fwww.w3.org%2F1999%2Fxlink%22%3E%3Cdefs%2F%3E%3Csymbol%20id%3D%22arrow-down%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M205.7%2C149.7l-72%2C72a8.2%2C8.2%2C0%2C0%2C1-11.4%2C0l-72-72a8.1%2C8.1%2C0%2C0%2C1%2C11.4-11.4L120%2C196.7V40a8%2C8%2C0%2C0%2C1%2C16%2C0V196.7l58.3-58.4a8.1%2C8.1%2C0%2C0%2C1%2C11.4%2C11.4Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22arrow-left%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M224%2C128a8%2C8%2C0%2C0%2C1-8%2C8H59.3l58.4%2C58.3a8.1%2C8.1%2C0%2C0%2C1%2C0%2C11.4%2C8.2%2C8.2%2C0%2C0%2C1-11.4%2C0l-72-72a8.1%2C8.1%2C0%2C0%2C1%2C0-11.4l72-72a8.1%2C8.1%2C0%2C0%2C1%2C11.4%2C11.4L59.3%2C120H216A8%2C8%2C0%2C0%2C1%2C224%2C128Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22arrow-right%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M221.7%2C133.7l-72%2C72a8.2%2C8.2%2C0%2C0%2C1-11.4%2C0%2C8.1%2C8.1%2C0%2C0%2C1%2C0-11.4L196.7%2C136H40a8%2C8%2C0%2C0%2C1%2C0-16H196.7L138.3%2C61.7a8.1%2C8.1%2C0%2C0%2C1%2C11.4-11.4l72%2C72A8.1%2C8.1%2C0%2C0%2C1%2C221.7%2C133.7Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22arrow-square-out%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M224%2C100a8%2C8%2C0%2C0%2C1-16%2C0V59.3l-58.4%2C58.4A8%2C8%2C0%2C0%2C1%2C144%2C120a8.3%2C8.3%2C0%2C0%2C1-5.7-2.3%2C8%2C8%2C0%2C0%2C1%2C0-11.3L196.7%2C48H156a8%2C8%2C0%2C0%2C1%2C0-16h60a8%2C8%2C0%2C0%2C1%2C8%2C8Zm-40%2C36a8%2C8%2C0%2C0%2C0-8%2C8v64H48V80h64a8%2C8%2C0%2C0%2C0%2C0-16H48A16%2C16%2C0%2C0%2C0%2C32%2C80V208a16%2C16%2C0%2C0%2C0%2C16%2C16H176a16%2C16%2C0%2C0%2C0%2C16-16V144A8%2C8%2C0%2C0%2C0%2C184%2C136Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22arrow-up%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M205.7%2C117.7a8.2%2C8.2%2C0%2C0%2C1-11.4%2C0L136%2C59.3V216a8%2C8%2C0%2C0%2C1-16%2C0V59.3L61.7%2C117.7a8.1%2C8.1%2C0%2C0%2C1-11.4-11.4l72-72a8.1%2C8.1%2C0%2C0%2C1%2C11.4%2C0l72%2C72A8.1%2C8.1%2C0%2C0%2C1%2C205.7%2C117.7Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22caret-down%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M128%2C184a8.5%2C8.5%2C0%2C0%2C1-5.7-2.3l-80-80A8.1%2C8.1%2C0%2C0%2C1%2C53.7%2C90.3L128%2C164.7l74.3-74.4a8.1%2C8.1%2C0%2C0%2C1%2C11.4%2C11.4l-80%2C80A8.5%2C8.5%2C0%2C0%2C1%2C128%2C184Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22caret-left%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M160%2C216a8.5%2C8.5%2C0%2C0%2C1-5.7-2.3l-80-80a8.1%2C8.1%2C0%2C0%2C1%2C0-11.4l80-80a8.1%2C8.1%2C0%2C0%2C1%2C11.4%2C11.4L91.3%2C128l74.4%2C74.3a8.1%2C8.1%2C0%2C0%2C1%2C0%2C11.4A8.5%2C8.5%2C0%2C0%2C1%2C160%2C216Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22caret-right%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M96%2C216a8.5%2C8.5%2C0%2C0%2C1-5.7-2.3%2C8.1%2C8.1%2C0%2C0%2C1%2C0-11.4L164.7%2C128%2C90.3%2C53.7a8.1%2C8.1%2C0%2C0%2C1%2C11.4-11.4l80%2C80a8.1%2C8.1%2C0%2C0%2C1%2C0%2C11.4l-80%2C80A8.5%2C8.5%2C0%2C0%2C1%2C96%2C216Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22caret-up%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M208%2C168a8.5%2C8.5%2C0%2C0%2C1-5.7-2.3L128%2C91.3%2C53.7%2C165.7a8.1%2C8.1%2C0%2C0%2C1-11.4-11.4l80-80a8.1%2C8.1%2C0%2C0%2C1%2C11.4%2C0l80%2C80a8.1%2C8.1%2C0%2C0%2C1%2C0%2C11.4A8.5%2C8.5%2C0%2C0%2C1%2C208%2C168Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22check%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M104%2C192a8.5%2C8.5%2C0%2C0%2C1-5.7-2.3l-56-56a8.1%2C8.1%2C0%2C0%2C1%2C11.4-11.4L104%2C172.7%2C210.3%2C66.3a8.1%2C8.1%2C0%2C0%2C1%2C11.4%2C11.4l-112%2C112A8.5%2C8.5%2C0%2C0%2C1%2C104%2C192Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22copy-simple%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M224%2C40V184a8%2C8%2C0%2C0%2C1-16%2C0V48H72a8%2C8%2C0%2C0%2C1%2C0-16H216A8%2C8%2C0%2C0%2C1%2C224%2C40ZM192%2C72V216a8%2C8%2C0%2C0%2C1-8%2C8H40a8%2C8%2C0%2C0%2C1-8-8V72a8%2C8%2C0%2C0%2C1%2C8-8H184A8%2C8%2C0%2C0%2C1%2C192%2C72Zm-16%2C8H48V208H176Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22download-simple%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M80.3%2C115.7a8%2C8%2C0%2C0%2C1%2C11.4-11.3L120%2C132.7V40a8%2C8%2C0%2C0%2C1%2C16%2C0v92.7l28.3-28.3a8%2C8%2C0%2C0%2C1%2C11.4%2C11.3l-42%2C42a8.2%2C8.2%2C0%2C0%2C1-11.4%2C0ZM216%2C144a8%2C8%2C0%2C0%2C0-8%2C8v56H48V152a8%2C8%2C0%2C0%2C0-16%2C0v56a16%2C16%2C0%2C0%2C0%2C16%2C16H208a16%2C16%2C0%2C0%2C0%2C16-16V152A8%2C8%2C0%2C0%2C0%2C216%2C144Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22envelope-simple%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M224%2C48H32a8%2C8%2C0%2C0%2C0-8%2C8V192a16%2C16%2C0%2C0%2C0%2C16%2C16H216a16%2C16%2C0%2C0%2C0%2C16-16V56A8%2C8%2C0%2C0%2C0%2C224%2C48ZM203.4%2C64%2C128%2C133.1%2C52.6%2C64ZM216%2C192H40V74.2l82.6%2C75.7a8%2C8%2C0%2C0%2C0%2C10.8%2C0L216%2C74.2V192Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22faders%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M136%2C120v96a8%2C8%2C0%2C0%2C1-16%2C0V120a8%2C8%2C0%2C0%2C1%2C16%2C0Zm64%2C72a8%2C8%2C0%2C0%2C0-8%2C8v16a8%2C8%2C0%2C0%2C0%2C16%2C0V200A8%2C8%2C0%2C0%2C0%2C200%2C192Zm24-32H208V40a8%2C8%2C0%2C0%2C0-8-8h0a8%2C8%2C0%2C0%2C0-8%2C8V160H176a8%2C8%2C0%2C0%2C0%2C0%2C16h48a8%2C8%2C0%2C0%2C0%2C0-16ZM56%2C160h0a8%2C8%2C0%2C0%2C0-8%2C8v48a8%2C8%2C0%2C0%2C0%2C8%2C8h0a8%2C8%2C0%2C0%2C0%2C8-8V168A8%2C8%2C0%2C0%2C0%2C56%2C160Zm24-32H64V40a8%2C8%2C0%2C0%2C0-16%2C0v88H32a8%2C8%2C0%2C0%2C0%2C0%2C16H80a8%2C8%2C0%2C0%2C0%2C0-16Zm72-48H136V40a8%2C8%2C0%2C0%2C0-16%2C0V80H104a8%2C8%2C0%2C0%2C0%2C0%2C16h48a8%2C8%2C0%2C0%2C0%2C0-16Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22info%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M128%2C24A104%2C104%2C0%2C1%2C0%2C232%2C128%2C104.1%2C104.1%2C0%2C0%2C0%2C128%2C24Zm0%2C192a88%2C88%2C0%2C1%2C1%2C88-88A88.1%2C88.1%2C0%2C0%2C1%2C128%2C216Zm16-40a8%2C8%2C0%2C0%2C1-8%2C8h-8a8%2C8%2C0%2C0%2C1-8-8V128a8%2C8%2C0%2C0%2C1%2C0-16h8a8%2C8%2C0%2C0%2C1%2C8%2C8v48A8%2C8%2C0%2C0%2C1%2C144%2C176ZM114%2C84a12%2C12%2C0%2C1%2C1%2C12%2C12A12%2C12%2C0%2C0%2C1%2C114%2C84Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22magnifying-glass%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M229.7%2C218.3l-43.3-43.2a92.2%2C92.2%2C0%2C1%2C0-11.3%2C11.3l43.2%2C43.3a8.2%2C8.2%2C0%2C0%2C0%2C11.4%2C0A8.1%2C8.1%2C0%2C0%2C0%2C229.7%2C218.3ZM40%2C116a76%2C76%2C0%2C1%2C1%2C76%2C76A76.1%2C76.1%2C0%2C0%2C1%2C40%2C116Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22map-pin%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M128.1%2C64a40%2C40%2C0%2C1%2C0%2C40%2C40A40.1%2C40.1%2C0%2C0%2C0%2C128.1%2C64Zm0%2C64a24%2C24%2C0%2C1%2C1%2C24-24A24.1%2C24.1%2C0%2C0%2C1%2C128.1%2C128Zm0-112a88.1%2C88.1%2C0%2C0%2C0-88%2C88c0%2C31.4%2C14.5%2C64.7%2C42%2C96.2a259.4%2C259.4%2C0%2C0%2C0%2C41.4%2C38.4%2C8.3%2C8.3%2C0%2C0%2C0%2C9.2%2C0%2C257.6%2C257.6%2C0%2C0%2C0%2C41.5-38.4c27.4-31.5%2C41.9-64.8%2C41.9-96.2A88.1%2C88.1%2C0%2C0%2C0%2C128.1%2C16Zm0%2C206c-16.5-13-72-60.8-72-118a72%2C72%2C0%2C0%2C1%2C144%2C0C200.1%2C161.2%2C144.6%2C209%2C128.1%2C222Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22map-trifold%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M229%2C49.7a7.9%2C7.9%2C0%2C0%2C0-6.8-1.5L161%2C63.5%2C99.7%2C32.8h-.1l-.8-.3h-.2l-.7-.2h-.3l-.7-.2H94.2l-64%2C16A8%2C8%2C0%2C0%2C0%2C24.1%2C56V200a7.8%2C7.8%2C0%2C0%2C0%2C3.1%2C6.3%2C7.9%2C7.9%2C0%2C0%2C0%2C4.9%2C1.7l2-.2%2C61.1-15.3%2C61.3%2C30.7h.1l.7.3h.1l.8.3h3.9l64-16a8%2C8%2C0%2C0%2C0%2C6-7.8V56A7.8%2C7.8%2C0%2C0%2C0%2C229%2C49.7ZM40.1%2C62.2l48-12V177.8l-48%2C12Zm112%2C140.9-48-24V52.9l48%2C24Zm64-9.3-48%2C12V78.2l48-12Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22minus-circle%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M128%2C24A104%2C104%2C0%2C1%2C0%2C232%2C128%2C104.1%2C104.1%2C0%2C0%2C0%2C128%2C24Zm0%2C192a88%2C88%2C0%2C1%2C1%2C88-88A88.1%2C88.1%2C0%2C0%2C1%2C128%2C216Zm48-88a8%2C8%2C0%2C0%2C1-8%2C8H88a8%2C8%2C0%2C0%2C1%2C0-16h80A8%2C8%2C0%2C0%2C1%2C176%2C128Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22minus%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M216%2C136H40a8%2C8%2C0%2C0%2C1%2C0-16H216a8%2C8%2C0%2C0%2C1%2C0%2C16Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22paperclip%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M209.7%2C122.3a8.1%2C8.1%2C0%2C0%2C1%2C0%2C11.4l-82.1%2C81.9a56%2C56%2C0%2C0%2C1-79.2-79.2L147.7%2C35.8a40%2C40%2C0%2C1%2C1%2C56.6%2C56.5L105%2C192.9A23.8%2C23.8%2C0%2C0%2C1%2C88%2C200a24%2C24%2C0%2C0%2C1-17-41l83.3-84.6a8%2C8%2C0%2C1%2C1%2C11.4%2C11.2L82.4%2C170.3A8%2C8%2C0%2C0%2C0%2C80%2C176a8.1%2C8.1%2C0%2C0%2C0%2C2.3%2C5.7A8.3%2C8.3%2C0%2C0%2C0%2C88%2C184a8.1%2C8.1%2C0%2C0%2C0%2C5.7-2.3L192.9%2C81A23.8%2C23.8%2C0%2C0%2C0%2C200%2C64a24%2C24%2C0%2C0%2C0-41-17L59.8%2C147.7a40%2C40%2C0%2C1%2C0%2C56.5%2C56.6l82-82A8.1%2C8.1%2C0%2C0%2C1%2C209.7%2C122.3Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22phone%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M176%2C224C96.6%2C224%2C32%2C159.4%2C32%2C80A56.2%2C56.2%2C0%2C0%2C1%2C80.9%2C24.4%2C16.3%2C16.3%2C0%2C0%2C1%2C97.6%2C34l20.1%2C46.9A15.9%2C15.9%2C0%2C0%2C1%2C116.3%2C96L99.7%2C121.4h0a76.5%2C76.5%2C0%2C0%2C0%2C35.2%2C35L160%2C139.7a15.6%2C15.6%2C0%2C0%2C1%2C15.1-1.3l46.9%2C20a16.3%2C16.3%2C0%2C0%2C1%2C9.6%2C16.7A56.2%2C56.2%2C0%2C0%2C1%2C176%2C224ZM82.9%2C40.3A40%2C40%2C0%2C0%2C0%2C48%2C80%2C128.1%2C128.1%2C0%2C0%2C0%2C176%2C208a40%2C40%2C0%2C0%2C0%2C39.7-34.9l-46.9-20-25%2C16.7a16%2C16%2C0%2C0%2C1-15.7%2C1.1%2C92.5%2C92.5%2C0%2C0%2C1-42.8-42.6%2C16%2C16%2C0%2C0%2C1%2C1-15.7L103%2C87.2ZM135%2C156.5Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22plus-circle%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M128%2C24A104%2C104%2C0%2C1%2C0%2C232%2C128%2C104.1%2C104.1%2C0%2C0%2C0%2C128%2C24Zm0%2C192a88%2C88%2C0%2C1%2C1%2C88-88A88.1%2C88.1%2C0%2C0%2C1%2C128%2C216Zm48-88a8%2C8%2C0%2C0%2C1-8%2C8H136v32a8%2C8%2C0%2C0%2C1-16%2C0V136H88a8%2C8%2C0%2C0%2C1%2C0-16h32V88a8%2C8%2C0%2C0%2C1%2C16%2C0v32h32A8%2C8%2C0%2C0%2C1%2C176%2C128Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22plus%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M224%2C128a8%2C8%2C0%2C0%2C1-8%2C8H136v80a8%2C8%2C0%2C0%2C1-16%2C0V136H40a8%2C8%2C0%2C0%2C1%2C0-16h80V40a8%2C8%2C0%2C0%2C1%2C16%2C0v80h80A8%2C8%2C0%2C0%2C1%2C224%2C128Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22sign-in%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M141.7%2C133.7l-42%2C42A8.3%2C8.3%2C0%2C0%2C1%2C94%2C178a8%2C8%2C0%2C0%2C1-5.6-13.7L116.7%2C136H24a8%2C8%2C0%2C0%2C1%2C0-16h92.7L88.4%2C91.7A8%2C8%2C0%2C0%2C1%2C99.7%2C80.3l42%2C42A8.1%2C8.1%2C0%2C0%2C1%2C141.7%2C133.7ZM192%2C32H136a8%2C8%2C0%2C0%2C0%2C0%2C16h56V208H136a8%2C8%2C0%2C0%2C0%2C0%2C16h56a16%2C16%2C0%2C0%2C0%2C16-16V48A16%2C16%2C0%2C0%2C0%2C192%2C32Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22sign-out%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M221.7%2C133.7l-42%2C42A8.3%2C8.3%2C0%2C0%2C1%2C174%2C178a8%2C8%2C0%2C0%2C1-5.6-13.7L196.7%2C136H104a8%2C8%2C0%2C0%2C1%2C0-16h92.7L168.4%2C91.7a8%2C8%2C0%2C0%2C1%2C11.3-11.4l42%2C42A8.1%2C8.1%2C0%2C0%2C1%2C221.7%2C133.7ZM104%2C208H48V48h56a8%2C8%2C0%2C0%2C0%2C0-16H48A16%2C16%2C0%2C0%2C0%2C32%2C48V208a16%2C16%2C0%2C0%2C0%2C16%2C16h56a8%2C8%2C0%2C0%2C0%2C0-16Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22star%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M187.3%2C232a16.1%2C16.1%2C0%2C0%2C1-8.7-2.6l-50.5-31.9h-.2L81%2C227.2a18%2C18%2C0%2C0%2C1-20.1-.6%2C18.6%2C18.6%2C0%2C0%2C1-7-19.6l13.5-53.1a.8.8%2C0%2C0%2C0-.2-.8L22%2C115.5a16.8%2C16.8%2C0%2C0%2C1-5.2-18.1A16.4%2C16.4%2C0%2C0%2C1%2C31.4%2C86l59-3.8a.5.5%2C0%2C0%2C0%2C.4-.3l22-55.5a16.3%2C16.3%2C0%2C0%2C1%2C30.4%2C0l22%2C55.5a.5.5%2C0%2C0%2C0%2C.4.3l59%2C3.8a16.4%2C16.4%2C0%2C0%2C1%2C14.6%2C11.4%2C16.8%2C16.8%2C0%2C0%2C1-5.2%2C18.1l-45.2%2C37.6a.8.8%2C0%2C0%2C0-.2.8l14.5%2C57.3a16.6%2C16.6%2C0%2C0%2C1-6.3%2C17.7A16.8%2C16.8%2C0%2C0%2C1%2C187.3%2C232ZM128%2C181.5a16%2C16%2C0%2C0%2C1%2C8.7%2C2.5h0l50.4%2C31.9h.2a.7.7%2C0%2C0%2C0%2C.3-.3c.1-.1.1-.2%2C0-.6l-14.5-57.3a16.8%2C16.8%2C0%2C0%2C1%2C5.4-17l45.3-37.6c.1-.1.3-.3.1-.8s-.2-.4-.3-.4l-59.1-3.8a16.4%2C16.4%2C0%2C0%2C1-14.1-10.4L128.3%2C32.3c-.1-.3-.2-.3-.3-.3s-.2%2C0-.3.3L105.6%2C87.8A16.4%2C16.4%2C0%2C0%2C1%2C91.5%2C98.2L32.4%2C102c-.1%2C0-.2%2C0-.3.4s0%2C.7.1.8l45.3%2C37.6a16.8%2C16.8%2C0%2C0%2C1%2C5.4%2C17L69.4%2C211a2.5%2C2.5%2C0%2C0%2C0%2C.9%2C2.6%2C1.6%2C1.6%2C0%2C0%2C0%2C2.1.1L119.3%2C184A16%2C16%2C0%2C0%2C1%2C128%2C181.5Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22thumbs-down%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M237.7%2C157l-12-96a24.1%2C24.1%2C0%2C0%2C0-23.8-21H32A16%2C16%2C0%2C0%2C0%2C16%2C56v88a16%2C16%2C0%2C0%2C0%2C16%2C16H75l37.8%2C75.6A8.2%2C8.2%2C0%2C0%2C0%2C120%2C240a40.1%2C40.1%2C0%2C0%2C0%2C40-40V184h53.9a23.9%2C23.9%2C0%2C0%2C0%2C23.8-27ZM72%2C144H32V56H72Zm147.9%2C21.3a8.2%2C8.2%2C0%2C0%2C1-6%2C2.7H152a8%2C8%2C0%2C0%2C0-8%2C8v24a24%2C24%2C0%2C0%2C1-19.3%2C23.5L88%2C150.1V56H201.9a8%2C8%2C0%2C0%2C1%2C7.9%2C7l12%2C96A8.1%2C8.1%2C0%2C0%2C1%2C219.9%2C165.3Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22thumbs-up%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M231.9%2C80.1a24.3%2C24.3%2C0%2C0%2C0-18-8.1H160V56a40.1%2C40.1%2C0%2C0%2C0-40-40%2C8.2%2C8.2%2C0%2C0%2C0-7.2%2C4.4L75%2C96H32a16%2C16%2C0%2C0%2C0-16%2C16v88a16%2C16%2C0%2C0%2C0%2C16%2C16H201.9a24.1%2C24.1%2C0%2C0%2C0%2C23.8-21l12-96A24.5%2C24.5%2C0%2C0%2C0%2C231.9%2C80.1ZM32%2C112H72v88H32ZM221.8%2C97l-12%2C96a8%2C8%2C0%2C0%2C1-7.9%2C7H88V105.9l36.7-73.4A24%2C24%2C0%2C0%2C1%2C144%2C56V80a8%2C8%2C0%2C0%2C0%2C8%2C8h61.9a8.2%2C8.2%2C0%2C0%2C1%2C6%2C2.7A8.1%2C8.1%2C0%2C0%2C1%2C221.8%2C97Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22trash-simple%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M216%2C48H40a8%2C8%2C0%2C0%2C0%2C0%2C16h8V208a16%2C16%2C0%2C0%2C0%2C16%2C16H192a16%2C16%2C0%2C0%2C0%2C16-16V64h8a8%2C8%2C0%2C0%2C0%2C0-16ZM192%2C208H64V64H192ZM80%2C24a8%2C8%2C0%2C0%2C1%2C8-8h80a8%2C8%2C0%2C0%2C1%2C0%2C16H88A8%2C8%2C0%2C0%2C1%2C80%2C24Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22upload-simple%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M80.3%2C87.6a8%2C8%2C0%2C0%2C1%2C0-11.3l42-42a8.1%2C8.1%2C0%2C0%2C1%2C11.4%2C0l42%2C42a8%2C8%2C0%2C0%2C1%2C0%2C11.3%2C8%2C8%2C0%2C0%2C1-11.4%2C0L136%2C59.3V152a8%2C8%2C0%2C0%2C1-16%2C0V59.3L91.7%2C87.6A8%2C8%2C0%2C0%2C1%2C80.3%2C87.6ZM216%2C144a8%2C8%2C0%2C0%2C0-8%2C8v56H48V152a8%2C8%2C0%2C0%2C0-16%2C0v56a16%2C16%2C0%2C0%2C0%2C16%2C16H208a16%2C16%2C0%2C0%2C0%2C16-16V152A8%2C8%2C0%2C0%2C0%2C216%2C144Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22user%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M231.9%2C212a120.7%2C120.7%2C0%2C0%2C0-67.1-54.2%2C72%2C72%2C0%2C1%2C0-73.6%2C0A120.7%2C120.7%2C0%2C0%2C0%2C24.1%2C212a8%2C8%2C0%2C1%2C0%2C13.8%2C8%2C104.1%2C104.1%2C0%2C0%2C1%2C180.2%2C0%2C8%2C8%2C0%2C1%2C0%2C13.8-8ZM72%2C96a56%2C56%2C0%2C1%2C1%2C56%2C56A56%2C56%2C0%2C0%2C1%2C72%2C96Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22users%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M121.2%2C157.9a60%2C60%2C0%2C1%2C0-66.4%2C0A95.5%2C95.5%2C0%2C0%2C0%2C9.5%2C192.8a8%2C8%2C0%2C1%2C0%2C13%2C9.2%2C80.1%2C80.1%2C0%2C0%2C1%2C131%2C0%2C8%2C8%2C0%2C1%2C0%2C13-9.2A95.5%2C95.5%2C0%2C0%2C0%2C121.2%2C157.9ZM44%2C108a44%2C44%2C0%2C1%2C1%2C44%2C44A44%2C44%2C0%2C0%2C1%2C44%2C108Zm202.1%2C95.9A7.9%2C7.9%2C0%2C0%2C1%2C235%2C202a80.2%2C80.2%2C0%2C0%2C0-65.5-34%2C8%2C8%2C0%2C0%2C1%2C0-16%2C44%2C44%2C0%2C0%2C0%2C0-88%2C47.4%2C47.4%2C0%2C0%2C0-11.9%2C1.6%2C8%2C8%2C0%2C0%2C1-9.9-5.5%2C8.1%2C8.1%2C0%2C0%2C1%2C5.5-9.9A64%2C64%2C0%2C0%2C1%2C169.5%2C48a59.9%2C59.9%2C0%2C0%2C1%2C33.2%2C109.9%2C96.3%2C96.3%2C0%2C0%2C1%2C45.4%2C34.9A8%2C8%2C0%2C0%2C1%2C246.1%2C203.9Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22warning%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M120%2C144V104a8%2C8%2C0%2C0%2C1%2C16%2C0v40a8%2C8%2C0%2C0%2C1-16%2C0Zm116.8%2C68A23.9%2C23.9%2C0%2C0%2C1%2C216%2C224H40a23.9%2C23.9%2C0%2C0%2C1-20.7-36L107.2%2C36a24%2C24%2C0%2C0%2C1%2C41.6%2C0l87.9%2C152A23.7%2C23.7%2C0%2C0%2C1%2C236.8%2C212Zm-13.9-16-88-152a8%2C8%2C0%2C0%2C0-13.8%2C0h0l-88%2C152a7.8%2C7.8%2C0%2C0%2C0%2C0%2C8%2C7.9%2C7.9%2C0%2C0%2C0%2C6.9%2C4H216a7.9%2C7.9%2C0%2C0%2C0%2C6.9-4A7.8%2C7.8%2C0%2C0%2C0%2C222.9%2C196ZM128%2C168a12%2C12%2C0%2C1%2C0%2C12%2C12A12%2C12%2C0%2C0%2C0%2C128%2C168Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22x-circle%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M128%2C24A104%2C104%2C0%2C1%2C0%2C232%2C128%2C104.1%2C104.1%2C0%2C0%2C0%2C128%2C24Zm0%2C192a88%2C88%2C0%2C1%2C1%2C88-88A88.1%2C88.1%2C0%2C0%2C1%2C128%2C216Zm37.7-61.7a8.1%2C8.1%2C0%2C0%2C1%2C0%2C11.4%2C8.2%2C8.2%2C0%2C0%2C1-11.4%2C0L128%2C139.3l-26.3%2C26.4a8.2%2C8.2%2C0%2C0%2C1-11.4%2C0%2C8.1%2C8.1%2C0%2C0%2C1%2C0-11.4L116.7%2C128%2C90.3%2C101.7a8.1%2C8.1%2C0%2C0%2C1%2C11.4-11.4L128%2C116.7l26.3-26.4a8.1%2C8.1%2C0%2C0%2C1%2C11.4%2C11.4L139.3%2C128Z%22%2F%3E%3C%2Fsymbol%3E%3Csymbol%20id%3D%22x%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20d%3D%22M205.7%2C194.3a8.1%2C8.1%2C0%2C0%2C1%2C0%2C11.4%2C8.2%2C8.2%2C0%2C0%2C1-11.4%2C0L128%2C139.3%2C61.7%2C205.7a8.2%2C8.2%2C0%2C0%2C1-11.4%2C0%2C8.1%2C8.1%2C0%2C0%2C1%2C0-11.4L116.7%2C128%2C50.3%2C61.7A8.1%2C8.1%2C0%2C0%2C1%2C61.7%2C50.3L128%2C116.7l66.3-66.4a8.1%2C8.1%2C0%2C0%2C1%2C11.4%2C11.4L139.3%2C128Z%22%2F%3E%3C%2Fsymbol%3E%3C%2Fsvg%3E#${a}`})}),o=({ariaLabel:l,ariaLabelNext:o="Vis neste side",ariaLabelPrevious:m="Vis forrige side",ariaLabelItem:e="Vis side",count:d,currentIndex:t,limit:D=7,handleClick:E,className:h,...F})=>{const b=Math.ceil(D/2)-2-1,A=t+b,n=t-b,Z=d-1-A-1,r=n-1;let p=d-1>A?A-1:A;p=r<0?p-r:p;let y=1<n?n+1:n;return y=Z<0?y+Z:y,C("nav",{className:i("sds-pagination",h),"aria-label":l,...F,children:a("ol",{className:"sds-pagination__list",children:[C("li",{className:"sds-pagination__list-item",children:C("button",{className:"sds-pagination__button","aria-label":`${m} ${t}`,disabled:0===t,onClick:()=>E(t-1),children:C(s,{icon:"caret-left"})})}),[...Array(d).keys()].map((a=>0===a||a===d-1||a>=y&&a<=p?C("li",{className:"sds-pagination__list-item",children:C("button",{className:"sds-pagination__button","aria-current":a===t||void 0,"aria-label":`${e} ${a+1}`,disabled:a===t,onClick:()=>E(a),children:a+1})},a):a==p+1||a==y-1?C("li",{className:"sds-pagination__list-item",children:C("div",{className:"sds-pagination__button sds-pagination__button--spacer",children:"…"})},a):void 0)),C("li",{className:"sds-pagination__list-item",children:C("button",{className:"sds-pagination__button","aria-label":`${o} ${t+2}`,disabled:t===d-1,onClick:()=>E(t+1),children:C(s,{icon:"caret-right"})})})]})})};export{o as Pagination};
|
|
1
|
+
import{jsx as a,jsxs as i}from"react/jsx-runtime";import s,{clsx as l}from"clsx";const e=({className:i,...l})=>a("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 256 256",className:s("sds-icon",i),"aria-hidden":"true",...l,children:a("path",{d:"M165.66 202.34a8 8 0 0 1-11.32 11.32l-80-80a8 8 0 0 1 0-11.32l80-80a8 8 0 0 1 11.32 11.32L91.31 128Z"})}),n=({className:i,...l})=>a("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 256 256",className:s("sds-icon",i),"aria-hidden":"true",...l,children:a("path",{d:"m181.66 133.66-80 80a8 8 0 0 1-11.32-11.32L164.69 128 90.34 53.66a8 8 0 0 1 11.32-11.32l80 80a8 8 0 0 1 0 11.32Z"})}),t=({"aria-label":s,ariaLabelNext:t="Vis neste side",ariaLabelPrevious:r="Vis forrige side",ariaLabelItem:d="Vis side",count:o,currentIndex:c,limit:m=7,handleClick:h,className:p,..._})=>{const b=Math.ceil(m/2)-2-1,g=c+b,u=c-b,N=o-1-g-1,v=u-1;let w=o-1>g?g-1:g;w=v<0?w-v:w;let x=1<u?u+1:u;return x=N<0?x+N:x,a("nav",{className:l("sds-pagination",p),"aria-label":s,..._,children:i("ol",{className:"sds-pagination__list",children:[a("li",{className:"sds-pagination__list-item",children:a("button",{className:"sds-pagination__button","aria-label":`${r} ${c}`,disabled:0===c,onClick:()=>h(c-1),children:a(e,{})})}),[...Array(o).keys()].map((i=>0===i||i===o-1||i>=x&&i<=w?a("li",{className:"sds-pagination__list-item",children:a("button",{className:"sds-pagination__button","aria-current":i===c||void 0,"aria-label":`${d} ${i+1}`,disabled:i===c,onClick:()=>h(i),children:i+1})},i):i==w+1||i==x-1?a("li",{className:"sds-pagination__list-item",children:a("div",{className:"sds-pagination__button sds-pagination__button--spacer",children:"…"})},i):void 0)),a("li",{className:"sds-pagination__list-item",children:a("button",{className:"sds-pagination__button","aria-label":`${t} ${c+2}`,disabled:c===o-1,onClick:()=>h(c+1),children:a(n,{})})})]})})};export{t as Pagination};
|
|
2
2
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../icons/Icon.tsx","../Pagination.tsx"],"sourcesContent":["import React, { SVGAttributes } from \"react\";\nimport clsx from \"clsx\";\nimport config from \"./icons.config\";\nimport SdsIcons from \"./dist/sds-icons.svg\";\nimport \"./icon.pcss\";\n\ntype IconType = (typeof config.icons)[number];\n\nexport interface IconProps extends SVGAttributes<SVGElement> {\n icon: IconType;\n}\n\nexport const Icon = ({ icon, className, ...rest }: IconProps) => (\n <svg className={clsx(\"sds-icon\", className)} aria-hidden=\"true\" {...rest}>\n <use href={`${SdsIcons}#${icon}`}></use>\n </svg>\n);\n","import React, { HTMLAttributes } from \"react\";\nimport { Icon } from \"@sikt/sds-icons/Icon\";\nimport { clsx } from \"clsx\";\nimport \"./pagination.pcss\";\n\nexport interface PaginationProps extends HTMLAttributes<HTMLElement> {\n className?: string;\n ariaLabel: string;\n ariaLabelPrevious?: string;\n ariaLabelNext?: string;\n ariaLabelItem?: string;\n count: number;\n currentIndex: number;\n /** Total limit of elements, this includes previous/next/first/last. */\n limit?: number;\n handleClick: (index: number) => void;\n}\n\nexport const Pagination = ({\n ariaLabel,\n ariaLabelNext = \"Vis neste side\",\n ariaLabelPrevious = \"Vis forrige side\",\n ariaLabelItem = \"Vis side\",\n count,\n currentIndex,\n limit = 7,\n handleClick,\n className,\n ...rest\n}: PaginationProps) => {\n const constantCount = 2;\n const delimiter = Math.ceil(limit / 2) - constantCount - 1;\n const max = currentIndex + delimiter;\n const min = currentIndex - delimiter;\n const hasMaxSpacer = count - 1 > max;\n const hasMinSpacer = 1 < min;\n const maxModifier = count - 1 - max - 1;\n const minModifier = min - 1;\n const hasLessBeforeIndex = minModifier < 0;\n const hasLessAfterIndex = maxModifier < 0;\n let maxLimit = hasMaxSpacer ? max - 1 : max;\n maxLimit = hasLessBeforeIndex ? maxLimit - minModifier : maxLimit;\n let minLimit = hasMinSpacer ? min + 1 : min;\n minLimit = hasLessAfterIndex ? minLimit + maxModifier : minLimit;\n\n return (\n <nav\n className={clsx(\"sds-pagination\", className)}\n aria-label={ariaLabel}\n {...rest}\n >\n <ol className=\"sds-pagination__list\">\n <li className=\"sds-pagination__list-item\">\n <button\n className=\"sds-pagination__button\"\n aria-label={`${ariaLabelPrevious} ${currentIndex}`}\n disabled={currentIndex === 0}\n onClick={() => handleClick(currentIndex - 1)}\n >\n <Icon icon=\"caret-left\" />\n </button>\n </li>\n {[...Array(count).keys()].map((value) => {\n if (\n value === 0 ||\n value === count - 1 ||\n (value >= minLimit && value <= maxLimit)\n ) {\n return (\n <li className=\"sds-pagination__list-item\" key={value}>\n <button\n className=\"sds-pagination__button\"\n aria-current={value === currentIndex ? true : undefined}\n aria-label={`${ariaLabelItem} ${value + 1}`}\n disabled={value === currentIndex}\n onClick={() => handleClick(value)}\n >\n {value + 1}\n </button>\n </li>\n );\n } else if (value == maxLimit + 1 || value == minLimit - 1) {\n return (\n <li className=\"sds-pagination__list-item\" key={value}>\n <div className=\"sds-pagination__button sds-pagination__button--spacer\">\n …\n </div>\n </li>\n );\n }\n })}\n <li className=\"sds-pagination__list-item\">\n <button\n className=\"sds-pagination__button\"\n aria-label={`${ariaLabelNext} ${currentIndex + 2}`}\n disabled={currentIndex === count - 1}\n onClick={() => handleClick(currentIndex + 1)}\n >\n <Icon icon=\"caret-right\" />\n </button>\n </li>\n </ol>\n </nav>\n );\n};\n"],"names":["Icon","icon","className","rest","_jsx","clsx","children","href","Pagination","ariaLabel","ariaLabelNext","ariaLabelPrevious","ariaLabelItem","count","currentIndex","limit","handleClick","delimiter","Math","ceil","max","min","maxModifier","minModifier","maxLimit","minLimit","_jsxs","disabled","onClick","Array","keys","map","value","undefined"],"mappings":"+FAYO,MAAMA,EAAO,EAAGC,OAAMC,eAAcC,KACzCC,EAAA,MAAA,CAAKF,UAAWG,EAAK,WAAYH,iBAAwB,UAAWC,EAClEG,SAAAF,EAAA,MAAA,CAAKG,KAAM,s7hBAAeN,QCIjBO,EAAa,EACxBC,YACAC,gBAAgB,iBAChBC,oBAAoB,mBACpBC,gBAAgB,WAChBC,QACAC,eACAC,QAAQ,EACRC,cACAd,eACGC,MAEH,MACMc,EAAYC,KAAKC,KAAKJ,EAAQ,GADd,EACmC,EACnDK,EAAMN,EAAeG,EACrBI,EAAMP,EAAeG,EAGrBK,EAAcT,EAAQ,EAAIO,EAAM,EAChCG,EAAcF,EAAM,EAG1B,IAAIG,EANiBX,EAAQ,EAAIO,EAMHA,EAAM,EAAIA,EACxCI,EAH2BD,EAAc,EAGTC,EAAWD,EAAcC,EACzD,IAAIC,EAPiB,EAAIJ,EAOKA,EAAM,EAAIA,EAGxC,OAFAI,EAJ0BH,EAAc,EAITG,EAAWH,EAAcG,EAGtDrB,EACE,MAAA,CAAAF,UAAWG,EAAK,iBAAkBH,gBACtBO,KACRN,EAEJG,SAAAoB,EAAA,KAAA,CAAIxB,UAAU,uBACZI,SAAA,CAAAF,EAAA,KAAA,CAAIF,UAAU,4BACZI,SAAAF,EAAA,SAAA,CACEF,UAAU,yBACE,aAAA,GAAGS,KAAqBG,IACpCa,SAA2B,IAAjBb,EACVc,QAAS,IAAMZ,EAAYF,EAAe,GAE1CR,SAAAF,EAACJ,EAAK,CAAAC,KAAK,mBAGd,IAAI4B,MAAMhB,GAAOiB,QAAQC,KAAKC,GAEjB,IAAVA,GACAA,IAAUnB,EAAQ,GACjBmB,GAASP,GAAYO,GAASR,EAG7BpB,EAAI,KAAA,CAAAF,UAAU,qCACZE,EACE,SAAA,CAAAF,UAAU,yBACI,eAAA8B,IAAUlB,QAAsBmB,EAAS,aAC3C,GAAGrB,KAAiBoB,EAAQ,IACxCL,SAAUK,IAAUlB,EACpBc,QAAS,IAAMZ,EAAYgB,GAAM1B,SAEhC0B,EAAQ,KARkCA,GAYxCA,GAASR,EAAW,GAAKQ,GAASP,EAAW,EAEpDrB,EAAA,KAAA,CAAIF,UAAU,4BACZI,SAAAF,EAAA,MAAA,CAAKF,UAAU,wDAETI,SAAA,OAHuC0B,QAF5C,IAUT5B,EAAA,KAAA,CAAIF,UAAU,4BACZI,SAAAF,EAAA,SAAA,CACEF,UAAU,yBAAwB,aACtB,GAAGQ,KAAiBI,EAAe,IAC/Ca,SAAUb,IAAiBD,EAAQ,EACnCe,QAAS,IAAMZ,EAAYF,EAAe,GAAER,SAE5CF,EAACJ,EAAI,CAACC,KAAK,wBAKnB"}
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../icons/dist/index.js","../Pagination.tsx"],"sourcesContent":["import{jsx as a}from\"react/jsx-runtime\";import s from\"clsx\";const l=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M128 24a104 104 0 1 0 104 104A104.11 104.11 0 0 0 128 24Zm0 192a88 88 0 1 1 88-88 88.1 88.1 0 0 1-88 88Zm48-88a8 8 0 0 1-8 8h-60.69l18.35 18.34a8 8 0 0 1-11.32 11.32l-32-32a8 8 0 0 1 0-11.32l32-32a8 8 0 0 1 11.32 11.32L107.31 120H168a8 8 0 0 1 8 8Z\"})}),e=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M128 24a104 104 0 1 0 104 104A104.11 104.11 0 0 0 128 24Zm0 192a88 88 0 1 1 88-88 88.1 88.1 0 0 1-88 88Zm45.66-93.66a8 8 0 0 1 0 11.32l-32 32a8 8 0 0 1-11.32-11.32L148.69 136H88a8 8 0 0 1 0-16h60.69l-18.35-18.34a8 8 0 0 1 11.32-11.32Z\"})}),r=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M224 128a8 8 0 0 1-8 8H59.31l58.35 58.34a8 8 0 0 1-11.32 11.32l-72-72a8 8 0 0 1 0-11.32l72-72a8 8 0 0 1 11.32 11.32L59.31 120H216a8 8 0 0 1 8 8Z\"})}),i=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"m221.66 133.66-72 72a8 8 0 0 1-11.32-11.32L196.69 136H40a8 8 0 0 1 0-16h156.69l-58.35-58.34a8 8 0 0 1 11.32-11.32l72 72a8 8 0 0 1 0 11.32Z\"})}),c=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M224 104a8 8 0 0 1-16 0V59.32l-66.33 66.34a8 8 0 0 1-11.32-11.32L196.68 48H152a8 8 0 0 1 0-16h64a8 8 0 0 1 8 8Zm-40 24a8 8 0 0 0-8 8v72H48V80h72a8 8 0 0 0 0-16H48a16 16 0 0 0-16 16v128a16 16 0 0 0 16 16h128a16 16 0 0 0 16-16v-72a8 8 0 0 0-8-8Z\"})}),o=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M232 144a64.07 64.07 0 0 1-64 64H80a8 8 0 0 1 0-16h88a48 48 0 0 0 0-96H51.31l34.35 34.34a8 8 0 0 1-11.32 11.32l-48-48a8 8 0 0 1 0-11.32l48-48a8 8 0 0 1 11.32 11.32L51.31 80H168a64.07 64.07 0 0 1 64 64Z\"})}),n=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M170.34 130.34 204.69 96H88a48 48 0 0 0 0 96h88a8 8 0 0 1 0 16H88a64 64 0 0 1 0-128h116.69l-34.35-34.34a8 8 0 0 1 11.32-11.32l48 48a8 8 0 0 1 0 11.32l-48 48a8 8 0 0 1-11.32-11.32Z\"})}),h=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M224 71.1a8 8 0 0 1-10.78-3.42 94.13 94.13 0 0 0-33.46-36.91 8 8 0 1 1 8.54-13.54 111.46 111.46 0 0 1 39.12 43.09A8 8 0 0 1 224 71.1ZM35.71 72a8 8 0 0 0 7.1-4.32 94.13 94.13 0 0 1 33.46-36.91 8 8 0 1 0-8.54-13.54 111.46 111.46 0 0 0-39.12 43.09A8 8 0 0 0 35.71 72Zm186.1 103.94A16 16 0 0 1 208 200h-40.8a40 40 0 0 1-78.4 0H48a16 16 0 0 1-13.79-24.06C43.22 160.39 48 138.28 48 112a80 80 0 0 1 160 0c0 26.27 4.78 48.38 13.81 63.94ZM150.62 200h-45.24a24 24 0 0 0 45.24 0ZM208 184c-10.64-18.27-16-42.49-16-72a64 64 0 0 0-128 0c0 29.52-5.38 53.74-16 72Z\"})}),t=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M221.8 175.94c-5.55-9.56-13.8-36.61-13.8-71.94a80 80 0 1 0-160 0c0 35.34-8.26 62.38-13.81 71.94A16 16 0 0 0 48 200h40.81a40 40 0 0 0 78.38 0H208a16 16 0 0 0 13.8-24.06ZM128 216a24 24 0 0 1-22.62-16h45.24A24 24 0 0 1 128 216Zm-80-32c7.7-13.24 16-43.92 16-80a64 64 0 1 1 128 0c0 36.05 8.28 66.73 16 80Z\"})}),w=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M184 32H72a16 16 0 0 0-16 16v176a8 8 0 0 0 12.24 6.78L128 193.43l59.77 37.35A8 8 0 0 0 200 224V48a16 16 0 0 0-16-16Z\"})}),d=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M184 32H72a16 16 0 0 0-16 16v176a8 8 0 0 0 12.24 6.78L128 193.43l59.77 37.35A8 8 0 0 0 200 224V48a16 16 0 0 0-16-16Zm0 177.57-51.77-32.35a8 8 0 0 0-8.48 0L72 209.57V48h112Z\"})}),m=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M208 32h-24v-8a8 8 0 0 0-16 0v8H88v-8a8 8 0 0 0-16 0v8H48a16 16 0 0 0-16 16v160a16 16 0 0 0 16 16h160a16 16 0 0 0 16-16V48a16 16 0 0 0-16-16ZM72 48v8a8 8 0 0 0 16 0v-8h80v8a8 8 0 0 0 16 0v-8h24v32H48V48Zm136 160H48V96h160v112Z\"})}),v=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M208 32h-24v-8a8 8 0 0 0-16 0v8H88v-8a8 8 0 0 0-16 0v8H48a16 16 0 0 0-16 16v160a16 16 0 0 0 16 16h160a16 16 0 0 0 16-16V48a16 16 0 0 0-16-16ZM72 48v8a8 8 0 0 0 16 0v-8h80v8a8 8 0 0 0 16 0v-8h24v32H48V48Zm136 160H48V96h160v112Zm-48-56a8 8 0 0 1-8 8h-16v16a8 8 0 0 1-16 0v-16h-16a8 8 0 0 1 0-16h16v-16a8 8 0 0 1 16 0v16h16a8 8 0 0 1 8 8Z\"})}),g=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M128 24a104 104 0 1 0 104 104A104.11 104.11 0 0 0 128 24Zm0 192a88 88 0 1 1 88-88 88.1 88.1 0 0 1-88 88Zm45.66-109.66a8 8 0 0 1 0 11.32l-40 40a8 8 0 0 1-11.32 0l-40-40a8 8 0 0 1 11.32-11.32L128 140.69l34.34-34.35a8 8 0 0 1 11.32 0Z\"})}),Z=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M128 24a104 104 0 1 0 104 104A104.11 104.11 0 0 0 128 24Zm0 192a88 88 0 1 1 88-88 88.1 88.1 0 0 1-88 88Zm21.66-122.34L115.31 128l34.35 34.34a8 8 0 0 1-11.32 11.32l-40-40a8 8 0 0 1 0-11.32l40-40a8 8 0 0 1 11.32 11.32Z\"})}),p=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M128 24a104 104 0 1 0 104 104A104.11 104.11 0 0 0 128 24Zm0 192a88 88 0 1 1 88-88 88.1 88.1 0 0 1-88 88Zm29.66-93.66a8 8 0 0 1 0 11.32l-40 40a8 8 0 0 1-11.32-11.32L140.69 128l-34.35-34.34a8 8 0 0 1 11.32-11.32Z\"})}),u=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M128 24a104 104 0 1 0 104 104A104.11 104.11 0 0 0 128 24Zm0 192a88 88 0 1 1 88-88 88.1 88.1 0 0 1-88 88Zm45.66-77.66a8 8 0 0 1-11.32 11.32L128 115.31l-34.34 34.35a8 8 0 0 1-11.32-11.32l40-40a8 8 0 0 1 11.32 0Z\"})}),x=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"m213.66 101.66-80 80a8 8 0 0 1-11.32 0l-80-80a8 8 0 0 1 11.32-11.32L128 164.69l74.34-74.35a8 8 0 0 1 11.32 11.32Z\"})}),N=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M165.66 202.34a8 8 0 0 1-11.32 11.32l-80-80a8 8 0 0 1 0-11.32l80-80a8 8 0 0 1 11.32 11.32L91.31 128Z\"})}),C=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"m181.66 133.66-80 80a8 8 0 0 1-11.32-11.32L164.69 128 90.34 53.66a8 8 0 0 1 11.32-11.32l80 80a8 8 0 0 1 0 11.32Z\"})}),M=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M213.66 165.66a8 8 0 0 1-11.32 0L128 91.31l-74.34 74.35a8 8 0 0 1-11.32-11.32l80-80a8 8 0 0 1 11.32 0l80 80a8 8 0 0 1 0 11.32Z\"})}),H=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M173.66 98.34a8 8 0 0 1 0 11.32l-56 56a8 8 0 0 1-11.32 0l-24-24a8 8 0 0 1 11.32-11.32L112 148.69l50.34-50.35a8 8 0 0 1 11.32 0ZM232 128A104 104 0 1 1 128 24a104.11 104.11 0 0 1 104 104Zm-16 0a88 88 0 1 0-88 88 88.1 88.1 0 0 0 88-88Z\"})}),L=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"m229.66 77.66-128 128a8 8 0 0 1-11.32 0l-56-56a8 8 0 0 1 11.32-11.32L96 188.69 218.34 66.34a8 8 0 0 1 11.32 11.32Z\"})}),f=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M128 24a104 104 0 1 0 104 104A104.11 104.11 0 0 0 128 24Zm0 192a88 88 0 1 1 88-88 88.1 88.1 0 0 1-88 88Z\"})}),B=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M128 24a104 104 0 1 0 104 104A104.11 104.11 0 0 0 128 24Zm0 192a88 88 0 1 1 88-88 88.1 88.1 0 0 1-88 88Zm64-88a8 8 0 0 1-8 8h-56a8 8 0 0 1-8-8V72a8 8 0 0 1 16 0v48h48a8 8 0 0 1 8 8Z\"})}),I=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M216 32H88a8 8 0 0 0-8 8v40H40a8 8 0 0 0-8 8v128a8 8 0 0 0 8 8h128a8 8 0 0 0 8-8v-40h40a8 8 0 0 0 8-8V40a8 8 0 0 0-8-8Zm-56 176H48V96h112Zm48-48h-32V88a8 8 0 0 0-8-8H96V48h112Z\"})}),V=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M104 60a12 12 0 1 1-12-12 12 12 0 0 1 12 12Zm60 12a12 12 0 1 0-12-12 12 12 0 0 0 12 12Zm-72 44a12 12 0 1 0 12 12 12 12 0 0 0-12-12Zm72 0a12 12 0 1 0 12 12 12 12 0 0 0-12-12Zm-72 68a12 12 0 1 0 12 12 12 12 0 0 0-12-12Zm72 0a12 12 0 1 0 12 12 12 12 0 0 0-12-12Z\"})}),A=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M128 24a104 104 0 1 0 104 104A104.11 104.11 0 0 0 128 24Zm0 192a88 88 0 1 1 88-88 88.1 88.1 0 0 1-88 88Zm12-88a12 12 0 1 1-12-12 12 12 0 0 1 12 12Zm44 0a12 12 0 1 1-12-12 12 12 0 0 1 12 12Zm-88 0a12 12 0 1 1-12-12 12 12 0 0 1 12 12Z\"})}),S=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M140 128a12 12 0 1 1-12-12 12 12 0 0 1 12 12Zm56-12a12 12 0 1 0 12 12 12 12 0 0 0-12-12Zm-136 0a12 12 0 1 0 12 12 12 12 0 0 0-12-12Z\"})}),k=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M224 152v56a16 16 0 0 1-16 16H48a16 16 0 0 1-16-16v-56a8 8 0 0 1 16 0v56h160v-56a8 8 0 0 1 16 0Zm-101.66 5.66a8 8 0 0 0 11.32 0l40-40a8 8 0 0 0-11.32-11.32L136 132.69V40a8 8 0 0 0-16 0v92.69l-26.34-26.35a8 8 0 0 0-11.32 11.32Z\"})}),D=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M224 48H32a8 8 0 0 0-8 8v136a16 16 0 0 0 16 16h176a16 16 0 0 0 16-16V56a8 8 0 0 0-8-8Zm-96 85.15L52.57 64h150.86ZM98.71 128 40 181.81V74.19Zm11.84 10.85 12 11.05a8 8 0 0 0 10.82 0l12-11.05 58 53.15H52.57ZM157.29 128 216 74.18v107.64Z\"})}),P=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M216 112v96a16 16 0 0 1-16 16H56a16 16 0 0 1-16-16v-96a16 16 0 0 1 16-16h24a8 8 0 0 1 0 16H56v96h144v-96h-24a8 8 0 0 1 0-16h24a16 16 0 0 1 16 16ZM93.66 69.66 120 43.31V136a8 8 0 0 0 16 0V43.31l26.34 26.35a8 8 0 0 0 11.32-11.32l-40-40a8 8 0 0 0-11.32 0l-40 40a8 8 0 0 0 11.32 11.32Z\"})}),U=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M219.31 80 176 36.69A15.86 15.86 0 0 0 164.69 32H48a16 16 0 0 0-16 16v160a16 16 0 0 0 16 16h160a16 16 0 0 0 16-16V91.31A15.86 15.86 0 0 0 219.31 80ZM168 208H88v-56h80Zm40 0h-24v-56a16 16 0 0 0-16-16H88a16 16 0 0 0-16 16v56H48V48h116.69L208 91.31ZM160 72a8 8 0 0 1-8 8H96a8 8 0 0 1 0-16h56a8 8 0 0 1 8 8Z\"})}),q=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M230.6 49.53A15.81 15.81 0 0 0 216 40H40a16 16 0 0 0-11.81 26.76l.08.09L96 139.17V216a16 16 0 0 0 24.87 13.32l32-21.34a16 16 0 0 0 7.13-13.32v-55.49l67.74-72.32.08-.09a15.8 15.8 0 0 0 2.78-17.23ZM40 56Zm108.34 72.28a15.92 15.92 0 0 0-4.34 10.89v55.49L112 216v-76.83a15.92 15.92 0 0 0-4.32-10.94L40 56h176Z\"})}),R=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M128 80a48 48 0 1 0 48 48 48.05 48.05 0 0 0-48-48Zm0 80a32 32 0 1 1 32-32 32 32 0 0 1-32 32Zm88-29.84q.06-2.16 0-4.32l14.92-18.64a8 8 0 0 0 1.48-7.06 107.21 107.21 0 0 0-10.88-26.25 8 8 0 0 0-6-3.93l-23.72-2.64q-1.48-1.56-3-3L186 40.54a8 8 0 0 0-3.94-6 107.71 107.71 0 0 0-26.25-10.87 8 8 0 0 0-7.06 1.49L130.16 40h-4.32L107.2 25.11a8 8 0 0 0-7.06-1.48 107.6 107.6 0 0 0-26.25 10.88 8 8 0 0 0-3.93 6l-2.64 23.76q-1.56 1.49-3 3L40.54 70a8 8 0 0 0-6 3.94 107.71 107.71 0 0 0-10.87 26.25 8 8 0 0 0 1.49 7.06L40 125.84v4.32L25.11 148.8a8 8 0 0 0-1.48 7.06 107.21 107.21 0 0 0 10.88 26.25 8 8 0 0 0 6 3.93l23.72 2.64q1.49 1.56 3 3L70 215.46a8 8 0 0 0 3.94 6 107.71 107.71 0 0 0 26.25 10.87 8 8 0 0 0 7.06-1.49L125.84 216q2.16.06 4.32 0l18.64 14.92a8 8 0 0 0 7.06 1.48 107.21 107.21 0 0 0 26.25-10.88 8 8 0 0 0 3.93-6l2.64-23.72q1.56-1.48 3-3l23.78-2.8a8 8 0 0 0 6-3.94 107.71 107.71 0 0 0 10.87-26.25 8 8 0 0 0-1.49-7.06Zm-16.1-6.5a73.93 73.93 0 0 1 0 8.68 8 8 0 0 0 1.74 5.48l14.19 17.73a91.57 91.57 0 0 1-6.23 15l-22.6 2.56a8 8 0 0 0-5.1 2.64 74.11 74.11 0 0 1-6.14 6.14 8 8 0 0 0-2.64 5.1l-2.51 22.58a91.32 91.32 0 0 1-15 6.23l-17.74-14.19a8 8 0 0 0-5-1.75h-.48a73.93 73.93 0 0 1-8.68 0 8 8 0 0 0-5.48 1.74l-17.78 14.2a91.57 91.57 0 0 1-15-6.23L82.89 187a8 8 0 0 0-2.64-5.1 74.11 74.11 0 0 1-6.14-6.14 8 8 0 0 0-5.1-2.64l-22.58-2.52a91.32 91.32 0 0 1-6.23-15l14.19-17.74a8 8 0 0 0 1.74-5.48 73.93 73.93 0 0 1 0-8.68 8 8 0 0 0-1.74-5.48L40.2 100.45a91.57 91.57 0 0 1 6.23-15L69 82.89a8 8 0 0 0 5.1-2.64 74.11 74.11 0 0 1 6.14-6.14A8 8 0 0 0 82.89 69l2.51-22.57a91.32 91.32 0 0 1 15-6.23l17.74 14.19a8 8 0 0 0 5.48 1.74 73.93 73.93 0 0 1 8.68 0 8 8 0 0 0 5.48-1.74l17.77-14.19a91.57 91.57 0 0 1 15 6.23L173.11 69a8 8 0 0 0 2.64 5.1 74.11 74.11 0 0 1 6.14 6.14 8 8 0 0 0 5.1 2.64l22.58 2.51a91.32 91.32 0 0 1 6.23 15l-14.19 17.74a8 8 0 0 0-1.74 5.53Z\"})}),y=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M128 24a104 104 0 1 0 104 104A104.11 104.11 0 0 0 128 24Zm0 192a88 88 0 1 1 88-88 88.1 88.1 0 0 1-88 88Zm16-40a8 8 0 0 1-8 8 16 16 0 0 1-16-16v-40a8 8 0 0 1 0-16 16 16 0 0 1 16 16v40a8 8 0 0 1 8 8Zm-32-92a12 12 0 1 1 12 12 12 12 0 0 1-12-12Z\"})}),F=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M165.66 90.34a8 8 0 0 1 0 11.32l-64 64a8 8 0 0 1-11.32-11.32l64-64a8 8 0 0 1 11.32 0ZM215.6 40.4a56 56 0 0 0-79.2 0l-30.06 30.05a8 8 0 0 0 11.32 11.32l30.06-30a40 40 0 0 1 56.57 56.56l-30.07 30.06a8 8 0 0 0 11.31 11.32l30.07-30.11a56 56 0 0 0 0-79.2Zm-77.26 133.82-30.06 30.06a40 40 0 1 1-56.56-56.57l30.05-30.05a8 8 0 0 0-11.32-11.32L40.4 136.4a56 56 0 0 0 79.2 79.2l30.06-30.07a8 8 0 0 0-11.32-11.31Z\"})}),G=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M224 128a8 8 0 0 1-8 8H40a8 8 0 0 1 0-16h176a8 8 0 0 1 8 8ZM40 72h176a8 8 0 0 0 0-16H40a8 8 0 0 0 0 16Zm176 112H40a8 8 0 0 0 0 16h176a8 8 0 0 0 0-16Z\"})}),O=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M208 80H96V56a32 32 0 0 1 32-32c15.37 0 29.2 11 32.16 25.59a8 8 0 0 0 15.68-3.18C171.32 24.15 151.2 8 128 8a48.05 48.05 0 0 0-48 48v24H48a16 16 0 0 0-16 16v112a16 16 0 0 0 16 16h160a16 16 0 0 0 16-16V96a16 16 0 0 0-16-16Zm0 128H48V96h160v112Z\"})}),T=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M208 80h-32V56a48 48 0 0 0-96 0v24H48a16 16 0 0 0-16 16v112a16 16 0 0 0 16 16h160a16 16 0 0 0 16-16V96a16 16 0 0 0-16-16ZM96 56a32 32 0 0 1 64 0v24H96Zm112 152H48V96h160v112Z\"})}),E=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"m229.66 218.34-50.07-50.06a88.11 88.11 0 1 0-11.31 11.31l50.06 50.07a8 8 0 0 0 11.32-11.32ZM40 112a72 72 0 1 1 72 72 72.08 72.08 0 0 1-72-72Z\"})}),X=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M128 64a40 40 0 1 0 40 40 40 40 0 0 0-40-40Zm0 64a24 24 0 1 1 24-24 24 24 0 0 1-24 24Zm0-112a88.1 88.1 0 0 0-88 88c0 31.4 14.51 64.68 42 96.25a254.19 254.19 0 0 0 41.45 38.3 8 8 0 0 0 9.18 0 254.19 254.19 0 0 0 41.37-38.3c27.45-31.57 42-64.85 42-96.25a88.1 88.1 0 0 0-88-88Zm0 206c-16.53-13-72-60.75-72-118a72 72 0 0 1 144 0c0 57.23-55.47 105-72 118Z\"})}),j=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M176 128a8 8 0 0 1-8 8H88a8 8 0 0 1 0-16h80a8 8 0 0 1 8 8Zm56 0A104 104 0 1 1 128 24a104.11 104.11 0 0 1 104 104Zm-16 0a88 88 0 1 0-88 88 88.1 88.1 0 0 0 88-88Z\"})}),W=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M224 128a8 8 0 0 1-8 8H40a8 8 0 0 1 0-16h176a8 8 0 0 1 8 8Z\"})}),b=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M209.66 122.34a8 8 0 0 1 0 11.32l-82.05 82a56 56 0 0 1-79.2-79.21l99.26-100.72a40 40 0 1 1 56.61 56.55L105 193a24 24 0 1 1-34-34l83.3-84.62a8 8 0 1 1 11.4 11.22l-83.31 84.71a8 8 0 1 0 11.27 11.36L192.93 81A24 24 0 1 0 159 47L59.76 147.68a40 40 0 1 0 56.53 56.62l82.06-82a8 8 0 0 1 11.31.04Z\"})}),z=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M48 56v144a8 8 0 0 1-16 0V56a8 8 0 0 1 16 0Zm84 54.5-20 6.5V96a8 8 0 0 0-16 0v21l-20-6.5a8 8 0 0 0-5 15.22l20 6.49-12.34 17a8 8 0 1 0 12.94 9.4l12.34-17 12.34 17a8 8 0 1 0 12.94-9.4l-12.34-17 20-6.49A8 8 0 0 0 132 110.5Zm106 5.14a8 8 0 0 0-10-5.14l-20 6.5V96a8 8 0 0 0-16 0v21l-20-6.49a8 8 0 0 0-4.95 15.22l20 6.49-12.34 17a8 8 0 1 0 12.94 9.4l12.34-17 12.34 17a8 8 0 1 0 12.94-9.4l-12.34-17 20-6.49a8 8 0 0 0 5.07-10.09Z\"})}),J=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"m227.31 73.37-44.68-44.69a16 16 0 0 0-22.63 0L36.69 152A15.86 15.86 0 0 0 32 163.31V208a16 16 0 0 0 16 16h44.69a15.86 15.86 0 0 0 11.31-4.69L227.31 96a16 16 0 0 0 0-22.63ZM51.31 160 136 75.31 152.69 92 68 176.68ZM48 179.31 76.69 208H48Zm48 25.38L79.31 188 164 103.31 180.69 120Zm96-96L147.31 64l24-24L216 84.68Z\"})}),K=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"m222.37 158.46-47.11-21.11-.13-.06a16 16 0 0 0-15.17 1.4 8.12 8.12 0 0 0-.75.56L134.87 160c-15.42-7.49-31.34-23.29-38.83-38.51l20.78-24.71c.2-.25.39-.5.57-.77a16 16 0 0 0 1.32-15.06v-.12L97.54 33.64a16 16 0 0 0-16.62-9.52A56.26 56.26 0 0 0 32 80c0 79.4 64.6 144 144 144a56.26 56.26 0 0 0 55.88-48.92 16 16 0 0 0-9.51-16.62ZM176 208A128.14 128.14 0 0 1 48 80a40.2 40.2 0 0 1 34.87-40 .61.61 0 0 0 0 .12l21 47-20.67 24.74a6.13 6.13 0 0 0-.57.77 16 16 0 0 0-1 15.7c9.06 18.53 27.73 37.06 46.46 46.11a16 16 0 0 0 15.75-1.14 8.44 8.44 0 0 0 .74-.56L168.89 152l47 21.05h.11A40.21 40.21 0 0 1 176 208Z\"})}),Q=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M128 24a104 104 0 1 0 104 104A104.11 104.11 0 0 0 128 24Zm0 192a88 88 0 1 1 88-88 88.1 88.1 0 0 1-88 88Zm48-88a8 8 0 0 1-8 8h-32v32a8 8 0 0 1-16 0v-32H88a8 8 0 0 1 0-16h32V88a8 8 0 0 1 16 0v32h32a8 8 0 0 1 8 8Z\"})}),Y=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M224 128a8 8 0 0 1-8 8h-80v80a8 8 0 0 1-16 0v-80H40a8 8 0 0 1 0-16h80V40a8 8 0 0 1 16 0v80h80a8 8 0 0 1 8 8Z\"})}),$=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M222.14 58.87A8 8 0 0 0 216 56H54.68l-4.89-26.86A16 16 0 0 0 34.05 16H16a8 8 0 0 0 0 16h18l25.56 140.29a24 24 0 0 0 5.33 11.27 28 28 0 1 0 44.4 8.44h45.42a27.75 27.75 0 0 0-2.71 12 28 28 0 1 0 28-28H83.17a8 8 0 0 1-7.87-6.57L72.13 152h116a24 24 0 0 0 23.61-19.71l12.16-66.86a8 8 0 0 0-1.76-6.56ZM96 204a12 12 0 1 1-12-12 12 12 0 0 1 12 12Zm96 0a12 12 0 1 1-12-12 12 12 0 0 1 12 12Zm4-74.57a8 8 0 0 1-7.9 6.57H69.22L57.59 72h148.82Z\"})}),_=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"m141.66 133.66-40 40a8 8 0 0 1-11.32-11.32L116.69 136H24a8 8 0 0 1 0-16h92.69L90.34 93.66a8 8 0 0 1 11.32-11.32l40 40a8 8 0 0 1 0 11.32ZM192 32h-56a8 8 0 0 0 0 16h56v160h-56a8 8 0 0 0 0 16h56a16 16 0 0 0 16-16V48a16 16 0 0 0-16-16Z\"})}),aa=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M112 216a8 8 0 0 1-8 8H48a16 16 0 0 1-16-16V48a16 16 0 0 1 16-16h56a8 8 0 0 1 0 16H48v160h56a8 8 0 0 1 8 8Zm109.66-93.66-40-40a8 8 0 0 0-11.32 11.32L196.69 120H104a8 8 0 0 0 0 16h92.69l-26.35 26.34a8 8 0 0 0 11.32 11.32l40-40a8 8 0 0 0 0-11.32Z\"})}),sa=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M64 105V40a8 8 0 0 0-16 0v65a32 32 0 0 0 0 62v49a8 8 0 0 0 16 0v-49a32 32 0 0 0 0-62Zm-8 47a16 16 0 1 1 16-16 16 16 0 0 1-16 16Zm80-95V40a8 8 0 0 0-16 0v17a32 32 0 0 0 0 62v97a8 8 0 0 0 16 0v-97a32 32 0 0 0 0-62Zm-8 47a16 16 0 1 1 16-16 16 16 0 0 1-16 16Zm104 64a32.06 32.06 0 0 0-24-31V40a8 8 0 0 0-16 0v97a32 32 0 0 0 0 62v17a8 8 0 0 0 16 0v-17a32.06 32.06 0 0 0 24-31Zm-32 16a16 16 0 1 1 16-16 16 16 0 0 1-16 16Z\"})}),la=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M128 128a8 8 0 0 1-8 8H48a8 8 0 0 1 0-16h72a8 8 0 0 1 8 8ZM48 72h136a8 8 0 0 0 0-16H48a8 8 0 0 0 0 16Zm56 112H48a8 8 0 0 0 0 16h56a8 8 0 0 0 0-16Zm125.66-21.66a8 8 0 0 0-11.32 0L192 188.69V112a8 8 0 0 0-16 0v76.69l-26.34-26.35a8 8 0 0 0-11.32 11.32l40 40a8 8 0 0 0 11.32 0l40-40a8 8 0 0 0 0-11.32Z\"})}),ea=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M40 128a8 8 0 0 1 8-8h72a8 8 0 0 1 0 16H48a8 8 0 0 1-8-8Zm8-56h56a8 8 0 0 0 0-16H48a8 8 0 0 0 0 16Zm136 112H48a8 8 0 0 0 0 16h136a8 8 0 0 0 0-16Zm45.66-101.66-40-40a8 8 0 0 0-11.32 0l-40 40a8 8 0 0 0 11.32 11.32L176 67.31V144a8 8 0 0 0 16 0V67.31l26.34 26.35a8 8 0 0 0 11.32-11.32Z\"})}),ra=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M136 32v32a8 8 0 0 1-16 0V32a8 8 0 0 1 16 0Zm88 88h-32a8 8 0 0 0 0 16h32a8 8 0 0 0 0-16Zm-45.09 47.6a8 8 0 0 0-11.31 11.31l22.62 22.63a8 8 0 0 0 11.32-11.32ZM128 184a8 8 0 0 0-8 8v32a8 8 0 0 0 16 0v-32a8 8 0 0 0-8-8Zm-50.91-16.4-22.63 22.62a8 8 0 0 0 11.32 11.32l22.62-22.63a8 8 0 0 0-11.31-11.31ZM72 128a8 8 0 0 0-8-8H32a8 8 0 0 0 0 16h32a8 8 0 0 0 8-8Zm-6.22-73.54a8 8 0 0 0-11.32 11.32L77.09 88.4A8 8 0 0 0 88.4 77.09Z\"})}),ia=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M216 48h-40v-8a24 24 0 0 0-24-24h-48a24 24 0 0 0-24 24v8H40a8 8 0 0 0 0 16h8v144a16 16 0 0 0 16 16h128a16 16 0 0 0 16-16V64h8a8 8 0 0 0 0-16ZM96 40a8 8 0 0 1 8-8h48a8 8 0 0 1 8 8v8H96Zm96 168H64V64h128Zm-80-104v64a8 8 0 0 1-16 0v-64a8 8 0 0 1 16 0Zm48 0v64a8 8 0 0 1-16 0v-64a8 8 0 0 1 16 0Z\"})}),ca=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M224 152v56a16 16 0 0 1-16 16H48a16 16 0 0 1-16-16v-56a8 8 0 0 1 16 0v56h160v-56a8 8 0 0 1 16 0ZM93.66 85.66 120 59.31V152a8 8 0 0 0 16 0V59.31l26.34 26.35a8 8 0 0 0 11.32-11.32l-40-40a8 8 0 0 0-11.32 0l-40 40a8 8 0 0 0 11.32 11.32Z\"})}),oa=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M128 24a104 104 0 1 0 104 104A104.11 104.11 0 0 0 128 24ZM74.08 197.5a64 64 0 0 1 107.84 0 87.83 87.83 0 0 1-107.84 0ZM96 120a32 32 0 1 1 32 32 32 32 0 0 1-32-32Zm97.76 66.41a79.66 79.66 0 0 0-36.06-28.75 48 48 0 1 0-59.4 0 79.66 79.66 0 0 0-36.06 28.75 88 88 0 1 1 131.52 0Z\"})}),na=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M236.8 188.09 149.35 36.22a24.76 24.76 0 0 0-42.7 0L19.2 188.09a23.51 23.51 0 0 0 0 23.72A24.35 24.35 0 0 0 40.55 224h174.9a24.35 24.35 0 0 0 21.33-12.19 23.51 23.51 0 0 0 .02-23.72Zm-13.87 15.71a8.5 8.5 0 0 1-7.48 4.2H40.55a8.5 8.5 0 0 1-7.48-4.2 7.59 7.59 0 0 1 0-7.72l87.45-151.87a8.75 8.75 0 0 1 15 0l87.45 151.87a7.59 7.59 0 0 1-.04 7.72ZM120 144v-40a8 8 0 0 1 16 0v40a8 8 0 0 1-16 0Zm20 36a12 12 0 1 1-12-12 12 12 0 0 1 12 12Z\"})}),ha=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M165.66 101.66 139.31 128l26.35 26.34a8 8 0 0 1-11.32 11.32L128 139.31l-26.34 26.35a8 8 0 0 1-11.32-11.32L116.69 128l-26.35-26.34a8 8 0 0 1 11.32-11.32L128 116.69l26.34-26.35a8 8 0 0 1 11.32 11.32ZM232 128A104 104 0 1 1 128 24a104.11 104.11 0 0 1 104 104Zm-16 0a88 88 0 1 0-88 88 88.1 88.1 0 0 0 88-88Z\"})}),ta=({className:l,...e})=>a(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",fill:\"currentColor\",viewBox:\"0 0 256 256\",className:s(\"sds-icon\",l),\"aria-hidden\":\"true\",...e,children:a(\"path\",{d:\"M205.66 194.34a8 8 0 0 1-11.32 11.32L128 139.31l-66.34 66.35a8 8 0 0 1-11.32-11.32L116.69 128 50.34 61.66a8 8 0 0 1 11.32-11.32L128 116.69l66.34-66.35a8 8 0 0 1 11.32 11.32L139.31 128Z\"})}),wa=({className:l,...e})=>a(ra,{className:s(\"sds-icon sds-icon--spinner\",l),...e});export{l as ArrowCircleLeftIcon,e as ArrowCircleRightIcon,r as ArrowLeftIcon,i as ArrowRightIcon,c as ArrowSquareOutIcon,o as ArrowUUpLeftIcon,n as ArrowUUpRightIcon,t as BellIcon,h as BellRingingIcon,w as BookmarkSimpleFillIcon,d as BookmarkSimpleIcon,m as CalendarBlankIcon,v as CalendarPlusIcon,g as CaretCircleDownIcon,Z as CaretCircleLeftIcon,p as CaretCircleRightIcon,u as CaretCircleUpIcon,x as CaretDownIcon,N as CaretLeftIcon,C as CaretRightIcon,M as CaretUpIcon,H as CheckCircleIcon,L as CheckIcon,f as CircleIcon,B as ClockIcon,I as CopyIcon,V as DotsSixVerticalIcon,A as DotsThreeCircleIcon,S as DotsThreeIcon,k as DownloadSimpleIcon,D as EnvelopeIcon,P as ExportIcon,U as FloppyDiskIcon,q as FunnelIcon,R as GearIcon,y as InfoIcon,F as LinkSimpleIcon,G as ListIcon,T as LockSimpleIcon,O as LockSimpleOpenIcon,E as MagnifyingGlassIcon,X as MapPinIcon,j as MinusCircleIcon,W as MinusIcon,b as PaperclipIcon,z as PasswordIcon,J as PencilIcon,K as PhoneIcon,Q as PlusCircleIcon,Y as PlusIcon,$ as ShoppingCartIcon,_ as SignInIcon,aa as SignOutIcon,sa as SlidersIcon,la as SortAscendingIcon,ea as SortDescendingIcon,ra as SpinnerGapIcon,wa as SpinnerIcon,ia as TrashIcon,ca as UploadSimpleIcon,oa as UserCircleIcon,na as WarningIcon,ha as XCircleIcon,ta as XIcon};\n//# sourceMappingURL=index.js.map\n","import React, { HTMLAttributes } from \"react\";\nimport { CaretRightIcon, CaretLeftIcon } from \"@sikt/sds-icons\";\nimport { clsx } from \"clsx\";\nimport \"./pagination.pcss\";\n\nexport interface PaginationProps extends HTMLAttributes<HTMLElement> {\n \"aria-label\": string;\n ariaLabelPrevious?: string;\n ariaLabelNext?: string;\n ariaLabelItem?: string;\n count: number;\n currentIndex: number;\n /** Total limit of elements, this includes previous/next/first/last. Minimum is 7 (previous/next/first/last/current/) */\n limit?: number;\n handleClick: (index: number) => void;\n className?: string;\n}\n\nexport const Pagination = ({\n \"aria-label\": ariaLabel,\n ariaLabelNext = \"Vis neste side\",\n ariaLabelPrevious = \"Vis forrige side\",\n ariaLabelItem = \"Vis side\",\n count,\n currentIndex,\n limit = 7,\n handleClick,\n className,\n ...rest\n}: PaginationProps) => {\n const constantCount = 2;\n const delimiter = Math.ceil(limit / 2) - constantCount - 1;\n const max = currentIndex + delimiter;\n const min = currentIndex - delimiter;\n const hasMaxSpacer = count - 1 > max;\n const hasMinSpacer = 1 < min;\n const maxModifier = count - 1 - max - 1;\n const minModifier = min - 1;\n const hasLessBeforeIndex = minModifier < 0;\n const hasLessAfterIndex = maxModifier < 0;\n let maxLimit = hasMaxSpacer ? max - 1 : max;\n maxLimit = hasLessBeforeIndex ? maxLimit - minModifier : maxLimit;\n let minLimit = hasMinSpacer ? min + 1 : min;\n minLimit = hasLessAfterIndex ? minLimit + maxModifier : minLimit;\n\n return (\n <nav\n className={clsx(\"sds-pagination\", className)}\n aria-label={ariaLabel}\n {...rest}\n >\n <ol className=\"sds-pagination__list\">\n <li className=\"sds-pagination__list-item\">\n <button\n className=\"sds-pagination__button\"\n aria-label={`${ariaLabelPrevious} ${currentIndex}`}\n disabled={currentIndex === 0}\n onClick={() => handleClick(currentIndex - 1)}\n >\n <CaretLeftIcon />\n </button>\n </li>\n {[...Array(count).keys()].map((value) => {\n if (\n value === 0 ||\n value === count - 1 ||\n (value >= minLimit && value <= maxLimit)\n ) {\n return (\n <li className=\"sds-pagination__list-item\" key={value}>\n <button\n className=\"sds-pagination__button\"\n aria-current={value === currentIndex ? true : undefined}\n aria-label={`${ariaLabelItem} ${value + 1}`}\n disabled={value === currentIndex}\n onClick={() => handleClick(value)}\n >\n {value + 1}\n </button>\n </li>\n );\n } else if (value == maxLimit + 1 || value == minLimit - 1) {\n return (\n <li className=\"sds-pagination__list-item\" key={value}>\n <div className=\"sds-pagination__button sds-pagination__button--spacer\">\n …\n </div>\n </li>\n );\n }\n })}\n <li className=\"sds-pagination__list-item\">\n <button\n className=\"sds-pagination__button\"\n aria-label={`${ariaLabelNext} ${currentIndex + 2}`}\n disabled={currentIndex === count - 1}\n onClick={() => handleClick(currentIndex + 1)}\n >\n <CaretRightIcon />\n </button>\n </li>\n </ol>\n </nav>\n );\n};\n"],"names":["N","className","l","e","a","xmlns","fill","viewBox","s","children","d","C","Pagination","ariaLabel","ariaLabelNext","ariaLabelPrevious","ariaLabelItem","count","currentIndex","limit","handleClick","rest","delimiter","Math","ceil","max","min","maxModifier","minModifier","maxLimit","minLimit","_jsx","clsx","_jsxs","disabled","onClick","CaretLeftIcon","Array","keys","map","value","undefined","CaretRightIcon"],"mappings":"iFAAkE,MAA2zOA,EAAE,EAAEC,UAAUC,KAAKC,KAAKC,EAAE,MAAM,CAACC,MAAM,6BAA6BC,KAAK,eAAeC,QAAQ,cAAcN,UAAUO,EAAE,WAAWN,GAAG,cAAc,UAAUC,EAAEM,SAASL,EAAE,OAAO,CAACM,EAAE,2GAA2GC,EAAE,EAAEV,UAAUC,KAAKC,KAAKC,EAAE,MAAM,CAACC,MAAM,6BAA6BC,KAAK,eAAeC,QAAQ,cAAcN,UAAUO,EAAE,WAAWN,GAAG,cAAc,UAAUC,EAAEM,SAASL,EAAE,OAAO,CAACM,EAAE,uHCkBz0PE,EAAa,EACxB,aAAcC,EACdC,gBAAgB,iBAChBC,oBAAoB,mBACpBC,gBAAgB,WAChBC,QACAC,eACAC,QAAQ,EACRC,cACAnB,eACGoB,MAEH,MACMC,EAAYC,KAAKC,KAAKL,EAAQ,GADd,EACmC,EACnDM,EAAMP,EAAeI,EACrBI,EAAMR,EAAeI,EAGrBK,EAAcV,EAAQ,EAAIQ,EAAM,EAChCG,EAAcF,EAAM,EAG1B,IAAIG,EANiBZ,EAAQ,EAAIQ,EAMHA,EAAM,EAAIA,EACxCI,EAH2BD,EAAc,EAGTC,EAAWD,EAAcC,EACzD,IAAIC,EAPiB,EAAIJ,EAOKA,EAAM,EAAIA,EAGxC,OAFAI,EAJ0BH,EAAc,EAITG,EAAWH,EAAcG,EAGtDC,EACE,MAAA,CAAA9B,UAAW+B,EAAK,iBAAkB/B,gBACtBY,KACRQ,EAAIZ,SAERwB,QAAIhC,UAAU,uBAAsBQ,SAAA,CAClCsB,QAAI9B,UAAU,4BAA2BQ,SACvCsB,YACE9B,UAAU,yBAAwB,aACtB,GAAGc,KAAqBG,IACpCgB,SAA2B,IAAjBhB,EACViB,QAAS,IAAMf,EAAYF,EAAe,GAE1CT,SAAAsB,EAACK,EAAgB,CAAA,OAGpB,IAAIC,MAAMpB,GAAOqB,QAAQC,KAAKC,GAEjB,IAAVA,GACAA,IAAUvB,EAAQ,GACjBuB,GAASV,GAAYU,GAASX,EAG7BE,EAAI,KAAA,CAAA9B,UAAU,qCACZ8B,EACE,SAAA,CAAA9B,UAAU,yBACI,eAAAuC,IAAUtB,QAAsBuB,EAAS,aAC3C,GAAGzB,KAAiBwB,EAAQ,IACxCN,SAAUM,IAAUtB,EACpBiB,QAAS,IAAMf,EAAYoB,GAAM/B,SAEhC+B,EAAQ,KARkCA,GAYxCA,GAASX,EAAW,GAAKW,GAASV,EAAW,EAEpDC,EAAA,KAAA,CAAI9B,UAAU,4BACZQ,SAAAsB,EAAA,MAAA,CAAK9B,UAAU,wDAETQ,SAAA,OAHuC+B,QAF5C,IAUTT,EAAI,KAAA,CAAA9B,UAAU,4BAA2BQ,SACvCsB,EACE,SAAA,CAAA9B,UAAU,sCACE,GAAGa,KAAiBI,EAAe,IAC/CgB,SAAUhB,IAAiBD,EAAQ,EACnCkB,QAAS,IAAMf,EAAYF,EAAe,GAAET,SAE5CsB,EAACW,EAAc,YAKvB"}
|
package/package.json
CHANGED
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sikt/sds-pagination",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "1.0.0",
|
|
4
4
|
"license": "UNLICENSED",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"module": "dist/index.js",
|
|
7
|
+
"types": "dist/index.d.ts",
|
|
7
8
|
"style": "dist/index.css",
|
|
8
9
|
"files": [
|
|
9
10
|
"dist"
|
|
@@ -12,10 +13,12 @@
|
|
|
12
13
|
"build": "rollup -c ../../rollup.config.mjs"
|
|
13
14
|
},
|
|
14
15
|
"dependencies": {
|
|
15
|
-
"@sikt/sds-
|
|
16
|
+
"@sikt/sds-core": "^1.0.0",
|
|
17
|
+
"@sikt/sds-icons": "^1.0.0"
|
|
16
18
|
},
|
|
17
19
|
"peerDependencies": {
|
|
18
|
-
"@
|
|
20
|
+
"@types/react": "^18.0.0",
|
|
21
|
+
"@types/react-dom": "^18.0.0",
|
|
19
22
|
"clsx": "^1.2.1",
|
|
20
23
|
"react": "^18.0.0",
|
|
21
24
|
"react-dom": "^18.0.0"
|