@nysds/nys-pagination 1.10.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.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./nys-pagination";
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { LitElement, TemplateResult } from "lit";
|
|
2
|
+
export declare class NysPagination extends LitElement {
|
|
3
|
+
id: string;
|
|
4
|
+
name: string;
|
|
5
|
+
currentPage: number;
|
|
6
|
+
totalPages: number;
|
|
7
|
+
_twoBeforeLast: boolean;
|
|
8
|
+
static styles: import("lit").CSSResult;
|
|
9
|
+
/**************** Lifecycle Methods ****************/
|
|
10
|
+
constructor();
|
|
11
|
+
updated(changedProps: Map<string, unknown>): void;
|
|
12
|
+
connectedCallback(): void;
|
|
13
|
+
/******************** Functions ********************/
|
|
14
|
+
private _clampPage;
|
|
15
|
+
private renderPageButtons;
|
|
16
|
+
/****************** Event Handlers ******************/
|
|
17
|
+
private _handlePageClick;
|
|
18
|
+
render(): TemplateResult<1> | null;
|
|
19
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,804 @@
|
|
|
1
|
+
import { css as at, LitElement as ht, html as A } from "lit";
|
|
2
|
+
/*!
|
|
3
|
+
* ▒█▄░▒█ ▒█░░▒█ ▒█▀▀▀█ ▒█▀▀▄ ▒█▀▀▀█
|
|
4
|
+
* ▒█▒█▒█ ▒█▄▄▄█ ░▀▀▀▄▄ ▒█░▒█ ░▀▀▀▄▄
|
|
5
|
+
* ▒█░░▀█ ░░▒█░░ ▒█▄▄▄█ ▒█▄▄▀ ▒█▄▄▄█
|
|
6
|
+
*
|
|
7
|
+
* Pagination Component
|
|
8
|
+
* Part of the New York State Design System
|
|
9
|
+
* Repository: https://github.com/its-hcd/nysds
|
|
10
|
+
* License: MIT
|
|
11
|
+
*/
|
|
12
|
+
/**
|
|
13
|
+
* @license
|
|
14
|
+
* Copyright 2019 Google LLC
|
|
15
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
16
|
+
*/
|
|
17
|
+
const M = globalThis, D = M.ShadowRoot && (M.ShadyCSS === void 0 || M.ShadyCSS.nativeShadow) && "adoptedStyleSheets" in Document.prototype && "replace" in CSSStyleSheet.prototype, st = Symbol(), J = /* @__PURE__ */ new WeakMap();
|
|
18
|
+
let lt = class {
|
|
19
|
+
constructor(t, e, s) {
|
|
20
|
+
if (this._$cssResult$ = !0, s !== st) throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");
|
|
21
|
+
this.cssText = t, this.t = e;
|
|
22
|
+
}
|
|
23
|
+
get styleSheet() {
|
|
24
|
+
let t = this.o;
|
|
25
|
+
const e = this.t;
|
|
26
|
+
if (D && t === void 0) {
|
|
27
|
+
const s = e !== void 0 && e.length === 1;
|
|
28
|
+
s && (t = J.get(e)), t === void 0 && ((this.o = t = new CSSStyleSheet()).replaceSync(this.cssText), s && J.set(e, t));
|
|
29
|
+
}
|
|
30
|
+
return t;
|
|
31
|
+
}
|
|
32
|
+
toString() {
|
|
33
|
+
return this.cssText;
|
|
34
|
+
}
|
|
35
|
+
};
|
|
36
|
+
const ct = (i) => new lt(typeof i == "string" ? i : i + "", void 0, st), ut = (i, t) => {
|
|
37
|
+
if (D) i.adoptedStyleSheets = t.map((e) => e instanceof CSSStyleSheet ? e : e.styleSheet);
|
|
38
|
+
else for (const e of t) {
|
|
39
|
+
const s = document.createElement("style"), n = M.litNonce;
|
|
40
|
+
n !== void 0 && s.setAttribute("nonce", n), s.textContent = e.cssText, i.appendChild(s);
|
|
41
|
+
}
|
|
42
|
+
}, K = D ? (i) => i : (i) => i instanceof CSSStyleSheet ? ((t) => {
|
|
43
|
+
let e = "";
|
|
44
|
+
for (const s of t.cssRules) e += s.cssText;
|
|
45
|
+
return ct(e);
|
|
46
|
+
})(i) : i;
|
|
47
|
+
/**
|
|
48
|
+
* @license
|
|
49
|
+
* Copyright 2017 Google LLC
|
|
50
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
51
|
+
*/
|
|
52
|
+
const { is: dt, defineProperty: pt, getOwnPropertyDescriptor: yt, getOwnPropertyNames: gt, getOwnPropertySymbols: ft, getPrototypeOf: bt } = Object, f = globalThis, Z = f.trustedTypes, $t = Z ? Z.emptyScript : "", B = f.reactiveElementPolyfillSupport, S = (i, t) => i, O = { toAttribute(i, t) {
|
|
53
|
+
switch (t) {
|
|
54
|
+
case Boolean:
|
|
55
|
+
i = i ? $t : null;
|
|
56
|
+
break;
|
|
57
|
+
case Object:
|
|
58
|
+
case Array:
|
|
59
|
+
i = i == null ? i : JSON.stringify(i);
|
|
60
|
+
}
|
|
61
|
+
return i;
|
|
62
|
+
}, fromAttribute(i, t) {
|
|
63
|
+
let e = i;
|
|
64
|
+
switch (t) {
|
|
65
|
+
case Boolean:
|
|
66
|
+
e = i !== null;
|
|
67
|
+
break;
|
|
68
|
+
case Number:
|
|
69
|
+
e = i === null ? null : Number(i);
|
|
70
|
+
break;
|
|
71
|
+
case Object:
|
|
72
|
+
case Array:
|
|
73
|
+
try {
|
|
74
|
+
e = JSON.parse(i);
|
|
75
|
+
} catch {
|
|
76
|
+
e = null;
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
return e;
|
|
80
|
+
} }, W = (i, t) => !dt(i, t), F = { attribute: !0, type: String, converter: O, reflect: !1, hasChanged: W };
|
|
81
|
+
Symbol.metadata ?? (Symbol.metadata = Symbol("metadata")), f.litPropertyMetadata ?? (f.litPropertyMetadata = /* @__PURE__ */ new WeakMap());
|
|
82
|
+
class P extends HTMLElement {
|
|
83
|
+
static addInitializer(t) {
|
|
84
|
+
this._$Ei(), (this.l ?? (this.l = [])).push(t);
|
|
85
|
+
}
|
|
86
|
+
static get observedAttributes() {
|
|
87
|
+
return this.finalize(), this._$Eh && [...this._$Eh.keys()];
|
|
88
|
+
}
|
|
89
|
+
static createProperty(t, e = F) {
|
|
90
|
+
if (e.state && (e.attribute = !1), this._$Ei(), this.elementProperties.set(t, e), !e.noAccessor) {
|
|
91
|
+
const s = Symbol(), n = this.getPropertyDescriptor(t, s, e);
|
|
92
|
+
n !== void 0 && pt(this.prototype, t, n);
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
static getPropertyDescriptor(t, e, s) {
|
|
96
|
+
const { get: n, set: o } = yt(this.prototype, t) ?? { get() {
|
|
97
|
+
return this[e];
|
|
98
|
+
}, set(r) {
|
|
99
|
+
this[e] = r;
|
|
100
|
+
} };
|
|
101
|
+
return { get() {
|
|
102
|
+
return n == null ? void 0 : n.call(this);
|
|
103
|
+
}, set(r) {
|
|
104
|
+
const h = n == null ? void 0 : n.call(this);
|
|
105
|
+
o.call(this, r), this.requestUpdate(t, h, s);
|
|
106
|
+
}, configurable: !0, enumerable: !0 };
|
|
107
|
+
}
|
|
108
|
+
static getPropertyOptions(t) {
|
|
109
|
+
return this.elementProperties.get(t) ?? F;
|
|
110
|
+
}
|
|
111
|
+
static _$Ei() {
|
|
112
|
+
if (this.hasOwnProperty(S("elementProperties"))) return;
|
|
113
|
+
const t = bt(this);
|
|
114
|
+
t.finalize(), t.l !== void 0 && (this.l = [...t.l]), this.elementProperties = new Map(t.elementProperties);
|
|
115
|
+
}
|
|
116
|
+
static finalize() {
|
|
117
|
+
if (this.hasOwnProperty(S("finalized"))) return;
|
|
118
|
+
if (this.finalized = !0, this._$Ei(), this.hasOwnProperty(S("properties"))) {
|
|
119
|
+
const e = this.properties, s = [...gt(e), ...ft(e)];
|
|
120
|
+
for (const n of s) this.createProperty(n, e[n]);
|
|
121
|
+
}
|
|
122
|
+
const t = this[Symbol.metadata];
|
|
123
|
+
if (t !== null) {
|
|
124
|
+
const e = litPropertyMetadata.get(t);
|
|
125
|
+
if (e !== void 0) for (const [s, n] of e) this.elementProperties.set(s, n);
|
|
126
|
+
}
|
|
127
|
+
this._$Eh = /* @__PURE__ */ new Map();
|
|
128
|
+
for (const [e, s] of this.elementProperties) {
|
|
129
|
+
const n = this._$Eu(e, s);
|
|
130
|
+
n !== void 0 && this._$Eh.set(n, e);
|
|
131
|
+
}
|
|
132
|
+
this.elementStyles = this.finalizeStyles(this.styles);
|
|
133
|
+
}
|
|
134
|
+
static finalizeStyles(t) {
|
|
135
|
+
const e = [];
|
|
136
|
+
if (Array.isArray(t)) {
|
|
137
|
+
const s = new Set(t.flat(1 / 0).reverse());
|
|
138
|
+
for (const n of s) e.unshift(K(n));
|
|
139
|
+
} else t !== void 0 && e.push(K(t));
|
|
140
|
+
return e;
|
|
141
|
+
}
|
|
142
|
+
static _$Eu(t, e) {
|
|
143
|
+
const s = e.attribute;
|
|
144
|
+
return s === !1 ? void 0 : typeof s == "string" ? s : typeof t == "string" ? t.toLowerCase() : void 0;
|
|
145
|
+
}
|
|
146
|
+
constructor() {
|
|
147
|
+
super(), this._$Ep = void 0, this.isUpdatePending = !1, this.hasUpdated = !1, this._$Em = null, this._$Ev();
|
|
148
|
+
}
|
|
149
|
+
_$Ev() {
|
|
150
|
+
var t;
|
|
151
|
+
this._$ES = new Promise((e) => this.enableUpdating = e), this._$AL = /* @__PURE__ */ new Map(), this._$E_(), this.requestUpdate(), (t = this.constructor.l) == null || t.forEach((e) => e(this));
|
|
152
|
+
}
|
|
153
|
+
addController(t) {
|
|
154
|
+
var e;
|
|
155
|
+
(this._$EO ?? (this._$EO = /* @__PURE__ */ new Set())).add(t), this.renderRoot !== void 0 && this.isConnected && ((e = t.hostConnected) == null || e.call(t));
|
|
156
|
+
}
|
|
157
|
+
removeController(t) {
|
|
158
|
+
var e;
|
|
159
|
+
(e = this._$EO) == null || e.delete(t);
|
|
160
|
+
}
|
|
161
|
+
_$E_() {
|
|
162
|
+
const t = /* @__PURE__ */ new Map(), e = this.constructor.elementProperties;
|
|
163
|
+
for (const s of e.keys()) this.hasOwnProperty(s) && (t.set(s, this[s]), delete this[s]);
|
|
164
|
+
t.size > 0 && (this._$Ep = t);
|
|
165
|
+
}
|
|
166
|
+
createRenderRoot() {
|
|
167
|
+
const t = this.shadowRoot ?? this.attachShadow(this.constructor.shadowRootOptions);
|
|
168
|
+
return ut(t, this.constructor.elementStyles), t;
|
|
169
|
+
}
|
|
170
|
+
connectedCallback() {
|
|
171
|
+
var t;
|
|
172
|
+
this.renderRoot ?? (this.renderRoot = this.createRenderRoot()), this.enableUpdating(!0), (t = this._$EO) == null || t.forEach((e) => {
|
|
173
|
+
var s;
|
|
174
|
+
return (s = e.hostConnected) == null ? void 0 : s.call(e);
|
|
175
|
+
});
|
|
176
|
+
}
|
|
177
|
+
enableUpdating(t) {
|
|
178
|
+
}
|
|
179
|
+
disconnectedCallback() {
|
|
180
|
+
var t;
|
|
181
|
+
(t = this._$EO) == null || t.forEach((e) => {
|
|
182
|
+
var s;
|
|
183
|
+
return (s = e.hostDisconnected) == null ? void 0 : s.call(e);
|
|
184
|
+
});
|
|
185
|
+
}
|
|
186
|
+
attributeChangedCallback(t, e, s) {
|
|
187
|
+
this._$AK(t, s);
|
|
188
|
+
}
|
|
189
|
+
_$EC(t, e) {
|
|
190
|
+
var o;
|
|
191
|
+
const s = this.constructor.elementProperties.get(t), n = this.constructor._$Eu(t, s);
|
|
192
|
+
if (n !== void 0 && s.reflect === !0) {
|
|
193
|
+
const r = (((o = s.converter) == null ? void 0 : o.toAttribute) !== void 0 ? s.converter : O).toAttribute(e, s.type);
|
|
194
|
+
this._$Em = t, r == null ? this.removeAttribute(n) : this.setAttribute(n, r), this._$Em = null;
|
|
195
|
+
}
|
|
196
|
+
}
|
|
197
|
+
_$AK(t, e) {
|
|
198
|
+
var o;
|
|
199
|
+
const s = this.constructor, n = s._$Eh.get(t);
|
|
200
|
+
if (n !== void 0 && this._$Em !== n) {
|
|
201
|
+
const r = s.getPropertyOptions(n), h = typeof r.converter == "function" ? { fromAttribute: r.converter } : ((o = r.converter) == null ? void 0 : o.fromAttribute) !== void 0 ? r.converter : O;
|
|
202
|
+
this._$Em = n, this[n] = h.fromAttribute(e, r.type), this._$Em = null;
|
|
203
|
+
}
|
|
204
|
+
}
|
|
205
|
+
requestUpdate(t, e, s) {
|
|
206
|
+
if (t !== void 0) {
|
|
207
|
+
if (s ?? (s = this.constructor.getPropertyOptions(t)), !(s.hasChanged ?? W)(this[t], e)) return;
|
|
208
|
+
this.P(t, e, s);
|
|
209
|
+
}
|
|
210
|
+
this.isUpdatePending === !1 && (this._$ES = this._$ET());
|
|
211
|
+
}
|
|
212
|
+
P(t, e, s) {
|
|
213
|
+
this._$AL.has(t) || this._$AL.set(t, e), s.reflect === !0 && this._$Em !== t && (this._$Ej ?? (this._$Ej = /* @__PURE__ */ new Set())).add(t);
|
|
214
|
+
}
|
|
215
|
+
async _$ET() {
|
|
216
|
+
this.isUpdatePending = !0;
|
|
217
|
+
try {
|
|
218
|
+
await this._$ES;
|
|
219
|
+
} catch (e) {
|
|
220
|
+
Promise.reject(e);
|
|
221
|
+
}
|
|
222
|
+
const t = this.scheduleUpdate();
|
|
223
|
+
return t != null && await t, !this.isUpdatePending;
|
|
224
|
+
}
|
|
225
|
+
scheduleUpdate() {
|
|
226
|
+
return this.performUpdate();
|
|
227
|
+
}
|
|
228
|
+
performUpdate() {
|
|
229
|
+
var s;
|
|
230
|
+
if (!this.isUpdatePending) return;
|
|
231
|
+
if (!this.hasUpdated) {
|
|
232
|
+
if (this.renderRoot ?? (this.renderRoot = this.createRenderRoot()), this._$Ep) {
|
|
233
|
+
for (const [o, r] of this._$Ep) this[o] = r;
|
|
234
|
+
this._$Ep = void 0;
|
|
235
|
+
}
|
|
236
|
+
const n = this.constructor.elementProperties;
|
|
237
|
+
if (n.size > 0) for (const [o, r] of n) r.wrapped !== !0 || this._$AL.has(o) || this[o] === void 0 || this.P(o, this[o], r);
|
|
238
|
+
}
|
|
239
|
+
let t = !1;
|
|
240
|
+
const e = this._$AL;
|
|
241
|
+
try {
|
|
242
|
+
t = this.shouldUpdate(e), t ? (this.willUpdate(e), (s = this._$EO) == null || s.forEach((n) => {
|
|
243
|
+
var o;
|
|
244
|
+
return (o = n.hostUpdate) == null ? void 0 : o.call(n);
|
|
245
|
+
}), this.update(e)) : this._$EU();
|
|
246
|
+
} catch (n) {
|
|
247
|
+
throw t = !1, this._$EU(), n;
|
|
248
|
+
}
|
|
249
|
+
t && this._$AE(e);
|
|
250
|
+
}
|
|
251
|
+
willUpdate(t) {
|
|
252
|
+
}
|
|
253
|
+
_$AE(t) {
|
|
254
|
+
var e;
|
|
255
|
+
(e = this._$EO) == null || e.forEach((s) => {
|
|
256
|
+
var n;
|
|
257
|
+
return (n = s.hostUpdated) == null ? void 0 : n.call(s);
|
|
258
|
+
}), this.hasUpdated || (this.hasUpdated = !0, this.firstUpdated(t)), this.updated(t);
|
|
259
|
+
}
|
|
260
|
+
_$EU() {
|
|
261
|
+
this._$AL = /* @__PURE__ */ new Map(), this.isUpdatePending = !1;
|
|
262
|
+
}
|
|
263
|
+
get updateComplete() {
|
|
264
|
+
return this.getUpdateComplete();
|
|
265
|
+
}
|
|
266
|
+
getUpdateComplete() {
|
|
267
|
+
return this._$ES;
|
|
268
|
+
}
|
|
269
|
+
shouldUpdate(t) {
|
|
270
|
+
return !0;
|
|
271
|
+
}
|
|
272
|
+
update(t) {
|
|
273
|
+
this._$Ej && (this._$Ej = this._$Ej.forEach((e) => this._$EC(e, this[e]))), this._$EU();
|
|
274
|
+
}
|
|
275
|
+
updated(t) {
|
|
276
|
+
}
|
|
277
|
+
firstUpdated(t) {
|
|
278
|
+
}
|
|
279
|
+
}
|
|
280
|
+
P.elementStyles = [], P.shadowRootOptions = { mode: "open" }, P[S("elementProperties")] = /* @__PURE__ */ new Map(), P[S("finalized")] = /* @__PURE__ */ new Map(), B == null || B({ ReactiveElement: P }), (f.reactiveElementVersions ?? (f.reactiveElementVersions = [])).push("2.0.4");
|
|
281
|
+
/**
|
|
282
|
+
* @license
|
|
283
|
+
* Copyright 2017 Google LLC
|
|
284
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
285
|
+
*/
|
|
286
|
+
const _t = { attribute: !0, type: String, converter: O, reflect: !1, hasChanged: W }, vt = (i = _t, t, e) => {
|
|
287
|
+
const { kind: s, metadata: n } = e;
|
|
288
|
+
let o = globalThis.litPropertyMetadata.get(n);
|
|
289
|
+
if (o === void 0 && globalThis.litPropertyMetadata.set(n, o = /* @__PURE__ */ new Map()), o.set(e.name, i), s === "accessor") {
|
|
290
|
+
const { name: r } = e;
|
|
291
|
+
return { set(h) {
|
|
292
|
+
const a = t.get.call(this);
|
|
293
|
+
t.set.call(this, h), this.requestUpdate(r, a, i);
|
|
294
|
+
}, init(h) {
|
|
295
|
+
return h !== void 0 && this.P(r, void 0, i), h;
|
|
296
|
+
} };
|
|
297
|
+
}
|
|
298
|
+
if (s === "setter") {
|
|
299
|
+
const { name: r } = e;
|
|
300
|
+
return function(h) {
|
|
301
|
+
const a = this[r];
|
|
302
|
+
t.call(this, h), this.requestUpdate(r, a, i);
|
|
303
|
+
};
|
|
304
|
+
}
|
|
305
|
+
throw Error("Unsupported decorator location: " + s);
|
|
306
|
+
};
|
|
307
|
+
function U(i) {
|
|
308
|
+
return (t, e) => typeof e == "object" ? vt(i, t, e) : ((s, n, o) => {
|
|
309
|
+
const r = n.hasOwnProperty(o);
|
|
310
|
+
return n.constructor.createProperty(o, r ? { ...s, wrapped: !0 } : s), r ? Object.getOwnPropertyDescriptor(n, o) : void 0;
|
|
311
|
+
})(i, t, e);
|
|
312
|
+
}
|
|
313
|
+
const mt = at`
|
|
314
|
+
:host {
|
|
315
|
+
/* Anything that can be overridden should be defined here */
|
|
316
|
+
|
|
317
|
+
/* Global Pagination Styles */
|
|
318
|
+
--_nys-pagination-width: fit-content;
|
|
319
|
+
--_nys-pagination-height: var(--nys-size-500, 40px);
|
|
320
|
+
--_nys-pagination-radius: var(--nys-radius-xl, 12px);
|
|
321
|
+
--_nys-pagination-gap: var(--nys-space-100, 8px);
|
|
322
|
+
|
|
323
|
+
/* Typography */
|
|
324
|
+
--_nys-pagination-font-size: var(--nys-font-size-ui-md, 16px);
|
|
325
|
+
--_nys-pagination-font-weight: var(--nys-font-weight-semibold, 600);
|
|
326
|
+
--_nys-pagination-line-height: var(--nys-font-lineheight-ui-md, 24px);
|
|
327
|
+
--_nys-pagination-font-family: var(
|
|
328
|
+
--nys-font-family-ui,
|
|
329
|
+
var(
|
|
330
|
+
--nys-font-family-sans,
|
|
331
|
+
"Proxima Nova",
|
|
332
|
+
"Helvetica Neue",
|
|
333
|
+
"Helvetica",
|
|
334
|
+
"Arial",
|
|
335
|
+
sans-serif
|
|
336
|
+
)
|
|
337
|
+
);
|
|
338
|
+
}
|
|
339
|
+
|
|
340
|
+
.nys-pagination {
|
|
341
|
+
width: var(--_nys-pagination-width);
|
|
342
|
+
height: var(--_nys-pagination-height);
|
|
343
|
+
border-radius: var(--_nys-pagination-radius);
|
|
344
|
+
display: flex;
|
|
345
|
+
align-items: center;
|
|
346
|
+
justify-content: center;
|
|
347
|
+
gap: var(--_nys-pagination-gap);
|
|
348
|
+
font-family: var(--_nys-pagination-font-family);
|
|
349
|
+
font-size: var(--_nys-pagination-font-size);
|
|
350
|
+
font-weight: var(--_nys-pagination-font-weight);
|
|
351
|
+
line-height: var(--_nys-pagination-line-height);
|
|
352
|
+
}
|
|
353
|
+
|
|
354
|
+
nys-button {
|
|
355
|
+
--_nys-button-height: var(--_nys-pagination-height);
|
|
356
|
+
--_nys-button-border-width: var(--nys-border-width-sm, 1px);
|
|
357
|
+
--_nys-button-border-radius--start: var(--nys-radius-md, 4px);
|
|
358
|
+
--_nys-button-border-radius--end: var(--nys-radius-md, 4px);
|
|
359
|
+
--_nys-button-padding--x: var(--nys-space-200, 16px);
|
|
360
|
+
}
|
|
361
|
+
|
|
362
|
+
nys-button[variant="outline"] {
|
|
363
|
+
--nys-button-background-color: var(--nys-color-ink-reverse, #fff);
|
|
364
|
+
--nys-button-background-color--hover: var(--nys-color-neutral-10, #f6f6f6);
|
|
365
|
+
--nys-button-background-color--active: var(--nys-color-neutral-50, #ededed);
|
|
366
|
+
--nys-button-border-color: var(--nys-color-neutral-200, #bec0c1);
|
|
367
|
+
--nys-button-border-color--hover: var(--nys-color-neutral-600, #62666a);
|
|
368
|
+
--nys-button-border-color--active: var(--nys-color-neutral-900, #1b1b1b);
|
|
369
|
+
--nys-button-color: var(--nys-color-link, #004dd1);
|
|
370
|
+
--nys-button-color--hover: var(--nys-color-link-strong, #003ba1);
|
|
371
|
+
--nys-button-color--active: var(--nys-color-link-strong, #003ba1);
|
|
372
|
+
}
|
|
373
|
+
|
|
374
|
+
nys-button[variant="filled"] {
|
|
375
|
+
--nys-button-background-color: var(--nys-color-link, #004dd1);
|
|
376
|
+
--nys-button-background-color--hover: var(
|
|
377
|
+
--nys-color-link-strong,
|
|
378
|
+
##003ba1
|
|
379
|
+
);
|
|
380
|
+
--nys-button-background-color--active: var(
|
|
381
|
+
--nys-color-link-strongest,
|
|
382
|
+
##002971
|
|
383
|
+
);
|
|
384
|
+
--nys-button-border-color: var(--nys-color-link, #004dd1);
|
|
385
|
+
--nys-button-border-color--hover: var(--nys-color-link-strong, ##003ba1);
|
|
386
|
+
--nys-button-border-color--active: var(
|
|
387
|
+
--nys-color-link-strongest,
|
|
388
|
+
##002971
|
|
389
|
+
);
|
|
390
|
+
--nys-button-color: var(--nys-color-ink-reverse, #fff);
|
|
391
|
+
--nys-button-color--hover: var(--nys-color-ink-reverse, #fff);
|
|
392
|
+
--nys-button-color--active: var(--nys-color-ink-reverse, #fff);
|
|
393
|
+
}
|
|
394
|
+
|
|
395
|
+
nys-button#previous,
|
|
396
|
+
nys-button#next,
|
|
397
|
+
nys-button#previous--mobile,
|
|
398
|
+
nys-button#next--mobile {
|
|
399
|
+
--nys-button-color: var(--nys-color-text, ##1b1b1b);
|
|
400
|
+
--nys-button-color--hover: var(--nys-color-text, ##1b1b1b);
|
|
401
|
+
--nys-button-color--active: var(--nys-color-text, ##1b1b1b);
|
|
402
|
+
--_nys-button-padding--x: var(--nys-space-150, 12px);
|
|
403
|
+
}
|
|
404
|
+
|
|
405
|
+
nys-button#previous--mobile,
|
|
406
|
+
nys-button#next--mobile {
|
|
407
|
+
display: none;
|
|
408
|
+
}
|
|
409
|
+
|
|
410
|
+
nys-button.spacer {
|
|
411
|
+
--nys-button-border-color: transparent;
|
|
412
|
+
--nys-button-border-color--hover: transparent;
|
|
413
|
+
--nys-button-border-color--active: transparent;
|
|
414
|
+
--nys-button-background-color: transparent;
|
|
415
|
+
--nys-button-background-color--hover: transparent;
|
|
416
|
+
--nys-button-background-color--active: transparent;
|
|
417
|
+
--nys-button-color: var(--nys-color-text, ##1b1b1b);
|
|
418
|
+
--nys-button-color--hover: var(--nys-color-text, ##1b1b1b);
|
|
419
|
+
--nys-button-color--active: var(--nys-color-text, ##1b1b1b);
|
|
420
|
+
--_nys-button-padding--x: var(--nys-space-1px, 1px);
|
|
421
|
+
--_nys-button-cursor: default;
|
|
422
|
+
}
|
|
423
|
+
|
|
424
|
+
:host([currentPage="3"]) nys-button#first-spacer,
|
|
425
|
+
:host([_twoBeforeLast]) nys-button#last-spacer {
|
|
426
|
+
display: none;
|
|
427
|
+
}
|
|
428
|
+
|
|
429
|
+
@media (min-width: 0) and (max-width: 767px) {
|
|
430
|
+
/* Mobile (XS) and Mobile Large (SM) */
|
|
431
|
+
|
|
432
|
+
/* Hide 1 less and more than currentPage */
|
|
433
|
+
nys-button#prev-page,
|
|
434
|
+
nys-button#next-page {
|
|
435
|
+
display: none;
|
|
436
|
+
}
|
|
437
|
+
|
|
438
|
+
/* Show spacer instead of 1 less and more than currentPage*/
|
|
439
|
+
:host([currentPage="3"]) nys-button#first-spacer,
|
|
440
|
+
:host([_twoBeforeLast]) nys-button#last-spacer {
|
|
441
|
+
display: block;
|
|
442
|
+
}
|
|
443
|
+
|
|
444
|
+
/* Swap to icon only previous and next buttons */
|
|
445
|
+
nys-button#previous--mobile,
|
|
446
|
+
nys-button#next--mobile {
|
|
447
|
+
display: block;
|
|
448
|
+
}
|
|
449
|
+
nys-button#previous,
|
|
450
|
+
nys-button#next {
|
|
451
|
+
display: none;
|
|
452
|
+
}
|
|
453
|
+
}
|
|
454
|
+
`;
|
|
455
|
+
/**
|
|
456
|
+
* @license
|
|
457
|
+
* Copyright 2017 Google LLC
|
|
458
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
459
|
+
*/
|
|
460
|
+
const E = globalThis, T = E.trustedTypes, G = T ? T.createPolicy("lit-html", { createHTML: (i) => i }) : void 0, nt = "$lit$", g = `lit$${Math.random().toFixed(9).slice(2)}$`, it = "?" + g, At = `<${it}>`, v = document, L = () => v.createComment(""), w = (i) => i === null || typeof i != "object" && typeof i != "function", V = Array.isArray, Pt = (i) => V(i) || typeof (i == null ? void 0 : i[Symbol.iterator]) == "function", I = `[
|
|
461
|
+
\f\r]`, x = /<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g, X = /-->/g, Q = />/g, $ = RegExp(`>|${I}(?:([^\\s"'>=/]+)(${I}*=${I}*(?:[^
|
|
462
|
+
\f\r"'\`<>=]|("|')|))|$)`, "g"), Y = /'/g, tt = /"/g, rt = /^(?:script|style|textarea|title)$/i, C = Symbol.for("lit-noChange"), u = Symbol.for("lit-nothing"), et = /* @__PURE__ */ new WeakMap(), _ = v.createTreeWalker(v, 129);
|
|
463
|
+
function ot(i, t) {
|
|
464
|
+
if (!V(i) || !i.hasOwnProperty("raw")) throw Error("invalid template strings array");
|
|
465
|
+
return G !== void 0 ? G.createHTML(t) : t;
|
|
466
|
+
}
|
|
467
|
+
const xt = (i, t) => {
|
|
468
|
+
const e = i.length - 1, s = [];
|
|
469
|
+
let n, o = t === 2 ? "<svg>" : t === 3 ? "<math>" : "", r = x;
|
|
470
|
+
for (let h = 0; h < e; h++) {
|
|
471
|
+
const a = i[h];
|
|
472
|
+
let c, d, l = -1, p = 0;
|
|
473
|
+
for (; p < a.length && (r.lastIndex = p, d = r.exec(a), d !== null); ) p = r.lastIndex, r === x ? d[1] === "!--" ? r = X : d[1] !== void 0 ? r = Q : d[2] !== void 0 ? (rt.test(d[2]) && (n = RegExp("</" + d[2], "g")), r = $) : d[3] !== void 0 && (r = $) : r === $ ? d[0] === ">" ? (r = n ?? x, l = -1) : d[1] === void 0 ? l = -2 : (l = r.lastIndex - d[2].length, c = d[1], r = d[3] === void 0 ? $ : d[3] === '"' ? tt : Y) : r === tt || r === Y ? r = $ : r === X || r === Q ? r = x : (r = $, n = void 0);
|
|
474
|
+
const y = r === $ && i[h + 1].startsWith("/>") ? " " : "";
|
|
475
|
+
o += r === x ? a + At : l >= 0 ? (s.push(c), a.slice(0, l) + nt + a.slice(l) + g + y) : a + g + (l === -2 ? h : y);
|
|
476
|
+
}
|
|
477
|
+
return [ot(i, o + (i[e] || "<?>") + (t === 2 ? "</svg>" : t === 3 ? "</math>" : "")), s];
|
|
478
|
+
};
|
|
479
|
+
class k {
|
|
480
|
+
constructor({ strings: t, _$litType$: e }, s) {
|
|
481
|
+
let n;
|
|
482
|
+
this.parts = [];
|
|
483
|
+
let o = 0, r = 0;
|
|
484
|
+
const h = t.length - 1, a = this.parts, [c, d] = xt(t, e);
|
|
485
|
+
if (this.el = k.createElement(c, s), _.currentNode = this.el.content, e === 2 || e === 3) {
|
|
486
|
+
const l = this.el.content.firstChild;
|
|
487
|
+
l.replaceWith(...l.childNodes);
|
|
488
|
+
}
|
|
489
|
+
for (; (n = _.nextNode()) !== null && a.length < h; ) {
|
|
490
|
+
if (n.nodeType === 1) {
|
|
491
|
+
if (n.hasAttributes()) for (const l of n.getAttributeNames()) if (l.endsWith(nt)) {
|
|
492
|
+
const p = d[r++], y = n.getAttribute(l).split(g), N = /([.?@])?(.*)/.exec(p);
|
|
493
|
+
a.push({ type: 1, index: o, name: N[2], strings: y, ctor: N[1] === "." ? Et : N[1] === "?" ? wt : N[1] === "@" ? Ct : z }), n.removeAttribute(l);
|
|
494
|
+
} else l.startsWith(g) && (a.push({ type: 6, index: o }), n.removeAttribute(l));
|
|
495
|
+
if (rt.test(n.tagName)) {
|
|
496
|
+
const l = n.textContent.split(g), p = l.length - 1;
|
|
497
|
+
if (p > 0) {
|
|
498
|
+
n.textContent = T ? T.emptyScript : "";
|
|
499
|
+
for (let y = 0; y < p; y++) n.append(l[y], L()), _.nextNode(), a.push({ type: 2, index: ++o });
|
|
500
|
+
n.append(l[p], L());
|
|
501
|
+
}
|
|
502
|
+
}
|
|
503
|
+
} else if (n.nodeType === 8) if (n.data === it) a.push({ type: 2, index: o });
|
|
504
|
+
else {
|
|
505
|
+
let l = -1;
|
|
506
|
+
for (; (l = n.data.indexOf(g, l + 1)) !== -1; ) a.push({ type: 7, index: o }), l += g.length - 1;
|
|
507
|
+
}
|
|
508
|
+
o++;
|
|
509
|
+
}
|
|
510
|
+
}
|
|
511
|
+
static createElement(t, e) {
|
|
512
|
+
const s = v.createElement("template");
|
|
513
|
+
return s.innerHTML = t, s;
|
|
514
|
+
}
|
|
515
|
+
}
|
|
516
|
+
function m(i, t, e = i, s) {
|
|
517
|
+
var r, h;
|
|
518
|
+
if (t === C) return t;
|
|
519
|
+
let n = s !== void 0 ? (r = e._$Co) == null ? void 0 : r[s] : e._$Cl;
|
|
520
|
+
const o = w(t) ? void 0 : t._$litDirective$;
|
|
521
|
+
return (n == null ? void 0 : n.constructor) !== o && ((h = n == null ? void 0 : n._$AO) == null || h.call(n, !1), o === void 0 ? n = void 0 : (n = new o(i), n._$AT(i, e, s)), s !== void 0 ? (e._$Co ?? (e._$Co = []))[s] = n : e._$Cl = n), n !== void 0 && (t = m(i, n._$AS(i, t.values), n, s)), t;
|
|
522
|
+
}
|
|
523
|
+
class St {
|
|
524
|
+
constructor(t, e) {
|
|
525
|
+
this._$AV = [], this._$AN = void 0, this._$AD = t, this._$AM = e;
|
|
526
|
+
}
|
|
527
|
+
get parentNode() {
|
|
528
|
+
return this._$AM.parentNode;
|
|
529
|
+
}
|
|
530
|
+
get _$AU() {
|
|
531
|
+
return this._$AM._$AU;
|
|
532
|
+
}
|
|
533
|
+
u(t) {
|
|
534
|
+
const { el: { content: e }, parts: s } = this._$AD, n = ((t == null ? void 0 : t.creationScope) ?? v).importNode(e, !0);
|
|
535
|
+
_.currentNode = n;
|
|
536
|
+
let o = _.nextNode(), r = 0, h = 0, a = s[0];
|
|
537
|
+
for (; a !== void 0; ) {
|
|
538
|
+
if (r === a.index) {
|
|
539
|
+
let c;
|
|
540
|
+
a.type === 2 ? c = new R(o, o.nextSibling, this, t) : a.type === 1 ? c = new a.ctor(o, a.name, a.strings, this, t) : a.type === 6 && (c = new kt(o, this, t)), this._$AV.push(c), a = s[++h];
|
|
541
|
+
}
|
|
542
|
+
r !== (a == null ? void 0 : a.index) && (o = _.nextNode(), r++);
|
|
543
|
+
}
|
|
544
|
+
return _.currentNode = v, n;
|
|
545
|
+
}
|
|
546
|
+
p(t) {
|
|
547
|
+
let e = 0;
|
|
548
|
+
for (const s of this._$AV) s !== void 0 && (s.strings !== void 0 ? (s._$AI(t, s, e), e += s.strings.length - 2) : s._$AI(t[e])), e++;
|
|
549
|
+
}
|
|
550
|
+
}
|
|
551
|
+
class R {
|
|
552
|
+
get _$AU() {
|
|
553
|
+
var t;
|
|
554
|
+
return ((t = this._$AM) == null ? void 0 : t._$AU) ?? this._$Cv;
|
|
555
|
+
}
|
|
556
|
+
constructor(t, e, s, n) {
|
|
557
|
+
this.type = 2, this._$AH = u, this._$AN = void 0, this._$AA = t, this._$AB = e, this._$AM = s, this.options = n, this._$Cv = (n == null ? void 0 : n.isConnected) ?? !0;
|
|
558
|
+
}
|
|
559
|
+
get parentNode() {
|
|
560
|
+
let t = this._$AA.parentNode;
|
|
561
|
+
const e = this._$AM;
|
|
562
|
+
return e !== void 0 && (t == null ? void 0 : t.nodeType) === 11 && (t = e.parentNode), t;
|
|
563
|
+
}
|
|
564
|
+
get startNode() {
|
|
565
|
+
return this._$AA;
|
|
566
|
+
}
|
|
567
|
+
get endNode() {
|
|
568
|
+
return this._$AB;
|
|
569
|
+
}
|
|
570
|
+
_$AI(t, e = this) {
|
|
571
|
+
t = m(this, t, e), w(t) ? t === u || t == null || t === "" ? (this._$AH !== u && this._$AR(), this._$AH = u) : t !== this._$AH && t !== C && this._(t) : t._$litType$ !== void 0 ? this.$(t) : t.nodeType !== void 0 ? this.T(t) : Pt(t) ? this.k(t) : this._(t);
|
|
572
|
+
}
|
|
573
|
+
O(t) {
|
|
574
|
+
return this._$AA.parentNode.insertBefore(t, this._$AB);
|
|
575
|
+
}
|
|
576
|
+
T(t) {
|
|
577
|
+
this._$AH !== t && (this._$AR(), this._$AH = this.O(t));
|
|
578
|
+
}
|
|
579
|
+
_(t) {
|
|
580
|
+
this._$AH !== u && w(this._$AH) ? this._$AA.nextSibling.data = t : this.T(v.createTextNode(t)), this._$AH = t;
|
|
581
|
+
}
|
|
582
|
+
$(t) {
|
|
583
|
+
var o;
|
|
584
|
+
const { values: e, _$litType$: s } = t, n = typeof s == "number" ? this._$AC(t) : (s.el === void 0 && (s.el = k.createElement(ot(s.h, s.h[0]), this.options)), s);
|
|
585
|
+
if (((o = this._$AH) == null ? void 0 : o._$AD) === n) this._$AH.p(e);
|
|
586
|
+
else {
|
|
587
|
+
const r = new St(n, this), h = r.u(this.options);
|
|
588
|
+
r.p(e), this.T(h), this._$AH = r;
|
|
589
|
+
}
|
|
590
|
+
}
|
|
591
|
+
_$AC(t) {
|
|
592
|
+
let e = et.get(t.strings);
|
|
593
|
+
return e === void 0 && et.set(t.strings, e = new k(t)), e;
|
|
594
|
+
}
|
|
595
|
+
k(t) {
|
|
596
|
+
V(this._$AH) || (this._$AH = [], this._$AR());
|
|
597
|
+
const e = this._$AH;
|
|
598
|
+
let s, n = 0;
|
|
599
|
+
for (const o of t) n === e.length ? e.push(s = new R(this.O(L()), this.O(L()), this, this.options)) : s = e[n], s._$AI(o), n++;
|
|
600
|
+
n < e.length && (this._$AR(s && s._$AB.nextSibling, n), e.length = n);
|
|
601
|
+
}
|
|
602
|
+
_$AR(t = this._$AA.nextSibling, e) {
|
|
603
|
+
var s;
|
|
604
|
+
for ((s = this._$AP) == null ? void 0 : s.call(this, !1, !0, e); t && t !== this._$AB; ) {
|
|
605
|
+
const n = t.nextSibling;
|
|
606
|
+
t.remove(), t = n;
|
|
607
|
+
}
|
|
608
|
+
}
|
|
609
|
+
setConnected(t) {
|
|
610
|
+
var e;
|
|
611
|
+
this._$AM === void 0 && (this._$Cv = t, (e = this._$AP) == null || e.call(this, t));
|
|
612
|
+
}
|
|
613
|
+
}
|
|
614
|
+
class z {
|
|
615
|
+
get tagName() {
|
|
616
|
+
return this.element.tagName;
|
|
617
|
+
}
|
|
618
|
+
get _$AU() {
|
|
619
|
+
return this._$AM._$AU;
|
|
620
|
+
}
|
|
621
|
+
constructor(t, e, s, n, o) {
|
|
622
|
+
this.type = 1, this._$AH = u, this._$AN = void 0, this.element = t, this.name = e, this._$AM = n, this.options = o, s.length > 2 || s[0] !== "" || s[1] !== "" ? (this._$AH = Array(s.length - 1).fill(new String()), this.strings = s) : this._$AH = u;
|
|
623
|
+
}
|
|
624
|
+
_$AI(t, e = this, s, n) {
|
|
625
|
+
const o = this.strings;
|
|
626
|
+
let r = !1;
|
|
627
|
+
if (o === void 0) t = m(this, t, e, 0), r = !w(t) || t !== this._$AH && t !== C, r && (this._$AH = t);
|
|
628
|
+
else {
|
|
629
|
+
const h = t;
|
|
630
|
+
let a, c;
|
|
631
|
+
for (t = o[0], a = 0; a < o.length - 1; a++) c = m(this, h[s + a], e, a), c === C && (c = this._$AH[a]), r || (r = !w(c) || c !== this._$AH[a]), c === u ? t = u : t !== u && (t += (c ?? "") + o[a + 1]), this._$AH[a] = c;
|
|
632
|
+
}
|
|
633
|
+
r && !n && this.j(t);
|
|
634
|
+
}
|
|
635
|
+
j(t) {
|
|
636
|
+
t === u ? this.element.removeAttribute(this.name) : this.element.setAttribute(this.name, t ?? "");
|
|
637
|
+
}
|
|
638
|
+
}
|
|
639
|
+
class Et extends z {
|
|
640
|
+
constructor() {
|
|
641
|
+
super(...arguments), this.type = 3;
|
|
642
|
+
}
|
|
643
|
+
j(t) {
|
|
644
|
+
this.element[this.name] = t === u ? void 0 : t;
|
|
645
|
+
}
|
|
646
|
+
}
|
|
647
|
+
class wt extends z {
|
|
648
|
+
constructor() {
|
|
649
|
+
super(...arguments), this.type = 4;
|
|
650
|
+
}
|
|
651
|
+
j(t) {
|
|
652
|
+
this.element.toggleAttribute(this.name, !!t && t !== u);
|
|
653
|
+
}
|
|
654
|
+
}
|
|
655
|
+
class Ct extends z {
|
|
656
|
+
constructor(t, e, s, n, o) {
|
|
657
|
+
super(t, e, s, n, o), this.type = 5;
|
|
658
|
+
}
|
|
659
|
+
_$AI(t, e = this) {
|
|
660
|
+
if ((t = m(this, t, e, 0) ?? u) === C) return;
|
|
661
|
+
const s = this._$AH, n = t === u && s !== u || t.capture !== s.capture || t.once !== s.once || t.passive !== s.passive, o = t !== u && (s === u || n);
|
|
662
|
+
n && this.element.removeEventListener(this.name, this, s), o && this.element.addEventListener(this.name, this, t), this._$AH = t;
|
|
663
|
+
}
|
|
664
|
+
handleEvent(t) {
|
|
665
|
+
var e;
|
|
666
|
+
typeof this._$AH == "function" ? this._$AH.call(((e = this.options) == null ? void 0 : e.host) ?? this.element, t) : this._$AH.handleEvent(t);
|
|
667
|
+
}
|
|
668
|
+
}
|
|
669
|
+
class kt {
|
|
670
|
+
constructor(t, e, s) {
|
|
671
|
+
this.element = t, this.type = 6, this._$AN = void 0, this._$AM = e, this.options = s;
|
|
672
|
+
}
|
|
673
|
+
get _$AU() {
|
|
674
|
+
return this._$AM._$AU;
|
|
675
|
+
}
|
|
676
|
+
_$AI(t) {
|
|
677
|
+
m(this, t);
|
|
678
|
+
}
|
|
679
|
+
}
|
|
680
|
+
const j = E.litHtmlPolyfillSupport;
|
|
681
|
+
j == null || j(k, R), (E.litHtmlVersions ?? (E.litHtmlVersions = [])).push("3.2.1");
|
|
682
|
+
/**
|
|
683
|
+
* @license
|
|
684
|
+
* Copyright 2018 Google LLC
|
|
685
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
686
|
+
*/
|
|
687
|
+
const Ut = (i) => i ?? u;
|
|
688
|
+
var Ht = Object.defineProperty, H = (i, t, e, s) => {
|
|
689
|
+
for (var n = void 0, o = i.length - 1, r; o >= 0; o--)
|
|
690
|
+
(r = i[o]) && (n = r(t, e, n) || n);
|
|
691
|
+
return n && Ht(t, e, n), n;
|
|
692
|
+
};
|
|
693
|
+
let Nt = 0;
|
|
694
|
+
const q = class q extends ht {
|
|
695
|
+
/**************** Lifecycle Methods ****************/
|
|
696
|
+
constructor() {
|
|
697
|
+
super(), this.id = "", this.name = "", this.currentPage = 1, this.totalPages = 1, this._twoBeforeLast = !1;
|
|
698
|
+
}
|
|
699
|
+
updated(t) {
|
|
700
|
+
super.updated(t), this.currentPage = this._clampPage(this.currentPage), this._twoBeforeLast = this.currentPage === this.totalPages - 2;
|
|
701
|
+
}
|
|
702
|
+
// Generate a unique ID if one is not provided
|
|
703
|
+
connectedCallback() {
|
|
704
|
+
super.connectedCallback(), this.id || (this.id = `nys-pagination-${Date.now()}-${Nt++}`);
|
|
705
|
+
}
|
|
706
|
+
/******************** Functions ********************/
|
|
707
|
+
_clampPage(t) {
|
|
708
|
+
return t < 1 ? 1 : t > this.totalPages ? this.totalPages : t;
|
|
709
|
+
}
|
|
710
|
+
renderPageButtons() {
|
|
711
|
+
const t = [], e = (a, c) => {
|
|
712
|
+
t.push(A`
|
|
713
|
+
<nys-button
|
|
714
|
+
label=${String(a)}
|
|
715
|
+
ariaLabel="Page ${a}"
|
|
716
|
+
id=${Ut(c)}
|
|
717
|
+
variant=${this.currentPage === a ? "filled" : "outline"}
|
|
718
|
+
@nys-click="${() => this._handlePageClick(a)}"
|
|
719
|
+
></nys-button>
|
|
720
|
+
`);
|
|
721
|
+
}, s = (a) => {
|
|
722
|
+
t.push(
|
|
723
|
+
A`<nys-button
|
|
724
|
+
label="..."
|
|
725
|
+
class="spacer"
|
|
726
|
+
tabindex="-1"
|
|
727
|
+
id=${a}
|
|
728
|
+
></nys-button>`
|
|
729
|
+
);
|
|
730
|
+
}, o = this.totalPages, r = this.currentPage - 1, h = this.currentPage + 1;
|
|
731
|
+
return e(1), this.currentPage > 2 && s("first-spacer"), r > 1 && e(r, "prev-page"), this.currentPage !== 1 && this.currentPage !== o && e(this.currentPage, "current-page"), h < o && e(h, "next-page"), this.currentPage < o - 1 && s("last-spacer"), o > 1 && e(o), t;
|
|
732
|
+
}
|
|
733
|
+
/****************** Event Handlers ******************/
|
|
734
|
+
_handlePageClick(t) {
|
|
735
|
+
this.currentPage = this._clampPage(t), this.dispatchEvent(
|
|
736
|
+
new CustomEvent("nys-change", {
|
|
737
|
+
detail: { page: this.currentPage },
|
|
738
|
+
bubbles: !0,
|
|
739
|
+
composed: !0
|
|
740
|
+
})
|
|
741
|
+
);
|
|
742
|
+
}
|
|
743
|
+
render() {
|
|
744
|
+
return this.totalPages <= 1 ? null : A`<div class="nys-pagination">
|
|
745
|
+
${this.currentPage > 1 ? A`
|
|
746
|
+
<nys-button
|
|
747
|
+
id="previous"
|
|
748
|
+
label="Previous"
|
|
749
|
+
prefixIcon="chevron_left"
|
|
750
|
+
variant="outline"
|
|
751
|
+
@nys-click="${() => this._handlePageClick(this.currentPage - 1)}"
|
|
752
|
+
></nys-button>
|
|
753
|
+
<nys-button
|
|
754
|
+
id="previous--mobile"
|
|
755
|
+
prefixIcon="chevron_left"
|
|
756
|
+
ariaLabel="Previous Page"
|
|
757
|
+
variant="outline"
|
|
758
|
+
@nys-click="${() => this._handlePageClick(this.currentPage - 1)}"
|
|
759
|
+
></nys-button>
|
|
760
|
+
` : null}
|
|
761
|
+
${this.renderPageButtons()}
|
|
762
|
+
${this.currentPage < this.totalPages ? A`
|
|
763
|
+
<nys-button
|
|
764
|
+
id="next"
|
|
765
|
+
label="Next"
|
|
766
|
+
suffixIcon="chevron_right"
|
|
767
|
+
variant="outline"
|
|
768
|
+
@nys-click="${() => this._handlePageClick(this.currentPage + 1)}"
|
|
769
|
+
></nys-button>
|
|
770
|
+
<nys-button
|
|
771
|
+
id="next--mobile"
|
|
772
|
+
suffixIcon="chevron_right"
|
|
773
|
+
ariaLabel="Next Page"
|
|
774
|
+
variant="outline"
|
|
775
|
+
@nys-click="${() => this._handlePageClick(this.currentPage + 1)}"
|
|
776
|
+
></nys-button>
|
|
777
|
+
` : null}
|
|
778
|
+
</div>`;
|
|
779
|
+
}
|
|
780
|
+
/****************** 🪡 for 1.10.0 ******************/
|
|
781
|
+
/****************** designsystem@its.ny.gov ********/
|
|
782
|
+
};
|
|
783
|
+
q.styles = mt;
|
|
784
|
+
let b = q;
|
|
785
|
+
H([
|
|
786
|
+
U({ type: String })
|
|
787
|
+
], b.prototype, "id");
|
|
788
|
+
H([
|
|
789
|
+
U({ type: String, reflect: !0 })
|
|
790
|
+
], b.prototype, "name");
|
|
791
|
+
H([
|
|
792
|
+
U({ type: Number, reflect: !0 })
|
|
793
|
+
], b.prototype, "currentPage");
|
|
794
|
+
H([
|
|
795
|
+
U({ type: Number, reflect: !0 })
|
|
796
|
+
], b.prototype, "totalPages");
|
|
797
|
+
H([
|
|
798
|
+
U({ type: Boolean, reflect: !0 })
|
|
799
|
+
], b.prototype, "_twoBeforeLast");
|
|
800
|
+
customElements.get("nys-pagination") || customElements.define("nys-pagination", b);
|
|
801
|
+
export {
|
|
802
|
+
b as NysPagination
|
|
803
|
+
};
|
|
804
|
+
//# sourceMappingURL=nys-pagination.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"nys-pagination.js","sources":["../../../node_modules/@lit/reactive-element/css-tag.js","../../../node_modules/@lit/reactive-element/reactive-element.js","../../../node_modules/@lit/reactive-element/decorators/property.js","../src/nys-pagination.styles.ts","../../../node_modules/lit-html/lit-html.js","../../../node_modules/lit-html/directives/if-defined.js","../src/nys-pagination.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2019 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\nconst t=globalThis,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow)&&\"adoptedStyleSheets\"in Document.prototype&&\"replace\"in CSSStyleSheet.prototype,s=Symbol(),o=new WeakMap;class n{constructor(t,e,o){if(this._$cssResult$=!0,o!==s)throw Error(\"CSSResult is not constructable. Use `unsafeCSS` or `css` instead.\");this.cssText=t,this.t=e}get styleSheet(){let t=this.o;const s=this.t;if(e&&void 0===t){const e=void 0!==s&&1===s.length;e&&(t=o.get(s)),void 0===t&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),e&&o.set(s,t))}return t}toString(){return this.cssText}}const r=t=>new n(\"string\"==typeof t?t:t+\"\",void 0,s),i=(t,...e)=>{const o=1===t.length?t[0]:e.reduce(((e,s,o)=>e+(t=>{if(!0===t._$cssResult$)return t.cssText;if(\"number\"==typeof t)return t;throw Error(\"Value passed to 'css' function must be a 'css' function result: \"+t+\". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.\")})(s)+t[o+1]),t[0]);return new n(o,t,s)},S=(s,o)=>{if(e)s.adoptedStyleSheets=o.map((t=>t instanceof CSSStyleSheet?t:t.styleSheet));else for(const e of o){const o=document.createElement(\"style\"),n=t.litNonce;void 0!==n&&o.setAttribute(\"nonce\",n),o.textContent=e.cssText,s.appendChild(o)}},c=e?t=>t:t=>t instanceof CSSStyleSheet?(t=>{let e=\"\";for(const s of t.cssRules)e+=s.cssText;return r(e)})(t):t;export{n as CSSResult,S as adoptStyles,i as css,c as getCompatibleStyle,e as supportsAdoptingStyleSheets,r as unsafeCSS};\n//# sourceMappingURL=css-tag.js.map\n","import{getCompatibleStyle as t,adoptStyles as s}from\"./css-tag.js\";export{CSSResult,adoptStyles,css,getCompatibleStyle,supportsAdoptingStyleSheets,unsafeCSS}from\"./css-tag.js\";\n/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */const{is:i,defineProperty:e,getOwnPropertyDescriptor:r,getOwnPropertyNames:h,getOwnPropertySymbols:o,getPrototypeOf:n}=Object,a=globalThis,c=a.trustedTypes,l=c?c.emptyScript:\"\",p=a.reactiveElementPolyfillSupport,d=(t,s)=>t,u={toAttribute(t,s){switch(s){case Boolean:t=t?l:null;break;case Object:case Array:t=null==t?t:JSON.stringify(t)}return t},fromAttribute(t,s){let i=t;switch(s){case Boolean:i=null!==t;break;case Number:i=null===t?null:Number(t);break;case Object:case Array:try{i=JSON.parse(t)}catch(t){i=null}}return i}},f=(t,s)=>!i(t,s),y={attribute:!0,type:String,converter:u,reflect:!1,hasChanged:f};Symbol.metadata??=Symbol(\"metadata\"),a.litPropertyMetadata??=new WeakMap;class b extends HTMLElement{static addInitializer(t){this._$Ei(),(this.l??=[]).push(t)}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(t,s=y){if(s.state&&(s.attribute=!1),this._$Ei(),this.elementProperties.set(t,s),!s.noAccessor){const i=Symbol(),r=this.getPropertyDescriptor(t,i,s);void 0!==r&&e(this.prototype,t,r)}}static getPropertyDescriptor(t,s,i){const{get:e,set:h}=r(this.prototype,t)??{get(){return this[s]},set(t){this[s]=t}};return{get(){return e?.call(this)},set(s){const r=e?.call(this);h.call(this,s),this.requestUpdate(t,r,i)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)??y}static _$Ei(){if(this.hasOwnProperty(d(\"elementProperties\")))return;const t=n(this);t.finalize(),void 0!==t.l&&(this.l=[...t.l]),this.elementProperties=new Map(t.elementProperties)}static finalize(){if(this.hasOwnProperty(d(\"finalized\")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(d(\"properties\"))){const t=this.properties,s=[...h(t),...o(t)];for(const i of s)this.createProperty(i,t[i])}const t=this[Symbol.metadata];if(null!==t){const s=litPropertyMetadata.get(t);if(void 0!==s)for(const[t,i]of s)this.elementProperties.set(t,i)}this._$Eh=new Map;for(const[t,s]of this.elementProperties){const i=this._$Eu(t,s);void 0!==i&&this._$Eh.set(i,t)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(s){const i=[];if(Array.isArray(s)){const e=new Set(s.flat(1/0).reverse());for(const s of e)i.unshift(t(s))}else void 0!==s&&i.push(t(s));return i}static _$Eu(t,s){const i=s.attribute;return!1===i?void 0:\"string\"==typeof i?i:\"string\"==typeof t?t.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Em=null,this._$Ev()}_$Ev(){this._$ES=new Promise((t=>this.enableUpdating=t)),this._$AL=new Map,this._$E_(),this.requestUpdate(),this.constructor.l?.forEach((t=>t(this)))}addController(t){(this._$EO??=new Set).add(t),void 0!==this.renderRoot&&this.isConnected&&t.hostConnected?.()}removeController(t){this._$EO?.delete(t)}_$E_(){const t=new Map,s=this.constructor.elementProperties;for(const i of s.keys())this.hasOwnProperty(i)&&(t.set(i,this[i]),delete this[i]);t.size>0&&(this._$Ep=t)}createRenderRoot(){const t=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return s(t,this.constructor.elementStyles),t}connectedCallback(){this.renderRoot??=this.createRenderRoot(),this.enableUpdating(!0),this._$EO?.forEach((t=>t.hostConnected?.()))}enableUpdating(t){}disconnectedCallback(){this._$EO?.forEach((t=>t.hostDisconnected?.()))}attributeChangedCallback(t,s,i){this._$AK(t,i)}_$EC(t,s){const i=this.constructor.elementProperties.get(t),e=this.constructor._$Eu(t,i);if(void 0!==e&&!0===i.reflect){const r=(void 0!==i.converter?.toAttribute?i.converter:u).toAttribute(s,i.type);this._$Em=t,null==r?this.removeAttribute(e):this.setAttribute(e,r),this._$Em=null}}_$AK(t,s){const i=this.constructor,e=i._$Eh.get(t);if(void 0!==e&&this._$Em!==e){const t=i.getPropertyOptions(e),r=\"function\"==typeof t.converter?{fromAttribute:t.converter}:void 0!==t.converter?.fromAttribute?t.converter:u;this._$Em=e,this[e]=r.fromAttribute(s,t.type),this._$Em=null}}requestUpdate(t,s,i){if(void 0!==t){if(i??=this.constructor.getPropertyOptions(t),!(i.hasChanged??f)(this[t],s))return;this.P(t,s,i)}!1===this.isUpdatePending&&(this._$ES=this._$ET())}P(t,s,i){this._$AL.has(t)||this._$AL.set(t,s),!0===i.reflect&&this._$Em!==t&&(this._$Ej??=new Set).add(t)}async _$ET(){this.isUpdatePending=!0;try{await this._$ES}catch(t){Promise.reject(t)}const t=this.scheduleUpdate();return null!=t&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){if(!this.isUpdatePending)return;if(!this.hasUpdated){if(this.renderRoot??=this.createRenderRoot(),this._$Ep){for(const[t,s]of this._$Ep)this[t]=s;this._$Ep=void 0}const t=this.constructor.elementProperties;if(t.size>0)for(const[s,i]of t)!0!==i.wrapped||this._$AL.has(s)||void 0===this[s]||this.P(s,this[s],i)}let t=!1;const s=this._$AL;try{t=this.shouldUpdate(s),t?(this.willUpdate(s),this._$EO?.forEach((t=>t.hostUpdate?.())),this.update(s)):this._$EU()}catch(s){throw t=!1,this._$EU(),s}t&&this._$AE(s)}willUpdate(t){}_$AE(t){this._$EO?.forEach((t=>t.hostUpdated?.())),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$EU(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$ES}shouldUpdate(t){return!0}update(t){this._$Ej&&=this._$Ej.forEach((t=>this._$EC(t,this[t]))),this._$EU()}updated(t){}firstUpdated(t){}}b.elementStyles=[],b.shadowRootOptions={mode:\"open\"},b[d(\"elementProperties\")]=new Map,b[d(\"finalized\")]=new Map,p?.({ReactiveElement:b}),(a.reactiveElementVersions??=[]).push(\"2.0.4\");export{b as ReactiveElement,u as defaultConverter,f as notEqual};\n//# sourceMappingURL=reactive-element.js.map\n","import{defaultConverter as t,notEqual as e}from\"../reactive-element.js\";\n/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */const o={attribute:!0,type:String,converter:t,reflect:!1,hasChanged:e},r=(t=o,e,r)=>{const{kind:n,metadata:i}=r;let s=globalThis.litPropertyMetadata.get(i);if(void 0===s&&globalThis.litPropertyMetadata.set(i,s=new Map),s.set(r.name,t),\"accessor\"===n){const{name:o}=r;return{set(r){const n=e.get.call(this);e.set.call(this,r),this.requestUpdate(o,n,t)},init(e){return void 0!==e&&this.P(o,void 0,t),e}}}if(\"setter\"===n){const{name:o}=r;return function(r){const n=this[o];e.call(this,r),this.requestUpdate(o,n,t)}}throw Error(\"Unsupported decorator location: \"+n)};function n(t){return(e,o)=>\"object\"==typeof o?r(t,e,o):((t,e,o)=>{const r=e.hasOwnProperty(o);return e.constructor.createProperty(o,r?{...t,wrapped:!0}:t),r?Object.getOwnPropertyDescriptor(e,o):void 0})(t,e,o)}export{n as property,r as standardProperty};\n//# sourceMappingURL=property.js.map\n","import { css } from \"lit\";\n\nexport default css`\n :host {\n /* Anything that can be overridden should be defined here */\n\n /* Global Pagination Styles */\n --_nys-pagination-width: fit-content;\n --_nys-pagination-height: var(--nys-size-500, 40px);\n --_nys-pagination-radius: var(--nys-radius-xl, 12px);\n --_nys-pagination-gap: var(--nys-space-100, 8px);\n\n /* Typography */\n --_nys-pagination-font-size: var(--nys-font-size-ui-md, 16px);\n --_nys-pagination-font-weight: var(--nys-font-weight-semibold, 600);\n --_nys-pagination-line-height: var(--nys-font-lineheight-ui-md, 24px);\n --_nys-pagination-font-family: var(\n --nys-font-family-ui,\n var(\n --nys-font-family-sans,\n \"Proxima Nova\",\n \"Helvetica Neue\",\n \"Helvetica\",\n \"Arial\",\n sans-serif\n )\n );\n }\n\n .nys-pagination {\n width: var(--_nys-pagination-width);\n height: var(--_nys-pagination-height);\n border-radius: var(--_nys-pagination-radius);\n display: flex;\n align-items: center;\n justify-content: center;\n gap: var(--_nys-pagination-gap);\n font-family: var(--_nys-pagination-font-family);\n font-size: var(--_nys-pagination-font-size);\n font-weight: var(--_nys-pagination-font-weight);\n line-height: var(--_nys-pagination-line-height);\n }\n\n nys-button {\n --_nys-button-height: var(--_nys-pagination-height);\n --_nys-button-border-width: var(--nys-border-width-sm, 1px);\n --_nys-button-border-radius--start: var(--nys-radius-md, 4px);\n --_nys-button-border-radius--end: var(--nys-radius-md, 4px);\n --_nys-button-padding--x: var(--nys-space-200, 16px);\n }\n\n nys-button[variant=\"outline\"] {\n --nys-button-background-color: var(--nys-color-ink-reverse, #fff);\n --nys-button-background-color--hover: var(--nys-color-neutral-10, #f6f6f6);\n --nys-button-background-color--active: var(--nys-color-neutral-50, #ededed);\n --nys-button-border-color: var(--nys-color-neutral-200, #bec0c1);\n --nys-button-border-color--hover: var(--nys-color-neutral-600, #62666a);\n --nys-button-border-color--active: var(--nys-color-neutral-900, #1b1b1b);\n --nys-button-color: var(--nys-color-link, #004dd1);\n --nys-button-color--hover: var(--nys-color-link-strong, #003ba1);\n --nys-button-color--active: var(--nys-color-link-strong, #003ba1);\n }\n\n nys-button[variant=\"filled\"] {\n --nys-button-background-color: var(--nys-color-link, #004dd1);\n --nys-button-background-color--hover: var(\n --nys-color-link-strong,\n ##003ba1\n );\n --nys-button-background-color--active: var(\n --nys-color-link-strongest,\n ##002971\n );\n --nys-button-border-color: var(--nys-color-link, #004dd1);\n --nys-button-border-color--hover: var(--nys-color-link-strong, ##003ba1);\n --nys-button-border-color--active: var(\n --nys-color-link-strongest,\n ##002971\n );\n --nys-button-color: var(--nys-color-ink-reverse, #fff);\n --nys-button-color--hover: var(--nys-color-ink-reverse, #fff);\n --nys-button-color--active: var(--nys-color-ink-reverse, #fff);\n }\n\n nys-button#previous,\n nys-button#next,\n nys-button#previous--mobile,\n nys-button#next--mobile {\n --nys-button-color: var(--nys-color-text, ##1b1b1b);\n --nys-button-color--hover: var(--nys-color-text, ##1b1b1b);\n --nys-button-color--active: var(--nys-color-text, ##1b1b1b);\n --_nys-button-padding--x: var(--nys-space-150, 12px);\n }\n\n nys-button#previous--mobile,\n nys-button#next--mobile {\n display: none;\n }\n\n nys-button.spacer {\n --nys-button-border-color: transparent;\n --nys-button-border-color--hover: transparent;\n --nys-button-border-color--active: transparent;\n --nys-button-background-color: transparent;\n --nys-button-background-color--hover: transparent;\n --nys-button-background-color--active: transparent;\n --nys-button-color: var(--nys-color-text, ##1b1b1b);\n --nys-button-color--hover: var(--nys-color-text, ##1b1b1b);\n --nys-button-color--active: var(--nys-color-text, ##1b1b1b);\n --_nys-button-padding--x: var(--nys-space-1px, 1px);\n --_nys-button-cursor: default;\n }\n\n :host([currentPage=\"3\"]) nys-button#first-spacer,\n :host([_twoBeforeLast]) nys-button#last-spacer {\n display: none;\n }\n\n @media (min-width: 0) and (max-width: 767px) {\n /* Mobile (XS) and Mobile Large (SM) */\n\n /* Hide 1 less and more than currentPage */\n nys-button#prev-page,\n nys-button#next-page {\n display: none;\n }\n\n /* Show spacer instead of 1 less and more than currentPage*/\n :host([currentPage=\"3\"]) nys-button#first-spacer,\n :host([_twoBeforeLast]) nys-button#last-spacer {\n display: block;\n }\n\n /* Swap to icon only previous and next buttons */\n nys-button#previous--mobile,\n nys-button#next--mobile {\n display: block;\n }\n nys-button#previous,\n nys-button#next {\n display: none;\n }\n }\n`;\n","/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\nconst t=globalThis,i=t.trustedTypes,s=i?i.createPolicy(\"lit-html\",{createHTML:t=>t}):void 0,e=\"$lit$\",h=`lit$${Math.random().toFixed(9).slice(2)}$`,o=\"?\"+h,n=`<${o}>`,r=document,l=()=>r.createComment(\"\"),c=t=>null===t||\"object\"!=typeof t&&\"function\"!=typeof t,a=Array.isArray,u=t=>a(t)||\"function\"==typeof t?.[Symbol.iterator],d=\"[ \\t\\n\\f\\r]\",f=/<(?:(!--|\\/[^a-zA-Z])|(\\/?[a-zA-Z][^>\\s]*)|(\\/?$))/g,v=/-->/g,_=/>/g,m=RegExp(`>|${d}(?:([^\\\\s\"'>=/]+)(${d}*=${d}*(?:[^ \\t\\n\\f\\r\"'\\`<>=]|(\"|')|))|$)`,\"g\"),p=/'/g,g=/\"/g,$=/^(?:script|style|textarea|title)$/i,y=t=>(i,...s)=>({_$litType$:t,strings:i,values:s}),x=y(1),b=y(2),w=y(3),T=Symbol.for(\"lit-noChange\"),E=Symbol.for(\"lit-nothing\"),A=new WeakMap,C=r.createTreeWalker(r,129);function P(t,i){if(!a(t)||!t.hasOwnProperty(\"raw\"))throw Error(\"invalid template strings array\");return void 0!==s?s.createHTML(i):i}const V=(t,i)=>{const s=t.length-1,o=[];let r,l=2===i?\"<svg>\":3===i?\"<math>\":\"\",c=f;for(let i=0;i<s;i++){const s=t[i];let a,u,d=-1,y=0;for(;y<s.length&&(c.lastIndex=y,u=c.exec(s),null!==u);)y=c.lastIndex,c===f?\"!--\"===u[1]?c=v:void 0!==u[1]?c=_:void 0!==u[2]?($.test(u[2])&&(r=RegExp(\"</\"+u[2],\"g\")),c=m):void 0!==u[3]&&(c=m):c===m?\">\"===u[0]?(c=r??f,d=-1):void 0===u[1]?d=-2:(d=c.lastIndex-u[2].length,a=u[1],c=void 0===u[3]?m:'\"'===u[3]?g:p):c===g||c===p?c=m:c===v||c===_?c=f:(c=m,r=void 0);const x=c===m&&t[i+1].startsWith(\"/>\")?\" \":\"\";l+=c===f?s+n:d>=0?(o.push(a),s.slice(0,d)+e+s.slice(d)+h+x):s+h+(-2===d?i:x)}return[P(t,l+(t[s]||\"<?>\")+(2===i?\"</svg>\":3===i?\"</math>\":\"\")),o]};class N{constructor({strings:t,_$litType$:s},n){let r;this.parts=[];let c=0,a=0;const u=t.length-1,d=this.parts,[f,v]=V(t,s);if(this.el=N.createElement(f,n),C.currentNode=this.el.content,2===s||3===s){const t=this.el.content.firstChild;t.replaceWith(...t.childNodes)}for(;null!==(r=C.nextNode())&&d.length<u;){if(1===r.nodeType){if(r.hasAttributes())for(const t of r.getAttributeNames())if(t.endsWith(e)){const i=v[a++],s=r.getAttribute(t).split(h),e=/([.?@])?(.*)/.exec(i);d.push({type:1,index:c,name:e[2],strings:s,ctor:\".\"===e[1]?H:\"?\"===e[1]?I:\"@\"===e[1]?L:k}),r.removeAttribute(t)}else t.startsWith(h)&&(d.push({type:6,index:c}),r.removeAttribute(t));if($.test(r.tagName)){const t=r.textContent.split(h),s=t.length-1;if(s>0){r.textContent=i?i.emptyScript:\"\";for(let i=0;i<s;i++)r.append(t[i],l()),C.nextNode(),d.push({type:2,index:++c});r.append(t[s],l())}}}else if(8===r.nodeType)if(r.data===o)d.push({type:2,index:c});else{let t=-1;for(;-1!==(t=r.data.indexOf(h,t+1));)d.push({type:7,index:c}),t+=h.length-1}c++}}static createElement(t,i){const s=r.createElement(\"template\");return s.innerHTML=t,s}}function S(t,i,s=t,e){if(i===T)return i;let h=void 0!==e?s._$Co?.[e]:s._$Cl;const o=c(i)?void 0:i._$litDirective$;return h?.constructor!==o&&(h?._$AO?.(!1),void 0===o?h=void 0:(h=new o(t),h._$AT(t,s,e)),void 0!==e?(s._$Co??=[])[e]=h:s._$Cl=h),void 0!==h&&(i=S(t,h._$AS(t,i.values),h,e)),i}class M{constructor(t,i){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=i}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){const{el:{content:i},parts:s}=this._$AD,e=(t?.creationScope??r).importNode(i,!0);C.currentNode=e;let h=C.nextNode(),o=0,n=0,l=s[0];for(;void 0!==l;){if(o===l.index){let i;2===l.type?i=new R(h,h.nextSibling,this,t):1===l.type?i=new l.ctor(h,l.name,l.strings,this,t):6===l.type&&(i=new z(h,this,t)),this._$AV.push(i),l=s[++n]}o!==l?.index&&(h=C.nextNode(),o++)}return C.currentNode=r,e}p(t){let i=0;for(const s of this._$AV)void 0!==s&&(void 0!==s.strings?(s._$AI(t,s,i),i+=s.strings.length-2):s._$AI(t[i])),i++}}class R{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,i,s,e){this.type=2,this._$AH=E,this._$AN=void 0,this._$AA=t,this._$AB=i,this._$AM=s,this.options=e,this._$Cv=e?.isConnected??!0}get parentNode(){let t=this._$AA.parentNode;const i=this._$AM;return void 0!==i&&11===t?.nodeType&&(t=i.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,i=this){t=S(this,t,i),c(t)?t===E||null==t||\"\"===t?(this._$AH!==E&&this._$AR(),this._$AH=E):t!==this._$AH&&t!==T&&this._(t):void 0!==t._$litType$?this.$(t):void 0!==t.nodeType?this.T(t):u(t)?this.k(t):this._(t)}O(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}T(t){this._$AH!==t&&(this._$AR(),this._$AH=this.O(t))}_(t){this._$AH!==E&&c(this._$AH)?this._$AA.nextSibling.data=t:this.T(r.createTextNode(t)),this._$AH=t}$(t){const{values:i,_$litType$:s}=t,e=\"number\"==typeof s?this._$AC(t):(void 0===s.el&&(s.el=N.createElement(P(s.h,s.h[0]),this.options)),s);if(this._$AH?._$AD===e)this._$AH.p(i);else{const t=new M(e,this),s=t.u(this.options);t.p(i),this.T(s),this._$AH=t}}_$AC(t){let i=A.get(t.strings);return void 0===i&&A.set(t.strings,i=new N(t)),i}k(t){a(this._$AH)||(this._$AH=[],this._$AR());const i=this._$AH;let s,e=0;for(const h of t)e===i.length?i.push(s=new R(this.O(l()),this.O(l()),this,this.options)):s=i[e],s._$AI(h),e++;e<i.length&&(this._$AR(s&&s._$AB.nextSibling,e),i.length=e)}_$AR(t=this._$AA.nextSibling,i){for(this._$AP?.(!1,!0,i);t&&t!==this._$AB;){const i=t.nextSibling;t.remove(),t=i}}setConnected(t){void 0===this._$AM&&(this._$Cv=t,this._$AP?.(t))}}class k{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,i,s,e,h){this.type=1,this._$AH=E,this._$AN=void 0,this.element=t,this.name=i,this._$AM=e,this.options=h,s.length>2||\"\"!==s[0]||\"\"!==s[1]?(this._$AH=Array(s.length-1).fill(new String),this.strings=s):this._$AH=E}_$AI(t,i=this,s,e){const h=this.strings;let o=!1;if(void 0===h)t=S(this,t,i,0),o=!c(t)||t!==this._$AH&&t!==T,o&&(this._$AH=t);else{const e=t;let n,r;for(t=h[0],n=0;n<h.length-1;n++)r=S(this,e[s+n],i,n),r===T&&(r=this._$AH[n]),o||=!c(r)||r!==this._$AH[n],r===E?t=E:t!==E&&(t+=(r??\"\")+h[n+1]),this._$AH[n]=r}o&&!e&&this.j(t)}j(t){t===E?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??\"\")}}class H extends k{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===E?void 0:t}}class I extends k{constructor(){super(...arguments),this.type=4}j(t){this.element.toggleAttribute(this.name,!!t&&t!==E)}}class L extends k{constructor(t,i,s,e,h){super(t,i,s,e,h),this.type=5}_$AI(t,i=this){if((t=S(this,t,i,0)??E)===T)return;const s=this._$AH,e=t===E&&s!==E||t.capture!==s.capture||t.once!==s.once||t.passive!==s.passive,h=t!==E&&(s===E||e);e&&this.element.removeEventListener(this.name,this,s),h&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){\"function\"==typeof this._$AH?this._$AH.call(this.options?.host??this.element,t):this._$AH.handleEvent(t)}}class z{constructor(t,i,s){this.element=t,this.type=6,this._$AN=void 0,this._$AM=i,this.options=s}get _$AU(){return this._$AM._$AU}_$AI(t){S(this,t)}}const Z={M:e,P:h,A:o,C:1,L:V,R:M,D:u,V:S,I:R,H:k,N:I,U:L,B:H,F:z},j=t.litHtmlPolyfillSupport;j?.(N,R),(t.litHtmlVersions??=[]).push(\"3.2.1\");const B=(t,i,s)=>{const e=s?.renderBefore??i;let h=e._$litPart$;if(void 0===h){const t=s?.renderBefore??null;e._$litPart$=h=new R(i.insertBefore(l(),t),t,void 0,s??{})}return h._$AI(t),h};export{Z as _$LH,x as html,w as mathml,T as noChange,E as nothing,B as render,b as svg};\n//# sourceMappingURL=lit-html.js.map\n","import{nothing as t}from\"../lit-html.js\";\n/**\n * @license\n * Copyright 2018 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */const o=o=>o??t;export{o as ifDefined};\n//# sourceMappingURL=if-defined.js.map\n","import { LitElement, TemplateResult, html } from \"lit\";\nimport { property } from \"lit/decorators.js\";\nimport styles from \"./nys-pagination.styles\";\nimport { ifDefined } from \"lit/directives/if-defined.js\";\n\nlet componentIdCounter = 0; // Counter for generating unique IDs\n\nexport class NysPagination extends LitElement {\n @property({ type: String }) id = \"\";\n @property({ type: String, reflect: true }) name = \"\";\n @property({ type: Number, reflect: true }) currentPage = 1;\n @property({ type: Number, reflect: true }) totalPages = 1;\n @property({ type: Boolean, reflect: true }) _twoBeforeLast = false;\n\n static styles = styles;\n\n /**************** Lifecycle Methods ****************/\n constructor() {\n super();\n }\n\n updated(changedProps: Map<string, unknown>) {\n super.updated(changedProps);\n // Clamp currentPage whenever it or totalPages changes\n this.currentPage = this._clampPage(this.currentPage);\n this._twoBeforeLast = this.currentPage === this.totalPages - 2;\n }\n\n // Generate a unique ID if one is not provided\n connectedCallback() {\n super.connectedCallback();\n if (!this.id) {\n this.id = `nys-pagination-${Date.now()}-${componentIdCounter++}`;\n }\n }\n\n /******************** Functions ********************/\n private _clampPage(page: number): number {\n if (page < 1) return 1;\n if (page > this.totalPages) return this.totalPages;\n return page;\n }\n\n private renderPageButtons() {\n const buttons: TemplateResult[] = [];\n\n const addPageButton = (page: number, id?: string) => {\n buttons.push(html`\n <nys-button\n label=${String(page)}\n ariaLabel=\"Page ${page}\"\n id=${ifDefined(id)}\n variant=${this.currentPage === page ? \"filled\" : \"outline\"}\n @nys-click=\"${() => this._handlePageClick(page)}\"\n ></nys-button>\n `);\n };\n\n const addSpacer = (id: string) => {\n buttons.push(\n html`<nys-button\n label=\"...\"\n class=\"spacer\"\n tabindex=\"-1\"\n id=${id}\n ></nys-button>`,\n );\n };\n\n const firstPage = 1;\n const lastPage = this.totalPages;\n const prev = this.currentPage - 1;\n const next = this.currentPage + 1;\n\n // Always show first page\n addPageButton(firstPage);\n\n // Spacer if there's a gap between first and current/prev\n if (this.currentPage > 2) {\n addSpacer(\"first-spacer\");\n }\n\n // Show prev neighbor (desktop; can be hidden via CSS at mobile)\n if (prev > firstPage) {\n addPageButton(prev, \"prev-page\");\n }\n\n // Show current (only if not first/last, since they’re already rendered)\n if (this.currentPage !== firstPage && this.currentPage !== lastPage) {\n addPageButton(this.currentPage, \"current-page\");\n }\n\n // Show next neighbor (desktop; can be hidden via CSS at mobile)\n if (next < lastPage) {\n addPageButton(next, \"next-page\");\n }\n\n // Spacer if there's a gap between current/next and last\n if (this.currentPage < lastPage - 1) {\n addSpacer(\"last-spacer\");\n }\n\n // Always show last page if more than one\n if (lastPage > firstPage) {\n addPageButton(lastPage);\n }\n\n return buttons;\n }\n\n /****************** Event Handlers ******************/\n private _handlePageClick(page: number) {\n this.currentPage = this._clampPage(page);\n this.dispatchEvent(\n new CustomEvent(\"nys-change\", {\n detail: { page: this.currentPage },\n bubbles: true,\n composed: true,\n }),\n );\n }\n\n render() {\n // If only one page, render nothing\n if (this.totalPages <= 1) {\n return null;\n }\n\n return html`<div class=\"nys-pagination\">\n ${this.currentPage > 1\n ? html`\n <nys-button\n id=\"previous\"\n label=\"Previous\"\n prefixIcon=\"chevron_left\"\n variant=\"outline\"\n @nys-click=\"${() => this._handlePageClick(this.currentPage - 1)}\"\n ></nys-button>\n <nys-button\n id=\"previous--mobile\"\n prefixIcon=\"chevron_left\"\n ariaLabel=\"Previous Page\"\n variant=\"outline\"\n @nys-click=\"${() => this._handlePageClick(this.currentPage - 1)}\"\n ></nys-button>\n `\n : null}\n ${this.renderPageButtons()}\n ${this.currentPage < this.totalPages\n ? html`\n <nys-button\n id=\"next\"\n label=\"Next\"\n suffixIcon=\"chevron_right\"\n variant=\"outline\"\n @nys-click=\"${() => this._handlePageClick(this.currentPage + 1)}\"\n ></nys-button>\n <nys-button\n id=\"next--mobile\"\n suffixIcon=\"chevron_right\"\n ariaLabel=\"Next Page\"\n variant=\"outline\"\n @nys-click=\"${() => this._handlePageClick(this.currentPage + 1)}\"\n ></nys-button>\n `\n : null}\n </div>`;\n }\n /****************** 🪡 for 1.10.0 ******************/\n /****************** designsystem@its.ny.gov ********/\n}\n\nif (!customElements.get(\"nys-pagination\")) {\n customElements.define(\"nys-pagination\", NysPagination);\n}\n"],"names":["t","e","s","o","n$3","r","n","S","c","i","h","a","l","p","d","u","f","y","b","_a","styles","css","v","_","m","g","$","T","E","A","C","P","V","x","N","H","I","L","k","_b","M","z","componentIdCounter","_NysPagination","LitElement","changedProps","page","buttons","addPageButton","id","html","ifDefined","addSpacer","lastPage","prev","next","NysPagination","__decorateClass","property"],"mappings":";;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAKA,MAAMA,IAAE,YAAWC,IAAED,EAAE,eAAsBA,EAAE,aAAX,UAAqBA,EAAE,SAAS,iBAAe,wBAAuB,SAAS,aAAW,aAAY,cAAc,WAAUE,KAAE,OAAM,GAAGC,IAAE,oBAAI;AAAO,IAAAC,KAAC,MAAO;AAAA,EAAC,YAAY,GAAE,GAAED,GAAE;AAAC,QAAG,KAAK,eAAa,IAAGA,MAAID,GAAE,OAAM,MAAM,mEAAmE;AAAE,SAAK,UAAQ,GAAE,KAAK,IAAE;AAAA,EAAC;AAAA,EAAC,IAAI,aAAY;AAAC,QAAI,IAAE,KAAK;AAAE,UAAMA,IAAE,KAAK;AAAE,QAAGD,KAAY,MAAT,QAAW;AAAC,YAAMA,IAAWC,MAAT,UAAgBA,EAAE,WAAN;AAAa,MAAAD,MAAI,IAAEE,EAAE,IAAID,CAAC,IAAY,MAAT,YAAc,KAAK,IAAE,IAAE,IAAI,iBAAe,YAAY,KAAK,OAAO,GAAED,KAAGE,EAAE,IAAID,GAAE,CAAC;AAAA,IAAE;AAAC,WAAO;AAAA,EAAC;AAAA,EAAC,WAAU;AAAC,WAAO,KAAK;AAAA,EAAO;AAAC;AAAM,MAACG,KAAE,CAAAL,MAAG,IAAIM,GAAY,OAAON,KAAjB,WAAmBA,IAA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,WAAA,gBAAA;AAgKzC,eAAe,IAAI,gBAAgB,KACtC,eAAe,OAAO,kBAAkBA,CAAa;","x_google_ignoreList":[0,1,2,4,5]}
|
package/package.json
ADDED
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@nysds/nys-pagination",
|
|
3
|
+
"version": "1.10.0",
|
|
4
|
+
"description": "The Pagination component from the NYS Design System.",
|
|
5
|
+
"module": "dist/nys-pagination.js",
|
|
6
|
+
"types": "dist/index.d.ts",
|
|
7
|
+
"exports": {
|
|
8
|
+
".": {
|
|
9
|
+
"import": "./dist/nys-pagination.js",
|
|
10
|
+
"types": "./dist/index.d.ts"
|
|
11
|
+
}
|
|
12
|
+
},
|
|
13
|
+
"type": "module",
|
|
14
|
+
"files": [
|
|
15
|
+
"dist/"
|
|
16
|
+
],
|
|
17
|
+
"scripts": {
|
|
18
|
+
"dev": "tsc --emitDeclarationOnly && vite",
|
|
19
|
+
"build": "tsc --emitDeclarationOnly && vite build",
|
|
20
|
+
"test": "vite build && wtr",
|
|
21
|
+
"build:watch": "tsc --emitDeclarationOnly && vite build --watch",
|
|
22
|
+
"test:watch": "vite build && wtr --watch",
|
|
23
|
+
"lit-analyze": "lit-analyzer '*.ts'"
|
|
24
|
+
},
|
|
25
|
+
"peerDependencies": {
|
|
26
|
+
"lit": "^3.2.1"
|
|
27
|
+
},
|
|
28
|
+
"dependencies": {
|
|
29
|
+
"@nysds/nys-button": "^1.10.0"
|
|
30
|
+
},
|
|
31
|
+
"devDependencies": {
|
|
32
|
+
"lit": "^3.2.1",
|
|
33
|
+
"typescript": "^5.7.2",
|
|
34
|
+
"vite": "^6.3.6"
|
|
35
|
+
},
|
|
36
|
+
"keywords": [
|
|
37
|
+
"new-york-state",
|
|
38
|
+
"design-system",
|
|
39
|
+
"web-components",
|
|
40
|
+
"lit",
|
|
41
|
+
"nys",
|
|
42
|
+
"pagination",
|
|
43
|
+
"forms"
|
|
44
|
+
],
|
|
45
|
+
"author": "New York State Design System Team",
|
|
46
|
+
"license": "MIT"
|
|
47
|
+
}
|
|
48
|
+
|