@ulu/frontend 0.2.0-beta.8 → 0.2.1

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 (53) hide show
  1. package/README.dev.md +36 -13
  2. package/README.md +3 -1
  3. package/dist/es/core/events.js +36 -25
  4. package/dist/es/core/settings.js +33 -22
  5. package/dist/es/index.js +92 -88
  6. package/dist/es/ui/dialog.js +57 -46
  7. package/dist/es/ui/index.d.ts +2 -0
  8. package/dist/es/ui/modal-builder.js +39 -28
  9. package/dist/es/ui/overflow-scroller.js +30 -24
  10. package/dist/es/ui/programmatic-modal.js +55 -0
  11. package/dist/es/ui/proxy-click.js +37 -26
  12. package/dist/es/ui/resizer.js +57 -49
  13. package/dist/es/ui/slider.d.ts.map +1 -1
  14. package/dist/es/ui/slider.js +90 -67
  15. package/dist/es/ui/tab-manager.d.ts +145 -0
  16. package/dist/es/ui/tab-manager.d.ts.map +1 -0
  17. package/dist/es/ui/tab-manager.js +155 -0
  18. package/dist/es/ui/tabs.d.ts +5 -5
  19. package/dist/es/ui/tabs.d.ts.map +1 -1
  20. package/dist/es/ui/tabs.js +34 -51
  21. package/dist/es/ui/theme-toggle.js +80 -69
  22. package/dist/es/ui/tooltip.js +53 -44
  23. package/dist/es/utils/floating-ui.js +35 -24
  24. package/dist/umd/frontend.css +1 -0
  25. package/dist/umd/ulu-frontend.umd.js +40 -47
  26. package/lib/js/exports.md +1 -0
  27. package/lib/js/ui/index.js +8 -0
  28. package/lib/js/ui/slider.js +3 -3
  29. package/lib/js/ui/tab-manager.js +324 -0
  30. package/lib/js/ui/tabs.js +33 -92
  31. package/lib/scss/_breakpoint.scss +3 -3
  32. package/lib/scss/_button.scss +3 -3
  33. package/lib/scss/_color.scss +3 -2
  34. package/lib/scss/_element.scss +10 -4
  35. package/lib/scss/_layout.scss +11 -4
  36. package/lib/scss/_selector.scss +2 -1
  37. package/lib/scss/_typography.scss +9 -10
  38. package/lib/scss/_utils.scss +52 -19
  39. package/lib/scss/base/_elements.scss +1 -1
  40. package/lib/scss/components/_basic-hero.scss +1 -1
  41. package/lib/scss/components/_button-verbose.scss +2 -2
  42. package/lib/scss/components/_callout.scss +3 -4
  43. package/lib/scss/components/_css-icon.scss +2 -2
  44. package/lib/scss/components/_data-grid.scss +5 -5
  45. package/lib/scss/components/_flipcard.scss +3 -2
  46. package/lib/scss/components/_index.scss +6 -0
  47. package/lib/scss/components/_panel.scss +1 -1
  48. package/lib/scss/components/_popover.scss +9 -6
  49. package/lib/scss/components/_tabs.scss +20 -5
  50. package/lib/scss/components/_tagged.scss +59 -0
  51. package/package.json +25 -35
  52. package/dist/umd/style.css +0 -1
  53. package/lib/js/ui/dialog.todo +0 -3
package/README.dev.md CHANGED
@@ -1,22 +1,45 @@
1
- # Development
1
+ # Development Overview
2
2
 
3
- ## Dist
3
+ ## System Architecture
4
4
 
5
- - Dist can be used standalone (browser, etc) (stylesheet with everything currently)
6
- - Used for examples in docs
7
- - Rebuild by running `npm run build`
5
+ The library is designed with a clear separation between styles (SCSS) and behavior (JavaScript). They are loosely coupled, interacting through CSS classes and data attributes in the HTML.
8
6
 
9
- ## Docs
7
+ * **SCSS:** Provides the styling layer. It is highly modular, with global settings (color, typography), base element styles, and individual component styles. The file `lib/scss/stylesheets/full.scss` compiles everything into a single, comprehensive stylesheet for easy consumption.
10
8
 
11
- ## Updating SCSS
9
+ * **JavaScript:** Provides interactivity. It is also modular, with `core` logic, `utility` functions, and `ui` components. The JavaScript is designed to be "tree-shakable," so a project using this library will only bundle the code for the components it actually uses.
12
10
 
13
- - Update sassdocs markdown by `npm run docs:update:scss`
11
+ ### How They Interact
14
12
 
15
- ## Updating JS Docs
13
+ 1. **Component Structure:** Components are composed of SCSS and JavaScript files. A component might be SCSS-only (providing styles for a static element), JavaScript-only (providing some background logic), or a pair of both that work together (e.g., `_tabs.scss` and `tabs.js`).
16
14
 
17
- - Run `npm run docs:build:js` to update jsdoc markdown
18
- - Run `npm run types` to update Typescript declarations (extracted from JS docs)
15
+ 2. **Initialization:** For components with JavaScript, an `init` function (e.g., `tabsInit`) is typically provided. This function scans the DOM for specific elements, usually identified by a `data-ulu-component` attribute.
19
16
 
20
- ## Building/Deploying
17
+ 3. **Styling Agnosticism:** A key design principle is that the JavaScript is styling-agnostic. It identifies and interacts with elements exclusively through `data-ulu-*` attributes, not CSS classes. This intentional separation means you can use the provided JavaScript functionality with completely custom component styling, simply by structuring your HTML with the correct data attributes.
21
18
 
22
- - Use `npm run docs:build`
19
+ 4. **Activation:** When an `init` function finds its corresponding component in the HTML, it instantiates a JavaScript class to manage its state and handle user interactions (like clicks or keyboard events).
20
+
21
+ 5. **State & Styling:** While the JavaScript itself is not tied to the SCSS styling, it does manage state by adding or removing state-based CSS classes (e.g., `.is-active`). The library's SCSS uses these classes to apply styles, and you can use them in your own stylesheets as well.
22
+
23
+ In short, the SCSS defines what components and their different states *look like*, while the JavaScript is responsible for activating components and changing their states based on user interaction. This creates a flexible and efficient system.
24
+
25
+
26
+ ## Benchmark Notes
27
+
28
+ ### Javascript
29
+
30
+ - Old Vite 4
31
+ - No build.target
32
+ - /dist/es 183kb (js, types, etc)
33
+ - Included aria-tablist dep
34
+ - Wasn't minified
35
+ - Current Build (Vite 7)
36
+ - Javascript Bundle
37
+ - Uncompressed: ~74.7 kB
38
+ - Gzip: ~30 kB (less when actually bundled with tree-shaking)
39
+ - About the size of jquery or a small image
40
+ - CSS Bundle
41
+ - Uncompressed: ~139 kB
42
+ - Gzip: ~21 kB (compresses well)
43
+ - In a real project not using every scss module
44
+ - Uncompressed: ~80-100 kB
45
+ - Gzip: ~13-16 kB
package/README.md CHANGED
@@ -6,11 +6,13 @@ Versatile frontend toolkit designed for a variety of web development scenarios.
6
6
 
7
7
  ## key Features
8
8
 
9
+ - **Lightweight Footprint:** The core library is very small, with the full UMD JavaScript bundle at ~20kb (gzipped) and the complete CSS bundle at ~19kb (gzipped). With tree-shaking and modular SCSS, the final footprint in a project is often even smaller.
9
10
  - **Target Environment:** The JavaScript "UI" modules are specifically tailored for traditional sites, such as static websites and CMS-driven platforms. However, the comprehensive SCSS modules are fully compatible and can be utilized in modern JavaScript applications built with frameworks like React or Vue.
10
11
  - **Configuration & Consistency:** The system's main goal is to allow for highly flexible, per-site configuration while maintaining a consistent set of accessible and high-quality components.
11
12
  - **Flexible Usage:** This library is designed as a toolkit, offering the flexibility to be used as a complete stylesheet solution or to pick and choose individual SCSS modules and components as needed.
13
+ - **Styling Agnostic JavaScript:** The JavaScript components use `data-*` attributes for behavior, not CSS classes. This means you can use the powerful JavaScript-driven interactions with your own custom-styled components.
12
14
  - **Integration Adaptability:** All SCSS base selectors (for components, utilities, etc.) can be easily adjusted, making it highly adaptable for seamless integration into pre-existing systems and diverse development environments.
13
- - API Documentation for both SCSS and JS with examples
15
+ - **API Documentation:** API Documentation for both SCSS and JS with demos
14
16
 
15
17
  ## Related Links
16
18
 
@@ -1,45 +1,56 @@
1
- import { debounce as s } from "@ulu/utils/performance.js";
2
- import { isBrowser as a } from "@ulu/utils/browser/dom.js";
3
- a() && (u(), f());
4
- const i = {
1
+ var u = Object.defineProperty;
2
+ var d = Object.getOwnPropertySymbols;
3
+ var f = Object.prototype.hasOwnProperty, v = Object.prototype.propertyIsEnumerable;
4
+ var s = (e, n, t) => n in e ? u(e, n, { enumerable: !0, configurable: !0, writable: !0, value: t }) : e[n] = t, a = (e, n) => {
5
+ for (var t in n || (n = {}))
6
+ f.call(n, t) && s(e, t, n[t]);
7
+ if (d)
8
+ for (var t of d(n))
9
+ v.call(n, t) && s(e, t, n[t]);
10
+ return e;
11
+ };
12
+ import { debounce as l } from "@ulu/utils/performance.js";
13
+ import { isBrowser as p } from "@ulu/utils/browser/dom.js";
14
+ p() && (b(), m());
15
+ const r = {
5
16
  pageModified(e) {
6
- e.dispatchEvent(n("pageModified"));
17
+ e.dispatchEvent(i("pageModified"));
7
18
  },
8
19
  pageResized(e) {
9
- e.dispatchEvent(n("pageResized"));
20
+ e.dispatchEvent(i("pageResized"));
10
21
  },
11
22
  beforePrint(e) {
12
- e.dispatchEvent(n("beforePrint"));
23
+ e.dispatchEvent(i("beforePrint"));
13
24
  },
14
25
  afterPrint(e) {
15
- e.dispatchEvent(n("afterPrint"));
26
+ e.dispatchEvent(i("afterPrint"));
16
27
  }
17
- }, c = Object.keys(i);
18
- function r(e, t) {
19
- i[e] ? i[e](t) : console.warn(`Unable to dispatch non-core event: ${e}`);
28
+ }, E = Object.keys(r);
29
+ function o(e, n) {
30
+ r[e] ? r[e](n) : console.warn(`Unable to dispatch non-core event: ${e}`);
20
31
  }
21
- function o(e) {
32
+ function c(e) {
22
33
  return "ulu:" + e;
23
34
  }
24
- function p(e) {
25
- return c.includes(e) ? o(e) : (console.warn(`'${e}' is not a valid core event type.`), null);
35
+ function h(e) {
36
+ return E.includes(e) ? c(e) : (console.warn(`'${e}' is not a valid core event type.`), null);
26
37
  }
27
- function n(e, t = null, d = { bubbles: !0 }) {
28
- return new CustomEvent(o(e), { detail: t, ...d });
38
+ function i(e, n = null, t = { bubbles: !0 }) {
39
+ return new CustomEvent(c(e), a({ detail: n }, t));
29
40
  }
30
- function u() {
31
- window.addEventListener("resize", s(() => r("pageResized", document), 250));
41
+ function b() {
42
+ window.addEventListener("resize", l(() => o("pageResized", document), 250));
32
43
  }
33
- function f() {
44
+ function m() {
34
45
  window.addEventListener("beforeprint", () => {
35
- r("beforePrint", document);
46
+ o("beforePrint", document);
36
47
  }), window.addEventListener("afterprint", () => {
37
- r("afterPrint", document);
48
+ o("afterPrint", document);
38
49
  });
39
50
  }
40
51
  export {
41
- n as createUluEvent,
42
- r as dispatchCoreEvent,
43
- p as getCoreEventName,
44
- o as getUluEventName
52
+ i as createUluEvent,
53
+ o as dispatchCoreEvent,
54
+ h as getCoreEventName,
55
+ c as getUluEventName
45
56
  };
@@ -1,4 +1,15 @@
1
- const c = {
1
+ var a = Object.defineProperty;
2
+ var i = Object.getOwnPropertySymbols;
3
+ var g = Object.prototype.hasOwnProperty, u = Object.prototype.propertyIsEnumerable;
4
+ var o = (n, t, s) => t in n ? a(n, t, { enumerable: !0, configurable: !0, writable: !0, value: s }) : n[t] = s, c = (n, t) => {
5
+ for (var s in t || (t = {}))
6
+ g.call(t, s) && o(n, s, t[s]);
7
+ if (i)
8
+ for (var s of i(t))
9
+ u.call(t, s) && o(n, s, t[s]);
10
+ return n;
11
+ };
12
+ const r = {
2
13
  iconClassClose: "css-icon css-icon--close",
3
14
  iconClassDragX: "css-icon css-icon--drag-x",
4
15
  iconClassDragBoth: "css-icon css-icon--drag-both",
@@ -6,39 +17,39 @@ const c = {
6
17
  iconClassNext: "css-icon css-icon--angle-right",
7
18
  cssvarPrefix: ""
8
19
  };
9
- let t = { ...c };
10
- function o() {
11
- return { ...c };
20
+ let e = c({}, r);
21
+ function S() {
22
+ return c({}, r);
12
23
  }
13
- function r(n) {
14
- Object.assign(t, n);
24
+ function d(n) {
25
+ Object.assign(e, n);
15
26
  }
16
- function a() {
17
- return { ...t };
27
+ function p() {
28
+ return c({}, e);
18
29
  }
19
- function i(n) {
20
- if (!t.hasOwnProperty(n)) {
30
+ function l(n) {
31
+ if (!e.hasOwnProperty(n)) {
21
32
  console.warn(`Attempted to access non-existent setting: ${n}`);
22
33
  return;
23
34
  }
24
- return t[n];
35
+ return e[n];
25
36
  }
26
- function g(n, s) {
27
- t[n] = s;
37
+ function C(n, t) {
38
+ e[n] = t;
28
39
  }
29
- function u(n, s) {
40
+ function x(n, t) {
30
41
  return {
31
42
  toString() {
32
- const e = i(n);
33
- return s ? s(e) : e;
43
+ const s = l(n);
44
+ return t ? t(s) : s;
34
45
  }
35
46
  };
36
47
  }
37
48
  export {
38
- o as getDefaultSettings,
39
- i as getSetting,
40
- a as getSettings,
41
- g as updateSetting,
42
- r as updateSettings,
43
- u as wrapSettingString
49
+ S as getDefaultSettings,
50
+ l as getSetting,
51
+ p as getSettings,
52
+ C as updateSetting,
53
+ d as updateSettings,
54
+ x as wrapSettingString
44
55
  };
package/dist/es/index.js CHANGED
@@ -4,120 +4,124 @@ import { ComponentInitializer as m } from "./core/component.js";
4
4
  import { BreakpointManager as I } from "./ui/breakpoints.js";
5
5
  import { Collapsible as z } from "./ui/collapsible.js";
6
6
  import { init as D, initializer as C, setupGroup as v } from "./ui/details-group.js";
7
- import { baseAttribute as y, closeAttribute as T, defaults as B, getDialogOptions as h, init as A, initializer as P, setDefaults as k, setupDialog as G, setupTrigger as L } from "./ui/dialog.js";
8
- import { Flipcard as w, init as U, initializer as V } from "./ui/flipcard.js";
9
- import { init as M, initializer as O } from "./ui/grid.js";
7
+ import { baseAttribute as T, closeAttribute as y, defaults as B, getDialogOptions as P, init as h, initializer as A, setDefaults as k, setupDialog as G, setupTrigger as L } from "./ui/dialog.js";
8
+ import { Flipcard as M, init as w, initializer as U } from "./ui/flipcard.js";
9
+ import { init as F, initializer as O } from "./ui/grid.js";
10
10
  import { buildModal as N, defaults as R, init as W, initializer as K, setDefaults as j } from "./ui/modal-builder.js";
11
- import { OverflowScroller as J } from "./ui/overflow-scroller.js";
12
- import { createPager as X } from "./ui/overflow-scroller-pager.js";
13
- import { init as Z } from "./ui/page.js";
14
- import { Popover as $, getContentByTrigger as ee, init as te, initializer as ie, instances as re, resolve as ae } from "./ui/popover.js";
15
- import { attrs as se, init as le } from "./ui/print-details.js";
16
- import { init as pe } from "./ui/print.js";
17
- import { attachHandlers as ue, defaults as fe, init as de, initializer as me, setDefaults as xe, setupProxy as Ie } from "./ui/proxy-click.js";
18
- import { Resizer as ze } from "./ui/resizer.js";
19
- import { init as De, initializer as Ce } from "./ui/scroll-slider.js";
20
- import { Scrollpoint as be, init as ye, initializer as Te } from "./ui/scrollpoint.js";
21
- import { Slider as he, init as Ae, initializer as Pe, setupSlider as ke } from "./ui/slider.js";
22
- import { init as Le, initializer as Ee, instances as we, setup as Ue } from "./ui/tabs.js";
23
- import { defaults as Fe, init as Me, initializer as Oe, setDefaults as He, setupToggle as Ne } from "./ui/theme-toggle.js";
24
- import { Tooltip as We, init as Ke, initializer as je } from "./ui/tooltip.js";
25
- import { log as Je, logError as Qe, logWarning as Xe, set as Ye } from "./utils/class-logger.js";
26
- import { dataAttributeToDatasetKey as _e, resolveClasses as $e, setPositionClasses as et } from "./utils/dom.js";
27
- import { FileSave as it } from "./utils/file-save.js";
28
- import { createFloatingUi as at, defaults as ot } from "./utils/floating-ui.js";
29
- import { configureIcons as lt } from "./utils/font-awesome.js";
30
- import { ensureId as pt, newId as gt } from "./utils/id.js";
31
- import { pauseVideos as ft, prepVideos as dt } from "./utils/pause-youtube-video.js";
11
+ import { ProgrammaticModalManager as J } from "./ui/programmatic-modal.js";
12
+ import { OverflowScroller as X } from "./ui/overflow-scroller.js";
13
+ import { createPager as Z } from "./ui/overflow-scroller-pager.js";
14
+ import { init as $ } from "./ui/page.js";
15
+ import { Popover as te, getContentByTrigger as ie, init as re, initializer as ae, instances as oe, resolve as se } from "./ui/popover.js";
16
+ import { attrs as ne, init as pe } from "./ui/print-details.js";
17
+ import { init as ue } from "./ui/print.js";
18
+ import { attachHandlers as de, defaults as me, init as xe, initializer as Ie, setDefaults as ce, setupProxy as ze } from "./ui/proxy-click.js";
19
+ import { Resizer as De } from "./ui/resizer.js";
20
+ import { init as ve, initializer as be } from "./ui/scroll-slider.js";
21
+ import { Scrollpoint as ye, init as Be, initializer as Pe } from "./ui/scrollpoint.js";
22
+ import { Slider as Ae, init as ke, initializer as Ge, setupSlider as Le } from "./ui/slider.js";
23
+ import { TabManager as Me } from "./ui/tab-manager.js";
24
+ import { init as Ue, initializer as Ve, instances as Fe, setup as Oe } from "./ui/tabs.js";
25
+ import { defaults as Ne, init as Re, initializer as We, setDefaults as Ke, setupToggle as je } from "./ui/theme-toggle.js";
26
+ import { Tooltip as Je, init as Qe, initializer as Xe } from "./ui/tooltip.js";
27
+ import { log as Ze, logError as _e, logWarning as $e, set as et } from "./utils/class-logger.js";
28
+ import { dataAttributeToDatasetKey as it, resolveClasses as rt, setPositionClasses as at } from "./utils/dom.js";
29
+ import { FileSave as st } from "./utils/file-save.js";
30
+ import { createFloatingUi as nt, defaults as pt } from "./utils/floating-ui.js";
31
+ import { configureIcons as ut } from "./utils/font-awesome.js";
32
+ import { ensureId as dt, newId as mt } from "./utils/id.js";
33
+ import { pauseVideos as It, prepVideos as ct } from "./utils/pause-youtube-video.js";
32
34
  export {
33
35
  I as BreakpointManager,
34
36
  z as Collapsible,
35
37
  m as ComponentInitializer,
36
- it as FileSave,
37
- w as Flipcard,
38
- J as OverflowScroller,
39
- $ as Popover,
40
- ze as Resizer,
41
- be as Scrollpoint,
42
- he as Slider,
43
- We as Tooltip,
44
- Je as classLoggerLog,
45
- Qe as classLoggerLogError,
46
- Xe as classLoggerLogWarning,
47
- Ye as classLoggerSet,
48
- at as createFloatingUi,
38
+ st as FileSave,
39
+ M as Flipcard,
40
+ X as OverflowScroller,
41
+ te as Popover,
42
+ J as ProgrammaticModalManager,
43
+ De as Resizer,
44
+ ye as Scrollpoint,
45
+ Ae as Slider,
46
+ Me as TabManager,
47
+ Je as Tooltip,
48
+ Ze as classLoggerLog,
49
+ _e as classLoggerLogError,
50
+ $e as classLoggerLogWarning,
51
+ et as classLoggerSet,
52
+ nt as createFloatingUi,
49
53
  i as createUluEvent,
50
- _e as dataAttributeToDatasetKey,
54
+ it as dataAttributeToDatasetKey,
51
55
  D as detailsGroupInit,
52
56
  C as detailsGroupInitializer,
53
57
  v as detailsGroupSetupGroup,
54
- y as dialogBaseAttribute,
55
- T as dialogCloseAttribute,
58
+ T as dialogBaseAttribute,
59
+ y as dialogCloseAttribute,
56
60
  B as dialogDefaults,
57
- h as dialogGetDialogOptions,
58
- A as dialogInit,
59
- P as dialogInitializer,
61
+ P as dialogGetDialogOptions,
62
+ h as dialogInit,
63
+ A as dialogInitializer,
60
64
  k as dialogSetDefaults,
61
65
  G as dialogSetupDialog,
62
66
  L as dialogSetupTrigger,
63
67
  r as dispatchCoreEvent,
64
- pt as ensureId,
65
- U as flipcardInit,
66
- V as flipcardInitializer,
67
- ot as floatingUiDefaults,
68
- lt as fontAwesomeConfigureIcons,
68
+ dt as ensureId,
69
+ w as flipcardInit,
70
+ U as flipcardInitializer,
71
+ pt as floatingUiDefaults,
72
+ ut as fontAwesomeConfigureIcons,
69
73
  a as getCoreEventName,
70
74
  l as getDefaultSettings,
71
75
  n as getSetting,
72
76
  p as getSettings,
73
77
  o as getUluEventName,
74
- M as gridInit,
78
+ F as gridInit,
75
79
  O as gridInitializer,
76
80
  N as modalBuilderBuildModal,
77
81
  R as modalBuilderDefaults,
78
82
  W as modalBuilderInit,
79
83
  K as modalBuilderInitializer,
80
84
  j as modalBuilderSetDefaults,
81
- gt as newId,
82
- X as overflowScrollerCreatePager,
83
- Z as pageInit,
84
- ee as popoverGetContentByTrigger,
85
- te as popoverInit,
86
- ie as popoverInitializer,
87
- re as popoverInstances,
88
- ae as popoverResolve,
89
- se as printDetailsAttrs,
90
- le as printDetailsInit,
91
- pe as printInit,
92
- ue as proxyClickAttachHandlers,
93
- fe as proxyClickDefaults,
94
- de as proxyClickInit,
95
- me as proxyClickInitializer,
96
- xe as proxyClickSetDefaults,
97
- Ie as proxyClickSetupProxy,
98
- $e as resolveClasses,
99
- De as scrollSliderInit,
100
- Ce as scrollSliderInitializer,
101
- ye as scrollpointInit,
102
- Te as scrollpointInitializer,
103
- et as setPositionClasses,
104
- Ae as sliderInit,
105
- Pe as sliderInitializer,
106
- ke as sliderSetupSlider,
107
- Le as tabsInit,
108
- Ee as tabsInitializer,
109
- we as tabsInstances,
110
- Ue as tabsSetup,
111
- Fe as themeToggleDefaults,
112
- Me as themeToggleInit,
113
- Oe as themeToggleInitializer,
114
- He as themeToggleSetDefaults,
115
- Ne as themeToggleSetupToggle,
116
- Ke as tooltipInit,
117
- je as tooltipInitializer,
85
+ mt as newId,
86
+ Z as overflowScrollerCreatePager,
87
+ $ as pageInit,
88
+ ie as popoverGetContentByTrigger,
89
+ re as popoverInit,
90
+ ae as popoverInitializer,
91
+ oe as popoverInstances,
92
+ se as popoverResolve,
93
+ ne as printDetailsAttrs,
94
+ pe as printDetailsInit,
95
+ ue as printInit,
96
+ de as proxyClickAttachHandlers,
97
+ me as proxyClickDefaults,
98
+ xe as proxyClickInit,
99
+ Ie as proxyClickInitializer,
100
+ ce as proxyClickSetDefaults,
101
+ ze as proxyClickSetupProxy,
102
+ rt as resolveClasses,
103
+ ve as scrollSliderInit,
104
+ be as scrollSliderInitializer,
105
+ Be as scrollpointInit,
106
+ Pe as scrollpointInitializer,
107
+ at as setPositionClasses,
108
+ ke as sliderInit,
109
+ Ge as sliderInitializer,
110
+ Le as sliderSetupSlider,
111
+ Ue as tabsInit,
112
+ Ve as tabsInitializer,
113
+ Fe as tabsInstances,
114
+ Oe as tabsSetup,
115
+ Ne as themeToggleDefaults,
116
+ Re as themeToggleInit,
117
+ We as themeToggleInitializer,
118
+ Ke as themeToggleSetDefaults,
119
+ je as themeToggleSetupToggle,
120
+ Qe as tooltipInit,
121
+ Xe as tooltipInitializer,
118
122
  g as updateSetting,
119
123
  u as updateSettings,
120
124
  f as wrapSettingString,
121
- ft as youtubePauseVideos,
122
- dt as youtubePrepVideos
125
+ It as youtubePauseVideos,
126
+ ct as youtubePrepVideos
123
127
  };
@@ -1,8 +1,19 @@
1
- import { getUluEventName as f } from "../core/events.js";
2
- import { ComponentInitializer as v } from "../core/component.js";
3
- import { preventScroll as h, wasClickOutside as E } from "@ulu/utils/browser/dom.js";
4
- import { prepVideos as O, pauseVideos as S } from "../utils/pause-youtube-video.js";
5
- const b = "data-ulu-dialog", i = new v({ type: "dialog", baseAttribute: b }), F = i.getAttribute("close"), V = {
1
+ var O = Object.defineProperty;
2
+ var f = Object.getOwnPropertySymbols;
3
+ var S = Object.prototype.hasOwnProperty, b = Object.prototype.propertyIsEnumerable;
4
+ var m = (e, o, t) => o in e ? O(e, o, { enumerable: !0, configurable: !0, writable: !0, value: t }) : e[o] = t, g = (e, o) => {
5
+ for (var t in o || (o = {}))
6
+ S.call(o, t) && m(e, t, o[t]);
7
+ if (f)
8
+ for (var t of f(o))
9
+ b.call(o, t) && m(e, t, o[t]);
10
+ return e;
11
+ };
12
+ import { getUluEventName as v } from "../core/events.js";
13
+ import { ComponentInitializer as V } from "../core/component.js";
14
+ import { preventScroll as w, wasClickOutside as C } from "@ulu/utils/browser/dom.js";
15
+ import { prepVideos as D, pauseVideos as k } from "../utils/pause-youtube-video.js";
16
+ const L = "data-ulu-dialog", i = new V({ type: "dialog", baseAttribute: L }), x = i.getAttribute("close"), y = {
6
17
  /**
7
18
  * Use non-modal interface for dialog
8
19
  */
@@ -30,83 +41,83 @@ const b = "data-ulu-dialog", i = new v({ type: "dialog", baseAttribute: b }), F
30
41
  */
31
42
  preventScrollShift: !0
32
43
  };
33
- let a = { ...V };
34
- function R(e) {
44
+ let a = g({}, y);
45
+ function P(e) {
35
46
  a = Object.assign({}, a, e);
36
47
  }
37
- function T() {
48
+ function U() {
38
49
  i.init({
39
50
  coreEvents: ["pageModified"],
40
51
  withData: !0,
41
- setup({ element: e, initialize: s, data: t }) {
42
- C(e, t), s();
52
+ setup({ element: e, initialize: o, data: t }) {
53
+ M(e, t), o();
43
54
  }
44
55
  }), i.init({
45
56
  key: "trigger",
46
57
  coreEvents: ["pageModified"],
47
58
  withData: !0,
48
- setup({ element: e, initialize: s, data: t }) {
49
- w(e, t), s();
59
+ setup({ element: e, initialize: o, data: t }) {
60
+ z(e, t), o();
50
61
  }
51
62
  });
52
63
  }
53
- function w(e, s) {
64
+ function z(e, o) {
54
65
  e.addEventListener("click", t);
55
66
  function t(r) {
56
67
  var c;
57
68
  r.target.closest("a") && r.preventDefault();
58
- const o = document.getElementById(s);
59
- if (!o) {
60
- console.error("Could not locate dialog (id)", s);
69
+ const n = document.getElementById(o);
70
+ if (!n) {
71
+ console.error("Could not locate dialog (id)", o);
61
72
  return;
62
73
  }
63
- if (((c = o == null ? void 0 : o.tagName) == null ? void 0 : c.toLowerCase()) !== "dialog") {
74
+ if (((c = n == null ? void 0 : n.tagName) == null ? void 0 : c.toLowerCase()) !== "dialog") {
64
75
  console.error("Attempted to trigger non <dialog> element. Did you mean to use modal builder?");
65
76
  return;
66
77
  }
67
- const u = D(o);
68
- o[u.nonModal ? "show" : "showModal"]();
78
+ const u = A(n);
79
+ n[u.nonModal ? "show" : "showModal"]();
69
80
  }
70
81
  }
71
- function C(e, s) {
72
- const t = Object.assign({}, a, s), r = document.body, { preventScrollShift: d } = t;
73
- let o;
74
- if (e.addEventListener(f("resizer:start"), c), e.addEventListener(f("resizer:end"), m), e.addEventListener("click", u), t.documentEnd && r.appendChild(e), t.pauseVideos && k(e), !t.nonModal && t.preventScroll) {
75
- let n;
82
+ function M(e, o) {
83
+ const t = Object.assign({}, a, o), r = document.body, { preventScrollShift: d } = t;
84
+ let n;
85
+ if (e.addEventListener(v("resizer:start"), c), e.addEventListener(v("resizer:end"), h), e.addEventListener("click", u), t.documentEnd && r.appendChild(e), t.pauseVideos && I(e), !t.nonModal && t.preventScroll) {
86
+ let s;
76
87
  e.addEventListener("toggle", (l) => {
77
- l.newState === "open" ? n = h({ preventShift: d }) : n && n();
88
+ l.newState === "open" ? s = w({ preventShift: d }) : s && s();
78
89
  });
79
90
  }
80
- function u(n) {
81
- const { target: l } = n, p = l === e, g = l.closest(i.attributeSelector("close"));
82
- (!o && t.clickOutsideCloses && p && E(e, n) || g) && (t.pauseVideos && L(e), e.close());
91
+ function u(s) {
92
+ const { target: l } = s, p = l === e, E = l.closest(i.attributeSelector("close"));
93
+ (!n && t.clickOutsideCloses && p && C(e, s) || E) && (t.pauseVideos && j(e), e.close());
83
94
  }
84
- function c(n) {
85
- o = n.pointerId;
95
+ function c(s) {
96
+ n = s.pointerId;
86
97
  }
87
- function m(n) {
88
- o === n.pointerId && setTimeout(() => {
89
- o = null;
98
+ function h(s) {
99
+ n === s.pointerId && setTimeout(() => {
100
+ n = null;
90
101
  }, 0);
91
102
  }
92
103
  }
93
- function D(e) {
104
+ function A(e) {
94
105
  return Object.assign({}, a, i.getData(e));
95
106
  }
96
- function k(e) {
97
- O(e);
107
+ function I(e) {
108
+ D(e);
98
109
  }
99
- function L(e) {
100
- S(e), e.querySelectorAll("video").forEach((t) => t.pause());
110
+ function j(e) {
111
+ k(e), e.querySelectorAll("video").forEach((t) => t.pause());
101
112
  }
102
113
  export {
103
- b as baseAttribute,
104
- F as closeAttribute,
105
- V as defaults,
106
- D as getDialogOptions,
107
- T as init,
114
+ L as baseAttribute,
115
+ x as closeAttribute,
116
+ y as defaults,
117
+ A as getDialogOptions,
118
+ U as init,
108
119
  i as initializer,
109
- R as setDefaults,
110
- C as setupDialog,
111
- w as setupTrigger
120
+ P as setDefaults,
121
+ M as setupDialog,
122
+ z as setupTrigger
112
123
  };
@@ -1,10 +1,12 @@
1
1
  export { BreakpointManager } from './breakpoints.js';
2
2
  export { Collapsible } from './collapsible.js';
3
+ export { ProgrammaticModalManager } from './programmatic-modal.js';
3
4
  export { OverflowScroller } from './overflow-scroller.js';
4
5
  export { createPager as overflowScrollerCreatePager } from './overflow-scroller-pager.js';
5
6
  export { init as pageInit } from './page.js';
6
7
  export { init as printInit } from './print.js';
7
8
  export { Resizer } from './resizer.js';
9
+ export { TabManager } from './tab-manager.js';
8
10
  export { init as detailsGroupInit, initializer as detailsGroupInitializer, setupGroup as detailsGroupSetupGroup } from './details-group.js';
9
11
  export { baseAttribute as dialogBaseAttribute, closeAttribute as dialogCloseAttribute, defaults as dialogDefaults, getDialogOptions as dialogGetDialogOptions, init as dialogInit, initializer as dialogInitializer, setDefaults as dialogSetDefaults, setupDialog as dialogSetupDialog, setupTrigger as dialogSetupTrigger } from './dialog.js';
10
12
  export { Flipcard, init as flipcardInit, initializer as flipcardInitializer } from './flipcard.js';