@stackoverflow/stacks 1.6.6 → 1.7.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.
Files changed (35) hide show
  1. package/README.md +86 -2
  2. package/dist/controllers/index.d.ts +2 -0
  3. package/dist/controllers/s-banner.d.ts +41 -0
  4. package/dist/controllers/s-toast.d.ts +97 -0
  5. package/dist/css/stacks.css +18884 -18912
  6. package/dist/css/stacks.min.css +1 -1
  7. package/dist/js/stacks.js +5252 -5260
  8. package/dist/js/stacks.min.js +1 -1
  9. package/dist/stacks.d.ts +1 -1
  10. package/lib/css/components/anchors.less +61 -0
  11. package/lib/css/components/block-link.less +80 -0
  12. package/lib/css/components/buttons.less +20 -4
  13. package/lib/css/components/expandable.less +1 -1
  14. package/lib/css/components/inputs.less +4 -0
  15. package/lib/css/components/link.less +104 -0
  16. package/lib/css/components/post-summary.less +327 -356
  17. package/lib/css/components/table.less +297 -0
  18. package/lib/css/stacks-dynamic.less +0 -8
  19. package/lib/css/stacks-static.less +9 -1
  20. package/lib/test/s-banner.test.ts +73 -0
  21. package/lib/test/s-banner.visual.test.ts +61 -0
  22. package/lib/test/s-button.visual.test.ts +12 -0
  23. package/lib/test/s-toast.test.ts +63 -0
  24. package/lib/test/s-toast.visual.test.ts +48 -0
  25. package/lib/test/s-tooltip.test.ts +62 -0
  26. package/lib/test/s-tooltip.visual.test.ts +31 -0
  27. package/lib/ts/controllers/index.ts +2 -0
  28. package/lib/ts/controllers/s-banner.ts +149 -0
  29. package/lib/ts/controllers/s-toast.ts +357 -0
  30. package/lib/ts/index.ts +4 -0
  31. package/lib/ts/stacks.ts +1 -1
  32. package/lib/tsconfig.json +2 -2
  33. package/package.json +35 -19
  34. package/lib/css/components/links.less +0 -214
  35. package/lib/css/components/tables.less +0 -313
@@ -0,0 +1,31 @@
1
+ import { html, fixture } from "@open-wc/testing";
2
+ import { screen } from "@testing-library/dom";
3
+ import userEvent from "@testing-library/user-event";
4
+ import { visualDiff } from "@web/test-runner-visual-regression";
5
+ import "../ts/index";
6
+
7
+ const user = userEvent.setup();
8
+
9
+ describe("s-tooltip", () => {
10
+ it("should not introduce visual regressions", async () => {
11
+ const wrapper = await fixture(html`
12
+ <div style="height: 100px; width: 160px; display: inline-block;">
13
+ <button
14
+ class="s-btn s-btn__filled"
15
+ role="button"
16
+ data-controller="s-tooltip"
17
+ title="tooltip content"
18
+ data-s-tooltip-placement="bottom-start"
19
+ >
20
+ Hover tooltip popover
21
+ </button>
22
+ </div>
23
+ `);
24
+
25
+ const trigger = screen.getByRole("button");
26
+ await user.hover(trigger);
27
+ await screen.findByRole("tooltip");
28
+
29
+ await visualDiff(wrapper, "s-tooltip");
30
+ });
31
+ });
@@ -1,6 +1,8 @@
1
1
  // export all controllers *with helpers* so they can be bulk re-exported by the package entry point
2
2
  export { ExpandableController } from "./s-expandable-control";
3
3
  export { hideModal, ModalController, showModal } from "./s-modal";
4
+ export { hideBanner, BannerController, showBanner } from "./s-banner";
5
+ export { hideToast, ToastController, showToast } from "./s-toast";
4
6
  export { TabListController } from "./s-navigation-tablist";
5
7
  export {
6
8
  attachPopover,
@@ -0,0 +1,149 @@
1
+ import * as Stacks from "../stacks";
2
+
3
+ export class BannerController extends Stacks.StacksController {
4
+ static targets = ["banner"];
5
+
6
+ declare readonly bannerTarget: HTMLElement;
7
+
8
+ /**
9
+ * Toggles the visibility of the banner
10
+ */
11
+ toggle(dispatcher: Event | Element | null = null) {
12
+ this._toggle(undefined, dispatcher);
13
+ }
14
+
15
+ /**
16
+ * Shows the banner
17
+ */
18
+ show(dispatcher: Event | Element | null = null) {
19
+ this._toggle(true, dispatcher);
20
+ }
21
+
22
+ /**
23
+ * Hides the banner
24
+ */
25
+ hide(dispatcher: Event | Element | null = null) {
26
+ this._toggle(false, dispatcher);
27
+ }
28
+
29
+ /**
30
+ * Toggles the visibility of the banner element
31
+ * @param show Optional parameter that force shows/hides the element or toggles it if left undefined
32
+ */
33
+ private _toggle(
34
+ show?: boolean | undefined,
35
+ dispatcher: Event | Element | null = null
36
+ ) {
37
+ let toShow = show;
38
+ const isVisible =
39
+ this.bannerTarget.getAttribute("aria-hidden") === "false";
40
+
41
+ // if we're letting the class toggle, we need to figure out if the banner is visible manually
42
+ if (typeof toShow === "undefined") {
43
+ toShow = !isVisible;
44
+ }
45
+
46
+ // if the state matches the disired state, return without changing anything
47
+ if ((toShow && isVisible) || (!toShow && !isVisible)) {
48
+ return;
49
+ }
50
+
51
+ const dispatchingElement = this.getDispatcher(dispatcher);
52
+
53
+ // show/hide events trigger before toggling the class
54
+ const triggeredEvent = this.triggerEvent(
55
+ toShow ? "show" : "hide",
56
+ {
57
+ dispatcher: this.getDispatcher(dispatchingElement),
58
+ },
59
+ this.bannerTarget
60
+ );
61
+
62
+ // if this pre-show/hide event was prevented, don't attempt to continue changing the banner state
63
+ if (triggeredEvent.defaultPrevented) {
64
+ return;
65
+ }
66
+
67
+ this.bannerTarget.setAttribute(
68
+ "aria-hidden",
69
+ toShow ? "false" : "true"
70
+ );
71
+
72
+ if (!toShow) {
73
+ this.removeBannerOnHide();
74
+ }
75
+
76
+ this.triggerEvent(
77
+ toShow ? "shown" : "hidden",
78
+ {
79
+ dispatcher: dispatchingElement,
80
+ },
81
+ this.bannerTarget
82
+ );
83
+ }
84
+
85
+ /**
86
+ * Remove the element on hide if the `remove-when-hidden` flag is set
87
+ */
88
+ private removeBannerOnHide() {
89
+ if (this.data.get("remove-when-hidden") !== "true") {
90
+ return;
91
+ }
92
+
93
+ this.bannerTarget.addEventListener(
94
+ "s-banner:hidden",
95
+ () => {
96
+ this.element.remove();
97
+ },
98
+ { once: true }
99
+ );
100
+ }
101
+
102
+ /**
103
+ * Determines the correct dispatching element from a potential input
104
+ * @param dispatcher The event or element to get the dispatcher from
105
+ */
106
+ private getDispatcher(dispatcher: Event | Element | null = null): Element {
107
+ if (dispatcher instanceof Event) {
108
+ return <Element>dispatcher.target;
109
+ } else if (dispatcher instanceof Element) {
110
+ return dispatcher;
111
+ } else {
112
+ return this.element;
113
+ }
114
+ }
115
+ }
116
+
117
+ /**
118
+ * Helper to manually show an s-banner element via external JS
119
+ * @param element the element the `data-controller="s-banner"` attribute is on
120
+ */
121
+ export function showBanner(element: HTMLElement) {
122
+ toggleBanner(element, true);
123
+ }
124
+
125
+ /**
126
+ * Helper to manually hide an s-banner element via external JS
127
+ * @param element the element the `data-controller="s-banner"` attribute is on
128
+ */
129
+ export function hideBanner(element: HTMLElement) {
130
+ toggleBanner(element, false);
131
+ }
132
+
133
+ /**
134
+ * Helper to manually show an s-banner element via external JS
135
+ * @param element the element the `data-controller="s-banner"` attribute is on
136
+ * @param show whether to force show/hide the banner; toggles the banner if left undefined
137
+ */
138
+ function toggleBanner(element: HTMLElement, show?: boolean | undefined) {
139
+ const controller = Stacks.application.getControllerForElementAndIdentifier(
140
+ element,
141
+ "s-banner"
142
+ ) as BannerController;
143
+
144
+ if (!controller) {
145
+ throw "Unable to get s-banner controller from element";
146
+ }
147
+
148
+ show ? controller.show() : controller.hide();
149
+ }
@@ -0,0 +1,357 @@
1
+ import * as Stacks from "../stacks";
2
+
3
+ export class ToastController extends Stacks.StacksController {
4
+ static targets = ["toast", "initialFocus"];
5
+
6
+ declare readonly toastTarget: HTMLElement;
7
+ declare readonly initialFocusTargets: HTMLElement[];
8
+
9
+ private _boundClickFn!: (event: MouseEvent) => void;
10
+ private _boundKeypressFn!: (event: KeyboardEvent) => void;
11
+
12
+ private activeTimeout!: number;
13
+ private returnElement!: HTMLElement;
14
+
15
+ connect() {
16
+ this.validate();
17
+ }
18
+
19
+ /**
20
+ * Disconnects all added event listeners on controller disconnect
21
+ */
22
+ disconnect() {
23
+ this.unbindDocumentEvents();
24
+ }
25
+
26
+ /**
27
+ * Toggles the visibility of the toast
28
+ */
29
+ toggle(dispatcher: Event | Element | null = null) {
30
+ this._toggle(undefined, dispatcher);
31
+ }
32
+
33
+ /**
34
+ * Shows the toast
35
+ */
36
+ show(dispatcher: Event | Element | null = null) {
37
+ this._toggle(true, dispatcher);
38
+ }
39
+
40
+ /**
41
+ * Hides the toast
42
+ */
43
+ hide(dispatcher: Event | Element | null = null) {
44
+ this._toggle(false, dispatcher);
45
+ }
46
+
47
+ /**
48
+ * Validates the toast settings and attempts to set necessary internal variables
49
+ */
50
+ private validate() {
51
+ // check for returnElement support
52
+ const returnElementSelector = this.data.get("return-element");
53
+ if (returnElementSelector) {
54
+ this.returnElement = <HTMLElement>(
55
+ document.querySelector(returnElementSelector)
56
+ );
57
+
58
+ if (!this.returnElement) {
59
+ throw (
60
+ "Unable to find element by return-element selector: " +
61
+ returnElementSelector
62
+ );
63
+ }
64
+ }
65
+ }
66
+
67
+ /**
68
+ * Toggles the visibility of the toast element
69
+ * @param show Optional parameter that force shows/hides the element or toggles it if left undefined
70
+ */
71
+ private _toggle(
72
+ show?: boolean | undefined,
73
+ dispatcher: Event | Element | null = null
74
+ ) {
75
+ let toShow = show;
76
+ const isVisible =
77
+ this.toastTarget.getAttribute("aria-hidden") === "false";
78
+
79
+ // if we're letting the class toggle, we need to figure out if the toast is visible manually
80
+ if (typeof toShow === "undefined") {
81
+ toShow = !isVisible;
82
+ }
83
+
84
+ // if the state matches the disired state, return without changing anything
85
+ if ((toShow && isVisible) || (!toShow && !isVisible)) {
86
+ return;
87
+ }
88
+
89
+ const dispatchingElement = this.getDispatcher(dispatcher);
90
+
91
+ // show/hide events trigger before toggling the class
92
+ const triggeredEvent = this.triggerEvent(
93
+ toShow ? "show" : "hide",
94
+ {
95
+ returnElement: this.returnElement,
96
+ dispatcher: this.getDispatcher(dispatchingElement),
97
+ },
98
+ this.toastTarget
99
+ );
100
+
101
+ // if this pre-show/hide event was prevented, don't attempt to continue changing the toast state
102
+ if (triggeredEvent.defaultPrevented) {
103
+ return;
104
+ }
105
+
106
+ this.returnElement = triggeredEvent.detail.returnElement;
107
+ this.toastTarget.setAttribute("aria-hidden", toShow ? "false" : "true");
108
+
109
+ if (toShow) {
110
+ this.bindDocumentEvents();
111
+ this.hideAfterTimeout();
112
+
113
+ if (this.data.get("prevent-focus-capture") !== "true") {
114
+ this.focusInsideToast();
115
+ }
116
+ } else {
117
+ this.unbindDocumentEvents();
118
+ this.focusReturnElement();
119
+ this.removeToastOnHide();
120
+ this.clearActiveTimeout();
121
+ }
122
+
123
+ // check for transitionend support
124
+ const supportsTransitionEnd =
125
+ this.toastTarget.ontransitionend !== undefined;
126
+
127
+ // shown/hidden events trigger after toggling the class
128
+ if (supportsTransitionEnd) {
129
+ // wait until after the toast finishes transitioning to fire the event
130
+ this.toastTarget.addEventListener(
131
+ "transitionend",
132
+ () => {
133
+ //TODO this is firing waaay to soon?
134
+ this.triggerEvent(
135
+ toShow ? "shown" : "hidden",
136
+ {
137
+ dispatcher: dispatchingElement,
138
+ },
139
+ this.toastTarget
140
+ );
141
+ },
142
+ { once: true }
143
+ );
144
+ } else {
145
+ this.triggerEvent(
146
+ toShow ? "shown" : "hidden",
147
+ {
148
+ dispatcher: dispatchingElement,
149
+ },
150
+ this.toastTarget
151
+ );
152
+ }
153
+ }
154
+
155
+ /**
156
+ * Listens for the s-toast:hidden event and focuses the returnElement when it is fired
157
+ */
158
+ private focusReturnElement() {
159
+ if (!this.returnElement) {
160
+ return;
161
+ }
162
+
163
+ this.toastTarget.addEventListener(
164
+ "s-toast:hidden",
165
+ () => {
166
+ // double check the element still exists when the event is called
167
+ if (
168
+ this.returnElement &&
169
+ document.body.contains(this.returnElement)
170
+ ) {
171
+ this.returnElement.focus();
172
+ }
173
+ },
174
+ { once: true }
175
+ );
176
+ }
177
+
178
+ /**
179
+ * Remove the element on hide if the `remove-when-hidden` flag is set
180
+ */
181
+ private removeToastOnHide() {
182
+ if (this.data.get("remove-when-hidden") !== "true") {
183
+ return;
184
+ }
185
+
186
+ this.toastTarget.addEventListener(
187
+ "s-toast:hidden",
188
+ () => {
189
+ this.element.remove();
190
+ },
191
+ { once: true }
192
+ );
193
+ }
194
+
195
+ /**
196
+ * Hide the element after a delay
197
+ */
198
+ private hideAfterTimeout() {
199
+ if (
200
+ this.data.get("prevent-auto-hide") === "true" ||
201
+ this.data.get("hide-after-timeout") === "0"
202
+ ) {
203
+ return;
204
+ }
205
+
206
+ const timeout =
207
+ parseInt(this.data.get("hide-after-timeout") as string, 10) || 3000;
208
+
209
+ this.activeTimeout = window.setTimeout(() => this.hide(), timeout);
210
+ }
211
+
212
+ /**
213
+ * Cancels the activeTimeout
214
+ */
215
+ clearActiveTimeout() {
216
+ clearTimeout(this.activeTimeout);
217
+ }
218
+
219
+ /**
220
+ * Gets all elements within the toast that could receive keyboard focus.
221
+ */
222
+ private getAllTabbables() {
223
+ return Array.from(
224
+ this.toastTarget.querySelectorAll<HTMLElement>(
225
+ "[href], input, select, textarea, button, [tabindex]"
226
+ )
227
+ ).filter((el: Element) =>
228
+ el.matches(":not([disabled]):not([tabindex='-1'])")
229
+ );
230
+ }
231
+
232
+ /**
233
+ * Returns the first visible element in an array or `undefined` if no elements are visible.
234
+ */
235
+ private firstVisible(elements?: HTMLElement[]) {
236
+ // https://stackoverflow.com/a/21696585
237
+ return elements?.find((el) => el.offsetParent !== null);
238
+ }
239
+
240
+ /**
241
+ * Attempts to shift keyboard focus into the toast.
242
+ * If elements with `data-s-toast-target="initialFocus"` are present and visible, one of those will be selected.
243
+ * Otherwise, the first visible focusable element will receive focus.
244
+ */
245
+ private focusInsideToast() {
246
+ this.toastTarget.addEventListener(
247
+ "s-toast:shown",
248
+ () => {
249
+ const initialFocus =
250
+ this.firstVisible(this.initialFocusTargets) ??
251
+ this.firstVisible(this.getAllTabbables());
252
+ initialFocus?.focus();
253
+ },
254
+ { once: true }
255
+ );
256
+ }
257
+ /**
258
+ * Binds global events to the document for hiding toasts on user interaction
259
+ */
260
+ private bindDocumentEvents() {
261
+ // in order for removeEventListener to remove the right event, this bound function needs a constant reference
262
+ this._boundClickFn =
263
+ this._boundClickFn || this.hideOnOutsideClick.bind(this);
264
+ this._boundKeypressFn =
265
+ this._boundKeypressFn || this.hideOnEscapePress.bind(this);
266
+
267
+ document.addEventListener("mousedown", this._boundClickFn);
268
+ document.addEventListener("keyup", this._boundKeypressFn);
269
+ }
270
+
271
+ /**
272
+ * Unbinds global events to the document for hiding toasts on user interaction
273
+ */
274
+ private unbindDocumentEvents() {
275
+ document.removeEventListener("mousedown", this._boundClickFn);
276
+ document.removeEventListener("keyup", this._boundKeypressFn);
277
+ }
278
+
279
+ /**
280
+ * Forces the toast to hide if a user clicks outside of it or its reference element
281
+ */
282
+ private hideOnOutsideClick(e: Event) {
283
+ const target = <Node>e.target;
284
+ // check if the document was clicked inside either the toggle element or the toast itself
285
+ // note: .contains also returns true if the node itself matches the target element
286
+ if (
287
+ !this.toastTarget?.contains(target) &&
288
+ document.body.contains(target) &&
289
+ this.data.get("hide-on-outside-click") !== "false"
290
+ ) {
291
+ this._toggle(false, e);
292
+ }
293
+ }
294
+
295
+ /**
296
+ * Forces the toast to hide if the user presses escape while it, one of its childen, or the reference element are focused
297
+ */
298
+ private hideOnEscapePress(e: KeyboardEvent) {
299
+ // if the ESC key (27) wasn't pressed or if no toasts are showing, return
300
+ if (
301
+ e.which !== 27 ||
302
+ this.toastTarget.getAttribute("aria-hidden") === "true"
303
+ ) {
304
+ return;
305
+ }
306
+
307
+ this._toggle(false, e);
308
+ }
309
+
310
+ /**
311
+ * Determines the correct dispatching element from a potential input
312
+ * @param dispatcher The event or element to get the dispatcher from
313
+ */
314
+ private getDispatcher(dispatcher: Event | Element | null = null): Element {
315
+ if (dispatcher instanceof Event) {
316
+ return <Element>dispatcher.target;
317
+ } else if (dispatcher instanceof Element) {
318
+ return dispatcher;
319
+ } else {
320
+ return this.element;
321
+ }
322
+ }
323
+ }
324
+
325
+ /**
326
+ * Helper to manually show an s-toast element via external JS
327
+ * @param element the element the `data-controller="s-toast"` attribute is on
328
+ */
329
+ export function showToast(element: HTMLElement) {
330
+ toggleToast(element, true);
331
+ }
332
+
333
+ /**
334
+ * Helper to manually hide an s-toast element via external JS
335
+ * @param element the element the `data-controller="s-toast"` attribute is on
336
+ */
337
+ export function hideToast(element: HTMLElement) {
338
+ toggleToast(element, false);
339
+ }
340
+
341
+ /**
342
+ * Helper to manually show an s-toast element via external JS
343
+ * @param element the element the `data-controller="s-toast"` attribute is on
344
+ * @param show whether to force show/hide the toast; toggles the toast if left undefined
345
+ */
346
+ function toggleToast(element: HTMLElement, show?: boolean | undefined) {
347
+ const controller = Stacks.application.getControllerForElementAndIdentifier(
348
+ element,
349
+ "s-toast"
350
+ ) as ToastController;
351
+
352
+ if (!controller) {
353
+ throw "Unable to get s-toast controller from element";
354
+ }
355
+
356
+ show ? controller.show() : controller.hide();
357
+ }
package/lib/ts/index.ts CHANGED
@@ -1,18 +1,22 @@
1
1
  import "../css/stacks.less";
2
2
  import {
3
+ BannerController,
3
4
  ExpandableController,
4
5
  ModalController,
5
6
  PopoverController,
6
7
  TableController,
7
8
  TabListController,
9
+ ToastController,
8
10
  TooltipController,
9
11
  UploaderController,
10
12
  } from "./controllers";
11
13
  import { application, StacksApplication } from "./stacks";
12
14
 
13
15
  // register all built-in controllers
16
+ application.register("s-banner", BannerController);
14
17
  application.register("s-expandable-control", ExpandableController);
15
18
  application.register("s-modal", ModalController);
19
+ application.register("s-toast", ToastController);
16
20
  application.register("s-navigation-tablist", TabListController);
17
21
  application.register("s-popover", PopoverController);
18
22
  application.register("s-table", TableController);
package/lib/ts/stacks.ts CHANGED
@@ -1,4 +1,4 @@
1
- import * as Stimulus from "stimulus";
1
+ import * as Stimulus from "@hotwired/stimulus";
2
2
 
3
3
  export class StacksApplication extends Stimulus.Application {
4
4
  static _initializing = true;
package/lib/tsconfig.json CHANGED
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "compilerOptions": {
3
3
  "strict": true,
4
- "target": "es5",
5
- "lib": ["dom", "es6", "dom.iterable", "scripthost"], // es6 stuff is polyfilled by stimulus
4
+ "target": "es6",
5
+ "lib": ["dom", "es6", "dom.iterable", "scripthost"],
6
6
  "outDir": "../dist",
7
7
  "sourceMap": true,
8
8
  "moduleResolution": "node",
package/package.json CHANGED
@@ -5,7 +5,7 @@
5
5
  "type": "git",
6
6
  "url": "https://github.com/StackExchange/Stacks.git"
7
7
  },
8
- "version": "1.6.6",
8
+ "version": "1.7.0",
9
9
  "files": [
10
10
  "dist",
11
11
  "lib"
@@ -22,8 +22,11 @@
22
22
  "build:docs": "webpack --mode=production --config ./docs/webpack.config.js && cd ./docs && eleventy",
23
23
  "start:webpack": "webpack --watch --config ./docs/webpack.config.js",
24
24
  "start:eleventy": "cd ./docs && eleventy --serve",
25
- "test": "backstop test",
26
- "approve": "backstop approve",
25
+ "test": "web-test-runner",
26
+ "test:unit": "web-test-runner --group=unit",
27
+ "test:unit:watch": "web-test-runner --group=unit --watch",
28
+ "test:visual": "web-test-runner --group=visual",
29
+ "test:visual:update": "web-test-runner --group=visual --update-visual-baseline",
27
30
  "prepublishOnly": "npm run build",
28
31
  "lint": "concurrently -n w: npm:lint:*",
29
32
  "lint:ts": "eslint ./lib/ts",
@@ -32,40 +35,50 @@
32
35
  },
33
36
  "license": "MIT",
34
37
  "dependencies": {
35
- "@popperjs/core": "^2.11.6",
36
- "stimulus": "^2.0.0"
38
+ "@hotwired/stimulus": "^3.2.1",
39
+ "@popperjs/core": "^2.11.6"
37
40
  },
38
41
  "devDependencies": {
39
42
  "@11ty/eleventy": "^1.0.2",
40
- "@highlightjs/cdn-assets": "^11.6.0",
41
- "@stackoverflow/stacks-editor": "^0.8.2",
42
- "@stackoverflow/stacks-icons": "^3.1.0",
43
- "@typescript-eslint/eslint-plugin": "^5.42.0",
44
- "@typescript-eslint/parser": "^5.46.0",
45
- "backstopjs": "^6.1.4",
46
- "concurrently": "^7.5.0",
43
+ "@highlightjs/cdn-assets": "^11.7.0",
44
+ "@open-wc/testing": "^3.1.7",
45
+ "@rollup/plugin-commonjs": "^24.0.1",
46
+ "@rollup/plugin-replace": "^5.0.2",
47
+ "@stackoverflow/stacks-editor": "^0.8.4",
48
+ "@stackoverflow/stacks-icons": "^5.0.2",
49
+ "@testing-library/dom": "^8.19.1",
50
+ "@testing-library/user-event": "^14.4.3",
51
+ "@typescript-eslint/eslint-plugin": "^5.47.1",
52
+ "@typescript-eslint/parser": "^5.48.2",
53
+ "@web/dev-server-esbuild": "^0.3.3",
54
+ "@web/dev-server-rollup": "0.3.21",
55
+ "@web/test-runner": "^0.15.0",
56
+ "@web/test-runner-playwright": "^0.9.0",
57
+ "@web/test-runner-visual-regression": "^0.7.0",
58
+ "concurrently": "^7.6.0",
47
59
  "css-loader": "^6.7.2",
48
60
  "cssnano": "^5.1.14",
49
61
  "docsearch.js": "^2.6.3",
50
62
  "eleventy-plugin-highlightjs": "^1.1.0",
51
63
  "eleventy-plugin-nesting-toc": "^1.3.0",
52
- "eslint": "^8.29.0",
53
- "eslint-config-prettier": "^8.5.0",
64
+ "eslint": "^8.31.0",
65
+ "eslint-config-prettier": "^8.6.0",
54
66
  "eslint-plugin-no-unsanitized": "^4.0.2",
55
67
  "jquery": "^3.6.1",
56
68
  "less-loader": "^11.1.0",
57
69
  "list.js": "^2.3.1",
58
70
  "markdown-it": "^13.0.1",
59
- "mini-css-extract-plugin": "^2.6.1",
71
+ "mini-css-extract-plugin": "^2.7.2",
60
72
  "postcss-less": "^6.0.0",
61
- "postcss-loader": "^7.0.1",
62
- "prettier": "^2.7.1",
73
+ "postcss-loader": "^7.0.2",
74
+ "prettier": "^2.8.2",
75
+ "rollup-plugin-postcss": "^4.0.2",
63
76
  "stylelint": "^14.16.0",
64
77
  "stylelint-config-recommended": "^9.0.0",
65
78
  "stylelint-config-standard": "^29.0.0",
66
79
  "terser-webpack-plugin": "^5.3.6",
67
80
  "ts-loader": "^9.4.2",
68
- "typescript": "^4.9.3",
81
+ "typescript": "^4.9.4",
69
82
  "webpack": "^5.75.0",
70
83
  "webpack-cli": "^5.0.0",
71
84
  "webpack-merge": "^5.8.0"
@@ -84,5 +97,8 @@
84
97
  "not and_uc > 0",
85
98
  "not Samsung > 0",
86
99
  "not Android > 0"
87
- ]
100
+ ],
101
+ "overrides": {
102
+ "aria-query": "~5.0.0"
103
+ }
88
104
  }